Create Customer Events
Required feature: **customer_events/create**
Section:
Group Create Customer Events. Base URL:https://instance_name.meiro.io/api/.
Create Customer Events [/customer_events/]
Create customer events [POST]
Required feature: customer_events/create
-
Attributes
- customer_events (array[CustomerEventUpload])
-
Request (application/json)
-
Headers
X-Access-Token: 1234567890abcdef
-
-
Response 201 (application/json)
{
"count": 1,
"customer_events": [
{
"payload": "{\"some\": \"json\"}",
"type": "app_transaction",
"version": "1-0-0",
"created": "2022-09-05 09:35:25.949395",
"source_id": "bank_app",
"event_time": "2022-08-01 13:12:00",
"id": "940a3fc506470ca2f702db546ede3953",
"event_id": "870bcfd3-abf0-f6a7-0b2f-577d3997dc21",
"user_identifier": "a"
}
]
}
Async Create Customer Events [/customer_events/async]
Initiate creation [POST]
Upload a CSV file with the following columns:
source_id, type, version, user_identifier, event_time, payload
The CSV file must:
- be compressed by gzip
- be without headers
- respect the order of columns above
Required feature: customer_events/create
-
Attributes
- customer_events (array[CustomerEventUpload])
-
Request
-
Headers
X-Access-Token: 1234567890abcdef Content-Type: application/octet-stream
-
-
Response 201 (application/json)
- Attributes (AsyncUpload)
Check status of async upload [GET /customer_events/async/{id}]
Required feature: customer_events/create
-
Parameters
-
id:41f2cc9a-f7df-4ef8-b2e1-1bd4e627639aID of AsyncUpload (returned by Initiate creation request) to check
-
-
Request
-
Headers
X-Access-Token: 1234567890abcdef
-
-
Response 200 (application/json)
- Attributes (AsyncUpload)