View Categories

21.2 Required Request Format

Endpoint: POST /api/integrations/events

You can also post to POST /api/integrations/{provider}/events. The provider name in the URL is used when the body does not include provider.

Required Headers:

Authorization: Bearer {your_tenant_api_token}
Content-Type: application/json
X-ArtinCRM-Timestamp: {Unix seconds or UTC ISO-8601}
X-ArtinCRM-Nonce: {unique value for this request}
X-ArtinCRM-Signature: {HMAC-SHA256 signature}
  • The timestamp must be within 5 minutes of Application’s clock.
  • Use a new nonce for every request. A nonce that was already used in the last 10 minutes is rejected.

Signature Calculation: The signature is an HMAC-SHA256 over:

{timestamp}\n{nonce}\n{raw_request_body}

Use the raw Bearer token value as the HMAC key, and the timestamp and nonce exactly as you send them in the headers. The result is lowercase hex, optionally prefixed with sha256=. Sign the exact body bytes you send: serializing the JSON again after signing changes the body and breaks the signature.

JSON Body Fields:

FieldRequiredWhat to send
providerYes, unless it is in the URLThe sending system, for example woocommerce or my-app (up to 64 characters)
connection.externalInstanceIdYesOne installation of that system, for example a store or an environment (up to 200 characters)
connection.externalInstanceName, connection.externalBaseUrlNoA readable name and the base URL of that installation
eventTypeYesA built-in type such as order.completed, or your own, such as trial.ending (up to 128 characters). Case is ignored, and dots, hyphens and spaces count as underscores, so trial.ending and trial_ending are the same type.
externalEventIdYesYour unique ID for this event (up to 200 characters). Repeats are recognized as duplicates (21.5).
occurredAtUtcNoWhen the event happened, as UTC ISO-8601
subjectType, subjectIdNoWhat the event is about, for example order and 1042
customerNofullName, email, whatsAppNumber (with country code) and externalCustomerId. Needed when a workflow should create or find the contact.
dataNoAny JSON object with further details of the event

Example:

{
  "provider": "my-app",
  "connection": {
    "externalInstanceId": "production"
  },
  "eventType": "trial.ending",
  "externalEventId": "evt_8421",
  "occurredAtUtc": "2026-11-01T09:00:00Z",
  "subjectType": "subscription",
  "subjectId": "sub_1042",
  "customer": {
    "externalCustomerId": "user_77",
    "fullName": "Daniel Ross",
    "email": "daniel@example.com",
    "whatsAppNumber": "+971501234567"
  },
  "data": {
    "plan": "Team",
    "daysLeft": 3
  }
}
Scroll to Top