curl --request POST \
--url https://ninjachat.ai/api/v1/batch \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"requests": [
{
"id": "chat-1",
"endpoint": "/api/v1/chat",
"body": {
"model": "gpt-5",
"messages": [
{
"role": "user",
"content": "Summarize this article about AI safety."
}
]
}
},
{
"id": "image-1",
"endpoint": "/api/v1/images",
"body": {
"model": "flux-2-klein",
"prompt": "A futuristic city skyline at sunset, concept art"
}
}
]
}
'