Add to Cart
add_to_cartAdds one or more menu items to a foodpanda cart, clearing the current cart when switching restaurants, then validates prices and returns updated totals.
Instructions
Add one or more items to the cart. If items are from a different restaurant than the current cart, the cart is cleared first. Sends the full cart to foodpanda for price validation and returns updated totals.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"restaurant_id": "<restaurant_id>",
"items": "<items>"
},
"name": "add_to_cart"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| items | Yes | Items to add to cart | |
| restaurant_id | Yes | The vendor code (e.g. 'p7nl') |