{ "openapi": "3.1.0", "info": { "title": "Neuland AI Hub API", "summary": "REST API for the Neuland AI Hub platform.", "description": "The **Neuland AI Hub API** powers chat, retrieval-augmented document Q&A,\nassistants, and the surrounding workspace, tenant, and integration features of\nthe platform.\n\nMost endpoints require authentication. Obtain a token via the **Auth**\nendpoints (or use an **ApiKey**) and send it as a bearer token in the\n`Authorization` header.\n\nEndpoints are grouped by resource \u2014 see the tag groups below.", "contact": { "name": "neuland.ai", "url": "https://neuland-hub.ai/" }, "version": "0.1.0" }, "paths": { "/": { "get": { "summary": "Root", "description": "A welcome message for the API and testing.", "operationId": "root_root", "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } } } } }, "/alerts/": { "post": { "tags": [ "Alert" ], "summary": "Create a budget alert", "description": "Create a new budget alert with threshold and current spend.", "operationId": "alerts_create_alert", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/BudgetAlertRequest" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/BudgetAlert" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Admin privileges required." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/alerts/{alert_id}": { "delete": { "tags": [ "Alert" ], "summary": "Delete a budget alert", "description": "Delete an existing budget alert.", "operationId": "alerts_delete_alert", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "alert_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the budget alert to delete.", "title": "Alert Id" }, "description": "ID of the budget alert to delete." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Admin privileges required." }, "404": { "description": "No budget alert exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "patch": { "tags": [ "Alert" ], "summary": "Update a budget alert", "description": "Update an existing budget alert.", "operationId": "alerts_update_alert", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "alert_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the budget alert to update.", "title": "Alert Id" }, "description": "ID of the budget alert to update." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/BudgetAlertUpdate" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/BudgetAlert" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Admin privileges required." }, "404": { "description": "No budget alert exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/api/key/": { "post": { "tags": [ "ApiKey" ], "summary": "Create an API key", "description": "Create an API key for the current user; the secret is returned only once.", "operationId": "api_create_key", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "content": { "application/json": { "schema": { "anyOf": [ { "$ref": "#/components/schemas/ApiKeyCreateRequest" }, { "type": "null" } ], "title": "Payload" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiKeyCreateResponse" } } } }, "401": { "description": "Missing or invalid authentication." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/api/key/revoke/{api_key_id}": { "patch": { "tags": [ "ApiKey" ], "summary": "Revoke an API key", "description": "Deactivate an API key so it can no longer authenticate requests.", "operationId": "api_revoke_api_key", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "api_key_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the API key to revoke.", "title": "Api Key Id" }, "description": "ID of the API key to revoke." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiKey" } } } }, "401": { "description": "Missing or invalid authentication." }, "404": { "description": "No API key exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/applications/": { "post": { "tags": [ "Application" ], "summary": "Create an application", "description": "Create a new application (superadmin only).", "operationId": "applications_create_app", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApplicationIn" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Superadmin privileges required." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/applications/group/access": { "put": { "tags": [ "Application" ], "summary": "Set application access for a user group", "description": "Grant or update application access for a user group (tenant admin only).", "operationId": "applications_update_group_membership", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GroupAppAccessIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/ApplicationGroup" }, "title": "Response Applications Update Group Membership" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Tenant admin privileges required." }, "404": { "description": "Application not found, or one or more groups not found." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/applications/user/access": { "put": { "tags": [ "Application" ], "summary": "Set application access for users", "description": "Grant or update application access for a list of users (tenant admin only).", "operationId": "applications_update_user_membership", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApplicationAccessIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/ApplicationMember" }, "title": "Response Applications Update User Membership" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Tenant admin privileges required." }, "404": { "description": "No application exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/applications/{app_id}": { "delete": { "tags": [ "Application" ], "summary": "Delete an application", "description": "Delete an application (superadmin only).", "operationId": "applications_delete_app", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "app_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the application to delete.", "title": "App Id" }, "description": "ID of the application to delete." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Superadmin privileges required." }, "404": { "description": "No application exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "patch": { "tags": [ "Application" ], "summary": "Update an application", "description": "Update an existing application (superadmin only).", "operationId": "applications_update_app", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "app_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the application to update.", "title": "App Id" }, "description": "ID of the application to update." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApplicationIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Application" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Superadmin privileges required." }, "404": { "description": "No application exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/assistants/": { "post": { "tags": [ "Assistant" ], "summary": "Create an assistant", "description": "Create an assistant from a JSON payload.", "operationId": "assistants_create_assistant", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AssistantIn" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Assistant" } } } }, "401": { "description": "Missing or invalid authentication." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/assistants/submit": { "post": { "tags": [ "Assistant" ], "summary": "Create an assistant with attachments", "description": "Create an assistant via multipart form, with optional knowledge-file uploads.", "operationId": "assistants_submit_assistant", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "multipart/form-data": { "schema": { "$ref": "#/components/schemas/Body_assistants_submit_assistant" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Assistant" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Usage budget exceeded." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/assistants/{assistant_id}": { "delete": { "tags": [ "Assistant" ], "summary": "Delete an assistant", "description": "Delete an assistant and orphan its associated chats.", "operationId": "assistants_delete_assistant", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "assistant_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Assistant Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Not the creator of this assistant." }, "404": { "description": "No assistant exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "patch": { "tags": [ "Assistant" ], "summary": "Update an assistant", "description": "Update an assistant's configuration.", "operationId": "assistants_update_assistant", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "assistant_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Assistant Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AssistantIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Assistant" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Not the creator of this assistant." }, "404": { "description": "No assistant exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/assistants/{assistant_id}/libraries/{library_id}": { "delete": { "tags": [ "Assistant" ], "summary": "Remove a library from an assistant", "description": "Disables a library from an assistant by removing the association", "operationId": "assistants_remove_library_from_assistant", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "assistant_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Assistant Id" } }, { "name": "library_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the library to disable.", "title": "Library Id" }, "description": "ID of the library to disable." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Not the creator of this assistant." }, "404": { "description": "No assistant exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "post": { "tags": [ "Assistant" ], "summary": "Add a library to an assistant", "description": "Enables a library for a assistant by creating a new association", "operationId": "assistants_add_library_to_assistant", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "assistant_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Assistant Id" } }, { "name": "library_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Library Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AssistantLibrary" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "No access to the library, or not the creator of the assistant." }, "404": { "description": "Assistant or library does not exist." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/assistants/{assistant_id}/members": { "delete": { "tags": [ "Assistant" ], "summary": "Remove members from an assistant", "description": "Remove one or more users from the assistant's membership.", "operationId": "assistants_delete_members", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "assistant_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Assistant Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AssistantMembersIn" } } } }, "responses": { "204": { "description": "Successful Response" }, "400": { "description": "One or more given users are not members of the assistant." }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Not the creator of this assistant." }, "404": { "description": "No assistant exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "post": { "tags": [ "Assistant" ], "summary": "Add members to an assistant", "description": "Add one or more users as members of the assistant.", "operationId": "assistants_add_members", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "assistant_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Assistant Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AssistantMembersIn" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/AssistantMember" }, "title": "Response Assistants Add Members" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Not the creator of this assistant." }, "404": { "description": "No assistant exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/assistants/{assistant_id}/members/{user_id}": { "delete": { "tags": [ "Assistant" ], "summary": "Remove a single member", "description": "Remove a specific user from the assistant's membership.", "operationId": "assistants_remove_member", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "assistant_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Assistant Id" } }, { "name": "user_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the member to remove.", "title": "User Id" }, "description": "ID of the member to remove." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Not the creator, or attempting to remove yourself as owner." }, "404": { "description": "Assistant does not exist, or the user is not a member." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/assistants/{assistant_id}/remove/me": { "delete": { "tags": [ "Assistant" ], "summary": "Leave an assistant", "description": "user can leave the assistant by themselves.", "operationId": "assistants_leave_assitant", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "assistant_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Assistant Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Not a member, or you are the owner and cannot leave." }, "404": { "description": "Assistant does not exist, or you are not a member." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/assistants/{assistant_id}/tags/{tag_id}": { "delete": { "tags": [ "Assistant" ], "summary": "Remove a tag from an assistant", "description": "Detach a tag from an assistant.", "operationId": "assistants_remove_tag_from_assistant", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "assistant_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Assistant Id" } }, { "name": "tag_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Tag Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "No access to the tag, or not the creator of the assistant." }, "404": { "description": "Assistant or tag does not exist." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "post": { "tags": [ "Assistant" ], "summary": "Add a tag to an assistant", "description": "Attach a tag to an assistant.", "operationId": "assistants_add_tag_to_assistant", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "assistant_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Assistant Id" } }, { "name": "tag_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Tag Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Tagging" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "No access to the tag, or not the creator of the assistant." }, "404": { "description": "Assistant or tag does not exist." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/assistants/{assistant_id}/tools/{tool_id}": { "delete": { "tags": [ "Assistant" ], "summary": "Remove a tool from an assistant", "description": "Disable a tool for the assistant by removing the association.", "operationId": "assistants_remove_tool_from_assistant", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "assistant_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Assistant Id" } }, { "name": "tool_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the tool to disable.", "title": "Tool Id" }, "description": "ID of the tool to disable." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Not the creator of this assistant." }, "404": { "description": "No assistant exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "post": { "tags": [ "Assistant" ], "summary": "Add a tool to an assistant", "description": "Enable a tenant tool for the assistant.", "operationId": "assistants_add_tool_to_assistant", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "assistant_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Assistant Id" } }, { "name": "tool_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the tool to enable.", "title": "Tool Id" }, "description": "ID of the tool to enable." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AssistantTool" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Not the creator, or the tool is not enabled for the tenant." }, "404": { "description": "Assistant, owning user, or tool does not exist." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/auth/callback/azure-entra": { "get": { "tags": [ "Auth" ], "summary": "Azure Entra login callback", "description": "Complete the Azure Entra ID OAuth flow and return an access token.", "operationId": "auth_azure_entra_callback", "parameters": [ { "name": "code", "in": "query", "required": true, "schema": { "type": "string", "description": "Authorization code from Azure Entra ID", "title": "Code" }, "description": "Authorization code from Azure Entra ID" }, { "name": "user-agent", "in": "header", "required": false, "schema": { "type": "string", "title": "User-Agent" } }, { "name": "x-real-ip", "in": "header", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "X-Real-Ip" } }, { "name": "x-forwarded-for", "in": "header", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "X-Forwarded-For" } }, { "name": "x-client-ip", "in": "header", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "X-Client-Ip" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "object", "additionalProperties": true, "title": "Response Auth Azure Entra Callback" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/auth/callback/oidc": { "get": { "tags": [ "Auth" ], "summary": "OIDC login callback", "description": "Complete the generic OIDC OAuth flow and return an access token.", "operationId": "auth_oidc_callback", "parameters": [ { "name": "code", "in": "query", "required": true, "schema": { "type": "string", "description": "Authorization code from OIDC provider", "title": "Code" }, "description": "Authorization code from OIDC provider" }, { "name": "user-agent", "in": "header", "required": false, "schema": { "type": "string", "title": "User-Agent" } }, { "name": "x-real-ip", "in": "header", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "X-Real-Ip" } }, { "name": "x-forwarded-for", "in": "header", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "X-Forwarded-For" } }, { "name": "x-client-ip", "in": "header", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "X-Client-Ip" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "object", "additionalProperties": true, "title": "Response Auth Oidc Callback" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/auth/confirm-email": { "get": { "tags": [ "Auth" ], "summary": "Confirm an email address", "description": "Confirm a user's email address (or pending email change) using a token from the email link.", "operationId": "auth_confirm_email", "parameters": [ { "name": "token", "in": "query", "required": true, "schema": { "type": "string", "description": "JWT token from confirmation email", "title": "Token" }, "description": "JWT token from confirmation email" }, { "name": "accept", "in": "header", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Accept" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "400": { "description": "Invalid or expired confirmation link." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/auth/connectors/callback": { "get": { "tags": [ "AuthConnector" ], "summary": "Connector OAuth callback", "description": "Handle the provider redirect after user consent and persist the granted connector tokens.", "operationId": "auth_oauth_callback", "parameters": [ { "name": "state", "in": "query", "required": true, "schema": { "type": "string", "description": "Opaque state token issued when consent was initiated.", "title": "State" }, "description": "Opaque state token issued when consent was initiated." }, { "name": "code", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Code" } }, { "name": "error", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Error" } }, { "name": "error_description", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Error Description" } }, { "name": "error_subcode", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Error Subcode" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "403": { "description": "The provider granted insufficient scopes for the requested capabilities." }, "404": { "description": "No connector or OAuth client exists for the consent state." }, "503": { "description": "Token exchange with the OAuth provider failed." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/auth/connectors/oauth-clients/{oauth_client_id}": { "patch": { "tags": [ "AuthConnector" ], "summary": "Update an OAuth client", "description": "Update an OAuth client (superadmin only).", "operationId": "auth_update_oauth_client", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "oauth_client_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the OAuth client to update.", "title": "Oauth Client Id" }, "description": "ID of the OAuth client to update." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/OAuthClientUpdate" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/OAuthClient" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Platform operator (superadmin) privileges required." }, "404": { "description": "No OAuth client exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/auth/connectors/status": { "get": { "tags": [ "AuthConnector" ], "summary": "List connector status", "description": "List connectors available to the user's tenant with their per-user consent status.", "operationId": "auth_list_connector_status", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/ConnectorStatusOut" }, "title": "Response Auth List Connector Status" } } } }, "401": { "description": "Missing or invalid authentication." }, "404": { "description": "The current user no longer exists." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/auth/connectors/{connector_id}": { "patch": { "tags": [ "AuthConnector" ], "summary": "Update a connector", "description": "Update a connector (superadmin only).", "operationId": "auth_update_connector", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "connector_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the connector to update.", "title": "Connector Id" }, "description": "ID of the connector to update." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ConnectorUpdate" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Connector" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Platform operator (superadmin) privileges required." }, "404": { "description": "No connector exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/auth/connectors/{connector_id}/consent": { "delete": { "tags": [ "AuthConnector" ], "summary": "Revoke connector consent", "description": "Delete the current user's stored consent for a connector, if any exists.", "operationId": "auth_revoke_consent", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "connector_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the connector to revoke consent for.", "title": "Connector Id" }, "description": "ID of the connector to revoke consent for." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "get": { "tags": [ "AuthConnector" ], "summary": "Initiate connector consent", "description": "Start the OAuth consent flow for a connector, returning (or redirecting to) the provider URL.", "operationId": "auth_initiate_consent", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "connector_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the connector to consent to.", "title": "Connector Id" }, "description": "ID of the connector to consent to." }, { "name": "return_url", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "description": "URL to return the user to after consent.", "title": "Return Url" }, "description": "URL to return the user to after consent." }, { "name": "redirect", "in": "query", "required": false, "schema": { "type": "boolean", "description": "If true, return 302 redirect instead of JSON", "default": false, "title": "Redirect" }, "description": "If true, return 302 redirect instead of JSON" }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ConnectorConsentOut" } } } }, "401": { "description": "Missing or invalid authentication." }, "404": { "description": "No connector or OAuth client exists for the given id." }, "503": { "description": "The OAuth provider is misconfigured." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/auth/connectors/{connector_id}/consent/admin": { "get": { "tags": [ "AuthConnector" ], "summary": "Initiate admin connector consent", "description": "Start the admin consent flow for connectors that require organization-wide admin consent.", "operationId": "auth_initiate_admin_consent", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "connector_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the connector to consent to.", "title": "Connector Id" }, "description": "ID of the connector to consent to." }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ConnectorConsentOut" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Administrator privileges required." }, "404": { "description": "No connector or OAuth client exists for the given id." }, "503": { "description": "The OAuth provider has no admin consent URL or is misconfigured." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/auth/entra/groups": { "get": { "tags": [ "Auth" ], "summary": "Get Entra group names", "description": "Resolve Azure Entra group display names for the current user's groups.", "operationId": "auth_get_entra_groups", "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "additionalProperties": { "anyOf": [ { "type": "string" }, { "type": "null" } ] }, "type": "object", "title": "Response Auth Get Entra Groups" } } } }, "401": { "description": "Missing or invalid authentication." } } } }, "/auth/entra/scopes": { "get": { "tags": [ "Auth" ], "summary": "List Entra scopes", "description": "List the Azure Entra OAuth scopes the platform requests.", "operationId": "auth_get_entra_scopes", "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "items": { "type": "string" }, "type": "array", "title": "Response Auth Get Entra Scopes" } } } } } } }, "/auth/exchange/token": { "post": { "tags": [ "Auth" ], "summary": "Exchange for a service token", "description": "Exchange the caller's token for a service token scoped to an AI application.", "operationId": "auth_exchange_token", "parameters": [ { "name": "app_id", "in": "query", "required": true, "schema": { "type": "integer", "description": "ID of the AI application to scope the token to.", "title": "App Id" }, "description": "ID of the AI application to scope the token to." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "string", "title": "Response Auth Exchange Token" } } } }, "401": { "description": "Missing or invalid authentication." }, "404": { "description": "No application exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/auth/logout": { "post": { "tags": [ "Auth" ], "summary": "Log out", "description": "Revoke the current session so its token can no longer authenticate.", "operationId": "auth_logout", "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "401": { "description": "Missing or invalid authentication." }, "404": { "description": "Session not found." } } } }, "/auth/request-password-reset": { "post": { "tags": [ "Auth" ], "summary": "Request a password reset", "description": "Send a password reset link if the account exists; always succeeds to prevent enumeration.", "operationId": "auth_request_password_reset", "parameters": [ { "name": "origin", "in": "header", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Origin" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PasswordResetRequestIn" } } } }, "responses": { "204": { "description": "Successful Response" }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/auth/reset-password": { "get": { "tags": [ "Auth" ], "summary": "Password reset HTML form", "description": "Render the fallback HTML password-reset form for when no frontend is available.", "operationId": "auth_reset_password_form", "parameters": [ { "name": "token", "in": "query", "required": true, "schema": { "type": "string", "description": "Password reset JWT token", "title": "Token" }, "description": "Password reset JWT token" } ], "responses": { "200": { "description": "Successful Response", "content": { "text/html": { "schema": { "type": "string" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "post": { "tags": [ "Auth" ], "summary": "Complete a password reset", "description": "Validate the reset token, set the new password, and revoke all of the user's sessions.", "operationId": "auth_reset_password", "parameters": [ { "name": "token", "in": "query", "required": true, "schema": { "type": "string", "description": "Password reset JWT token", "title": "Token" }, "description": "Password reset JWT token" } ], "responses": { "204": { "description": "Successful Response" }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/auth/send-email-confirmation": { "post": { "tags": [ "Auth" ], "summary": "Send an email confirmation", "description": "Send a confirmation email to the current user unless their email is already verified.", "operationId": "auth_send_email_confirmation", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/auth/token": { "post": { "tags": [ "Auth" ], "summary": "Log in", "description": "Authenticate with username and password and return an access token.", "operationId": "auth_login", "parameters": [ { "name": "user-agent", "in": "header", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "User-Agent" } }, { "name": "x-real-ip", "in": "header", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "X-Real-Ip" } }, { "name": "x-forwarded-for", "in": "header", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "X-Forwarded-For" } }, { "name": "x-client-ip", "in": "header", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "X-Client-Ip" } }, { "name": "session_id", "in": "cookie", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Session Id" } } ], "requestBody": { "required": true, "content": { "application/x-www-form-urlencoded": { "schema": { "$ref": "#/components/schemas/Body_auth_login" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TokenOut" } } } }, "401": { "description": "Invalid email or password." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/chats/{chat_id}": { "delete": { "tags": [ "Chat" ], "summary": "Delete a chat", "description": "Delete a chat and its messages.", "operationId": "chats_remove_chat", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "chat_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Chat Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "No access to this chat." }, "404": { "description": "No chat exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "patch": { "tags": [ "Chat" ], "summary": "Update a chat", "description": "Update settings of an existing chat (name, model, temperature, etc.).", "operationId": "chats_update_chat", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "chat_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Chat Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ChatIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Chat" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "No access to this chat." }, "404": { "description": "No chat exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/chats/{chat_id}/cancel": { "post": { "tags": [ "Chat" ], "summary": "Cancel in-progress generation", "description": "Cancel any pending or streaming message generation in the chat.", "operationId": "chats_cancel_message", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "chat_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Chat Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "No access to this chat." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/chats/{chat_id}/inactive-documents": { "delete": { "tags": [ "Chat" ], "summary": "Reactivate documents in a chat", "description": "Re-include previously deactivated documents in the chat's retrieval context.", "operationId": "chats_remove_inactive_documents", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "chat_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Chat Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/x-www-form-urlencoded": { "schema": { "$ref": "#/components/schemas/Body_chats_remove_inactive_documents" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/BulkResult" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "No access to this chat." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "post": { "tags": [ "Chat" ], "summary": "Deactivate documents in a chat", "description": "Exclude the given documents from the chat's retrieval context.", "operationId": "chats_deactivate_documents", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "chat_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Chat Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/x-www-form-urlencoded": { "schema": { "$ref": "#/components/schemas/Body_chats_deactivate_documents" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/ChatInactiveDocument" }, "title": "Response Chats Deactivate Documents" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "No access to this chat." }, "404": { "description": "Chat or one of the documents does not exist." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/chats/{chat_id}/libraries/{library_id}": { "delete": { "tags": [ "Chat" ], "summary": "Remove a library from a chat", "description": "Disables a library from a chat by removing the association", "operationId": "chats_remove_library_from_chat", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "chat_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Chat Id" } }, { "name": "library_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the library to disable.", "title": "Library Id" }, "description": "ID of the library to disable." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "No access to this chat." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "post": { "tags": [ "Chat" ], "summary": "Add a library to a chat", "description": "Enables a library in a chat by creating a new association", "operationId": "chats_add_library_to_chat", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "chat_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Chat Id" } }, { "name": "library_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Library Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ChatLibrary" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "No access to the chat or the library." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/chats/{chat_id}/summary": { "get": { "tags": [ "Chat" ], "summary": "Summarize a chat", "description": "Generate a short LLM summary of the chat's recent conversation.", "operationId": "chats_summerize_chat", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "chat_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Chat Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "string", "title": "Response Chats Summerize Chat" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "No access to the chat, or usage budget exceeded." }, "404": { "description": "Chat or owning user does not exist." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/chats/{chat_id}/tools/{tool_id}": { "put": { "tags": [ "Chat" ], "summary": "Set a chat tool setting", "description": "Enable or disable a tool for a chat, creating the setting if needed.", "operationId": "chats_update_chat_tool_settings", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "chat_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Chat Id" } }, { "name": "tool_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the tool to configure.", "title": "Tool Id" }, "description": "ID of the tool to configure." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ChatToolSettingsUpdate" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ChatToolSettingsOut" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "No access to the chat, or the tool is not enabled for the tenant." }, "404": { "description": "Chat, tool, or owning user does not exist." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/documents/": { "post": { "tags": [ "Document" ], "summary": "Upload documents", "description": "Upload files as documents and kick off async processing for the given entity.", "operationId": "documents_upload_documents", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "multipart/form-data": { "schema": { "$ref": "#/components/schemas/Body_documents_upload_documents" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/Document" }, "title": "Response Documents Upload Documents" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Usage limit exceeded, or caller lacks access to the target entity." }, "404": { "description": "The referenced project, chat, assistant, or library does not exist." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/documents/import": { "delete": { "tags": [ "Document" ], "summary": "Remove imported documents", "description": "Delete documents previously imported from a source for the given entity.", "operationId": "documents_unimport_documents", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/x-www-form-urlencoded": { "schema": { "$ref": "#/components/schemas/Body_documents_unimport_documents" } } } }, "responses": { "204": { "description": "Successful Response" }, "400": { "description": "The provided source type is not supported." }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Caller lacks access to the target entity." }, "404": { "description": "The referenced project, chat, or assistant does not exist." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "post": { "tags": [ "Document" ], "summary": "Import documents from a connected source", "description": "Import drive items from a connected source as documents; returns an import token.", "operationId": "documents_import_documents", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/x-www-form-urlencoded": { "schema": { "$ref": "#/components/schemas/Body_documents_import_documents" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "string", "format": "uuid", "title": "Response Documents Import Documents" } } } }, "400": { "description": "The provided source type is not supported." }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Usage limit exceeded, or caller lacks access to the target entity." }, "404": { "description": "The referenced project, chat, assistant, or library does not exist." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/documents/{document_id}": { "delete": { "tags": [ "Document" ], "summary": "Delete a document", "description": "Delete a document and its associated content.", "operationId": "documents_delete_chat_document", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "document_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Document Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Caller may not access this document." }, "404": { "description": "No document exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "get": { "tags": [ "Document" ], "summary": "Download a document", "description": "Stream a document's content as an attachment to authorized callers.", "operationId": "documents_get_file", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "document_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Document Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Caller may not access this document." }, "404": { "description": "No document exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/documents/{document_id}/retry": { "post": { "tags": [ "Document" ], "summary": "Retry document processing", "description": "Re-run processing for a previously failed or stuck document.", "operationId": "documents_retry_document", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "document_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Document Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Usage limit exceeded, or caller may not access this document." }, "404": { "description": "No document exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/files/{file_id}": { "get": { "tags": [ "File" ], "summary": "Download a file", "description": "Stream a stored file as an attachment to authorized callers.", "operationId": "files_download_file", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "file_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "File Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Caller may not access this file." }, "404": { "description": "No file exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/atlassian/{connector_id}/cloudid": { "put": { "tags": [ "Atlassian" ], "summary": "Set active Atlassian cloud_id", "description": "Set the active Atlassian cloud_id on this connector's consent.", "operationId": "integrations_set_atlassian_cloud_id", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "connector_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the Atlassian connector to configure.", "title": "Connector Id" }, "description": "ID of the Atlassian connector to configure." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SetAtlassianCloudIdRequest" } } } }, "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "404": { "description": "Connector is not connected for this user." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/onedrive/capabilities": { "get": { "tags": [ "OneDrive" ], "summary": "Get data source capabilities", "description": "Return the browse-hierarchy metadata for this data source.", "operationId": "onedrive_capabilities", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DataSourceCapabilities" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/onedrive/connected": { "get": { "tags": [ "OneDrive" ], "summary": "Check data source connection", "description": "Report whether the user has consented to this source's browse scopes.", "operationId": "onedrive_is_connected", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "boolean", "title": "Response Onedrive Is Connected" } } } }, "401": { "description": "Missing or invalid authentication." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/onedrive/drives/{drive_id}/items/{drive_item_id}": { "get": { "tags": [ "OneDrive" ], "summary": "Get a drive item", "description": "Get a single data source drive item, annotated with imported counts.", "operationId": "onedrive_get_item_info", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "drive_id", "in": "path", "required": true, "schema": { "type": "string", "description": "Id of the drive.", "title": "Drive Id" }, "description": "Id of the drive." }, { "name": "drive_item_id", "in": "path", "required": true, "schema": { "type": "string", "description": "Id of the drive item.", "title": "Drive Item Id" }, "description": "Id of the drive item." }, { "name": "chat_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this chat.", "title": "Chat Id" }, "description": "Scope imported counts to this chat." }, { "name": "library_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this library.", "title": "Library Id" }, "description": "Scope imported counts to this library." }, { "name": "assistant_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this assistant.", "title": "Assistant Id" }, "description": "Scope imported counts to this assistant." }, { "name": "project_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this project.", "title": "Project Id" }, "description": "Scope imported counts to this project." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DataSourceItemModel" } } } }, "401": { "description": "Missing or invalid authentication, or no valid connector token." }, "403": { "description": "User has not consented to the required scope." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/onedrive/drives/{drive_id}/items/{drive_item_id}/children": { "get": { "tags": [ "OneDrive" ], "summary": "List children of a drive item", "description": "List files and folders under a drive item, annotated with imported counts.", "operationId": "onedrive_list_children", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "drive_id", "in": "path", "required": true, "schema": { "type": "string", "description": "Id of the drive.", "title": "Drive Id" }, "description": "Id of the drive." }, { "name": "drive_item_id", "in": "path", "required": true, "schema": { "type": "string", "description": "Id of the parent item; empty or 'root' for the drive root.", "title": "Drive Item Id" }, "description": "Id of the parent item; empty or 'root' for the drive root." }, { "name": "chat_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this chat.", "title": "Chat Id" }, "description": "Scope imported counts to this chat." }, { "name": "library_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this library.", "title": "Library Id" }, "description": "Scope imported counts to this library." }, { "name": "assistant_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this assistant.", "title": "Assistant Id" }, "description": "Scope imported counts to this assistant." }, { "name": "project_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this project.", "title": "Project Id" }, "description": "Scope imported counts to this project." }, { "name": "recursive", "in": "query", "required": false, "schema": { "type": "boolean", "description": "Recurse into subfolders, returning only files.", "default": false, "title": "Recursive" }, "description": "Recurse into subfolders, returning only files." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/DataSourceItemModel" }, "title": "Response Onedrive List Children" } } } }, "401": { "description": "Missing or invalid authentication, or no valid connector token." }, "403": { "description": "User has not consented to the required scope." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/onedrive/me": { "get": { "tags": [ "OneDrive" ], "summary": "Get current data source user", "description": "Return the signed-in user's profile on this data source.", "operationId": "onedrive_get_user_info", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DataSourceUserModel" } } } }, "401": { "description": "Missing or invalid authentication, or no valid connector token." }, "403": { "description": "User has not consented to the required scope." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/onedrive/roots": { "get": { "tags": [ "OneDrive" ], "summary": "List top-level browse entries", "description": "List the source's top-level browse entries (sites or drives) with imported counts.", "operationId": "onedrive_list_roots", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "chat_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this chat.", "title": "Chat Id" }, "description": "Scope imported counts to this chat." }, { "name": "library_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this library.", "title": "Library Id" }, "description": "Scope imported counts to this library." }, { "name": "assistant_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this assistant.", "title": "Assistant Id" }, "description": "Scope imported counts to this assistant." }, { "name": "project_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this project.", "title": "Project Id" }, "description": "Scope imported counts to this project." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "anyOf": [ { "type": "array", "items": { "$ref": "#/components/schemas/DataSourceSiteModel" } }, { "type": "array", "items": { "$ref": "#/components/schemas/DataSourceDriveModel" } } ], "title": "Response Onedrive List Roots" } } } }, "401": { "description": "Missing or invalid authentication, or no valid connector token." }, "403": { "description": "User has not consented to the required scope." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/onedrive/sites/{site_id}/drives": { "get": { "tags": [ "OneDrive" ], "summary": "List drives in a site", "description": "List the drives under a site (or the user's drives for drive-rooted sources).", "operationId": "onedrive_list_drives", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "site_id", "in": "path", "required": true, "schema": { "type": "string", "description": "Id of the site to list drives for.", "title": "Site Id" }, "description": "Id of the site to list drives for." }, { "name": "chat_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this chat.", "title": "Chat Id" }, "description": "Scope imported counts to this chat." }, { "name": "library_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this library.", "title": "Library Id" }, "description": "Scope imported counts to this library." }, { "name": "assistant_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this assistant.", "title": "Assistant Id" }, "description": "Scope imported counts to this assistant." }, { "name": "project_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this project.", "title": "Project Id" }, "description": "Scope imported counts to this project." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/DataSourceDriveModel" }, "title": "Response Onedrive List Drives" } } } }, "401": { "description": "Missing or invalid authentication, or no valid connector token." }, "403": { "description": "User has not consented to the required scope." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/sharepoint/connected": { "get": { "tags": [ "Sharepoint" ], "summary": "Check SharePoint connection", "description": "Report whether the user has consented to the SharePoint file-read scope.", "operationId": "integrations_is_connected", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "boolean", "title": "Response Integrations Is Connected" } } } }, "401": { "description": "Missing or invalid authentication." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/sharepoint/drives/{drive_id}/items/{drive_item_id}": { "get": { "tags": [ "Sharepoint" ], "summary": "Get a drive item", "description": "Get a single SharePoint drive item, annotated with imported counts.", "operationId": "integrations_get_item_info", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "drive_id", "in": "path", "required": true, "schema": { "type": "string", "description": "Id of the drive.", "title": "Drive Id" }, "description": "Id of the drive." }, { "name": "drive_item_id", "in": "path", "required": true, "schema": { "type": "string", "description": "Id of the drive item.", "title": "Drive Item Id" }, "description": "Id of the drive item." }, { "name": "chat_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this chat.", "title": "Chat Id" }, "description": "Scope imported counts to this chat." }, { "name": "library_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this library.", "title": "Library Id" }, "description": "Scope imported counts to this library." }, { "name": "assistant_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this assistant.", "title": "Assistant Id" }, "description": "Scope imported counts to this assistant." }, { "name": "project_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this project.", "title": "Project Id" }, "description": "Scope imported counts to this project." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SharepointItemModel" } } } }, "401": { "description": "Missing or invalid authentication, or no valid connector token." }, "403": { "description": "User has not consented to the required SharePoint scope." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/sharepoint/drives/{drive_id}/items/{drive_item_id}/children": { "get": { "tags": [ "Sharepoint" ], "summary": "List children of a drive item", "description": "List files and folders under a drive item, annotated with imported counts.", "operationId": "integrations_list_children", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "drive_id", "in": "path", "required": true, "schema": { "type": "string", "description": "Id of the drive.", "title": "Drive Id" }, "description": "Id of the drive." }, { "name": "drive_item_id", "in": "path", "required": true, "schema": { "type": "string", "description": "Id of the parent item; empty or 'root' for the drive root.", "title": "Drive Item Id" }, "description": "Id of the parent item; empty or 'root' for the drive root." }, { "name": "chat_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this chat.", "title": "Chat Id" }, "description": "Scope imported counts to this chat." }, { "name": "library_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this library.", "title": "Library Id" }, "description": "Scope imported counts to this library." }, { "name": "assistant_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this assistant.", "title": "Assistant Id" }, "description": "Scope imported counts to this assistant." }, { "name": "project_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this project.", "title": "Project Id" }, "description": "Scope imported counts to this project." }, { "name": "recursive", "in": "query", "required": false, "schema": { "type": "boolean", "description": "Recurse into subfolders, returning only files.", "default": false, "title": "Recursive" }, "description": "Recurse into subfolders, returning only files." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/SharepointItemModel" }, "title": "Response Integrations List Children" } } } }, "401": { "description": "Missing or invalid authentication, or no valid connector token." }, "403": { "description": "User has not consented to the required SharePoint scope." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/sharepoint/me": { "get": { "tags": [ "Sharepoint" ], "summary": "Get current SharePoint user", "description": "Return the signed-in user's SharePoint / Microsoft Graph profile.", "operationId": "integrations_get_user_info", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SharepointUserModel" } } } }, "401": { "description": "Missing or invalid authentication, or no valid connector token." }, "403": { "description": "User has not consented to the required SharePoint scope." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/sharepoint/sites": { "get": { "tags": [ "Sharepoint" ], "summary": "List SharePoint sites", "description": "List the SharePoint sites the user can access, with imported document counts.", "operationId": "integrations_list_all_sites", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "chat_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this chat.", "title": "Chat Id" }, "description": "Scope imported counts to this chat." }, { "name": "library_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this library.", "title": "Library Id" }, "description": "Scope imported counts to this library." }, { "name": "assistant_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this assistant.", "title": "Assistant Id" }, "description": "Scope imported counts to this assistant." }, { "name": "project_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this project.", "title": "Project Id" }, "description": "Scope imported counts to this project." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/SharepointSiteModel" }, "title": "Response Integrations List All Sites" } } } }, "401": { "description": "Missing or invalid authentication, or no valid connector token." }, "403": { "description": "User has not consented to the required SharePoint scope." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/sharepoint/sites/{site_id}/drives": { "get": { "tags": [ "Sharepoint" ], "summary": "List drives in a site", "description": "List the document libraries (drives) within a SharePoint site.", "operationId": "integrations_list_drives", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "site_id", "in": "path", "required": true, "schema": { "type": "string", "description": "SharePoint site id.", "title": "Site Id" }, "description": "SharePoint site id." }, { "name": "chat_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this chat.", "title": "Chat Id" }, "description": "Scope imported counts to this chat." }, { "name": "library_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this library.", "title": "Library Id" }, "description": "Scope imported counts to this library." }, { "name": "assistant_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this assistant.", "title": "Assistant Id" }, "description": "Scope imported counts to this assistant." }, { "name": "project_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this project.", "title": "Project Id" }, "description": "Scope imported counts to this project." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/SharepointDriveModel" }, "title": "Response Integrations List Drives" } } } }, "401": { "description": "Missing or invalid authentication, or no valid connector token." }, "403": { "description": "User has not consented to the required SharePoint scope." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/sharepoint/v1/capabilities": { "get": { "tags": [ "Sharepoint v1" ], "summary": "Get data source capabilities", "description": "Return the browse-hierarchy metadata for this data source.", "operationId": "sharepointv1_capabilities", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DataSourceCapabilities" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/sharepoint/v1/connected": { "get": { "tags": [ "Sharepoint v1" ], "summary": "Check data source connection", "description": "Report whether the user has consented to this source's browse scopes.", "operationId": "sharepointv1_is_connected", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "boolean", "title": "Response Sharepointv1 Is Connected" } } } }, "401": { "description": "Missing or invalid authentication." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/sharepoint/v1/drives/{drive_id}/items/{drive_item_id}": { "get": { "tags": [ "Sharepoint v1" ], "summary": "Get a drive item", "description": "Get a single data source drive item, annotated with imported counts.", "operationId": "sharepointv1_get_item_info", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "drive_id", "in": "path", "required": true, "schema": { "type": "string", "description": "Id of the drive.", "title": "Drive Id" }, "description": "Id of the drive." }, { "name": "drive_item_id", "in": "path", "required": true, "schema": { "type": "string", "description": "Id of the drive item.", "title": "Drive Item Id" }, "description": "Id of the drive item." }, { "name": "chat_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this chat.", "title": "Chat Id" }, "description": "Scope imported counts to this chat." }, { "name": "library_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this library.", "title": "Library Id" }, "description": "Scope imported counts to this library." }, { "name": "assistant_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this assistant.", "title": "Assistant Id" }, "description": "Scope imported counts to this assistant." }, { "name": "project_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this project.", "title": "Project Id" }, "description": "Scope imported counts to this project." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DataSourceItemModel" } } } }, "401": { "description": "Missing or invalid authentication, or no valid connector token." }, "403": { "description": "User has not consented to the required scope." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/sharepoint/v1/drives/{drive_id}/items/{drive_item_id}/children": { "get": { "tags": [ "Sharepoint v1" ], "summary": "List children of a drive item", "description": "List files and folders under a drive item, annotated with imported counts.", "operationId": "sharepointv1_list_children", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "drive_id", "in": "path", "required": true, "schema": { "type": "string", "description": "Id of the drive.", "title": "Drive Id" }, "description": "Id of the drive." }, { "name": "drive_item_id", "in": "path", "required": true, "schema": { "type": "string", "description": "Id of the parent item; empty or 'root' for the drive root.", "title": "Drive Item Id" }, "description": "Id of the parent item; empty or 'root' for the drive root." }, { "name": "chat_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this chat.", "title": "Chat Id" }, "description": "Scope imported counts to this chat." }, { "name": "library_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this library.", "title": "Library Id" }, "description": "Scope imported counts to this library." }, { "name": "assistant_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this assistant.", "title": "Assistant Id" }, "description": "Scope imported counts to this assistant." }, { "name": "project_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this project.", "title": "Project Id" }, "description": "Scope imported counts to this project." }, { "name": "recursive", "in": "query", "required": false, "schema": { "type": "boolean", "description": "Recurse into subfolders, returning only files.", "default": false, "title": "Recursive" }, "description": "Recurse into subfolders, returning only files." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/DataSourceItemModel" }, "title": "Response Sharepointv1 List Children" } } } }, "401": { "description": "Missing or invalid authentication, or no valid connector token." }, "403": { "description": "User has not consented to the required scope." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/sharepoint/v1/me": { "get": { "tags": [ "Sharepoint v1" ], "summary": "Get current data source user", "description": "Return the signed-in user's profile on this data source.", "operationId": "sharepointv1_get_user_info", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DataSourceUserModel" } } } }, "401": { "description": "Missing or invalid authentication, or no valid connector token." }, "403": { "description": "User has not consented to the required scope." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/sharepoint/v1/roots": { "get": { "tags": [ "Sharepoint v1" ], "summary": "List top-level browse entries", "description": "List the source's top-level browse entries (sites or drives) with imported counts.", "operationId": "sharepointv1_list_roots", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "chat_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this chat.", "title": "Chat Id" }, "description": "Scope imported counts to this chat." }, { "name": "library_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this library.", "title": "Library Id" }, "description": "Scope imported counts to this library." }, { "name": "assistant_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this assistant.", "title": "Assistant Id" }, "description": "Scope imported counts to this assistant." }, { "name": "project_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this project.", "title": "Project Id" }, "description": "Scope imported counts to this project." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "anyOf": [ { "type": "array", "items": { "$ref": "#/components/schemas/DataSourceSiteModel" } }, { "type": "array", "items": { "$ref": "#/components/schemas/DataSourceDriveModel" } } ], "title": "Response Sharepointv1 List Roots" } } } }, "401": { "description": "Missing or invalid authentication, or no valid connector token." }, "403": { "description": "User has not consented to the required scope." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/integrations/sharepoint/v1/sites/{site_id}/drives": { "get": { "tags": [ "Sharepoint v1" ], "summary": "List drives in a site", "description": "List the drives under a site (or the user's drives for drive-rooted sources).", "operationId": "sharepointv1_list_drives", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "site_id", "in": "path", "required": true, "schema": { "type": "string", "description": "Id of the site to list drives for.", "title": "Site Id" }, "description": "Id of the site to list drives for." }, { "name": "chat_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this chat.", "title": "Chat Id" }, "description": "Scope imported counts to this chat." }, { "name": "library_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this library.", "title": "Library Id" }, "description": "Scope imported counts to this library." }, { "name": "assistant_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this assistant.", "title": "Assistant Id" }, "description": "Scope imported counts to this assistant." }, { "name": "project_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Scope imported counts to this project.", "title": "Project Id" }, "description": "Scope imported counts to this project." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/DataSourceDriveModel" }, "title": "Response Sharepointv1 List Drives" } } } }, "401": { "description": "Missing or invalid authentication, or no valid connector token." }, "403": { "description": "User has not consented to the required scope." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/invitations/": { "post": { "tags": [ "Invitation" ], "summary": "Create invitations", "description": "Invite the given email addresses, skipping ones already invited or registered.", "operationId": "invitations_create_invitations", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/InvitationIn" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/InvitationOut" }, "title": "Response Invitations Create Invitations" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Tenant admin or project owner privileges required." }, "404": { "description": "The target tenant or project does not exist." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/invitations/accept": { "get": { "tags": [ "Invitation" ], "summary": "Invitation acceptance HTML form", "description": "Fallback HTML form for accepting invitation when no frontend is available.", "operationId": "invitations_accept_invitation_form", "parameters": [ { "name": "token", "in": "query", "required": true, "schema": { "type": "string", "description": "Invitation JWT token", "title": "Token" }, "description": "Invitation JWT token" } ], "responses": { "200": { "description": "Successful Response", "content": { "text/html": { "schema": { "type": "string" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "post": { "tags": [ "Invitation" ], "summary": "Accept an invitation", "description": "Complete invitation acceptance and create user account.", "operationId": "invitations_accept_invitation_complete", "parameters": [ { "name": "token", "in": "query", "required": true, "schema": { "type": "string", "description": "Invitation JWT token", "title": "Token" }, "description": "Invitation JWT token" } ], "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/invitations/{invitation_id}/resend": { "post": { "tags": [ "Invitation" ], "summary": "Resend an invitation", "description": "Resend the invitation email for a pending invitation.", "operationId": "invitations_resend_invitation", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "invitation_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the invitation to resend.", "title": "Invitation Id" }, "description": "ID of the invitation to resend." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/InvitationOut" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Tenant admin privileges required." }, "404": { "description": "No invitation exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/invitations/{invitation_id}/revoke": { "post": { "tags": [ "Invitation" ], "summary": "Revoke an invitation", "description": "Revoke a pending invitation so its token can no longer be used.", "operationId": "invitations_revoke_invitation", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "invitation_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the invitation to revoke.", "title": "Invitation Id" }, "description": "ID of the invitation to revoke." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Tenant admin privileges required." }, "404": { "description": "No invitation exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/libraries/": { "post": { "tags": [ "Library" ], "summary": "Create a library", "description": "Create a library owned by the caller in their tenant.", "operationId": "libraries_new_library", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LibraryIn" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Library" } } } }, "401": { "description": "Missing or invalid authentication." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/libraries/{library_id}": { "delete": { "tags": [ "Library" ], "summary": "Delete a library", "description": "Delete a library; owner only.", "operationId": "libraries_delete_library", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "library_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Library Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Caller is not an owner of this library." }, "404": { "description": "No library exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "patch": { "tags": [ "Library" ], "summary": "Update a library", "description": "Update name and/or description of an existing library.", "operationId": "libraries_update_library", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "library_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Library Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LibraryUpdateIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Library" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Caller is not a member of this library." }, "404": { "description": "No library exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/libraries/{library_id}/members": { "delete": { "tags": [ "Library" ], "summary": "Remove library members", "description": "Remove one or more members from the library; owner only.", "operationId": "libraries_remove_library_members", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "library_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Library Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LibraryMemberBulkDelete" } } } }, "responses": { "204": { "description": "Successful Response" }, "400": { "description": "Cannot remove the sole owner of the library." }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Caller is not an owner of this library." }, "404": { "description": "No library exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "post": { "tags": [ "Library" ], "summary": "Add library members", "description": "Add one or more members to the library; owner only.", "operationId": "libraries_add_library_members", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "library_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Library Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LibraryMemberBulkIn" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/LibraryMember" }, "title": "Response Libraries Add Library Members" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Caller is not an owner of this library." }, "404": { "description": "No library exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/libraries/{library_id}/members/{user_id}": { "delete": { "tags": [ "Library" ], "summary": "Remove a library member", "description": "Remove a member from the library; owner only unless removing yourself.", "operationId": "libraries_remove_single_member", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "library_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Library Id" } }, { "name": "user_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the member to remove.", "title": "User Id" }, "description": "ID of the member to remove." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "400": { "description": "Cannot remove the sole owner of the library." }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Caller may not remove this member." }, "404": { "description": "No library exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/libraries/{library_id}/remove/me": { "delete": { "tags": [ "Library" ], "summary": "Leave a library", "description": "Remove the caller from the library's members.", "operationId": "libraries_leave_library", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "library_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Library Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "400": { "description": "Cannot leave while you are the sole owner of the library." }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Caller is not a member of this library." }, "404": { "description": "No library exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/llm/catalog": { "post": { "tags": [ "LlmCatalog" ], "summary": "Create a catalog entry", "description": "Register a new LLM in the model catalog.", "operationId": "llm_create_catalog", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CatalogIn" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Platform operator privileges required." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/llm/catalog/{catalog_id}": { "delete": { "tags": [ "LlmCatalog" ], "summary": "Delete a catalog entry", "description": "Remove a catalog entry permanently.", "operationId": "llm_delete_catalog", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "catalog_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the catalog entry to delete.", "title": "Catalog Id" }, "description": "ID of the catalog entry to delete." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Platform operator privileges required." }, "404": { "description": "No catalog entry exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "patch": { "tags": [ "LlmCatalog" ], "summary": "Update a catalog entry", "description": "Update fields of an existing catalog entry.", "operationId": "llm_update_catalog", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "catalog_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the catalog entry to update.", "title": "Catalog Id" }, "description": "ID of the catalog entry to update." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CatalogUpdate" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Platform operator privileges required." }, "404": { "description": "No catalog entry exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/llm/cost": { "post": { "tags": [ "Llm" ], "summary": "Get LLM cost metrics", "description": "Return current-month total LLM cost and per-model cost timeseries for the tenant.", "operationId": "llm_get_cost", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UsageRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TimeseriesResponse" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Admin privileges required." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/llm/services/cost": { "post": { "tags": [ "Llm" ], "summary": "Get external service usage costs", "description": "Return non-LLM service usage costs aggregated by source, model, and time period.", "operationId": "llm_get_usage_costs", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UsageCostRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UsageCostResponse" } } } }, "400": { "description": "Custom granularity requires both date_start and date_end." }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Admin privileges required." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/llm/settings": { "post": { "tags": [ "LlmSetting" ], "summary": "Create LLM settings", "description": "Create a provider-specific settings entry for a catalog model.", "operationId": "llm_create_llm_settings", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LLMSettingsIn" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Platform operator privileges required." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/llm/settings/{settings_id}": { "delete": { "tags": [ "LlmSetting" ], "summary": "Delete LLM settings", "description": "Remove an LLM settings entry permanently.", "operationId": "llm_delete_llm_settings", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "settings_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the LLM settings entry to delete.", "title": "Settings Id" }, "description": "ID of the LLM settings entry to delete." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Platform operator privileges required." }, "404": { "description": "No LLM settings exist with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "patch": { "tags": [ "LlmSetting" ], "summary": "Update LLM settings", "description": "Update fields of an existing LLM settings entry.", "operationId": "llm_update_llm_settings", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "settings_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the LLM settings entry to update.", "title": "Settings Id" }, "description": "ID of the LLM settings entry to update." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LLMSettingsUpdate" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Platform operator privileges required." }, "404": { "description": "No LLM settings exist with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/llm/tokens": { "post": { "tags": [ "Llm" ], "summary": "Get token usage metrics", "description": "Return current-month token totals and per-model token timeseries for the tenant.", "operationId": "llm_llm_total_tokens", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UsageRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TokensTimeseriesResponse" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Admin privileges required." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/messages/": { "post": { "tags": [ "Message" ], "summary": "Create a message", "description": "Send a JSON message to a chat (or start a new one) and enqueue generation.", "operationId": "messages_create_message", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/MessageIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Message" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "No access to the chat/project/assistant, or usage budget exceeded." }, "404": { "description": "Referenced chat or assistant does not exist." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/messages/submit": { "post": { "tags": [ "Message" ], "summary": "Submit a message with attachments", "description": "Send a multipart message with optional file uploads and enqueue generation.", "operationId": "messages_submit_message", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "content": { "multipart/form-data": { "schema": { "$ref": "#/components/schemas/Body_messages_submit_message" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Message" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "No access to the chat/project/assistant, or usage budget exceeded." }, "404": { "description": "Referenced chat or assistant does not exist." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/messages/{message_id}": { "get": { "tags": [ "Message" ], "summary": "Get a message", "description": "Canonical recovery endpoint: full composed state of a message.", "operationId": "messages_get_message", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "message_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the message to fetch.", "title": "Message Id" }, "description": "ID of the message to fetch." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/MessageDetailOut" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "No access to the chat the message belongs to." }, "404": { "description": "Message or its chat does not exist." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/messages/{message_id}/convert": { "get": { "tags": [ "Message" ], "summary": "Convert a message to a document", "description": "Convert a message to various document formats.", "operationId": "messages_convert_message", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "message_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the message to convert.", "title": "Message Id" }, "description": "ID of the message to convert." }, { "name": "format", "in": "query", "required": true, "schema": { "$ref": "#/components/schemas/OutputFormat", "description": "Output format" }, "description": "Output format" }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "No access to the message's chat." }, "404": { "description": "Message or its chat does not exist." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/messages/{message_id}/rephrase": { "get": { "tags": [ "Message" ], "summary": "Rephrase a message", "description": "Rephrase a message's content in the requested style.", "operationId": "messages_rephrase_message", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "message_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the message to rephrase.", "title": "Message Id" }, "description": "ID of the message to rephrase." }, { "name": "style", "in": "query", "required": true, "schema": { "$ref": "#/components/schemas/RephraseStyleEnum", "description": "Style of rephrasing: 'same' (same length), 'short' (shorter), or 'long' (longer)" }, "description": "Style of rephrasing: 'same' (same length), 'short' (shorter), or 'long' (longer)" }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Translation" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "No access to the message's chat, or usage budget exceeded." }, "404": { "description": "Message, its chat, or owning user does not exist." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/messages/{message_id}/translate": { "get": { "tags": [ "Message" ], "summary": "Translate a message", "description": "Translate a message's content into the requested language.", "operationId": "messages_translate_message", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "message_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the message to translate.", "title": "Message Id" }, "description": "ID of the message to translate." }, { "name": "lang", "in": "query", "required": true, "schema": { "type": "string", "description": "Target language. Preferably RFC 5646 format.", "title": "Lang" }, "description": "Target language. Preferably RFC 5646 format." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Translation" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "No access to the message's chat, or usage budget exceeded." }, "404": { "description": "Message, its chat, or owning user does not exist." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/post": { "post": { "summary": "Post Check", "description": "Power-On Self-Test (POST) endpoint.\nRuns comprehensive health checks for all configured services and returns results.", "operationId": "post_post_check", "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } } } } }, "/projects/": { "post": { "tags": [ "Project" ], "summary": "Create a project", "description": "Create a project and add the current user as its owner.", "operationId": "projects_create_project", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProjectIn" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Project" } } } }, "401": { "description": "Missing or invalid authentication." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/projects/available": { "get": { "tags": [ "Project" ], "summary": "Check if a project name is free", "description": "Return true if no project already uses the given name.", "operationId": "projects_is_project_name_free", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "name", "in": "query", "required": true, "schema": { "type": "string", "description": "Project name to check for availability.", "title": "Name" }, "description": "Project name to check for availability." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "boolean", "title": "Response Projects Is Project Name Free" } } } }, "401": { "description": "Missing or invalid authentication." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/projects/{project_id}": { "delete": { "tags": [ "Project" ], "summary": "Delete a project", "description": "Permanently delete a project (project owner only).", "operationId": "projects_delete_project", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "project_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Project Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Current user is not an owner of the project." }, "404": { "description": "No project exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "patch": { "tags": [ "Project" ], "summary": "Update a project", "description": "Update an existing project's fields (project owner only).", "operationId": "projects_update_project", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "project_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Project Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProjectIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Project" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Current user is not an owner of the project." }, "404": { "description": "No project exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/projects/{project_id}/libraries/{library_id}": { "delete": { "tags": [ "Project" ], "summary": "Remove a library from a project", "description": "Disable a library for a project by deleting the association.", "operationId": "projects_remove_library_from_project", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "project_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Project Id" } }, { "name": "library_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the library to disable.", "title": "Library Id" }, "description": "ID of the library to disable." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Current user is not a member of the project." }, "404": { "description": "No project exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "post": { "tags": [ "Project" ], "summary": "Add a library to a project", "description": "Enable a library for a project by creating an association.", "operationId": "projects_add_library_to_project", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "project_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Project Id" } }, { "name": "library_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Library Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProjectLibrary" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Current user lacks access to the library or the project." }, "404": { "description": "Library or project not found." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/projects/{project_id}/members": { "delete": { "tags": [ "Project" ], "summary": "Remove members from a project", "description": "Remove multiple members from a project (project owner only).", "operationId": "projects_delete_members", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "project_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Project Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProjectMemberBulkDelete" } } } }, "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Current user is not an owner of the project." }, "404": { "description": "Project not found, or a user is not a member of it." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "post": { "tags": [ "Project" ], "summary": "Add members to a project", "description": "Add one or more members to a project (project owner only).", "operationId": "projects_add_members", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "project_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Project Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProjectMemberBulkIn" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/ProjectMember" }, "title": "Response Projects Add Members" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Current user is not an owner of the project." }, "404": { "description": "No project exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/projects/{project_id}/members/{user_id}": { "delete": { "tags": [ "Project" ], "summary": "Remove a member from a project", "description": "Remove a single member from a project (project owner only).", "operationId": "projects_delete_member", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "project_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Project Id" } }, { "name": "user_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the user to remove.", "title": "User Id" }, "description": "ID of the user to remove." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Current user is not an owner of the project." }, "404": { "description": "Project not found, or the user is not a member of it." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/projects/{project_id}/remove/me": { "delete": { "tags": [ "Project" ], "summary": "Leave a project", "description": "Remove the current user from a project they belong to.", "operationId": "projects_leave_project", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "project_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Project Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Current user is not a member of the project." }, "404": { "description": "Project not found, or the user is not a member of it." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/prompts/": { "post": { "tags": [ "Prompt" ], "summary": "Create a prompt", "description": "Create a saved prompt for the current user.", "operationId": "prompts_create_prompt", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PromptIn" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Prompt" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Only admins may create public prompts." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/prompts/optimize": { "post": { "tags": [ "Prompt" ], "summary": "Optimize a prompt", "description": "Rewrite a draft prompt into a clearer, better-structured version using an LLM.", "operationId": "prompts_optimize_prompt", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PromptOptimizeIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PromptOptimizeOut" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Usage budget exceeded." }, "404": { "description": "Current user does not exist." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/prompts/{prompt_id}": { "delete": { "tags": [ "Prompt" ], "summary": "Delete a prompt", "description": "Delete a prompt owned by the current user.", "operationId": "prompts_delete_prompt", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "prompt_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the prompt to delete.", "title": "Prompt Id" }, "description": "ID of the prompt to delete." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Not the creator of this prompt." }, "404": { "description": "No prompt exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "patch": { "tags": [ "Prompt" ], "summary": "Update a prompt", "description": "Update a prompt owned by the current user.", "operationId": "prompts_update_prompt", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "prompt_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the prompt to update.", "title": "Prompt Id" }, "description": "ID of the prompt to update." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PromptIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Prompt" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Not the creator, or only admins may make a prompt public." }, "404": { "description": "No prompt exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/query/rpc/{path}": { "get": { "tags": [ "Query" ], "summary": "Proxy a PostgREST RPC call", "description": "Forward the request to an upstream PostgREST RPC endpoint and return its response.", "operationId": "query_query_rpc", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "path", "in": "path", "required": true, "schema": { "type": "string", "description": "PostgREST RPC function name to invoke.", "title": "Path" }, "description": "PostgREST RPC function name to invoke." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "401": { "description": "Missing or invalid authentication." }, "502": { "description": "The upstream PostgREST service is unavailable." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/query/{path}": { "get": { "tags": [ "Query" ], "summary": "Proxy a PostgREST query", "description": "Forward the request to the upstream PostgREST service and return its response.", "operationId": "query_query", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "path", "in": "path", "required": true, "schema": { "type": "string", "description": "PostgREST resource path to proxy.", "title": "Path" }, "description": "PostgREST resource path to proxy." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "401": { "description": "Missing or invalid authentication." }, "502": { "description": "The upstream PostgREST service is unavailable." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/settings/current": { "get": { "tags": [ "Settings" ], "summary": "Get current tenant settings", "description": "Get the settings for the current user's tenant, creating defaults if absent.", "operationId": "settings_current", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Settings" } } } }, "401": { "description": "Missing or invalid authentication." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "patch": { "tags": [ "Settings" ], "summary": "Update current tenant settings", "description": "Update the settings for the current user's tenant (tenant admin only).", "operationId": "settings_update_current_settings", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SettingsIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Settings" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Tenant admin privileges required." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/settings/{settings_id}": { "patch": { "tags": [ "Settings" ], "summary": "Update settings by id", "description": "Update a tenant's settings by id (tenant admin; some fields superadmin-only).", "operationId": "settings_update_settings", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "settings_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the settings record to update.", "title": "Settings Id" }, "description": "ID of the settings record to update." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SettingsIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Settings" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Tenant admin privileges required, or superadmin required to change protected fields." }, "404": { "description": "No settings record exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/stat": { "get": { "summary": "Stat", "description": "Returns application stat.", "operationId": "stat_stat", "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } } } } }, "/storage/{path}": { "get": { "tags": [ "Storage" ], "summary": "Download a file by signed token", "description": "Stream a stored file as an attachment, authorized by a signed download token.", "operationId": "storage_download_file", "parameters": [ { "name": "path", "in": "path", "required": true, "schema": { "type": "string", "description": "Storage path of the file to download.", "title": "Path" }, "description": "Storage path of the file to download." }, { "name": "token", "in": "query", "required": true, "schema": { "type": "string", "description": "Signed download token authorizing access to the file.", "title": "Token" }, "description": "Signed download token authorizing access to the file." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "400": { "description": "Token is malformed or missing required claims." }, "401": { "description": "Token issuer is not trusted." }, "404": { "description": "Token does not match the path, or the file no longer exists." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/system/settings": { "get": { "tags": [ "System" ], "summary": "Read System Settings", "operationId": "system_read_system_settings", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SystemSettings" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "patch": { "tags": [ "System" ], "summary": "Update System Settings", "operationId": "system_update_system_settings", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SystemSettingsUpdate" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SystemSettings" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/tags/": { "post": { "tags": [ "Tag" ], "summary": "Create a tag", "description": "Create a new tag in the caller's tenant.", "operationId": "tags_new_tag", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TagIn" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Tag" } } } }, "401": { "description": "Missing or invalid authentication." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/tags/{tag_id}": { "delete": { "tags": [ "Tag" ], "summary": "Delete a tag", "description": "Delete a tag. CASCADE removes all taggings.", "operationId": "tags_delete_tag", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "tag_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Tag Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Tag belongs to another tenant." }, "404": { "description": "No tag exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "patch": { "tags": [ "Tag" ], "summary": "Rename a tag", "description": "Rename a tag in the caller's tenant.", "operationId": "tags_update_tag", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "tag_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Tag Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TagIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Tag" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Tag belongs to another tenant." }, "404": { "description": "No tag exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/tarifs/": { "post": { "tags": [ "Tarif" ], "summary": "Create a tarif plan", "description": "Create a new tarif plan.", "operationId": "tarifs_create_tarif", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TarifIn" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Tarif" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Platform operator or parent tenant admin privileges required." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/tarifs/{tarif_id}": { "delete": { "tags": [ "Tarif" ], "summary": "Delete a tarif plan", "description": "Delete a tarif plan.", "operationId": "tarifs_delete_tarif", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "tarif_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the tarif to delete.", "title": "Tarif Id" }, "description": "ID of the tarif to delete." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Insufficient privileges, or tariff not deletable by your tenant." }, "404": { "description": "No tarif exists with the given id." }, "409": { "description": "Tarif is the active plan for one or more tenants and cannot be deleted." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "patch": { "tags": [ "Tarif" ], "summary": "Update a tarif plan", "description": "Update an existing tarif plan.", "operationId": "tarifs_update_tarif", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "tarif_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the tarif to update.", "title": "Tarif Id" }, "description": "ID of the tarif to update." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TarifIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Tarif" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Insufficient privileges, or tariff not editable by your tenant." }, "404": { "description": "No tarif exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/templates/": { "post": { "tags": [ "Template" ], "summary": "Create an email template", "description": "Create a new email template for the current user's tenant.", "operationId": "templates_create", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TemplateIn" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TemplateOut" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Admin privileges required." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/templates/{template_id}": { "delete": { "tags": [ "Template" ], "summary": "Delete an email template", "description": "Delete an email template.", "operationId": "templates_delete", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "template_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the template to delete.", "title": "Template Id" }, "description": "ID of the template to delete." }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Admin privileges required." }, "404": { "description": "No email template exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "patch": { "tags": [ "Template" ], "summary": "Update an email template", "description": "Update an existing email template.", "operationId": "templates_update", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "template_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the template to update.", "title": "Template Id" }, "description": "ID of the template to update." }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TemplateIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TemplateOut" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Admin privileges required." }, "404": { "description": "No email template exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/tenants/": { "post": { "tags": [ "Tenant" ], "summary": "Create a tenant", "description": "Create a new tenant (platform operator or parent tenant admin).", "operationId": "tenants_create_tenant", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenantIn" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenantOut" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Tenant admin privileges required, or not permitted to create this kind of tenant." }, "404": { "description": "Current user or parent tenant not found." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/tenants/current": { "get": { "tags": [ "Tenant" ], "summary": "Get current tenant", "description": "Get the tenant the current user belongs to.", "operationId": "tenants_get_current_tenant", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenantOut" } } } }, "401": { "description": "Missing or invalid authentication." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "patch": { "tags": [ "Tenant" ], "summary": "Update current tenant", "description": "Update the current user's tenant (tenant admin; some fields superadmin-only).", "operationId": "tenants_update_current_tenant", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenantUpdateIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenantOut" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Tenant admin privileges required, or superadmin required to change protected fields." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/tenants/models/{model_id}/bulk": { "delete": { "tags": [ "Tenant" ], "summary": "Disable a model for multiple tenants", "description": "Disable an LLM catalog model for all tenants or a list of tenants (superadmin).", "operationId": "tenants_delete_tenant_models_bulk", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "model_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the LLM catalog model to disable.", "title": "Model Id" }, "description": "ID of the LLM catalog model to disable." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenantModelBulkIn" } } } }, "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Superadmin privileges required." }, "404": { "description": "Catalog model not found, or a target tenant not found." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "put": { "tags": [ "Tenant" ], "summary": "Enable a model for multiple tenants", "description": "Enable an LLM catalog model for all tenants or a list of tenants (superadmin).", "operationId": "tenants_put_tenant_models_bulk", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "model_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the LLM catalog model to enable.", "title": "Model Id" }, "description": "ID of the LLM catalog model to enable." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenantModelBulkIn" } } } }, "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Superadmin privileges required." }, "404": { "description": "Catalog model not found, or a target tenant not found." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/tenants/{tenant_id}": { "delete": { "tags": [ "Tenant" ], "summary": "Delete a tenant", "description": "Delete a tenant by id (superadmin or parent tenant admin).", "operationId": "tenants_delete_tenant", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "tenant_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Tenant Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Superadmin or parent tenant admin required." }, "404": { "description": "No tenant exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "patch": { "tags": [ "Tenant" ], "summary": "Update a tenant", "description": "Update a tenant by id (superadmin or parent tenant admin).", "operationId": "tenants_update_tenant", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "tenant_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Tenant Id" } }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenantUpdateIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenantOut" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Superadmin or parent tenant admin required; some fields require superadmin." }, "404": { "description": "No tenant exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/tenants/{tenant_id}/connectors/{connector_id}": { "delete": { "tags": [ "Tenant" ], "summary": "Disable a connector for a tenant", "description": "Disable a connector for a tenant (superadmin or parent tenant admin).", "operationId": "tenants_delete_tenant_connector", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "tenant_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Tenant Id" } }, { "name": "connector_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the connector to disable.", "title": "Connector Id" }, "description": "ID of the connector to disable." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Superadmin or parent tenant admin required." }, "404": { "description": "The connector is not enabled for the tenant." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "post": { "tags": [ "Tenant" ], "summary": "Enable a connector for a tenant", "description": "Enable a connector for a tenant (superadmin or parent tenant admin).", "operationId": "tenants_create_tenant_connector", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "tenant_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Tenant Id" } }, { "name": "connector_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the connector to enable.", "title": "Connector Id" }, "description": "ID of the connector to enable." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Superadmin or parent tenant admin required." }, "404": { "description": "No connector exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/tenants/{tenant_id}/libraries/{library_id}": { "delete": { "tags": [ "Tenant" ], "summary": "Unassign a library from a tenant", "description": "Remove a library assignment from a tenant (library owner who is tenant admin).", "operationId": "tenants_remove_tenant_library_member", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "library_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Library Id" } }, { "name": "tenant_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the tenant.", "title": "Tenant Id" }, "description": "ID of the tenant." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Library owner and tenant admin privileges required." }, "404": { "description": "The library is not assigned to the tenant." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "post": { "tags": [ "Tenant" ], "summary": "Assign a library to a tenant", "description": "Assign a library to a tenant (library owner who is admin of that tenant).", "operationId": "tenants_add_library_to_tenants", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "library_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Library Id" } }, { "name": "tenant_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the tenant.", "title": "Tenant Id" }, "description": "ID of the tenant." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Library owner and tenant admin privileges required." }, "404": { "description": "Current user not found." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/tenants/{tenant_id}/models/{model_id}": { "delete": { "tags": [ "Tenant" ], "summary": "Disable a model for a tenant", "description": "Disable an LLM catalog model for a tenant (superadmin or parent tenant admin).", "operationId": "tenants_delete_tenant_model", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "tenant_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Tenant Id" } }, { "name": "model_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the LLM catalog model to disable.", "title": "Model Id" }, "description": "ID of the LLM catalog model to disable." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Superadmin or parent tenant admin required." }, "404": { "description": "Tenant model association not found." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "put": { "tags": [ "Tenant" ], "summary": "Enable a model for a tenant", "description": "Enable an LLM catalog model for a tenant (superadmin or parent tenant admin).", "operationId": "tenants_put_tenant_model", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "tenant_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Tenant Id" } }, { "name": "model_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the LLM catalog model to enable.", "title": "Model Id" }, "description": "ID of the LLM catalog model to enable." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenantLLM" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Superadmin or parent tenant admin required." }, "404": { "description": "Tenant or catalog model not found." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/tenants/{tenant_id}/tools/{tool_id}": { "delete": { "tags": [ "Tenant" ], "summary": "Disable a tool for a tenant", "description": "Disable a tool for a tenant (superadmin or parent tenant admin).", "operationId": "tenants_delete_tenant_tool", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "tenant_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Tenant Id" } }, { "name": "tool_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the tool to disable.", "title": "Tool Id" }, "description": "ID of the tool to disable." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Superadmin or parent tenant admin required." }, "404": { "description": "The tool is not enabled for the tenant." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "post": { "tags": [ "Tenant" ], "summary": "Enable a tool for a tenant", "description": "Enable a tool for a tenant (superadmin or parent tenant admin).", "operationId": "tenants_create_tenant_tool", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "tenant_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Tenant Id" } }, { "name": "tool_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the tool to enable.", "title": "Tool Id" }, "description": "ID of the tool to enable." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Superadmin or parent tenant admin required." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/theme": { "get": { "summary": "Get Theme", "description": "Get the icon for a tenant", "operationId": "theme_get_theme", "parameters": [ { "name": "origin", "in": "header", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Origin" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TenantThemeOut" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/tool-actions/email/send": { "post": { "tags": [ "ToolAction" ], "summary": "Send an email from a draft", "description": "Send an email from a user-approved, tool-generated draft via Microsoft Graph.", "operationId": "toolactions_send_email_from_draft", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SendEmailRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SendEmailResponse" } } } }, "400": { "description": "No recipient provided or the mail provider rejected the send." }, "401": { "description": "Missing or invalid authentication." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/tools/{tool_id}": { "patch": { "tags": [ "Tool" ], "summary": "Update a tool", "description": "Update a tool's editable fields (superadmin only).", "operationId": "tools_update_tool", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "tool_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the tool to update.", "title": "Tool Id" }, "description": "ID of the tool to update." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ToolUpdate" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ToolOut" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Caller is not a superadmin." }, "404": { "description": "No tool exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/transcriptions/": { "post": { "tags": [ "Transcription" ], "summary": "Transcribe an audio file", "description": "Transcribe an uploaded audio file via the configured Whisper provider.", "operationId": "transcriptions_create_transcription", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "multipart/form-data": { "schema": { "$ref": "#/components/schemas/Body_transcriptions_create_transcription" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TranscriptionOut" } } } }, "401": { "description": "Missing or invalid authentication." }, "413": { "description": "Audio file exceeds the 25 MB limit." }, "415": { "description": "Unsupported audio content type." }, "502": { "description": "Transcription provider request failed." }, "503": { "description": "No transcription provider is configured or available." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/users/": { "post": { "tags": [ "User" ], "summary": "Create a user", "description": "Create a user in the caller's (or specified) tenant and send a confirmation email.", "operationId": "users_create_user", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserIn" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserOut" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Administrator privileges required for the target tenant or flags." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/users/groups": { "post": { "tags": [ "User" ], "summary": "Create a user group", "description": "Create a new user group", "operationId": "users_create_group", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GroupIn" } } } }, "responses": { "201": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserGroup" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Administrator privileges required." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/users/groups/{group_id}": { "delete": { "tags": [ "User" ], "summary": "Delete a user group", "description": "Delete a user group.", "operationId": "users_delete_group", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "group_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the user group to delete.", "title": "Group Id" }, "description": "ID of the user group to delete." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "responses": { "204": { "description": "Successful Response" }, "400": { "description": "Group belongs to another tenant." }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Administrator privileges required." }, "404": { "description": "No user group exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "patch": { "tags": [ "User" ], "summary": "Update a user group", "description": "Update an existing user group.", "operationId": "users_update_group", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "group_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the user group to update.", "title": "Group Id" }, "description": "ID of the user group to update." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GroupIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserGroup" } } } }, "400": { "description": "Group belongs to another tenant or caller lacks admin rights." }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Administrator privileges required." }, "404": { "description": "No user group exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/users/me": { "get": { "tags": [ "User" ], "summary": "Get current user", "description": "Return the profile of the currently authenticated user.", "operationId": "users_get_myself", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserOut" } } } }, "401": { "description": "Missing or invalid authentication." }, "404": { "description": "The current user no longer exists." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/users/me/preferences": { "patch": { "tags": [ "User" ], "summary": "Update own preferences", "description": "Create or update the current user's UI preferences.", "operationId": "users_upsert_my_preferences", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserPreferenceUpdateIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserPreferenceOut" } } } }, "401": { "description": "Missing or invalid authentication." }, "404": { "description": "The current user no longer exists." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/users/members/{group_id}": { "put": { "tags": [ "User" ], "summary": "Set user group members", "description": "Synchronize group members \u2014 add new ones and remove missing ones.", "operationId": "users_upsert_members", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "group_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the user group to update.", "title": "Group Id" }, "description": "ID of the user group to update." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "type": "array", "items": { "type": "integer" }, "title": "User Ids" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/UserGroupMember" }, "title": "Response Users Upsert Members" } } } }, "400": { "description": "Group belongs to another tenant." }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Administrator privileges required." }, "404": { "description": "No user group exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/users/passwd": { "post": { "tags": [ "User" ], "summary": "Change own password", "description": "Change the current user's password and revoke all of their sessions.", "operationId": "users_reset_password", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PasswordResetIn" } } } }, "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication, or wrong current password." }, "404": { "description": "The current user no longer exists." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/users/{user_id}": { "delete": { "tags": [ "User" ], "summary": "Delete a user", "description": "Delete a user; you cannot delete your own account.", "operationId": "users_delete_user", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "user_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the user to delete.", "title": "User Id" }, "description": "ID of the user to delete." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "responses": { "204": { "description": "Successful Response" }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Administrator privileges required for the user's tenant." }, "404": { "description": "No user exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "patch": { "tags": [ "User" ], "summary": "Update a user", "description": "Update a user's profile, role, tenant, or email; password changes are restricted.", "operationId": "users_update_user", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "user_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the user to update.", "title": "User Id" }, "description": "ID of the user to update." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserUpdateIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserOut" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Insufficient privileges to change the requested fields or tenant." }, "404": { "description": "No user exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/users/{user_id}/activate": { "post": { "tags": [ "User" ], "summary": "Activate a user", "description": "Re-activate a user so they can authenticate again.", "operationId": "users_activate_user", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "user_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the user to activate.", "title": "User Id" }, "description": "ID of the user to activate." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserOut" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Administrator privileges required for the user's tenant." }, "404": { "description": "No user exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/users/{user_id}/deactivate": { "post": { "tags": [ "User" ], "summary": "Deactivate a user", "description": "Deactivate a user so they can no longer authenticate; you cannot deactivate yourself.", "operationId": "users_deactivate_user", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "user_id", "in": "path", "required": true, "schema": { "type": "integer", "description": "ID of the user to deactivate.", "title": "User Id" }, "description": "ID of the user to deactivate." }, { "name": "cookie_name", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Cookie Name" } }, { "name": "tenant_id", "in": "query", "required": false, "schema": { "type": "integer", "title": "Tenant Id" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserOut" } } } }, "401": { "description": "Missing or invalid authentication." }, "403": { "description": "Administrator privileges required for the user's tenant." }, "404": { "description": "No user exists with the given id." }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/version": { "get": { "summary": "Version", "description": "Returns version information about the deployed application.", "operationId": "version_version", "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } } } } } }, "components": { "schemas": { "ApiKey": { "properties": { "id": { "type": "integer", "title": "Id", "description": "Primary key for api keys" }, "name": { "anyOf": [ { "type": "string", "maxLength": 100 }, { "type": "null" } ], "title": "Name", "description": "Name for the key to be created. Max 100 characters." }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description of the key." }, "key_id": { "type": "string", "maxLength": 40, "title": "Key Id", "description": "Public part of the key" }, "environment": { "type": "string", "title": "Environment", "description": "Environment where the key is used." }, "hashed_secret": { "type": "string", "maxLength": 128, "title": "Hashed Secret", "description": "hashed api key" }, "active": { "type": "boolean", "title": "Active", "description": "Whether the API key is currently active.", "default": true, "examples": [ true ] }, "version": { "type": "string", "title": "Version", "description": "Version of the API key for rotation purposes.", "default": "v1" }, "creator_user_id": { "type": "integer", "title": "Creator User Id", "description": "ID of the user who created the key." }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "Timestamp when the key was created." }, "last_used_at": { "type": "string", "format": "date-time", "title": "Last Used At", "description": "Timestamp when the API key was last used.", "examples": [ "2026-06-23T12:00:00Z" ] }, "expires_at": { "type": "string", "format": "date-time", "title": "Expires At", "description": "Timestamp when the API key expires.", "examples": [ "2027-06-23T12:00:00Z" ] } }, "type": "object", "required": [ "key_id", "hashed_secret", "creator_user_id" ], "title": "ApiKey", "description": "api key model" }, "ApiKeyCreateRequest": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Human-readable label to identify the key later.", "examples": [ "CI pipeline" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Optional longer note describing what the key is used for.", "examples": [ "Key used by the nightly data-sync job." ] } }, "type": "object", "title": "ApiKeyCreateRequest", "description": "Payload for creating an API key. All fields are optional." }, "ApiKeyCreateResponse": { "properties": { "key": { "type": "string", "title": "Key", "description": "The full secret token, in the form `ak..`. **Shown only once at creation** \u2014 store it securely; it cannot be retrieved again.", "examples": [ "ak.a1b2c3d4.s3cr3t-value" ] }, "key_id": { "type": "string", "title": "Key Id", "description": "Public identifier of the key. Safe to log and reference.", "examples": [ "a1b2c3d4" ] }, "expires_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Expires At", "description": "UTC timestamp when the key expires, or null if it never expires.", "examples": [ "2026-12-31T23:59:59Z" ] } }, "type": "object", "required": [ "key", "key_id" ], "title": "ApiKeyCreateResponse", "description": "Returned once when an API key is created." }, "Application": { "properties": { "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "UTC timestamp when the record was created.", "examples": [ "2026-01-15T10:30:00Z" ] }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At", "description": "UTC timestamp when the record was last updated.", "examples": [ "2026-01-16T08:00:00Z" ] }, "id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Id", "description": "Primary key for applications." }, "name": { "type": "string", "title": "Name", "description": "Name of the application." }, "tenant_id": { "type": "integer", "title": "Tenant Id", "description": "ID of the tenant that owns the application." }, "is_active": { "type": "boolean", "title": "Is Active", "description": "Whether the application is active.", "default": true, "examples": [ true ] }, "is_native": { "type": "boolean", "title": "Is Native", "description": "Whether the application is a native (built-in) application.", "default": false, "examples": [ false ] }, "app_url": { "type": "string", "title": "App Url", "description": "Unique URL identifier for the application." }, "native_app_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Native App Id", "description": "Unique identifier for native applications only." }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description of the application." }, "version": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Version", "description": "Version of the application." }, "avatar": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Avatar", "description": "Avatar image (URL or encoded data) for the application.", "examples": [ "https://cdn.example.com/app-icon.png" ] }, "creator_user_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Creator User Id", "description": "ID of the user who created the app." } }, "type": "object", "required": [ "tenant_id", "creator_user_id" ], "title": "Application", "description": "Applications available on the platform." }, "ApplicationAccessIn": { "properties": { "application_id": { "type": "integer", "title": "Application Id", "description": "ID of the application to grant access to.", "examples": [ 5 ] }, "user_ids": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "title": "User Ids", "description": "IDs of the users who should have access to the application.", "examples": [ [ 42, 43 ] ] } }, "type": "object", "required": [ "application_id" ], "title": "ApplicationAccessIn", "description": "Schema for granting app access to users" }, "ApplicationGroup": { "properties": { "tenant_id": { "type": "integer", "title": "Tenant Id", "description": "ID of the tenant." }, "group_id": { "type": "integer", "title": "Group Id", "description": " ID of the user group." }, "app_id": { "type": "integer", "title": "App Id", "description": "ID of the application." }, "granted_by": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Granted By", "description": "ID of the user who granted access." }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "Timestamp when the user group was created." } }, "type": "object", "required": [ "tenant_id", "group_id", "app_id", "granted_by" ], "title": "ApplicationGroup", "description": "Group-level access for an application, scoped to tenant." }, "ApplicationIn": { "properties": { "name": { "type": "string", "title": "Name", "description": "Display name of the application.", "examples": [ "Knowledge Assistant" ] }, "is_active": { "type": "boolean", "title": "Is Active", "description": "Whether the application is active and available to users.", "default": true, "examples": [ true ] }, "tenant_id": { "type": "integer", "title": "Tenant Id", "description": "ID of the tenant the application belongs to.", "examples": [ 1 ] }, "app_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "App Url", "description": "URL where an external (non-native) application is hosted.", "examples": [ "https://apps.example.com/assistant" ] }, "is_native": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Is Native", "description": "Whether the application is a native, built-in application.", "default": false, "examples": [ false ] }, "native_app_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Native App Id", "description": "Identifier of the native application, when `is_native` is true.", "examples": [ 10 ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Optional description of what the application does.", "examples": [ "Answers questions over the company knowledge base." ] }, "version": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Version", "description": "Version string of the application.", "examples": [ "1.0.0" ] }, "avatar": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Avatar", "description": "URL or identifier of the application's avatar image.", "examples": [ "https://cdn.example.com/avatars/assistant.png" ] } }, "type": "object", "required": [ "name", "tenant_id" ], "title": "ApplicationIn", "description": "Schema for creating an application" }, "ApplicationMember": { "properties": { "user_id": { "type": "integer", "title": "User Id", "description": "ID of the user." }, "tenant_id": { "type": "integer", "title": "Tenant Id", "description": "ID of the tenant." }, "app_id": { "type": "integer", "title": "App Id", "description": "ID of the application." }, "granted_by": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Granted By", "description": "ID of the user who granted access." }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "Timestamp when access was created." } }, "type": "object", "required": [ "user_id", "tenant_id", "app_id", "granted_by" ], "title": "ApplicationMember", "description": "User-specific access control for applications.\nThis table allows setting explicit allow/deny rules for users on specific applications." }, "Assistant": { "properties": { "state": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "State", "description": "Current lifecycle state of the record.", "default": "NEW", "examples": [ "NEW" ] }, "state_reason": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "State Reason", "description": "Optional explanation for the current state.", "examples": [ "Processing failed: timeout" ] }, "state_changed_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "State Changed At", "description": "UTC timestamp when the state last changed.", "examples": [ "2026-01-16T08:00:00Z" ] }, "id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Id", "description": "Primary key for the assistant.", "examples": [ 1 ] }, "tenant_id": { "type": "integer", "title": "Tenant Id", "description": "ID of the tenant that owns the assistant.", "examples": [ 1 ] }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "Timestamp when the assistant was created.", "examples": [ "2026-06-23T12:00:00Z" ] }, "updated_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Updated At", "description": "Timestamp when the assistant was last updated.", "examples": [ "2026-06-23T12:00:00Z" ] }, "creator_user_id": { "type": "integer", "title": "Creator User Id", "description": "ID of the user who created the assistant.", "examples": [ 1 ] }, "name": { "type": "string", "title": "Name", "description": "Name of the assistant.", "examples": [ "Research Assistant" ] }, "avatar": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Avatar", "description": "Avatar image (URL or encoded data) for the assistant.", "examples": [ "https://cdn.example.com/avatar.png" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Optional description of the assistant.", "examples": [ "Helps research and summarize documents" ] }, "description_show_in_chat": { "type": "boolean", "title": "Description Show In Chat", "description": "Whether the assistant description is shown in the chat UI.", "default": false, "examples": [ false ] }, "predefined_prompts": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "title": "Predefined Prompts", "description": "List of predefined prompts suggested to users.", "examples": [ [ "Summarize this", "List key points" ] ] }, "instructions": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Instructions", "description": "System instructions guiding the assistant's behavior.", "examples": [ "You are a concise research assistant." ] }, "llm_catalog_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Llm Catalog Id", "description": "ID of the LLM catalog entry used by the assistant.", "examples": [ 1 ] }, "temperature": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Temperature", "description": "Sampling temperature used by the assistant.", "examples": [ 0.7 ] }, "similarity_top_k": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Similarity Top K", "description": "Number of top similar documents to retrieve for the assistant.", "examples": [ 5 ] }, "input_type": { "type": "string", "title": "Input Type", "description": "Input type for the assistant (e.g. prompt or form).", "default": "prompt", "examples": [ "PROMPT" ] }, "form_fields": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "title": "Form Fields", "description": "Form field definitions for form-input assistants.", "examples": [ [ { "key": "topic", "label": "Topic", "type": "text" } ] ] } }, "type": "object", "required": [ "tenant_id", "creator_user_id", "name" ], "title": "Assistant", "description": "Represents an AI Assistant partially compatible with the OpenAI Assistant API." }, "AssistantIn": { "properties": { "name": { "type": "string", "title": "Name", "description": "Display name of the assistant.", "examples": [ "Support Bot" ] }, "model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Model", "description": "Name of the LLM model the assistant uses; defaults to the tenant default.", "examples": [ "gpt-4o" ] }, "avatar": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Avatar", "description": "Avatar image reference for the assistant.", "examples": [ "avatars/support.png" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Short description of what the assistant does.", "examples": [ "Answers product support questions." ] }, "description_show_in_chat": { "type": "boolean", "title": "Description Show In Chat", "description": "Whether to show the description inside the chat UI.", "default": false, "examples": [ false ] }, "predefined_prompts": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Predefined Prompts", "description": "Suggested starter prompts shown to users.", "examples": [ [ "How do I reset my password?" ] ] }, "instructions": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Instructions", "description": "System instructions steering the assistant's behavior.", "examples": [ "You are a helpful support agent." ] }, "temperature": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Temperature", "description": "Sampling temperature for the assistant's LLM.", "examples": [ 0.5 ] }, "similarity_top_k": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Similarity Top K", "description": "Number of top similar chunks to retrieve for context.", "examples": [ 5 ] }, "input_type": { "$ref": "#/components/schemas/AssistantInputTypeEnum", "description": "Input mode: free-text prompt or structured form.", "default": "prompt", "examples": [ "prompt" ] }, "form_fields": { "anyOf": [ { "items": { "$ref": "#/components/schemas/FormField" }, "type": "array" }, { "type": "null" } ], "title": "Form Fields", "description": "Field definitions for form-input assistants.", "examples": [ null ] } }, "type": "object", "required": [ "name" ], "title": "AssistantIn" }, "AssistantInputTypeEnum": { "type": "string", "enum": [ "prompt", "form" ], "title": "AssistantInputTypeEnum" }, "AssistantLibrary": { "properties": { "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "UTC timestamp when the record was created.", "examples": [ "2026-01-15T10:30:00Z" ] }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At", "description": "UTC timestamp when the record was last updated.", "examples": [ "2026-01-16T08:00:00Z" ] }, "creator_user_id": { "type": "integer", "title": "Creator User Id", "description": "ID of the user who created the record.", "examples": [ 12 ] }, "updater_user_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Updater User Id", "description": "ID of the user who last updated the record, if any.", "examples": [ 12 ] }, "assistant_id": { "type": "integer", "title": "Assistant Id", "description": "ID of the assistant.", "examples": [ 1 ] }, "library_id": { "type": "integer", "title": "Library Id", "description": "ID of the library linked to the assistant.", "examples": [ 1 ] } }, "type": "object", "required": [ "creator_user_id", "assistant_id", "library_id" ], "title": "AssistantLibrary" }, "AssistantMember": { "properties": { "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "Timestamp when the membership was created.", "examples": [ "2026-06-23T12:00:00Z" ] }, "assistant_id": { "type": "integer", "title": "Assistant Id", "description": "ID of the assistant.", "examples": [ 1 ] }, "user_id": { "type": "integer", "title": "User Id", "description": "ID of the member user.", "examples": [ 1 ] } }, "type": "object", "required": [ "assistant_id", "user_id" ], "title": "AssistantMember", "description": "Saves the members of an AI Assistant." }, "AssistantMembersIn": { "properties": { "user_ids": { "items": { "type": "integer" }, "type": "array", "title": "User Ids", "description": "IDs of the users to add or remove as members.", "examples": [ [ 12, 34 ] ] } }, "type": "object", "required": [ "user_ids" ], "title": "AssistantMembersIn" }, "AssistantTool": { "properties": { "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "UTC timestamp when the record was created.", "examples": [ "2026-01-15T10:30:00Z" ] }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At", "description": "UTC timestamp when the record was last updated.", "examples": [ "2026-01-16T08:00:00Z" ] }, "assistant_id": { "type": "integer", "title": "Assistant Id", "description": "ID of the assistant the tool is attached to.", "examples": [ 1 ] }, "tool_id": { "type": "integer", "title": "Tool Id", "description": "ID of the tool attached to the assistant.", "examples": [ 1 ] } }, "type": "object", "required": [ "assistant_id", "tool_id" ], "title": "AssistantTool" }, "Body_assistants_submit_assistant": { "properties": { "name": { "type": "string", "title": "Name" }, "model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Model" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description" }, "description_show_in_chat": { "type": "boolean", "title": "Description Show In Chat", "default": false }, "predefined_prompts": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Predefined Prompts" }, "avatar": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Avatar" }, "instructions": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Instructions" }, "temperature": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Temperature" }, "similarity_top_k": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Similarity Top K" }, "input_type": { "$ref": "#/components/schemas/AssistantInputTypeEnum", "default": "prompt" }, "form_fields": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Form Fields" }, "files": { "anyOf": [ { "items": { "type": "string", "contentMediaType": "application/octet-stream" }, "type": "array" }, { "type": "null" } ], "title": "Files" } }, "type": "object", "required": [ "name" ], "title": "Body_assistants_submit_assistant" }, "Body_auth_login": { "properties": { "grant_type": { "anyOf": [ { "type": "string", "pattern": "^password$" }, { "type": "null" } ], "title": "Grant Type" }, "username": { "type": "string", "title": "Username" }, "password": { "type": "string", "format": "password", "title": "Password" }, "scope": { "type": "string", "title": "Scope", "default": "" }, "client_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Client Id" }, "client_secret": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "format": "password", "title": "Client Secret" } }, "type": "object", "required": [ "username", "password" ], "title": "Body_auth_login" }, "Body_chats_deactivate_documents": { "properties": { "document_ids": { "items": { "type": "integer" }, "type": "array", "title": "Document Ids" } }, "type": "object", "required": [ "document_ids" ], "title": "Body_chats_deactivate_documents" }, "Body_chats_remove_inactive_documents": { "properties": { "document_ids": { "items": { "type": "integer" }, "type": "array", "title": "Document Ids" } }, "type": "object", "required": [ "document_ids" ], "title": "Body_chats_remove_inactive_documents" }, "Body_documents_import_documents": { "properties": { "src": { "type": "string", "title": "Src", "description": "Source type which the documents will be imported from" }, "drive_id": { "type": "string", "title": "Drive Id", "description": "Drive ID" }, "drive_item_ids": { "items": { "type": "string" }, "type": "array", "title": "Drive Item Ids", "description": "Item IDs of the documents to be imported" }, "project_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Project Id", "description": "Project ID which the document belongs to" }, "chat_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Chat Id", "description": "Chat ID which the document belongs to" }, "assistant_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Assistant Id", "description": "Assistant ID which the document belongs to" }, "message_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Message Id", "description": "Message ID which the document relates to" }, "library_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Library Id", "description": "Library ID which the document relates to" } }, "type": "object", "required": [ "src", "drive_id", "drive_item_ids" ], "title": "Body_documents_import_documents" }, "Body_documents_unimport_documents": { "properties": { "src": { "type": "string", "title": "Src", "description": "Source type which the documents will be imported from" }, "drive_id": { "type": "string", "title": "Drive Id", "description": "Sharepoint drive ID" }, "drive_item_ids": { "items": { "type": "string" }, "type": "array", "title": "Drive Item Ids", "description": "Sharepoint item IDs of the documents to be unimported" }, "project_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Project Id", "description": "Project ID which the document belongs to" }, "chat_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Chat Id", "description": "Chat ID which the document belongs to" }, "assistant_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Assistant Id", "description": "Assistant ID which the document belongs to" } }, "type": "object", "required": [ "src", "drive_id", "drive_item_ids" ], "title": "Body_documents_unimport_documents" }, "Body_documents_upload_documents": { "properties": { "files": { "items": { "type": "string", "contentMediaType": "application/octet-stream" }, "type": "array", "title": "Files" }, "project_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Project Id", "description": "Project ID which the document belongs to" }, "chat_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Chat Id", "description": "Chat ID which the document belongs to" }, "assistant_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Assistant Id", "description": "Assistant ID which the document belongs to" }, "message_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Message Id", "description": "Message ID which the document relates to" }, "library_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Library Id", "description": "Library ID which the document relates to" } }, "type": "object", "required": [ "files" ], "title": "Body_documents_upload_documents" }, "Body_messages_submit_message": { "properties": { "content": { "type": "string", "title": "Content" }, "project_id": { "type": "integer", "title": "Project Id" }, "chat_id": { "type": "integer", "title": "Chat Id" }, "document_ids": { "items": { "type": "integer" }, "type": "array", "title": "Document Ids" }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At" }, "files": { "anyOf": [ { "items": { "type": "string", "contentMediaType": "application/octet-stream" }, "type": "array" }, { "type": "null" } ], "title": "Files" }, "chat_temperature": { "type": "number", "title": "Chat Temperature" }, "chat_similarity_top_k": { "type": "integer", "title": "Chat Similarity Top K" }, "chat_system_prompt": { "type": "string", "title": "Chat System Prompt" }, "assistant_id": { "type": "integer", "title": "Assistant Id" }, "model": { "type": "string", "title": "Model" }, "tool_ids": { "items": { "type": "integer" }, "type": "array", "title": "Tool Ids" }, "private": { "type": "boolean", "title": "Private", "default": false }, "library_id": { "type": "integer", "title": "Library Id" }, "form_data": { "type": "string", "title": "Form Data" } }, "type": "object", "title": "Body_messages_submit_message" }, "Body_transcriptions_create_transcription": { "properties": { "file": { "type": "string", "contentMediaType": "application/octet-stream", "title": "File" } }, "type": "object", "required": [ "file" ], "title": "Body_transcriptions_create_transcription" }, "BudgetAlert": { "properties": { "id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Id", "description": "Primary key for budget alerts." }, "tenant_id": { "type": "integer", "title": "Tenant Id", "description": "ID of the tenant the budget alert belongs to.", "examples": [ 1 ] }, "name": { "type": "string", "title": "Name", "description": "Name of the alert." }, "threshold_amount": { "type": "number", "title": "Threshold Amount", "description": "Budget threshold, for notification.", "default": 0 }, "current_spend": { "type": "string", "pattern": "^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$", "title": "Current Spend", "description": "Total Spent. In decimal to have more accuracy", "default": "0.000000" }, "triggered": { "type": "boolean", "title": "Triggered", "description": "If the alert is triggered or not", "default": false }, "active": { "type": "boolean", "title": "Active", "description": "If the alert is enabled", "default": true }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "Timestamp when the alert was created." }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At", "description": "Timestamp when alert was updated." }, "created_user_id": { "type": "integer", "title": "Created User Id", "description": "ID of the user who made the LLM request." } }, "type": "object", "required": [ "tenant_id", "created_user_id" ], "title": "BudgetAlert", "description": "Saves the budget alerts." }, "BudgetAlertRequest": { "properties": { "name": { "type": "string", "maxLength": 100, "title": "Name", "description": "Name for the alert to be created. Max 100 characters.", "examples": [ "Monthly spend warning" ] }, "threshold_amount": { "type": "number", "title": "Threshold Amount", "description": "Spend threshold that triggers the alert.", "examples": [ 1000.0 ] } }, "type": "object", "required": [ "name", "threshold_amount" ], "title": "BudgetAlertRequest", "description": "Payload for creating a budget alert." }, "BudgetAlertUpdate": { "properties": { "name": { "anyOf": [ { "type": "string", "maxLength": 100 }, { "type": "null" } ], "title": "Name", "description": "Name for the alert to be created. Max 100 characters.", "examples": [ "Monthly spend warning" ] }, "threshold_amount": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Threshold Amount", "description": "Spend threshold that triggers the alert.", "examples": [ 1000.0 ] }, "active": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Active", "description": "If it is enabled or disabled.", "examples": [ true ] } }, "type": "object", "title": "BudgetAlertUpdate", "description": "Payload for updating a budget alert. All fields are optional." }, "BulkResult": { "properties": { "count": { "type": "integer", "title": "Count", "description": "Number of rows affected.", "examples": [ 3 ] }, "ids": { "items": { "type": "integer" }, "type": "array", "title": "Ids", "description": "IDs that were targeted by the operation.", "examples": [ [ 1, 2, 3 ] ] } }, "type": "object", "required": [ "count", "ids" ], "title": "BulkResult" }, "CatalogIn": { "properties": { "name": { "type": "string", "title": "Name", "description": "Unique catalog name identifying the model.", "examples": [ "gpt-4o" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Human-readable description of the model.", "examples": [ "OpenAI GPT-4o multimodal model." ] }, "multi_modal": { "type": "boolean", "title": "Multi Modal", "description": "Whether the model accepts non-text inputs such as images.", "examples": [ true ] }, "gdpr_compliant": { "type": "boolean", "title": "Gdpr Compliant", "description": "Whether the model may be used for GDPR-compliant workloads.", "examples": [ true ] }, "embedding_dimension": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Embedding Dimension", "description": "Vector dimension produced by the model; required for embedding models.", "examples": [ 1536 ] }, "supports_embedding": { "type": "boolean", "title": "Supports Embedding", "description": "Whether the model can generate embeddings.", "default": false, "examples": [ false ] }, "supports_transcription": { "type": "boolean", "title": "Supports Transcription", "description": "Whether the model can transcribe audio.", "default": false, "examples": [ false ] }, "auto_seed": { "type": "boolean", "title": "Auto Seed", "description": "Whether to auto-create default settings for this catalog entry on seed.", "default": false, "examples": [ false ] } }, "type": "object", "required": [ "name", "description", "multi_modal", "gdpr_compliant" ], "title": "CatalogIn" }, "CatalogUpdate": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Unique catalog name identifying the model.", "examples": [ "gpt-4o" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Human-readable description of the model.", "examples": [ "OpenAI GPT-4o multimodal model." ] }, "multi_modal": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Multi Modal", "description": "Whether the model accepts non-text inputs such as images.", "examples": [ true ] }, "gdpr_compliant": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Gdpr Compliant", "description": "Whether the model may be used for GDPR-compliant workloads.", "examples": [ true ] }, "embedding_dimension": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Embedding Dimension", "description": "Vector dimension produced by the model; required for embedding models.", "examples": [ 1536 ] }, "supports_embedding": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Supports Embedding", "description": "Whether the model can generate embeddings.", "examples": [ false ] }, "supports_transcription": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Supports Transcription", "description": "Whether the model can transcribe audio.", "examples": [ false ] }, "auto_seed": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Auto Seed", "description": "Whether to auto-create default settings for this catalog entry on seed.", "examples": [ false ] } }, "type": "object", "title": "CatalogUpdate" }, "Chat": { "properties": { "state": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "State", "description": "Current lifecycle state of the record.", "default": "NEW", "examples": [ "NEW" ] }, "state_reason": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "State Reason", "description": "Optional explanation for the current state.", "examples": [ "Processing failed: timeout" ] }, "state_changed_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "State Changed At", "description": "UTC timestamp when the state last changed.", "examples": [ "2026-01-16T08:00:00Z" ] }, "id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Id", "description": "Primary key for the chat.", "examples": [ 1 ] }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "Timestamp when the chat was created.", "examples": [ "2026-06-23T12:00:00Z" ] }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At", "description": "Timestamp when the chat was last updated.", "examples": [ "2026-06-23T12:00:00Z" ] }, "creator_user_id": { "type": "integer", "title": "Creator User Id", "description": "ID of the user who created the chat.", "examples": [ 1 ] }, "project_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Project Id", "description": "ID of the project the chat belongs to, if any.", "examples": [ 1 ] }, "name": { "type": "string", "title": "Name", "description": "Name/title of the chat.", "examples": [ "Untitled chat" ] }, "busy": { "type": "boolean", "title": "Busy", "description": "DEPRECATED. Whether the chat is currently busy processing.", "examples": [ false ] }, "temperature": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Temperature", "description": "Sampling temperature override for this chat.", "examples": [ 0.7 ] }, "similarity_top_k": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Similarity Top K", "description": "Number of top similar documents to retrieve for this chat.", "examples": [ 5 ] }, "system_prompt": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "System Prompt", "description": "System prompt override for this chat.", "examples": [ "You are a helpful assistant." ] }, "llm_catalog_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Llm Catalog Id", "description": "ID of the LLM catalog entry used by this chat.", "examples": [ 1 ] }, "llm_settings_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Llm Settings Id", "description": "ID of the LLM settings used by this chat.", "examples": [ 1 ] }, "assistant_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Assistant Id", "description": "ID of the assistant driving this chat, if any.", "examples": [ 1 ] }, "private": { "type": "boolean", "title": "Private", "description": "Whether the chat is private to its creator within the project.", "default": false, "examples": [ false ] }, "consumed_tokens": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Consumed Tokens", "description": "Total number of tokens consumed by this chat.", "examples": [ 1024 ] }, "form_data": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Form Data", "description": "Submitted form values for form-input assistants, keyed by field key.", "examples": [ { "tone": "formal", "topic": "sales" } ] } }, "type": "object", "required": [ "creator_user_id", "project_id", "name", "busy" ], "title": "Chat" }, "ChatIn": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Display name for the chat.", "examples": [ "Q3 planning" ] }, "temperature": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Temperature", "description": "Sampling temperature for the chat's LLM; higher is more creative.", "examples": [ 0.7 ] }, "similarity_top_k": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Similarity Top K", "description": "Number of top similar document chunks to retrieve for context.", "examples": [ 5 ] }, "system_prompt": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "System Prompt", "description": "System prompt steering the assistant. Not allowed when an assistant is set.", "examples": [ "You are a concise financial analyst." ] }, "model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Model", "description": "Name of the LLM model to use. Not allowed when an assistant is set.", "examples": [ "gpt-4o" ] }, "private": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Private", "description": "Whether the chat is private to its creator.", "default": false, "examples": [ false ] } }, "type": "object", "title": "ChatIn" }, "ChatInactiveDocument": { "properties": { "creator_user_id": { "type": "integer", "title": "Creator User Id", "description": "ID of the user who marked the document inactive.", "examples": [ 1 ] }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "Timestamp when the document was marked inactive in the chat.", "examples": [ "2026-06-23T12:00:00Z" ] }, "chat_id": { "type": "integer", "title": "Chat Id", "description": "ID of the chat the inactive document belongs to.", "examples": [ 1 ] }, "document_id": { "type": "integer", "title": "Document Id", "description": "ID of the document marked inactive in the chat.", "examples": [ 1 ] } }, "type": "object", "required": [ "creator_user_id", "chat_id", "document_id" ], "title": "ChatInactiveDocument" }, "ChatLibrary": { "properties": { "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "UTC timestamp when the record was created.", "examples": [ "2026-01-15T10:30:00Z" ] }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At", "description": "UTC timestamp when the record was last updated.", "examples": [ "2026-01-16T08:00:00Z" ] }, "creator_user_id": { "type": "integer", "title": "Creator User Id", "description": "ID of the user who created the record.", "examples": [ 12 ] }, "updater_user_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Updater User Id", "description": "ID of the user who last updated the record, if any.", "examples": [ 12 ] }, "chat_id": { "type": "integer", "title": "Chat Id", "description": "ID of the chat.", "examples": [ 1 ] }, "library_id": { "type": "integer", "title": "Library Id", "description": "ID of the library linked to the chat.", "examples": [ 1 ] } }, "type": "object", "required": [ "creator_user_id", "chat_id", "library_id" ], "title": "ChatLibrary" }, "ChatToolSettingsOut": { "properties": { "chat_id": { "type": "integer", "title": "Chat Id", "description": "ID of the chat.", "examples": [ 42 ] }, "tool_id": { "type": "integer", "title": "Tool Id", "description": "ID of the tool.", "examples": [ 7 ] }, "enabled": { "type": "boolean", "title": "Enabled", "description": "Whether the tool is enabled for the chat.", "examples": [ true ] }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "When the setting was created.", "examples": [ "2026-01-15T10:30:00Z" ] }, "updated_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Updated At", "description": "When the setting was last updated, or null if never.", "examples": [ "2026-01-16T08:00:00Z" ] } }, "type": "object", "required": [ "chat_id", "tool_id", "enabled", "created_at", "updated_at" ], "title": "ChatToolSettingsOut", "description": "Response schema for chat tool settings" }, "ChatToolSettingsUpdate": { "properties": { "enabled": { "type": "boolean", "title": "Enabled", "description": "Whether the tool is enabled for the chat.", "examples": [ true ] } }, "type": "object", "required": [ "enabled" ], "title": "ChatToolSettingsUpdate", "description": "Request schema for updating a single chat tool setting" }, "Connector": { "properties": { "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "UTC timestamp when the record was created.", "examples": [ "2026-01-15T10:30:00Z" ] }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At", "description": "UTC timestamp when the record was last updated.", "examples": [ "2026-01-16T08:00:00Z" ] }, "creator_user_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Creator User Id", "description": "ID of the user who created the record, if attributable.", "examples": [ 12 ] }, "updater_user_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Updater User Id", "description": "ID of the user who last updated the record, if any.", "examples": [ 12 ] }, "id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Id", "description": "Primary key for the connector.", "examples": [ 1 ] }, "oauth_client_id": { "type": "integer", "title": "Oauth Client Id", "description": "ID of the OAuth client backing this connector.", "examples": [ 1 ] }, "name": { "type": "string", "title": "Name", "description": "Name of the connector.", "examples": [ "SharePoint" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Optional description of the connector.", "examples": [ "Connects to SharePoint document libraries" ] }, "scopes": { "items": { "type": "string" }, "type": "array", "title": "Scopes", "description": "OAuth scopes requested by this connector.", "examples": [ [ "Files.Read.All", "Sites.Read.All" ] ] }, "caps": { "items": { "type": "string" }, "type": "array", "title": "Caps", "description": "Capabilities provided by this connector.", "examples": [ [ "read_files", "list_sites" ] ] }, "auto_attach": { "type": "boolean", "title": "Auto Attach", "description": "Whether this connector is automatically attached to new resources.", "default": false, "examples": [ false ] } }, "type": "object", "required": [ "oauth_client_id", "name" ], "title": "Connector" }, "ConnectorConsentOut": { "properties": { "consent_url": { "type": "string", "title": "Consent Url", "description": "URL to redirect the user to for granting consent.", "examples": [ "https://login.microsoftonline.com/common/oauth2/v2.0/authorize?..." ] }, "connector": { "$ref": "#/components/schemas/ConnectorOut", "description": "Details of the connector consent is being requested for." } }, "type": "object", "required": [ "consent_url", "connector" ], "title": "ConnectorConsentOut" }, "ConnectorOut": { "properties": { "id": { "type": "integer", "title": "Id", "description": "Unique identifier of the connector.", "examples": [ 3 ] }, "name": { "type": "string", "title": "Name", "description": "Human-readable connector name.", "examples": [ "OneDrive" ] }, "provider": { "type": "string", "title": "Provider", "description": "OAuth provider key backing the connector.", "examples": [ "microsoft" ] }, "caps": { "items": { "type": "string" }, "type": "array", "title": "Caps", "description": "Capabilities the connector requests.", "examples": [ [ "files.read" ] ] }, "scopes": { "items": { "type": "string" }, "type": "array", "title": "Scopes", "description": "OAuth scopes requested from the provider.", "examples": [ [ "Files.Read.All", "offline_access" ] ] } }, "type": "object", "required": [ "id", "name", "provider", "caps", "scopes" ], "title": "ConnectorOut" }, "ConnectorStatusOut": { "properties": { "connector_id": { "type": "integer", "title": "Connector Id", "description": "Unique identifier of the connector.", "examples": [ 3 ] }, "name": { "type": "string", "title": "Name", "description": "Human-readable connector name.", "examples": [ "OneDrive" ] }, "connected": { "type": "boolean", "title": "Connected", "description": "Whether the current user has a valid consent for this connector.", "examples": [ true ] }, "needs_consent": { "type": "boolean", "title": "Needs Consent", "description": "Whether the user must (re)grant consent to use this connector.", "examples": [ false ] }, "missing_caps": { "items": { "type": "string" }, "type": "array", "title": "Missing Caps", "description": "Capabilities not yet covered by the user's consent.", "examples": [ [] ] } }, "type": "object", "required": [ "connector_id", "name", "connected", "needs_consent", "missing_caps" ], "title": "ConnectorStatusOut" }, "ConnectorUpdate": { "properties": { "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "New description for the connector.", "examples": [ "Access OneDrive files for retrieval." ] } }, "type": "object", "title": "ConnectorUpdate" }, "CostByModel": { "properties": { "provider": { "type": "string", "title": "Provider", "description": "Provider of the model.", "examples": [ "azure" ] }, "model": { "type": "string", "title": "Model", "description": "Catalog name of the model.", "examples": [ "gpt-4o" ] }, "total_cost": { "type": "number", "title": "Total Cost", "description": "Total cost for this model.", "examples": [ 12.34 ] }, "total_tokens": { "type": "integer", "title": "Total Tokens", "description": "Total tokens for this model.", "examples": [ 10000 ] }, "prompt_tokens": { "type": "integer", "title": "Prompt Tokens", "description": "Prompt tokens for this model.", "examples": [ 6000 ] }, "completion_tokens": { "type": "integer", "title": "Completion Tokens", "description": "Completion tokens for this model.", "examples": [ 4000 ] }, "record_count": { "type": "integer", "title": "Record Count", "description": "Number of usage records for this model.", "examples": [ 42 ] } }, "type": "object", "required": [ "provider", "model", "total_cost", "total_tokens", "prompt_tokens", "completion_tokens", "record_count" ], "title": "CostByModel" }, "CostBySource": { "properties": { "source": { "type": "string", "title": "Source", "description": "Usage source name.", "examples": [ "doc_intelligence" ] }, "total_cost": { "type": "number", "title": "Total Cost", "description": "Total cost for this source.", "examples": [ 12.34 ] }, "total_tokens": { "type": "integer", "title": "Total Tokens", "description": "Total tokens for this source.", "examples": [ 10000 ] }, "prompt_tokens": { "type": "integer", "title": "Prompt Tokens", "description": "Prompt tokens for this source.", "examples": [ 6000 ] }, "completion_tokens": { "type": "integer", "title": "Completion Tokens", "description": "Completion tokens for this source.", "examples": [ 4000 ] }, "record_count": { "type": "integer", "title": "Record Count", "description": "Number of usage records for this source.", "examples": [ 42 ] } }, "type": "object", "required": [ "source", "total_cost", "total_tokens", "prompt_tokens", "completion_tokens", "record_count" ], "title": "CostBySource" }, "CostTimeseriesPoint": { "properties": { "date": { "type": "string", "title": "Date", "description": "Date of the data point (YYYY-MM-DD).", "examples": [ "2026-01-15" ] }, "cost": { "type": "number", "title": "Cost", "description": "Cost incurred on this date.", "examples": [ 12.34 ] }, "tokens": { "type": "integer", "title": "Tokens", "description": "Tokens consumed on this date.", "examples": [ 1234 ] }, "record_count": { "type": "integer", "title": "Record Count", "description": "Number of usage records on this date.", "examples": [ 5 ] } }, "type": "object", "required": [ "date", "cost", "tokens", "record_count" ], "title": "CostTimeseriesPoint" }, "DataSourceCapabilities": { "properties": { "source": { "type": "string", "title": "Source", "description": "Data source identifier.", "examples": [ "sharepoint", "onedrive" ] }, "root_kind": { "type": "string", "enum": [ "site", "drive" ], "title": "Root Kind", "description": "Whether the source's top level is sites or drives.", "examples": [ "site" ] }, "hierarchy_depth": { "type": "integer", "title": "Hierarchy Depth", "description": "Number of browsable levels above individual drive items.", "examples": [ 2 ] } }, "type": "object", "required": [ "source", "root_kind", "hierarchy_depth" ], "title": "DataSourceCapabilities", "description": "Metadata the frontend uses to render the right browse hierarchy." }, "DataSourceDriveModel": { "properties": { "id": { "type": "string", "title": "Id", "description": "Drive id.", "examples": [ "b!abc123" ] }, "web_url": { "type": "string", "title": "Web Url", "description": "URL to open the drive in the source application.", "examples": [ "https://contoso.sharepoint.com/sites/Team/Shared%20Documents" ] }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Drive name.", "examples": [ "Documents" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Drive description, if set.", "examples": [ "Shared team documents" ] }, "root": { "$ref": "#/components/schemas/DataSourceItemModel", "description": "The drive's root folder item." }, "imported_count": { "type": "integer", "title": "Imported Count", "description": "Number of imported documents from this drive in the current scope.", "default": 0, "examples": [ 7 ] } }, "type": "object", "required": [ "id", "web_url", "name", "description", "root" ], "title": "DataSourceDriveModel", "description": "A drive from a data source, normalized across providers." }, "DataSourceFolderModel": { "properties": { "child_count": { "type": "integer", "title": "Child Count", "description": "Number of immediate children inside the folder.", "examples": [ 12 ] } }, "type": "object", "required": [ "child_count" ], "title": "DataSourceFolderModel", "description": "Metadata specific to folder items." }, "DataSourceItemModel": { "properties": { "id": { "type": "string", "title": "Id", "description": "Provider item id.", "examples": [ "01ABCDEF..." ] }, "web_url": { "type": "string", "title": "Web Url", "description": "URL to open the item in the source application.", "examples": [ "https://contoso.sharepoint.com/.../file.docx" ] }, "drive_id": { "type": "string", "title": "Drive Id", "description": "Id of the drive containing the item.", "examples": [ "b!abc123" ] }, "site_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Site Id", "description": "Id of the site the item belongs to, if the source is site-rooted.", "examples": [ "contoso.sharepoint.com,guid1,guid2" ] }, "parent_folder_id": { "type": "string", "title": "Parent Folder Id", "description": "Id of the parent folder, or 'root'.", "examples": [ "root" ] }, "parent_path": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Parent Path", "description": "Path of the parent folder within the drive.", "examples": [ "/drive/root:/Documents" ] }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Item name.", "examples": [ "report.docx" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Item description, if set.", "examples": [ "Quarterly report" ] }, "size": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Size", "description": "Item size in bytes.", "examples": [ 24576 ] }, "last_modified_date_time": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Last Modified Date Time", "description": "When the item was last modified.", "examples": [ "2026-02-20T14:00:00Z" ] }, "mimetype": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Mimetype", "description": "MIME type for files; null for folders.", "examples": [ "application/pdf" ] }, "folder": { "anyOf": [ { "$ref": "#/components/schemas/DataSourceFolderModel" }, { "type": "null" } ], "description": "Folder metadata when the item is a folder; null for files." }, "imported": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Imported", "description": "Whether this file has already been imported into the current scope.", "examples": [ false ] }, "imported_count": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Imported Count", "description": "For folders, the number of imported documents under this folder.", "examples": [ 3 ] } }, "type": "object", "required": [ "id", "web_url", "drive_id", "site_id", "parent_folder_id", "parent_path", "name", "description", "size", "last_modified_date_time", "mimetype", "folder" ], "title": "DataSourceItemModel", "description": "A file or folder item from a data source, normalized across providers." }, "DataSourceSiteModel": { "properties": { "id": { "type": "string", "title": "Id", "description": "Site id.", "examples": [ "contoso.sharepoint.com,guid1,guid2" ] }, "web_url": { "type": "string", "title": "Web Url", "description": "URL to open the site in the source application.", "examples": [ "https://contoso.sharepoint.com/sites/Team" ] }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Site name.", "examples": [ "Team" ] }, "display_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Display Name", "description": "Human-readable site display name.", "examples": [ "Team Site" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Site description, if set.", "examples": [ "Collaboration site" ] }, "imported_count": { "type": "integer", "title": "Imported Count", "description": "Number of imported documents from this site in the current scope.", "default": 0, "examples": [ 15 ] } }, "type": "object", "required": [ "id", "web_url", "name", "display_name", "description" ], "title": "DataSourceSiteModel", "description": "A site from a data source \u2014 the top level for site-rooted sources (SharePoint)." }, "DataSourceUserModel": { "properties": { "display_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Display Name", "description": "User's display name.", "examples": [ "Alice Smith" ] }, "job_title": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Job Title", "description": "User's job title.", "examples": [ "Product Manager" ] }, "mail": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Mail", "description": "User's email address.", "examples": [ "alice@contoso.com" ] }, "surname": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Surname", "description": "User's surname.", "examples": [ "Smith" ] }, "user_principal_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "User Principal Name", "description": "User principal name (UPN).", "examples": [ "alice@contoso.com" ] } }, "type": "object", "required": [ "display_name", "job_title", "mail", "surname", "user_principal_name" ], "title": "DataSourceUserModel", "description": "The current user's profile on the data source." }, "Document": { "properties": { "id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Id", "description": "Primary key for the document.", "examples": [ 1 ] }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "Timestamp when the document was created.", "examples": [ "2026-06-23T12:00:00Z" ] }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At", "description": "Timestamp when the document was last updated.", "examples": [ "2026-06-23T12:00:00Z" ] }, "creator_user_id": { "type": "integer", "title": "Creator User Id", "description": "ID of the user who created the document.", "examples": [ 1 ] }, "tenant_id": { "type": "integer", "title": "Tenant Id", "description": "ID of the tenant that owns the document.", "examples": [ 1 ] }, "project_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Project Id", "description": "ID of the project the document belongs to, if any.", "examples": [ 1 ] }, "chat_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Chat Id", "description": "ID of the chat the document belongs to, if any.", "examples": [ 1 ] }, "assistant_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Assistant Id", "description": "ID of the assistant the document belongs to, if any.", "examples": [ 1 ] }, "message_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Message Id", "description": "ID of the message the document is associated with, if any.", "examples": [ 1 ] }, "library_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Library Id", "description": "ID of the library the document belongs to, if any.", "examples": [ 1 ] }, "filename": { "type": "string", "title": "Filename", "description": "Original filename of the document.", "examples": [ "report.pdf" ] }, "content_type": { "type": "string", "title": "Content Type", "description": "MIME content type of the document.", "default": "text/plain", "examples": [ "application/pdf" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Optional description of the document.", "examples": [ "Quarterly financial report" ] }, "content_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Content Id", "description": "ID of the associated document content record.", "examples": [ 1 ] }, "src": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Src", "description": "Source identifier of the document (e.g. connector source).", "examples": [ "SHAREPOINT" ] }, "url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Url", "description": "External URL of the document, if any.", "examples": [ "https://example.sharepoint.com/doc.pdf" ] }, "sp_site_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Sp Site Id", "description": "SharePoint site ID the document originated from.", "examples": [ "contoso.sharepoint.com,guid1,guid2" ] }, "sp_drive_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Sp Drive Id", "description": "SharePoint drive ID the document originated from.", "examples": [ "b!abcdef123456" ] }, "sp_drive_item_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Sp Drive Item Id", "description": "SharePoint drive item ID of the document.", "examples": [ "01ABCDEF1234567890" ] }, "sp_parent_folder_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Sp Parent Folder Id", "description": "SharePoint parent folder ID of the document.", "examples": [ "01ABCDEFPARENT" ] }, "sp_parent_path": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Sp Parent Path", "description": "SharePoint parent folder path of the document.", "examples": [ "/Shared Documents/Reports" ] }, "sp_last_modified_date_time": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Sp Last Modified Date Time", "description": "Last-modified timestamp reported by SharePoint.", "examples": [ "2026-06-23T12:00:00Z" ] }, "sp_import_folder_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Sp Import Folder Id", "description": "SharePoint folder ID used as the import root.", "examples": [ "01ABCDEFIMPORT" ] }, "autosync": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Autosync", "description": "Whether the document is automatically synced from its source.", "examples": [ true ] }, "import_token": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Import Token", "description": "Token identifying the import batch for this document.", "examples": [ "3fa85f64-5717-4562-b3fc-2c963f66afa6" ] }, "import_started_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Import Started At", "description": "Timestamp when the import started.", "examples": [ "2026-06-23T12:00:00Z" ] }, "import_finished_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Import Finished At", "description": "Timestamp when the import finished.", "examples": [ "2026-06-23T12:05:00Z" ] }, "import_error": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Import Error", "description": "Error message captured during import, if any.", "examples": [ "Permission denied" ] } }, "type": "object", "required": [ "creator_user_id", "tenant_id", "project_id", "chat_id", "filename", "description", "src", "url", "sp_site_id", "sp_drive_id", "sp_drive_item_id", "sp_parent_folder_id", "sp_parent_path", "sp_last_modified_date_time", "sp_import_folder_id", "autosync", "import_token", "import_started_at", "import_finished_at" ], "title": "Document" }, "FormField": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name" }, "label": { "type": "string", "title": "Label" }, "type": { "$ref": "#/components/schemas/FormFieldTypeEnum" }, "required": { "type": "boolean", "title": "Required", "default": false }, "options": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Options" }, "placeholder": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Placeholder" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description" } }, "type": "object", "required": [ "label", "type" ], "title": "FormField", "description": "A single creator-defined input field of a form assistant.\n\n``name`` is the stable machine slug referenced as ``{{name}}`` in the\nassistant instructions; ``label`` is the display text. A missing name\nis derived from the label by :func:`normalize_form_fields`." }, "FormFieldTypeEnum": { "type": "string", "enum": [ "text", "selection", "number", "email", "checkbox", "date", "file" ], "title": "FormFieldTypeEnum" }, "GroupAppAccessIn": { "properties": { "application_id": { "type": "integer", "title": "Application Id", "description": "ID of the application to grant access to.", "examples": [ 5 ] }, "group_ids": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "title": "Group Ids", "description": "IDs of the user groups that should have access to the application.", "examples": [ [ 7, 8 ] ] } }, "type": "object", "required": [ "application_id" ], "title": "GroupAppAccessIn", "description": "Schema for granting app access to a group" }, "GroupIn": { "properties": { "name": { "type": "string", "maxLength": 96, "minLength": 2, "title": "Name", "description": "Display name of the user group.", "examples": [ "Engineering" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Optional description of the group's purpose.", "examples": [ "All engineering staff." ] } }, "type": "object", "required": [ "name" ], "title": "GroupIn", "description": "Schema for creating a user group" }, "HTTPValidationError": { "properties": { "detail": { "items": { "$ref": "#/components/schemas/ValidationError" }, "type": "array", "title": "Detail" } }, "type": "object", "title": "HTTPValidationError" }, "InvitationIn": { "properties": { "emails": { "items": { "type": "string", "format": "email" }, "type": "array", "title": "Emails", "description": "Email addresses to invite; already-invited or existing users are skipped.", "examples": [ [ "jane.doe@example.com", "john.smith@example.com" ] ] }, "tenant_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Tenant Id", "description": "Tenant to invite into; defaults to the caller's tenant.", "examples": [ 1 ] }, "project_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Project Id", "description": "Optional project to grant the invitees access to.", "examples": [ 10 ] }, "admin": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Admin", "description": "Whether invitees should be granted tenant admin privileges.", "examples": [ false ] } }, "type": "object", "required": [ "emails" ], "title": "InvitationIn" }, "InvitationOut": { "properties": { "id": { "type": "integer", "title": "Id", "description": "Unique identifier of the invitation.", "examples": [ 100 ] }, "email": { "type": "string", "title": "Email", "description": "Email address the invitation was sent to.", "examples": [ "jane.doe@example.com" ] }, "tenant_id": { "type": "integer", "title": "Tenant Id", "description": "Identifier of the tenant the invite belongs to.", "examples": [ 1 ] }, "project_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Project Id", "description": "Project the invite grants access to, if any.", "examples": [ 10 ] }, "status": { "type": "string", "title": "Status", "description": "Current invitation status.", "examples": [ "PENDING" ] }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "UTC timestamp when the invitation was created.", "examples": [ "2026-01-15T09:30:00Z" ] }, "accepted_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Accepted At", "description": "UTC timestamp when the invitation was accepted, if it was.", "examples": [ "2026-01-16T12:00:00Z" ] }, "revoked_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Revoked At", "description": "UTC timestamp when the invitation was revoked, if it was.", "examples": [ null ] }, "creator_user_id": { "type": "integer", "title": "Creator User Id", "description": "Identifier of the user who created the invitation.", "examples": [ 42 ] } }, "type": "object", "required": [ "id", "email", "tenant_id", "project_id", "status", "created_at", "accepted_at", "revoked_at", "creator_user_id" ], "title": "InvitationOut" }, "LLMSettingsIn": { "properties": { "llm_catalog_id": { "type": "integer", "title": "Llm Catalog Id", "description": "ID of the catalog model these settings configure.", "examples": [ 1 ] }, "provider": { "type": "string", "title": "Provider", "description": "Provider backing the model.", "examples": [ "azure" ] }, "library": { "type": "string", "title": "Library", "description": "Client library used to call the provider.", "examples": [ "openai" ] }, "max_tokens": { "type": "integer", "title": "Max Tokens", "description": "Maximum tokens allowed per request for this model.", "examples": [ 128000 ] }, "cost_prompt_tokens": { "anyOf": [ { "type": "number" }, { "type": "string", "pattern": "^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$" } ], "title": "Cost Prompt Tokens", "description": "Cost per prompt token in the billing currency.", "examples": [ "0.000005" ] }, "cost_completion_tokens": { "anyOf": [ { "type": "number" }, { "type": "string", "pattern": "^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$" } ], "title": "Cost Completion Tokens", "description": "Cost per completion token in the billing currency.", "examples": [ "0.000015" ] }, "region": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Region", "description": "Provider region hosting the deployment.", "examples": [ "westeurope" ] }, "args": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Args", "description": "Extra provider-specific arguments passed to the client.", "examples": [ { "temperature": 0.2 } ] }, "openai_resource": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Openai Resource", "description": "Azure OpenAI resource name.", "examples": [ "my-openai-resource" ] }, "api_version": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Api Version", "description": "Provider API version to target.", "examples": [ "2024-02-01" ] }, "deployment_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Deployment Name", "description": "Provider deployment name for the model.", "examples": [ "gpt-4o-deployment" ] }, "endpoint": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Endpoint", "description": "Base URL of the provider endpoint.", "examples": [ "https://my-resource.openai.azure.com" ] }, "api_key": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Api Key", "description": "Secret API key used to authenticate with the provider.", "examples": [ "sk-..." ] } }, "type": "object", "required": [ "llm_catalog_id", "provider", "library", "max_tokens", "cost_prompt_tokens", "cost_completion_tokens" ], "title": "LLMSettingsIn" }, "LLMSettingsUpdate": { "properties": { "llm_catalog_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Llm Catalog Id", "description": "ID of the catalog model these settings configure.", "examples": [ 1 ] }, "provider": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Provider", "description": "Provider backing the model.", "examples": [ "azure" ] }, "library": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Library", "description": "Client library used to call the provider.", "examples": [ "openai" ] }, "max_tokens": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Max Tokens", "description": "Maximum tokens allowed per request for this model.", "examples": [ 128000 ] }, "cost_prompt_tokens": { "anyOf": [ { "type": "number" }, { "type": "string", "pattern": "^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$" }, { "type": "null" } ], "title": "Cost Prompt Tokens", "description": "Cost per prompt token in the billing currency.", "examples": [ "0.000005" ] }, "cost_completion_tokens": { "anyOf": [ { "type": "number" }, { "type": "string", "pattern": "^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$" }, { "type": "null" } ], "title": "Cost Completion Tokens", "description": "Cost per completion token in the billing currency.", "examples": [ "0.000015" ] }, "region": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Region", "description": "Provider region hosting the deployment.", "examples": [ "westeurope" ] }, "args": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Args", "description": "Extra provider-specific arguments passed to the client.", "examples": [ { "temperature": 0.2 } ] }, "openai_resource": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Openai Resource", "description": "Azure OpenAI resource name.", "examples": [ "my-openai-resource" ] }, "api_version": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Api Version", "description": "Provider API version to target.", "examples": [ "2024-02-01" ] }, "deployment_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Deployment Name", "description": "Provider deployment name for the model.", "examples": [ "gpt-4o-deployment" ] }, "endpoint": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Endpoint", "description": "Base URL of the provider endpoint.", "examples": [ "https://my-resource.openai.azure.com" ] }, "api_key": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Api Key", "description": "Secret API key used to authenticate with the provider.", "examples": [ "sk-..." ] } }, "type": "object", "title": "LLMSettingsUpdate" }, "Library": { "properties": { "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "UTC timestamp when the record was created.", "examples": [ "2026-01-15T10:30:00Z" ] }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At", "description": "UTC timestamp when the record was last updated.", "examples": [ "2026-01-16T08:00:00Z" ] }, "creator_user_id": { "type": "integer", "title": "Creator User Id", "description": "ID of the user who created the record.", "examples": [ 12 ] }, "updater_user_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Updater User Id", "description": "ID of the user who last updated the record, if any.", "examples": [ 12 ] }, "id": { "type": "integer", "title": "Id", "description": "Primary key for the library.", "examples": [ 1 ] }, "tenant_id": { "type": "integer", "title": "Tenant Id", "description": "ID of the tenant that owns the library.", "examples": [ 1 ] }, "name": { "type": "string", "title": "Name", "description": "Name of the library.", "examples": [ "Company Knowledge Base" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Optional description of the library.", "examples": [ "Shared documents for the whole company" ] } }, "type": "object", "required": [ "creator_user_id", "tenant_id", "name" ], "title": "Library", "description": "Library definition" }, "LibraryIn": { "properties": { "name": { "type": "string", "title": "Name", "description": "Display name of the library.", "examples": [ "Engineering Knowledge Base" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Optional longer description of the library.", "examples": [ "Internal docs and runbooks for the platform team." ] } }, "type": "object", "required": [ "name" ], "title": "LibraryIn" }, "LibraryMember": { "properties": { "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "UTC timestamp when the record was created.", "examples": [ "2026-01-15T10:30:00Z" ] }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At", "description": "UTC timestamp when the record was last updated.", "examples": [ "2026-01-16T08:00:00Z" ] }, "creator_user_id": { "type": "integer", "title": "Creator User Id", "description": "ID of the user who created the record.", "examples": [ 12 ] }, "updater_user_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Updater User Id", "description": "ID of the user who last updated the record, if any.", "examples": [ 12 ] }, "library_id": { "type": "integer", "title": "Library Id", "description": "ID of the library.", "examples": [ 1 ] }, "user_id": { "type": "integer", "title": "User Id", "description": "ID of the member user.", "examples": [ 1 ] }, "role": { "type": "string", "title": "Role", "description": "Role of the user within the library.", "examples": [ "OWNER" ] } }, "type": "object", "required": [ "creator_user_id", "library_id", "user_id", "role" ], "title": "LibraryMember", "description": "Members for a library" }, "LibraryMemberBulkDelete": { "properties": { "user_ids": { "items": { "type": "integer" }, "type": "array", "title": "User Ids", "description": "IDs of the users to remove from the library.", "examples": [ [ 42, 43 ] ] } }, "type": "object", "required": [ "user_ids" ], "title": "LibraryMemberBulkDelete" }, "LibraryMemberBulkIn": { "properties": { "members": { "items": { "$ref": "#/components/schemas/LibraryMemberIn" }, "type": "array", "title": "Members", "description": "Members to add to the library." } }, "type": "object", "required": [ "members" ], "title": "LibraryMemberBulkIn" }, "LibraryMemberIn": { "properties": { "user_id": { "type": "integer", "title": "User Id", "description": "ID of the user to add as a member.", "examples": [ 42 ] }, "role": { "type": "string", "title": "Role", "description": "Role to assign the member (e.g. owner or member).", "examples": [ "member" ] } }, "type": "object", "required": [ "user_id", "role" ], "title": "LibraryMemberIn" }, "LibraryUpdateIn": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "New display name for the library.", "examples": [ "Platform Knowledge Base" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "New description for the library.", "examples": [ "Updated docs and runbooks." ] } }, "type": "object", "title": "LibraryUpdateIn" }, "Message": { "properties": { "state": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "State", "description": "Current lifecycle state of the record.", "default": "NEW", "examples": [ "NEW" ] }, "state_reason": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "State Reason", "description": "Optional explanation for the current state.", "examples": [ "Processing failed: timeout" ] }, "state_changed_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "State Changed At", "description": "UTC timestamp when the state last changed.", "examples": [ "2026-01-16T08:00:00Z" ] }, "id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Id", "description": "Primary key for the message.", "examples": [ 1 ] }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "Timestamp when the message was created.", "examples": [ "2026-06-23T12:00:00Z" ] }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At", "description": "Timestamp when the message was last updated.", "examples": [ "2026-06-23T12:00:00Z" ] }, "creator_user_id": { "type": "integer", "title": "Creator User Id", "description": "ID of the user who created the message.", "examples": [ 1 ] }, "chat_id": { "type": "integer", "title": "Chat Id", "description": "ID of the chat the message belongs to.", "examples": [ 1 ] }, "role": { "type": "string", "title": "Role", "description": "Role of the message author (see llama-index MessageRole values).", "examples": [ "user" ] }, "content": { "type": "string", "title": "Content", "description": "Rendered content of the message.", "examples": [ "Hello, how can I help you?" ] }, "sent_user_msg": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Sent User Msg", "description": "Original user-sent message text, if applicable.", "examples": [ "Summarize the attached document." ] }, "parent_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Parent Id", "description": "ID of the parent message in a threaded conversation.", "examples": [ 1 ] }, "completed": { "type": "boolean", "title": "Completed", "description": "DEPRECATED. Whether the message has finished processing.", "default": false, "examples": [ true ] }, "error": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Error", "description": "DEPRECATED. Error message captured during processing, if any.", "examples": [ "Model timed out" ] }, "hint": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Hint", "description": "Hint shown to the user about the next action.", "examples": [ "You can ask a follow-up question." ] }, "llm_catalog_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Llm Catalog Id", "description": "ID of the LLM catalog entry used for this message.", "examples": [ 1 ] }, "llm_settings_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Llm Settings Id", "description": "ID of the LLM settings used for this message.", "examples": [ 1 ] }, "usage": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Usage", "description": "Token usage metadata recorded for this message.", "examples": [ { "completion_tokens": 120, "prompt_tokens": 50 } ] }, "celery_task_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Celery Task Id", "description": "ID of the Celery task processing this message, if any.", "examples": [ "3fa85f64-5717-4562-b3fc-2c963f66afa6" ] } }, "type": "object", "required": [ "creator_user_id", "chat_id", "role", "content", "sent_user_msg", "parent_id", "error", "hint" ], "title": "Message" }, "MessageDetailOut": { "properties": { "id": { "type": "integer", "title": "Id", "description": "ID of the message.", "examples": [ 200 ] }, "chat_id": { "type": "integer", "title": "Chat Id", "description": "ID of the chat the message belongs to.", "examples": [ 42 ] }, "parent_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Parent Id", "description": "ID of the parent user message for assistant replies, else null.", "examples": [ 199 ] }, "role": { "type": "string", "title": "Role", "description": "Role of the message author.", "examples": [ "assistant" ] }, "content": { "type": "string", "title": "Content", "description": "Text content of the message.", "examples": [ "Here is the summary you requested." ] }, "state": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "State", "description": "Processing state of the message.", "examples": [ "completed" ] }, "error": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Error", "description": "Error string if generation failed, else null.", "examples": [ null ] }, "hint": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Hint", "description": "Optional hint about the message state.", "examples": [ null ] }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "When the message was created.", "examples": [ "2026-01-15T10:30:00Z" ] }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At", "description": "When the message was last updated.", "examples": [ "2026-01-15T10:30:05Z" ] }, "usage": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Usage", "description": "Token usage and cost metadata, if available.", "examples": [ { "completion_tokens": 80, "prompt_tokens": 120 } ] }, "tool_calls": { "items": { "$ref": "#/components/schemas/ToolCallOut" }, "type": "array", "title": "Tool Calls", "description": "Tool calls made while generating the message.", "examples": [ [] ] }, "files": { "items": { "$ref": "#/components/schemas/MessageFileOut" }, "type": "array", "title": "Files", "description": "Files attached to the message.", "examples": [ [] ] } }, "type": "object", "required": [ "id", "chat_id", "parent_id", "role", "content", "state", "error", "hint", "created_at", "updated_at", "usage", "tool_calls", "files" ], "title": "MessageDetailOut", "description": "Composed message state \u2014 the recovery contract for dropped SSE streams.\n\nSee backend/docs/streaming-architecture.md \u00a76 requirement 4." }, "MessageFileOut": { "properties": { "id": { "type": "integer", "title": "Id", "description": "ID of the attached document.", "examples": [ 55 ] }, "filename": { "type": "string", "title": "Filename", "description": "Original file name.", "examples": [ "report.pdf" ] }, "content_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Content Type", "description": "MIME type of the file, if known.", "examples": [ "application/pdf" ] } }, "type": "object", "required": [ "id", "filename", "content_type" ], "title": "MessageFileOut" }, "MessageIn": { "properties": { "content": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Content", "description": "Text content of the user message.", "examples": [ "Summarize the attached report." ] }, "chat_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Chat Id", "description": "ID of an existing chat to post into; omit to start a new chat.", "examples": [ 42 ] }, "updated_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Updated At", "description": "Last-known chat timestamp, used for optimistic concurrency.", "examples": [ "2026-01-15T10:30:00Z" ] }, "project_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Project Id", "description": "ID of the project to associate a new chat with.", "examples": [ 7 ] }, "model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Model", "description": "Name of the LLM model to use for a new chat.", "examples": [ "gpt-4o" ] }, "temperature": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Temperature", "description": "Sampling temperature for a new chat.", "examples": [ 0.7 ] }, "similarity_top_k": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Similarity Top K", "description": "Number of top similar chunks to retrieve for a new chat.", "examples": [ 5 ] }, "system_prompt": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "System Prompt", "description": "System prompt for a new chat.", "examples": [ "You are a concise analyst." ] }, "assistant_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Assistant Id", "description": "ID of an assistant to drive a new chat.", "examples": [ 3 ] }, "private": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Private", "description": "Whether a new chat is private to its creator.", "default": false, "examples": [ false ] }, "form_data": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Form Data", "description": "Form submission data, accepted only when starting a new chat with a form-input assistant.", "examples": [ { "topic": "Q3 results" } ] } }, "type": "object", "title": "MessageIn" }, "OAuth2ProviderEnum": { "type": "string", "enum": [ "azure-entra", "microsoft", "atlassian", "hubspot", "oidc" ], "title": "OAuth2ProviderEnum", "description": "Enum for OAuth providers." }, "OAuthClient": { "properties": { "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "UTC timestamp when the record was created.", "examples": [ "2026-01-15T10:30:00Z" ] }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At", "description": "UTC timestamp when the record was last updated.", "examples": [ "2026-01-16T08:00:00Z" ] }, "creator_user_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Creator User Id", "description": "ID of the user who created the record, if attributable.", "examples": [ 12 ] }, "updater_user_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Updater User Id", "description": "ID of the user who last updated the record, if any.", "examples": [ 12 ] }, "id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Id", "description": "Primary key for the OAuth client.", "examples": [ 1 ] }, "name": { "type": "string", "title": "Name", "description": "Unique human-readable name of the OAuth client.", "examples": [ "Microsoft 365" ] }, "provider_key": { "$ref": "#/components/schemas/OAuth2ProviderEnum", "description": "OAuth provider this client uses.", "examples": [ "microsoft" ] }, "client_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Client Id", "description": "OAuth application (client) ID issued by the provider.", "examples": [ "11111111-2222-3333-4444-555555555555" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Optional description of the OAuth client.", "examples": [ "Microsoft Entra ID login and connectors" ] }, "icon_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Icon Url", "description": "URL of the icon shown for this OAuth client.", "examples": [ "https://cdn.example.com/microsoft.png" ] }, "authorize_url": { "type": "string", "title": "Authorize Url", "description": "OAuth authorization endpoint URL.", "examples": [ "https://login.microsoftonline.com/common/oauth2/v2.0/authorize" ] }, "admin_consent_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Admin Consent Url", "description": "URL for granting tenant-wide admin consent, if applicable.", "examples": [ "https://login.microsoftonline.com/common/adminconsent" ] }, "token_url": { "type": "string", "title": "Token Url", "description": "OAuth token endpoint URL.", "examples": [ "https://login.microsoftonline.com/common/oauth2/v2.0/token" ] }, "logout_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Logout Url", "description": "URL used to log the user out of the provider session.", "examples": [ "https://login.microsoftonline.com/common/oauth2/v2.0/logout" ] }, "redirect_uri": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Redirect Uri", "description": "Redirect URI registered for the OAuth callback.", "examples": [ "https://app.example.com/auth/callback" ] } }, "type": "object", "required": [ "name", "provider_key", "authorize_url", "token_url" ], "title": "OAuthClient" }, "OAuthClientUpdate": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "New display name for the OAuth client.", "examples": [ "Microsoft 365" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "New description for the OAuth client.", "examples": [ "Shared Microsoft OAuth application." ] }, "icon_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Icon Url", "description": "URL of an icon representing the OAuth client.", "examples": [ "https://cdn.example.com/icons/microsoft.svg" ] } }, "type": "object", "title": "OAuthClientUpdate" }, "OutputFormat": { "type": "string", "enum": [ "pdf", "docx", "html", "rtf", "odt", "xlsx", "csv" ], "title": "OutputFormat" }, "PasswordResetIn": { "properties": { "old_password": { "type": "string", "title": "Old Password", "description": "Current password, required to authorize the change.", "examples": [ "Old-P@ssw0rd!" ] }, "new_password": { "type": "string", "title": "New Password", "description": "New password to set.", "examples": [ "S3cure-P@ssw0rd!" ] } }, "type": "object", "required": [ "old_password", "new_password" ], "title": "PasswordResetIn" }, "PasswordResetRequestIn": { "properties": { "email": { "type": "string", "format": "email", "title": "Email", "description": "Email address of the account to send a reset link to.", "examples": [ "jane.doe@example.com" ] } }, "type": "object", "required": [ "email" ], "title": "PasswordResetRequestIn" }, "Project": { "properties": { "id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Id", "description": "Primary key for the project.", "examples": [ 1 ] }, "tenant_id": { "type": "integer", "title": "Tenant Id", "description": "ID of the tenant that owns the project.", "examples": [ 1 ] }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "Timestamp when the project was created.", "examples": [ "2026-06-23T12:00:00Z" ] }, "creator_user_id": { "type": "integer", "title": "Creator User Id", "description": "ID of the user who created the project.", "examples": [ 1 ] }, "name": { "type": "string", "title": "Name", "description": "Name of the project.", "examples": [ "Marketing Campaign" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Optional description of the project.", "examples": [ "Project for Q3 marketing assets" ] }, "description_show_in_chat": { "type": "boolean", "title": "Description Show In Chat", "description": "Whether the project description is shown in the chat UI.", "default": false, "examples": [ false ] } }, "type": "object", "required": [ "tenant_id", "creator_user_id", "name", "description" ], "title": "Project" }, "ProjectIn": { "properties": { "name": { "type": "string", "title": "Name", "description": "Display name of the project.", "examples": [ "Customer Support Bot" ] }, "description_show_in_chat": { "type": "boolean", "title": "Description Show In Chat", "description": "Whether the project description is shown to users in chat.", "default": false, "examples": [ false ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Optional longer description of the project's purpose.", "examples": [ "Internal assistant for the support team." ] } }, "type": "object", "required": [ "name" ], "title": "ProjectIn" }, "ProjectLibrary": { "properties": { "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "UTC timestamp when the record was created.", "examples": [ "2026-01-15T10:30:00Z" ] }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At", "description": "UTC timestamp when the record was last updated.", "examples": [ "2026-01-16T08:00:00Z" ] }, "creator_user_id": { "type": "integer", "title": "Creator User Id", "description": "ID of the user who created the record.", "examples": [ 12 ] }, "updater_user_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Updater User Id", "description": "ID of the user who last updated the record, if any.", "examples": [ 12 ] }, "project_id": { "type": "integer", "title": "Project Id", "description": "ID of the project.", "examples": [ 1 ] }, "library_id": { "type": "integer", "title": "Library Id", "description": "ID of the library linked to the project.", "examples": [ 1 ] } }, "type": "object", "required": [ "creator_user_id", "project_id", "library_id" ], "title": "ProjectLibrary" }, "ProjectMember": { "properties": { "tenant_id": { "type": "integer", "title": "Tenant Id", "description": "ID of the tenant that owns the project membership.", "examples": [ 1 ] }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "Timestamp when the membership was created.", "examples": [ "2026-06-23T12:00:00Z" ] }, "project_id": { "type": "integer", "title": "Project Id", "description": "ID of the project.", "examples": [ 1 ] }, "user_id": { "type": "integer", "title": "User Id", "description": "ID of the member user.", "examples": [ 1 ] }, "role": { "type": "string", "title": "Role", "description": "Role of the user within the project.", "examples": [ "OWNER" ] } }, "type": "object", "required": [ "tenant_id", "project_id", "user_id", "role" ], "title": "ProjectMember" }, "ProjectMemberBulkDelete": { "properties": { "user_ids": { "items": { "type": "integer" }, "type": "array", "title": "User Ids", "description": "IDs of the users to remove from the project.", "examples": [ [ 42, 43 ] ] } }, "type": "object", "required": [ "user_ids" ], "title": "ProjectMemberBulkDelete" }, "ProjectMemberBulkIn": { "properties": { "members": { "items": { "$ref": "#/components/schemas/ProjectMemberIn" }, "type": "array", "title": "Members", "description": "List of members to add to the project." } }, "type": "object", "required": [ "members" ], "title": "ProjectMemberBulkIn" }, "ProjectMemberIn": { "properties": { "user_id": { "type": "integer", "title": "User Id", "description": "ID of the user to add to the project.", "examples": [ 42 ] }, "role": { "type": "string", "title": "Role", "description": "Role to assign to the member (e.g. `owner` or `member`).", "examples": [ "member" ] } }, "type": "object", "required": [ "user_id", "role" ], "title": "ProjectMemberIn" }, "Prompt": { "properties": { "id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Id", "description": "Primary key for the prompt.", "examples": [ 1 ] }, "tenant_id": { "type": "integer", "title": "Tenant Id", "description": "ID of the tenant that owns the prompt.", "examples": [ 1 ] }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "Timestamp when the prompt was created.", "examples": [ "2026-06-23T12:00:00Z" ] }, "creator_user_id": { "type": "integer", "title": "Creator User Id", "description": "ID of the user who created the prompt.", "examples": [ 1 ] }, "name": { "anyOf": [ { "type": "string", "maxLength": 100 }, { "type": "null" } ], "title": "Name", "description": "Name of the prompt.", "examples": [ "Summarize document" ] }, "prompt": { "type": "string", "title": "Prompt", "description": "Prompt text content.", "examples": [ "Summarize the following document in three bullet points." ] }, "is_public": { "type": "boolean", "title": "Is Public", "description": "Whether the prompt is shared publicly within the tenant.", "default": false, "examples": [ false ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Optional description of the prompt.", "examples": [ "A reusable prompt for document summaries" ] } }, "type": "object", "required": [ "tenant_id", "creator_user_id", "name", "prompt", "description" ], "title": "Prompt" }, "PromptIn": { "properties": { "name": { "anyOf": [ { "type": "string", "maxLength": 100 }, { "type": "null" } ], "title": "Name", "description": "Name for the prompt to be created. Max 100 characters.", "examples": [ "Weekly report template" ] }, "prompt": { "type": "string", "title": "Prompt", "description": "The content of the prompt. This field is required.", "examples": [ "Summarize the following text in three bullet points: {{text}}" ] }, "is_public": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Is Public", "description": "Whether the prompt is public or privtate, default is private (False)", "default": false, "examples": [ false ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description for the prompt.", "examples": [ "Reusable template for weekly status reports." ] } }, "type": "object", "required": [ "prompt" ], "title": "PromptIn" }, "PromptOptimizeIn": { "properties": { "prompt": { "type": "string", "minLength": 1, "title": "Prompt", "description": "Prompt to optimize.", "examples": [ "write a short email to my team about the deadline" ] }, "temperature": { "type": "number", "title": "Temperature", "description": "Temperature for optimization, default is 0.0", "default": 0.0, "examples": [ 0.0 ] } }, "type": "object", "required": [ "prompt" ], "title": "PromptOptimizeIn" }, "PromptOptimizeOut": { "properties": { "content": { "type": "string", "title": "Content", "description": "The rewritten, optimized prompt text.", "examples": [ "Write a concise email to my team reminding them of the project deadline on Friday." ] } }, "type": "object", "required": [ "content" ], "title": "PromptOptimizeOut" }, "RephraseStyleEnum": { "type": "string", "enum": [ "same", "short", "long" ], "title": "RephraseStyleEnum" }, "SendEmailRequest": { "properties": { "tool_call_id": { "type": "string", "title": "Tool Call Id", "description": "The ID of the tool call that generated the draft", "examples": [ "call_abc123" ] }, "to": { "anyOf": [ { "type": "string" }, { "items": { "type": "string" }, "type": "array" } ], "title": "To", "description": "Recipient email address(es)", "examples": [ "alice@example.com", [ "alice@example.com", "bob@example.com" ] ] }, "subject": { "type": "string", "title": "Subject", "description": "Email subject", "examples": [ "Q2 report" ] }, "body": { "type": "string", "title": "Body", "description": "Email body content (can be markdown or HTML)", "examples": [ "Hi team,\n\nPlease find the **Q2 report** attached." ] }, "cc": { "anyOf": [ { "type": "string" }, { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Cc", "description": "CC recipients", "examples": [ "carol@example.com" ] }, "bcc": { "anyOf": [ { "type": "string" }, { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Bcc", "description": "BCC recipients", "examples": [ "dave@example.com" ] } }, "type": "object", "required": [ "tool_call_id", "to", "subject", "body" ], "title": "SendEmailRequest", "description": "Request to send an email from a tool call." }, "SendEmailResponse": { "properties": { "success": { "type": "boolean", "title": "Success", "description": "Whether the email was sent successfully.", "examples": [ true ] }, "message": { "type": "string", "title": "Message", "description": "Human-readable result message.", "examples": [ "Email sent successfully" ] }, "recipients": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Recipients", "description": "The recipients the email was sent to, if available.", "examples": [ [ "alice@example.com" ] ] } }, "type": "object", "required": [ "success", "message" ], "title": "SendEmailResponse", "description": "Response from sending an email." }, "SetAtlassianCloudIdRequest": { "properties": { "cloud_id": { "type": "string", "title": "Cloud Id", "description": "ID of the Atlassian site to make active. Must be one of the sites the user consented to (stored in `atlassian_sites`).", "examples": [ "11111111-2222-3333-4444-555555555555" ] } }, "type": "object", "required": [ "cloud_id" ], "title": "SetAtlassianCloudIdRequest", "description": "Payload selecting the active Atlassian site (cloud_id) for a connector." }, "Settings": { "properties": { "id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Id", "description": "Primary key for the tenant settings record.", "examples": [ 1 ] }, "tenant_id": { "type": "integer", "title": "Tenant Id", "description": "ID of the tenant these settings belong to.", "examples": [ 1 ] }, "default_llm_catalog_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Default Llm Catalog Id", "description": "ID of the default LLM catalog entry for the tenant.", "examples": [ 1 ] }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "Timestamp when the settings record was created.", "examples": [ "2026-06-23T12:00:00Z" ] }, "guardrails_enabled": { "type": "boolean", "title": "Guardrails Enabled", "description": "Whether guardrails are enabled for the tenant.", "default": false, "examples": [ false ] }, "sharepoint_enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Sharepoint Enabled", "description": "Whether SharePoint integration is enabled for the tenant.", "examples": [ true ] }, "inbound_guardrail": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Inbound Guardrail", "description": "Identifier of the inbound guardrail policy applied to user input.", "examples": [ "default-inbound" ] }, "outbound_guardrail": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Outbound Guardrail", "description": "Identifier of the outbound guardrail policy applied to model output.", "examples": [ "default-outbound" ] }, "system_prompt": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "System Prompt", "description": "Tenant-wide default system prompt.", "examples": [ "You are a helpful assistant." ] }, "inserted_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Inserted By", "description": "Marker indicating which process inserted the record (e.g. alembic).", "examples": [ "alembic" ] }, "errlog_webhook_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Errlog Webhook Url", "description": "Webhook URL for delivering error log notifications.", "examples": [ "https://hooks.example.com/errors" ] }, "default_language": { "type": "string", "maxLength": 5, "title": "Default Language", "description": "Default language code for the tenant's emails.", "default": "en", "examples": [ "en" ] }, "require_email_confirmation": { "type": "boolean", "title": "Require Email Confirmation", "description": "Whether users must confirm their email before login.", "default": false, "examples": [ false ] } }, "type": "object", "required": [ "tenant_id", "sharepoint_enabled", "inserted_by" ], "title": "Settings" }, "SettingsIn": { "properties": { "default_llm_catalog_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Default Llm Catalog Id", "description": "ID of the LLM catalog entry to use as the tenant default model. Must be a model enabled for the tenant.", "examples": [ 3 ] }, "guardrails_enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Guardrails Enabled", "description": "Whether input/output guardrails are applied to chat.", "examples": [ true ] }, "sharepoint_enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Sharepoint Enabled", "description": "Whether the SharePoint integration is enabled for the tenant.", "examples": [ false ] }, "inbound_guardrail": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Inbound Guardrail", "description": "Identifier of the guardrail applied to inbound (user) messages.", "examples": [ "default-inbound" ] }, "outbound_guardrail": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Outbound Guardrail", "description": "Identifier of the guardrail applied to outbound (model) messages.", "examples": [ "default-outbound" ] }, "welcome_email_template_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Welcome Email Template Id", "description": "ID of the email template sent to new users on signup.", "examples": [ 1 ] }, "project_member_added_email_template_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Project Member Added Email Template Id", "description": "ID of the email template sent when a user is added to a project.", "examples": [ 2 ] }, "system_prompt": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "System Prompt", "description": "Tenant-wide system prompt prepended to chat conversations.", "examples": [ "You are a helpful assistant for Acme Corp." ] }, "errlog_webhook_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Errlog Webhook Url", "description": "Webhook URL that receives error-log notifications.", "examples": [ "https://hooks.example.com/errlog" ] }, "require_email_confirmation": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Require Email Confirmation", "description": "Whether new users must confirm their email. Superadmin-only field.", "examples": [ true ] } }, "type": "object", "title": "SettingsIn" }, "SharepointDriveModel": { "properties": { "id": { "type": "string", "title": "Id", "description": "Drive id.", "examples": [ "b!abc123" ] }, "web_url": { "type": "string", "title": "Web Url", "description": "URL to open the drive in SharePoint.", "examples": [ "https://contoso.sharepoint.com/sites/Team/Shared%20Documents" ] }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Drive name.", "examples": [ "Documents" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Drive description, if set.", "examples": [ "Shared team documents" ] }, "root": { "$ref": "#/components/schemas/SharepointItemModel", "description": "The drive's root folder item." }, "imported_count": { "type": "integer", "title": "Imported Count", "description": "Number of imported documents from this drive in the current scope.", "default": 0, "examples": [ 7 ] } }, "type": "object", "required": [ "id", "web_url", "name", "description", "root" ], "title": "SharepointDriveModel", "description": "A document library (drive) within a SharePoint site." }, "SharepointFolderModel": { "properties": { "child_count": { "type": "integer", "title": "Child Count", "description": "Number of immediate children inside the folder.", "examples": [ 12 ] } }, "type": "object", "required": [ "child_count" ], "title": "SharepointFolderModel", "description": "Metadata specific to folder items." }, "SharepointItemModel": { "properties": { "id": { "type": "string", "title": "Id", "description": "Drive item id.", "examples": [ "01ABCDEF..." ] }, "web_url": { "type": "string", "title": "Web Url", "description": "URL to open the item in SharePoint.", "examples": [ "https://contoso.sharepoint.com/sites/Team/Shared%20Documents/file.docx" ] }, "drive_id": { "type": "string", "title": "Drive Id", "description": "Id of the drive containing the item.", "examples": [ "b!abc123" ] }, "site_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Site Id", "description": "Id of the site the item belongs to, if any.", "examples": [ "contoso.sharepoint.com,guid1,guid2" ] }, "parent_folder_id": { "type": "string", "title": "Parent Folder Id", "description": "Id of the parent folder, or 'root'.", "examples": [ "root" ] }, "parent_path": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Parent Path", "description": "Path of the parent folder within the drive.", "examples": [ "/drive/root:/Documents" ] }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Item name.", "examples": [ "report.docx" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Item description, if set.", "examples": [ "Quarterly report" ] }, "size": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Size", "description": "Item size in bytes.", "examples": [ 24576 ] }, "last_modified_date_time": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Last Modified Date Time", "description": "When the item was last modified.", "examples": [ "2026-02-20T14:00:00Z" ] }, "mimetype": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Mimetype", "description": "MIME type for files; null for folders.", "examples": [ "application/vnd.openxmlformats-officedocument.wordprocessingml.document" ] }, "folder": { "anyOf": [ { "$ref": "#/components/schemas/SharepointFolderModel" }, { "type": "null" } ], "description": "Folder metadata when the item is a folder; null for files." }, "imported": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Imported", "description": "Whether this file has already been imported into the current scope.", "examples": [ false ] }, "imported_count": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Imported Count", "description": "For folders, the number of imported documents under this folder.", "examples": [ 3 ] } }, "type": "object", "required": [ "id", "web_url", "drive_id", "site_id", "parent_folder_id", "parent_path", "name", "description", "size", "last_modified_date_time", "mimetype", "folder" ], "title": "SharepointItemModel", "description": "A file or folder item in a SharePoint drive." }, "SharepointSiteModel": { "properties": { "id": { "type": "string", "title": "Id", "description": "Site id.", "examples": [ "contoso.sharepoint.com,guid1,guid2" ] }, "web_url": { "type": "string", "title": "Web Url", "description": "URL to open the site in SharePoint.", "examples": [ "https://contoso.sharepoint.com/sites/Team" ] }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Site name.", "examples": [ "Team" ] }, "display_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Display Name", "description": "Human-readable site display name.", "examples": [ "Team Site" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Site description, if set.", "examples": [ "Collaboration site" ] }, "imported_count": { "type": "integer", "title": "Imported Count", "description": "Number of imported documents from this site in the current scope.", "default": 0, "examples": [ 15 ] } }, "type": "object", "required": [ "id", "web_url", "name", "display_name", "description" ], "title": "SharepointSiteModel", "description": "A SharePoint site." }, "SharepointUserModel": { "properties": { "display_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Display Name", "description": "User's display name.", "examples": [ "Alice Smith" ] }, "job_title": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Job Title", "description": "User's job title.", "examples": [ "Product Manager" ] }, "mail": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Mail", "description": "User's email address.", "examples": [ "alice@contoso.com" ] }, "surname": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Surname", "description": "User's surname.", "examples": [ "Smith" ] }, "user_principal_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "User Principal Name", "description": "User principal name (UPN).", "examples": [ "alice@contoso.com" ] } }, "type": "object", "required": [ "display_name", "job_title", "mail", "surname", "user_principal_name" ], "title": "SharepointUserModel", "description": "The signed-in user's SharePoint / Microsoft Graph profile." }, "SystemSettings": { "properties": { "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "UTC timestamp when the record was created.", "examples": [ "2026-01-15T10:30:00Z" ] }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At", "description": "UTC timestamp when the record was last updated.", "examples": [ "2026-01-16T08:00:00Z" ] }, "id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Id", "description": "Primary key for the system settings record.", "examples": [ 1 ] }, "maintenance_enabled": { "type": "boolean", "title": "Maintenance Enabled", "description": "Whether maintenance mode is currently enabled.", "default": false, "examples": [ false ] }, "tracing_enabled": { "type": "boolean", "title": "Tracing Enabled", "description": "Whether observability tracing is enabled system-wide.", "default": true, "examples": [ true ] }, "inbound_guardrail_llm_settings_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Inbound Guardrail Llm Settings Id", "description": "ID of the LLM settings used for the inbound guardrail.", "examples": [ 1 ] }, "outbound_guardrail_llm_settings_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Outbound Guardrail Llm Settings Id", "description": "ID of the LLM settings used for the outbound guardrail.", "examples": [ 1 ] }, "embedding_llm_settings_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Embedding Llm Settings Id", "description": "ID of the LLM settings used for embeddings.", "examples": [ 1 ] }, "transcription_llm_settings_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Transcription Llm Settings Id", "description": "ID of the LLM settings used for audio transcription.", "examples": [ 1 ] }, "maintenance_start_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Maintenance Start At", "description": "Timestamp when the scheduled maintenance window starts.", "examples": [ "2026-06-23T12:00:00Z" ] }, "maintenance_end_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Maintenance End At", "description": "Timestamp when the scheduled maintenance window ends.", "examples": [ "2026-06-23T14:00:00Z" ] }, "maintenance_message": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Maintenance Message", "description": "Message shown to users during maintenance mode.", "examples": [ "The system is under maintenance." ] } }, "type": "object", "title": "SystemSettings" }, "SystemSettingsUpdate": { "properties": { "maintenance_enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Maintenance Enabled" }, "tracing_enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Tracing Enabled" }, "inbound_guardrail_llm_settings_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Inbound Guardrail Llm Settings Id" }, "outbound_guardrail_llm_settings_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Outbound Guardrail Llm Settings Id" }, "embedding_llm_settings_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Embedding Llm Settings Id" }, "maintenance_start_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Maintenance Start At" }, "maintenance_end_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Maintenance End At" }, "maintenance_message": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Maintenance Message" }, "reason": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Reason" } }, "type": "object", "title": "SystemSettingsUpdate" }, "Tag": { "properties": { "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "UTC timestamp when the record was created.", "examples": [ "2026-01-15T10:30:00Z" ] }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At", "description": "UTC timestamp when the record was last updated.", "examples": [ "2026-01-16T08:00:00Z" ] }, "id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Id", "description": "Primary key for the tag.", "examples": [ 1 ] }, "tenant_id": { "type": "integer", "title": "Tenant Id", "description": "ID of the tenant that owns the tag.", "examples": [ 1 ] }, "name": { "type": "string", "maxLength": 50, "title": "Name", "description": "Name of the tag.", "examples": [ "urgent" ] }, "creator_user_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Creator User Id", "description": "ID of the user who created the tag." }, "updater_user_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Updater User Id", "description": "ID of the user who last updated the tag.", "examples": [ 1 ] } }, "type": "object", "required": [ "tenant_id", "name" ], "title": "Tag" }, "TagIn": { "properties": { "name": { "type": "string", "maxLength": 50, "minLength": 1, "title": "Name", "description": "Tag label, unique per tenant. Leading/trailing whitespace is stripped.", "examples": [ "finance" ] } }, "type": "object", "required": [ "name" ], "title": "TagIn" }, "Tagging": { "properties": { "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "UTC timestamp when the record was created.", "examples": [ "2026-01-15T10:30:00Z" ] }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At", "description": "UTC timestamp when the record was last updated.", "examples": [ "2026-01-16T08:00:00Z" ] }, "tag_id": { "type": "integer", "title": "Tag Id", "description": "ID of the tag being applied.", "examples": [ 1 ] }, "taggable_type": { "type": "string", "maxLength": 50, "title": "Taggable Type", "description": "Resource type this tag is attached to." }, "taggable_id": { "type": "integer", "title": "Taggable Id", "description": "ID of the resource." }, "tenant_id": { "type": "integer", "title": "Tenant Id", "description": "ID of the tenant that owns the tagging.", "examples": [ 1 ] }, "creator_user_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Creator User Id", "description": "ID of the user who attached the tag." } }, "type": "object", "required": [ "tag_id", "taggable_type", "taggable_id", "tenant_id" ], "title": "Tagging" }, "Tarif": { "properties": { "id": { "type": "integer", "title": "Id", "description": "Primary key for the tarif record." }, "name": { "type": "string", "maxLength": 100, "title": "Name", "description": "Name for the tarif to be created. Max 100 characters." }, "price": { "type": "number", "title": "Price", "description": "The price of the tarif. This field is required." }, "hard_limit": { "anyOf": [ { "type": "number", "minimum": 0.0 }, { "type": "null" } ], "title": "Hard Limit", "description": "Max allowed usage; None = unlimited if is_unlimited.", "default": 0 }, "licenses": { "anyOf": [ { "type": "integer", "minimum": 0.0 }, { "type": "null" } ], "title": "Licenses", "description": "Seats sold; sizes the tenant monthly pool." }, "monthly_limit_per_license": { "anyOf": [ { "type": "number", "minimum": 0.0 }, { "type": "null" } ], "title": "Monthly Limit Per License", "description": "Per-seat monthly allowance." }, "soft_limit_fraction": { "anyOf": [ { "type": "number", "maximum": 1.0, "minimum": 0.0 }, { "type": "null" } ], "title": "Soft Limit Fraction", "description": "Warn user when monthly spend reaches this fraction of monthly_limit_per_license." }, "is_unlimited": { "type": "boolean", "title": "Is Unlimited", "description": "Bypass usage checks if True.", "default": false }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description of the tarif." }, "status": { "$ref": "#/components/schemas/TarifStatusEnum", "description": "active = offered; retired = not for new signups.", "default": "ACTIVE" }, "is_default": { "type": "boolean", "title": "Is Default", "description": "Whether this tarif is the default plan for new tenants.", "default": false, "examples": [ false ] }, "creator_user_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Creator User Id", "description": "ID of the user who created the tarif." }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "Timestamp when the tarif was created." }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At", "description": "Timestamp when the tarif was last updated." } }, "type": "object", "required": [ "name", "price", "creator_user_id" ], "title": "Tarif", "description": "Model for creating or updating a tarif." }, "TarifIn": { "properties": { "name": { "type": "string", "maxLength": 100, "title": "Name", "description": "Name for the tarif to be created. Max 100 characters.", "examples": [ "Pro plan" ] }, "price": { "type": "number", "title": "Price", "description": "The price of the tarif. This field is required.", "examples": [ 99.0 ] }, "hard_limit": { "type": "number", "title": "Hard Limit", "description": "The hard limit to restrict the user.", "examples": [ 500.0 ] }, "licenses": { "anyOf": [ { "type": "integer", "minimum": 0.0 }, { "type": "null" } ], "title": "Licenses", "description": "Seats sold; sizes the tenant monthly pool.", "examples": [ 25 ] }, "monthly_limit_per_license": { "anyOf": [ { "type": "number", "minimum": 0.0 }, { "type": "null" } ], "title": "Monthly Limit Per License", "description": "Per-seat monthly allowance.", "examples": [ 20.0 ] }, "soft_limit_fraction": { "anyOf": [ { "type": "number", "maximum": 1.0, "minimum": 0.0 }, { "type": "null" } ], "title": "Soft Limit Fraction", "description": "Warn user when monthly spend reaches this fraction of monthly_limit_per_license.", "examples": [ 0.8 ] }, "status": { "anyOf": [ { "$ref": "#/components/schemas/TarifStatusEnum" }, { "type": "null" } ], "description": "The status of tarif (Active/Retired)", "default": "ACTIVE", "examples": [ "active" ] }, "expires_at": { "anyOf": [ { "type": "string", "format": "date" }, { "type": "null" } ], "title": "Expires At", "description": "When the tarif expires; None = never.", "examples": [ "2026-12-31" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description of the tarif.", "examples": [ "Standard professional plan with monthly pool." ] }, "is_unlimited": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Is Unlimited", "description": "Whether the tarif has unlimited usage.", "default": false, "examples": [ false ] } }, "type": "object", "required": [ "name", "price", "hard_limit" ], "title": "TarifIn", "description": "Model for creating or updating a tarif." }, "TarifStatusEnum": { "type": "string", "enum": [ "ACTIVE", "RETIRED" ], "title": "TarifStatusEnum", "description": "Enum for Tarif status in Tarif" }, "TemplateIn": { "properties": { "name": { "anyOf": [ { "type": "string", "maxLength": 100 }, { "type": "null" } ], "title": "Name", "description": "Human-readable label for the template. Max 100 characters.", "examples": [ "Welcome email" ] }, "text_body": { "type": "string", "title": "Text Body", "description": "Plain-text body of the email.", "examples": [ "Welcome to Neuland AI Hub!" ] }, "html_body": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Html Body", "description": "Optional HTML body of the email.", "examples": [ "

Welcome to Neuland AI Hub!

" ] } }, "type": "object", "required": [ "text_body" ], "title": "TemplateIn", "description": "Payload for creating or updating an email template." }, "TemplateOut": { "properties": { "id": { "type": "integer", "title": "Id", "description": "Unique identifier of the template.", "examples": [ 42 ] }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Human-readable label for the template.", "examples": [ "Welcome email" ] }, "text_body": { "type": "string", "title": "Text Body", "description": "Plain-text body of the email.", "examples": [ "Welcome to Neuland AI Hub!" ] }, "html_body": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Html Body", "description": "HTML body of the email, or null if none.", "examples": [ "

Welcome to Neuland AI Hub!

" ] } }, "type": "object", "required": [ "id", "name", "text_body", "html_body" ], "title": "TemplateOut", "description": "Email template as returned by the API." }, "TenantIn": { "properties": { "name": { "type": "string", "title": "Name", "description": "Internal name of the tenant.", "examples": [ "Acme Corp" ] }, "slug": { "type": "string", "title": "Slug", "description": "URL-safe unique identifier for the tenant.", "examples": [ "acme-corp" ] }, "domain": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Domain", "description": "Primary email/web domain associated with the tenant.", "examples": [ "acme.com" ] }, "parent_tenant_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Parent Tenant Id", "description": "ID of the parent tenant, when this is a child tenant.", "examples": [ 1 ] }, "subtenants_enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Subtenants Enabled", "description": "Whether this tenant may create child tenants. Superadmin-only.", "examples": [ false ] }, "timezone": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Timezone", "description": "Default IANA timezone for the tenant.", "examples": [ "Europe/Berlin" ] }, "locale": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Locale", "description": "Default locale for the tenant.", "examples": [ "en-US" ] }, "tarif_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Tarif Id", "description": "ID of the tariff to assign to the tenant. Superadmin-only.", "examples": [ 2 ] }, "tarif_expires_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Tarif Expires At", "description": "UTC timestamp when the assigned tariff expires. Superadmin-only.", "examples": [ "2026-12-31T23:59:59Z" ] }, "max_users": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Max Users", "description": "Maximum number of users allowed in the tenant.", "examples": [ 100 ] }, "max_projects": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Max Projects", "description": "Maximum number of projects allowed in the tenant.", "examples": [ 50 ] }, "licenses": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Licenses", "description": "Number of seats/licenses for the tenant. Superadmin-only.", "examples": [ 100 ] }, "display_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Display Name", "description": "Human-friendly display name shown in the UI.", "examples": [ "Acme Corporation" ] }, "motto": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Motto", "description": "Short tagline shown in the tenant's UI.", "examples": [ "Building the future." ] }, "logo_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Logo Url", "description": "URL of the tenant's primary logo.", "examples": [ "https://cdn.example.com/acme/logo.png" ] }, "square_logo_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Square Logo Url", "description": "URL of the tenant's square logo variant.", "examples": [ "https://cdn.example.com/acme/logo-square.png" ] }, "favicon_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Favicon Url", "description": "URL of the tenant's favicon.", "examples": [ "https://cdn.example.com/acme/favicon.ico" ] }, "chat_square_logo_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Chat Square Logo Url", "description": "URL of the square logo shown in the chat UI.", "examples": [ "https://cdn.example.com/acme/chat-logo.png" ] }, "primary_color": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Primary Color", "description": "Primary brand color (hex).", "examples": [ "#1A2B3C" ] }, "secondary_color": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Secondary Color", "description": "Secondary brand color (hex).", "examples": [ "#4D5E6F" ] }, "theme": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Theme", "description": "Name of the UI theme to apply.", "examples": [ "light" ] }, "storage_limit_gb": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Storage Limit Gb", "description": "Storage limit for the tenant, in gigabytes.", "examples": [ 100 ] }, "api_rate_limit": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Api Rate Limit", "description": "API request rate limit for the tenant.", "examples": [ 1000 ] }, "upstream_tenant_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Upstream Tenant Id", "description": "UUID of the upstream identity-provider tenant. Superadmin-only.", "examples": [ "3fa85f64-5717-4562-b3fc-2c963f66afa6" ] }, "upstream_oidc_issuer": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Upstream Oidc Issuer", "description": "OIDC issuer URL of the upstream identity provider. Superadmin-only.", "examples": [ "https://login.example.com/" ] } }, "type": "object", "required": [ "name", "slug" ], "title": "TenantIn" }, "TenantLLM": { "properties": { "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "UTC timestamp when the record was created.", "examples": [ "2026-01-15T10:30:00Z" ] }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At", "description": "UTC timestamp when the record was last updated.", "examples": [ "2026-01-16T08:00:00Z" ] }, "creator_user_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Creator User Id", "description": "ID of the user who created the record, if attributable.", "examples": [ 12 ] }, "updater_user_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Updater User Id", "description": "ID of the user who last updated the record, if any.", "examples": [ 12 ] }, "tenant_id": { "type": "integer", "title": "Tenant Id", "description": "ID of the tenant the LLM is enabled for.", "examples": [ 1 ] }, "llm_catalog_id": { "type": "integer", "title": "Llm Catalog Id", "description": "ID of the LLM catalog entry enabled for the tenant.", "examples": [ 1 ] } }, "type": "object", "required": [ "tenant_id", "llm_catalog_id" ], "title": "TenantLLM", "description": "Availability rows for tenant-enabled LLM models." }, "TenantModelBulkIn": { "properties": { "all": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "All", "description": "When true, apply to every tenant. Mutually exclusive with `tenant_ids`; exactly one must be provided.", "examples": [ true ] }, "tenant_ids": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "title": "Tenant Ids", "description": "Explicit list of tenant IDs to apply to. Mutually exclusive with `all`; exactly one must be provided.", "examples": [ [ 1, 2, 3 ] ] } }, "type": "object", "title": "TenantModelBulkIn" }, "TenantOut": { "properties": { "id": { "type": "integer", "title": "Id", "description": "Unique identifier of the tenant.", "examples": [ 1 ] }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "UTC timestamp when the tenant was created.", "examples": [ "2026-01-15T08:30:00Z" ] }, "creator_user_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Creator User Id", "description": "ID of the user who created the tenant, if known.", "examples": [ 42 ] }, "name": { "type": "string", "title": "Name", "description": "Internal name of the tenant.", "examples": [ "Acme Corp" ] }, "slug": { "type": "string", "title": "Slug", "description": "URL-safe unique identifier for the tenant.", "examples": [ "acme-corp" ] }, "domain": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Domain", "description": "Primary email/web domain associated with the tenant.", "examples": [ "acme.com" ] }, "parent_tenant_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Parent Tenant Id", "description": "ID of the parent tenant, when this is a child tenant.", "examples": [ 1 ] }, "subtenants_enabled": { "type": "boolean", "title": "Subtenants Enabled", "description": "Whether this tenant may create child tenants.", "examples": [ false ] }, "timezone": { "type": "string", "title": "Timezone", "description": "Default IANA timezone for the tenant.", "examples": [ "Europe/Berlin" ] }, "locale": { "type": "string", "title": "Locale", "description": "Default locale for the tenant.", "examples": [ "en-US" ] }, "tarif_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Tarif Id", "description": "ID of the tariff currently assigned to the tenant.", "examples": [ 2 ] }, "max_users": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Max Users", "description": "Maximum number of users allowed in the tenant.", "examples": [ 100 ] }, "max_projects": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Max Projects", "description": "Maximum number of projects allowed in the tenant.", "examples": [ 50 ] }, "licenses": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Licenses", "description": "Number of seats/licenses for the tenant.", "examples": [ 100 ] }, "display_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Display Name", "description": "Human-friendly display name shown in the UI.", "examples": [ "Acme Corporation" ] }, "motto": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Motto", "description": "Short tagline shown in the tenant's UI.", "examples": [ "Building the future." ] }, "logo_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Logo Url", "description": "URL of the tenant's primary logo.", "examples": [ "https://cdn.example.com/acme/logo.png" ] }, "square_logo_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Square Logo Url", "description": "URL of the tenant's square logo variant.", "examples": [ "https://cdn.example.com/acme/logo-square.png" ] }, "favicon_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Favicon Url", "description": "URL of the tenant's favicon.", "examples": [ "https://cdn.example.com/acme/favicon.ico" ] }, "chat_square_logo_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Chat Square Logo Url", "description": "URL of the square logo shown in the chat UI.", "examples": [ "https://cdn.example.com/acme/chat-logo.png" ] }, "primary_color": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Primary Color", "description": "Primary brand color (hex).", "examples": [ "#1A2B3C" ] }, "secondary_color": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Secondary Color", "description": "Secondary brand color (hex).", "examples": [ "#4D5E6F" ] }, "theme": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Theme", "description": "Name of the UI theme applied.", "examples": [ "light" ] }, "storage_limit_gb": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Storage Limit Gb", "description": "Storage limit for the tenant, in gigabytes.", "examples": [ 100 ] }, "api_rate_limit": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Api Rate Limit", "description": "API request rate limit for the tenant.", "examples": [ 1000 ] }, "state": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "State", "description": "Lifecycle state of the tenant.", "examples": [ "active" ] }, "upstream_tenant_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Upstream Tenant Id", "description": "UUID of the upstream identity-provider tenant.", "examples": [ "3fa85f64-5717-4562-b3fc-2c963f66afa6" ] }, "upstream_oidc_issuer": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Upstream Oidc Issuer", "description": "OIDC issuer URL of the upstream identity provider.", "examples": [ "https://login.example.com/" ] } }, "type": "object", "required": [ "id", "created_at", "name", "slug", "subtenants_enabled", "timezone", "locale" ], "title": "TenantOut" }, "TenantThemeOut": { "properties": { "name": { "type": "string", "title": "Name", "description": "Internal name of the tenant.", "examples": [ "Acme Corp" ] }, "slug": { "type": "string", "title": "Slug", "description": "URL-safe unique identifier for the tenant.", "examples": [ "acme-corp" ] }, "domain": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Domain", "description": "Primary email/web domain associated with the tenant.", "examples": [ "acme.com" ] }, "timezone": { "type": "string", "title": "Timezone", "description": "Default IANA timezone for the tenant.", "examples": [ "Europe/Berlin" ] }, "locale": { "type": "string", "title": "Locale", "description": "Default locale for the tenant.", "examples": [ "en-US" ] }, "display_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Display Name", "description": "Human-friendly display name shown in the UI.", "examples": [ "Acme Corporation" ] }, "motto": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Motto", "description": "Short tagline shown in the tenant's UI.", "examples": [ "Building the future." ] }, "logo_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Logo Url", "description": "URL of the tenant's primary logo.", "examples": [ "https://cdn.example.com/acme/logo.png" ] }, "square_logo_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Square Logo Url", "description": "URL of the tenant's square logo variant.", "examples": [ "https://cdn.example.com/acme/logo-square.png" ] }, "favicon_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Favicon Url", "description": "URL of the tenant's favicon.", "examples": [ "https://cdn.example.com/acme/favicon.ico" ] }, "chat_square_logo_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Chat Square Logo Url", "description": "URL of the square logo shown in the chat UI.", "examples": [ "https://cdn.example.com/acme/chat-logo.png" ] }, "primary_color": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Primary Color", "description": "Primary brand color (hex).", "examples": [ "#1A2B3C" ] }, "secondary_color": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Secondary Color", "description": "Secondary brand color (hex).", "examples": [ "#4D5E6F" ] }, "theme": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Theme", "description": "Name of the UI theme applied.", "examples": [ "light" ] } }, "type": "object", "required": [ "name", "slug", "timezone", "locale" ], "title": "TenantThemeOut" }, "TenantUpdateIn": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Internal name of the tenant.", "examples": [ "Acme Corp" ] }, "domain": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Domain", "description": "Primary email/web domain associated with the tenant.", "examples": [ "acme.com" ] }, "parent_tenant_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Parent Tenant Id", "description": "ID of the parent tenant. Changing requires superadmin.", "examples": [ 1 ] }, "subtenants_enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Subtenants Enabled", "description": "Whether this tenant may create child tenants. Changing requires superadmin.", "examples": [ false ] }, "timezone": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Timezone", "description": "Default IANA timezone for the tenant.", "examples": [ "Europe/Berlin" ] }, "locale": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Locale", "description": "Default locale for the tenant.", "examples": [ "en-US" ] }, "tarif_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Tarif Id", "description": "ID of the tariff to assign. Changing requires superadmin.", "examples": [ 2 ] }, "tarif_expires_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Tarif Expires At", "description": "UTC timestamp when the assigned tariff expires. Changing requires superadmin.", "examples": [ "2026-12-31T23:59:59Z" ] }, "max_users": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Max Users", "description": "Maximum number of users allowed in the tenant.", "examples": [ 100 ] }, "max_projects": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Max Projects", "description": "Maximum number of projects allowed in the tenant.", "examples": [ 50 ] }, "licenses": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Licenses", "description": "Number of seats/licenses. Changing requires superadmin.", "examples": [ 100 ] }, "display_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Display Name", "description": "Human-friendly display name shown in the UI.", "examples": [ "Acme Corporation" ] }, "motto": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Motto", "description": "Short tagline shown in the tenant's UI.", "examples": [ "Building the future." ] }, "logo_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Logo Url", "description": "URL of the tenant's primary logo.", "examples": [ "https://cdn.example.com/acme/logo.png" ] }, "square_logo_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Square Logo Url", "description": "URL of the tenant's square logo variant.", "examples": [ "https://cdn.example.com/acme/logo-square.png" ] }, "favicon_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Favicon Url", "description": "URL of the tenant's favicon.", "examples": [ "https://cdn.example.com/acme/favicon.ico" ] }, "chat_square_logo_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Chat Square Logo Url", "description": "URL of the square logo shown in the chat UI.", "examples": [ "https://cdn.example.com/acme/chat-logo.png" ] }, "primary_color": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Primary Color", "description": "Primary brand color (hex).", "examples": [ "#1A2B3C" ] }, "secondary_color": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Secondary Color", "description": "Secondary brand color (hex).", "examples": [ "#4D5E6F" ] }, "theme": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Theme", "description": "Name of the UI theme to apply.", "examples": [ "light" ] }, "storage_limit_gb": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Storage Limit Gb", "description": "Storage limit for the tenant, in gigabytes.", "examples": [ 100 ] }, "api_rate_limit": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Api Rate Limit", "description": "API request rate limit for the tenant.", "examples": [ 1000 ] }, "upstream_tenant_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Upstream Tenant Id", "description": "UUID of the upstream identity-provider tenant. Changing requires superadmin.", "examples": [ "3fa85f64-5717-4562-b3fc-2c963f66afa6" ] }, "upstream_oidc_issuer": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Upstream Oidc Issuer", "description": "OIDC issuer URL of the upstream identity provider. Changing requires superadmin.", "examples": [ "https://login.example.com/" ] } }, "type": "object", "title": "TenantUpdateIn" }, "ThemeModeEnum": { "type": "string", "enum": [ "LIGHT", "DARK", "SYSTEM" ], "title": "ThemeModeEnum" }, "TimeseriesPoint": { "properties": { "date": { "type": "string", "title": "Date", "description": "Date of the data point (YYYY-MM-DD).", "examples": [ "2026-01-15" ] }, "cost": { "type": "number", "title": "Cost", "description": "Cost incurred on this date.", "examples": [ 12.34 ] } }, "type": "object", "required": [ "date", "cost" ], "title": "TimeseriesPoint", "description": "Represents a single point in the timeseries data." }, "TimeseriesResponse": { "properties": { "total_cost": { "type": "number", "title": "Total Cost", "description": "Total LLM cost for the current month across all models.", "examples": [ 123.45 ] }, "timeseries": { "additionalProperties": { "items": { "$ref": "#/components/schemas/TimeseriesPoint" }, "type": "array" }, "type": "object", "title": "Timeseries", "description": "Cost timeseries keyed by model name.", "examples": [ { "gpt-4o": [ { "cost": 12.34, "date": "2026-01-15" } ] } ] } }, "type": "object", "required": [ "total_cost", "timeseries" ], "title": "TimeseriesResponse", "description": "Timeseries response model for LLM costs.\nContains total cost for the current month and timeseries data for each model." }, "TokenOut": { "properties": { "access_token": { "type": "string", "title": "Access Token", "description": "Signed JWT access token to send as a Bearer credential.", "examples": [ "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..." ] }, "token_type": { "type": "string", "title": "Token Type", "description": "Token scheme to use in the Authorization header.", "examples": [ "bearer" ] } }, "type": "object", "required": [ "access_token", "token_type" ], "title": "TokenOut" }, "TokenTimeseriesPerModel": { "properties": { "llm_model": { "type": "string", "title": "Llm Model", "description": "Catalog name of the model.", "examples": [ "gpt-4o" ] }, "timeseries": { "additionalProperties": { "items": { "$ref": "#/components/schemas/TokenTimeseriesPoint" }, "type": "array" }, "type": "object", "title": "Timeseries", "description": "Per-metric timeseries keyed by metric name (PromptTokens, CompletionTokens, TotalTokens).", "examples": [ { "TotalTokens": [ { "date": "2026-01-15", "value": 1234.0 } ] } ] } }, "type": "object", "required": [ "llm_model", "timeseries" ], "title": "TokenTimeseriesPerModel", "description": "\"Represents token usage timeseries for a specific LLM model." }, "TokenTimeseriesPoint": { "properties": { "date": { "type": "string", "title": "Date", "description": "Date of the data point (YYYY-MM-DD).", "examples": [ "2026-01-15" ] }, "value": { "type": "number", "title": "Value", "description": "Token count for this date.", "examples": [ 1234.0 ] } }, "type": "object", "required": [ "date", "value" ], "title": "TokenTimeseriesPoint", "description": "Represents a single point in the token timeseries data." }, "TokensPerModel": { "properties": { "llm_model": { "type": "string", "title": "Llm Model", "description": "Catalog name of the model.", "examples": [ "gpt-4o" ] }, "duration": { "type": "string", "title": "Duration", "description": "Window the totals cover.", "examples": [ "monthly" ] }, "total_tokens_count": { "type": "number", "title": "Total Tokens Count", "description": "Total tokens (prompt + completion) in the window.", "examples": [ 12345.0 ] }, "prompt_token_count": { "type": "number", "title": "Prompt Token Count", "description": "Prompt tokens consumed in the window.", "examples": [ 8000.0 ] }, "completion_token_count": { "type": "number", "title": "Completion Token Count", "description": "Completion tokens generated in the window.", "examples": [ 4345.0 ] }, "total_requests": { "type": "number", "title": "Total Requests", "description": "Number of requests in the window.", "examples": [ 42.0 ] } }, "type": "object", "required": [ "llm_model", "duration", "total_tokens_count", "prompt_token_count", "completion_token_count", "total_requests" ], "title": "TokensPerModel", "description": "Model for total tokens of one llm resource." }, "TokensTimeseriesResponse": { "properties": { "total_prompt_tokens": { "type": "number", "title": "Total Prompt Tokens", "description": "Total prompt tokens across all models for the current month.", "examples": [ 80000.0 ] }, "total_completion_tokens": { "type": "number", "title": "Total Completion Tokens", "description": "Total completion tokens across all models for the current month.", "examples": [ 40000.0 ] }, "total_requests": { "type": "number", "title": "Total Requests", "description": "Total requests across all models for the current month.", "examples": [ 420.0 ] }, "total_tokens": { "type": "number", "title": "Total Tokens", "description": "Total tokens (prompt + completion) for the current month.", "examples": [ 120000.0 ] }, "tokens_per_model": { "items": { "$ref": "#/components/schemas/TokensPerModel" }, "type": "array", "title": "Tokens Per Model", "description": "Current-month token summary for each model." }, "timeseries_per_model": { "items": { "$ref": "#/components/schemas/TokenTimeseriesPerModel" }, "type": "array", "title": "Timeseries Per Model", "description": "Token usage timeseries for each model." } }, "type": "object", "required": [ "total_prompt_tokens", "total_completion_tokens", "total_requests", "total_tokens", "tokens_per_model", "timeseries_per_model" ], "title": "TokensTimeseriesResponse", "description": "Response model for LLM tokens with timeseries data." }, "ToolCallOut": { "properties": { "id": { "type": "integer", "title": "Id", "description": "ID of the tool call.", "examples": [ 101 ] }, "call_id": { "type": "string", "title": "Call Id", "description": "Provider-assigned identifier for the tool call.", "examples": [ "call_abc123" ] }, "tool_name": { "type": "string", "title": "Tool Name", "description": "Name of the invoked tool.", "examples": [ "web_search" ] }, "call_group": { "type": "integer", "title": "Call Group", "description": "Group index for tool calls issued together.", "examples": [ 0 ] }, "call_index": { "type": "integer", "title": "Call Index", "description": "Order of the call within its group.", "examples": [ 0 ] }, "state": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "State", "description": "Current state of the tool call.", "examples": [ "completed" ] }, "is_error": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Is Error", "description": "Whether the tool call resulted in an error.", "examples": [ false ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Human-readable description of the tool call.", "examples": [ "Searched the web for recent results." ] }, "progress_steps": { "items": { "$ref": "#/components/schemas/ToolCallProgressStepOut" }, "type": "array", "title": "Progress Steps", "description": "Ordered progress steps emitted during the call.", "examples": [ [] ] } }, "type": "object", "required": [ "id", "call_id", "tool_name", "call_group", "call_index", "state", "is_error", "description", "progress_steps" ], "title": "ToolCallOut" }, "ToolCallProgressStepOut": { "properties": { "name": { "type": "string", "title": "Name", "description": "Name of the progress step.", "examples": [ "search" ] }, "message": { "type": "string", "title": "Message", "description": "Human-readable progress message.", "examples": [ "Searching the knowledge base..." ] }, "step_index": { "type": "integer", "title": "Step Index", "description": "Zero-based order of the step within the tool call.", "examples": [ 0 ] } }, "type": "object", "required": [ "name", "message", "step_index" ], "title": "ToolCallProgressStepOut" }, "ToolOut": { "properties": { "id": { "type": "integer", "title": "Id", "description": "Unique identifier of the tool.", "examples": [ 42 ] }, "name": { "type": "string", "title": "Name", "description": "Human-readable name of the tool.", "examples": [ "Web Search" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Short description of what the tool does.", "examples": [ "Searches the public web for up-to-date information." ] }, "prompt": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Prompt", "description": "Tool prompt/description shown to LLM", "examples": [ "Use this tool to look up current events on the web." ] }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "UTC timestamp when the tool was created.", "examples": [ "2026-01-15T09:30:00Z" ] }, "updated_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Updated At", "description": "UTC timestamp when the tool was last updated, or null if never updated.", "examples": [ "2026-02-20T14:00:00Z" ] } }, "type": "object", "required": [ "id", "name", "description", "prompt", "created_at", "updated_at" ], "title": "ToolOut", "description": "A tool as returned by the API." }, "ToolUpdate": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Human-readable name of the tool.", "examples": [ "Web Search" ] }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Short description of what the tool does.", "examples": [ "Searches the public web for up-to-date information." ] }, "prompt": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Prompt", "description": "Tool prompt/description shown to LLM", "examples": [ "Use this tool to look up current events on the web." ] } }, "type": "object", "title": "ToolUpdate", "description": "Editable fields of a tool; only provided fields are updated." }, "TranscriptionOut": { "properties": { "text": { "type": "string", "title": "Text", "description": "Transcribed text of the audio.", "examples": [ "Hello, this is a test transcription." ] }, "language": { "type": "string", "title": "Language", "description": "Detected language of the audio (ISO 639-1 or language name).", "examples": [ "english" ] }, "duration_seconds": { "type": "number", "title": "Duration Seconds", "description": "Duration of the audio in seconds.", "examples": [ 12.5 ] } }, "type": "object", "required": [ "text", "language", "duration_seconds" ], "title": "TranscriptionOut", "description": "The response format from the transcription endpoint" }, "Translation": { "properties": { "content": { "type": "string", "title": "Content", "description": "The translated or rephrased text.", "examples": [ "Here is the translated content." ] } }, "type": "object", "required": [ "content" ], "title": "Translation" }, "UsageCostRequest": { "properties": { "granularity": { "type": "string", "enum": [ "monthly", "yearly", "custom" ], "title": "Granularity", "description": "Aggregation window; 'custom' requires date_start and date_end.", "default": "monthly", "examples": [ "monthly" ] }, "date_start": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Date Start", "description": "Start of the custom range (used only when granularity is 'custom').", "examples": [ "2026-01-01T00:00:00Z" ] }, "date_end": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Date End", "description": "End of the custom range (used only when granularity is 'custom').", "examples": [ "2026-01-31T23:59:59Z" ] }, "source": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Source", "description": "Filter by usage source (e.g. doc_intelligence, interpreter).", "examples": [ "doc_intelligence" ] }, "model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Model", "description": "Filter by specific model catalog name.", "examples": [ "gpt-4o" ] }, "provider": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Provider", "description": "Filter by provider.", "examples": [ "azure" ] } }, "type": "object", "title": "UsageCostRequest" }, "UsageCostResponse": { "properties": { "start_date": { "type": "string", "format": "date-time", "title": "Start Date", "description": "Start of the aggregation window.", "examples": [ "2026-01-01T00:00:00Z" ] }, "end_date": { "type": "string", "format": "date-time", "title": "End Date", "description": "End of the aggregation window.", "examples": [ "2026-01-31T23:59:59Z" ] }, "total_cost": { "type": "number", "title": "Total Cost", "description": "Total cost across the window.", "examples": [ 123.45 ] }, "total_tokens": { "type": "integer", "title": "Total Tokens", "description": "Total tokens across the window.", "examples": [ 120000 ] }, "total_prompt_tokens": { "type": "integer", "title": "Total Prompt Tokens", "description": "Total prompt tokens across the window.", "examples": [ 80000 ] }, "total_completion_tokens": { "type": "integer", "title": "Total Completion Tokens", "description": "Total completion tokens across the window.", "examples": [ 40000 ] }, "total_cached_tokens": { "type": "integer", "title": "Total Cached Tokens", "description": "Total cached prompt tokens across the window.", "examples": [ 5000 ] }, "record_count": { "type": "integer", "title": "Record Count", "description": "Total number of usage records.", "examples": [ 420 ] }, "by_source": { "items": { "$ref": "#/components/schemas/CostBySource" }, "type": "array", "title": "By Source", "description": "Cost breakdown grouped by source." }, "by_model": { "items": { "$ref": "#/components/schemas/CostByModel" }, "type": "array", "title": "By Model", "description": "Cost breakdown grouped by provider and model." }, "timeseries": { "items": { "$ref": "#/components/schemas/CostTimeseriesPoint" }, "type": "array", "title": "Timeseries", "description": "Daily cost timeseries across the window." } }, "type": "object", "required": [ "start_date", "end_date", "total_cost", "total_tokens", "total_prompt_tokens", "total_completion_tokens", "total_cached_tokens", "record_count", "by_source", "by_model", "timeseries" ], "title": "UsageCostResponse" }, "UsageRequest": { "properties": { "granularity": { "type": "string", "enum": [ "monthly", "yearly", "custom" ], "title": "Granularity", "description": "Aggregation window; 'custom' requires date_start and date_end.", "examples": [ "monthly" ] }, "date_start": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Date Start", "description": "Start of the custom range (used only when granularity is 'custom').", "examples": [ "2026-01-01T00:00:00Z" ] }, "date_end": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Date End", "description": "End of the custom range (used only when granularity is 'custom').", "examples": [ "2026-01-31T23:59:59Z" ] } }, "type": "object", "required": [ "granularity" ], "title": "UsageRequest", "description": "Generic usage request model for both token and cost queries." }, "UserGroup": { "properties": { "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "UTC timestamp when the record was created.", "examples": [ "2026-01-15T10:30:00Z" ] }, "updated_at": { "type": "string", "format": "date-time", "title": "Updated At", "description": "UTC timestamp when the record was last updated.", "examples": [ "2026-01-16T08:00:00Z" ] }, "id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Id", "description": "Primary key for UserGroups." }, "tenant_id": { "type": "integer", "title": "Tenant Id", "description": "ID of the tenant." }, "name": { "type": "string", "title": "Name", "description": "Name of the user group." }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description of the user group." }, "creator_user_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Creator User Id", "description": "ID of the user who created the group." } }, "type": "object", "required": [ "tenant_id", "creator_user_id" ], "title": "UserGroup", "description": "Named group scoped to a tenant." }, "UserGroupMember": { "properties": { "group_id": { "type": "integer", "title": "Group Id", "description": " ID of the user group." }, "user_id": { "type": "integer", "title": "User Id", "description": "ID of the user." }, "tenant_id": { "type": "integer", "title": "Tenant Id", "description": "ID of the tenant." }, "creator_user_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Creator User Id", "description": "ID of the user who created the group." }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "Timestamp when the user group was created." } }, "type": "object", "required": [ "group_id", "user_id", "tenant_id", "creator_user_id" ], "title": "UserGroupMember", "description": "Membership of a user in a group (within a tenant)." }, "UserIn": { "properties": { "first_name": { "type": "string", "title": "First Name", "description": "User's given name.", "examples": [ "Jane" ] }, "last_name": { "type": "string", "title": "Last Name", "description": "User's family name.", "examples": [ "Doe" ] }, "email": { "type": "string", "format": "email", "title": "Email", "description": "Email address used to log in; must be unique.", "examples": [ "jane.doe@example.com" ] }, "password": { "type": "string", "title": "Password", "description": "Initial password; the user is prompted to change it on first login.", "examples": [ "S3cure-P@ssw0rd!" ] }, "admin": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Admin", "description": "Whether the user has tenant administrator privileges.", "examples": [ false ] }, "superadmin": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Superadmin", "description": "Whether the user is a platform operator; requires superadmin to set.", "examples": [ false ] }, "tenant_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Tenant Id", "description": "Tenant to create the user in; defaults to the caller's tenant.", "examples": [ 1 ] } }, "type": "object", "required": [ "first_name", "last_name", "email", "password" ], "title": "UserIn" }, "UserOut": { "properties": { "id": { "type": "integer", "title": "Id", "description": "Unique identifier of the user.", "examples": [ 42 ] }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "UTC timestamp when the user was created.", "examples": [ "2026-01-15T09:30:00Z" ] }, "email": { "type": "string", "format": "email", "title": "Email", "description": "Current confirmed email address.", "examples": [ "jane.doe@example.com" ] }, "email_confirmed": { "type": "boolean", "title": "Email Confirmed", "description": "Whether the email address has been confirmed.", "examples": [ true ] }, "pending_email": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Pending Email", "description": "New email awaiting confirmation, or null if none pending.", "examples": [ "jane.new@example.com" ] }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Full display name, if set.", "examples": [ "Jane Doe" ] }, "first_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "First Name", "description": "User's given name.", "examples": [ "Jane" ] }, "last_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Last Name", "description": "User's family name.", "examples": [ "Doe" ] }, "admin": { "type": "boolean", "title": "Admin", "description": "Whether the user has tenant administrator privileges.", "examples": [ false ] }, "superadmin": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Superadmin", "description": "Whether the user is a platform operator.", "examples": [ false ] }, "active": { "type": "boolean", "title": "Active", "description": "Whether the account is active and can authenticate.", "examples": [ true ] }, "tenant_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Tenant Id", "description": "Identifier of the tenant the user belongs to.", "examples": [ 1 ] } }, "type": "object", "required": [ "id", "created_at", "email", "email_confirmed", "admin", "active" ], "title": "UserOut" }, "UserPreferenceOut": { "properties": { "id": { "type": "integer", "title": "Id", "description": "Unique identifier of the preference record.", "examples": [ 7 ] }, "user_id": { "type": "integer", "title": "User Id", "description": "Identifier of the user these preferences belong to.", "examples": [ 42 ] }, "theme_mode": { "anyOf": [ { "$ref": "#/components/schemas/ThemeModeEnum" }, { "type": "null" } ], "description": "Preferred UI theme mode.", "examples": [ "dark" ] }, "lang": { "anyOf": [ { "type": "string", "pattern": "^\\w{2}$" }, { "type": "null" } ], "title": "Lang", "description": "Preferred language as an ISO 639-1 code.", "examples": [ "en" ] }, "timezone": { "anyOf": [ { "type": "string", "enum": [ "Africa/Abidjan", "Africa/Accra", "Africa/Addis_Ababa", "Africa/Algiers", "Africa/Asmara", "Africa/Asmera", "Africa/Bamako", "Africa/Bangui", "Africa/Banjul", "Africa/Bissau", "Africa/Blantyre", "Africa/Brazzaville", "Africa/Bujumbura", "Africa/Cairo", "Africa/Casablanca", "Africa/Ceuta", "Africa/Conakry", "Africa/Dakar", "Africa/Dar_es_Salaam", "Africa/Djibouti", "Africa/Douala", "Africa/El_Aaiun", "Africa/Freetown", "Africa/Gaborone", "Africa/Harare", "Africa/Johannesburg", "Africa/Juba", "Africa/Kampala", "Africa/Khartoum", "Africa/Kigali", "Africa/Kinshasa", "Africa/Lagos", "Africa/Libreville", "Africa/Lome", "Africa/Luanda", "Africa/Lubumbashi", "Africa/Lusaka", "Africa/Malabo", "Africa/Maputo", "Africa/Maseru", "Africa/Mbabane", "Africa/Mogadishu", "Africa/Monrovia", "Africa/Nairobi", "Africa/Ndjamena", "Africa/Niamey", "Africa/Nouakchott", "Africa/Ouagadougou", "Africa/Porto-Novo", "Africa/Sao_Tome", "Africa/Timbuktu", "Africa/Tripoli", "Africa/Tunis", "Africa/Windhoek", "America/Adak", "America/Anchorage", "America/Anguilla", "America/Antigua", "America/Araguaina", "America/Argentina/Buenos_Aires", "America/Argentina/Catamarca", "America/Argentina/ComodRivadavia", "America/Argentina/Cordoba", "America/Argentina/Jujuy", "America/Argentina/La_Rioja", "America/Argentina/Mendoza", "America/Argentina/Rio_Gallegos", "America/Argentina/Salta", "America/Argentina/San_Juan", "America/Argentina/San_Luis", "America/Argentina/Tucuman", "America/Argentina/Ushuaia", "America/Aruba", "America/Asuncion", "America/Atikokan", "America/Atka", "America/Bahia", "America/Bahia_Banderas", "America/Barbados", "America/Belem", "America/Belize", "America/Blanc-Sablon", "America/Boa_Vista", "America/Bogota", "America/Boise", "America/Buenos_Aires", "America/Cambridge_Bay", "America/Campo_Grande", "America/Cancun", "America/Caracas", "America/Catamarca", "America/Cayenne", "America/Cayman", "America/Chicago", "America/Chihuahua", "America/Ciudad_Juarez", "America/Coral_Harbour", "America/Cordoba", "America/Costa_Rica", "America/Coyhaique", "America/Creston", "America/Cuiaba", "America/Curacao", "America/Danmarkshavn", "America/Dawson", "America/Dawson_Creek", "America/Denver", "America/Detroit", "America/Dominica", "America/Edmonton", "America/Eirunepe", "America/El_Salvador", "America/Ensenada", "America/Fort_Nelson", "America/Fort_Wayne", "America/Fortaleza", "America/Glace_Bay", "America/Godthab", "America/Goose_Bay", "America/Grand_Turk", "America/Grenada", "America/Guadeloupe", "America/Guatemala", "America/Guayaquil", "America/Guyana", "America/Halifax", "America/Havana", "America/Hermosillo", "America/Indiana/Indianapolis", "America/Indiana/Knox", "America/Indiana/Marengo", "America/Indiana/Petersburg", "America/Indiana/Tell_City", "America/Indiana/Vevay", "America/Indiana/Vincennes", "America/Indiana/Winamac", "America/Indianapolis", "America/Inuvik", "America/Iqaluit", "America/Jamaica", "America/Jujuy", "America/Juneau", "America/Kentucky/Louisville", "America/Kentucky/Monticello", "America/Knox_IN", "America/Kralendijk", "America/La_Paz", "America/Lima", "America/Los_Angeles", "America/Louisville", "America/Lower_Princes", "America/Maceio", "America/Managua", "America/Manaus", "America/Marigot", "America/Martinique", "America/Matamoros", "America/Mazatlan", "America/Mendoza", "America/Menominee", "America/Merida", "America/Metlakatla", "America/Mexico_City", "America/Miquelon", "America/Moncton", "America/Monterrey", "America/Montevideo", "America/Montreal", "America/Montserrat", "America/Nassau", "America/New_York", "America/Nipigon", "America/Nome", "America/Noronha", "America/North_Dakota/Beulah", "America/North_Dakota/Center", "America/North_Dakota/New_Salem", "America/Nuuk", "America/Ojinaga", "America/Panama", "America/Pangnirtung", "America/Paramaribo", "America/Phoenix", "America/Port-au-Prince", "America/Port_of_Spain", "America/Porto_Acre", "America/Porto_Velho", "America/Puerto_Rico", "America/Punta_Arenas", "America/Rainy_River", "America/Rankin_Inlet", "America/Recife", "America/Regina", "America/Resolute", "America/Rio_Branco", "America/Rosario", "America/Santa_Isabel", "America/Santarem", "America/Santiago", "America/Santo_Domingo", "America/Sao_Paulo", "America/Scoresbysund", "America/Shiprock", "America/Sitka", "America/St_Barthelemy", "America/St_Johns", "America/St_Kitts", "America/St_Lucia", "America/St_Thomas", "America/St_Vincent", "America/Swift_Current", "America/Tegucigalpa", "America/Thule", "America/Thunder_Bay", "America/Tijuana", "America/Toronto", "America/Tortola", "America/Vancouver", "America/Virgin", "America/Whitehorse", "America/Winnipeg", "America/Yakutat", "America/Yellowknife", "Antarctica/Casey", "Antarctica/Davis", "Antarctica/DumontDUrville", "Antarctica/Macquarie", "Antarctica/Mawson", "Antarctica/McMurdo", "Antarctica/Palmer", "Antarctica/Rothera", "Antarctica/South_Pole", "Antarctica/Syowa", "Antarctica/Troll", "Antarctica/Vostok", "Arctic/Longyearbyen", "Asia/Aden", "Asia/Almaty", "Asia/Amman", "Asia/Anadyr", "Asia/Aqtau", "Asia/Aqtobe", "Asia/Ashgabat", "Asia/Ashkhabad", "Asia/Atyrau", "Asia/Baghdad", "Asia/Bahrain", "Asia/Baku", "Asia/Bangkok", "Asia/Barnaul", "Asia/Beirut", "Asia/Bishkek", "Asia/Brunei", "Asia/Calcutta", "Asia/Chita", "Asia/Choibalsan", "Asia/Chongqing", "Asia/Chungking", "Asia/Colombo", "Asia/Dacca", "Asia/Damascus", "Asia/Dhaka", "Asia/Dili", "Asia/Dubai", "Asia/Dushanbe", "Asia/Famagusta", "Asia/Gaza", "Asia/Harbin", "Asia/Hebron", "Asia/Ho_Chi_Minh", "Asia/Hong_Kong", "Asia/Hovd", "Asia/Irkutsk", "Asia/Istanbul", "Asia/Jakarta", "Asia/Jayapura", "Asia/Jerusalem", "Asia/Kabul", "Asia/Kamchatka", "Asia/Karachi", "Asia/Kashgar", "Asia/Kathmandu", "Asia/Katmandu", "Asia/Khandyga", "Asia/Kolkata", "Asia/Krasnoyarsk", "Asia/Kuala_Lumpur", "Asia/Kuching", "Asia/Kuwait", "Asia/Macao", "Asia/Macau", "Asia/Magadan", "Asia/Makassar", "Asia/Manila", "Asia/Muscat", "Asia/Nicosia", "Asia/Novokuznetsk", "Asia/Novosibirsk", "Asia/Omsk", "Asia/Oral", "Asia/Phnom_Penh", "Asia/Pontianak", "Asia/Pyongyang", "Asia/Qatar", "Asia/Qostanay", "Asia/Qyzylorda", "Asia/Rangoon", "Asia/Riyadh", "Asia/Saigon", "Asia/Sakhalin", "Asia/Samarkand", "Asia/Seoul", "Asia/Shanghai", "Asia/Singapore", "Asia/Srednekolymsk", "Asia/Taipei", "Asia/Tashkent", "Asia/Tbilisi", "Asia/Tehran", "Asia/Tel_Aviv", "Asia/Thimbu", "Asia/Thimphu", "Asia/Tokyo", "Asia/Tomsk", "Asia/Ujung_Pandang", "Asia/Ulaanbaatar", "Asia/Ulan_Bator", "Asia/Urumqi", "Asia/Ust-Nera", "Asia/Vientiane", "Asia/Vladivostok", "Asia/Yakutsk", "Asia/Yangon", "Asia/Yekaterinburg", "Asia/Yerevan", "Atlantic/Azores", "Atlantic/Bermuda", "Atlantic/Canary", "Atlantic/Cape_Verde", "Atlantic/Faeroe", "Atlantic/Faroe", "Atlantic/Jan_Mayen", "Atlantic/Madeira", "Atlantic/Reykjavik", "Atlantic/South_Georgia", "Atlantic/St_Helena", "Atlantic/Stanley", "Australia/ACT", "Australia/Adelaide", "Australia/Brisbane", "Australia/Broken_Hill", "Australia/Canberra", "Australia/Currie", "Australia/Darwin", "Australia/Eucla", "Australia/Hobart", "Australia/LHI", "Australia/Lindeman", "Australia/Lord_Howe", "Australia/Melbourne", "Australia/NSW", "Australia/North", "Australia/Perth", "Australia/Queensland", "Australia/South", "Australia/Sydney", "Australia/Tasmania", "Australia/Victoria", "Australia/West", "Australia/Yancowinna", "Brazil/Acre", "Brazil/DeNoronha", "Brazil/East", "Brazil/West", "CET", "CST6CDT", "Canada/Atlantic", "Canada/Central", "Canada/Eastern", "Canada/Mountain", "Canada/Newfoundland", "Canada/Pacific", "Canada/Saskatchewan", "Canada/Yukon", "Chile/Continental", "Chile/EasterIsland", "Cuba", "EET", "EST", "EST5EDT", "Egypt", "Eire", "Etc/GMT", "Etc/GMT+0", "Etc/GMT+1", "Etc/GMT+10", "Etc/GMT+11", "Etc/GMT+12", "Etc/GMT+2", "Etc/GMT+3", "Etc/GMT+4", "Etc/GMT+5", "Etc/GMT+6", "Etc/GMT+7", "Etc/GMT+8", "Etc/GMT+9", "Etc/GMT-0", "Etc/GMT-1", "Etc/GMT-10", "Etc/GMT-11", "Etc/GMT-12", "Etc/GMT-13", "Etc/GMT-14", "Etc/GMT-2", "Etc/GMT-3", "Etc/GMT-4", "Etc/GMT-5", "Etc/GMT-6", "Etc/GMT-7", "Etc/GMT-8", "Etc/GMT-9", "Etc/GMT0", "Etc/Greenwich", "Etc/UCT", "Etc/UTC", "Etc/Universal", "Etc/Zulu", "Europe/Amsterdam", "Europe/Andorra", "Europe/Astrakhan", "Europe/Athens", "Europe/Belfast", "Europe/Belgrade", "Europe/Berlin", "Europe/Bratislava", "Europe/Brussels", "Europe/Bucharest", "Europe/Budapest", "Europe/Busingen", "Europe/Chisinau", "Europe/Copenhagen", "Europe/Dublin", "Europe/Gibraltar", "Europe/Guernsey", "Europe/Helsinki", "Europe/Isle_of_Man", "Europe/Istanbul", "Europe/Jersey", "Europe/Kaliningrad", "Europe/Kiev", "Europe/Kirov", "Europe/Kyiv", "Europe/Lisbon", "Europe/Ljubljana", "Europe/London", "Europe/Luxembourg", "Europe/Madrid", "Europe/Malta", "Europe/Mariehamn", "Europe/Minsk", "Europe/Monaco", "Europe/Moscow", "Europe/Nicosia", "Europe/Oslo", "Europe/Paris", "Europe/Podgorica", "Europe/Prague", "Europe/Riga", "Europe/Rome", "Europe/Samara", "Europe/San_Marino", "Europe/Sarajevo", "Europe/Saratov", "Europe/Simferopol", "Europe/Skopje", "Europe/Sofia", "Europe/Stockholm", "Europe/Tallinn", "Europe/Tirane", "Europe/Tiraspol", "Europe/Ulyanovsk", "Europe/Uzhgorod", "Europe/Vaduz", "Europe/Vatican", "Europe/Vienna", "Europe/Vilnius", "Europe/Volgograd", "Europe/Warsaw", "Europe/Zagreb", "Europe/Zaporozhye", "Europe/Zurich", "Factory", "GB", "GB-Eire", "GMT", "GMT+0", "GMT-0", "GMT0", "Greenwich", "HST", "Hongkong", "Iceland", "Indian/Antananarivo", "Indian/Chagos", "Indian/Christmas", "Indian/Cocos", "Indian/Comoro", "Indian/Kerguelen", "Indian/Mahe", "Indian/Maldives", "Indian/Mauritius", "Indian/Mayotte", "Indian/Reunion", "Iran", "Israel", "Jamaica", "Japan", "Kwajalein", "Libya", "MET", "MST", "MST7MDT", "Mexico/BajaNorte", "Mexico/BajaSur", "Mexico/General", "NZ", "NZ-CHAT", "Navajo", "PRC", "PST8PDT", "Pacific/Apia", "Pacific/Auckland", "Pacific/Bougainville", "Pacific/Chatham", "Pacific/Chuuk", "Pacific/Easter", "Pacific/Efate", "Pacific/Enderbury", "Pacific/Fakaofo", "Pacific/Fiji", "Pacific/Funafuti", "Pacific/Galapagos", "Pacific/Gambier", "Pacific/Guadalcanal", "Pacific/Guam", "Pacific/Honolulu", "Pacific/Johnston", "Pacific/Kanton", "Pacific/Kiritimati", "Pacific/Kosrae", "Pacific/Kwajalein", "Pacific/Majuro", "Pacific/Marquesas", "Pacific/Midway", "Pacific/Nauru", "Pacific/Niue", "Pacific/Norfolk", "Pacific/Noumea", "Pacific/Pago_Pago", "Pacific/Palau", "Pacific/Pitcairn", "Pacific/Pohnpei", "Pacific/Ponape", "Pacific/Port_Moresby", "Pacific/Rarotonga", "Pacific/Saipan", "Pacific/Samoa", "Pacific/Tahiti", "Pacific/Tarawa", "Pacific/Tongatapu", "Pacific/Truk", "Pacific/Wake", "Pacific/Wallis", "Pacific/Yap", "Poland", "Portugal", "ROC", "ROK", "Singapore", "Turkey", "UCT", "US/Alaska", "US/Aleutian", "US/Arizona", "US/Central", "US/East-Indiana", "US/Eastern", "US/Hawaii", "US/Indiana-Starke", "US/Michigan", "US/Mountain", "US/Pacific", "US/Samoa", "UTC", "Universal", "W-SU", "WET", "Zulu" ], "minLength": 1 }, { "type": "null" } ], "title": "Timezone", "description": "Preferred IANA timezone name.", "examples": [ "Europe/Berlin" ] } }, "type": "object", "required": [ "id", "user_id" ], "title": "UserPreferenceOut" }, "UserPreferenceUpdateIn": { "properties": { "theme_mode": { "anyOf": [ { "$ref": "#/components/schemas/ThemeModeEnum" }, { "type": "null" } ], "description": "Preferred UI theme mode.", "examples": [ "dark" ] }, "lang": { "anyOf": [ { "type": "string", "pattern": "^\\w{2}$" }, { "type": "null" } ], "title": "Lang", "description": "Preferred language as an ISO 639-1 code.", "examples": [ "en" ] }, "timezone": { "anyOf": [ { "type": "string", "enum": [ "Africa/Abidjan", "Africa/Accra", "Africa/Addis_Ababa", "Africa/Algiers", "Africa/Asmara", "Africa/Asmera", "Africa/Bamako", "Africa/Bangui", "Africa/Banjul", "Africa/Bissau", "Africa/Blantyre", "Africa/Brazzaville", "Africa/Bujumbura", "Africa/Cairo", "Africa/Casablanca", "Africa/Ceuta", "Africa/Conakry", "Africa/Dakar", "Africa/Dar_es_Salaam", "Africa/Djibouti", "Africa/Douala", "Africa/El_Aaiun", "Africa/Freetown", "Africa/Gaborone", "Africa/Harare", "Africa/Johannesburg", "Africa/Juba", "Africa/Kampala", "Africa/Khartoum", "Africa/Kigali", "Africa/Kinshasa", "Africa/Lagos", "Africa/Libreville", "Africa/Lome", "Africa/Luanda", "Africa/Lubumbashi", "Africa/Lusaka", "Africa/Malabo", "Africa/Maputo", "Africa/Maseru", "Africa/Mbabane", "Africa/Mogadishu", "Africa/Monrovia", "Africa/Nairobi", "Africa/Ndjamena", "Africa/Niamey", "Africa/Nouakchott", "Africa/Ouagadougou", "Africa/Porto-Novo", "Africa/Sao_Tome", "Africa/Timbuktu", "Africa/Tripoli", "Africa/Tunis", "Africa/Windhoek", "America/Adak", "America/Anchorage", "America/Anguilla", "America/Antigua", "America/Araguaina", "America/Argentina/Buenos_Aires", "America/Argentina/Catamarca", "America/Argentina/ComodRivadavia", "America/Argentina/Cordoba", "America/Argentina/Jujuy", "America/Argentina/La_Rioja", "America/Argentina/Mendoza", "America/Argentina/Rio_Gallegos", "America/Argentina/Salta", "America/Argentina/San_Juan", "America/Argentina/San_Luis", "America/Argentina/Tucuman", "America/Argentina/Ushuaia", "America/Aruba", "America/Asuncion", "America/Atikokan", "America/Atka", "America/Bahia", "America/Bahia_Banderas", "America/Barbados", "America/Belem", "America/Belize", "America/Blanc-Sablon", "America/Boa_Vista", "America/Bogota", "America/Boise", "America/Buenos_Aires", "America/Cambridge_Bay", "America/Campo_Grande", "America/Cancun", "America/Caracas", "America/Catamarca", "America/Cayenne", "America/Cayman", "America/Chicago", "America/Chihuahua", "America/Ciudad_Juarez", "America/Coral_Harbour", "America/Cordoba", "America/Costa_Rica", "America/Coyhaique", "America/Creston", "America/Cuiaba", "America/Curacao", "America/Danmarkshavn", "America/Dawson", "America/Dawson_Creek", "America/Denver", "America/Detroit", "America/Dominica", "America/Edmonton", "America/Eirunepe", "America/El_Salvador", "America/Ensenada", "America/Fort_Nelson", "America/Fort_Wayne", "America/Fortaleza", "America/Glace_Bay", "America/Godthab", "America/Goose_Bay", "America/Grand_Turk", "America/Grenada", "America/Guadeloupe", "America/Guatemala", "America/Guayaquil", "America/Guyana", "America/Halifax", "America/Havana", "America/Hermosillo", "America/Indiana/Indianapolis", "America/Indiana/Knox", "America/Indiana/Marengo", "America/Indiana/Petersburg", "America/Indiana/Tell_City", "America/Indiana/Vevay", "America/Indiana/Vincennes", "America/Indiana/Winamac", "America/Indianapolis", "America/Inuvik", "America/Iqaluit", "America/Jamaica", "America/Jujuy", "America/Juneau", "America/Kentucky/Louisville", "America/Kentucky/Monticello", "America/Knox_IN", "America/Kralendijk", "America/La_Paz", "America/Lima", "America/Los_Angeles", "America/Louisville", "America/Lower_Princes", "America/Maceio", "America/Managua", "America/Manaus", "America/Marigot", "America/Martinique", "America/Matamoros", "America/Mazatlan", "America/Mendoza", "America/Menominee", "America/Merida", "America/Metlakatla", "America/Mexico_City", "America/Miquelon", "America/Moncton", "America/Monterrey", "America/Montevideo", "America/Montreal", "America/Montserrat", "America/Nassau", "America/New_York", "America/Nipigon", "America/Nome", "America/Noronha", "America/North_Dakota/Beulah", "America/North_Dakota/Center", "America/North_Dakota/New_Salem", "America/Nuuk", "America/Ojinaga", "America/Panama", "America/Pangnirtung", "America/Paramaribo", "America/Phoenix", "America/Port-au-Prince", "America/Port_of_Spain", "America/Porto_Acre", "America/Porto_Velho", "America/Puerto_Rico", "America/Punta_Arenas", "America/Rainy_River", "America/Rankin_Inlet", "America/Recife", "America/Regina", "America/Resolute", "America/Rio_Branco", "America/Rosario", "America/Santa_Isabel", "America/Santarem", "America/Santiago", "America/Santo_Domingo", "America/Sao_Paulo", "America/Scoresbysund", "America/Shiprock", "America/Sitka", "America/St_Barthelemy", "America/St_Johns", "America/St_Kitts", "America/St_Lucia", "America/St_Thomas", "America/St_Vincent", "America/Swift_Current", "America/Tegucigalpa", "America/Thule", "America/Thunder_Bay", "America/Tijuana", "America/Toronto", "America/Tortola", "America/Vancouver", "America/Virgin", "America/Whitehorse", "America/Winnipeg", "America/Yakutat", "America/Yellowknife", "Antarctica/Casey", "Antarctica/Davis", "Antarctica/DumontDUrville", "Antarctica/Macquarie", "Antarctica/Mawson", "Antarctica/McMurdo", "Antarctica/Palmer", "Antarctica/Rothera", "Antarctica/South_Pole", "Antarctica/Syowa", "Antarctica/Troll", "Antarctica/Vostok", "Arctic/Longyearbyen", "Asia/Aden", "Asia/Almaty", "Asia/Amman", "Asia/Anadyr", "Asia/Aqtau", "Asia/Aqtobe", "Asia/Ashgabat", "Asia/Ashkhabad", "Asia/Atyrau", "Asia/Baghdad", "Asia/Bahrain", "Asia/Baku", "Asia/Bangkok", "Asia/Barnaul", "Asia/Beirut", "Asia/Bishkek", "Asia/Brunei", "Asia/Calcutta", "Asia/Chita", "Asia/Choibalsan", "Asia/Chongqing", "Asia/Chungking", "Asia/Colombo", "Asia/Dacca", "Asia/Damascus", "Asia/Dhaka", "Asia/Dili", "Asia/Dubai", "Asia/Dushanbe", "Asia/Famagusta", "Asia/Gaza", "Asia/Harbin", "Asia/Hebron", "Asia/Ho_Chi_Minh", "Asia/Hong_Kong", "Asia/Hovd", "Asia/Irkutsk", "Asia/Istanbul", "Asia/Jakarta", "Asia/Jayapura", "Asia/Jerusalem", "Asia/Kabul", "Asia/Kamchatka", "Asia/Karachi", "Asia/Kashgar", "Asia/Kathmandu", "Asia/Katmandu", "Asia/Khandyga", "Asia/Kolkata", "Asia/Krasnoyarsk", "Asia/Kuala_Lumpur", "Asia/Kuching", "Asia/Kuwait", "Asia/Macao", "Asia/Macau", "Asia/Magadan", "Asia/Makassar", "Asia/Manila", "Asia/Muscat", "Asia/Nicosia", "Asia/Novokuznetsk", "Asia/Novosibirsk", "Asia/Omsk", "Asia/Oral", "Asia/Phnom_Penh", "Asia/Pontianak", "Asia/Pyongyang", "Asia/Qatar", "Asia/Qostanay", "Asia/Qyzylorda", "Asia/Rangoon", "Asia/Riyadh", "Asia/Saigon", "Asia/Sakhalin", "Asia/Samarkand", "Asia/Seoul", "Asia/Shanghai", "Asia/Singapore", "Asia/Srednekolymsk", "Asia/Taipei", "Asia/Tashkent", "Asia/Tbilisi", "Asia/Tehran", "Asia/Tel_Aviv", "Asia/Thimbu", "Asia/Thimphu", "Asia/Tokyo", "Asia/Tomsk", "Asia/Ujung_Pandang", "Asia/Ulaanbaatar", "Asia/Ulan_Bator", "Asia/Urumqi", "Asia/Ust-Nera", "Asia/Vientiane", "Asia/Vladivostok", "Asia/Yakutsk", "Asia/Yangon", "Asia/Yekaterinburg", "Asia/Yerevan", "Atlantic/Azores", "Atlantic/Bermuda", "Atlantic/Canary", "Atlantic/Cape_Verde", "Atlantic/Faeroe", "Atlantic/Faroe", "Atlantic/Jan_Mayen", "Atlantic/Madeira", "Atlantic/Reykjavik", "Atlantic/South_Georgia", "Atlantic/St_Helena", "Atlantic/Stanley", "Australia/ACT", "Australia/Adelaide", "Australia/Brisbane", "Australia/Broken_Hill", "Australia/Canberra", "Australia/Currie", "Australia/Darwin", "Australia/Eucla", "Australia/Hobart", "Australia/LHI", "Australia/Lindeman", "Australia/Lord_Howe", "Australia/Melbourne", "Australia/NSW", "Australia/North", "Australia/Perth", "Australia/Queensland", "Australia/South", "Australia/Sydney", "Australia/Tasmania", "Australia/Victoria", "Australia/West", "Australia/Yancowinna", "Brazil/Acre", "Brazil/DeNoronha", "Brazil/East", "Brazil/West", "CET", "CST6CDT", "Canada/Atlantic", "Canada/Central", "Canada/Eastern", "Canada/Mountain", "Canada/Newfoundland", "Canada/Pacific", "Canada/Saskatchewan", "Canada/Yukon", "Chile/Continental", "Chile/EasterIsland", "Cuba", "EET", "EST", "EST5EDT", "Egypt", "Eire", "Etc/GMT", "Etc/GMT+0", "Etc/GMT+1", "Etc/GMT+10", "Etc/GMT+11", "Etc/GMT+12", "Etc/GMT+2", "Etc/GMT+3", "Etc/GMT+4", "Etc/GMT+5", "Etc/GMT+6", "Etc/GMT+7", "Etc/GMT+8", "Etc/GMT+9", "Etc/GMT-0", "Etc/GMT-1", "Etc/GMT-10", "Etc/GMT-11", "Etc/GMT-12", "Etc/GMT-13", "Etc/GMT-14", "Etc/GMT-2", "Etc/GMT-3", "Etc/GMT-4", "Etc/GMT-5", "Etc/GMT-6", "Etc/GMT-7", "Etc/GMT-8", "Etc/GMT-9", "Etc/GMT0", "Etc/Greenwich", "Etc/UCT", "Etc/UTC", "Etc/Universal", "Etc/Zulu", "Europe/Amsterdam", "Europe/Andorra", "Europe/Astrakhan", "Europe/Athens", "Europe/Belfast", "Europe/Belgrade", "Europe/Berlin", "Europe/Bratislava", "Europe/Brussels", "Europe/Bucharest", "Europe/Budapest", "Europe/Busingen", "Europe/Chisinau", "Europe/Copenhagen", "Europe/Dublin", "Europe/Gibraltar", "Europe/Guernsey", "Europe/Helsinki", "Europe/Isle_of_Man", "Europe/Istanbul", "Europe/Jersey", "Europe/Kaliningrad", "Europe/Kiev", "Europe/Kirov", "Europe/Kyiv", "Europe/Lisbon", "Europe/Ljubljana", "Europe/London", "Europe/Luxembourg", "Europe/Madrid", "Europe/Malta", "Europe/Mariehamn", "Europe/Minsk", "Europe/Monaco", "Europe/Moscow", "Europe/Nicosia", "Europe/Oslo", "Europe/Paris", "Europe/Podgorica", "Europe/Prague", "Europe/Riga", "Europe/Rome", "Europe/Samara", "Europe/San_Marino", "Europe/Sarajevo", "Europe/Saratov", "Europe/Simferopol", "Europe/Skopje", "Europe/Sofia", "Europe/Stockholm", "Europe/Tallinn", "Europe/Tirane", "Europe/Tiraspol", "Europe/Ulyanovsk", "Europe/Uzhgorod", "Europe/Vaduz", "Europe/Vatican", "Europe/Vienna", "Europe/Vilnius", "Europe/Volgograd", "Europe/Warsaw", "Europe/Zagreb", "Europe/Zaporozhye", "Europe/Zurich", "Factory", "GB", "GB-Eire", "GMT", "GMT+0", "GMT-0", "GMT0", "Greenwich", "HST", "Hongkong", "Iceland", "Indian/Antananarivo", "Indian/Chagos", "Indian/Christmas", "Indian/Cocos", "Indian/Comoro", "Indian/Kerguelen", "Indian/Mahe", "Indian/Maldives", "Indian/Mauritius", "Indian/Mayotte", "Indian/Reunion", "Iran", "Israel", "Jamaica", "Japan", "Kwajalein", "Libya", "MET", "MST", "MST7MDT", "Mexico/BajaNorte", "Mexico/BajaSur", "Mexico/General", "NZ", "NZ-CHAT", "Navajo", "PRC", "PST8PDT", "Pacific/Apia", "Pacific/Auckland", "Pacific/Bougainville", "Pacific/Chatham", "Pacific/Chuuk", "Pacific/Easter", "Pacific/Efate", "Pacific/Enderbury", "Pacific/Fakaofo", "Pacific/Fiji", "Pacific/Funafuti", "Pacific/Galapagos", "Pacific/Gambier", "Pacific/Guadalcanal", "Pacific/Guam", "Pacific/Honolulu", "Pacific/Johnston", "Pacific/Kanton", "Pacific/Kiritimati", "Pacific/Kosrae", "Pacific/Kwajalein", "Pacific/Majuro", "Pacific/Marquesas", "Pacific/Midway", "Pacific/Nauru", "Pacific/Niue", "Pacific/Norfolk", "Pacific/Noumea", "Pacific/Pago_Pago", "Pacific/Palau", "Pacific/Pitcairn", "Pacific/Pohnpei", "Pacific/Ponape", "Pacific/Port_Moresby", "Pacific/Rarotonga", "Pacific/Saipan", "Pacific/Samoa", "Pacific/Tahiti", "Pacific/Tarawa", "Pacific/Tongatapu", "Pacific/Truk", "Pacific/Wake", "Pacific/Wallis", "Pacific/Yap", "Poland", "Portugal", "ROC", "ROK", "Singapore", "Turkey", "UCT", "US/Alaska", "US/Aleutian", "US/Arizona", "US/Central", "US/East-Indiana", "US/Eastern", "US/Hawaii", "US/Indiana-Starke", "US/Michigan", "US/Mountain", "US/Pacific", "US/Samoa", "UTC", "Universal", "W-SU", "WET", "Zulu" ], "minLength": 1 }, { "type": "null" } ], "title": "Timezone", "description": "Preferred IANA timezone name.", "examples": [ "Europe/Berlin" ] } }, "type": "object", "title": "UserPreferenceUpdateIn" }, "UserUpdateIn": { "properties": { "first_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "First Name", "description": "New given name.", "examples": [ "Jane" ] }, "last_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Last Name", "description": "New family name.", "examples": [ "Doe" ] }, "email": { "anyOf": [ { "type": "string", "format": "email" }, { "type": "null" } ], "title": "Email", "description": "New email address; triggers a confirmation flow.", "examples": [ "jane.doe@example.com" ] }, "password": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Password", "description": "New password; cannot be set for your own account here.", "examples": [ "S3cure-P@ssw0rd!" ] }, "admin": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Admin", "description": "Whether the user has tenant administrator privileges.", "examples": [ false ] }, "superadmin": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Superadmin", "description": "Whether the user is a platform operator; requires superadmin to change.", "examples": [ false ] }, "tenant_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Tenant Id", "description": "Move the user to this tenant; requires appropriate privileges.", "examples": [ 1 ] } }, "type": "object", "title": "UserUpdateIn" }, "ValidationError": { "properties": { "loc": { "items": { "anyOf": [ { "type": "string" }, { "type": "integer" } ] }, "type": "array", "title": "Location" }, "msg": { "type": "string", "title": "Message" }, "type": { "type": "string", "title": "Error Type" }, "input": { "title": "Input" }, "ctx": { "type": "object", "title": "Context" } }, "type": "object", "required": [ "loc", "msg", "type" ], "title": "ValidationError" } }, "securitySchemes": { "APIKeyHeader": { "type": "apiKey", "description": "Api key to access backend from external services", "in": "header", "name": "X-API-KEY" } } }, "tags": [ { "name": "Auth", "description": "Authentication: login, tokens, password reset, and SSO callbacks." }, { "name": "AuthConnector", "description": "OAuth connector authorization flows linking a user to external providers." }, { "name": "User", "description": "User accounts, profiles, and account management." }, { "name": "Invitation", "description": "Invite users to a tenant and manage pending invitations." }, { "name": "Tenant", "description": "Tenant (organization) configuration, theming, and membership." }, { "name": "Project", "description": "Projects that group chats, documents, and related resources." }, { "name": "Chat", "description": "Conversations between users and assistants." }, { "name": "Message", "description": "Messages within a chat, including assistant responses." }, { "name": "Query", "description": "Retrieval-augmented queries over indexed documents." }, { "name": "Document", "description": "Upload, index, and manage documents used for retrieval." }, { "name": "Library", "description": "Document libraries: collections of documents and their settings." }, { "name": "File", "description": "Raw file upload, download, and management." }, { "name": "Storage", "description": "Storage backend operations and file persistence." }, { "name": "Tag", "description": "Tags for organizing and filtering resources." }, { "name": "Assistant", "description": "Configurable AI assistants and their behaviour." }, { "name": "Prompt", "description": "Reusable prompts and prompt management." }, { "name": "Template", "description": "Shared templates (admin-managed)." }, { "name": "Tool", "description": "Tools that assistants can invoke." }, { "name": "ToolAction", "description": "Execution of specific tool actions (e.g. sending mail)." }, { "name": "Llm", "description": "LLM token usage and cost tracking." }, { "name": "LlmCatalog", "description": "Catalog of available LLM models." }, { "name": "LlmSetting", "description": "LLM configuration and per-tenant model settings." }, { "name": "Transcription", "description": "Audio transcription endpoints." }, { "name": "Sharepoint", "description": "Legacy SharePoint integration (retained for backward compatibility)." }, { "name": "Sharepoint v1", "description": "SharePoint data source: browse and connect via the data-source abstraction." }, { "name": "OneDrive", "description": "OneDrive data source: browse and connect." }, { "name": "Atlassian", "description": "Atlassian (Confluence/Jira) integration." }, { "name": "Application", "description": "Application-level configuration and metadata." }, { "name": "ApiKey", "description": "Programmatic API keys for authenticating SDK and server-to-server calls." }, { "name": "Tarif", "description": "Tariff / pricing plans and their definitions." }, { "name": "Alert", "description": "Budget alerts and spend notifications." }, { "name": "Settings", "description": "User and workspace settings." }, { "name": "System", "description": "System-level configuration and status." } ], "servers": [ { "url": "https://api.your-domain.com" } ] }