Migrate
Migrate customers
Migrate a customer from an old system to Masivo
POST
/
customers
/
migrate
Copy
curl --request POST \
--url https://app.masivo.ai/api/storefront/v1/customers/migrate \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"customers": [
{
"id": "<string>",
"name": "John Smith",
"email": "jsmith@example.com",
"gender": "MALE",
"dob": "2023-11-07T05:31:56Z",
"registration_date": "2023-11-07T05:31:56Z",
"metrics": {
"lifetime": {
"from": "2023-11-07T05:31:56Z",
"to": "2023-11-07T05:31:56Z",
"tier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"last_visit": "2023-11-07T05:31:56Z",
"last_session": "2023-11-07T05:31:56Z",
"spend_total": 123,
"number_of_purchases": 123
},
"last_year": {
"from": "2023-11-07T05:31:56Z",
"to": "2023-11-07T05:31:56Z",
"tier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"last_visit": "2023-11-07T05:31:56Z",
"last_session": "2023-11-07T05:31:56Z",
"spend_total": 123,
"number_of_purchases": 123
},
"this_year": {
"from": "2023-11-07T05:31:56Z",
"to": "2023-11-07T05:31:56Z",
"tier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"last_visit": "2023-11-07T05:31:56Z",
"last_session": "2023-11-07T05:31:56Z",
"spend_total": 123,
"number_of_purchases": 123
},
"last_month": {
"from": "2023-11-07T05:31:56Z",
"to": "2023-11-07T05:31:56Z",
"tier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"last_visit": "2023-11-07T05:31:56Z",
"last_session": "2023-11-07T05:31:56Z",
"spend_total": 123,
"number_of_purchases": 123
},
"this_month": {
"from": "2023-11-07T05:31:56Z",
"to": "2023-11-07T05:31:56Z",
"tier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"last_visit": "2023-11-07T05:31:56Z",
"last_session": "2023-11-07T05:31:56Z",
"spend_total": 123,
"number_of_purchases": 123
},
"last_quarter": {
"from": "2023-11-07T05:31:56Z",
"to": "2023-11-07T05:31:56Z",
"tier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"last_visit": "2023-11-07T05:31:56Z",
"last_session": "2023-11-07T05:31:56Z",
"spend_total": 123,
"number_of_purchases": 123
},
"this_quarter": {
"from": "2023-11-07T05:31:56Z",
"to": "2023-11-07T05:31:56Z",
"tier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"last_visit": "2023-11-07T05:31:56Z",
"last_session": "2023-11-07T05:31:56Z",
"spend_total": 123,
"number_of_purchases": 123
},
"last_semester": {
"from": "2023-11-07T05:31:56Z",
"to": "2023-11-07T05:31:56Z",
"tier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"last_visit": "2023-11-07T05:31:56Z",
"last_session": "2023-11-07T05:31:56Z",
"spend_total": 123,
"number_of_purchases": 123
},
"this_semester": {
"from": "2023-11-07T05:31:56Z",
"to": "2023-11-07T05:31:56Z",
"tier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"last_visit": "2023-11-07T05:31:56Z",
"last_session": "2023-11-07T05:31:56Z",
"spend_total": 123,
"number_of_purchases": 123
},
"updated_at": "2023-11-07T05:31:56Z"
},
"balance": [
{
"reward_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"amount": 123,
"expiration_date": "2023-11-07T05:31:56Z",
"brand_id": "<string>",
"channel_id": "<string>",
"store_id": "<string>",
"issued_at": "2023-11-07T05:31:56Z",
"funded_by": "<string>"
}
],
"devices": [
{
"device_token": "<string>",
"device_info": {
"platform": "ios",
"model": "<string>",
"osVersion": "<string>"
},
"expires_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z"
}
],
"tags": {},
"status": "ACTIVE",
"metadata": {}
}
]
}'
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
Customers batch enqueued successfully
Copy
curl --request POST \
--url https://app.masivo.ai/api/storefront/v1/customers/migrate \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"customers": [
{
"id": "<string>",
"name": "John Smith",
"email": "jsmith@example.com",
"gender": "MALE",
"dob": "2023-11-07T05:31:56Z",
"registration_date": "2023-11-07T05:31:56Z",
"metrics": {
"lifetime": {
"from": "2023-11-07T05:31:56Z",
"to": "2023-11-07T05:31:56Z",
"tier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"last_visit": "2023-11-07T05:31:56Z",
"last_session": "2023-11-07T05:31:56Z",
"spend_total": 123,
"number_of_purchases": 123
},
"last_year": {
"from": "2023-11-07T05:31:56Z",
"to": "2023-11-07T05:31:56Z",
"tier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"last_visit": "2023-11-07T05:31:56Z",
"last_session": "2023-11-07T05:31:56Z",
"spend_total": 123,
"number_of_purchases": 123
},
"this_year": {
"from": "2023-11-07T05:31:56Z",
"to": "2023-11-07T05:31:56Z",
"tier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"last_visit": "2023-11-07T05:31:56Z",
"last_session": "2023-11-07T05:31:56Z",
"spend_total": 123,
"number_of_purchases": 123
},
"last_month": {
"from": "2023-11-07T05:31:56Z",
"to": "2023-11-07T05:31:56Z",
"tier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"last_visit": "2023-11-07T05:31:56Z",
"last_session": "2023-11-07T05:31:56Z",
"spend_total": 123,
"number_of_purchases": 123
},
"this_month": {
"from": "2023-11-07T05:31:56Z",
"to": "2023-11-07T05:31:56Z",
"tier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"last_visit": "2023-11-07T05:31:56Z",
"last_session": "2023-11-07T05:31:56Z",
"spend_total": 123,
"number_of_purchases": 123
},
"last_quarter": {
"from": "2023-11-07T05:31:56Z",
"to": "2023-11-07T05:31:56Z",
"tier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"last_visit": "2023-11-07T05:31:56Z",
"last_session": "2023-11-07T05:31:56Z",
"spend_total": 123,
"number_of_purchases": 123
},
"this_quarter": {
"from": "2023-11-07T05:31:56Z",
"to": "2023-11-07T05:31:56Z",
"tier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"last_visit": "2023-11-07T05:31:56Z",
"last_session": "2023-11-07T05:31:56Z",
"spend_total": 123,
"number_of_purchases": 123
},
"last_semester": {
"from": "2023-11-07T05:31:56Z",
"to": "2023-11-07T05:31:56Z",
"tier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"last_visit": "2023-11-07T05:31:56Z",
"last_session": "2023-11-07T05:31:56Z",
"spend_total": 123,
"number_of_purchases": 123
},
"this_semester": {
"from": "2023-11-07T05:31:56Z",
"to": "2023-11-07T05:31:56Z",
"tier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"last_visit": "2023-11-07T05:31:56Z",
"last_session": "2023-11-07T05:31:56Z",
"spend_total": 123,
"number_of_purchases": 123
},
"updated_at": "2023-11-07T05:31:56Z"
},
"balance": [
{
"reward_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"amount": 123,
"expiration_date": "2023-11-07T05:31:56Z",
"brand_id": "<string>",
"channel_id": "<string>",
"store_id": "<string>",
"issued_at": "2023-11-07T05:31:56Z",
"funded_by": "<string>"
}
],
"devices": [
{
"device_token": "<string>",
"device_info": {
"platform": "ios",
"model": "<string>",
"osVersion": "<string>"
},
"expires_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z"
}
],
"tags": {},
"status": "ACTIVE",
"metadata": {}
}
]
}'
Copy
This response does not have an example.
Assistant
Responses are generated using AI and may contain mistakes.