From 2edb67148ad11fe21181a56aef7b78661a9f5c5c Mon Sep 17 00:00:00 2001 From: Emma Fabre Date: Tue, 26 Nov 2024 13:40:41 +0100 Subject: [PATCH 1/2] Add DELETE ownership endpoint documentation --- projects/uitdatabank/reference/entry.json | 40 +++++++++++++++++++++++ 1 file changed, 40 insertions(+) diff --git a/projects/uitdatabank/reference/entry.json b/projects/uitdatabank/reference/entry.json index 772f57aa..0989d091 100644 --- a/projects/uitdatabank/reference/entry.json +++ b/projects/uitdatabank/reference/entry.json @@ -8303,6 +8303,35 @@ }, "parameters": [] }, + "/ownerships/{ownershipId}": { + "parameters": [ + { + "$ref": "#/components/parameters/ownershipId" + } + ], + "delete": { + "summary": "ownership - delete", + "operationId": "delete-ownerships-ownershipId", + "responses": { + "204": { + "description": "No Content" + } + }, + "description": "Delete a specific ownership", + "x-internal": true, + "tags": [ + "Ownerships" + ], + "security": [ + { + "USER_ACCESS_TOKEN": [] + }, + { + "CLIENT_ACCESS_TOKEN": [] + } + ] + } + }, "/news-articles": { "post": { "summary": "news article - create", @@ -9293,6 +9322,17 @@ "example": "365f99a4-5490-4313-8ee9-adebea2dceb0" }, "description": "The unique uuid of an already uploaded image." + }, + "ownershipId": { + "name": "ownershipId", + "in": "path", + "required": true, + "schema": { + "type": "string", + "format": "uuid", + "example": "F2D5D20C-CC98-4979-9CD2-453ABAD979B5" + }, + "description": "Unique id of an ownership, in the format of a UUID" } }, "responses": { From ee80acd5b0abb7dca6d26666ad225fa6729a6192 Mon Sep 17 00:00:00 2001 From: Emma Fabre Date: Wed, 27 Nov 2024 11:43:47 +0100 Subject: [PATCH 2/2] Add 4xx responses --- projects/uitdatabank/reference/entry.json | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/projects/uitdatabank/reference/entry.json b/projects/uitdatabank/reference/entry.json index 0989d091..71cd762f 100644 --- a/projects/uitdatabank/reference/entry.json +++ b/projects/uitdatabank/reference/entry.json @@ -8315,6 +8315,15 @@ "responses": { "204": { "description": "No Content" + }, + "401": { + "$ref": "#/components/responses/Unauthorized" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" } }, "description": "Delete a specific ownership", @@ -9426,4 +9435,4 @@ "name": "Users" } ] -} \ No newline at end of file +}