mirror of
https://github.com/azukaar/Cosmos-Server.git
synced 2026-05-19 11:58:33 -05:00
12343 lines
314 KiB
JSON
12343 lines
314 KiB
JSON
{
|
|
"openapi": "3.0.0",
|
|
"info": {
|
|
"description": "REST API for Cosmos Cloud server management",
|
|
"title": "Cosmos Server API",
|
|
"contact": {},
|
|
"version": "0.22.0-unstable16"
|
|
},
|
|
"paths": {
|
|
"/_logs": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Returns the server log file as a plain text attachment",
|
|
"tags": [
|
|
"system"
|
|
],
|
|
"summary": "Download server logs",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"text/plain": {
|
|
"schema": {
|
|
"type": "string",
|
|
"format": "binary"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"text/plain": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"text/plain": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"text/plain": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/_memory": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Returns memory usage details for internal caches and buffers",
|
|
"tags": [
|
|
"system"
|
|
],
|
|
"summary": "Get internal memory status",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/alerts": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Metrics"
|
|
],
|
|
"summary": "List or create monitoring alerts",
|
|
"requestBody": {
|
|
"$ref": "#/components/requestBodies/utils.Alert"
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"409": {
|
|
"description": "Conflict",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Metrics"
|
|
],
|
|
"summary": "List or create monitoring alerts",
|
|
"requestBody": {
|
|
"$ref": "#/components/requestBodies/utils.Alert"
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"409": {
|
|
"description": "Conflict",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/alerts/{name}": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Metrics"
|
|
],
|
|
"summary": "Get, update, or delete a monitoring alert by name",
|
|
"parameters": [
|
|
{
|
|
"description": "Alert name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"$ref": "#/components/requestBodies/utils.Alert2"
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"put": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Metrics"
|
|
],
|
|
"summary": "Get, update, or delete a monitoring alert by name",
|
|
"parameters": [
|
|
{
|
|
"description": "Alert name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"$ref": "#/components/requestBodies/utils.Alert2"
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"delete": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Metrics"
|
|
],
|
|
"summary": "Get, update, or delete a monitoring alert by name",
|
|
"parameters": [
|
|
{
|
|
"description": "Alert name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"$ref": "#/components/requestBodies/utils.Alert2"
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/api-tokens": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Returns all configured API tokens (without the actual token hashes)",
|
|
"tags": [
|
|
"api-tokens"
|
|
],
|
|
"summary": "List all API tokens",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Generates a new API token with the specified permissions and returns the raw token (shown only once)",
|
|
"tags": [
|
|
"api-tokens"
|
|
],
|
|
"summary": "Create a new API token",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/configapi.CreateAPITokenRequest"
|
|
}
|
|
}
|
|
},
|
|
"description": "Token creation details",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"409": {
|
|
"description": "Conflict",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"delete": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Removes an API token by name",
|
|
"tags": [
|
|
"api-tokens"
|
|
],
|
|
"summary": "Delete an API token",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/configapi.DeleteAPITokenRequest"
|
|
}
|
|
}
|
|
},
|
|
"description": "Token name to delete",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/api-tokens/{name}": {
|
|
"put": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Updates an existing API token's description, permissions, IP whitelist, or constellation restriction",
|
|
"tags": [
|
|
"api-tokens"
|
|
],
|
|
"summary": "Update an API token",
|
|
"parameters": [
|
|
{
|
|
"description": "Token name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/configapi.UpdateAPITokenRequest"
|
|
}
|
|
}
|
|
},
|
|
"description": "Fields to update",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/backups": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Creates a backup config and initializes the repository if needed. Requires premium licence and non-container mode.",
|
|
"tags": [
|
|
"Backups"
|
|
],
|
|
"summary": "Create a new backup configuration",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.SingleBackupConfig"
|
|
}
|
|
}
|
|
},
|
|
"description": "Backup configuration",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/backups-config": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Returns a map of all backup configurations from the server config, keyed by backup name.",
|
|
"tags": [
|
|
"Backups"
|
|
],
|
|
"summary": "List all backup configurations",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/backups-config/{name}": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Returns a single backup configuration from the server config.",
|
|
"tags": [
|
|
"Backups"
|
|
],
|
|
"summary": "Get a single backup configuration by name",
|
|
"parameters": [
|
|
{
|
|
"description": "Backup name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/backups-repository": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Backups"
|
|
],
|
|
"summary": "List all backup repositories with their lock status",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/backups-repository/{name}/snapshots": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Backups"
|
|
],
|
|
"summary": "List all snapshots in a backup repository (all backup tags)",
|
|
"parameters": [
|
|
{
|
|
"description": "Backup name (used to resolve repository)",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/backups-repository/{name}/stats": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Backups"
|
|
],
|
|
"summary": "Get repository statistics (size, file count, etc.)",
|
|
"parameters": [
|
|
{
|
|
"description": "Backup name (used to resolve repository)",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/backups/edit": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Backups"
|
|
],
|
|
"summary": "Edit an existing backup configuration",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.SingleBackupConfig"
|
|
}
|
|
}
|
|
},
|
|
"description": "Updated backup configuration",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/backups/{name}": {
|
|
"delete": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Backups"
|
|
],
|
|
"summary": "Remove a backup configuration and its snapshots",
|
|
"parameters": [
|
|
{
|
|
"description": "Backup name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/backups/{name}/restore": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Backups"
|
|
],
|
|
"summary": "Restore files from a backup snapshot",
|
|
"parameters": [
|
|
{
|
|
"description": "Backup name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object"
|
|
}
|
|
}
|
|
},
|
|
"description": "Restore request with snapshotId, target, and optional include paths",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/backups/{name}/snapshots": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Backups"
|
|
],
|
|
"summary": "List snapshots for a specific backup",
|
|
"parameters": [
|
|
{
|
|
"description": "Backup name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/backups/{name}/unlock": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Backups"
|
|
],
|
|
"summary": "Unlock a backup repository (remove stale locks)",
|
|
"parameters": [
|
|
{
|
|
"description": "Backup name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/backups/{name}/{snapshot}/folders": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Backups"
|
|
],
|
|
"summary": "List folders in a backup snapshot",
|
|
"parameters": [
|
|
{
|
|
"description": "Backup name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Snapshot ID",
|
|
"name": "snapshot",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Directory path within the snapshot",
|
|
"name": "path",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/backups/{name}/{snapshot}/forget": {
|
|
"delete": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Backups"
|
|
],
|
|
"summary": "Forget (delete) a specific snapshot from a backup repository",
|
|
"parameters": [
|
|
{
|
|
"description": "Backup name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Snapshot ID to forget",
|
|
"name": "snapshot",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/backups/{name}/{snapshot}/subfolder-restore-size": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Backups"
|
|
],
|
|
"summary": "Get restore size stats for a subfolder within a snapshot",
|
|
"parameters": [
|
|
{
|
|
"description": "Backup name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Snapshot ID",
|
|
"name": "snapshot",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Subfolder path within the snapshot",
|
|
"name": "path",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/can-send-email": {
|
|
"get": {
|
|
"description": "Returns whether the server has email sending capabilities configured",
|
|
"tags": [
|
|
"system"
|
|
],
|
|
"summary": "Check if email sending is enabled",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/config": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Returns the full server configuration (sensitive fields masked for non-credential users)",
|
|
"tags": [
|
|
"config"
|
|
],
|
|
"summary": "Get server configuration",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"data": {
|
|
"$ref": "#/components/schemas/github_com_azukaar_cosmos-server_src_utils.Config"
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"put": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Replaces the entire server configuration (masked credential fields are preserved from existing config)",
|
|
"tags": [
|
|
"config"
|
|
],
|
|
"summary": "Update server configuration",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/github_com_azukaar_cosmos-server_src_utils.Config"
|
|
}
|
|
}
|
|
},
|
|
"description": "Full configuration object",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"patch": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Performs route operations (add, replace, delete, move_up, move_down) on proxy routes",
|
|
"tags": [
|
|
"config"
|
|
],
|
|
"summary": "Patch route configuration",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/configapi.UpdateRouteRequest"
|
|
}
|
|
}
|
|
},
|
|
"description": "Route update operation",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/config/dns": {
|
|
"patch": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Patches DNS-related settings including port, fallback, blocklists, and custom entries",
|
|
"tags": [
|
|
"config"
|
|
],
|
|
"summary": "Update DNS configuration",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/configapi.DNSConfigRequest"
|
|
}
|
|
}
|
|
},
|
|
"description": "DNS configuration fields to update",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/constellation/block": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"constellation"
|
|
],
|
|
"summary": "Block or unblock a Constellation device",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/constellation.DeviceBlockRequestJSON"
|
|
}
|
|
}
|
|
},
|
|
"description": "Device block/unblock payload",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/constellation/config": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"constellation"
|
|
],
|
|
"summary": "Get the current Nebula configuration",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/constellation/connect": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"constellation"
|
|
],
|
|
"summary": "Connect this node to an existing Constellation VPN network",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/x-yaml": {
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"description": "Nebula YAML configuration",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/constellation/create": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"constellation"
|
|
],
|
|
"summary": "Create a new Constellation VPN network",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object"
|
|
}
|
|
}
|
|
},
|
|
"description": "Constellation creation payload (deviceName, isLighthouse, hostname, ipRange)",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/constellation/devices": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"constellation"
|
|
],
|
|
"summary": "List Constellation devices for the current user (or all if admin)",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"constellation"
|
|
],
|
|
"summary": "Create a new Constellation device and generate its certificates",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/constellation.DeviceCreateRequestJSON"
|
|
}
|
|
}
|
|
},
|
|
"description": "Device creation payload",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/constellation/devices/{id}/ping": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"constellation"
|
|
],
|
|
"summary": "Ping a Constellation device to check reachability",
|
|
"parameters": [
|
|
{
|
|
"description": "Device name/ID",
|
|
"name": "id",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/constellation/dns": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"constellation"
|
|
],
|
|
"summary": "List all custom Constellation DNS entries",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"constellation"
|
|
],
|
|
"summary": "Create a new Constellation DNS entry",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.ConstellationDNSEntry"
|
|
}
|
|
}
|
|
},
|
|
"description": "DNS entry to create",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"409": {
|
|
"description": "Conflict",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/constellation/dns/{key}": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"constellation"
|
|
],
|
|
"summary": "Get a single Constellation DNS entry by key",
|
|
"parameters": [
|
|
{
|
|
"description": "DNS entry key",
|
|
"name": "key",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"put": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"constellation"
|
|
],
|
|
"summary": "Update an existing Constellation DNS entry",
|
|
"parameters": [
|
|
{
|
|
"description": "DNS entry key",
|
|
"name": "key",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.ConstellationDNSEntry"
|
|
}
|
|
}
|
|
},
|
|
"description": "Updated DNS entry",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"delete": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"constellation"
|
|
],
|
|
"summary": "Delete a Constellation DNS entry by key",
|
|
"parameters": [
|
|
{
|
|
"description": "DNS entry key",
|
|
"name": "key",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/constellation/edit-device": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"constellation"
|
|
],
|
|
"summary": "Edit the current Constellation device properties",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/constellation.DeviceEditRequestJSON"
|
|
}
|
|
}
|
|
},
|
|
"description": "Device edit payload",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/constellation/get-next-ip": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"constellation"
|
|
],
|
|
"summary": "Get the next available IP address in the Constellation CIDR range",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/constellation/logs": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"constellation"
|
|
],
|
|
"summary": "Get Nebula VPN service logs",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/constellation/ping": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"constellation"
|
|
],
|
|
"summary": "Check if the NATS client connection is alive",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/constellation/public-devices": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"constellation"
|
|
],
|
|
"summary": "List public information about all non-blocked Constellation devices",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/constellation/reset": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"constellation"
|
|
],
|
|
"summary": "Reset the Nebula VPN configuration",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/constellation/restart": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"constellation"
|
|
],
|
|
"summary": "Restart the Nebula VPN service and HTTP server",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/constellation/tunnels": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"constellation"
|
|
],
|
|
"summary": "List all active Constellation tunnels",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/cron": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Cron"
|
|
],
|
|
"summary": "List or create CRON job configurations",
|
|
"requestBody": {
|
|
"$ref": "#/components/requestBodies/utils.CRONConfig2"
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"409": {
|
|
"description": "Conflict",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Cron"
|
|
],
|
|
"summary": "List or create CRON job configurations",
|
|
"requestBody": {
|
|
"$ref": "#/components/requestBodies/utils.CRONConfig2"
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"409": {
|
|
"description": "Conflict",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/cron/{name}": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Cron"
|
|
],
|
|
"summary": "Get, update, or delete a CRON job configuration by name",
|
|
"parameters": [
|
|
{
|
|
"description": "CRON job name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"$ref": "#/components/requestBodies/utils.CRONConfig"
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"put": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Cron"
|
|
],
|
|
"summary": "Get, update, or delete a CRON job configuration by name",
|
|
"parameters": [
|
|
{
|
|
"description": "CRON job name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"$ref": "#/components/requestBodies/utils.CRONConfig"
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"delete": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Cron"
|
|
],
|
|
"summary": "Get, update, or delete a CRON job configuration by name",
|
|
"parameters": [
|
|
{
|
|
"description": "CRON job name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"$ref": "#/components/requestBodies/utils.CRONConfig"
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/dashboard": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Returns dashboard route information with container status for SERVAPP routes",
|
|
"tags": [
|
|
"config"
|
|
],
|
|
"summary": "Get dashboard data",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"data": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/configapi.DashboardRoute"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/disks": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Storage"
|
|
],
|
|
"summary": "List all disks",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/disks/format": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Formats the specified disk with the given filesystem format. Requires password confirmation. Streams progress output.",
|
|
"tags": [
|
|
"Storage"
|
|
],
|
|
"summary": "Format a disk or partition",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/storage.FormatDiskJSON"
|
|
}
|
|
}
|
|
},
|
|
"description": "Format disk request",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "Streamed text output ending with [OPERATION SUCCEEDED]",
|
|
"content": {
|
|
"text/plain": {
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"text/plain": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"text/plain": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"text/plain": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"text/plain": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/dns": {
|
|
"get": {
|
|
"description": "Performs a DNS lookup for the given URL and returns the resolved IPv4 address",
|
|
"tags": [
|
|
"system"
|
|
],
|
|
"summary": "Resolve DNS for a URL",
|
|
"parameters": [
|
|
{
|
|
"description": "URL to resolve",
|
|
"name": "url",
|
|
"in": "query",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"data": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/dns-check": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Verifies that DNS is correctly configured for the given URL",
|
|
"tags": [
|
|
"system"
|
|
],
|
|
"summary": "Check DNS configuration for a URL",
|
|
"parameters": [
|
|
{
|
|
"description": "URL to check DNS for",
|
|
"name": "url",
|
|
"in": "query",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/docker-service": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "Create a Docker service (compose-like) with networks, volumes, and containers",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/docker.DockerServiceCreateRequest"
|
|
}
|
|
}
|
|
},
|
|
"description": "Service creation payload",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "Streamed creation output",
|
|
"content": {
|
|
"text/plain": {
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"text/plain": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"text/plain": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"text/plain": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/events": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Metrics"
|
|
],
|
|
"summary": "List events with filtering and pagination",
|
|
"parameters": [
|
|
{
|
|
"description": "Start date in RFC3339 format (2006-01-02T15:04:05Z)",
|
|
"name": "from",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "End date in RFC3339 format (2006-01-02T15:04:05Z)",
|
|
"name": "to",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Minimum log level (debug, info, success, warning, important, error)",
|
|
"name": "logLevel",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "string",
|
|
"default": "info"
|
|
}
|
|
},
|
|
{
|
|
"description": "Full-text search term",
|
|
"name": "search",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "BSON query as JSON string",
|
|
"name": "query",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Pagination cursor (ObjectID hex string)",
|
|
"name": "page",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/favicon": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Fetches and caches the favicon for the given URL, returning it as an image",
|
|
"tags": [
|
|
"system"
|
|
],
|
|
"summary": "Get favicon for a URL",
|
|
"parameters": [
|
|
{
|
|
"description": "URL-encoded site URL to fetch favicon for",
|
|
"name": "q",
|
|
"in": "query",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Service app mode flag",
|
|
"name": "servapp",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/octet-stream": {
|
|
"schema": {
|
|
"type": "string",
|
|
"format": "binary"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/octet-stream": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/octet-stream": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/octet-stream": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/force-server-update": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Triggers a manual check for available server updates",
|
|
"tags": [
|
|
"system"
|
|
],
|
|
"summary": "Force check for server updates",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/get-backup": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Returns the backup cosmos-compose JSON file",
|
|
"tags": [
|
|
"config"
|
|
],
|
|
"summary": "Get backup file",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "string",
|
|
"format": "binary"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/image/{name}": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Returns a previously uploaded image by name",
|
|
"tags": [
|
|
"system"
|
|
],
|
|
"summary": "Get an uploaded image",
|
|
"parameters": [
|
|
{
|
|
"description": "Image file name (including extension)",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/octet-stream": {
|
|
"schema": {
|
|
"type": "string",
|
|
"format": "binary"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/octet-stream": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/octet-stream": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/octet-stream": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/octet-stream": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/images": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "Inspect a Docker image by name",
|
|
"parameters": [
|
|
{
|
|
"description": "Name of the Docker image to inspect",
|
|
"name": "imageName",
|
|
"in": "query",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/types.ImageInspect"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/images/pull": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "Pull a Docker image from a registry",
|
|
"parameters": [
|
|
{
|
|
"description": "Name of the Docker image to pull",
|
|
"name": "imageName",
|
|
"in": "query",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Streamed pull output",
|
|
"content": {
|
|
"text/plain": {
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"text/plain": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"text/plain": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/images/pull-if-missing": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "Pull a Docker image only if it is not already present locally",
|
|
"parameters": [
|
|
{
|
|
"description": "Name of the Docker image to pull",
|
|
"name": "imageName",
|
|
"in": "query",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Streamed pull output",
|
|
"content": {
|
|
"text/plain": {
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"text/plain": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"text/plain": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/invite": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Generates a new registration key and optionally sends an invite or password reset email",
|
|
"tags": [
|
|
"users"
|
|
],
|
|
"summary": "Resend invite link",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/user.InviteRequestJSON"
|
|
}
|
|
}
|
|
},
|
|
"description": "Nickname and form type",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/jobs": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Cron"
|
|
],
|
|
"summary": "List all scheduled jobs",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/jobs/delete": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Cron"
|
|
],
|
|
"summary": "Delete a job from the CRON configuration",
|
|
"requestBody": {
|
|
"$ref": "#/components/requestBodies/cron.JobRequestJSON"
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/jobs/get": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Cron"
|
|
],
|
|
"summary": "Get details and logs of a specific job",
|
|
"requestBody": {
|
|
"$ref": "#/components/requestBodies/cron.JobRequestJSON"
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/jobs/run": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Cron"
|
|
],
|
|
"summary": "Manually trigger a job to run",
|
|
"requestBody": {
|
|
"$ref": "#/components/requestBodies/cron.JobRequestJSON"
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/jobs/running": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Cron"
|
|
],
|
|
"summary": "List currently running jobs",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/jobs/stop": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Cron"
|
|
],
|
|
"summary": "Stop a running job",
|
|
"requestBody": {
|
|
"$ref": "#/components/requestBodies/cron.JobRequestJSON"
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/list-dir": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Storage"
|
|
],
|
|
"summary": "List the contents of a directory",
|
|
"parameters": [
|
|
{
|
|
"description": "Storage name (default: local)",
|
|
"name": "storage",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Directory path (default: /)",
|
|
"name": "path",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/list-metrics": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Metrics"
|
|
],
|
|
"summary": "List all available metric keys and their labels",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/login": {
|
|
"post": {
|
|
"description": "Authenticates a user with nickname and password, sets JWT cookie on success",
|
|
"tags": [
|
|
"auth"
|
|
],
|
|
"summary": "User login",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/user.LoginRequestJSON"
|
|
}
|
|
}
|
|
},
|
|
"description": "Login credentials",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/logout": {
|
|
"get": {
|
|
"description": "Logs out the current user by clearing authentication cookies",
|
|
"tags": [
|
|
"auth"
|
|
],
|
|
"summary": "User logout",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/markets": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Returns all marketplace sources and their applications, plus the showcase from cosmos-cloud.",
|
|
"tags": [
|
|
"Market"
|
|
],
|
|
"summary": "Get the app marketplace listings",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/me": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Returns the profile information of the currently authenticated user",
|
|
"tags": [
|
|
"auth"
|
|
],
|
|
"summary": "Get current user info",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"data": {
|
|
"$ref": "#/components/schemas/utils.User"
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/merge": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Storage"
|
|
],
|
|
"summary": "Merge multiple filesystems using MergerFS",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/storage.MergeRequest"
|
|
}
|
|
}
|
|
},
|
|
"description": "Merge request",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/metrics": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Metrics"
|
|
],
|
|
"summary": "Get aggregated metrics data",
|
|
"parameters": [
|
|
{
|
|
"description": "Comma-separated list of metric keys to retrieve",
|
|
"name": "metrics",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/mfa": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Generates a new TOTP key for the current user and returns the provisioning URL",
|
|
"tags": [
|
|
"auth"
|
|
],
|
|
"summary": "Generate new 2FA key",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Validates a TOTP token for the current user to complete multi-factor authentication",
|
|
"tags": [
|
|
"auth"
|
|
],
|
|
"summary": "Verify 2FA token",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/user.User2FACheckRequest"
|
|
}
|
|
}
|
|
},
|
|
"description": "TOTP token",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"delete": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Removes the 2FA key for a specified user (admin operation)",
|
|
"tags": [
|
|
"auth"
|
|
],
|
|
"summary": "Reset 2FA for a user",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/user.User2FAResetRequest"
|
|
}
|
|
}
|
|
},
|
|
"description": "Nickname of the user to reset 2FA for",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/migrate-host": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "Migrate Cosmos container to host network mode",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/docker.migrateToHostMode"
|
|
}
|
|
}
|
|
},
|
|
"description": "HTTP and HTTPS port configuration",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/mount": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Storage"
|
|
],
|
|
"summary": "Mount a filesystem",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/storage.MountRequest"
|
|
}
|
|
}
|
|
},
|
|
"description": "Mount request",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/mounts": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Storage"
|
|
],
|
|
"summary": "List all mounted filesystems",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/network/{networkID}": {
|
|
"delete": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "Delete a Docker network by ID",
|
|
"parameters": [
|
|
{
|
|
"description": "Network ID",
|
|
"name": "networkID",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/networks": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "List all Docker networks",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "Create a new Docker network",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/docker.createNetworkPayload"
|
|
}
|
|
}
|
|
},
|
|
"description": "Network creation payload",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/new-dir": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Storage"
|
|
],
|
|
"summary": "Create a new folder",
|
|
"parameters": [
|
|
{
|
|
"description": "Storage name",
|
|
"name": "storage",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Parent directory path",
|
|
"name": "path",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Folder name to create",
|
|
"name": "folder",
|
|
"in": "query",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/newInstall": {
|
|
"post": {
|
|
"description": "Handles multi-step server installation including database setup, HTTPS configuration, and admin user creation",
|
|
"tags": [
|
|
"system"
|
|
],
|
|
"summary": "Process new installation steps",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/main.NewInstallJSON"
|
|
}
|
|
}
|
|
},
|
|
"description": "Installation step data",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/notifications": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Notifications"
|
|
],
|
|
"summary": "Get notifications for the authenticated user",
|
|
"parameters": [
|
|
{
|
|
"description": "Pagination cursor (ObjectID hex string for older notifications)",
|
|
"name": "from",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/notifications/read": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Notifications"
|
|
],
|
|
"summary": "Mark notifications as read",
|
|
"parameters": [
|
|
{
|
|
"description": "Comma-separated list of notification ObjectID hex strings",
|
|
"name": "ids",
|
|
"in": "query",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/openid": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Returns all configured OpenID Connect client configurations",
|
|
"tags": [
|
|
"openid"
|
|
],
|
|
"summary": "List all OpenID clients",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"data": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/utils.OpenIDClient"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Creates a new OpenID Connect client configuration",
|
|
"tags": [
|
|
"openid"
|
|
],
|
|
"summary": "Create an OpenID client",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.OpenIDClient"
|
|
}
|
|
}
|
|
},
|
|
"description": "OpenID client configuration",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"data": {
|
|
"$ref": "#/components/schemas/utils.OpenIDClient"
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"409": {
|
|
"description": "Conflict",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/openid/{id}": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Returns a single OpenID Connect client configuration",
|
|
"tags": [
|
|
"openid"
|
|
],
|
|
"summary": "Get an OpenID client by ID",
|
|
"parameters": [
|
|
{
|
|
"description": "OpenID client ID",
|
|
"name": "id",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"data": {
|
|
"$ref": "#/components/schemas/utils.OpenIDClient"
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"put": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Replaces an existing OpenID Connect client configuration",
|
|
"tags": [
|
|
"openid"
|
|
],
|
|
"summary": "Update an OpenID client",
|
|
"parameters": [
|
|
{
|
|
"description": "OpenID client ID",
|
|
"name": "id",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.OpenIDClient"
|
|
}
|
|
}
|
|
},
|
|
"description": "Updated OpenID client configuration",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"data": {
|
|
"$ref": "#/components/schemas/utils.OpenIDClient"
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"delete": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Removes an OpenID Connect client configuration by ID",
|
|
"tags": [
|
|
"openid"
|
|
],
|
|
"summary": "Delete an OpenID client",
|
|
"parameters": [
|
|
{
|
|
"description": "OpenID client ID",
|
|
"name": "id",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/password-reset": {
|
|
"post": {
|
|
"description": "Sends a password reset email to the user if email is configured",
|
|
"tags": [
|
|
"auth"
|
|
],
|
|
"summary": "Request a password reset",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/user.PasswordResetRequestJSON"
|
|
}
|
|
}
|
|
},
|
|
"description": "Nickname and email for password reset",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/ping": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Checks if a URL is reachable and returns a non-5xx response",
|
|
"tags": [
|
|
"system"
|
|
],
|
|
"summary": "Ping a URL",
|
|
"parameters": [
|
|
{
|
|
"description": "URL-encoded site URL to ping",
|
|
"name": "q",
|
|
"in": "query",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Service app mode flag",
|
|
"name": "servapp",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/rclone-restart": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Storage"
|
|
],
|
|
"summary": "Restart all RClone remote storage mounts",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/register": {
|
|
"post": {
|
|
"description": "Completes user registration using a registration key (invite link)",
|
|
"tags": [
|
|
"auth"
|
|
],
|
|
"summary": "Register a new user",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/user.RegisterRequestJSON"
|
|
}
|
|
}
|
|
},
|
|
"description": "Registration details including register key",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/reset-metrics": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Metrics"
|
|
],
|
|
"summary": "Reset all metrics and events data",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/restart": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Triggers a graceful server restart",
|
|
"tags": [
|
|
"config"
|
|
],
|
|
"summary": "Restart the server",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/restart-server": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Triggers a restart of the host machine (not available when running inside a container)",
|
|
"tags": [
|
|
"system"
|
|
],
|
|
"summary": "Restart the host machine",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/routes": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Returns all configured proxy routes",
|
|
"tags": [
|
|
"routes"
|
|
],
|
|
"summary": "List all proxy routes",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"data": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/utils.ProxyRouteConfig"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Creates a new proxy route configuration",
|
|
"tags": [
|
|
"routes"
|
|
],
|
|
"summary": "Create a new proxy route",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.ProxyRouteConfig"
|
|
}
|
|
}
|
|
},
|
|
"description": "Route configuration",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"data": {
|
|
"$ref": "#/components/schemas/utils.ProxyRouteConfig"
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"409": {
|
|
"description": "Conflict",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/routes/{name}": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Returns a single proxy route configuration by its name",
|
|
"tags": [
|
|
"routes"
|
|
],
|
|
"summary": "Get a proxy route by name",
|
|
"parameters": [
|
|
{
|
|
"description": "Route name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"data": {
|
|
"$ref": "#/components/schemas/utils.ProxyRouteConfig"
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"put": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Replaces an existing proxy route configuration by name",
|
|
"tags": [
|
|
"routes"
|
|
],
|
|
"summary": "Update a proxy route",
|
|
"parameters": [
|
|
{
|
|
"description": "Route name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.ProxyRouteConfig"
|
|
}
|
|
}
|
|
},
|
|
"description": "Updated route configuration",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"data": {
|
|
"$ref": "#/components/schemas/utils.ProxyRouteConfig"
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"delete": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Removes a proxy route configuration by name",
|
|
"tags": [
|
|
"routes"
|
|
],
|
|
"summary": "Delete a proxy route",
|
|
"parameters": [
|
|
{
|
|
"description": "Route name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/servapps": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "List all Docker containers",
|
|
"parameters": [
|
|
{
|
|
"description": "Maximum number of containers to return",
|
|
"name": "limit",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "integer"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/servapps/{containerId}/": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "Inspect a single Docker container by ID",
|
|
"parameters": [
|
|
{
|
|
"description": "Container ID or name",
|
|
"name": "containerId",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/servapps/{containerId}/auto-update/{status}": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "Enable or disable auto-update for a Docker container",
|
|
"parameters": [
|
|
{
|
|
"description": "Container ID or name",
|
|
"name": "containerId",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Auto-update status (true or false)",
|
|
"name": "status",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/servapps/{containerId}/check-update": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "Check whether a container's image has a newer version available",
|
|
"parameters": [
|
|
{
|
|
"description": "Container ID or name",
|
|
"name": "containerId",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/servapps/{containerId}/export": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "Export a container configuration as a service definition",
|
|
"parameters": [
|
|
{
|
|
"description": "Container ID or name",
|
|
"name": "containerId",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/servapps/{containerId}/logs": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "Retrieve logs for a Docker container",
|
|
"parameters": [
|
|
{
|
|
"description": "Container ID or name",
|
|
"name": "containerId",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Maximum number of log lines to return",
|
|
"name": "limit",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "integer"
|
|
}
|
|
},
|
|
{
|
|
"description": "Filter logs by search string",
|
|
"name": "search",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Timestamp to fetch logs until",
|
|
"name": "lastReceivedLogs",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Return only stderr logs",
|
|
"name": "errorOnly",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "boolean"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/servapps/{containerId}/manage/{action}": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Actions: stop, start, restart, kill, remove, pause, unpause, recreate, update",
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "Perform a management action on a Docker container",
|
|
"parameters": [
|
|
{
|
|
"description": "Container ID or name",
|
|
"name": "containerId",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Management action",
|
|
"name": "action",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string",
|
|
"enum": [
|
|
"stop",
|
|
"start",
|
|
"restart",
|
|
"kill",
|
|
"remove",
|
|
"pause",
|
|
"unpause",
|
|
"recreate",
|
|
"update"
|
|
]
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/servapps/{containerId}/network/{networkId}": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "Attach a Docker network to a container",
|
|
"parameters": [
|
|
{
|
|
"description": "Container ID or name",
|
|
"name": "containerId",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Network ID",
|
|
"name": "networkId",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"delete": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "Detach a Docker network from a container",
|
|
"parameters": [
|
|
{
|
|
"description": "Container ID or name",
|
|
"name": "containerId",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Network ID",
|
|
"name": "networkId",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/servapps/{containerId}/networks": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "List all networks and the networks a container is connected to",
|
|
"parameters": [
|
|
{
|
|
"description": "Container ID or name",
|
|
"name": "containerId",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/servapps/{containerId}/secure/{status}": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "Set or unset network isolation on a Docker container",
|
|
"parameters": [
|
|
{
|
|
"description": "Container ID or name",
|
|
"name": "containerId",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Network secured status (true or false)",
|
|
"name": "status",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/servapps/{containerId}/update": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "Update a Docker container's settings",
|
|
"parameters": [
|
|
{
|
|
"description": "Container ID or name",
|
|
"name": "containerId",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/docker.ContainerForm"
|
|
}
|
|
}
|
|
},
|
|
"description": "Container update payload",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/setup": {
|
|
"post": {
|
|
"description": "Performs the entire initial setup in a single call: database, HTTPS, admin user, optional Constellation connect, and optional admin API token creation. Only available when the server is in NewInstall mode.",
|
|
"tags": [
|
|
"system"
|
|
],
|
|
"summary": "One-shot server provisioning",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/main.SetupJSON"
|
|
}
|
|
}
|
|
},
|
|
"description": "Setup configuration",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/smart-def": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Storage"
|
|
],
|
|
"summary": "Get SMART attribute definitions for ATA and NVMe drives",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/snapraid": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Storage"
|
|
],
|
|
"summary": "List or create SnapRAID configurations",
|
|
"requestBody": {
|
|
"$ref": "#/components/requestBodies/utils.SnapRAIDConfig2"
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Storage"
|
|
],
|
|
"summary": "List or create SnapRAID configurations",
|
|
"requestBody": {
|
|
"$ref": "#/components/requestBodies/utils.SnapRAIDConfig2"
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/snapraid/{name}": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Storage"
|
|
],
|
|
"summary": "Update or delete a SnapRAID configuration by name",
|
|
"parameters": [
|
|
{
|
|
"description": "SnapRAID config name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"$ref": "#/components/requestBodies/utils.SnapRAIDConfig"
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"delete": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Storage"
|
|
],
|
|
"summary": "Update or delete a SnapRAID configuration by name",
|
|
"parameters": [
|
|
{
|
|
"description": "SnapRAID config name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"$ref": "#/components/requestBodies/utils.SnapRAIDConfig"
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/snapraid/{name}/{action}": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Storage"
|
|
],
|
|
"summary": "Run a SnapRAID action (sync, scrub, fix, enable, disable)",
|
|
"parameters": [
|
|
{
|
|
"description": "SnapRAID config name",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Action to run",
|
|
"name": "action",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string",
|
|
"enum": [
|
|
"sync",
|
|
"scrub",
|
|
"fix",
|
|
"enable",
|
|
"disable"
|
|
]
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"404": {
|
|
"description": "Not Found",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/status": {
|
|
"get": {
|
|
"description": "Returns the current server status including configuration, resource info, and system state",
|
|
"tags": [
|
|
"system"
|
|
],
|
|
"summary": "Get server status",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/sudo": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Re-authenticates the user with their password to grant elevated (sudo) permissions",
|
|
"tags": [
|
|
"auth"
|
|
],
|
|
"summary": "Elevate to sudo mode",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/user.SudoRequestJSON"
|
|
}
|
|
}
|
|
},
|
|
"description": "Password for sudo elevation",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/unmount": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"Storage"
|
|
],
|
|
"summary": "Unmount a filesystem",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/storage.MountRequest"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unmount request",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/upload/{name}": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Uploads an image file to the server (supports jpg, jpeg, png, gif, bmp, svg, webp, tiff, avif)",
|
|
"tags": [
|
|
"system"
|
|
],
|
|
"summary": "Upload an image",
|
|
"parameters": [
|
|
{
|
|
"description": "Base name for the uploaded file",
|
|
"name": "name",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"content": {
|
|
"multipart/form-data": {
|
|
"schema": {
|
|
"type": "object",
|
|
"properties": {
|
|
"image": {
|
|
"description": "Image file to upload",
|
|
"type": "string",
|
|
"format": "binary"
|
|
}
|
|
},
|
|
"required": [
|
|
"image"
|
|
]
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/users": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Returns a list of all users with optional limit",
|
|
"tags": [
|
|
"users"
|
|
],
|
|
"summary": "List all users",
|
|
"parameters": [
|
|
{
|
|
"description": "Maximum number of users to return",
|
|
"name": "limit",
|
|
"in": "query",
|
|
"schema": {
|
|
"type": "integer"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"data": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/utils.User"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Creates a new user account with a registration key for invite-based onboarding",
|
|
"tags": [
|
|
"users"
|
|
],
|
|
"summary": "Create a new user",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/user.CreateRequestJSON"
|
|
}
|
|
}
|
|
},
|
|
"description": "User creation details",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"409": {
|
|
"description": "Conflict",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/users/{nickname}": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Returns user details for the specified nickname",
|
|
"tags": [
|
|
"users"
|
|
],
|
|
"summary": "Get a user by nickname",
|
|
"parameters": [
|
|
{
|
|
"description": "User nickname",
|
|
"name": "nickname",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"data": {
|
|
"$ref": "#/components/schemas/utils.User"
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"delete": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Deletes a user account by nickname",
|
|
"tags": [
|
|
"users"
|
|
],
|
|
"summary": "Delete a user",
|
|
"parameters": [
|
|
{
|
|
"description": "User nickname",
|
|
"name": "nickname",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"patch": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"description": "Updates user details such as email and role",
|
|
"tags": [
|
|
"users"
|
|
],
|
|
"summary": "Edit a user",
|
|
"parameters": [
|
|
{
|
|
"description": "User nickname",
|
|
"name": "nickname",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/user.EditRequestJSON"
|
|
}
|
|
}
|
|
},
|
|
"description": "Fields to update",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Unauthorized",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"405": {
|
|
"description": "Method Not Allowed",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/volume/{volumeName}": {
|
|
"delete": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "Delete a Docker volume by name",
|
|
"parameters": [
|
|
{
|
|
"description": "Name of the volume to delete",
|
|
"name": "volumeName",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/api/volumes": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "List all Docker volumes",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"docker"
|
|
],
|
|
"summary": "Create a new Docker volume",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/docker.VolumeCreateRequest"
|
|
}
|
|
}
|
|
},
|
|
"description": "Volume creation payload",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.APIResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/logo": {
|
|
"get": {
|
|
"description": "Returns the Cosmos server logo as a PNG image",
|
|
"tags": [
|
|
"system"
|
|
],
|
|
"summary": "Get Cosmos logo",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"image/png": {
|
|
"schema": {
|
|
"type": "string",
|
|
"format": "binary"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"image/png": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/rclone/config/create": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"RClone"
|
|
],
|
|
"summary": "Create a new RClone remote",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object"
|
|
}
|
|
}
|
|
},
|
|
"description": "Remote config with name, type, and parameters",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/rclone/config/delete": {
|
|
"delete": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"RClone"
|
|
],
|
|
"summary": "Delete an RClone remote",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object"
|
|
}
|
|
}
|
|
},
|
|
"description": "Object with name of remote to delete",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/rclone/config/dump": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"RClone"
|
|
],
|
|
"summary": "Dump the full RClone configuration",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/rclone/config/listremotes": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"RClone"
|
|
],
|
|
"summary": "List RClone remotes (name and type only, no credentials)",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/rclone/config/save": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"RClone"
|
|
],
|
|
"summary": "Save the RClone configuration",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/rclone/config/update": {
|
|
"put": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"RClone"
|
|
],
|
|
"summary": "Update an existing RClone remote",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object"
|
|
}
|
|
}
|
|
},
|
|
"description": "Remote update with name and parameters",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/rclone/core/stats": {
|
|
"get": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"RClone"
|
|
],
|
|
"summary": "Get global RClone transfer stats",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/rclone/operations/about": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"RClone"
|
|
],
|
|
"summary": "Get storage usage info for a remote (total, used, free)",
|
|
"requestBody": {
|
|
"$ref": "#/components/requestBodies/Body"
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"500": {
|
|
"description": "Internal Server Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"501": {
|
|
"description": "Not Implemented",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/rclone/vfs/stats": {
|
|
"post": {
|
|
"security": [
|
|
{
|
|
"BearerAuth": []
|
|
}
|
|
],
|
|
"tags": [
|
|
"RClone"
|
|
],
|
|
"summary": "Get VFS stats for a mounted remote",
|
|
"requestBody": {
|
|
"$ref": "#/components/requestBodies/Body"
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Bad Request",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"403": {
|
|
"description": "Forbidden",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.HTTPErrorResult"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"servers": [
|
|
{
|
|
"url": "/cosmos"
|
|
}
|
|
],
|
|
"components": {
|
|
"requestBodies": {
|
|
"cron.JobRequestJSON": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cron.JobRequestJSON"
|
|
}
|
|
}
|
|
},
|
|
"description": "Job identifier",
|
|
"required": true
|
|
},
|
|
"utils.SnapRAIDConfig": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.SnapRAIDConfig"
|
|
}
|
|
}
|
|
},
|
|
"description": "Updated SnapRAID config (POST only)"
|
|
},
|
|
"utils.SnapRAIDConfig2": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.SnapRAIDConfig"
|
|
}
|
|
}
|
|
},
|
|
"description": "SnapRAID config (POST only)"
|
|
},
|
|
"utils.CRONConfig": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.CRONConfig"
|
|
}
|
|
}
|
|
},
|
|
"description": "Updated CRON config (PUT only)"
|
|
},
|
|
"utils.Alert": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.Alert"
|
|
}
|
|
}
|
|
},
|
|
"description": "Alert config (POST only)"
|
|
},
|
|
"utils.Alert2": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.Alert"
|
|
}
|
|
}
|
|
},
|
|
"description": "Updated alert config (PUT only)"
|
|
},
|
|
"utils.CRONConfig2": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/utils.CRONConfig"
|
|
}
|
|
}
|
|
},
|
|
"description": "CRON config (POST only)"
|
|
},
|
|
"Body": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "object"
|
|
}
|
|
}
|
|
},
|
|
"description": "Object with fs field specifying the remote",
|
|
"required": true
|
|
}
|
|
},
|
|
"securitySchemes": {
|
|
"BearerAuth": {
|
|
"type": "apiKey",
|
|
"name": "Authorization",
|
|
"in": "header"
|
|
}
|
|
},
|
|
"schemas": {
|
|
"configapi.CreateAPITokenRequest": {
|
|
"type": "object",
|
|
"required": [
|
|
"name"
|
|
],
|
|
"properties": {
|
|
"description": {
|
|
"type": "string"
|
|
},
|
|
"expiryDays": {
|
|
"type": "integer"
|
|
},
|
|
"ipWhitelist": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"permissions": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/utils.Permission"
|
|
}
|
|
},
|
|
"readOnly": {
|
|
"type": "boolean"
|
|
},
|
|
"restrictToConstellation": {
|
|
"type": "boolean"
|
|
}
|
|
}
|
|
},
|
|
"configapi.DNSConfigRequest": {
|
|
"type": "object",
|
|
"properties": {
|
|
"customDNSEntries": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/utils.ConstellationDNSEntry"
|
|
}
|
|
},
|
|
"dnsAdditionalBlocklists": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"dnsBlockBlacklist": {
|
|
"type": "boolean"
|
|
},
|
|
"dnsFallback": {
|
|
"type": "string"
|
|
},
|
|
"dnsPort": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"configapi.DashboardRoute": {
|
|
"type": "object",
|
|
"properties": {
|
|
"ContainerIcon": {
|
|
"type": "string"
|
|
},
|
|
"ContainerRunning": {
|
|
"description": "Container info (for SERVAPP routes)",
|
|
"type": "boolean"
|
|
},
|
|
"Description": {
|
|
"type": "string"
|
|
},
|
|
"HideFromDashboard": {
|
|
"type": "boolean"
|
|
},
|
|
"Host": {
|
|
"type": "string"
|
|
},
|
|
"Icon": {
|
|
"type": "string"
|
|
},
|
|
"Mode": {
|
|
"type": "string"
|
|
},
|
|
"Name": {
|
|
"type": "string"
|
|
},
|
|
"PathPrefix": {
|
|
"type": "string"
|
|
},
|
|
"Target": {
|
|
"type": "string"
|
|
},
|
|
"UseHost": {
|
|
"type": "boolean"
|
|
},
|
|
"UsePathPrefix": {
|
|
"type": "boolean"
|
|
}
|
|
}
|
|
},
|
|
"configapi.DeleteAPITokenRequest": {
|
|
"type": "object",
|
|
"required": [
|
|
"name"
|
|
],
|
|
"properties": {
|
|
"name": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"configapi.UpdateAPITokenRequest": {
|
|
"type": "object",
|
|
"properties": {
|
|
"description": {
|
|
"type": "string"
|
|
},
|
|
"ipWhitelist": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"permissions": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/utils.Permission"
|
|
}
|
|
},
|
|
"restrictToConstellation": {
|
|
"type": "boolean"
|
|
}
|
|
}
|
|
},
|
|
"configapi.UpdateRouteRequest": {
|
|
"type": "object",
|
|
"required": [
|
|
"operation"
|
|
],
|
|
"properties": {
|
|
"newRoute": {
|
|
"$ref": "#/components/schemas/utils.ProxyRouteConfig"
|
|
},
|
|
"operation": {
|
|
"type": "string"
|
|
},
|
|
"routeName": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"constellation.DeviceBlockRequestJSON": {
|
|
"type": "object",
|
|
"required": [
|
|
"deviceName",
|
|
"nickname"
|
|
],
|
|
"properties": {
|
|
"block": {
|
|
"type": "boolean"
|
|
},
|
|
"deviceName": {
|
|
"type": "string",
|
|
"maxLength": 32,
|
|
"minLength": 3
|
|
},
|
|
"nickname": {
|
|
"type": "string",
|
|
"maxLength": 32,
|
|
"minLength": 3
|
|
}
|
|
}
|
|
},
|
|
"constellation.DeviceCreateRequestJSON": {
|
|
"type": "object",
|
|
"required": [
|
|
"deviceName",
|
|
"ip",
|
|
"nickname"
|
|
],
|
|
"properties": {
|
|
"PublicHostname": {
|
|
"type": "string"
|
|
},
|
|
"cosmosNode": {
|
|
"type": "integer"
|
|
},
|
|
"deviceName": {
|
|
"type": "string",
|
|
"maxLength": 32,
|
|
"minLength": 3
|
|
},
|
|
"invisible": {
|
|
"type": "boolean"
|
|
},
|
|
"ip": {
|
|
"type": "string"
|
|
},
|
|
"isExitNode": {
|
|
"type": "boolean"
|
|
},
|
|
"isLighthouse": {
|
|
"description": "for lighthouse only",
|
|
"type": "boolean"
|
|
},
|
|
"isLoadBalancer": {
|
|
"type": "boolean"
|
|
},
|
|
"isRelay": {
|
|
"type": "boolean"
|
|
},
|
|
"nickname": {
|
|
"description": "for devices only",
|
|
"type": "string",
|
|
"maxLength": 32
|
|
},
|
|
"port": {
|
|
"type": "string"
|
|
},
|
|
"publicKey": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"constellation.DeviceEditRequestJSON": {
|
|
"type": "object",
|
|
"properties": {
|
|
"isExitNode": {
|
|
"type": "boolean"
|
|
},
|
|
"isLighthouse": {
|
|
"type": "boolean"
|
|
},
|
|
"isLoadBalancer": {
|
|
"type": "boolean"
|
|
},
|
|
"isRelay": {
|
|
"type": "boolean"
|
|
}
|
|
}
|
|
},
|
|
"container.Config": {
|
|
"type": "object",
|
|
"properties": {
|
|
"argsEscaped": {
|
|
"description": "True if command is already escaped (meaning treat as a command line) (Windows specific).",
|
|
"type": "boolean"
|
|
},
|
|
"attachStderr": {
|
|
"description": "Attach the standard error",
|
|
"type": "boolean"
|
|
},
|
|
"attachStdin": {
|
|
"description": "Attach the standard input, makes possible user interaction",
|
|
"type": "boolean"
|
|
},
|
|
"attachStdout": {
|
|
"description": "Attach the standard output",
|
|
"type": "boolean"
|
|
},
|
|
"cmd": {
|
|
"description": "Command to run when starting the container",
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"domainname": {
|
|
"description": "Domainname",
|
|
"type": "string"
|
|
},
|
|
"entrypoint": {
|
|
"description": "Entrypoint to run when starting the container",
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"env": {
|
|
"description": "List of environment variable to set in the container",
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"exposedPorts": {
|
|
"description": "List of exposed ports",
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/nat.PortSet"
|
|
}
|
|
]
|
|
},
|
|
"healthcheck": {
|
|
"description": "Healthcheck describes how to check the container is healthy",
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/container.HealthConfig"
|
|
}
|
|
]
|
|
},
|
|
"hostname": {
|
|
"description": "Hostname",
|
|
"type": "string"
|
|
},
|
|
"image": {
|
|
"description": "Name of the image as it was passed by the operator (e.g. could be symbolic)",
|
|
"type": "string"
|
|
},
|
|
"labels": {
|
|
"description": "List of labels set to this container",
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"macAddress": {
|
|
"description": "Mac Address of the container.\n\nDeprecated: this field is deprecated since API v1.44. Use EndpointSettings.MacAddress instead.",
|
|
"type": "string"
|
|
},
|
|
"networkDisabled": {
|
|
"description": "Is network disabled",
|
|
"type": "boolean"
|
|
},
|
|
"onBuild": {
|
|
"description": "ONBUILD metadata that were defined on the image Dockerfile",
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"openStdin": {
|
|
"description": "Open stdin",
|
|
"type": "boolean"
|
|
},
|
|
"shell": {
|
|
"description": "Shell for shell-form of RUN, CMD, ENTRYPOINT",
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"stdinOnce": {
|
|
"description": "If true, close stdin after the 1 attached client disconnects.",
|
|
"type": "boolean"
|
|
},
|
|
"stopSignal": {
|
|
"description": "Signal to stop a container",
|
|
"type": "string"
|
|
},
|
|
"stopTimeout": {
|
|
"description": "Timeout (in seconds) to stop a container",
|
|
"type": "integer"
|
|
},
|
|
"tty": {
|
|
"description": "Attach standard streams to a tty, including stdin if it is not closed.",
|
|
"type": "boolean"
|
|
},
|
|
"user": {
|
|
"description": "User that will run the command(s) inside the container, also support user:group",
|
|
"type": "string"
|
|
},
|
|
"volumes": {
|
|
"description": "List of volumes (mounts) used for the container",
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"type": "object"
|
|
}
|
|
},
|
|
"workingDir": {
|
|
"description": "Current directory (PWD) in the command will be launched",
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"container.HealthConfig": {
|
|
"type": "object",
|
|
"properties": {
|
|
"interval": {
|
|
"description": "Zero means to inherit. Durations are expressed as integer nanoseconds.",
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/time.Duration"
|
|
}
|
|
]
|
|
},
|
|
"retries": {
|
|
"description": "Retries is the number of consecutive failures needed to consider a container as unhealthy.\nZero means inherit.",
|
|
"type": "integer"
|
|
},
|
|
"startInterval": {
|
|
"description": "The interval to attempt healthchecks at during the start period",
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/time.Duration"
|
|
}
|
|
]
|
|
},
|
|
"startPeriod": {
|
|
"description": "The start period for the container to initialize before the retries starts to count down.",
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/time.Duration"
|
|
}
|
|
]
|
|
},
|
|
"test": {
|
|
"description": "Test is the test to perform to check that the container is healthy.\nAn empty slice means to inherit the default.\nThe options are:\n{} : inherit healthcheck\n{\"NONE\"} : disable healthcheck\n{\"CMD\", args...} : exec arguments directly\n{\"CMD-SHELL\", command} : run command with system's default shell",
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"timeout": {
|
|
"description": "Timeout is the time to wait before considering the check to have hung.",
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/time.Duration"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
},
|
|
"cron.JobRequestJSON": {
|
|
"type": "object",
|
|
"required": [
|
|
"name",
|
|
"scheduler"
|
|
],
|
|
"properties": {
|
|
"name": {
|
|
"type": "string",
|
|
"maxLength": 32,
|
|
"minLength": 3
|
|
},
|
|
"scheduler": {
|
|
"type": "string",
|
|
"maxLength": 32,
|
|
"minLength": 3
|
|
}
|
|
}
|
|
},
|
|
"docker.ContainerCreateRequestContainer": {
|
|
"type": "object",
|
|
"required": [
|
|
"image"
|
|
],
|
|
"properties": {
|
|
"cap_add": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"cap_drop": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"command": {
|
|
"type": "string"
|
|
},
|
|
"container_name": {
|
|
"type": "string"
|
|
},
|
|
"cpu_shares": {
|
|
"type": "integer"
|
|
},
|
|
"cpus": {
|
|
"type": "number"
|
|
},
|
|
"cpuset_cpus": {
|
|
"type": "string"
|
|
},
|
|
"depends_on": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"$ref": "#/components/schemas/docker.ContainerCreateRequestContainerDependsOnCont"
|
|
}
|
|
},
|
|
"devices": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"dns": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"dns_search": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"domainname": {
|
|
"type": "string"
|
|
},
|
|
"entrypoint": {
|
|
"type": "string"
|
|
},
|
|
"environment": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"expose": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"extra_hosts": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"gid": {
|
|
"type": "integer"
|
|
},
|
|
"healthcheck": {
|
|
"$ref": "#/components/schemas/docker.ContainerCreateRequestContainerHealthcheck"
|
|
},
|
|
"hostname": {
|
|
"type": "string"
|
|
},
|
|
"image": {
|
|
"type": "string"
|
|
},
|
|
"isolation": {
|
|
"type": "string"
|
|
},
|
|
"labels": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"links": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"mac_address": {
|
|
"type": "string"
|
|
},
|
|
"mem_limit": {
|
|
"description": "Resource constraints",
|
|
"type": "string"
|
|
},
|
|
"mem_reservation": {
|
|
"type": "string"
|
|
},
|
|
"network_mode": {
|
|
"type": "string"
|
|
},
|
|
"networks": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"$ref": "#/components/schemas/docker.ContainerCreateRequestServiceNetwork"
|
|
}
|
|
},
|
|
"ports": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"post_install": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"privileged": {
|
|
"type": "boolean"
|
|
},
|
|
"restart": {
|
|
"type": "string"
|
|
},
|
|
"routes": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/utils.ProxyRouteConfig"
|
|
}
|
|
},
|
|
"runtime": {
|
|
"type": "string"
|
|
},
|
|
"security_opt": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"stdin_open": {
|
|
"type": "boolean"
|
|
},
|
|
"stop_grace_period": {
|
|
"type": "integer"
|
|
},
|
|
"stop_signal": {
|
|
"type": "string"
|
|
},
|
|
"storage_opt": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"sysctls": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"tty": {
|
|
"type": "boolean"
|
|
},
|
|
"uid": {
|
|
"type": "integer"
|
|
},
|
|
"user": {
|
|
"type": "string"
|
|
},
|
|
"volumes": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/mount.Mount"
|
|
}
|
|
},
|
|
"working_dir": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"docker.ContainerCreateRequestContainerDependsOnCont": {
|
|
"type": "object",
|
|
"properties": {
|
|
"condition": {
|
|
"type": "string"
|
|
},
|
|
"restart": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"docker.ContainerCreateRequestContainerHealthcheck": {
|
|
"type": "object",
|
|
"properties": {
|
|
"interval": {
|
|
"type": "integer"
|
|
},
|
|
"retries": {
|
|
"type": "integer"
|
|
},
|
|
"start_period": {
|
|
"type": "integer"
|
|
},
|
|
"test": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"timeout": {
|
|
"type": "integer"
|
|
}
|
|
}
|
|
},
|
|
"docker.ContainerCreateRequestNetwork": {
|
|
"type": "object",
|
|
"properties": {
|
|
"attachable": {
|
|
"type": "boolean"
|
|
},
|
|
"driver": {
|
|
"type": "string"
|
|
},
|
|
"enable_ipv6": {
|
|
"type": "boolean"
|
|
},
|
|
"internal": {
|
|
"type": "boolean"
|
|
},
|
|
"ipam": {
|
|
"type": "object",
|
|
"properties": {
|
|
"config": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/docker.ContainerCreateRequestNetworkIPAMConfig"
|
|
}
|
|
},
|
|
"driver": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"labels": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"name": {
|
|
"description": "name must be unique",
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"docker.ContainerCreateRequestNetworkIPAMConfig": {
|
|
"type": "object",
|
|
"properties": {
|
|
"gateway": {
|
|
"type": "string"
|
|
},
|
|
"subnet": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"docker.ContainerCreateRequestServiceNetwork": {
|
|
"type": "object",
|
|
"properties": {
|
|
"aliases": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"ipv4_address": {
|
|
"type": "string"
|
|
},
|
|
"ipv6_address": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"docker.ContainerCreateRequestVolume": {
|
|
"type": "object",
|
|
"properties": {
|
|
"driver": {
|
|
"type": "string"
|
|
},
|
|
"name": {
|
|
"description": "name must be unique",
|
|
"type": "string"
|
|
},
|
|
"source": {
|
|
"type": "string"
|
|
},
|
|
"target": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"docker.ContainerForm": {
|
|
"type": "object",
|
|
"properties": {
|
|
"Volumes": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/mount.Mount"
|
|
}
|
|
},
|
|
"cpus": {
|
|
"type": "number"
|
|
},
|
|
"devices": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"envVars": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"image": {
|
|
"type": "string"
|
|
},
|
|
"interactive": {
|
|
"description": "we make this a int so that we can ignore 0",
|
|
"type": "integer"
|
|
},
|
|
"labels": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"memLimit": {
|
|
"type": "string"
|
|
},
|
|
"networkMode": {
|
|
"type": "string"
|
|
},
|
|
"portBindings": {
|
|
"$ref": "#/components/schemas/nat.PortMap"
|
|
},
|
|
"restartPolicy": {
|
|
"type": "string"
|
|
},
|
|
"user": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"docker.DockerServiceCreateRequest": {
|
|
"type": "object",
|
|
"properties": {
|
|
"networks": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"$ref": "#/components/schemas/docker.ContainerCreateRequestNetwork"
|
|
}
|
|
},
|
|
"services": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"$ref": "#/components/schemas/docker.ContainerCreateRequestContainer"
|
|
}
|
|
},
|
|
"volumes": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"$ref": "#/components/schemas/docker.ContainerCreateRequestVolume"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"docker.VolumeCreateRequest": {
|
|
"type": "object",
|
|
"required": [
|
|
"name"
|
|
],
|
|
"properties": {
|
|
"driver": {
|
|
"type": "string"
|
|
},
|
|
"name": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"docker.createNetworkPayload": {
|
|
"type": "object",
|
|
"required": [
|
|
"name"
|
|
],
|
|
"properties": {
|
|
"attachCosmos": {
|
|
"type": "boolean"
|
|
},
|
|
"driver": {
|
|
"type": "string"
|
|
},
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"parentInterface": {
|
|
"type": "string"
|
|
},
|
|
"subnet": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"docker.migrateToHostMode": {
|
|
"type": "object",
|
|
"required": [
|
|
"http",
|
|
"https"
|
|
],
|
|
"properties": {
|
|
"http": {
|
|
"type": "string"
|
|
},
|
|
"https": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"github_com_azukaar_cosmos-server_src_utils.Config": {
|
|
"type": "object",
|
|
"required": [
|
|
"emailConfig",
|
|
"httpconfig"
|
|
],
|
|
"properties": {
|
|
"APITokens": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"$ref": "#/components/schemas/utils.APITokenConfig"
|
|
}
|
|
},
|
|
"Roles": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"$ref": "#/components/schemas/utils.RoleConfig"
|
|
}
|
|
},
|
|
"adminConstellationOnly": {
|
|
"type": "boolean"
|
|
},
|
|
"adminWhitelistIPs": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"agentMode": {
|
|
"type": "boolean"
|
|
},
|
|
"autoUpdate": {
|
|
"type": "boolean"
|
|
},
|
|
"backup": {
|
|
"$ref": "#/components/schemas/utils.BackupConfig"
|
|
},
|
|
"backupOutputDir": {
|
|
"type": "string"
|
|
},
|
|
"betaUpdates": {
|
|
"type": "boolean"
|
|
},
|
|
"blockedCountries": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"constellationConfig": {
|
|
"$ref": "#/components/schemas/utils.ConstellationConfig"
|
|
},
|
|
"countryBlacklistIsWhitelist": {
|
|
"type": "boolean"
|
|
},
|
|
"cron": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"$ref": "#/components/schemas/utils.CRONConfig"
|
|
}
|
|
},
|
|
"database": {
|
|
"$ref": "#/components/schemas/utils.DatabaseConfig"
|
|
},
|
|
"disableHostModeWarning": {
|
|
"type": "boolean"
|
|
},
|
|
"disableOpenIDDirect": {
|
|
"type": "boolean"
|
|
},
|
|
"disableUserManagement": {
|
|
"type": "boolean"
|
|
},
|
|
"dockerConfig": {
|
|
"$ref": "#/components/schemas/utils.DockerConfig"
|
|
},
|
|
"emailConfig": {
|
|
"$ref": "#/components/schemas/utils.EmailConfig"
|
|
},
|
|
"homepageConfig": {
|
|
"$ref": "#/components/schemas/utils.HomepageConfig"
|
|
},
|
|
"httpconfig": {
|
|
"$ref": "#/components/schemas/utils.HTTPConfig"
|
|
},
|
|
"incrBackupOutputDir": {
|
|
"type": "string"
|
|
},
|
|
"licence": {
|
|
"type": "string"
|
|
},
|
|
"loggingLevel": {
|
|
"type": "string"
|
|
},
|
|
"marketConfig": {
|
|
"$ref": "#/components/schemas/utils.MarketConfig"
|
|
},
|
|
"mongoDB": {
|
|
"type": "string"
|
|
},
|
|
"monitoringAlerts": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"$ref": "#/components/schemas/utils.Alert"
|
|
}
|
|
},
|
|
"monitoringDisabled": {
|
|
"type": "boolean"
|
|
},
|
|
"mpdn_": {
|
|
"type": "string"
|
|
},
|
|
"mpdu_": {
|
|
"type": "string"
|
|
},
|
|
"newInstall": {
|
|
"type": "boolean"
|
|
},
|
|
"openIDClients": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/utils.OpenIDClient"
|
|
}
|
|
},
|
|
"remoteStorage": {
|
|
"$ref": "#/components/schemas/utils.RemoteStorageConfig"
|
|
},
|
|
"requireMFA": {
|
|
"type": "boolean"
|
|
},
|
|
"serverCountry": {
|
|
"type": "string"
|
|
},
|
|
"serverToken": {
|
|
"type": "string"
|
|
},
|
|
"storage": {
|
|
"$ref": "#/components/schemas/utils.StorageConfig"
|
|
},
|
|
"themeConfig": {
|
|
"$ref": "#/components/schemas/utils.ThemeConfig"
|
|
}
|
|
}
|
|
},
|
|
"image.Metadata": {
|
|
"type": "object",
|
|
"properties": {
|
|
"lastTagTime": {
|
|
"description": "LastTagTime is the date and time at which the image was last tagged.",
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"main.NewInstallJSON": {
|
|
"type": "object",
|
|
"properties": {
|
|
"allowHTTPLocalIPAccess": {
|
|
"type": "boolean"
|
|
},
|
|
"dnsChallengeProvider": {
|
|
"type": "string"
|
|
},
|
|
"dnschallengeConfig": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"hostname": {
|
|
"type": "string"
|
|
},
|
|
"httpsCertificateMode": {
|
|
"type": "string"
|
|
},
|
|
"mongodb": {
|
|
"type": "string"
|
|
},
|
|
"mongodbMode": {
|
|
"type": "string"
|
|
},
|
|
"nickname": {
|
|
"type": "string"
|
|
},
|
|
"omitempty": {
|
|
"type": "string"
|
|
},
|
|
"password": {
|
|
"type": "string"
|
|
},
|
|
"sslEmail": {
|
|
"type": "string"
|
|
},
|
|
"step": {
|
|
"type": "string"
|
|
},
|
|
"tlsCert": {
|
|
"type": "string"
|
|
},
|
|
"tlsKey": {
|
|
"type": "string"
|
|
},
|
|
"useWildcardCertificate": {
|
|
"type": "boolean"
|
|
}
|
|
}
|
|
},
|
|
"main.SetupJSON": {
|
|
"type": "object",
|
|
"properties": {
|
|
"DNSChallengeConfig": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"allowHTTPLocalIPAccess": {
|
|
"type": "boolean"
|
|
},
|
|
"clearConfig": {
|
|
"description": "Optional: clear config before setup",
|
|
"type": "boolean"
|
|
},
|
|
"constellationConfig": {
|
|
"description": "Optional: Constellation connect",
|
|
"type": "string"
|
|
},
|
|
"createAdminToken": {
|
|
"description": "Optional: create admin API token",
|
|
"type": "boolean"
|
|
},
|
|
"dnsChallengeProvider": {
|
|
"type": "string"
|
|
},
|
|
"email": {
|
|
"type": "string"
|
|
},
|
|
"hostname": {
|
|
"description": "HTTPS",
|
|
"type": "string"
|
|
},
|
|
"httpsCertificateMode": {
|
|
"type": "string"
|
|
},
|
|
"mongodb": {
|
|
"type": "string"
|
|
},
|
|
"mongodbMode": {
|
|
"description": "Database",
|
|
"type": "string"
|
|
},
|
|
"nickname": {
|
|
"description": "Admin",
|
|
"type": "string"
|
|
},
|
|
"password": {
|
|
"type": "string"
|
|
},
|
|
"sslEmail": {
|
|
"type": "string"
|
|
},
|
|
"tlsCert": {
|
|
"type": "string"
|
|
},
|
|
"tlsKey": {
|
|
"type": "string"
|
|
},
|
|
"useWildcardCertificate": {
|
|
"type": "boolean"
|
|
}
|
|
}
|
|
},
|
|
"mount.BindOptions": {
|
|
"type": "object",
|
|
"properties": {
|
|
"createMountpoint": {
|
|
"type": "boolean"
|
|
},
|
|
"nonRecursive": {
|
|
"type": "boolean"
|
|
},
|
|
"propagation": {
|
|
"$ref": "#/components/schemas/mount.Propagation"
|
|
},
|
|
"readOnlyForceRecursive": {
|
|
"description": "ReadOnlyForceRecursive raises an error if the mount cannot be made recursively read-only.",
|
|
"type": "boolean"
|
|
},
|
|
"readOnlyNonRecursive": {
|
|
"description": "ReadOnlyNonRecursive makes the mount non-recursively read-only, but still leaves the mount recursive\n(unless NonRecursive is set to true in conjunction).",
|
|
"type": "boolean"
|
|
}
|
|
}
|
|
},
|
|
"mount.ClusterOptions": {
|
|
"type": "object"
|
|
},
|
|
"mount.Consistency": {
|
|
"type": "string",
|
|
"enum": [
|
|
"consistent",
|
|
"cached",
|
|
"delegated",
|
|
"default"
|
|
],
|
|
"x-enum-varnames": [
|
|
"ConsistencyFull",
|
|
"ConsistencyCached",
|
|
"ConsistencyDelegated",
|
|
"ConsistencyDefault"
|
|
]
|
|
},
|
|
"mount.Driver": {
|
|
"type": "object",
|
|
"properties": {
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"options": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"mount.Mount": {
|
|
"type": "object",
|
|
"properties": {
|
|
"bindOptions": {
|
|
"$ref": "#/components/schemas/mount.BindOptions"
|
|
},
|
|
"clusterOptions": {
|
|
"$ref": "#/components/schemas/mount.ClusterOptions"
|
|
},
|
|
"consistency": {
|
|
"$ref": "#/components/schemas/mount.Consistency"
|
|
},
|
|
"readOnly": {
|
|
"description": "attempts recursive read-only if possible",
|
|
"type": "boolean"
|
|
},
|
|
"source": {
|
|
"description": "Source specifies the name of the mount. Depending on mount type, this\nmay be a volume name or a host path, or even ignored.\nSource is not supported for tmpfs (must be an empty value)",
|
|
"type": "string"
|
|
},
|
|
"target": {
|
|
"type": "string"
|
|
},
|
|
"tmpfsOptions": {
|
|
"$ref": "#/components/schemas/mount.TmpfsOptions"
|
|
},
|
|
"type": {
|
|
"$ref": "#/components/schemas/mount.Type"
|
|
},
|
|
"volumeOptions": {
|
|
"$ref": "#/components/schemas/mount.VolumeOptions"
|
|
}
|
|
}
|
|
},
|
|
"mount.Propagation": {
|
|
"type": "string",
|
|
"enum": [
|
|
"rprivate",
|
|
"private",
|
|
"rshared",
|
|
"shared",
|
|
"rslave",
|
|
"slave"
|
|
],
|
|
"x-enum-varnames": [
|
|
"PropagationRPrivate",
|
|
"PropagationPrivate",
|
|
"PropagationRShared",
|
|
"PropagationShared",
|
|
"PropagationRSlave",
|
|
"PropagationSlave"
|
|
]
|
|
},
|
|
"mount.TmpfsOptions": {
|
|
"type": "object",
|
|
"properties": {
|
|
"mode": {
|
|
"description": "Mode of the tmpfs upon creation",
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/os.FileMode"
|
|
}
|
|
]
|
|
},
|
|
"sizeBytes": {
|
|
"description": "Size sets the size of the tmpfs, in bytes.\n\nThis will be converted to an operating system specific value\ndepending on the host. For example, on linux, it will be converted to\nuse a 'k', 'm' or 'g' syntax. BSD, though not widely supported with\ndocker, uses a straight byte value.\n\nPercentages are not supported.",
|
|
"type": "integer"
|
|
}
|
|
}
|
|
},
|
|
"mount.Type": {
|
|
"type": "string",
|
|
"enum": [
|
|
"bind",
|
|
"volume",
|
|
"tmpfs",
|
|
"npipe",
|
|
"cluster"
|
|
],
|
|
"x-enum-varnames": [
|
|
"TypeBind",
|
|
"TypeVolume",
|
|
"TypeTmpfs",
|
|
"TypeNamedPipe",
|
|
"TypeCluster"
|
|
]
|
|
},
|
|
"mount.VolumeOptions": {
|
|
"type": "object",
|
|
"properties": {
|
|
"driverConfig": {
|
|
"$ref": "#/components/schemas/mount.Driver"
|
|
},
|
|
"labels": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"noCopy": {
|
|
"type": "boolean"
|
|
},
|
|
"subpath": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"nat.PortBinding": {
|
|
"type": "object",
|
|
"properties": {
|
|
"HostIp": {
|
|
"description": "HostIP is the host IP Address",
|
|
"type": "string"
|
|
},
|
|
"hostPort": {
|
|
"description": "HostPort is the host port number",
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"nat.PortMap": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/nat.PortBinding"
|
|
}
|
|
}
|
|
},
|
|
"nat.PortSet": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
},
|
|
"os.FileMode": {
|
|
"type": "integer",
|
|
"format": "uint32"
|
|
},
|
|
"storage.FormatDiskJSON": {
|
|
"type": "object",
|
|
"required": [
|
|
"disk",
|
|
"format",
|
|
"password"
|
|
],
|
|
"properties": {
|
|
"disk": {
|
|
"type": "string"
|
|
},
|
|
"format": {
|
|
"type": "string"
|
|
},
|
|
"password": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"storage.MergeRequest": {
|
|
"type": "object",
|
|
"required": [
|
|
"branches",
|
|
"mountPoint"
|
|
],
|
|
"properties": {
|
|
"branches": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"chown": {
|
|
"type": "string"
|
|
},
|
|
"mountPoint": {
|
|
"type": "string"
|
|
},
|
|
"opts": {
|
|
"type": "string"
|
|
},
|
|
"permanent": {
|
|
"type": "boolean"
|
|
}
|
|
}
|
|
},
|
|
"storage.MountRequest": {
|
|
"type": "object",
|
|
"required": [
|
|
"mountPoint",
|
|
"path"
|
|
],
|
|
"properties": {
|
|
"chown": {
|
|
"type": "string"
|
|
},
|
|
"mountPoint": {
|
|
"type": "string"
|
|
},
|
|
"netDisk": {
|
|
"type": "boolean"
|
|
},
|
|
"path": {
|
|
"type": "string"
|
|
},
|
|
"permanent": {
|
|
"type": "boolean"
|
|
}
|
|
}
|
|
},
|
|
"time.Duration": {
|
|
"type": "integer",
|
|
"format": "int64"
|
|
},
|
|
"types.GraphDriverData": {
|
|
"type": "object",
|
|
"properties": {
|
|
"Data": {
|
|
"description": "Low-level storage metadata, provided as key/value pairs.\n\nThis information is driver-specific, and depends on the storage-driver\nin use, and should be used for informational purposes only.\n\nRequired: true",
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"Name": {
|
|
"description": "Name of the storage driver.\nRequired: true",
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"types.ImageInspect": {
|
|
"type": "object",
|
|
"properties": {
|
|
"Id": {
|
|
"description": "ID is the content-addressable ID of an image.\n\nThis identifier is a content-addressable digest calculated from the\nimage's configuration (which includes the digests of layers used by\nthe image).\n\nNote that this digest differs from the `RepoDigests` below, which\nholds digests of image manifests that reference the image.",
|
|
"type": "string"
|
|
},
|
|
"VirtualSize": {
|
|
"description": "VirtualSize is the total size of the image including all layers it is\ncomposed of.\n\nDeprecated: this field is omitted in API v1.44, but kept for backward compatibility. Use Size instead.",
|
|
"type": "integer"
|
|
},
|
|
"architecture": {
|
|
"description": "Architecture is the hardware CPU architecture that the image runs on.",
|
|
"type": "string"
|
|
},
|
|
"author": {
|
|
"description": "Author is the name of the author that was specified when committing the\nimage, or as specified through MAINTAINER (deprecated) in the Dockerfile.",
|
|
"type": "string"
|
|
},
|
|
"comment": {
|
|
"description": "Comment is an optional message that can be set when committing or\nimporting the image.",
|
|
"type": "string"
|
|
},
|
|
"config": {
|
|
"$ref": "#/components/schemas/container.Config"
|
|
},
|
|
"container": {
|
|
"description": "Container is the ID of the container that was used to create the image.\n\nDepending on how the image was created, this field may be empty.\n\nDeprecated: this field is omitted in API v1.45, but kept for backward compatibility.",
|
|
"type": "string"
|
|
},
|
|
"containerConfig": {
|
|
"description": "ContainerConfig is an optional field containing the configuration of the\ncontainer that was last committed when creating the image.\n\nPrevious versions of Docker builder used this field to store build cache,\nand it is not in active use anymore.\n\nDeprecated: this field is omitted in API v1.45, but kept for backward compatibility.",
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/container.Config"
|
|
}
|
|
]
|
|
},
|
|
"created": {
|
|
"description": "Created is the date and time at which the image was created, formatted in\nRFC 3339 nano-seconds (time.RFC3339Nano).\n\nThis information is only available if present in the image,\nand omitted otherwise.",
|
|
"type": "string"
|
|
},
|
|
"dockerVersion": {
|
|
"description": "DockerVersion is the version of Docker that was used to build the image.\n\nDepending on how the image was created, this field may be empty.",
|
|
"type": "string"
|
|
},
|
|
"graphDriver": {
|
|
"description": "GraphDriver holds information about the storage driver used to store the\ncontainer's and image's filesystem.",
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/types.GraphDriverData"
|
|
}
|
|
]
|
|
},
|
|
"metadata": {
|
|
"description": "Metadata of the image in the local cache.\n\nThis information is local to the daemon, and not part of the image itself.",
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/image.Metadata"
|
|
}
|
|
]
|
|
},
|
|
"os": {
|
|
"description": "OS is the Operating System the image is built to run on.",
|
|
"type": "string"
|
|
},
|
|
"osVersion": {
|
|
"description": "OsVersion is the version of the Operating System the image is built to\nrun on (especially for Windows).",
|
|
"type": "string"
|
|
},
|
|
"parent": {
|
|
"description": "Parent is the ID of the parent image.\n\nDepending on how the image was created, this field may be empty and\nis only set for images that were built/created locally. This field\nis empty if the image was pulled from an image registry.",
|
|
"type": "string"
|
|
},
|
|
"repoDigests": {
|
|
"description": "RepoDigests is a list of content-addressable digests of locally available\nimage manifests that the image is referenced from. Multiple manifests can\nrefer to the same image.\n\nThese digests are usually only available if the image was either pulled\nfrom a registry, or if the image was pushed to a registry, which is when\nthe manifest is generated and its digest calculated.",
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"repoTags": {
|
|
"description": "RepoTags is a list of image names/tags in the local image cache that\nreference this image.\n\nMultiple image tags can refer to the same image, and this list may be\nempty if no tags reference the image, in which case the image is\n\"untagged\", in which case it can still be referenced by its ID.",
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"rootFS": {
|
|
"description": "RootFS contains information about the image's RootFS, including the\nlayer IDs.",
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/types.RootFS"
|
|
}
|
|
]
|
|
},
|
|
"size": {
|
|
"description": "Size is the total size of the image including all layers it is composed of.",
|
|
"type": "integer",
|
|
"format": "int64"
|
|
},
|
|
"variant": {
|
|
"description": "Variant is the CPU architecture variant (presently ARM-only).",
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"types.RootFS": {
|
|
"type": "object",
|
|
"properties": {
|
|
"layers": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"type": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"user.CreateRequestJSON": {
|
|
"type": "object",
|
|
"required": [
|
|
"nickname"
|
|
],
|
|
"properties": {
|
|
"email": {
|
|
"type": "string"
|
|
},
|
|
"nickname": {
|
|
"type": "string",
|
|
"maxLength": 32,
|
|
"minLength": 3
|
|
},
|
|
"role": {
|
|
"type": "integer"
|
|
}
|
|
}
|
|
},
|
|
"user.EditRequestJSON": {
|
|
"type": "object",
|
|
"properties": {
|
|
"email": {
|
|
"type": "string"
|
|
},
|
|
"role": {
|
|
"type": "integer"
|
|
}
|
|
}
|
|
},
|
|
"user.InviteRequestJSON": {
|
|
"type": "object",
|
|
"required": [
|
|
"nickname"
|
|
],
|
|
"properties": {
|
|
"formType": {
|
|
"type": "string"
|
|
},
|
|
"nickname": {
|
|
"type": "string",
|
|
"maxLength": 32,
|
|
"minLength": 3
|
|
}
|
|
}
|
|
},
|
|
"user.LoginRequestJSON": {
|
|
"type": "object",
|
|
"required": [
|
|
"nickname",
|
|
"password"
|
|
],
|
|
"properties": {
|
|
"nickname": {
|
|
"type": "string",
|
|
"maxLength": 32,
|
|
"minLength": 3
|
|
},
|
|
"password": {
|
|
"type": "string",
|
|
"maxLength": 128,
|
|
"minLength": 8
|
|
}
|
|
}
|
|
},
|
|
"user.PasswordResetRequestJSON": {
|
|
"type": "object",
|
|
"required": [
|
|
"email",
|
|
"nickname"
|
|
],
|
|
"properties": {
|
|
"email": {
|
|
"type": "string",
|
|
"maxLength": 32,
|
|
"minLength": 3
|
|
},
|
|
"nickname": {
|
|
"type": "string",
|
|
"maxLength": 32,
|
|
"minLength": 3
|
|
}
|
|
}
|
|
},
|
|
"user.RegisterRequestJSON": {
|
|
"type": "object",
|
|
"required": [
|
|
"nickname",
|
|
"password",
|
|
"registerKey"
|
|
],
|
|
"properties": {
|
|
"nickname": {
|
|
"type": "string",
|
|
"maxLength": 32,
|
|
"minLength": 3
|
|
},
|
|
"password": {
|
|
"type": "string",
|
|
"maxLength": 128,
|
|
"minLength": 9
|
|
},
|
|
"registerKey": {
|
|
"type": "string",
|
|
"maxLength": 512,
|
|
"minLength": 1
|
|
}
|
|
}
|
|
},
|
|
"user.SudoRequestJSON": {
|
|
"type": "object",
|
|
"required": [
|
|
"password"
|
|
],
|
|
"properties": {
|
|
"password": {
|
|
"type": "string",
|
|
"maxLength": 128,
|
|
"minLength": 8
|
|
}
|
|
}
|
|
},
|
|
"user.User2FACheckRequest": {
|
|
"type": "object",
|
|
"required": [
|
|
"token"
|
|
],
|
|
"properties": {
|
|
"token": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"user.User2FAResetRequest": {
|
|
"type": "object",
|
|
"required": [
|
|
"nickname"
|
|
],
|
|
"properties": {
|
|
"nickname": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"utils.APIResponse": {
|
|
"type": "object",
|
|
"properties": {
|
|
"data": {},
|
|
"status": {
|
|
"type": "string",
|
|
"example": "OK"
|
|
}
|
|
}
|
|
},
|
|
"utils.APITokenConfig": {
|
|
"type": "object",
|
|
"properties": {
|
|
"createdAt": {
|
|
"type": "string"
|
|
},
|
|
"description": {
|
|
"type": "string"
|
|
},
|
|
"expiresAt": {
|
|
"type": "string"
|
|
},
|
|
"ipWhitelist": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"owner": {
|
|
"type": "string"
|
|
},
|
|
"permissions": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/utils.Permission"
|
|
}
|
|
},
|
|
"restrictToConstellation": {
|
|
"type": "boolean"
|
|
},
|
|
"tokenHash": {
|
|
"type": "string"
|
|
},
|
|
"tokenSuffix": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"utils.AddionalFiltersConfig": {
|
|
"type": "object",
|
|
"properties": {
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"type": {
|
|
"type": "string"
|
|
},
|
|
"value": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"utils.Alert": {
|
|
"type": "object",
|
|
"required": [
|
|
"name"
|
|
],
|
|
"properties": {
|
|
"actions": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/utils.AlertAction"
|
|
}
|
|
},
|
|
"condition": {
|
|
"$ref": "#/components/schemas/utils.AlertCondition"
|
|
},
|
|
"enabled": {
|
|
"type": "boolean"
|
|
},
|
|
"lastTriggered": {
|
|
"type": "string"
|
|
},
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"period": {
|
|
"type": "string"
|
|
},
|
|
"severity": {
|
|
"type": "string"
|
|
},
|
|
"throttled": {
|
|
"type": "boolean"
|
|
},
|
|
"trackingMetric": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"utils.AlertAction": {
|
|
"type": "object",
|
|
"properties": {
|
|
"target": {
|
|
"type": "string"
|
|
},
|
|
"type": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"utils.AlertCondition": {
|
|
"type": "object",
|
|
"properties": {
|
|
"operator": {
|
|
"type": "string"
|
|
},
|
|
"percent": {
|
|
"type": "boolean"
|
|
},
|
|
"value": {
|
|
"type": "integer"
|
|
}
|
|
}
|
|
},
|
|
"utils.BackupConfig": {
|
|
"type": "object",
|
|
"properties": {
|
|
"backups": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"$ref": "#/components/schemas/utils.SingleBackupConfig"
|
|
}
|
|
},
|
|
"disable": {
|
|
"type": "boolean"
|
|
}
|
|
}
|
|
},
|
|
"utils.CRONConfig": {
|
|
"type": "object",
|
|
"required": [
|
|
"name"
|
|
],
|
|
"properties": {
|
|
"command": {
|
|
"type": "string"
|
|
},
|
|
"container": {
|
|
"type": "string"
|
|
},
|
|
"crontab": {
|
|
"type": "string"
|
|
},
|
|
"enabled": {
|
|
"type": "boolean"
|
|
},
|
|
"name": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"utils.ConstellationConfig": {
|
|
"type": "object",
|
|
"properties": {
|
|
"FirewallBlockedClients": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"constellationHostname": {
|
|
"type": "string"
|
|
},
|
|
"customDNSEntries": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/utils.ConstellationDNSEntry"
|
|
}
|
|
},
|
|
"dnsadditionalBlocklists": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"dnsblockBlacklist": {
|
|
"type": "boolean"
|
|
},
|
|
"dnsdisabled": {
|
|
"type": "boolean"
|
|
},
|
|
"dnsfallback": {
|
|
"type": "string"
|
|
},
|
|
"dnsport": {
|
|
"type": "string"
|
|
},
|
|
"doNotSyncNodes": {
|
|
"type": "boolean"
|
|
},
|
|
"enabled": {
|
|
"type": "boolean"
|
|
},
|
|
"iprange": {
|
|
"type": "string"
|
|
},
|
|
"overrideNebulaExitNodeInterface": {
|
|
"type": "string"
|
|
},
|
|
"thisDeviceName": {
|
|
"type": "string"
|
|
},
|
|
"tunnels": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/utils.ProxyRouteConfig"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"utils.ConstellationDNSEntry": {
|
|
"type": "object",
|
|
"required": [
|
|
"key"
|
|
],
|
|
"properties": {
|
|
"key": {
|
|
"type": "string"
|
|
},
|
|
"type": {
|
|
"type": "string"
|
|
},
|
|
"value": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"utils.DatabaseConfig": {
|
|
"type": "object",
|
|
"properties": {
|
|
"configVolume": {
|
|
"type": "string"
|
|
},
|
|
"dbVolume": {
|
|
"type": "string"
|
|
},
|
|
"hostname": {
|
|
"type": "string"
|
|
},
|
|
"password": {
|
|
"type": "string"
|
|
},
|
|
"puppetMode": {
|
|
"type": "boolean"
|
|
},
|
|
"username": {
|
|
"type": "string"
|
|
},
|
|
"version": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"utils.DockerConfig": {
|
|
"type": "object",
|
|
"properties": {
|
|
"defaultDataPath": {
|
|
"type": "string"
|
|
},
|
|
"skipPruneImages": {
|
|
"type": "boolean"
|
|
},
|
|
"skipPruneNetwork": {
|
|
"type": "boolean"
|
|
}
|
|
}
|
|
},
|
|
"utils.EmailConfig": {
|
|
"type": "object",
|
|
"properties": {
|
|
"allowInsecureTLS": {
|
|
"type": "boolean"
|
|
},
|
|
"enabled": {
|
|
"type": "boolean"
|
|
},
|
|
"from": {
|
|
"type": "string"
|
|
},
|
|
"host": {
|
|
"type": "string"
|
|
},
|
|
"notifyLogin": {
|
|
"type": "boolean"
|
|
},
|
|
"password": {
|
|
"type": "string"
|
|
},
|
|
"port": {
|
|
"type": "string"
|
|
},
|
|
"useTLS": {
|
|
"type": "boolean"
|
|
},
|
|
"username": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"utils.HTTPConfig": {
|
|
"type": "object",
|
|
"required": [
|
|
"hostname",
|
|
"httpport",
|
|
"httpsport"
|
|
],
|
|
"properties": {
|
|
"DNSChallengeConfig": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"acceptAllInsecureHostname": {
|
|
"type": "boolean"
|
|
},
|
|
"allowHTTPLocalIPAccess": {
|
|
"type": "boolean"
|
|
},
|
|
"allowSearchEngine": {
|
|
"type": "boolean"
|
|
},
|
|
"authPrivateKey": {
|
|
"type": "string"
|
|
},
|
|
"authPublicKey": {
|
|
"type": "string"
|
|
},
|
|
"cacert": {
|
|
"type": "string"
|
|
},
|
|
"caprivateKey": {
|
|
"type": "string"
|
|
},
|
|
"disablePropagationChecks": {
|
|
"type": "boolean"
|
|
},
|
|
"dnschallengePropagationWait": {
|
|
"type": "integer"
|
|
},
|
|
"dnschallengeProvider": {
|
|
"type": "string"
|
|
},
|
|
"dnschallengeResolvers": {
|
|
"type": "string"
|
|
},
|
|
"forceHTTPSCertificateRenewal": {
|
|
"type": "boolean"
|
|
},
|
|
"generateMissingAuthCert": {
|
|
"type": "boolean"
|
|
},
|
|
"hostname": {
|
|
"type": "string"
|
|
},
|
|
"httpport": {
|
|
"type": "string",
|
|
"maxLength": 6,
|
|
"minLength": 1
|
|
},
|
|
"httpscertificateMode": {
|
|
"type": "string"
|
|
},
|
|
"httpsport": {
|
|
"type": "string",
|
|
"maxLength": 6,
|
|
"minLength": 1
|
|
},
|
|
"overrideWildcardDomains": {
|
|
"type": "string"
|
|
},
|
|
"proxyConfig": {
|
|
"$ref": "#/components/schemas/utils.ProxyConfig"
|
|
},
|
|
"publishMDNS": {
|
|
"type": "boolean"
|
|
},
|
|
"selfTLSCert": {
|
|
"type": "string"
|
|
},
|
|
"selfTLSKey": {
|
|
"type": "string"
|
|
},
|
|
"selfTLSKeyHostsCached": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"selfTLSValidUntil": {
|
|
"type": "string"
|
|
},
|
|
"sslemail": {
|
|
"type": "string"
|
|
},
|
|
"tlscert": {
|
|
"type": "string"
|
|
},
|
|
"tlskey": {
|
|
"type": "string"
|
|
},
|
|
"tlskeyHostsCached": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"tlsvalidUntil": {
|
|
"type": "string"
|
|
},
|
|
"trustedProxies": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"useForwardedFor": {
|
|
"type": "boolean"
|
|
},
|
|
"useWildcardCertificate": {
|
|
"type": "boolean"
|
|
}
|
|
}
|
|
},
|
|
"utils.HTTPErrorResult": {
|
|
"type": "object",
|
|
"properties": {
|
|
"code": {
|
|
"type": "string"
|
|
},
|
|
"message": {
|
|
"type": "string"
|
|
},
|
|
"status": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"utils.HomepageConfig": {
|
|
"type": "object",
|
|
"properties": {
|
|
"background": {
|
|
"type": "string"
|
|
},
|
|
"expanded": {
|
|
"type": "boolean"
|
|
},
|
|
"widgets": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"utils.LocationRemoteStorageConfig": {
|
|
"type": "object",
|
|
"properties": {
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"protocol": {
|
|
"type": "string"
|
|
},
|
|
"route": {
|
|
"$ref": "#/components/schemas/utils.ProxyRouteConfig"
|
|
},
|
|
"settings": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"source": {
|
|
"type": "string"
|
|
},
|
|
"target": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"utils.MarketConfig": {
|
|
"type": "object",
|
|
"properties": {
|
|
"sources": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/utils.MarketSource"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"utils.MarketSource": {
|
|
"type": "object",
|
|
"properties": {
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"url": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"utils.OpenIDClient": {
|
|
"type": "object",
|
|
"required": [
|
|
"id"
|
|
],
|
|
"properties": {
|
|
"id": {
|
|
"type": "string"
|
|
},
|
|
"redirect": {
|
|
"type": "string"
|
|
},
|
|
"secret": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"utils.Permission": {
|
|
"type": "integer",
|
|
"enum": [
|
|
1,
|
|
2,
|
|
10,
|
|
11,
|
|
20,
|
|
21,
|
|
30,
|
|
31,
|
|
40,
|
|
100,
|
|
101
|
|
],
|
|
"x-enum-comments": {
|
|
"PERM_ADMIN": "System ops: restart, shutdown, update, terminal",
|
|
"PERM_ADMIN_READ": "View logs",
|
|
"PERM_CONFIGURATION": "Set/patch config, DNS",
|
|
"PERM_CONFIGURATION_READ": "View config",
|
|
"PERM_CREDENTIALS_READ": "View credentials (env vars, passwords, secrets)",
|
|
"PERM_LOGIN": "Any logged-in user, MFA required",
|
|
"PERM_LOGIN_WEAK": "Any logged-in user, no MFA check",
|
|
"PERM_RESOURCES": "Manage containers, storage, devices, backups, cron",
|
|
"PERM_RESOURCES_READ": "View containers, storage, devices, backups, cron, metrics",
|
|
"PERM_USERS": "Create, delete, edit users, 2FA reset",
|
|
"PERM_USERS_READ": "View user list/details"
|
|
},
|
|
"x-enum-descriptions": [
|
|
"View logs",
|
|
"System ops: restart, shutdown, update, terminal",
|
|
"View user list/details",
|
|
"Create, delete, edit users, 2FA reset",
|
|
"View containers, storage, devices, backups, cron, metrics",
|
|
"Manage containers, storage, devices, backups, cron",
|
|
"View config",
|
|
"Set/patch config, DNS",
|
|
"View credentials (env vars, passwords, secrets)",
|
|
"Any logged-in user, MFA required",
|
|
"Any logged-in user, no MFA check"
|
|
],
|
|
"x-enum-varnames": [
|
|
"PERM_ADMIN_READ",
|
|
"PERM_ADMIN",
|
|
"PERM_USERS_READ",
|
|
"PERM_USERS",
|
|
"PERM_RESOURCES_READ",
|
|
"PERM_RESOURCES",
|
|
"PERM_CONFIGURATION_READ",
|
|
"PERM_CONFIGURATION",
|
|
"PERM_CREDENTIALS_READ",
|
|
"PERM_LOGIN",
|
|
"PERM_LOGIN_WEAK"
|
|
]
|
|
},
|
|
"utils.ProxyConfig": {
|
|
"type": "object",
|
|
"properties": {
|
|
"routes": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/utils.ProxyRouteConfig"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"utils.ProxyRouteConfig": {
|
|
"type": "object",
|
|
"required": [
|
|
"name",
|
|
"target"
|
|
],
|
|
"properties": {
|
|
"LBMode": {
|
|
"type": "string"
|
|
},
|
|
"LBStickyMode": {
|
|
"type": "boolean"
|
|
},
|
|
"acceptInsecureHTTPSTarget": {
|
|
"type": "boolean"
|
|
},
|
|
"addionalFilters": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/utils.AddionalFiltersConfig"
|
|
}
|
|
},
|
|
"adminOnly": {
|
|
"type": "boolean"
|
|
},
|
|
"authEnabled": {
|
|
"type": "boolean"
|
|
},
|
|
"blockAPIAbuse": {
|
|
"type": "boolean"
|
|
},
|
|
"blockCommonBots": {
|
|
"type": "boolean"
|
|
},
|
|
"corsorigin": {
|
|
"type": "string"
|
|
},
|
|
"description": {
|
|
"type": "string"
|
|
},
|
|
"disableHeaderHardening": {
|
|
"type": "boolean"
|
|
},
|
|
"disableLegacyHTTPHeaders": {
|
|
"type": "boolean"
|
|
},
|
|
"disabled": {
|
|
"type": "boolean"
|
|
},
|
|
"extraHeaders": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"hideFromDashboard": {
|
|
"type": "boolean"
|
|
},
|
|
"host": {
|
|
"type": "string"
|
|
},
|
|
"icon": {
|
|
"type": "string"
|
|
},
|
|
"maxBandwith": {
|
|
"type": "integer"
|
|
},
|
|
"mode": {
|
|
"type": "string"
|
|
},
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"overwriteHostHeader": {
|
|
"type": "string"
|
|
},
|
|
"pathPrefix": {
|
|
"type": "string"
|
|
},
|
|
"restrictToConstellation": {
|
|
"type": "boolean"
|
|
},
|
|
"skipURLClean": {
|
|
"type": "boolean"
|
|
},
|
|
"smartShield": {
|
|
"$ref": "#/components/schemas/utils.SmartShieldPolicy"
|
|
},
|
|
"spoofHostname": {
|
|
"type": "boolean"
|
|
},
|
|
"stripPathPrefix": {
|
|
"type": "boolean"
|
|
},
|
|
"target": {
|
|
"type": "string"
|
|
},
|
|
"throttlePerMinute": {
|
|
"type": "integer"
|
|
},
|
|
"timeout": {
|
|
"$ref": "#/components/schemas/time.Duration"
|
|
},
|
|
"tunnel": {
|
|
"type": "string"
|
|
},
|
|
"tunneledHost": {
|
|
"type": "string"
|
|
},
|
|
"useH2C": {
|
|
"type": "boolean"
|
|
},
|
|
"useHost": {
|
|
"type": "boolean"
|
|
},
|
|
"usePathPrefix": {
|
|
"type": "boolean"
|
|
},
|
|
"whitelistInboundIPs": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"utils.RemoteStorageConfig": {
|
|
"type": "object",
|
|
"properties": {
|
|
"shares": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/utils.LocationRemoteStorageConfig"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"utils.RoleConfig": {
|
|
"type": "object",
|
|
"properties": {
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"permissions": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/utils.Permission"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"utils.SingleBackupConfig": {
|
|
"type": "object",
|
|
"required": [
|
|
"name",
|
|
"repository"
|
|
],
|
|
"properties": {
|
|
"autoStopContainers": {
|
|
"type": "boolean"
|
|
},
|
|
"crontab": {
|
|
"type": "string"
|
|
},
|
|
"crontabForget": {
|
|
"type": "string"
|
|
},
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"password": {
|
|
"type": "string"
|
|
},
|
|
"repository": {
|
|
"type": "string"
|
|
},
|
|
"retentionPolicy": {
|
|
"type": "string"
|
|
},
|
|
"source": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"utils.SmartShieldPolicy": {
|
|
"type": "object",
|
|
"properties": {
|
|
"enabled": {
|
|
"type": "boolean"
|
|
},
|
|
"maxGlobalSimultaneous": {
|
|
"type": "integer"
|
|
},
|
|
"perUserByteLimit": {
|
|
"type": "integer"
|
|
},
|
|
"perUserRequestLimit": {
|
|
"type": "integer"
|
|
},
|
|
"perUserSimultaneous": {
|
|
"type": "integer"
|
|
},
|
|
"perUserTimeBudget": {
|
|
"type": "number"
|
|
},
|
|
"policyStrictness": {
|
|
"type": "integer"
|
|
},
|
|
"privilegedGroups": {
|
|
"type": "integer"
|
|
}
|
|
}
|
|
},
|
|
"utils.SnapRAIDConfig": {
|
|
"type": "object",
|
|
"properties": {
|
|
"checkOnFix": {
|
|
"type": "boolean"
|
|
},
|
|
"data": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"enabled": {
|
|
"type": "boolean"
|
|
},
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"parity": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"scrubCrontab": {
|
|
"type": "string"
|
|
},
|
|
"syncCrontab": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"utils.StorageConfig": {
|
|
"type": "object",
|
|
"properties": {
|
|
"snapRAIDs": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/utils.SnapRAIDConfig"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"utils.ThemeConfig": {
|
|
"type": "object",
|
|
"properties": {
|
|
"primaryColor": {
|
|
"type": "string"
|
|
},
|
|
"secondaryColor": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"utils.User": {
|
|
"type": "object",
|
|
"required": [
|
|
"nickname",
|
|
"role"
|
|
],
|
|
"properties": {
|
|
"createdAt": {
|
|
"type": "string"
|
|
},
|
|
"email": {
|
|
"type": "string"
|
|
},
|
|
"lastLogin": {
|
|
"type": "string"
|
|
},
|
|
"lastPasswordChangedAt": {
|
|
"type": "string"
|
|
},
|
|
"link": {
|
|
"type": "string"
|
|
},
|
|
"nickname": {
|
|
"type": "string"
|
|
},
|
|
"registerKey": {
|
|
"type": "string"
|
|
},
|
|
"registerKeyExp": {
|
|
"type": "string"
|
|
},
|
|
"registeredAt": {
|
|
"type": "string"
|
|
},
|
|
"role": {
|
|
"type": "integer"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
} |