MailcrateDocs
Events

Record a contact event

POST
/public/event

Records a custom event against a contact, which segments and journey triggers can match on. Identify the contact by contactId, email or externalIdentifier.

Requires the event:write scope.

Authorization

ApiKey
headerAuthorization<token>

Api-Key mc_... — a workspace API key.

Request Body

application/json
  1. body
name*string
Match^[a-zA-Z0-9][a-zA-Z0-9 ._-]*$
Length1 <= length <= 100
email?string
Formatemail
contactId?string
Formatuuid
externalIdentifier?string
properties?
occurredAt?string
idempotencyKey?string
Lengthlength <= 255

Response Body

application/json
  1. response
id*string
name*string
contactId*string
occurredAt*string
Formatdate-time
deduplicated*boolean
Example Request
curl -X POST 'https://api.mailcrate.io/public/event' \  -H 'Authorization: Api-Key <api_key>' \  -H 'Content-Type: application/json' \  -d '{  "name": "string"}'
Example Response
{  "id": "string",  "name": "string",  "contactId": "string",  "occurredAt": "2019-08-24T14:15:22Z",  "deduplicated": true}