Skip to Content
Contacts

Change a contact's consent

POST
/contacts/{contactId}/consent

Either the legacy kind (opt_in / opt_out, which set both categories) or a status for one or both categories. Every change is kept in the consent history and the audit log. Opted-out contacts receive no business-initiated messages of that category from campaigns, the API or automations; docs/CONSENT.md has the rules.

Scope: contacts.update. Rate limit: 300 requests per minute per API key.

Authorization

apiKey contacts.update
headerAuthorizationBearer <msk_live_…>

An API key created under API keys in the panel: Authorization: Bearer msk_live_…. The key's scopes decide which operations it may call.

Scope: contacts.update

Path Parameters

contactId*string
Formatuuid

Request Body

application/json
  1. body

Give kind (legacy, both categories) or status.

category?string
Default"all"
Value in"marketing""service""all"
kind?string

Legacy: opt_in / opt_out sets both categories to opted_in / opted_out.

Value in"opt_in""opt_out"
note?string

The reason; kept in the history.

Lengthlength <= 500
status?ConsentStatus
Value in"opted_in""unknown""opt_out_requested""opted_out""resubscribed"

Response Body

Contact after the change

application/json
  1. response
data*
meta*
Example Request
curl -X POST 'https://app.messora.tech/api/v1/contacts/497f6eca-6276-4993-bfeb-53cbbbba6f08/consent' \  -H 'Content-Type: application/json' \  -d '{  "category": "marketing",  "note": "Asked by phone not to receive promotions",  "status": "opted_out"}'
Example Response
{  "data": {    "attributes": {      "city": "İstanbul",      "customer_no": "C-10293"    },    "consent": {      "marketing": {        "reason": null,        "source": "import",        "status": "opted_in",        "updated_at": "2026-10-01T10:00:00Z"      },      "meta_marketing_stopped_at": null,      "service": {        "reason": null,        "source": null,        "status": "unknown",        "updated_at": null      },      "undeliverable_at": null,      "undeliverable_code": null    },    "created_at": "2026-09-12T07:30:00Z",    "created_by_inbound_at": null,    "email": "ayse@example.com",    "group_ids": [      "019a8c2e-4f1b-7a0d-9c3d-5e7a1000000d"    ],    "id": "019a8c2e-4f1b-7a09-9c3d-5e7a10000009",    "last_inbound_at": "2026-11-25T08:41:00Z",    "name": "Ayşe Yılmaz",    "opted_out": false,    "opted_out_at": null,    "phone": "+905321234567",    "profile_name": "Ayşe",    "profile_status": null,    "source": "api",    "tags": [      {        "color": "#16a34a",        "id": "019a8c2e-4f1b-7a0c-9c3d-5e7a1000000c",        "name": "vip"      }    ],    "updated_at": "2026-11-25T08:41:00Z",    "var1": "Gold",    "var2": null,    "var3": null,    "var4": null,    "var5": null  },  "meta": {    "request_id": "019a8c2e-4f1b-7fff-9c3d-5e7a1000ffff"  }}