Vidbyte

API documentation

Batch Create Quizzes

Generate multiple quizzes in one request envelope. This route is designed for scenarios where you need several quiz variants or per-learner quiz generation in one call.

POST
/api/v1/quizzes/batch_create

Example request

curl https://api.vidbyte.ai/api/v1/quizzes/batch_create \
  -H "Authorization: Bearer vb_live_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "items": [
      { "prompt": "HTTP caching", "quiz_type": "multiple_choice" },
      { "prompt": "HTTP caching", "quiz_type": "open_ended" }
    ]
  }'

Example response

{
  "success": true,
  "data": [
    {
      "index": 0,
      "success": true,
      "id": "quiz_9Yv7k12Lm",
      "quiz_type": "multiple_choice",
      "data": { "id": "quiz_9Yv7k12Lm", "item_type": "quiz", "title": "HTTP caching mastery check" }
    },
    {
      "index": 1,
      "success": true,
      "id": "quiz_f1Pq23ZaR",
      "quiz_type": "open_ended",
      "data": { "id": "quiz_f1Pq23ZaR", "item_type": "quiz", "title": "HTTP caching reflection prompts" }
    }
  ],
  "token_stats": { "input_tokens": 1311, "output_tokens": 1124, "total_tokens": 2435 },
  "pricing": { "total_cost": 0.0389 }
}

Parameter information

These are the public parameters for /api/v1/quizzes/batch_create. Path parameters and request-body fields are shown together so the page stays focused on the live request contract you actually send.

itemsobject[]Required

Array of quiz-create payloads. Each item should look like a normal quiz create request, and the current backend supports between 1 and 20 items per batch.