Skip to content
This repository has been archived by the owner on Mar 21, 2024. It is now read-only.

Commit

Permalink
Try to add multipe refs to a response object
Browse files Browse the repository at this point in the history
  • Loading branch information
gmourier committed May 17, 2022
1 parent 1f9b162 commit ee1dbc4
Showing 1 changed file with 62 additions and 3 deletions.
65 changes: 62 additions & 3 deletions open-api.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,18 @@ servers:
description: 'https://example.meilisearch.com:7700'
components:
schemas:
limit:
type: integer
description: Limit given for the query. If limit is not provided as a query parameter, this parameter displays the default limit value.
example: 10
offset:
type: integer
description: Offset given for the query. If offset is not provided as a query parameter, this parameter displays the default offset value.
example: 0
total:
type: integer
description: Total number of browsable results using offset/limit parameters for the given resource.
example: 50
timestamp:
type: string
description: An `RFC 3339` format for date/time/duration.
Expand Down Expand Up @@ -680,14 +692,14 @@ components:
limit:
name: limit
in: query
description: Maximum number of documents to return.
description: Maximum number of results to return.
schema:
type: number
default: 20
offset:
name: offset
in: query
description: Number of documents to skip.
description: Number of results to skip.
schema:
type: number
default: 0
Expand Down Expand Up @@ -1055,6 +1067,17 @@ paths:
type: array
items:
$ref: '#/components/schemas/index'
limit:
$ref: '#/components/schemas/limit'
offset:
$ref: '#/components/schemas/offset'
total:
$ref: '#/components/schemas/total'
required:
- results
- limit
- offset
- total
examples:
Example:
value:
Expand All @@ -1064,8 +1087,14 @@ paths:
primaryKey: movie_id
createdAt: '2019-11-20T09:40:33.711324Z'
updatedAt: '2019-11-20T09:40:33.711324Z'
limit: 1
offset: 0
total: 1
'401':
$ref: '#/components/responses/401'
parameters:
- $ref: '#/components/parameters/limit'
- $ref: '#/components/parameters/offset'
post:
operationId: indexes.create
summary: Create Index
Expand Down Expand Up @@ -1237,6 +1266,17 @@ paths:
type: array
items:
$ref: '#/components/schemas/document'
limit:
$ref: '#/components/schemas/limit'
offset:
$ref: '#/components/schemas/offset'
total:
$ref: '#/components/schemas/total'
required:
- results
- limit
- offset
- total
examples:
Example:
value:
Expand All @@ -1251,7 +1291,9 @@ paths:
poster: 'https://image.tmdb.org/t/p/w500/4X7quIcdkc24Cveg5XdpfRqxtYA.jpg'
overview: "The Bridge of San Luis Rey is American author Thornton Wilder's second novel, first published in 1927 to worldwide acclaim. It tells the story of several interrelated people who die in the collapse of an Inca rope-fiber suspension bridge in Peru, and the events that lead up to their being on the bridge.[ A friar who has witnessed the tragic accident then goes about inquiring into the lives of the victims, seeking some sort of cosmic answer to the question of why each had to die. The novel won the Pulitzer Prize in 1928."
release_date: 1072915200

limit: 20
offset: 0
total: 2
'401':
$ref: '#/components/responses/401'
'404':
Expand Down Expand Up @@ -2653,6 +2695,17 @@ paths:
type: array
items:
$ref: '#/components/schemas/key'
limit:
$ref: '#/components/schemas/limit'
offset:
$ref: '#/components/schemas/offset'
total:
$ref: '#/components/schemas/total'
required:
- results
- limit
- offset
- total
examples:
example-1:
value:
Expand All @@ -2666,8 +2719,14 @@ paths:
expiresAt: '2022-11-12T10:00:00Z'
createdAt: '2021-11-12T10:00:00Z'
updatedAt: '2021-11-12T10:00:00Z'
limit: 20
offset: 0
total: 1
'401':
$ref: '#/components/responses/401'
parameters:
- $ref: '#/components/parameters/limit'
- $ref: '#/components/parameters/offset'
'/keys/{key}':
get:
summary: Get an API key
Expand Down

0 comments on commit ee1dbc4

Please sign in to comment.