Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions lib/Controller/WorkspaceApiOcsController.php
Original file line number Diff line number Diff line change
Expand Up @@ -150,9 +150,9 @@ public function find(int $id): DataResponse {
* Edit workspace name, color and quota
*
* @param int $id Represents the ID of a workspace
* @param string|null $name Workspace name (optional)
* @param string|null $color Workspace color (optional)
* @param int|null $quota Workspace quota in bytes (optional, -3 means unlimited, 0 means no quota)
* @param string|null $name Optional - Workspace name.
* @param string|null $color Optional - Workspace color in hexadecimal format (example: #f91616).
* @param int|null $quota Optional - Workspace quota in bytes; e.g., 5368709120 for 5GB, or -3 for unlimited.
* @return DataResponse<Http::STATUS_OK, WorkspaceSpace, array{}>
* @throws OCSNotFoundException when no groupfolder is associated with the given space ID
* @throws OCSException for all unknown errors
Expand All @@ -171,7 +171,7 @@ public function find(int $id): DataResponse {
url: '/api/v1/spaces/{id}',
requirements: ['id' => '\d+']
)]
public function edit(int $id, ?string $name, ?string $color = null, ?int $quota = null): DataResponse {
public function edit(int $id, ?string $name = null, ?string $color = null, ?int $quota = null): DataResponse {
$toSet = array_merge(WorkspaceEditParams::DEFAULT, [
'name' => $name,
'color' => $color,
Expand Down
17 changes: 10 additions & 7 deletions openapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@
"/ocs/v2.php/apps/workspace/api/v1/spaces": {
"get": {
"operationId": "workspace_api_ocs-find-all",
"summary": "Return the first 30 workspaces (optional filtering by name)",
"summary": "Return the first 25 workspaces (optional filtering by name)",
"tags": [
"workspace"
],
Expand All @@ -257,13 +257,14 @@
}
},
{
"name": "page",
"name": "offset",
"in": "query",
"description": "Optional page number for pagination",
"schema": {
"type": "integer",
"format": "int64",
"nullable": true
"nullable": true,
"default": null
}
},
{
Expand All @@ -273,7 +274,8 @@
"schema": {
"type": "integer",
"format": "int64",
"nullable": true
"nullable": true,
"default": null
}
},
{
Expand Down Expand Up @@ -665,20 +667,21 @@
"name": {
"type": "string",
"nullable": true,
"description": "Workspace name (optional)"
"default": null,
"description": "Optional - Workspace name."
},
"color": {
"type": "string",
"nullable": true,
"default": null,
"description": "Workspace color (optional)"
"description": "Optional - Workspace color in hexadecimal format (example: #f91616)."
},
"quota": {
"type": "integer",
"format": "int64",
"nullable": true,
"default": null,
"description": "Workspace quota in bytes (optional, -3 means unlimited, 0 means no quota)"
"description": "Optional - Workspace quota in bytes. For example: 5368709120 for 5GB or -3 means unlimited."
}
}
}
Expand Down
Loading