Examples
Last update: 6 hours ago by Irais Aguirre
curl examples for sending C-Commerce product messages (single product and multiple products).
Single product
HTTP request: single product
curl -X POST 'https://{{url}}/whatsapp-bsp-api-endpoint-ws/services/v1/messaging' \-H 'Authorization: Bearer {{wa-msg-api-token}}' \-H 'Content-Type: application/json' \-d '{"from": "5215500000001","to": "5215500000002","type": "interactive","singleProductMessage": {"type": "product","body": "Speak English in 8 months","footer": "The English course includes one hour a day","action": {"catalogId": "1374748992926971","productRetailerId": "ING_0001"}}}'
Body: single product
{"from": "5215500000001","to": "5215500000002","type": "interactive","singleProductMessage": {"type": "product","body": "Speak English in 8 months","footer": "The English course includes one hour a day","action": {"catalogId": "1374748992926971","productRetailerId": "ING_0001"}}}
Multiple products
HTTP request: multiple products
curl -X POST 'https://{{url}}/whatsapp-bsp-api-endpoint-ws/services/v1/messaging' \-H 'Authorization: Bearer {{wa-msg-api-token}}' \-H 'Content-Type: application/json' \-d '{"from": "5215500000001","to": "5215500000002","type": "interactive","multiProductMessage": {"type": "product_list","header": {"type": "text","text": "English Classes"},"body": "Learn English","footer": "The best English school","action": {"catalogId": "1374748992926971","sections": [{"title": "My English Section","productItems": [{"productRetailerId": "ING_0001"},{"productRetailerId": "LLPI12102021"}]}]}}}'
Body: multiple products
{"from": "5215500000001","to": "5215500000002","type": "interactive","multiProductMessage": {"type": "product_list","header": {"type": "text","text": "English Classes"},"body": "Learn English","footer": "The best English school","action": {"catalogId": "1374748992926971","sections": [{"title": "My English Section","productItems": [{"productRetailerId": "ING_0001"},{"productRetailerId": "LLPI12102021"}]}]}}}
