The intercom API reference.
The intercom API reference.
curl -i -X POST \
'https://api.intercom.io/contacts/{id}/companies' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-H 'Intercom-Version: 2.10' \
-d '{
"id": "6657ac426abd0166b52ae1f9"
}'
{ "type": "company", "company_id": "1", "id": "6657ac426abd0166b52ae1f9", "app_id": "this_is_an_id166_that_should_be_at_least_", "name": "company6", "remote_created_at": 1717021762, "created_at": 1717021762, "updated_at": 1717021762, "monthly_spend": 0, "session_count": 0, "user_count": 1, "tags": { "type": "tag.list", "tags": [] }, "segments": { "type": "segment.list", "segments": [] }, "plan": {}, "custom_attributes": {} }
curl -i -X GET \
https://api.intercom.io/contacts/63a07ddf05a32042dffac965/companies \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Intercom-Version: 2.10'
successful
The majority of list resources in the API are paginated to allow clients to traverse data over multiple requests.
Their responses are likely to contain a pages object that hosts pagination links which a client can use to paginate through the data without having to construct a query. The link relations for the pages field are as follows.
{ "type": "list", "data": [ { … } ], "pages": { "type": "pages", "next": null, "page": 1, "per_page": 50, "total_pages": 1 }, "total_count": 1 }
curl -i -X DELETE \
https://api.intercom.io/contacts/58a430d35458202d41b1e65b/companies/58a430d35458202d41b1e65b \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Intercom-Version: 2.10'
{ "type": "company", "company_id": "1", "id": "6657ac456abd0166b52ae209", "app_id": "this_is_an_id174_that_should_be_at_least_", "name": "company8", "remote_created_at": 1717021765, "created_at": 1717021765, "updated_at": 1717021765, "monthly_spend": 0, "session_count": 0, "user_count": 0, "tags": { "type": "tag.list", "tags": [] }, "segments": { "type": "segment.list", "segments": [] }, "plan": {}, "custom_attributes": {} }