API Reference
Integrate the AI recommendation engine into your custom checkout flows.
Get Recommendations
POST /api/recommend
Send the current cart contents to receive two AI-powered upsell recommendations and a dynamic cashier phrase.
Headers
Authorization: Bearer <YOUR_API_KEY> Content-Type: application/json
Request Body
{
"merchant_id": "your-uuid-here",
"current_cart": [
{
"id": "prod_123",
"name": "Cheeseburger",
"price": 12.99,
"quantity": 1
}
]
}Response
{
"recommendation_1": {
"id": "prod_456",
"name": "Large Fries"
},
"recommendation_2": {
"id": "prod_789",
"name": "Vanilla Shake"
},
"cashier_phrase": "Would you like to add some fries or a shake to go with that burger?",
"source": "ai"
}