Ricky logorickyDocs

Change tags on many contacts

POST
/contacts/tags

Adds and removes the same tags on up to 100 contacts and answers one result per contact, in order. A tag ID the organization does not have refuses the whole request before any contact changes.

Scope: contacts:write.

Authorization

bearerAuth
headerAuthorizationBearer <token>

An organization API key, rky_live_…, created in Settings → API. Send it only from a server.

Idempotency-Key?string

Optional. A value you choose, unique per logical write, 8–200 characters: a UUID or an ID from your system such as order-10482-ready. Retrying with the same key and body replays the first response instead of repeating the write.

Length8 <= length <= 200

Request Body

application/json
  1. body

Adds and removes the same tags on many contacts. Their other tags stay.

contact_ids*array<>

Contacts to change, up to 100. Repeated IDs count once.

Items1 <= items <= 100
add_tag_ids?array<>

Tags to add. See GET /tags.

Itemsitems <= 30
Default[]
remove_tag_ids?array<>

Tags to remove.

Itemsitems <= 30
Default[]

Response Body

Success.

application/json
  1. response
data*array<>
next_cursor*|

Pass as cursor for the next page; null on the last page.

curl -X POST 'https://getricky.ai/api/v1/contacts/tags' \  -H 'Idempotency-Key: order-10482-ready' \  -H 'Content-Type: application/json' \  -d '{  "contact_ids": [    "3f6c2b1e-8d4a-4b7e-9a51-2c7d8e9f0a1b"  ],  "add_tag_ids": [    "5c6d7e8f-9a0b-4c1d-8e2f-3a4b5c6d7e8f"  ]}'
{  "data": [    {      "contact_id": "3f6c2b1e-8d4a-4b7e-9a51-2c7d8e9f0a1b",      "status": "updated",      "tags": [        {          "id": "5c6d7e8f-9a0b-4c1d-8e2f-3a4b5c6d7e8f",          "name": "Cliente frecuente",          "color": "gray"        }      ]    }  ],  "next_cursor": "string"}