From f224b38613f1e92806d869da0f685c2e67d995b7 Mon Sep 17 00:00:00 2001 From: udatny Date: Fri, 1 Oct 2021 15:01:34 +0200 Subject: [PATCH] Update openapi.yaml adding dedicated response object types where items is using in conjunction with object --- apidocs/openapi.yaml | 52 ++++++++++++++++++++++++++++++-------------- 1 file changed, 36 insertions(+), 16 deletions(-) diff --git a/apidocs/openapi.yaml b/apidocs/openapi.yaml index 04b98b5f..b0fc2a76 100644 --- a/apidocs/openapi.yaml +++ b/apidocs/openapi.yaml @@ -299,6 +299,38 @@ components: type: string enum: [idle, read, publish] + PathsList: + type: object + properties: + items: + type: object + additionalProperties: + $ref: '#/components/schemas/Path' + + RtspSessionsList: + type: object + properties: + items: + type: object + additionalProperties: + $ref: '#/components/schemas/RTSPSession' + + RtspsSessionsList: + type: object + properties: + items: + type: object + additionalProperties: + $ref: '#/components/schemas/RTSPSSession' + + RtmpConnsList: + type: object + properties: + items: + type: object + additionalProperties: + $ref: '#/components/schemas/RTMPConn' + paths: /v1/config/get: get: @@ -417,10 +449,7 @@ paths: content: application/json: schema: - items: - type: object - additionalProperties: - $ref: '#/components/schemas/Path' + $ref: '#/components/schemas/PathsList' '400': description: invalid request. '500': @@ -437,10 +466,7 @@ paths: content: application/json: schema: - items: - type: object - additionalProperties: - $ref: '#/components/schemas/RTSPSession' + $ref: '#/components/schemas/RtspSessionsList' '400': description: invalid request. '500': @@ -477,10 +503,7 @@ paths: content: application/json: schema: - items: - type: object - additionalProperties: - $ref: '#/components/schemas/RTSPSSession' + $ref: '#/components/schemas/RtspsSessionsList' '400': description: invalid request. '500': @@ -517,10 +540,7 @@ paths: content: application/json: schema: - items: - type: object - additionalProperties: - $ref: '#/components/schemas/RTMPConn' + $ref: '#/components/schemas/RtmpConnsList' '400': description: invalid request. '500':