Batch requests (v2)
documentedBatch multiple v2 entity requests in a single call.
POST /api/v2/batchTrack v2 APIno implementation yet0 runsNo implementation yet. Run it to have the agent write one, or open a pull request with your own.
Seed example (keychains curl)
npx -y keychains@latest curl "https://cdp.customer.io/v1/batch" \
-X POST \
-u "{{CUSTOMER_API_KEY}}:" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-d '{"batch": [ {"type": "identify", "userId": "{{$user_id}}", "traits": {"name": "{{$name}}", "email": "{{$email}}"} }, {"type": "track", "userId": "{{$user_id}}", "event": "Order Completed", "properties": {"order_id": "{{$order_id}}", "value": {{$value}}}}], "context": {"ip": "{{$ip}}", "locale": "{{$locale}}"}, "integrations": {"All": true}}'
# Source: https://docs.customer.io/integrations/api/cdp/ (Pipelines API batch)