Skip to content

. Add POST /api/v1/quizzes/generate-batch endpoint #316

Description

@DeFiVC

What: Add an endpoint that generates quizzes for multiple modules in a single request.

Why: Users enrolled in a course with many modules must generate quizzes one at a time. Batch generation reduces round trips and improves the onboarding experience for new course content.

Scope: Add route accepting { courseId: string, moduleIds: string[], difficulty?: string, numQuestions?: number }. Generate quizzes for each module sequentially (to avoid AI service overload). Return array of generated quizzes.

Acceptance criteria:

  • Accepts array of module IDs
  • Each quiz is generated independently
  • Partial failures don't block successful generations
  • Rate limited to prevent AI service abuse

Technical context: src/modules/quizzes/quiz.service.ts:28-147 — generateQuiz. src/middleware/rate-limit.ts — rate limit patterns.


Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Stellar WaveIssues in the Stellar wave program

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions