The Companies API icon

The Companies API

Access company data, enrichment, analytics and more using The Companies API

Overview

This node integrates with The Companies API to fetch lists of companies. It allows users to retrieve paginated company lists, which can be useful for managing and analyzing groups of companies in various business scenarios. For example, marketing teams might use it to pull targeted company lists for campaigns, or sales teams could fetch segmented lists for outreach.

The "Fetch lists" operation specifically retrieves these company lists with pagination support, enabling efficient handling of large datasets by specifying the page number and size of each page.

Properties

Name Meaning
Page The page number of the list results to fetch. Defaults to 1.
Size The number of items per page to return. Defaults to 25.

Output

The node outputs JSON data containing the fetched lists of companies. The structure typically includes metadata about the lists and the companies within them as returned by The Companies API. Each output item corresponds to one input item, preserving pairing.

If an error occurs during fetching, the output JSON will contain an error field with the error message.

The node does not output binary data.

Dependencies

  • Requires an API token credential for authenticating with The Companies API.
  • Uses the official SDK from The Companies API (@thecompaniesapi/sdk) bundled within the node.
  • No additional environment variables are needed beyond the API token credential configured in n8n.

Troubleshooting

  • Unknown operation error: If the operation parameter is set incorrectly or to a non-existent value, the node throws an error indicating "Unknown operation". Ensure the operation is set exactly to "fetchLists".
  • SDK method not found: If the SDK method corresponding to the operation is missing, the node throws an error like "SDK method fetchLists not found". This usually indicates a version mismatch or internal issue; updating the node or SDK may help.
  • API authentication errors: If the API token is invalid or missing, requests will fail. Verify that the API token credential is correctly configured and has necessary permissions.
  • Empty or invalid parameters: The node applies default values if parameters like page or size are empty or zero. However, providing invalid types or out-of-range values may cause unexpected behavior. Use valid positive integers for pagination properties.

Links and References

Discussion