mirror of
https://github.com/nextcloud/server.git
synced 2025-02-07 09:59:46 +00:00
9f037c3ef3
Signed-off-by: provokateurin <kate@provokateurin.de>
1777 lines
73 KiB
JSON
1777 lines
73 KiB
JSON
{
|
|
"openapi": "3.0.3",
|
|
"info": {
|
|
"title": "provisioning_api-administration",
|
|
"version": "0.0.1",
|
|
"description": "This application enables a set of APIs that external systems can use to manage accounts, groups and apps.",
|
|
"license": {
|
|
"name": "agpl"
|
|
}
|
|
},
|
|
"components": {
|
|
"securitySchemes": {
|
|
"basic_auth": {
|
|
"type": "http",
|
|
"scheme": "basic"
|
|
},
|
|
"bearer_auth": {
|
|
"type": "http",
|
|
"scheme": "bearer"
|
|
}
|
|
},
|
|
"schemas": {
|
|
"Capabilities": {
|
|
"type": "object",
|
|
"required": [
|
|
"provisioning_api"
|
|
],
|
|
"properties": {
|
|
"provisioning_api": {
|
|
"type": "object",
|
|
"required": [
|
|
"version",
|
|
"AccountPropertyScopesVersion",
|
|
"AccountPropertyScopesFederatedEnabled",
|
|
"AccountPropertyScopesPublishedEnabled"
|
|
],
|
|
"properties": {
|
|
"version": {
|
|
"type": "string"
|
|
},
|
|
"AccountPropertyScopesVersion": {
|
|
"type": "integer",
|
|
"format": "int64"
|
|
},
|
|
"AccountPropertyScopesFederatedEnabled": {
|
|
"type": "boolean"
|
|
},
|
|
"AccountPropertyScopesPublishedEnabled": {
|
|
"type": "boolean"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"OCSMeta": {
|
|
"type": "object",
|
|
"required": [
|
|
"status",
|
|
"statuscode"
|
|
],
|
|
"properties": {
|
|
"status": {
|
|
"type": "string"
|
|
},
|
|
"statuscode": {
|
|
"type": "integer"
|
|
},
|
|
"message": {
|
|
"type": "string"
|
|
},
|
|
"totalitems": {
|
|
"type": "string"
|
|
},
|
|
"itemsperpage": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"UserDetails": {
|
|
"type": "object",
|
|
"required": [
|
|
"additional_mail",
|
|
"address",
|
|
"backend",
|
|
"backendCapabilities",
|
|
"biography",
|
|
"display-name",
|
|
"displayname",
|
|
"email",
|
|
"fediverse",
|
|
"groups",
|
|
"headline",
|
|
"id",
|
|
"language",
|
|
"lastLogin",
|
|
"locale",
|
|
"manager",
|
|
"notify_email",
|
|
"organisation",
|
|
"phone",
|
|
"profile_enabled",
|
|
"quota",
|
|
"role",
|
|
"subadmin",
|
|
"twitter",
|
|
"website"
|
|
],
|
|
"properties": {
|
|
"additional_mail": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"additional_mailScope": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/UserDetailsScope"
|
|
}
|
|
},
|
|
"address": {
|
|
"type": "string"
|
|
},
|
|
"addressScope": {
|
|
"$ref": "#/components/schemas/UserDetailsScope"
|
|
},
|
|
"avatarScope": {
|
|
"$ref": "#/components/schemas/UserDetailsScope"
|
|
},
|
|
"backend": {
|
|
"type": "string"
|
|
},
|
|
"backendCapabilities": {
|
|
"type": "object",
|
|
"required": [
|
|
"setDisplayName",
|
|
"setPassword"
|
|
],
|
|
"properties": {
|
|
"setDisplayName": {
|
|
"type": "boolean"
|
|
},
|
|
"setPassword": {
|
|
"type": "boolean"
|
|
}
|
|
}
|
|
},
|
|
"biography": {
|
|
"type": "string"
|
|
},
|
|
"biographyScope": {
|
|
"$ref": "#/components/schemas/UserDetailsScope"
|
|
},
|
|
"display-name": {
|
|
"type": "string"
|
|
},
|
|
"displayname": {
|
|
"type": "string"
|
|
},
|
|
"displaynameScope": {
|
|
"$ref": "#/components/schemas/UserDetailsScope"
|
|
},
|
|
"email": {
|
|
"type": "string",
|
|
"nullable": true
|
|
},
|
|
"emailScope": {
|
|
"$ref": "#/components/schemas/UserDetailsScope"
|
|
},
|
|
"enabled": {
|
|
"type": "boolean"
|
|
},
|
|
"fediverse": {
|
|
"type": "string"
|
|
},
|
|
"fediverseScope": {
|
|
"$ref": "#/components/schemas/UserDetailsScope"
|
|
},
|
|
"groups": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"headline": {
|
|
"type": "string"
|
|
},
|
|
"headlineScope": {
|
|
"$ref": "#/components/schemas/UserDetailsScope"
|
|
},
|
|
"id": {
|
|
"type": "string"
|
|
},
|
|
"language": {
|
|
"type": "string"
|
|
},
|
|
"lastLogin": {
|
|
"type": "integer",
|
|
"format": "int64"
|
|
},
|
|
"locale": {
|
|
"type": "string"
|
|
},
|
|
"manager": {
|
|
"type": "string"
|
|
},
|
|
"notify_email": {
|
|
"type": "string",
|
|
"nullable": true
|
|
},
|
|
"organisation": {
|
|
"type": "string"
|
|
},
|
|
"organisationScope": {
|
|
"$ref": "#/components/schemas/UserDetailsScope"
|
|
},
|
|
"phone": {
|
|
"type": "string"
|
|
},
|
|
"phoneScope": {
|
|
"$ref": "#/components/schemas/UserDetailsScope"
|
|
},
|
|
"profile_enabled": {
|
|
"type": "string"
|
|
},
|
|
"profile_enabledScope": {
|
|
"$ref": "#/components/schemas/UserDetailsScope"
|
|
},
|
|
"quota": {
|
|
"$ref": "#/components/schemas/UserDetailsQuota"
|
|
},
|
|
"role": {
|
|
"type": "string"
|
|
},
|
|
"roleScope": {
|
|
"$ref": "#/components/schemas/UserDetailsScope"
|
|
},
|
|
"storageLocation": {
|
|
"type": "string"
|
|
},
|
|
"subadmin": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"twitter": {
|
|
"type": "string"
|
|
},
|
|
"twitterScope": {
|
|
"$ref": "#/components/schemas/UserDetailsScope"
|
|
},
|
|
"website": {
|
|
"type": "string"
|
|
},
|
|
"websiteScope": {
|
|
"$ref": "#/components/schemas/UserDetailsScope"
|
|
}
|
|
}
|
|
},
|
|
"UserDetailsQuota": {
|
|
"type": "object",
|
|
"properties": {
|
|
"free": {
|
|
"anyOf": [
|
|
{
|
|
"type": "number",
|
|
"format": "double"
|
|
},
|
|
{
|
|
"type": "integer",
|
|
"format": "int64"
|
|
}
|
|
]
|
|
},
|
|
"quota": {
|
|
"anyOf": [
|
|
{
|
|
"type": "number",
|
|
"format": "double"
|
|
},
|
|
{
|
|
"type": "integer",
|
|
"format": "int64"
|
|
},
|
|
{
|
|
"type": "string"
|
|
}
|
|
]
|
|
},
|
|
"relative": {
|
|
"anyOf": [
|
|
{
|
|
"type": "number",
|
|
"format": "double"
|
|
},
|
|
{
|
|
"type": "integer",
|
|
"format": "int64"
|
|
}
|
|
]
|
|
},
|
|
"total": {
|
|
"anyOf": [
|
|
{
|
|
"type": "number",
|
|
"format": "double"
|
|
},
|
|
{
|
|
"type": "integer",
|
|
"format": "int64"
|
|
}
|
|
]
|
|
},
|
|
"used": {
|
|
"anyOf": [
|
|
{
|
|
"type": "number",
|
|
"format": "double"
|
|
},
|
|
{
|
|
"type": "integer",
|
|
"format": "int64"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
},
|
|
"UserDetailsScope": {
|
|
"type": "string",
|
|
"enum": [
|
|
"v2-private",
|
|
"v2-local",
|
|
"v2-federated",
|
|
"v2-published",
|
|
"private",
|
|
"contacts",
|
|
"public"
|
|
]
|
|
}
|
|
}
|
|
},
|
|
"paths": {
|
|
"/ocs/v2.php/cloud/apps": {
|
|
"get": {
|
|
"operationId": "apps-get-apps",
|
|
"summary": "Get a list of installed apps",
|
|
"description": "This endpoint requires admin access",
|
|
"tags": [
|
|
"apps"
|
|
],
|
|
"security": [
|
|
{
|
|
"bearer_auth": []
|
|
},
|
|
{
|
|
"basic_auth": []
|
|
}
|
|
],
|
|
"parameters": [
|
|
{
|
|
"name": "filter",
|
|
"in": "query",
|
|
"description": "Filter for enabled or disabled apps",
|
|
"schema": {
|
|
"type": "string",
|
|
"nullable": true
|
|
}
|
|
},
|
|
{
|
|
"name": "OCS-APIRequest",
|
|
"in": "header",
|
|
"description": "Required to be true for the API request to pass",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "boolean",
|
|
"default": true
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Installed apps returned",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"ocs"
|
|
],
|
|
"properties": {
|
|
"ocs": {
|
|
"type": "object",
|
|
"required": [
|
|
"meta",
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"meta": {
|
|
"$ref": "#/components/schemas/OCSMeta"
|
|
},
|
|
"data": {
|
|
"type": "object",
|
|
"required": [
|
|
"apps"
|
|
],
|
|
"properties": {
|
|
"apps": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/ocs/v2.php/cloud/apps/{app}": {
|
|
"get": {
|
|
"operationId": "apps-get-app-info",
|
|
"summary": "Get the app info for an app",
|
|
"description": "This endpoint requires admin access",
|
|
"tags": [
|
|
"apps"
|
|
],
|
|
"security": [
|
|
{
|
|
"bearer_auth": []
|
|
},
|
|
{
|
|
"basic_auth": []
|
|
}
|
|
],
|
|
"parameters": [
|
|
{
|
|
"name": "app",
|
|
"in": "path",
|
|
"description": "ID of the app",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"name": "OCS-APIRequest",
|
|
"in": "header",
|
|
"description": "Required to be true for the API request to pass",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "boolean",
|
|
"default": true
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "App info returned",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"ocs"
|
|
],
|
|
"properties": {
|
|
"ocs": {
|
|
"type": "object",
|
|
"required": [
|
|
"meta",
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"meta": {
|
|
"$ref": "#/components/schemas/OCSMeta"
|
|
},
|
|
"data": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"type": "object",
|
|
"nullable": true
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"post": {
|
|
"operationId": "apps-enable",
|
|
"summary": "Enable an app",
|
|
"description": "This endpoint requires admin access\nThis endpoint requires password confirmation",
|
|
"tags": [
|
|
"apps"
|
|
],
|
|
"security": [
|
|
{
|
|
"bearer_auth": []
|
|
},
|
|
{
|
|
"basic_auth": []
|
|
}
|
|
],
|
|
"parameters": [
|
|
{
|
|
"name": "app",
|
|
"in": "path",
|
|
"description": "ID of the app",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"name": "OCS-APIRequest",
|
|
"in": "header",
|
|
"description": "Required to be true for the API request to pass",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "boolean",
|
|
"default": true
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "App enabled successfully",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"ocs"
|
|
],
|
|
"properties": {
|
|
"ocs": {
|
|
"type": "object",
|
|
"required": [
|
|
"meta",
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"meta": {
|
|
"$ref": "#/components/schemas/OCSMeta"
|
|
},
|
|
"data": {}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"delete": {
|
|
"operationId": "apps-disable",
|
|
"summary": "Disable an app",
|
|
"description": "This endpoint requires admin access\nThis endpoint requires password confirmation",
|
|
"tags": [
|
|
"apps"
|
|
],
|
|
"security": [
|
|
{
|
|
"bearer_auth": []
|
|
},
|
|
{
|
|
"basic_auth": []
|
|
}
|
|
],
|
|
"parameters": [
|
|
{
|
|
"name": "app",
|
|
"in": "path",
|
|
"description": "ID of the app",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"name": "OCS-APIRequest",
|
|
"in": "header",
|
|
"description": "Required to be true for the API request to pass",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "boolean",
|
|
"default": true
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "App disabled successfully",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"ocs"
|
|
],
|
|
"properties": {
|
|
"ocs": {
|
|
"type": "object",
|
|
"required": [
|
|
"meta",
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"meta": {
|
|
"$ref": "#/components/schemas/OCSMeta"
|
|
},
|
|
"data": {}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/ocs/v2.php/cloud/groups/{groupId}/subadmins": {
|
|
"get": {
|
|
"operationId": "groups-get-sub-admins-of-group",
|
|
"summary": "Get the list of user IDs that are a subadmin of the group",
|
|
"description": "This endpoint requires admin access",
|
|
"tags": [
|
|
"groups"
|
|
],
|
|
"security": [
|
|
{
|
|
"bearer_auth": []
|
|
},
|
|
{
|
|
"basic_auth": []
|
|
}
|
|
],
|
|
"parameters": [
|
|
{
|
|
"name": "groupId",
|
|
"in": "path",
|
|
"description": "ID of the group",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string",
|
|
"pattern": "^.+$"
|
|
}
|
|
},
|
|
{
|
|
"name": "OCS-APIRequest",
|
|
"in": "header",
|
|
"description": "Required to be true for the API request to pass",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "boolean",
|
|
"default": true
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Sub admins returned",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"ocs"
|
|
],
|
|
"properties": {
|
|
"ocs": {
|
|
"type": "object",
|
|
"required": [
|
|
"meta",
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"meta": {
|
|
"$ref": "#/components/schemas/OCSMeta"
|
|
},
|
|
"data": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/ocs/v2.php/cloud/groups": {
|
|
"post": {
|
|
"operationId": "groups-add-group",
|
|
"summary": "Create a new group",
|
|
"description": "This endpoint requires admin access\nThis endpoint requires password confirmation",
|
|
"tags": [
|
|
"groups"
|
|
],
|
|
"security": [
|
|
{
|
|
"bearer_auth": []
|
|
},
|
|
{
|
|
"basic_auth": []
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"required": true,
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"groupid"
|
|
],
|
|
"properties": {
|
|
"groupid": {
|
|
"type": "string",
|
|
"description": "ID of the group"
|
|
},
|
|
"displayname": {
|
|
"type": "string",
|
|
"default": "",
|
|
"description": "Display name of the group"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"parameters": [
|
|
{
|
|
"name": "OCS-APIRequest",
|
|
"in": "header",
|
|
"description": "Required to be true for the API request to pass",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "boolean",
|
|
"default": true
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Group created successfully",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"ocs"
|
|
],
|
|
"properties": {
|
|
"ocs": {
|
|
"type": "object",
|
|
"required": [
|
|
"meta",
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"meta": {
|
|
"$ref": "#/components/schemas/OCSMeta"
|
|
},
|
|
"data": {}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/ocs/v2.php/cloud/groups/{groupId}": {
|
|
"put": {
|
|
"operationId": "groups-update-group",
|
|
"summary": "Update a group",
|
|
"description": "This endpoint requires admin access\nThis endpoint requires password confirmation",
|
|
"tags": [
|
|
"groups"
|
|
],
|
|
"security": [
|
|
{
|
|
"bearer_auth": []
|
|
},
|
|
{
|
|
"basic_auth": []
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"required": true,
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"key",
|
|
"value"
|
|
],
|
|
"properties": {
|
|
"key": {
|
|
"type": "string",
|
|
"description": "Key to update, only 'displayname'"
|
|
},
|
|
"value": {
|
|
"type": "string",
|
|
"description": "New value for the key"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"parameters": [
|
|
{
|
|
"name": "groupId",
|
|
"in": "path",
|
|
"description": "ID of the group",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string",
|
|
"pattern": "^.+$"
|
|
}
|
|
},
|
|
{
|
|
"name": "OCS-APIRequest",
|
|
"in": "header",
|
|
"description": "Required to be true for the API request to pass",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "boolean",
|
|
"default": true
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Group updated successfully",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"ocs"
|
|
],
|
|
"properties": {
|
|
"ocs": {
|
|
"type": "object",
|
|
"required": [
|
|
"meta",
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"meta": {
|
|
"$ref": "#/components/schemas/OCSMeta"
|
|
},
|
|
"data": {}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"delete": {
|
|
"operationId": "groups-delete-group",
|
|
"summary": "Delete a group",
|
|
"description": "This endpoint requires admin access\nThis endpoint requires password confirmation",
|
|
"tags": [
|
|
"groups"
|
|
],
|
|
"security": [
|
|
{
|
|
"bearer_auth": []
|
|
},
|
|
{
|
|
"basic_auth": []
|
|
}
|
|
],
|
|
"parameters": [
|
|
{
|
|
"name": "groupId",
|
|
"in": "path",
|
|
"description": "ID of the group",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string",
|
|
"pattern": "^.+$"
|
|
}
|
|
},
|
|
{
|
|
"name": "OCS-APIRequest",
|
|
"in": "header",
|
|
"description": "Required to be true for the API request to pass",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "boolean",
|
|
"default": true
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Group deleted successfully",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"ocs"
|
|
],
|
|
"properties": {
|
|
"ocs": {
|
|
"type": "object",
|
|
"required": [
|
|
"meta",
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"meta": {
|
|
"$ref": "#/components/schemas/OCSMeta"
|
|
},
|
|
"data": {}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/ocs/v2.php/cloud/users/recent": {
|
|
"get": {
|
|
"operationId": "users-get-last-logged-in-users",
|
|
"summary": "Gets the list of users sorted by lastLogin, from most recent to least recent",
|
|
"description": "This endpoint requires admin access",
|
|
"tags": [
|
|
"users"
|
|
],
|
|
"security": [
|
|
{
|
|
"bearer_auth": []
|
|
},
|
|
{
|
|
"basic_auth": []
|
|
}
|
|
],
|
|
"parameters": [
|
|
{
|
|
"name": "search",
|
|
"in": "query",
|
|
"description": "Text to search for",
|
|
"schema": {
|
|
"type": "string",
|
|
"default": ""
|
|
}
|
|
},
|
|
{
|
|
"name": "limit",
|
|
"in": "query",
|
|
"description": "Limit the amount of users returned",
|
|
"schema": {
|
|
"type": "integer",
|
|
"format": "int64",
|
|
"nullable": true
|
|
}
|
|
},
|
|
{
|
|
"name": "offset",
|
|
"in": "query",
|
|
"description": "Offset",
|
|
"schema": {
|
|
"type": "integer",
|
|
"format": "int64",
|
|
"default": 0
|
|
}
|
|
},
|
|
{
|
|
"name": "OCS-APIRequest",
|
|
"in": "header",
|
|
"description": "Required to be true for the API request to pass",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "boolean",
|
|
"default": true
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Users details returned based on last logged in information",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"ocs"
|
|
],
|
|
"properties": {
|
|
"ocs": {
|
|
"type": "object",
|
|
"required": [
|
|
"meta",
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"meta": {
|
|
"$ref": "#/components/schemas/OCSMeta"
|
|
},
|
|
"data": {
|
|
"type": "object",
|
|
"required": [
|
|
"users"
|
|
],
|
|
"properties": {
|
|
"users": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"anyOf": [
|
|
{
|
|
"$ref": "#/components/schemas/UserDetails"
|
|
},
|
|
{
|
|
"type": "object",
|
|
"required": [
|
|
"id"
|
|
],
|
|
"properties": {
|
|
"id": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/ocs/v2.php/cloud/users/{userId}/subadmins": {
|
|
"get": {
|
|
"operationId": "users-get-user-sub-admin-groups",
|
|
"summary": "Get the groups a user is a subadmin of",
|
|
"description": "This endpoint requires admin access",
|
|
"tags": [
|
|
"users"
|
|
],
|
|
"security": [
|
|
{
|
|
"bearer_auth": []
|
|
},
|
|
{
|
|
"basic_auth": []
|
|
}
|
|
],
|
|
"parameters": [
|
|
{
|
|
"name": "userId",
|
|
"in": "path",
|
|
"description": "ID if the user",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"name": "OCS-APIRequest",
|
|
"in": "header",
|
|
"description": "Required to be true for the API request to pass",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "boolean",
|
|
"default": true
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "User subadmin groups returned",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"ocs"
|
|
],
|
|
"properties": {
|
|
"ocs": {
|
|
"type": "object",
|
|
"required": [
|
|
"meta",
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"meta": {
|
|
"$ref": "#/components/schemas/OCSMeta"
|
|
},
|
|
"data": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"post": {
|
|
"operationId": "users-add-sub-admin",
|
|
"summary": "Make a user a subadmin of a group",
|
|
"description": "This endpoint requires admin access\nThis endpoint requires password confirmation",
|
|
"tags": [
|
|
"users"
|
|
],
|
|
"security": [
|
|
{
|
|
"bearer_auth": []
|
|
},
|
|
{
|
|
"basic_auth": []
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"required": true,
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"groupid"
|
|
],
|
|
"properties": {
|
|
"groupid": {
|
|
"type": "string",
|
|
"description": "ID of the group"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"parameters": [
|
|
{
|
|
"name": "userId",
|
|
"in": "path",
|
|
"description": "ID of the user",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"name": "OCS-APIRequest",
|
|
"in": "header",
|
|
"description": "Required to be true for the API request to pass",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "boolean",
|
|
"default": true
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "User added as group subadmin successfully",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"ocs"
|
|
],
|
|
"properties": {
|
|
"ocs": {
|
|
"type": "object",
|
|
"required": [
|
|
"meta",
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"meta": {
|
|
"$ref": "#/components/schemas/OCSMeta"
|
|
},
|
|
"data": {}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"delete": {
|
|
"operationId": "users-remove-sub-admin",
|
|
"summary": "Remove a user from the subadmins of a group",
|
|
"description": "This endpoint requires admin access\nThis endpoint requires password confirmation",
|
|
"tags": [
|
|
"users"
|
|
],
|
|
"security": [
|
|
{
|
|
"bearer_auth": []
|
|
},
|
|
{
|
|
"basic_auth": []
|
|
}
|
|
],
|
|
"parameters": [
|
|
{
|
|
"name": "userId",
|
|
"in": "path",
|
|
"description": "ID of the user",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"name": "groupid",
|
|
"in": "query",
|
|
"description": "ID of the group",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"name": "OCS-APIRequest",
|
|
"in": "header",
|
|
"description": "Required to be true for the API request to pass",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "boolean",
|
|
"default": true
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "User removed as group subadmin successfully",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"ocs"
|
|
],
|
|
"properties": {
|
|
"ocs": {
|
|
"type": "object",
|
|
"required": [
|
|
"meta",
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"meta": {
|
|
"$ref": "#/components/schemas/OCSMeta"
|
|
},
|
|
"data": {}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/ocs/v2.php/apps/provisioning_api/api/v1/config/apps": {
|
|
"get": {
|
|
"operationId": "app_config-get-apps",
|
|
"summary": "Get a list of apps",
|
|
"description": "This endpoint requires admin access",
|
|
"tags": [
|
|
"app_config"
|
|
],
|
|
"security": [
|
|
{
|
|
"bearer_auth": []
|
|
},
|
|
{
|
|
"basic_auth": []
|
|
}
|
|
],
|
|
"parameters": [
|
|
{
|
|
"name": "OCS-APIRequest",
|
|
"in": "header",
|
|
"description": "Required to be true for the API request to pass",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "boolean",
|
|
"default": true
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Apps returned",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"ocs"
|
|
],
|
|
"properties": {
|
|
"ocs": {
|
|
"type": "object",
|
|
"required": [
|
|
"meta",
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"meta": {
|
|
"$ref": "#/components/schemas/OCSMeta"
|
|
},
|
|
"data": {
|
|
"type": "object",
|
|
"required": [
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"data": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/ocs/v2.php/apps/provisioning_api/api/v1/config/apps/{app}": {
|
|
"get": {
|
|
"operationId": "app_config-get-keys",
|
|
"summary": "Get the config keys of an app",
|
|
"description": "This endpoint requires admin access",
|
|
"tags": [
|
|
"app_config"
|
|
],
|
|
"security": [
|
|
{
|
|
"bearer_auth": []
|
|
},
|
|
{
|
|
"basic_auth": []
|
|
}
|
|
],
|
|
"parameters": [
|
|
{
|
|
"name": "app",
|
|
"in": "path",
|
|
"description": "ID of the app",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"name": "OCS-APIRequest",
|
|
"in": "header",
|
|
"description": "Required to be true for the API request to pass",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "boolean",
|
|
"default": true
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Keys returned",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"ocs"
|
|
],
|
|
"properties": {
|
|
"ocs": {
|
|
"type": "object",
|
|
"required": [
|
|
"meta",
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"meta": {
|
|
"$ref": "#/components/schemas/OCSMeta"
|
|
},
|
|
"data": {
|
|
"type": "object",
|
|
"required": [
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"data": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "App is not allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"ocs"
|
|
],
|
|
"properties": {
|
|
"ocs": {
|
|
"type": "object",
|
|
"required": [
|
|
"meta",
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"meta": {
|
|
"$ref": "#/components/schemas/OCSMeta"
|
|
},
|
|
"data": {
|
|
"type": "object",
|
|
"required": [
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"data": {
|
|
"type": "object",
|
|
"required": [
|
|
"message"
|
|
],
|
|
"properties": {
|
|
"message": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/ocs/v2.php/apps/provisioning_api/api/v1/config/apps/{app}/{key}": {
|
|
"get": {
|
|
"operationId": "app_config-get-value",
|
|
"summary": "Get a the config value of an app",
|
|
"description": "This endpoint requires admin access",
|
|
"tags": [
|
|
"app_config"
|
|
],
|
|
"security": [
|
|
{
|
|
"bearer_auth": []
|
|
},
|
|
{
|
|
"basic_auth": []
|
|
}
|
|
],
|
|
"parameters": [
|
|
{
|
|
"name": "app",
|
|
"in": "path",
|
|
"description": "ID of the app",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"name": "key",
|
|
"in": "path",
|
|
"description": "Key",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"name": "defaultValue",
|
|
"in": "query",
|
|
"description": "Default returned value if the value is empty",
|
|
"schema": {
|
|
"type": "string",
|
|
"default": ""
|
|
}
|
|
},
|
|
{
|
|
"name": "OCS-APIRequest",
|
|
"in": "header",
|
|
"description": "Required to be true for the API request to pass",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "boolean",
|
|
"default": true
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Value returned",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"ocs"
|
|
],
|
|
"properties": {
|
|
"ocs": {
|
|
"type": "object",
|
|
"required": [
|
|
"meta",
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"meta": {
|
|
"$ref": "#/components/schemas/OCSMeta"
|
|
},
|
|
"data": {
|
|
"type": "object",
|
|
"required": [
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"data": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "App is not allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"ocs"
|
|
],
|
|
"properties": {
|
|
"ocs": {
|
|
"type": "object",
|
|
"required": [
|
|
"meta",
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"meta": {
|
|
"$ref": "#/components/schemas/OCSMeta"
|
|
},
|
|
"data": {
|
|
"type": "object",
|
|
"required": [
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"data": {
|
|
"type": "object",
|
|
"required": [
|
|
"message"
|
|
],
|
|
"properties": {
|
|
"message": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"delete": {
|
|
"operationId": "app_config-delete-key",
|
|
"summary": "Delete a config key of an app",
|
|
"description": "This endpoint requires admin access\nThis endpoint requires password confirmation",
|
|
"tags": [
|
|
"app_config"
|
|
],
|
|
"security": [
|
|
{
|
|
"bearer_auth": []
|
|
},
|
|
{
|
|
"basic_auth": []
|
|
}
|
|
],
|
|
"parameters": [
|
|
{
|
|
"name": "app",
|
|
"in": "path",
|
|
"description": "ID of the app",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"name": "key",
|
|
"in": "path",
|
|
"description": "Key to delete",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"name": "OCS-APIRequest",
|
|
"in": "header",
|
|
"description": "Required to be true for the API request to pass",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "boolean",
|
|
"default": true
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Key deleted successfully",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"ocs"
|
|
],
|
|
"properties": {
|
|
"ocs": {
|
|
"type": "object",
|
|
"required": [
|
|
"meta",
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"meta": {
|
|
"$ref": "#/components/schemas/OCSMeta"
|
|
},
|
|
"data": {}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "App or key is not allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"required": [
|
|
"ocs"
|
|
],
|
|
"properties": {
|
|
"ocs": {
|
|
"type": "object",
|
|
"required": [
|
|
"meta",
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"meta": {
|
|
"$ref": "#/components/schemas/OCSMeta"
|
|
},
|
|
"data": {
|
|
"type": "object",
|
|
"required": [
|
|
"data"
|
|
],
|
|
"properties": {
|
|
"data": {
|
|
"type": "object",
|
|
"required": [
|
|
"message"
|
|
],
|
|
"properties": {
|
|
"message": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"tags": []
|
|
}
|