2279 lines
55 KiB
YAML
2279 lines
55 KiB
YAML
|
|
openapi: 3.1.0
|
||
|
|
info:
|
||
|
|
title: TryMe Gaming App API
|
||
|
|
description: Student quiz creation, sharing, voting, favourites, leaderboards, Auth0
|
||
|
|
federated login, API keys, and moderation.
|
||
|
|
version: '0.1'
|
||
|
|
paths:
|
||
|
|
/api/v1/auth/config:
|
||
|
|
get:
|
||
|
|
tags:
|
||
|
|
- Authentication
|
||
|
|
summary: Get Auth Config
|
||
|
|
operationId: get_auth_config_api_v1_auth_config_get
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/AuthConfigOut'
|
||
|
|
/api/v1/auth/login:
|
||
|
|
get:
|
||
|
|
tags:
|
||
|
|
- Authentication
|
||
|
|
summary: Auth0 Login
|
||
|
|
operationId: auth0_login_api_v1_auth_login_get
|
||
|
|
parameters:
|
||
|
|
- name: return_to
|
||
|
|
in: query
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
type: string
|
||
|
|
default: /
|
||
|
|
title: Return To
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema: {}
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/api/v1/auth/callback:
|
||
|
|
get:
|
||
|
|
tags:
|
||
|
|
- Authentication
|
||
|
|
summary: Auth0 Callback
|
||
|
|
operationId: auth0_callback_api_v1_auth_callback_get
|
||
|
|
parameters:
|
||
|
|
- name: code
|
||
|
|
in: query
|
||
|
|
required: true
|
||
|
|
schema:
|
||
|
|
type: string
|
||
|
|
title: Code
|
||
|
|
- name: state
|
||
|
|
in: query
|
||
|
|
required: true
|
||
|
|
schema:
|
||
|
|
type: string
|
||
|
|
title: State
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema: {}
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/api/v1/auth/dev-login:
|
||
|
|
post:
|
||
|
|
tags:
|
||
|
|
- Authentication
|
||
|
|
summary: Dev Login
|
||
|
|
operationId: dev_login_api_v1_auth_dev_login_post
|
||
|
|
requestBody:
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/DevLoginIn'
|
||
|
|
required: true
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/TokenSessionOut'
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/api/v1/auth/logout:
|
||
|
|
post:
|
||
|
|
tags:
|
||
|
|
- Authentication
|
||
|
|
summary: Logout
|
||
|
|
operationId: logout_api_v1_auth_logout_post
|
||
|
|
responses:
|
||
|
|
'204':
|
||
|
|
description: Successful Response
|
||
|
|
/api/v1/users/me:
|
||
|
|
get:
|
||
|
|
tags:
|
||
|
|
- Users & API Keys
|
||
|
|
summary: Get Me
|
||
|
|
operationId: get_me_api_v1_users_me_get
|
||
|
|
parameters:
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/UserOut'
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
patch:
|
||
|
|
tags:
|
||
|
|
- Users & API Keys
|
||
|
|
summary: Update Me
|
||
|
|
operationId: update_me_api_v1_users_me_patch
|
||
|
|
parameters:
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
requestBody:
|
||
|
|
required: true
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/UserUpdateIn'
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/UserOut'
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/api/v1/users/me/scores:
|
||
|
|
get:
|
||
|
|
tags:
|
||
|
|
- Users & API Keys
|
||
|
|
summary: Get My Scores
|
||
|
|
operationId: get_my_scores_api_v1_users_me_scores_get
|
||
|
|
parameters:
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
type: array
|
||
|
|
items:
|
||
|
|
$ref: '#/components/schemas/UserScoreRowOut'
|
||
|
|
title: Response Get My Scores Api V1 Users Me Scores Get
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/api/v1/users/me/api-keys:
|
||
|
|
get:
|
||
|
|
tags:
|
||
|
|
- Users & API Keys
|
||
|
|
summary: List Api Keys
|
||
|
|
operationId: list_api_keys_api_v1_users_me_api_keys_get
|
||
|
|
parameters:
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
type: array
|
||
|
|
items:
|
||
|
|
$ref: '#/components/schemas/ApiKeyOut'
|
||
|
|
title: Response List Api Keys Api V1 Users Me Api Keys Get
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
post:
|
||
|
|
tags:
|
||
|
|
- Users & API Keys
|
||
|
|
summary: Create Api Key
|
||
|
|
operationId: create_api_key_api_v1_users_me_api_keys_post
|
||
|
|
parameters:
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
requestBody:
|
||
|
|
required: true
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/ApiKeyCreateIn'
|
||
|
|
responses:
|
||
|
|
'201':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/ApiKeyCreatedOut'
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/api/v1/users/me/api-keys/{key_id}/expire:
|
||
|
|
post:
|
||
|
|
tags:
|
||
|
|
- Users & API Keys
|
||
|
|
summary: Expire Api Key
|
||
|
|
operationId: expire_api_key_api_v1_users_me_api_keys__key_id__expire_post
|
||
|
|
parameters:
|
||
|
|
- name: key_id
|
||
|
|
in: path
|
||
|
|
required: true
|
||
|
|
schema:
|
||
|
|
type: integer
|
||
|
|
title: Key Id
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/ApiKeyOut'
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/api/v1/quizzes:
|
||
|
|
get:
|
||
|
|
tags:
|
||
|
|
- Quizzes
|
||
|
|
summary: List Quizzes
|
||
|
|
operationId: list_quizzes_api_v1_quizzes_get
|
||
|
|
parameters:
|
||
|
|
- name: q
|
||
|
|
in: query
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
maxLength: 120
|
||
|
|
- type: 'null'
|
||
|
|
title: Q
|
||
|
|
- name: mode
|
||
|
|
in: query
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Mode
|
||
|
|
- name: mine_only
|
||
|
|
in: query
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
type: boolean
|
||
|
|
default: false
|
||
|
|
title: Mine Only
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
type: array
|
||
|
|
items:
|
||
|
|
$ref: '#/components/schemas/QuizSummaryOut'
|
||
|
|
title: Response List Quizzes Api V1 Quizzes Get
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
post:
|
||
|
|
tags:
|
||
|
|
- Quizzes
|
||
|
|
summary: Create Quiz
|
||
|
|
operationId: create_quiz_api_v1_quizzes_post
|
||
|
|
parameters:
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
requestBody:
|
||
|
|
required: true
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/QuizCreateIn'
|
||
|
|
responses:
|
||
|
|
'201':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/QuizDetailOut'
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/api/v1/quizzes/{slug_or_id}:
|
||
|
|
get:
|
||
|
|
tags:
|
||
|
|
- Quizzes
|
||
|
|
summary: Get Quiz
|
||
|
|
operationId: get_quiz_api_v1_quizzes__slug_or_id__get
|
||
|
|
parameters:
|
||
|
|
- name: slug_or_id
|
||
|
|
in: path
|
||
|
|
required: true
|
||
|
|
schema:
|
||
|
|
type: string
|
||
|
|
title: Slug Or Id
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/QuizDetailOut'
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/api/v1/quizzes/{quiz_id}:
|
||
|
|
put:
|
||
|
|
tags:
|
||
|
|
- Quizzes
|
||
|
|
summary: Update Quiz
|
||
|
|
operationId: update_quiz_api_v1_quizzes__quiz_id__put
|
||
|
|
parameters:
|
||
|
|
- name: quiz_id
|
||
|
|
in: path
|
||
|
|
required: true
|
||
|
|
schema:
|
||
|
|
type: integer
|
||
|
|
title: Quiz Id
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
requestBody:
|
||
|
|
required: true
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/QuizUpdateIn'
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/QuizDetailOut'
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
delete:
|
||
|
|
tags:
|
||
|
|
- Quizzes
|
||
|
|
summary: Delete Quiz
|
||
|
|
operationId: delete_quiz_api_v1_quizzes__quiz_id__delete
|
||
|
|
parameters:
|
||
|
|
- name: quiz_id
|
||
|
|
in: path
|
||
|
|
required: true
|
||
|
|
schema:
|
||
|
|
type: integer
|
||
|
|
title: Quiz Id
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
responses:
|
||
|
|
'204':
|
||
|
|
description: Successful Response
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/api/v1/quizzes/{quiz_id}/submit:
|
||
|
|
post:
|
||
|
|
tags:
|
||
|
|
- Quizzes
|
||
|
|
summary: Submit Quiz
|
||
|
|
operationId: submit_quiz_api_v1_quizzes__quiz_id__submit_post
|
||
|
|
parameters:
|
||
|
|
- name: quiz_id
|
||
|
|
in: path
|
||
|
|
required: true
|
||
|
|
schema:
|
||
|
|
type: integer
|
||
|
|
title: Quiz Id
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
requestBody:
|
||
|
|
required: true
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/QuizSubmitIn'
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/QuizSubmitOut'
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/api/v1/quizzes/{quiz_id}/vote:
|
||
|
|
post:
|
||
|
|
tags:
|
||
|
|
- Quizzes
|
||
|
|
summary: Vote Quiz
|
||
|
|
operationId: vote_quiz_api_v1_quizzes__quiz_id__vote_post
|
||
|
|
parameters:
|
||
|
|
- name: quiz_id
|
||
|
|
in: path
|
||
|
|
required: true
|
||
|
|
schema:
|
||
|
|
type: integer
|
||
|
|
title: Quiz Id
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
requestBody:
|
||
|
|
required: true
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/VoteIn'
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/VoteOut'
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/api/v1/favourites:
|
||
|
|
get:
|
||
|
|
tags:
|
||
|
|
- Favourites
|
||
|
|
summary: List Favourites
|
||
|
|
operationId: list_favourites_api_v1_favourites_get
|
||
|
|
parameters:
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
type: array
|
||
|
|
items:
|
||
|
|
$ref: '#/components/schemas/FavouriteItemOut'
|
||
|
|
title: Response List Favourites Api V1 Favourites Get
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
post:
|
||
|
|
tags:
|
||
|
|
- Favourites
|
||
|
|
summary: Add Favourite
|
||
|
|
operationId: add_favourite_api_v1_favourites_post
|
||
|
|
parameters:
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
requestBody:
|
||
|
|
required: true
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/FavouriteAddIn'
|
||
|
|
responses:
|
||
|
|
'201':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
type: array
|
||
|
|
items:
|
||
|
|
$ref: '#/components/schemas/FavouriteItemOut'
|
||
|
|
title: Response Add Favourite Api V1 Favourites Post
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/api/v1/favourites/reorder:
|
||
|
|
put:
|
||
|
|
tags:
|
||
|
|
- Favourites
|
||
|
|
summary: Reorder Favourites
|
||
|
|
operationId: reorder_favourites_api_v1_favourites_reorder_put
|
||
|
|
parameters:
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
requestBody:
|
||
|
|
required: true
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/FavouriteReorderIn'
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
type: array
|
||
|
|
items:
|
||
|
|
$ref: '#/components/schemas/FavouriteItemOut'
|
||
|
|
title: Response Reorder Favourites Api V1 Favourites Reorder Put
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/api/v1/favourites/{quiz_id}:
|
||
|
|
delete:
|
||
|
|
tags:
|
||
|
|
- Favourites
|
||
|
|
summary: Remove Favourite
|
||
|
|
operationId: remove_favourite_api_v1_favourites__quiz_id__delete
|
||
|
|
parameters:
|
||
|
|
- name: quiz_id
|
||
|
|
in: path
|
||
|
|
required: true
|
||
|
|
schema:
|
||
|
|
type: integer
|
||
|
|
title: Quiz Id
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
type: array
|
||
|
|
items:
|
||
|
|
$ref: '#/components/schemas/FavouriteItemOut'
|
||
|
|
title: Response Remove Favourite Api V1 Favourites Quiz Id Delete
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/api/v1/admin/claim:
|
||
|
|
post:
|
||
|
|
tags:
|
||
|
|
- Moderation
|
||
|
|
summary: Claim Initial Moderator
|
||
|
|
operationId: claim_initial_moderator_api_v1_admin_claim_post
|
||
|
|
parameters:
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/UserOut'
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/api/v1/admin/users:
|
||
|
|
get:
|
||
|
|
tags:
|
||
|
|
- Moderation
|
||
|
|
summary: List Users For Moderation
|
||
|
|
operationId: list_users_for_moderation_api_v1_admin_users_get
|
||
|
|
parameters:
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
type: array
|
||
|
|
items:
|
||
|
|
$ref: '#/components/schemas/UserOut'
|
||
|
|
title: Response List Users For Moderation Api V1 Admin Users Get
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/api/v1/admin/users/{user_id}/ban:
|
||
|
|
post:
|
||
|
|
tags:
|
||
|
|
- Moderation
|
||
|
|
summary: Ban User
|
||
|
|
operationId: ban_user_api_v1_admin_users__user_id__ban_post
|
||
|
|
parameters:
|
||
|
|
- name: user_id
|
||
|
|
in: path
|
||
|
|
required: true
|
||
|
|
schema:
|
||
|
|
type: integer
|
||
|
|
title: User Id
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
requestBody:
|
||
|
|
required: true
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/BanUserIn'
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/UserOut'
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/api/v1/admin/users/{user_id}/unban:
|
||
|
|
post:
|
||
|
|
tags:
|
||
|
|
- Moderation
|
||
|
|
summary: Unban User
|
||
|
|
operationId: unban_user_api_v1_admin_users__user_id__unban_post
|
||
|
|
parameters:
|
||
|
|
- name: user_id
|
||
|
|
in: path
|
||
|
|
required: true
|
||
|
|
schema:
|
||
|
|
type: integer
|
||
|
|
title: User Id
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/UserOut'
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/api/v1/admin/quizzes:
|
||
|
|
get:
|
||
|
|
tags:
|
||
|
|
- Moderation
|
||
|
|
summary: List Quizzes For Moderation
|
||
|
|
operationId: list_quizzes_for_moderation_api_v1_admin_quizzes_get
|
||
|
|
parameters:
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
type: array
|
||
|
|
items:
|
||
|
|
$ref: '#/components/schemas/QuizSummaryOut'
|
||
|
|
title: Response List Quizzes For Moderation Api V1 Admin Quizzes Get
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/api/v1/admin/quizzes/{quiz_id}:
|
||
|
|
delete:
|
||
|
|
tags:
|
||
|
|
- Moderation
|
||
|
|
summary: Moderator Remove Quiz
|
||
|
|
operationId: moderator_remove_quiz_api_v1_admin_quizzes__quiz_id__delete
|
||
|
|
parameters:
|
||
|
|
- name: quiz_id
|
||
|
|
in: path
|
||
|
|
required: true
|
||
|
|
schema:
|
||
|
|
type: integer
|
||
|
|
title: Quiz Id
|
||
|
|
- name: authorization
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Authorization
|
||
|
|
- name: X-API-Key
|
||
|
|
in: header
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: X-Api-Key
|
||
|
|
- name: tryme_session
|
||
|
|
in: cookie
|
||
|
|
required: false
|
||
|
|
schema:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Tryme Session
|
||
|
|
responses:
|
||
|
|
'204':
|
||
|
|
description: Successful Response
|
||
|
|
'422':
|
||
|
|
description: Validation Error
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
$ref: '#/components/schemas/HTTPValidationError'
|
||
|
|
/health:
|
||
|
|
get:
|
||
|
|
tags:
|
||
|
|
- System
|
||
|
|
summary: Healthcheck
|
||
|
|
operationId: healthcheck_health_get
|
||
|
|
responses:
|
||
|
|
'200':
|
||
|
|
description: Successful Response
|
||
|
|
content:
|
||
|
|
application/json:
|
||
|
|
schema:
|
||
|
|
additionalProperties:
|
||
|
|
type: string
|
||
|
|
type: object
|
||
|
|
title: Response Healthcheck Health Get
|
||
|
|
components:
|
||
|
|
schemas:
|
||
|
|
ApiKeyCreateIn:
|
||
|
|
properties:
|
||
|
|
name:
|
||
|
|
type: string
|
||
|
|
maxLength: 80
|
||
|
|
minLength: 1
|
||
|
|
title: Name
|
||
|
|
expires_in_days:
|
||
|
|
anyOf:
|
||
|
|
- type: integer
|
||
|
|
maximum: 3650.0
|
||
|
|
minimum: 1.0
|
||
|
|
- type: 'null'
|
||
|
|
title: Expires In Days
|
||
|
|
default: 90
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- name
|
||
|
|
title: ApiKeyCreateIn
|
||
|
|
ApiKeyCreatedOut:
|
||
|
|
properties:
|
||
|
|
id:
|
||
|
|
type: integer
|
||
|
|
title: Id
|
||
|
|
name:
|
||
|
|
type: string
|
||
|
|
title: Name
|
||
|
|
key_prefix:
|
||
|
|
type: string
|
||
|
|
title: Key Prefix
|
||
|
|
expires_at:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
format: date-time
|
||
|
|
- type: 'null'
|
||
|
|
title: Expires At
|
||
|
|
revoked_at:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
format: date-time
|
||
|
|
- type: 'null'
|
||
|
|
title: Revoked At
|
||
|
|
last_used_at:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
format: date-time
|
||
|
|
- type: 'null'
|
||
|
|
title: Last Used At
|
||
|
|
created_at:
|
||
|
|
type: string
|
||
|
|
format: date-time
|
||
|
|
title: Created At
|
||
|
|
is_active:
|
||
|
|
type: boolean
|
||
|
|
title: Is Active
|
||
|
|
raw_key:
|
||
|
|
type: string
|
||
|
|
title: Raw Key
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- id
|
||
|
|
- name
|
||
|
|
- key_prefix
|
||
|
|
- expires_at
|
||
|
|
- revoked_at
|
||
|
|
- last_used_at
|
||
|
|
- created_at
|
||
|
|
- is_active
|
||
|
|
- raw_key
|
||
|
|
title: ApiKeyCreatedOut
|
||
|
|
ApiKeyOut:
|
||
|
|
properties:
|
||
|
|
id:
|
||
|
|
type: integer
|
||
|
|
title: Id
|
||
|
|
name:
|
||
|
|
type: string
|
||
|
|
title: Name
|
||
|
|
key_prefix:
|
||
|
|
type: string
|
||
|
|
title: Key Prefix
|
||
|
|
expires_at:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
format: date-time
|
||
|
|
- type: 'null'
|
||
|
|
title: Expires At
|
||
|
|
revoked_at:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
format: date-time
|
||
|
|
- type: 'null'
|
||
|
|
title: Revoked At
|
||
|
|
last_used_at:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
format: date-time
|
||
|
|
- type: 'null'
|
||
|
|
title: Last Used At
|
||
|
|
created_at:
|
||
|
|
type: string
|
||
|
|
format: date-time
|
||
|
|
title: Created At
|
||
|
|
is_active:
|
||
|
|
type: boolean
|
||
|
|
title: Is Active
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- id
|
||
|
|
- name
|
||
|
|
- key_prefix
|
||
|
|
- expires_at
|
||
|
|
- revoked_at
|
||
|
|
- last_used_at
|
||
|
|
- created_at
|
||
|
|
- is_active
|
||
|
|
title: ApiKeyOut
|
||
|
|
AuthConfigOut:
|
||
|
|
properties:
|
||
|
|
auth0_enabled:
|
||
|
|
type: boolean
|
||
|
|
title: Auth0 Enabled
|
||
|
|
auth0_domain:
|
||
|
|
type: string
|
||
|
|
title: Auth0 Domain
|
||
|
|
auth0_client_id:
|
||
|
|
type: string
|
||
|
|
title: Auth0 Client Id
|
||
|
|
auth0_audience:
|
||
|
|
type: string
|
||
|
|
title: Auth0 Audience
|
||
|
|
dev_auth_enabled:
|
||
|
|
type: boolean
|
||
|
|
title: Dev Auth Enabled
|
||
|
|
admin_unclaimed:
|
||
|
|
type: boolean
|
||
|
|
title: Admin Unclaimed
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- auth0_enabled
|
||
|
|
- auth0_domain
|
||
|
|
- auth0_client_id
|
||
|
|
- auth0_audience
|
||
|
|
- dev_auth_enabled
|
||
|
|
- admin_unclaimed
|
||
|
|
title: AuthConfigOut
|
||
|
|
BanUserIn:
|
||
|
|
properties:
|
||
|
|
reason:
|
||
|
|
type: string
|
||
|
|
maxLength: 255
|
||
|
|
title: Reason
|
||
|
|
default: Community guidelines violation
|
||
|
|
type: object
|
||
|
|
title: BanUserIn
|
||
|
|
DevLoginIn:
|
||
|
|
properties:
|
||
|
|
nickname:
|
||
|
|
type: string
|
||
|
|
maxLength: 48
|
||
|
|
minLength: 2
|
||
|
|
title: Nickname
|
||
|
|
email:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
maxLength: 255
|
||
|
|
- type: 'null'
|
||
|
|
title: Email
|
||
|
|
as_moderator:
|
||
|
|
type: boolean
|
||
|
|
title: As Moderator
|
||
|
|
default: false
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- nickname
|
||
|
|
title: DevLoginIn
|
||
|
|
FavouriteAddIn:
|
||
|
|
properties:
|
||
|
|
quiz_id:
|
||
|
|
type: integer
|
||
|
|
title: Quiz Id
|
||
|
|
position:
|
||
|
|
anyOf:
|
||
|
|
- type: integer
|
||
|
|
minimum: 0.0
|
||
|
|
- type: 'null'
|
||
|
|
title: Position
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- quiz_id
|
||
|
|
title: FavouriteAddIn
|
||
|
|
FavouriteItemOut:
|
||
|
|
properties:
|
||
|
|
favourite_id:
|
||
|
|
type: integer
|
||
|
|
title: Favourite Id
|
||
|
|
position:
|
||
|
|
type: integer
|
||
|
|
title: Position
|
||
|
|
quiz:
|
||
|
|
$ref: '#/components/schemas/QuizSummaryOut'
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- favourite_id
|
||
|
|
- position
|
||
|
|
- quiz
|
||
|
|
title: FavouriteItemOut
|
||
|
|
FavouriteReorderIn:
|
||
|
|
properties:
|
||
|
|
quiz_ids:
|
||
|
|
items:
|
||
|
|
type: integer
|
||
|
|
type: array
|
||
|
|
title: Quiz Ids
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- quiz_ids
|
||
|
|
title: FavouriteReorderIn
|
||
|
|
GlobalBestScoreOut:
|
||
|
|
properties:
|
||
|
|
score_count:
|
||
|
|
type: integer
|
||
|
|
title: Score Count
|
||
|
|
total_questions:
|
||
|
|
type: integer
|
||
|
|
title: Total Questions
|
||
|
|
score_percent:
|
||
|
|
type: number
|
||
|
|
title: Score Percent
|
||
|
|
holder_nickname:
|
||
|
|
type: string
|
||
|
|
title: Holder Nickname
|
||
|
|
holder_avatar_animal:
|
||
|
|
type: string
|
||
|
|
title: Holder Avatar Animal
|
||
|
|
holder_avatar_color:
|
||
|
|
type: string
|
||
|
|
title: Holder Avatar Color
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- score_count
|
||
|
|
- total_questions
|
||
|
|
- score_percent
|
||
|
|
- holder_nickname
|
||
|
|
- holder_avatar_animal
|
||
|
|
- holder_avatar_color
|
||
|
|
title: GlobalBestScoreOut
|
||
|
|
HTTPValidationError:
|
||
|
|
properties:
|
||
|
|
detail:
|
||
|
|
items:
|
||
|
|
$ref: '#/components/schemas/ValidationError'
|
||
|
|
type: array
|
||
|
|
title: Detail
|
||
|
|
type: object
|
||
|
|
title: HTTPValidationError
|
||
|
|
QuestionAuthorOut:
|
||
|
|
properties:
|
||
|
|
id:
|
||
|
|
type: integer
|
||
|
|
title: Id
|
||
|
|
position:
|
||
|
|
type: integer
|
||
|
|
title: Position
|
||
|
|
question_type:
|
||
|
|
type: string
|
||
|
|
enum:
|
||
|
|
- multiple_choice
|
||
|
|
- write_in
|
||
|
|
title: Question Type
|
||
|
|
prompt:
|
||
|
|
type: string
|
||
|
|
title: Prompt
|
||
|
|
options:
|
||
|
|
items:
|
||
|
|
$ref: '#/components/schemas/QuestionOptionSchema'
|
||
|
|
type: array
|
||
|
|
title: Options
|
||
|
|
correct_answer:
|
||
|
|
type: string
|
||
|
|
title: Correct Answer
|
||
|
|
accepted_answers:
|
||
|
|
items:
|
||
|
|
type: string
|
||
|
|
type: array
|
||
|
|
title: Accepted Answers
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- id
|
||
|
|
- position
|
||
|
|
- question_type
|
||
|
|
- prompt
|
||
|
|
- options
|
||
|
|
- correct_answer
|
||
|
|
- accepted_answers
|
||
|
|
title: QuestionAuthorOut
|
||
|
|
QuestionIn:
|
||
|
|
properties:
|
||
|
|
question_type:
|
||
|
|
type: string
|
||
|
|
enum:
|
||
|
|
- multiple_choice
|
||
|
|
- write_in
|
||
|
|
title: Question Type
|
||
|
|
prompt:
|
||
|
|
type: string
|
||
|
|
maxLength: 1000
|
||
|
|
minLength: 1
|
||
|
|
title: Prompt
|
||
|
|
options:
|
||
|
|
items:
|
||
|
|
$ref: '#/components/schemas/QuestionOptionSchema'
|
||
|
|
type: array
|
||
|
|
title: Options
|
||
|
|
correct_answer:
|
||
|
|
type: string
|
||
|
|
maxLength: 500
|
||
|
|
minLength: 1
|
||
|
|
title: Correct Answer
|
||
|
|
accepted_answers:
|
||
|
|
items:
|
||
|
|
type: string
|
||
|
|
type: array
|
||
|
|
title: Accepted Answers
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- question_type
|
||
|
|
- prompt
|
||
|
|
- correct_answer
|
||
|
|
title: QuestionIn
|
||
|
|
QuestionOptionSchema:
|
||
|
|
properties:
|
||
|
|
id:
|
||
|
|
type: string
|
||
|
|
maxLength: 32
|
||
|
|
minLength: 1
|
||
|
|
title: Id
|
||
|
|
text:
|
||
|
|
type: string
|
||
|
|
maxLength: 300
|
||
|
|
minLength: 1
|
||
|
|
title: Text
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- id
|
||
|
|
- text
|
||
|
|
title: QuestionOptionSchema
|
||
|
|
QuestionPlayOut:
|
||
|
|
properties:
|
||
|
|
id:
|
||
|
|
type: integer
|
||
|
|
title: Id
|
||
|
|
position:
|
||
|
|
type: integer
|
||
|
|
title: Position
|
||
|
|
question_type:
|
||
|
|
type: string
|
||
|
|
enum:
|
||
|
|
- multiple_choice
|
||
|
|
- write_in
|
||
|
|
title: Question Type
|
||
|
|
prompt:
|
||
|
|
type: string
|
||
|
|
title: Prompt
|
||
|
|
options:
|
||
|
|
items:
|
||
|
|
$ref: '#/components/schemas/QuestionOptionSchema'
|
||
|
|
type: array
|
||
|
|
title: Options
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- id
|
||
|
|
- position
|
||
|
|
- question_type
|
||
|
|
- prompt
|
||
|
|
- options
|
||
|
|
title: QuestionPlayOut
|
||
|
|
QuestionResultOut:
|
||
|
|
properties:
|
||
|
|
question_id:
|
||
|
|
type: integer
|
||
|
|
title: Question Id
|
||
|
|
prompt:
|
||
|
|
type: string
|
||
|
|
title: Prompt
|
||
|
|
question_type:
|
||
|
|
type: string
|
||
|
|
enum:
|
||
|
|
- multiple_choice
|
||
|
|
- write_in
|
||
|
|
title: Question Type
|
||
|
|
submitted_answer:
|
||
|
|
type: string
|
||
|
|
title: Submitted Answer
|
||
|
|
is_correct:
|
||
|
|
type: boolean
|
||
|
|
title: Is Correct
|
||
|
|
correct_display:
|
||
|
|
type: string
|
||
|
|
title: Correct Display
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- question_id
|
||
|
|
- prompt
|
||
|
|
- question_type
|
||
|
|
- submitted_answer
|
||
|
|
- is_correct
|
||
|
|
- correct_display
|
||
|
|
title: QuestionResultOut
|
||
|
|
QuizCreateIn:
|
||
|
|
properties:
|
||
|
|
title:
|
||
|
|
type: string
|
||
|
|
maxLength: 140
|
||
|
|
minLength: 1
|
||
|
|
title: Title
|
||
|
|
description:
|
||
|
|
type: string
|
||
|
|
maxLength: 1000
|
||
|
|
title: Description
|
||
|
|
default: ''
|
||
|
|
is_public:
|
||
|
|
type: boolean
|
||
|
|
title: Is Public
|
||
|
|
default: true
|
||
|
|
questions:
|
||
|
|
items:
|
||
|
|
$ref: '#/components/schemas/QuestionIn'
|
||
|
|
type: array
|
||
|
|
maxItems: 40
|
||
|
|
title: Questions
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- title
|
||
|
|
title: QuizCreateIn
|
||
|
|
QuizDetailOut:
|
||
|
|
properties:
|
||
|
|
id:
|
||
|
|
type: integer
|
||
|
|
title: Id
|
||
|
|
share_slug:
|
||
|
|
type: string
|
||
|
|
title: Share Slug
|
||
|
|
title:
|
||
|
|
type: string
|
||
|
|
title: Title
|
||
|
|
description:
|
||
|
|
type: string
|
||
|
|
title: Description
|
||
|
|
is_public:
|
||
|
|
type: boolean
|
||
|
|
title: Is Public
|
||
|
|
author_id:
|
||
|
|
type: integer
|
||
|
|
title: Author Id
|
||
|
|
author_nickname:
|
||
|
|
type: string
|
||
|
|
title: Author Nickname
|
||
|
|
author_avatar_animal:
|
||
|
|
type: string
|
||
|
|
title: Author Avatar Animal
|
||
|
|
author_avatar_color:
|
||
|
|
type: string
|
||
|
|
title: Author Avatar Color
|
||
|
|
question_count:
|
||
|
|
type: integer
|
||
|
|
title: Question Count
|
||
|
|
quiz_mode:
|
||
|
|
type: string
|
||
|
|
enum:
|
||
|
|
- multiple_choice
|
||
|
|
- write_in
|
||
|
|
- mixed
|
||
|
|
- empty
|
||
|
|
title: Quiz Mode
|
||
|
|
upvotes:
|
||
|
|
type: integer
|
||
|
|
title: Upvotes
|
||
|
|
downvotes:
|
||
|
|
type: integer
|
||
|
|
title: Downvotes
|
||
|
|
user_vote:
|
||
|
|
type: integer
|
||
|
|
title: User Vote
|
||
|
|
my_latest_score:
|
||
|
|
anyOf:
|
||
|
|
- $ref: '#/components/schemas/ScoreSummaryOut'
|
||
|
|
- type: 'null'
|
||
|
|
my_best_score:
|
||
|
|
anyOf:
|
||
|
|
- $ref: '#/components/schemas/ScoreSummaryOut'
|
||
|
|
- type: 'null'
|
||
|
|
global_best_score:
|
||
|
|
anyOf:
|
||
|
|
- $ref: '#/components/schemas/GlobalBestScoreOut'
|
||
|
|
- type: 'null'
|
||
|
|
is_favourited:
|
||
|
|
type: boolean
|
||
|
|
title: Is Favourited
|
||
|
|
default: false
|
||
|
|
created_at:
|
||
|
|
type: string
|
||
|
|
format: date-time
|
||
|
|
title: Created At
|
||
|
|
updated_at:
|
||
|
|
type: string
|
||
|
|
format: date-time
|
||
|
|
title: Updated At
|
||
|
|
questions:
|
||
|
|
items:
|
||
|
|
$ref: '#/components/schemas/QuestionPlayOut'
|
||
|
|
type: array
|
||
|
|
title: Questions
|
||
|
|
editable_questions:
|
||
|
|
anyOf:
|
||
|
|
- items:
|
||
|
|
$ref: '#/components/schemas/QuestionAuthorOut'
|
||
|
|
type: array
|
||
|
|
- type: 'null'
|
||
|
|
title: Editable Questions
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- id
|
||
|
|
- share_slug
|
||
|
|
- title
|
||
|
|
- description
|
||
|
|
- is_public
|
||
|
|
- author_id
|
||
|
|
- author_nickname
|
||
|
|
- author_avatar_animal
|
||
|
|
- author_avatar_color
|
||
|
|
- question_count
|
||
|
|
- quiz_mode
|
||
|
|
- upvotes
|
||
|
|
- downvotes
|
||
|
|
- user_vote
|
||
|
|
- created_at
|
||
|
|
- updated_at
|
||
|
|
- questions
|
||
|
|
title: QuizDetailOut
|
||
|
|
QuizSubmitIn:
|
||
|
|
properties:
|
||
|
|
answers:
|
||
|
|
additionalProperties:
|
||
|
|
type: string
|
||
|
|
type: object
|
||
|
|
title: Answers
|
||
|
|
type: object
|
||
|
|
title: QuizSubmitIn
|
||
|
|
QuizSubmitOut:
|
||
|
|
properties:
|
||
|
|
attempt_id:
|
||
|
|
type: integer
|
||
|
|
title: Attempt Id
|
||
|
|
score_count:
|
||
|
|
type: integer
|
||
|
|
title: Score Count
|
||
|
|
total_questions:
|
||
|
|
type: integer
|
||
|
|
title: Total Questions
|
||
|
|
score_percent:
|
||
|
|
type: number
|
||
|
|
title: Score Percent
|
||
|
|
results:
|
||
|
|
items:
|
||
|
|
$ref: '#/components/schemas/QuestionResultOut'
|
||
|
|
type: array
|
||
|
|
title: Results
|
||
|
|
my_latest_score:
|
||
|
|
$ref: '#/components/schemas/ScoreSummaryOut'
|
||
|
|
my_best_score:
|
||
|
|
$ref: '#/components/schemas/ScoreSummaryOut'
|
||
|
|
global_best_score:
|
||
|
|
$ref: '#/components/schemas/GlobalBestScoreOut'
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- attempt_id
|
||
|
|
- score_count
|
||
|
|
- total_questions
|
||
|
|
- score_percent
|
||
|
|
- results
|
||
|
|
- my_latest_score
|
||
|
|
- my_best_score
|
||
|
|
- global_best_score
|
||
|
|
title: QuizSubmitOut
|
||
|
|
QuizSummaryOut:
|
||
|
|
properties:
|
||
|
|
id:
|
||
|
|
type: integer
|
||
|
|
title: Id
|
||
|
|
share_slug:
|
||
|
|
type: string
|
||
|
|
title: Share Slug
|
||
|
|
title:
|
||
|
|
type: string
|
||
|
|
title: Title
|
||
|
|
description:
|
||
|
|
type: string
|
||
|
|
title: Description
|
||
|
|
is_public:
|
||
|
|
type: boolean
|
||
|
|
title: Is Public
|
||
|
|
author_id:
|
||
|
|
type: integer
|
||
|
|
title: Author Id
|
||
|
|
author_nickname:
|
||
|
|
type: string
|
||
|
|
title: Author Nickname
|
||
|
|
author_avatar_animal:
|
||
|
|
type: string
|
||
|
|
title: Author Avatar Animal
|
||
|
|
author_avatar_color:
|
||
|
|
type: string
|
||
|
|
title: Author Avatar Color
|
||
|
|
question_count:
|
||
|
|
type: integer
|
||
|
|
title: Question Count
|
||
|
|
quiz_mode:
|
||
|
|
type: string
|
||
|
|
enum:
|
||
|
|
- multiple_choice
|
||
|
|
- write_in
|
||
|
|
- mixed
|
||
|
|
- empty
|
||
|
|
title: Quiz Mode
|
||
|
|
upvotes:
|
||
|
|
type: integer
|
||
|
|
title: Upvotes
|
||
|
|
downvotes:
|
||
|
|
type: integer
|
||
|
|
title: Downvotes
|
||
|
|
user_vote:
|
||
|
|
type: integer
|
||
|
|
title: User Vote
|
||
|
|
my_latest_score:
|
||
|
|
anyOf:
|
||
|
|
- $ref: '#/components/schemas/ScoreSummaryOut'
|
||
|
|
- type: 'null'
|
||
|
|
my_best_score:
|
||
|
|
anyOf:
|
||
|
|
- $ref: '#/components/schemas/ScoreSummaryOut'
|
||
|
|
- type: 'null'
|
||
|
|
global_best_score:
|
||
|
|
anyOf:
|
||
|
|
- $ref: '#/components/schemas/GlobalBestScoreOut'
|
||
|
|
- type: 'null'
|
||
|
|
is_favourited:
|
||
|
|
type: boolean
|
||
|
|
title: Is Favourited
|
||
|
|
default: false
|
||
|
|
created_at:
|
||
|
|
type: string
|
||
|
|
format: date-time
|
||
|
|
title: Created At
|
||
|
|
updated_at:
|
||
|
|
type: string
|
||
|
|
format: date-time
|
||
|
|
title: Updated At
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- id
|
||
|
|
- share_slug
|
||
|
|
- title
|
||
|
|
- description
|
||
|
|
- is_public
|
||
|
|
- author_id
|
||
|
|
- author_nickname
|
||
|
|
- author_avatar_animal
|
||
|
|
- author_avatar_color
|
||
|
|
- question_count
|
||
|
|
- quiz_mode
|
||
|
|
- upvotes
|
||
|
|
- downvotes
|
||
|
|
- user_vote
|
||
|
|
- created_at
|
||
|
|
- updated_at
|
||
|
|
title: QuizSummaryOut
|
||
|
|
QuizUpdateIn:
|
||
|
|
properties:
|
||
|
|
title:
|
||
|
|
type: string
|
||
|
|
maxLength: 140
|
||
|
|
minLength: 1
|
||
|
|
title: Title
|
||
|
|
description:
|
||
|
|
type: string
|
||
|
|
maxLength: 1000
|
||
|
|
title: Description
|
||
|
|
default: ''
|
||
|
|
is_public:
|
||
|
|
type: boolean
|
||
|
|
title: Is Public
|
||
|
|
default: true
|
||
|
|
questions:
|
||
|
|
items:
|
||
|
|
$ref: '#/components/schemas/QuestionIn'
|
||
|
|
type: array
|
||
|
|
maxItems: 40
|
||
|
|
title: Questions
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- title
|
||
|
|
title: QuizUpdateIn
|
||
|
|
ScoreSummaryOut:
|
||
|
|
properties:
|
||
|
|
score_count:
|
||
|
|
type: integer
|
||
|
|
title: Score Count
|
||
|
|
total_questions:
|
||
|
|
type: integer
|
||
|
|
title: Total Questions
|
||
|
|
score_percent:
|
||
|
|
type: number
|
||
|
|
title: Score Percent
|
||
|
|
completed_at:
|
||
|
|
type: string
|
||
|
|
format: date-time
|
||
|
|
title: Completed At
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- score_count
|
||
|
|
- total_questions
|
||
|
|
- score_percent
|
||
|
|
- completed_at
|
||
|
|
title: ScoreSummaryOut
|
||
|
|
TokenSessionOut:
|
||
|
|
properties:
|
||
|
|
access_token:
|
||
|
|
type: string
|
||
|
|
title: Access Token
|
||
|
|
token_type:
|
||
|
|
type: string
|
||
|
|
title: Token Type
|
||
|
|
default: bearer
|
||
|
|
user:
|
||
|
|
$ref: '#/components/schemas/UserOut'
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- access_token
|
||
|
|
- user
|
||
|
|
title: TokenSessionOut
|
||
|
|
UserOut:
|
||
|
|
properties:
|
||
|
|
id:
|
||
|
|
type: integer
|
||
|
|
title: Id
|
||
|
|
auth_sub:
|
||
|
|
type: string
|
||
|
|
title: Auth Sub
|
||
|
|
email:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Email
|
||
|
|
nickname:
|
||
|
|
type: string
|
||
|
|
title: Nickname
|
||
|
|
first_name:
|
||
|
|
type: string
|
||
|
|
title: First Name
|
||
|
|
last_name:
|
||
|
|
type: string
|
||
|
|
title: Last Name
|
||
|
|
age:
|
||
|
|
anyOf:
|
||
|
|
- type: integer
|
||
|
|
- type: 'null'
|
||
|
|
title: Age
|
||
|
|
gender:
|
||
|
|
type: string
|
||
|
|
title: Gender
|
||
|
|
gender_custom:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Gender Custom
|
||
|
|
avatar_animal:
|
||
|
|
type: string
|
||
|
|
title: Avatar Animal
|
||
|
|
avatar_color:
|
||
|
|
type: string
|
||
|
|
title: Avatar Color
|
||
|
|
public_website_consent:
|
||
|
|
type: boolean
|
||
|
|
title: Public Website Consent
|
||
|
|
consent_at:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
format: date-time
|
||
|
|
- type: 'null'
|
||
|
|
title: Consent At
|
||
|
|
onboarded:
|
||
|
|
type: boolean
|
||
|
|
title: Onboarded
|
||
|
|
is_admin:
|
||
|
|
type: boolean
|
||
|
|
title: Is Admin
|
||
|
|
is_banned:
|
||
|
|
type: boolean
|
||
|
|
title: Is Banned
|
||
|
|
ban_reason:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Ban Reason
|
||
|
|
created_at:
|
||
|
|
type: string
|
||
|
|
format: date-time
|
||
|
|
title: Created At
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- id
|
||
|
|
- auth_sub
|
||
|
|
- email
|
||
|
|
- nickname
|
||
|
|
- first_name
|
||
|
|
- last_name
|
||
|
|
- age
|
||
|
|
- gender
|
||
|
|
- gender_custom
|
||
|
|
- avatar_animal
|
||
|
|
- avatar_color
|
||
|
|
- public_website_consent
|
||
|
|
- consent_at
|
||
|
|
- onboarded
|
||
|
|
- is_admin
|
||
|
|
- is_banned
|
||
|
|
- ban_reason
|
||
|
|
- created_at
|
||
|
|
title: UserOut
|
||
|
|
UserScoreRowOut:
|
||
|
|
properties:
|
||
|
|
quiz_id:
|
||
|
|
type: integer
|
||
|
|
title: Quiz Id
|
||
|
|
share_slug:
|
||
|
|
type: string
|
||
|
|
title: Share Slug
|
||
|
|
quiz_title:
|
||
|
|
type: string
|
||
|
|
title: Quiz Title
|
||
|
|
question_count:
|
||
|
|
type: integer
|
||
|
|
title: Question Count
|
||
|
|
latest_score:
|
||
|
|
$ref: '#/components/schemas/ScoreSummaryOut'
|
||
|
|
best_score:
|
||
|
|
$ref: '#/components/schemas/ScoreSummaryOut'
|
||
|
|
global_best_score:
|
||
|
|
anyOf:
|
||
|
|
- $ref: '#/components/schemas/GlobalBestScoreOut'
|
||
|
|
- type: 'null'
|
||
|
|
attempts_count:
|
||
|
|
type: integer
|
||
|
|
title: Attempts Count
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- quiz_id
|
||
|
|
- share_slug
|
||
|
|
- quiz_title
|
||
|
|
- question_count
|
||
|
|
- latest_score
|
||
|
|
- best_score
|
||
|
|
- attempts_count
|
||
|
|
title: UserScoreRowOut
|
||
|
|
UserUpdateIn:
|
||
|
|
properties:
|
||
|
|
nickname:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
maxLength: 48
|
||
|
|
minLength: 2
|
||
|
|
- type: 'null'
|
||
|
|
title: Nickname
|
||
|
|
first_name:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
maxLength: 80
|
||
|
|
- type: 'null'
|
||
|
|
title: First Name
|
||
|
|
last_name:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
maxLength: 80
|
||
|
|
- type: 'null'
|
||
|
|
title: Last Name
|
||
|
|
age:
|
||
|
|
anyOf:
|
||
|
|
- type: integer
|
||
|
|
maximum: 120.0
|
||
|
|
minimum: 4.0
|
||
|
|
- type: 'null'
|
||
|
|
title: Age
|
||
|
|
clear_age:
|
||
|
|
type: boolean
|
||
|
|
title: Clear Age
|
||
|
|
default: false
|
||
|
|
gender:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Gender
|
||
|
|
gender_custom:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
maxLength: 80
|
||
|
|
- type: 'null'
|
||
|
|
title: Gender Custom
|
||
|
|
avatar_animal:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Avatar Animal
|
||
|
|
avatar_color:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: 'null'
|
||
|
|
title: Avatar Color
|
||
|
|
public_website_consent:
|
||
|
|
anyOf:
|
||
|
|
- type: boolean
|
||
|
|
- type: 'null'
|
||
|
|
title: Public Website Consent
|
||
|
|
type: object
|
||
|
|
title: UserUpdateIn
|
||
|
|
ValidationError:
|
||
|
|
properties:
|
||
|
|
loc:
|
||
|
|
items:
|
||
|
|
anyOf:
|
||
|
|
- type: string
|
||
|
|
- type: integer
|
||
|
|
type: array
|
||
|
|
title: Location
|
||
|
|
msg:
|
||
|
|
type: string
|
||
|
|
title: Message
|
||
|
|
type:
|
||
|
|
type: string
|
||
|
|
title: Error Type
|
||
|
|
input:
|
||
|
|
title: Input
|
||
|
|
ctx:
|
||
|
|
type: object
|
||
|
|
title: Context
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- loc
|
||
|
|
- msg
|
||
|
|
- type
|
||
|
|
title: ValidationError
|
||
|
|
VoteIn:
|
||
|
|
properties:
|
||
|
|
value:
|
||
|
|
type: integer
|
||
|
|
enum:
|
||
|
|
- -1
|
||
|
|
- 0
|
||
|
|
- 1
|
||
|
|
title: Value
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- value
|
||
|
|
title: VoteIn
|
||
|
|
VoteOut:
|
||
|
|
properties:
|
||
|
|
quiz_id:
|
||
|
|
type: integer
|
||
|
|
title: Quiz Id
|
||
|
|
upvotes:
|
||
|
|
type: integer
|
||
|
|
title: Upvotes
|
||
|
|
downvotes:
|
||
|
|
type: integer
|
||
|
|
title: Downvotes
|
||
|
|
user_vote:
|
||
|
|
type: integer
|
||
|
|
title: User Vote
|
||
|
|
type: object
|
||
|
|
required:
|
||
|
|
- quiz_id
|
||
|
|
- upvotes
|
||
|
|
- downvotes
|
||
|
|
- user_vote
|
||
|
|
title: VoteOut
|