-
Notifications
You must be signed in to change notification settings - Fork 2
Mapp Connect API
API Keys Each integration will have a unique ID, this ID and random secret (if enabled) can be used to sign REST requests using HMAC Authentication. (https://en.wikipedia.org/wiki/Message_authentication_code)
EU L3 cluster: https://jamie.g.shortest-route.com/charon/api/v1/
US L3 cluster: https://jamie.a.shortest-route.com/charon/api/v1/
EMC cluster: https://jamie.h.shortest-route.com/charon/api/v1/
EMC-US cluster: https://jamie.c.shortest-route.com/charon/api/v1/
Mapp Connect Endpoints
- PING
- CONNECT
- EVENT
GET//ping For testing connectivity and authentication
Example response:
{ "ping": true, "integrationId": "47291122-e5bb-4865-a107-a68ec9957325", "timestamp": 1555054882877 }
POST//connect For setting config params and changing status to 'Connected'
Example request:
{ "params":{ "magentourl":"www.supermagento.pl", "someconfigparam":"42" } }
Response: HTTP status code
POST /integration//event{?subtype=} Request body can contain any JSON object. Example event that is sent to Kafka:
{ "id":"6d329d9b-201a-4188-a429-7e45d9a674a8", "timestamp":1555401662153, "integrationId":"47291122-e5bb-4865-a107-a68ec9957325", "type":"Import", "subtype":"xx", }
Response: HTTP status code
- user - add/updates contact data in Mapp Engage
- email - sends single or group email - requires prepared message-id
- sms- sends SMS to contact (either a phone number or to contact email if this contact has a phone number) - requires prepared SMS message-id
- push - sends push message (prepared message) to contact - requires to push message Id also App ID
- transaction - stores order data in Transactional RD and if prepared message-id is included send the order email using a predefined structure
- automation - sends 3rd party event to Engage and if there is automation (Whiteboard) set for this event name its triggered
POST /integration//event?subtype=user Request body can contain any JSON object. Example event that is sent to Kafka:
{
"id":"6d329d9b-201a-4188-a429-7e45d9a674a8",
"timestamp":1555401662153,
"integrationId":"47291122-e5bb-4865-a107-a68ec9957325",
"type":"Import",
"subtype":"user",
"email":"user@mapp.com",
"group":"2324333335",
}
Response: HTTP status code
POST /integration//event?subtype=user FLAG: 'delete'
Request body can contain any JSON object. Example event that is sent to Kafka:
` { "id":"6d329d9b-201a-4188-a429-7e45d9a674a8", "timestamp":1555401662153, "integrationId":"47291122-e5bb-4865-a107-a68ec9957325", "type":"Import", "subtype":"user", "email":"user@mapp.com", "group":"2324333335", "delete":"true"
} `
Response: HTTP status code
POST /integration//event?subtype=user FLAG: 'unsubscribe'
Request body can contain any JSON object. Example event that is sent to Kafka:
{ "id":"6d329d9b-201a-4188-a429-7e45d9a674a8", "timestamp":1555401662153, "integrationId":"47291122-e5bb-4865-a107-a68ec9957325", "type":"Import", "subtype":"user", "email":"user@mapp.com", "group":"2324333335", "unsubscribe":"true" }
Response: HTTP status code
POST /integration//event?subtype=sms Request body can contain any JSON object. MessageId it's an ID of the prepared message. Either 'email', 'recipientMobileNumber' or 'recipientId' can be used as an identifier. Example event that is sent to Kafka:
{ "id":"6d329d9b-201a-4188-a429-7e45d9a674a8", "timestamp":1555401662153, "integrationId":"47291122-e5bb-4865-a107-a68ec9957325", "type":"Import", "subtype":"sms", "recipientMobileNumber":"+48666777888", "messageId":"2324333335", "param1":"param 1 value" }
Response: HTTP status code
Example payload that the API can accept:
{"recipientMobileNumber":"+48666777888","messageId":"2324333335","param1":"param 1 value"}
POST /integration//event?subtype=push Request body can contain any JSON object, 'pushMessageId' is an ID of push message template (not the campaign), 'mobileAppId' refers to the app that should be used, 'email' is used as user identifier. Example event that is sent to Kafka:
{ "id":"6d329d9b-201a-4188-a429-7e45d9a674a8", "timestamp":1555401662153, "integrationId":"47291122-e5bb-4865-a107-a68ec9957325", "type":"Import", "subtype":"push", "email":"andrzej.wuda@xx.xx", "pushMessageId":"1234", "mobileAppId":"5678", "param1":"param 1 value" }
Response: HTTP status code
Example payload that the API can accept:
{"email":"test@test.xx","pushMessageId":"1234","mobileAppId":"5678","param1":"param 1 value"}
POST /integration//event?subtype=email Request body can contain any JSON object. MessageId it's an ID of the prepared message. Example event that is sent to Kafka:
{ "id":"6d329d9b-201a-4188-a429-7e45d9a674a8", "timestamp":1555401662153, "integrationId":"47291122-e5bb-4865-a107-a68ec9957325", "type":"Import", "subtype":"email", "email":"user@mapp.com", "messageId":"2324333335", }
Response: HTTP status code
POST /integration//event?subtype=email Request body can contain any JSON object. MessageId it's an ID of the prepared message. Example event that is sent to Kafka:
`{ "id":"6d329d9b-201a-4188-a429-7e45d9a674a8", "timestamp":1555401662153, "integrationId":"47291122-e5bb-4865-a107-a68ec9957325", "type":"Import", "subtype":"email", "group":"12", "messageId":"2324333335", "params":"valsue1"
} `
POST /integration//event?subtype=transaction Request body can contain any JSON object. MessageId it's an ID of the prepared message. Example event that is sent to Kafka:
{ "id":"6d329d9b-201a-4188-a429-7e45d9a674a8", "timestamp":1555401662153, "integrationId":"47291122-e5bb-4865-a107-a68ec9957325", "type":"Import", "subtype":"transaction", "email":"user@mapp.com", "messageId":"2324333335", "items":[{"sku":"JB-129","name":"Dungen-H","price":"15","qty_ordered":"1"}], "group":"1200073880", "orderId":"1012", "timestamp": "2020-04-28T12:30:08.537Z", "currency":"GBP" }
POST /integration//event?subtype=transaction Request body can contain any JSON object. MessageId it's an ID of the prepared message. Example event that is sent to Kafka:
{ "id":"6d329d9b-201a-4188-a429-7e45d9a674a8", "timestamp":1555401662153, "integrationId":"47291122-e5bb-4865-a107-a68ec9957325", "type":"Import", "subtype":"transaction", "email":"user@mapp.com", "items":[{"sku":"JB-129","name":"Dungen-H","price":"15","qty_ordered":"1"}], "group":"1200073880", "orderId":"1012", "timestamp": "2020-04-28T12:30:08.537Z", "currency":"GBP" }
POST /integration//event?subtype=automation Request body can contain any JSON object. MessageId it's an ID of the prepared message. Example event that is sent to Kafka:
{ "id":"6d329d9b-201a-4188-a429-7e45d9a674a8", "timestamp":1555401662153, "integrationId":"47291122-e5bb-4865-a107-a68ec9957325", "type":"Import", "subtype":"automation", "email":"user@mapp.com", "external_event":"new_account", "value1":"account_URL" }