diff options
author | Stephen Finucane <stephen@that.guru> | 2018-12-24 13:40:02 +0000 |
---|---|---|
committer | Stephen Finucane <stephen@that.guru> | 2018-12-24 14:23:05 +0000 |
commit | 1913800e1fe5806d0dfac2986b08c165c2577541 (patch) | |
tree | 52d401f13a4af51489bdc78a92a8802b9a107e3a /docs | |
parent | 8e42d30896e1b50d9916e564e7455a1f5272ca74 (diff) | |
download | patchwork-1913800e1fe5806d0dfac2986b08c165c2577541.tar patchwork-1913800e1fe5806d0dfac2986b08c165c2577541.tar.gz |
docs: Reformat schemas
Tested using 'yamllint'.
Signed-off-by: Stephen Finucane <stephen@that.guru>
Diffstat (limited to 'docs')
-rw-r--r-- | docs/api/schemas/generate_schema.py | 1 | ||||
-rw-r--r-- | docs/api/schemas/latest/patchwork.yaml | 1246 | ||||
-rw-r--r-- | docs/api/schemas/patchwork.j2 | 1244 | ||||
-rw-r--r-- | docs/api/schemas/v1.0/patchwork.yaml | 1235 | ||||
-rw-r--r-- | docs/api/schemas/v1.1/patchwork.yaml | 1246 |
5 files changed, 2530 insertions, 2442 deletions
diff --git a/docs/api/schemas/generate_schema.py b/docs/api/schemas/generate_schema.py index 01ebaed..39f5cf0 100644 --- a/docs/api/schemas/generate_schema.py +++ b/docs/api/schemas/generate_schema.py @@ -30,6 +30,7 @@ def generate_schema(): with open(os.path.join(version_dir, 'patchwork.yaml'), 'wb') as fh: template.stream(version=version, version_str=version_str, version_url=version_url).dump(fh, encoding='utf-8') + fh.write('\n') if __name__ == '__main__': diff --git a/docs/api/schemas/latest/patchwork.yaml b/docs/api/schemas/latest/patchwork.yaml index f96d689..e3ba69c 100644 --- a/docs/api/schemas/latest/patchwork.yaml +++ b/docs/api/schemas/latest/patchwork.yaml @@ -1,9 +1,10 @@ # DO NOT EDIT THIS FILE. It is generated from a template. Changes should be # proposed against the template. +--- openapi: '3.0.0' info: title: Patchwork API - description: | + description: > Patchwork is a web-based patch tracking system designed to facilitate the contribution and management of contributions to an open-source project. contact: @@ -26,37 +27,37 @@ paths: schema: $ref: '#/components/schemas/Index' tags: - - api + - api /api/bundles/: get: description: List bundles. operationId: bundles_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - in: query - name: project - description: 'An ID or linkname of a project to filter bundles by.' - schema: - title: '' - type: string - - in: query - name: owner - description: 'An ID or username of a user to filter bundles by.' - schema: - title: '' - type: string - - in: query - name: public - description: 'Show only public (`true`) or private (`false`) bundles.' - schema: - title: '' - type: string - enum: - - 'true' - - 'false' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - in: query + name: project + description: An ID or linkname of a project to filter bundles by. + schema: + title: '' + type: string + - in: query + name: owner + description: An ID or username of a user to filter bundles by. + schema: + title: '' + type: string + - in: query + name: public + description: Show only public (`true`) or private (`false`) bundles. + schema: + title: '' + type: string + enum: + - 'true' + - 'false' responses: '200': description: '' @@ -70,19 +71,19 @@ paths: items: $ref: '#/components/schemas/Bundle' tags: - - bundles + - bundles /api/bundles/{id}/: get: description: Show a bundle. operationId: bundles_read parameters: - - in: path - name: id - required: true - description: 'A unique integer value identifying this bundle.' - schema: - title: ID - type: integer + - in: path + name: id + required: true + description: A unique integer value identifying this bundle. + schema: + title: ID + type: integer responses: '200': description: '' @@ -91,42 +92,44 @@ paths: schema: $ref: '#/components/schemas/Bundle' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - bundles + - bundles /api/covers/: get: description: List cover letters. operationId: covers_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - $ref: '#/components/parameters/BeforeFilter' - - $ref: '#/components/parameters/SinceFilter' - - in: query - name: project - description: 'An ID or linkname of a project to filter cover letters by.' - schema: - title: '' - type: string - - in: query - name: series - description: 'An ID of a series to filter cover letters by.' - schema: - title: '' - type: string - - in: query - name: submitter - description: 'An ID or email address of a person to filter cover letters by.' - schema: - title: '' - type: string + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/BeforeFilter' + - $ref: '#/components/parameters/SinceFilter' + - in: query + name: project + description: > + An ID or linkname of a project to filter cover letters by. + schema: + title: '' + type: string + - in: query + name: series + description: An ID of a series to filter cover letters by. + schema: + title: '' + type: string + - in: query + name: submitter + description: > + An ID or email address of a person to filter cover letters by. + schema: + title: '' + type: string responses: '200': description: '' @@ -140,19 +143,19 @@ paths: items: $ref: '#/components/schemas/CoverLetterList' tags: - - covers + - covers /api/covers/{id}/: get: description: Show a cover letter. operationId: covers_read parameters: - - in: path - name: id - description: 'A unique integer value identifying this cover letter.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this cover letter. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -161,29 +164,30 @@ paths: schema: $ref: '#/components/schemas/CoverLetterDetail' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - covers + - covers /api/covers/{id}/comments/: get: description: List comments operationId: cover_comments_list parameters: - - in: path - name: id - description: 'A unique integer value identifying the parent cover letter.' - required: true - schema: - title: ID - type: integer - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' + - in: path + name: id + description: > + A unique integer value identifying the parent cover letter. + required: true + schema: + title: ID + type: integer + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' responses: '200': description: '' @@ -197,63 +201,63 @@ paths: items: $ref: '#/components/schemas/Comment' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - comments + - comments /api/events/: get: description: List events. operationId: events_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - $ref: '#/components/parameters/BeforeFilter' - - $ref: '#/components/parameters/SinceFilter' - - in: query - name: project - description: 'An ID or linkname of a project to filter events by.' - schema: - title: '' - type: string - - in: query - name: category - description: 'An event category to filter events by.' - schema: - title: '' - type: string - enum: - - cover-created - - patch-created - - patch-completed - - patch-state-changed - - patch-delegated - - check-created - - series-created - - series-completed - - in: query - name: series - description: 'An ID of a series to filter events by.' - schema: - title: '' - type: integer - - in: query - name: patch - description: 'An ID of a patch to filter events by.' - schema: - title: '' - type: integer - - in: query - name: cover - description: 'An ID of a cover letter to filter events by.' - schema: - title: '' - type: integer + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/BeforeFilter' + - $ref: '#/components/parameters/SinceFilter' + - in: query + name: project + description: An ID or linkname of a project to filter events by. + schema: + title: '' + type: string + - in: query + name: category + description: An event category to filter events by. + schema: + title: '' + type: string + enum: + - cover-created + - patch-created + - patch-completed + - patch-state-changed + - patch-delegated + - check-created + - series-created + - series-completed + - in: query + name: series + description: An ID of a series to filter events by. + schema: + title: '' + type: integer + - in: query + name: patch + description: An ID of a patch to filter events by. + schema: + title: '' + type: integer + - in: query + name: cover + description: An ID of a cover letter to filter events by. + schema: + title: '' + type: integer responses: '200': description: '' @@ -279,64 +283,70 @@ paths: mapping: cover-created: '#/components/schemas/EventCoverCreated' patch-created: '#/components/schemas/EventPatchCreated' - patch-completed: '#/components/schemas/EventPatchCompleted' - patch-state-changed: '#/components/schemas/EventPatchStateChanged' - patch-delegated: '#/components/schemas/EventPatchDelegated' + patch-completed: > + '#/components/schemas/EventPatchCompleted' + patch-state-changed: > + '#/components/schemas/EventPatchStateChanged' + patch-delegated: > + '#/components/schemas/EventPatchDelegated' check-created: '#/components/schemas/EventCheckCreated' series-created: '#/components/schemas/EventSeriesCreated' - series-completed: '#/components/schemas/EventSeriesCompleted' + series-completed: > + '#/components/schemas/EventSeriesCompleted' tags: - - events + - events /api/patches/: get: description: List patches. operationId: patches_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - $ref: '#/components/parameters/BeforeFilter' - - $ref: '#/components/parameters/SinceFilter' - - in: query - name: project - description: 'An ID or linkname of a project to filter patches by.' - schema: - title: '' - type: string - - in: query - name: series - description: 'An ID of a series to filter patches by.' - schema: - title: '' - type: integer - - in: query - name: submitter - description: 'An ID or email address of a person to filter patches by.' - schema: - title: '' - type: string - - in: query - name: delegate - description: 'An ID or username of a user to filter patches by.' - schema: - title: '' - type: string - - in: query - name: state - description: 'A slug representation of a state to filter patches by.' - schema: - title: '' - type: string - - in: query - name: archived - description: 'Show only archived (`true`) or non-archived (`false`) patches.' - schema: - title: '' - type: string - enum: - - 'true' - - 'false' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/BeforeFilter' + - $ref: '#/components/parameters/SinceFilter' + - in: query + name: project + description: An ID or linkname of a project to filter patches by. + schema: + title: '' + type: string + - in: query + name: series + description: An ID of a series to filter patches by. + schema: + title: '' + type: integer + - in: query + name: submitter + description: > + An ID or email address of a person to filter patches by. + schema: + title: '' + type: string + - in: query + name: delegate + description: An ID or username of a user to filter patches by. + schema: + title: '' + type: string + - in: query + name: state + description: A slug representation of a state to filter patches by. + schema: + title: '' + type: string + - in: query + name: archived + description: > + Show only archived (`true`) or non-archived (`false`) patches. + schema: + title: '' + type: string + enum: + - 'true' + - 'false' responses: '200': description: '' @@ -350,19 +360,19 @@ paths: items: $ref: '#/components/schemas/PatchList' tags: - - patches + - patches /api/patches/{id}/: get: description: Show a patch. operationId: patches_read parameters: - - in: path - name: id - description: 'A unique integer value identifying this patch.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this patch. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -371,27 +381,27 @@ paths: schema: $ref: '#/components/schemas/PatchDetail' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - patches + - patches patch: description: Update a patch (partial). operationId: patches_partial_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this patch.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this patch. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/Patch' responses: @@ -402,39 +412,39 @@ paths: schema: $ref: '#/components/schemas/PatchDetail' '400': - description: 'Invalid Request' + description: Invalid Request content: application/json: schema: $ref: '#/components/schemas/ErrorPatchUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - patches + - patches put: description: Update a patch. operationId: patches_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this patch.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this patch. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/Patch' responses: @@ -445,41 +455,41 @@ paths: schema: $ref: '#/components/schemas/PatchDetail' '400': - description: 'Invalid Request' + description: Invalid Request content: application/json: schema: $ref: '#/components/schemas/ErrorPatchUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - patches + - patches /api/patches/{id}/comments/: get: description: List comments operationId: patch_comments_list parameters: - - in: path - name: id - description: 'A unique integer value identifying the parent patch.' - required: true - schema: - title: ID - type: integer - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' + - in: path + name: id + description: A unique integer value identifying the parent patch. + required: true + schema: + title: ID + type: integer + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' responses: '200': description: '' @@ -493,54 +503,54 @@ paths: items: $ref: '#/components/schemas/Comment' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - comments + - comments /api/patches/{patch_id}/checks/: get: description: List checks. operationId: checks_list parameters: - - in: path - name: patch_id - description: 'A unique integer value identifying the parent patch.' - required: true - schema: - title: Patch ID - type: integer - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - $ref: '#/components/parameters/BeforeFilter' - - $ref: '#/components/parameters/SinceFilter' - - in: query - name: user - description: 'An ID or username of a user to filter checks by.' - schema: - title: '' - type: string - - in: query - name: state - description: 'A check state to filter checks by.' - schema: - title: '' - type: string - enum: - - pending - - success - - warning - - fail - - in: query - name: context - description: 'A check context to filter checks by.' - schema: - title: '' - type: string + - in: path + name: patch_id + description: A unique integer value identifying the parent patch. + required: true + schema: + title: Patch ID + type: integer + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/BeforeFilter' + - $ref: '#/components/parameters/SinceFilter' + - in: query + name: user + description: An ID or username of a user to filter checks by. + schema: + title: '' + type: string + - in: query + name: state + description: A check state to filter checks by. + schema: + title: '' + type: string + enum: + - pending + - success + - warning + - fail + - in: query + name: context + description: A check context to filter checks by. + schema: + title: '' + type: string responses: '200': description: '' @@ -554,27 +564,27 @@ paths: items: $ref: '#/components/schemas/Check' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - checks + - checks post: description: Create a check. operationId: checks_create security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: patch_id - description: 'A unique integer value identifying the parent patch.' - required: true - schema: - title: Patch ID - type: integer + - in: path + name: patch_id + description: A unique integer value identifying the parent patch. + required: true + schema: + title: Patch ID + type: integer requestBody: $ref: '#/components/requestBodies/Check' responses: @@ -585,44 +595,44 @@ paths: schema: $ref: '#/components/schemas/Check' '400': - description: 'Invalid Request' + description: Invalid Request content: application/json: schema: $ref: '#/components/schemas/ErrorCheckCreate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - checks + - checks /api/patches/{patch_id}/checks/{check_id}/: get: description: Show a check. operationId: checks_read parameters: - - in: path - name: patch_id - description: 'A unique integer value identifying the parent patch.' - required: true - schema: - title: Patch ID - type: integer - - in: path - name: check_id - description: 'A unique integer value identifying this check.' - required: true - schema: - title: Check ID - type: integer + - in: path + name: patch_id + description: A unique integer value identifying the parent patch. + required: true + schema: + title: Patch ID + type: integer + - in: path + name: check_id + description: A unique integer value identifying this check. + required: true + schema: + title: Check ID + type: integer responses: '200': description: '' @@ -631,25 +641,25 @@ paths: schema: $ref: '#/components/schemas/Check' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - checks + - checks /api/people/: get: description: List people. operationId: people_list security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' responses: '200': description: '' @@ -663,28 +673,28 @@ paths: items: $ref: '#/components/schemas/Person' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - people + - people /api/people/{id}/: get: description: Show a person. operationId: people_read security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this person.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this person. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -693,28 +703,28 @@ paths: schema: $ref: '#/components/schemas/Person' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - people + - people /api/projects/: get: description: List projects. operationId: projects_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' responses: '200': description: '' @@ -728,19 +738,19 @@ paths: items: $ref: '#/components/schemas/Project' tags: - - projects + - projects /api/projects/{id}/: get: description: Show a project. operationId: projects_read parameters: - - in: path - name: id - description: 'A unique integer value identifying this project.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this project. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -749,27 +759,27 @@ paths: schema: $ref: '#/components/schemas/Project' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - projects + - projects patch: description: Update a project (partial). operationId: projects_partial_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this project.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this project. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/Project' responses: @@ -780,39 +790,39 @@ paths: schema: $ref: '#/components/schemas/Project' '400': - description: 'Bad request' + description: Bad request content: application/json: schema: $ref: '#/components/schemas/ErrorProjectUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - projects + - projects put: description: Update a project. operationId: projects_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this project.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this project. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/Project' responses: @@ -823,48 +833,48 @@ paths: schema: $ref: '#/components/schemas/Project' '400': - description: 'Bad request' + description: Bad request content: application/json: schema: $ref: '#/components/schemas/ErrorProjectUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - projects + - projects /api/series/: get: description: List series. operationId: series_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - $ref: '#/components/parameters/BeforeFilter' - - $ref: '#/components/parameters/SinceFilter' - - in: query - name: submitter - description: 'An ID or email address of a person to filter series by.' - schema: - title: '' - type: string - - in: query - name: project - description: 'An ID or linkname of a project to filter series by.' - schema: - title: '' - type: string + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/BeforeFilter' + - $ref: '#/components/parameters/SinceFilter' + - in: query + name: submitter + description: An ID or email address of a person to filter series by. + schema: + title: '' + type: string + - in: query + name: project + description: An ID or linkname of a project to filter series by. + schema: + title: '' + type: string responses: '200': description: '' @@ -878,19 +888,19 @@ paths: items: $ref: '#/components/schemas/Series' tags: - - series + - series /api/series/{id}/: get: description: Show a series. operationId: series_read parameters: - - in: path - name: id - description: 'A unique integer value identifying this series.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this series. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -899,25 +909,25 @@ paths: schema: $ref: '#/components/schemas/Series' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - series + - series /api/users/: get: description: List users. operationId: users_list security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' responses: '200': description: '' @@ -931,28 +941,28 @@ paths: items: $ref: '#/components/schemas/User' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - users + - users /api/users/{id}/: get: description: Show a user. operationId: users_read security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this user.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this user. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -961,33 +971,33 @@ paths: schema: $ref: '#/components/schemas/User' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - users + - users patch: description: Update a user (partial). operationId: users_partial_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this user.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this user. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/User' responses: @@ -998,39 +1008,39 @@ paths: schema: $ref: '#/components/schemas/User' '400': - description: 'Bad request' + description: Bad request content: application/json: schema: $ref: '#/components/schemas/ErrorUserUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - users + - users put: description: Update a user. operationId: users_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this user.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this user. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/User' responses: @@ -1041,25 +1051,25 @@ paths: schema: $ref: '#/components/schemas/User' '400': - description: 'Bad request' + description: Bad request content: application/json: schema: $ref: '#/components/schemas/ErrorUserUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - users + - users components: securitySchemes: basicAuth: @@ -1072,48 +1082,48 @@ components: Page: in: query name: page - description: 'A page number within the paginated result set.' + description: A page number within the paginated result set. schema: title: Page type: integer PageSize: in: query name: per_page - description: 'Number of results to return per page.' + description: Number of results to return per page. schema: title: Page size type: integer Order: in: query name: order - description: 'Which field to use when ordering the results.' + description: Which field to use when ordering the results. schema: title: Ordering type: string Search: in: query name: q - description: 'A search term.' + description: A search term. schema: title: Search type: string BeforeFilter: in: query name: before - description: 'Latest date-time to retrieve results for.' + description: Latest date-time to retrieve results for. schema: title: '' type: string SinceFilter: in: query name: since - description: 'Earliest date-time to retrieve results for.' + description: Earliest date-time to retrieve results for. schema: title: '' type: string headers: Link: - description: | + description: > Links to related resources, in the format defined by [RFC 5988](https://tools.ietf.org/html/rfc5988#section-5). This will include a link with relation type `next` to the @@ -1239,7 +1249,7 @@ components: title: Owner readOnly: true allOf: - - $ref: '#/components/schemas/UserEmbedded' + - $ref: '#/components/schemas/UserEmbedded' patches: type: array items: @@ -1278,21 +1288,23 @@ components: description: The state of the check. type: string enum: - - pending - - success - - warning - - fail + - pending + - success + - warning + - fail target_url: title: Target URL - description: The target URL to associate with this check. This should be specific - to the patch. + description: > + The target URL to associate with this check. This should be + specific to the patch. type: string format: uri maxLength: 200 nullable: true context: title: Context - description: A label to discern check from checks of other testing systems. + description: > + A label to discern check from checks of other testing systems. type: string pattern: ^[-a-zA-Z0-9_]+$ minLength: 1 @@ -1310,21 +1322,23 @@ components: description: The state of the check. type: string enum: - - pending - - success - - warning - - fail + - pending + - success + - warning + - fail target_url: title: Target URL - description: The target URL to associate with this check. This should be specific - to the patch. + description: + The target URL to associate with this check. This should be + specific to the patch. type: string format: uri maxLength: 200 nullable: true context: title: Context - description: A label to discern check from checks of other testing systems. + description: > + A label to discern check from checks of other testing systems. type: string pattern: ^[-a-zA-Z0-9_]+$ minLength: 1 @@ -1365,7 +1379,7 @@ components: type: object title: Submitter allOf: - - $ref: '#/components/schemas/PersonEmbedded' + - $ref: '#/components/schemas/PersonEmbedded' content: title: Content type: string @@ -1418,7 +1432,7 @@ components: title: Submitter readOnly: true allOf: - - $ref: '#/components/schemas/PersonEmbedded' + - $ref: '#/components/schemas/PersonEmbedded' mbox: title: Mbox type: string @@ -1436,19 +1450,19 @@ components: readOnly: true CoverLetterDetail: allOf: - - $ref: '#/components/schemas/CoverLetterList' - - properties: - headers: - title: Headers - type: array - items: + - $ref: '#/components/schemas/CoverLetterList' + - properties: + headers: + title: Headers + type: array + items: + type: string + readOnly: true + content: + title: Content type: string - readOnly: true - content: - title: Content - type: string - readOnly: true - minLength: 1 + readOnly: true + minLength: 1 EventBase: type: object properties: @@ -1473,120 +1487,120 @@ components: type: object EventCoverCreated: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - cover-created - payload: - properties: - cover: - title: Cover - type: string - readOnly: true + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - cover-created + payload: + properties: + cover: + title: Cover + type: string + readOnly: true EventPatchCreated: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - patch-created - payload: - properties: - patch: - $ref: '#/components/schemas/PatchEmbedded' + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - patch-created + payload: + properties: + patch: + $ref: '#/components/schemas/PatchEmbedded' EventPatchCompleted: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - patch-completed - payload: - properties: - patch: - $ref: '#/components/schemas/PatchEmbedded' - series: - $ref: '#/components/schemas/SeriesEmbedded' + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - patch-completed + payload: + properties: + patch: + $ref: '#/components/schemas/PatchEmbedded' + series: + $ref: '#/components/schemas/SeriesEmbedded' EventPatchStateChanged: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - patch-state-changed - payload: - properties: - patch: - $ref: '#/components/schemas/PatchEmbedded' - previous_state: - title: Previous state - type: string - current_state: - title: Current state - type: string + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - patch-state-changed + payload: + properties: + patch: + $ref: '#/components/schemas/PatchEmbedded' + previous_state: + title: Previous state + type: string + current_state: + title: Current state + type: string EventPatchDelegated: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - patch-delegated - payload: - properties: - patch: - $ref: '#/components/schemas/PatchEmbedded' - previous_delegate: - allOf: - - $ref: '#/components/schemas/UserEmbedded' - - title: Previous delegate - current_delegate: - allOf: - - $ref: '#/components/schemas/UserEmbedded' - - title: Current delegate + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - patch-delegated + payload: + properties: + patch: + $ref: '#/components/schemas/PatchEmbedded' + previous_delegate: + allOf: + - $ref: '#/components/schemas/UserEmbedded' + - title: Previous delegate + current_delegate: + allOf: + - $ref: '#/components/schemas/UserEmbedded' + - title: Current delegate EventCheckCreated: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - check-created - payload: - properties: - patch: - $ref: '#/components/schemas/PatchEmbedded' - check: - $ref: '#/components/schemas/CheckEmbedded' + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - check-created + payload: + properties: + patch: + $ref: '#/components/schemas/PatchEmbedded' + check: + $ref: '#/components/schemas/CheckEmbedded' EventSeriesCreated: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - series-created - payload: - properties: - series: - $ref: '#/components/schemas/SeriesEmbedded' + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - series-created + payload: + properties: + series: + $ref: '#/components/schemas/SeriesEmbedded' EventSeriesCompleted: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - series-completed - payload: - properties: - series: - $ref: '#/components/schemas/SeriesEmbedded' + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - series-completed + payload: + properties: + series: + $ref: '#/components/schemas/SeriesEmbedded' PatchList: required: - state @@ -1653,14 +1667,14 @@ components: title: Submitter readOnly: true allOf: - - $ref: '#/components/schemas/PersonEmbedded' + - $ref: '#/components/schemas/PersonEmbedded' delegate: type: object title: Delegate nullable: true readOnly: true allOf: - - $ref: '#/components/schemas/UserEmbedded' + - $ref: '#/components/schemas/UserEmbedded' mbox: title: Mbox type: string @@ -1681,10 +1695,10 @@ components: type: string readOnly: true enum: - - pending - - success - - warning - - fail + - pending + - success + - warning + - fail checks: title: Checks type: string @@ -1698,30 +1712,30 @@ components: readOnly: true PatchDetail: allOf: - - $ref: '#/components/schemas/PatchList' - - properties: - headers: - title: Headers - type: array - items: + - $ref: '#/components/schemas/PatchList' + - properties: + headers: + title: Headers + type: array + items: + type: string + readOnly: true + content: + title: Content type: string - readOnly: true - content: - title: Content - type: string - readOnly: true - minLength: 1 - diff: - title: Diff - type: string - readOnly: true - minLength: 1 - prefixes: - title: Prefixes - type: array - items: + readOnly: true + minLength: 1 + diff: + title: Diff type: string - readOnly: true + readOnly: true + minLength: 1 + prefixes: + title: Prefixes + type: array + items: + type: string + readOnly: true PatchUpdate: type: object properties: @@ -1777,7 +1791,7 @@ components: nullable: true readOnly: true allOf: - - $ref: '#/components/schemas/UserEmbedded' + - $ref: '#/components/schemas/UserEmbedded' Project: type: object properties: @@ -1838,11 +1852,12 @@ components: uniqueItems: true subject_match: title: Subject match - description: Regex to match the subject against if only part of emails - sent to the list belongs to this project. Will be used with - IGNORECASE and MULTILINE flags. If rules for more projects match the - first one returned from DB is chosen; empty field serves as a - default for every email which has no other match. + description: > + Regex to match the subject against if only part of emails sent to + the list belongs to this project. Will be used with IGNORECASE and + MULTILINE flags. If rules for more projects match the first one + returned from DB is chosen; empty field serves as a default for + every email which has no other match. type: string readOnly: true maxLength: 64 @@ -1867,7 +1882,8 @@ components: $ref: '#/components/schemas/ProjectEmbedded' name: title: Name - description: An optional name to associate with the series, e.g. "John's PCI + description: > + An optional name to associate with the series, e.g. "John's PCI series". type: string maxLength: 255 @@ -1882,14 +1898,16 @@ components: title: Submitter readOnly: true allOf: - - $ref: '#/components/schemas/PersonEmbedded' + - $ref: '#/components/schemas/PersonEmbedded' version: title: Version - description: Version of series as indicated by the subject prefix(es) + description: > + Version of series as indicated by the subject prefix(es). type: integer total: title: Total - description: Number of patches in series as indicated by the subject prefix(es) + description: > + Number of patches in series as indicated by the subject prefix(es). type: integer readOnly: true received_total: @@ -1968,13 +1986,14 @@ components: type: string readOnly: true enum: - - pending - - success - - warning - - fail + - pending + - success + - warning + - fail target_url: title: Target url - description: The target URL to associate with this check. This should be specific + description: > + The target URL to associate with this check. This should be specific to the patch. type: string format: uri @@ -1983,7 +2002,8 @@ components: readOnly: true context: title: Context - description: A label to discern check from checks of other testing systems. + description: > + A label to discern check from checks of other testing systems. type: string pattern: ^[-a-zA-Z0-9_]+$ maxLength: 255 @@ -2159,7 +2179,8 @@ components: readOnly: true name: title: Name - description: An optional name to associate with the series, e.g. "John's PCI + description: > + An optional name to associate with the series, e.g. "John's PCI series". type: string readOnly: true @@ -2172,7 +2193,8 @@ components: readOnly: true version: title: Version - description: Version of series as indicated by the subject prefix(es) + description: > + Version of series as indicated by the subject prefix(es). type: integer readOnly: true mbox: @@ -2287,4 +2309,4 @@ components: last_name: title: First name type: string - readOnly: true
\ No newline at end of file + readOnly: true diff --git a/docs/api/schemas/patchwork.j2 b/docs/api/schemas/patchwork.j2 index c0f330f..7d34863 100644 --- a/docs/api/schemas/patchwork.j2 +++ b/docs/api/schemas/patchwork.j2 @@ -1,10 +1,11 @@ {# You can obviously ignore the below when editing this template #} # DO NOT EDIT THIS FILE. It is generated from a template. Changes should be # proposed against the template. +--- openapi: '3.0.0' info: title: Patchwork API - description: | + description: > Patchwork is a web-based patch tracking system designed to facilitate the contribution and management of contributions to an open-source project. contact: @@ -27,37 +28,37 @@ paths: schema: $ref: '#/components/schemas/Index' tags: - - api + - api /api/{{ version_url}}bundles/: get: description: List bundles. operationId: bundles_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - in: query - name: project - description: 'An ID or linkname of a project to filter bundles by.' - schema: - title: '' - type: string - - in: query - name: owner - description: 'An ID or username of a user to filter bundles by.' - schema: - title: '' - type: string - - in: query - name: public - description: 'Show only public (`true`) or private (`false`) bundles.' - schema: - title: '' - type: string - enum: - - 'true' - - 'false' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - in: query + name: project + description: An ID or linkname of a project to filter bundles by. + schema: + title: '' + type: string + - in: query + name: owner + description: An ID or username of a user to filter bundles by. + schema: + title: '' + type: string + - in: query + name: public + description: Show only public (`true`) or private (`false`) bundles. + schema: + title: '' + type: string + enum: + - 'true' + - 'false' responses: '200': description: '' @@ -71,19 +72,19 @@ paths: items: $ref: '#/components/schemas/Bundle' tags: - - bundles + - bundles /api/{{ version_url }}bundles/{id}/: get: description: Show a bundle. operationId: bundles_read parameters: - - in: path - name: id - required: true - description: 'A unique integer value identifying this bundle.' - schema: - title: ID - type: integer + - in: path + name: id + required: true + description: A unique integer value identifying this bundle. + schema: + title: ID + type: integer responses: '200': description: '' @@ -92,42 +93,44 @@ paths: schema: $ref: '#/components/schemas/Bundle' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - bundles + - bundles /api/{{ version_url }}covers/: get: description: List cover letters. operationId: covers_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - $ref: '#/components/parameters/BeforeFilter' - - $ref: '#/components/parameters/SinceFilter' - - in: query - name: project - description: 'An ID or linkname of a project to filter cover letters by.' - schema: - title: '' - type: string - - in: query - name: series - description: 'An ID of a series to filter cover letters by.' - schema: - title: '' - type: string - - in: query - name: submitter - description: 'An ID or email address of a person to filter cover letters by.' - schema: - title: '' - type: string + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/BeforeFilter' + - $ref: '#/components/parameters/SinceFilter' + - in: query + name: project + description: > + An ID or linkname of a project to filter cover letters by. + schema: + title: '' + type: string + - in: query + name: series + description: An ID of a series to filter cover letters by. + schema: + title: '' + type: string + - in: query + name: submitter + description: > + An ID or email address of a person to filter cover letters by. + schema: + title: '' + type: string responses: '200': description: '' @@ -141,19 +144,19 @@ paths: items: $ref: '#/components/schemas/CoverLetterList' tags: - - covers + - covers /api/{{ version_url }}covers/{id}/: get: description: Show a cover letter. operationId: covers_read parameters: - - in: path - name: id - description: 'A unique integer value identifying this cover letter.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this cover letter. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -162,29 +165,30 @@ paths: schema: $ref: '#/components/schemas/CoverLetterDetail' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - covers + - covers /api/{{ version_url }}covers/{id}/comments/: get: description: List comments operationId: cover_comments_list parameters: - - in: path - name: id - description: 'A unique integer value identifying the parent cover letter.' - required: true - schema: - title: ID - type: integer - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' + - in: path + name: id + description: > + A unique integer value identifying the parent cover letter. + required: true + schema: + title: ID + type: integer + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' responses: '200': description: '' @@ -198,63 +202,63 @@ paths: items: $ref: '#/components/schemas/Comment' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - comments + - comments /api/{{ version_url }}events/: get: description: List events. operationId: events_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - $ref: '#/components/parameters/BeforeFilter' - - $ref: '#/components/parameters/SinceFilter' - - in: query - name: project - description: 'An ID or linkname of a project to filter events by.' - schema: - title: '' - type: string - - in: query - name: category - description: 'An event category to filter events by.' - schema: - title: '' - type: string - enum: - - cover-created - - patch-created - - patch-completed - - patch-state-changed - - patch-delegated - - check-created - - series-created - - series-completed - - in: query - name: series - description: 'An ID of a series to filter events by.' - schema: - title: '' - type: integer - - in: query - name: patch - description: 'An ID of a patch to filter events by.' - schema: - title: '' - type: integer - - in: query - name: cover - description: 'An ID of a cover letter to filter events by.' - schema: - title: '' - type: integer + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/BeforeFilter' + - $ref: '#/components/parameters/SinceFilter' + - in: query + name: project + description: An ID or linkname of a project to filter events by. + schema: + title: '' + type: string + - in: query + name: category + description: An event category to filter events by. + schema: + title: '' + type: string + enum: + - cover-created + - patch-created + - patch-completed + - patch-state-changed + - patch-delegated + - check-created + - series-created + - series-completed + - in: query + name: series + description: An ID of a series to filter events by. + schema: + title: '' + type: integer + - in: query + name: patch + description: An ID of a patch to filter events by. + schema: + title: '' + type: integer + - in: query + name: cover + description: An ID of a cover letter to filter events by. + schema: + title: '' + type: integer responses: '200': description: '' @@ -280,64 +284,70 @@ paths: mapping: cover-created: '#/components/schemas/EventCoverCreated' patch-created: '#/components/schemas/EventPatchCreated' - patch-completed: '#/components/schemas/EventPatchCompleted' - patch-state-changed: '#/components/schemas/EventPatchStateChanged' - patch-delegated: '#/components/schemas/EventPatchDelegated' + patch-completed: > + '#/components/schemas/EventPatchCompleted' + patch-state-changed: > + '#/components/schemas/EventPatchStateChanged' + patch-delegated: > + '#/components/schemas/EventPatchDelegated' check-created: '#/components/schemas/EventCheckCreated' series-created: '#/components/schemas/EventSeriesCreated' - series-completed: '#/components/schemas/EventSeriesCompleted' + series-completed: > + '#/components/schemas/EventSeriesCompleted' tags: - - events + - events /api/{{ version_url }}patches/: get: description: List patches. operationId: patches_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - $ref: '#/components/parameters/BeforeFilter' - - $ref: '#/components/parameters/SinceFilter' - - in: query - name: project - description: 'An ID or linkname of a project to filter patches by.' - schema: - title: '' - type: string - - in: query - name: series - description: 'An ID of a series to filter patches by.' - schema: - title: '' - type: integer - - in: query - name: submitter - description: 'An ID or email address of a person to filter patches by.' - schema: - title: '' - type: string - - in: query - name: delegate - description: 'An ID or username of a user to filter patches by.' - schema: - title: '' - type: string - - in: query - name: state - description: 'A slug representation of a state to filter patches by.' - schema: - title: '' - type: string - - in: query - name: archived - description: 'Show only archived (`true`) or non-archived (`false`) patches.' - schema: - title: '' - type: string - enum: - - 'true' - - 'false' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/BeforeFilter' + - $ref: '#/components/parameters/SinceFilter' + - in: query + name: project + description: An ID or linkname of a project to filter patches by. + schema: + title: '' + type: string + - in: query + name: series + description: An ID of a series to filter patches by. + schema: + title: '' + type: integer + - in: query + name: submitter + description: > + An ID or email address of a person to filter patches by. + schema: + title: '' + type: string + - in: query + name: delegate + description: An ID or username of a user to filter patches by. + schema: + title: '' + type: string + - in: query + name: state + description: A slug representation of a state to filter patches by. + schema: + title: '' + type: string + - in: query + name: archived + description: > + Show only archived (`true`) or non-archived (`false`) patches. + schema: + title: '' + type: string + enum: + - 'true' + - 'false' responses: '200': description: '' @@ -351,19 +361,19 @@ paths: items: $ref: '#/components/schemas/PatchList' tags: - - patches + - patches /api/{{ version_url }}patches/{id}/: get: description: Show a patch. operationId: patches_read parameters: - - in: path - name: id - description: 'A unique integer value identifying this patch.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this patch. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -372,27 +382,27 @@ paths: schema: $ref: '#/components/schemas/PatchDetail' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - patches + - patches patch: description: Update a patch (partial). operationId: patches_partial_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this patch.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this patch. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/Patch' responses: @@ -403,39 +413,39 @@ paths: schema: $ref: '#/components/schemas/PatchDetail' '400': - description: 'Invalid Request' + description: Invalid Request content: application/json: schema: $ref: '#/components/schemas/ErrorPatchUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - patches + - patches put: description: Update a patch. operationId: patches_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this patch.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this patch. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/Patch' responses: @@ -446,41 +456,41 @@ paths: schema: $ref: '#/components/schemas/PatchDetail' '400': - description: 'Invalid Request' + description: Invalid Request content: application/json: schema: $ref: '#/components/schemas/ErrorPatchUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - patches + - patches /api/{{ version_url }}patches/{id}/comments/: get: description: List comments operationId: patch_comments_list parameters: - - in: path - name: id - description: 'A unique integer value identifying the parent patch.' - required: true - schema: - title: ID - type: integer - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' + - in: path + name: id + description: A unique integer value identifying the parent patch. + required: true + schema: + title: ID + type: integer + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' responses: '200': description: '' @@ -494,54 +504,54 @@ paths: items: $ref: '#/components/schemas/Comment' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - comments + - comments /api/{{ version_url }}patches/{patch_id}/checks/: get: description: List checks. operationId: checks_list parameters: - - in: path - name: patch_id - description: 'A unique integer value identifying the parent patch.' - required: true - schema: - title: Patch ID - type: integer - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - $ref: '#/components/parameters/BeforeFilter' - - $ref: '#/components/parameters/SinceFilter' - - in: query - name: user - description: 'An ID or username of a user to filter checks by.' - schema: - title: '' - type: string - - in: query - name: state - description: 'A check state to filter checks by.' - schema: - title: '' - type: string - enum: - - pending - - success - - warning - - fail - - in: query - name: context - description: 'A check context to filter checks by.' - schema: - title: '' - type: string + - in: path + name: patch_id + description: A unique integer value identifying the parent patch. + required: true + schema: + title: Patch ID + type: integer + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/BeforeFilter' + - $ref: '#/components/parameters/SinceFilter' + - in: query + name: user + description: An ID or username of a user to filter checks by. + schema: + title: '' + type: string + - in: query + name: state + description: A check state to filter checks by. + schema: + title: '' + type: string + enum: + - pending + - success + - warning + - fail + - in: query + name: context + description: A check context to filter checks by. + schema: + title: '' + type: string responses: '200': description: '' @@ -555,27 +565,27 @@ paths: items: $ref: '#/components/schemas/Check' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - checks + - checks post: description: Create a check. operationId: checks_create security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: patch_id - description: 'A unique integer value identifying the parent patch.' - required: true - schema: - title: Patch ID - type: integer + - in: path + name: patch_id + description: A unique integer value identifying the parent patch. + required: true + schema: + title: Patch ID + type: integer requestBody: $ref: '#/components/requestBodies/Check' responses: @@ -586,44 +596,44 @@ paths: schema: $ref: '#/components/schemas/Check' '400': - description: 'Invalid Request' + description: Invalid Request content: application/json: schema: $ref: '#/components/schemas/ErrorCheckCreate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - checks + - checks /api/{{ version_url }}patches/{patch_id}/checks/{check_id}/: get: description: Show a check. operationId: checks_read parameters: - - in: path - name: patch_id - description: 'A unique integer value identifying the parent patch.' - required: true - schema: - title: Patch ID - type: integer - - in: path - name: check_id - description: 'A unique integer value identifying this check.' - required: true - schema: - title: Check ID - type: integer + - in: path + name: patch_id + description: A unique integer value identifying the parent patch. + required: true + schema: + title: Patch ID + type: integer + - in: path + name: check_id + description: A unique integer value identifying this check. + required: true + schema: + title: Check ID + type: integer responses: '200': description: '' @@ -632,25 +642,25 @@ paths: schema: $ref: '#/components/schemas/Check' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - checks + - checks /api/{{ version_url }}people/: get: description: List people. operationId: people_list security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' responses: '200': description: '' @@ -664,28 +674,28 @@ paths: items: $ref: '#/components/schemas/Person' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - people + - people /api/{{ version_url }}people/{id}/: get: description: Show a person. operationId: people_read security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this person.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this person. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -694,28 +704,28 @@ paths: schema: $ref: '#/components/schemas/Person' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - people + - people /api/{{ version_url }}projects/: get: description: List projects. operationId: projects_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' responses: '200': description: '' @@ -729,19 +739,19 @@ paths: items: $ref: '#/components/schemas/Project' tags: - - projects + - projects /api/{{ version_url }}projects/{id}/: get: description: Show a project. operationId: projects_read parameters: - - in: path - name: id - description: 'A unique integer value identifying this project.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this project. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -750,27 +760,27 @@ paths: schema: $ref: '#/components/schemas/Project' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - projects + - projects patch: description: Update a project (partial). operationId: projects_partial_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this project.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this project. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/Project' responses: @@ -781,39 +791,39 @@ paths: schema: $ref: '#/components/schemas/Project' '400': - description: 'Bad request' + description: Bad request content: application/json: schema: $ref: '#/components/schemas/ErrorProjectUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - projects + - projects put: description: Update a project. operationId: projects_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this project.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this project. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/Project' responses: @@ -824,48 +834,48 @@ paths: schema: $ref: '#/components/schemas/Project' '400': - description: 'Bad request' + description: Bad request content: application/json: schema: $ref: '#/components/schemas/ErrorProjectUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - projects + - projects /api/{{ version_url }}series/: get: description: List series. operationId: series_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - $ref: '#/components/parameters/BeforeFilter' - - $ref: '#/components/parameters/SinceFilter' - - in: query - name: submitter - description: 'An ID or email address of a person to filter series by.' - schema: - title: '' - type: string - - in: query - name: project - description: 'An ID or linkname of a project to filter series by.' - schema: - title: '' - type: string + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/BeforeFilter' + - $ref: '#/components/parameters/SinceFilter' + - in: query + name: submitter + description: An ID or email address of a person to filter series by. + schema: + title: '' + type: string + - in: query + name: project + description: An ID or linkname of a project to filter series by. + schema: + title: '' + type: string responses: '200': description: '' @@ -879,19 +889,19 @@ paths: items: $ref: '#/components/schemas/Series' tags: - - series + - series /api/{{ version_url }}series/{id}/: get: description: Show a series. operationId: series_read parameters: - - in: path - name: id - description: 'A unique integer value identifying this series.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this series. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -900,25 +910,25 @@ paths: schema: $ref: '#/components/schemas/Series' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - series + - series /api/{{ version_url }}users/: get: description: List users. operationId: users_list security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' responses: '200': description: '' @@ -932,28 +942,28 @@ paths: items: $ref: '#/components/schemas/User' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - users + - users /api/{{ version_url }}users/{id}/: get: description: Show a user. operationId: users_read security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this user.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this user. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -962,33 +972,33 @@ paths: schema: $ref: '#/components/schemas/User' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - users + - users patch: description: Update a user (partial). operationId: users_partial_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this user.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this user. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/User' responses: @@ -999,39 +1009,39 @@ paths: schema: $ref: '#/components/schemas/User' '400': - description: 'Bad request' + description: Bad request content: application/json: schema: $ref: '#/components/schemas/ErrorUserUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - users + - users put: description: Update a user. operationId: users_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this user.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this user. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/User' responses: @@ -1042,25 +1052,25 @@ paths: schema: $ref: '#/components/schemas/User' '400': - description: 'Bad request' + description: Bad request content: application/json: schema: $ref: '#/components/schemas/ErrorUserUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - users + - users components: securitySchemes: basicAuth: @@ -1073,48 +1083,48 @@ components: Page: in: query name: page - description: 'A page number within the paginated result set.' + description: A page number within the paginated result set. schema: title: Page type: integer PageSize: in: query name: per_page - description: 'Number of results to return per page.' + description: Number of results to return per page. schema: title: Page size type: integer Order: in: query name: order - description: 'Which field to use when ordering the results.' + description: Which field to use when ordering the results. schema: title: Ordering type: string Search: in: query name: q - description: 'A search term.' + description: A search term. schema: title: Search type: string BeforeFilter: in: query name: before - description: 'Latest date-time to retrieve results for.' + description: Latest date-time to retrieve results for. schema: title: '' type: string SinceFilter: in: query name: since - description: 'Earliest date-time to retrieve results for.' + description: Earliest date-time to retrieve results for. schema: title: '' type: string headers: Link: - description: | + description: > Links to related resources, in the format defined by [RFC 5988](https://tools.ietf.org/html/rfc5988#section-5). This will include a link with relation type `next` to the @@ -1242,7 +1252,7 @@ components: title: Owner readOnly: true allOf: - - $ref: '#/components/schemas/UserEmbedded' + - $ref: '#/components/schemas/UserEmbedded' patches: type: array items: @@ -1281,21 +1291,23 @@ components: description: The state of the check. type: string enum: - - pending - - success - - warning - - fail + - pending + - success + - warning + - fail target_url: title: Target URL - description: The target URL to associate with this check. This should be specific - to the patch. + description: > + The target URL to associate with this check. This should be + specific to the patch. type: string format: uri maxLength: 200 nullable: true context: title: Context - description: A label to discern check from checks of other testing systems. + description: > + A label to discern check from checks of other testing systems. type: string pattern: ^[-a-zA-Z0-9_]+$ minLength: 1 @@ -1313,21 +1325,23 @@ components: description: The state of the check. type: string enum: - - pending - - success - - warning - - fail + - pending + - success + - warning + - fail target_url: title: Target URL - description: The target URL to associate with this check. This should be specific - to the patch. + description: + The target URL to associate with this check. This should be + specific to the patch. type: string format: uri maxLength: 200 nullable: true context: title: Context - description: A label to discern check from checks of other testing systems. + description: > + A label to discern check from checks of other testing systems. type: string pattern: ^[-a-zA-Z0-9_]+$ minLength: 1 @@ -1370,7 +1384,7 @@ components: type: object title: Submitter allOf: - - $ref: '#/components/schemas/PersonEmbedded' + - $ref: '#/components/schemas/PersonEmbedded' content: title: Content type: string @@ -1425,7 +1439,7 @@ components: title: Submitter readOnly: true allOf: - - $ref: '#/components/schemas/PersonEmbedded' + - $ref: '#/components/schemas/PersonEmbedded' {% if version > (1, 0) %} mbox: title: Mbox @@ -1447,19 +1461,19 @@ components: {% endif %} CoverLetterDetail: allOf: - - $ref: '#/components/schemas/CoverLetterList' - - properties: - headers: - title: Headers - type: array - items: + - $ref: '#/components/schemas/CoverLetterList' + - properties: + headers: + title: Headers + type: array + items: + type: string + readOnly: true + content: + title: Content type: string - readOnly: true - content: - title: Content - type: string - readOnly: true - minLength: 1 + readOnly: true + minLength: 1 EventBase: type: object properties: @@ -1484,120 +1498,120 @@ components: type: object EventCoverCreated: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - cover-created - payload: - properties: - cover: - title: Cover - type: string - readOnly: true + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - cover-created + payload: + properties: + cover: + title: Cover + type: string + readOnly: true EventPatchCreated: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - patch-created - payload: - properties: - patch: - $ref: '#/components/schemas/PatchEmbedded' + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - patch-created + payload: + properties: + patch: + $ref: '#/components/schemas/PatchEmbedded' EventPatchCompleted: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - patch-completed - payload: - properties: - patch: - $ref: '#/components/schemas/PatchEmbedded' - series: - $ref: '#/components/schemas/SeriesEmbedded' + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - patch-completed + payload: + properties: + patch: + $ref: '#/components/schemas/PatchEmbedded' + series: + $ref: '#/components/schemas/SeriesEmbedded' EventPatchStateChanged: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - patch-state-changed - payload: - properties: - patch: - $ref: '#/components/schemas/PatchEmbedded' - previous_state: - title: Previous state - type: string - current_state: - title: Current state - type: string + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - patch-state-changed + payload: + properties: + patch: + $ref: '#/components/schemas/PatchEmbedded' + previous_state: + title: Previous state + type: string + current_state: + title: Current state + type: string EventPatchDelegated: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - patch-delegated - payload: - properties: - patch: - $ref: '#/components/schemas/PatchEmbedded' - previous_delegate: - allOf: - - $ref: '#/components/schemas/UserEmbedded' - - title: Previous delegate - current_delegate: - allOf: - - $ref: '#/components/schemas/UserEmbedded' - - title: Current delegate + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - patch-delegated + payload: + properties: + patch: + $ref: '#/components/schemas/PatchEmbedded' + previous_delegate: + allOf: + - $ref: '#/components/schemas/UserEmbedded' + - title: Previous delegate + current_delegate: + allOf: + - $ref: '#/components/schemas/UserEmbedded' + - title: Current delegate EventCheckCreated: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - check-created - payload: - properties: - patch: - $ref: '#/components/schemas/PatchEmbedded' - check: - $ref: '#/components/schemas/CheckEmbedded' + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - check-created + payload: + properties: + patch: + $ref: '#/components/schemas/PatchEmbedded' + check: + $ref: '#/components/schemas/CheckEmbedded' EventSeriesCreated: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - series-created - payload: - properties: - series: - $ref: '#/components/schemas/SeriesEmbedded' + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - series-created + payload: + properties: + series: + $ref: '#/components/schemas/SeriesEmbedded' EventSeriesCompleted: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - series-completed - payload: - properties: - series: - $ref: '#/components/schemas/SeriesEmbedded' + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - series-completed + payload: + properties: + series: + $ref: '#/components/schemas/SeriesEmbedded' PatchList: required: - state @@ -1666,14 +1680,14 @@ components: title: Submitter readOnly: true allOf: - - $ref: '#/components/schemas/PersonEmbedded' + - $ref: '#/components/schemas/PersonEmbedded' delegate: type: object title: Delegate nullable: true readOnly: true allOf: - - $ref: '#/components/schemas/UserEmbedded' + - $ref: '#/components/schemas/UserEmbedded' mbox: title: Mbox type: string @@ -1696,10 +1710,10 @@ components: type: string readOnly: true enum: - - pending - - success - - warning - - fail + - pending + - success + - warning + - fail checks: title: Checks type: string @@ -1713,30 +1727,30 @@ components: readOnly: true PatchDetail: allOf: - - $ref: '#/components/schemas/PatchList' - - properties: - headers: - title: Headers - type: array - items: + - $ref: '#/components/schemas/PatchList' + - properties: + headers: + title: Headers + type: array + items: + type: string + readOnly: true + content: + title: Content type: string - readOnly: true - content: - title: Content - type: string - readOnly: true - minLength: 1 - diff: - title: Diff - type: string - readOnly: true - minLength: 1 - prefixes: - title: Prefixes - type: array - items: + readOnly: true + minLength: 1 + diff: + title: Diff type: string - readOnly: true + readOnly: true + minLength: 1 + prefixes: + title: Prefixes + type: array + items: + type: string + readOnly: true PatchUpdate: type: object properties: @@ -1792,7 +1806,7 @@ components: nullable: true readOnly: true allOf: - - $ref: '#/components/schemas/UserEmbedded' + - $ref: '#/components/schemas/UserEmbedded' Project: type: object properties: @@ -1854,11 +1868,12 @@ components: {% if version > (1, 0) %} subject_match: title: Subject match - description: Regex to match the subject against if only part of emails - sent to the list belongs to this project. Will be used with - IGNORECASE and MULTILINE flags. If rules for more projects match the - first one returned from DB is chosen; empty field serves as a - default for every email which has no other match. + description: > + Regex to match the subject against if only part of emails sent to + the list belongs to this project. Will be used with IGNORECASE and + MULTILINE flags. If rules for more projects match the first one + returned from DB is chosen; empty field serves as a default for + every email which has no other match. type: string readOnly: true maxLength: 64 @@ -1886,7 +1901,8 @@ components: $ref: '#/components/schemas/ProjectEmbedded' name: title: Name - description: An optional name to associate with the series, e.g. "John's PCI + description: > + An optional name to associate with the series, e.g. "John's PCI series". type: string maxLength: 255 @@ -1901,14 +1917,16 @@ components: title: Submitter readOnly: true allOf: - - $ref: '#/components/schemas/PersonEmbedded' + - $ref: '#/components/schemas/PersonEmbedded' version: title: Version - description: Version of series as indicated by the subject prefix(es) + description: > + Version of series as indicated by the subject prefix(es). type: integer total: title: Total - description: Number of patches in series as indicated by the subject prefix(es) + description: > + Number of patches in series as indicated by the subject prefix(es). type: integer readOnly: true received_total: @@ -1987,13 +2005,14 @@ components: type: string readOnly: true enum: - - pending - - success - - warning - - fail + - pending + - success + - warning + - fail target_url: title: Target url - description: The target URL to associate with this check. This should be specific + description: > + The target URL to associate with this check. This should be specific to the patch. type: string format: uri @@ -2002,7 +2021,8 @@ components: readOnly: true context: title: Context - description: A label to discern check from checks of other testing systems. + description: > + A label to discern check from checks of other testing systems. type: string pattern: ^[-a-zA-Z0-9_]+$ maxLength: 255 @@ -2184,7 +2204,8 @@ components: {% endif %} name: title: Name - description: An optional name to associate with the series, e.g. "John's PCI + description: > + An optional name to associate with the series, e.g. "John's PCI series". type: string readOnly: true @@ -2197,7 +2218,8 @@ components: readOnly: true version: title: Version - description: Version of series as indicated by the subject prefix(es) + description: > + Version of series as indicated by the subject prefix(es). type: integer readOnly: true mbox: diff --git a/docs/api/schemas/v1.0/patchwork.yaml b/docs/api/schemas/v1.0/patchwork.yaml index ea519de..11e3ae3 100644 --- a/docs/api/schemas/v1.0/patchwork.yaml +++ b/docs/api/schemas/v1.0/patchwork.yaml @@ -1,9 +1,10 @@ # DO NOT EDIT THIS FILE. It is generated from a template. Changes should be # proposed against the template. +--- openapi: '3.0.0' info: title: Patchwork API - description: | + description: > Patchwork is a web-based patch tracking system designed to facilitate the contribution and management of contributions to an open-source project. contact: @@ -26,37 +27,37 @@ paths: schema: $ref: '#/components/schemas/Index' tags: - - api + - api /api/1.0/bundles/: get: description: List bundles. operationId: bundles_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - in: query - name: project - description: 'An ID or linkname of a project to filter bundles by.' - schema: - title: '' - type: string - - in: query - name: owner - description: 'An ID or username of a user to filter bundles by.' - schema: - title: '' - type: string - - in: query - name: public - description: 'Show only public (`true`) or private (`false`) bundles.' - schema: - title: '' - type: string - enum: - - 'true' - - 'false' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - in: query + name: project + description: An ID or linkname of a project to filter bundles by. + schema: + title: '' + type: string + - in: query + name: owner + description: An ID or username of a user to filter bundles by. + schema: + title: '' + type: string + - in: query + name: public + description: Show only public (`true`) or private (`false`) bundles. + schema: + title: '' + type: string + enum: + - 'true' + - 'false' responses: '200': description: '' @@ -70,19 +71,19 @@ paths: items: $ref: '#/components/schemas/Bundle' tags: - - bundles + - bundles /api/1.0/bundles/{id}/: get: description: Show a bundle. operationId: bundles_read parameters: - - in: path - name: id - required: true - description: 'A unique integer value identifying this bundle.' - schema: - title: ID - type: integer + - in: path + name: id + required: true + description: A unique integer value identifying this bundle. + schema: + title: ID + type: integer responses: '200': description: '' @@ -91,42 +92,44 @@ paths: schema: $ref: '#/components/schemas/Bundle' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - bundles + - bundles /api/1.0/covers/: get: description: List cover letters. operationId: covers_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - $ref: '#/components/parameters/BeforeFilter' - - $ref: '#/components/parameters/SinceFilter' - - in: query - name: project - description: 'An ID or linkname of a project to filter cover letters by.' - schema: - title: '' - type: string - - in: query - name: series - description: 'An ID of a series to filter cover letters by.' - schema: - title: '' - type: string - - in: query - name: submitter - description: 'An ID or email address of a person to filter cover letters by.' - schema: - title: '' - type: string + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/BeforeFilter' + - $ref: '#/components/parameters/SinceFilter' + - in: query + name: project + description: > + An ID or linkname of a project to filter cover letters by. + schema: + title: '' + type: string + - in: query + name: series + description: An ID of a series to filter cover letters by. + schema: + title: '' + type: string + - in: query + name: submitter + description: > + An ID or email address of a person to filter cover letters by. + schema: + title: '' + type: string responses: '200': description: '' @@ -140,19 +143,19 @@ paths: items: $ref: '#/components/schemas/CoverLetterList' tags: - - covers + - covers /api/1.0/covers/{id}/: get: description: Show a cover letter. operationId: covers_read parameters: - - in: path - name: id - description: 'A unique integer value identifying this cover letter.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this cover letter. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -161,29 +164,30 @@ paths: schema: $ref: '#/components/schemas/CoverLetterDetail' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - covers + - covers /api/1.0/covers/{id}/comments/: get: description: List comments operationId: cover_comments_list parameters: - - in: path - name: id - description: 'A unique integer value identifying the parent cover letter.' - required: true - schema: - title: ID - type: integer - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' + - in: path + name: id + description: > + A unique integer value identifying the parent cover letter. + required: true + schema: + title: ID + type: integer + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' responses: '200': description: '' @@ -197,63 +201,63 @@ paths: items: $ref: '#/components/schemas/Comment' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - comments + - comments /api/1.0/events/: get: description: List events. operationId: events_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - $ref: '#/components/parameters/BeforeFilter' - - $ref: '#/components/parameters/SinceFilter' - - in: query - name: project - description: 'An ID or linkname of a project to filter events by.' - schema: - title: '' - type: string - - in: query - name: category - description: 'An event category to filter events by.' - schema: - title: '' - type: string - enum: - - cover-created - - patch-created - - patch-completed - - patch-state-changed - - patch-delegated - - check-created - - series-created - - series-completed - - in: query - name: series - description: 'An ID of a series to filter events by.' - schema: - title: '' - type: integer - - in: query - name: patch - description: 'An ID of a patch to filter events by.' - schema: - title: '' - type: integer - - in: query - name: cover - description: 'An ID of a cover letter to filter events by.' - schema: - title: '' - type: integer + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/BeforeFilter' + - $ref: '#/components/parameters/SinceFilter' + - in: query + name: project + description: An ID or linkname of a project to filter events by. + schema: + title: '' + type: string + - in: query + name: category + description: An event category to filter events by. + schema: + title: '' + type: string + enum: + - cover-created + - patch-created + - patch-completed + - patch-state-changed + - patch-delegated + - check-created + - series-created + - series-completed + - in: query + name: series + description: An ID of a series to filter events by. + schema: + title: '' + type: integer + - in: query + name: patch + description: An ID of a patch to filter events by. + schema: + title: '' + type: integer + - in: query + name: cover + description: An ID of a cover letter to filter events by. + schema: + title: '' + type: integer responses: '200': description: '' @@ -279,64 +283,70 @@ paths: mapping: cover-created: '#/components/schemas/EventCoverCreated' patch-created: '#/components/schemas/EventPatchCreated' - patch-completed: '#/components/schemas/EventPatchCompleted' - patch-state-changed: '#/components/schemas/EventPatchStateChanged' - patch-delegated: '#/components/schemas/EventPatchDelegated' + patch-completed: > + '#/components/schemas/EventPatchCompleted' + patch-state-changed: > + '#/components/schemas/EventPatchStateChanged' + patch-delegated: > + '#/components/schemas/EventPatchDelegated' check-created: '#/components/schemas/EventCheckCreated' series-created: '#/components/schemas/EventSeriesCreated' - series-completed: '#/components/schemas/EventSeriesCompleted' + series-completed: > + '#/components/schemas/EventSeriesCompleted' tags: - - events + - events /api/1.0/patches/: get: description: List patches. operationId: patches_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - $ref: '#/components/parameters/BeforeFilter' - - $ref: '#/components/parameters/SinceFilter' - - in: query - name: project - description: 'An ID or linkname of a project to filter patches by.' - schema: - title: '' - type: string - - in: query - name: series - description: 'An ID of a series to filter patches by.' - schema: - title: '' - type: integer - - in: query - name: submitter - description: 'An ID or email address of a person to filter patches by.' - schema: - title: '' - type: string - - in: query - name: delegate - description: 'An ID or username of a user to filter patches by.' - schema: - title: '' - type: string - - in: query - name: state - description: 'A slug representation of a state to filter patches by.' - schema: - title: '' - type: string - - in: query - name: archived - description: 'Show only archived (`true`) or non-archived (`false`) patches.' - schema: - title: '' - type: string - enum: - - 'true' - - 'false' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/BeforeFilter' + - $ref: '#/components/parameters/SinceFilter' + - in: query + name: project + description: An ID or linkname of a project to filter patches by. + schema: + title: '' + type: string + - in: query + name: series + description: An ID of a series to filter patches by. + schema: + title: '' + type: integer + - in: query + name: submitter + description: > + An ID or email address of a person to filter patches by. + schema: + title: '' + type: string + - in: query + name: delegate + description: An ID or username of a user to filter patches by. + schema: + title: '' + type: string + - in: query + name: state + description: A slug representation of a state to filter patches by. + schema: + title: '' + type: string + - in: query + name: archived + description: > + Show only archived (`true`) or non-archived (`false`) patches. + schema: + title: '' + type: string + enum: + - 'true' + - 'false' responses: '200': description: '' @@ -350,19 +360,19 @@ paths: items: $ref: '#/components/schemas/PatchList' tags: - - patches + - patches /api/1.0/patches/{id}/: get: description: Show a patch. operationId: patches_read parameters: - - in: path - name: id - description: 'A unique integer value identifying this patch.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this patch. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -371,27 +381,27 @@ paths: schema: $ref: '#/components/schemas/PatchDetail' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - patches + - patches patch: description: Update a patch (partial). operationId: patches_partial_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this patch.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this patch. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/Patch' responses: @@ -402,39 +412,39 @@ paths: schema: $ref: '#/components/schemas/PatchDetail' '400': - description: 'Invalid Request' + description: Invalid Request content: application/json: schema: $ref: '#/components/schemas/ErrorPatchUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - patches + - patches put: description: Update a patch. operationId: patches_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this patch.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this patch. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/Patch' responses: @@ -445,41 +455,41 @@ paths: schema: $ref: '#/components/schemas/PatchDetail' '400': - description: 'Invalid Request' + description: Invalid Request content: application/json: schema: $ref: '#/components/schemas/ErrorPatchUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - patches + - patches /api/1.0/patches/{id}/comments/: get: description: List comments operationId: patch_comments_list parameters: - - in: path - name: id - description: 'A unique integer value identifying the parent patch.' - required: true - schema: - title: ID - type: integer - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' + - in: path + name: id + description: A unique integer value identifying the parent patch. + required: true + schema: + title: ID + type: integer + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' responses: '200': description: '' @@ -493,54 +503,54 @@ paths: items: $ref: '#/components/schemas/Comment' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - comments + - comments /api/1.0/patches/{patch_id}/checks/: get: description: List checks. operationId: checks_list parameters: - - in: path - name: patch_id - description: 'A unique integer value identifying the parent patch.' - required: true - schema: - title: Patch ID - type: integer - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - $ref: '#/components/parameters/BeforeFilter' - - $ref: '#/components/parameters/SinceFilter' - - in: query - name: user - description: 'An ID or username of a user to filter checks by.' - schema: - title: '' - type: string - - in: query - name: state - description: 'A check state to filter checks by.' - schema: - title: '' - type: string - enum: - - pending - - success - - warning - - fail - - in: query - name: context - description: 'A check context to filter checks by.' - schema: - title: '' - type: string + - in: path + name: patch_id + description: A unique integer value identifying the parent patch. + required: true + schema: + title: Patch ID + type: integer + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/BeforeFilter' + - $ref: '#/components/parameters/SinceFilter' + - in: query + name: user + description: An ID or username of a user to filter checks by. + schema: + title: '' + type: string + - in: query + name: state + description: A check state to filter checks by. + schema: + title: '' + type: string + enum: + - pending + - success + - warning + - fail + - in: query + name: context + description: A check context to filter checks by. + schema: + title: '' + type: string responses: '200': description: '' @@ -554,27 +564,27 @@ paths: items: $ref: '#/components/schemas/Check' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - checks + - checks post: description: Create a check. operationId: checks_create security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: patch_id - description: 'A unique integer value identifying the parent patch.' - required: true - schema: - title: Patch ID - type: integer + - in: path + name: patch_id + description: A unique integer value identifying the parent patch. + required: true + schema: + title: Patch ID + type: integer requestBody: $ref: '#/components/requestBodies/Check' responses: @@ -585,44 +595,44 @@ paths: schema: $ref: '#/components/schemas/Check' '400': - description: 'Invalid Request' + description: Invalid Request content: application/json: schema: $ref: '#/components/schemas/ErrorCheckCreate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - checks + - checks /api/1.0/patches/{patch_id}/checks/{check_id}/: get: description: Show a check. operationId: checks_read parameters: - - in: path - name: patch_id - description: 'A unique integer value identifying the parent patch.' - required: true - schema: - title: Patch ID - type: integer - - in: path - name: check_id - description: 'A unique integer value identifying this check.' - required: true - schema: - title: Check ID - type: integer + - in: path + name: patch_id + description: A unique integer value identifying the parent patch. + required: true + schema: + title: Patch ID + type: integer + - in: path + name: check_id + description: A unique integer value identifying this check. + required: true + schema: + title: Check ID + type: integer responses: '200': description: '' @@ -631,25 +641,25 @@ paths: schema: $ref: '#/components/schemas/Check' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - checks + - checks /api/1.0/people/: get: description: List people. operationId: people_list security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' responses: '200': description: '' @@ -663,28 +673,28 @@ paths: items: $ref: '#/components/schemas/Person' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - people + - people /api/1.0/people/{id}/: get: description: Show a person. operationId: people_read security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this person.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this person. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -693,28 +703,28 @@ paths: schema: $ref: '#/components/schemas/Person' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - people + - people /api/1.0/projects/: get: description: List projects. operationId: projects_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' responses: '200': description: '' @@ -728,19 +738,19 @@ paths: items: $ref: '#/components/schemas/Project' tags: - - projects + - projects /api/1.0/projects/{id}/: get: description: Show a project. operationId: projects_read parameters: - - in: path - name: id - description: 'A unique integer value identifying this project.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this project. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -749,27 +759,27 @@ paths: schema: $ref: '#/components/schemas/Project' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - projects + - projects patch: description: Update a project (partial). operationId: projects_partial_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this project.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this project. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/Project' responses: @@ -780,39 +790,39 @@ paths: schema: $ref: '#/components/schemas/Project' '400': - description: 'Bad request' + description: Bad request content: application/json: schema: $ref: '#/components/schemas/ErrorProjectUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - projects + - projects put: description: Update a project. operationId: projects_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this project.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this project. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/Project' responses: @@ -823,48 +833,48 @@ paths: schema: $ref: '#/components/schemas/Project' '400': - description: 'Bad request' + description: Bad request content: application/json: schema: $ref: '#/components/schemas/ErrorProjectUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - projects + - projects /api/1.0/series/: get: description: List series. operationId: series_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - $ref: '#/components/parameters/BeforeFilter' - - $ref: '#/components/parameters/SinceFilter' - - in: query - name: submitter - description: 'An ID or email address of a person to filter series by.' - schema: - title: '' - type: string - - in: query - name: project - description: 'An ID or linkname of a project to filter series by.' - schema: - title: '' - type: string + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/BeforeFilter' + - $ref: '#/components/parameters/SinceFilter' + - in: query + name: submitter + description: An ID or email address of a person to filter series by. + schema: + title: '' + type: string + - in: query + name: project + description: An ID or linkname of a project to filter series by. + schema: + title: '' + type: string responses: '200': description: '' @@ -878,19 +888,19 @@ paths: items: $ref: '#/components/schemas/Series' tags: - - series + - series /api/1.0/series/{id}/: get: description: Show a series. operationId: series_read parameters: - - in: path - name: id - description: 'A unique integer value identifying this series.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this series. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -899,25 +909,25 @@ paths: schema: $ref: '#/components/schemas/Series' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - series + - series /api/1.0/users/: get: description: List users. operationId: users_list security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' responses: '200': description: '' @@ -931,28 +941,28 @@ paths: items: $ref: '#/components/schemas/User' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - users + - users /api/1.0/users/{id}/: get: description: Show a user. operationId: users_read security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this user.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this user. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -961,33 +971,33 @@ paths: schema: $ref: '#/components/schemas/User' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - users + - users patch: description: Update a user (partial). operationId: users_partial_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this user.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this user. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/User' responses: @@ -998,39 +1008,39 @@ paths: schema: $ref: '#/components/schemas/User' '400': - description: 'Bad request' + description: Bad request content: application/json: schema: $ref: '#/components/schemas/ErrorUserUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - users + - users put: description: Update a user. operationId: users_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this user.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this user. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/User' responses: @@ -1041,25 +1051,25 @@ paths: schema: $ref: '#/components/schemas/User' '400': - description: 'Bad request' + description: Bad request content: application/json: schema: $ref: '#/components/schemas/ErrorUserUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - users + - users components: securitySchemes: basicAuth: @@ -1072,48 +1082,48 @@ components: Page: in: query name: page - description: 'A page number within the paginated result set.' + description: A page number within the paginated result set. schema: title: Page type: integer PageSize: in: query name: per_page - description: 'Number of results to return per page.' + description: Number of results to return per page. schema: title: Page size type: integer Order: in: query name: order - description: 'Which field to use when ordering the results.' + description: Which field to use when ordering the results. schema: title: Ordering type: string Search: in: query name: q - description: 'A search term.' + description: A search term. schema: title: Search type: string BeforeFilter: in: query name: before - description: 'Latest date-time to retrieve results for.' + description: Latest date-time to retrieve results for. schema: title: '' type: string SinceFilter: in: query name: since - description: 'Earliest date-time to retrieve results for.' + description: Earliest date-time to retrieve results for. schema: title: '' type: string headers: Link: - description: | + description: > Links to related resources, in the format defined by [RFC 5988](https://tools.ietf.org/html/rfc5988#section-5). This will include a link with relation type `next` to the @@ -1234,7 +1244,7 @@ components: title: Owner readOnly: true allOf: - - $ref: '#/components/schemas/UserEmbedded' + - $ref: '#/components/schemas/UserEmbedded' patches: type: array items: @@ -1273,21 +1283,23 @@ components: description: The state of the check. type: string enum: - - pending - - success - - warning - - fail + - pending + - success + - warning + - fail target_url: title: Target URL - description: The target URL to associate with this check. This should be specific - to the patch. + description: > + The target URL to associate with this check. This should be + specific to the patch. type: string format: uri maxLength: 200 nullable: true context: title: Context - description: A label to discern check from checks of other testing systems. + description: > + A label to discern check from checks of other testing systems. type: string pattern: ^[-a-zA-Z0-9_]+$ minLength: 1 @@ -1305,21 +1317,23 @@ components: description: The state of the check. type: string enum: - - pending - - success - - warning - - fail + - pending + - success + - warning + - fail target_url: title: Target URL - description: The target URL to associate with this check. This should be specific - to the patch. + description: + The target URL to associate with this check. This should be + specific to the patch. type: string format: uri maxLength: 200 nullable: true context: title: Context - description: A label to discern check from checks of other testing systems. + description: > + A label to discern check from checks of other testing systems. type: string pattern: ^[-a-zA-Z0-9_]+$ minLength: 1 @@ -1355,7 +1369,7 @@ components: type: object title: Submitter allOf: - - $ref: '#/components/schemas/PersonEmbedded' + - $ref: '#/components/schemas/PersonEmbedded' content: title: Content type: string @@ -1403,7 +1417,7 @@ components: title: Submitter readOnly: true allOf: - - $ref: '#/components/schemas/PersonEmbedded' + - $ref: '#/components/schemas/PersonEmbedded' series: type: array items: @@ -1411,19 +1425,19 @@ components: readOnly: true CoverLetterDetail: allOf: - - $ref: '#/components/schemas/CoverLetterList' - - properties: - headers: - title: Headers - type: array - items: + - $ref: '#/components/schemas/CoverLetterList' + - properties: + headers: + title: Headers + type: array + items: + type: string + readOnly: true + content: + title: Content type: string - readOnly: true - content: - title: Content - type: string - readOnly: true - minLength: 1 + readOnly: true + minLength: 1 EventBase: type: object properties: @@ -1448,120 +1462,120 @@ components: type: object EventCoverCreated: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - cover-created - payload: - properties: - cover: - title: Cover - type: string - readOnly: true + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - cover-created + payload: + properties: + cover: + title: Cover + type: string + readOnly: true EventPatchCreated: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - patch-created - payload: - properties: - patch: - $ref: '#/components/schemas/PatchEmbedded' + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - patch-created + payload: + properties: + patch: + $ref: '#/components/schemas/PatchEmbedded' EventPatchCompleted: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - patch-completed - payload: - properties: - patch: - $ref: '#/components/schemas/PatchEmbedded' - series: - $ref: '#/components/schemas/SeriesEmbedded' + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - patch-completed + payload: + properties: + patch: + $ref: '#/components/schemas/PatchEmbedded' + series: + $ref: '#/components/schemas/SeriesEmbedded' EventPatchStateChanged: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - patch-state-changed - payload: - properties: - patch: - $ref: '#/components/schemas/PatchEmbedded' - previous_state: - title: Previous state - type: string - current_state: - title: Current state - type: string + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - patch-state-changed + payload: + properties: + patch: + $ref: '#/components/schemas/PatchEmbedded' + previous_state: + title: Previous state + type: string + current_state: + title: Current state + type: string EventPatchDelegated: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - patch-delegated - payload: - properties: - patch: - $ref: '#/components/schemas/PatchEmbedded' - previous_delegate: - allOf: - - $ref: '#/components/schemas/UserEmbedded' - - title: Previous delegate - current_delegate: - allOf: - - $ref: '#/components/schemas/UserEmbedded' - - title: Current delegate + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - patch-delegated + payload: + properties: + patch: + $ref: '#/components/schemas/PatchEmbedded' + previous_delegate: + allOf: + - $ref: '#/components/schemas/UserEmbedded' + - title: Previous delegate + current_delegate: + allOf: + - $ref: '#/components/schemas/UserEmbedded' + - title: Current delegate EventCheckCreated: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - check-created - payload: - properties: - patch: - $ref: '#/components/schemas/PatchEmbedded' - check: - $ref: '#/components/schemas/CheckEmbedded' + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - check-created + payload: + properties: + patch: + $ref: '#/components/schemas/PatchEmbedded' + check: + $ref: '#/components/schemas/CheckEmbedded' EventSeriesCreated: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - series-created - payload: - properties: - series: - $ref: '#/components/schemas/SeriesEmbedded' + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - series-created + payload: + properties: + series: + $ref: '#/components/schemas/SeriesEmbedded' EventSeriesCompleted: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - series-completed - payload: - properties: - series: - $ref: '#/components/schemas/SeriesEmbedded' + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - series-completed + payload: + properties: + series: + $ref: '#/components/schemas/SeriesEmbedded' PatchList: required: - state @@ -1623,14 +1637,14 @@ components: title: Submitter readOnly: true allOf: - - $ref: '#/components/schemas/PersonEmbedded' + - $ref: '#/components/schemas/PersonEmbedded' delegate: type: object title: Delegate nullable: true readOnly: true allOf: - - $ref: '#/components/schemas/UserEmbedded' + - $ref: '#/components/schemas/UserEmbedded' mbox: title: Mbox type: string @@ -1646,10 +1660,10 @@ components: type: string readOnly: true enum: - - pending - - success - - warning - - fail + - pending + - success + - warning + - fail checks: title: Checks type: string @@ -1663,30 +1677,30 @@ components: readOnly: true PatchDetail: allOf: - - $ref: '#/components/schemas/PatchList' - - properties: - headers: - title: Headers - type: array - items: + - $ref: '#/components/schemas/PatchList' + - properties: + headers: + title: Headers + type: array + items: + type: string + readOnly: true + content: + title: Content type: string - readOnly: true - content: - title: Content - type: string - readOnly: true - minLength: 1 - diff: - title: Diff - type: string - readOnly: true - minLength: 1 - prefixes: - title: Prefixes - type: array - items: + readOnly: true + minLength: 1 + diff: + title: Diff type: string - readOnly: true + readOnly: true + minLength: 1 + prefixes: + title: Prefixes + type: array + items: + type: string + readOnly: true PatchUpdate: type: object properties: @@ -1742,7 +1756,7 @@ components: nullable: true readOnly: true allOf: - - $ref: '#/components/schemas/UserEmbedded' + - $ref: '#/components/schemas/UserEmbedded' Project: type: object properties: @@ -1817,7 +1831,8 @@ components: $ref: '#/components/schemas/ProjectEmbedded' name: title: Name - description: An optional name to associate with the series, e.g. "John's PCI + description: > + An optional name to associate with the series, e.g. "John's PCI series". type: string maxLength: 255 @@ -1832,14 +1847,16 @@ components: title: Submitter readOnly: true allOf: - - $ref: '#/components/schemas/PersonEmbedded' + - $ref: '#/components/schemas/PersonEmbedded' version: title: Version - description: Version of series as indicated by the subject prefix(es) + description: > + Version of series as indicated by the subject prefix(es). type: integer total: title: Total - description: Number of patches in series as indicated by the subject prefix(es) + description: > + Number of patches in series as indicated by the subject prefix(es). type: integer readOnly: true received_total: @@ -1918,13 +1935,14 @@ components: type: string readOnly: true enum: - - pending - - success - - warning - - fail + - pending + - success + - warning + - fail target_url: title: Target url - description: The target URL to associate with this check. This should be specific + description: > + The target URL to associate with this check. This should be specific to the patch. type: string format: uri @@ -1933,7 +1951,8 @@ components: readOnly: true context: title: Context - description: A label to discern check from checks of other testing systems. + description: > + A label to discern check from checks of other testing systems. type: string pattern: ^[-a-zA-Z0-9_]+$ maxLength: 255 @@ -2094,7 +2113,8 @@ components: readOnly: true name: title: Name - description: An optional name to associate with the series, e.g. "John's PCI + description: > + An optional name to associate with the series, e.g. "John's PCI series". type: string readOnly: true @@ -2107,7 +2127,8 @@ components: readOnly: true version: title: Version - description: Version of series as indicated by the subject prefix(es) + description: > + Version of series as indicated by the subject prefix(es). type: integer readOnly: true mbox: @@ -2222,4 +2243,4 @@ components: last_name: title: First name type: string - readOnly: true
\ No newline at end of file + readOnly: true diff --git a/docs/api/schemas/v1.1/patchwork.yaml b/docs/api/schemas/v1.1/patchwork.yaml index bf66d3e..4e81ac3 100644 --- a/docs/api/schemas/v1.1/patchwork.yaml +++ b/docs/api/schemas/v1.1/patchwork.yaml @@ -1,9 +1,10 @@ # DO NOT EDIT THIS FILE. It is generated from a template. Changes should be # proposed against the template. +--- openapi: '3.0.0' info: title: Patchwork API - description: | + description: > Patchwork is a web-based patch tracking system designed to facilitate the contribution and management of contributions to an open-source project. contact: @@ -26,37 +27,37 @@ paths: schema: $ref: '#/components/schemas/Index' tags: - - api + - api /api/1.1/bundles/: get: description: List bundles. operationId: bundles_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - in: query - name: project - description: 'An ID or linkname of a project to filter bundles by.' - schema: - title: '' - type: string - - in: query - name: owner - description: 'An ID or username of a user to filter bundles by.' - schema: - title: '' - type: string - - in: query - name: public - description: 'Show only public (`true`) or private (`false`) bundles.' - schema: - title: '' - type: string - enum: - - 'true' - - 'false' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - in: query + name: project + description: An ID or linkname of a project to filter bundles by. + schema: + title: '' + type: string + - in: query + name: owner + description: An ID or username of a user to filter bundles by. + schema: + title: '' + type: string + - in: query + name: public + description: Show only public (`true`) or private (`false`) bundles. + schema: + title: '' + type: string + enum: + - 'true' + - 'false' responses: '200': description: '' @@ -70,19 +71,19 @@ paths: items: $ref: '#/components/schemas/Bundle' tags: - - bundles + - bundles /api/1.1/bundles/{id}/: get: description: Show a bundle. operationId: bundles_read parameters: - - in: path - name: id - required: true - description: 'A unique integer value identifying this bundle.' - schema: - title: ID - type: integer + - in: path + name: id + required: true + description: A unique integer value identifying this bundle. + schema: + title: ID + type: integer responses: '200': description: '' @@ -91,42 +92,44 @@ paths: schema: $ref: '#/components/schemas/Bundle' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - bundles + - bundles /api/1.1/covers/: get: description: List cover letters. operationId: covers_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - $ref: '#/components/parameters/BeforeFilter' - - $ref: '#/components/parameters/SinceFilter' - - in: query - name: project - description: 'An ID or linkname of a project to filter cover letters by.' - schema: - title: '' - type: string - - in: query - name: series - description: 'An ID of a series to filter cover letters by.' - schema: - title: '' - type: string - - in: query - name: submitter - description: 'An ID or email address of a person to filter cover letters by.' - schema: - title: '' - type: string + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/BeforeFilter' + - $ref: '#/components/parameters/SinceFilter' + - in: query + name: project + description: > + An ID or linkname of a project to filter cover letters by. + schema: + title: '' + type: string + - in: query + name: series + description: An ID of a series to filter cover letters by. + schema: + title: '' + type: string + - in: query + name: submitter + description: > + An ID or email address of a person to filter cover letters by. + schema: + title: '' + type: string responses: '200': description: '' @@ -140,19 +143,19 @@ paths: items: $ref: '#/components/schemas/CoverLetterList' tags: - - covers + - covers /api/1.1/covers/{id}/: get: description: Show a cover letter. operationId: covers_read parameters: - - in: path - name: id - description: 'A unique integer value identifying this cover letter.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this cover letter. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -161,29 +164,30 @@ paths: schema: $ref: '#/components/schemas/CoverLetterDetail' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - covers + - covers /api/1.1/covers/{id}/comments/: get: description: List comments operationId: cover_comments_list parameters: - - in: path - name: id - description: 'A unique integer value identifying the parent cover letter.' - required: true - schema: - title: ID - type: integer - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' + - in: path + name: id + description: > + A unique integer value identifying the parent cover letter. + required: true + schema: + title: ID + type: integer + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' responses: '200': description: '' @@ -197,63 +201,63 @@ paths: items: $ref: '#/components/schemas/Comment' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - comments + - comments /api/1.1/events/: get: description: List events. operationId: events_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - $ref: '#/components/parameters/BeforeFilter' - - $ref: '#/components/parameters/SinceFilter' - - in: query - name: project - description: 'An ID or linkname of a project to filter events by.' - schema: - title: '' - type: string - - in: query - name: category - description: 'An event category to filter events by.' - schema: - title: '' - type: string - enum: - - cover-created - - patch-created - - patch-completed - - patch-state-changed - - patch-delegated - - check-created - - series-created - - series-completed - - in: query - name: series - description: 'An ID of a series to filter events by.' - schema: - title: '' - type: integer - - in: query - name: patch - description: 'An ID of a patch to filter events by.' - schema: - title: '' - type: integer - - in: query - name: cover - description: 'An ID of a cover letter to filter events by.' - schema: - title: '' - type: integer + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/BeforeFilter' + - $ref: '#/components/parameters/SinceFilter' + - in: query + name: project + description: An ID or linkname of a project to filter events by. + schema: + title: '' + type: string + - in: query + name: category + description: An event category to filter events by. + schema: + title: '' + type: string + enum: + - cover-created + - patch-created + - patch-completed + - patch-state-changed + - patch-delegated + - check-created + - series-created + - series-completed + - in: query + name: series + description: An ID of a series to filter events by. + schema: + title: '' + type: integer + - in: query + name: patch + description: An ID of a patch to filter events by. + schema: + title: '' + type: integer + - in: query + name: cover + description: An ID of a cover letter to filter events by. + schema: + title: '' + type: integer responses: '200': description: '' @@ -279,64 +283,70 @@ paths: mapping: cover-created: '#/components/schemas/EventCoverCreated' patch-created: '#/components/schemas/EventPatchCreated' - patch-completed: '#/components/schemas/EventPatchCompleted' - patch-state-changed: '#/components/schemas/EventPatchStateChanged' - patch-delegated: '#/components/schemas/EventPatchDelegated' + patch-completed: > + '#/components/schemas/EventPatchCompleted' + patch-state-changed: > + '#/components/schemas/EventPatchStateChanged' + patch-delegated: > + '#/components/schemas/EventPatchDelegated' check-created: '#/components/schemas/EventCheckCreated' series-created: '#/components/schemas/EventSeriesCreated' - series-completed: '#/components/schemas/EventSeriesCompleted' + series-completed: > + '#/components/schemas/EventSeriesCompleted' tags: - - events + - events /api/1.1/patches/: get: description: List patches. operationId: patches_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - $ref: '#/components/parameters/BeforeFilter' - - $ref: '#/components/parameters/SinceFilter' - - in: query - name: project - description: 'An ID or linkname of a project to filter patches by.' - schema: - title: '' - type: string - - in: query - name: series - description: 'An ID of a series to filter patches by.' - schema: - title: '' - type: integer - - in: query - name: submitter - description: 'An ID or email address of a person to filter patches by.' - schema: - title: '' - type: string - - in: query - name: delegate - description: 'An ID or username of a user to filter patches by.' - schema: - title: '' - type: string - - in: query - name: state - description: 'A slug representation of a state to filter patches by.' - schema: - title: '' - type: string - - in: query - name: archived - description: 'Show only archived (`true`) or non-archived (`false`) patches.' - schema: - title: '' - type: string - enum: - - 'true' - - 'false' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/BeforeFilter' + - $ref: '#/components/parameters/SinceFilter' + - in: query + name: project + description: An ID or linkname of a project to filter patches by. + schema: + title: '' + type: string + - in: query + name: series + description: An ID of a series to filter patches by. + schema: + title: '' + type: integer + - in: query + name: submitter + description: > + An ID or email address of a person to filter patches by. + schema: + title: '' + type: string + - in: query + name: delegate + description: An ID or username of a user to filter patches by. + schema: + title: '' + type: string + - in: query + name: state + description: A slug representation of a state to filter patches by. + schema: + title: '' + type: string + - in: query + name: archived + description: > + Show only archived (`true`) or non-archived (`false`) patches. + schema: + title: '' + type: string + enum: + - 'true' + - 'false' responses: '200': description: '' @@ -350,19 +360,19 @@ paths: items: $ref: '#/components/schemas/PatchList' tags: - - patches + - patches /api/1.1/patches/{id}/: get: description: Show a patch. operationId: patches_read parameters: - - in: path - name: id - description: 'A unique integer value identifying this patch.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this patch. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -371,27 +381,27 @@ paths: schema: $ref: '#/components/schemas/PatchDetail' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - patches + - patches patch: description: Update a patch (partial). operationId: patches_partial_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this patch.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this patch. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/Patch' responses: @@ -402,39 +412,39 @@ paths: schema: $ref: '#/components/schemas/PatchDetail' '400': - description: 'Invalid Request' + description: Invalid Request content: application/json: schema: $ref: '#/components/schemas/ErrorPatchUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - patches + - patches put: description: Update a patch. operationId: patches_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this patch.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this patch. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/Patch' responses: @@ -445,41 +455,41 @@ paths: schema: $ref: '#/components/schemas/PatchDetail' '400': - description: 'Invalid Request' + description: Invalid Request content: application/json: schema: $ref: '#/components/schemas/ErrorPatchUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - patches + - patches /api/1.1/patches/{id}/comments/: get: description: List comments operationId: patch_comments_list parameters: - - in: path - name: id - description: 'A unique integer value identifying the parent patch.' - required: true - schema: - title: ID - type: integer - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' + - in: path + name: id + description: A unique integer value identifying the parent patch. + required: true + schema: + title: ID + type: integer + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' responses: '200': description: '' @@ -493,54 +503,54 @@ paths: items: $ref: '#/components/schemas/Comment' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - comments + - comments /api/1.1/patches/{patch_id}/checks/: get: description: List checks. operationId: checks_list parameters: - - in: path - name: patch_id - description: 'A unique integer value identifying the parent patch.' - required: true - schema: - title: Patch ID - type: integer - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - $ref: '#/components/parameters/BeforeFilter' - - $ref: '#/components/parameters/SinceFilter' - - in: query - name: user - description: 'An ID or username of a user to filter checks by.' - schema: - title: '' - type: string - - in: query - name: state - description: 'A check state to filter checks by.' - schema: - title: '' - type: string - enum: - - pending - - success - - warning - - fail - - in: query - name: context - description: 'A check context to filter checks by.' - schema: - title: '' - type: string + - in: path + name: patch_id + description: A unique integer value identifying the parent patch. + required: true + schema: + title: Patch ID + type: integer + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/BeforeFilter' + - $ref: '#/components/parameters/SinceFilter' + - in: query + name: user + description: An ID or username of a user to filter checks by. + schema: + title: '' + type: string + - in: query + name: state + description: A check state to filter checks by. + schema: + title: '' + type: string + enum: + - pending + - success + - warning + - fail + - in: query + name: context + description: A check context to filter checks by. + schema: + title: '' + type: string responses: '200': description: '' @@ -554,27 +564,27 @@ paths: items: $ref: '#/components/schemas/Check' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - checks + - checks post: description: Create a check. operationId: checks_create security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: patch_id - description: 'A unique integer value identifying the parent patch.' - required: true - schema: - title: Patch ID - type: integer + - in: path + name: patch_id + description: A unique integer value identifying the parent patch. + required: true + schema: + title: Patch ID + type: integer requestBody: $ref: '#/components/requestBodies/Check' responses: @@ -585,44 +595,44 @@ paths: schema: $ref: '#/components/schemas/Check' '400': - description: 'Invalid Request' + description: Invalid Request content: application/json: schema: $ref: '#/components/schemas/ErrorCheckCreate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - checks + - checks /api/1.1/patches/{patch_id}/checks/{check_id}/: get: description: Show a check. operationId: checks_read parameters: - - in: path - name: patch_id - description: 'A unique integer value identifying the parent patch.' - required: true - schema: - title: Patch ID - type: integer - - in: path - name: check_id - description: 'A unique integer value identifying this check.' - required: true - schema: - title: Check ID - type: integer + - in: path + name: patch_id + description: A unique integer value identifying the parent patch. + required: true + schema: + title: Patch ID + type: integer + - in: path + name: check_id + description: A unique integer value identifying this check. + required: true + schema: + title: Check ID + type: integer responses: '200': description: '' @@ -631,25 +641,25 @@ paths: schema: $ref: '#/components/schemas/Check' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - checks + - checks /api/1.1/people/: get: description: List people. operationId: people_list security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' responses: '200': description: '' @@ -663,28 +673,28 @@ paths: items: $ref: '#/components/schemas/Person' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - people + - people /api/1.1/people/{id}/: get: description: Show a person. operationId: people_read security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this person.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this person. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -693,28 +703,28 @@ paths: schema: $ref: '#/components/schemas/Person' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - people + - people /api/1.1/projects/: get: description: List projects. operationId: projects_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' responses: '200': description: '' @@ -728,19 +738,19 @@ paths: items: $ref: '#/components/schemas/Project' tags: - - projects + - projects /api/1.1/projects/{id}/: get: description: Show a project. operationId: projects_read parameters: - - in: path - name: id - description: 'A unique integer value identifying this project.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this project. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -749,27 +759,27 @@ paths: schema: $ref: '#/components/schemas/Project' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - projects + - projects patch: description: Update a project (partial). operationId: projects_partial_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this project.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this project. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/Project' responses: @@ -780,39 +790,39 @@ paths: schema: $ref: '#/components/schemas/Project' '400': - description: 'Bad request' + description: Bad request content: application/json: schema: $ref: '#/components/schemas/ErrorProjectUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - projects + - projects put: description: Update a project. operationId: projects_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this project.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this project. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/Project' responses: @@ -823,48 +833,48 @@ paths: schema: $ref: '#/components/schemas/Project' '400': - description: 'Bad request' + description: Bad request content: application/json: schema: $ref: '#/components/schemas/ErrorProjectUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - projects + - projects /api/1.1/series/: get: description: List series. operationId: series_list parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' - - $ref: '#/components/parameters/BeforeFilter' - - $ref: '#/components/parameters/SinceFilter' - - in: query - name: submitter - description: 'An ID or email address of a person to filter series by.' - schema: - title: '' - type: string - - in: query - name: project - description: 'An ID or linkname of a project to filter series by.' - schema: - title: '' - type: string + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/BeforeFilter' + - $ref: '#/components/parameters/SinceFilter' + - in: query + name: submitter + description: An ID or email address of a person to filter series by. + schema: + title: '' + type: string + - in: query + name: project + description: An ID or linkname of a project to filter series by. + schema: + title: '' + type: string responses: '200': description: '' @@ -878,19 +888,19 @@ paths: items: $ref: '#/components/schemas/Series' tags: - - series + - series /api/1.1/series/{id}/: get: description: Show a series. operationId: series_read parameters: - - in: path - name: id - description: 'A unique integer value identifying this series.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this series. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -899,25 +909,25 @@ paths: schema: $ref: '#/components/schemas/Series' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - series + - series /api/1.1/users/: get: description: List users. operationId: users_list security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - $ref: '#/components/parameters/Page' - - $ref: '#/components/parameters/PageSize' - - $ref: '#/components/parameters/Order' - - $ref: '#/components/parameters/Search' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/PageSize' + - $ref: '#/components/parameters/Order' + - $ref: '#/components/parameters/Search' responses: '200': description: '' @@ -931,28 +941,28 @@ paths: items: $ref: '#/components/schemas/User' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - users + - users /api/1.1/users/{id}/: get: description: Show a user. operationId: users_read security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this user.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this user. + required: true + schema: + title: ID + type: integer responses: '200': description: '' @@ -961,33 +971,33 @@ paths: schema: $ref: '#/components/schemas/User' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - users + - users patch: description: Update a user (partial). operationId: users_partial_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this user.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this user. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/User' responses: @@ -998,39 +1008,39 @@ paths: schema: $ref: '#/components/schemas/User' '400': - description: 'Bad request' + description: Bad request content: application/json: schema: $ref: '#/components/schemas/ErrorUserUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - users + - users put: description: Update a user. operationId: users_update security: - - basicAuth: [] - - apiKeyAuth: [] + - basicAuth: [] + - apiKeyAuth: [] parameters: - - in: path - name: id - description: 'A unique integer value identifying this user.' - required: true - schema: - title: ID - type: integer + - in: path + name: id + description: A unique integer value identifying this user. + required: true + schema: + title: ID + type: integer requestBody: $ref: '#/components/requestBodies/User' responses: @@ -1041,25 +1051,25 @@ paths: schema: $ref: '#/components/schemas/User' '400': - description: 'Bad request' + description: Bad request content: application/json: schema: $ref: '#/components/schemas/ErrorUserUpdate' '403': - description: 'Forbidden' + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '404': - description: 'Not found' + description: Not found content: application/json: schema: $ref: '#/components/schemas/Error' tags: - - users + - users components: securitySchemes: basicAuth: @@ -1072,48 +1082,48 @@ components: Page: in: query name: page - description: 'A page number within the paginated result set.' + description: A page number within the paginated result set. schema: title: Page type: integer PageSize: in: query name: per_page - description: 'Number of results to return per page.' + description: Number of results to return per page. schema: title: Page size type: integer Order: in: query name: order - description: 'Which field to use when ordering the results.' + description: Which field to use when ordering the results. schema: title: Ordering type: string Search: in: query name: q - description: 'A search term.' + description: A search term. schema: title: Search type: string BeforeFilter: in: query name: before - description: 'Latest date-time to retrieve results for.' + description: Latest date-time to retrieve results for. schema: title: '' type: string SinceFilter: in: query name: since - description: 'Earliest date-time to retrieve results for.' + description: Earliest date-time to retrieve results for. schema: title: '' type: string headers: Link: - description: | + description: > Links to related resources, in the format defined by [RFC 5988](https://tools.ietf.org/html/rfc5988#section-5). This will include a link with relation type `next` to the @@ -1239,7 +1249,7 @@ components: title: Owner readOnly: true allOf: - - $ref: '#/components/schemas/UserEmbedded' + - $ref: '#/components/schemas/UserEmbedded' patches: type: array items: @@ -1278,21 +1288,23 @@ components: description: The state of the check. type: string enum: - - pending - - success - - warning - - fail + - pending + - success + - warning + - fail target_url: title: Target URL - description: The target URL to associate with this check. This should be specific - to the patch. + description: > + The target URL to associate with this check. This should be + specific to the patch. type: string format: uri maxLength: 200 nullable: true context: title: Context - description: A label to discern check from checks of other testing systems. + description: > + A label to discern check from checks of other testing systems. type: string pattern: ^[-a-zA-Z0-9_]+$ minLength: 1 @@ -1310,21 +1322,23 @@ components: description: The state of the check. type: string enum: - - pending - - success - - warning - - fail + - pending + - success + - warning + - fail target_url: title: Target URL - description: The target URL to associate with this check. This should be specific - to the patch. + description: + The target URL to associate with this check. This should be + specific to the patch. type: string format: uri maxLength: 200 nullable: true context: title: Context - description: A label to discern check from checks of other testing systems. + description: > + A label to discern check from checks of other testing systems. type: string pattern: ^[-a-zA-Z0-9_]+$ minLength: 1 @@ -1365,7 +1379,7 @@ components: type: object title: Submitter allOf: - - $ref: '#/components/schemas/PersonEmbedded' + - $ref: '#/components/schemas/PersonEmbedded' content: title: Content type: string @@ -1418,7 +1432,7 @@ components: title: Submitter readOnly: true allOf: - - $ref: '#/components/schemas/PersonEmbedded' + - $ref: '#/components/schemas/PersonEmbedded' mbox: title: Mbox type: string @@ -1436,19 +1450,19 @@ components: readOnly: true CoverLetterDetail: allOf: - - $ref: '#/components/schemas/CoverLetterList' - - properties: - headers: - title: Headers - type: array - items: + - $ref: '#/components/schemas/CoverLetterList' + - properties: + headers: + title: Headers + type: array + items: + type: string + readOnly: true + content: + title: Content type: string - readOnly: true - content: - title: Content - type: string - readOnly: true - minLength: 1 + readOnly: true + minLength: 1 EventBase: type: object properties: @@ -1473,120 +1487,120 @@ components: type: object EventCoverCreated: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - cover-created - payload: - properties: - cover: - title: Cover - type: string - readOnly: true + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - cover-created + payload: + properties: + cover: + title: Cover + type: string + readOnly: true EventPatchCreated: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - patch-created - payload: - properties: - patch: - $ref: '#/components/schemas/PatchEmbedded' + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - patch-created + payload: + properties: + patch: + $ref: '#/components/schemas/PatchEmbedded' EventPatchCompleted: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - patch-completed - payload: - properties: - patch: - $ref: '#/components/schemas/PatchEmbedded' - series: - $ref: '#/components/schemas/SeriesEmbedded' + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - patch-completed + payload: + properties: + patch: + $ref: '#/components/schemas/PatchEmbedded' + series: + $ref: '#/components/schemas/SeriesEmbedded' EventPatchStateChanged: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - patch-state-changed - payload: - properties: - patch: - $ref: '#/components/schemas/PatchEmbedded' - previous_state: - title: Previous state - type: string - current_state: - title: Current state - type: string + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - patch-state-changed + payload: + properties: + patch: + $ref: '#/components/schemas/PatchEmbedded' + previous_state: + title: Previous state + type: string + current_state: + title: Current state + type: string EventPatchDelegated: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - patch-delegated - payload: - properties: - patch: - $ref: '#/components/schemas/PatchEmbedded' - previous_delegate: - allOf: - - $ref: '#/components/schemas/UserEmbedded' - - title: Previous delegate - current_delegate: - allOf: - - $ref: '#/components/schemas/UserEmbedded' - - title: Current delegate + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - patch-delegated + payload: + properties: + patch: + $ref: '#/components/schemas/PatchEmbedded' + previous_delegate: + allOf: + - $ref: '#/components/schemas/UserEmbedded' + - title: Previous delegate + current_delegate: + allOf: + - $ref: '#/components/schemas/UserEmbedded' + - title: Current delegate EventCheckCreated: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - check-created - payload: - properties: - patch: - $ref: '#/components/schemas/PatchEmbedded' - check: - $ref: '#/components/schemas/CheckEmbedded' + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - check-created + payload: + properties: + patch: + $ref: '#/components/schemas/PatchEmbedded' + check: + $ref: '#/components/schemas/CheckEmbedded' EventSeriesCreated: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - series-created - payload: - properties: - series: - $ref: '#/components/schemas/SeriesEmbedded' + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - series-created + payload: + properties: + series: + $ref: '#/components/schemas/SeriesEmbedded' EventSeriesCompleted: allOf: - - $ref: '#/components/schemas/EventBase' - - type: object - properties: - category: - enum: - - series-completed - payload: - properties: - series: - $ref: '#/components/schemas/SeriesEmbedded' + - $ref: '#/components/schemas/EventBase' + - type: object + properties: + category: + enum: + - series-completed + payload: + properties: + series: + $ref: '#/components/schemas/SeriesEmbedded' PatchList: required: - state @@ -1653,14 +1667,14 @@ components: title: Submitter readOnly: true allOf: - - $ref: '#/components/schemas/PersonEmbedded' + - $ref: '#/components/schemas/PersonEmbedded' delegate: type: object title: Delegate nullable: true readOnly: true allOf: - - $ref: '#/components/schemas/UserEmbedded' + - $ref: '#/components/schemas/UserEmbedded' mbox: title: Mbox type: string @@ -1681,10 +1695,10 @@ components: type: string readOnly: true enum: - - pending - - success - - warning - - fail + - pending + - success + - warning + - fail checks: title: Checks type: string @@ -1698,30 +1712,30 @@ components: readOnly: true PatchDetail: allOf: - - $ref: '#/components/schemas/PatchList' - - properties: - headers: - title: Headers - type: array - items: + - $ref: '#/components/schemas/PatchList' + - properties: + headers: + title: Headers + type: array + items: + type: string + readOnly: true + content: + title: Content type: string - readOnly: true - content: - title: Content - type: string - readOnly: true - minLength: 1 - diff: - title: Diff - type: string - readOnly: true - minLength: 1 - prefixes: - title: Prefixes - type: array - items: + readOnly: true + minLength: 1 + diff: + title: Diff type: string - readOnly: true + readOnly: true + minLength: 1 + prefixes: + title: Prefixes + type: array + items: + type: string + readOnly: true PatchUpdate: type: object properties: @@ -1777,7 +1791,7 @@ components: nullable: true readOnly: true allOf: - - $ref: '#/components/schemas/UserEmbedded' + - $ref: '#/components/schemas/UserEmbedded' Project: type: object properties: @@ -1838,11 +1852,12 @@ components: uniqueItems: true subject_match: title: Subject match - description: Regex to match the subject against if only part of emails - sent to the list belongs to this project. Will be used with - IGNORECASE and MULTILINE flags. If rules for more projects match the - first one returned from DB is chosen; empty field serves as a - default for every email which has no other match. + description: > + Regex to match the subject against if only part of emails sent to + the list belongs to this project. Will be used with IGNORECASE and + MULTILINE flags. If rules for more projects match the first one + returned from DB is chosen; empty field serves as a default for + every email which has no other match. type: string readOnly: true maxLength: 64 @@ -1867,7 +1882,8 @@ components: $ref: '#/components/schemas/ProjectEmbedded' name: title: Name - description: An optional name to associate with the series, e.g. "John's PCI + description: > + An optional name to associate with the series, e.g. "John's PCI series". type: string maxLength: 255 @@ -1882,14 +1898,16 @@ components: title: Submitter readOnly: true allOf: - - $ref: '#/components/schemas/PersonEmbedded' + - $ref: '#/components/schemas/PersonEmbedded' version: title: Version - description: Version of series as indicated by the subject prefix(es) + description: > + Version of series as indicated by the subject prefix(es). type: integer total: title: Total - description: Number of patches in series as indicated by the subject prefix(es) + description: > + Number of patches in series as indicated by the subject prefix(es). type: integer readOnly: true received_total: @@ -1968,13 +1986,14 @@ components: type: string readOnly: true enum: - - pending - - success - - warning - - fail + - pending + - success + - warning + - fail target_url: title: Target url - description: The target URL to associate with this check. This should be specific + description: > + The target URL to associate with this check. This should be specific to the patch. type: string format: uri @@ -1983,7 +2002,8 @@ components: readOnly: true context: title: Context - description: A label to discern check from checks of other testing systems. + description: > + A label to discern check from checks of other testing systems. type: string pattern: ^[-a-zA-Z0-9_]+$ maxLength: 255 @@ -2159,7 +2179,8 @@ components: readOnly: true name: title: Name - description: An optional name to associate with the series, e.g. "John's PCI + description: > + An optional name to associate with the series, e.g. "John's PCI series". type: string readOnly: true @@ -2172,7 +2193,8 @@ components: readOnly: true version: title: Version - description: Version of series as indicated by the subject prefix(es) + description: > + Version of series as indicated by the subject prefix(es). type: integer readOnly: true mbox: @@ -2287,4 +2309,4 @@ components: last_name: title: First name type: string - readOnly: true
\ No newline at end of file + readOnly: true |