@trivia-api/models
Version:
Models for The Trivia API.
42 lines (41 loc) • 1.16 kB
JavaScript
"use strict";
/**
* @openapi
* components:
* schemas:
* ImageChoiceQuestion:
* allOf:
* - $ref: '#/components/schemas/BaseQuestion'
* - type: object
* properties:
* question:
* type: object
* properties:
* text:
* type: string
* description: String formulation of the questions
* example: 'Which of these photos shows The Eiffel Tower?'
* required:
* - text
* correctAnswer:
* type: array
* items:
* $ref: '#/components/schemas/ImageOption'
* incorrectAnswers:
* type: array
* items:
* type: array
* items:
* $ref: '#/components/schemas/ImageOption'
* type:
* type: string
* enum:
* - image_choice
* example: 'image_choice'
* required:
* - question
* - correctAnswer
* - incorrectAnswers
* - type
*
*/