From b6c6eee251c302cf33ba632668ef67c58e7e6d2b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sybren=20A=2E=20St=C3=BCvel?= Date: Tue, 19 Jul 2022 16:52:38 +0200 Subject: [PATCH] OAPI: add examples to some schemas Add examples to the `WorkerSignOn` and `WorkerStateChanged` schemas. These will make it easier to test with SwaggerUI, as they reflect a worker signing on with the default task types. --- pkg/api/flamenco-openapi.yaml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/pkg/api/flamenco-openapi.yaml b/pkg/api/flamenco-openapi.yaml index b26f8a46..7a97294f 100644 --- a/pkg/api/flamenco-openapi.yaml +++ b/pkg/api/flamenco-openapi.yaml @@ -1224,6 +1224,11 @@ components: items: { type: string } software_version: { type: string } required: [name, supported_task_types, software_version] + example: + # This example may be nice to use from the SwaggerUI interface. + name: API user + supported_task_types: [blender, ffmpeg, file-management, misc] + software_version: swagger-ui WorkerStateChange: type: object @@ -1236,6 +1241,8 @@ components: properties: status: { $ref: "#/components/schemas/WorkerStatus" } required: [status] + example: + status: "awake" AssignedTask: type: object