From 39609398dcdd63a0a955a765dd40176c568718e5 Mon Sep 17 00:00:00 2001 From: Oguzhan Unlu Date: Tue, 24 Mar 2026 14:48:19 +0300 Subject: [PATCH 1/2] OpenAPI: Add 404 response for /v1/config endpoint Add NoSuchWarehouseResponse to document HTTP 404 as a valid response for the /v1/config endpoint when a requested warehouse does not exist. --- open-api/rest-catalog-open-api.yaml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/open-api/rest-catalog-open-api.yaml b/open-api/rest-catalog-open-api.yaml index d322b0c7c7c0..cdd496a14f21 100644 --- a/open-api/rest-catalog-open-api.yaml +++ b/open-api/rest-catalog-open-api.yaml @@ -162,6 +162,8 @@ paths: $ref: '#/components/responses/UnauthorizedResponse' 403: $ref: '#/components/responses/ForbiddenResponse' + 404: + $ref: '#/components/responses/NoSuchWarehouseResponse' 419: $ref: '#/components/responses/AuthenticationTimeoutResponse' 503: @@ -4660,6 +4662,20 @@ components: } } + NoSuchWarehouseResponse: + description: Not Found - The given warehouse does not exist. + content: + application/json: + schema: + $ref: '#/components/schemas/IcebergErrorResponse' + example: { + "error": { + "message": "The given warehouse does not exist", + "type": "NoSuchWarehouseException", + "code": 404 + } + } + # Note that this is a representative example response for use as a shorthand in the spec. # The fields `message` and `type` as indicated here are not presently prescriptive. UnsupportedOperationResponse: From f0f7d14c5bb3b03a112302c565b19aab3e54d166 Mon Sep 17 00:00:00 2001 From: Oguzhan Unlu Date: Wed, 25 Mar 2026 23:42:09 +0300 Subject: [PATCH 2/2] Follow inline response pattern --- open-api/rest-catalog-open-api.yaml | 33 ++++++++++++++++------------- 1 file changed, 18 insertions(+), 15 deletions(-) diff --git a/open-api/rest-catalog-open-api.yaml b/open-api/rest-catalog-open-api.yaml index cdd496a14f21..bff57faf9658 100644 --- a/open-api/rest-catalog-open-api.yaml +++ b/open-api/rest-catalog-open-api.yaml @@ -163,7 +163,14 @@ paths: 403: $ref: '#/components/responses/ForbiddenResponse' 404: - $ref: '#/components/responses/NoSuchWarehouseResponse' + description: Not Found - Warehouse provided in the `warehouse` query parameter is not found. + content: + application/json: + schema: + $ref: '#/components/schemas/IcebergErrorResponse' + examples: + NoSuchWarehouseExample: + $ref: '#/components/examples/NoSuchWarehouseError' 419: $ref: '#/components/responses/AuthenticationTimeoutResponse' 503: @@ -4662,20 +4669,6 @@ components: } } - NoSuchWarehouseResponse: - description: Not Found - The given warehouse does not exist. - content: - application/json: - schema: - $ref: '#/components/schemas/IcebergErrorResponse' - example: { - "error": { - "message": "The given warehouse does not exist", - "type": "NoSuchWarehouseException", - "code": 404 - } - } - # Note that this is a representative example response for use as a shorthand in the spec. # The fields `message` and `type` as indicated here are not presently prescriptive. UnsupportedOperationResponse: @@ -4978,6 +4971,16 @@ components: } } + NoSuchWarehouseError: + summary: The requested warehouse does not exist + value: { + "error": { + "message": "The given warehouse does not exist", + "type": "NoSuchWarehouseException", + "code": 404 + } + } + NoSuchNamespaceError: summary: The requested namespace does not exist value: {