Migrate
Migrate events
Migrate events from an old system to Masivo
POST
/
customers
/
migrate
/
events
Copy
curl --request POST \
--url https://app.masivo.ai/api/storefront/v1/customers/migrate/events \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"customers": [
{
"id": "<string>",
"events": [
{
"type": "PURCHASE",
"channel_id": "<string>",
"store_id": "<string>",
"brand_id": "<string>",
"order": {
"purchase_id": "<string>",
"channel_id": "<string>",
"store_id": "<string>",
"value": 20.95,
"discounted_value": 10.95,
"products": [
{
"sku": "<string>",
"amount": 123,
"value": 123,
"discounted_value": 123,
"redeem": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"amount": 1
}
],
"tags": {},
"metadata": {}
}
],
"shipping": {
"value": 3.25,
"discounted_value": 2.25,
"redeem": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"amount": 1
}
],
"tags": {},
"metadata": {}
},
"payment_method": "CREDIT",
"redeem": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"amount": 1
}
],
"metadata": {}
},
"fulfilled": true,
"issued_at": "2023-11-07T05:31:56Z",
"resolved_at": "2023-11-07T05:31:56Z"
}
]
}
]
}'
Copy
This response does not have an example.
Authorizations
Bearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
Body
application/json
Response
201
Customer events enqueued successfully
Copy
curl --request POST \
--url https://app.masivo.ai/api/storefront/v1/customers/migrate/events \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"customers": [
{
"id": "<string>",
"events": [
{
"type": "PURCHASE",
"channel_id": "<string>",
"store_id": "<string>",
"brand_id": "<string>",
"order": {
"purchase_id": "<string>",
"channel_id": "<string>",
"store_id": "<string>",
"value": 20.95,
"discounted_value": 10.95,
"products": [
{
"sku": "<string>",
"amount": 123,
"value": 123,
"discounted_value": 123,
"redeem": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"amount": 1
}
],
"tags": {},
"metadata": {}
}
],
"shipping": {
"value": 3.25,
"discounted_value": 2.25,
"redeem": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"amount": 1
}
],
"tags": {},
"metadata": {}
},
"payment_method": "CREDIT",
"redeem": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"amount": 1
}
],
"metadata": {}
},
"fulfilled": true,
"issued_at": "2023-11-07T05:31:56Z",
"resolved_at": "2023-11-07T05:31:56Z"
}
]
}
]
}'
Copy
This response does not have an example.
Assistant
Responses are generated using AI and may contain mistakes.