|
@@ -0,0 +1,229 @@
|
|
|
+openapi: 3.0.3
|
|
|
+info:
|
|
|
+ title: null
|
|
|
+ description: ''
|
|
|
+ version: 3.9.9
|
|
|
+servers:
|
|
|
+ -
|
|
|
+ url: 'http://okay.dev'
|
|
|
+paths:
|
|
|
+ /api/withDescription:
|
|
|
+ get:
|
|
|
+ summary: 'Example title.'
|
|
|
+ description: "This will be the long description.\nIt can also be multiple lines long."
|
|
|
+ parameters:
|
|
|
+ -
|
|
|
+ in: header
|
|
|
+ name: Content-Type
|
|
|
+ description: ''
|
|
|
+ example: application/json
|
|
|
+ schema:
|
|
|
+ type: string
|
|
|
+ -
|
|
|
+ in: header
|
|
|
+ name: Accept
|
|
|
+ description: ''
|
|
|
+ example: application/json
|
|
|
+ schema:
|
|
|
+ type: string
|
|
|
+ responses: { }
|
|
|
+ tags:
|
|
|
+ - 'Group A'
|
|
|
+ security: []
|
|
|
+ /api/withResponseTag:
|
|
|
+ get:
|
|
|
+ summary: ''
|
|
|
+ description: ''
|
|
|
+ parameters:
|
|
|
+ -
|
|
|
+ in: header
|
|
|
+ name: Content-Type
|
|
|
+ description: ''
|
|
|
+ example: application/json
|
|
|
+ schema:
|
|
|
+ type: string
|
|
|
+ -
|
|
|
+ in: header
|
|
|
+ name: Accept
|
|
|
+ description: ''
|
|
|
+ example: application/json
|
|
|
+ schema:
|
|
|
+ type: string
|
|
|
+ responses:
|
|
|
+ 200:
|
|
|
+ description: '200'
|
|
|
+ content:
|
|
|
+ application/json:
|
|
|
+ schema:
|
|
|
+ type: object
|
|
|
+ example:
|
|
|
+ id: 4
|
|
|
+ name: banana
|
|
|
+ color: red
|
|
|
+ weight: '1 kg'
|
|
|
+ delicious: true
|
|
|
+ responseTag: true
|
|
|
+ properties:
|
|
|
+ id: { type: integer, example: 4 }
|
|
|
+ name: { type: string, example: banana }
|
|
|
+ color: { type: string, example: red }
|
|
|
+ weight: { type: string, example: '1 kg' }
|
|
|
+ delicious: { type: boolean, example: true }
|
|
|
+ responseTag: { type: boolean, example: true }
|
|
|
+ tags:
|
|
|
+ - 'Group A'
|
|
|
+ security: []
|
|
|
+ /api/withBodyParameters:
|
|
|
+ post:
|
|
|
+ summary: 'Endpoint with body parameters.'
|
|
|
+ description: ''
|
|
|
+ parameters:
|
|
|
+ -
|
|
|
+ in: header
|
|
|
+ name: Content-Type
|
|
|
+ description: ''
|
|
|
+ example: application/json
|
|
|
+ schema:
|
|
|
+ type: string
|
|
|
+ -
|
|
|
+ in: header
|
|
|
+ name: Accept
|
|
|
+ description: ''
|
|
|
+ example: application/json
|
|
|
+ schema:
|
|
|
+ type: string
|
|
|
+ responses: { }
|
|
|
+ tags:
|
|
|
+ - 'Group A'
|
|
|
+ requestBody:
|
|
|
+ required: true
|
|
|
+ content:
|
|
|
+ application/json:
|
|
|
+ schema:
|
|
|
+ type: object
|
|
|
+ properties:
|
|
|
+ user_id:
|
|
|
+ type: integer
|
|
|
+ description: 'The id of the user.'
|
|
|
+ example: 9
|
|
|
+ room_id:
|
|
|
+ type: string
|
|
|
+ description: 'The id of the room.'
|
|
|
+ example: consequatur
|
|
|
+ forever:
|
|
|
+ type: boolean
|
|
|
+ description: 'Whether to ban the user forever.'
|
|
|
+ example: false
|
|
|
+ another_one:
|
|
|
+ type: number
|
|
|
+ description: 'Just need something here.'
|
|
|
+ example: 11613.31890586
|
|
|
+ yet_another_param:
|
|
|
+ type: object
|
|
|
+ description: 'Some object params.'
|
|
|
+ example: { }
|
|
|
+ yet_another_param.name:
|
|
|
+ type: string
|
|
|
+ description: 'Subkey in the object param.'
|
|
|
+ example: consequatur
|
|
|
+ even_more_param:
|
|
|
+ type: array
|
|
|
+ description: 'Some array params.'
|
|
|
+ example: []
|
|
|
+ items: { type: object }
|
|
|
+ 'even_more_param.*':
|
|
|
+ type: number
|
|
|
+ description: 'Subkey in the array param.'
|
|
|
+ example: 11613.31890586
|
|
|
+ book.name:
|
|
|
+ type: string
|
|
|
+ description: ''
|
|
|
+ example: consequatur
|
|
|
+ book.author_id:
|
|
|
+ type: integer
|
|
|
+ description: ''
|
|
|
+ example: 17
|
|
|
+ 'book[pages_count]':
|
|
|
+ type: integer
|
|
|
+ description: ''
|
|
|
+ example: 17
|
|
|
+ 'ids.*':
|
|
|
+ type: integer
|
|
|
+ description: ''
|
|
|
+ example: 17
|
|
|
+ 'users.*.first_name':
|
|
|
+ type: string
|
|
|
+ description: 'The first name of the user.'
|
|
|
+ example: John
|
|
|
+ 'users.*.last_name':
|
|
|
+ type: string
|
|
|
+ description: 'The last name of the user.'
|
|
|
+ example: Doe
|
|
|
+ required:
|
|
|
+ - user_id
|
|
|
+ - yet_another_param
|
|
|
+ - yet_another_param.name
|
|
|
+ security: []
|
|
|
+ /api/withQueryParameters:
|
|
|
+ get:
|
|
|
+ summary: ''
|
|
|
+ description: ''
|
|
|
+ parameters:
|
|
|
+ -
|
|
|
+ in: query
|
|
|
+ name: location_id
|
|
|
+ description: 'The id of the location.'
|
|
|
+ example: consequatur
|
|
|
+ required: true
|
|
|
+ schema:
|
|
|
+ type: string
|
|
|
+ -
|
|
|
+ in: query
|
|
|
+ name: user_id
|
|
|
+ description: 'The id of the user.'
|
|
|
+ example: me
|
|
|
+ required: true
|
|
|
+ schema:
|
|
|
+ type: string
|
|
|
+ -
|
|
|
+ in: query
|
|
|
+ name: page
|
|
|
+ description: 'The page number.'
|
|
|
+ example: '4'
|
|
|
+ required: true
|
|
|
+ schema:
|
|
|
+ type: string
|
|
|
+ -
|
|
|
+ in: query
|
|
|
+ name: 'filters.*'
|
|
|
+ description: 'The filters.'
|
|
|
+ example: consequatur
|
|
|
+ required: false
|
|
|
+ schema:
|
|
|
+ type: string
|
|
|
+ -
|
|
|
+ in: query
|
|
|
+ name: url_encoded
|
|
|
+ description: 'Used for testing that URL parameters will be URL-encoded where needed.'
|
|
|
+ example: '+ []&='
|
|
|
+ required: false
|
|
|
+ schema:
|
|
|
+ type: string
|
|
|
+ -
|
|
|
+ in: header
|
|
|
+ name: Content-Type
|
|
|
+ description: ''
|
|
|
+ example: application/json
|
|
|
+ schema:
|
|
|
+ type: string
|
|
|
+ -
|
|
|
+ in: header
|
|
|
+ name: Accept
|
|
|
+ description: ''
|
|
|
+ example: application/json
|
|
|
+ schema:
|
|
|
+ type: string
|
|
|
+ responses: { }
|
|
|
+ tags:
|
|
|
+ - 'Group A'
|
|
|
+ security: []
|