Common Recipes
End-to-end examples for the most common API integrations.
Recipe 1 — Sync inventory from an external system
Step 1 — Submit the inventory
curl -X POST "https://plan.claret.app/{tenant}/api/v1/workflows/sync-inventory" \
-H "Authorization: Bearer {token}" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: 550e8400-e29b-41d4-a716-446655440000" \
-d '{
"mode": "upsert",
"data": [
{
"item_name": "Chardonnay Juice",
"bin_name": "Tank-01",
"lot_name": "LOT-2026-001",
"date_filled": "2026-04-01",
"quantity": 5000,
"uom": "Liter"
}
]
}'Step 2 — Poll for completion
Recipe 2 — Pull sales data
Step 1 — First page
Step 2 — Follow the cursor
Recipe 3 — Generate a supply plan
Option A — Single item-location (synchronous)
Option B — Whole location (batched, asynchronous)
Related documentation
Last updated
Was this helpful?