- Create or update a tag, Tag or untag companies, Tag contacts
You can use this endpoint to perform the following operations:
1. Create a new tag: You can create a new tag by passing in the tag name as specified in "Create or Update Tag Request Payload" described below.
2. Update an existing tag: You can update an existing tag by passing the id of the tag as specified in "Create or Update Tag Request Payload" described below.
3. Tag Companies: You can tag single company or a list of companies. You can tag a company by passing in the tag name and the company details as specified in "Tag Company Request Payload" described below. Also, if the tag doesn't exist then a new one will be created automatically.
4. Untag Companies: You can untag a single company or a list of companies. You can untag a company by passing in the tag id and the company details as specified in "Untag Company Request Payload" described below.
5. Tag Multiple Users: You can tag a list of users. You can tag the users by passing in the tag name and the user details as specified in "Tag Users Request Payload" described below.
Each operation will return a tag object.
Contacts and companies listed in users or companies that do not exist are skipped: they are left out of the users and companies arrays in the response and the request still succeeds. With ids_to_add it depends on taggable_type: a contact id that does not exist returns a 404, while a company id that does not exist is skipped. With ids_to_add, the users and companies arrays in the response are always empty, and a 404 still leaves the tag created or renamed.
Requires the write_tags or write_users_companies OAuth scope.
Intercom API version.
If you omit the header, the API uses the version set in your app package, and 1.0 if none is set.
You can create or update an existing tag, and optionally apply it to a list of contact or company ids.
The name of the tag, which will be created if not found, or the new name for the tag if this is an update request. Names are case insensitive and can be at most 191 characters long. Creating a tag with a longer name returns a 400. When updating by id, a longer name or one that another tag already has returns 200 with the new name, but the tag keeps its old name.
The Intercom ids of the contacts or companies to apply the tag to. A contact id that does not exist returns a 404; a company id that does not exist is skipped. A 404 still leaves the tag created or renamed. The users and companies arrays in the response are always empty when this field is used.
[ "536e564f316c83104c000020" ]
- The production API serverhttps://api.intercom.io/tags
- The european API serverhttps://api.eu.intercom.io/tags
- The australian API serverhttps://api.au.intercom.io/tags
- Create or Update Tag Request Payload
- Tag Company Request Payload
- Untag Company Request Payload
- Tag Users Request Payload
- Action successful
- Companies tagged
- Invalid parameters
- Unknown company skipped
- Unknown user skipped
- Contact in ids_to_add not found
curl -i -X POST \
https://api.intercom.io/tags \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-H 'Intercom-Version: 2.17' \
-d '{
"name": "test"
}'Action successful
- Action successful
- Companies tagged
{ "type": "tag", "id": "105", "name": "test", "users": [], "companies": [] }