Skip to content

Instantly share code, notes, and snippets.

@nicolastakashi
Last active May 29, 2020 08:18
Show Gist options
  • Save nicolastakashi/aa5bf6dae053cf625649d866734ceddb to your computer and use it in GitHub Desktop.
Save nicolastakashi/aa5bf6dae053cf625649d866734ceddb to your computer and use it in GitHub Desktop.
get:
operationId: get-tasks
summary: Returns a paged list of tasks.
description: Returns a paged list of active tasks
tags:
- Tasks
parameters:
- $ref: '../../parameters/page-parameters.yaml#/components/parameters/page'
- $ref: '../../parameters/page-parameters.yaml#/components/parameters/pageSize'
responses:
'200':
description: Success
content:
application/json:
schema:
$ref: '../../schemas/pagedTask.yaml#/components/schemas/PagedTask'
post:
operationId: create-task
summary: Create a task
description: Create a new task
tags:
- Tasks
requestBody:
required: true
content:
application/json:
schema:
$ref: '../../schemas/task.yaml#/components/schemas/Task'
responses:
'201':
description: Created
headers:
Location:
description: 'Location of the created task /tasks/{id}'
schema:
type: string
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment