Actions8
Get Company Hierarchy
AI-generatedSummary
Fetches the corporate hierarchy (companies in the same global ultimate hierarchy) for a DataMerge company ID via GET /v1/company/hierarchy, with optional filters and pagination.
Inputs
- DataMerge ID (required) — DataMerge company ID (e.g. DM001283124635) used as the root of the hierarchy.
- Country Codes — Multiple ISO 3166-1 alpha-2 codes; only companies from these countries are returned. Sent only if at least one is provided.
- Include Branches — Include branches and divisions in results. Default false.
- Include Company Names — Include company names in results. Charges 1 credit per request when true. Default false.
- Only Subsidiaries — Return only companies that are subsidiaries of the given company. Default false.
- Max Level — Maximum hierarchy level to return; 0 (default) means no limit and the parameter is not sent.
- Page — Page number of results, minimum 1. Default 1.
Output shape
One output item per input item, containing the API response JSON as-is. The results array (if present) has each entry's hierarchy_id field removed.
Pagination is manual: increase Page to fetch more results. Errors throw a NodeApiError, or if Continue On Fail is enabled, output an item with an
errormessage. Names are only included when Include Company Names is enabled.
Examples
Example 1: List all subsidiaries of a parent company with names, limited to two levels deep
DataMerge ID = DM001283124635, Only Subsidiaries = true, Include Company Names = true, Max Level = 2
Example 2: Find a company's German and French entities including branches
DataMerge ID = DM001283124635, Country Codes = DE, FR, Include Branches = true