Actions41
- Companies Actions
- Search companies
- Search companies (POST)
- Enrich company
- Search companies by name
- Search companies by prompt
- Search similar companies
- Count companies
- Count companies (POST)
- Enrich company by email
- Enrich company by social
- Get email patterns
- Ask company
- Get company context
- Fetch companies analytics
- Export companies analytics
- Lists Actions
- Locations Actions
- Business data Actions
- Actions Actions
- Prompts Actions
- Utilities Actions
Overview
This node allows users to search for counties using The Companies API. It is useful in scenarios where geographic data segmentation or filtering by county is needed, such as market research, regional sales analysis, or location-based enrichment of company data.
For example, a user might want to find all counties matching a certain search term, paginate through results, and sort them by the number of companies present in each county. This can help businesses target specific regions or analyze geographic distribution of companies.
Properties
| Name | Meaning |
|---|---|
| Search | A string query to search for counties by name or keyword. |
| Page | The page number of the paginated results to retrieve (default is 1). |
| Size | The number of results per page (default is 25). |
| Sort key | The field by which to sort the results. Currently supports: Counts > companies |
| Sort order | The order of sorting: Ascending (asc) or Descending (desc). Default is Descending. |
Output
The node outputs JSON data containing the search results from the API. Each item corresponds to a county matching the search criteria, including metadata such as counts of companies within that county.
The output structure is:
{
"data": [
{
// County details and associated metadata, e.g.:
"id": "string",
"name": "string",
"counts": {
"companies": number
},
...
}
]
}
No binary data output is produced by this node.
Dependencies
- Requires an API token credential for authenticating with The Companies API.
- Uses the official SDK of The Companies API to perform requests.
- The node expects the API token to be configured in n8n credentials before execution.
Troubleshooting
- Unknown operation error: If the operation parameter is set incorrectly or not supported, the node will throw an error indicating an unknown operation. Ensure the operation is set to
searchCountieswhen searching counties. - SDK method not found: If the SDK does not have the expected method, it indicates a mismatch between the node's operation and the SDK version. Updating the SDK or node may resolve this.
- Empty or invalid parameters: Parameters like
search,page, orsizeshould be valid; otherwise, default values are applied. Make sure to provide meaningful search terms to get results. - API authentication errors: If the API token is missing or invalid, the node will fail to authenticate. Verify the API token credential configuration.
- Rate limiting or network issues: As with any API integration, network problems or rate limits may cause failures. Implement retry logic or handle errors gracefully using the node's "Continue On Fail" option.
Links and References
- The Companies API Documentation
- The Companies API SDK on npm (for reference)
- n8n documentation on Creating Custom Nodes