diff --git a/openapi.json b/openapi.json index bd7ec2fe1..b3b0b3f0d 100644 --- a/openapi.json +++ b/openapi.json @@ -184,6 +184,30 @@ } } }, + "OCSMeta": { + "type": "object", + "required": [ + "status", + "statuscode" + ], + "properties": { + "status": { + "type": "string" + }, + "statuscode": { + "type": "integer" + }, + "message": { + "type": "string" + }, + "totalitems": { + "type": "string" + }, + "itemsperpage": { + "type": "string" + } + } + }, "User": { "type": "object", "required": [ @@ -249,8 +273,28 @@ "application/json": { "schema": { "type": "object", - "additionalProperties": { - "$ref": "#/components/schemas/Folder" + "required": [ + "ocs" + ], + "properties": { + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": { + "type": "object", + "additionalProperties": { + "$ref": "#/components/schemas/Folder" + } + } + } + } } } } @@ -260,7 +304,27 @@ "description": "Storage not found", "content": { "application/json": { - "schema": {} + "schema": { + "type": "object", + "required": [ + "ocs" + ], + "properties": { + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": {} + } + } + } + } } } } @@ -318,7 +382,27 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Folder" + "type": "object", + "required": [ + "ocs" + ], + "properties": { + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": { + "$ref": "#/components/schemas/Folder" + } + } + } + } } } } @@ -327,7 +411,27 @@ "description": "Groupfolder not found", "content": { "application/json": { - "schema": {} + "schema": { + "type": "object", + "required": [ + "ocs" + ], + "properties": { + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": {} + } + } + } + } } } } @@ -377,7 +481,27 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Folder" + "type": "object", + "required": [ + "ocs" + ], + "properties": { + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": { + "$ref": "#/components/schemas/Folder" + } + } + } + } } } } @@ -386,7 +510,27 @@ "description": "Groupfolder not found", "content": { "application/json": { - "schema": {} + "schema": { + "type": "object", + "required": [ + "ocs" + ], + "properties": { + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": {} + } + } + } + } } } } @@ -437,14 +581,34 @@ "schema": { "type": "object", "required": [ - "success" + "ocs" ], "properties": { - "success": { - "type": "boolean", - "enum": [ - true - ] + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": { + "type": "object", + "required": [ + "success" + ], + "properties": { + "success": { + "type": "boolean", + "enum": [ + true + ] + } + } + } + } } } } @@ -455,7 +619,27 @@ "description": "Groupfolder not found", "content": { "application/json": { - "schema": {} + "schema": { + "type": "object", + "required": [ + "ocs" + ], + "properties": { + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": {} + } + } + } + } } } } @@ -525,14 +709,34 @@ "schema": { "type": "object", "required": [ - "success" + "ocs" ], "properties": { - "success": { - "type": "boolean", - "enum": [ - true - ] + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": { + "type": "object", + "required": [ + "success" + ], + "properties": { + "success": { + "type": "boolean", + "enum": [ + true + ] + } + } + } + } } } } @@ -607,14 +811,34 @@ "schema": { "type": "object", "required": [ - "success" + "ocs" ], "properties": { - "success": { - "type": "boolean", - "enum": [ - true - ] + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": { + "type": "object", + "required": [ + "success" + ], + "properties": { + "success": { + "type": "boolean", + "enum": [ + true + ] + } + } + } + } } } } @@ -625,7 +849,27 @@ "description": "Groupfolder not found", "content": { "application/json": { - "schema": {} + "schema": { + "type": "object", + "required": [ + "ocs" + ], + "properties": { + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": {} + } + } + } + } } } } @@ -688,14 +932,34 @@ "schema": { "type": "object", "required": [ - "success" + "ocs" ], "properties": { - "success": { - "type": "boolean", - "enum": [ - true - ] + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": { + "type": "object", + "required": [ + "success" + ], + "properties": { + "success": { + "type": "boolean", + "enum": [ + true + ] + } + } + } + } } } } @@ -706,7 +970,27 @@ "description": "Groupfolder not found", "content": { "application/json": { - "schema": {} + "schema": { + "type": "object", + "required": [ + "ocs" + ], + "properties": { + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": {} + } + } + } + } } } } @@ -787,14 +1071,34 @@ "schema": { "type": "object", "required": [ - "success" + "ocs" ], "properties": { - "success": { - "type": "boolean", - "enum": [ - true - ] + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": { + "type": "object", + "required": [ + "success" + ], + "properties": { + "success": { + "type": "boolean", + "enum": [ + true + ] + } + } + } + } } } } @@ -805,7 +1109,27 @@ "description": "Groupfolder not found", "content": { "application/json": { - "schema": {} + "schema": { + "type": "object", + "required": [ + "ocs" + ], + "properties": { + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": {} + } + } + } + } } } } @@ -887,14 +1211,34 @@ "schema": { "type": "object", "required": [ - "success" + "ocs" ], "properties": { - "success": { - "type": "boolean", - "enum": [ - true - ] + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": { + "type": "object", + "required": [ + "success" + ], + "properties": { + "success": { + "type": "boolean", + "enum": [ + true + ] + } + } + } + } } } } @@ -905,7 +1249,27 @@ "description": "Groupfolder not found", "content": { "application/json": { - "schema": {} + "schema": { + "type": "object", + "required": [ + "ocs" + ], + "properties": { + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": {} + } + } + } + } } } } @@ -978,14 +1342,34 @@ "schema": { "type": "object", "required": [ - "success" + "ocs" ], "properties": { - "success": { - "type": "boolean", - "enum": [ - true - ] + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": { + "type": "object", + "required": [ + "success" + ], + "properties": { + "success": { + "type": "boolean", + "enum": [ + true + ] + } + } + } + } } } } @@ -996,7 +1380,27 @@ "description": "Groupfolder not found", "content": { "application/json": { - "schema": {} + "schema": { + "type": "object", + "required": [ + "ocs" + ], + "properties": { + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": {} + } + } + } + } } } } @@ -1068,14 +1472,34 @@ "schema": { "type": "object", "required": [ - "success" + "ocs" ], "properties": { - "success": { - "type": "boolean", - "enum": [ - true - ] + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": { + "type": "object", + "required": [ + "success" + ], + "properties": { + "success": { + "type": "boolean", + "enum": [ + true + ] + } + } + } + } } } } @@ -1086,7 +1510,27 @@ "description": "Groupfolder not found", "content": { "application/json": { - "schema": {} + "schema": { + "type": "object", + "required": [ + "ocs" + ], + "properties": { + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": {} + } + } + } + } } } } @@ -1158,14 +1602,34 @@ "schema": { "type": "object", "required": [ - "success" + "ocs" ], "properties": { - "success": { - "type": "boolean", - "enum": [ - true - ] + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": { + "type": "object", + "required": [ + "success" + ], + "properties": { + "success": { + "type": "boolean", + "enum": [ + true + ] + } + } + } + } } } } @@ -1176,7 +1640,27 @@ "description": "Groupfolder not found", "content": { "application/json": { - "schema": {} + "schema": { + "type": "object", + "required": [ + "ocs" + ], + "properties": { + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": {} + } + } + } + } } } } @@ -1237,20 +1721,40 @@ "schema": { "type": "object", "required": [ - "users", - "groups" + "ocs" ], "properties": { - "users": { - "type": "array", - "items": { - "$ref": "#/components/schemas/User" - } - }, - "groups": { - "type": "array", - "items": { - "$ref": "#/components/schemas/Group" + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": { + "type": "object", + "required": [ + "users", + "groups" + ], + "properties": { + "users": { + "type": "array", + "items": { + "$ref": "#/components/schemas/User" + } + }, + "groups": { + "type": "array", + "items": { + "$ref": "#/components/schemas/Group" + } + } + } + } } } } @@ -1262,7 +1766,27 @@ "description": "Not allowed to search", "content": { "application/json": { - "schema": {} + "schema": { + "type": "object", + "required": [ + "ocs" + ], + "properties": { + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": {} + } + } + } + } } } } @@ -1302,9 +1826,29 @@ "content": { "application/json": { "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/DelegationGroup" + "type": "object", + "required": [ + "ocs" + ], + "properties": { + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": { + "type": "array", + "items": { + "$ref": "#/components/schemas/DelegationGroup" + } + } + } + } } } } @@ -1346,9 +1890,29 @@ "content": { "application/json": { "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/DelegationCircle" + "type": "object", + "required": [ + "ocs" + ], + "properties": { + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": { + "type": "array", + "items": { + "$ref": "#/components/schemas/DelegationCircle" + } + } + } + } } } } @@ -1399,9 +1963,29 @@ "content": { "application/json": { "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/DelegationGroup" + "type": "object", + "required": [ + "ocs" + ], + "properties": { + "ocs": { + "type": "object", + "required": [ + "meta", + "data" + ], + "properties": { + "meta": { + "$ref": "#/components/schemas/OCSMeta" + }, + "data": { + "type": "array", + "items": { + "$ref": "#/components/schemas/DelegationGroup" + } + } + } + } } } } diff --git a/src/types/openapi/openapi.ts b/src/types/openapi/openapi.ts index daa2a5bc1..2d3946996 100644 --- a/src/types/openapi/openapi.ts +++ b/src/types/openapi/openapi.ts @@ -294,6 +294,13 @@ export type components = { gid: string; displayname: string; }; + OCSMeta: { + status: string; + statuscode: number; + message?: string; + totalitems?: string; + itemsperpage?: string; + }; User: { uid: string; displayname: string; @@ -329,7 +336,12 @@ export interface operations { }; content: { "application/json": { - [key: string]: components["schemas"]["Folder"]; + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: { + [key: string]: components["schemas"]["Folder"]; + }; + }; }; }; }; @@ -339,7 +351,12 @@ export interface operations { [name: string]: unknown; }; content: { - "application/json": unknown; + "application/json": { + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: unknown; + }; + }; }; }; }; @@ -369,7 +386,12 @@ export interface operations { [name: string]: unknown; }; content: { - "application/json": components["schemas"]["Folder"]; + "application/json": { + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: components["schemas"]["Folder"]; + }; + }; }; }; /** @description Groupfolder not found */ @@ -378,7 +400,12 @@ export interface operations { [name: string]: unknown; }; content: { - "application/json": unknown; + "application/json": { + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: unknown; + }; + }; }; }; }; @@ -404,7 +431,12 @@ export interface operations { [name: string]: unknown; }; content: { - "application/json": components["schemas"]["Folder"]; + "application/json": { + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: components["schemas"]["Folder"]; + }; + }; }; }; /** @description Groupfolder not found */ @@ -413,7 +445,12 @@ export interface operations { [name: string]: unknown; }; content: { - "application/json": unknown; + "application/json": { + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: unknown; + }; + }; }; }; }; @@ -447,8 +484,13 @@ export interface operations { }; content: { "application/json": { - /** @enum {boolean} */ - success: true; + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: { + /** @enum {boolean} */ + success: true; + }; + }; }; }; }; @@ -476,8 +518,13 @@ export interface operations { }; content: { "application/json": { - /** @enum {boolean} */ - success: true; + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: { + /** @enum {boolean} */ + success: true; + }; + }; }; }; }; @@ -487,7 +534,12 @@ export interface operations { [name: string]: unknown; }; content: { - "application/json": unknown; + "application/json": { + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: unknown; + }; + }; }; }; }; @@ -521,8 +573,13 @@ export interface operations { }; content: { "application/json": { - /** @enum {boolean} */ - success: true; + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: { + /** @enum {boolean} */ + success: true; + }; + }; }; }; }; @@ -532,7 +589,12 @@ export interface operations { [name: string]: unknown; }; content: { - "application/json": unknown; + "application/json": { + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: unknown; + }; + }; }; }; }; @@ -571,8 +633,13 @@ export interface operations { }; content: { "application/json": { - /** @enum {boolean} */ - success: true; + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: { + /** @enum {boolean} */ + success: true; + }; + }; }; }; }; @@ -582,7 +649,12 @@ export interface operations { [name: string]: unknown; }; content: { - "application/json": unknown; + "application/json": { + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: unknown; + }; + }; }; }; }; @@ -611,8 +683,13 @@ export interface operations { }; content: { "application/json": { - /** @enum {boolean} */ - success: true; + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: { + /** @enum {boolean} */ + success: true; + }; + }; }; }; }; @@ -622,7 +699,12 @@ export interface operations { [name: string]: unknown; }; content: { - "application/json": unknown; + "application/json": { + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: unknown; + }; + }; }; }; }; @@ -660,8 +742,13 @@ export interface operations { }; content: { "application/json": { - /** @enum {boolean} */ - success: true; + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: { + /** @enum {boolean} */ + success: true; + }; + }; }; }; }; @@ -671,7 +758,12 @@ export interface operations { [name: string]: unknown; }; content: { - "application/json": unknown; + "application/json": { + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: unknown; + }; + }; }; }; }; @@ -708,8 +800,13 @@ export interface operations { }; content: { "application/json": { - /** @enum {boolean} */ - success: true; + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: { + /** @enum {boolean} */ + success: true; + }; + }; }; }; }; @@ -719,7 +816,12 @@ export interface operations { [name: string]: unknown; }; content: { - "application/json": unknown; + "application/json": { + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: unknown; + }; + }; }; }; }; @@ -753,8 +855,13 @@ export interface operations { }; content: { "application/json": { - /** @enum {boolean} */ - success: true; + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: { + /** @enum {boolean} */ + success: true; + }; + }; }; }; }; @@ -764,7 +871,12 @@ export interface operations { [name: string]: unknown; }; content: { - "application/json": unknown; + "application/json": { + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: unknown; + }; + }; }; }; }; @@ -798,8 +910,13 @@ export interface operations { }; content: { "application/json": { - /** @enum {boolean} */ - success: true; + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: { + /** @enum {boolean} */ + success: true; + }; + }; }; }; }; @@ -809,7 +926,12 @@ export interface operations { [name: string]: unknown; }; content: { - "application/json": unknown; + "application/json": { + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: unknown; + }; + }; }; }; }; @@ -839,8 +961,13 @@ export interface operations { }; content: { "application/json": { - users: components["schemas"]["User"][]; - groups: components["schemas"]["Group"][]; + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: { + users: components["schemas"]["User"][]; + groups: components["schemas"]["Group"][]; + }; + }; }; }; }; @@ -850,7 +977,12 @@ export interface operations { [name: string]: unknown; }; content: { - "application/json": unknown; + "application/json": { + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: unknown; + }; + }; }; }; }; @@ -873,7 +1005,12 @@ export interface operations { [name: string]: unknown; }; content: { - "application/json": components["schemas"]["DelegationGroup"][]; + "application/json": { + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: components["schemas"]["DelegationGroup"][]; + }; + }; }; }; }; @@ -896,7 +1033,12 @@ export interface operations { [name: string]: unknown; }; content: { - "application/json": components["schemas"]["DelegationCircle"][]; + "application/json": { + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: components["schemas"]["DelegationCircle"][]; + }; + }; }; }; }; @@ -922,7 +1064,12 @@ export interface operations { [name: string]: unknown; }; content: { - "application/json": components["schemas"]["DelegationGroup"][]; + "application/json": { + ocs: { + meta: components["schemas"]["OCSMeta"]; + data: components["schemas"]["DelegationGroup"][]; + }; + }; }; }; }; diff --git a/vendor-bin/openapi-extractor/composer.lock b/vendor-bin/openapi-extractor/composer.lock index df45fe707..b30d7164a 100644 --- a/vendor-bin/openapi-extractor/composer.lock +++ b/vendor-bin/openapi-extractor/composer.lock @@ -79,16 +79,16 @@ }, { "name": "nextcloud/openapi-extractor", - "version": "v1.2.0", + "version": "v1.2.2", "source": { "type": "git", "url": "https://github.com/nextcloud-releases/openapi-extractor.git", - "reference": "b8b55ccb2407bb7a073a482293fbf0067186313c" + "reference": "fb177110c9d182dd9c6c5c19d20f1275f2b7f6af" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nextcloud-releases/openapi-extractor/zipball/b8b55ccb2407bb7a073a482293fbf0067186313c", - "reference": "b8b55ccb2407bb7a073a482293fbf0067186313c", + "url": "https://api.github.com/repos/nextcloud-releases/openapi-extractor/zipball/fb177110c9d182dd9c6c5c19d20f1275f2b7f6af", + "reference": "fb177110c9d182dd9c6c5c19d20f1275f2b7f6af", "shasum": "" }, "require": { @@ -119,9 +119,9 @@ "description": "A tool for extracting OpenAPI specifications from Nextcloud source code", "support": { "issues": "https://github.com/nextcloud-releases/openapi-extractor/issues", - "source": "https://github.com/nextcloud-releases/openapi-extractor/tree/v1.2.0" + "source": "https://github.com/nextcloud-releases/openapi-extractor/tree/v1.2.2" }, - "time": "2024-11-11T14:31:25+00:00" + "time": "2024-11-13T10:36:57+00:00" }, { "name": "nikic/php-parser",