{ "swagger": "2.0", "info": { "description": "AI-Hermes Portal backend APIs.", "title": "AI-Hermes Portal API", "contact": {}, "version": "1.0" }, "basePath": "/", "paths": { "/api/v1/admin/litellm/access": { "get": { "security": [ { "BearerAuth": [] } ], "produces": [ "application/json" ], "tags": [ "litellm-admin" ], "summary": "Get LiteLLM admin access flags", "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/api.swaggerLiteLLMAccessResponse" } }, "401": { "description": "Unauthorized", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } } } } }, "/api/v1/admin/litellm/calls/{tenant_id}/{user_id}": { "get": { "security": [ { "BearerAuth": [] } ], "produces": [ "application/json" ], "tags": [ "litellm-admin" ], "summary": "List user recent calls (admin)", "parameters": [ { "type": "string", "description": "Tenant ID", "name": "tenant_id", "in": "path", "required": true }, { "type": "string", "description": "User ID", "name": "user_id", "in": "path", "required": true }, { "type": "integer", "description": "Max items (default 20)", "name": "limit", "in": "query" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/api.swaggerLiteLLMCallListResponse" } }, "401": { "description": "Unauthorized", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "403": { "description": "Forbidden", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } }, "503": { "description": "Service Unavailable", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } } } } }, "/api/v1/admin/litellm/credits/adjust": { "post": { "security": [ { "BearerAuth": [] } ], "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "litellm-admin" ], "summary": "Adjust user credit (admin)", "parameters": [ { "description": "Adjust payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/api.liteLLMCreditAdjustRequest" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/litellmcredit.CreditSnapshot" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "401": { "description": "Unauthorized", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "403": { "description": "Forbidden", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } }, "503": { "description": "Service Unavailable", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } } } } }, "/api/v1/admin/litellm/credits/{tenant_id}/{user_id}": { "get": { "security": [ { "BearerAuth": [] } ], "produces": [ "application/json" ], "tags": [ "litellm-admin" ], "summary": "Get user credit snapshot (admin)", "parameters": [ { "type": "string", "description": "Tenant ID", "name": "tenant_id", "in": "path", "required": true }, { "type": "string", "description": "User ID", "name": "user_id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/litellmcredit.CreditSnapshot" } }, "401": { "description": "Unauthorized", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "403": { "description": "Forbidden", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } }, "503": { "description": "Service Unavailable", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } } } } }, "/api/v1/admin/litellm/events": { "get": { "security": [ { "BearerAuth": [] } ], "produces": [ "application/json" ], "tags": [ "litellm-admin" ], "summary": "List credit events (admin)", "parameters": [ { "type": "integer", "description": "Max items (default 50)", "name": "limit", "in": "query" }, { "type": "integer", "description": "Offset (default 0)", "name": "offset", "in": "query" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/api.swaggerLiteLLMEventListResponse" } }, "401": { "description": "Unauthorized", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "403": { "description": "Forbidden", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } }, "503": { "description": "Service Unavailable", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } } } } }, "/api/v1/audit/events": { "get": { "security": [ { "BearerAuth": [] } ], "produces": [ "application/json" ], "tags": [ "audit" ], "summary": "Query audit events", "parameters": [ { "type": "string", "description": "Actor filter", "name": "actor", "in": "query" }, { "type": "string", "description": "Action filter", "name": "action", "in": "query" }, { "type": "string", "description": "Resource filter", "name": "resource", "in": "query" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/api.swaggerAuditListResponse" } }, "401": { "description": "Unauthorized", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } } } } }, "/api/v1/auth/login": { "post": { "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "auth" ], "summary": "Login", "parameters": [ { "description": "Login payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/api.loginRequest" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/authn.TokenPair" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "401": { "description": "Unauthorized", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } }, "403": { "description": "Forbidden", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } } } } }, "/api/v1/auth/logout": { "post": { "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "auth" ], "summary": "Logout by refresh token", "parameters": [ { "description": "Refresh token payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/api.refreshRequest" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/api.swaggerOKResponse" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } } } } }, "/api/v1/auth/password/change": { "post": { "security": [ { "BearerAuth": [] } ], "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "auth" ], "summary": "Change current password", "parameters": [ { "description": "Change password payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/api.changePasswordRequest" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/api.swaggerOKResponse" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "401": { "description": "Unauthorized", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } } } } }, "/api/v1/auth/password/forgot": { "post": { "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "auth" ], "summary": "Request password reset", "parameters": [ { "description": "Forgot password payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/api.forgotPasswordRequest" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/api.swaggerOKResponse" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } } } } }, "/api/v1/auth/password/reset": { "post": { "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "auth" ], "summary": "Reset password", "parameters": [ { "description": "Reset password payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/api.resetPasswordRequest" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/api.swaggerOKResponse" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } } } } }, "/api/v1/auth/password/reset/phone": { "post": { "description": "Resets password with a phone SMS verification code.", "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "auth" ], "summary": "Reset password by phone", "parameters": [ { "description": "Reset password by phone payload", "name": "request", "in": "body", "required": true, "schema": { "$ref": "#/definitions/api.resetPasswordByPhoneRequest" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/api.okResponse" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/api.errorMessageResponse" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/api.apiErrorResponse" } } } } }, "/api/v1/auth/refresh": { "post": { "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "auth" ], "summary": "Refresh token pair", "parameters": [ { "description": "Refresh token payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/api.refreshRequest" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/authn.TokenPair" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "401": { "description": "Unauthorized", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } } } } }, "/api/v1/auth/register": { "post": { "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "auth" ], "summary": "Register by email", "parameters": [ { "description": "Register payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/api.registerRequest" } } ], "responses": { "201": { "description": "Created", "schema": { "$ref": "#/definitions/authn.RegisterResult" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "409": { "description": "Conflict", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } } } } }, "/api/v1/auth/register/phone": { "post": { "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "auth" ], "summary": "Register by phone", "parameters": [ { "description": "Register by phone payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/api.registerByPhoneRequest" } } ], "responses": { "201": { "description": "Created", "schema": { "$ref": "#/definitions/authn.RegisterResult" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "409": { "description": "Conflict", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } } } } }, "/api/v1/auth/sms/send-code": { "post": { "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "auth" ], "summary": "Send registration SMS code", "parameters": [ { "description": "SMS request", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/api.sendSMSCodeRequest" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/api.swaggerOKResponse" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } } } } }, "/api/v1/auth/verify-email": { "post": { "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "auth" ], "summary": "Verify email by code", "parameters": [ { "description": "Verify email payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/api.verifyEmailRequest" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/api.swaggerVerifiedResponse" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } } } } }, "/api/v1/config/litellm": { "get": { "produces": [ "application/json" ], "tags": [ "litellm" ], "summary": "Get LiteLLM client config", "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/api.swaggerLiteLLMConfigResponse" } } } } }, "/api/v1/litellm/me/calls": { "get": { "security": [ { "BearerAuth": [] } ], "produces": [ "application/json" ], "tags": [ "litellm" ], "summary": "List my recent LiteLLM calls", "parameters": [ { "type": "integer", "description": "Max items (default 20)", "name": "limit", "in": "query" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/api.swaggerLiteLLMCallListResponse" } }, "401": { "description": "Unauthorized", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "503": { "description": "Service Unavailable", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } } } } }, "/api/v1/litellm/me/credit": { "get": { "security": [ { "BearerAuth": [] } ], "produces": [ "application/json" ], "tags": [ "litellm" ], "summary": "Get my LiteLLM credit snapshot", "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/litellmcredit.CreditSnapshot" } }, "401": { "description": "Unauthorized", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "503": { "description": "Service Unavailable", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } } } } }, "/api/v1/litellm/me/models": { "get": { "security": [ { "BearerAuth": [] } ], "produces": [ "application/json" ], "tags": [ "litellm" ], "summary": "List available LiteLLM models", "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/api.swaggerLiteLLMModelListResponse" } }, "401": { "description": "Unauthorized", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "502": { "description": "Bad Gateway", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } }, "503": { "description": "Service Unavailable", "schema": { "$ref": "#/definitions/api.swaggerAPIErrorResponse" } } } } }, "/api/v1/me": { "get": { "security": [ { "BearerAuth": [] } ], "produces": [ "application/json" ], "tags": [ "user" ], "summary": "Get current principal", "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/identity.Principal" } }, "401": { "description": "Unauthorized", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } } } } }, "/api/v1/permissions/check": { "post": { "security": [ { "BearerAuth": [] } ], "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "authz" ], "summary": "Check a policy tuple", "parameters": [ { "description": "Permission check payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/api.checkPermissionRequest" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/api.swaggerAllowedResponse" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "401": { "description": "Unauthorized", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } } } } }, "/api/v1/policies/relationships": { "post": { "security": [ { "BearerAuth": [] } ], "consumes": [ "application/json" ], "produces": [ "application/json" ], "tags": [ "authz" ], "summary": "Write policy relationships", "parameters": [ { "description": "Relationship payload", "name": "body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/api.writeRelationshipRequest" } } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/api.swaggerWrittenResponse" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "401": { "description": "Unauthorized", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "403": { "description": "Forbidden", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } } } } }, "/api/v1/tenants/{tenant_id}/members": { "get": { "security": [ { "BearerAuth": [] } ], "produces": [ "application/json" ], "tags": [ "tenant" ], "summary": "List tenant members", "parameters": [ { "type": "string", "description": "Tenant ID", "name": "tenant_id", "in": "path", "required": true } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/api.swaggerMemberListResponse" } }, "400": { "description": "Bad Request", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "401": { "description": "Unauthorized", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "403": { "description": "Forbidden", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } }, "500": { "description": "Internal Server Error", "schema": { "$ref": "#/definitions/api.swaggerSimpleErrorResponse" } } } } }, "/healthz": { "get": { "produces": [ "application/json" ], "tags": [ "system" ], "summary": "Health check", "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/api.swaggerStatusResponse" } } } } } }, "definitions": { "api.allowedResponse": { "type": "object", "properties": { "allowed": { "type": "boolean" } } }, "api.apiErrorBody": { "type": "object", "properties": { "code": { "type": "string" }, "message": { "type": "string" } } }, "api.apiErrorResponse": { "type": "object", "properties": { "error": { "$ref": "#/definitions/api.apiErrorBody" } } }, "api.auditEventsResponse": { "type": "object", "properties": { "items": { "type": "array", "items": { "$ref": "#/definitions/models.AuditEvent" } } } }, "api.changePasswordRequest": { "type": "object", "properties": { "new_password": { "type": "string" }, "old_password": { "type": "string" } } }, "api.checkPermissionRequest": { "type": "object", "properties": { "object": { "type": "string" }, "relation": { "type": "string" }, "subject": { "type": "string" } } }, "api.errorMessageResponse": { "type": "object", "properties": { "error": { "type": "string" } } }, "api.forgotPasswordRequest": { "type": "object", "properties": { "email": { "type": "string" } } }, "api.liteLLMAccessResponse": { "type": "object", "properties": { "can_manage": { "type": "boolean" }, "service_available": { "type": "boolean" } } }, "api.liteLLMCreditAdjustRequest": { "type": "object", "properties": { "amount": { "type": "number" }, "mode": { "type": "string" }, "reason": { "type": "string" }, "tenant_id": { "type": "string" }, "user_id": { "type": "string" } } }, "api.liteLLMEventsResponse": { "type": "object", "properties": { "items": { "type": "array", "items": { "$ref": "#/definitions/litellmcredit.CreditEvent" } }, "limit": { "type": "integer" }, "offset": { "type": "integer" } } }, "api.liteLLMRecentCallsResponse": { "type": "object", "properties": { "items": { "type": "array", "items": { "$ref": "#/definitions/litellmcredit.RecentCall" } }, "limit": { "type": "integer" } } }, "api.loginRequest": { "type": "object", "properties": { "account": { "type": "string" }, "email": { "type": "string" }, "password": { "type": "string" } } }, "api.okResponse": { "type": "object", "properties": { "ok": { "type": "boolean" } } }, "api.refreshRequest": { "type": "object", "properties": { "refresh_token": { "type": "string" } } }, "api.registerByPhoneRequest": { "type": "object", "properties": { "code": { "type": "string" }, "display_name": { "type": "string" }, "password": { "type": "string" }, "phone": { "type": "string" } } }, "api.registerRequest": { "type": "object", "properties": { "display_name": { "type": "string" }, "email": { "type": "string" }, "password": { "type": "string" } } }, "api.resetPasswordByPhoneRequest": { "type": "object", "properties": { "code": { "type": "string" }, "new_password": { "type": "string" }, "phone": { "type": "string" } } }, "api.resetPasswordRequest": { "type": "object", "properties": { "new_password": { "type": "string" }, "token": { "type": "string" } } }, "api.sendSMSCodeRequest": { "type": "object", "properties": { "phone": { "type": "string" }, "purpose": { "type": "string" } } }, "api.statusResponse": { "type": "object", "properties": { "status": { "type": "string" } } }, "api.swaggerAPIErrorResponse": { "type": "object", "properties": { "error": { "$ref": "#/definitions/api.swaggerErrorBody" } } }, "api.swaggerAllowedResponse": { "type": "object", "properties": { "allowed": { "type": "boolean" } } }, "api.swaggerAuditListResponse": { "type": "object", "properties": { "items": { "type": "array", "items": { "$ref": "#/definitions/models.AuditEvent" } } } }, "api.swaggerErrorBody": { "type": "object", "properties": { "code": { "type": "string" }, "message": { "type": "string" } } }, "api.swaggerLiteLLMAccessResponse": { "type": "object", "properties": { "can_manage": { "type": "boolean" }, "service_available": { "type": "boolean" } } }, "api.swaggerLiteLLMCallListResponse": { "type": "object", "properties": { "items": { "type": "array", "items": { "$ref": "#/definitions/litellmcredit.RecentCall" } }, "limit": { "type": "integer" } } }, "api.swaggerLiteLLMConfigResponse": { "type": "object", "properties": { "base_url": { "type": "string" }, "default_model": { "type": "string" } } }, "api.swaggerLiteLLMEventListResponse": { "type": "object", "properties": { "items": { "type": "array", "items": { "$ref": "#/definitions/litellmcredit.CreditEvent" } }, "limit": { "type": "integer" }, "offset": { "type": "integer" } } }, "api.swaggerLiteLLMModelListResponse": { "type": "object", "properties": { "items": { "type": "array", "items": { "$ref": "#/definitions/litellm.ModelInfo" } }, "total": { "type": "integer" } } }, "api.swaggerMemberListResponse": { "type": "object", "properties": { "items": { "type": "array", "items": { "$ref": "#/definitions/identity.Principal" } } } }, "api.swaggerOKResponse": { "type": "object", "properties": { "ok": { "type": "boolean" } } }, "api.swaggerSimpleErrorResponse": { "type": "object", "properties": { "error": { "type": "string" } } }, "api.swaggerStatusResponse": { "type": "object", "properties": { "status": { "type": "string" } } }, "api.swaggerVerifiedResponse": { "type": "object", "properties": { "verified": { "type": "boolean" } } }, "api.swaggerWrittenResponse": { "type": "object", "properties": { "written": { "type": "integer" } } }, "api.tenantMembersResponse": { "type": "object", "properties": { "items": { "type": "array", "items": { "$ref": "#/definitions/identity.Principal" } } } }, "api.verifiedResponse": { "type": "object", "properties": { "verified": { "type": "boolean" } } }, "api.verifyEmailRequest": { "type": "object", "properties": { "code": { "type": "string" }, "email": { "type": "string" } } }, "api.writeRelationshipRequest": { "type": "object", "properties": { "tuples": { "type": "array", "items": { "$ref": "#/definitions/models.PolicyTuple" } } } }, "api.writtenResponse": { "type": "object", "properties": { "written": { "type": "integer" } } }, "authn.RegisterResult": { "type": "object", "properties": { "tenant_id": { "type": "string" }, "user_id": { "type": "string" } } }, "authn.TokenPair": { "type": "object", "properties": { "access_token": { "type": "string" }, "expires_in": { "type": "integer" }, "refresh_token": { "type": "string" }, "token_type": { "type": "string" } } }, "identity.Principal": { "type": "object", "properties": { "email": { "type": "string" }, "role": { "type": "string" }, "tenant_id": { "type": "string" }, "user_id": { "type": "string" } } }, "litellm.ModelInfo": { "type": "object", "properties": { "context_window": { "type": "integer" }, "id": { "type": "string" }, "model_name": { "type": "string" }, "provider": { "type": "string" }, "raw": { "type": "object", "additionalProperties": {} } } }, "litellmcredit.CreditEvent": { "type": "object", "properties": { "actor_email": { "type": "string" }, "actor_user_id": { "type": "string" }, "after_budget": { "type": "number" }, "amount": { "type": "number" }, "before_budget": { "type": "number" }, "created_at": { "type": "string" }, "error_message": { "type": "string" }, "id": { "type": "integer" }, "mode": { "type": "string" }, "reason": { "type": "string" }, "result": { "type": "string" }, "tenant_id": { "type": "string" }, "user_id": { "type": "string" } } }, "litellmcredit.CreditSnapshot": { "type": "object", "properties": { "api_key": { "type": "string" }, "budget_remaining": { "type": "number" }, "budget_total": { "type": "number" }, "key_alias": { "type": "string" }, "last_synced_at": { "type": "string" }, "litellm_user_id": { "type": "string" }, "spend_used": { "type": "number" }, "tenant_id": { "type": "string" }, "unit": { "type": "string" }, "user_id": { "type": "string" } } }, "litellmcredit.RecentCall": { "type": "object", "properties": { "at": { "type": "string" }, "completion_tokens": { "type": "integer" }, "cost": { "type": "number" }, "model": { "type": "string" }, "prompt_tokens": { "type": "integer" }, "total_tokens": { "type": "integer" } } }, "models.AuditEvent": { "type": "object", "properties": { "action": { "type": "string" }, "actor": { "type": "string" }, "at": { "type": "string" }, "id": { "type": "integer" }, "ip": { "type": "string" }, "resource": { "type": "string" }, "result": { "type": "string" }, "tenant_id": { "type": "string" }, "trace_id": { "type": "string" }, "user_agent": { "type": "string" } } }, "models.PolicyTuple": { "type": "object", "properties": { "object": { "type": "string" }, "relation": { "type": "string" }, "subject": { "type": "string" } } } }, "securityDefinitions": { "BearerAuth": { "type": "apiKey", "name": "Authorization", "in": "header" } } }