A framework for building convergent cross-platform Nextcloud clients using Flutter.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1343 lines
43 KiB

3 years ago
{
"openapi": "3.1.0",
3 years ago
"info": {
"title": "Core",
"version": "25.0.0",
3 years ago
"description": "Core functionality of Nextcloud",
"license": {
"name": "agpl",
"identifier": " AGPL-3.0"
3 years ago
}
},
"servers": [
{
"url": "https://{hostname}:{port}",
"variables": {
"hostname": {
"default": "localhost"
},
"port": {
"default": "8080"
}
}
}
],
"security": [
{
"basic_auth": []
}
],
"tags": [
{
"name": "core"
}
],
3 years ago
"components": {
"schemas": {
"OCSMeta": {
"type": "object",
"required": [
"status",
"statuscode",
"totalitems",
"itemsperpage"
],
"properties": {
"status": {
"type": "string"
},
"statuscode": {
"type": "integer"
},
"message": {
"type": "string"
},
"totalitems": {
"type": "string"
},
"itemsperpage": {
"type": "string"
}
}
3 years ago
},
"CoreServerStatus": {
"type": "object",
"required": [
"installed",
"maintenance",
"needsDbUpgrade",
"version",
"versionstring",
"edition",
"productname",
"extendedSupport"
],
3 years ago
"properties": {
"installed": {
"type": "boolean"
},
"maintenance": {
"type": "boolean"
},
"needsDbUpgrade": {
"type": "boolean"
},
"version": {
"type": "string"
},
"versionstring": {
"type": "string"
},
"edition": {
"type": "string"
},
"productname": {
"type": "string"
},
"extendedSupport": {
"type": "boolean"
}
}
},
"CoreServerCapabilities": {
"type": "object",
"required": [
"ocs"
],
3 years ago
"properties": {
"ocs": {
"type": "object",
"required": [
"meta",
"data"
],
3 years ago
"properties": {
"meta": {
"$ref": "#/components/schemas/OCSMeta"
},
"data": {
"type": "object",
"required": [
"version",
"capabilities"
],
3 years ago
"properties": {
"version": {
"type": "object",
"required": [
"major",
"minor",
"micro",
"string",
"edition",
"extendedSupport"
],
3 years ago
"properties": {
"major": {
"type": "integer"
},
"minor": {
"type": "integer"
},
"micro": {
"type": "integer"
},
"string": {
"type": "string"
},
"edition": {
"type": "string"
},
"extendedSupport": {
"type": "boolean"
}
}
},
"capabilities": {
"type": "object",
"required": [
"core",
"bruteforce",
"metadataAvailable",
"files",
"ocm",
"dav"
],
3 years ago
"properties": {
"core": {
"type": "object",
"required": [
"pollinterval",
"webdav-root",
"reference-api",
"reference-regex"
],
3 years ago
"properties": {
"pollinterval": {
"type": "integer"
},
"webdav-root": {
"type": "string"
},
"reference-api": {
"type": "boolean"
},
"reference-regex": {
"type": "string"
3 years ago
}
}
},
"bruteforce": {
"type": "object",
"required": [
"delay"
],
3 years ago
"properties": {
"delay": {
"type": "integer"
}
}
},
"metadataAvailable": {
3 years ago
"type": "object",
"required": [
"size"
],
3 years ago
"properties": {
"size": {
"type": "array",
"items": {
"type": "string"
}
}
}
},
"files": {
"type": "object",
"required": [
"bigfilechunking",
"blacklisted_files",
"directEditing",
"comments",
"undelete",
"versioning"
],
3 years ago
"properties": {
"bigfilechunking": {
"type": "boolean"
},
"blacklisted_files": {
"type": "array",
"items": {
"type": "string"
}
},
"directEditing": {
"type": "object",
"required": [
"url",
"etag"
],
3 years ago
"properties": {
"url": {
"type": "string"
},
"etag": {
"type": "string"
}
}
},
"comments": {
"type": "boolean"
},
"undelete": {
"type": "boolean"
},
"versioning": {
"type": "boolean"
}
}
},
"activity": {
"type": "object",
"required": [
"apiv2"
],
3 years ago
"properties": {
"apiv2": {
"type": "array",
"items": {
"type": "string"
}
}
}
},
"circles": {
"type": "object",
"required": [
"version",
"status",
"settings",
"circle",
"member"
],
3 years ago
"properties": {
"version": {
"type": "string"
},
"status": {
"type": "object",
"required": [
"globalScale"
],
3 years ago
"properties": {
"globalScale": {
"type": "boolean"
}
}
},
"settings": {
"type": "object",
"required": [
"frontendEnabled",
"allowedCircles",
"allowedUserTypes",
"membersLimit"
],
3 years ago
"properties": {
"frontendEnabled": {
"type": "boolean"
},
"allowedCircles": {
"type": "integer"
},
"allowedUserTypes": {
"type": "integer"
},
"membersLimit": {
"type": "integer"
}
}
},
"circle": {
"type": "object",
"required": [
"constants",
"config"
],
3 years ago
"properties": {
"constants": {
"type": "object",
"required": [
"flags",
"source"
],
3 years ago
"properties": {
"flags": {
"type": "object"
},
"source": {
"type": "object",
"required": [
"core",
"extra"
],
3 years ago
"properties": {
"core": {
"type": "object"
},
"extra": {
"type": "object"
}
}
}
}
},
"config": {
"type": "object",
"required": [
"coreFlags",
"systemFlags"
],
3 years ago
"properties": {
"coreFlags": {
"type": "array",
"items": {
"type": "integer"
}
},
"systemFlags": {
"type": "array",
"items": {
"type": "integer"
}
}
}
}
}
},
"member": {
"type": "object",
"required": [
"constants",
"type"
],
3 years ago
"properties": {
"constants": {
"type": "object",
"required": [
"level"
],
3 years ago
"properties": {
"level": {
"type": "object"
}
}
},
"type": {
"type": "object"
}
}
}
}
},
"ocm": {
"type": "object",
"required": [
"enabled",
"apiVersion",
"endPoint",
"resourceTypes"
],
3 years ago
"properties": {
"enabled": {
"type": "boolean"
},
"apiVersion": {
"type": "string"
},
"endPoint": {
"type": "string"
},
"resourceTypes": {
"type": "array",
"items": {
"type": "object",
"required": [
"name",
"shareTypes",
"protocols"
],
3 years ago
"properties": {
"name": {
"type": "string"
},
"shareTypes": {
"type": "array",
"items": {
"type": "string"
}
},
"protocols": {
"type": "object",
"required": [
"webdav"
],
3 years ago
"properties": {
"webdav": {
"type": "string"
}
}
}
}
}
}
}
},
"dav": {
"type": "object",
"required": [
"chunking"
],
3 years ago
"properties": {
"bulkupload": {
"type": "string"
},
3 years ago
"chunking": {
"type": "string"
}
}
},
"files_sharing": {
"type": "object",
"required": [
"api_enabled",
"public",
"resharing",
"user",
"group_sharing",
"group",
"default_permissions",
"federation",
"sharee",
"sharebymail"
],
3 years ago
"properties": {
"api_enabled": {
"type": "boolean"
},
"public": {
"type": "object",
"required": [
"enabled",
"password",
"expire_date",
"multiple_links",
"expire_date_internal",
"expire_date_remote",
"send_mail",
"upload",
"upload_files_drop"
],
3 years ago
"properties": {
"enabled": {
"type": "boolean"
},
"password": {
"type": "object",
"required": [
"enforced",
"askForOptionalPassword"
],
3 years ago
"properties": {
"enforced": {
"type": "boolean"
},
"askForOptionalPassword": {
"type": "boolean"
}
}
},
"expire_date": {
"type": "object",
"required": [
"enabled"
],
3 years ago
"properties": {
"enabled": {
"type": "boolean"
}
}
},
"multiple_links": {
"type": "boolean"
},
"expire_date_internal": {
"type": "object",
"required": [
"enabled"
],
3 years ago
"properties": {
"enabled": {
"type": "boolean"
}
}
},
"expire_date_remote": {
"type": "object",
"required": [
"enabled"
],
3 years ago
"properties": {
"enabled": {
"type": "boolean"
}
}
},
"send_mail": {
"type": "boolean"
},
"upload": {
"type": "boolean"
},
"upload_files_drop": {
"type": "boolean"
}
}
},
"resharing": {
"type": "boolean"
},
"user": {
"type": "object",
"required": [
"send_mail",
"expire_date"
],
3 years ago
"properties": {
"send_mail": {
"type": "boolean"
},
"expire_date": {
"type": "object",
"required": [
"enabled"
],
3 years ago
"properties": {
"enabled": {
"type": "boolean"
}
}
}
}
},
"group_sharing": {
"type": "boolean"
},
"group": {
"type": "object",
"required": [
"enabled",
"expire_date"
],
3 years ago
"properties": {
"enabled": {
"type": "boolean"
},
"expire_date": {
"type": "object",
"required": [
"enabled"
],
3 years ago
"properties": {
"enabled": {
"type": "boolean"
}
}
}
}
},
"default_permissions": {
"type": "integer"
},
"federation": {
"type": "object",
"required": [
"outgoing",
"incoming",
"expire_date",
"expire_date_supported"
],
3 years ago
"properties": {
"outgoing": {
"type": "boolean"
},
"incoming": {
"type": "boolean"
},
"expire_date": {
"type": "object",
"required": [
"enabled"
],
3 years ago
"properties": {
"enabled": {
"type": "boolean"
}
}
},
"expire_date_supported": {
"type": "object",
"required": [
"enabled"
],
3 years ago
"properties": {
"enabled": {
"type": "boolean"
}
}
}
}
},
"sharee": {
"type": "object",
"required": [
"query_lookup_default",
"always_show_unique"
],
3 years ago
"properties": {
"query_lookup_default": {
"type": "boolean"
},
"always_show_unique": {
"type": "boolean"
}
}
},
"sharebymail": {
"type": "object",
"required": [
"enabled",
"send_password_by_mail",
"upload_files_drop",
"password",
"expire_date"
],
3 years ago
"properties": {
"enabled": {
"type": "boolean"
},
"send_password_by_mail": {
"type": "boolean"
},
"upload_files_drop": {
"type": "object",
"required": [
"enabled"
],
3 years ago
"properties": {
"enabled": {
"type": "boolean"
}
}
},
"password": {
"type": "object",
"required": [
"enabled",
"enforced"
],
3 years ago
"properties": {
"enabled": {
"type": "boolean"
},
"enforced": {
"type": "boolean"
}
}
},
"expire_date": {
"type": "object",
"required": [
"enabled",
"enforced"
],
3 years ago
"properties": {
"enabled": {
"type": "boolean"
},
"enforced": {
"type": "boolean"
}
}
}
}
}
}
},
"notes": {
"type": "object",
"required": [
"api_version",
"version"
],
3 years ago
"properties": {
"api_version": {
"type": "array",
"items": {
"type": "string"
}
},
"version": {
"type": "string"
}
}
},
"notifications": {
"type": "object",
"required": [
"ocs-endpoints",
"push",
"admin-notifications"
],
3 years ago
"properties": {
"ocs-endpoints": {
"type": "array",
"items": {
"type": "string"
}
},
"push": {
"type": "array",
"items": {
"type": "string"
}
},
"admin-notifications": {
"type": "array",
"items": {
"type": "string"
}
}
}
},
"password_policy": {
"type": "object",
"required": [
"minLength",
"enforceNonCommonPassword",
"enforceNumericCharacters",
"enforceSpecialCharacters",
"enforceUpperLowerCase",
"api"
],
3 years ago
"properties": {
"minLength": {
"type": "integer"
},
"enforceNonCommonPassword": {
"type": "boolean"
},
"enforceNumericCharacters": {
"type": "boolean"
},
"enforceSpecialCharacters": {
"type": "boolean"
},
"enforceUpperLowerCase": {
"type": "boolean"
},
"api": {
"type": "object",
"required": [
"generate",
"validate"
],
3 years ago
"properties": {
"generate": {
"type": "string"
},
"validate": {
"type": "string"
}
}
}
}
},
"provisioning_api": {
"type": "object",
"required": [
"version",
"AccountPropertyScopesVersion",
"AccountPropertyScopesFederatedEnabled",
"AccountPropertyScopesPublishedEnabled"
],
3 years ago
"properties": {
"version": {
"type": "string"
},
"AccountPropertyScopesVersion": {
"type": "integer"
},
"AccountPropertyScopesFederatedEnabled": {
"type": "boolean"
},
"AccountPropertyScopesPublishedEnabled": {
"type": "boolean"
}
}
},
"theming": {
"type": "object",
"required": [
"name",
"url",
"slogan",
"color",
"color-text",
"color-element",
"color-element-bright",
"color-element-dark",
"logo",
"background",
"background-plain",
"background-default",
"logoheader",
"favicon"
],
3 years ago
"properties": {
"name": {
"type": "string"
},
"url": {
"type": "string"
},
"slogan": {
"type": "string"
},
"color": {
"type": "string"
},
"color-text": {
"type": "string"
},
"color-element": {
"type": "string"
},
"color-element-bright": {
"type": "string"
},
"color-element-dark": {
"type": "string"
},
"logo": {
"type": "string"
},
"background": {
"type": "string"
},
"background-plain": {
"type": "boolean"
},
"background-default": {
"type": "boolean"
},
"logoheader": {
"type": "string"
},
"favicon": {
"type": "string"
}
}
},
"user_status": {
"type": "object",
"required": [
"enabled",
"supports_emoji"
],
3 years ago
"properties": {
"enabled": {
"type": "boolean"
},
"supports_emoji": {
"type": "boolean"
}
}
},
"weather_status": {
"type": "object",
"required": [
"enabled"
],
3 years ago
"properties": {
"enabled": {
"type": "boolean"
}
}
}
}
}
}
}
}
}
}
},
"CoreNavigationApps": {
"type": "object",
"required": [
"ocs"
],
3 years ago
"properties": {
"ocs": {
"type": "object",
"required": [
"meta",
"data"
],
3 years ago
"properties": {
"meta": {
"$ref": "#/components/schemas/OCSMeta"
},
"data": {
"type": "array",
"items": {
"type": "object",
"required": [
"id",
"order",
"href",
"icon",
"type",
"name",
"active",
"classes",
"unread"
],
3 years ago
"properties": {
"id": {
"type": "string"
},
"order": {
"description": "Should always be an integer, but there is a bug. See https://github.com/nextcloud/server/issues/32828",
"oneOf": [
{
"type": "integer"
},
{
"type": "string"
}
]
3 years ago
},
"href": {
"type": "string"
},
"icon": {
"type": "string"
},
"type": {
"type": "string"
},
"name": {
"type": "string"
},
"active": {
"type": "boolean"
},
"classes": {
"type": "string"
},
"unread": {
"type": "integer"
}
}
}
}
}
}
}
},
"CoreLoginFlowInit": {
"type": "object",
"required": [
"poll",
"login"
],
3 years ago
"properties": {
"poll": {
"type": "object",
"required": [
"token",
"endpoint"
],
3 years ago
"properties": {
"token": {
"type": "string"
},
"endpoint": {
"type": "string"
}
}
},
"login": {
"type": "string"
}
}
},
"CoreLoginFlowResult": {
"type": "object",
"required": [
"server",
"loginName",
"appPassword"
],
3 years ago
"properties": {
"server": {
"type": "string"
},
"loginName": {
"type": "string"
},
"appPassword": {
"type": "string"
}
}
}
},
"securitySchemes": {
"basic_auth": {
"type": "http",
"scheme": "basic"
}
3 years ago
}
},
"paths": {
"/status.php": {
"get": {
"operationId": "get-status",
"tags": [
"core"
],
3 years ago
"responses": {
"200": {
"description": "Status of the Nextcloud instance",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/CoreServerStatus"
}
}
}
}
}
}
},
"/ocs/v1.php/cloud/capabilities": {
"get": {
"operationId": "get-capabilities",
"tags": [
"core"
],
3 years ago
"responses": {
"200": {
"description": "Capabilities of the Nextcloud instance",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/CoreServerCapabilities"
}
}
}
}
}
}
},
"/ocs/v1.php/core/navigation/apps": {
"get": {
"operationId": "get-navigation-apps",
"tags": [
"core"
],
3 years ago
"responses": {
"200": {
"description": "Navigation apps of the Nextcloud instance",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/CoreNavigationApps"
}
}
}
}
}
}
},
"/index.php/login/v2": {
3 years ago
"post": {
"operationId": "init-login-flow",
"tags": [
"core"
],
3 years ago
"responses": {
"200": {
"description": "Login flow init",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/CoreLoginFlowInit"
}
}
}
}
}
}
},
"/index.php/login/v2/poll": {
3 years ago
"post": {
"operationId": "get-login-flow-result",
"tags": [
"core"
],
"parameters": [
{
"name": "token",
"in": "query",
"required": true,
"schema": {
"type": "string"
3 years ago
}
}
],
3 years ago
"responses": {
"200": {
"description": "Login flow result",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/CoreLoginFlowResult"
}
}
}
}
}
}
},
"/index.php/core/preview.png": {
3 years ago
"parameters": [
{
"name": "file",
"in": "query",
"required": false,
3 years ago
"schema": {
"type": "string",
"default": ""
3 years ago
}
},
{
"name": "x",
"in": "query",
"required": false,
3 years ago
"schema": {
"type": "integer",
"default": 32
3 years ago
}
},
{
"name": "y",
"in": "query",
"required": false,
3 years ago
"schema": {
"type": "integer",
"default": 32
3 years ago
}
},
{
"name": "a",
3 years ago
"in": "query",
"required": false,
3 years ago
"schema": {
"type": "integer",
"default": 0
3 years ago
}
},
{
"name": "forceIcon",
"in": "query",
"required": false,
3 years ago
"schema": {
"type": "integer",
"default": 1
3 years ago
}
},
{
"name": "mode",
3 years ago
"in": "query",
"required": false,
3 years ago
"schema": {
"type": "string",
"default": "fill"
3 years ago
}
}
],
"get": {
"operationId": "get-preview",
"tags": [
"core"
],
3 years ago
"responses": {
"200": {
"description": "Preview image of a file",
"content": {
"image/png": {
"schema": {
"type": "string",
"format": "binary"
}
}
}
}
}
}
},
"/index.php/avatar/{userId}/{size}/dark": {
"parameters": [
{
"name": "userId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "size",
"in": "path",
"required": true,
"schema": {
"type": "integer"
}
}
],
"get": {
"operationId": "get-dark-avatar",
"tags": [
"core"
],
"responses": {
"200": {
"description": "",
"content": {
3 years ago
"image/png": {
"schema": {
"type": "string",
"format": "binary"
3 years ago
}
}
}
}
}
}
},
"/index.php/avatar/{userId}/{size}": {
3 years ago
"parameters": [
{
"name": "userId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "size",
"in": "path",
"required": true,
"schema": {
"type": "integer"
}
}
],
"get": {
"operationId": "get-avatar",
"tags": [
"core"
],
3 years ago
"responses": {
"200": {
"description": "",
"content": {
"image/png": {
3 years ago
"schema": {
"type": "string",
"format": "binary"
3 years ago
}
}
}
}
}
}
}
}
}