on 11-08-2018 3:51 PM
Hello,
we are using the API_MKT_INTERACTION_SRV service to upload interactions into SAP Marketing Cloud.
Sample JSON:
--batch
content-type:multipart/mixed; boundary=changeset_1
--changeset_1
content-type: application/http
content-transfer-encoding: binary
POST Interactions HTTP/1.1
Content-Length: 1035
Accept: application/json
Content-Type: application/json
{
"InteractionContactOrigin":"PORTAL",
"InteractionContactId":"1000058",
"CommunicationMedium":"ONLINE_SHOP",
"InteractionType":"SHOP_ITEM_VIEW",
"InteractionTimeStampUTC":"2018-10-01T08:31:51",
"MarketingArea":"GLOB",
"InteractionAmount": "0",
"InteractionCurrency": "EUR",
"InteractionStatus": "03",
"DeviceType": "DESKTOP",
"InteractionReason": "",
"InteractionProducts":
[
{
"ProductOrigin":"ECOMMERCE",
"Product":"2000001",
"InteractionProductAmount":"0",
"InteractionProductQuantity":"2",
"InteractionProductUnit":"m"
}
]
}
--changeset_1--
--batch--
The creation works fine and the interaction was created without any errors but the unit of quantity (InteractionProductUnit) is only displayed as "***":
I tried different units without success.
Which are the possible units or is there any possibility to customize own units? I didn't find a customizing entry for this in the App "Manage Your Solution".
Thank you in advance and best regards,
Christian
Hi Saurabh,
i found the solution. The field "InteractionProductUnit" is case sensitive.
With the following JSON it worked fine:
--batch
content-type:multipart/mixed; boundary=changeset_1
--changeset_1
content-type: application/http
content-transfer-encoding: binary
POST Interactions HTTP/1.1
Content-Length: 1035
Accept: application/json
Content-Type: application/json
{
"InteractionContactOrigin":"PORTAL",
"InteractionContactId":"1000058",
"CommunicationMedium":"ONLINE_SHOP",
"InteractionType":"SHOP_ITEM_VIEW",
"InteractionTimeStampUTC":"2018-10-01T08:31:51",
"MarketingArea":"GLOB",
"InteractionAmount": "0",
"InteractionCurrency": "EUR",
"InteractionStatus": "03",
"DeviceType": "DESKTOP",
"InteractionReason": "",
"InteractionProducts":
[
{
"ProductOrigin":"ECOMMERCE",
"Product":"2000001",
"InteractionProductAmount":"0",
"InteractionProductQuantity":"2",
"InteractionProductUnit":"PC"
}
]
}
--changeset_1--
--batch--
Best regards,
Christian
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Christian,
Make sure you are passing a valid code for unit of measurement fields "InteractionProductUnit". Unfortunately I couldn't find any specific service or place in cloud which can give a list of allowed code. Since we also have a onprem edition so i just pass the standard ISO codes for Unit of measurement and it always works. Also you can read the product data from API and see what is the UOM maintained against same.
Just a workaround, If you already have product loaded in marketing cloud try to skip InteractionProductUnit in interaction payload. in our experience in such case it picks the value from product root data.
Thanks
Saurabh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
5 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.