diff --git a/ai-hub/docs/api_reference/agent-nodes.md b/ai-hub/docs/api_reference/agent-nodes.md index f08a24c..10db238 100644 --- a/ai-hub/docs/api_reference/agent-nodes.md +++ b/ai-hub/docs/api_reference/agent-nodes.md @@ -1,6 +1,6 @@ # API Reference: Agent Nodes -## POST `/nodes/admin` +## POST `/api/v1/nodes/admin` **Summary:** [Admin] Register New Node @@ -32,7 +32,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/nodes/admin?admin_id=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/admin?admin_id=' \ -H 'accept: application/json' \ -H 'Content-Type: application/json' \ -d '{}' @@ -40,7 +40,7 @@ --- -## GET `/nodes/admin` +## GET `/api/v1/nodes/admin` **Summary:** [Admin] List All Nodes @@ -63,13 +63,13 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/nodes/admin?admin_id=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/admin?admin_id=' \ -H 'accept: application/json' ``` --- -## GET `/nodes/admin/{node_id}` +## GET `/api/v1/nodes/admin/{node_id}` **Summary:** [Admin] Get Node Detail @@ -93,13 +93,13 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/nodes/admin/{node_id}?admin_id=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/admin/{node_id}?admin_id=' \ -H 'accept: application/json' ``` --- -## PATCH `/nodes/admin/{node_id}` +## PATCH `/api/v1/nodes/admin/{node_id}` **Summary:** [Admin] Update Node Config @@ -130,7 +130,7 @@ ```bash curl -X 'PATCH' \ - 'http://localhost:8000/api/v1/nodes/admin/{node_id}?admin_id=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/admin/{node_id}?admin_id=' \ -H 'accept: application/json' \ -H 'Content-Type: application/json' \ -d '{}' @@ -138,7 +138,7 @@ --- -## DELETE `/nodes/admin/{node_id}` +## DELETE `/api/v1/nodes/admin/{node_id}` **Summary:** [Admin] Deregister Node @@ -162,13 +162,13 @@ ```bash curl -X 'DELETE' \ - 'http://localhost:8000/api/v1/nodes/admin/{node_id}?admin_id=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/admin/{node_id}?admin_id=' \ -H 'accept: application/json' ``` --- -## POST `/nodes/admin/{node_id}/access` +## POST `/api/v1/nodes/admin/{node_id}/access` **Summary:** [Admin] Grant Group Access @@ -199,7 +199,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/nodes/admin/{node_id}/access?admin_id=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/admin/{node_id}/access?admin_id=' \ -H 'accept: application/json' \ -H 'Content-Type: application/json' \ -d '{}' @@ -207,7 +207,7 @@ --- -## DELETE `/nodes/admin/{node_id}/access/{group_id}` +## DELETE `/api/v1/nodes/admin/{node_id}/access/{group_id}` **Summary:** [Admin] Revoke Group Access @@ -232,13 +232,13 @@ ```bash curl -X 'DELETE' \ - 'http://localhost:8000/api/v1/nodes/admin/{node_id}/access/{group_id}?admin_id=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/admin/{node_id}/access/{group_id}?admin_id=' \ -H 'accept: application/json' ``` --- -## POST `/nodes/admin/mesh/reset` +## POST `/api/v1/nodes/admin/mesh/reset` **Summary:** [Admin] Emergency Mesh Reset @@ -262,13 +262,13 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/nodes/admin/mesh/reset?admin_id=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/admin/mesh/reset?admin_id=' \ -H 'accept: application/json' ``` --- -## GET `/nodes/` +## GET `/api/v1/nodes/` **Summary:** List Accessible Nodes @@ -292,13 +292,13 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/nodes/?user_id=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/?user_id=' \ -H 'accept: application/json' ``` --- -## GET `/nodes/{node_id}/status` +## GET `/api/v1/nodes/{node_id}/status` **Summary:** Quick Node Online Check @@ -322,14 +322,14 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/nodes/{node_id}/status' \ + 'http://localhost:8000/api/v1/api/v1/nodes/{node_id}/status' \ -H 'accept: application/json' \ -H 'X-User-ID: ' ``` --- -## GET `/nodes/{node_id}/terminal` +## GET `/api/v1/nodes/{node_id}/terminal` **Summary:** Read Node Terminal History (AI Use Case) @@ -354,14 +354,14 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/nodes/{node_id}/terminal' \ + 'http://localhost:8000/api/v1/api/v1/nodes/{node_id}/terminal' \ -H 'accept: application/json' \ -H 'X-User-ID: ' ``` --- -## POST `/nodes/{node_id}/dispatch` +## POST `/api/v1/nodes/{node_id}/dispatch` **Summary:** Dispatch Task to Node @@ -393,7 +393,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/nodes/{node_id}/dispatch?user_id=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/{node_id}/dispatch?user_id=' \ -H 'accept: application/json' \ -H 'Content-Type: application/json' \ -d '{}' @@ -401,7 +401,7 @@ --- -## POST `/nodes/{node_id}/cancel` +## POST `/api/v1/nodes/{node_id}/cancel` **Summary:** Cancel/Interrupt Task on Node @@ -427,14 +427,14 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/nodes/{node_id}/cancel?task_id=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/{node_id}/cancel?task_id=' \ -H 'accept: application/json' \ -H 'X-User-ID: ' ``` --- -## PATCH `/nodes/preferences` +## PATCH `/api/v1/nodes/preferences` **Summary:** Update User Node Preferences @@ -465,7 +465,7 @@ ```bash curl -X 'PATCH' \ - 'http://localhost:8000/api/v1/nodes/preferences?user_id=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/preferences?user_id=' \ -H 'accept: application/json' \ -H 'Content-Type: application/json' \ -d '{}' @@ -473,7 +473,7 @@ --- -## GET `/nodes/preferences` +## GET `/api/v1/nodes/preferences` **Summary:** Get User Node Preferences @@ -496,13 +496,13 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/nodes/preferences?user_id=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/preferences?user_id=' \ -H 'accept: application/json' ``` --- -## GET `/nodes/admin/{node_id}/config.yaml` +## GET `/api/v1/nodes/admin/{node_id}/config.yaml` **Summary:** [Admin] Download Node Config YAML @@ -527,13 +527,13 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/nodes/admin/{node_id}/config.yaml?admin_id=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/admin/{node_id}/config.yaml?admin_id=' \ -H 'accept: application/json' ``` --- -## GET `/nodes/provision/{node_id}` +## GET `/api/v1/nodes/provision/{node_id}` **Summary:** Headless Provisioning Script @@ -560,13 +560,13 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/nodes/provision/{node_id}?token=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/provision/{node_id}?token=' \ -H 'accept: application/json' ``` --- -## GET `/nodes/admin/{node_id}/download` +## GET `/api/v1/nodes/admin/{node_id}/download` **Summary:** [Admin] Download Agent Node Bundle (ZIP) @@ -591,13 +591,13 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/nodes/admin/{node_id}/download?admin_id=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/admin/{node_id}/download?admin_id=' \ -H 'accept: application/json' ``` --- -## POST `/nodes/validate-token` +## POST `/api/v1/nodes/validate-token` **Summary:** [Internal] Validate Node Invite Token @@ -629,13 +629,13 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/nodes/validate-token?token=&node_id=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/validate-token?token=&node_id=' \ -H 'accept: application/json' ``` --- -## GET `/nodes/{node_id}/fs/ls` +## GET `/api/v1/nodes/{node_id}/fs/ls` **Summary:** List Directory Content @@ -662,14 +662,14 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/nodes/{node_id}/fs/ls?path=&session_id=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/{node_id}/fs/ls?path=&session_id=' \ -H 'accept: application/json' \ -H 'X-User-ID: ' ``` --- -## GET `/nodes/{node_id}/fs/cat` +## GET `/api/v1/nodes/{node_id}/fs/cat` **Summary:** Read File Content @@ -695,14 +695,14 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/nodes/{node_id}/fs/cat?path=&session_id=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/{node_id}/fs/cat?path=&session_id=' \ -H 'accept: application/json' \ -H 'X-User-ID: ' ``` --- -## POST `/nodes/{node_id}/fs/touch` +## POST `/api/v1/nodes/{node_id}/fs/touch` **Summary:** Create File or Directory @@ -733,7 +733,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/nodes/{node_id}/fs/touch' \ + 'http://localhost:8000/api/v1/api/v1/nodes/{node_id}/fs/touch' \ -H 'accept: application/json' \ -H 'X-User-ID: ' \ -H 'Content-Type: application/json' \ @@ -742,7 +742,7 @@ --- -## GET `/nodes/{node_id}/fs/download` +## GET `/api/v1/nodes/{node_id}/fs/download` **Summary:** Download File @@ -769,14 +769,14 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/nodes/{node_id}/fs/download?path=&session_id=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/{node_id}/fs/download?path=&session_id=' \ -H 'accept: application/json' \ -H 'X-User-ID: ' ``` --- -## POST `/nodes/{node_id}/fs/upload` +## POST `/api/v1/nodes/{node_id}/fs/upload` **Summary:** Upload File @@ -796,7 +796,7 @@ **Required:** Yes - **Media Type:** `multipart/form-data` -- **Schema:** `Body_fs_upload_nodes__node_id__fs_upload_post` (Define in Models) +- **Schema:** `Body_fs_upload_api_v1_nodes__node_id__fs_upload_post` (Define in Models) #### Responses @@ -809,7 +809,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/nodes/{node_id}/fs/upload?path=&session_id=' \ + 'http://localhost:8000/api/v1/api/v1/nodes/{node_id}/fs/upload?path=&session_id=' \ -H 'accept: application/json' \ -H 'X-User-ID: ' \ -H 'Content-Type: multipart/form-data' \ @@ -818,7 +818,7 @@ --- -## POST `/nodes/{node_id}/fs/rm` +## POST `/api/v1/nodes/{node_id}/fs/rm` **Summary:** Delete File/Directory @@ -849,7 +849,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/nodes/{node_id}/fs/rm' \ + 'http://localhost:8000/api/v1/api/v1/nodes/{node_id}/fs/rm' \ -H 'accept: application/json' \ -H 'X-User-ID: ' \ -H 'Content-Type: application/json' \ diff --git a/ai-hub/docs/api_reference/agent-update.md b/ai-hub/docs/api_reference/agent-update.md index 9c7a29c..678fe81 100644 --- a/ai-hub/docs/api_reference/agent-update.md +++ b/ai-hub/docs/api_reference/agent-update.md @@ -1,6 +1,6 @@ # API Reference: Agent Update -## GET `/agent/version` +## GET `/api/v1/agent/version` **Summary:** Get current agent version @@ -17,13 +17,13 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/agent/version' \ + 'http://localhost:8000/api/v1/api/v1/agent/version' \ -H 'accept: application/json' ``` --- -## GET `/agent/download` +## GET `/api/v1/agent/download` **Summary:** Download agent node tarball @@ -40,13 +40,13 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/agent/download' \ + 'http://localhost:8000/api/v1/api/v1/agent/download' \ -H 'accept: application/json' ``` --- -## GET `/agent/installer` +## GET `/api/v1/agent/installer` **Summary:** Download bootstrap_installer.py @@ -63,7 +63,7 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/agent/installer' \ + 'http://localhost:8000/api/v1/api/v1/agent/installer' \ -H 'accept: application/json' ``` diff --git a/ai-hub/docs/api_reference/agents.md b/ai-hub/docs/api_reference/agents.md new file mode 100644 index 0000000..1453e28 --- /dev/null +++ b/ai-hub/docs/api_reference/agents.md @@ -0,0 +1,418 @@ +# API Reference: Agents + +## GET `/api/v1/agents` + +**Summary:** Get Agents + +**Description:** Get Agents + +#### Responses + +| Status Code | Description | +|-------------|-------------| +| `200` | Successful Response | + +#### Example Usage + +```bash +curl -X 'GET' \ + 'http://localhost:8000/api/v1/api/v1/agents' \ + -H 'accept: application/json' +``` + +--- + +## POST `/api/v1/agents/templates` + +**Summary:** Create Template + +**Description:** Create Template + +#### Request Body + +**Required:** Yes + +- **Media Type:** `application/json` +- **Schema:** `AgentTemplateCreate` (Define in Models) + +#### Responses + +| Status Code | Description | +|-------------|-------------| +| `200` | Successful Response | +| `422` | Validation Error | + +#### Example Usage + +```bash +curl -X 'POST' \ + 'http://localhost:8000/api/v1/api/v1/agents/templates' \ + -H 'accept: application/json' \ + -H 'Content-Type: application/json' \ + -d '{}' +``` + +--- + +## POST `/api/v1/agents/instances` + +**Summary:** Create Instance + +**Description:** Create Instance + +#### Request Body + +**Required:** Yes + +- **Media Type:** `application/json` +- **Schema:** `AgentInstanceCreate` (Define in Models) + +#### Responses + +| Status Code | Description | +|-------------|-------------| +| `200` | Successful Response | +| `422` | Validation Error | + +#### Example Usage + +```bash +curl -X 'POST' \ + 'http://localhost:8000/api/v1/api/v1/agents/instances' \ + -H 'accept: application/json' \ + -H 'Content-Type: application/json' \ + -d '{}' +``` + +--- + +## PATCH `/api/v1/agents/{id}/status` + +**Summary:** Update Status + +**Description:** Update Status + +#### Parameters + +| Name | In | Required | Type | Description | +|------|----|----------|------|-------------| +| `id` | path | Yes | string | | + +#### Request Body + +**Required:** Yes + +- **Media Type:** `application/json` +- **Schema:** `AgentInstanceStatusUpdate` (Define in Models) + +#### Responses + +| Status Code | Description | +|-------------|-------------| +| `200` | Successful Response | +| `422` | Validation Error | + +#### Example Usage + +```bash +curl -X 'PATCH' \ + 'http://localhost:8000/api/v1/api/v1/agents/{id}/status' \ + -H 'accept: application/json' \ + -H 'Content-Type: application/json' \ + -d '{}' +``` + +--- + +## PATCH `/api/v1/agents/{id}/config` + +**Summary:** Update Config + +**Description:** Update Config + +#### Parameters + +| Name | In | Required | Type | Description | +|------|----|----------|------|-------------| +| `id` | path | Yes | string | | + +#### Request Body + +**Required:** Yes + +- **Media Type:** `application/json` +- **Schema:** `AgentConfigUpdate` (Define in Models) + +#### Responses + +| Status Code | Description | +|-------------|-------------| +| `200` | Successful Response | +| `422` | Validation Error | + +#### Example Usage + +```bash +curl -X 'PATCH' \ + 'http://localhost:8000/api/v1/api/v1/agents/{id}/config' \ + -H 'accept: application/json' \ + -H 'Content-Type: application/json' \ + -d '{}' +``` + +--- + +## POST `/api/v1/agents/{id}/webhook` + +**Summary:** Webhook Receiver + +**Description:** Webhook Receiver + +#### Parameters + +| Name | In | Required | Type | Description | +|------|----|----------|------|-------------| +| `id` | path | Yes | string | | +| `token` | query | No | string | | + +#### Request Body + +**Required:** Yes + +- **Media Type:** `application/json` + +#### Responses + +| Status Code | Description | +|-------------|-------------| +| `202` | Successful Response | +| `422` | Validation Error | + +#### Example Usage + +```bash +curl -X 'POST' \ + 'http://localhost:8000/api/v1/api/v1/agents/{id}/webhook?token=' \ + -H 'accept: application/json' \ + -H 'Content-Type: application/json' \ + -d '{}' +``` + +--- + +## GET `/api/v1/agents/{id}/triggers` + +**Summary:** Get Agent Triggers + +**Description:** Get Agent Triggers + +#### Parameters + +| Name | In | Required | Type | Description | +|------|----|----------|------|-------------| +| `id` | path | Yes | string | | + +#### Responses + +| Status Code | Description | +|-------------|-------------| +| `200` | Successful Response | +| `422` | Validation Error | + +#### Example Usage + +```bash +curl -X 'GET' \ + 'http://localhost:8000/api/v1/api/v1/agents/{id}/triggers' \ + -H 'accept: application/json' +``` + +--- + +## POST `/api/v1/agents/{id}/triggers` + +**Summary:** Create Agent Trigger + +**Description:** Create Agent Trigger + +#### Parameters + +| Name | In | Required | Type | Description | +|------|----|----------|------|-------------| +| `id` | path | Yes | string | | + +#### Request Body + +**Required:** Yes + +- **Media Type:** `application/json` +- **Schema:** `AgentTriggerCreate` (Define in Models) + +#### Responses + +| Status Code | Description | +|-------------|-------------| +| `200` | Successful Response | +| `422` | Validation Error | + +#### Example Usage + +```bash +curl -X 'POST' \ + 'http://localhost:8000/api/v1/api/v1/agents/{id}/triggers' \ + -H 'accept: application/json' \ + -H 'Content-Type: application/json' \ + -d '{}' +``` + +--- + +## DELETE `/api/v1/agents/triggers/{trigger_id}` + +**Summary:** Delete Agent Trigger + +**Description:** Delete Agent Trigger + +#### Parameters + +| Name | In | Required | Type | Description | +|------|----|----------|------|-------------| +| `trigger_id` | path | Yes | string | | + +#### Responses + +| Status Code | Description | +|-------------|-------------| +| `200` | Successful Response | +| `422` | Validation Error | + +#### Example Usage + +```bash +curl -X 'DELETE' \ + 'http://localhost:8000/api/v1/api/v1/agents/triggers/{trigger_id}' \ + -H 'accept: application/json' +``` + +--- + +## GET `/api/v1/agents/{id}/telemetry` + +**Summary:** Get Telemetry + +**Description:** Get Telemetry + +#### Parameters + +| Name | In | Required | Type | Description | +|------|----|----------|------|-------------| +| `id` | path | Yes | string | | + +#### Responses + +| Status Code | Description | +|-------------|-------------| +| `200` | Successful Response | +| `422` | Validation Error | + +#### Example Usage + +```bash +curl -X 'GET' \ + 'http://localhost:8000/api/v1/api/v1/agents/{id}/telemetry' \ + -H 'accept: application/json' +``` + +--- + +## GET `/api/v1/agents/{id}/dependencies` + +**Summary:** Get Dependencies + +**Description:** Get Dependencies + +#### Parameters + +| Name | In | Required | Type | Description | +|------|----|----------|------|-------------| +| `id` | path | Yes | string | | + +#### Responses + +| Status Code | Description | +|-------------|-------------| +| `200` | Successful Response | +| `422` | Validation Error | + +#### Example Usage + +```bash +curl -X 'GET' \ + 'http://localhost:8000/api/v1/api/v1/agents/{id}/dependencies' \ + -H 'accept: application/json' +``` + +--- + +## POST `/api/v1/agents/deploy` + +**Summary:** Deploy Agent + +**Description:** One-click agent deployment (Design Doc CUJ 1). +Atomically creates: Template → Session → Instance → Locks Session → Injects initial prompt → Starts loop. + +#### Request Body + +**Required:** Yes + +- **Media Type:** `application/json` +- **Schema:** `DeployAgentRequest` (Define in Models) + +#### Responses + +| Status Code | Description | +|-------------|-------------| +| `200` | Successful Response | +| `422` | Validation Error | + +#### Example Usage + +```bash +curl -X 'POST' \ + 'http://localhost:8000/api/v1/api/v1/agents/deploy' \ + -H 'accept: application/json' \ + -H 'Content-Type: application/json' \ + -d '{}' +``` + +--- + +## DELETE `/api/v1/agents/{id}` + +**Summary:** Delete Agent + +**Description:** Delete Agent + +#### Parameters + +| Name | In | Required | Type | Description | +|------|----|----------|------|-------------| +| `id` | path | Yes | string | | + +#### Responses + +| Status Code | Description | +|-------------|-------------| +| `200` | Successful Response | +| `422` | Validation Error | + +#### Example Usage + +```bash +curl -X 'DELETE' \ + 'http://localhost:8000/api/v1/api/v1/agents/{id}' \ + -H 'accept: application/json' +``` + +--- + diff --git a/ai-hub/docs/api_reference/api.md b/ai-hub/docs/api_reference/api.md new file mode 100644 index 0000000..41c4cda --- /dev/null +++ b/ai-hub/docs/api_reference/api.md @@ -0,0 +1,256 @@ +# API Reference: Api + +## PUT `/api/v1/admin/config/oidc` + +**Summary:** Update OIDC Configuration + +**Description:** Update OIDC Configuration + +#### Parameters + +| Name | In | Required | Type | Description | +|------|----|----------|------|-------------| +| `x-user-id` | header | No | anyOf | | + +#### Request Body + +**Required:** Yes + +- **Media Type:** `application/json` +- **Schema:** `OIDCConfigUpdate` (Define in Models) + +#### Responses + +| Status Code | Description | +|-------------|-------------| +| `200` | Successful Response | +| `422` | Validation Error | + +#### Example Usage + +```bash +curl -X 'PUT' \ + 'http://localhost:8000/api/v1/api/v1/admin/config/oidc' \ + -H 'accept: application/json' \ + -H 'X-User-ID: ' \ + -H 'Content-Type: application/json' \ + -d '{}' +``` + +--- + +## PUT `/api/v1/admin/config/app` + +**Summary:** Update Application Configuration + +**Description:** Update Application Configuration + +#### Parameters + +| Name | In | Required | Type | Description | +|------|----|----------|------|-------------| +| `x-user-id` | header | No | anyOf | | + +#### Request Body + +**Required:** Yes + +- **Media Type:** `application/json` +- **Schema:** `AppConfigUpdate` (Define in Models) + +#### Responses + +| Status Code | Description | +|-------------|-------------| +| `200` | Successful Response | +| `422` | Validation Error | + +#### Example Usage + +```bash +curl -X 'PUT' \ + 'http://localhost:8000/api/v1/api/v1/admin/config/app' \ + -H 'accept: application/json' \ + -H 'X-User-ID: ' \ + -H 'Content-Type: application/json' \ + -d '{}' +``` + +--- + +## POST `/api/v1/admin/config/oidc/test` + +**Summary:** Test OIDC Discovery + +**Description:** Test OIDC Discovery + +#### Parameters + +| Name | In | Required | Type | Description | +|------|----|----------|------|-------------| +| `x-user-id` | header | No | anyOf | | + +#### Request Body + +**Required:** Yes + +- **Media Type:** `application/json` +- **Schema:** `OIDCConfigUpdate` (Define in Models) + +#### Responses + +| Status Code | Description | +|-------------|-------------| +| `200` | Successful Response | +| `422` | Validation Error | + +#### Example Usage + +```bash +curl -X 'POST' \ + 'http://localhost:8000/api/v1/api/v1/admin/config/oidc/test' \ + -H 'accept: application/json' \ + -H 'X-User-ID: ' \ + -H 'Content-Type: application/json' \ + -d '{}' +``` + +--- + +## GET `/api/v1/admin/config/swarm/test/{nonce}` + +**Summary:** Echo Swarm Nonce + +**Description:** Echo Swarm Nonce + +#### Parameters + +| Name | In | Required | Type | Description | +|------|----|----------|------|-------------| +| `nonce` | path | Yes | string | | + +#### Responses + +| Status Code | Description | +|-------------|-------------| +| `200` | Successful Response | +| `422` | Validation Error | + +#### Example Usage + +```bash +curl -X 'GET' \ + 'http://localhost:8000/api/v1/api/v1/admin/config/swarm/test/{nonce}' \ + -H 'accept: application/json' +``` + +--- + +## POST `/api/v1/admin/config/swarm/test` + +**Summary:** Test Swarm Connection + +**Description:** Test Swarm Connection + +#### Parameters + +| Name | In | Required | Type | Description | +|------|----|----------|------|-------------| +| `x-user-id` | header | No | anyOf | | + +#### Request Body + +**Required:** Yes + +- **Media Type:** `application/json` +- **Schema:** `SwarmConfigUpdate` (Define in Models) + +#### Responses + +| Status Code | Description | +|-------------|-------------| +| `200` | Successful Response | +| `422` | Validation Error | + +#### Example Usage + +```bash +curl -X 'POST' \ + 'http://localhost:8000/api/v1/api/v1/admin/config/swarm/test' \ + -H 'accept: application/json' \ + -H 'X-User-ID: ' \ + -H 'Content-Type: application/json' \ + -d '{}' +``` + +--- + +## PUT `/api/v1/admin/config/swarm` + +**Summary:** Update Swarm Configuration + +**Description:** Update Swarm Configuration + +#### Parameters + +| Name | In | Required | Type | Description | +|------|----|----------|------|-------------| +| `x-user-id` | header | No | anyOf | | + +#### Request Body + +**Required:** Yes + +- **Media Type:** `application/json` +- **Schema:** `SwarmConfigUpdate` (Define in Models) + +#### Responses + +| Status Code | Description | +|-------------|-------------| +| `200` | Successful Response | +| `422` | Validation Error | + +#### Example Usage + +```bash +curl -X 'PUT' \ + 'http://localhost:8000/api/v1/api/v1/admin/config/swarm' \ + -H 'accept: application/json' \ + -H 'X-User-ID: ' \ + -H 'Content-Type: application/json' \ + -d '{}' +``` + +--- + +## GET `/api/v1/admin/config` + +**Summary:** Get Admin Configuration + +**Description:** Get Admin Configuration + +#### Parameters + +| Name | In | Required | Type | Description | +|------|----|----------|------|-------------| +| `x-user-id` | header | No | anyOf | | + +#### Responses + +| Status Code | Description | +|-------------|-------------| +| `200` | Successful Response | +| `422` | Validation Error | + +#### Example Usage + +```bash +curl -X 'GET' \ + 'http://localhost:8000/api/v1/api/v1/admin/config' \ + -H 'accept: application/json' \ + -H 'X-User-ID: ' +``` + +--- + diff --git a/ai-hub/docs/api_reference/documents.md b/ai-hub/docs/api_reference/documents.md index 015a72a..1ed6ad0 100644 --- a/ai-hub/docs/api_reference/documents.md +++ b/ai-hub/docs/api_reference/documents.md @@ -1,6 +1,6 @@ # API Reference: Documents -## GET `/documents/` +## GET `/api/v1/documents/` **Summary:** List All Documents @@ -16,13 +16,13 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/documents/' \ + 'http://localhost:8000/api/v1/api/v1/documents/' \ -H 'accept: application/json' ``` --- -## POST `/documents/` +## POST `/api/v1/documents/` **Summary:** Add a New Document @@ -46,7 +46,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/documents/' \ + 'http://localhost:8000/api/v1/api/v1/documents/' \ -H 'accept: application/json' \ -H 'Content-Type: application/json' \ -d '{}' @@ -54,7 +54,7 @@ --- -## DELETE `/documents/{document_id}` +## DELETE `/api/v1/documents/{document_id}` **Summary:** Delete a Document @@ -77,7 +77,7 @@ ```bash curl -X 'DELETE' \ - 'http://localhost:8000/api/v1/documents/{document_id}' \ + 'http://localhost:8000/api/v1/api/v1/documents/{document_id}' \ -H 'accept: application/json' ``` diff --git a/ai-hub/docs/api_reference/general.md b/ai-hub/docs/api_reference/general.md index 69c7cb1..7979207 100644 --- a/ai-hub/docs/api_reference/general.md +++ b/ai-hub/docs/api_reference/general.md @@ -1,6 +1,6 @@ # API Reference: General -## GET `/` +## GET `/api/v1/` **Summary:** Check Service Status @@ -16,13 +16,13 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/' \ + 'http://localhost:8000/api/v1/api/v1/' \ -H 'accept: application/json' ``` --- -## GET `/status` +## GET `/api/v1/status` **Summary:** Get Full System Status @@ -38,7 +38,7 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/status' \ + 'http://localhost:8000/api/v1/api/v1/status' \ -H 'accept: application/json' ``` diff --git a/ai-hub/docs/api_reference/index.md b/ai-hub/docs/api_reference/index.md index c2bfd17..348baab 100644 --- a/ai-hub/docs/api_reference/index.md +++ b/ai-hub/docs/api_reference/index.md @@ -11,5 +11,6 @@ - [Agent Nodes](./agent-nodes.md) - [Skills](./skills.md) - [Agent Update](./agent-update.md) -- [Admin](./admin.md) +- [Api](./api.md) +- [Agents](./agents.md) - [Models (Schemas)](./models.md) diff --git a/ai-hub/docs/api_reference/models.md b/ai-hub/docs/api_reference/models.md index f8067ae..def9156 100644 --- a/ai-hub/docs/api_reference/models.md +++ b/ai-hub/docs/api_reference/models.md @@ -1,5 +1,54 @@ # Models (Schemas) +## `AgentConfigUpdate` + +**Type:** `object` + +**Description:** Day 2 Agent Configuration edits + +| Property | Type | Description | +|----------|------|-------------| +| `name` | `anyOf` | | +| `system_prompt` | `anyOf` | | +| `max_loop_iterations` | `anyOf` | | +| `mesh_node_id*` | `string` | | +| `provider_name` | `anyOf` | | + +## `AgentInstanceCreate` + +**Type:** `object` + +| Property | Type | Description | +|----------|------|-------------| +| `template_id*` | `string` | | +| `session_id` | `anyOf` | | +| `mesh_node_id` | `anyOf` | | +| `status` | `string` | | +| `current_workspace_jail` | `anyOf` | | + +## `AgentInstanceResponse` + +**Type:** `object` + +| Property | Type | Description | +|----------|------|-------------| +| `template_id*` | `string` | | +| `session_id` | `anyOf` | | +| `mesh_node_id` | `anyOf` | | +| `status` | `string` | | +| `current_workspace_jail` | `anyOf` | | +| `id*` | `string` | | +| `last_heartbeat` | `anyOf` | | +| `template` | `anyOf` | | + +## `AgentInstanceStatusUpdate` + +**Type:** `object` + +| Property | Type | Description | +|----------|------|-------------| +| `status*` | `string` | | + ## `AgentNodeAdminDetail` **Type:** `object` @@ -85,6 +134,56 @@ | `last_seen_at` | `anyOf` | | | `stats` | `Ref: AgentNodeStats` | | +## `AgentTemplateCreate` + +**Type:** `object` + +| Property | Type | Description | +|----------|------|-------------| +| `name*` | `string` | | +| `description` | `anyOf` | | +| `system_prompt_path` | `anyOf` | | +| `max_loop_iterations` | `integer` | | + +## `AgentTemplateResponse` + +**Type:** `object` + +| Property | Type | Description | +|----------|------|-------------| +| `name*` | `string` | | +| `description` | `anyOf` | | +| `system_prompt_path` | `anyOf` | | +| `max_loop_iterations` | `integer` | | +| `id*` | `string` | | +| `system_prompt_content` | `anyOf` | | + +## `AgentTriggerCreate` + +**Type:** `object` + +| Property | Type | Description | +|----------|------|-------------| +| `trigger_type*` | `string` | | +| `cron_expression` | `anyOf` | | +| `interval_seconds` | `anyOf` | | +| `default_prompt` | `anyOf` | | + +## `AgentTriggerResponse` + +**Type:** `object` + +| Property | Type | Description | +|----------|------|-------------| +| `instance_id*` | `string` | | +| `trigger_type*` | `string` | | +| `cron_expression` | `anyOf` | | +| `interval_seconds` | `anyOf` | | +| `default_prompt` | `anyOf` | | +| `webhook_secret` | `anyOf` | | +| `webhook_mapping_schema` | `anyOf` | | +| `id*` | `string` | | + ## `AppConfigUpdate` **Type:** `object` @@ -93,7 +192,7 @@ |----------|------|-------------| | `allow_password_login` | `anyOf` | | -## `Body_fs_upload_nodes__node_id__fs_upload_post` +## `Body_fs_upload_api_v1_nodes__node_id__fs_upload_post` **Type:** `object` @@ -101,7 +200,7 @@ |----------|------|-------------| | `file*` | `string` | | -## `Body_import_user_config_yaml_users_me_config_import_post` +## `Body_import_user_config_yaml_api_v1_users_me_config_import_post` **Type:** `object` @@ -109,7 +208,7 @@ |----------|------|-------------| | `file*` | `string` | | -## `Body_transcribe_audio_to_text_stt_transcribe_post` +## `Body_transcribe_audio_to_text_api_v1_stt_transcribe_post` **Type:** `object` @@ -117,7 +216,7 @@ |----------|------|-------------| | `audio_file*` | `string` | | -## `Body_upload_message_audio_sessions_messages__message_id__audio_post` +## `Body_upload_message_audio_api_v1_sessions_messages__message_id__audio_post` **Type:** `object` @@ -148,6 +247,26 @@ | `preferences*` | `Ref: UserPreferences` | | | `effective` | `object` | | +## `DeployAgentRequest` + +**Type:** `object` + +**Description:** One-click deployment: creates template + session + instance atomically. + +| Property | Type | Description | +|----------|------|-------------| +| `name*` | `string` | | +| `description` | `anyOf` | | +| `system_prompt` | `anyOf` | | +| `mesh_node_id*` | `string` | | +| `max_loop_iterations` | `integer` | | +| `initial_prompt` | `anyOf` | | +| `provider_name` | `anyOf` | | +| `trigger_type` | `anyOf` | | +| `cron_expression` | `anyOf` | | +| `interval_seconds` | `anyOf` | | +| `default_prompt` | `anyOf` | | + ## `DirectoryListing` **Type:** `object` diff --git a/ai-hub/docs/api_reference/sessions.md b/ai-hub/docs/api_reference/sessions.md index 1155d9c..9ad55af 100644 --- a/ai-hub/docs/api_reference/sessions.md +++ b/ai-hub/docs/api_reference/sessions.md @@ -1,6 +1,6 @@ # API Reference: Sessions -## POST `/sessions/` +## POST `/api/v1/sessions/` **Summary:** Create a New Chat Session @@ -24,7 +24,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/sessions/' \ + 'http://localhost:8000/api/v1/api/v1/sessions/' \ -H 'accept: application/json' \ -H 'Content-Type: application/json' \ -d '{}' @@ -32,7 +32,7 @@ --- -## GET `/sessions/` +## GET `/api/v1/sessions/` **Summary:** Get All Chat Sessions @@ -56,13 +56,13 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/sessions/?user_id=&feature_name=' \ + 'http://localhost:8000/api/v1/api/v1/sessions/?user_id=&feature_name=' \ -H 'accept: application/json' ``` --- -## DELETE `/sessions/` +## DELETE `/api/v1/sessions/` **Summary:** Delete All Sessions for Feature @@ -86,13 +86,13 @@ ```bash curl -X 'DELETE' \ - 'http://localhost:8000/api/v1/sessions/?user_id=&feature_name=' \ + 'http://localhost:8000/api/v1/api/v1/sessions/?user_id=&feature_name=' \ -H 'accept: application/json' ``` --- -## POST `/sessions/{session_id}/chat` +## POST `/api/v1/sessions/{session_id}/chat` **Summary:** Send a Message in a Session (Streaming) @@ -123,7 +123,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/sessions/{session_id}/chat' \ + 'http://localhost:8000/api/v1/api/v1/sessions/{session_id}/chat' \ -H 'accept: application/json' \ -H 'Content-Type: application/json' \ -d '{}' @@ -131,7 +131,7 @@ --- -## GET `/sessions/{session_id}/messages` +## GET `/api/v1/sessions/{session_id}/messages` **Summary:** Get Session Chat History @@ -154,13 +154,13 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/sessions/{session_id}/messages' \ + 'http://localhost:8000/api/v1/api/v1/sessions/{session_id}/messages' \ -H 'accept: application/json' ``` --- -## POST `/sessions/{session_id}/clear-history` +## POST `/api/v1/sessions/{session_id}/clear-history` **Summary:** Clear Chat History (Preserve Session) @@ -185,13 +185,13 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/sessions/{session_id}/clear-history' \ + 'http://localhost:8000/api/v1/api/v1/sessions/{session_id}/clear-history' \ -H 'accept: application/json' ``` --- -## GET `/sessions/{session_id}/tokens` +## GET `/api/v1/sessions/{session_id}/tokens` **Summary:** Get Session Token Usage @@ -214,13 +214,13 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/sessions/{session_id}/tokens' \ + 'http://localhost:8000/api/v1/api/v1/sessions/{session_id}/tokens' \ -H 'accept: application/json' ``` --- -## GET `/sessions/{session_id}` +## GET `/api/v1/sessions/{session_id}` **Summary:** Get a Single Session @@ -243,13 +243,13 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/sessions/{session_id}' \ + 'http://localhost:8000/api/v1/api/v1/sessions/{session_id}' \ -H 'accept: application/json' ``` --- -## PATCH `/sessions/{session_id}` +## PATCH `/api/v1/sessions/{session_id}` **Summary:** Update a Chat Session @@ -279,7 +279,7 @@ ```bash curl -X 'PATCH' \ - 'http://localhost:8000/api/v1/sessions/{session_id}' \ + 'http://localhost:8000/api/v1/api/v1/sessions/{session_id}' \ -H 'accept: application/json' \ -H 'Content-Type: application/json' \ -d '{}' @@ -287,7 +287,7 @@ --- -## DELETE `/sessions/{session_id}` +## DELETE `/api/v1/sessions/{session_id}` **Summary:** Delete a Chat Session @@ -310,13 +310,13 @@ ```bash curl -X 'DELETE' \ - 'http://localhost:8000/api/v1/sessions/{session_id}' \ + 'http://localhost:8000/api/v1/api/v1/sessions/{session_id}' \ -H 'accept: application/json' ``` --- -## POST `/sessions/messages/{message_id}/audio` +## POST `/api/v1/sessions/messages/{message_id}/audio` **Summary:** Upload audio for a specific message @@ -333,7 +333,7 @@ **Required:** Yes - **Media Type:** `multipart/form-data` -- **Schema:** `Body_upload_message_audio_sessions_messages__message_id__audio_post` (Define in Models) +- **Schema:** `Body_upload_message_audio_api_v1_sessions_messages__message_id__audio_post` (Define in Models) #### Responses @@ -346,7 +346,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/sessions/messages/{message_id}/audio' \ + 'http://localhost:8000/api/v1/api/v1/sessions/messages/{message_id}/audio' \ -H 'accept: application/json' \ -H 'Content-Type: multipart/form-data' \ -F 'file=@/path/to/file' @@ -354,7 +354,7 @@ --- -## GET `/sessions/messages/{message_id}/audio` +## GET `/api/v1/sessions/messages/{message_id}/audio` **Summary:** Get audio for a specific message @@ -377,13 +377,13 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/sessions/messages/{message_id}/audio' \ + 'http://localhost:8000/api/v1/api/v1/sessions/messages/{message_id}/audio' \ -H 'accept: application/json' ``` --- -## POST `/sessions/{session_id}/nodes` +## POST `/api/v1/sessions/{session_id}/nodes` **Summary:** Attach Nodes to Session @@ -413,7 +413,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/sessions/{session_id}/nodes' \ + 'http://localhost:8000/api/v1/api/v1/sessions/{session_id}/nodes' \ -H 'accept: application/json' \ -H 'Content-Type: application/json' \ -d '{}' @@ -421,7 +421,7 @@ --- -## GET `/sessions/{session_id}/nodes` +## GET `/api/v1/sessions/{session_id}/nodes` **Summary:** Get Session Node Status @@ -445,13 +445,13 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/sessions/{session_id}/nodes' \ + 'http://localhost:8000/api/v1/api/v1/sessions/{session_id}/nodes' \ -H 'accept: application/json' ``` --- -## DELETE `/sessions/{session_id}/nodes/{node_id}` +## DELETE `/api/v1/sessions/{session_id}/nodes/{node_id}` **Summary:** Detach Node from Session @@ -475,13 +475,13 @@ ```bash curl -X 'DELETE' \ - 'http://localhost:8000/api/v1/sessions/{session_id}/nodes/{node_id}' \ + 'http://localhost:8000/api/v1/api/v1/sessions/{session_id}/nodes/{node_id}' \ -H 'accept: application/json' ``` --- -## POST `/sessions/{session_id}/cancel` +## POST `/api/v1/sessions/{session_id}/cancel` **Summary:** Cancel Running AI Task @@ -504,7 +504,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/sessions/{session_id}/cancel' \ + 'http://localhost:8000/api/v1/api/v1/sessions/{session_id}/cancel' \ -H 'accept: application/json' ``` diff --git a/ai-hub/docs/api_reference/skills.md b/ai-hub/docs/api_reference/skills.md index 5bd5862..c00a49c 100644 --- a/ai-hub/docs/api_reference/skills.md +++ b/ai-hub/docs/api_reference/skills.md @@ -1,6 +1,6 @@ # API Reference: Skills -## GET `/skills/` +## GET `/api/v1/skills/` **Summary:** List Skills @@ -24,14 +24,14 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/skills/?feature=' \ + 'http://localhost:8000/api/v1/api/v1/skills/?feature=' \ -H 'accept: application/json' \ -H 'X-User-ID: ' ``` --- -## POST `/skills/` +## POST `/api/v1/skills/` **Summary:** Create Skill @@ -61,7 +61,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/skills/' \ + 'http://localhost:8000/api/v1/api/v1/skills/' \ -H 'accept: application/json' \ -H 'X-User-ID: ' \ -H 'Content-Type: application/json' \ @@ -70,7 +70,7 @@ --- -## PUT `/skills/{skill_id}` +## PUT `/api/v1/skills/{skill_id}` **Summary:** Update Skill @@ -101,7 +101,7 @@ ```bash curl -X 'PUT' \ - 'http://localhost:8000/api/v1/skills/{skill_id}' \ + 'http://localhost:8000/api/v1/api/v1/skills/{skill_id}' \ -H 'accept: application/json' \ -H 'X-User-ID: ' \ -H 'Content-Type: application/json' \ @@ -110,7 +110,7 @@ --- -## DELETE `/skills/{skill_id}` +## DELETE `/api/v1/skills/{skill_id}` **Summary:** Delete Skill @@ -134,14 +134,14 @@ ```bash curl -X 'DELETE' \ - 'http://localhost:8000/api/v1/skills/{skill_id}' \ + 'http://localhost:8000/api/v1/api/v1/skills/{skill_id}' \ -H 'accept: application/json' \ -H 'X-User-ID: ' ``` --- -## GET `/skills/{skill_id}/files` +## GET `/api/v1/skills/{skill_id}/files` **Summary:** List Skill Files @@ -165,14 +165,14 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/skills/{skill_id}/files' \ + 'http://localhost:8000/api/v1/api/v1/skills/{skill_id}/files' \ -H 'accept: application/json' \ -H 'X-User-ID: ' ``` --- -## GET `/skills/{skill_id}/files/{path}` +## GET `/api/v1/skills/{skill_id}/files/{path}` **Summary:** Read Skill File @@ -197,14 +197,14 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/skills/{skill_id}/files/{path}' \ + 'http://localhost:8000/api/v1/api/v1/skills/{skill_id}/files/{path}' \ -H 'accept: application/json' \ -H 'X-User-ID: ' ``` --- -## POST `/skills/{skill_id}/files/{path}` +## POST `/api/v1/skills/{skill_id}/files/{path}` **Summary:** Create Or Update Skill File @@ -236,7 +236,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/skills/{skill_id}/files/{path}' \ + 'http://localhost:8000/api/v1/api/v1/skills/{skill_id}/files/{path}' \ -H 'accept: application/json' \ -H 'X-User-ID: ' \ -H 'Content-Type: application/json' \ @@ -245,7 +245,7 @@ --- -## DELETE `/skills/{skill_id}/files/{path}` +## DELETE `/api/v1/skills/{skill_id}/files/{path}` **Summary:** Delete Skill File @@ -270,7 +270,7 @@ ```bash curl -X 'DELETE' \ - 'http://localhost:8000/api/v1/skills/{skill_id}/files/{path}' \ + 'http://localhost:8000/api/v1/api/v1/skills/{skill_id}/files/{path}' \ -H 'accept: application/json' \ -H 'X-User-ID: ' ``` diff --git a/ai-hub/docs/api_reference/stt.md b/ai-hub/docs/api_reference/stt.md index 85af7b8..c7e8404 100644 --- a/ai-hub/docs/api_reference/stt.md +++ b/ai-hub/docs/api_reference/stt.md @@ -1,6 +1,6 @@ # API Reference: STT -## POST `/stt/transcribe` +## POST `/api/v1/stt/transcribe` **Summary:** Transcribe audio to text @@ -21,7 +21,7 @@ **Required:** Yes - **Media Type:** `multipart/form-data` -- **Schema:** `Body_transcribe_audio_to_text_stt_transcribe_post` (Define in Models) +- **Schema:** `Body_transcribe_audio_to_text_api_v1_stt_transcribe_post` (Define in Models) #### Responses @@ -34,7 +34,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/stt/transcribe?provider_name=' \ + 'http://localhost:8000/api/v1/api/v1/stt/transcribe?provider_name=' \ -H 'accept: application/json' \ -H 'X-User-ID: ' \ -H 'Content-Type: multipart/form-data' \ diff --git a/ai-hub/docs/api_reference/tts.md b/ai-hub/docs/api_reference/tts.md index d223116..de890ce 100644 --- a/ai-hub/docs/api_reference/tts.md +++ b/ai-hub/docs/api_reference/tts.md @@ -1,6 +1,6 @@ # API Reference: TTS -## POST `/speech` +## POST `/api/v1/speech` **Summary:** Generate speech from text @@ -33,7 +33,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/speech?stream=&as_wav=&provider_name=' \ + 'http://localhost:8000/api/v1/api/v1/speech?stream=&as_wav=&provider_name=' \ -H 'accept: application/json' \ -H 'X-User-ID: ' \ -H 'Content-Type: application/json' \ @@ -42,7 +42,7 @@ --- -## GET `/speech/voices` +## GET `/api/v1/speech/voices` **Summary:** List available TTS voices @@ -67,7 +67,7 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/speech/voices?provider=&api_key=' \ + 'http://localhost:8000/api/v1/api/v1/speech/voices?provider=&api_key=' \ -H 'accept: application/json' \ -H 'X-User-ID: ' ``` diff --git a/ai-hub/docs/api_reference/users.md b/ai-hub/docs/api_reference/users.md index deb8d8d..0bdddb8 100644 --- a/ai-hub/docs/api_reference/users.md +++ b/ai-hub/docs/api_reference/users.md @@ -1,6 +1,6 @@ # API Reference: Users -## GET `/users/login` +## GET `/api/v1/users/login` **Summary:** Initiate OIDC Login Flow @@ -23,13 +23,13 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/users/login?frontend_callback_uri=' \ + 'http://localhost:8000/api/v1/api/v1/users/login?frontend_callback_uri=' \ -H 'accept: application/json' ``` --- -## GET `/users/login/callback` +## GET `/api/v1/users/login/callback` **Summary:** Handle OIDC Login Callback @@ -53,13 +53,13 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/users/login/callback?code=&state=' \ + 'http://localhost:8000/api/v1/api/v1/users/login/callback?code=&state=' \ -H 'accept: application/json' ``` --- -## GET `/users/me` +## GET `/api/v1/users/me` **Summary:** Get Current User Status @@ -83,14 +83,14 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/users/me' \ + 'http://localhost:8000/api/v1/api/v1/users/me' \ -H 'accept: application/json' \ -H 'X-User-ID: ' ``` --- -## POST `/users/login/local` +## POST `/api/v1/users/login/local` **Summary:** Local Authentication Fallback @@ -114,7 +114,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/users/login/local' \ + 'http://localhost:8000/api/v1/api/v1/users/login/local' \ -H 'accept: application/json' \ -H 'Content-Type: application/json' \ -d '{}' @@ -122,7 +122,7 @@ --- -## PUT `/users/password` +## PUT `/api/v1/users/password` **Summary:** Update User Password @@ -152,7 +152,7 @@ ```bash curl -X 'PUT' \ - 'http://localhost:8000/api/v1/users/password' \ + 'http://localhost:8000/api/v1/api/v1/users/password' \ -H 'accept: application/json' \ -H 'X-User-ID: ' \ -H 'Content-Type: application/json' \ @@ -161,7 +161,7 @@ --- -## GET `/users/me/profile` +## GET `/api/v1/users/me/profile` **Summary:** Get Current User Profile @@ -184,14 +184,14 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/users/me/profile' \ + 'http://localhost:8000/api/v1/api/v1/users/me/profile' \ -H 'accept: application/json' \ -H 'X-User-ID: ' ``` --- -## PUT `/users/me/profile` +## PUT `/api/v1/users/me/profile` **Summary:** Update User Profile @@ -221,7 +221,7 @@ ```bash curl -X 'PUT' \ - 'http://localhost:8000/api/v1/users/me/profile' \ + 'http://localhost:8000/api/v1/api/v1/users/me/profile' \ -H 'accept: application/json' \ -H 'X-User-ID: ' \ -H 'Content-Type: application/json' \ @@ -230,7 +230,7 @@ --- -## GET `/users/me/config` +## GET `/api/v1/users/me/config` **Summary:** Get Current User Preferences @@ -253,14 +253,14 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/users/me/config' \ + 'http://localhost:8000/api/v1/api/v1/users/me/config' \ -H 'accept: application/json' \ -H 'X-User-ID: ' ``` --- -## PUT `/users/me/config` +## PUT `/api/v1/users/me/config` **Summary:** Update Current User Preferences @@ -290,7 +290,7 @@ ```bash curl -X 'PUT' \ - 'http://localhost:8000/api/v1/users/me/config' \ + 'http://localhost:8000/api/v1/api/v1/users/me/config' \ -H 'accept: application/json' \ -H 'X-User-ID: ' \ -H 'Content-Type: application/json' \ @@ -299,7 +299,7 @@ --- -## GET `/users/me/config/models` +## GET `/api/v1/users/me/config/models` **Summary:** Get Models for Provider @@ -323,13 +323,13 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/users/me/config/models?provider_name=§ion=
' \ + 'http://localhost:8000/api/v1/api/v1/users/me/config/models?provider_name=§ion=
' \ -H 'accept: application/json' ``` --- -## GET `/users/me/config/providers` +## GET `/api/v1/users/me/config/providers` **Summary:** Get All Valid Providers per Section @@ -354,14 +354,14 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/users/me/config/providers?section=
&configured_only=' \ + 'http://localhost:8000/api/v1/api/v1/users/me/config/providers?section=
&configured_only=' \ -H 'accept: application/json' \ -H 'X-User-ID: ' ``` --- -## POST `/users/me/config/verify_llm` +## POST `/api/v1/users/me/config/verify_llm` **Summary:** Verify Llm @@ -391,7 +391,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/users/me/config/verify_llm' \ + 'http://localhost:8000/api/v1/api/v1/users/me/config/verify_llm' \ -H 'accept: application/json' \ -H 'X-User-ID: ' \ -H 'Content-Type: application/json' \ @@ -400,7 +400,7 @@ --- -## POST `/users/me/config/verify_tts` +## POST `/api/v1/users/me/config/verify_tts` **Summary:** Verify Tts @@ -430,7 +430,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/users/me/config/verify_tts' \ + 'http://localhost:8000/api/v1/api/v1/users/me/config/verify_tts' \ -H 'accept: application/json' \ -H 'X-User-ID: ' \ -H 'Content-Type: application/json' \ @@ -439,7 +439,7 @@ --- -## POST `/users/me/config/verify_stt` +## POST `/api/v1/users/me/config/verify_stt` **Summary:** Verify Stt @@ -469,7 +469,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/users/me/config/verify_stt' \ + 'http://localhost:8000/api/v1/api/v1/users/me/config/verify_stt' \ -H 'accept: application/json' \ -H 'X-User-ID: ' \ -H 'Content-Type: application/json' \ @@ -478,7 +478,7 @@ --- -## POST `/users/logout` +## POST `/api/v1/users/logout` **Summary:** Log Out the Current User @@ -494,13 +494,13 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/users/logout' \ + 'http://localhost:8000/api/v1/api/v1/users/logout' \ -H 'accept: application/json' ``` --- -## GET `/users/me/config/export` +## GET `/api/v1/users/me/config/export` **Summary:** Export Configurations to YAML @@ -523,14 +523,14 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/users/me/config/export' \ + 'http://localhost:8000/api/v1/api/v1/users/me/config/export' \ -H 'accept: application/json' \ -H 'X-User-ID: ' ``` --- -## POST `/users/me/config/import` +## POST `/api/v1/users/me/config/import` **Summary:** Import Configurations from YAML @@ -547,7 +547,7 @@ **Required:** Yes - **Media Type:** `multipart/form-data` -- **Schema:** `Body_import_user_config_yaml_users_me_config_import_post` (Define in Models) +- **Schema:** `Body_import_user_config_yaml_api_v1_users_me_config_import_post` (Define in Models) #### Responses @@ -560,7 +560,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/users/me/config/import' \ + 'http://localhost:8000/api/v1/api/v1/users/me/config/import' \ -H 'accept: application/json' \ -H 'X-User-ID: ' \ -H 'Content-Type: multipart/form-data' \ @@ -569,7 +569,7 @@ --- -## GET `/users/admin/users` +## GET `/api/v1/users/admin/users` **Summary:** List All Users (Admin Only) @@ -592,14 +592,14 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/users/admin/users' \ + 'http://localhost:8000/api/v1/api/v1/users/admin/users' \ -H 'accept: application/json' \ -H 'X-User-ID: ' ``` --- -## PUT `/users/admin/users/{uid}/role` +## PUT `/api/v1/users/admin/users/{uid}/role` **Summary:** Update User Role (Admin Only) @@ -630,7 +630,7 @@ ```bash curl -X 'PUT' \ - 'http://localhost:8000/api/v1/users/admin/users/{uid}/role' \ + 'http://localhost:8000/api/v1/api/v1/users/admin/users/{uid}/role' \ -H 'accept: application/json' \ -H 'X-User-ID: ' \ -H 'Content-Type: application/json' \ @@ -639,7 +639,7 @@ --- -## PUT `/users/admin/users/{uid}/group` +## PUT `/api/v1/users/admin/users/{uid}/group` **Summary:** Update User Group (Admin Only) @@ -670,7 +670,7 @@ ```bash curl -X 'PUT' \ - 'http://localhost:8000/api/v1/users/admin/users/{uid}/group' \ + 'http://localhost:8000/api/v1/api/v1/users/admin/users/{uid}/group' \ -H 'accept: application/json' \ -H 'X-User-ID: ' \ -H 'Content-Type: application/json' \ @@ -679,7 +679,7 @@ --- -## GET `/users/admin/groups` +## GET `/api/v1/users/admin/groups` **Summary:** List All Groups (Admin Only) @@ -702,14 +702,14 @@ ```bash curl -X 'GET' \ - 'http://localhost:8000/api/v1/users/admin/groups' \ + 'http://localhost:8000/api/v1/api/v1/users/admin/groups' \ -H 'accept: application/json' \ -H 'X-User-ID: ' ``` --- -## POST `/users/admin/groups` +## POST `/api/v1/users/admin/groups` **Summary:** Create Group (Admin Only) @@ -739,7 +739,7 @@ ```bash curl -X 'POST' \ - 'http://localhost:8000/api/v1/users/admin/groups' \ + 'http://localhost:8000/api/v1/api/v1/users/admin/groups' \ -H 'accept: application/json' \ -H 'X-User-ID: ' \ -H 'Content-Type: application/json' \ @@ -748,7 +748,7 @@ --- -## PUT `/users/admin/groups/{gid}` +## PUT `/api/v1/users/admin/groups/{gid}` **Summary:** Update Group (Admin Only) @@ -779,7 +779,7 @@ ```bash curl -X 'PUT' \ - 'http://localhost:8000/api/v1/users/admin/groups/{gid}' \ + 'http://localhost:8000/api/v1/api/v1/users/admin/groups/{gid}' \ -H 'accept: application/json' \ -H 'X-User-ID: ' \ -H 'Content-Type: application/json' \ @@ -788,7 +788,7 @@ --- -## DELETE `/users/admin/groups/{gid}` +## DELETE `/api/v1/users/admin/groups/{gid}` **Summary:** Delete Group (Admin Only) @@ -812,7 +812,7 @@ ```bash curl -X 'DELETE' \ - 'http://localhost:8000/api/v1/users/admin/groups/{gid}' \ + 'http://localhost:8000/api/v1/api/v1/users/admin/groups/{gid}' \ -H 'accept: application/json' \ -H 'X-User-ID: ' ```