Skip to content

Instantly share code, notes, and snippets.

@vmstarchenko
Created March 22, 2021 09:47
Show Gist options
  • Save vmstarchenko/9671d45499a66d73b6746e69168c6cc5 to your computer and use it in GitHub Desktop.
Save vmstarchenko/9671d45499a66d73b6746e69168c6cc5 to your computer and use it in GitHub Desktop.
typescript-axios-broken-multiformat-nested-schema
openapi: 3.0.3
info:
title: ''
version: 0.0.1
paths:
/api/problem/:
post:
operationId: api_problem_create
description: ''
tags:
- api
requestBody:
content:
multipart/form-data:
schema:
$ref: '#/components/schemas/ProblemRequest'
required: true
responses:
'201':
content:
application/json:
schema:
$ref: '#/components/schemas/Problem'
description: ''
/api/problem_tag/:
post:
operationId: api_problem_tag_create
description: ''
tags:
- api
requestBody:
content:
multipart/form-data:
schema:
$ref: '#/components/schemas/ProblemTagRequest'
required: true
responses:
'201':
content:
application/json:
schema:
$ref: '#/components/schemas/ProblemTag'
description: ''
components:
schemas:
Problem:
type: object
properties:
id:
type: integer
readOnly: true
tags:
type: array
items:
$ref: '#/components/schemas/ProblemTag'
required:
- tags
ProblemRequest:
type: object
properties:
tags:
type: array
items:
$ref: '#/components/schemas/ProblemTagRequest'
required:
- tags
ProblemTag:
type: object
properties:
id:
type: integer
readOnly: true
title:
type: string
maxLength: 32
required:
- title
ProblemTagRequest:
type: object
properties:
title:
type: string
maxLength: 32
required:
- title
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment