{"openapi":"3.1.0","info":{"title":"Mixpeek API","description":"This is the Mixpeek API, providing access to various endpoints for data processing and retrieval.","termsOfService":"https://mixpeek.com/terms","contact":{"name":"Mixpeek Support","url":"https://mixpeek.com/contact","email":"info@mixpeek.com"},"version":"0.82"},"servers":[{"url":"https://api.mixpeek.com","description":"Production"}],"paths":{"/v1/public/retrievers/":{"get":{"tags":["Public Retriever API"],"summary":"List Public Retrievers","description":"List all public retrievers with pagination and search.\n\nThis endpoint allows browsing and discovering all published retrievers\nacross all organizations. No authentication required.\n\n**Authentication:**\n- NO authentication required - completely public endpoint\n- Discover retrievers created by all Mixpeek users\n\n**Pagination:**\n- Default: page=1, page_size=20\n- Maximum page_size: 100\n- Returns total count and total pages\n\n**Search:**\n- Search across retriever titles and descriptions\n- Case-insensitive regex matching\n- Combine with pagination\n\n**Filtering:**\n- By default, only active retrievers are shown\n- Set `include_inactive=true` to see all retrievers\n\n**Response includes:**\n- List of public retrievers with basic info\n- Pagination details (page, page_size, total_count, total_pages)\n- Aggregate statistics (total active, password protected, open)\n\n**What's NOT exposed:**\n- API keys (except in individual config endpoint)\n- Internal IDs or organization details\n- Full retriever configuration (use template endpoint for that)\n- Password values (only password_protected: true/false)\n\n**Example:**\n```bash\n# List all public retrievers (first page)\ncurl -X GET \"https://api.mixpeek.com/v1/public/retrievers/\"\n\n# Search for video-related retrievers\ncurl -X GET \"https://api.mixpeek.com/v1/public/retrievers/?search=video&page_size=50\"\n\n# Get page 2 with custom page size\ncurl -X GET \"https://api.mixpeek.com/v1/public/retrievers/?page=2&page_size=50\"\n```\n\n**Use Cases:**\n- Browse available public retrievers\n- Discover search patterns and implementations\n- Find retrievers to use as templates\n- Explore what others have built","operationId":"list_public_retrievers_v1_public_retrievers__get","parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","maximum":500,"minimum":1,"description":"Page number (1-indexed)","default":1,"title":"Page"},"description":"Page number (1-indexed)"},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"description":"Results per page","default":20,"title":"Page Size"},"description":"Results per page"},{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","description":"Include inactive retrievers in results","default":false,"title":"Include Inactive"},"description":"Include inactive retrievers in results"},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"description":"Search query for filtering by title or description","title":"Search"},"description":"Search query for filtering by title or description"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListPublicRetrieversResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/retrievers/{public_name}/execute":{"post":{"tags":["Public Retriever API"],"summary":"Execute Public Retriever","description":"Execute a published retriever (public endpoint).\n\n**Authentication:**\n- API key is OPTIONAL for public retrievers\n- Supports: no key, prk_ keys (deprecated), or ret_sk_ keys\n- If password-protected, requires `X-Retriever-Password` header\n\n**Rate Limiting:**\n- Subject to per-retriever rate limits (per minute/hour/day)\n- May also have IP-based rate limits\n\n**Response:**\n- Only returns fields specified in `exposed_fields` configuration\n- Internal metadata is stripped from results\n- Includes `execution_id` for interaction tracking\n- Presigned URLs returned by default (return_presigned_urls=true) for media rendering\n\n**Example (no API key - recommended for public access):**\n```bash\ncurl -X POST \"https://api.mixpeek.com/v1/public/retrievers/video-search/execute\" \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\n    \"inputs\": {\"query\": \"red car\"},\n    \"pagination\": {\"method\": \"offset\", \"page_number\": 1, \"page_size\": 10}\n  }'\n```\n\n**Example with ret_sk_ key (for SDK/programmatic access):**\n```bash\ncurl -X POST \"https://api.mixpeek.com/v1/public/retrievers/video-search/execute\" \\\n  -H \"X-Public-API-Key: ret_sk_abc123...\" \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\n    \"inputs\": {\"query\": \"red car\"},\n    \"pagination\": {\"method\": \"offset\", \"page_number\": 1, \"page_size\": 10}\n  }'\n```","operationId":"execute_public_retriever_v1_public_retrievers__public_name__execute_post","parameters":[{"name":"public_name","in":"path","required":true,"schema":{"type":"string","description":"Public name of the published retriever","title":"Public Name"},"description":"Public name of the published retriever"},{"name":"return_presigned_urls","in":"query","required":false,"schema":{"type":"boolean","description":"Generate fresh presigned download URLs for all blobs with S3 storage. Default: True for public retrievers to enable media rendering. Set to False if you only need metadata without URLs.","default":true,"title":"Return Presigned Urls"},"description":"Generate fresh presigned download URLs for all blobs with S3 storage. Default: True for public retrievers to enable media rendering. Set to False if you only need metadata without URLs."},{"name":"X-Public-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Public-Api-Key"}},{"name":"X-Retriever-Password","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Retriever-Password"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RetrieverExecutionRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/retrievers/{public_name}/config":{"get":{"tags":["Public Retriever API"],"summary":"Get Public Retriever Config","description":"Get display configuration for public page rendering.\n\n⚠️ **DEPRECATED**: Use `/v1/marketplace/catalog/{public_name}/config` instead.\nThis endpoint is maintained for backwards compatibility but may be removed in the future.\n\nReturns the UI configuration needed to render the public search interface.\nUsed by the frontend app at mxp.co to dynamically build the UI.\n\n**Authentication:**\n- NO authentication required - this endpoint is public\n- Anyone can access the config if they know the public_name\n- The config includes the public_api_key needed for execute/interact endpoints\n\n**Response includes:**\n- Display config (logo, theme, components, field rendering)\n- Title and description\n- Password protection status\n- Public API key for subsequent authenticated requests\n\n**Example (deprecated):**\n```bash\ncurl -X GET \"https://api.mixpeek.com/v1/public/retrievers/video-search/config\"\n```\n\n**Example (recommended):**\n```bash\ncurl -X GET \"https://api.mixpeek.com/v1/marketplace/catalog/video-search/config\"\n```","operationId":"get_public_retriever_config_v1_public_retrievers__public_name__config_get","parameters":[{"name":"public_name","in":"path","required":true,"schema":{"type":"string","description":"Public name of the published retriever","title":"Public Name"},"description":"Public name of the published retriever"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicRetrieverConfigResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/retrievers/{public_name}/verify":{"post":{"tags":["Public Retriever API"],"summary":"Verify Password","description":"Verify password for a password-protected retriever.\n\nAllows the frontend to check if a password is valid before attempting to execute\na password-protected retriever. Returns the public API key if the password is valid.\n\n**Authentication:**\n- NO authentication required - this endpoint is public\n- The password is verified against the retriever's configured password\n\n**Use Case:**\n1. Frontend detects that a retriever is password-protected (from /config endpoint)\n2. User enters password in the UI\n3. Frontend calls this endpoint to verify the password\n4. If valid, frontend receives the public_api_key to use for subsequent requests\n\n**Response:**\n- `valid`: Whether the password is correct\n- `public_api_key`: The API key to use for execute/interact endpoints (only if valid)\n\n**Example:**\n```bash\ncurl -X POST \"https://api.mixpeek.com/v1/public/retrievers/private-search/verify\" \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\"password\": \"secret123\"}'\n```\n\n**Response if valid:**\n```json\n{\n  \"valid\": true,\n  \"public_api_key\": \"prk_abc123...\"\n}\n```\n\n**Response if invalid:**\n```json\n{\n  \"valid\": false,\n  \"public_api_key\": null\n}\n```","operationId":"verify_password_v1_public_retrievers__public_name__verify_post","parameters":[{"name":"public_name","in":"path","required":true,"schema":{"type":"string","description":"Public name of the published retriever","title":"Public Name"},"description":"Public name of the published retriever"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VerifyPasswordRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VerifyPasswordResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/retrievers/{public_name}/interactions":{"post":{"tags":["Public Retriever API"],"summary":"Track Interaction","description":"Track user interaction with search results.\n\nRecords user engagement (clicks, views, etc.) for analytics and\npotential search optimization (Learning to Rank).\n\n**Authentication:**\n- API key is OPTIONAL (same as execute endpoint)\n- Password NOT required (tracking should work even without auth)\n\n**Recommended Headers:**\n- `X-Session-ID`: Session identifier for tracking user journey\n\n**Interaction Types:**\n- `VIEW`: Result was visible in viewport\n- `CLICK`: User clicked on result\n- `POSITIVE_FEEDBACK`: User explicitly liked result\n- `NEGATIVE_FEEDBACK`: User explicitly disliked result\n- `PURCHASE`: User purchased/converted\n- `ADD_TO_CART`: User added to cart\n- `WISHLIST`: User added to wishlist\n- `LONG_VIEW`: User spent significant time viewing\n- `SHARE`: User shared result\n- `BOOKMARK`: User bookmarked result\n\n**Example:**\n```bash\ncurl -X POST \"https://api.mixpeek.com/v1/public/retrievers/video-search/interactions\" \\\n  -H \"X-Session-ID: sess_xyz...\" \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\n    \"document_id\": \"doc_123\",\n    \"interaction_type\": [\"CLICK\"],\n    \"position\": 2,\n    \"execution_id\": \"exec_abc\",\n    \"query_snapshot\": {\"query\": \"red car\"}\n  }'\n```","operationId":"track_interaction_v1_public_retrievers__public_name__interactions_post","parameters":[{"name":"public_name","in":"path","required":true,"schema":{"type":"string","description":"Public name of the published retriever","title":"Public Name"},"description":"Public name of the published retriever"},{"name":"X-Session-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Session-Id"}},{"name":"X-Public-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Public-Api-Key"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicInteractionRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/retrievers/{public_name}/interactions/batch":{"post":{"tags":["Public Retriever API"],"summary":"Track Interaction Batch","description":"Track multiple interactions in a single request (batching).\n\nMore efficient than sending individual interaction requests.\nUse this for batching viewport visibility, bulk actions, etc.\n\n**Authentication:**\n- API key is OPTIONAL (same as execute endpoint)\n- Password NOT required (tracking should work even without auth)\n\n**Recommended Headers:**\n- `X-Session-ID`: Applied to all interactions in the batch\n\n**Limits:**\n- Maximum 100 interactions per batch\n\n**Example:**\n```bash\ncurl -X POST \"https://api.mixpeek.com/v1/public/retrievers/video-search/interactions/batch\" \\\n  -H \"X-Session-ID: sess_xyz...\" \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\n    \"interactions\": [\n      {\n        \"document_id\": \"doc_123\",\n        \"interaction_type\": [\"VIEW\"],\n        \"position\": 0,\n        \"execution_id\": \"exec_abc\"\n      },\n      {\n        \"document_id\": \"doc_456\",\n        \"interaction_type\": [\"VIEW\"],\n        \"position\": 1,\n        \"execution_id\": \"exec_abc\"\n      }\n    ]\n  }'\n```","operationId":"track_interaction_batch_v1_public_retrievers__public_name__interactions_batch_post","parameters":[{"name":"public_name","in":"path","required":true,"schema":{"type":"string","description":"Public name of the published retriever","title":"Public Name"},"description":"Public name of the published retriever"},{"name":"X-Session-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Session-Id"}},{"name":"X-Public-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Public-Api-Key"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicInteractionBatchRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/retrievers/{public_name}/template":{"get":{"tags":["Public Retriever API"],"summary":"Get Public Retriever Template","description":"Get retriever configuration as a reusable template.\n\nReturns the published retriever's configuration in a format that can be\ndirectly used to create your own retriever. This is perfect for discovering\npatterns and adapting them to your own data.\n\n**Authentication:**\n- NO authentication required - this endpoint is completely public\n- Anyone can get the template if they know the public_name\n\n**Use Case:**\n1. Browse public retrievers to find patterns you like\n2. GET this endpoint to get the full configuration\n3. Copy the config and modify for your needs (especially `collection_identifiers`)\n4. POST to `/v1/retrievers` to create your own retriever\n5. Optionally publish it with the same display_config\n\n**What's included:**\n- Retriever configuration (stages, input_schema, budget_limits)\n- Display configuration (for publishing with similar UI)\n- Original metadata for reference\n\n**What you need to change:**\n- `collection_identifiers`: Replace with your own collection IDs\n- `retriever_name`: Give it a unique name\n- Optionally modify stages, inputs, display_config as needed\n\n**Example:**\n```bash\n# 1. Get the template\ncurl -X GET \"https://api.mixpeek.com/v1/public/retrievers/video-search/template\"\n\n# 2. Modify the response and create your own retriever\ncurl -X POST \"https://api.mixpeek.com/v1/retrievers\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\n    \"retriever_name\": \"my_video_search\",\n    \"collection_identifiers\": [\"my_videos\"],\n    \"stages\": [...],  # From template\n    \"input_schema\": {...},  # From template\n    \"budget_limits\": {...},  # From template\n    \"display_config\": {...}  # From template (optional)\n  }'\n```\n\n**Response includes:**\n- All retriever configuration fields\n- Display config for publishing (optional to use)\n- Source reference (where this template came from)","operationId":"get_public_retriever_template_v1_public_retrievers__public_name__template_get","parameters":[{"name":"public_name","in":"path","required":true,"schema":{"type":"string","description":"Public name of the published retriever","title":"Public Name"},"description":"Public name of the published retriever"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicRetrieverTemplateResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/auth/token-exchange":{"post":{"tags":["Authentication"],"summary":"Exchange a workload OIDC token for a short-lived API key","description":"Trade the OIDC token a workload's platform issued for a Mixpeek API key.\n\nConfigure a workload identity provider on the organization first (``PATCH\n/v1/organizations`` with ``workload_identity_providers``, or Studio >\nSettings > Organization > Workload identity). The workload then sends its\ntoken here with the provider's ``provider_id`` and uses the returned\n``access_token`` as ``Authorization: Bearer <access_token>`` until\n``expires_at``. No API key is needed to call this route.\n\nOn Vercel, the token is ``getVercelOidcToken()`` from ``@vercel/oidc``; on\nGitHub Actions it is ``core.getIDToken(audience)`` with ``permissions:\nid-token: write``.","operationId":"token_exchange_v1_auth_token_exchange_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenExchangeRequest"}}},"required":true,"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenExchangeResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"The token failed verification or the provider is unknown.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"The token's claims do not match the provider's conditions.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too many exchanges for this provider in the last minute.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/templates/scaffolds":{"get":{"tags":["Public Templates API","Public Scaffolds"],"summary":"List Scaffolds","description":"List available scaffold templates (public, no auth required).\n\nScaffolds are pre-configured templates that create complete infrastructure:\n- Namespace with feature extractors\n- Bucket with data schema\n- Collection with processing config\n- Retriever with search pipeline\n\n**Categories:**\n- `media` - Video, image, podcast search\n- `documents` - Document Q&A, RAG\n- `ecommerce` - Product catalog search\n\n**To instantiate (requires auth):**\n```\nPOST /v1/templates/scaffolds/{template_id}/instantiate\n{\"namespace_name\": \"my_app\"}\n```","operationId":"list_scaffolds_v1_public_templates_scaffolds_get","parameters":[{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by category (media, documents, ecommerce)","title":"Category"},"description":"Filter by category (media, documents, ecommerce)"},{"name":"is_active","in":"query","required":false,"schema":{"type":"boolean","description":"Only show active templates","default":true,"title":"Is Active"},"description":"Only show active templates"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/BaseTemplateModel"},"title":"Response List Scaffolds V1 Public Templates Scaffolds Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/templates/scaffolds/{template_id}":{"get":{"tags":["Public Templates API","Public Scaffolds"],"summary":"Get Scaffold","description":"Get scaffold template details (public, no auth required).\n\nReturns the complete configuration including:\n- Namespace: feature extractors, payload indexes\n- Bucket: name, description, schema\n- Collection: feature extractor config\n- Retriever: stages, input schema\n\n**To instantiate (requires auth):**\n```\nPOST /v1/templates/scaffolds/{template_id}/instantiate\n{\"namespace_name\": \"my_app\"}\n```","operationId":"get_scaffold_v1_public_templates_scaffolds__template_id__get","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","description":"Scaffold template ID","title":"Template Id"},"description":"Scaffold template ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BaseTemplateModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/templates/scaffolds/{template_id}/sample-data":{"get":{"tags":["Public Templates API","Public Scaffolds"],"summary":"Get Scaffold Sample Data","description":"Live per-collection document counts of the scaffold's golden sample\nnamespace (public, no auth required).\n\nPowers the Studio pre-clone preview: what a user actually gets when they\nclone this scaffold with sample data. Counts are live-derived server-side\n(cached ~10 min) because golden namespaces are not readable with normal\norg keys.","operationId":"get_scaffold_sample_data_v1_public_templates_scaffolds__template_id__sample_data_get","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","description":"Scaffold template ID","title":"Template Id"},"description":"Scaffold template ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScaffoldSampleDataResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/templates/scaffolds/{template_id}/manifest":{"get":{"tags":["Public Templates API","Public Scaffolds"],"summary":"Get Scaffold Manifest","description":"Render a scaffold template as a Mixpeek manifest (public, no auth).\n\nPowers the Studio namespace-templates UI, which shows each template as a\ndeclarative manifest tree + copyable YAML (the same IaC format used by\n`POST /v1/manifest/apply`). Returns both the YAML string (`manifest_yaml`)\nand the parsed manifest dict (`manifest`).","operationId":"get_scaffold_manifest_v1_public_templates_scaffolds__template_id__manifest_get","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","description":"Scaffold template ID","title":"Template Id"},"description":"Scaffold template ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScaffoldManifestResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/templates/namespaces":{"get":{"tags":["Public Templates API"],"summary":"List Public Namespace Templates","description":"List public namespace templates (no authentication required).\n\nReturns only templates marked as public (is_public=True).","operationId":"list_public_namespace_templates_v1_public_templates_namespaces_get","parameters":[{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by category","title":"Category"},"description":"Filter by category"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/BaseTemplateModel"},"title":"Response List Public Namespace Templates V1 Public Templates Namespaces Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/templates/namespaces/{template_id}":{"get":{"tags":["Public Templates API"],"summary":"Get Public Namespace Template","description":"Get public namespace template details (no authentication required).\n\nReturns template only if marked as public.","operationId":"get_public_namespace_template_v1_public_templates_namespaces__template_id__get","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","description":"Template ID","title":"Template Id"},"description":"Template ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BaseTemplateModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/templates/retrievers":{"get":{"tags":["Public Templates API"],"summary":"List Public Retriever Templates","description":"List public retriever templates (no authentication required).\n\nReturns only templates marked as public (is_public=True).","operationId":"list_public_retriever_templates_v1_public_templates_retrievers_get","parameters":[{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by category","title":"Category"},"description":"Filter by category"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/BaseTemplateModel"},"title":"Response List Public Retriever Templates V1 Public Templates Retrievers Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/templates/retrievers/{template_id}":{"get":{"tags":["Public Templates API"],"summary":"Get Public Retriever Template","description":"Get public retriever template details (no authentication required).\n\nReturns template only if marked as public.","operationId":"get_public_retriever_template_v1_public_templates_retrievers__template_id__get","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","description":"Template ID","title":"Template Id"},"description":"Template ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BaseTemplateModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/apps/{slug}/config":{"get":{"tags":["Public Apps API"],"summary":"Get public App config","description":"Fetch the full configuration for a public App — no authentication required.\n\nUsed by the `canvas/` host runtime and the `@mixpeek/canvas-sdk`\n`useApp()` hook to render the app. Returns tabs, hero, stats, sections,\ntheme, and SEO settings.\n\nServes the `published_config` snapshot when available, so draft edits\nmade via `PATCH /v1/apps/{app_id}` are not visible until the app is\npublished.","operationId":"get_public_app_config_v1_public_apps__slug__config_get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","description":"Globally unique app slug","title":"Slug"},"description":"Globally unique app slug"}],"responses":{"200":{"description":"Full app configuration for UI rendering","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicAppConfigResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/apps/{slug}/search":{"post":{"tags":["Public Apps API"],"summary":"Execute an App tab search","description":"Execute a search on a specific tab of a public App — no authentication required.\n\nRoutes `tab_id` → retriever → results. Each tab can be backed by either:\n- An **internal retriever** (`retriever_id`) — org-scoped\n- A **marketplace catalog entry** (`public_name`) — proxied via public API\n\nThe `inputs` dict is passed directly to the retriever's `input_schema`.\nExtra top-level fields are automatically merged into `inputs`.\n\n**Example:**\n```json\n{\n  \"tab_id\": \"search\",\n  \"inputs\": { \"query\": \"red sneakers\" },\n  \"settings\": { \"limit\": 20 }\n}\n```","operationId":"execute_public_app_search_v1_public_apps__slug__search_post","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","description":"Globally unique app slug","title":"Slug"},"description":"Globally unique app slug"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicAppSearchRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Search results from the tab's retriever","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/apps/{slug}/gallery":{"get":{"tags":["Public Apps API"],"summary":"Get App featured gallery","description":"Fetch featured gallery results for a public App — no authentication required.\n\nExecutes the app's `featured_gallery` retriever using `default_inputs`\ndefined in the gallery configuration. Returns an empty result set if the\ngallery is disabled or not configured.","operationId":"get_public_app_gallery_v1_public_apps__slug__gallery_get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","description":"Globally unique app slug","title":"Slug"},"description":"Globally unique app slug"}],"responses":{"200":{"description":"Featured gallery results using the gallery's default inputs","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/apps/{slug}/interactions":{"post":{"tags":["Public Apps API"],"summary":"Track an App interaction event","description":"Record a user interaction event for a public App — no authentication required.\n\nInteraction events are written to the ``app_interactions`` collection for\nanalytics and relevance tuning. Write errors are swallowed server-side so\nthat a transient storage failure never surfaces as an error to the caller.\n\n**Example:**\n```json\n{\n  \"event_type\": \"click\",\n  \"document_id\": \"doc_abc123\",\n  \"position\": 2,\n  \"query\": \"red sneakers\",\n  \"session_id\": \"sess_xyz\"\n}\n```","operationId":"track_public_app_interaction_v1_public_apps__slug__interactions_post","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","description":"Globally unique app slug","title":"Slug"},"description":"Globally unique app slug"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InteractionRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Acknowledgement that the event was recorded","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Track Public App Interaction V1 Public Apps  Slug  Interactions Post"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/apps/{slug}/taxonomies/{taxonomy_id}/tree":{"get":{"tags":["Public Apps API"],"summary":"Get taxonomy node tree for an App","description":"Fetch the node tree for a taxonomy associated with a public App — no authentication required.\n\nLooks up the taxonomy by ``taxonomy_id`` within the namespace that owns\nthe app identified by ``slug``. Returns the full ``nodes`` array as stored,\nwhich can be used to render faceted navigation or classification trees in\nthe app UI.","operationId":"get_public_app_taxonomy_tree_v1_public_apps__slug__taxonomies__taxonomy_id__tree_get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","description":"Globally unique app slug","title":"Slug"},"description":"Globally unique app slug"},{"name":"taxonomy_id","in":"path","required":true,"schema":{"type":"string","description":"Taxonomy ID to retrieve","title":"Taxonomy Id"},"description":"Taxonomy ID to retrieve"}],"responses":{"200":{"description":"Full taxonomy node tree scoped to the App's namespace","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxonomyTreeResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/extractors/":{"get":{"tags":["Public Extractor Marketplace"],"summary":"List Public Extractors","description":"Browse and search public extractors.\n\nNo authentication required. Returns active extractors sorted by install count.","operationId":"list_public_extractors_v1_public_extractors__get","parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","maximum":500,"minimum":1,"description":"Page number (1-indexed)","default":1,"title":"Page"},"description":"Page number (1-indexed)"},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"description":"Results per page","default":20,"title":"Page Size"},"description":"Results per page"},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"description":"Search query","title":"Search"},"description":"Search query"},{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"description":"Filter by category","title":"Category"},"description":"Filter by category"},{"name":"capability","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by capability (batch, realtime)","title":"Capability"},"description":"Filter by capability (batch, realtime)"},{"name":"tags","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"null"}],"description":"Filter by tags (all must match)","title":"Tags"},"description":"Filter by tags (all must match)"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListPublicExtractorsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/public/extractors/{public_name}":{"get":{"tags":["Public Extractor Marketplace"],"summary":"Get Public Extractor","description":"Get full detail for a public extractor including manifest and readme.","operationId":"get_public_extractor_v1_public_extractors__public_name__get","parameters":[{"name":"public_name","in":"path","required":true,"schema":{"type":"string","description":"Public name of the extractor","title":"Public Name"},"description":"Public name of the extractor"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicExtractorDetailResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/apps":{"post":{"tags":["Apps"],"summary":"Create an App","description":"Create a new App.\n\nApps are full-stack web applications deployed as zip bundles to\n``{slug}.mxp.co``.  After creation, deploy your built frontend via the\ndeploy pipeline:\n\n1. ``POST /v1/apps/{app_id}/deploy/upload-url`` — get a presigned S3 PUT URL\n2. Upload your built ``dist/`` zip to that URL\n3. ``POST /v1/apps/{app_id}/deploy`` — trigger the build\n\nOnly ``slug`` and ``meta`` are required.  Set ``auth_config.mode`` to\ncontrol end-user authentication (``public``, ``clerk``, ``password``,\n``api_key``, ``jwt``, ``sso_oidc``, ``sso_saml``).\n\nSlugs are globally unique across all organizations.\n\n**Deprecated fields:** ``template``, ``sections``, ``custom_html``,\n``hero``, ``theme``, ``seo``, ``stats``, ``featured_gallery``, ``tabs``,\n``password_secret_name`` are accepted for backward compatibility but\nshould not be used for new apps.\n\n**Tier limits:** Free = 1 app, Pro = 10, Enterprise = unlimited\n(``TierLimits._max_apps``). Exceeding your tier's limit returns a 400 with\nthe limit + current count in ``error.details``.","operationId":"create_app_v1_apps_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateAppRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"The created App configuration","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]},"get":{"tags":["Apps"],"summary":"List Apps","description":"List all Apps for this organization.\n\nThe response includes ``max_apps`` (the tier's Canvas App limit, ``null`` =\nunlimited) so the UI can render usage (\"X of N apps used\") and gate the\ncreate action without a second round-trip.","operationId":"list_apps_v1_apps_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"default":100,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"template","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by template type","title":"Template"},"description":"Filter by template type"},{"name":"slug","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Exact match on app slug","title":"Slug"},"description":"Exact match on app slug"},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Case-insensitive partial match on app name","title":"Search"},"description":"Case-insensitive partial match on app name"}],"responses":{"200":{"description":"Paginated list of Apps for this organization","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListAppsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}":{"get":{"tags":["Apps"],"summary":"Get an App","description":"Get an App by its `app_id`.","operationId":"get_app_v1_apps__app_id__get","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","description":"App ID (e.g. app_abc123def456)","title":"App Id"},"description":"App ID (e.g. app_abc123def456)"}],"responses":{"200":{"description":"Full App configuration","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]},"patch":{"tags":["Apps"],"summary":"Update an App","description":"Partially update an App configuration (saved as draft).\n\nAll fields are optional — only the fields you provide are updated.\nUpdates are draft by default. Set `publish: true` to apply and publish\nin a single call.\n\nSet `dry_run=true` to check slug availability only, with no write.","operationId":"update_app_v1_apps__app_id__patch","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","description":"App ID (e.g. app_abc123def456)","title":"App Id"},"description":"App ID (e.g. app_abc123def456)"},{"name":"dry_run","in":"query","required":false,"schema":{"type":"boolean","description":"Check candidate slug availability (global uniqueness + reserved words) without writing anything, then return the app unchanged. Only slug is checked under dry_run; other fields in the body are ignored. Use this instead of PATCHing a live app repeatedly to probe for an open slug.","default":false,"title":"Dry Run"},"description":"Check candidate slug availability (global uniqueness + reserved words) without writing anything, then return the app unchanged. Only slug is checked under dry_run; other fields in the body are ignored. Use this instead of PATCHing a live app repeatedly to probe for an open slug."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateAppRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Updated App configuration","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]},"delete":{"tags":["Apps"],"summary":"Delete an App","description":"Delete an App permanently.\n\nThe slug is freed immediately. Any active custom domains will stop\nresolving within seconds.","operationId":"delete_app_v1_apps__app_id__delete","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","description":"App ID (e.g. app_abc123def456)","title":"App Id"},"description":"App ID (e.g. app_abc123def456)"}],"responses":{"200":{"description":"Deletion confirmation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenericDeleteResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/publish":{"post":{"tags":["Apps"],"summary":"Publish an App","description":"Publish the current draft config of an App.\n\nFor deploy-based apps, code deploys go live automatically — you only\nneed this endpoint to publish **config changes** (auth, meta, etc.).\n\nCreates an immutable version snapshot with a content hash.","operationId":"publish_app_v1_apps__app_id__publish_post","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","description":"App ID (e.g. app_abc123def456)","title":"App Id"},"description":"App ID (e.g. app_abc123def456)"}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/PublishAppRequest"},{"type":"null"}],"title":"Payload"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"The published App configuration","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/rollback":{"post":{"tags":["Apps"],"summary":"Rollback an App","description":"Rollback to the previous published config version.\n\nFor deploy-based apps, use ``POST /v1/apps/{app_id}/versions/{version}/restore``\nto roll back to any previous code deploy instead.","operationId":"rollback_app_v1_apps__app_id__rollback_post","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","description":"App ID (e.g. app_abc123def456)","title":"App Id"},"description":"App ID (e.g. app_abc123def456)"}],"responses":{"200":{"description":"The restored App configuration","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/domains":{"post":{"tags":["Apps"],"summary":"Add a custom domain","description":"Attach a custom domain to an App.\n\nReturns a `verification_token` and `cname_target`. To prove ownership,\nadd a DNS TXT record:\n\n    _mixpeek-verify.{domain}  TXT  \"mixpeek-site-verification={verification_token}\"\n\nThen call `POST /{app_id}/domains/{domain}/verify` to start polling.","operationId":"add_domain_v1_apps__app_id__domains_post","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","description":"App ID (e.g. app_abc123def456)","title":"App Id"},"description":"App ID (e.g. app_abc123def456)"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddDomainRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"The newly added domain configuration","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DomainResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]},"get":{"tags":["Apps"],"summary":"List custom domains","description":"List all custom domains attached to an App.","operationId":"list_domains_v1_apps__app_id__domains_get","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","description":"App ID (e.g. app_abc123def456)","title":"App Id"},"description":"App ID (e.g. app_abc123def456)"}],"responses":{"200":{"description":"All custom domains attached to the App","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListDomainsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/domains/{domain}/verify":{"post":{"tags":["Apps"],"summary":"Trigger DNS verification","description":"Trigger asynchronous DNS TXT record verification for a domain.\n\nThe domain status is set to `verifying` immediately. A background worker\npolls DNS every 30 minutes for up to 72 hours. On success the status\nadvances to `provisioning_tls`.","operationId":"verify_domain_v1_apps__app_id__domains__domain__verify_post","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","description":"App ID (e.g. app_abc123def456)","title":"App Id"},"description":"App ID (e.g. app_abc123def456)"},{"name":"domain","in":"path","required":true,"schema":{"type":"string","description":"Domain to verify (e.g. search.acme.com)","title":"Domain"},"description":"Domain to verify (e.g. search.acme.com)"}],"responses":{"200":{"description":"Domain record with status set to 'verifying'","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DomainResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/domains/{domain}":{"delete":{"tags":["Apps"],"summary":"Remove a domain","description":"Remove a custom domain from an App.","operationId":"delete_domain_v1_apps__app_id__domains__domain__delete","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","description":"App ID (e.g. app_abc123def456)","title":"App Id"},"description":"App ID (e.g. app_abc123def456)"},{"name":"domain","in":"path","required":true,"schema":{"type":"string","description":"Domain to remove (e.g. search.acme.com)","title":"Domain"},"description":"Domain to remove (e.g. search.acme.com)"}],"responses":{"200":{"description":"Deletion confirmation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenericDeleteResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/users":{"get":{"tags":["Apps"],"summary":"List app users","description":"List all users in this app's Clerk organization.","operationId":"list_app_users_v1_apps__app_id__users_get","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","description":"App ID","title":"App Id"},"description":"App ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListUsersResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/users/invite":{"post":{"tags":["Apps"],"summary":"Invite a user","description":"Invite a user to this app by email via Clerk.","operationId":"invite_app_user_v1_apps__app_id__users_invite_post","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","description":"App ID","title":"App Id"},"description":"App ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InviteUserRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppInvitationResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/users/{user_id}":{"delete":{"tags":["Apps"],"summary":"Remove a user","description":"Remove a user from this app's Clerk organization.","operationId":"remove_app_user_v1_apps__app_id__users__user_id__delete","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","description":"App ID","title":"App Id"},"description":"App ID"},{"name":"user_id","in":"path","required":true,"schema":{"type":"string","description":"Clerk user ID","title":"User Id"},"description":"Clerk user ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenericDeleteResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/users/{user_id}/role":{"patch":{"tags":["Apps"],"summary":"Update user role","description":"Update a user's role in this app's Clerk organization.","operationId":"update_app_user_role_v1_apps__app_id__users__user_id__role_patch","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","description":"App ID","title":"App Id"},"description":"App ID"},{"name":"user_id","in":"path","required":true,"schema":{"type":"string","description":"Clerk user ID","title":"User Id"},"description":"Clerk user ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateRoleRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppUserResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/users/invitations":{"get":{"tags":["Apps"],"summary":"List pending invitations","description":"List pending invitations for this app's Clerk organization.","operationId":"list_app_invitations_v1_apps__app_id__users_invitations_get","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","description":"App ID","title":"App Id"},"description":"App ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListInvitationsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/users/invitations/{invitation_id}":{"delete":{"tags":["Apps"],"summary":"Revoke an invitation","description":"Revoke a pending invitation.","operationId":"revoke_app_invitation_v1_apps__app_id__users_invitations__invitation_id__delete","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","description":"App ID","title":"App Id"},"description":"App ID"},{"name":"invitation_id","in":"path","required":true,"schema":{"type":"string","description":"Clerk invitation ID","title":"Invitation Id"},"description":"Clerk invitation ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenericDeleteResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/deploy/upload-url":{"post":{"tags":["Apps"],"summary":"Get presigned upload URL","description":"Generate a presigned S3 PUT URL so the CLI can upload a bundle zip directly.\nPass the returned `bundle_s3_key` to the deploy endpoint.","operationId":"get_upload_url_v1_apps__app_id__deploy_upload_url_post","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","title":"App Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UploadUrlRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UploadUrlResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/deploy/verify-upload":{"post":{"tags":["Apps"],"summary":"Verify a presigned-URL upload landed in S3","description":"Confirm a bundle uploaded via a presigned PUT URL actually landed in S3.\n\nS3 returns an empty body on a successful PUT — the ETag is only in\nresponse headers, which browser clients often can't read due to CORS.\nThis endpoint does a server-side HEAD and returns {etag, size_bytes,\nlast_modified, exists} so clients can verify the upload before calling\n`/deploy`.","operationId":"verify_upload_v1_apps__app_id__deploy_verify_upload_post","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","title":"App Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VerifyUploadRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VerifyUploadResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/deploy":{"post":{"tags":["Apps"],"summary":"Deploy an App","description":"Queue a build+deploy for an App, creating a new version.\n\n**Full deploy workflow:**\n1. `POST /{app_id}/deploy/upload-url` → get a presigned S3 PUT URL\n2. Upload your built dist/ zip to that URL\n3. Call this endpoint with the returned `bundle_s3_key`\n4. Optionally include `source_files` (path→content map) for version diffing\n5. Poll `GET /{app_id}/deploys/{deploy_id}` until status is `complete`\n\n**Edit-and-redeploy workflow:**\n1. `GET /{app_id}/versions/{version}/download` → download the bundle zip\n2. Edit files locally\n3. Re-zip and upload via upload-url → deploy (creates a new version)\n4. `GET /{app_id}/versions/{old}/diff/{new}` to review changes\n\nEach deploy creates an immutable version record. Use `POST /{app_id}/versions/{n}/restore`\nfor instant rollback to any previous version.","operationId":"deploy_app_v1_apps__app_id__deploy_post","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","title":"App Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeployRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeployResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/versions":{"get":{"tags":["Apps"],"summary":"List version history","description":"Return version history for an App, most recent first.","operationId":"list_versions_v1_apps__app_id__versions_get","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","title":"App Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VersionListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/versions/{version}/restore":{"post":{"tags":["Apps"],"summary":"Restore a previous version","description":"Restore a previous version by pointing the environment to its assets.\n\nThis is instant — no rebuild required. Old assets are always retained in S3.","operationId":"restore_version_v1_apps__app_id__versions__version__restore_post","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","title":"App Id"}},{"name":"version","in":"path","required":true,"schema":{"type":"integer","description":"Version number to restore","title":"Version"},"description":"Version number to restore"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RestoreVersionRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RestoreVersionResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/versions/{version}":{"get":{"tags":["Apps"],"summary":"Get version details","description":"Return full details for a specific version including asset manifest and source files.","operationId":"get_version_v1_apps__app_id__versions__version__get","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","title":"App Id"}},{"name":"version","in":"path","required":true,"schema":{"type":"integer","description":"Version number","title":"Version"},"description":"Version number"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VersionDetailResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/versions/{version}/download":{"get":{"tags":["Apps"],"summary":"Download a version's bundle","description":"Get a presigned download URL for a version's original bundle zip.\n\nUse this to download → edit → re-upload → deploy as a new version.\nThe returned URL expires in 1 hour.","operationId":"download_version_v1_apps__app_id__versions__version__download_get","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","title":"App Id"}},{"name":"version","in":"path","required":true,"schema":{"type":"integer","description":"Version number to download","title":"Version"},"description":"Version number to download"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DownloadUrlResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/versions/{from_version}/diff/{to_version}":{"get":{"tags":["Apps"],"summary":"Diff two versions","description":"Compare two versions — returns file-level changes and optional source diffs.\n\nLike `git diff v1..v2`: shows added, removed, modified, and unchanged files\nbased on content hashes. If both versions have source_files, also returns\nunified diffs of the source code.","operationId":"diff_versions_v1_apps__app_id__versions__from_version__diff__to_version__get","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","title":"App Id"}},{"name":"from_version","in":"path","required":true,"schema":{"type":"integer","description":"Base version","title":"From Version"},"description":"Base version"},{"name":"to_version","in":"path","required":true,"schema":{"type":"integer","description":"Target version","title":"To Version"},"description":"Target version"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VersionDiffResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/deploys/{deploy_id}":{"get":{"tags":["Apps"],"summary":"Get deploy status","description":"Check the status of a specific deployment (queued, building, complete, failed).","operationId":"get_deploy_status_v1_apps__app_id__deploys__deploy_id__get","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","title":"App Id"}},{"name":"deploy_id","in":"path","required":true,"schema":{"type":"string","description":"Deploy ID","title":"Deploy Id"},"description":"Deploy ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeployStatusResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/deploys/{deploy_id}/logs/stream":{"get":{"tags":["Apps"],"summary":"Stream deploy logs (SSE)","description":"Server-Sent Events stream of real-time deploy logs.\n\nSends cached logs first (catch-up), then subscribes to live log\nevents via Redis pub/sub until the deploy reaches a terminal state.","operationId":"stream_deploy_logs_v1_apps__app_id__deploys__deploy_id__logs_stream_get","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","title":"App Id"}},{"name":"deploy_id","in":"path","required":true,"schema":{"type":"string","title":"Deploy Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/promote":{"post":{"tags":["Apps"],"summary":"Promote staging to production","description":"Promote the current staging deployment to production.\n\nCopies `environments.staging` (deploy_id, asset_prefix) to\n`environments.production` and updates `build_config.asset_prefix`\nfor backward compatibility. Also invalidates the canvas asset cache\nso the new production version is served immediately.","operationId":"promote_app_v1_apps__app_id__promote_post","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","description":"App ID (e.g. app_abc123def456)","title":"App Id"},"description":"App ID (e.g. app_abc123def456)"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromoteResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/connect-repo":{"post":{"tags":["Apps"],"summary":"Connect a GitHub repository","description":"Connect a GitHub repository for automatic deploys on push.\n\nAfter connecting, pushes to the configured branch will trigger\na build + deploy via the GitHub App webhook.","operationId":"connect_repo_v1_apps__app_id__connect_repo_post","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","title":"App Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectRepoRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]},"delete":{"tags":["Apps"],"summary":"Disconnect GitHub repository","description":"Disconnect the GitHub repository from this app.","operationId":"disconnect_repo_v1_apps__app_id__connect_repo_delete","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","title":"App Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/github/install-url":{"get":{"tags":["Apps"],"summary":"Get the GitHub App install URL for this app","description":"Return the GitHub App installation URL carrying a signed ``state``.\n\nThe Studio \"Install GitHub App\" button opens this URL; after install,\nGitHub redirects to ``/webhooks/apps/github/setup`` which verifies the\nsignature and links the installation to this app.","operationId":"github_install_url_v1_apps__app_id__github_install_url_get","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","title":"App Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/error-rate":{"get":{"tags":["Apps"],"summary":"Get recent error rate","description":"Count of canvas_errors for this app in the last N minutes.","operationId":"get_error_rate_v1_apps__app_id__error_rate_get","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","title":"App Id"}},{"name":"minutes","in":"query","required":false,"schema":{"type":"integer","maximum":1440,"minimum":1,"description":"Lookback window in minutes","default":60,"title":"Minutes"},"description":"Lookback window in minutes"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorRateResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/analytics":{"get":{"tags":["Apps"],"summary":"Get app analytics overview","description":"Per-app analytics dashboard data: error trend, Web Vitals, recent errors, event counts.\n\nReads the canvas_errors, canvas_vitals and canvas_app_events collections.","operationId":"get_app_analytics_v1_apps__app_id__analytics_get","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","title":"App Id"}},{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":720,"minimum":1,"description":"Lookback window in hours","default":24,"title":"Hours"},"description":"Lookback window in hours"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppAnalyticsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/apps/{app_id}/logs":{"get":{"tags":["Apps"],"summary":"Get runtime or request logs","description":"Read the canvas_app_logs or canvas_request_logs collection.","operationId":"get_app_logs_v1_apps__app_id__logs_get","parameters":[{"name":"app_id","in":"path","required":true,"schema":{"type":"string","title":"App Id"}},{"name":"log_type","in":"query","required":false,"schema":{"enum":["runtime","requests"],"type":"string","description":"Which log stream: 'runtime' (console/app logs from canvas_app_logs) or 'requests' (HTTP request logs from canvas_request_logs). Any other value is a 422 naming these — previously 'request' (singular) silently fell through to the runtime branch and returned nothing.","default":"runtime","title":"Log Type"},"description":"Which log stream: 'runtime' (console/app logs from canvas_app_logs) or 'requests' (HTTP request logs from canvas_request_logs). Any other value is a 422 naming these — previously 'request' (singular) silently fell through to the runtime branch and returned nothing."},{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":168,"minimum":1,"description":"Lookback window in hours","default":1,"title":"Hours"},"description":"Lookback window in hours"},{"name":"level","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by log level (runtime only)","title":"Level"},"description":"Filter by log level (runtime only)"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"description":"Max entries","default":100,"title":"Limit"},"description":"Max entries"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppLogsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/events":{"get":{"tags":["Events"],"summary":"List change feed events","description":"List this organization's change feed, ordered and resumable by cursor.\n\n**Scope**: org-global by default — one ordered sequence across every\nnamespace and resource type. An `X-Namespace` header (or `namespace_id`\nquery param) narrows it to one namespace's events. Events recorded\nbefore namespace stamping shipped (2026-08) carry no namespace and are\nexcluded by ANY namespace filter — a namespace-filtered read is not a\nreplay of history older than that.\n\nA consumer can be killed mid-stream and resume from its last stored\n`next_cursor` without re-reading or missing anything, **as long as it\nresumes within the 90-day retention window** — events older than that\nare permanently expired, not archived. A consumer that has been down\nlonger than 90 days must resync current state instead of resuming.\n\nA cursor is only meaningful for a FIXED filter set: it encodes a\nposition in this organization's overall sequence, not a position\nwithin any particular `namespace_id`/`event_type` filter. Changing\neither filter mid-stream while reusing an old cursor silently skips\nwhatever the previous filter combination would have matched in\nbetween — start a fresh cursor (or none) whenever the filters change.\n\nHigh-churn event types (`object.*` under active storage syncs) can bury\nsparse ones thousands of pages deep in the unfiltered walk — a consumer\nlooking for one type should pass `event_type` rather than walking\neverything.","operationId":"list_events_v1_events_get","parameters":[{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Opaque cursor from a prior response's next_cursor. Omit to start from the beginning of the 90-day retention window.","title":"Cursor"},"description":"Opaque cursor from a prior response's next_cursor. Omit to start from the beginning of the 90-day retention window."},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Alias for `cursor` — the response surfaces this name, so feeding it back must work. If both are given, `cursor` wins.","title":"Next Cursor"},"description":"Alias for `cursor` — the response surfaces this name, so feeding it back must work. If both are given, `cursor` wins."},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Alias for `cursor`. If both are given, `cursor` wins.","title":"After"},"description":"Alias for `cursor`. If both are given, `cursor` wins."},{"name":"namespace_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter to events scoped to one namespace (ns_ id or name). The X-Namespace header does the same; if both are present they must agree.","title":"Namespace Id"},"description":"Filter to events scoped to one namespace (ns_ id or name). The X-Namespace header does the same; if both are present they must agree."},{"name":"event_type","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/WebhookEventType"},{"type":"null"}],"description":"Filter to one event type.","title":"Event Type"},"description":"Filter to one event type."},{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"description":"Page size (default 100).","title":"Limit"},"description":"Page size (default 100)."},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"description":"Alias for `limit`. If both are given, `limit` wins.","title":"Page Size"},"description":"Alias for `limit`. If both are given, `limit` wins."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListEventsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/health/liveness":{"get":{"tags":["Health"],"summary":"Liveness","description":"Lightweight liveness probe for container orchestration (Render, K8s).\n\nThis endpoint returns immediately without checking external services.\nUse this for Render health checks to avoid timeouts when services are slow.","operationId":"liveness_v1_health_liveness_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/health/beat":{"get":{"tags":["Health"],"summary":"Scheduler Health","description":"Check that this plane's work scheduler is running.\n\nReads the scheduler's `last_tick` from `work_schedules`. The scheduler\nwrites it each time it fires an entry, and the schedule has several\nevery-minute entries, so a heartbeat older than 5 minutes means it stopped.\nThe response keeps the fields this route has always returned\n(`beat_running`, `last_heartbeat`, `age_seconds`).","operationId":"celery_beat_health_v1_health_beat_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/health":{"get":{"tags":["Health"],"summary":"Healthcheck","description":"Lightweight health check — confirms the process is alive and the event loop\nis responding.  Completes in <10ms with no external service calls.\n\nUse ``GET /v1/health/deep`` for the full service-level health check.","operationId":"healthcheck_v1_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/health/deep":{"get":{"tags":["Health"],"summary":"Healthcheck Deep","description":"Full health check — pings every dependent service with aggressive per-service\ntimeouts (500ms) so total wall time stays under ~3s even when a service is slow.\n\nUse the ``deep=true`` query parameter for additional data-plane verification\n(e.g. reading from MongoDB collections, probing MVS namespaces, listing\nthe live work dispatchers).","operationId":"healthcheck_deep_v1_health_deep_get","parameters":[{"name":"deep","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Deep"}},{"name":"metrics","in":"query","required":false,"schema":{"type":"boolean","description":"Include Layer 2 protection metrics","default":false,"title":"Metrics"},"description":"Include Layer 2 protection metrics"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HealthCheckResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/resources/search":{"post":{"tags":["Resource Search"],"summary":"Search Resources","description":"Search across all resource names and IDs within your namespace.\n\n    This endpoint performs a case-insensitive search across:\n    - Buckets (bucket_name, bucket_id)\n    - Collections (collection_name, collection_id)\n    - Retrievers (retriever_name, retriever_id)\n    - Taxonomies (taxonomy_name, taxonomy_id)\n    - Clusters (cluster_name, cluster_id)\n    - Namespaces (namespace_name, namespace_id)\n\n    Results are sorted by relevance (exact matches first) and creation time (newest first).\n    Use the resource_types parameter to filter searches to specific resource types.\n    Pagination is supported via limit and offset parameters.","operationId":"search_resources_v1_resources_search_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/collections/features/extractors":{"get":{"tags":["Feature Extractors"],"summary":"List Feature Extractors","description":"List all available feature extractors grouped by category","operationId":"list_feature_extractors_v1_collections_features_extractors_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/FeatureExtractorResponseModel"},"type":"array","title":"Response List Feature Extractors V1 Collections Features Extractors Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/collections/features/extractors/{feature_extractor_id}":{"get":{"tags":["Feature Extractors"],"summary":"Get Feature Extractor by Name","description":"Get detailed information about a specific feature extractor by its name","operationId":"get_feature_extractor_by_id_v1_collections_features_extractors__feature_extractor_id__get","parameters":[{"name":"feature_extractor_id","in":"path","required":true,"schema":{"type":"string","title":"Feature Extractor Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FeatureExtractorResponseModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/collections/features":{"get":{"tags":["Features"],"summary":"Discover Features","description":"The menu of what you can search by: each file type (modality), its billing unit, and the search features available on it (with rates). Feature keys are the values accepted by collection config `features: [...]`. No authentication required.","operationId":"discover_features_v1_collections_features_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FeatureDiscoveryResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/features/search":{"post":{"tags":["Feature Search"],"summary":"Feature Search","description":"Search documents by vector similarity across collections. A convenience wrapper that builds an ad-hoc retriever with a single feature_search stage.","operationId":"feature_search_v1_features_search_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FeatureSearchRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/collections/import/infer":{"post":{"tags":["Collections"],"summary":"Infer import schema","description":"Infer source fields + types from a sample of an external export and return a suggested source->target mapping for the collection-import wizard. Runs on the sample alone; no data is written.","operationId":"infer_import_schema_v1_collections_import_infer_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SchemaInferenceRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SchemaInferenceResult"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/collections/import/validate-mapping":{"post":{"tags":["Collections"],"summary":"Validate an import mapping","description":"Validate a finalized source->target mapping before any import. Flags a missing root-identity mapping, source/target type mismatches, vector-dim mismatches against a known index, and unknown source fields.","operationId":"validate_import_mapping_v1_collections_import_validate_mapping_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MappingValidationRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MappingValidationResult"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/collections/{collection_identifier}/import":{"post":{"tags":["Collections"],"summary":"Import external documents into a collection","description":"Reconstruct documents (with vectors + lineage) from one external export using a validated mapping, and write them into the collection via the BYO write core. Use /import/infer and /import/validate-mapping first; dry_run reconstructs and validates without writing.","operationId":"import_collection_documents_v1_collections__collection_identifier__import_post","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID or name of the collection to import into","title":"Collection Identifier"},"description":"The ID or name of the collection to import into"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImportRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImportResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":true,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/collections":{"post":{"tags":["Collections"],"summary":"Create Collection","description":"Create a new processing collection linked to a namespace.\n\nA collection defines the feature extraction pipeline that runs when objects are\nuploaded to a bucket.  One feature extractor per collection.\n\n**Custom plugin collections:**\n\nWhen `feature_extractor_name` references a custom plugin, the collection's vector\nindexes are read from the plugin's `manifest.py` `features` list.  The `features`\nentries **must** use these exact key names — wrong keys silently produce a collection\nwith no vector indexes and 0 documents will be written:\n\n```json\n{\n  \"feature_type\": \"embedding\",\n  \"feature_name\": \"my_embedding\",\n  \"embedding_dim\": 768,\n  \"distance_metric\": \"cosine\"\n}\n```\n\nCommon wrong keys (will be ignored): `type`, `name`, `dimensions`, `distance`.\n\n**Vector schema:** Custom plugin vectors are automatically added to the namespace's\nvector store collection the first time a batch is processed, so there is no need to recreate\nthe namespace when adding a plugin with new embedding types.","operationId":"create_collection_v1_collections_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCollectionRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"get":{"tags":["Collections"],"summary":"List Collections (GET)","description":"GET-friendly alias for `POST /v1/collections/list`. Supports the same\n    pagination/search semantics via query parameters. The namespace is taken\n    from the `X-Namespace` header (`namespace_id` query parameter is accepted\n    but ignored — namespace scoping is always header-based).","operationId":"list_collections_get_v1_collections_get","parameters":[{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Free-text search over collection names","title":"Search"},"description":"Free-text search over collection names"},{"name":"namespace_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Ignored — set X-Namespace header","title":"Namespace Id"},"description":"Ignored — set X-Namespace header"},{"name":"include_system","in":"query","required":false,"schema":{"type":"boolean","description":"Include the namespace's system collections (the `_direct_upsert` default that documents/upsert writes to). Off by default.","default":false,"title":"Include System"},"description":"Include the namespace's system collections (the `_direct_upsert` default that documents/upsert writes to). Off by default."},{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListCollectionsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/collections/{collection_identifier}/clone":{"post":{"tags":["Collections"],"summary":"Clone Collection","description":"Clone a collection with optional modifications.\n\n    **Purpose:**\n    Creates a NEW collection (with new ID) based on an existing one. This is the\n    recommended way to iterate on collection designs when you need to modify core\n    configuration that PATCH doesn't allow (source, feature_extractor, field_passthrough).\n\n    **Clone vs PATCH vs Template:**\n    - **PATCH**: Update settings in place (enabled, metadata, schedule, taxonomy_applications, tiering and the other mutable fields)\n    - **Clone**: Copy and modify core configuration (source, feature_extractor). Everything you do not override is copied, including a retriever_transform, schedule, alert and cluster applications, and tiering\n    - **Template**: Start from a pre-configured pattern (for new projects)\n\n    **Common Use Cases:**\n    - Change feature extractor configuration (model, parameters)\n    - Modify field_passthrough to include/exclude fields\n    - Switch to different source (bucket or collection)\n    - Test modifications before replacing production collection\n    - Create variants (e.g., different embedding models)\n\n    **How it works:**\n    1. Source collection is copied\n    2. You provide a new name (REQUIRED)\n    3. Optionally override any other fields\n    4. A new collection is created with a new ID\n    5. Original collection remains unchanged","operationId":"clone_collection_v1_collections__collection_identifier__clone_post","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"Source collection ID or name to clone.","title":"Collection Identifier"},"description":"Source collection ID or name to clone."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloneCollectionRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloneCollectionResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/collections/{collection_identifier}/trigger":{"post":{"tags":["Collections"],"summary":"Trigger Collection Processing","description":"Process data through a collection - works for both bucket-sourced and collection-sourced collections.\n\n    **For bucket-sourced collections:**\n    Creates a batch and answers with its id and a task id, then reads the source\n    bucket(s), splits a load over 1,000 objects into several batches, and submits\n    them. Use `include_buckets` to limit which source buckets to process from.\n    If the buckets hold no matching objects, or a submission is refused, the\n    batch and the task read FAILED with the reason. The task lists every batch\n    as `additional_data.trigger.batch_ids` once they are submitted.\n\n    **For collection-sourced collections:**\n    Processes existing documents from upstream collection(s).\n    Use `include_collections` to limit which source collections to process from.\n\n    **Filtering:**\n    - `source_filters`: Field-level filters using LogicalOperator format\n    - Example: `{\"AND\": [{\"field\": \"status\", \"operator\": \"eq\", \"value\": \"pending\"}]}`\n    - For specific objects: `{\"AND\": [{\"field\": \"object_id\", \"operator\": \"in\", \"value\": [\"obj_1\", \"obj_2\"]}]}`\n\n    **Returns:**\n    - batch_id: Track progress via GET /batches/{batch_id}\n    - task_id: Monitor via GET /tasks/{task_id}","operationId":"trigger_collection_v1_collections__collection_identifier__trigger_post","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID or name of the collection to trigger","title":"Collection Identifier"},"description":"The ID or name of the collection to trigger"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TriggerCollectionRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TriggerCollectionResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/collections/{collection_identifier}":{"get":{"tags":["Collections"],"summary":"Get Collection","description":"This endpoint allows you to retrieve a collection by ID or name.","operationId":"get_collection_v1_collections__collection_identifier__get","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID or name of the collection to retrieve","title":"Collection Identifier"},"description":"The ID or name of the collection to retrieve"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"patch":{"tags":["Collections"],"summary":"Update Collection","description":"Update mutable collection fields (collection_name, description, taxonomy_applications, enabled)","operationId":"update_collection_v1_collections__collection_identifier__patch","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID or name of the collection to update","title":"Collection Identifier"},"description":"The ID or name of the collection to update"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Updates"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"delete":{"tags":["Collections"],"summary":"Delete Collection","description":"This endpoint deletes a collection and all its resources including:\n    - Vector store points (documents) with this collection_id\n    - Cache entries\n    - MongoDB collection metadata\n\n    Note: Collections are payload IDs within the namespace's vector store collection,\n    not separate vector store collections.\n\n    The deletion is performed synchronously and returns when complete.","operationId":"delete_collection_v1_collections__collection_identifier__delete","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID or name of the collection to delete","title":"Collection Identifier"},"description":"The ID or name of the collection to delete"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["delete"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/collections/{collection_identifier}/features":{"get":{"tags":["Collections"],"summary":"Describe collection features","description":"List feature addresses and metadata available in this collection","operationId":"describe_collection_features_route_v1_collections__collection_identifier__features_get","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID or name of the collection to describe","title":"Collection Identifier"},"description":"The ID or name of the collection to describe"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DescribeCollectionFeaturesResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/collections/{collection_identifier}/reconciliation":{"get":{"tags":["Collections"],"summary":"Reconcile objects vs documents","description":"Objects-vs-documents conservation for a collection. Returns the distinct source-object count, the count that produced at least one document, the document count, and their delta, plus an itemized (bounded) list of source objects that produced no document with a machine-readable reason for each.","operationId":"reconcile_collection_route_v1_collections__collection_identifier__reconciliation_get","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID or name of the collection to reconcile","title":"Collection Identifier"},"description":"The ID or name of the collection to reconcile"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"description":"Cap on the itemized discrepancies list.","default":100,"title":"Limit"},"description":"Cap on the itemized discrepancies list."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionReconciliationResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/collections/{collection_identifier}/export":{"post":{"tags":["Collections"],"summary":"Export Collection","description":"Export collection documents to JSON, CSV, Parquet or WebDataset format.\n\n    **Export Formats:**\n    - **JSON**: Line-delimited JSON (JSONL) format. Good for streaming.\n    - **CSV**: Comma-separated values. Best for spreadsheets.\n    - **PARQUET**: Columnar format (default). Best for data pipelines.\n    - **WEBDATASET**: Tar shards for training loaders. One sample per document,\n      carrying `<key>.json` and, with `include_media=True`, the source object's\n      bytes. The response returns every shard plus the brace pattern loaders take.\n\n    **Vector Export:**\n    Vectors are large and exported separately. When `include_vectors=True`,\n    a separate file is created for vectors with document_id mapping.\n\n    **Field Selection:**\n    Use `select_fields` to export only specific fields, reducing file size.\n\n    **Lineage:**\n    Set `include_lineage=True` to add `lineage_chain`, `source_content_hash` and\n    `document_created_at` to every row, so each exported document traces back to its\n    source object and processing steps.\n\n    **Filtering:**\n    Apply filters to export a subset of documents.\n\n    **Destination (your own storage):**\n    Set `destination` to a storage connection you own plus a prefix, and the files and a\n    `manifest.json` are written there as well as to the download copy. The connection\n    needs `write_enabled` set, which is off by default, and its credentials need the\n    write permission on your side (`s3:PutObject`, or `storage.objects.create` for GCS).\n    A connection without it is refused with the permission named.\n\n    **Response:**\n    Returns presigned download URLs valid for 1 hour.\n\n    **Limits:**\n    - Large exports may take time. Consider using `sample_size` for testing.\n    - Vector exports significantly increase processing time.","operationId":"export_collection_v1_collections__collection_identifier__export_post","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID or name of the collection to export","title":"Collection Identifier"},"description":"The ID or name of the collection to export"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionExportRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionExportResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/collections/list":{"post":{"tags":["Collections"],"summary":"List Collections","description":"This endpoint allows you to list collections.","operationId":"list_collections_v1_collections_list_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListCollectionsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListCollectionsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/collections/{collection_identifier}/lifecycle":{"get":{"tags":["Collection Lifecycle"],"summary":"Get Lifecycle Status","description":"Get the storage lifecycle status of a collection including vector counts.","operationId":"get_lifecycle_v1_collections__collection_identifier__lifecycle_get","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"Collection ID or name","title":"Collection Identifier"},"description":"Collection ID or name"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LifecycleStatusResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"patch":{"tags":["Collection Lifecycle"],"summary":"Transition Lifecycle","description":"Transition a collection's storage tier. 'cold' evicts from the vector store (vectors searchable via object storage). 'active' rehydrates back to the vector store. 'archived' permanently removes vectors.","operationId":"transition_lifecycle_v1_collections__collection_identifier__lifecycle_patch","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"Collection ID or name","title":"Collection Identifier"},"description":"Collection ID or name"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TransitionLifecycleRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LifecycleStatusResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/collections/{collection_id}/sync-schema":{"post":{"tags":["Collection Schema"],"summary":"Sync Collection Schema","description":"Sample documents from the vector store and automatically discover new fields to add to the collection's output_schema.\n\n    This endpoint:\n    - Samples N documents from the collection (default: 1000)\n    - Discovers all fields present in actual documents\n    - Merges discovered fields into the collection's output_schema (additive only)\n    - Optionally cascades schema updates to downstream collections\n    - Respects debounce window (max once per 5 minutes, unless force=true)\n\n    The sync operation is additive only - it never removes or changes existing field types.\n\n    Use this endpoint to:\n    - Manually trigger schema discovery after data ingestion\n    - Force an immediate schema sync (bypassing debounce)\n    - Update schemas with new fields discovered in documents","operationId":"sync_collection_schema_v1_collections__collection_id__sync_schema_post","parameters":[{"name":"collection_id","in":"path","required":true,"schema":{"type":"string","description":"Collection ID to sync schema for","title":"Collection Id"},"description":"Collection ID to sync schema for"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SchemaSyncRequest","default":{"sample_size":1000,"force":false,"cascade_to_downstream":true}}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/SchemaSyncResponse"},{"$ref":"#/components/schemas/SchemaSyncSkippedResponse"}],"title":"Response Sync Collection Schema V1 Collections  Collection Id  Sync Schema Post"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/collections/{collection_identifier}/documents/count":{"get":{"tags":["Collection Documents"],"summary":"Count documents in a collection.","description":"Return the total number of documents in the collection. This is the obvious REST endpoint for a document count; it is declared before the `/{document_id}` route so the literal `count` segment is never matched as a document id (which previously produced a misleading 404).","operationId":"count_documents_endpoint_v1_collections__collection_identifier__documents_count_get","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID of the collection to count documents in.","title":"Collection Identifier"},"description":"The ID of the collection to count documents in."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentCountResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/collections/{collection_identifier}/documents/{document_id}":{"get":{"tags":["Collection Documents"],"summary":"Get a document by ID.","description":"Get a document by ID.","operationId":"get_document_v1_collections__collection_identifier__documents__document_id__get","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID of the collection.","title":"Collection Identifier"},"description":"The ID of the collection."},{"name":"document_id","in":"path","required":true,"schema":{"type":"string","description":"The ID of the document to retrieve.","title":"Document Id"},"description":"The ID of the document to retrieve."},{"name":"return_presigned_urls","in":"query","required":false,"schema":{"type":"boolean","description":"Generate fresh presigned download URLs for all blobs with S3 storage","default":false,"title":"Return Presigned Urls"},"description":"Generate fresh presigned download URLs for all blobs with S3 storage"},{"name":"return_vectors","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":false,"title":"Return Vectors"}},{"name":"return_vector_names","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Pass `true` for a '_vectors' field listing available vector names (no embedding data). Pass a comma-separated list of vector names (e.g. 'gemini-embedding-2,siglip_v1') to return the float arrays for those specific vectors as top-level fields named after each vector -- matching the true/List[str] contract on the return_vector_names body field of POST .../documents/list. Storage and output names both accepted.","title":"Return Vector Names"},"description":"Pass `true` for a '_vectors' field listing available vector names (no embedding data). Pass a comma-separated list of vector names (e.g. 'gemini-embedding-2,siglip_v1') to return the float arrays for those specific vectors as top-level fields named after each vector -- matching the true/List[str] contract on the return_vector_names body field of POST .../documents/list. Storage and output names both accepted."},{"name":"expand","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Comma-separated fields to resolve inline under an '_expanded' key. Reserved lineage keywords: 'parent' (immediate upstream document), 'root_object' (originating bucket object), 'ancestors' (full chain root → parent), 'children' (direct downstream documents, max 100). Any other value is treated as a user field path containing doc_* references (supports dot-notation, e.g. 'items.product_id'). Max 50 unique references for non-lineage fields. Depth is limited to 1 (no recursive expansion).","title":"Expand"},"description":"Comma-separated fields to resolve inline under an '_expanded' key. Reserved lineage keywords: 'parent' (immediate upstream document), 'root_object' (originating bucket object), 'ancestors' (full chain root → parent), 'children' (direct downstream documents, max 100). Any other value is treated as a user field path containing doc_* references (supports dot-notation, e.g. 'items.product_id'). Max 50 unique references for non-lineage fields. Depth is limited to 1 (no recursive expansion)."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}},"put":{"tags":["Collection Documents"],"summary":"Update Document","description":"Update a document by ID.\n\nFields you omit keep their stored values. In `metadata`, each key you send is\nset, keys you omit stay, and a key set to `null` is removed.","operationId":"update_document_v1_collections__collection_identifier__documents__document_id__put","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID of the collection.","title":"Collection Identifier"},"description":"The ID of the collection."},{"name":"document_id","in":"path","required":true,"schema":{"type":"string","description":"The ID of the document to update.","title":"Document Id"},"description":"The ID of the document to update."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentUpdateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}},"patch":{"tags":["Collection Documents"],"summary":"Patch Document","description":"Partially update a document by ID (PATCH operation).\n\nIn `metadata`, each key you send is set, keys you omit stay, and a key set to\n`null` is removed.","operationId":"patch_document_v1_collections__collection_identifier__documents__document_id__patch","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID of the collection.","title":"Collection Identifier"},"description":"The ID of the collection."},{"name":"document_id","in":"path","required":true,"schema":{"type":"string","description":"The ID of the document to patch.","title":"Document Id"},"description":"The ID of the document to patch."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchDocumentRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}},"delete":{"tags":["Collection Documents"],"summary":"Delete a document by ID.","description":"Delete a document by ID.","operationId":"delete_document_v1_collections__collection_identifier__documents__document_id__delete","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID of the collection.","title":"Collection Identifier"},"description":"The ID of the collection."},{"name":"document_id","in":"path","required":true,"schema":{"type":"string","description":"The ID of the document to delete.","title":"Document Id"},"description":"The ID of the document to delete."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenericDeleteResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/collections/{collection_identifier}/documents/{document_id}/ancestors":{"get":{"tags":["Collection Documents"],"summary":"Get document ancestors (lineage chain root → parent).","description":"Return every prior step in this document's lineage chain, in order from\nroot through immediate parent. Excludes the document itself.\n\nEquivalent to ``GET /documents/{id}?expand=ancestors`` but returns just\nthe ancestor list — convenient for SDKs and the Studio decomposition tree.","operationId":"get_document_ancestors_v1_collections__collection_identifier__documents__document_id__ancestors_get","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID or name of the collection.","title":"Collection Identifier"},"description":"The ID or name of the collection."},{"name":"document_id","in":"path","required":true,"schema":{"type":"string","description":"The ID of the document.","title":"Document Id"},"description":"The ID of the document."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/DocumentResponse"},"title":"Response Get Document Ancestors V1 Collections  Collection Identifier  Documents  Document Id  Ancestors Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/collections/{collection_identifier}/documents/{document_id}/download":{"get":{"tags":["Collection Documents"],"summary":"Download frame-accurate scene media for this document.","description":"Export this scene's media cut frame-accurately to its time range.\n\nThe document's ``video_segment_url`` serves the extraction-time clip,\nwhich is stream-copied and therefore keyframe-bounded — it can overshoot\n``[start_time, end_time]`` by up to a GOP (~1s). This endpoint re-cuts\nfrom the ORIGINAL source with re-encode so the exported media matches the\ndeclared range within one source frame, caches the\nresult beside the extraction clip, and returns a presigned download URL.\nThe first call for a given range pays the re-encode (seconds, bounded);\nrepeat calls serve the cache.","operationId":"download_document_media_v1_collections__collection_identifier__documents__document_id__download_get","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID or name of the collection.","title":"Collection Identifier"},"description":"The ID or name of the collection."},{"name":"document_id","in":"path","required":true,"schema":{"type":"string","description":"The ID of the scene document.","title":"Document Id"},"description":"The ID of the scene document."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SceneDownloadResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/collections/{collection_identifier}/documents/{document_id}/descendants":{"get":{"tags":["Collection Documents"],"summary":"Get direct downstream documents (depth=1 children).","description":"Return direct downstream documents (depth=1) — every document whose\n`_internal.lineage.source_document_id` equals this document's ID.\n\nCapped at 100 children per request. Equivalent to\n``GET /documents/{id}?expand=children`` but returns just the children.\n\nDeeper traversal (descendants beyond depth=1) is not yet supported in\na single call — walk recursively client-side or filter the namespace by\n``from_object`` and post-process.","operationId":"get_document_descendants_v1_collections__collection_identifier__documents__document_id__descendants_get","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID or name of the collection.","title":"Collection Identifier"},"description":"The ID or name of the collection."},{"name":"document_id","in":"path","required":true,"schema":{"type":"string","description":"The ID of the document.","title":"Document Id"},"description":"The ID of the document."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/DocumentResponse"},"title":"Response Get Document Descendants V1 Collections  Collection Identifier  Documents  Document Id  Descendants Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/collections/{collection_identifier}/documents/{document_id}/diagnostics":{"get":{"tags":["Collection Documents"],"summary":"Per-document support diagnostics (visibility, failures, history).","description":"Answer three support facets for ONE document that no other surface exposes: (1) visibility_reason - are this document's vectors present in MVS (searchable) and, if not, why (the Unsearchable class, made per-document answerable via the vector-presence machinery); (2) recent_failures - the source object's own status/error, with an honest note that structured batch errors are aggregate-only; (3) diagnostic_history - the document's processing history from its own _internal records. Every facet returns a real value, or an empty/None value with a reason naming what would carry it.","operationId":"get_document_diagnostics_v1_collections__collection_identifier__documents__document_id__diagnostics_get","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID or name of the collection.","title":"Collection Identifier"},"description":"The ID or name of the collection."},{"name":"document_id","in":"path","required":true,"schema":{"type":"string","description":"The ID of the document.","title":"Document Id"},"description":"The ID of the document."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentDiagnosticsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/collections/{collection_identifier}/documents/list":{"post":{"tags":["Collection Documents"],"summary":"List documents.","description":"List documents with optional grouping support.\n\nSupports two modes:\n1. Regular listing: Returns flat list of documents with pagination\n2. Grouped listing: When group_by is specified, returns documents grouped by field value\n\nWhen using group_by:\n- Requires a payload index on the specified field in the vector store\n- Pagination applies to groups, not individual documents\n- Each group contains all documents sharing the same field value","operationId":"list_documents_v1_collections__collection_identifier__documents_list_post","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID of the collection to list documents from.","title":"Collection Identifier"},"description":"The ID of the collection to list documents from."},{"name":"return_presigned_urls","in":"query","required":false,"schema":{"type":"boolean","description":"Generate presigned URLs for S3-backed blobs and url-shaped fields. Also accepted as a body field — if either is true, presigning is enabled.","default":false,"title":"Return Presigned Urls"},"description":"Generate presigned URLs for S3-backed blobs and url-shaped fields. Also accepted as a body field — if either is true, presigning is enabled."},{"name":"return_vectors","in":"query","required":false,"schema":{"type":"boolean","description":"Include vector embeddings in results. Also accepted as a body field — if either is true, vectors are returned.","default":false,"title":"Return Vectors"},"description":"Include vector embeddings in results. Also accepted as a body field — if either is true, vectors are returned."},{"name":"filters","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"URL-encoded JSON filter (LogicalOperator shape: {\"AND\":[{\"field\":\"metadata.status\",\"operator\":\"eq\",\"value\":\"active\"}]}; OR/NOT also supported). Applies to the GET listing. POST /documents/list callers should send `filters` in the JSON body instead — the body wins when both are present. Invalid JSON returns 422 (never silently ignored).","title":"Filters"},"description":"URL-encoded JSON filter (LogicalOperator shape: {\"AND\":[{\"field\":\"metadata.status\",\"operator\":\"eq\",\"value\":\"active\"}]}; OR/NOT also supported). Applies to the GET listing. POST /documents/list callers should send `filters` in the JSON body instead — the body wins when both are present. Invalid JSON returns 422 (never silently ignored)."},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Free-text search across common document fields. Body `search` wins when both are set.","title":"Search"},"description":"Free-text search across common document fields. Body `search` wins when both are set."},{"name":"sort","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Sort spec as JSON ({\"field\":\"created_at\",\"direction\":\"desc\"}) or the compact \"field:direction\" form. Body `sort` wins when both are set.","title":"Sort"},"description":"Sort spec as JSON ({\"field\":\"created_at\",\"direction\":\"desc\"}) or the compact \"field:direction\" form. Body `sort` wins when both are set."},{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListDocumentsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListDocumentsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/collections/{collection_identifier}/documents":{"get":{"tags":["Collection Documents"],"summary":"List documents.","description":"List documents with optional grouping support.\n\nSupports two modes:\n1. Regular listing: Returns flat list of documents with pagination\n2. Grouped listing: When group_by is specified, returns documents grouped by field value\n\nWhen using group_by:\n- Requires a payload index on the specified field in the vector store\n- Pagination applies to groups, not individual documents\n- Each group contains all documents sharing the same field value","operationId":"list_documents_v1_collections__collection_identifier__documents_get","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID of the collection to list documents from.","title":"Collection Identifier"},"description":"The ID of the collection to list documents from."},{"name":"return_presigned_urls","in":"query","required":false,"schema":{"type":"boolean","description":"Generate presigned URLs for S3-backed blobs and url-shaped fields. Also accepted as a body field — if either is true, presigning is enabled.","default":false,"title":"Return Presigned Urls"},"description":"Generate presigned URLs for S3-backed blobs and url-shaped fields. Also accepted as a body field — if either is true, presigning is enabled."},{"name":"return_vectors","in":"query","required":false,"schema":{"type":"boolean","description":"Include vector embeddings in results. Also accepted as a body field — if either is true, vectors are returned.","default":false,"title":"Return Vectors"},"description":"Include vector embeddings in results. Also accepted as a body field — if either is true, vectors are returned."},{"name":"filters","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"URL-encoded JSON filter (LogicalOperator shape: {\"AND\":[{\"field\":\"metadata.status\",\"operator\":\"eq\",\"value\":\"active\"}]}; OR/NOT also supported). Applies to the GET listing. POST /documents/list callers should send `filters` in the JSON body instead — the body wins when both are present. Invalid JSON returns 422 (never silently ignored).","title":"Filters"},"description":"URL-encoded JSON filter (LogicalOperator shape: {\"AND\":[{\"field\":\"metadata.status\",\"operator\":\"eq\",\"value\":\"active\"}]}; OR/NOT also supported). Applies to the GET listing. POST /documents/list callers should send `filters` in the JSON body instead — the body wins when both are present. Invalid JSON returns 422 (never silently ignored)."},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Free-text search across common document fields. Body `search` wins when both are set.","title":"Search"},"description":"Free-text search across common document fields. Body `search` wins when both are set."},{"name":"sort","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Sort spec as JSON ({\"field\":\"created_at\",\"direction\":\"desc\"}) or the compact \"field:direction\" form. Body `sort` wins when both are set.","title":"Sort"},"description":"Sort spec as JSON ({\"field\":\"created_at\",\"direction\":\"desc\"}) or the compact \"field:direction\" form. Body `sort` wins when both are set."},{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListDocumentsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListDocumentsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}},"post":{"tags":["Collection Documents"],"summary":"Create a document.","description":"Create a document in a collection addressed by ID or name.","operationId":"create_document_v1_collections__collection_identifier__documents_post","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID or name of the collection.","title":"Collection Identifier"},"description":"The ID or name of the collection."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentCreateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/collections/{collection_identifier}/documents/bulk":{"patch":{"tags":["Collection Documents"],"summary":"Bulk Update Documents","description":"Bulk update documents matching filter conditions.\n\nPartially updates all documents in the collection that match the provided filters.\nIf no filters are provided, updates all documents in the collection.\n\nThis endpoint applies the SAME update_data to ALL documents matching the filters.\nFor per-document updates with different values, use POST /batch endpoint instead.","operationId":"bulk_update_documents_v1_collections__collection_identifier__documents_bulk_patch","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID of the collection to update documents in.","title":"Collection Identifier"},"description":"The ID of the collection to update documents in."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkUpdateDocumentsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkUpdateDocumentsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/collections/{collection_identifier}/documents/batch":{"post":{"tags":["Collection Documents"],"summary":"Batch Update Documents","description":"Batch update multiple documents by explicit IDs or filters.\n\nSupports TWO modes:\n1. Explicit IDs mode: Provide 'updates' array with document_id + update_data for each document\n   - Each document can have DIFFERENT update_data\n   - Returns detailed per-document results\n\n2. Filter mode: Provide 'filters' + 'update_data' to update all matching documents\n   - All documents receive the SAME update_data\n   - Returns total count only\n\nKey Features:\n- Update any document field except vectors (metadata, internal_metadata, source_blobs, etc.)\n- Maximum 1000 documents per batch in explicit mode\n- Per-document success/failure reporting in explicit mode\n- Validates documents exist in the specified collection\n\nExamples:\n    Explicit IDs mode:\n    ```json\n    {\n        \"updates\": [\n            {\"document_id\": \"doc_123\", \"update_data\": {\"metadata\": {\"status\": \"processed\"}}},\n            {\"document_id\": \"doc_456\", \"update_data\": {\"metadata\": {\"status\": \"archived\"}}}\n        ]\n    }\n    ```\n\n    Filter mode (logical AND/OR/NOT shape — NOT MVS-native must/key):\n    ```json\n    {\n        \"filters\": {\"AND\": [{\"field\": \"metadata.status\", \"operator\": \"eq\", \"value\": \"pending\"}]},\n        \"update_data\": {\"metadata\": {\"status\": \"processed\"}}\n    }\n    ```","operationId":"batch_update_documents_v1_collections__collection_identifier__documents_batch_post","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID of the collection to update documents in.","title":"Collection Identifier"},"description":"The ID of the collection to update documents in."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchUpdateDocumentsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchUpdateDocumentsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}},"delete":{"tags":["Collection Documents"],"summary":"Batch Delete Documents","description":"Batch delete multiple documents by explicit IDs or filters.\n\nSupports TWO modes:\n1. Explicit IDs mode: Provide 'document_ids' array\n   - Deletes specific documents by ID\n   - Returns detailed per-document results\n   - Maximum 1000 documents per batch\n\n2. Filter mode: Provide 'filters' to delete all matching documents\n   - Deletes ALL documents matching the filters\n   - Returns total count only\n   - Use with caution - can delete many documents\n\nKey Features:\n- Per-document success/failure reporting in explicit mode\n- Validates documents exist in the specified collection\n- Automatic document count update for the collection\n- Efficient bulk deletion\n\nExamples:\n    Explicit IDs mode:\n    ```json\n    {\n        \"document_ids\": [\"doc_123\", \"doc_456\", \"doc_789\"]\n    }\n    ```\n\n    Filter mode (logical AND/OR/NOT shape — NOT MVS-native must/key):\n    ```json\n    {\n        \"filters\": {\"AND\": [{\"field\": \"metadata.status\", \"operator\": \"eq\", \"value\": \"archived\"}]}\n    }\n    ```","operationId":"batch_delete_documents_v1_collections__collection_identifier__documents_batch_delete","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID of the collection to delete documents from.","title":"Collection Identifier"},"description":"The ID of the collection to delete documents from."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchDeleteDocumentsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchDeleteDocumentsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/collections/{collection_identifier}/documents/schema/validate":{"post":{"tags":["Collection Documents"],"summary":"Validate document against collection schema","description":"Dry-run validation: checks a document payload against the collection's document_schema without creating or modifying any data. Returns validation result with any violations found.","operationId":"validate_document_schema_v1_collections__collection_identifier__documents_schema_validate_post","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID or name of the collection.","title":"Collection Identifier"},"description":"The ID or name of the collection."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"The document payload to validate against the collection schema.","title":"Document Payload"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/collections/{collection_identifier}/documents/aggregate":{"post":{"tags":["Collection Documents"],"summary":"Aggregate Documents","description":"This endpoint performs aggregation operations on documents in a collection.\n\n    **Aggregation Framework**: Provides MongoDB-style aggregation operations:\n    - GROUP BY: Group documents by one or more fields\n    - Aggregations: COUNT, SUM, AVG, MIN, MAX, COUNT_DISTINCT, etc.\n    - Date Operations: Truncate or extract date parts for time-series analysis\n    - Filtering: Pre-aggregation filters (WHERE) and post-aggregation filters (HAVING)\n    - Sorting & Limiting: Control result ordering and size\n\n    **Counting documents that match a filter**: omit group_by and send only count\n    aggregations, for example\n    `{\"aggregations\": [{\"function\": \"count\", \"alias\": \"total\"}], \"filters\": {...}}`.\n    The response holds one row whose metrics carry the exact number of matching\n    documents (an empty `group`). This is the same count documents/list returns in\n    `pagination.total` when you send `\"include_total\": true`. Any other\n    aggregation needs at least one group_by field.\n\n    **Use Cases**:\n    - Count documents by feature type or collection\n    - Calculate daily/monthly processing statistics\n    - Analyze feature distributions and confidence scores\n    - Generate reports with multiple metrics\n\n    **Group values**: a group_by value comes back as a JSON number or boolean when the\n    namespace declares a payload index of type integer, float or bool on the field. Any\n    other field, including an undeclared numeric one, groups as strings.\n\n    **Note**: This endpoint works with both MongoDB and the vector store using the same interface.\n    The system automatically selects the appropriate aggregation provider based on\n    the underlying metadata store.","operationId":"aggregate_documents_v1_collections__collection_identifier__documents_aggregate_post","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the collection.","title":"Collection Identifier"},"description":"The unique identifier of the collection."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentAggregationRequest","description":"Aggregation configuration specifying grouping, metrics, and filters."}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentAggregationResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/collections/{collection_identifier}/documents/distinct":{"post":{"tags":["Collection Documents"],"summary":"Return distinct values for a single field.","description":"Return the set of unique values for one document field across a collection, together with a per-value document count sorted desc. Thin wrapper over `/aggregate` for the common `SELECT DISTINCT <field>` case — use this when a UI needs a facet list (e.g. `brand_slug`) without loading every document. Null/missing values are excluded. A value comes back as a JSON number or boolean when the namespace declares a payload index of type integer, float or bool on the field. Any other field, including an undeclared numeric one, facets as strings, so check the namespace's `payload_indexes` to know which you will get. When a storage shard times out or returns only part of its documents, the list can be short: `query_info.truncated` is then true and `query_info.warning` says what to do.","operationId":"distinct_document_values_v1_collections__collection_identifier__documents_distinct_post","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the collection.","title":"Collection Identifier"},"description":"The unique identifier of the collection."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DistinctValuesRequest","description":"Field + optional filters/limit for the distinct query."}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DistinctValuesResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/collections/{collection_identifier}/documents/{document_id}/acl":{"patch":{"tags":["Collection Documents"],"summary":"Update a document's access control list (ACL).","description":"Update a document's ACL (access control list).\n\nOnly the document owner or an org-scoped key can modify ACL.\nUser-scoped keys that are not the owner will receive a 403.\n\nThis route edits one document per call. To set ACLs on many documents (an\nimport or a migration), send them with\nPOST /v1/namespaces/{namespace_id}/documents/upsert and a per-document\n`acl`, which writes a whole batch in one call.","operationId":"update_document_acl_v1_collections__collection_identifier__documents__document_id__acl_patch","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"The ID of the collection.","title":"Collection Identifier"},"description":"The ID of the collection."},{"name":"document_id","in":"path","required":true,"schema":{"type":"string","description":"The ID of the document.","title":"Document Id"},"description":"The ID of the document."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateDocumentACLRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/documents/list":{"post":{"tags":["Documents"],"summary":"List documents across all collections (namespace-scoped).","description":"List documents across all collections in the namespace.\n\nUse this when you don't know which collection a document belongs to,\nor when you need to search across collections. Optionally filter to\nspecific collection_ids.\n\nFor collection-specific listing, use\nPOST /v1/collections/{collection_id}/documents/list instead.","operationId":"list_documents_ns_v1_documents_list_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NamespaceListDocumentsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListDocumentsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/documents/batch-get":{"post":{"tags":["Documents"],"summary":"Batch get documents by IDs","description":"Batch retrieve multiple documents by their IDs.\n\nReturns documents and a list of IDs that were not found.\nMaximum 1000 document IDs per request.","operationId":"batch_get_documents_v1_documents_batch_get_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchGetDocumentsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchGetDocumentsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/documents/list/batch":{"post":{"tags":["Documents"],"summary":"Run multiple list-documents queries concurrently.","description":"Execute up to 10 `POST /v1/documents/list` queries in parallel against the\nsame namespace and return their responses together.\n\nCollapses dossier / multi-collection N+1 fan-outs into one round-trip. Each\nsub-query is independent; a failure in one does not fail the batch — the\nfailing entry's `response` is null and `error` carries a short message.","operationId":"list_documents_batch_v1_documents_list_batch_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchListDocumentsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchListDocumentsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/documents/{document_id}":{"get":{"tags":["Documents"],"summary":"Get a document by ID (namespace-scoped).","description":"Get a document by ID without specifying a collection.\n\nSearches across all collections in the namespace. Use the\ncollection-scoped GET /v1/collections/{collection_id}/documents/{document_id}\nwhen you know the collection for a faster lookup.","operationId":"get_document_ns_v1_documents__document_id__get","parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","description":"The ID of the document to retrieve.","title":"Document Id"},"description":"The ID of the document to retrieve."},{"name":"return_presigned_urls","in":"query","required":false,"schema":{"type":"boolean","description":"Generate fresh presigned download URLs for all blobs with S3 storage","default":false,"title":"Return Presigned Urls"},"description":"Generate fresh presigned download URLs for all blobs with S3 storage"},{"name":"return_vectors","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":false,"title":"Return Vectors"}},{"name":"return_vector_names","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Pass `true` for a '_vectors' field listing available vector names (no embedding data). Pass a comma-separated list of vector names to return the float arrays for those specific vectors as top-level fields, matching the collection-scoped GET's contract. This route does not know the document's collection until after the lookup, so only STORAGE names (the raw vector_indexes.index.name, not the output alias) are guaranteed to resolve here -- use the collection-scoped route for output-name translation.","title":"Return Vector Names"},"description":"Pass `true` for a '_vectors' field listing available vector names (no embedding data). Pass a comma-separated list of vector names to return the float arrays for those specific vectors as top-level fields, matching the collection-scoped GET's contract. This route does not know the document's collection until after the lookup, so only STORAGE names (the raw vector_indexes.index.name, not the output alias) are guaranteed to resolve here -- use the collection-scoped route for output-name translation."},{"name":"expand","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Comma-separated fields containing document IDs to resolve inline. Referenced documents are fetched and attached under an '_expanded' key. Supports dot-notation for nested fields (e.g., 'items.product_id'). Max 50 unique references per request.","title":"Expand"},"description":"Comma-separated fields containing document IDs to resolve inline. Referenced documents are fetched and attached under an '_expanded' key. Supports dot-notation for nested fields (e.g., 'items.product_id'). Max 50 unique references per request."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}},"patch":{"tags":["Documents"],"summary":"Partially update a document by ID (namespace-scoped).","description":"Partially update a document by ID without specifying a collection.\n\nOnly the fields provided are updated; all other fields are left unchanged.","operationId":"patch_document_ns_v1_documents__document_id__patch","parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","description":"The ID of the document to patch.","title":"Document Id"},"description":"The ID of the document to patch."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchDocumentRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}},"put":{"tags":["Documents"],"summary":"Update a document by ID (namespace-scoped).","description":"Replace a document's fields by ID without specifying a collection.","operationId":"update_document_ns_v1_documents__document_id__put","parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","description":"The ID of the document to update.","title":"Document Id"},"description":"The ID of the document to update."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentUpdateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/collections/{collection_id}/documents/{document_id}/lineage":{"get":{"tags":["Document Lineage"],"summary":"Get document lineage","description":"Get the complete processing lineage for a document. Shows the full chain of transformations from the root bucket object through all collection processing stages.","operationId":"get_document_lineage_v1_collections__collection_id__documents__document_id__lineage_get","parameters":[{"name":"collection_id","in":"path","required":true,"schema":{"type":"string","description":"ID of the collection containing the document","title":"Collection Id"},"description":"ID of the collection containing the document"},{"name":"document_id","in":"path","required":true,"schema":{"type":"string","description":"ID of the document to trace","title":"Document Id"},"description":"ID of the document to trace"}],"responses":{"200":{"description":"Document lineage information","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentLineageResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/objects/{object_id}/documents":{"get":{"tags":["Document Lineage"],"summary":"Get all documents derived from an object","description":"Get all documents your collections created from a specific root object. The object's own record in its bucket is not listed or counted, so an object no collection has processed yet returns total_documents 0. Useful for finding all processing outputs across multiple collections.","operationId":"get_documents_by_object_v1_objects__object_id__documents_get","parameters":[{"name":"object_id","in":"path","required":true,"schema":{"type":"string","description":"Root object ID to find all derived documents","title":"Object Id"},"description":"Root object ID to find all derived documents"},{"name":"collection_ids","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"},"description":"Optional: Filter to specific collections","title":"Collection Ids"},"description":"Optional: Filter to specific collections"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Documents By Object V1 Objects  Object Id  Documents Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/objects/{object_id}/decomposition-tree":{"get":{"tags":["Document Lineage"],"summary":"Get decomposition tree visualization","description":"Get a hierarchical tree structure showing all collections and documents derived from a root object. Shows the complete multi-stage processing pipeline.","operationId":"get_decomposition_tree_v1_objects__object_id__decomposition_tree_get","parameters":[{"name":"object_id","in":"path","required":true,"schema":{"type":"string","description":"Root object ID to build decomposition tree for","title":"Object Id"},"description":"Root object ID to build decomposition tree for"},{"name":"include_document_ids","in":"query","required":false,"schema":{"type":"boolean","description":"Include full list of document IDs (can be large)","default":false,"title":"Include Document Ids"},"description":"Include full list of document IDs (can be large)"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Decomposition Tree V1 Objects  Object Id  Decomposition Tree Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/collections/{collection_identifier}/apply-taxonomy":{"post":{"tags":["Collection Taxonomies"],"summary":"Apply Taxonomy to Existing Documents","description":"Apply a taxonomy to all existing documents in a collection retroactively.\n\nThis endpoint triggers distributed Ray processing to enrich existing documents\nwith taxonomy data. Unlike automatic materialization (which happens during ingestion),\nthis endpoint allows you to:\n\n1. **Backfill enrichment** for documents ingested before the taxonomy was created\n2. **Re-apply taxonomy** after configuration changes\n3. **Process specific subsets** using scroll_filters\n\n⚙️ **Processing Details:**\n- Uses Ray datasets with map_batches for parallel processing\n- Scales horizontally across Ray cluster\n- Non-blocking: Returns immediately with task_id\n- Monitor progress via Tasks API\n\n⚠️ **Prerequisites:**\n- Taxonomy must exist and be valid\n- Taxonomy must be in collection's taxonomy_applications list\n- Collection must contain documents\n\n📊 **Performance:**\n- ~1000-5000 docs/second depending on cluster size\n- Parallel processing across multiple Ray workers\n- Batch size and parallelism configurable\n\n🔍 **Use Cases:**\n- Backfill: Apply new taxonomy to historical data\n- Re-enrichment: Update after taxonomy changes\n- Selective: Process filtered document subsets\n\nSee Collections API and Taxonomies API documentation for details.","operationId":"apply_taxonomy_to_collection_v1_collections__collection_identifier__apply_taxonomy_post","parameters":[{"name":"collection_identifier","in":"path","required":true,"schema":{"type":"string","description":"Collection ID or name to apply taxonomy to","title":"Collection Identifier"},"description":"Collection ID or name to apply taxonomy to"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApplyTaxonomyRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApplyTaxonomyResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/stages":{"get":{"tags":["Retriever Stages"],"summary":"List Available Retriever Stages","description":"List all registered retriever stages with their configurations. Use this endpoint to discover available stages before creating retrievers. Each stage includes its ID, description, category, and full parameter schema. The parameter_schema field contains complete Pydantic JSON Schema with validation rules, descriptions, and examples for all stage parameters.","operationId":"list_stages_v1_retrievers_stages_get","responses":{"200":{"description":"List of retriever stage definitions with complete parameter schemas. Each stage includes: - stage_id: Unique identifier to use in retriever configurations - description: Human-readable purpose and behavior - category: Transformation type (filter/sort/reduce/apply) - icon: UI icon identifier - parameter_schema: Full JSON Schema for stage parameters (null if no params)","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/RetrieverStageDefinition"},"type":"array","title":"Response List Stages V1 Retrievers Stages Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/retrievers/published":{"get":{"tags":["Published Retrievers"],"summary":"List Published Retrievers","description":"List all published retrievers for the organization.","operationId":"list_published_retrievers_v1_retrievers_published_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"description":"Maximum number of results","default":100,"title":"Limit"},"description":"Maximum number of results"},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"description":"Number of results to skip","default":0,"title":"Offset"},"description":"Number of results to skip"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response List Published Retrievers V1 Retrievers Published Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/publish/stats":{"get":{"tags":["Published Retrievers"],"summary":"Get Organization Publish Stats","description":"Get publish statistics for the namespace in the request.\n\nThe publish limit counts each namespace separately.","operationId":"get_organization_publish_stats_v1_retrievers_publish_stats_get","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationPublishStatsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/{retriever_id}/publish":{"post":{"tags":["Published Retrievers"],"summary":"Publish Retriever","description":"Publish a retriever as a public search interface.\n\nCreates a public API endpoint and branded page for the retriever.\nReturns a public API key that should be stored securely (shown only once).\n\n**Limits:**\n- Maximum 10 published retrievers per organization\n- Public name must be globally unique\n\n**Security:**\n- Public API key is required for all requests\n- Optional password protection via organization secrets\n- Configurable rate limits per retriever\n- Field masking ensures only approved fields are exposed","operationId":"publish_retriever_v1_retrievers__retriever_id__publish_post","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","description":"ID of the retriever to publish","title":"Retriever Id"},"description":"ID of the retriever to publish"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublishRetrieverRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublishRetrieverResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"patch":{"tags":["Published Retrievers"],"summary":"Update Published Retriever","description":"Update published retriever configuration.\n\nAllows updating display config, rate limits, exposed fields, and password protection.\nThe public API key and public name cannot be changed (unpublish and republish instead).","operationId":"update_published_retriever_v1_retrievers__retriever_id__publish_patch","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","description":"ID of the retriever","title":"Retriever Id"},"description":"ID of the retriever"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdatePublishedRetrieverRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublishedRetrieverResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"delete":{"tags":["Published Retrievers"],"summary":"Unpublish Retriever","description":"Unpublish a retriever.\n\nRemoves the public API endpoint and deletes the short URL redirect.\nThe public API key will immediately stop working.\nThis action cannot be undone (you'll need to republish to get a new API key).","operationId":"unpublish_retriever_v1_retrievers__retriever_id__publish_delete","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","description":"ID of the retriever to unpublish","title":"Retriever Id"},"description":"ID of the retriever to unpublish"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenericDeleteResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"get":{"tags":["Published Retrievers"],"summary":"Get Published Retriever","description":"Get published retriever details.\n\nReturns configuration including public URL, display settings, and rate limits.\nThe public API key is not returned (it was shown only once during publishing).\n\nA retriever that simply hasn't been published yet is a normal state (the\nStudio Publish tab opens this on every visit), not an error — so this\nreturns ``200`` with a ``null`` body rather than ``404``, which previously\nlogged a console error for every unpublished retriever.","operationId":"get_published_retriever_v1_retrievers__retriever_id__publish_get","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","description":"ID of the retriever","title":"Retriever Id"},"description":"ID of the retriever"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/PublishedRetrieverResponse"},{"type":"null"}],"title":"Response Get Published Retriever V1 Retrievers  Retriever Id  Publish Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/{retriever_id}/publish/reconcile":{"post":{"tags":["Published Retrievers"],"summary":"Reconcile Publish State","description":"Repair published_retrievers <-> marketplace_listings divergence.\n\nA retriever's public surfaces can drift apart — e.g. a marketplace listing\nexists but its published_retrievers record is missing, so\n/v1/public/retrievers/{name} 404s (half-published). This detects the state\nand (unless ``dry_run``) repairs it idempotently:\n- missing_published -> create the published record from the listing (reused id)\n- missing_listing   -> create the listing from the published record\n- consistent        -> ensure cross-link\n- not_published     -> no-op","operationId":"reconcile_publish_state_v1_retrievers__retriever_id__publish_reconcile_post","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","description":"ID of the retriever to reconcile","title":"Retriever Id"},"description":"ID of the retriever to reconcile"},{"name":"dry_run","in":"query","required":false,"schema":{"type":"boolean","description":"Report the divergence state without mutating","default":false,"title":"Dry Run"},"description":"Report the divergence state without mutating"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Reconcile Publish State V1 Retrievers  Retriever Id  Publish Reconcile Post"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/{retriever_id}/publish/availability":{"get":{"tags":["Published Retrievers"],"summary":"Check Name Availability","description":"Check if a public name is available.\n\nPublic names must be globally unique across all organizations.\nUse this endpoint before publishing to ensure your desired name is available.","operationId":"check_name_availability_v1_retrievers__retriever_id__publish_availability_get","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","description":"ID of the retriever","title":"Retriever Id"},"description":"ID of the retriever"},{"name":"name","in":"query","required":true,"schema":{"type":"string","description":"Public name to check","title":"Name"},"description":"Public name to check"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicNameAvailabilityResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/execute":{"post":{"tags":["Adhoc Retrievers"],"summary":"Execute Adhoc Retriever","description":"Execute a retriever ad-hoc without persisting the configuration.\n\nThis endpoint allows you to execute a retriever without saving it to the database.\nUseful for one-time queries, testing configurations, or temporary searches.\n\nCaching: this route does not use the retriever-level execute cache, so\n``cache_status`` is always ``disabled`` and there is no ``skip_cache``\nparameter.\n\nThat does NOT mean every response is freshly computed. Individual stages\nkeep their own caches, which this route cannot switch off, so a stage may\nserve a cached result and report ``cache_hit: true`` under\n``stage_statistics.stages[*]`` on a response whose top-level\n``cache_status`` reads ``disabled``. The two fields describe different\ncaches. If you need a guaranteed fresh execution, persist the retriever\n(``POST /retrievers``) and call ``/retrievers/{id}/execute`` with\n``skip_cache``, which this route lacks and which does reach the stages.\n\nStreaming Execution (stream=True):\n    Response uses Server-Sent Events (SSE) format with Content-Type: text/event-stream.\n    Each stage emits events as it executes, formatted as: data: {json}\\n\\n\n\n    Event Types (StreamEventType):\n    - stage_start: Emitted when a stage begins (includes stage_name, stage_index, total_stages)\n    - stage_complete: Emitted when a stage finishes (includes documents, statistics, budget_used)\n    - stage_error: Emitted if a stage fails (includes error message)\n    - execution_complete: Final event with complete results and pagination\n    - execution_error: Emitted if entire execution fails\n\n    StreamStageEvent Fields:\n    - event_type: Type of event\n    - execution_id: Unique execution identifier\n    - stage_name/stage_index/total_stages: Stage progress info\n    - documents: Intermediate results (stage_complete only)\n    - statistics: Stage metrics (duration_ms, input_count, output_count, efficiency)\n    - budget_used: Cumulative consumption (credits_used, time_elapsed_ms, tokens_used)\n\n    Response Headers:\n    - Content-Type: text/event-stream\n    - Cache-Control: no-cache\n    - Connection: keep-alive\n    - X-Execution-Mode: adhoc\n\nStandard Execution (stream=False, default):\n    - Returns ExecuteRetrieverResponse after all stages complete\n    - Includes X-Execution-Mode: adhoc header\n    - execution_metadata.retriever_persisted = False\n\nUse Cases:\n    - One-time queries without saving retriever configuration\n    - Testing stage configurations before persisting\n    - Dynamic retrieval with varying parameters\n    - Real-time progress tracking with streaming","operationId":"execute_adhoc_retriever_v1_retrievers_execute_post","parameters":[{"name":"return_presigned_urls","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Return Presigned Urls"}},{"name":"return_vectors","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Return Vectors"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdhocExecuteRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/executions/list":{"post":{"tags":["Adhoc Retrievers"],"summary":"List Adhoc Executions","description":"List execution history for ad-hoc retrievers.\n\nReturns execution history for all ad-hoc retriever executions in the namespace,\nsorted by timestamp descending (most recent first).\n\nUse Cases:\n    - Track ad-hoc retriever usage across the namespace\n    - Debug ad-hoc retriever executions\n    - Analyze query patterns from ad-hoc searches\n    - Monitor performance of ad-hoc executions\n\nFiltering:\n    - Filter by status (completed, failed, etc.)\n    - Filter by time range (start_time, end_time)\n\nPagination:\n    - Supports offset-based pagination via query parameters\n    - Default limit: 20, max limit: 100\n    - Use ?page_size=X&page_number=Y for pagination","operationId":"list_adhoc_executions_v1_retrievers_executions_list_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListAdhocExecutionsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListAdhocExecutionsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/executions/{execution_id}":{"get":{"tags":["Adhoc Retrievers"],"summary":"Get Adhoc Execution","description":"Get detailed execution information for a specific ad-hoc retriever execution.\n\nReturns comprehensive execution details including:\n    - Execution metadata (status, duration, credits used)\n    - Performance metrics (documents processed/returned, cache hit rate)\n    - Input data and query summary\n    - Stage completion information\n    - Collections queried\n\nUse Cases:\n    - Debug specific ad-hoc executions\n    - Analyze performance of a particular query\n    - Retrieve execution inputs for reproduction\n    - Audit ad-hoc retriever usage\n\nRaises:\n    404 NotFoundError: If execution not found or not an ad-hoc execution","operationId":"get_adhoc_execution_v1_retrievers_executions__execution_id__get","parameters":[{"name":"execution_id","in":"path","required":true,"schema":{"type":"string","description":"Execution identifier.","title":"Execution Id"},"description":"Execution identifier."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdhocExecutionDetail"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/benchmarks":{"post":{"tags":["Retriever Benchmarks"],"summary":"Create benchmark","description":"Create a new benchmark run to compare retriever pipelines. The benchmark will replay historical sessions and measure alignment with observed user behavior.","operationId":"create_benchmark_v1_retrievers_benchmarks_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateBenchmarkRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BenchmarkResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"get":{"tags":["Retriever Benchmarks"],"summary":"List benchmarks","description":"List benchmarks with optional filtering","operationId":"list_benchmarks_v1_retrievers_benchmarks_get","parameters":[{"name":"retriever_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter to benchmarks involving this retriever (as baseline or candidate)","title":"Retriever Id"},"description":"Filter to benchmarks involving this retriever (as baseline or candidate)"},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by status (pending, building_sessions, replaying, completed, failed)","title":"Status"},"description":"Filter by status (pending, building_sessions, replaying, completed, failed)"},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"description":"Page number","default":1,"title":"Page"},"description":"Page number"},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"description":"Items per page","default":20,"title":"Page Size"},"description":"Items per page"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BenchmarkListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/benchmarks/{benchmark_id}":{"get":{"tags":["Retriever Benchmarks"],"summary":"Get benchmark","description":"Get benchmark status and results by ID","operationId":"get_benchmark_v1_retrievers_benchmarks__benchmark_id__get","parameters":[{"name":"benchmark_id","in":"path","required":true,"schema":{"type":"string","title":"Benchmark Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BenchmarkResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"delete":{"tags":["Retriever Benchmarks"],"summary":"Delete benchmark","description":"Delete a benchmark and its results","operationId":"delete_benchmark_v1_retrievers_benchmarks__benchmark_id__delete","parameters":[{"name":"benchmark_id","in":"path","required":true,"schema":{"type":"string","title":"Benchmark Id"}}],"responses":{"204":{"description":"Successful Response"},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers":{"post":{"tags":["Retrievers"],"summary":"Create Retriever","description":"Create a new retriever.\n\nA retriever executes a series of stages to find and process documents\nfrom one or more collections.","operationId":"create_retriever_v1_retrievers_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateRetrieverRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateRetrieverResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"get":{"tags":["Retrievers"],"summary":"List Retrievers Get","description":"List all retrievers in the namespace (GET alias for POST /list).","operationId":"list_retrievers_get_v1_retrievers_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListRetrieversResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/list":{"post":{"tags":["Retrievers"],"summary":"List Retrievers","description":"List all retrievers in the namespace.","operationId":"list_retrievers_v1_retrievers_list_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListRetrieversRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListRetrieversResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/typeahead":{"get":{"tags":["Retrievers"],"summary":"Typeahead","description":"Prefix suggestions for a search box (autocomplete/typeahead).\n\nSuggests from three namespace-scoped sources concurrently: values of the\nrequested metadata fields (index-backed, with per-value document counts),\ncollection names, and the caller's own recent search queries. A source\nthat cannot answer is dropped and named in ``warnings`` rather than\nfailing the request.","operationId":"typeahead_v1_retrievers_typeahead_get","parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":1,"maxLength":200,"description":"The typed prefix.","title":"Q"},"description":"The typed prefix."},{"name":"fields","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Comma-separated metadata field paths to suggest values from (e.g. `metadata.talent,metadata.production`). Each field should carry a keyword index; at most 5 are consulted. Omit to skip the field-value source.","title":"Fields"},"description":"Comma-separated metadata field paths to suggest values from (e.g. `metadata.talent,metadata.production`). Each field should carry a keyword index; at most 5 are consulted. Omit to skip the field-value source."},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":50,"minimum":1,"description":"Max suggestions per source.","default":10,"title":"Limit"},"description":"Max suggestions per source."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TypeaheadResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/{retriever_id}":{"get":{"tags":["Retrievers"],"summary":"Get Retriever","description":"Get a retriever by ID or name.","operationId":"get_retriever_v1_retrievers__retriever_id__get","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","description":"Retriever ID or name.","title":"Retriever Id"},"description":"Retriever ID or name."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RetrieverModel-Output"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"patch":{"tags":["Retrievers"],"summary":"Patch Retriever","description":"Update a retriever's metadata.\n\nEditable fields:\n- name, description, tags, display_config: metadata\n- collection_identifiers: re-points + re-validates stage feature URIs\n- stages: edit stages in place on an UNPUBLISHED retriever\n  (change a filter/operator/rerank without clone+repoint+delete); the full\n  stage list is replaced + re-validated as on create. A PUBLISHED retriever's\n  stages stay immutable — clone or unpublish to change them.\n- input_schema: NON-BREAKING evolution only (add default/examples/description\n  to a field, add a new optional field). Breaking changes — removing a field,\n  changing a type, making a field newly required — are rejected with 422\n  naming each one; clone the retriever for those.\n\nbudget_limits remains immutable; use POST /{retriever_id}/clone.","operationId":"patch_retriever_v1_retrievers__retriever_id__patch","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","description":"Retriever ID or name.","title":"Retriever Id"},"description":"Retriever ID or name."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchRetrieverRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchRetrieverResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"delete":{"tags":["Retrievers"],"summary":"Delete Retriever","description":"Delete a retriever and all its resources comprehensively.\n\nDeletes:\n- Published retrievers\n- Execution history\n- Interactions (user feedback)\n- Evaluations\n- Cache entries\n- Retriever metadata\n\nThe deletion is performed synchronously and returns when complete.","operationId":"delete_retriever_v1_retrievers__retriever_id__delete","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","description":"Retriever ID or name.","title":"Retriever Id"},"description":"Retriever ID or name."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["delete"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/{retriever_id}/clone":{"post":{"tags":["Retrievers"],"summary":"Clone Retriever","description":"Clone a retriever with optional modifications.\n\n**Purpose:**\nCreates a NEW retriever (with new ID) based on an existing one. This is the\nrecommended way to iterate on retriever designs when you need to modify core\nlogic that PATCH doesn't allow (stages, input_schema, collections).\n\n**Clone vs PATCH vs Template:**\n- **PATCH**: Update metadata only (name, description, tags, display_config)\n- **Clone**: Copy and modify core logic (stages, input_schema, collections)\n- **Template**: Start from a pre-configured pattern (for new projects)\n\n**Common Use Cases:**\n- Fix a typo in a stage name\n- Add or remove stages\n- Change target collections\n- Create variants (e.g., \"strict\" vs \"relaxed\" versions)\n- Test modifications before replacing production retriever\n\n**How it works:**\n1. Source retriever is copied\n2. You provide a new name (REQUIRED)\n3. Optionally override any other fields\n4. A new retriever is created with a new ID\n5. Original retriever remains unchanged\n\n**All fields except retriever_name are OPTIONAL:**\n- Omit a field to copy from source\n- Provide a field to override the source value","operationId":"clone_retriever_v1_retrievers__retriever_id__clone_post","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","description":"Source retriever ID or name to clone.","title":"Retriever Id"},"description":"Source retriever ID or name to clone."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloneRetrieverRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloneRetrieverResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/{retriever_id}/execute":{"post":{"tags":["Retrievers"],"summary":"Execute Retriever (Auto-Optimized)","description":"Execute a retriever and return matching documents. The pipeline is automatically optimized before execution for best performance.\n\n**Automatic Optimization:**\nYour pipeline stages are automatically transformed for optimal performance:\n- Filters pushed down to reduce expensive operations\n- Redundant stages merged or eliminated\n- Grouping operations pushed to database layer (10-100x faster)\n- Operations reordered for efficiency\n\n**Streaming Support:**\nSet stream=true in the request body to receive real-time stage updates via SSE:\n- Response uses text/event-stream content type\n- Each stage emits stage_start and stage_complete events\n- Final event contains complete results, pagination and consistency_mode\n- Useful for progress tracking and debugging\n\n**Response Includes (when stream=false):**\n- documents: Final matching documents\n- pagination: Pagination metadata\n- stage_statistics: Per-stage execution metrics\n- budget: Credit/time consumption\n- limits: Every cap that clamped the request (setting, value asked for, value used, the cap's maximum, the stage), absent when nothing was capped. A capped run can return fewer documents than asked for.\n- optimization_applied: Whether optimizations were applied\n- optimization_summary: Details about transformations (when applied)\n\n**Optimization Summary Example:**\n```json\n{\n  \"optimization_applied\": true,\n  \"optimization_summary\": {\n    \"original_stage_count\": 5,\n    \"optimized_stage_count\": 3,\n    \"optimization_time_ms\": 8.2,\n    \"rules_applied\": [\"push_down_filters\", \"group_by_push_down\"],\n    \"stage_reduction_pct\": 40.0\n  }\n}\n```\n\nUse the /explain endpoint to see the optimized execution plan before running.","operationId":"execute_retriever_v1_retrievers__retriever_id__execute_post","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","description":"Retriever ID or name. Pipeline will be automatically optimized before execution.","title":"Retriever Id"},"description":"Retriever ID or name. Pipeline will be automatically optimized before execution."},{"name":"return_presigned_urls","in":"query","required":false,"schema":{"type":"boolean","description":"Generate presigned URLs for S3-backed blobs and url-shaped fields. Also accepted as a body field — if either source is true, presigning is enabled.","default":false,"title":"Return Presigned Urls"},"description":"Generate presigned URLs for S3-backed blobs and url-shaped fields. Also accepted as a body field — if either source is true, presigning is enabled."},{"name":"return_vectors","in":"query","required":false,"schema":{"type":"boolean","description":"Include vector embeddings in result documents. Also accepted as a body field — if either source is true, vectors are returned.","default":false,"title":"Return Vectors"},"description":"Include vector embeddings in result documents. Also accepted as a body field — if either source is true, vectors are returned."},{"name":"explain","in":"query","required":false,"schema":{"type":"boolean","description":"Return the inline `explain_plan` (per-stage timings + optimization summary) in the response. Also accepted as a body field — if either source is true, the plan is included.","default":false,"title":"Explain"},"description":"Return the inline `explain_plan` (per-stage timings + optimization summary) in the response. Also accepted as a body field — if either source is true, the plan is included."},{"name":"include_legacy_results","in":"query","required":false,"schema":{"type":"boolean","description":"DEPRECATED. Restore the legacy `results` alias (a byte-for-byte copy of `documents`). Off by default — `results` previously duplicated the entire document array in every response (~half the payload). Prefer `documents`; use this only as a temporary migration shim.","default":false,"title":"Include Legacy Results"},"description":"DEPRECATED. Restore the legacy `results` alias (a byte-for-byte copy of `documents`). Off by default — `results` previously duplicated the entire document array in every response (~half the payload). Prefer `documents`; use this only as a temporary migration shim."},{"name":"skip_cache","in":"query","required":false,"schema":{"type":"boolean","description":"Bypass the execute/stage cache read for this request (a fresh execution; the result is still written to cache). Also accepted as a body field — if either source is true, the cache is skipped.","default":false,"title":"Skip Cache"},"description":"Bypass the execute/stage cache read for this request (a fresh execution; the result is still written to cache). Also accepted as a body field — if either source is true, the cache is skipped."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExecuteRetrieverRequest","description":"Execution request with inputs, filters, pagination, and optional stream parameter. Set stream=true to receive real-time stage updates via Server-Sent Events."}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Execution results with documents, pagination, statistics, and optimization details. When stream=true, returns Server-Sent Events. When stream=false, returns JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExecuteRetrieverResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/{retriever_id}/execute/batch":{"post":{"tags":["Retrievers"],"summary":"Batch Execute Retriever","description":"Execute a retriever against multiple queries in a single request. The retriever is fetched and optimized once, then executed concurrently against each query with bounded parallelism.\n\n**Use case:** IP safety / copyright clearance — scan 20 media files against face, logo, or audio retrievers in one call instead of 60 sequential SSE requests.\n\n**Limits:** 1-16 queries per batch (a 17th is refused with `limits.max_queries`), 1-20 concurrency.\n\nReturns results keyed by query index with per-query documents and errors.","operationId":"execute_batch_v1_retrievers__retriever_id__execute_batch_post","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","description":"Retriever ID or name.","title":"Retriever Id"},"description":"Retriever ID or name."},{"name":"return_presigned_urls","in":"query","required":false,"schema":{"type":"boolean","description":"Generate presigned URLs for S3-backed blobs and url-shaped fields. Also accepted as a body field — if either source is true, presigning is enabled.","default":false,"title":"Return Presigned Urls"},"description":"Generate presigned URLs for S3-backed blobs and url-shaped fields. Also accepted as a body field — if either source is true, presigning is enabled."},{"name":"return_vectors","in":"query","required":false,"schema":{"type":"boolean","description":"Include vector embeddings in result documents. Also accepted as a body field — if either source is true, vectors are returned.","default":false,"title":"Return Vectors"},"description":"Include vector embeddings in result documents. Also accepted as a body field — if either source is true, vectors are returned."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExecuteBatchRequest","description":"Batch of queries to execute."}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/{retriever_id}/executions/list":{"post":{"tags":["Retrievers"],"summary":"List Executions","description":"List execution history for a retriever.","operationId":"list_executions_v1_retrievers__retriever_id__executions_list_post","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","description":"Retriever ID or name.","title":"Retriever Id"},"description":"Retriever ID or name."},{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListExecutionsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListExecutionsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/{retriever_id}/executions/{execution_id}/status":{"get":{"tags":["Retrievers"],"summary":"Get Live Execution Status","description":"Fetch live execution status from the durability journal. Returns real-time progress including current stage, completed stages, and heartbeat timestamp. If the execution is completed, returns the full results. Falls back to the execution history for past executions.","operationId":"get_execution_status_v1_retrievers__retriever_id__executions__execution_id__status_get","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","description":"Retriever ID or name.","title":"Retriever Id"},"description":"Retriever ID or name."},{"name":"execution_id","in":"path","required":true,"schema":{"type":"string","description":"Execution identifier.","title":"Execution Id"},"description":"Execution identifier."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Execution Status V1 Retrievers  Retriever Id  Executions  Execution Id  Status Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/{retriever_id}/executions/{execution_id}":{"get":{"tags":["Retrievers"],"summary":"Get Execution","description":"Get execution details and statistics.","operationId":"get_execution_v1_retrievers__retriever_id__executions__execution_id__get","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","description":"Retriever ID or name.","title":"Retriever Id"},"description":"Retriever ID or name."},{"name":"execution_id","in":"path","required":true,"schema":{"type":"string","description":"Execution identifier.","title":"Execution Id"},"description":"Execution identifier."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExecutionDetail"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/{retriever_id}/executions/{execution_id}/profile":{"get":{"tags":["Retrievers"],"summary":"Get Execution Query Profile (explain-on-execute read path)","description":"Return the query profile for a PAST execution, by execution_id — the same plan that `explain=true` returns inline at execute time, read back later. Contains per-stage timings + input/output counts, MVS execution stats, the optimizer summary, and (as it is wired) the shard ExecutionTrace (chosen legs, fusion, push-downs, nprobe, served/shadow planner). Reads the query_profile stored on the execution's record in the mxp_retriever_executions collection. Returns 404 if the execution has no captured profile. This is the queryable, Studio-friendly counterpart to inline explain.","operationId":"get_execution_profile_v1_retrievers__retriever_id__executions__execution_id__profile_get","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","description":"Retriever ID or name.","title":"Retriever Id"},"description":"Retriever ID or name."},{"name":"execution_id","in":"path","required":true,"schema":{"type":"string","description":"Execution identifier.","title":"Execution Id"},"description":"Execution identifier."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Execution Profile V1 Retrievers  Retriever Id  Executions  Execution Id  Profile Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/{retriever_id}/execute/explain":{"post":{"tags":["Retrievers"],"summary":"Explain Retriever Execution Plan","description":"Get a detailed execution plan for a retriever without actually executing it. Similar to MongoDB's explain plan or SQL's EXPLAIN command, this endpoint helps you understand performance characteristics, identify bottlenecks, estimate costs, and troubleshoot retrieval issues before running expensive queries.\n\n**What This Returns:**\n- Stage-by-stage execution plan (AFTER automatic optimizations)\n- Estimated costs (credits + time per stage)\n- Document flow projections (input/output counts per stage)\n- Efficiency metrics (selectivity ratios, cache likelihood)\n- Bottleneck identification (slowest/most expensive stages)\n- Optimization details (transformations applied by the optimizer)\n- Performance warnings and improvement suggestions\n\n\n**Key Features:**\n- **Cost Estimation**: See how many credits and milliseconds each stage will consume\n- **Bottleneck Detection**: Identify which stages dominate execution time\n- **Optimization Transparency**: Understand how your pipeline was optimized\n- **Cache Analysis**: See which stages are likely to hit cache\n- **Accuracy Troubleshooting**: Analyze stage efficiency and document flow\n- **Latency Analysis**: Break down estimated duration by stage\n\n\n**Important:** The execution_plan shows OPTIMIZED stages (after automatic transformations like filter push-down, stage fusion, and grouping optimization). Check optimization_details to understand what changed from your original configuration.\n\n\n**Use Cases:**\n- Debug slow retrievers by identifying bottleneck stages\n- Estimate costs before running expensive queries\n- Understand how the optimizer transformed your pipeline\n- Troubleshoot accuracy issues by analyzing stage selectivity\n- Compare different retriever configurations\n- Plan budget allocation for production workloads\n\n\n**Example Response:**\n```json\n{\n  \"retriever_id\": \"ret_abc123\",\n  \"retriever_name\": \"product_search\",\n  \"execution_plan\": [\n    {\n      \"stage_index\": 0,\n      \"stage_name\": \"attribute_filter\",\n      \"stage_type\": \"filter\",\n      \"estimated_input\": 10000,\n      \"estimated_output\": 5000,\n      \"estimated_efficiency\": 0.5,\n      \"estimated_cost_credits\": 0.01,\n      \"estimated_duration_ms\": 20,\n      \"cache_likely\": true,\n      \"optimization_notes\": [\"Pushed down from stage 2\"],\n      \"warnings\": []\n    },\n    {\n      \"stage_index\": 1,\n      \"stage_name\": \"semantic_search\",\n      \"stage_type\": \"filter\",\n      \"estimated_input\": 5000,\n      \"estimated_output\": 100,\n      \"estimated_efficiency\": 0.02,\n      \"estimated_cost_credits\": 0.5,\n      \"estimated_duration_ms\": 200,\n      \"cache_likely\": false,\n      \"optimization_notes\": [],\n      \"warnings\": [\"High cost stage - consider reducing limit\"]\n    }\n  ],\n  \"estimated_cost\": {\n    \"total_credits\": 0.51,\n    \"total_duration_ms\": 220\n  },\n  \"bottleneck_stages\": [\"semantic_search\"],\n  \"optimization_applied\": true,\n  \"optimization_details\": {\n    \"original_stage_count\": 3,\n    \"optimized_stage_count\": 2,\n    \"optimization_time_ms\": 8.2,\n    \"stage_reduction_pct\": 33.3,\n    \"decisions\": [\n      {\n        \"rule_type\": \"push_down_filters\",\n        \"applied\": true,\n        \"reason\": \"Moved attribute_filter before semantic_search to reduce search scope\"\n      }\n    ]\n  },\n  \"optimization_suggestions\": [\n    {\n      \"type\": \"reduce_limit\",\n      \"stage\": \"semantic_search\",\n      \"message\": \"Consider reducing limit to improve latency\"\n    }\n  ]\n}\n```","operationId":"explain_retriever_execution_v1_retrievers__retriever_id__execute_explain_post","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","description":"Retriever ID or name to explain. The execution plan will show the OPTIMIZED version after automatic transformations.","title":"Retriever Id"},"description":"Retriever ID or name to explain. The execution plan will show the OPTIMIZED version after automatic transformations."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExplainRetrieverRequest","description":"Optional hypothetical inputs for estimation. Provide sample inputs to see how the plan changes with different parameters (e.g., different top_k values, query complexity, filter combinations). If not provided, uses default/representative values."}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Detailed execution plan with stage-by-stage cost estimates, optimization details, bottleneck identification, and performance insights. Use this to troubleshoot slow queries, estimate costs, and understand optimizer transformations.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExplainRetrieverResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/{retriever_id}/api-keys":{"post":{"tags":["Retriever API Keys"],"summary":"Create Retriever API Key","description":"Generate a scoped API key for executing this specific retriever.\n\n    **Use Cases:**\n    - Provide external services with execution-only access\n    - Embed retriever calls in customer applications\n    - Create separate keys for staging vs production\n    - Implement per-customer access keys for SaaS products\n\n    **Security:**\n    - Keys grant EXECUTE_RETRIEVER permission only\n    - Keys are scoped to single retriever (cannot access others)\n    - Keys inherit org's rate limits\n    - Keys can be revoked instantly\n    - Key prefix (ret_sk_abc...) shown in UI for identification\n\n    **Ownership:**\n    - Only the organization that owns the retriever can create keys\n    - Verified by matching internal_id + namespace_id\n\n    **Key Format:**\n    - Prefix: ret_sk_\n    - Length: 60 characters\n    - Example: ret_sk_abcdefghijklmnopqrstuvwxyz123456789...\n\n    **Response:**\n    - Plaintext key shown ONLY ONCE in response\n    - Save the key immediately - it cannot be retrieved later\n    - Key prefix stored for identification in UI","operationId":"create_retriever_api_key_v1_retrievers__retriever_id__api_keys_post","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","title":"Retriever Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateRetrieverAPIKeyRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RetrieverAPIKeyResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"get":{"tags":["Retriever API Keys"],"summary":"List Retriever API Keys","description":"List all API keys for this retriever.\n\n    **Fields:**\n    - key_id: Public identifier for the key\n    - key_prefix: First 10 characters + \"...\" for identification (e.g., \"ret_sk_abc...\")\n    - name: Human-friendly label\n    - created_at: When the key was created\n    - last_used_at: When the key was last used (if ever)\n    - status: ACTIVE, REVOKED, or EXPIRED\n    - expires_at: Expiration timestamp (if set)\n\n    **Note:**\n    - Plaintext key is NEVER returned in list responses\n    - Only shown once in creation response\n    - Use key_prefix to identify keys in the UI","operationId":"list_retriever_api_keys_v1_retrievers__retriever_id__api_keys_get","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","title":"Retriever Id"}},{"name":"include_revoked","in":"query","required":false,"schema":{"type":"boolean","description":"Include revoked and expired keys in the response","default":false,"title":"Include Revoked"},"description":"Include revoked and expired keys in the response"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RetrieverAPIKeyListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/{retriever_id}/api-keys/{key_id}":{"delete":{"tags":["Retriever API Keys"],"summary":"Revoke Retriever API Key","description":"Revoke a retriever-scoped API key.\n\n    **Effect:**\n    - Key status is set to REVOKED\n    - Key can no longer be used for authentication\n    - Revocation is immediate (no grace period)\n    - Auth cache is invalidated immediately\n    - Cannot be undone (create a new key if needed)\n\n    **Audit:**\n    - Revocation is logged in the retriever's audit trail\n    - Includes actor user ID and timestamp","operationId":"revoke_retriever_api_key_v1_retrievers__retriever_id__api_keys__key_id__delete","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","title":"Retriever Id"}},{"name":"key_id","in":"path","required":true,"schema":{"type":"string","title":"Key Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenericSuccessResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/interactions":{"post":{"tags":["Retriever Interactions"],"summary":"Create Interaction","description":"Record a search interaction (view, click, feedback, etc.).\n\nAutomatically computes and injects ``metadata.reward_value`` based on\nthe interaction types and the retriever's reward_map configuration.\nThis pre-computed value is used by the learned-fusion bandit aggregation\nquery so it doesn't need to join against the retriever config at read time.\n\n**Deduplication (Phase 4e):** If ``(execution_id, feature_id,\ninteraction_type)`` has already been recorded within the last 5 minutes\nthe duplicate is silently dropped.\n\n**Session cache (Phase 1b):** When ``session_id`` is present the\ninteraction is also written to the Redis session cache so the Thompson\nSampling bandit can incorporate it in real time, before the stored\naggregate refreshes.","operationId":"create_interaction_v1_retrievers_interactions_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchInteraction"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InteractionResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/interactions/batch":{"post":{"tags":["Retriever Interactions"],"summary":"Create Interactions Bulk","description":"Record up to 1000 interactions in one call — for backfilling history.\n\nEach interaction is enriched (reward_value, feature_uri/context promotion)\nexactly like the single-create path, then written. Reward config is resolved\nONCE per distinct retriever (not per interaction). Dedup and the real-time\nsession cache are skipped — bulk writes are for historical backfill, not\nlive in-session adaptation. Set each interaction's ``occurred_at`` to its\ntrue timestamp so temporal decay weights it by real age.","operationId":"create_interactions_bulk_v1_retrievers_interactions_batch_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkInteractionsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkInteractionsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/interactions/list":{"post":{"tags":["Retriever Interactions"],"summary":"List Interactions","description":"List interactions with optional filters and pagination.\n\nSupports hybrid filtering: simple fields + advanced LogicalOperator.","operationId":"list_interactions_v1_retrievers_interactions_list_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListInteractionsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListInteractionsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/interactions/{interaction_id}":{"get":{"tags":["Retriever Interactions"],"summary":"Get Interaction","description":"Get a specific interaction.","operationId":"get_interaction_v1_retrievers_interactions__interaction_id__get","parameters":[{"name":"interaction_id","in":"path","required":true,"schema":{"type":"string","title":"Interaction Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InteractionResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"delete":{"tags":["Retriever Interactions"],"summary":"Delete Interaction","description":"Delete a specific interaction (idempotent - succeeds even if already deleted).","operationId":"delete_interaction_v1_retrievers_interactions__interaction_id__delete","parameters":[{"name":"interaction_id","in":"path","required":true,"schema":{"type":"string","title":"Interaction Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Delete Interaction V1 Retrievers Interactions  Interaction Id  Delete"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/evaluations/datasets":{"post":{"tags":["Retriever Evaluations"],"summary":"Create evaluation dataset","description":"Create a ground truth dataset for evaluating retrievers. Include queries with their relevant documents and optional graded relevance scores.","operationId":"create_dataset_v1_retrievers_evaluations_datasets_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateDatasetRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EvaluationDataset"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"get":{"tags":["Retriever Evaluations"],"summary":"List evaluation datasets","description":"List all evaluation datasets with pagination","operationId":"list_datasets_v1_retrievers_evaluations_datasets_get","parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"description":"Page number (1-indexed)","default":1,"title":"Page"},"description":"Page number (1-indexed)"},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"description":"Items per page","default":20,"title":"Page Size"},"description":"Items per page"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DatasetListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/evaluations/datasets/{dataset_identifier}":{"get":{"tags":["Retriever Evaluations"],"summary":"Get evaluation dataset","description":"Retrieve a specific dataset by ID or name","operationId":"get_dataset_v1_retrievers_evaluations_datasets__dataset_identifier__get","parameters":[{"name":"dataset_identifier","in":"path","required":true,"schema":{"type":"string","title":"Dataset Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EvaluationDataset"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/{retriever_id}/evaluations/generate-from-interactions":{"post":{"tags":["Retriever Evaluations"],"summary":"Generate evaluation dataset from interactions","description":"Auto-generate a ground truth evaluation dataset by mining user interactions for this retriever. Queries with sufficient positive interactions (click, purchase, bookmark, etc.) are used to infer relevance labels, creating a dataset suitable for offline evaluation.","operationId":"generate_dataset_from_interactions_v1_retrievers__retriever_id__evaluations_generate_from_interactions_post","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","title":"Retriever Id"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerateFromInteractionsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EvaluationDataset"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/{retriever_id}/evaluations":{"post":{"tags":["Retriever Evaluations"],"summary":"Run evaluation","description":"Evaluate a retriever's quality using a ground truth dataset. Returns immediately with a task ID - evaluation runs asynchronously.","operationId":"start_evaluation_v1_retrievers__retriever_id__evaluations_post","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","title":"Retriever Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StartEvaluationRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StartEvaluationResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"get":{"tags":["Retriever Evaluations"],"summary":"List evaluations","description":"List all evaluations for a retriever with optional filters","operationId":"list_evaluations_v1_retrievers__retriever_id__evaluations_get","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","title":"Retriever Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/EvaluationStatus"},{"type":"null"}],"description":"Filter by status (pending, in_progress, completed, failed)","title":"Status"},"description":"Filter by status (pending, in_progress, completed, failed)"},{"name":"dataset_name","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by dataset name","title":"Dataset Name"},"description":"Filter by dataset name"},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"description":"Page number (1-indexed)","default":1,"title":"Page"},"description":"Page number (1-indexed)"},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"description":"Items per page","default":20,"title":"Page Size"},"description":"Items per page"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EvaluationListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/retrievers/{retriever_id}/evaluations/{evaluation_id}":{"get":{"tags":["Retriever Evaluations"],"summary":"Get evaluation results","description":"Retrieve evaluation results with all calculated metrics","operationId":"get_evaluation_v1_retrievers__retriever_id__evaluations__evaluation_id__get","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","title":"Retriever Id"}},{"name":"evaluation_id","in":"path","required":true,"schema":{"type":"string","title":"Evaluation Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EvaluationRecord"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/evaluations":{"get":{"tags":["Retriever Evaluations"],"summary":"Discover evaluation endpoints","description":"Lightweight discovery endpoint. Evaluation **datasets** are namespace-scoped and evaluation **runs** are retriever-scoped, so both live under `/v1/retrievers/...` rather than a top-level `/v1/evaluations/{id}`. This endpoint exists so a bare `GET /v1/evaluations` returns the real endpoint map instead of a hintless 404.","operationId":"discover_evaluations_v1_evaluations_get","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Discover Evaluations V1 Evaluations Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/evaluations/score":{"post":{"tags":["Retriever Evaluations"],"summary":"Score predictions vs ground truth (stateless)","description":"Compute quality metrics (Precision@K, Recall@K, F1@K, F2@K) for precomputed predictions vs ground truth, with NO retriever, namespace, or persistence. Each item's `predicted` and `ground_truth` are treated as SETS. Send a single pair (`predicted` + `ground_truth`) or an `items` batch. Returns per-item scores and the macro-average across items. Auth only (no X-Namespace). This is the stateless counterpart to the retriever-scoped evaluation runs — use it to dogfood F1/F2 on extraction/generation benchmarks.","operationId":"score_predictions_v1_evaluations_score_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScorePredictionsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScorePredictionsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/inference":{"post":{"tags":["Inference"],"summary":"Execute Raw Inference","description":"Execute raw inference with provider+model or custom plugin.\n\nThis endpoint provides direct access to inference services without\nthe retriever framework overhead. Supports two modes:\n\n1. **Provider + Model**: Use standard providers (openai, google, anthropic).\n   ``gemini`` is accepted as an alias for ``google``.\n2. **Custom Plugin**: Use your custom inference plugins by inference_name\n\n## Supported Providers\n\n- **openai**: GPT models, embeddings, Whisper transcription\n- **google** (alias **gemini**): Gemini models, Vertex multimodal embeddings (1408D)\n- **anthropic**: Claude models\n\n## Examples\n\n### Custom Plugin (by inference_name)\n```json\n{\n    \"inference_name\": \"my_text_embedder_1_0_0\",\n    \"inputs\": {\"text\": \"hello world\"},\n    \"parameters\": {}\n}\n```\n\n### Custom Plugin (by feature_uri)\n```json\n{\n    \"feature_uri\": \"mixpeek://my_custom_embedder@1.0.0/embedding\",\n    \"inputs\": {\"text\": \"hello world\"},\n    \"parameters\": {}\n}\n```\n\n### Builtin Embedder (by feature_uri)\n```json\n{\n    \"feature_uri\": \"mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1\",\n    \"inputs\": {\"text\": \"hello world\"},\n    \"parameters\": {}\n}\n```\n\n### Chat Completion\n```json\n{\n    \"provider\": \"openai\",\n    \"model\": \"gpt-4o-mini\",\n    \"inputs\": {\"prompts\": [\"What is AI?\"]},\n    \"parameters\": {\"temperature\": 0.7, \"max_tokens\": 500}\n}\n```\n\n### Text Embedding (OpenAI)\n```json\n{\n    \"provider\": \"openai\",\n    \"model\": \"text-embedding-3-large\",\n    \"inputs\": {\"text\": \"machine learning\"},\n    \"parameters\": {}\n}\n```\n\n### Text Embedding (Google Vertex Multimodal - 1408D)\n```json\n{\n    \"provider\": \"google\",\n    \"model\": \"multimodalembedding\",\n    \"inputs\": {\"text\": \"machine learning\"},\n    \"parameters\": {}\n}\n```\n\n### Image Embedding (Google Vertex Multimodal - 1408D)\n```json\n{\n    \"provider\": \"google\",\n    \"model\": \"multimodalembedding\",\n    \"inputs\": {\"image_url\": \"https://example.com/image.jpg\"},\n    \"parameters\": {}\n}\n```\n\n### Image Embedding from Base64\n```json\n{\n    \"provider\": \"google\",\n    \"model\": \"multimodalembedding\",\n    \"inputs\": {\"image_base64\": \"<base64-encoded-image>\"},\n    \"parameters\": {}\n}\n```\n\n### Video Embedding (Google Vertex Multimodal - 1408D)\n```json\n{\n    \"provider\": \"google\",\n    \"model\": \"multimodalembedding\",\n    \"inputs\": {\"video_url\": \"https://example.com/video.mp4\"},\n    \"parameters\": {}\n}\n```\n\n### Video Embedding from Base64\n```json\n{\n    \"provider\": \"google\",\n    \"model\": \"multimodalembedding\",\n    \"inputs\": {\"video_base64\": \"<base64-encoded-video>\"},\n    \"parameters\": {}\n}\n```\n\n### Audio Transcription\n```json\n{\n    \"provider\": \"openai\",\n    \"model\": \"whisper-1\",\n    \"inputs\": {\"audio_url\": \"https://example.com/audio.mp3\"},\n    \"parameters\": {}\n}\n```\n\n### Vision (Multimodal LLM)\n```json\n{\n    \"provider\": \"openai\",\n    \"model\": \"gpt-4o\",\n    \"inputs\": {\n        \"prompts\": [\"Describe this image\"],\n        \"image_url\": \"https://example.com/image.jpg\"\n    },\n    \"parameters\": {\"temperature\": 0.5}\n}\n```\n\nArgs:\n    request: FastAPI request object (populated by middleware)\n    payload: Raw inference request\n\nReturns:\n    Inference response with results and metadata\n\nRaises:\n    400 Bad Request: Invalid provider, model, or inputs\n    422 Unprocessable Entity: inputs carries no key the provider call\n        reads (for example ``prompt`` instead of ``prompts``)\n    401 Unauthorized: Missing or invalid API key\n    429 Too Many Requests: Rate limit exceeded\n    500 Internal Server Error: Inference execution failed","operationId":"execute_raw_inference_v1_inference_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawInferenceRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawInferenceResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/organizations":{"get":{"tags":["Organizations"],"summary":"Get Organization","description":"Get current organization details.\n\nSecurity: Infrastructure configuration is NOT exposed via this endpoint.\nInfrastructure (vector store URLs, Ray clusters) is only accessible via private admin endpoints.","operationId":"get_organization_v1_organizations_get","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationModelResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]},"patch":{"tags":["Organizations"],"summary":"Update Organization","description":"Update organization settings (requires ADMIN permission).\n\nSecurity: Infrastructure configuration cannot be modified via this endpoint.\nInfrastructure updates require Mixpeek admin access via private endpoints.","operationId":"update_organization_v1_organizations_patch","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationUpdateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationModelResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/credits":{"get":{"tags":["Organizations"],"summary":"Get Credits","description":"Read the org's credit/usage state.\n\nGET on this path returned 405 (only POST existed) — a\nnatural read that every evaluator tries. Returns the ENFORCED ceiling\n(`effective_monthly_credit_cap`, the number the block point uses), the\ncurrent month usage, and the decorative legacy `credit_count` clearly\nlabeled as non-gating.","operationId":"get_credits_v1_organizations_credits_get","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Credits V1 Organizations Credits Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/me":{"get":{"tags":["Account"],"summary":"Whoami","description":"Return the caller's identity: organization, tier, key metadata, limits.\n\nWorks for every valid key. `/account` is an undocumented alias so both\nnatural spellings resolve.","operationId":"whoami_v1_me_get","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MeResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/connections":{"post":{"tags":["Organization Connections"],"summary":"Create Storage Connection","description":"Create a new storage provider connection.\n\nEstablishes a connection to an external storage provider (Google Drive, S3, etc.)\nfor use in sync operations. Credentials are validated before saving unless\ntest_before_save is False.\n\n**Use Cases:**\n- Connect to team Google Drive for automated file ingestion\n- Link customer S3 buckets for batch processing\n- Set up storage connections for sync operations\n\n**Security:**\n- Requires ADMIN permission\n- Credentials never appear in read responses; only the credential type is returned\n- Connection is tested before saving (unless test_before_save=False)\n- Audit log entry created for compliance\n\n**Example:**\n```bash\ncurl -X POST \"http://localhost:8000/v1/organizations/connections\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\n    \"name\": \"Marketing Drive\",\n    \"provider_type\": \"google_drive\",\n    \"provider_config\": {\n      \"credentials\": {...},\n      \"shared_drive_id\": \"0AH-Xabc123\"\n    }\n  }'\n```","operationId":"create_storage_connection_v1_organizations_connections_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageConnectionCreateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageConnectionModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/connections/list":{"post":{"tags":["Organization Connections"],"summary":"List Storage Connections","description":"List storage connections for the authenticated organization.\n\nReturns paginated results with optional filters for provider type, status,\nand active flag. Results are sorted by creation date (newest first).\n\n**Use Cases:**\n- List all active Google Drive connections\n- Find failed connections that need attention\n- Filter by provider type for sync configuration\n\n**Example:**\n```bash\ncurl -X POST \"http://localhost:8000/v1/organizations/connections/list\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\n    \"provider_type\": \"google_drive\",\n    \"is_active\": true\n  }'\n```","operationId":"list_storage_connections_v1_organizations_connections_list_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListStorageConnectionsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageConnectionListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/connections/{connection_identifier}":{"get":{"tags":["Organization Connections"],"summary":"Get Storage Connection","description":"Retrieve a storage connection by ID or name.\n\nReturns connection metadata including name, provider type, status, and\nhealth information. Credential fields are not returned; provider_config.credentials\ncarries only the credential type.\n\n**Identifier Resolution:**\n- If identifier starts with 'conn_', treated as connection ID\n- Otherwise, treated as connection name\n\n**Example:**\n```bash\n# By ID\ncurl -X GET \"http://localhost:8000/v1/organizations/connections/conn_abc123\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\"\n\n# By name\ncurl -X GET \"http://localhost:8000/v1/organizations/connections/Marketing%20Drive\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\"\n```","operationId":"get_storage_connection_v1_organizations_connections__connection_identifier__get","parameters":[{"name":"connection_identifier","in":"path","required":true,"schema":{"type":"string","description":"Connection identifier - either connection ID (conn_...) or name. The system will automatically resolve names to IDs.","examples":["conn_abc123def456ghi","Marketing Google Drive"],"title":"Connection Identifier"},"description":"Connection identifier - either connection ID (conn_...) or name. The system will automatically resolve names to IDs."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageConnectionModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]},"patch":{"tags":["Organization Connections"],"summary":"Update Storage Connection","description":"Update connection metadata or credentials.\n\nAllows partial updates to connection metadata without changing credentials.\nCredentials can be updated via provider_config. All changes are logged\nin audit trail.\n\n**What You Can Update:**\n- Connection name and description\n- Metadata tags\n- Status (active/suspended)\n- Provider credentials (via provider_config)\n\n**Example:**\n```bash\ncurl -X PATCH \"http://localhost:8000/v1/organizations/connections/conn_abc123\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\n    \"name\": \"Updated Drive Name\",\n    \"status\": \"suspended\"\n  }'\n```","operationId":"update_storage_connection_v1_organizations_connections__connection_identifier__patch","parameters":[{"name":"connection_identifier","in":"path","required":true,"schema":{"type":"string","description":"Connection identifier - either connection ID (conn_...) or name. The system will automatically resolve names to IDs.","examples":["conn_abc123def456ghi","Marketing Google Drive"],"title":"Connection Identifier"},"description":"Connection identifier - either connection ID (conn_...) or name. The system will automatically resolve names to IDs."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageConnectionUpdateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageConnectionModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]},"delete":{"tags":["Organization Connections"],"summary":"Delete Storage Connection","description":"Soft-delete a connection (mark archived).\n\nPermanently retires a connection by marking it as ARCHIVED. The connection\ncannot be reactivated after deletion. Credentials are preserved for audit\npurposes but the connection is no longer usable.\n\n**Example:**\n```bash\ncurl -X DELETE \"http://localhost:8000/v1/organizations/connections/conn_abc123\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\"\n```","operationId":"delete_storage_connection_v1_organizations_connections__connection_identifier__delete","parameters":[{"name":"connection_identifier","in":"path","required":true,"schema":{"type":"string","description":"Connection identifier - either connection ID (conn_...) or name. The system will automatically resolve names to IDs.","examples":["conn_abc123def456ghi","Marketing Google Drive"],"title":"Connection Identifier"},"description":"Connection identifier - either connection ID (conn_...) or name. The system will automatically resolve names to IDs."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Delete Storage Connection V1 Organizations Connections  Connection Identifier  Delete"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/connections/{connection_identifier}/test":{"post":{"tags":["Organization Connections"],"summary":"Test Storage Connection","description":"Perform a credential test against the external provider.\n\nValidates that connection credentials are still valid and the provider\nis accessible. Result is logged in audit trail.\n\n**Use Cases:**\n- Validate credentials before using in sync operations\n- Diagnose connection issues\n- Refresh credentials after expiration\n\n**Example:**\n```bash\ncurl -X POST \"http://localhost:8000/v1/organizations/connections/conn_abc123/test\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\"\n```","operationId":"test_storage_connection_v1_organizations_connections__connection_identifier__test_post","parameters":[{"name":"connection_identifier","in":"path","required":true,"schema":{"type":"string","description":"Connection identifier - either connection ID (conn_...) or name. The system will automatically resolve names to IDs.","examples":["conn_abc123def456ghi","Marketing Google Drive"],"title":"Connection Identifier"},"description":"Connection identifier - either connection ID (conn_...) or name. The system will automatically resolve names to IDs."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageConnectionTestResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/connections/{connection_identifier}/folders":{"get":{"tags":["Organization Connections"],"summary":"List Google Drive Folders","description":"List folders in Google Drive for folder selection in sync configuration.\n\nEnables users to browse and select folders when configuring sync operations.\nOnly available for Google Drive connections.\n\n**Use Cases:**\n- Browse available folders for sync configuration\n- Select source folder for bucket sync\n- Navigate nested folder structures\n\n**Example:**\n```bash\ncurl -X GET \"http://localhost:8000/v1/organizations/connections/conn_abc123/folders?path=/Marketing\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\"\n```","operationId":"list_google_drive_folders_v1_organizations_connections__connection_identifier__folders_get","parameters":[{"name":"connection_identifier","in":"path","required":true,"schema":{"type":"string","description":"Connection identifier - either connection ID (conn_...) or name. The system will automatically resolve names to IDs.","examples":["conn_abc123def456ghi","Marketing Google Drive"],"title":"Connection Identifier"},"description":"Connection identifier - either connection ID (conn_...) or name. The system will automatically resolve names to IDs."},{"name":"path","in":"query","required":false,"schema":{"type":"string","description":"Parent folder path to list from","default":"/","title":"Path"},"description":"Parent folder path to list from"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListFoldersResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/connections/{connection_identifier}/files":{"get":{"tags":["Organization Connections"],"summary":"List Google Drive Files","description":"List files in Google Drive folder for preview.\n\nShows a preview of files in the selected folder when configuring sync operations.\nOnly available for Google Drive connections.\n\n**Use Cases:**\n- Preview files in a folder before selecting it for sync\n- Verify folder contains expected files\n- Check file types and counts\n\n**Example:**\n```bash\ncurl -X GET \"http://localhost:8000/v1/organizations/connections/conn_abc123/files?path=/Marketing&max_results=20\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\"\n```","operationId":"list_google_drive_files_v1_organizations_connections__connection_identifier__files_get","parameters":[{"name":"connection_identifier","in":"path","required":true,"schema":{"type":"string","description":"Connection identifier - either connection ID (conn_...) or name. The system will automatically resolve names to IDs.","examples":["conn_abc123def456ghi","Marketing Google Drive"],"title":"Connection Identifier"},"description":"Connection identifier - either connection ID (conn_...) or name. The system will automatically resolve names to IDs."},{"name":"path","in":"query","required":false,"schema":{"type":"string","description":"Folder path to list files from","default":"/","title":"Path"},"description":"Folder path to list files from"},{"name":"max_results","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Maximum number of files to return","default":50,"title":"Max Results"},"description":"Maximum number of files to return"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response List Google Drive Files V1 Organizations Connections  Connection Identifier  Files Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/users":{"post":{"tags":["Organization Users"],"summary":"Create User","description":"Create a new organization user.","operationId":"create_user_v1_organizations_users_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserCreateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Create User V1 Organizations Users Post"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]},"get":{"tags":["Organization Users"],"summary":"List Users","description":"List organization users with pagination and optional filters.","operationId":"list_users_v1_organizations_users_get","parameters":[{"name":"skip","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"default":50,"title":"Limit"}},{"name":"role","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/UserRole"},{"type":"null"}],"title":"Role"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/UserStatus"},{"type":"null"}],"title":"Status"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response List Users V1 Organizations Users Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/users/{user_email}":{"get":{"tags":["Organization Users"],"summary":"Get User","description":"Return a user by email address.","operationId":"get_user_v1_organizations_users__user_email__get","parameters":[{"name":"user_email","in":"path","required":true,"schema":{"type":"string","title":"User Email"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get User V1 Organizations Users  User Email  Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]},"patch":{"tags":["Organization Users"],"summary":"Update User","description":"Apply partial updates to an existing user.","operationId":"update_user_v1_organizations_users__user_email__patch","parameters":[{"name":"user_email","in":"path","required":true,"schema":{"type":"string","title":"User Email"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserUpdateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Update User V1 Organizations Users  User Email  Patch"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]},"delete":{"tags":["Organization Users"],"summary":"Delete User","description":"Delete a user and revoke their API keys.","operationId":"delete_user_v1_organizations_users__user_email__delete","parameters":[{"name":"user_email","in":"path","required":true,"schema":{"type":"string","title":"User Email"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenericSuccessResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/users/{user_email}/api-keys":{"post":{"tags":["Organization API Keys"],"summary":"Create Api Key","description":"Create a new API key for a user.","operationId":"create_api_key_v1_organizations_users__user_email__api_keys_post","parameters":[{"name":"user_email","in":"path","required":true,"schema":{"type":"string","title":"User Email"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/APIKeyCreateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/APIKeyCreateResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]},"get":{"tags":["Organization API Keys"],"summary":"List Api Keys","description":"List API keys for a user.","operationId":"list_api_keys_v1_organizations_users__user_email__api_keys_get","parameters":[{"name":"user_email","in":"path","required":true,"schema":{"type":"string","title":"User Email"}},{"name":"include_revoked","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Revoked"}},{"name":"include_session_keys","in":"query","required":false,"schema":{"type":"boolean","description":"Also list the short-lived Studio session keys minted at each Studio login. Each can be revoked by its key_id with DELETE.","default":false,"title":"Include Session Keys"},"description":"Also list the short-lived Studio session keys minted at each Studio login. Each can be revoked by its key_id with DELETE."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response List Api Keys V1 Organizations Users  User Email  Api Keys Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/users/{user_email}/api-keys/{key_name}":{"patch":{"tags":["Organization API Keys"],"summary":"Update Api Key","description":"Update an API key's metadata or permissions.\n\n🔒 The \"admin-key\" is protected and cannot be modified.","operationId":"update_api_key_v1_organizations_users__user_email__api_keys__key_name__patch","parameters":[{"name":"user_email","in":"path","required":true,"schema":{"type":"string","title":"User Email"}},{"name":"key_name","in":"path","required":true,"schema":{"type":"string","title":"Key Name"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/APIKeyUpdateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/APIKeyModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]},"delete":{"tags":["Organization API Keys"],"summary":"Delete Api Key","description":"Revoke an API key.\n\n🔒 The \"admin-key\" is protected and cannot be deleted.\n\nStudio session keys can be revoked here by name or key_id; list them with\ninclude_session_keys=true.\n\nRefuses when a live published app still embeds this key, naming the app.\nA 2026-06-03 revocation killed 2 published apps for seven weeks\nbecause nothing in this path looked for references and the call reported\nsuccess.","operationId":"delete_api_key_v1_organizations_users__user_email__api_keys__key_name__delete","parameters":[{"name":"user_email","in":"path","required":true,"schema":{"type":"string","title":"User Email"}},{"name":"key_name","in":"path","required":true,"schema":{"type":"string","title":"Key Name"}},{"name":"force","in":"query","required":false,"schema":{"type":"boolean","description":"Revoke even when a live published app still embeds this key. Without it, the call is refused and names the apps that would break. Use force for a COMPROMISED key, where breaking them is the point.","default":false,"title":"Force"},"description":"Revoke even when a live published app still embeds this key. Without it, the call is refused and names the apps that would break. Use force for a COMPROMISED key, where breaking them is the point."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenericSuccessResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/users/{user_email}/api-keys/{key_name}/rotate":{"post":{"tags":["Organization API Keys"],"summary":"Rotate Api Key","description":"Rotate an API key and return the new secret.\n\n🔒 The \"admin-key\" is protected and cannot be rotated.","operationId":"rotate_api_key_v1_organizations_users__user_email__api_keys__key_name__rotate_post","parameters":[{"name":"user_email","in":"path","required":true,"schema":{"type":"string","title":"User Email"}},{"name":"key_name","in":"path","required":true,"schema":{"type":"string","title":"Key Name"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/APIKeyCreateResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/usage":{"get":{"tags":["Organization Usage"],"summary":"Get Org Usage","description":"Return aggregated usage for the organization.","operationId":"get_org_usage_v1_organizations_usage_get","parameters":[{"name":"start","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"ISO8601 start timestamp","title":"Start"},"description":"ISO8601 start timestamp"},{"name":"end","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"ISO8601 end timestamp","title":"End"},"description":"ISO8601 end timestamp"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Org Usage V1 Organizations Usage Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/api-keys/{key_id}/usage":{"get":{"tags":["Organization Usage"],"summary":"Get Api Key Usage","description":"Return usage metrics for a specific API key.","operationId":"get_api_key_usage_v1_organizations_api_keys__key_id__usage_get","parameters":[{"name":"key_id","in":"path","required":true,"schema":{"type":"string","title":"Key Id"}},{"name":"start","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"ISO8601 start timestamp","title":"Start"},"description":"ISO8601 start timestamp"},{"name":"end","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"ISO8601 end timestamp","title":"End"},"description":"ISO8601 end timestamp"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Api Key Usage V1 Organizations Api Keys  Key Id  Usage Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/api-keys/{key_id}/usage/endpoints":{"get":{"tags":["Organization Usage"],"summary":"Get Api Key Endpoint Breakdown","description":"Return endpoint-level usage metrics for a specific API key.","operationId":"get_api_key_endpoint_breakdown_v1_organizations_api_keys__key_id__usage_endpoints_get","parameters":[{"name":"key_id","in":"path","required":true,"schema":{"type":"string","title":"Key Id"}},{"name":"start","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"ISO8601 start timestamp","title":"Start"},"description":"ISO8601 start timestamp"},{"name":"end","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"ISO8601 end timestamp","title":"End"},"description":"ISO8601 end timestamp"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","additionalProperties":true},"title":"Response Get Api Key Endpoint Breakdown V1 Organizations Api Keys  Key Id  Usage Endpoints Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/audit/logs":{"get":{"tags":["Organization Audit"],"summary":"List Audit Logs","description":"List organization audit logs with filtering and pagination.\n\nReturns audit events for the organization, sorted by timestamp descending.\nRequires ADMIN permission.","operationId":"list_audit_logs_v1_organizations_audit_logs_get","parameters":[{"name":"resource_type","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/ResourceType-Input"},{"type":"null"}],"description":"Filter by resource type","title":"Resource Type"},"description":"Filter by resource type"},{"name":"resource_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by resource ID","title":"Resource Id"},"description":"Filter by resource ID"},{"name":"actor_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by actor ID","title":"Actor Id"},"description":"Filter by actor ID"},{"name":"action","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/AuditAction"},{"type":"null"}],"description":"Filter by action","title":"Action"},"description":"Filter by action"},{"name":"start","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"ISO8601 start timestamp","title":"Start"},"description":"ISO8601 start timestamp"},{"name":"end","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"ISO8601 end timestamp","title":"End"},"description":"ISO8601 end timestamp"},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","minimum":0,"description":"Number of results to skip","default":0,"title":"Skip"},"description":"Number of results to skip"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"description":"Number of results to return","default":50,"title":"Limit"},"description":"Number of results to return"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuditEventListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/audit/logs/export":{"get":{"tags":["Organization Audit"],"summary":"Export Audit Logs","description":"Export a time-bounded, filterable audit evidence bundle.\n\nStreams newline-delimited JSON (NDJSON): one audit event per line with\nresolved actor identity (name/email/key name), newest first. If the cap\ntruncates the export, the FINAL line is a marker object\n`{\"__truncated__\": true, \"exported\": N, \"total\": T}` — a cut bundle\nalways says so rather than presenting as complete. Requires ADMIN.","operationId":"export_audit_logs_v1_organizations_audit_logs_export_get","parameters":[{"name":"resource_type","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/ResourceType-Input"},{"type":"null"}],"description":"Filter by resource type","title":"Resource Type"},"description":"Filter by resource type"},{"name":"resource_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by resource ID","title":"Resource Id"},"description":"Filter by resource ID"},{"name":"actor_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by actor ID","title":"Actor Id"},"description":"Filter by actor ID"},{"name":"action","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/AuditAction"},{"type":"null"}],"description":"Filter by action","title":"Action"},"description":"Filter by action"},{"name":"start","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"ISO8601 start timestamp","title":"Start"},"description":"ISO8601 start timestamp"},{"name":"end","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"ISO8601 end timestamp","title":"End"},"description":"ISO8601 end timestamp"},{"name":"max_events","in":"query","required":false,"schema":{"type":"integer","maximum":200000,"minimum":1,"description":"Hard cap on exported events","default":50000,"title":"Max Events"},"description":"Hard cap on exported events"}],"responses":{"200":{"description":"Successful Response","content":{"application/x-ndjson":{"schema":{"type":"string"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/audit/logs/{audit_id}":{"get":{"tags":["Organization Audit"],"summary":"Get Audit Log","description":"Get a specific audit log entry by ID.\n\nRequires ADMIN permission.","operationId":"get_audit_log_v1_organizations_audit_logs__audit_id__get","parameters":[{"name":"audit_id","in":"path","required":true,"schema":{"type":"string","title":"Audit Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/AuditEventResponse"},{"type":"null"}],"title":"Response Get Audit Log V1 Organizations Audit Logs  Audit Id  Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/audit/settings":{"get":{"tags":["Organization Audit"],"summary":"Get Audit Settings","description":"Get current audit configuration for the organization.\n\nReturns the audit settings including whether read auditing is enabled.\nRequires ADMIN permission.","operationId":"get_audit_settings_v1_organizations_audit_settings_get","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuditSettings"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]},"patch":{"tags":["Organization Audit"],"summary":"Update Audit Settings","description":"Update audit configuration for the organization.\n\nUse this to enable or disable read auditing.\nRequires ADMIN permission.","operationId":"update_audit_settings_v1_organizations_audit_settings_patch","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuditSettingsUpdateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuditSettings"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/secrets":{"post":{"tags":["Organization Secrets"],"summary":"Create Secret","description":"Create a new secret in organization vault.\n\n**Security**:\n- Secret value is encrypted at rest using Fernet encryption\n- Encrypted using ENCRYPTION_KEY from environment\n- Decrypted value is NEVER returned in API responses\n- Only secret names are exposed in list operations\n\n**Use Cases**:\n- Store API keys for external services (Stripe, GitHub, etc.)\n- Store authentication tokens for api_call retriever stage\n- Store credentials for third-party integrations\n\n**Important**:\n- Secret names must be unique within organization\n- Use update endpoint to modify existing secrets\n- Delete and recreate if you forget the value","operationId":"create_secret_v1_organizations_secrets_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateSecretRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SecretResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]},"get":{"tags":["Organization Secrets"],"summary":"List Secrets","description":"List all secret names in organization vault.\n\n**Security**:\n- Returns ONLY secret names, never values\n- Use for discovering which secrets are configured\n- Secret values can only be retrieved by internal services\n\n**Response**:\n- List of secret names (e.g., ['stripe_api_key', 'github_token'])\n- Total count of secrets","operationId":"list_secrets_v1_organizations_secrets_get","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SecretsListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/secrets/{secret_name}":{"put":{"tags":["Organization Secrets"],"summary":"Update Secret","description":"Update an existing secret in organization vault.\n\n**Security**:\n- Replaces existing encrypted value with new encrypted value\n- Old value is permanently overwritten\n- No history or audit trail of previous values\n\n**Use Cases**:\n- Rotate API keys periodically\n- Update expired tokens\n- Change credentials after security incident","operationId":"update_secret_v1_organizations_secrets__secret_name__put","parameters":[{"name":"secret_name","in":"path","required":true,"schema":{"type":"string","title":"Secret Name"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateSecretRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SecretResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]},"delete":{"tags":["Organization Secrets"],"summary":"Delete Secret","description":"Delete a secret from organization vault.\n\n**Warning**:\n- Deletion is permanent and immediate\n- Any api_call stages using this secret will fail\n- No confirmation prompt - use with caution\n\n**Use Cases**:\n- Remove unused credentials\n- Clean up after service decommissioning\n- Security incident response","operationId":"delete_secret_v1_organizations_secrets__secret_name__delete","parameters":[{"name":"secret_name","in":"path","required":true,"schema":{"type":"string","title":"Secret Name"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SecretResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/dsar/export":{"post":{"tags":["Data Subject Access Requests"],"summary":"Request Data Export","description":"Request a full data export for this organization.\n\nReturns a summary of all data categories that will be exported.\nThe export is processed asynchronously and delivered within 30 days\nas required by GDPR Article 15 and CCPA Section 1798.100.\n\nRequires ADMIN permission.","operationId":"request_data_export_v1_organizations_dsar_export_post","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DSARExportResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/dsar/delete":{"post":{"tags":["Data Subject Access Requests"],"summary":"Request Data Deletion","description":"Request deletion of all organization data.\n\nThis is a DSAR deletion request per GDPR Article 17 (Right to Erasure)\nand CCPA Section 1798.105. The request is logged and processed within\n30 days. Once executed, this action is IRREVERSIBLE.\n\nThe actual deletion is performed by the delete_organization_resources_flow\nafter verification. This endpoint creates the request record.\n\nRequires ADMIN permission.","operationId":"request_data_deletion_v1_organizations_dsar_delete_post","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DSARDeleteResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/dsar/status":{"get":{"tags":["Data Subject Access Requests"],"summary":"List Dsar Requests","description":"List all DSAR requests for this organization.\n\nReturns the status of all pending and completed data subject\naccess requests (exports and deletions).\n\nRequires ADMIN permission.","operationId":"list_dsar_requests_v1_organizations_dsar_status_get","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/DSARStatusResponse"},"title":"Response List Dsar Requests V1 Organizations Dsar Status Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/estimate":{"post":{"tags":["Organization Billing"],"summary":"Estimate Cost","description":"Quote the v2 cost of planned ingestion before submitting it.\n\nSend `items` to price content per modality, or `manifest` with an\n`inventory` and `queries_per_month` to price a namespace: what indexing\nthose files is charged, the monthly price and the unit prices. Wrong unit\nfields and inapplicable features return teaching errors.","operationId":"estimate_cost_v1_organizations_billing_estimate_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EstimateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EstimateResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/generate-invoice":{"post":{"tags":["Organization Billing"],"summary":"Generate Invoice Now","description":"Manually trigger invoice generation for this organization.\n\nUseful for testing the billing flow or generating retroactive invoices.\nRequires ADMIN permission.\n\nLine items follow the v2 (modality+features, D8) composition: flat monthly\nfee + per-modality feature usage in natural units and dollars + the plan's\nincluded-usage pool as a deduction; only usage beyond the pool is due. The\ntotal always reconciles to the month's ledger charges (see `pricing_v2`).\n\n**Example:**\n```python\n# Dry run\nresponse = await client.post(\n    \"/v1/organizations/billing/generate-invoice\",\n    json={\"dry_run\": true}\n)\n\n# Actually generate\nresponse = await client.post(\n    \"/v1/organizations/billing/generate-invoice\",\n    json={\"billing_month\": \"2026-01\"}\n)\n```","operationId":"generate_invoice_now_v1_organizations_billing_generate_invoice_post","parameters":[],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Body_generate_invoice_now_v1_organizations_billing_generate_invoice_post"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Generate Invoice Now V1 Organizations Billing Generate Invoice Post"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/balance":{"get":{"tags":["Organization Billing"],"summary":"Get Credit Balance","description":"Get current credit balance and tier information.\n\nReturns the organization's credit balance, current tier, and usage statistics.\nUseful for displaying billing status in dashboards.\n\n**Requirements:**\n- Read permission\n\n**Example:**\n```python\nresponse = await client.get(\"/v1/organizations/billing/balance\")\nprint(f\"Balance: {response['credit_balance']} credits\")\nprint(f\"Tier: {response['account_tier']}\")\n```","operationId":"get_credit_balance_v1_organizations_billing_balance_get","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreditBalanceResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/setup-payment-method":{"post":{"tags":["Organization Billing"],"summary":"Setup Payment Method","description":"Initialize payment method setup flow.\n\nCreates a Stripe SetupIntent for collecting payment method without charging.\nThe client_secret should be used with Stripe Elements on the frontend.\n\n**Flow:**\n1. Frontend calls this endpoint\n2. Backend creates Stripe Customer (if needed) and SetupIntent\n3. Frontend uses client_secret with Stripe Elements\n4. User enters card details\n5. Frontend calls confirm-payment-method endpoint\n\n**Requirements:**\n- Admin permission (only org admins can set up payment methods)\n\n**Example:**\n```python\nresponse = await client.post(\"/v1/organizations/billing/setup-payment-method\")\nclient_secret = response[\"client_secret\"]\n# Use client_secret with Stripe Elements\n```","operationId":"setup_payment_method_v1_organizations_billing_setup_payment_method_post","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetupPaymentMethodResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/confirm-payment-method":{"post":{"tags":["Organization Billing"],"summary":"Confirm Payment Method","description":"Confirm payment method after frontend collects it.\n\nAfter Stripe Elements confirms the SetupIntent, call this endpoint\nto attach the payment method to the customer and enable auto-billing.\n\n**Requirements:**\n- Admin permission\n- Must have called setup-payment-method first\n\n**Example:**\n```python\n# After Stripe Elements confirms setup\nresponse = await client.post(\n    \"/v1/organizations/billing/confirm-payment-method\",\n    json={\"payment_method_id\": \"pm_1ABC2DEF3GHI\"}\n)\n```","operationId":"confirm_payment_method_v1_organizations_billing_confirm_payment_method_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfirmPaymentMethodRequest","description":"Payment method confirmation"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfirmPaymentMethodResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/payment-method":{"get":{"tags":["Organization Billing"],"summary":"Get Payment Method","description":"Get current payment method.\n\nReturns the saved payment method details (last 4 digits, brand)\nand auto-billing status.\n\n**Requirements:**\n- Read permission\n\n**Example:**\n```python\nresponse = await client.get(\"/v1/organizations/billing/payment-method\")\nif response[\"has_payment_method\"]:\n    print(f\"Card: {response['payment_method']['card_brand']} ****{response['payment_method']['card_last4']}\")\n```","operationId":"get_payment_method_v1_organizations_billing_payment_method_get","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetPaymentMethodResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/enable-auto-billing":{"post":{"tags":["Organization Billing"],"summary":"Enable Auto Billing","description":"Enable automatic monthly billing.\n\nRe-enables automatic billing if it was previously disabled.\nPayment method must already be saved.\n\n**Requirements:**\n- Admin permission\n- Must have payment method saved\n\n**Example:**\n```python\nresponse = await client.post(\"/v1/organizations/billing/enable-auto-billing\")\n```","operationId":"enable_auto_billing_v1_organizations_billing_enable_auto_billing_post","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AutoBillingToggleResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/disable-auto-billing":{"post":{"tags":["Organization Billing"],"summary":"Disable Auto Billing","description":"Disable automatic monthly billing.\n\nDisables automatic billing but keeps payment method saved.\nOrganization can re-enable later or pay invoices manually.\n\n**Requirements:**\n- Admin permission\n\n**Example:**\n```python\nresponse = await client.post(\"/v1/organizations/billing/disable-auto-billing\")\n```","operationId":"disable_auto_billing_v1_organizations_billing_disable_auto_billing_post","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AutoBillingToggleResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/usage/current":{"get":{"tags":["Organization Billing"],"summary":"Get Current Usage","description":"Get current month usage.\n\nReturns credit consumption for the current billing period,\nestimated cost, and next invoice date.\n\n**Requirements:**\n- Read permission\n\n**Example:**\n```python\nresponse = await client.get(\"/v1/organizations/billing/usage/current\")\nprint(f\"Usage: {response['current_month_usage']} credits\")\nprint(f\"Estimated cost: ${response['estimated_cost_usd']}\")\n```","operationId":"get_current_usage_v1_organizations_billing_usage_current_get","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CurrentUsageResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/usage/breakdown":{"get":{"tags":["Organization Billing"],"summary":"Get Usage Breakdown","description":"Get detailed usage breakdown.\n\nReturns usage breakdown by operation type and extractor\nfor the specified billing period.\n\n**Query Parameters:**\n- `billing_month`: Month to query (YYYY-MM format, defaults to current)\n\n**Requirements:**\n- Read permission\n\n**Example:**\n```python\n# Current month\nresponse = await client.get(\"/v1/organizations/billing/usage/breakdown\")\n\n# Specific month\nresponse = await client.get(\n    \"/v1/organizations/billing/usage/breakdown\",\n    params={\"billing_month\": \"2025-11\"}\n)\n```","operationId":"get_usage_breakdown_v1_organizations_billing_usage_breakdown_get","parameters":[{"name":"billing_month","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Billing month in YYYY-MM format (defaults to current month)","examples":["2025-12"],"title":"Billing Month"},"description":"Billing month in YYYY-MM format (defaults to current month)"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UsageBreakdownResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/transactions":{"get":{"tags":["Organization Billing"],"summary":"List Transactions","description":"List individual credit-usage transactions (most recent first).\n\nThe per-operation **credit ledger**: every credit debit, what consumed it\n(operation/extractor/resource), and when — the transaction-level itemization\nbeyond the aggregated `/usage/breakdown` totals.\n\n**Query Parameters:**\n- `limit`: page size (1-200, default 50)\n- `offset`: records to skip\n- `billing_month`: optional YYYY-MM filter\n\n**Requirements:** Read permission.\n\n**Example:**\n```python\nresponse = await client.get(\n    \"/v1/organizations/billing/transactions\",\n    params={\"limit\": 50, \"billing_month\": \"2026-06\"},\n)\n```","operationId":"list_transactions_v1_organizations_billing_transactions_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"description":"Page size (max 200)","examples":[50],"default":50,"title":"Limit"},"description":"Page size (max 200)"},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"description":"Records to skip (pagination)","default":0,"title":"Offset"},"description":"Records to skip (pagination)"},{"name":"billing_month","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Optional YYYY-MM filter (defaults to all months)","examples":["2026-06"],"title":"Billing Month"},"description":"Optional YYYY-MM filter (defaults to all months)"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TransactionsListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/usage/vector-backend":{"get":{"tags":["Organization Billing"],"summary":"Get Vector Backend Usage","description":"Get vector backend usage breakdown.\n\nReturns usage dimensions (vectors stored, storage, queries, writes) and\ncost breakdown for the tenant's vector backend (MVS).\n\n**Requirements:**\n- Read permission","operationId":"get_vector_backend_usage_v1_organizations_billing_usage_vector_backend_get","parameters":[{"name":"billing_month","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Billing month in YYYY-MM format (defaults to current month)","examples":["2026-05"],"title":"Billing Month"},"description":"Billing month in YYYY-MM format (defaults to current month)"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VectorBackendUsageResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/invoices":{"get":{"tags":["Organization Billing"],"summary":"List Invoices","description":"List monthly invoices.\n\nReturns paginated list of monthly invoices with links to\nStripe-hosted invoice pages.\n\n**Query Parameters:**\n- `limit`: Number of invoices (1-100, default 10)\n\n**Requirements:**\n- Read permission\n\n**Example:**\n```python\nresponse = await client.get(\"/v1/organizations/billing/invoices?limit=10\")\nfor invoice in response[\"invoices\"]:\n    print(f\"{invoice['billing_month']}: ${invoice['amount_paid']/100}\")\n```","operationId":"list_invoices_v1_organizations_billing_invoices_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Number of invoices to return","default":10,"title":"Limit"},"description":"Number of invoices to return"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvoiceListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/spending-caps":{"get":{"tags":["Organization Billing"],"summary":"Get Spending Caps","description":"Get current spending cap configuration.\n\nReturns spending cap settings including budget limits, alert thresholds,\nand current spending status.\n\n**Requirements:**\n- Read permission\n\n**Example:**\n```python\nresponse = await client.get(\"/v1/organizations/billing/spending-caps\")\nprint(f\"Monthly budget: ${response['monthly_spending_budget_usd']}\")\nprint(f\"Hard cap enabled: {response['hard_cap_enabled']}\")\nprint(f\"Current spending: ${response['current_spending_usd']}\")\n```","operationId":"get_spending_caps_v1_organizations_billing_spending_caps_get","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SpendingCapsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]},"post":{"tags":["Organization Billing"],"summary":"Update Spending Caps","description":"Update spending cap configuration.\n\nConfigure spending limits and alert thresholds to control costs.\n\n**Features:**\n- **Soft Limit (Budget)**: Triggers alerts but doesn't block API access\n- **Hard Cap**: Blocks API access when reached. Setting a positive\n  `hard_spending_cap` arms enforcement automatically; pass\n  `hard_cap_enabled: false` in the same request to set the cap without\n  enforcing it. Clearing the cap (null/0) disarms enforcement.\n- **Alert Thresholds**: Customize when to receive spending notifications\n\n**Requirements:**\n- Admin permission\n- Only applies to organizations with auto-billing enabled\n\n**Example:**\n```python\n# Set $100 budget with alerts at 75% and 100%\nresponse = await client.post(\n    \"/v1/organizations/billing/spending-caps\",\n    json={\n        \"monthly_spending_budget\": 10000,  # $100 in cents\n        \"spending_alert_thresholds\": [75, 100],\n        \"spending_alerts_enabled\": True,\n    }\n)\n\n# Enable hard cap at $500\nresponse = await client.post(\n    \"/v1/organizations/billing/spending-caps\",\n    json={\n        \"hard_spending_cap\": 50000,  # $500 in cents\n        \"hard_cap_enabled\": True,\n    }\n)\n\n# Disable all spending limits\nresponse = await client.post(\n    \"/v1/organizations/billing/spending-caps\",\n    json={\n        \"monthly_spending_budget\": None,\n        \"hard_spending_cap\": None,\n        \"hard_cap_enabled\": False,\n    }\n)\n```","operationId":"update_spending_caps_v1_organizations_billing_spending_caps_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateSpendingCapsRequest","description":"Spending cap configuration"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SpendingCapsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/checkout":{"post":{"tags":["Organization Billing"],"summary":"Create Checkout","description":"Create a Stripe Checkout Session for a one-time credit purchase.\n\nAllows organization admins to purchase credit packages via Stripe Checkout.\nAfter successful payment, credits are automatically added to the organization.\n\n**Available Packages:**\n- `starter`: 10,000 credits — $10\n- `growth`: 50,000 credits — $40\n- `scale`: 200,000 credits — $120\n\n**Requirements:**\n- Admin permission\n\n**Example:**\n```python\nresponse = await client.post(\n    \"/v1/organizations/billing/checkout\",\n    json={\"package\": \"growth\"}\n)\n# Redirect user to response[\"checkout_url\"]\n```","operationId":"create_checkout_v1_organizations_billing_checkout_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCheckoutRequest","description":"Credit package checkout request"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCheckoutResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/subscribe":{"post":{"tags":["Organization Billing"],"summary":"Subscribe To Plan","description":"Subscribe to a paid plan via Stripe Checkout.\n\nCreates a Stripe Checkout Session in subscription mode. After payment,\nthe organization's account_type is updated via webhook.\n\nIf the organization already has an active subscription, the plan is\nchanged inline (upgrade/downgrade with proration) instead of creating\na new checkout session.\n\n**Available Plans** (tier minimum is a billing floor; usage above it\nbills automatically):\n- `managed_build`: Managed Mixpeek Build — $25/mo min, 100K objects/mo\n- `managed_scale`: Managed Mixpeek Scale — $250/mo min, 1M objects/mo\n- `mvs_build`: MVS Standalone Build — $25/mo min, 1M vectors\n- `mvs_scale`: MVS Standalone Scale — $250/mo min, 25M vectors\n\n**Discounts:** each non-empty `onboarding_answers` field takes $5 off the\nfirst invoice (max $10). An explicit `promo_code` is validated and\npre-applied; when both are sent the promo takes checkout's single\ndiscount slot and the onboarding credit lands on the customer balance.\nWithout either, Stripe's own promo-code field is enabled at checkout.","operationId":"subscribe_to_plan_v1_organizations_billing_subscribe_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscribeRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscribeResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/portal":{"post":{"tags":["Organization Billing"],"summary":"Open Billing Portal","description":"Open the Stripe customer billing portal.\n\nThis is the correct destination for a \"Manage subscription\" action: the\nportal lets an existing customer update their card, view/download invoices,\nand change or cancel their plan. It is NOT the same as POST /subscribe —\nre-running /subscribe for an existing subscriber starts a brand-new checkout\ninstead of managing the current one.\n\nRequires an existing Stripe customer. Orgs that have never started billing\nhave nothing to manage, so they get an actionable 400 pointing at /subscribe.","operationId":"open_billing_portal_v1_organizations_billing_portal_post","parameters":[],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BillingPortalRequest","default":{"return_url":"https://studio.mixpeek.com/billing"}}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BillingPortalResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/subscription":{"get":{"tags":["Organization Billing"],"summary":"Get Subscription Status","description":"Get current subscription status.","operationId":"get_subscription_status_v1_organizations_billing_subscription_get","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionStatusResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/subscription/cancel":{"post":{"tags":["Organization Billing"],"summary":"Cancel Subscription","description":"Cancel the current subscription.\n\nDefault: cancel at end of billing period (the subscription remains\nactive until then, after which the organization downgrades). With\n``immediate=true``: cancel NOW — the org-deletion cascade\nand teardown callers need a cancel that actually ends billing today\ninstead of leaving a live sub on the card.","operationId":"cancel_subscription_v1_organizations_billing_subscription_cancel_post","parameters":[],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/CancelSubscriptionRequest"},{"type":"null"}],"title":"Payload"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CancelSubscriptionResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/apply-promo":{"post":{"tags":["Organization Billing"],"summary":"Apply Promo","description":"Apply a promo code to the organization's active subscription.\n\nEvery failure carries a reason (invalid / expired / exhausted / product\nmismatch / no subscription) — never a silent no-op.","operationId":"apply_promo_v1_organizations_billing_apply_promo_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApplyPromoRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApplyPromoResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/billing/redeem-promo":{"post":{"tags":["Organization Billing"],"summary":"Redeem Promo","description":"Redeem a promo code on a FRESH org — no Checkout, no card.\n\nA promo code lets you continue without entering a card. This creates the\nsubscription server-side with the coupon attached (the self-serve twin of the manual comp flow), stamps\n``metadata.organization_id`` so the subscription webhook grants tier +\nPOC cap, and sets the org's plan fields inline so the user continues\nIMMEDIATELY (no webhook-latency paywall).\n\nOnly codes whose window bills $0 (percent_off=100 — every POC code by\nvalidated shape) can start service card-less: a partial discount with no\npayment method would generate a FAILING first invoice (service cut +\ndunning — strictly worse than the card form; the uncollectable shape\nPOC-PROMO-CAP-2026-07-17 exists to prevent). Partial codes get a clear\nredirect to checkout, where the discount still applies. Card-ask happens\nat coupon end (finances' T-7d lifecycle).\n\nEvery failure carries a reason — never a silent no-op.","operationId":"redeem_promo_v1_organizations_billing_redeem_promo_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RedeemPromoRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RedeemPromoResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["admin"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/infrastructure/summary":{"get":{"tags":["Organization Infrastructure"],"summary":"Get Infrastructure","description":"Get infrastructure summary for an enterprise single-tenant deployment.\n\nReturns compute profiles for each extractor, cloud cost breakdown\nwith transparent margin, and the billing period summary for the\nrequested (default: current) month. Enterprise-only endpoint.","operationId":"get_infrastructure_v1_organizations_infrastructure_summary_get","parameters":[{"name":"billing_month","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Billing month to inspect (YYYY-MM). Defaults to the current month. Past months return the same category + line-item granularity as the current month.","examples":["2026-06"],"title":"Billing Month"},"description":"Billing month to inspect (YYYY-MM). Defaults to the current month. Past months return the same category + line-item granularity as the current month."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InfrastructureSummaryResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/targets":{"get":{"tags":["Organization Targets"],"summary":"Get Organization Targets","description":"Get this organization's resource + SLO targets.\n\nTenancy (dedicated vs shared) is resolved SERVER-SIDE from the org —\nnever from a client-supplied header. ``targets_writable``\nis the capability flag a client should read rather than infer from\n``plane``: shared-plane orgs are read-only by platform policy, and\ndedicated orgs hold write access to their own spec.","operationId":"get_organization_targets_v1_organizations_targets_get","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TargetSpec"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/billing/pricing":{"get":{"tags":["Pricing"],"summary":"Get Pricing Configuration","description":"Public pricing rate card. Price = how much content of each file type × (base rate + the search-by features enabled). Returns per-modality rates, tier usage pools, and plan definitions. No authentication required.","operationId":"get_pricing_config_v1_billing_pricing_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PricingConfigResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/buckets/{bucket_id}/source-adapter/status":{"get":{"tags":["Source Adapter"],"summary":"Get Adapter Status","description":"Get source adapter status and statistics.","operationId":"get_adapter_status_v1_buckets__bucket_id__source_adapter_status_get","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Adapter Status V1 Buckets  Bucket Id  Source Adapter Status Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/buckets/{bucket_id}/source-adapter/refresh":{"post":{"tags":["Source Adapter"],"summary":"Refresh Source Adapter","description":"Trigger a pull-based source refresh (collection bucket).\n\nThis is the explicit trigger that turns a source's contents into first-class\nobjects in this bucket: a ``collection`` source demotes the source collection's\ndocuments, a ``bucket`` source fans one or more source buckets' objects in. Only\nvalid for an enabled ``adapter_type`` in {``collection``, ``bucket``}; webhook\nadapters do not use it.","operationId":"refresh_source_adapter_v1_buckets__bucket_id__source_adapter_refresh_post","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Refresh Source Adapter V1 Buckets  Bucket Id  Source Adapter Refresh Post"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/public/notifications/unsubscribe":{"get":{"tags":["Public Notifications API"],"summary":"Unsubscribe From Nudges","description":"Unsubscribe from nudge emails using a signed token.\n\nThis is a public endpoint (no auth required) for one-click unsubscribe\nfrom email links. The token is cryptographically signed and contains\nthe organization ID and nudge type.","operationId":"unsubscribe_from_nudges_v1_public_notifications_unsubscribe_get","parameters":[{"name":"token","in":"query","required":true,"schema":{"type":"string","description":"Signed unsubscribe token from email","title":"Token"},"description":"Signed unsubscribe token from email"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/templates/namespaces":{"get":{"tags":["Templates","Namespace Templates"],"summary":"List Namespace Templates","description":"List namespace templates (system + organization + user).","operationId":"list_namespace_templates_v1_templates_namespaces_get","parameters":[{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by category","title":"Category"},"description":"Filter by category"},{"name":"scope","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/TemplateScope"},{"type":"null"}],"description":"Filter by scope (system, organization, or user)","title":"Scope"},"description":"Filter by scope (system, organization, or user)"},{"name":"is_active","in":"query","required":false,"schema":{"type":"boolean","description":"Show only active templates","default":true,"title":"Is Active"},"description":"Show only active templates"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/BaseTemplateModel"},"title":"Response List Namespace Templates V1 Templates Namespaces Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/templates/namespaces/{template_id}":{"get":{"tags":["Templates","Namespace Templates"],"summary":"Get Namespace Template","description":"Get namespace template details.","operationId":"get_namespace_template_v1_templates_namespaces__template_id__get","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","description":"Template ID","title":"Template Id"},"description":"Template ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BaseTemplateModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/templates/namespaces/from-namespace/{namespace_id}":{"post":{"tags":["Templates","Namespace Templates"],"summary":"Create Namespace Template","description":"Create template from existing namespace.\n\nSupports three template scopes:\n- **organization**: Available to all users in your organization (default)\n- **user**: Available only to you\n- **system**: Available to all organizations (requires Mixpeek admin email)","operationId":"create_namespace_template_v1_templates_namespaces_from_namespace__namespace_id__post","parameters":[{"name":"namespace_id","in":"path","required":true,"schema":{"type":"string","description":"Namespace ID","title":"Namespace Id"},"description":"Namespace ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTemplateFromResourceRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTemplateFromResourceResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/templates/retrievers":{"post":{"tags":["Templates","Retriever Templates"],"summary":"List Retriever Templates","description":"List retriever templates (system + organization + user).\n\nSupports filtering, sorting, and search like other list operations.\n\n**Request Body (optional):**\n- `filters`: Attribute-based filters `{\"AND\": [{\"field\": \"category\", \"operator\": \"eq\", \"value\": \"semantic_search\"}]}`\n- `sort`: Sort options `{\"field\": \"name\", \"direction\": \"asc\"}`\n- `search`: Wildcard search across template_id, name, description, tags\n- `scope`: Filter by scope (system, organization, user)\n- `category`: Filter by category\n- `is_active`: Show only active templates (default: true)\n- `tags`: Filter by tags (templates must have ALL specified tags)","operationId":"list_retriever_templates_v1_templates_retrievers_post","parameters":[],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTemplatesRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTemplatesResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/templates/retrievers/{template_id}":{"get":{"tags":["Templates","Retriever Templates"],"summary":"Get Retriever Template","description":"Get retriever template details.","operationId":"get_retriever_template_v1_templates_retrievers__template_id__get","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","description":"Template ID","title":"Template Id"},"description":"Template ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BaseTemplateModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/templates/retrievers/from-retriever/{retriever_id}":{"post":{"tags":["Templates","Retriever Templates"],"summary":"Create Retriever Template","description":"Create template from existing retriever.\n\nSupports three template scopes:\n- **organization**: Available to all users in your organization (default)\n- **user**: Available only to you\n- **system**: Available to all organizations (requires Mixpeek admin email)","operationId":"create_retriever_template_v1_templates_retrievers_from_retriever__retriever_id__post","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","description":"Retriever ID","title":"Retriever Id"},"description":"Retriever ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTemplateFromResourceRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTemplateFromResourceResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/templates/retrievers/{template_id}/instantiate":{"post":{"tags":["Templates","Retriever Templates"],"summary":"Instantiate Retriever Template","description":"Instantiate retriever template.","operationId":"instantiate_retriever_template_v1_templates_retrievers__template_id__instantiate_post","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","description":"Template ID","title":"Template Id"},"description":"Template ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InstantiateRetrieverTemplateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InstantiatedRetrieverTemplateResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/templates/clusters":{"post":{"tags":["Templates","Cluster Templates"],"summary":"List Cluster Templates","description":"List cluster templates (system + organization + user).\n\nSupports filtering, sorting, and search like other list operations.","operationId":"list_cluster_templates_v1_templates_clusters_post","parameters":[],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTemplatesRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTemplatesResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/templates/clusters/{template_id}":{"get":{"tags":["Templates","Cluster Templates"],"summary":"Get Cluster Template","description":"Get cluster template details.","operationId":"get_cluster_template_v1_templates_clusters__template_id__get","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","description":"Template ID","title":"Template Id"},"description":"Template ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BaseTemplateModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/templates/clusters/from-cluster/{cluster_id}":{"post":{"tags":["Templates","Cluster Templates"],"summary":"Create Cluster Template","description":"Create template from existing cluster.","operationId":"create_cluster_template_v1_templates_clusters_from_cluster__cluster_id__post","parameters":[{"name":"cluster_id","in":"path","required":true,"schema":{"type":"string","description":"Cluster ID","title":"Cluster Id"},"description":"Cluster ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTemplateFromResourceRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTemplateFromResourceResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/templates/clusters/{template_id}/instantiate":{"post":{"tags":["Templates","Cluster Templates"],"summary":"Instantiate Cluster Template","description":"Instantiate cluster template.","operationId":"instantiate_cluster_template_v1_templates_clusters__template_id__instantiate_post","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","description":"Template ID","title":"Template Id"},"description":"Template ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InstantiateClusterTemplateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InstantiatedClusterTemplateResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/templates/collections":{"post":{"tags":["Templates","Collection Templates"],"summary":"List Collection Templates","description":"List collection templates (system + organization + user).\n\nSupports filtering, sorting, and search like other list operations.","operationId":"list_collection_templates_v1_templates_collections_post","parameters":[],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTemplatesRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTemplatesResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/templates/collections/{template_id}":{"get":{"tags":["Templates","Collection Templates"],"summary":"Get Collection Template","description":"Get collection template details.","operationId":"get_collection_template_v1_templates_collections__template_id__get","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","description":"Template ID","title":"Template Id"},"description":"Template ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BaseTemplateModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/templates/collections/from-collection/{collection_id}":{"post":{"tags":["Templates","Collection Templates"],"summary":"Create Collection Template","description":"Create template from existing collection.\n\nSupports three template scopes:\n- **organization**: Available to all users in your organization (default)\n- **user**: Available only to you\n- **system**: Available to all organizations (requires Mixpeek admin email)","operationId":"create_collection_template_v1_templates_collections_from_collection__collection_id__post","parameters":[{"name":"collection_id","in":"path","required":true,"schema":{"type":"string","description":"Collection ID","title":"Collection Id"},"description":"Collection ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTemplateFromResourceRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTemplateFromResourceResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/templates/collections/{template_id}/instantiate":{"post":{"tags":["Templates","Collection Templates"],"summary":"Instantiate Collection Template","description":"Instantiate collection template.","operationId":"instantiate_collection_template_v1_templates_collections__template_id__instantiate_post","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","description":"Template ID","title":"Template Id"},"description":"Template ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InstantiateCollectionTemplateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InstantiatedCollectionTemplateResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/templates/buckets":{"post":{"tags":["Templates","Bucket Templates"],"summary":"List Bucket Templates","description":"List bucket templates (system + organization + user).\n\nSupports filtering, sorting, and search like other list operations.","operationId":"list_bucket_templates_v1_templates_buckets_post","parameters":[],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTemplatesRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTemplatesResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/templates/buckets/{template_id}":{"get":{"tags":["Templates","Bucket Templates"],"summary":"Get Bucket Template","description":"Get bucket template details.","operationId":"get_bucket_template_v1_templates_buckets__template_id__get","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","description":"Template ID","title":"Template Id"},"description":"Template ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BaseTemplateModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/templates/buckets/from-bucket/{bucket_id}":{"post":{"tags":["Templates","Bucket Templates"],"summary":"Create Bucket Template","description":"Create template from existing bucket.\n\nSupports three template scopes:\n- **organization**: Available to all users in your organization (default)\n- **user**: Available only to you\n- **system**: Available to all organizations (requires Mixpeek admin email)","operationId":"create_bucket_template_v1_templates_buckets_from_bucket__bucket_id__post","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","description":"Bucket ID","title":"Bucket Id"},"description":"Bucket ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTemplateFromResourceRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTemplateFromResourceResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/templates/buckets/{template_id}/instantiate":{"post":{"tags":["Templates","Bucket Templates"],"summary":"Instantiate Bucket Template","description":"Instantiate bucket template.","operationId":"instantiate_bucket_template_v1_templates_buckets__template_id__instantiate_post","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","description":"Template ID","title":"Template Id"},"description":"Template ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InstantiateBucketTemplateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InstantiatedBucketTemplateResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/templates/taxonomies":{"post":{"tags":["Templates","Taxonomy Templates"],"summary":"List Taxonomy Templates","description":"List taxonomy templates (system + organization + user).\n\nSupports filtering, sorting, and search like other list operations.","operationId":"list_taxonomy_templates_v1_templates_taxonomies_post","parameters":[],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTemplatesRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTemplatesResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/templates/taxonomies/{template_id}":{"get":{"tags":["Templates","Taxonomy Templates"],"summary":"Get Taxonomy Template","description":"Get taxonomy template details.","operationId":"get_taxonomy_template_v1_templates_taxonomies__template_id__get","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","description":"Template ID","title":"Template Id"},"description":"Template ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BaseTemplateModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/templates/taxonomies/from-taxonomy/{taxonomy_id}":{"post":{"tags":["Templates","Taxonomy Templates"],"summary":"Create Taxonomy Template","description":"Create template from existing taxonomy.\n\nSupports three template scopes:\n- **organization**: Available to all users in your organization (default)\n- **user**: Available only to you\n- **system**: Available to all organizations (requires Mixpeek admin email)","operationId":"create_taxonomy_template_v1_templates_taxonomies_from_taxonomy__taxonomy_id__post","parameters":[{"name":"taxonomy_id","in":"path","required":true,"schema":{"type":"string","description":"Taxonomy ID","title":"Taxonomy Id"},"description":"Taxonomy ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTemplateFromResourceRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTemplateFromResourceResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/templates/taxonomies/{template_id}/instantiate":{"post":{"tags":["Templates","Taxonomy Templates"],"summary":"Instantiate Taxonomy Template","description":"Instantiate taxonomy template.","operationId":"instantiate_taxonomy_template_v1_templates_taxonomies__template_id__instantiate_post","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","description":"Template ID","title":"Template Id"},"description":"Template ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InstantiateTaxonomyTemplateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InstantiatedTaxonomyTemplateResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/templates/scaffolds/default":{"post":{"tags":["Scaffold Templates"],"summary":"Get Or Create Default Namespace","description":"Get or create the default universal namespace.\n\nReturns the existing default namespace if one exists, or creates a new one\nusing the universal template. This is the primary onboarding entry point —\nStudio calls this on first upload to ensure a namespace exists without\nrequiring the user to choose a template.\n\nThe default namespace supports all file types (video, image, audio, PDF, text)\nwith pre-configured extractors and a universal retriever.\n\nIf the request carries an `X-Namespace` header that resolves to an existing\nwritable org namespace (e.g. one just created via the wizard), the scaffold\nis provisioned into THAT namespace instead of creating a \"default\" one.","operationId":"get_or_create_default_namespace_v1_templates_scaffolds_default_post","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InstantiatedScaffoldResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/templates/scaffolds/{template_id}/manifest":{"get":{"tags":["Scaffold Templates"],"summary":"Get Scaffold Template Manifest","description":"Render a scaffold template as a Mixpeek manifest.\n\nConverts the scaffold's configuration (namespace, bucket, collections,\nretriever, taxonomies, clusters) into declarative Infrastructure-as-Code\nYAML — the same format used by `POST /v1/manifest/apply` and\n`GET /v1/manifest/export`.\n\nReturns both the YAML string (`manifest_yaml`) and the parsed manifest\ndict (`manifest`).","operationId":"get_scaffold_template_manifest_v1_templates_scaffolds__template_id__manifest_get","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","description":"Scaffold template ID","title":"Template Id"},"description":"Scaffold template ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScaffoldManifestResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/templates/scaffolds/{template_id}/instantiate":{"post":{"tags":["Scaffold Templates"],"summary":"Instantiate Scaffold Template","description":"Create complete infrastructure from scaffold template.\n\nCreates all resources atomically:\n1. **Namespace** with configured feature extractors\n2. **Bucket** with schema for your data structure\n3. **Collection** linked to bucket with feature config\n4. **Retriever** with search pipeline stages\n\nAll resources are empty, ready for data upload.\n\n**Next Steps:**\n1. Upload data: `POST /v1/buckets/{bucket_id}/objects`\n2. Process batch: `POST /v1/collections/{collection_id}/batches`\n3. Search: `POST /v1/retrievers/{retriever_id}/retrieve`\n\n**Example Request:**\n```json\n{\n    \"namespace_name\": \"my_video_app\",\n    \"namespace_description\": \"Video search application\"\n}\n```","operationId":"instantiate_scaffold_template_v1_templates_scaffolds__template_id__instantiate_post","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","description":"Scaffold template ID","title":"Template Id"},"description":"Scaffold template ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InstantiateScaffoldRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InstantiatedScaffoldResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/quickstart/docs-search":{"post":{"tags":["Quickstart"],"summary":"Provision Docs Search","description":"One-call provisioning of a complete documentation search pipeline. Creates a namespace, bucket, web crawl collection, retriever with semantic + code search, publishes it, and generates a scoped API key. Returns everything needed to embed the search widget.","operationId":"provision_docs_search_v1_quickstart_docs_search_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocsSearchRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocsSearchResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/onboarding/infer-config":{"post":{"tags":["Onboarding"],"summary":"Infer onboarding configuration","description":"Given a free-text use-case description, uses an LLM to recommend the best scaffold template, extractors, retriever stages, and sample queries for the user's project.","operationId":"infer_config_v1_onboarding_infer_config_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InferConfigRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InferConfigResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/onboarding/suggested-config":{"get":{"tags":["Onboarding"],"summary":"Get the org's signup-time suggested namespace","description":"Returns the namespace configuration that was suggested from Mixpeek's company research at signup, if one was provisioned. Studio uses this to badge the suggested namespace.","operationId":"get_suggested_config_v1_onboarding_suggested_config_get","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SuggestedConfigResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/manifest/apply":{"post":{"tags":["Manifest"],"summary":"Apply Manifest","description":"Apply a YAML manifest to create resources.\n\nCreates all resources defined in the manifest file in dependency order.\n\n**Modes:**\n- `create_only` (default) — fails if any resource already exists.\n- `create_missing` — creates what is missing, leaves what exists alone, and resolves\n  manifest references against the resources ALREADY in the namespace. This is what makes\n  \"here is a namespace with buckets, add these collections over them\" work. Under\n  `create_only` a reference to an undeclared-but-existing bucket is a validation error,\n  because the manifest is treated as a closed world.\n\n**Plan first:** before creating anything, apply runs the same checks as\n`POST /v1/manifest/validate`. Any error refuses the whole manifest with\n`success: false`, every resource `skipped`, and each error naming the\nresource, the field and the fix. Nothing is created. A namespace budget above\nthe organization's bound is set to the bound and reported as a warning.\n\n**Features:**\n- Topological sorting ensures resources are created in correct dependency order\n- Secret references (`${{ secrets.NAME }}`) are resolved from organization secrets\n- Atomic operation: rolls back all created resources if any creation fails, and\n  an apply whose process is stopped part way is rolled back when the API starts again\n- Dry run returns the plan without making changes\n\n**Example:**\n```bash\ncurl -X POST /v1/manifest/apply \\\n  -H \"Authorization: Bearer $API_KEY\" \\\n  -H \"X-Namespace: ns_xxx\" \\\n  -F \"manifest_file=@mixpeek.yaml\"\n```\n\n**Example manifest:**\n```yaml\nversion: \"1.0\"\nmetadata:\n  name: \"my-environment\"\n\nnamespaces:\n  - name: video_search\n    feature_extractors:\n      - name: multimodal_extractor\n        version: v1\n\nbuckets:\n  - name: raw_videos\n    namespace: video_search\n    schema:\n      properties:\n        video: { type: video }\n```","operationId":"apply_manifest_v1_manifest_apply_post","parameters":[{"name":"dry_run","in":"query","required":false,"schema":{"type":"boolean","description":"Run the plan only: the same checks as POST /v1/manifest/validate, returned as errors and warnings, with nothing created. Each resource reads `would_create`, or `exists` when it is already there. Under mode create_only an existing resource refuses the plan, as it would refuse the apply","default":false,"title":"Dry Run"},"description":"Run the plan only: the same checks as POST /v1/manifest/validate, returned as errors and warnings, with nothing created. Each resource reads `would_create`, or `exists` when it is already there. Under mode create_only an existing resource refuses the plan, as it would refuse the apply"},{"name":"deadline_seconds","in":"query","required":false,"schema":{"anyOf":[{"type":"number","maximum":1800,"minimum":1},{"type":"null"}],"description":"Wait up to this many seconds after the resources are created for every Ray Serve app a declared collection needs to be RUNNING (the apps listed in `readiness`). Past the deadline the result has success false and an error naming the deadline and each app not RUNNING; the resources stay in place. Omit to return as soon as the resources exist.","title":"Deadline Seconds"},"description":"Wait up to this many seconds after the resources are created for every Ray Serve app a declared collection needs to be RUNNING (the apps listed in `readiness`). Past the deadline the result has success false and an error naming the deadline and each app not RUNNING; the resources stay in place. Omit to return as soon as the resources exist."},{"name":"wait_for_seed","in":"query","required":false,"schema":{"type":"boolean","description":"After the resources exist, wait until every `seed:` batch has finished (COMPLETED, COMPLETED_WITH_ERRORS, FAILED or CANCELED), within deadline_seconds or 900 seconds when that is omitted. Each batch's status and documents_written are returned in `seed_batches`; one that failed or did not finish in time is also named in `errors`. `success` still reports resource creation only","default":false,"title":"Wait For Seed"},"description":"After the resources exist, wait until every `seed:` batch has finished (COMPLETED, COMPLETED_WITH_ERRORS, FAILED or CANCELED), within deadline_seconds or 900 seconds when that is omitted. Each batch's status and documents_written are returned in `seed_batches`; one that failed or did not finish in time is also named in `errors`. `success` still reports resource creation only"},{"name":"run_acceptance","in":"query","required":false,"schema":{"type":"boolean","description":"Implies wait_for_seed and also waits for the Serve apps in `readiness`. Then runs the manifest's `acceptance:` steps in order and returns each in `acceptance` with passed, expected, observed and error. A step that could not run (deadline reached, seed batch failed, Serve apps not RUNNING) is passed false with the reason. The steps are normal executions in your organization and are billed like any query or inference call; `acceptance.max_cost_usd` is checked against the meter before each step and at the end. Re-apply with mode=create_missing to re-run the steps on a namespace that already exists without creating anything. A manifest with no `acceptance:` block is refused with 400","default":false,"title":"Run Acceptance"},"description":"Implies wait_for_seed and also waits for the Serve apps in `readiness`. Then runs the manifest's `acceptance:` steps in order and returns each in `acceptance` with passed, expected, observed and error. A step that could not run (deadline reached, seed batch failed, Serve apps not RUNNING) is passed false with the reason. The steps are normal executions in your organization and are billed like any query or inference call; `acceptance.max_cost_usd` is checked against the meter before each step and at the end. Re-apply with mode=create_missing to re-run the steps on a namespace that already exists without creating anything. A manifest with no `acceptance:` block is refused with 400"},{"name":"mode","in":"query","required":false,"schema":{"$ref":"#/components/schemas/ApplyMode","description":"create_only (default): fail if any resource already exists. create_missing: create what is missing and leave what exists alone, which is what lets a manifest be applied to an EXISTING namespace. create_missing does not UPDATE anything — a resource that exists but differs from the manifest is reported as `exists` and left untouched. upsert: create what is missing AND patch what exists but differs, so re-applying a manifest brings the running resources back to what it declares. Each resource is patched only through its own update surface, so a field that surface does not accept, or refuses the value of, is reported in `refused` with the resource and the field named, and the rest of the manifest still applies. Explicit on purpose: this is the only mode that CHANGES resources that already exist.","default":"create_only"},"description":"create_only (default): fail if any resource already exists. create_missing: create what is missing and leave what exists alone, which is what lets a manifest be applied to an EXISTING namespace. create_missing does not UPDATE anything — a resource that exists but differs from the manifest is reported as `exists` and left untouched. upsert: create what is missing AND patch what exists but differs, so re-applying a manifest brings the running resources back to what it declares. Each resource is patched only through its own update surface, so a field that surface does not accept, or refuses the value of, is reported in `refused` with the resource and the field named, and the rest of the manifest still applies. Explicit on purpose: this is the only mode that CHANGES resources that already exist."}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_apply_manifest_v1_manifest_apply_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApplyResult"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/manifest/validate":{"post":{"tags":["Manifest"],"summary":"Validate Manifest","description":"Validate a YAML manifest without applying.\n\nChecks:\n- YAML syntax validity\n- Schema validation against manifest models\n- Cross-resource reference validation\n- Dependency resolution (no circular dependencies)\n- Secret reference existence\n- Every extractor a namespace or collection names exists and is turned on\n- Retriever stages are registered and their parameters valid\n- Every feature URI a retriever or cluster names is written by a collection\n- Alert applications map every input their alert's retriever requires\n- Namespace budgets above the organization's bound (a warning: apply sets\n  the bound)\n\nThese are the checks apply runs before creating anything, so a manifest\nthat validates with no errors is one apply will not refuse on references.\n\nReturns detailed validation results including:\n- Resource counts by type\n- Missing secrets that need to be configured\n- Validation errors and warnings\n\n**Example:**\n```bash\ncurl -X POST /v1/manifest/validate \\\n  -H \"Authorization: Bearer $API_KEY\" \\\n  -F \"manifest_file=@mixpeek.yaml\"\n```","operationId":"validate_manifest_v1_manifest_validate_post","parameters":[],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_validate_manifest_v1_manifest_validate_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ValidateResult"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/manifest/lint":{"post":{"tags":["Manifest"],"summary":"Lint Manifest","description":"Lint a YAML manifest for best practices and potential issues.\n\nGoes beyond basic validation to provide actionable suggestions for\nimproving your manifest configuration. This endpoint is designed for\nAI agents and developers who want to optimize their Mixpeek setup.\n\n**Lint Rules:**\n- `UNUSED_EXTRACTOR`: Feature extractor defined but not used by any collection\n- `UNUSED_COLLECTION`: Collection not referenced by any retriever\n- `MISSING_INPUT_SCHEMA`: Retriever uses templates but has no input_schema\n- `SUBOPTIMAL_STAGE_ORDER`: Filter stages after expensive operations\n- `DUPLICATE_FEATURE_URI`: Same feature searched multiple times\n- `MISSING_DESCRIPTION`: Resources without descriptions\n- `NO_SEARCH_STAGE`: Retriever with no search stages\n- `EXTRACTOR_NOT_IN_NAMESPACE`: Collection uses extractor not in namespace\n- `MISSING_SECRET`: Secret reference not configured\n- `UNUSED_BUCKET`: Bucket that no collection reads\n- `TAXONOMY_INPUT_NOT_WRITTEN`: Taxonomy reads a feature its collection does not write\n- `RETRIEVER_FEATURE_NOT_IN_COLLECTIONS`: Retriever searches a feature none of its collections write\n\n**Severity Levels:**\n- `error`: Must be fixed before applying\n- `warning`: Best practice violation, should be fixed\n- `info`: Suggestion for improvement\n\n**Example:**\n```bash\ncurl -X POST /v1/manifest/lint \\\n  -H \"Authorization: Bearer $API_KEY\" \\\n  -F \"manifest_file=@mixpeek.yaml\"\n```\n\n**Response includes actionable suggestions:**\n```json\n{\n  \"valid\": true,\n  \"results\": [\n    {\n      \"code\": \"MISSING_INPUT_SCHEMA\",\n      \"severity\": \"warning\",\n      \"message\": \"Retriever 'product_search' uses template variables but has no input_schema defined\",\n      \"location\": \"retrievers[0]\",\n      \"suggestion\": \"Define input_schema to document and validate retriever inputs\",\n      \"fix_example\": \"input_schema:\\n  type: object\\n  properties:\\n    query:\\n      type: string\"\n    }\n  ],\n  \"summary\": {\"error\": 0, \"warning\": 1, \"info\": 0}\n}\n```","operationId":"lint_manifest_v1_manifest_lint_post","parameters":[{"name":"skip_rules","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"},"description":"Rule codes to skip (e.g., MISSING_DESCRIPTION)","default":[],"title":"Skip Rules"},"description":"Rule codes to skip (e.g., MISSING_DESCRIPTION)"}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_lint_manifest_v1_manifest_lint_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LintResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/manifest/export":{"get":{"tags":["Manifest"],"summary":"Export Manifest Get","description":"Export current resources to a YAML manifest.\n\nExports all resources (or a specific namespace) to a YAML file\nthat can be version-controlled and re-applied to another environment.\n\n**Features:**\n- Resource IDs are converted to human-readable names\n- Secret values are replaced with placeholder references (`${{ secrets.NAME }}`)\n- Output is formatted for readability and git-friendliness\n\n**Note:** You must configure actual secrets before applying the exported\nmanifest to a new environment.\n\n**Example:**\n```bash\n# Export all resources\ncurl /v1/manifest/export \\\n  -H \"Authorization: Bearer $API_KEY\" \\\n  -o mixpeek.yaml\n\n# Export specific namespace\ncurl \"/v1/manifest/export?namespace_id=ns_abc123\" \\\n  -H \"Authorization: Bearer $API_KEY\" \\\n  -o namespace.yaml\n```","operationId":"export_manifest_get_v1_manifest_export_get","parameters":[{"name":"namespace_id","in":"query","required":false,"schema":{"type":"string","description":"Export specific namespace (None = all)","title":"Namespace Id"},"description":"Export specific namespace (None = all)"},{"name":"format","in":"query","required":false,"schema":{"type":"string","description":"Output format (yaml)","default":"yaml","title":"Format"},"description":"Output format (yaml)"},{"name":"manifest_name","in":"query","required":false,"schema":{"type":"string","description":"Name for the manifest","default":"exported-manifest","title":"Manifest Name"},"description":"Name for the manifest"},{"name":"detail","in":"query","required":false,"schema":{"enum":["config","stats"],"type":"string","description":"'config' (default) exports the resources only. 'stats' also writes a read-only `status` section describing what is in the data: each collection's document count, field types, field descriptions and most common field values, and each cluster's groups with labels and sizes. Requires namespace_id. Apply ignores `status`.","default":"config","title":"Detail"},"description":"'config' (default) exports the resources only. 'stats' also writes a read-only `status` section describing what is in the data: each collection's document count, field types, field descriptions and most common field values, and each cluster's groups with labels and sizes. Requires namespace_id. Apply ignores `status`."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]},"post":{"tags":["Manifest"],"summary":"Export Manifest Post","description":"Export current resources to a YAML manifest (POST version for agent tools).\n\nSame as GET /export but accepts parameters in a JSON body instead of query\nparams. Used by agent tools and programmatic API clients. `detail: \"stats\"`\nadds the read-only `status` section (one namespace only), as on GET.\n\n**Example:**\n```bash\ncurl -X POST /v1/manifest/export \\\n  -H \"Authorization: Bearer $API_KEY\" \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\"namespace_ids\": [\"ns_abc123\"], \"manifest_name\": \"my-setup\"}'\n```","operationId":"export_manifest_post_v1_manifest_export_post","parameters":[{"name":"manifest_name","in":"query","required":false,"schema":{"type":"string","default":"exported-manifest","title":"Manifest Name"}},{"name":"detail","in":"query","required":false,"schema":{"enum":["config","stats"],"type":"string","default":"config","title":"Detail"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ExportRequest"},{"type":"array","items":{"type":"string"}},{"type":"null"}],"description":"An object with namespace_ids, manifest_name and detail. A bare list of namespace ids is also accepted, with manifest_name and detail taken from the query string.","title":"Export Request"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/manifest/diff":{"post":{"tags":["Manifest"],"summary":"Diff Manifest","description":"Compare a manifest file with current state.\n\nShows resources that would be:\n- **Created**: In manifest but not in system\n- **In system only**: In system but not in manifest\n- **Different**: In both but with configuration differences\n\nThis is useful for understanding what changes would occur\nbefore applying a manifest.\n\n**Example:**\n```bash\ncurl -X POST /v1/manifest/diff \\\n  -H \"Authorization: Bearer $API_KEY\" \\\n  -F \"manifest_file=@mixpeek.yaml\"\n```","operationId":"diff_manifest_v1_manifest_diff_post","parameters":[],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_diff_manifest_v1_manifest_diff_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DiffResult"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/manifest/generate":{"post":{"tags":["Manifest"],"summary":"Generate Manifest","description":"Generate a manifest from natural language description.\n\n    Uses AI to create a valid YAML manifest from a natural language description\n    of desired resources. The generated manifest can be reviewed and applied.\n\n    **Example:**\n    ```bash\n    curl -X POST /v1/manifest/generate \\\n      -H \"Authorization: Bearer $API_KEY\" \\\n      -H \"Content-Type: application/json\" \\\n      -d '{\n        \"description\": \"I need a bucket of images that feeds into a multimodal extractor and a retriever\",\n        \"manifest_name\": \"image-search-setup\"\n      }'\n    ```\n\n    The model is given the live extractor and retriever-stage catalogs. The\n    answer is checked with the same rules as POST /v1/manifest/validate, and\n    when that finds errors the model is shown them and asked to repair its\n    answer, up to 2 times.\n\n    **Response:**\n    ```json\n    {\n      \"manifest\": \"version: '1.0'\nmetadata:\n  name: image-search-setup\n...\",\n      \"format\": \"yaml\",\n      \"manifest_name\": \"image-search-setup\",\n      \"description\": \"I need a bucket of images...\",\n      \"validation\": {\"valid\": true, \"errors\": [], \"warnings\": []},\n      \"repair_rounds\": 1,\n      \"cost_estimate\": {\"per_1k_items_usd\": 1.5, \"per_month_usd\": 15.4, \"...\": \"...\"},\n      \"suggested\": {\"templates\": [\"...\"], \"models\": [\"siglip-base-patch16-224\"]}\n    }\n    ```\n\n    `cost_estimate` prices the returned manifest at list rates: per 1,000 items,\n    and per month at the volume in `monthly_volume`. `suggested` names the\n    namespace templates and catalog models the generator was offered as the\n    closest matches to the description.\n\n    `validation.valid` is false when the manifest still has errors after the\n    repair rounds; the errors are listed so you can fix them by hand.\n\n    Send the fields as a JSON body (above) or as query parameters. With an\n    `inventory` the answer also carries `quote`: what indexing those files is\n    charged, the monthly price and the unit prices, the same quote\n    POST /v1/organizations/billing/estimate returns for this manifest. A bucket\n    in `inventory` that the generated manifest does not declare is reported in\n    `quote.error`.\n\n    **Next Steps:**\n    1. Review the generated manifest\n    2. Apply it using POST /v1/manifest/apply","operationId":"generate_manifest_v1_manifest_generate_post","parameters":[{"name":"description","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Same as the body field","title":"Description"},"description":"Same as the body field"},{"name":"manifest_name","in":"query","required":false,"schema":{"type":"string","default":"generated-manifest","title":"Manifest Name"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/GenerateManifestRequest"},{"type":"null"}],"title":"Body"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/discovery/extractors":{"get":{"tags":["Discovery"],"summary":"List Available Feature Extractors","description":"Discover all available feature extractors with their capabilities, supported modalities, output features, and example usage. Use this to understand what extractors are available when configuring namespaces and collections in manifests.","operationId":"list_extractors_v1_discovery_extractors_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ExtractorDiscovery"},"type":"array","title":"Response List Extractors V1 Discovery Extractors Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/discovery/stages":{"get":{"tags":["Discovery"],"summary":"List Available Retriever Stages with Examples","description":"Discover all available retriever stages with extended information including example configurations, common use cases, and cost tiers. This endpoint provides more context than /v1/retrievers/stages for agent-driven configuration.","operationId":"list_stages_with_examples_v1_discovery_stages_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/StageDiscovery"},"type":"array","title":"Response List Stages With Examples V1 Discovery Stages Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/discovery/schema":{"get":{"tags":["Discovery"],"summary":"Get Manifest Schema for Agent Configuration","description":"Returns the complete manifest schema including all resource types, their JSON schemas, dependency graph, and YAML examples. Use this for programmatic manifest generation and validation.","operationId":"get_manifest_schema_v1_discovery_schema_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ManifestSchemaDiscovery"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/discovery/models":{"get":{"tags":["Discovery"],"summary":"List Models","description":"The model catalog: every model Mixpeek runs or can run, with its task, input and output schema, extractor and retriever wiring, run status, scale-to-zero profile, cost, evaluation evidence, references and the namespace templates that use it. Filter by task, modality, status, license, commercial use, GPU need, template or use case; search with q; sort by rank (default), name, release_date, params, size, dims or templates. No authentication required.","operationId":"list_models_v1_discovery_models_get","parameters":[{"name":"task","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Task category, e.g. embedding, detection, transcription","title":"Task"},"description":"Task category, e.g. embedding, detection, transcription"},{"name":"modality","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Input or output modality, e.g. image, video, text","title":"Modality"},"description":"Input or output modality, e.g. image, video, text"},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Run status: served, extractor, api, plugin or not_runnable","title":"Status"},"description":"Run status: served, extractor, api, plugin or not_runnable"},{"name":"commercial_use","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Only models whose license allows commercial use (true) or not","title":"Commercial Use"},"description":"Only models whose license allows commercial use (true) or not"},{"name":"license","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"License id, e.g. apache-2.0","title":"License"},"description":"License id, e.g. apache-2.0"},{"name":"gpu","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"true: needs a GPU. false: runs without one","title":"Gpu"},"description":"true: needs a GPU. false: runs without one"},{"name":"template","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Only models a namespace template uses (template slug)","title":"Template"},"description":"Only models a namespace template uses (template slug)"},{"name":"use_case","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Use case tag","title":"Use Case"},"description":"Use case tag"},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Words that must all appear in the model's text fields","title":"Q"},"description":"Words that must all appear in the model's text fields"},{"name":"sort","in":"query","required":false,"schema":{"type":"string","description":"rank, name, release_date, params, size, dims or templates","default":"rank","title":"Sort"},"description":"rank, name, release_date, params, size, dims or templates"},{"name":"order","in":"query","required":false,"schema":{"anyOf":[{"type":"string","pattern":"^(asc|desc)$"},{"type":"null"}],"description":"asc or desc; each sort has a default","title":"Order"},"description":"asc or desc; each sort has a default"},{"name":"view","in":"query","required":false,"schema":{"type":"string","pattern":"^(full|compact)$","description":"full records or compact index lines","default":"full","title":"View"},"description":"full records or compact index lines"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":500,"minimum":1,"description":"Page size","default":100,"title":"Limit"},"description":"Page size"},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"description":"Records to skip","default":0,"title":"Offset"},"description":"Records to skip"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ModelCatalogListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/discovery/models/{model_id}":{"get":{"tags":["Discovery"],"summary":"Get Model","description":"One model catalog record by id, with every stored field: identity, task, input and output schema, wiring, run profile, cost, evidence, references, templates, usage and facets. Name it in a manifest as an extractor source with ref: catalog://<id>. No authentication required.","operationId":"get_model_v1_discovery_models__model_id__get","parameters":[{"name":"model_id","in":"path","required":true,"schema":{"type":"string","title":"Model Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Model V1 Discovery Models  Model Id  Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"No model with that id","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/discovery":{"get":{"tags":["Discovery"],"summary":"Get All Discovery Information","description":"Returns combined discovery information including extractors, stages, the manifest schema and a compact model catalog index in a single request. Use this for comprehensive capability discovery.","operationId":"get_all_discovery_v1_discovery_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DiscoveryResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/signup/agent":{"post":{"tags":["Signup"],"summary":"Sign up as an agent","description":"Create a Mixpeek organization and API key without a browser. Send the email of the person you work for and accept_terms=true. The response carries a working API key (shown once), a namespace with a bucket, a collection and a retriever, and the calls that take a file to a search result. The email owner gets one email: confirming keeps the key, otherwise it expires 72 hours after signup, and blocking revokes it and refuses later agent signups for that email. One pending signup per email; limited per IP address per hour.","operationId":"agent_signup_v1_signup_agent_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgentSignupRequest"}}},"required":true,"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgentSignupResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"The email owner blocked agent signups.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"accept_terms is not true, or the email is disposable.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too many signups from this IP address this hour.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"409":{"description":"This email already has a signup waiting for confirmation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/marketplace/listings":{"post":{"tags":["Marketplace"],"summary":"Create Marketplace Listing","description":"Create a new marketplace listing for a retriever.\n\nThis endpoint allows retriever owners to publish their retrievers to the marketplace\nwith custom tiers, pricing, and display configuration.","operationId":"create_marketplace_listing_v1_marketplace_listings_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Listing Data"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketplaceListing"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/marketplace/listings/{listing_id}":{"patch":{"tags":["Marketplace"],"summary":"Update Marketplace Listing","description":"Update an existing marketplace listing.\n\nTo change what a live listing does, clone its retriever, edit the clone,\nthen send `{\"retriever_id\": \"<clone id>\"}`. The listing keeps its id,\nsubscribers, short URL and page configuration, and its publication moves\nto the clone. The clone must be in the listing's namespace and not already\npublished or listed.","operationId":"update_marketplace_listing_v1_marketplace_listings__listing_id__patch","parameters":[{"name":"listing_id","in":"path","required":true,"schema":{"type":"string","title":"Listing Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Listing Updates"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketplaceListing"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}},"delete":{"tags":["Marketplace"],"summary":"Delete Marketplace Listing","description":"Delete a marketplace listing.","operationId":"delete_marketplace_listing_v1_marketplace_listings__listing_id__delete","parameters":[{"name":"listing_id","in":"path","required":true,"schema":{"type":"string","title":"Listing Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/marketplace/listings/{listing_id}/publish":{"patch":{"tags":["Marketplace"],"summary":"Publish Marketplace Listing","description":"Publish a marketplace listing (change status from draft to published).","operationId":"publish_marketplace_listing_v1_marketplace_listings__listing_id__publish_patch","parameters":[{"name":"listing_id","in":"path","required":true,"schema":{"type":"string","title":"Listing Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketplaceListing"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/marketplace/catalog":{"get":{"tags":["Marketplace"],"summary":"Browse Marketplace Catalog","description":"Browse marketplace catalog with optional filters.\n\nReturns published, listed marketplace listings only. Unlisted retrievers\nare still accessible via direct link but don't appear here.","operationId":"get_marketplace_catalog_v1_marketplace_catalog_get","parameters":[{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by category label or slug (e.g., 'Brand Safety' or 'brand-safety').","title":"Category"},"description":"Filter by category label or slug (e.g., 'Brand Safety' or 'brand-safety')."},{"name":"group","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by curated group slug (e.g., 'ip-screening').","title":"Group"},"description":"Filter by curated group slug (e.g., 'ip-screening')."},{"name":"tags","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"null"}],"description":"Filter by tags (AND logic - listing must have all tags)","title":"Tags"},"description":"Filter by tags (AND logic - listing must have all tags)"},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Search in title and description","title":"Search"},"description":"Search in title and description"},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","minimum":0,"description":"Number of listings to skip","default":0,"title":"Skip"},"description":"Number of listings to skip"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Number of listings to return","default":20,"title":"Limit"},"description":"Number of listings to return"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/MarketplaceCatalogListing"},"title":"Response Get Marketplace Catalog V1 Marketplace Catalog Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/marketplace/catalog/{public_name}":{"get":{"tags":["Marketplace"],"summary":"Get Marketplace Listing by Public Name","description":"Get detailed information about a marketplace listing by its public name.\n\nExample: /marketplace/catalog/brand-safety-api","operationId":"get_marketplace_listing_by_name_v1_marketplace_catalog__public_name__get","parameters":[{"name":"public_name","in":"path","required":true,"schema":{"type":"string","description":"Public URL slug for the listing","title":"Public Name"},"description":"Public URL slug for the listing"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketplaceListingDetail"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/marketplace/catalog/{public_name}/execute":{"post":{"tags":["Marketplace"],"summary":"Execute Marketplace Retriever","description":"Execute a marketplace retriever using its public name. Free tier listings can be accessed without authentication. Paid tier access requires a subscription token.","operationId":"execute_marketplace_retriever_v1_marketplace_catalog__public_name__execute_post","parameters":[{"name":"public_name","in":"path","required":true,"schema":{"type":"string","description":"Public name of the marketplace listing","title":"Public Name"},"description":"Public name of the marketplace listing"},{"name":"return_presigned_urls","in":"query","required":false,"schema":{"type":"boolean","description":"Generate fresh presigned download URLs for all blobs with S3 storage","default":true,"title":"Return Presigned Urls"},"description":"Generate fresh presigned download URLs for all blobs with S3 storage"},{"name":"return_vectors","in":"query","required":false,"schema":{"type":"boolean","description":"Include vector embeddings in response","default":false,"title":"Return Vectors"},"description":"Include vector embeddings in response"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RetrieverExecutionRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/marketplace/catalog/{public_name}/config":{"get":{"tags":["Marketplace"],"summary":"Get Marketplace Listing Configuration","description":"Get display configuration for rendering the marketplace listing interface","operationId":"get_marketplace_listing_config_v1_marketplace_catalog__public_name__config_get","parameters":[{"name":"public_name","in":"path","required":true,"schema":{"type":"string","description":"Public name of the marketplace listing","title":"Public Name"},"description":"Public name of the marketplace listing"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/marketplace/catalog/{public_name}/verify":{"post":{"tags":["Marketplace"],"summary":"Verify Password for Marketplace Listing","description":"Verify password for a password-protected marketplace listing","operationId":"verify_marketplace_listing_password_v1_marketplace_catalog__public_name__verify_post","parameters":[{"name":"public_name","in":"path","required":true,"schema":{"type":"string","description":"Public name of the marketplace listing","title":"Public Name"},"description":"Public name of the marketplace listing"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Body_verify_marketplace_listing_password_v1_marketplace_catalog__public_name__verify_post"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/marketplace/catalog/{public_name}/template":{"get":{"tags":["Marketplace"],"summary":"Get Marketplace Listing as Template","description":"Get the retriever configuration from a marketplace listing as a reusable template","operationId":"get_marketplace_listing_template_v1_marketplace_catalog__public_name__template_get","parameters":[{"name":"public_name","in":"path","required":true,"schema":{"type":"string","description":"Public name of the marketplace listing","title":"Public Name"},"description":"Public name of the marketplace listing"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[]}},"/v1/marketplace/subscriptions":{"post":{"tags":["Marketplace"],"summary":"Subscribe to Marketplace Listing","description":"Subscribe to a marketplace listing.\n\nFree Tier:\n    - Immediately active\n    - Returns access_token (prk_xxx format)\n    - No Stripe checkout required\n\nPaid Tiers:\n    - Creates pending subscription\n    - Returns checkout_url for Stripe payment\n    - Subscription activates after payment via webhook","operationId":"create_subscription_v1_marketplace_subscriptions_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Body_create_subscription_v1_marketplace_subscriptions_post"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Create Subscription V1 Marketplace Subscriptions Post"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}},"get":{"tags":["Marketplace"],"summary":"List My Subscriptions","description":"List all subscriptions for the current organization.","operationId":"list_my_subscriptions_v1_marketplace_subscriptions_get","parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/SubscriptionStatus"},{"type":"null"}],"description":"Filter by subscription status","title":"Status"},"description":"Filter by subscription status"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","additionalProperties":true},"title":"Response List My Subscriptions V1 Marketplace Subscriptions Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/marketplace/subscriptions/{subscription_id}":{"get":{"tags":["Marketplace"],"summary":"Get Subscription Details","description":"Get detailed information about a subscription.","operationId":"get_subscription_v1_marketplace_subscriptions__subscription_id__get","parameters":[{"name":"subscription_id","in":"path","required":true,"schema":{"type":"string","description":"Subscription ID","title":"Subscription Id"},"description":"Subscription ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Subscription V1 Marketplace Subscriptions  Subscription Id  Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}},"delete":{"tags":["Marketplace"],"summary":"Cancel Subscription","description":"Cancel a marketplace subscription.\n\nFree Tier: Immediately revokes access\nPaid Tiers: Cancels at end of billing period","operationId":"cancel_subscription_v1_marketplace_subscriptions__subscription_id__delete","parameters":[{"name":"subscription_id","in":"path","required":true,"schema":{"type":"string","description":"Subscription ID to cancel","title":"Subscription Id"},"description":"Subscription ID to cancel"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Cancel Subscription V1 Marketplace Subscriptions  Subscription Id  Delete"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/namespaces/migrations/":{"post":{"tags":["Namespace Migrations"],"summary":"Create Migration","description":"Create a new namespace migration.\n\nThis endpoint creates a migration and optionally validates it.\nUse start_immediately=True to begin execution immediately.\n\nArgs:\n    request: FastAPI request\n    create_request: Migration configuration\n\nReturns:\n    CreateMigrationResponse with migration ID and status","operationId":"create_migration_v1_namespaces_migrations__post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateMigrationRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateMigrationResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/migrations/{migration_id}":{"get":{"tags":["Namespace Migrations"],"summary":"Get Migration","description":"Get migration details and status.\n\nArgs:\n    request: FastAPI request\n    migration_id: Migration ID\n\nReturns:\n    GetMigrationResponse with full migration details","operationId":"get_migration_v1_namespaces_migrations__migration_id__get","parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","title":"Migration Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetMigrationResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]},"delete":{"tags":["Namespace Migrations"],"summary":"Delete Migration","description":"Delete a migration record.\n\nOnly draft, completed, failed, or cancelled migrations can be deleted.\n\nArgs:\n    request: FastAPI request\n    migration_id: Migration ID","operationId":"delete_migration_v1_namespaces_migrations__migration_id__delete","parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","title":"Migration Id"}}],"responses":{"204":{"description":"Successful Response"},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["delete"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/migrations/list":{"post":{"tags":["Namespace Migrations"],"summary":"List Migrations","description":"List migrations with optional filters.\n\nArgs:\n    request: FastAPI request\n    list_request: Filter and pagination parameters\n\nReturns:\n    ListMigrationsResponse with migrations list","operationId":"list_migrations_v1_namespaces_migrations_list_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListMigrationsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListMigrationsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/migrations/{migration_id}/start":{"post":{"tags":["Namespace Migrations"],"summary":"Start Migration","description":"Start a migration execution.\n\nArgs:\n    request: FastAPI request\n    migration_id: Migration ID\n    start_request: Start options\n\nReturns:\n    StartMigrationResponse with task ID","operationId":"start_migration_v1_namespaces_migrations__migration_id__start_post","parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","title":"Migration Id"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StartMigrationRequest","default":{"force":false}}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StartMigrationResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/migrations/{migration_id}/cancel":{"post":{"tags":["Namespace Migrations"],"summary":"Cancel Migration","description":"Cancel a running migration.\n\nArgs:\n    request: FastAPI request\n    migration_id: Migration ID\n    cancel_request: Cancellation options\n\nReturns:\n    CancelMigrationResponse with updated status","operationId":"cancel_migration_v1_namespaces_migrations__migration_id__cancel_post","parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","title":"Migration Id"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CancelMigrationRequest","default":{}}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CancelMigrationResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/migrations/validate":{"post":{"tags":["Namespace Migrations"],"summary":"Validate Migration","description":"Validate a migration configuration without creating it.\n\nUse this endpoint to check if a migration configuration is valid\nbefore actually creating and running it.\n\nArgs:\n    request: FastAPI request\n    validate_request: Configuration to validate\n\nReturns:\n    ValidateMigrationResponse with validation results","operationId":"validate_migration_v1_namespaces_migrations_validate_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ValidateMigrationRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ValidateMigrationResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/{namespace_identifier}/snapshots":{"post":{"tags":["Namespace Snapshots"],"summary":"Create Namespace Snapshot","description":"Create a point-in-time snapshot of the entire namespace. Captures all MongoDB documents and an S3 object manifest. Optionally copies S3 objects to the snapshot prefix for full data preservation (required if you plan to delete the namespace and restore later). With import_from, imports a snapshot taken on another plane instead: its artifacts are copied from an allowed backup bucket, each checked against its recorded sha256, and the snapshot is completed only if verify finds it restorable.","operationId":"create_snapshot_v1_namespaces__namespace_identifier__snapshots_post","parameters":[{"name":"namespace_identifier","in":"path","required":true,"schema":{"type":"string","description":"Namespace name or ID","title":"Namespace Identifier"},"description":"Namespace name or ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateSnapshotRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateSnapshotResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/{namespace_identifier}/snapshots/list":{"post":{"tags":["Namespace Snapshots"],"summary":"List Namespace Snapshots","description":"List all snapshots for a namespace, newest first.","operationId":"list_snapshots_v1_namespaces__namespace_identifier__snapshots_list_post","parameters":[{"name":"namespace_identifier","in":"path","required":true,"schema":{"type":"string","description":"Namespace name or ID","title":"Namespace Identifier"},"description":"Namespace name or ID"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListSnapshotsRequest","description":"Pagination parameters","default":{"skip":0,"limit":20}}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListSnapshotsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/{namespace_identifier}/snapshots/{snapshot_id}":{"get":{"tags":["Namespace Snapshots"],"summary":"Get Snapshot","description":"Get details of a specific snapshot. With download=true the response also carries a signed URL and the sha256 for every artifact (configuration, Mongo dumps, vector export, object manifest), valid for one hour, so you can download the namespace.","operationId":"get_snapshot_v1_namespaces__namespace_identifier__snapshots__snapshot_id__get","parameters":[{"name":"namespace_identifier","in":"path","required":true,"schema":{"type":"string","description":"Namespace name or ID","title":"Namespace Identifier"},"description":"Namespace name or ID"},{"name":"snapshot_id","in":"path","required":true,"schema":{"type":"string","description":"Snapshot ID (e.g. snap_xxxxxxxxxxxx)","title":"Snapshot Id"},"description":"Snapshot ID (e.g. snap_xxxxxxxxxxxx)"},{"name":"download","in":"query","required":false,"schema":{"type":"boolean","description":"Return signed download URLs and sha256 digests for every artifact. Only a completed snapshot can be downloaded.","default":false,"title":"Download"},"description":"Return signed download URLs and sha256 digests for every artifact. Only a completed snapshot can be downloaded."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SnapshotDetailResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]},"delete":{"tags":["Namespace Snapshots"],"summary":"Delete Snapshot","description":"Delete a snapshot and its associated S3 data.","operationId":"delete_snapshot_v1_namespaces__namespace_identifier__snapshots__snapshot_id__delete","parameters":[{"name":"namespace_identifier","in":"path","required":true,"schema":{"type":"string","description":"Namespace name or ID","title":"Namespace Identifier"},"description":"Namespace name or ID"},{"name":"snapshot_id","in":"path","required":true,"schema":{"type":"string","description":"Snapshot ID to delete","title":"Snapshot Id"},"description":"Snapshot ID to delete"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["delete"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/{namespace_identifier}/snapshots/{snapshot_id}/verify":{"get":{"tags":["Namespace Snapshots"],"summary":"Verify Snapshot Restore-Readiness","description":"Read-only pre-flight check that a snapshot can actually be restored. Restore is lenient and silently skips missing artifacts, so this surfaces what a restore would drop (missing collection dumps, unreachable vectors, absent copied objects) BEFORE you depend on it in a recovery. Pass deep=true to also decompress each collection dump and detect truncation.","operationId":"verify_snapshot_v1_namespaces__namespace_identifier__snapshots__snapshot_id__verify_get","parameters":[{"name":"namespace_identifier","in":"path","required":true,"schema":{"type":"string","description":"Namespace name or ID","title":"Namespace Identifier"},"description":"Namespace name or ID"},{"name":"snapshot_id","in":"path","required":true,"schema":{"type":"string","description":"Snapshot ID to verify (e.g. snap_xxxxxxxxxxxx)","title":"Snapshot Id"},"description":"Snapshot ID to verify (e.g. snap_xxxxxxxxxxxx)"},{"name":"deep","in":"query","required":false,"schema":{"type":"boolean","description":"Also decompress each collection dump to detect truncated artifacts","default":false,"title":"Deep"},"description":"Also decompress each collection dump to detect truncated artifacts"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SnapshotVerifyResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/{namespace_identifier}/snapshots/{snapshot_id}/restore":{"post":{"tags":["Namespace Snapshots"],"summary":"Restore From Snapshot","description":"Restore a namespace from a snapshot. If target_namespace_name is provided, creates a new namespace with the restored data. Otherwise, restores in-place (replaces current namespace data).","operationId":"restore_snapshot_v1_namespaces__namespace_identifier__snapshots__snapshot_id__restore_post","parameters":[{"name":"namespace_identifier","in":"path","required":true,"schema":{"type":"string","description":"Namespace name or ID","title":"Namespace Identifier"},"description":"Namespace name or ID"},{"name":"snapshot_id","in":"path","required":true,"schema":{"type":"string","description":"Snapshot ID to restore from","title":"Snapshot Id"},"description":"Snapshot ID to restore from"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RestoreSnapshotRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RestoreSnapshotResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/{namespace_identifier}/clone":{"post":{"tags":["Namespace Clone"],"summary":"Clone Namespace","description":"Clone a namespace with all its data.\n\n    **What gets cloned:**\n    - Namespace configuration (extractors, payload indexes)\n    - Buckets (metadata, references same S3 files)\n    - Collections (full copy of all vectors/embeddings)\n    - Retrievers (pipeline configuration)\n\n    **Use Cases:**\n    - Create staging environment from production\n    - Backup namespace with all data\n    - Fork namespace for experimentation\n\n    **For a config-only copy (no data):** export the namespace with\n    POST /v1/manifest/export and apply the manifest with POST /v1/manifest/apply.","operationId":"clone_namespace_v1_namespaces__namespace_identifier__clone_post","parameters":[{"name":"namespace_identifier","in":"path","required":true,"schema":{"type":"string","description":"Source namespace ID or name to clone from","title":"Namespace Identifier"},"description":"Source namespace ID or name to clone from"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloneNamespaceRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloneNamespaceResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces":{"post":{"tags":["Namespaces"],"summary":"Create Namespace","description":"Creates a new namespace with specified feature extractors and payload indexes.","operationId":"create_namespace_v1_namespaces_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateNamespaceRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NamespaceModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]},"get":{"tags":["Namespaces"],"summary":"List Namespaces","description":"List all namespaces (GET alias for POST /list). Supports query param pagination: ?limit=N&offset=M","operationId":"list_namespaces_get_v1_namespaces_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListNamespacesResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/{namespace_identifier}":{"delete":{"tags":["Namespaces"],"summary":"Delete Namespace","description":"This endpoint deletes a namespace and ALL its resources including:\n    - All buckets (with S3 objects, batches, uploads)\n    - All collections (with vector points, cache, webhooks)\n    - All clusters (with Ray jobs, executions, triggers, S3 artifacts)\n    - All retrievers (with executions, evaluations, interactions, cache)\n    - Remaining MongoDB collections (tasks, uploads, taxonomies, API keys, etc.)\n    - All S3 objects with namespace prefix\n    - The namespace's vectors in the vector store\n    - All namespace cache (across all scopes)\n    - The namespace's analytics events\n    - Namespace metadata\n\n    The deletion is performed asynchronously. Returns a task_id that can be used\n    to poll for deletion progress via GET /v1/tasks/{task_id}.\n\n    ⚠️  WARNING: This operation is irreversible and will delete ALL data in the namespace!","operationId":"delete_namespace_v1_namespaces__namespace_identifier__delete","parameters":[{"name":"namespace_identifier","in":"path","required":true,"schema":{"type":"string","description":"Either the namespace name or namespace ID","examples":["my_namespace","ns_1234567890"],"title":"Namespace Identifier"},"description":"Either the namespace name or namespace ID"},{"name":"force","in":"query","required":false,"schema":{"type":"boolean","description":"Force deletion even if batches are still processing. Without this flag, the endpoint returns 409 when active batches exist.","default":false,"title":"Force"},"description":"Force deletion even if batches are still processing. Without this flag, the endpoint returns 409 when active batches exist."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["delete"]},"security":[{"BearerAuth":[]}]},"put":{"tags":["Namespaces"],"summary":"Update Namespace","description":"Fully updates an existing namespace (all fields required)","operationId":"update_namespace_v1_namespaces__namespace_identifier__put","parameters":[{"name":"namespace_identifier","in":"path","required":true,"schema":{"type":"string","description":"Either the namespace name or namespace ID","examples":["my_namespace","ns_1234567890"],"title":"Namespace Identifier"},"description":"Either the namespace name or namespace ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateNamespaceRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NamespaceModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]},"patch":{"tags":["Namespaces"],"summary":"Partially Update Namespace","description":"Partially updates an existing namespace (PATCH operation)","operationId":"patch_namespace_v1_namespaces__namespace_identifier__patch","parameters":[{"name":"namespace_identifier","in":"path","required":true,"schema":{"type":"string","description":"Either the namespace name or namespace ID","examples":["my_namespace","ns_1234567890"],"title":"Namespace Identifier"},"description":"Either the namespace name or namespace ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchNamespaceRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NamespaceModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]},"get":{"tags":["Namespaces"],"summary":"Get Namespace","description":"Retrieve details of a specific namespace using either its name or ID","operationId":"get_namespace_v1_namespaces__namespace_identifier__get","parameters":[{"name":"namespace_identifier","in":"path","required":true,"schema":{"type":"string","description":"Either the namespace name or namespace ID","examples":["my_namespace","ns_1234567890"],"title":"Namespace Identifier"},"description":"Either the namespace name or namespace ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NamespaceModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/list":{"post":{"tags":["Namespaces"],"summary":"List Namespaces","description":"List all namespaces for a user","operationId":"list_namespaces_v1_namespaces_list_post","parameters":[{"name":"include_system","in":"query","required":false,"schema":{"type":"boolean","description":"Include read-only system namespaces (e.g. sample-data)","default":false,"title":"Include System"},"description":"Include read-only system namespaces (e.g. sample-data)"},{"name":"view","in":"query","required":false,"schema":{"enum":["full","summary"],"type":"string","description":"Response detail level. 'full' (default) returns complete namespace objects. 'summary' omits heavy per-namespace config (payload_indexes, feature_extractors, vector_inference_map, vector_configs) — ~93% smaller — for high-frequency list/switcher views. Fetch full config via GET /v1/namespaces/{namespace_identifier}.","default":"full","title":"View"},"description":"Response detail level. 'full' (default) returns complete namespace objects. 'summary' omits heavy per-namespace config (payload_indexes, feature_extractors, vector_inference_map, vector_configs) — ~93% smaller — for high-frequency list/switcher views. Fetch full config via GET /v1/namespaces/{namespace_identifier}."},{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListNamespacesRequest","default":{"case_sensitive":false}}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListNamespacesResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/stats/batch":{"post":{"tags":["Namespaces"],"summary":"Get Namespace Stats (Batch)","description":"Returns document/bucket/collection/object counts for many namespaces in ONE call. Replaces per-row /stats fan-out on list views. Counts are aggregated in batch and live doc-counts gathered concurrently; namespaces the caller cannot see are omitted.","operationId":"get_namespace_stats_batch_v1_namespaces_stats_batch_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NamespaceStatsBatchRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NamespaceStatsBatchResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/{namespace_identifier}/stats":{"get":{"tags":["Namespaces"],"summary":"Get Namespace Stats","description":"Returns document, bucket, collection, and object counts for a single namespace. Use this instead of relying on counts in the list endpoint.","operationId":"get_namespace_stats_v1_namespaces__namespace_identifier__stats_get","parameters":[{"name":"namespace_identifier","in":"path","required":true,"schema":{"type":"string","description":"Either the namespace name or namespace ID","examples":["my_namespace","ns_1234567890"],"title":"Namespace Identifier"},"description":"Either the namespace name or namespace ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NamespaceStatsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/{namespace_identifier}/ensure-indexes":{"post":{"tags":["Namespaces"],"summary":"Ensure Namespace Payload Indexes","description":"(Re-)create the namespace's declared payload indexes in the vector store, including FULLTEXT/BM25, idempotently. ZERO-EXTRACTION: registers any missing indexes and backfills existing documents WITHOUT triggering any ingest or re-extraction. Use to repair a missing index (e.g. a FULLTEXT index that failed to register) or as a self-serve re-index tool — no re-ingest, no GPU.\n\nREADING THE RESPONSE: `ensured` lists indexes the call confirmed present — it does NOT mean they were newly built, and an already-registered index is a cheap no-op on the shard. `rebuilt` is populated only with `force_rebuild=true`, which is the case that does real work. `skipped` is normally empty because the store reports an idempotent no-op as success rather than an error, so an empty `skipped` does not imply the rest were created. `created` is a deprecated alias of `ensured` + `rebuilt`.\n\nCOST: a plain ensure is cheap. `force_rebuild=true` applies to EVERY declared index, drops and rebuilds each from the complete store, and for FULLTEXT fields first hydrates the full payload store — no GPU, but real shard CPU and memory proportional to the corpus. Size it before running on a large or memory-constrained namespace.","operationId":"ensure_namespace_indexes_v1_namespaces__namespace_identifier__ensure_indexes_post","parameters":[{"name":"namespace_identifier","in":"path","required":true,"schema":{"type":"string","description":"Either the namespace name or namespace ID","examples":["my_namespace","ns_1234567890"],"title":"Namespace Identifier"},"description":"Either the namespace name or namespace ID"},{"name":"force_rebuild","in":"query","required":false,"schema":{"type":"boolean","description":"Drop and rebuild each index from the complete store instead of the normal idempotent ensure. Use to repair a FULLTEXT/BM25 field that registered empty during a cold shard warmup (no cluster access needed — the shard grpc is in-cluster only, so this API is the sole trigger). Default false.","default":false,"title":"Force Rebuild"},"description":"Drop and rebuild each index from the complete store instead of the normal idempotent ensure. Use to repair a FULLTEXT/BM25 field that registered empty during a cold shard warmup (no cluster access needed — the shard grpc is in-cluster only, so this API is the sole trigger). Default false."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/{namespace_id}/documents/upsert":{"post":{"tags":["BYO Documents"],"summary":"Upsert documents with BYO vectors","description":"Upsert documents with user-provided vectors directly into a namespace. This bypasses the collection/batch/extractor pipeline entirely. Documents go directly to the vector store. Maximum 1000 documents per call.","operationId":"upsert_documents_byo_v1_namespaces__namespace_id__documents_upsert_post","parameters":[{"name":"namespace_id","in":"path","required":true,"schema":{"type":"string","description":"The namespace to upsert documents into.","examples":["ns_abc123def456"],"title":"Namespace Id"},"description":"The namespace to upsert documents into."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BYOUpsertRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BYOUpsertResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":true,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/{namespace_id}/documents/{document_id}":{"get":{"tags":["BYO Documents"],"summary":"Get a document by ID (path-scoped namespace)","description":"Fetch a single document by document_id from a namespace named in the PATH — the mirror of POST /v1/namespaces/{namespace_id}/documents/upsert, so directly-upserted (BYO/standalone) documents can be read back on the same URL convention they were written with. Equivalent to GET /v1/documents/{document_id} with the X-Namespace header.","operationId":"get_document_byo_v1_namespaces__namespace_id__documents__document_id__get","parameters":[{"name":"namespace_id","in":"path","required":true,"schema":{"type":"string","description":"Namespace name or ID the document lives in.","examples":["ns_abc123def456"],"title":"Namespace Id"},"description":"Namespace name or ID the document lives in."},{"name":"document_id","in":"path","required":true,"schema":{"type":"string","description":"The document_id to fetch.","examples":["doc_001"],"title":"Document Id"},"description":"The document_id to fetch."},{"name":"return_vectors","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Return Vectors"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":true,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/standalone":{"post":{"tags":["BYO Documents"],"summary":"Create standalone namespace (BYO vectors)","description":"Create a standalone namespace for BYO (Bring Your Own) vectors. No collection or feature extractor binding is required. Users upsert pre-computed vectors directly via the direct upsert endpoint.","operationId":"create_standalone_namespace_v1_namespaces_standalone_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateStandaloneNamespaceRequestModel"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StandaloneNamespaceResponseModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":true,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/{namespace_id}/promote":{"post":{"tags":["BYO Documents"],"summary":"Promote standalone namespace to managed mode","description":"Promote a standalone (BYO vectors) namespace to managed mode. Existing vectors and documents are preserved. Optionally maps existing vector indexes to inference services and adds new indexes.","operationId":"promote_namespace_v1_namespaces__namespace_id__promote_post","parameters":[{"name":"namespace_id","in":"path","required":true,"schema":{"type":"string","description":"Namespace to promote","title":"Namespace Id"},"description":"Namespace to promote"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromoteNamespaceRequestModel"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromoteNamespaceResponseModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":true,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/{namespace_id}/promote/validate":{"post":{"tags":["BYO Documents"],"summary":"Dry-run validate a standalone → managed promotion","description":"Validate a proposed promotion without mutating the namespace. Returns per-index mapping suggestions (dimension-matched candidates, flagged low-confidence) and validates any supplied vector_mappings / add_vectors for unknown indexes, unknown inference services, and dimension mismatches. Returns HTTP 422 when supplied mappings are invalid so callers can fix them before the real promote call.","operationId":"validate_promotion_v1_namespaces__namespace_id__promote_validate_post","parameters":[{"name":"namespace_id","in":"path","required":true,"schema":{"type":"string","description":"Namespace to validate promotion for","title":"Namespace Id"},"description":"Namespace to validate promotion for"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromoteNamespaceRequestModel"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromoteValidateResponseModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":true,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/extractors/{extractor_id}/publish":{"post":{"tags":["Extractor Publishing"],"summary":"Publish an extractor to the marketplace","operationId":"publish_extractor_v1_extractors__extractor_id__publish_post","parameters":[{"name":"extractor_id","in":"path","required":true,"schema":{"type":"string","description":"ID of the extractor to publish","title":"Extractor Id"},"description":"ID of the extractor to publish"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublishExtractorRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublishExtractorResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]},"get":{"tags":["Extractor Publishing"],"summary":"Get published extractor status","operationId":"get_published_extractor_v1_extractors__extractor_id__publish_get","parameters":[{"name":"extractor_id","in":"path","required":true,"schema":{"type":"string","description":"ID of the extractor","title":"Extractor Id"},"description":"ID of the extractor"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublishedExtractorResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]},"patch":{"tags":["Extractor Publishing"],"summary":"Update published extractor","operationId":"update_published_extractor_v1_extractors__extractor_id__publish_patch","parameters":[{"name":"extractor_id","in":"path","required":true,"schema":{"type":"string","description":"ID of the extractor","title":"Extractor Id"},"description":"ID of the extractor"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdatePublishedExtractorRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublishedExtractorResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]},"delete":{"tags":["Extractor Publishing"],"summary":"Unpublish an extractor","operationId":"unpublish_extractor_v1_extractors__extractor_id__publish_delete","parameters":[{"name":"extractor_id","in":"path","required":true,"schema":{"type":"string","description":"ID of the extractor to unpublish","title":"Extractor Id"},"description":"ID of the extractor to unpublish"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/extractors/install":{"post":{"tags":["Extractor Publishing"],"summary":"Install a public extractor","operationId":"install_extractor_v1_extractors_install_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InstallExtractorRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InstallExtractorResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/extractors":{"get":{"tags":["Extractors"],"summary":"List all extractors available to organization","description":"List all extractors available across the organization.\n\nReturns a unified view combining:\n- **Builtin extractors**: Core extractors shipped with Mixpeek\n- **Custom extractors**: Org-level custom extractors (uploaded via the upload workflow)\n\nUse `source` to filter by origin.","operationId":"list_org_extractors_v1_extractors_get","parameters":[{"name":"source","in":"query","required":false,"schema":{"anyOf":[{"enum":["builtin","custom","all"],"type":"string"},{"type":"null"}],"description":"Filter by extractor source","title":"Source"},"description":"Filter by extractor source"},{"name":"include_disabled","in":"query","required":false,"schema":{"type":"boolean","description":"Include disabled/undeployed custom extractors","default":false,"title":"Include Disabled"},"description":"Include disabled/undeployed custom extractors"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnifiedExtractorListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/extractors/submissions/uploads":{"post":{"tags":["Extractors"],"summary":"Get presigned URL for extractor submission","description":"Step 1: Get a presigned URL to upload your extractor archive to S3.","operationId":"generate_upload_url_v1_extractors_submissions_uploads_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateSubmissionUploadRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubmissionPresignedURLResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/extractors/submissions/uploads/{submission_id}/confirm":{"post":{"tags":["Extractors"],"summary":"Confirm extractor submission upload","description":"Step 2: Confirm upload, triggers security scan and manifest validation.","operationId":"confirm_submission_v1_extractors_submissions_uploads__submission_id__confirm_post","parameters":[{"name":"submission_id","in":"path","required":true,"schema":{"type":"string","title":"Submission Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfirmSubmissionRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfirmSubmissionResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/extractors/submissions":{"get":{"tags":["Extractors"],"summary":"List extractor submissions","description":"List all extractor submissions for this organization.","operationId":"list_submissions_v1_extractors_submissions_get","parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"enum":["submitted","scanning","review","approved","rejected"],"type":"string"},{"type":"null"}],"title":"Status"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubmissionListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]},"security":[{"BearerAuth":[]}]}},"/v1/extractors/submissions/{submission_id}":{"get":{"tags":["Extractors"],"summary":"Get submission details","operationId":"get_submission_v1_extractors_submissions__submission_id__get","parameters":[{"name":"submission_id","in":"path","required":true,"schema":{"type":"string","title":"Submission Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubmissionDetailResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]},"security":[{"BearerAuth":[]}]}},"/v1/models/uploads":{"post":{"tags":["Models"],"summary":"Generate presigned URL for model upload","description":"Generate a presigned URL for uploading a custom model archive.\n\nThis is step 1 of the presigned URL workflow:\n1. POST /models/uploads → Returns presigned_url + upload_id\n2. PUT presigned_url with model archive (client uploads directly to S3)\n3. POST /models/uploads/{upload_id}/confirm → Validates and creates model\n\nThe model will be stored at the organization level and can be enabled\nin any namespace within the organization.\n\n**Availability**: custom model upload is an **enterprise-tier** feature —\nrequests from other account tiers receive a 403. Contact support or\nupgrade your plan to enable it (this gate was previously\nundocumented and only discoverable by hitting the 403).","operationId":"generate_upload_url_v1_models_uploads_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateModelUploadRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ModelPresignedURLResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/models/uploads/{upload_id}/confirm":{"post":{"tags":["Models"],"summary":"Confirm model upload","description":"Confirm a model upload after the S3 upload completes.\n\nThis is step 3 of the presigned URL workflow. Call this after\nuploading the model archive to the presigned URL.\n\nThe service will:\n1. Verify the S3 object exists\n2. Validate the archive structure\n3. Create the model record","operationId":"confirm_upload_v1_models_uploads__upload_id__confirm_post","parameters":[{"name":"upload_id","in":"path","required":true,"schema":{"type":"string","title":"Upload Id"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfirmModelUploadRequest","default":{}}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfirmModelUploadResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/models":{"get":{"tags":["Models"],"summary":"List organization models","description":"List all custom models registered at the organization level.\n\nThese models can be enabled in any namespace within the organization\nusing the namespace-level enable endpoint.","operationId":"list_models_v1_models_get","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgModelListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":[]},"security":[{"BearerAuth":[]}]}},"/v1/models/{model_id}":{"get":{"tags":["Models"],"summary":"Get model details","description":"Get detailed information about an org-level model.","operationId":"get_model_v1_models__model_id__get","parameters":[{"name":"model_id","in":"path","required":true,"schema":{"type":"string","title":"Model Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgModelDetailResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":[]},"security":[{"BearerAuth":[]}]},"delete":{"tags":["Models"],"summary":"Delete model","description":"Delete an org-level model.\n\nThe model must not be enabled in any namespaces. If it is still enabled,\nyou must disable it in all namespaces first before deleting.","operationId":"delete_model_v1_models__model_id__delete","parameters":[{"name":"model_id","in":"path","required":true,"schema":{"type":"string","title":"Model Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgModelDeleteResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["delete"]},"security":[{"BearerAuth":[]}]}},"/v1/models/{model_id}/download":{"get":{"tags":["Models"],"summary":"Download model archive","description":"Get a presigned download URL for a model's archive (.tar.gz).\n\nOnly available for exportable models. Models created by Mixpeek\nprofessional services (source='mixpeek') are non-exportable and will\nreturn 403.","operationId":"download_model_v1_models__model_id__download_get","parameters":[{"name":"model_id","in":"path","required":true,"schema":{"type":"string","title":"Model Id"}}],"responses":{"200":{"description":"Presigned download URL","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Download Model V1 Models  Model Id  Download Get"},"example":{"download_url":"https://s3.amazonaws.com/..."}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Model is non-exportable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Model not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":[]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/{namespace_id}/extractors":{"get":{"tags":["Namespace Extractors"],"summary":"List all extractors available to namespace","description":"List all feature extractors available for use in this namespace.\n\nThis endpoint returns a **unified view** combining:\n- **Builtin extractors**: Core extractors shipped with Mixpeek (text_extractor, image_extractor, etc.)\n- **Custom plugins**: User-uploaded plugins at org or namespace level (Enterprise)\n\nEach extractor includes:\n- `input_schema`: JSON schema for input data validation\n- `output_schema`: JSON schema for output document structure\n- `parameter_schema`: JSON schema for configurable parameters\n- `required_vector_indexes`: Vector indexes produced by this extractor\n- `feature_uri`: URI to reference this extractor in collections\n\n**Use Cases:**\n- Discover available extractors when creating collections\n- Get schema information for SDK code generation\n- Check which custom plugins are deployed\n\n**Filtering:**\n- `source=builtin`: Only builtin extractors\n- `source=custom`: Only custom plugins\n- `source=all` (default): All extractors","operationId":"list_extractors_v1_namespaces__namespace_id__extractors_get","parameters":[{"name":"namespace_id","in":"path","required":true,"schema":{"type":"string","title":"Namespace Id"}},{"name":"source","in":"query","required":false,"schema":{"anyOf":[{"enum":["builtin","custom","all"],"type":"string"},{"type":"null"}],"description":"Filter by extractor source (builtin, custom, or all)","title":"Source"},"description":"Filter by extractor source (builtin, custom, or all)"},{"name":"include_disabled","in":"query","required":false,"schema":{"type":"boolean","description":"Include disabled/undeployed custom plugins","default":false,"title":"Include Disabled"},"description":"Include disabled/undeployed custom plugins"}],"responses":{"200":{"description":"List of all available extractors","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnifiedExtractorListResponse"},"example":{"success":true,"extractors":[{"feature_extractor_name":"text_extractor","version":"v1","feature_extractor_id":"text_extractor_v1","source":"builtin","description":"Extract text embeddings from documents","input_schema":{"type":"object"},"output_schema":{"type":"object"},"feature_uri":"mixpeek://text_extractor@v1/embedding"}],"total":8,"namespace_id":"ns_xxx","builtin_count":6,"custom_count":2}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/namespaces/{namespace_id}/extractors/{extractor_id}":{"get":{"tags":["Namespace Extractors"],"summary":"Get extractor details","description":"Get detailed information about a specific extractor.\n\nWorks for both builtin extractors and custom plugins.\n\n**Parameters:**\n- `extractor_id`: Extractor identifier (e.g., 'text_extractor_v1', 'my_custom_plugin_1_0_0')\n\n**Response includes:**\n- Full schema information (input, output, parameters)\n- Vector index configuration\n- For custom plugins: deployment status, validation status","operationId":"get_extractor_v1_namespaces__namespace_id__extractors__extractor_id__get","parameters":[{"name":"namespace_id","in":"path","required":true,"schema":{"type":"string","title":"Namespace Id"}},{"name":"extractor_id","in":"path","required":true,"schema":{"type":"string","title":"Extractor Id"}}],"responses":{"200":{"description":"Extractor details","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnifiedExtractorResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Extractor not found","content":{"application/json":{"example":{"success":false,"status":404,"error":{"message":"Extractor 'unknown_extractor_v1' not found","type":"NotFoundError"}},"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/namespaces/{namespace_id}/models":{"post":{"tags":["Custom Models"],"summary":"Upload a custom model","description":"Upload custom model weights and enable them in this namespace.\n\nThe weights become a model in your organization's model registry, the list\nGET /v1/models returns, so a model keeps one id in every namespace. Weights the\nregistry already holds resolve to that model's id. This namespace gets the same\nrecord that POST /v1/namespaces/{namespace_id}/models/org/{model_id}/enable\nwrites. The name and version follow the registry's rules: 3 to 64 letters,\nnumbers or underscores starting with a letter, and a version like `1.0.0`.\n\n**Requirements:**\n- Organization must be on Enterprise tier\n\n**Supported Model Formats:**\n- `safetensors`: SafeTensors format (recommended for transformers)\n- `onnx`: ONNX Runtime format\n- `pytorch`: PyTorch state_dict or TorchScript\n- `huggingface`: HuggingFace model directory\n\n**Base Images (auto-selected based on format):**\n- `mixpeek/serve-gpu:latest`: For safetensors, pytorch, huggingface (includes torch, transformers)\n- `mixpeek/serve-minimal:latest`: For ONNX (includes onnxruntime only)\n\n**Important:** Models run in fixed base images. You cannot install additional pip packages.\nAll required frameworks (torch, transformers, onnxruntime) are pre-installed.","operationId":"upload_model_v1_namespaces__namespace_id__models_post","parameters":[{"name":"namespace_id","in":"path","required":true,"schema":{"type":"string","title":"Namespace Id"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_model_v1_namespaces__namespace_id__models_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ModelUploadResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Custom models not supported","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"409":{"description":"This name and version already exist in this namespace, or in the organization with other weights","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]},"get":{"tags":["Custom Models"],"summary":"List models in namespace","description":"List all custom models uploaded to the namespace.","operationId":"list_models_v1_namespaces__namespace_id__models_get","parameters":[{"name":"namespace_id","in":"path","required":true,"schema":{"type":"string","title":"Namespace Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ModelListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/{namespace_id}/models/available":{"get":{"tags":["Custom Models"],"summary":"List available org models","description":"List org-level models available to enable in this namespace.\n\nShows all models registered at the organization level and whether\nthey are already enabled in the target namespace.","operationId":"list_available_org_models_v1_namespaces__namespace_id__models_available_get","parameters":[{"name":"namespace_id","in":"path","required":true,"schema":{"type":"string","title":"Namespace Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AvailableOrgModelsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/{namespace_id}/models/org/{model_id}/enable":{"post":{"tags":["Custom Models"],"summary":"Enable org model for namespace","description":"Enable an org-level model for this namespace.\n\nThis creates a namespace-specific deployment record for the model,\nallowing it to be used within this namespace. Optionally deploys\nthe model to Ray immediately.\n\n**Note:** The model must first be registered at the organization level\nvia POST /models/uploads.","operationId":"enable_org_model_v1_namespaces__namespace_id__models_org__model_id__enable_post","parameters":[{"name":"namespace_id","in":"path","required":true,"schema":{"type":"string","title":"Namespace Id"}},{"name":"model_id","in":"path","required":true,"schema":{"type":"string","title":"Model Id"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnableOrgModelRequest","default":{"deploy":false}}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnableOrgModelResponse"}}}},"400":{"description":"Model validation failed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Org model not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/{namespace_id}/models/org/{model_id}/disable":{"post":{"tags":["Custom Models"],"summary":"Disable org model for namespace","description":"Disable an org-level model for this namespace.\n\nThis removes the namespace-specific deployment record. The model\nremains available at the organization level and can be re-enabled.","operationId":"disable_org_model_v1_namespaces__namespace_id__models_org__model_id__disable_post","parameters":[{"name":"namespace_id","in":"path","required":true,"schema":{"type":"string","title":"Namespace Id"}},{"name":"model_id","in":"path","required":true,"schema":{"type":"string","title":"Model Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DisableOrgModelResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Model not enabled in namespace","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/{namespace_id}/models/{model_id}":{"get":{"tags":["Custom Models"],"summary":"Get model details","description":"Get detailed information about a specific model.","operationId":"get_model_v1_namespaces__namespace_id__models__model_id__get","parameters":[{"name":"namespace_id","in":"path","required":true,"schema":{"type":"string","title":"Namespace Id"}},{"name":"model_id","in":"path","required":true,"schema":{"type":"string","title":"Model Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ModelDetailResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Model not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]},"security":[{"BearerAuth":[]}]},"delete":{"tags":["Custom Models"],"summary":"Delete a model","description":"Delete a custom model from the namespace.","operationId":"delete_model_v1_namespaces__namespace_id__models__model_id__delete","parameters":[{"name":"namespace_id","in":"path","required":true,"schema":{"type":"string","title":"Namespace Id"}},{"name":"model_id","in":"path","required":true,"schema":{"type":"string","title":"Model Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ModelDeleteResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Model not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/namespaces/{namespace_id}/models/{model_id}/deploy":{"post":{"tags":["Custom Models"],"summary":"Deploy model to Ray object store","description":"Pre-load model weights into the Ray object store for fast access by plugins.\n\nThis operation:\n1. Downloads the model archive from S3\n2. Deserializes weights based on format (safetensors, pytorch, etc.)\n3. Stores weights in Ray object store for zero-copy sharing\n\nAfter deployment, plugins can load the model instantly using:\n```python\nfrom engine.models.loader import load_namespace_model\nweights = load_namespace_model(\"model_id\")\n```\n\n**Note:** This is optional - models are also loaded on-demand when plugins\nfirst request them. Use this endpoint to pre-warm the cache.","operationId":"deploy_model_v1_namespaces__namespace_id__models__model_id__deploy_post","parameters":[{"name":"namespace_id","in":"path","required":true,"schema":{"type":"string","title":"Namespace Id"}},{"name":"model_id","in":"path","required":true,"schema":{"type":"string","title":"Model Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ModelDeployResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Model not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Deployment failed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":"enterprise","requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/buckets":{"post":{"tags":["Buckets"],"summary":"Create Bucket","description":"This endpoint allows you to create a new bucket with a defined schema.\n    A bucket is a collection of objects that conform to the schema.\n    The schema defines the structure and validation rules for objects in the bucket.","operationId":"create_bucket_v1_buckets_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BucketCreateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BucketResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"get":{"tags":["Buckets"],"summary":"List Buckets","description":"List buckets (GET alias for POST /buckets/list), so buckets can be listed the same way as collections, retrievers, and namespaces.","operationId":"list_buckets_get_v1_buckets_get","parameters":[{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Free-text search over bucket names.","title":"Search"},"description":"Free-text search over bucket names."},{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListBucketsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}":{"get":{"tags":["Buckets"],"summary":"Get Bucket","description":"This endpoint retrieves a bucket by its ID.","operationId":"get_bucket_v1_buckets__bucket_identifier__get","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","title":"Bucket Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BucketResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"put":{"tags":["Buckets"],"summary":"Update Bucket","description":"This endpoint allows you to update an existing bucket.\n    You can update the bucket's name, description, and metadata.","operationId":"update_bucket_v1_buckets__bucket_identifier__put","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","title":"Bucket Identifier"}},{"name":"force_schema_break","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Force Schema Break"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BucketUpdateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BucketResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"patch":{"tags":["Buckets"],"summary":"Partially Update Bucket","description":"This endpoint allows you to partially update an existing bucket (PATCH operation).\n    Only provided fields will be updated. At minimum, metadata can always be updated.\n    Immutable fields like bucket_id and timestamps cannot be modified.","operationId":"patch_bucket_v1_buckets__bucket_identifier__patch","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","title":"Bucket Identifier"}},{"name":"force_schema_break","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Force Schema Break"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BucketPatchRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BucketResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"delete":{"tags":["Buckets"],"summary":"Delete Bucket","description":"This endpoint deletes a bucket and all its resources including:\n    - S3 objects and blobs\n    - Running Ray jobs (cancels active batch processing jobs)\n    - Batch processing artifacts\n    - Upload files\n    - Unique key lookups\n    - MongoDB metadata\n\n    The deletion is performed **asynchronously** via a background task.\n    Returns immediately with a task_id that can be polled via GET /v1/tasks/{task_id}.\n\n    **Response**:\n    - `task_id`: Use this to poll deletion status via GET /v1/tasks/{task_id}\n    - `status`: Initial status (PENDING)\n    - `bucket_id`: The bucket being deleted\n    - `bucket_name`: Name of the bucket\n    - `object_count`: Number of objects that will be deleted\n\n    **Polling**:\n    Poll GET /v1/tasks/{task_id} until status is COMPLETED or FAILED.\n    Use exponential backoff (start 1s, max 30s).","operationId":"delete_bucket_v1_buckets__bucket_identifier__delete","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","title":"Bucket Identifier"}},{"name":"force_foreclose","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Force Foreclose"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["delete"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/list":{"post":{"tags":["Buckets"],"summary":"List Buckets","description":"This endpoint lists buckets with pagination, sorting, and filtering options.","operationId":"list_buckets_v1_buckets_list_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListBucketsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListBucketsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_id}/syncs":{"post":{"tags":["Bucket Syncs"],"summary":"Create Sync Configuration","description":"Create a sync configuration for automated storage ingestion.\n\nEstablishes automated synchronization between an external storage provider\nand a Mixpeek bucket. The sync monitors the source path and ingests files\naccording to the specified mode and filters.\n\n**Supported Providers:** google_drive, s3, snowflake, sharepoint, tigris\n\n**Built-in Robustness:**\n- Dead Letter Queue (DLQ): Failed objects tracked with 3 retries\n- Idempotent ingestion: Deduplication prevents duplicate objects\n- Distributed locking: Prevents concurrent sync execution\n- Rate limit handling: Automatic backoff on 429 responses\n- Metrics: Duration, files synced/failed, batches created\n\n**Sync Modes** (the request enum accepts exactly these two):\n- `initial_only`: Single bulk import, then sync stops\n- `continuous`: Polling-based monitoring (``polling_interval_seconds``,\n  max 900)\n\n(Docstring previously advertised ``one_time``/``scheduled``, which the\nenum rejects with a 422 — modes here must match ``SyncCreateRequest``.)","operationId":"create_sync_configuration_v1_buckets__bucket_id__syncs_post","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SyncCreateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SyncConfigurationModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_id}/syncs/list":{"post":{"tags":["Bucket Syncs"],"summary":"List Sync Configurations","description":"List all sync configurations for a bucket with optional filtering.\n\nReturns paginated list of sync configurations with status, metrics, and settings.\nUse filters to find syncs by connection, status, or active state.","operationId":"list_sync_configurations_v1_buckets__bucket_id__syncs_list_post","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}},{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListSyncConfigurationsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SyncListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_id}/syncs/{sync_config_id}":{"get":{"tags":["Bucket Syncs"],"summary":"Get Sync Configuration","description":"Fetch a sync configuration.","operationId":"get_sync_configuration_v1_buckets__bucket_id__syncs__sync_config_id__get","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}},{"name":"sync_config_id","in":"path","required":true,"schema":{"type":"string","title":"Sync Config Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SyncConfigurationModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"patch":{"tags":["Bucket Syncs"],"summary":"Update Sync Configuration","description":"Update a sync configuration.","operationId":"update_sync_configuration_v1_buckets__bucket_id__syncs__sync_config_id__patch","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}},{"name":"sync_config_id","in":"path","required":true,"schema":{"type":"string","title":"Sync Config Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SyncUpdateRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SyncConfigurationModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"delete":{"tags":["Bucket Syncs"],"summary":"Delete Sync Configuration","description":"Delete a sync configuration.","operationId":"delete_sync_configuration_v1_buckets__bucket_id__syncs__sync_config_id__delete","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}},{"name":"sync_config_id","in":"path","required":true,"schema":{"type":"string","title":"Sync Config Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["delete"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_id}/syncs/{sync_config_id}/metrics":{"get":{"tags":["Bucket Syncs"],"summary":"Get Sync Metrics","description":"Operational metrics for a sync in one call.\n\nFolds config totals + health/staleness + the DLQ failure breakdown (grouped\nby normalized error reason) + the most-recent job's throughput into a single\nresponse — so callers can see \"is this sync healthy / is anything backlogged\"\nwithout stitching /jobs and /dlq or reading logs.","operationId":"get_sync_metrics_v1_buckets__bucket_id__syncs__sync_config_id__metrics_get","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}},{"name":"sync_config_id","in":"path","required":true,"schema":{"type":"string","title":"Sync Config Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SyncMetricsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_id}/syncs/{sync_config_id}/pause":{"post":{"tags":["Bucket Syncs"],"summary":"Pause Sync Configuration","description":"Pause a sync configuration.\n\nPauses the sync, preventing new sync jobs from executing.\nRunning jobs will complete but no new jobs will be scheduled.\nThe sync configuration and all settings are preserved.\n\n**Note:** Use POST /resume to reactivate the sync.","operationId":"pause_sync_configuration_v1_buckets__bucket_id__syncs__sync_config_id__pause_post","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}},{"name":"sync_config_id","in":"path","required":true,"schema":{"type":"string","title":"Sync Config Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SyncConfigurationModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_id}/syncs/{sync_config_id}/resume":{"post":{"tags":["Bucket Syncs"],"summary":"Resume Sync Configuration","description":"Resume a paused sync configuration.\n\nReactivates a paused sync, allowing new sync jobs to be scheduled.\nFor continuous syncs, polling will resume at the configured interval.\nThe next sync will be incremental (only files modified since last sync).","operationId":"resume_sync_configuration_v1_buckets__bucket_id__syncs__sync_config_id__resume_post","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}},{"name":"sync_config_id","in":"path","required":true,"schema":{"type":"string","title":"Sync Config Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SyncConfigurationModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_id}/syncs/{sync_config_id}/trigger":{"post":{"tags":["Bucket Syncs"],"summary":"Trigger Sync Configuration","description":"Manually trigger a sync execution.\n\nCreates a sync job and immediately dispatches it for async execution.\nThe sync job processes files from the storage provider and creates objects in the bucket.\n\n**Execution Flow:**\n1. Acquires distributed lock (prevents concurrent runs)\n2. Iterates files from storage provider with configured filters\n3. Creates objects idempotently (skips duplicates)\n4. Failed objects go to Dead Letter Queue (3 retries)\n5. Creates batches for collection processing (100 objects/batch)\n6. Emits metrics and releases lock\n\n**Use Cases:**\n- Test sync configuration after creation\n- Force sync outside of scheduled intervals\n- Re-sync after updating connection credentials\n- Trigger incremental sync (only modified files)\n\n**Returns:** `sync_job_id` to track progress via GET /syncs/{id}","operationId":"trigger_sync_configuration_v1_buckets__bucket_id__syncs__sync_config_id__trigger_post","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}},{"name":"sync_config_id","in":"path","required":true,"schema":{"type":"string","title":"Sync Config Id"}},{"name":"full_sync","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Full Sync"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_id}/syncs/{sync_config_id}/unlock":{"post":{"tags":["Bucket Syncs"],"summary":"Force Unlock Sync Configuration","description":"Force-release a distributed lock on a sync configuration.\n\nUse this when a sync trigger returns 'skipped_already_running' but no sync\nis actually executing (zombie lock from a crashed worker).","operationId":"force_unlock_sync_configuration_v1_buckets__bucket_id__syncs__sync_config_id__unlock_post","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}},{"name":"sync_config_id","in":"path","required":true,"schema":{"type":"string","title":"Sync Config Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_id}/syncs/{sync_config_id}/jobs":{"post":{"tags":["Bucket Syncs"],"summary":"List Sync Jobs","description":"List sync job history for a sync configuration.\n\nReturns paginated job records ordered by most recent first.\nEach job includes status, file counts, timing, and error details.\nUse the optional status filter to find failed or running jobs.","operationId":"list_sync_jobs_v1_buckets__bucket_id__syncs__sync_config_id__jobs_post","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}},{"name":"sync_config_id","in":"path","required":true,"schema":{"type":"string","title":"Sync Config Id"}},{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListSyncJobsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SyncJobListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_id}/syncs/{sync_config_id}/jobs/{sync_job_id}":{"get":{"tags":["Bucket Syncs"],"summary":"Get Sync Job","description":"Get details for a specific sync job.\n\nReturns the full job record including status, file counts,\nstart/completion times, and any error messages.","operationId":"get_sync_job_v1_buckets__bucket_id__syncs__sync_config_id__jobs__sync_job_id__get","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}},{"name":"sync_config_id","in":"path","required":true,"schema":{"type":"string","title":"Sync Config Id"}},{"name":"sync_job_id","in":"path","required":true,"schema":{"type":"string","title":"Sync Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SyncJobModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_id}/syncs/{sync_config_id}/dlq":{"post":{"tags":["Bucket Syncs"],"summary":"List Dlq Entries","description":"List Dead Letter Queue entries for a sync configuration.\n\nReturns objects that failed to sync after all retry attempts.\nEach entry includes the source object ID, error details, retry count,\nand timestamps. Use this to diagnose and resolve sync failures.","operationId":"list_dlq_entries_v1_buckets__bucket_id__syncs__sync_config_id__dlq_post","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}},{"name":"sync_config_id","in":"path","required":true,"schema":{"type":"string","title":"Sync Config Id"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListDLQRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DLQListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_id}/syncs/{sync_config_id}/dlq/requeue":{"post":{"tags":["Bucket Syncs"],"summary":"Requeue Dlq Entries","description":"Return exhausted DLQ entries to the retry path.\n\nThe inverse of bulk-mark-failed. Use after fixing the underlying cause (a\nrestored proxy URL, a storage permission, an upstream outage) to re-drive the\nentries that gave up. Without this, the only way to re-drive a DLQ was to\nlean on natural sync-diff and hope the objects were rediscovered.\n\nResets `max_retries_reached` and `retry_count`, stamps `requeued_at`, and\nclears `disposal_reason` so the retry task does not immediately re-retire the\nentry. Only entries that have EXHAUSTED their retries are touched; anything\nstill retrying is left alone rather than silently granted extra attempts.\n\nOmit `error_types` to requeue everything exhausted for the sync config.","operationId":"requeue_dlq_entries_v1_buckets__bucket_id__syncs__sync_config_id__dlq_requeue_post","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}},{"name":"sync_config_id","in":"path","required":true,"schema":{"type":"string","title":"Sync Config Id"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkRequeueDLQRequest","default":{}}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkRequeueDLQResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_id}/syncs/{sync_config_id}/dlq/bulk-mark-failed":{"post":{"tags":["Bucket Syncs"],"summary":"Bulk Mark Dlq Permanently Failed","description":"Mark DLQ entries as permanently failed by error type.\n\nStops automatic retries for entries matching the specified error types.\nUse this for structurally unrecoverable errors (e.g. missing proxy URLs,\nunsupported file types) that will never succeed on retry.","operationId":"bulk_mark_dlq_permanently_failed_v1_buckets__bucket_id__syncs__sync_config_id__dlq_bulk_mark_failed_post","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}},{"name":"sync_config_id","in":"path","required":true,"schema":{"type":"string","title":"Sync Config Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkMarkDLQRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkMarkDLQResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/objects":{"post":{"tags":["Bucket Objects"],"summary":"Create Object","description":"This endpoint creates a new object in the specified bucket.\n    The object must conform to the bucket's schema.\n\n    **Processing**: By default, objects are created in PENDING status, which\n    means not processed yet, and are processed when a batch that includes them\n    is submitted. An object stays PENDING until that batch run finishes with it;\n    the batch status shows whether it has been submitted. Set the `auto_process=true` query parameter\n    to automatically create a batch and submit it for processing (zero-touch\n    workflow). Sending `auto_process` in the JSON body returns 422, unless the\n    bucket schema declares a field with that name.\n\n    If the bucket has a unique_key configured, the insertion policy determines behavior:\n    - insert: Create only. Fail with 409 Conflict if unique key exists.\n    - update: Update only. Fail with 404 Not Found if unique key doesn't exist.\n    - upsert: Create if new, update if exists (idempotent).\n\n    Policy resolution:\n    1. Use ?policy= query parameter if provided\n    2. Fall back to bucket's default_policy if configured\n    3. Error 400 if neither is specified","operationId":"create_object_v1_buckets__bucket_identifier__objects_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"policy","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Insertion policy for unique key enforcement. Valid values: 'insert', 'update', 'upsert'. Only applies if bucket has unique_key configured. Overrides bucket's default_policy if provided.","examples":["insert","update","upsert"],"title":"Policy"},"description":"Insertion policy for unique key enforcement. Valid values: 'insert', 'update', 'upsert'. Only applies if bucket has unique_key configured. Overrides bucket's default_policy if provided."},{"name":"auto_process","in":"query","required":false,"schema":{"type":"boolean","description":"Automatically create a batch and submit it for processing. When true, the object will be immediately queued for processing without requiring separate batch creation and submission calls. Ideal for onboarding and single-object workflows.","default":false,"title":"Auto Process"},"description":"Automatically create a batch and submit it for processing. When true, the object will be immediately queued for processing without requiring separate batch creation and submission calls. Ideal for onboarding and single-object workflows."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateObjectRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ObjectResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":true,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"get":{"tags":["Bucket Objects"],"summary":"List Objects (GET)","description":"List objects in a bucket via GET with cursor-based pagination. Use POST /list for filtering and sorting.","operationId":"list_objects_get_v1_buckets__bucket_identifier__objects_get","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListObjectsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":true,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/objects/batch":{"post":{"tags":["Bucket Objects"],"summary":"Create Objects in Batch","description":"This endpoint creates multiple new objects in the specified bucket as a batch.\n    Each object must conform to the bucket's schema.\n\n    **Processing**: By default, objects are created in PENDING status, which\n    means not processed yet, and are processed when a batch that includes them\n    is submitted. An object stays PENDING until that batch run finishes with it;\n    the batch status shows whether it has been submitted. Set the `auto_process=true` query parameter\n    to automatically create a processing batch and submit it (zero-touch\n    workflow). Sending `auto_process` in the JSON body, at the top level or in\n    an object, returns 422, unless the bucket schema declares a field with that\n    name inside objects.\n\n    **Partial Success**: This endpoint uses partial success - valid objects are created\n    even if some fail validation. Failed objects are returned separately with error details,\n    allowing you to fix and retry only the failed ones.\n\n    **Response**: Returns both succeeded and failed objects. The batch succeeds (200 OK) as long\n    as at least one object is created. Check the `failed` array for objects that need attention.\n    If EVERY object in the batch failed, the response is 422 instead of 200 -- the body shape is\n    identical (`succeeded: []`, `failed: [...]`), only the status code signals total failure.\n\n    **unique_key buckets**: not supported here yet. If the bucket declares a `unique_key`\n    policy, this endpoint rejects the whole request (422) instead of silently creating\n    duplicates -- use `POST /v1/buckets/{bucket_id}/objects` (singular) per object instead,\n    which enforces it.","operationId":"create_objects_batch_v1_buckets__bucket_identifier__objects_batch_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"auto_process","in":"query","required":false,"schema":{"type":"boolean","description":"Automatically create a batch and submit it for processing. When true, all successfully created objects will be immediately queued for processing without requiring separate batch calls. Ideal for onboarding and bulk upload workflows.","default":false,"title":"Auto Process"},"description":"Automatically create a batch and submit it for processing. When true, all successfully created objects will be immediately queued for processing without requiring separate batch calls. Ideal for onboarding and bulk upload workflows."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateObjectsBatchRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateObjectsBatchResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":true,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/objects/{object_identifier}":{"get":{"tags":["Bucket Objects"],"summary":"Get Object","description":"This endpoint retrieves an object by its ID from the specified bucket.\n\n    **Presigned URLs**: Set `return_presigned_urls=true` query parameter to generate fresh presigned download URLs\n    for all blobs with S3 storage (default: false). URLs are added to each blob's properties as\n    `presigned_url` and expire after 1 hour.\n\n    **Document count**: `document_count` (how many documents this object produced, via vector-store\n    lineage) is computed by default. It fans out to the vector partition, which on a cold/serverless\n    partition can be slow — pass `include_document_count=false` to skip it for latency-sensitive,\n    interactive views (e.g. an object-detail modal) that don't render the count. Even when requested,\n    the count is best-effort and bounded by a deadline: it returns `null` rather than blocking the\n    response if the partition is cold.","operationId":"get_object_v1_buckets__bucket_identifier__objects__object_identifier__get","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"object_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the object.","title":"Object Identifier"},"description":"The unique identifier of the object."},{"name":"return_presigned_urls","in":"query","required":false,"schema":{"type":"boolean","description":"Generate fresh presigned download URLs for all blobs with S3 storage","default":false,"title":"Return Presigned Urls"},"description":"Generate fresh presigned download URLs for all blobs with S3 storage"},{"name":"include_document_count","in":"query","required":false,"schema":{"type":"boolean","description":"Compute document_count via vector-store lineage (default true). Pass false to skip the vector fan-out for latency-sensitive views that don't render the count.","default":true,"title":"Include Document Count"},"description":"Compute document_count via vector-store lineage (default true). Pass false to skip the vector fan-out for latency-sensitive views that don't render the count."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ObjectResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":true,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"put":{"tags":["Bucket Objects"],"summary":"Update Object","description":"This endpoint updates an existing object in the specified bucket.\n    It accepts `key_prefix`, `skip_duplicates` and `metadata`. A `metadata` key the object\n    holds inside its own `metadata` object is updated there; any other key is set at the\n    root of the object. Fields you leave out keep their values. It cannot\n    replace blobs: to change an object's files, delete it and create it again.\n    It does not trigger processing.","operationId":"update_object_v1_buckets__bucket_identifier__objects__object_identifier__put","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"object_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the object.","title":"Object Identifier"},"description":"The unique identifier of the object."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateObjectRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ObjectResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":true,"permissions":["delete"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"patch":{"tags":["Bucket Objects"],"summary":"Partially Update Object","description":"This endpoint partially updates an existing object in the specified bucket (PATCH operation).\n    Send the object's custom fields flat at the root of the body, for example {\"campaign_id\": \"camp_002\"}.\n    Only the fields you send change. `key_prefix` and `skip_duplicates` are also accepted.\n    An object created with a `metadata` object keeps its fields there. Send {\"metadata\": {\"tag\": \"new\"}} to change one of them: the keys you send are set, a key sent as null is removed, and the other keys keep their values.\n    System names such as `status`, `object_id` and `blobs` are reserved and return a 422.\n    It does not trigger processing.","operationId":"patch_object_v1_buckets__bucket_identifier__objects__object_identifier__patch","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"object_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the object.","title":"Object Identifier"},"description":"The unique identifier of the object."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchObjectRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ObjectResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":true,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"delete":{"tags":["Bucket Objects"],"summary":"Delete Object","description":"This endpoint deletes an object from the specified bucket.","operationId":"delete_object_v1_buckets__bucket_identifier__objects__object_identifier__delete","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"object_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the object.","title":"Object Identifier"},"description":"The unique identifier of the object."}],"responses":{"204":{"description":"Successful Response"},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":true,"permissions":["delete"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/objects/bulk-soft-delete":{"post":{"tags":["Bucket Objects"],"summary":"Bulk Soft-Delete Objects","description":"Soft-delete many objects by ID in one call. Records are\n    retained and flipped to a non-active lifecycle state (so retrieval excludes\n    them), with the lifecycle propagated to downstream documents. There is no\n    self-service restore endpoint: clearing the marker is a support action, so\n    treat this as a one-way call. Bucket stats\n    are recomputed once. Designed for large purges (e.g. scoping a synced bucket\n    to a subset) without the per-object webhook/stats storms of single delete.","operationId":"bulk_soft_delete_objects_v1_buckets__bucket_identifier__objects_bulk_soft_delete_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkSoftDeleteRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkSoftDeleteResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":true,"permissions":["delete"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/objects/list":{"post":{"tags":["Bucket Objects"],"summary":"List Objects","description":"This endpoint lists objects in a bucket with cursor-based pagination, filtering, and sorting.\n    Filtering, sorting and field selection go in the JSON request body. Pagination goes in the\n    query string or the body (limit, cursor, offset). Another unknown body key is a 422.\n\n    **Filtering**: `filters` in the body takes a logical operator tree. Use dot notation for\n    metadata fields (for example `metadata.type`).\n\n    **Sorting**: `sort` in the body is one object with a field and a direction\n    - Example: {\"sort\": {\"field\": \"created_at\", \"direction\": \"desc\"}}\n    - Direction: asc (ascending) or desc (descending), defaults to asc\n    - Without `sort`, objects come back in creation order, oldest first\n\n    **Pagination**: Cursor-based for efficient deep pagination\n    - First page: ?limit=100 (omit cursor)\n    - Next pages: ?limit=100&cursor={next_cursor}\n    - Use next_cursor from response to navigate\n    - No limit on pagination depth\n\n    **Total Count**: Optional (expensive operation)\n    - Use ?include_total=true to get total count\n    - Adds 50-200ms to response time\n    - Returns total, page, page_size, total_pages fields in pagination response","operationId":"list_objects_v1_buckets__bucket_identifier__objects_list_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListObjectsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListObjectsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":true,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/objects/aggregate":{"post":{"tags":["Bucket Objects"],"summary":"Aggregate Objects","description":"This endpoint performs aggregation operations on objects in a bucket.\n\n    **Aggregation Framework**: Provides MongoDB-style aggregation operations:\n    - GROUP BY: Group objects by one or more fields\n    - Aggregations: COUNT, SUM, AVG, MIN, MAX, COUNT_DISTINCT, etc.\n    - Date Operations: Truncate or extract date parts for time-series analysis\n    - Filtering: Pre-aggregation filters (WHERE) and post-aggregation filters (HAVING)\n    - Sorting & Limiting: Control result ordering and size\n\n    **Use Cases**:\n    - Count objects by status or category\n    - Calculate daily/monthly upload statistics\n    - Analyze content distribution and trends\n    - Generate reports with multiple metrics\n\n    **Note**: This endpoint works with both MongoDB objects and vector store documents\n    using the same interface. The system automatically selects the appropriate\n    aggregation provider.","operationId":"aggregate_objects_v1_buckets__bucket_identifier__objects_aggregate_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ObjectAggregationRequest","description":"Aggregation configuration specifying grouping, metrics, and filters."}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ObjectAggregationResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":true,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/batches":{"post":{"tags":["Bucket Batches"],"summary":"Create Batch","description":"Create a new batch for grouping bucket objects.","operationId":"create_batch_v1_buckets__bucket_identifier__batches_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"skip_validation","in":"query","required":false,"schema":{"type":"boolean","description":"Skip object existence validation. Use this for large batches (>10k objects) or when you're certain all object IDs are valid. Improves performance significantly.","default":false,"title":"Skip Validation"},"description":"Skip object existence validation. Use this for large batches (>10k objects) or when you're certain all object IDs are valid. Improves performance significantly."},{"name":"auto_submit","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Submit the batch for processing immediately after creation. When false (default) the batch is returned in DRAFT status and the caller must POST /submit separately. Symmetric with the auto_process flag on POST /buckets/{id}/objects, and explicit by design — earlier the only way to auto-submit was via the object endpoint, which made batch lifecycle behaviour non-obvious for callers driving the batch endpoint directly. Accepted here (query) or in the JSON body as {\"auto_submit\": true}; the query parameter wins when both are supplied.","title":"Auto Submit"},"description":"Submit the batch for processing immediately after creation. When false (default) the batch is returned in DRAFT status and the caller must POST /submit separately. Symmetric with the auto_process flag on POST /buckets/{id}/objects, and explicit by design — earlier the only way to auto-submit was via the object endpoint, which made batch lifecycle behaviour non-obvious for callers driving the batch endpoint directly. Accepted here (query) or in the JSON body as {\"auto_submit\": true}; the query parameter wins when both are supplied."},{"name":"trigger_processing","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Deprecated alias of auto_submit (kept for callers taught by older docs/hints). Accepted in query or JSON body; auto_submit wins when both are supplied.","title":"Trigger Processing"},"description":"Deprecated alias of auto_submit (kept for callers taught by older docs/hints). Accepted in query or JSON body; auto_submit wins when both are supplied."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateBatchRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/batches/{batch_id}/objects":{"post":{"tags":["Bucket Batches"],"summary":"Add Objects to Batch","description":"Add objects to an existing batch. The batch must be in 'draft' status.","operationId":"add_objects_to_batch_v1_buckets__bucket_identifier__batches__batch_id__objects_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the batch.","title":"Batch Id"},"description":"The unique identifier of the batch."},{"name":"skip_validation","in":"query","required":false,"schema":{"type":"boolean","description":"Skip object existence validation. Use this for large batches (>10k objects) or when you're certain all object IDs are valid. Improves performance significantly.","default":false,"title":"Skip Validation"},"description":"Skip object existence validation. Use this for large batches (>10k objects) or when you're certain all object IDs are valid. Improves performance significantly."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddObjectsToBatchRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/batches/{batch_id}/estimate-cost":{"post":{"tags":["Bucket Batches"],"summary":"Estimate Batch Cost (pre-flight, dry-run)","description":"Pre-flight estimate of the credits a DRAFT batch will consume on submit, plus how many of its objects were already extracted — so a force/replace re-run that re-pays GPU extraction surfaces its cost BEFORE submitting. Does not consume credits or change the batch's contents/status; it DOES refresh a DRAFT batch's activity timestamp so the draft-TTL reaper grants a fresh grace window while you confirm the cost.","operationId":"estimate_batch_cost_endpoint_v1_buckets__bucket_identifier__batches__batch_id__estimate_cost_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the batch.","title":"Batch Id"},"description":"The unique identifier of the batch."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchCostEstimate"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/batches/{batch_id}/submit":{"post":{"tags":["Bucket Batches"],"summary":"Submit Batch for Processing","description":"Submit a draft batch for asynchronous processing. The batch must be in 'DRAFT' status and contain objects.","operationId":"submit_batch_v1_buckets__bucket_identifier__batches__batch_id__submit_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the batch.","title":"Batch Id"},"description":"The unique identifier of the batch."},{"name":"force","in":"query","required":false,"schema":{"type":"boolean","description":"Bypass the concurrent batch dedup check. Use when you intentionally want to reprocess the same bucket+collection combination while another batch is in flight.","default":false,"title":"Force"},"description":"Bypass the concurrent batch dedup check. Use when you intentionally want to reprocess the same bucket+collection combination while another batch is in flight."}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubmitBatchRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/batches/submit-all":{"post":{"tags":["Bucket Batches"],"summary":"Submit All Draft Batches","description":"Submit all DRAFT batches in this bucket for processing in a single request. Bypasses per-request rate limiting. Each batch is submitted sequentially and subject to the same admission control as individual submit.","operationId":"submit_all_drafts_v1_buckets__bucket_identifier__batches_submit_all_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Submit All Drafts V1 Buckets  Bucket Identifier  Batches Submit All Post"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/batches/bulk-submit":{"post":{"tags":["Bucket Batches"],"summary":"Bulk-submit a whole bucket as N auto-chunked, auto-queued batches","description":"One call that streams the bucket's objects (paginated, de-duplicated), chunks them server-side into `chunk_size`-object batches, and submits each (accept-and-queue). Replaces the client-side chunk loop + cursor pacing — no 409 cursor-overlap, no 5k count-timeout, no manual 429 handling. Poll the returned batch ids / `batch_group_id` for QUEUED -> PROCESSING.","operationId":"bulk_submit_batches_v1_buckets__bucket_identifier__batches_bulk_submit_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The bucket to ingest.","title":"Bucket Identifier"},"description":"The bucket to ingest."}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkSubmitBatchesRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkSubmitBatchesResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/batches/list":{"post":{"tags":["Bucket Batches"],"summary":"List Batches","description":"List batches with pagination and filtering options.","operationId":"list_batches_v1_buckets__bucket_identifier__batches_list_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"description":"Page size. Wins over the body `limit`.","title":"Limit"},"description":"Page size. Wins over the body `limit`."},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"description":"Alias of `limit`.","title":"Page Size"},"description":"Alias of `limit`."},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"description":"Batches to skip. Wins over the body `offset`.","title":"Offset"},"description":"Batches to skip. Wins over the body `offset`."},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"next_cursor from a previous page. Wins over the body.","title":"Cursor"},"description":"next_cursor from a previous page. Wins over the body."}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListBatchesRequest","default":{"offset":0,"limit":100}}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListBatchesResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/batches/{batch_id}":{"get":{"tags":["Bucket Batches"],"summary":"Get Batch Configuration","description":"Retrieve batch configuration and historical data from MongoDB. Status is automatically synchronized from Task API. For real-time monitoring, use GET /v1/tasks/{task_id} (Redis, faster).","operationId":"get_batch_v1_buckets__bucket_identifier__batches__batch_id__get","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the batch.","title":"Batch Id"},"description":"The unique identifier of the batch."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"delete":{"tags":["Bucket Batches"],"summary":"Delete Batch","description":"Delete a batch by its ID.","operationId":"delete_batch_v1_buckets__bucket_identifier__batches__batch_id__delete","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the batch.","title":"Batch Id"},"description":"The unique identifier of the batch."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenericDeleteResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["delete"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"patch":{"tags":["Bucket Batches"],"summary":"Partially Update Batch","description":"This endpoint partially updates a batch (PATCH operation).\n    Only provided fields will be updated. At minimum, metadata can always be updated.\n    Immutable fields like batch_id and timestamps cannot be modified.","operationId":"patch_batch_v1_buckets__bucket_identifier__batches__batch_id__patch","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the batch.","title":"Batch Id"},"description":"The unique identifier of the batch."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchBatchRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/batches/{batch_id}/audit":{"get":{"tags":["Bucket Batches"],"summary":"Tier-completion invariant audit","description":"Returns the per-tier completion accounting for a batch: how many objects were submitted, how many ended up in the per-object success ledger (processed_objects), how many in the per-object failure ledger (failed_documents), how many were skipped, and how many are 'lost' (submitted but absent from both per-object ledgers).\n\nPhase 1 of INGESTION_RELIABILITY_PLAN.md. ``has_lost_objects=true`` is a smoking gun for the row-failure-swallow class of bug — the tier was marked COMPLETED but rows silently went missing. Compare against ``tier_tasks[].audit`` (persisted at completion) to see the snapshot at the time the callback fired.","operationId":"get_batch_audit_v1_buckets__bucket_identifier__batches__batch_id__audit_get","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the batch.","title":"Batch Id"},"description":"The unique identifier of the batch."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/batches/{batch_id}/documents":{"delete":{"tags":["Bucket Batches"],"summary":"Delete Documents Produced by Batch","description":"Delete all documents that were produced by this batch. Useful for cleaning up documents from batches that produced bad data (e.g. null vectors). Only works for terminal batches.","operationId":"delete_batch_documents_v1_buckets__bucket_identifier__batches__batch_id__documents_delete","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the batch.","title":"Batch Id"},"description":"The unique identifier of the batch."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Delete Batch Documents V1 Buckets  Bucket Identifier  Batches  Batch Id  Documents Delete"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["delete"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/batches/{batch_id}/cancel":{"post":{"tags":["Bucket Batches"],"summary":"Cancel Batch","description":"Cancel a submitted/processing batch: cancels Ray job via engine and marks task/batch as CANCELLED.","operationId":"cancel_batch_v1_buckets__bucket_identifier__batches__batch_id__cancel_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the batch.","title":"Batch Id"},"description":"The unique identifier of the batch."},{"name":"reason","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Optional human reason for the cancel, recorded on the batch record for audit.","title":"Reason"},"description":"Optional human reason for the cancel, recorded on the batch record for audit."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/batches/{batch_id}/tiers/{tier_num}/cancel":{"post":{"tags":["Bucket Batches"],"summary":"Cancel Tier","description":"Cancel a single tier within a batch without affecting other tiers. Cancels all Ray jobs and queued work for this tier and marks it CANCELED.","operationId":"cancel_tier_v1_buckets__bucket_identifier__batches__batch_id__tiers__tier_num__cancel_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the batch.","title":"Batch Id"},"description":"The unique identifier of the batch."},{"name":"tier_num","in":"path","required":true,"schema":{"type":"integer","minimum":0,"description":"Zero-based tier number to cancel.","title":"Tier Num"},"description":"Zero-based tier number to cancel."},{"name":"reason","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Optional human reason for the cancel, recorded on the batch record for audit.","title":"Reason"},"description":"Optional human reason for the cancel, recorded on the batch record for audit."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Cancel Tier V1 Buckets  Bucket Identifier  Batches  Batch Id  Tiers  Tier Num  Cancel Post"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/batches/{batch_id}/tiers/{tier_num}/jobs/{ray_job_id}/cancel":{"post":{"tags":["Bucket Batches"],"summary":"Cancel Job","description":"Cancel a single Ray job within a tier without affecting sibling jobs.","operationId":"cancel_job_v1_buckets__bucket_identifier__batches__batch_id__tiers__tier_num__jobs__ray_job_id__cancel_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the batch.","title":"Batch Id"},"description":"The unique identifier of the batch."},{"name":"tier_num","in":"path","required":true,"schema":{"type":"integer","minimum":0,"description":"Zero-based tier number.","title":"Tier Num"},"description":"Zero-based tier number."},{"name":"ray_job_id","in":"path","required":true,"schema":{"type":"string","description":"Ray job ID to cancel.","title":"Ray Job Id"},"description":"Ray job ID to cancel."},{"name":"reason","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Optional human reason for the cancel, recorded on the batch record for audit.","title":"Reason"},"description":"Optional human reason for the cancel, recorded on the batch record for audit."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Cancel Job V1 Buckets  Bucket Identifier  Batches  Batch Id  Tiers  Tier Num  Jobs  Ray Job Id  Cancel Post"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/batches/{batch_id}/tiers/{tier_num}/retry":{"post":{"tags":["Bucket Batches"],"summary":"Retry Tier with Resource Overrides","description":"Retry a failed or canceled tier, optionally with modified resource parameters. Useful for retrying OOM failures with more memory.","operationId":"retry_tier_v1_buckets__bucket_identifier__batches__batch_id__tiers__tier_num__retry_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the batch.","title":"Batch Id"},"description":"The unique identifier of the batch."},{"name":"tier_num","in":"path","required":true,"schema":{"type":"integer","minimum":0,"description":"Zero-based tier number to retry.","title":"Tier Num"},"description":"Zero-based tier number to retry."}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"type":"object","additionalProperties":true},{"type":"null"}],"description":"Resource overrides: {requires_gpu, priority}.","examples":[{"requires_gpu":true,"priority":50}],"title":"Resource Overrides"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Retry Tier V1 Buckets  Bucket Identifier  Batches  Batch Id  Tiers  Tier Num  Retry Post"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/batches/{batch_id}/tiers/{tier_num}/heal":{"post":{"tags":["Bucket Batches"],"summary":"Manual Self-Healing","description":"Trigger a self-healing action on a tier: kill duplicate jobs, detect stuck jobs, sync extractor status, or check the circuit breaker.","operationId":"heal_tier_v1_buckets__bucket_identifier__batches__batch_id__tiers__tier_num__heal_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the batch.","title":"Batch Id"},"description":"The unique identifier of the batch."},{"name":"tier_num","in":"path","required":true,"schema":{"type":"integer","minimum":0,"description":"Zero-based tier number.","title":"Tier Num"},"description":"Zero-based tier number."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Body_heal_tier_v1_buckets__bucket_identifier__batches__batch_id__tiers__tier_num__heal_post"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Heal Tier V1 Buckets  Bucket Identifier  Batches  Batch Id  Tiers  Tier Num  Heal Post"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/batches/{batch_id}/diagnose":{"get":{"tags":["Bucket Batches"],"summary":"Diagnose Batch","description":"Aggregate diagnostic information for a batch: status, timing, errors, infrastructure events, progress, failed documents, and recommendations.","operationId":"diagnose_batch_v1_buckets__bucket_identifier__batches__batch_id__diagnose_get","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the batch.","title":"Batch Id"},"description":"The unique identifier of the batch."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Diagnose Batch V1 Buckets  Bucket Identifier  Batches  Batch Id  Diagnose Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/batches/{batch_id}/failed-documents":{"get":{"tags":["Bucket Batches"],"summary":"Get Failed Documents for Batch","description":"Retrieve failed documents for a batch, optionally filtered by tier or collection.","operationId":"get_failed_documents_v1_buckets__bucket_identifier__batches__batch_id__failed_documents_get","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the batch.","title":"Batch Id"},"description":"The unique identifier of the batch."},{"name":"tier_num","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Tier Num"}},{"name":"collection_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Collection Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Offset"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Failed Documents V1 Buckets  Bucket Identifier  Batches  Batch Id  Failed Documents Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/batches/{batch_id}/retry":{"post":{"tags":["Bucket Batches"],"summary":"Retry Failed Documents","description":"Retry failed documents in a batch with intelligent filtering by error type and tier.","operationId":"retry_batch_v1_buckets__bucket_identifier__batches__batch_id__retry_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the batch.","title":"Batch Id"},"description":"The unique identifier of the batch."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RetryBatchRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Retry Batch V1 Buckets  Bucket Identifier  Batches  Batch Id  Retry Post"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/batches/{batch_id}/resubmit":{"post":{"tags":["Bucket Batches"],"summary":"Resubmit Failed Batch","description":"Re-run a terminal (FAILED/CANCELED/COMPLETED/…) batch: resets it to DRAFT and auto-submits by default, so the verb matches the behavior. Pass auto_submit=false to only park it as DRAFT — it must then be submitted manually before the draft TTL expires.","operationId":"resubmit_batch_v1_buckets__bucket_identifier__batches__batch_id__resubmit_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the batch.","title":"Batch Id"},"description":"The unique identifier of the batch."},{"name":"from_tier","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"description":"Resubmit starting from this tier number (0-indexed). Tiers before from_tier are preserved as COMPLETED. Omit to resubmit all tiers from scratch.","title":"From Tier"},"description":"Resubmit starting from this tier number (0-indexed). Tiers before from_tier are preserved as COMPLETED. Omit to resubmit all tiers from scratch."},{"name":"auto_submit","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Auto-submit after the DRAFT reset. DEFAULT TRUE — 'resubmit' means re-run the batch, so one call does both. Pass false to only reset to DRAFT (parked; you must POST /submit before the draft TTL expires or the zombie reaper cancels it). Accepted here (query) or in the JSON body as {\"auto_submit\": false}.","title":"Auto Submit"},"description":"Auto-submit after the DRAFT reset. DEFAULT TRUE — 'resubmit' means re-run the batch, so one call does both. Pass false to only reset to DRAFT (parked; you must POST /submit before the draft TTL expires or the zombie reaper cancels it). Accepted here (query) or in the JSON body as {\"auto_submit\": false}."},{"name":"trigger_processing","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Deprecated alias of auto_submit (kept for callers taught by the old submit-endpoint 400 hint). Accepted in query or JSON body; auto_submit wins when both are supplied.","title":"Trigger Processing"},"description":"Deprecated alias of auto_submit (kept for callers taught by the old submit-endpoint 400 hint). Accepted in query or JSON body; auto_submit wins when both are supplied."}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"type":"object","additionalProperties":true},{"type":"null"}],"description":"Optional body; {\"auto_submit\": bool} (or the deprecated {\"trigger_processing\": bool}) is honored.","title":"Body"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Resubmit Batch V1 Buckets  Bucket Identifier  Batches  Batch Id  Resubmit Post"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/batches/{batch_id}/logs":{"get":{"tags":["Bucket Batches"],"summary":"Get Ray Job Logs for Batch","description":"Retrieve Ray job submission logs for a batch's processing tiers. You can get logs for a specific tier or all tiers. User must have access to the batch to retrieve logs.","operationId":"get_batch_logs_v1_buckets__bucket_identifier__batches__batch_id__logs_get","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket.","title":"Bucket Identifier"},"description":"The unique identifier of the bucket."},{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the batch.","title":"Batch Id"},"description":"The unique identifier of the batch."},{"name":"tier_num","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"description":"Optional tier number (0-based). If not provided, returns logs for all tiers.","title":"Tier Num"},"description":"Optional tier number (0-based). If not provided, returns logs for all tiers."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/batches/list":{"post":{"tags":["Batches"],"summary":"List All Batches","description":"List batches across the organization. The X-Namespace header narrows the list to that namespace, exactly like every other namespaced endpoint; omit it for the org-wide view. `namespace_id` in the request body also works (and wins ties when it agrees with the header; a conflicting header + body is a 400). Other body filters: `status`, `bucket_id`, `collection_id`.","operationId":"list_all_batches_v1_batches_list_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"description":"Page size. Wins over the body `limit`.","title":"Limit"},"description":"Page size. Wins over the body `limit`."},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"description":"Alias of `limit`.","title":"Page Size"},"description":"Alias of `limit`."},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"description":"Batches to skip. Wins over the body `offset`.","title":"Offset"},"description":"Batches to skip. Wins over the body `offset`."},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"next_cursor from a previous page. Wins over the body.","title":"Cursor"},"description":"next_cursor from a previous page. Wins over the body."}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListBatchesRequest","default":{"offset":0,"limit":100}}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListBatchesResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/batches/queue":{"get":{"tags":["Batches"],"summary":"Batch Queue Status","description":"View the Ray job queue: active jobs, max concurrency, and waiting batches with priorities.","operationId":"get_queue_status_v1_batches_queue_get","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Queue Status V1 Batches Queue Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/batches/{batch_id}/cancel":{"post":{"tags":["Batches"],"summary":"Cancel Batch","description":"Cancel a submitted/processing batch by ID without requiring the bucket_id. Cancels all associated Ray jobs and queued work, releases queue slots, and marks the batch as CANCELLED.","operationId":"cancel_batch_by_id_v1_batches__batch_id__cancel_post","parameters":[{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the batch.","title":"Batch Id"},"description":"The unique identifier of the batch."},{"name":"reason","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Optional human reason for the cancel, recorded on the batch record for audit.","title":"Reason"},"description":"Optional human reason for the cancel, recorded on the batch record for audit."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/batches/{batch_id}":{"get":{"tags":["Batches"],"summary":"Get Batch by ID","description":"Retrieve a single batch by its ID without requiring the bucket_id. Returns full batch details including real-time progress (objects_processed, total_objects, items_per_second, eta_seconds) for in-flight batches.","operationId":"get_batch_by_id_v1_batches__batch_id__get","parameters":[{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the batch.","title":"Batch Id"},"description":"The unique identifier of the batch."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/buckets/{bucket_identifier}/uploads":{"post":{"tags":["Bucket Uploads"],"summary":"Create Upload","description":"Generate a presigned URL for direct S3 upload.\n\n    This endpoint validates all requirements BEFORE generating the presigned URL,\n    ensuring immediate feedback if something is wrong (bucket inactive, quota exceeded, etc.).\n\n    **Duplicate Detection (Enabled by Default)**:\n    - If `file_hash` provided and `skip_duplicates=true`: Checks for existing upload\n    - If duplicate found: Returns existing upload (200 OK) with `is_duplicate=true`\n    - If new file: Returns presigned URL (201 Created) with `is_duplicate=false`\n\n    **Two-Step Flow**:\n    1. Call this endpoint → Get presigned URL\n    2. PUT file to presigned URL → Upload directly to S3\n    3. Call confirm endpoint → Verify upload and create object","operationId":"create_upload_v1_buckets__bucket_identifier__uploads_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket","title":"Bucket Identifier"},"description":"The unique identifier of the bucket"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateUploadRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UploadResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/uploads/{upload_id}":{"get":{"tags":["Bucket Uploads"],"summary":"Get Upload","description":"Retrieve an upload by its ID.\n\n    Use this to check upload status, get S3 key, or retrieve created object_id after confirmation.\n\n    **Presigned URLs**: Set `return_presigned_urls=true` query parameter to generate fresh presigned download URLs (default: false).\n    The presigned URLs expire after 1 hour and allow direct download from S3.","operationId":"get_upload_v1_buckets__bucket_identifier__uploads__upload_id__get","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket","title":"Bucket Identifier"},"description":"The unique identifier of the bucket"},{"name":"upload_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the upload","title":"Upload Id"},"description":"The unique identifier of the upload"},{"name":"return_presigned_urls","in":"query","required":false,"schema":{"type":"boolean","description":"Generate fresh presigned download URLs for all blobs with S3 storage","default":false,"title":"Return Presigned Urls"},"description":"Generate fresh presigned download URLs for all blobs with S3 storage"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"delete":{"tags":["Bucket Uploads"],"summary":"Delete Upload","description":"Cancel an upload and optionally delete the S3 object.\n\n    Cannot cancel uploads with status COMPLETED.\n    Can cancel uploads with status: PENDING, IN_PROGRESS, FAILED.","operationId":"delete_upload_v1_buckets__bucket_identifier__uploads__upload_id__delete","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket","title":"Bucket Identifier"},"description":"The unique identifier of the bucket"},{"name":"upload_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the upload","title":"Upload Id"},"description":"The unique identifier of the upload"},{"name":"delete_s3_object","in":"query","required":false,"schema":{"type":"boolean","description":"Whether to delete the S3 object","default":true,"title":"Delete S3 Object"},"description":"Whether to delete the S3 object"}],"responses":{"204":{"description":"Successful Response"},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["delete"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/uploads/list":{"post":{"tags":["Bucket Uploads"],"summary":"List Uploads","description":"List uploads in a bucket with filtering, sorting, search, and pagination.\n\n    **Filtering**: Use LogicalOperator with shorthand syntax\n    - Simple: `{\"status\": \"PENDING\", \"metadata.campaign\": \"summer_2024\"}`\n    - Complex: `{\"AND\": [{\"field\": \"file_size_bytes\", \"operator\": \"gte\", \"value\": 1000000}]}`\n\n    **Sorting**: Specify field and direction\n    - Example: `{\"field\": \"created_at\", \"direction\": \"desc\"}`\n\n    **Search**: Full-text search across filename and metadata\n    - Example: `\"search\": \"video\"`\n\n    **Pagination**: Use limit and offset\n    - Example: `\"limit\": 50, \"offset\": 100`","operationId":"list_uploads_v1_buckets__bucket_identifier__uploads_list_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket","title":"Bucket Identifier"},"description":"The unique identifier of the bucket"},{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListUploadsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListUploadsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/uploads/{upload_id}/confirm":{"post":{"tags":["Bucket Uploads"],"summary":"Confirm Upload","description":"Verify S3 upload completion and create bucket object.\n\n    After uploading to S3 using the presigned URL, call this endpoint to:\n    1. Verify the file exists in S3\n    2. Validate ETag and file size (if provided)\n    3. Create bucket object (default, unless create_object_on_confirm=false)\n    4. Update upload status to COMPLETED\n\n    **Processing**: the created object is PENDING and is not processed by\n    confirmation. Add it to a batch and submit the batch to start processing,\n    or set `auto_submit_batch=true` on this request to create and submit a\n    batch for the new object in the same call.\n\n    **Sync vs Async**:\n    - Files < 100MB: Processed synchronously (~100ms)\n    - Files >= 100MB or async=true: Processed asynchronously (returns task_id)\n\n    **Duplicate Detection**:\n    - If file hash matches existing upload, marks as duplicate\n    - References original object_id if available\n\n    **Unique Keys**:\n    - If the bucket has a unique_key, the object is created under an insertion\n      policy: `?policy=insert|update|upsert` on this request, else the bucket's\n      `unique_key.default_policy`. With neither, confirmation returns 422.","operationId":"confirm_upload_v1_buckets__bucket_identifier__uploads__upload_id__confirm_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket","title":"Bucket Identifier"},"description":"The unique identifier of the bucket"},{"name":"upload_id","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the upload","title":"Upload Id"},"description":"The unique identifier of the upload"},{"name":"async","in":"query","required":false,"schema":{"type":"boolean","description":"Process confirmation asynchronously (recommended for files >= 100MB)","default":false,"title":"Async"},"description":"Process confirmation asynchronously (recommended for files >= 100MB)"},{"name":"policy","in":"query","required":false,"schema":{"anyOf":[{"enum":["insert","update","upsert"],"type":"string"},{"type":"null"}],"description":"Insertion policy for unique key enforcement on the object created at confirmation. Valid values: 'insert', 'update', 'upsert'. Only applies if the bucket has a unique_key. Overrides the bucket's default_policy, matching ?policy= on POST /objects. Required when the bucket has a unique_key and no default_policy.","examples":["insert","update","upsert"],"title":"Policy"},"description":"Insertion policy for unique key enforcement on the object created at confirmation. Valid values: 'insert', 'update', 'upsert'. Only applies if the bucket has a unique_key. Overrides the bucket's default_policy, matching ?policy= on POST /objects. Required when the bucket has a unique_key and no default_policy."}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ConfirmUploadRequest"},{"type":"null"}],"title":"Confirm Request"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfirmUploadResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/uploads/batch":{"post":{"tags":["Bucket Uploads"],"summary":"Batch Create Uploads","description":"Generate multiple presigned URLs in a single request.\n\n    All uploads belong to the same bucket (from path parameter).\n    Maximum 100 uploads per batch.\n\n    Shared metadata is merged with individual upload metadata (individual takes precedence).","operationId":"create_uploads_batch_v1_buckets__bucket_identifier__uploads_batch_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket","title":"Bucket Identifier"},"description":"The unique identifier of the bucket"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchUploadRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchUploadResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/buckets/{bucket_identifier}/uploads/confirm/batch":{"post":{"tags":["Bucket Uploads"],"summary":"Batch Confirm Uploads","description":"Confirm multiple uploads in a single request (processed asynchronously).\n\n    Maximum 100 confirmations per batch.\n    All uploads must belong to the same bucket.\n\n    Returns a task_id to track progress via GET /v1/tasks/{task_id}.","operationId":"confirm_uploads_batch_v1_buckets__bucket_identifier__uploads_confirm_batch_post","parameters":[{"name":"bucket_identifier","in":"path","required":true,"schema":{"type":"string","description":"The unique identifier of the bucket","title":"Bucket Identifier"},"description":"The unique identifier of the bucket"},{"name":"policy","in":"query","required":false,"schema":{"anyOf":[{"enum":["insert","update","upsert"],"type":"string"},{"type":"null"}],"description":"Insertion policy for unique key enforcement on the object created at confirmation. Valid values: 'insert', 'update', 'upsert'. Only applies if the bucket has a unique_key. Overrides the bucket's default_policy, matching ?policy= on POST /objects. Required when the bucket has a unique_key and no default_policy.","examples":["insert","update","upsert"],"title":"Policy"},"description":"Insertion policy for unique key enforcement on the object created at confirmation. Valid values: 'insert', 'update', 'upsert'. Only applies if the bucket has a unique_key. Overrides the bucket's default_policy, matching ?policy= on POST /objects. Required when the bucket has a unique_key and no default_policy."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchConfirmRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchConfirmResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/tasks/{task_id}":{"delete":{"tags":["Tasks"],"summary":"Kill Task","description":"Kill a task (idempotent - succeeds even if task doesn't exist or is already killed).","operationId":"kill_task_v1_tasks__task_id__delete","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenericDeleteResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["delete"]},"security":[{"BearerAuth":[]}]},"get":{"tags":["Tasks"],"summary":"Get Task Information","description":"Retrieve a task by its ID.\n\n    A task may have an expiration time, after which it will still be returned but marked as expired.\n    This allows tracking of historical tasks while indicating their current validity state.","operationId":"get_task_v1_tasks__task_id__get","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/tasks/list":{"post":{"tags":["Tasks"],"summary":"List Tasks","description":"List tasks with optional filtering, sorting, and pagination.\n\n    **Filter Options**:\n    - `status`: Filter by specific status (PENDING, IN_PROGRESS, COMPLETED, FAILED, etc.)\n    - `task_type`: Filter by task type\n    - `filters`: AND/OR/NOT conditions on any task field, for example\n      `{\"AND\": [{\"field\": \"task_id\", \"operator\": \"eq\", \"value\": \"<task_id>\"}]}`\n    - `search`: case-insensitive text matched against task_id, task_type and status\n    - `sort`: `{\"field\": \"created_at\", \"direction\": \"desc\"}`\n\n    **Examples**:\n    - All tasks: `{}`\n    - Failed tasks only: `{\"status\": \"FAILED\"}`\n    - Pending batches: `{\"status\": \"PENDING\", \"task_type\": \"API_BUCKETS_UPLOADS_BATCH_CONFIRM\"}`\n    - In-progress tasks: `{\"status\": \"IN_PROGRESS\"}`","operationId":"list_tasks_v1_tasks_list_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTasksRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTasksResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/webhooks":{"post":{"tags":["Webhooks"],"summary":"Create Webhook","description":"Create a new webhook for the user's organization.","operationId":"create_webhook_v1_organizations_webhooks_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Webhook-Input"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Webhook-Output"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/webhooks/list":{"post":{"tags":["Webhooks"],"summary":"List Webhooks","description":"List all webhooks for the user's organization.","operationId":"list_webhooks_v1_organizations_webhooks_list_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListWebhooksRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListWebhooksResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/webhooks/{identifier}":{"get":{"tags":["Webhooks"],"summary":"Get Webhook","description":"Get a single webhook by its ID.","operationId":"get_webhook_v1_organizations_webhooks__identifier__get","parameters":[{"name":"identifier","in":"path","required":true,"schema":{"type":"string","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Webhook-Output"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]},"put":{"tags":["Webhooks"],"summary":"Update Webhook","description":"Update an existing webhook.","operationId":"update_webhook_v1_organizations_webhooks__identifier__put","parameters":[{"name":"identifier","in":"path","required":true,"schema":{"type":"string","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Webhook-Input"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Webhook-Output"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]},"delete":{"tags":["Webhooks"],"summary":"Delete Webhook","description":"Delete a webhook (idempotent - succeeds even if already deleted).","operationId":"delete_webhook_v1_organizations_webhooks__identifier__delete","parameters":[{"name":"identifier","in":"path","required":true,"schema":{"type":"string","title":"Identifier"}}],"responses":{"204":{"description":"Successful Response"},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["delete"]},"security":[{"BearerAuth":[]}]}},"/v1/notifications/list":{"post":{"tags":["Notifications"],"summary":"List Notifications","description":"List all notifications for the user's organization.","operationId":"list_notifications_v1_notifications_list_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListNotificationsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListNotificationsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/notifications/read/all":{"post":{"tags":["Notifications"],"summary":"Mark All As Read","description":"Mark all notifications as read for a user.","operationId":"mark_all_as_read_v1_notifications_read_all_post","parameters":[],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarkAsReadRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/notifications/preferences":{"get":{"tags":["Notifications"],"summary":"Get Preferences","description":"Get notification preferences for the organization.","operationId":"get_preferences_v1_notifications_preferences_get","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Preferences V1 Notifications Preferences Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}},"put":{"tags":["Notifications"],"summary":"Update Preferences","description":"Update notification preferences for the organization.","operationId":"update_preferences_v1_notifications_preferences_put","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdatePreferencesRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Update Preferences V1 Notifications Preferences Put"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/notifications/unread/count":{"get":{"tags":["Notifications"],"summary":"Get Unread Count","description":"Get count of unread notifications.","operationId":"get_unread_count_v1_notifications_unread_count_get","parameters":[{"name":"user_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Unread Count V1 Notifications Unread Count Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/notifications/{notification_id}":{"get":{"tags":["Notifications"],"summary":"Get Notification","description":"Get a single notification by its ID.","operationId":"get_notification_v1_notifications__notification_id__get","parameters":[{"name":"notification_id","in":"path","required":true,"schema":{"type":"string","title":"Notification Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Notification"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}},"delete":{"tags":["Notifications"],"summary":"Delete Notification","description":"Delete a notification (idempotent - succeeds even if already deleted).","operationId":"delete_notification_v1_notifications__notification_id__delete","parameters":[{"name":"notification_id","in":"path","required":true,"schema":{"type":"string","title":"Notification Id"}}],"responses":{"204":{"description":"Successful Response"},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/notifications/{notification_id}/read":{"post":{"tags":["Notifications"],"summary":"Mark As Read","description":"Mark a notification as read.","operationId":"mark_as_read_v1_notifications__notification_id__read_post","parameters":[{"name":"notification_id","in":"path","required":true,"schema":{"type":"string","title":"Notification Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Notification"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/notifications/preferences/reminders":{"get":{"tags":["Notifications"],"summary":"Get Reminder Preferences","description":"Get reminder/nudge email preferences for the organization.\n\nThese preferences control funnel-based onboarding nudges,\nre-engagement emails, and feature tips.","operationId":"get_reminder_preferences_v1_notifications_preferences_reminders_get","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReminderPreferencesResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}},"put":{"tags":["Notifications"],"summary":"Update Reminder Preferences","description":"Update reminder/nudge email preferences for the organization.\n\nYou can update individual preferences without affecting others:\n- enabled: Master toggle for all reminder emails\n- onboarding_nudges: Funnel progression nudges\n- engagement_reminders: Re-engagement emails for inactivity\n- feature_tips: Helpful tips and inspiration\n- quiet_hours_start/end: Hours (0-23 UTC) when no emails are sent","operationId":"update_reminder_preferences_v1_notifications_preferences_reminders_put","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateReminderPreferencesRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReminderPreferencesResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/notifications/funnel/state":{"get":{"tags":["Notifications"],"summary":"Get Funnel State","description":"Get the current funnel state for the organization.\n\nReturns the user's position in the onboarding funnel, including:\n- Current stage\n- When each stage was reached\n- Nudges that have been sent\n- Last activity timestamp","operationId":"get_funnel_state_v1_notifications_funnel_state_get","parameters":[],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Funnel State V1 Notifications Funnel State Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/notifications/funnel/advance":{"post":{"tags":["Notifications"],"summary":"Advance Funnel Stage","description":"Advance the funnel stage from the client side.\n\nStudio calls this when key milestones happen in-browser that the server\ncannot observe directly (e.g. first_search executed in the test tab).\nAccepts both resource-creation stages and activation funnel stages.\n\n``source`` is optional provenance for the stage being advanced, recorded on\nthe analytics event so a stage reached two different ways can be counted\nseparately. It distinguishes a click on sample data from a real upload, and\na search of a sample retriever from a search of the caller's own data, which\nthe stage name alone cannot. Ignored for resource-creation stages.","operationId":"advance_funnel_stage_v1_notifications_funnel_advance_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Body_advance_funnel_stage_v1_notifications_funnel_advance_post"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Advance Funnel Stage V1 Notifications Funnel Advance Post"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"BearerAuth":[]}],"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":[]}}},"/v1/support/tickets":{"post":{"tags":["Support"],"summary":"Create Support Ticket","operationId":"create_ticket_v1_support_tickets_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTicketRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TicketResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]},"get":{"tags":["Support"],"summary":"List Support Tickets","operationId":"list_tickets_v1_support_tickets_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTicketsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTicketsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/support/tickets/list":{"post":{"tags":["Support"],"summary":"List Support Tickets (org + global).","operationId":"list_tickets_v1_support_tickets_list_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTicketsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTicketsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/support/tickets/{ticket_identifier}":{"get":{"tags":["Support"],"summary":"Get Support Ticket (with message thread).","operationId":"get_ticket_v1_support_tickets__ticket_identifier__get","parameters":[{"name":"ticket_identifier","in":"path","required":true,"schema":{"type":"string","title":"Ticket Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TicketResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]},"patch":{"tags":["Support"],"summary":"Update a support ticket (status/priority).","operationId":"update_ticket_v1_support_tickets__ticket_identifier__patch","parameters":[{"name":"ticket_identifier","in":"path","required":true,"schema":{"type":"string","title":"Ticket Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateTicketRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TicketResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/support/tickets/{ticket_identifier}/messages":{"post":{"tags":["Support"],"summary":"Reply to a support ticket.","operationId":"add_ticket_message_v1_support_tickets__ticket_identifier__messages_post","parameters":[{"name":"ticket_identifier","in":"path","required":true,"schema":{"type":"string","title":"Ticket Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateMessageRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MessageResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/support/comms/list":{"post":{"tags":["Support"],"summary":"List correspondence (ticket messages + broadcasts, org + global).","operationId":"list_comms_v1_support_comms_list_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListCommsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListCommsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/support/comms":{"get":{"tags":["Support"],"summary":"List Correspondence","operationId":"list_comms_v1_support_comms_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListCommsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListCommsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/support/comms/broadcast":{"post":{"tags":["Support"],"summary":"Create a broadcast communication (Mixpeek admin only).","operationId":"create_broadcast_v1_support_comms_broadcast_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateBroadcastRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MessageResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/support/videos/upload-url":{"post":{"tags":["Support"],"summary":"Presigned PUT to upload a support video to cold storage (admin only).","operationId":"create_video_upload_url_v1_support_videos_upload_url_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VideoUploadUrlRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VideoUploadUrlResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]}},"/v1/support/videos":{"post":{"tags":["Support"],"summary":"Register a support video (admin only); triggers Gemini review for uploads.","operationId":"create_video_v1_support_videos_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateVideoRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VideoResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]},"get":{"tags":["Support"],"summary":"List Support Videos","operationId":"list_videos_v1_support_videos_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListVideosRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListVideosResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/support/videos/list":{"post":{"tags":["Support"],"summary":"List curated support videos (org + global).","operationId":"list_videos_v1_support_videos_list_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListVideosRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListVideosResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/support/videos/{video_identifier}":{"get":{"tags":["Support"],"summary":"Get a support video (with presigned playback URL + chapters).","operationId":"get_video_v1_support_videos__video_identifier__get","parameters":[{"name":"video_identifier","in":"path","required":true,"schema":{"type":"string","title":"Video Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VideoResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/taxonomies":{"post":{"tags":["Taxonomies"],"summary":"Create Taxonomy","description":"Create a taxonomy and return the created resource.","operationId":"create_taxonomy_v1_taxonomies_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTaxonomyRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxonomyResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"get":{"tags":["Taxonomies"],"summary":"List taxonomies (GET alias for POST /list).","description":"List taxonomies with optional filters and pagination.","operationId":"list_taxonomies_v1_taxonomies_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTaxonomiesRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTaxonomiesResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/taxonomies/{taxonomy_identifier}":{"get":{"tags":["Taxonomies"],"summary":"Get Taxonomy","description":"Get a taxonomy by ID or name.","operationId":"get_taxonomy_v1_taxonomies__taxonomy_identifier__get","parameters":[{"name":"taxonomy_identifier","in":"path","required":true,"schema":{"type":"string","description":"Taxonomy ID or name","title":"Taxonomy Identifier"},"description":"Taxonomy ID or name"},{"name":"version","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"description":"Optional taxonomy version to fetch","title":"Version"},"description":"Optional taxonomy version to fetch"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxonomyResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"delete":{"tags":["Taxonomies"],"summary":"Delete Taxonomy","description":"This endpoint deletes a taxonomy and all its resources including:\n    - Taxonomy versions (version snapshots)\n    - Taxonomy metadata from MongoDB\n\n    The deletion is performed synchronously and returns when complete.","operationId":"delete_taxonomy_v1_taxonomies__taxonomy_identifier__delete","parameters":[{"name":"taxonomy_identifier","in":"path","required":true,"schema":{"type":"string","description":"Taxonomy ID or name","title":"Taxonomy Identifier"},"description":"Taxonomy ID or name"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["delete"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"patch":{"tags":["Taxonomies"],"summary":"Partially Update Taxonomy","description":"Update a taxonomy's metadata.\n\n    **Metadata Only Updates:**\n    This endpoint allows updating ONLY metadata fields. Core taxonomy logic is immutable\n    to ensure consistency for join history and dependent resources.\n\n    **Fields You CAN Update:**\n    - taxonomy_name: Rename the taxonomy\n    - description: Update documentation\n    - metadata: Update custom metadata\n\n    **Fields You CANNOT Update:**\n    - config: Taxonomy configuration (retriever_id, input_mappings, collections)\n    - taxonomy_type: Type (flat vs hierarchical)\n\n    **Need to Modify Core Logic?**\n    Use POST /{taxonomy_identifier}/clone instead to modify configuration,\n    retriever_id, input_mappings, or collections.","operationId":"patch_taxonomy_v1_taxonomies__taxonomy_identifier__patch","parameters":[{"name":"taxonomy_identifier","in":"path","required":true,"schema":{"type":"string","description":"Taxonomy ID or name","title":"Taxonomy Identifier"},"description":"Taxonomy ID or name"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchTaxonomyRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxonomyResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/taxonomies/{taxonomy_id}/versions":{"post":{"tags":["Taxonomies"],"summary":"Create Taxonomy Version","description":"Create a new version for a taxonomy with a new config snapshot.","operationId":"create_taxonomy_version_v1_taxonomies__taxonomy_id__versions_post","parameters":[{"name":"taxonomy_id","in":"path","required":true,"schema":{"type":"string","description":"Taxonomy ID (tax_...)","title":"Taxonomy Id"},"description":"Taxonomy ID (tax_...)"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxonomyResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"get":{"tags":["Taxonomies"],"summary":"List Taxonomy Versions","description":"List all versions for a taxonomy (head included as latest).","operationId":"list_taxonomy_versions_v1_taxonomies__taxonomy_id__versions_get","parameters":[{"name":"taxonomy_id","in":"path","required":true,"schema":{"type":"string","description":"Taxonomy ID (tax_...)","title":"Taxonomy Id"},"description":"Taxonomy ID (tax_...)"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTaxonomiesResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/taxonomies/{taxonomy_identifier}/clone":{"post":{"tags":["Taxonomies"],"summary":"Clone Taxonomy","description":"Clone a taxonomy with optional modifications.\n\n    **Purpose:**\n    Creates a NEW taxonomy (with new ID) based on an existing one. This is the\n    recommended way to iterate on taxonomy designs when you need to modify core\n    logic that PATCH doesn't allow (config, retriever_id, input_mappings).\n\n    **Clone vs PATCH vs Template:**\n    - **PATCH**: Update metadata only (name, description, metadata)\n    - **Clone**: Copy and modify core logic (config, retriever, collections)\n    - **Template**: Start from a pre-configured pattern (for new projects)\n\n    **Common Use Cases:**\n    - Fix configuration errors without losing join history\n    - Change retriever or input mappings\n    - Modify enrichment fields or collection configuration\n    - Test modifications before replacing production taxonomy\n    - Create variants for different datasets\n\n    **How it works:**\n    1. Source taxonomy is copied\n    2. You provide a new name (REQUIRED)\n    3. Optionally override any other fields (description, config)\n    4. A new taxonomy is created with a new ID\n    5. Original taxonomy remains unchanged","operationId":"clone_taxonomy_v1_taxonomies__taxonomy_identifier__clone_post","parameters":[{"name":"taxonomy_identifier","in":"path","required":true,"schema":{"type":"string","description":"Source taxonomy ID or name to clone.","title":"Taxonomy Identifier"},"description":"Source taxonomy ID or name to clone."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloneTaxonomyRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloneTaxonomyResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/taxonomies/from-documents":{"post":{"tags":["Taxonomies"],"summary":"Create a taxonomy from a document selection or a cluster run (one gesture)","description":"Promote a document selection (e.g. a lasso/cluster selection in the cluster\nvisualization) into a NEW flat taxonomy in one call.\n\nCreates, in order:\n1. a **node collection** mirroring the selection's vector index (same vector\n   name, dimensions, and feature_uri — no re-embedding, no GPU work),\n2. a **vector-search retriever** over it,\n3. the **flat taxonomy** wired to both (input_mappings map an incoming\n   document's stored embedding onto the retriever),\n4. the **nodes**, from one of two sources:\n   - `documents` + `node_label`: one node whose anchor vector is the centroid\n     of the referenced documents' stored vectors;\n   - `cluster_run` (`{cluster_id, run_id}`): one node per cluster in that run,\n     labeled with the cluster's label and anchored on its stored centroid, so\n     a whole cluster run becomes a classifier in one call. The response's\n     `nodes` lists every node created.\n\nDocuments enriched through the taxonomy afterwards are labeled with the\nnearest node's `label`. To add more nodes later, use\n`POST /v1/taxonomies/{taxonomy_id}/nodes/from-documents`.\n\nResources created before a failing step are cleaned up best-effort.","operationId":"create_taxonomy_from_documents_v1_taxonomies_from_documents_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTaxonomyFromDocumentsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxonomyNodeFromDocumentsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/taxonomies/{taxonomy_identifier}/nodes/from-documents":{"post":{"tags":["Taxonomies"],"summary":"Add a taxonomy node derived from a document selection","description":"Add a node to an existing **flat** taxonomy from a document selection.\n\nThe node is an ordinary document in the taxonomy's node (source) collection:\nits anchor vector is the **centroid of the referenced documents' stored\nvectors** and its `label` is `node_label`. Future documents enriched through\nthis taxonomy are labeled with the nearest node's `label`.\n\nOnly stored vectors are read — no re-embedding or GPU work. Documents that\ncan't contribute (missing, no matching vector) are skipped and reported in\n`documents_skipped`; the call fails only when NO document contributes.\n\nHierarchical taxonomies are not supported here (their nodes are whole\ncollections) — the error points you to the flat-taxonomy path.","operationId":"create_taxonomy_node_from_documents_v1_taxonomies__taxonomy_identifier__nodes_from_documents_post","parameters":[{"name":"taxonomy_identifier","in":"path","required":true,"schema":{"type":"string","description":"Taxonomy ID or name","title":"Taxonomy Identifier"},"description":"Taxonomy ID or name"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateNodeFromDocumentsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxonomyNodeFromDocumentsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/taxonomies/list":{"post":{"tags":["Taxonomies"],"summary":"List Taxonomies","description":"List taxonomies with optional filters and pagination.","operationId":"list_taxonomies_v1_taxonomies_list_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTaxonomiesRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTaxonomiesResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/taxonomies/execute/{taxonomy_identifier}":{"post":{"tags":["Taxonomies"],"summary":"Test taxonomy configuration (validation only) — DEPRECATED path","description":"⚠️ VALIDATION ENDPOINT ONLY - Not for production enrichment!\n\nDEPRECATED path shape — prefer POST /taxonomies/{id}/execute (id-first,\nconsistent with retrievers). This verb-first path still works.\n\nThis endpoint validates taxonomy configuration with 1-5 sample documents.\nResults are returned immediately and NOT persisted to any collection.\n\n❌ DO NOT USE FOR:\n- Enriching entire collections (use taxonomy_applications instead)\n- Batch processing documents (automatic during ingestion)\n- Persisting enriched documents (use retriever pipelines instead)\n\n✅ USE THIS FOR:\n- Testing taxonomy configuration is correct\n- Validating retriever finds matching taxonomy nodes\n- Checking enrichment fields are properly applied\n- Development/debugging taxonomy setup\n\n📚 FOR PRODUCTION ENRICHMENT:\n\nAutomatic (during ingestion):\n  1. Create taxonomy: POST /v1/taxonomies\n  2. Attach to collection: PATCH /v1/collections/{id} with taxonomy_applications field\n  3. Ingest documents: Documents are automatically enriched by engine\n\nOn-the-fly (during retrieval):\n  1. Add taxonomy_join stage to retriever pipeline\n  2. Execute retriever: POST /v1/retrievers/{id}/execute\n  3. Results include enriched documents (not persisted)\n\nSee API documentation for Collections and Retrievers for details.","operationId":"execute_taxonomy_v1_taxonomies_execute__taxonomy_identifier__post","deprecated":true,"parameters":[{"name":"taxonomy_identifier","in":"path","required":true,"schema":{"type":"string","description":"Taxonomy ID or name to validate","title":"Taxonomy Identifier"},"description":"Taxonomy ID or name to validate","example":"tax_abc123"},{"name":"version","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"description":"Optional taxonomy version (defaults to latest)","title":"Version"},"description":"Optional taxonomy version (defaults to latest)","example":1}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ExecuteTaxonomyRequest"},{"type":"object","additionalProperties":true}],"title":"Payload"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JoinResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/taxonomies/{taxonomy_identifier}/execute":{"post":{"tags":["Taxonomies"],"summary":"Test taxonomy configuration (validation only)","description":"⚠️ VALIDATION ENDPOINT ONLY - Not for production enrichment!","operationId":"execute_taxonomy_v1_taxonomies__taxonomy_identifier__execute_post","parameters":[{"name":"taxonomy_identifier","in":"path","required":true,"schema":{"type":"string","description":"Taxonomy ID or name to validate","title":"Taxonomy Identifier"},"description":"Taxonomy ID or name to validate","example":"tax_abc123"},{"name":"version","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"description":"Optional taxonomy version (defaults to latest)","title":"Version"},"description":"Optional taxonomy version (defaults to latest)","example":1}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ExecuteTaxonomyRequest"},{"type":"object","additionalProperties":true}],"title":"Payload"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JoinResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/taxonomies/{taxonomy_id}/analytics/transitions":{"post":{"tags":["Taxonomy Analytics"],"summary":"Compute step transition analytics","description":"Analyze how documents progress from one taxonomy step to another.\n\nThis endpoint computes conversion rates, duration statistics, and predictor lifts\nfor documents transitioning between taxonomy labels.\n\n## Use Cases\n\n**Email Thread Analysis:**\n- Question: How long from \"inquiry\" to \"closed_won\"?\n- Question: What % of inquiries result in sales?\n- Question: Which sender domains have highest conversion?\n\n**Content Workflow Tracking:**\n- Question: Conversion rate from \"draft\" to \"published\"?\n- Question: How long does content stay in review?\n- Question: Which authors publish fastest?\n\n**Safety Compliance Monitoring:**\n- Question: Time from violation detection to resolution?\n- Question: Success rate for remediation efforts?\n\n## Requirements\n\n- Taxonomy must have `step_analytics` configured (or provide `override_step_analytics`)\n- Collection must contain documents enriched with this taxonomy\n- Documents must have timestamp and sequence grouping fields configured\n\n## Returns\n\n**Conversion Metrics:**\n- `count`: Total sequences starting at from_step\n- `converted`: Number reaching to_step\n- `conversion_rate`: Percentage that converted\n\n**Duration Statistics (if converted > 0):**\n- `mean`, `median`: Average and middle duration\n- `p90`, `p95`: 90th and 95th percentile durations\n- `std_dev`, `min`, `max`: Distribution statistics\n\n**Top Predictors:**\n- Covariates with highest impact on conversion\n- Lift values (>1.0 = increases conversion, <1.0 = decreases)\n- Statistical significance via minimum support threshold\n\n## Example Request\n\n```json\n{\n    \"collection_id\": \"col_emails\",\n    \"taxonomy_id\": \"tax_sales_stages\",\n    \"from_step\": \"inquiry\",\n    \"to_step\": \"closed_won\",\n    \"max_window_days\": 90,\n    \"min_support\": 10\n}\n```\n\n## Example Response\n\n```json\n{\n    \"from_step\": \"inquiry\",\n    \"to_step\": \"closed_won\",\n    \"count\": 1000,\n    \"converted\": 350,\n    \"conversion_rate\": 0.35,\n    \"durations_sec\": {\n        \"mean\": 432000.0,\n        \"median\": 345600.0,\n        \"p50\": 345600.0,\n        \"p90\": 691200.0,\n        \"p95\": 864000.0\n    },\n    \"top_predictors\": [\n        {\n            \"field\": \"Sender Domain\",\n            \"value\": \"enterprise.com\",\n            \"count\": 150,\n            \"conversion_rate\": 0.75,\n            \"lift\": 2.14\n        }\n    ]\n}\n```","operationId":"compute_step_transitions_v1_taxonomies__taxonomy_id__analytics_transitions_post","parameters":[{"name":"taxonomy_id","in":"path","required":true,"schema":{"type":"string","title":"Taxonomy Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StepTransitionRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StepTransitionResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/taxonomies/{taxonomy_id}/analytics/paths":{"post":{"tags":["Taxonomy Analytics"],"summary":"Analyze multi-step transition paths","description":"Discover the most common multi-step paths documents take between two taxonomy steps.\n\nUnlike the `/transitions` endpoint which only analyzes direct A→B transitions,\nthis endpoint reveals the intermediate steps documents actually take.\n\n## Use Cases\n\n**Email Thread Analysis:**\n- Question: What paths do emails take from \"inquiry\" to \"closed_won\"?\n- Discover: Some go inquiry → followup → proposal → closed_won\n- Discover: Others skip steps: inquiry → proposal → closed_won\n- Discover: Fast track: inquiry → closed_won\n\n**Content Editorial Paths:**\n- Question: Common paths from \"draft\" to \"published\"?\n- Discover: draft → review → edit → review → published\n- Discover: draft → review → published (expedited)\n- Discover: Paths that loop back (draft → review → draft → review)\n\n**Compliance Resolution Paths:**\n- Question: How do violations get resolved?\n- Discover: violation → investigated → remediated → resolved\n- Discover: violation → false_positive → closed\n- Discover: Escalation paths: violation → escalated → legal_review → resolved\n\n## Requirements\n\n- Taxonomy must have `step_analytics` configured\n- Collection must contain documents with timestamp and sequence_id fields\n\n## Returns\n\n**Completion Metrics:**\n- `total_sequences`: Sequences starting at from_step\n- `completed_sequences`: Number reaching to_step\n- `completion_rate`: Percentage that completed\n\n**Paths (sorted by frequency):**\n- `path`: Ordered sequence of steps\n- `count`: Number of sequences following this path\n- `percentage`: Percentage of completing sequences\n- `avg_duration_sec`: Average time for this path\n\n## Example Request\n\n```json\n{\n    \"collection_id\": \"col_emails\",\n    \"taxonomy_id\": \"tax_sales_stages\",\n    \"from_step\": \"inquiry\",\n    \"to_step\": \"closed_won\",\n    \"max_path_length\": 10,\n    \"min_support\": 5\n}\n```\n\n## Example Response\n\n```json\n{\n    \"from_step\": \"inquiry\",\n    \"to_step\": \"closed_won\",\n    \"total_sequences\": 1000,\n    \"completed_sequences\": 350,\n    \"completion_rate\": 0.35,\n    \"paths\": [\n        {\n            \"path\": [\"inquiry\", \"followup\", \"proposal\", \"closed_won\"],\n            \"count\": 120,\n            \"percentage\": 34.3,\n            \"avg_duration_sec\": 604800.0\n        },\n        {\n            \"path\": [\"inquiry\", \"proposal\", \"closed_won\"],\n            \"count\": 90,\n            \"percentage\": 25.7,\n            \"avg_duration_sec\": 432000.0\n        },\n        {\n            \"path\": [\"inquiry\", \"closed_won\"],\n            \"count\": 70,\n            \"percentage\": 20.0,\n            \"avg_duration_sec\": 172800.0\n        }\n    ]\n}\n```\n\n## Path Interpretation\n\n**Length Analysis:**\n- Shorter paths indicate efficient progression\n- Longer paths may indicate complexity or bottlenecks\n- Loops (repeated steps) indicate rework or revisions\n\n**Duration Analysis:**\n- Compare avg_duration_sec across paths\n- Shorter paths may not always be faster\n- Identify optimization opportunities\n\n**Frequency Analysis:**\n- High-percentage paths are \"happy paths\"\n- Low-percentage paths may be edge cases or exceptions\n- Missing expected paths indicate drop-off points","operationId":"analyze_transition_paths_v1_taxonomies__taxonomy_id__analytics_paths_post","parameters":[{"name":"taxonomy_id","in":"path","required":true,"schema":{"type":"string","title":"Taxonomy Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PathAnalysisRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PathAnalysisResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/taxonomies/{taxonomy_id}/analytics/available-steps":{"get":{"tags":["Taxonomy Analytics"],"summary":"Get Available Steps","description":"Get all available steps for a taxonomy and collection.\n\nThis endpoint discovers what steps exist in your analytics data by querying\nthe taxonomy_events analytics collection. Use this before querying transitions\nor paths to understand what step values you can use.\n\n**Use Cases:**\n- Discover available steps before querying analytics\n- Validate step names (avoid typos in from_step/to_step)\n- See which steps have the most events\n- Check data freshness (first_seen/last_seen timestamps)\n\n**Example Usage:**\n```python\n# 1. Get available steps\nGET /v1/taxonomies/tax_sales/analytics/available-steps?collection_id=col_emails\n\n# Response:\n{\n    \"taxonomy_id\": \"tax_sales\",\n    \"collection_id\": \"col_emails\",\n    \"total_events\": 5432,\n    \"total_sequences\": 1000,\n    \"steps\": [\n        {\"step_key\": \"inquiry\", \"event_count\": 1000, ...},\n        {\"step_key\": \"followup\", \"event_count\": 450, ...},\n        {\"step_key\": \"closed_won\", \"event_count\": 350, ...}\n    ]\n}\n\n# 2. Use discovered steps in transition query\nPOST /v1/taxonomies/tax_sales/analytics/transitions\n{\n    \"collection_id\": \"col_emails\",\n    \"from_step\": \"inquiry\",      # From available steps\n    \"to_step\": \"closed_won\"      # From available steps\n}\n```\n\nArgs:\n    request: FastAPI request object (contains tenant context)\n    taxonomy_id: Taxonomy ID to query\n    collection_id: Collection ID for filtering events\n\nReturns:\n    AvailableStepsResponse with all steps sorted by event count (descending)\n\nRaises:\n    NotFoundError: If taxonomy not found\n    ValidationError: If unable to query the analytics store","operationId":"get_available_steps_v1_taxonomies__taxonomy_id__analytics_available_steps_get","parameters":[{"name":"taxonomy_id","in":"path","required":true,"schema":{"type":"string","title":"Taxonomy Id"}},{"name":"collection_id","in":"query","required":true,"schema":{"type":"string","description":"Collection ID to analyze","title":"Collection Id"},"description":"Collection ID to analyze"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AvailableStepsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/taxonomies/{taxonomy_id}/analytics/runs":{"get":{"tags":["Taxonomy Analytics"],"summary":"List taxonomy analytics run history","description":"List previously executed step-analytics runs (transitions and paths) for a taxonomy, newest-executed first. Runs are de-duplicated by their parameters, so re-running the same analysis updates the existing entry and bumps its run_count instead of creating a duplicate.","operationId":"list_analytics_runs_v1_taxonomies__taxonomy_id__analytics_runs_get","parameters":[{"name":"taxonomy_id","in":"path","required":true,"schema":{"type":"string","title":"Taxonomy Id"}},{"name":"analysis_type","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/AnalysisType"},{"type":"null"}],"description":"Filter by analysis type (transitions or paths)","title":"Analysis Type"},"description":"Filter by analysis type (transitions or paths)"},{"name":"collection_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by collection ID","title":"Collection Id"},"description":"Filter by collection ID"},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"description":"Page number (1-indexed)","default":1,"title":"Page"},"description":"Page number (1-indexed)"},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Items per page","default":20,"title":"Page Size"},"description":"Items per page"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxonomyAnalyticsRunListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/taxonomies/{taxonomy_id}/analytics/runs/{run_id}":{"get":{"tags":["Taxonomy Analytics"],"summary":"Get a taxonomy analytics run","description":"Retrieve a single persisted analytics run (its parameters and stored result) so it can be reviewed or re-run.","operationId":"get_analytics_run_v1_taxonomies__taxonomy_id__analytics_runs__run_id__get","parameters":[{"name":"taxonomy_id","in":"path","required":true,"schema":{"type":"string","title":"Taxonomy Id"}},{"name":"run_id","in":"path","required":true,"schema":{"type":"string","title":"Run Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxonomyAnalyticsRun"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/taxonomies/{taxonomy_id}/analytics/runs/{run_id}/rerun":{"post":{"tags":["Taxonomy Analytics"],"summary":"Re-run a stored taxonomy analytics run","description":"Re-execute a previously persisted analytics run using its stored parameters and return the FRESH result. The stored run is updated in place with the new result (run_count is incremented).","operationId":"rerun_analytics_run_v1_taxonomies__taxonomy_id__analytics_runs__run_id__rerun_post","parameters":[{"name":"taxonomy_id","in":"path","required":true,"schema":{"type":"string","title":"Taxonomy Id"}},{"name":"run_id","in":"path","required":true,"schema":{"type":"string","title":"Run Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/StepTransitionResponse"},{"$ref":"#/components/schemas/PathAnalysisResponse"}],"title":"Response Rerun Analytics Run V1 Taxonomies  Taxonomy Id  Analytics Runs  Run Id  Rerun Post"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/alerts":{"post":{"tags":["Alerts"],"summary":"Create Alert","description":"Create a new alert that monitors document ingestion and sends notifications.\n\n    Alerts attach retrievers to collections. When new documents are ingested,\n    the alert runs the retriever and sends notifications if matches are found.\n\n    **Key Components:**\n    - `retriever_id`: References a retriever that defines query logic (filters, scoring, limits)\n    - `notification_config`: Defines where to send notifications (webhook, Slack, email)\n\n    **Note:** The retriever owns all query semantics. The alert's job is simply\n    to run the retriever and notify if results exist.","operationId":"create_alert_v1_alerts_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateAlertRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"get":{"tags":["Alerts"],"summary":"List Alerts (GET alias for POST /list).","description":"List alerts with pagination and filtering.","operationId":"list_alerts_v1_alerts_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListAlertsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListAlertsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/alerts/executions":{"get":{"tags":["Alerts"],"summary":"List All Executions","description":"List execution history for all alerts in the namespace.","operationId":"list_all_executions_v1_alerts_executions_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertExecutionListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/alerts/executions/{execution_id}":{"get":{"tags":["Alerts"],"summary":"Get Alert Execution","description":"Get a single alert execution result by execution ID. Use this to poll for alert results without needing a webhook.","operationId":"get_execution_v1_alerts_executions__execution_id__get","parameters":[{"name":"execution_id","in":"path","required":true,"schema":{"type":"string","description":"Execution ID (exec_...)","title":"Execution Id"},"description":"Execution ID (exec_...)"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertExecutionResult"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/alerts/{alert_identifier}":{"get":{"tags":["Alerts"],"summary":"Get Alert","description":"Get an alert by ID (alt_...) or name.","operationId":"get_alert_v1_alerts__alert_identifier__get","parameters":[{"name":"alert_identifier","in":"path","required":true,"schema":{"type":"string","description":"Alert ID (alt_...) or name","title":"Alert Identifier"},"description":"Alert ID (alt_...) or name"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"patch":{"tags":["Alerts"],"summary":"Update Alert","description":"Partially update an alert's configuration.\n\n    **All fields are optional** - provide only what you want to update.\n\n    Unlike taxonomies, alerts can be fully updated including:\n    - `name`: Rename the alert\n    - `description`: Update documentation\n    - `retriever_id`: Change the retriever\n    - `notification_config`: Update notification channels\n    - `enabled`: Enable/disable the alert\n    - `metadata`: Update custom metadata","operationId":"patch_alert_v1_alerts__alert_identifier__patch","parameters":[{"name":"alert_identifier","in":"path","required":true,"schema":{"type":"string","description":"Alert ID (alt_...) or name","title":"Alert Identifier"},"description":"Alert ID (alt_...) or name"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchAlertRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"delete":{"tags":["Alerts"],"summary":"Delete Alert","description":"Delete an alert and its execution history.\n\n    This operation:\n    - Removes the alert from MongoDB\n    - Deletes all execution history for this alert\n    - Does NOT affect the referenced retriever","operationId":"delete_alert_v1_alerts__alert_identifier__delete","parameters":[{"name":"alert_identifier","in":"path","required":true,"schema":{"type":"string","description":"Alert ID (alt_...) or name","title":"Alert Identifier"},"description":"Alert ID (alt_...) or name"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["delete"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/alerts/list":{"post":{"tags":["Alerts"],"summary":"List Alerts","description":"List all alerts in the namespace with optional filtering and pagination.\n\n    **Filtering:**\n    - Use `search` for wildcard text search across alert_id, name, description\n    - Use `filters` for structured queries\n\n    **Sorting:**\n    - Default: created_at descending (newest first)","operationId":"list_alerts_v1_alerts_list_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListAlertsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListAlertsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/alerts/{alert_identifier}/executions":{"get":{"tags":["Alerts"],"summary":"List Alert Executions","description":"List execution history for a specific alert.","operationId":"list_alert_executions_v1_alerts__alert_identifier__executions_get","parameters":[{"name":"alert_identifier","in":"path","required":true,"schema":{"type":"string","description":"Alert ID (alt_...) or name","title":"Alert Identifier"},"description":"Alert ID (alt_...) or name"},{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertExecutionListResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/alerts/{alert_identifier}/results":{"get":{"tags":["Alerts"],"summary":"Get Latest Alert Result","description":"Get the most recent execution result for an alert. Use this endpoint to poll for alert results without a webhook. Returns the latest execution with match details, or 404 if the alert has never executed.","operationId":"get_latest_result_v1_alerts__alert_identifier__results_get","parameters":[{"name":"alert_identifier","in":"path","required":true,"schema":{"type":"string","description":"Alert ID (alt_...) or name","title":"Alert Identifier"},"description":"Alert ID (alt_...) or name"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertExecutionResult"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/organizations/alerts":{"post":{"tags":["Alerts"],"summary":"Create Org-Scoped Alert","description":"Create an organization-level alert that applies across namespaces via its `namespace_selector` (all or a selected set). Use this for system alerts (collection/batch/retriever health) that should cover the whole org rather than a single namespace.","operationId":"create_org_alert_v1_organizations_alerts_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateAlertRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]},"get":{"tags":["Alerts"],"summary":"List Org-Scoped Alerts (GET alias for POST /list).","description":"List org-scoped alerts with pagination and filtering.","operationId":"list_org_alerts_v1_organizations_alerts_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListAlertsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListAlertsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/alerts/list":{"post":{"tags":["Alerts"],"summary":"List Org-Scoped Alerts","description":"List all organization-level alerts (scoped by internal_id).","operationId":"list_org_alerts_v1_organizations_alerts_list_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListAlertsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListAlertsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]}},"/v1/organizations/alerts/{alert_identifier}":{"get":{"tags":["Alerts"],"summary":"Get Org-Scoped Alert","description":"Get an org-scoped alert by ID (alt_...) or name.","operationId":"get_org_alert_v1_organizations_alerts__alert_identifier__get","parameters":[{"name":"alert_identifier","in":"path","required":true,"schema":{"type":"string","description":"Alert ID (alt_...) or name","title":"Alert Identifier"},"description":"Alert ID (alt_...) or name"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"security":[{"BearerAuth":[]}]},"patch":{"tags":["Alerts"],"summary":"Update Org-Scoped Alert","description":"Partially update an org-scoped alert (e.g. enable/disable, channels).","operationId":"patch_org_alert_v1_organizations_alerts__alert_identifier__patch","parameters":[{"name":"alert_identifier","in":"path","required":true,"schema":{"type":"string","description":"Alert ID (alt_...) or name","title":"Alert Identifier"},"description":"Alert ID (alt_...) or name"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchAlertRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"security":[{"BearerAuth":[]}]},"delete":{"tags":["Alerts"],"summary":"Delete Org-Scoped Alert","description":"Delete an org-scoped alert.","operationId":"delete_org_alert_v1_organizations_alerts__alert_identifier__delete","parameters":[{"name":"alert_identifier","in":"path","required":true,"schema":{"type":"string","description":"Alert ID (alt_...) or name","title":"Alert Identifier"},"description":"Alert ID (alt_...) or name"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["delete"]},"security":[{"BearerAuth":[]}]}},"/v1/annotations":{"post":{"tags":["Annotations"],"summary":"Create Annotation","description":"Record a human decision on a document.","operationId":"create_annotation_v1_annotations_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateAnnotationRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnnotationResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/annotations/list":{"post":{"tags":["Annotations"],"summary":"List Annotations","description":"Query annotations with optional filters.","operationId":"list_annotations_v1_annotations_list_post","parameters":[{"name":"skip","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":500,"minimum":1,"default":50,"title":"Limit"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListAnnotationsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListAnnotationsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/annotations/stats":{"get":{"tags":["Annotations"],"summary":"Annotation Stats","description":"Aggregate annotation counts grouped by label.","operationId":"annotation_stats_v1_annotations_stats_get","parameters":[{"name":"document_id","in":"query","required":false,"schema":{"type":"string","title":"Document Id"}},{"name":"collection_id","in":"query","required":false,"schema":{"type":"string","title":"Collection Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnnotationStatsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/annotations/bulk":{"post":{"tags":["Annotations"],"summary":"Bulk Annotations","description":"Create, update, and/or delete annotations in a single call.\n\nEach operation is independent — a failure in one does not roll back the others.\nMaximum 1000 operations per type (creates, updates, deletes).","operationId":"bulk_annotations_v1_annotations_bulk_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkAnnotationsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkAnnotationsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/annotations/{annotation_id}":{"get":{"tags":["Annotations"],"summary":"Get Annotation","description":"Get a single annotation by ID.","operationId":"get_annotation_v1_annotations__annotation_id__get","parameters":[{"name":"annotation_id","in":"path","required":true,"schema":{"type":"string","title":"Annotation Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnnotationResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"patch":{"tags":["Annotations"],"summary":"Patch Annotation","description":"Update an existing annotation (label, confidence, reasoning, payload).","operationId":"patch_annotation_v1_annotations__annotation_id__patch","parameters":[{"name":"annotation_id","in":"path","required":true,"schema":{"type":"string","title":"Annotation Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchAnnotationRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnnotationResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"delete":{"tags":["Annotations"],"summary":"Delete Annotation","description":"Delete an annotation.","operationId":"delete_annotation_v1_annotations__annotation_id__delete","parameters":[{"name":"annotation_id","in":"path","required":true,"schema":{"type":"string","title":"Annotation Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["delete"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/annotations/{annotation_id}/versions":{"get":{"tags":["Annotations"],"summary":"Get Annotation Versions","description":"Version history of an annotation.\n\nEvery value-changing edit mints a new version; each descriptor names who\nmade the edit, when, and which fields changed. Fetch a specific version's\nfull state at /versions/{version}.","operationId":"get_annotation_versions_v1_annotations__annotation_id__versions_get","parameters":[{"name":"annotation_id","in":"path","required":true,"schema":{"type":"string","title":"Annotation Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnnotationVersionsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/annotations/{annotation_id}/versions/{version}":{"get":{"tags":["Annotations"],"summary":"Get Annotation At Version","description":"The annotation exactly as it stood at a given version.\n\nReproducible evaluation: pin (annotation_id, version) and this route\nreturns the identical judgment later, however many edits followed.","operationId":"get_annotation_at_version_v1_annotations__annotation_id__versions__version__get","parameters":[{"name":"annotation_id","in":"path","required":true,"schema":{"type":"string","title":"Annotation Id"}},{"name":"version","in":"path","required":true,"schema":{"type":"integer","minimum":1,"title":"Version"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnnotationResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/clusters":{"post":{"tags":["Clusters"],"summary":"Create Cluster","description":"Create a new cluster configuration and output collection.\n\n    This endpoint:\n    1. Creates cluster metadata\n    2. Creates output collection for cluster documents\n    3. Returns cluster metadata with output_collection_id\n\n    The cluster can then be executed via POST /v1/clusters/{id}/execute","operationId":"create_cluster_v1_clusters_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateClusterRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClusterMetadata"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"get":{"tags":["Clusters"],"summary":"List Clusters (GET)","description":"REST-convention listing endpoint. Equivalent to ``POST /v1/clusters/list``\n    with no filters or sort. Use the POST variant when you need filters,\n    sort, or search.","operationId":"list_clusters_get_v1_clusters_get","parameters":[{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Search query string","title":"Search"},"description":"Search query string"},{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListClustersResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/clusters/{cluster_id}/execute":{"post":{"tags":["Clusters"],"summary":"Execute Clustering","description":"Execute clustering on a specific cluster.\n\n    This endpoint:\n    1. Validates the cluster exists\n    2. Queues a background clustering job\n    3. Returns task_id immediately (non-blocking)\n    4. The background job prepares data and submits to Engine\n    5. Monitor progress via GET /v1/tasks/{task_id}\n\n    Flow:\n    - API: Receives request\n    - Background job: Fetches documents, creates parquet, uploads to S3\n    - Engine: Runs Ray job on parquet data\n    - Status: Automatically updates cluster when complete\n\n    Use GET /v1/clusters/{id}/executions to retrieve results.\n\n    Optional body (`ExecuteClusterByIdRequest`) accepts a `filters` override\n    that applies to this execution only and is not persisted on the cluster.","operationId":"execute_clustering_v1_clusters__cluster_id__execute_post","parameters":[{"name":"cluster_id","in":"path","required":true,"schema":{"type":"string","description":"Cluster ID to execute","title":"Cluster Id"},"description":"Cluster ID to execute"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExecuteClusterByIdRequest","description":"Optional per-execution overrides (e.g. filter override)."}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/clusters/{cluster_id}/groups":{"get":{"tags":["Clusters"],"summary":"List Cluster Groups","description":"Get all cluster groups with labels, summaries, and document counts from the latest execution.","operationId":"get_cluster_groups_v1_clusters__cluster_id__groups_get","parameters":[{"name":"cluster_id","in":"path","required":true,"schema":{"type":"string","description":"Cluster ID","title":"Cluster Id"},"description":"Cluster ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClusterGroupsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/clusters/{cluster_identifier}":{"get":{"tags":["Clusters"],"summary":"Get Cluster","description":"Retrieve a cluster by ID or name.\n\n    Returns cluster metadata including:\n    - Configuration (cluster_type, algorithm, parameters)\n    - Output collection information (output_collection_ids, output_collection_names)\n    - Execution results (num_clusters, num_documents_clustered, status)\n    - Timestamps and metadata\n\n    Per-document cluster assignments are not on this object. They are documents in\n    the output collections listed in output_collection_ids: a member document\n    (is_centroid=false) carries cluster_id, cluster_label and source_document_id.\n    With enrich_source_collection=true they are fields on your source documents.","operationId":"get_cluster_v1_clusters__cluster_identifier__get","parameters":[{"name":"cluster_identifier","in":"path","required":true,"schema":{"type":"string","description":"Cluster ID or name","title":"Cluster Identifier"},"description":"Cluster ID or name"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClusterMetadata"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"patch":{"tags":["Clusters"],"summary":"Partially Update Cluster","description":"This endpoint partially updates a cluster (PATCH operation).\n    Only provided fields will be updated. At minimum, metadata can always be updated.\n    Immutable fields like cluster_id, status, and computed fields cannot be modified.","operationId":"patch_cluster_v1_clusters__cluster_identifier__patch","parameters":[{"name":"cluster_identifier","in":"path","required":true,"schema":{"type":"string","description":"Cluster ID or name","title":"Cluster Identifier"},"description":"Cluster ID or name"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchClusterRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClusterModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/clusters/{cluster_id}":{"delete":{"tags":["Clusters"],"summary":"Delete Cluster","description":"This endpoint deletes a cluster and all its resources including:\n    - Running Ray jobs (cancels active jobs)\n    - Cluster triggers\n    - Execution history (clustering_results)\n    - S3 artifacts (parquet files, documents, members)\n    - Related tasks\n    - Clustering jobs\n    - MongoDB cluster metadata\n    - Output collections created by the cluster (by default)\n\n    By default, output collections created by the cluster are cascade-deleted\n    along with the cluster. Pass `cascade_output_collections=false` to preserve\n    them (useful when the cluster output documents were enriched / promoted\n    into user-managed data).\n\n    The deletion is performed synchronously and returns when complete.","operationId":"delete_cluster_v1_clusters__cluster_id__delete","parameters":[{"name":"cluster_id","in":"path","required":true,"schema":{"type":"string","description":"Cluster ID","title":"Cluster Id"},"description":"Cluster ID"},{"name":"cascade_output_collections","in":"query","required":false,"schema":{"type":"boolean","description":"When true (default), the cluster's output collections are deleted alongside the cluster. Set to false to preserve them.","default":true,"title":"Cascade Output Collections"},"description":"When true (default), the cluster's output collections are deleted alongside the cluster. Set to false to preserve them."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["delete"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/clusters/list":{"post":{"tags":["Clusters"],"summary":"List Clusters","description":"This endpoint allows you to list clusters.","operationId":"list_clusters_v1_clusters_list_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListClustersRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListClustersResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/clusters/{cluster_id}/visualization":{"get":{"tags":["Clusters"],"summary":"Cluster Visualization Data","description":"Return sampled visualization coordinates for rendering a cluster scatter plot. Returns all centroids plus a random sample of members (default 10,000). Only the fields needed for rendering are returned, keeping the payload small.","operationId":"get_cluster_visualization_v1_clusters__cluster_id__visualization_get","parameters":[{"name":"cluster_id","in":"path","required":true,"schema":{"type":"string","description":"Cluster ID","title":"Cluster Id"},"description":"Cluster ID"},{"name":"max_points","in":"query","required":false,"schema":{"type":"integer","maximum":1000000,"minimum":1,"description":"Max member points to return","default":10000,"title":"Max Points"},"description":"Max member points to return"},{"name":"centroids_only","in":"query","required":false,"schema":{"type":"boolean","description":"Return only centroid points (fast initial load for large clusters)","default":false,"title":"Centroids Only"},"description":"Return only centroid points (fast initial load for large clusters)"},{"name":"compact","in":"query","required":false,"schema":{"type":"boolean","description":"Return members as parallel arrays (x[], y[], z[], cluster_ids[], document_ids[]) instead of array-of-objects. ~60% smaller JSON for large point counts. Centroids are still returned as objects.","default":false,"title":"Compact"},"description":"Return members as parallel arrays (x[], y[], z[], cluster_ids[], document_ids[]) instead of array-of-objects. ~60% smaller JSON for large point counts. Centroids are still returned as objects."},{"name":"run_id","in":"query","required":false,"schema":{"type":"string","description":"Return the scatter for a SPECIFIC run instead of the current one. The output collection only ever holds the latest run's points, so per-run points are served from that run's stored artifact. Used by Studio's run-compare; omit for the current run (default).","title":"Run Id"},"description":"Return the scatter for a SPECIFIC run instead of the current one. The output collection only ever holds the latest run's points, so per-run points are served from that run's stored artifact. Used by Studio's run-compare; omit for the current run (default)."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/clusters/triggers":{"post":{"tags":["Cluster Triggers"],"summary":"Create Cluster Trigger","description":"Create a new trigger for automated cluster execution.\n\n    Supports multiple trigger types:\n    - **cron**: Execute at specific times using cron expressions\n    - **interval**: Execute at fixed intervals\n    - **event**: Execute when specific events occur (e.g., documents added)\n    - **conditional**: Execute when conditions are met (e.g., drift threshold)","operationId":"create_trigger_v1_clusters_triggers_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__clusters__triggers__models__CreateTriggerRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__clusters__triggers__models__TriggerModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/clusters/triggers/list":{"post":{"tags":["Cluster Triggers"],"summary":"List Cluster Triggers","description":"List cluster triggers with filters and pagination.","operationId":"list_triggers_v1_clusters_triggers_list_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__clusters__triggers__models__ListTriggersRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__clusters__triggers__models__ListTriggersResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/clusters/triggers/{trigger_id}":{"get":{"tags":["Cluster Triggers"],"summary":"Get Cluster Trigger","description":"Get a cluster trigger by ID.","operationId":"get_trigger_v1_clusters_triggers__trigger_id__get","parameters":[{"name":"trigger_id","in":"path","required":true,"schema":{"type":"string","description":"Trigger ID","title":"Trigger Id"},"description":"Trigger ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__clusters__triggers__models__TriggerModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"patch":{"tags":["Cluster Triggers"],"summary":"Update Cluster Trigger","description":"Update a cluster trigger.\n\n    Allowed updates:\n    - schedule_config: Modify trigger schedule\n    - description: Update description\n    - status: Change status (use pause/resume endpoints instead)\n\n    Not allowed:\n    - trigger_type: Must delete and recreate\n    - cluster_id: Immutable\n    - execution_config: Immutable","operationId":"update_trigger_v1_clusters_triggers__trigger_id__patch","parameters":[{"name":"trigger_id","in":"path","required":true,"schema":{"type":"string","description":"Trigger ID","title":"Trigger Id"},"description":"Trigger ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__clusters__triggers__models__UpdateTriggerRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__clusters__triggers__models__TriggerModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"delete":{"tags":["Cluster Triggers"],"summary":"Delete Cluster Trigger","description":"Delete a cluster trigger (soft delete).","operationId":"delete_trigger_v1_clusters_triggers__trigger_id__delete","parameters":[{"name":"trigger_id","in":"path","required":true,"schema":{"type":"string","description":"Trigger ID","title":"Trigger Id"},"description":"Trigger ID"}],"responses":{"204":{"description":"Successful Response"},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["delete"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/clusters/triggers/{trigger_id}/pause":{"post":{"tags":["Cluster Triggers"],"summary":"Pause Cluster Trigger","description":"Pause trigger execution. Paused triggers retain configuration but do not execute.","operationId":"pause_trigger_v1_clusters_triggers__trigger_id__pause_post","parameters":[{"name":"trigger_id","in":"path","required":true,"schema":{"type":"string","description":"Trigger ID","title":"Trigger Id"},"description":"Trigger ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__clusters__triggers__models__TriggerModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/clusters/triggers/{trigger_id}/resume":{"post":{"tags":["Cluster Triggers"],"summary":"Resume Cluster Trigger","description":"Resume paused trigger. Next execution time is recalculated from current time.","operationId":"resume_trigger_v1_clusters_triggers__trigger_id__resume_post","parameters":[{"name":"trigger_id","in":"path","required":true,"schema":{"type":"string","description":"Trigger ID","title":"Trigger Id"},"description":"Trigger ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__clusters__triggers__models__TriggerModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/clusters/triggers/{trigger_id}/history":{"post":{"tags":["Cluster Triggers"],"summary":"Get Trigger Execution History","description":"Get execution history for a trigger with pagination.","operationId":"get_trigger_history_v1_clusters_triggers__trigger_id__history_post","parameters":[{"name":"trigger_id","in":"path","required":true,"schema":{"type":"string","description":"Trigger ID","title":"Trigger Id"},"description":"Trigger ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TriggerHistoryRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__clusters__triggers__models__TriggerHistoryResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/clusters/{cluster_id}/executions":{"get":{"tags":["Cluster Executions"],"summary":"Get Latest Cluster Execution","description":"Get the most recent execution results for a cluster.\n\n    The response is a single execution object, not a list, even though the path\n    is plural. A cluster that has never been executed returns 200 with a null\n    body. To list past executions, call\n    POST /v1/clusters/{cluster_id}/executions/list, which returns them under\n    `results`. To read one specific run, call\n    GET /v1/clusters/{cluster_id}/executions/{run_id}.\n\n    Returns execution metadata including:\n    - Execution status (pending, processing, completed, failed)\n    - Clustering metrics (silhouette score, Davies-Bouldin index, etc.)\n    - Number of clusters found and documents processed\n    - Centroid information with labels and summaries\n    - Execution timestamps\n\n    Useful for:\n    - Displaying cluster statistics in dashboards\n    - Showing cluster quality metrics to users\n    - Rendering cluster labels and summaries in the UI\n    - Tracking execution status and errors","operationId":"get_cluster_execution_v1_clusters__cluster_id__executions_get","parameters":[{"name":"cluster_id","in":"path","required":true,"schema":{"type":"string","description":"Cluster ID","title":"Cluster Id"},"description":"Cluster ID"},{"name":"include_vectors","in":"query","required":false,"schema":{"type":"boolean","description":"Include each centroid's embedding vector (centroids[].centroid_vector). Opt-in: vectors are large (~120KB for 15x1024-dim centroids), so they are omitted from the response entirely unless this is true. Lets clients run vector-input searches with a centroid as the query even when the centroid document is no longer in the vector store.","default":false,"title":"Include Vectors"},"description":"Include each centroid's embedding vector (centroids[].centroid_vector). Opt-in: vectors are large (~120KB for 15x1024-dim centroids), so they are omitted from the response entirely unless this is true. Lets clients run vector-input searches with a centroid as the query even when the centroid document is no longer in the vector store."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ClusterExecutionResult"},{"type":"null"}],"title":"Response Get Cluster Execution V1 Clusters  Cluster Id  Executions Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/clusters/{cluster_id}/executions/{run_id}":{"get":{"tags":["Cluster Executions"],"summary":"Get Specific Cluster Execution","description":"Get a specific execution by run ID.\n\n    Returns detailed execution information for a particular clustering run,\n    allowing you to review historical executions and compare results over time.","operationId":"get_cluster_execution_by_run_v1_clusters__cluster_id__executions__run_id__get","parameters":[{"name":"cluster_id","in":"path","required":true,"schema":{"type":"string","description":"Cluster ID","title":"Cluster Id"},"description":"Cluster ID"},{"name":"run_id","in":"path","required":true,"schema":{"type":"string","description":"Run ID","title":"Run Id"},"description":"Run ID"},{"name":"include_vectors","in":"query","required":false,"schema":{"type":"boolean","description":"Include each centroid's embedding vector (centroids[].centroid_vector). Opt-in; see GET /{cluster_id}/executions for details.","default":false,"title":"Include Vectors"},"description":"Include each centroid's embedding vector (centroids[].centroid_vector). Opt-in; see GET /{cluster_id}/executions for details."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClusterExecutionResult"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/clusters/{cluster_id}/executions/list":{"post":{"tags":["Cluster Executions"],"summary":"List Cluster Execution History","description":"List execution history for a cluster with pagination, filtering, sorting, and search.\n\n    Returns all historical executions for the specified cluster, including:\n    - Execution status (pending, processing, completed, failed)\n    - Clustering metrics (silhouette score, Davies-Bouldin index, etc.)\n    - Number of clusters found and documents processed\n    - Execution timestamps and duration\n    - Centroid information\n\n    Supports:\n    - **Filtering**: Filter by status, date range, metrics, etc.\n    - **Sorting**: Sort by created_at, execution time, metrics\n    - **Search**: Full-text search across execution metadata\n    - **Pagination**: Limit and offset for large result sets\n\n    Use cases:\n    - View all past executions for a cluster\n    - Compare metrics across runs\n    - Track execution history over time\n    - Debug failed executions\n    - Analyze clustering performance trends","operationId":"list_cluster_executions_v1_clusters__cluster_id__executions_list_post","parameters":[{"name":"cluster_id","in":"path","required":true,"schema":{"type":"string","description":"Cluster ID","title":"Cluster Id"},"description":"Cluster ID"},{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListClusterExecutionsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListClusterExecutionsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/clusters/{cluster_id}/executions/{run_id}/export":{"get":{"tags":["Cluster Executions"],"summary":"Export Cluster Run Data (CSV / Parquet)","description":"One-click export of a clustering run's data — the exact rows behind the\n    visualization (one row per member plus one per centroid: document id,\n    cluster id and current label, x/y[/z] layout coordinates, per-cluster\n    stats, and any custom LLM fields).\n\n    Formats:\n    - **`format=parquet`** (default): returns JSON with a short-lived\n      presigned download URL for the run's `cluster_documents.parquet`\n      artifact — the full-fidelity file (includes centroid vectors), any\n      size. Download it promptly; the URL expires.\n    - **`format=csv`**: streams a spreadsheet-friendly CSV conversion —\n      stable column order, current (renamed) cluster labels, no raw vectors.\n      Capped at 100,000 rows; bigger runs get a clear 413 pointing to\n      parquet. Scope to one cluster with `cluster_label` (accepts the run's\n      cluster id like `cl_3` OR its current label).\n\n    Exports are strictly per-run: the run you pass is the run you get.\n    Runs that completed before artifacts existed, failed before the export\n    step, or whose artifacts have aged out of object storage return 404\n    with a message saying exactly what's missing.","operationId":"export_cluster_execution_v1_clusters__cluster_id__executions__run_id__export_get","parameters":[{"name":"cluster_id","in":"path","required":true,"schema":{"type":"string","description":"Cluster ID","title":"Cluster Id"},"description":"Cluster ID"},{"name":"run_id","in":"path","required":true,"schema":{"type":"string","description":"Run ID whose data to export","title":"Run Id"},"description":"Run ID whose data to export"},{"name":"format","in":"query","required":false,"schema":{"type":"string","pattern":"^(parquet|csv)$","description":"Export format: 'parquet' returns a presigned download URL (JSON), 'csv' streams the converted file","default":"parquet","title":"Format"},"description":"Export format: 'parquet' returns a presigned download URL (JSON), 'csv' streams the converted file"},{"name":"cluster_label","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"CSV only: restrict rows to one cluster — accepts the run's cluster id (e.g. 'cl_3') or its current label","title":"Cluster Label"},"description":"CSV only: restrict rows to one cluster — accepts the run's cluster id (e.g. 'cl_3') or its current label"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/clusters/{cluster_id}/executions/{run_id}/labels":{"patch":{"tags":["Cluster Executions"],"summary":"Rename Cluster Labels (Per-Execution)","description":"Rename cluster labels for a single execution — no re-run required.\n\n    Entries merge into the execution record's `label_overrides` map\n    (per-key upsert): a non-empty value sets/replaces the override for that\n    cluster_id, an empty string deletes it (restoring the original LLM/auto\n    label). Overrides are applied server-side wherever labels are read —\n    execution GETs (`centroids[].label`) and the cluster visualization\n    endpoint (`cluster_label` on centroid points) — so all clients agree.\n\n    Overrides are per-run because cluster ids (`cl_0`, `cl_1`, ...) are\n    assigned per-run: a rename on one execution never leaks onto another.\n\n    Example body: `{\"labels\": {\"cl_0\": \"Gadget Reviews\", \"cl_2\": \"\"}}`\n    (renames cl_0, deletes any override on cl_2).","operationId":"patch_execution_labels_v1_clusters__cluster_id__executions__run_id__labels_patch","parameters":[{"name":"cluster_id","in":"path","required":true,"schema":{"type":"string","description":"Cluster ID","title":"Cluster Id"},"description":"Cluster ID"},{"name":"run_id","in":"path","required":true,"schema":{"type":"string","description":"Run ID whose labels to rename","title":"Run Id"},"description":"Run ID whose labels to rename"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchExecutionLabelsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchExecutionLabelsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/clusters/{cluster_id}/executions/{run_id}/name":{"patch":{"tags":["Cluster Executions"],"summary":"Name an Execution Run","description":"Set (or clear) a human-friendly name on a single execution run — no\n    re-run required.\n\n    A non-empty value sets/replaces the run's `run_name`; an empty string\n    clears it, restoring the unnamed (run_id-only) state. Names are trimmed\n    and capped at 120 characters. The name is persisted on the execution\n    record and returned by execution GET/LIST responses (`run_name`,\n    omitted entirely while unnamed), so run selectors and execution-history\n    views can show 'July tuning baseline' instead of `run_a8e2709532...`.\n\n    Sibling of PATCH `.../executions/{run_id}/labels`: each display field\n    gets its own strict single-purpose PATCH rather than a general\n    execution PATCH, because execution results themselves are immutable.\n\n    Example body: `{\"run_name\": \"July tuning baseline\"}` (or\n    `{\"run_name\": \"\"}` to clear).","operationId":"patch_execution_run_name_v1_clusters__cluster_id__executions__run_id__name_patch","parameters":[{"name":"cluster_id","in":"path","required":true,"schema":{"type":"string","description":"Cluster ID","title":"Cluster Id"},"description":"Cluster ID"},{"name":"run_id","in":"path","required":true,"schema":{"type":"string","description":"Run ID to name","title":"Run Id"},"description":"Run ID to name"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchExecutionRunNameRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchExecutionRunNameResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/clusters/{cluster_id}/executions/{run_id}/cancel":{"post":{"tags":["Cluster Executions"],"summary":"Cancel Execution","description":"Cancel a pending or processing cluster execution.\n\n    This cancels the Ray job (if running) and marks the execution as CANCELED.\n    Useful for:\n    - Cleaning up orphaned executions where the Ray job was never submitted\n    - Stopping long-running clustering jobs\n    - Handling executions stuck in pending/processing state\n\n    Only works for executions in 'pending' or 'processing' status.\n    Returns an error if the execution is already 'completed', 'failed', or 'canceled'.","operationId":"cancel_execution_v1_clusters__cluster_id__executions__run_id__cancel_post","parameters":[{"name":"cluster_id","in":"path","required":true,"schema":{"type":"string","description":"Cluster ID","title":"Cluster Id"},"description":"Cluster ID"},{"name":"run_id","in":"path","required":true,"schema":{"type":"string","description":"Run ID to cancel","title":"Run Id"},"description":"Run ID to cancel"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/triggers":{"post":{"tags":["Triggers"],"summary":"Create Trigger","description":"Create a new trigger for scheduled job execution.\n\n    **Action Types:**\n    - `cluster`: Execute clustering on a cluster definition\n    - `taxonomy_enrichment`: Apply taxonomy enrichment to a collection\n\n    **Schedule Types:**\n    - `cron`: Execute at specific times using cron expressions (e.g., \"0 2 * * *\" for daily at 2am)\n    - `interval`: Execute at fixed intervals (e.g., every 6 hours)\n    - `event`: Execute when specific events occur (e.g., after 100 documents added)\n    - `conditional`: Execute when conditions are met (e.g., drift threshold exceeded)\n\n    **Examples:**\n\n    Cluster trigger (daily at 2am):\n    ```json\n    {\n      \"action_type\": \"cluster\",\n      \"action_config\": {\"cluster_id\": \"clust_abc123\"},\n      \"trigger_type\": \"cron\",\n      \"schedule_config\": {\"cron_expression\": \"0 2 * * *\", \"timezone\": \"UTC\"},\n      \"description\": \"Daily clustering at 2am\"\n    }\n    ```\n\n    Taxonomy enrichment trigger (every 6 hours):\n    ```json\n    {\n      \"action_type\": \"taxonomy_enrichment\",\n      \"action_config\": {\n        \"taxonomy_id\": \"tax_products\",\n        \"collection_id\": \"col_inventory\",\n        \"batch_size\": 1000\n      },\n      \"trigger_type\": \"interval\",\n      \"schedule_config\": {\"interval_seconds\": 21600},\n      \"description\": \"Re-enrich products every 6 hours\"\n    }\n    ```","operationId":"create_trigger_v1_triggers_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__triggers__models__CreateTriggerRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__triggers__models__TriggerModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"get":{"tags":["Triggers"],"summary":"List Triggers (GET alias for POST /list).","description":"List triggers with filters and pagination.","operationId":"list_triggers_v1_triggers_get","parameters":[],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__triggers__models__ListTriggersRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__triggers__models__ListTriggersResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/triggers/list":{"post":{"tags":["Triggers"],"summary":"List Triggers","description":"List triggers with filters and pagination.\n\n    **Filters:**\n    - `action_type`: Filter by action type (cluster, taxonomy_enrichment)\n    - `trigger_type`: Filter by trigger type (cron, interval, event, conditional)\n    - `status`: Filter by status (active, paused, disabled, failed)\n    - `resource_id`: Filter by resource ID (cluster_id or taxonomy_id)","operationId":"list_triggers_v1_triggers_list_post","parameters":[],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__triggers__models__ListTriggersRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__triggers__models__ListTriggersResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/triggers/{trigger_id}":{"get":{"tags":["Triggers"],"summary":"Get Trigger","description":"Get a trigger by ID.","operationId":"get_trigger_v1_triggers__trigger_id__get","parameters":[{"name":"trigger_id","in":"path","required":true,"schema":{"type":"string","description":"Trigger ID","title":"Trigger Id"},"description":"Trigger ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__triggers__models__TriggerModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"patch":{"tags":["Triggers"],"summary":"Update Trigger","description":"Update a trigger.\n\n    **Allowed updates:**\n    - `schedule_config`: Modify trigger schedule\n    - `description`: Update description\n    - `status`: Change status (prefer using pause/resume endpoints)\n\n    **Not allowed:**\n    - `action_type`: Must delete and recreate\n    - `trigger_type`: Must delete and recreate\n    - `action_config`: Must delete and recreate","operationId":"update_trigger_v1_triggers__trigger_id__patch","parameters":[{"name":"trigger_id","in":"path","required":true,"schema":{"type":"string","description":"Trigger ID","title":"Trigger Id"},"description":"Trigger ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__triggers__models__UpdateTriggerRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__triggers__models__TriggerModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"delete":{"tags":["Triggers"],"summary":"Delete Trigger","description":"Delete a trigger (soft delete - sets status to disabled).","operationId":"delete_trigger_v1_triggers__trigger_id__delete","parameters":[{"name":"trigger_id","in":"path","required":true,"schema":{"type":"string","description":"Trigger ID","title":"Trigger Id"},"description":"Trigger ID"}],"responses":{"204":{"description":"Successful Response"},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["delete"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/triggers/{trigger_id}/pause":{"post":{"tags":["Triggers"],"summary":"Pause Trigger","description":"Pause trigger execution. Paused triggers retain configuration but do not execute.","operationId":"pause_trigger_v1_triggers__trigger_id__pause_post","parameters":[{"name":"trigger_id","in":"path","required":true,"schema":{"type":"string","description":"Trigger ID","title":"Trigger Id"},"description":"Trigger ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__triggers__models__TriggerModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/triggers/{trigger_id}/resume":{"post":{"tags":["Triggers"],"summary":"Resume Trigger","description":"Resume a paused trigger. Next execution time is recalculated from current time.","operationId":"resume_trigger_v1_triggers__trigger_id__resume_post","parameters":[{"name":"trigger_id","in":"path","required":true,"schema":{"type":"string","description":"Trigger ID","title":"Trigger Id"},"description":"Trigger ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__triggers__models__TriggerModel"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/triggers/{trigger_id}/execute":{"post":{"tags":["Triggers"],"summary":"Execute Trigger Now","description":"Manually execute a trigger immediately.\n\n    This bypasses the schedule and executes the trigger's action right away.\n    Useful for testing trigger configuration or forcing immediate execution.\n\n    Returns a task response that can be used to monitor execution progress.","operationId":"execute_trigger_now_v1_triggers__trigger_id__execute_post","parameters":[{"name":"trigger_id","in":"path","required":true,"schema":{"type":"string","description":"Trigger ID","title":"Trigger Id"},"description":"Trigger ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/triggers/{trigger_id}/history":{"get":{"tags":["Triggers"],"summary":"Get Trigger Execution History","description":"Get execution history for a trigger with pagination.","operationId":"get_trigger_history_v1_triggers__trigger_id__history_get","parameters":[{"name":"trigger_id","in":"path","required":true,"schema":{"type":"string","description":"Trigger ID","title":"Trigger Id"},"description":"Trigger ID"},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"description":"Pagination offset","default":0,"title":"Offset"},"description":"Pagination offset"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"description":"Results per page","default":50,"title":"Limit"},"description":"Results per page"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/shared__triggers__models__TriggerHistoryResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/agents/sessions/tools":{"get":{"tags":["Agent Sessions"],"summary":"List Tools","description":"List all available agent tools.\n\nUse this endpoint to discover available tools before creating a session.\n\nTool Categories:\n- search: Tools for searching data (execute_retriever)\n- read: Tools for reading resources (list_*, get_*)\n- create: Tools for creating resources (create_*) - requires confirmation\n- update: Tools for updating resources (update_*) - requires confirmation\n- delete: Tools for deleting resources (delete_*) - requires confirmation\n- upload: Tools for file uploads (upload_object)\n\nNote: Write operations (create, update, delete) require user confirmation\nvia the /confirmations endpoint before execution.\n\nArgs:\n    request: FastAPI request with tenant context\n    category: Optional filter by tool category\n\nReturns:\n    ListToolsResponse with available tools\n\nExample:\n    ```bash\n    # List all tools\n    curl -X GET http://localhost:8000/v1/agents/tools \\\n      -H \"Authorization: Bearer {api_key}\" \\\n      -H \"X-Namespace: {namespace_id}\"\n\n    # List only search tools\n    curl -X GET \"http://localhost:8000/v1/agents/tools?category=search\" \\\n      -H \"Authorization: Bearer {api_key}\" \\\n      -H \"X-Namespace: {namespace_id}\"\n    ```","operationId":"list_tools_v1_agents_sessions_tools_get","parameters":[{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by tool category","title":"Category"},"description":"Filter by tool category"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListToolsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/agents/sessions":{"post":{"tags":["Agent Sessions"],"summary":"Create Session","description":"Create a new agent session.\n\nA session represents a stateful conversation with an AI agent that can\ncall tools to search data, filter results, and perform multi-step reasoning.\n\nArgs:\n    request: FastAPI request with tenant context\n    payload: Session creation request\n\nReturns:\n    CreateSessionResponse with session metadata\n\nExample:\n    ```bash\n    curl -X POST http://localhost:8000/v1/agents/sessions \\\n      -H \"Authorization: Bearer {api_key}\" \\\n      -H \"X-Namespace: {namespace_id}\" \\\n      -H \"Content-Type: application/json\" \\\n      -d '{\n        \"agent_config\": {\n          \"model\": \"claude-3-5-sonnet-20241022\",\n          \"temperature\": 0.7,\n          \"available_tools\": [\"search_retrievers\", \"execute_retriever\"]\n        },\n        \"quotas\": {\n          \"max_messages\": 100,\n          \"max_tokens_total\": 100000\n        }\n      }'\n    ```","operationId":"create_session_v1_agents_sessions_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateSessionRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateSessionResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/agents/sessions/list":{"post":{"tags":["Agent Sessions"],"summary":"List Sessions","description":"List agent sessions in the namespace.\n\nArgs:\n    request: FastAPI request with tenant context\n    list_request: Optional filters and sorting\n    pagination: Pagination parameters\n\nReturns:\n    ListSessionsResponse with session list\n\nExample:\n    ```bash\n    curl -X POST http://localhost:8000/v1/agents/sessions/list \\\n      -H \"Authorization: Bearer {api_key}\" \\\n      -H \"X-Namespace: {namespace_id}\" \\\n      -H \"Content-Type: application/json\" \\\n      -d '{\"status\": \"active\"}'\n    ```","operationId":"list_sessions_v1_agents_sessions_list_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"page_size","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":1000,"minimum":1},{"type":"null"}],"title":"Page Size"}},{"name":"offset","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000,"minimum":0},{"type":"null"}],"title":"Offset"}},{"name":"page","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Page"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"next_cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"After"}},{"name":"include_total","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Total"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListSessionsRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListSessionsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/agents/sessions/{session_id}":{"get":{"tags":["Agent Sessions"],"summary":"Get Session","description":"Get session metadata by ID.\n\nArgs:\n    request: FastAPI request with tenant context\n    session_id: Session identifier\n\nReturns:\n    GetSessionResponse with session metadata\n\nRaises:\n    NotFoundError: If session not found\n\nExample:\n    ```bash\n    curl -X GET http://localhost:8000/v1/agents/sessions/ses_abc123 \\\n      -H \"Authorization: Bearer {api_key}\" \\\n      -H \"X-Namespace: {namespace_id}\"\n    ```","operationId":"get_session_v1_agents_sessions__session_id__get","parameters":[{"name":"session_id","in":"path","required":true,"schema":{"type":"string","description":"Session ID","title":"Session Id"},"description":"Session ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetSessionResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"patch":{"tags":["Agent Sessions"],"summary":"Patch Session","description":"Update session metadata.\n\nOnly user_memory can be updated. To change agent configuration,\ncreate a new session.\n\nArgs:\n    request: FastAPI request with tenant context\n    session_id: Session identifier\n    payload: Update request\n\nReturns:\n    PatchSessionResponse with update timestamp\n\nRaises:\n    NotFoundError: If session not found\n\nExample:\n    ```bash\n    curl -X PATCH http://localhost:8000/v1/agents/sessions/ses_abc123 \\\n      -H \"Authorization: Bearer {api_key}\" \\\n      -H \"X-Namespace: {namespace_id}\" \\\n      -H \"Content-Type: application/json\" \\\n      -d '{\n        \"user_memory\": {\n          \"preferences\": {\"language\": \"en\", \"domain\": \"tech\"}\n        }\n      }'\n    ```","operationId":"patch_session_v1_agents_sessions__session_id__patch","parameters":[{"name":"session_id","in":"path","required":true,"schema":{"type":"string","description":"Session ID","title":"Session Id"},"description":"Session ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchSessionRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchSessionResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]},"delete":{"tags":["Agent Sessions"],"summary":"Terminate Session","description":"Terminate a session and kill its actor.\n\nThis permanently ends the session and releases all associated resources.\n\nArgs:\n    request: FastAPI request with tenant context\n    session_id: Session identifier\n\nReturns:\n    TerminateSessionResponse with termination timestamp\n\nRaises:\n    NotFoundError: If session not found\n\nExample:\n    ```bash\n    curl -X DELETE http://localhost:8000/v1/agents/sessions/ses_abc123 \\\n      -H \"Authorization: Bearer {api_key}\" \\\n      -H \"X-Namespace: {namespace_id}\"\n    ```","operationId":"terminate_session_v1_agents_sessions__session_id__delete","parameters":[{"name":"session_id","in":"path","required":true,"schema":{"type":"string","description":"Session ID","title":"Session Id"},"description":"Session ID"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TerminateSessionResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/agents/sessions/{session_id}/messages":{"post":{"tags":["Agent Sessions"],"summary":"Send Message","description":"Send a message to the agent and stream the response.\n\nThis endpoint streams Server-Sent Events (SSE) back to the client as\nthe agent processes the message through its workflow.\n\n## SSE Event Types\n\n**Core Events:**\n- `intent`: Intent classification result (emitted first)\n    - `{intent, confidence, category, reasoning, context_scope}`\n- `thinking`: Agent is analyzing/planning\n    - `{step, message}`\n- `tool_call`: Agent is calling a tool\n    - `{tool_name, tool_call_id, inputs}`\n- `tool_result`: Tool execution completed\n    - `{tool_name, tool_call_id, success, output, latency_ms}`\n- `token`: Response token (streaming)\n    - `{content}`\n- `message`: Final response content\n    - `{content, message_id, is_final}`\n- `session_name`: Auto-generated session name (first message only)\n    - `{session_name}`\n- `done`: Processing complete\n    - `{latency_ms, tool_calls_made, message_id, retriever_summary, data_accessed_via_retriever}`\n- `error`: Error occurred\n    - `{message, recoverable}`\n\n**Retriever Events (IMPORTANT - Primary Data Pathway):**\n- `retriever_execution`: Retriever was used for data access\n    - `{tool_name, execution_id, retriever_id, is_adhoc, documents_returned, latency_ms, message}`\n    - Emitted whenever data is accessed via retriever (saved or ad-hoc)\n- `pipeline_config`: Ad-hoc retriever configuration\n    - `{tool_name, config, message}`\n    - Contains the exact pipeline config users can save as a named retriever\n\n**Retriever Summary in `done` Event:**\n```json\n{\n  \"retriever_summary\": {\n    \"used_retrievers\": true,\n    \"retriever_count\": 2,\n    \"saved_retrievers\": 1,\n    \"adhoc_retrievers\": 1,\n    \"total_documents\": 25,\n    \"executions\": [...]\n  },\n  \"data_accessed_via_retriever\": true\n}\n```\n\nArgs:\n    request: FastAPI request with tenant context\n    session_id: Session identifier\n    payload: Message request\n\nReturns:\n    StreamingResponse with SSE events\n\nRaises:\n    NotFoundError: If session not found\n\nExample:\n    ```bash\n    curl -N -X POST http://localhost:8000/v1/agents/sessions/ses_abc123/messages \\\n      -H \"Authorization: Bearer {api_key}\" \\\n      -H \"X-Namespace: {namespace_id}\" \\\n      -H \"Content-Type: application/json\" \\\n      -d '{\n        \"content\": \"Find videos about machine learning\",\n        \"stream\": true\n      }'\n\n    # SSE Output:\n    event: intent\n    data: {\"intent\": \"retriever_search\", \"confidence\": 0.92, \"category\": \"retriever\"}\n\n    event: thinking\n    data: {\"step\": \"processing\", \"message\": \"Analyzing your request...\"}\n\n    event: tool_call\n    data: {\"tool_name\": \"execute_retriever\", \"tool_call_id\": \"run_abc\", \"inputs\": {...}}\n\n    event: tool_result\n    data: {\"tool_name\": \"execute_retriever\", \"success\": true, \"output\": {...}}\n\n    event: retriever_execution\n    data: {\"tool_name\": \"execute_retriever\", \"is_adhoc\": false, \"documents_returned\": 5}\n\n    event: message\n    data: {\"content\": \"I found 5 videos about machine learning...\", \"is_final\": true}\n\n    event: done\n    data: {\"latency_ms\": 1250.5, \"data_accessed_via_retriever\": true, \"retriever_summary\": {...}}\n    ```","operationId":"send_message_v1_agents_sessions__session_id__messages_post","parameters":[{"name":"session_id","in":"path","required":true,"schema":{"type":"string","description":"Session ID","title":"Session Id"},"description":"Session ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendMessageRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/agents/sessions/{session_id}/confirmations/{confirmation_id}":{"post":{"tags":["Agent Sessions"],"summary":"Respond To Confirmation","description":"Respond to a pending confirmation for a write operation.\n\nWhen the agent requests a write operation (create, update, delete),\nthe stream pauses and emits a `confirmation_required` event. The user\nmust call this endpoint to approve or deny the action.\n\nAfter responding, this endpoint returns a new SSE stream that continues\nthe agent's execution from where it paused.\n\n## Confirmation Workflow\n\n1. User sends message via POST /sessions/{id}/messages\n2. Agent proposes a write operation\n3. Stream emits `confirmation_required` event with `confirmation_id`\n4. User calls this endpoint with `approved: true/false`\n5. This endpoint returns SSE stream continuing the agent's work\n6. If approved, agent executes the tool and continues\n7. If denied, agent acknowledges and continues without executing\n\n## Confirmation Expiration\n\nConfirmations expire after 5 minutes. Attempting to respond to an\nexpired confirmation returns a 400 error.\n\nArgs:\n    request: FastAPI request with tenant context\n    session_id: Session identifier\n    confirmation_id: Confirmation identifier from `confirmation_required` event\n    payload: Approval/denial decision\n\nReturns:\n    StreamingResponse with SSE events (continuation of agent execution)\n\nRaises:\n    NotFoundError: If session or confirmation not found\n    ValidationError: If confirmation already processed or expired\n\nExample:\n    ```bash\n    # Approve a pending action\n    curl -N -X POST http://localhost:8000/v1/agents/sessions/ses_abc/confirmations/conf_xyz \\\n      -H \"Authorization: Bearer {api_key}\" \\\n      -H \"X-Namespace: {namespace_id}\" \\\n      -H \"Content-Type: application/json\" \\\n      -d '{\"approved\": true}'\n\n    # SSE Output (continuation):\n    event: tool_result\n    data: {\"tool_name\": \"delete_collection\", \"success\": true, \"result\": {...}}\n\n    event: token\n    data: {\"content\": \"I've deleted the collection as requested.\"}\n\n    event: done\n    data: {}\n    ```","operationId":"respond_to_confirmation_v1_agents_sessions__session_id__confirmations__confirmation_id__post","parameters":[{"name":"session_id","in":"path","required":true,"schema":{"type":"string","description":"Session ID","title":"Session Id"},"description":"Session ID"},{"name":"confirmation_id","in":"path","required":true,"schema":{"type":"string","description":"Confirmation ID","title":"Confirmation Id"},"description":"Confirmation ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfirmationRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/agents/sessions/{session_id}/history":{"get":{"tags":["Agent Sessions"],"summary":"Get History","description":"Get conversation history for a session.\n\nReturns messages in chronological order (oldest first).\n\nArgs:\n    request: FastAPI request with tenant context\n    session_id: Session identifier\n    limit: Maximum messages to return (default: 50, max: 200)\n    offset: Pagination offset (default: 0)\n\nReturns:\n    GetHistoryResponse with message history\n\nRaises:\n    NotFoundError: If session not found\n\nExample:\n    ```bash\n    curl -X GET \"http://localhost:8000/v1/agents/sessions/ses_abc123/history?limit=20&offset=0\" \\\n      -H \"Authorization: Bearer {api_key}\" \\\n      -H \"X-Namespace: {namespace_id}\"\n    ```","operationId":"get_history_v1_agents_sessions__session_id__history_get","parameters":[{"name":"session_id","in":"path","required":true,"schema":{"type":"string","description":"Session ID","title":"Session Id"},"description":"Session ID"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"description":"Maximum messages to return","default":50,"title":"Limit"},"description":"Maximum messages to return"},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"description":"Pagination offset","default":0,"title":"Offset"},"description":"Pagination offset"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetHistoryResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/agents/sessions/{session_id}/feedback":{"post":{"tags":["Agent Sessions"],"summary":"Submit Feedback","description":"Submit feedback on an assistant message.\n\nWhen positive feedback is received, the conversation exchange is stored\nto memory for future context. When negative feedback is received, the\nexchange is NOT stored. This enables learning from quality interactions.\n\nArgs:\n    request: FastAPI request with tenant context\n    session_id: Session identifier\n    payload: Feedback request\n\nReturns:\n    SubmitFeedbackResponse with feedback status\n\nRaises:\n    NotFoundError: If session or message not found\n\nExample:\n    ```bash\n    curl -X POST http://localhost:8000/v1/agents/sessions/ses_abc123/feedback \\\n      -H \"Authorization: Bearer {api_key}\" \\\n      -H \"X-Namespace: {namespace_id}\" \\\n      -H \"Content-Type: application/json\" \\\n      -d '{\n        \"message_id\": \"msg_xyz789\",\n        \"rating\": \"positive\",\n        \"feedback_text\": \"Very helpful response!\"\n      }'\n    ```","operationId":"submit_feedback_v1_agents_sessions__session_id__feedback_post","parameters":[{"name":"session_id","in":"path","required":true,"schema":{"type":"string","description":"Session ID","title":"Session Id"},"description":"Session ID"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubmitFeedbackRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubmitFeedbackResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["write"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/agents/sessions/intent/detect":{"post":{"tags":["Agent Sessions"],"summary":"Detect Intent","description":"Detect user intent from natural language request.\n\nThis endpoint analyzes a user's request to determine whether they want to:\n- Execute queries on existing data (execution mode)\n- Create new resources/infrastructure (setup mode)\n- Or if the request is ambiguous and needs clarification\n\nIt performs keyword analysis and checks existing collections to provide\nintelligent classification and recommendations.\n\nArgs:\n    request: FastAPI request with tenant context\n    payload: Intent detection request with user's input\n\nReturns:\n    IntentClassification with detected intent and recommendations\n\nExample:\n    ```bash\n    curl -X POST http://localhost:8000/v1/agents/intent/detect \\\n      -H \"Authorization: Bearer {api_key}\" \\\n      -H \"X-Namespace: {namespace_id}\" \\\n      -H \"Content-Type: application/json\" \\\n      -d '{\n        \"user_request\": \"I want to search videos by faces\",\n        \"include_collection_analysis\": true\n      }'\n    ```","operationId":"detect_intent_v1_agents_sessions_intent_detect_post","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DetectIntentRequest"}}},"description":"Keys this body does not declare are refused with 422 extra_forbidden naming the accepted keys (since 2026-11-02).","x-unknown-keys":{"until":"2026-11-02","then":"422 extra_forbidden"}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntentClassification"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/retrievers/{retriever_id}/performance":{"get":{"tags":["Analytics","Analytics - Retrievers"],"summary":"Get Retriever Performance","description":"Get retriever performance metrics for tuning.\n\nRetrieves time-series performance data including:\n- Query latency (P50, P95, P99)\n- Query counts\n- Result counts\n- Latency trends\n\n**Use Cases:**\n- Monitor retriever performance over time\n- Identify performance degradations\n- Compare performance across time periods\n- Establish performance baselines\n\n**Example:**\n```bash\ncurl -X GET \"https://api.mixpeek.com/v1/analytics/retrievers/ret_abc123/performance?hours=24&group_by=hour\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"X-Namespace: your-namespace\"\n```","operationId":"get_retriever_performance_v1_analytics_retrievers__retriever_id__performance_get","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","title":"Retriever Id"}},{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"Start date (UTC)","title":"Start Date"},"description":"Start date (UTC)"},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"End date (UTC)","title":"End Date"},"description":"End date (UTC)"},{"name":"group_by","in":"query","required":false,"schema":{"type":"string","description":"Time grouping: hour, day, week","default":"hour","title":"Group By"},"description":"Time grouping: hour, day, week"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RetrieverPerformanceResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/retrievers/{retriever_id}/stages":{"get":{"tags":["Analytics","Analytics - Retrievers"],"summary":"Get Stage Breakdown","description":"Get stage-level performance breakdown.\n\nAnalyzes individual stage performance to identify bottlenecks:\n- Stage execution times\n- Document flow (in/out)\n- Stage-level latency distribution\n\n**Use Cases:**\n- Identify slow stages in retrieval pipeline\n- Optimize stage ordering\n- Debug pipeline bottlenecks\n- Understand document reduction rates\n\n**Example:**\n```bash\ncurl -X GET \"https://api.mixpeek.com/v1/analytics/retrievers/ret_abc123/stages?hours=24\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"X-Namespace: your-namespace\"\n```","operationId":"get_stage_breakdown_v1_analytics_retrievers__retriever_id__stages_get","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","title":"Retriever Id"}},{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":720,"minimum":1,"description":"Hours of history","default":24,"title":"Hours"},"description":"Hours of history"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StageBreakdownResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/retrievers/{retriever_id}/signals":{"get":{"tags":["Analytics","Analytics - Retrievers"],"summary":"Get Retriever Signals","description":"Get retriever signals for interaction tuning.\n\nRetrieves fine-grained signals about retriever behavior:\n- Cache hits/misses\n- Reranking scores\n- Filter effectiveness\n- Query expansion results\n\n**Signal Types:**\n- `cache_hit`: Successful cache lookups\n- `cache_miss`: Cache misses requiring full search\n- `rerank_scores`: Reranking effectiveness metrics\n- `filter_reduction`: Pre-filter document reduction\n- `expansion_results`: Query expansion impact\n\n**Use Cases:**\n- Fine-tune retrieval parameters\n- Analyze query patterns\n- Optimize cache strategies\n- Validate optimization improvements\n\n**Example:**\n```bash\ncurl -X GET \"https://api.mixpeek.com/v1/analytics/retrievers/ret_abc123/signals?signal_type=rerank_scores&limit=50\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"X-Namespace: your-namespace\"\n```","operationId":"get_retriever_signals_v1_analytics_retrievers__retriever_id__signals_get","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","title":"Retriever Id"}},{"name":"signal_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by signal type (cache_hit, rerank_scores, etc.)","title":"Signal Type"},"description":"Filter by signal type (cache_hit, rerank_scores, etc.)"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"description":"Maximum results","default":100,"title":"Limit"},"description":"Maximum results"},{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":720,"minimum":1,"description":"Hours of history","default":24,"title":"Hours"},"description":"Hours of history"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/RetrieverSignal"},"title":"Response Get Retriever Signals V1 Analytics Retrievers  Retriever Id  Signals Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/retrievers/{retriever_id}/cache-performance":{"get":{"tags":["Analytics","Analytics - Retrievers"],"summary":"Get Cache Performance","description":"Get cache performance metrics.\n\nAnalyzes cache effectiveness including:\n- Hit/miss rates\n- Latency comparison (cache vs full search)\n- Hourly cache performance trends\n\n**Use Cases:**\n- Evaluate cache effectiveness\n- Optimize cache TTL settings\n- Monitor cache performance\n- Identify cache warming opportunities\n\n**Example:**\n```bash\ncurl -X GET \"https://api.mixpeek.com/v1/analytics/retrievers/ret_abc123/cache-performance?hours=168\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"X-Namespace: your-namespace\"\n```","operationId":"get_cache_performance_v1_analytics_retrievers__retriever_id__cache_performance_get","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","title":"Retriever Id"}},{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":720,"minimum":1,"description":"Hours of history","default":24,"title":"Hours"},"description":"Hours of history"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CachePerformanceResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/retrievers/{retriever_id}/analyze-tuning":{"post":{"tags":["Analytics","Analytics - Retrievers"],"summary":"Analyze For Tuning","description":"Analyze retriever and generate tuning recommendations.\n\nPerforms comprehensive analysis and generates actionable recommendations:\n- Parameter tuning suggestions\n- Cache optimization opportunities\n- Performance improvement estimates\n\n**Recommendations Include:**\n- Increase/decrease k value\n- Adjust reranking thresholds\n- Enable/optimize caching\n- Stage reordering suggestions\n\n**Use Cases:**\n- Initial retriever configuration\n- Periodic performance optimization\n- A/B testing parameter changes\n- Cost optimization\n\n**Example:**\n```bash\ncurl -X POST \"https://api.mixpeek.com/v1/analytics/retrievers/ret_abc123/analyze-tuning?days=7\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"X-Namespace: your-namespace\"\n```","operationId":"analyze_for_tuning_v1_analytics_retrievers__retriever_id__analyze_tuning_post","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","title":"Retriever Id"}},{"name":"days","in":"query","required":false,"schema":{"type":"integer","maximum":90,"minimum":1,"description":"Days of history to analyze","default":7,"title":"Days"},"description":"Days of history to analyze"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InteractionTuningResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/retrievers/{retriever_id}/slow-queries":{"get":{"tags":["Analytics","Analytics - Retrievers"],"summary":"Get Slowest Queries","description":"Get slowest queries for troubleshooting.\n\nIdentifies slowest-performing queries for optimization:\n- Query text\n- Execution time\n- Result counts\n- Stage breakdown\n\n**Use Cases:**\n- Identify problematic queries\n- Debug performance issues\n- Optimize query patterns\n- User experience improvements\n\n**Example:**\n```bash\ncurl -X GET \"https://api.mixpeek.com/v1/analytics/retrievers/ret_abc123/slow-queries?limit=10&hours=24\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"X-Namespace: your-namespace\"\n```","operationId":"get_slowest_queries_v1_analytics_retrievers__retriever_id__slow_queries_get","parameters":[{"name":"retriever_id","in":"path","required":true,"schema":{"type":"string","title":"Retriever Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"description":"Number of queries to return","default":10,"title":"Limit"},"description":"Number of queries to return"},{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":720,"minimum":1,"description":"Hours of history","default":24,"title":"Hours"},"description":"Hours of history"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","additionalProperties":true},"title":"Response Get Slowest Queries V1 Analytics Retrievers  Retriever Id  Slow Queries Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/performance/engine":{"get":{"tags":["Analytics","Analytics - Performance"],"summary":"Get Engine Performance","description":"Get engine performance metrics over time.\n\nQuery profiling data logged by the engine's profiling infrastructure.\nAll queries are automatically filtered to your namespace.\n\n**Time Range:**\n- Specify `hours` for recent history (e.g., `hours=24` for last 24 hours)\n- OR specify `start_date` and `end_date` for custom range\n- Defaults to last 24 hours if neither provided\n\n**Grouping:**\n- `minute`: High-resolution (for short time ranges)\n- `hour`: Standard resolution (default)\n- `day`: For longer time ranges\n- `week`, `month`: For historical trends\n\n**Response:**\n- Time-series metrics (avg, p50, p95, p99 latencies)\n- Summary statistics across the entire time range\n- All latencies in milliseconds\n\n**Example:**\n```bash\nGET /v1/analytics/performance/engine?hours=24&group_by=hour\n```","operationId":"get_engine_performance_v1_analytics_performance_engine_get","parameters":[{"name":"hours","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":720,"minimum":1},{"type":"null"}],"description":"Hours of history (alternative to date range)","title":"Hours"},"description":"Hours of history (alternative to date range)"},{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"Start date for time range","title":"Start Date"},"description":"Start date for time range"},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"End date for time range","title":"End Date"},"description":"End date for time range"},{"name":"group_by","in":"query","required":false,"schema":{"type":"string","pattern":"^(minute|hour|day|week|month)$","description":"Time grouping (minute, hour, day, week)","default":"hour","title":"Group By"},"description":"Time grouping (minute, hour, day, week)"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnginePerformanceResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/performance/engine/stages":{"get":{"tags":["Analytics","Analytics - Performance"],"summary":"Get Engine Stage Breakdown","description":"Get stage-level performance breakdown.\n\nBreaks down engine performance by individual profiled stages\n(e.g., pipeline_run, generate_input_dataset, gcs_batch_upload).\n\n**Use Cases:**\n- Identify which stages are slowest\n- See percentage of total time per stage\n- Optimize specific bottlenecks\n\n**Response:**\n- Per-stage metrics (count, avg, p95, max latencies)\n- Total time spent in each stage\n- Percentage of total execution time\n- Sorted by total time (worst bottlenecks first)\n\n**Example:**\n```bash\nGET /v1/analytics/performance/engine/stages?hours=24\n```","operationId":"get_engine_stage_breakdown_v1_analytics_performance_engine_stages_get","parameters":[{"name":"hours","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":720,"minimum":1},{"type":"null"}],"description":"Hours of history","title":"Hours"},"description":"Hours of history"},{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"Start date","title":"Start Date"},"description":"Start date"},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"End date","title":"End Date"},"description":"End date"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EngineStageBreakdownResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/performance/engine/extractors":{"get":{"tags":["Analytics","Analytics - Performance"],"summary":"Get Extractor Breakdown","description":"Get extractor performance breakdown.\n\nShows performance metrics for each extractor and its stages.\n\n**Use Cases:**\n- Compare performance across extractors\n- Identify slow extractor stages\n- Monitor specific extractor performance\n\n**Response:**\n- Per-extractor, per-stage metrics\n- Execution counts\n- Latency statistics (avg, p95, max)\n\n**Example:**\n```bash\nGET /v1/analytics/performance/engine/extractors?hours=24\n```","operationId":"get_extractor_breakdown_v1_analytics_performance_engine_extractors_get","parameters":[{"name":"hours","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":720,"minimum":1},{"type":"null"}],"description":"Hours of history","title":"Hours"},"description":"Hours of history"},{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"Start date","title":"Start Date"},"description":"Start date"},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"End date","title":"End Date"},"description":"End date"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExtractorBreakdownResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/performance/batches/{batch_id}/diagnostics":{"get":{"tags":["Analytics","Analytics - Performance"],"summary":"Get Batch Diagnostics","description":"Get comprehensive diagnostics for a batch.\n\nCombines batch status, task progress, collection info, performance metrics,\nand actionable insights into a single response for easy frontend rendering.\n\n**Use Cases:**\n- Monitor batch processing in real-time\n- Debug failed batches\n- View performance breakdown after completion\n- Get actionable next steps\n\n**Response includes:**\n- Overall batch status and progress\n- Per-tier task details with Ray job links\n- Collection document counts\n- Performance insights and bottlenecks (if completed)\n- Error details (if failed)\n- Recommended next actions\n\n**Example:**\n```bash\nGET /v1/analytics/performance/batches/{batch_id}/diagnostics\n```\n\n**Perfect for:**\n- Real-time progress tracking UI\n- Batch monitoring dashboards\n- Debugging failed extractions\n- Performance optimization","operationId":"get_batch_diagnostics_v1_analytics_performance_batches__batch_id__diagnostics_get","parameters":[{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","title":"Batch Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchDiagnostics"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/performance/engine/bottlenecks":{"get":{"tags":["Analytics","Analytics - Performance"],"summary":"Analyze Bottlenecks","description":"Identify performance bottlenecks.\n\nAnalyzes profiling data to identify the biggest bottlenecks,\nranked by total time spent.\n\n**Use Cases:**\n- Find what's slowing down your pipelines\n- Prioritize optimization efforts\n- Monitor bottleneck trends\n\n**Ranking:**\n- Sorted by total time spent (sum across all executions)\n- Shows percentage of total execution time\n- Includes execution count and average time\n\n**Example:**\n```bash\nGET /v1/analytics/performance/engine/bottlenecks?hours=24&limit=10\n```","operationId":"analyze_bottlenecks_v1_analytics_performance_engine_bottlenecks_get","parameters":[{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":168,"minimum":1,"description":"Hours of history","default":24,"title":"Hours"},"description":"Hours of history"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":50,"minimum":1,"description":"Number of bottlenecks to return","default":10,"title":"Limit"},"description":"Number of bottlenecks to return"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BottleneckResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/performance/engine/slow-operations":{"get":{"tags":["Analytics","Analytics - Performance"],"summary":"Get Slowest Operations","description":"Get slowest individual operations.\n\nReturns the slowest profiled operations, useful for debugging\nspecific slow executions.\n\n**Use Cases:**\n- Troubleshoot specific slow operations\n- Identify outliers\n- Deep dive into problematic executions\n\n**Filtering:**\n- `threshold_ms`: Only show operations slower than this\n- Default: 1000ms (1 second)\n\n**Response:**\n- Timestamp of slow operation\n- Stage name and component\n- Latency in milliseconds\n- Full metadata context\n\n**Example:**\n```bash\nGET /v1/analytics/performance/engine/slow-operations?hours=24&threshold_ms=5000\n```","operationId":"get_slowest_operations_v1_analytics_performance_engine_slow_operations_get","parameters":[{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":168,"minimum":1,"description":"Hours of history","default":24,"title":"Hours"},"description":"Hours of history"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"description":"Number of operations to return","default":10,"title":"Limit"},"description":"Number of operations to return"},{"name":"threshold_ms","in":"query","required":false,"schema":{"type":"number","minimum":0,"description":"Only show operations slower than this (ms)","default":1000.0,"title":"Threshold Ms"},"description":"Only show operations slower than this (ms)"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SlowOperationsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/usage/summary":{"get":{"tags":["Analytics","Analytics - Usage"],"summary":"Get Usage Summary","description":"Get usage summary for billing.\n\nAggregates the organization's usage_records — the SAME billing source of\ntruth that feeds daily_burn_rate and monthly invoicing, so this\nendpoint and the burn meter always agree.\n\nReturns per-operation credit totals for the window with USD derived at the\ncanonical $0.001/credit rate (CREDIT_RATE_USD):\n- ``usage``: one row per operation_type — ``{operation_type, credits,\n  cost_usd}`` — biggest spend first. Refund records are negative and net\n  automatically.\n- ``total_credits`` / ``total_cost``: window totals across operations.\n- ``multi_vector_tokens``: tokens of multi-vectors stored by writes, as\n  carried by the ``mvs_write`` usage records in the window (``recorded``),\n  plus tokens written since the last record (``pending``).\n\nScoped to the ORGANIZATION (matching the billing meter). Records are only\npartially namespace-attributed (async engine work carries no namespace),\nso filtering by namespace would silently under-report; ``namespace_id`` is\nechoed for request context only.\n\n**Time Range:**\n- If both `start_date` and `end_date` are provided, uses that range\n- If neither provided, defaults to last 30 days\n- If only one provided, defaults to now as the other bound\n\n**Example:**\n```bash\nGET /v1/analytics/usage/summary\nGET /v1/analytics/usage/summary?start_date=2025-01-01T00:00:00Z&end_date=2025-01-31T23:59:59Z\n```","operationId":"get_usage_summary_v1_analytics_usage_summary_get","parameters":[{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"Start date (UTC)","title":"Start Date"},"description":"Start date (UTC)"},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"End date (UTC)","title":"End Date"},"description":"End date (UTC)"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Usage Summary V1 Analytics Usage Summary Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/extractors/performance":{"get":{"tags":["Analytics","Analytics - Extractors"],"summary":"Get Extractor Performance","description":"Get feature extraction performance metrics.\n\nReturns per-extractor execution metrics from the ``extraction_events``\nanalytics collection over the last ``hours`` (namespace-scoped), one row per\n(extractor_name, version):\n- Total executions per extractor\n- Average duration + P95/P99 latencies\n- Success/failure counts and success rate\n\nReturns an empty array when no extraction has run in the window or analytics\nis unavailable.\n\n**Example:**\n```bash\nGET /v1/analytics/extractors/performance?hours=24\nGET /v1/analytics/extractors/performance?extractor_name=text_extractor&hours=168\n```","operationId":"get_extractor_performance_v1_analytics_extractors_performance_get","parameters":[{"name":"extractor_name","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by extractor","title":"Extractor Name"},"description":"Filter by extractor"},{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":720,"minimum":1,"description":"Hours of history","default":24,"title":"Hours"},"description":"Hours of history"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","additionalProperties":true},"title":"Response Get Extractor Performance V1 Analytics Extractors Performance Get"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/namespaces/fields/most-queried":{"get":{"tags":["Analytics","Analytics - Namespaces"],"summary":"Get Most Queried Fields","description":"Get most frequently queried metadata fields.\n\nIdentifies which metadata fields are accessed most often in retriever queries,\nhelping prioritize index creation and understand query patterns.\n\n**Use Cases:**\n- Identify fields that need indexing\n- Understand common query patterns\n- Prioritize optimization efforts\n- Plan database schema improvements\n\n**Response Includes:**\n- Field name and usage frequency\n- Average and P95 latency metrics\n- Total unique fields analyzed\n\n**Example:**\n```bash\ncurl -X GET \"https://api.mixpeek.com/v1/analytics/namespaces/fields/most-queried?days=30&limit=20\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"X-Namespace: your-namespace\"\n```","operationId":"get_most_queried_fields_v1_analytics_namespaces_fields_most_queried_get","parameters":[{"name":"days","in":"query","required":false,"schema":{"type":"integer","maximum":90,"minimum":1,"description":"Days of history to analyze","default":30,"title":"Days"},"description":"Days of history to analyze"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"description":"Maximum fields to return","default":50,"title":"Limit"},"description":"Maximum fields to return"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MostQueriedFieldsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/namespaces/queries/slow":{"get":{"tags":["Analytics","Analytics - Namespaces"],"summary":"Get Slow Queries","description":"Get slow queries and their filter patterns.\n\nIdentifies queries exceeding a latency threshold and shows which metadata\nfields they're filtering on, helping pinpoint optimization opportunities.\n\n**Use Cases:**\n- Troubleshoot slow queries\n- Identify unindexed fields causing slowdowns\n- Debug performance issues\n- Optimize query patterns\n\n**Response Includes:**\n- Query details (retriever, inputs, latency)\n- Results count\n- Metadata fields being filtered\n- Full query context\n\n**Example:**\n```bash\ncurl -X GET \"https://api.mixpeek.com/v1/analytics/namespaces/queries/slow?latency_threshold_ms=1000\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"X-Namespace: your-namespace\"\n```","operationId":"get_slow_queries_v1_analytics_namespaces_queries_slow_get","parameters":[{"name":"days","in":"query","required":false,"schema":{"type":"integer","maximum":90,"minimum":1,"description":"Days of history to analyze","default":30,"title":"Days"},"description":"Days of history to analyze"},{"name":"latency_threshold_ms","in":"query","required":false,"schema":{"type":"number","maximum":10000,"minimum":100,"description":"Latency threshold in ms","default":500,"title":"Latency Threshold Ms"},"description":"Latency threshold in ms"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":500,"minimum":1,"description":"Maximum queries to return","default":100,"title":"Limit"},"description":"Maximum queries to return"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SlowQueriesResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/namespaces/fields/performance":{"get":{"tags":["Analytics","Analytics - Namespaces"],"summary":"Get Field Performance","description":"Analyze field performance correlation.\n\nShows which metadata fields correlate with slow queries, helping identify\nfields that would benefit most from indexing.\n\n**Use Cases:**\n- Identify fields causing performance issues\n- Quantify indexing impact potential\n- Prioritize index creation\n- Monitor field usage patterns\n\n**Response Includes:**\n- Field usage count\n- Latency statistics (avg, P50, P95, P99, max)\n- Index priority score (usage × latency)\n- Sorted by priority score\n\n**Index Priority Score:**\nHigher scores indicate fields where indexing would have greatest impact.\nScore = (query count) × (average latency)\n\n**Example:**\n```bash\ncurl -X GET \"https://api.mixpeek.com/v1/analytics/namespaces/fields/performance?days=30\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"X-Namespace: your-namespace\"\n```","operationId":"get_field_performance_v1_analytics_namespaces_fields_performance_get","parameters":[{"name":"days","in":"query","required":false,"schema":{"type":"integer","maximum":90,"minimum":1,"description":"Days of history to analyze","default":30,"title":"Days"},"description":"Days of history to analyze"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"description":"Maximum fields to return","default":50,"title":"Limit"},"description":"Maximum fields to return"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FieldPerformanceResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/namespaces/indexes/compound-patterns":{"get":{"tags":["Analytics","Analytics - Namespaces"],"summary":"Get Compound Index Patterns","description":"Identify compound index opportunities.\n\nFinds metadata fields commonly used together in filters, suggesting\nopportunities for compound (multi-field) indexes.\n\n**Use Cases:**\n- Optimize multi-field queries\n- Create compound indexes\n- Understand query complexity\n- Improve complex filter performance\n\n**Response Includes:**\n- Field combinations used together\n- Frequency of combination usage\n- Average and P95 latency\n- Sorted by combination frequency\n\n**Compound Index Example:**\nIf `brand + status` appears frequently, create:\n```javascript\ndb.documents.createIndex({\"metadata.brand\": 1, \"metadata.status\": 1})\n```\n\n**Example:**\n```bash\ncurl -X GET \"https://api.mixpeek.com/v1/analytics/namespaces/indexes/compound-patterns\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"X-Namespace: your-namespace\"\n```","operationId":"get_compound_index_patterns_v1_analytics_namespaces_indexes_compound_patterns_get","parameters":[{"name":"days","in":"query","required":false,"schema":{"type":"integer","maximum":90,"minimum":1,"description":"Days of history to analyze","default":30,"title":"Days"},"description":"Days of history to analyze"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"description":"Maximum patterns to return","default":50,"title":"Limit"},"description":"Maximum patterns to return"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompoundIndexResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/namespaces/indexes/recommendations":{"get":{"tags":["Analytics","Analytics - Namespaces"],"summary":"Get Index Recommendations","description":"Get comprehensive MongoDB index recommendations.\n\nAnalyzes query patterns and generates prioritized index recommendations\nwith ready-to-use MongoDB commands.\n\n**Use Cases:**\n- Get actionable index suggestions\n- Prioritize database optimization\n- Copy/paste index creation commands\n- Track optimization opportunities\n\n**Recommendation Levels:**\n- **HIGH PRIORITY**: >100 queries, >300ms avg OR >10 very slow queries\n- **MEDIUM PRIORITY**: >50 queries, >200ms avg OR >20 slow queries\n- **LOW PRIORITY**: >10 queries but acceptable performance\n- **NO ACTION**: Low usage, no optimization needed\n\n**Response Includes:**\n- Prioritized recommendations\n- Usage and latency statistics\n- MongoDB index creation commands\n- Summary by priority level\n\n**Example:**\n```bash\ncurl -X GET \"https://api.mixpeek.com/v1/analytics/namespaces/indexes/recommendations\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"X-Namespace: your-namespace\"\n```","operationId":"get_index_recommendations_v1_analytics_namespaces_indexes_recommendations_get","parameters":[{"name":"days","in":"query","required":false,"schema":{"type":"integer","maximum":90,"minimum":1,"description":"Days of history to analyze","default":30,"title":"Days"},"description":"Days of history to analyze"},{"name":"min_usage_count","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Minimum queries to consider","default":5,"title":"Min Usage Count"},"description":"Minimum queries to consider"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Maximum recommendations to return","default":50,"title":"Limit"},"description":"Maximum recommendations to return"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IndexRecommendationsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/namespaces/errors":{"get":{"tags":["Analytics","Analytics - Namespaces"],"summary":"Get Namespace Errors","description":"Batch error/failure counts for every collection & cluster in the namespace.\n\nReturns one entry per resource that has at least one error/failure in the\nwindow, in a single response — replacing the per-resource\n``/analytics/{collections,clusters}/{id}/failures`` fan-out (the Studio\nMonitoring \"Errors & Health\" N+1, which fired ~13+ calls per visit, most\nreturning zero). Collection errors come from the\n``extraction_events`` analytics collection; cluster failures from Mongo\n``clustering_results``. An empty ``collections``/``clusters`` list means that\nresource type is healthy for the window.\n\n**Recommended workflow:** call this once for the aggregate health view, then\ncall the per-resource ``/failures`` endpoint lazily ONLY for the (usually\nfew) resources reporting errors to get the full error-type breakdown.\n\n**Example:**\n```bash\ncurl -X GET \"https://api.mixpeek.com/v1/analytics/namespaces/errors?hours=24\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"X-Namespace: your-namespace\"\n```","operationId":"get_namespace_errors_v1_analytics_namespaces_errors_get","parameters":[{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":720,"minimum":1,"description":"Hours of history to analyze","default":72,"title":"Hours"},"description":"Hours of history to analyze"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NamespaceErrorsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/namespaces/summary":{"get":{"tags":["Analytics","Analytics - Namespaces"],"summary":"Get Namespace Summary","description":"Get comprehensive namespace optimization summary.\n\nProvides a complete overview of namespace performance including:\n- Top index recommendations\n- Most queried fields\n- Slowest fields\n- Compound index opportunities\n- Summary statistics\n\n**Use Cases:**\n- Get full optimization picture\n- Regular performance reviews\n- Database health checks\n- Planning optimization work\n\n**Response Includes:**\n- Summary statistics (field counts, priority levels)\n- Top 10 index recommendations\n- Top 10 most queried fields\n- Top 10 slowest fields\n- Top 10 compound index opportunities\n\n**Recommended Workflow:**\n1. Call this endpoint for overview\n2. Use specific endpoints for details\n3. Implement high-priority recommendations\n4. Monitor improvement over time\n\n**Example:**\n```bash\ncurl -X GET \"https://api.mixpeek.com/v1/analytics/namespaces/summary?days=30\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"X-Namespace: your-namespace\"\n```","operationId":"get_namespace_summary_v1_analytics_namespaces_summary_get","parameters":[{"name":"days","in":"query","required":false,"schema":{"type":"integer","maximum":90,"minimum":1,"description":"Days of history to analyze","default":30,"title":"Days"},"description":"Days of history to analyze"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NamespaceSummaryResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/indexes/suggestions":{"get":{"tags":["Analytics","Analytics - Indexes"],"summary":"Get Index Suggestions","description":"Get index suggestions based on filter usage patterns.","operationId":"get_index_suggestions_v1_analytics_indexes_suggestions_get","parameters":[{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":720,"minimum":1,"description":"Time window in hours to analyze (max 30 days)","default":24,"title":"Hours"},"description":"Time window in hours to analyze (max 30 days)"},{"name":"min_count","in":"query","required":false,"schema":{"type":"integer","maximum":10000,"minimum":1,"description":"Minimum query count threshold for suggestions","default":100,"title":"Min Count"},"description":"Minimum query count threshold for suggestions"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IndexSuggestionsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/indexes/usage":{"get":{"tags":["Analytics","Analytics - Indexes"],"summary":"Get Field Usage","description":"Get usage statistics for all filtered fields.","operationId":"get_field_usage_v1_analytics_indexes_usage_get","parameters":[{"name":"period","in":"query","required":false,"schema":{"type":"string","pattern":"^(\\d+h|\\d+d)$","description":"Time period: Xh (hours) or Xd (days), e.g., 24h, 7d, 30d","default":"24h","title":"Period"},"description":"Time period: Xh (hours) or Xd (days), e.g., 24h, 7d, 30d"},{"name":"min_count","in":"query","required":false,"schema":{"type":"integer","maximum":10000,"minimum":1,"description":"Minimum query count to include a field","default":1,"title":"Min Count"},"description":"Minimum query count to include a field"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FieldUsageResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/buckets/{bucket_id}/storage":{"get":{"tags":["Analytics","Analytics - Buckets"],"summary":"Get Bucket Storage","description":"Get storage growth trends over time.\n\nAnalyzes bucket storage metrics including:\n- Total storage size over time\n- Object count trends\n- Growth rates\n\n**Use Cases:**\n- Monitor storage capacity planning\n- Identify storage growth patterns\n- Track object accumulation\n- Alert on unexpected growth\n\n**Example:**\n```bash\ncurl -X GET \"https://api.mixpeek.com/v1/analytics/buckets/bkt_abc123/storage?group_by=day\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"X-Namespace: your-namespace\"\n```","operationId":"get_bucket_storage_v1_analytics_buckets__bucket_id__storage_get","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}},{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"Start date (UTC)","title":"Start Date"},"description":"Start date (UTC)"},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"End date (UTC)","title":"End Date"},"description":"End date (UTC)"},{"name":"group_by","in":"query","required":false,"schema":{"type":"string","description":"Time grouping: hour, day, week, month","default":"day","title":"Group By"},"description":"Time grouping: hour, day, week, month"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BucketStorageResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/buckets/{bucket_id}/upload-performance":{"get":{"tags":["Analytics","Analytics - Buckets"],"summary":"Get Upload Performance","description":"Get upload performance metrics.\n\nAnalyzes upload operations including:\n- Upload latency (P50, P95, P99)\n- Throughput (MB/s)\n- Error rates\n\n**Use Cases:**\n- Monitor upload performance\n- Identify performance degradations\n- Optimize upload strategies\n- Debug upload issues\n\n**Example:**\n```bash\ncurl -X GET \"https://api.mixpeek.com/v1/analytics/buckets/bkt_abc123/upload-performance?hours=24\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"X-Namespace: your-namespace\"\n```","operationId":"get_upload_performance_v1_analytics_buckets__bucket_id__upload_performance_get","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}},{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":720,"minimum":1,"description":"Hours of history","default":24,"title":"Hours"},"description":"Hours of history"},{"name":"group_by","in":"query","required":false,"schema":{"type":"string","description":"Time grouping: hour, day","default":"hour","title":"Group By"},"description":"Time grouping: hour, day"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UploadPerformanceResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/buckets/{bucket_id}/sync-performance":{"get":{"tags":["Analytics","Analytics - Buckets"],"summary":"Get Sync Performance","description":"Get sync performance metrics.\n\nAnalyzes sync job execution including:\n- Files synced/failed\n- Sync duration and throughput\n- Success rates by provider\n\n**Use Cases:**\n- Monitor sync reliability\n- Compare sync configurations\n- Identify slow syncs\n- Debug sync failures\n\n**Example:**\n```bash\ncurl -X GET \"https://api.mixpeek.com/v1/analytics/buckets/bkt_abc123/sync-performance?hours=168\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"X-Namespace: your-namespace\"\n```","operationId":"get_sync_performance_v1_analytics_buckets__bucket_id__sync_performance_get","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}},{"name":"sync_config_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by sync config ID","title":"Sync Config Id"},"description":"Filter by sync config ID"},{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":720,"minimum":1,"description":"Hours of history (default: 7 days)","default":168,"title":"Hours"},"description":"Hours of history (default: 7 days)"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"description":"Maximum sync runs to return","default":100,"title":"Limit"},"description":"Maximum sync runs to return"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SyncPerformanceResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/buckets/health":{"get":{"tags":["Analytics","Analytics - Buckets"],"summary":"Get Namespace Buckets Health","description":"Get health for ALL buckets in the namespace in one request.\n\nBatch counterpart of GET /{bucket_id}/health: two grouped analytics\nqueries cover the whole namespace instead of a query fan-out per bucket.\nBuckets with no events in the window are omitted from the response and\nshould be treated as healthy.\n\n**Use Cases:**\n- Monitoring dashboards listing many buckets (replaces the per-bucket\n  health call fan-out that scaled linearly with bucket count)\n- Alerting sweeps over all buckets\n\n**Example:**\n```bash\ncurl -X GET \"https://api.mixpeek.com/v1/analytics/buckets/health?hours=24\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"X-Namespace: your-namespace\"\n```","operationId":"get_namespace_buckets_health_v1_analytics_buckets_health_get","parameters":[{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":720,"minimum":1,"description":"Hours of history","default":24,"title":"Hours"},"description":"Hours of history"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NamespaceBucketsHealthResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/buckets/{bucket_id}/health":{"get":{"tags":["Analytics","Analytics - Buckets"],"summary":"Get Bucket Health","description":"Get bucket health monitoring metrics.\n\nAnalyzes bucket health including:\n- Error breakdown by type\n- Sync health per configuration\n- Stuck/failing syncs\n- Overall health status\n\n**Use Cases:**\n- Monitor bucket health\n- Identify failing syncs\n- Debug errors by type\n- Alert on unhealthy buckets\n\n**Example:**\n```bash\ncurl -X GET \"https://api.mixpeek.com/v1/analytics/buckets/bkt_abc123/health?hours=24\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"X-Namespace: your-namespace\"\n```","operationId":"get_bucket_health_v1_analytics_buckets__bucket_id__health_get","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}},{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":720,"minimum":1,"description":"Hours of history","default":24,"title":"Hours"},"description":"Hours of history"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BucketHealthResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/buckets/{bucket_id}/usage":{"get":{"tags":["Analytics","Analytics - Buckets"],"summary":"Get Bucket Usage","description":"A bucket's storage, upload and sync usage over time.\n\nPer period: storage_gb_hours, the bytes the bucket held integrated over\ntime from its hourly storage snapshots (GB is 10^9 bytes; time before the\nfirst snapshot in the window is not counted); upload_operations, the\nobjects created through the object create endpoints; and sync_operations,\nthe sync runs that finished, successful or failed. Objects a sync creates\ncount under its run, not as uploads.\n\nCredits and estimated cost read 0: storage, uploads and syncs have no\nprice yet, and this route reports quantities until the invoice's price\ntable carries them. The default window is the last 30 days.","operationId":"get_bucket_usage_v1_analytics_buckets__bucket_id__usage_get","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}},{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"Start date (UTC)","title":"Start Date"},"description":"Start date (UTC)"},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"End date (UTC)","title":"End Date"},"description":"End date (UTC)"},{"name":"group_by","in":"query","required":false,"schema":{"type":"string","description":"Time grouping: hour, day, week, month","default":"day","title":"Group By"},"description":"Time grouping: hour, day, week, month"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BucketUsageResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/buckets/{bucket_id}/sync-comparison":{"get":{"tags":["Analytics","Analytics - Buckets"],"summary":"Get Sync Comparison","description":"Compare performance across sync configurations.\n\nCompares sync configurations by:\n- Average duration and throughput\n- Success rates\n- Total files and bytes synced\n- Provider performance\n\n**Use Cases:**\n- Compare sync providers (S3 vs GCS)\n- Optimize sync configurations\n- Identify best-performing syncs\n- Benchmark sync strategies\n\n**Example:**\n```bash\ncurl -X GET \"https://api.mixpeek.com/v1/analytics/buckets/bkt_abc123/sync-comparison?hours=168\" \\\n  -H \"Authorization: Bearer YOUR_API_KEY\" \\\n  -H \"X-Namespace: your-namespace\"\n```","operationId":"get_sync_comparison_v1_analytics_buckets__bucket_id__sync_comparison_get","parameters":[{"name":"bucket_id","in":"path","required":true,"schema":{"type":"string","title":"Bucket Id"}},{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":720,"minimum":1,"description":"Hours of history (default: 7 days)","default":168,"title":"Hours"},"description":"Hours of history (default: 7 days)"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SyncComparisonResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/collections/{collection_id}/overview":{"get":{"tags":["Analytics","Analytics - Collections"],"summary":"Get Collection Overview","description":"Get high-level collection health and status metrics.\n\nProvides collection health including:\n- Total document count and recent growth\n- Processing performance and success rates\n- Active enrichments (taxonomies, clusters)\n\n**Use Cases:**\n- Monitor collection health\n- Quick status check\n- Identify collections needing attention","operationId":"get_collection_overview_v1_analytics_collections__collection_id__overview_get","parameters":[{"name":"collection_id","in":"path","required":true,"schema":{"type":"string","title":"Collection Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionOverviewResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/collections/{collection_id}/growth":{"get":{"tags":["Analytics","Analytics - Collections"],"summary":"Get Document Growth","description":"Get document growth trends over time.\n\nTracks document additions over time, useful for understanding\nbatch processing patterns and indexing velocity.","operationId":"get_document_growth_v1_analytics_collections__collection_id__growth_get","parameters":[{"name":"collection_id","in":"path","required":true,"schema":{"type":"string","title":"Collection Id"}},{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start Date"}},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End Date"}},{"name":"group_by","in":"query","required":false,"schema":{"type":"string","description":"hour, day, week, month","default":"day","title":"Group By"},"description":"hour, day, week, month"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GrowthMetricsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/collections/{collection_id}/extractors":{"get":{"tags":["Analytics","Analytics - Collections"],"summary":"Get Extractor Performance","description":"Get feature extractor performance breakdown.\n\nAnalyzes extractor execution metrics including:\n- Execution counts and success/failure rates\n- Latency percentiles (P95, P99)\n- Total processing time\n\n**Use Cases:**\n- Identify slow extractors for optimization\n- Monitor extraction success rates\n- Understanding processing bottlenecks","operationId":"get_extractor_performance_v1_analytics_collections__collection_id__extractors_get","parameters":[{"name":"collection_id","in":"path","required":true,"schema":{"type":"string","title":"Collection Id"}},{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":720,"minimum":1,"default":24,"title":"Hours"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExtractorPerformanceResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/collections/{collection_id}/latency":{"get":{"tags":["Analytics","Analytics - Collections"],"summary":"Get Latency Metrics","description":"Get processing latency distribution.\n\nAnalyzes document processing latency including:\n- Latency percentiles over time\n- Slowest document operations\n- Performance trends","operationId":"get_latency_metrics_v1_analytics_collections__collection_id__latency_get","parameters":[{"name":"collection_id","in":"path","required":true,"schema":{"type":"string","title":"Collection Id"}},{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":720,"minimum":1,"default":24,"title":"Hours"}},{"name":"group_by","in":"query","required":false,"schema":{"type":"string","default":"hour","title":"Group By"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LatencyResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/collections/{collection_id}/failures":{"get":{"tags":["Analytics","Analytics - Collections"],"summary":"Get Failure Analysis","description":"Get failure analysis metrics.\n\nDebug processing failures including:\n- Error distribution by type\n- Recent error messages\n- Failure patterns\n\n**Use Cases:**\n- Debug processing failures\n- Identify common error patterns\n- Track error trends","operationId":"get_failure_analysis_v1_analytics_collections__collection_id__failures_get","parameters":[{"name":"collection_id","in":"path","required":true,"schema":{"type":"string","title":"Collection Id"}},{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":720,"minimum":1,"default":72,"title":"Hours"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/api__analytics__collections__models__FailureAnalysisResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/clusters/{cluster_id}/execution-history":{"get":{"tags":["Analytics","Analytics - Clusters"],"summary":"Get Execution History","description":"Get cluster execution history with metrics.\n\nProvides execution timeline including:\n- Execution duration and document counts\n- Algorithm and cluster counts\n- Success/failure status\n\n**Use Cases:**\n- Monitor clustering performance\n- Track execution patterns\n- Identify execution issues","operationId":"get_execution_history_v1_analytics_clusters__cluster_id__execution_history_get","parameters":[{"name":"cluster_id","in":"path","required":true,"schema":{"type":"string","title":"Cluster Id"}},{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":720,"minimum":1,"description":"Hours of history","default":168,"title":"Hours"},"description":"Hours of history"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExecutionHistoryResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/clusters/{cluster_id}/failures":{"get":{"tags":["Analytics","Analytics - Clusters"],"summary":"Get Failure Analysis","description":"Get cluster failure analysis.\n\nAnalyzes clustering failures including:\n- Error messages and types\n- Failure timestamps\n- Failure patterns\n\n**Use Cases:**\n- Debug clustering failures\n- Identify common error patterns\n- Monitor cluster health","operationId":"get_failure_analysis_v1_analytics_clusters__cluster_id__failures_get","parameters":[{"name":"cluster_id","in":"path","required":true,"schema":{"type":"string","title":"Cluster Id"}},{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":720,"minimum":1,"default":168,"title":"Hours"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/api__analytics__clusters__models__FailureAnalysisResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/taxonomies/{taxonomy_id}/assignments":{"get":{"tags":["Analytics","Analytics - Taxonomies"],"summary":"Get Assignment Metrics","description":"Get taxonomy assignment metrics over time.\n\nTracks assignment counts including:\n- Assignment volume over time\n- Average confidence scores\n- Unique labels assigned\n\n**Use Cases:**\n- Monitor taxonomy usage\n- Track assignment trends\n- Identify popular labels","operationId":"get_assignment_metrics_v1_analytics_taxonomies__taxonomy_id__assignments_get","parameters":[{"name":"taxonomy_id","in":"path","required":true,"schema":{"type":"string","title":"Taxonomy Id"}},{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start Date"}},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End Date"}},{"name":"group_by","in":"query","required":false,"schema":{"type":"string","default":"day","title":"Group By"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AssignmentMetricsResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/taxonomies/{taxonomy_id}/confidence":{"get":{"tags":["Analytics","Analytics - Taxonomies"],"summary":"Get Confidence Distribution","description":"Get confidence score distribution.\n\nAnalyzes assignment confidence including:\n- Distribution across confidence ranges\n- Low-confidence assignment alerts\n- Average confidence trends\n\n**Use Cases:**\n- Monitor taxonomy quality\n- Identify low-confidence assignments\n- Track confidence improvements","operationId":"get_confidence_distribution_v1_analytics_taxonomies__taxonomy_id__confidence_get","parameters":[{"name":"taxonomy_id","in":"path","required":true,"schema":{"type":"string","title":"Taxonomy Id"}},{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":720,"minimum":1,"default":168,"title":"Hours"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfidenceResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/taxonomies/{taxonomy_id}/labels":{"get":{"tags":["Analytics","Analytics - Taxonomies"],"summary":"Get Label Distribution","description":"Get label distribution.\n\nAnalyzes label usage including:\n- Top labels by assignment count\n- Label popularity percentages\n- Confidence by label\n\n**Use Cases:**\n- Understand label usage\n- Identify most common categories\n- Balance taxonomy coverage","operationId":"get_label_distribution_v1_analytics_taxonomies__taxonomy_id__labels_get","parameters":[{"name":"taxonomy_id","in":"path","required":true,"schema":{"type":"string","title":"Taxonomy Id"}},{"name":"hours","in":"query","required":false,"schema":{"type":"integer","maximum":720,"minimum":1,"default":168,"title":"Hours"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LabelDistributionResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}},"/v1/analytics/taxonomies/{taxonomy_id}/enrichments":{"get":{"tags":["Analytics","Analytics - Taxonomies"],"summary":"Get Enrichment History","description":"Get enrichment execution history.\n\nTracks enrichment operations including:\n- Enrichment success rates\n- Average latency\n- Volume trends\n\n**Use Cases:**\n- Monitor enrichment performance\n- Track success rates\n- Identify performance issues","operationId":"get_enrichment_history_v1_analytics_taxonomies__taxonomy_id__enrichments_get","parameters":[{"name":"taxonomy_id","in":"path","required":true,"schema":{"type":"string","title":"Taxonomy Id"}},{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start Date"}},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End Date"}},{"name":"group_by","in":"query","required":false,"schema":{"type":"string","default":"day","title":"Group By"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnrichmentHistoryResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"x-mixpeek-plan":{"minimum_tier":null,"requires_selected_plan":false,"permissions":["read"]},"x-mixpeek-namespace-scoped":true,"security":[{"BearerAuth":[],"NamespaceHeader":[]}]}}},"components":{"schemas":{"APIKeyCreateRequest":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Human-friendly key label shown in dashboards."},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description","description":"Optional description explaining the key's purpose."},"permissions":{"items":{"$ref":"#/components/schemas/Permission"},"type":"array","title":"Permissions","description":"Set of permissions granted to the API key. Defaults to full read/write/delete access. Restrict explicitly when creating scoped keys."},"scopes":{"anyOf":[{"items":{"$ref":"#/components/schemas/ResourceScope-Input"},"type":"array"},{"type":"null"}],"title":"Scopes","description":"Optional resource scope restrictions applied to the key."},"rate_limit_override":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Rate Limit Override","description":"Per-key requests-per-minute override (defaults to plan limit when absent)."},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At","description":"Optional UTC timestamp when the key automatically expires."},"principal_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Principal Id","description":"End-user identifier for document-level ACL. When set, the key becomes user-scoped and all document reads are automatically filtered to documents the principal has access to. This represents an end-user in your application, NOT an org user."},"allowed_origins":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Allowed Origins","description":"Optional list of allowed HTTP origins for this API key. When set, browser requests must include a matching Origin header. Supports exact matches and wildcard subdomains (e.g., 'https://*.example.com'). Defense-in-depth: Origin headers can be spoofed from non-browser contexts. Null means no origin restriction.","examples":[["https://docs.example.com","https://*.example.com"]]}},"type":"object","required":["name"],"title":"APIKeyCreateRequest","description":"Payload for creating a new API key.","examples":[{"description":"Service account for ingestion pipeline","name":"backend-service","permissions":["read","write"],"rate_limit_override":120},{"name":"analytics-read","permissions":["read"],"scopes":[{"operations":["read_data"],"resource_id":"ns_reporting","resource_type":"namespace"}]}]},"APIKeyCreateResponse":{"properties":{"key_id":{"type":"string","title":"Key Id","description":"Public identifier for the API key."},"key_hash":{"type":"string","title":"Key Hash","description":"SHA-256 hash of the plaintext key."},"key_prefix":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Key Prefix","description":"Visible prefix of the API key for user identification (e.g., 'sk_abc123...'). Shows the first 10 characters of the plaintext key to help users identify which key is which in lists, without exposing the full secret. This follows industry best practices from GitHub, Stripe, and AWS. Generated automatically for new keys. Older keys may not have this field.","examples":["sk_abc123...","sk_xyz789..."]},"key_type":{"$ref":"#/components/schemas/APIKeyType","description":"Type of API key. STANDARD for regular organization keys, MARKETPLACE_SUBSCRIPTION for marketplace subscription access tokens.","default":"standard"},"subscription_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subscription Id","description":"Marketplace subscription ID if this is a marketplace subscription key. Only set when key_type is MARKETPLACE_SUBSCRIPTION."},"is_internal":{"type":"boolean","title":"Is Internal","description":"SERVER-VERIFIED internal-actor marker. When True, this key belongs to Mixpeek's own operations (e.g. the in-org ops/health probe that must authenticate under a dedicated tenant's internal_id because the single-tenant pod gate fail-closes cross-org auth) and its usage is NOT billed to the org: accrue_mvs_usage skips the accrual and consume_credits skips the direct charge. FAIL CLOSED — absent/False means BILL. This is the ONLY server-side source a billing skip may key on; never the client-influenced X-Mixpeek-Traffic header or mixpeek-loop-* User-Agent. Set only by an admin provisioning an internal key, never from a create request.","default":false},"internal_id":{"type":"string","title":"Internal Id","description":"Organization internal identifier."},"organization_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Id","description":"Organization public identifier (denormalized)."},"user_id":{"type":"string","title":"User Id","description":"Identifier of the user who owns the key."},"name":{"type":"string","title":"Name","description":"Human-friendly key label."},"description":{"type":"string","title":"Description","description":"Optional description explaining the key usage.","default":""},"permissions":{"items":{"$ref":"#/components/schemas/Permission"},"type":"array","title":"Permissions","description":"Permissions granted to the key."},"scopes":{"items":{"$ref":"#/components/schemas/ResourceScope-Output"},"type":"array","title":"Scopes","description":"Resource-level scopes restricting the key."},"rate_limit_override":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Rate Limit Override","description":"Optional per-key rate limit override in requests per minute."},"status":{"$ref":"#/components/schemas/KeyStatus","description":"Lifecycle status of the key (active, revoked, expired).","default":"active"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At","description":"UTC timestamp when the key automatically expires."},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At","description":"UTC timestamp of the last successful request using the key."},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"UTC timestamp when the key was created."},"created_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By","description":"User identifier that created the key."},"revoked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Revoked At","description":"UTC timestamp when the key was revoked (if applicable)."},"revoked_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Revoked By","description":"User identifier that revoked the key (if applicable)."},"allowed_origins":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Allowed Origins","description":"Optional list of allowed HTTP origins for this API key. When set, requests must include an Origin header matching one of these values. Supports exact matches (e.g., 'https://docs.example.com') and wildcard subdomains (e.g., 'https://*.example.com'). Only enforced for browser requests (defense-in-depth, not a security boundary). Null means no origin restriction.","examples":[["https://docs.example.com","https://*.example.com"]]},"principal_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Principal Id","description":"End-user identifier for document-level ACL (row-level security). When set, this key is user-scoped: all document reads are automatically filtered to documents the principal owns or has been granted access to. This represents an end-user in your application, NOT an org user."},"key":{"type":"string","title":"Key"}},"type":"object","required":["key_hash","internal_id","user_id","name","key"],"title":"APIKeyCreateResponse","description":"API key response including the plaintext secret.","examples":[{"created_at":"2025-01-01T00:00:00Z","created_by":"usr_admin","description":"Service account for ingestion","internal_id":"int_x1y2z3","key_hash":"2c26b46b68ffc68ff99b453c1d304134","key_id":"key_a1b2c3d4e5f6g7h","key_prefix":"sk_abc123...","name":"backend-service","organization_id":"org_demo123","permissions":["read","write"],"scopes":[],"status":"active","user_id":"usr_a1b2c3d4e5f6g7h"}]},"APIKeyModel":{"properties":{"key_id":{"type":"string","title":"Key Id","description":"Public identifier for the API key."},"key_hash":{"type":"string","title":"Key Hash","description":"SHA-256 hash of the plaintext key."},"key_prefix":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Key Prefix","description":"Visible prefix of the API key for user identification (e.g., 'sk_abc123...'). Shows the first 10 characters of the plaintext key to help users identify which key is which in lists, without exposing the full secret. This follows industry best practices from GitHub, Stripe, and AWS. Generated automatically for new keys. Older keys may not have this field.","examples":["sk_abc123...","sk_xyz789..."]},"key_type":{"$ref":"#/components/schemas/APIKeyType","description":"Type of API key. STANDARD for regular organization keys, MARKETPLACE_SUBSCRIPTION for marketplace subscription access tokens.","default":"standard"},"subscription_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subscription Id","description":"Marketplace subscription ID if this is a marketplace subscription key. Only set when key_type is MARKETPLACE_SUBSCRIPTION."},"is_internal":{"type":"boolean","title":"Is Internal","description":"SERVER-VERIFIED internal-actor marker. When True, this key belongs to Mixpeek's own operations (e.g. the in-org ops/health probe that must authenticate under a dedicated tenant's internal_id because the single-tenant pod gate fail-closes cross-org auth) and its usage is NOT billed to the org: accrue_mvs_usage skips the accrual and consume_credits skips the direct charge. FAIL CLOSED — absent/False means BILL. This is the ONLY server-side source a billing skip may key on; never the client-influenced X-Mixpeek-Traffic header or mixpeek-loop-* User-Agent. Set only by an admin provisioning an internal key, never from a create request.","default":false},"internal_id":{"type":"string","title":"Internal Id","description":"Organization internal identifier."},"organization_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Id","description":"Organization public identifier (denormalized)."},"user_id":{"type":"string","title":"User Id","description":"Identifier of the user who owns the key."},"name":{"type":"string","title":"Name","description":"Human-friendly key label."},"description":{"type":"string","title":"Description","description":"Optional description explaining the key usage.","default":""},"permissions":{"items":{"$ref":"#/components/schemas/Permission"},"type":"array","title":"Permissions","description":"Permissions granted to the key."},"scopes":{"items":{"$ref":"#/components/schemas/ResourceScope-Output"},"type":"array","title":"Scopes","description":"Resource-level scopes restricting the key."},"rate_limit_override":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Rate Limit Override","description":"Optional per-key rate limit override in requests per minute."},"status":{"$ref":"#/components/schemas/KeyStatus","description":"Lifecycle status of the key (active, revoked, expired).","default":"active"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At","description":"UTC timestamp when the key automatically expires."},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At","description":"UTC timestamp of the last successful request using the key."},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"UTC timestamp when the key was created."},"created_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By","description":"User identifier that created the key."},"revoked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Revoked At","description":"UTC timestamp when the key was revoked (if applicable)."},"revoked_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Revoked By","description":"User identifier that revoked the key (if applicable)."},"allowed_origins":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Allowed Origins","description":"Optional list of allowed HTTP origins for this API key. When set, requests must include an Origin header matching one of these values. Supports exact matches (e.g., 'https://docs.example.com') and wildcard subdomains (e.g., 'https://*.example.com'). Only enforced for browser requests (defense-in-depth, not a security boundary). Null means no origin restriction.","examples":[["https://docs.example.com","https://*.example.com"]]},"principal_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Principal Id","description":"End-user identifier for document-level ACL (row-level security). When set, this key is user-scoped: all document reads are automatically filtered to documents the principal owns or has been granted access to. This represents an end-user in your application, NOT an org user."}},"type":"object","required":["key_hash","internal_id","user_id","name"],"title":"APIKeyModel","description":"API key document stored in MongoDB.","examples":[{"created_at":"2025-01-01T00:00:00Z","created_by":"usr_admin","description":"Service account for ingestion","internal_id":"int_x1y2z3","key_hash":"2c26b46b68ffc68ff99b453c1d304134","key_id":"key_a1b2c3d4e5f6g7h","key_prefix":"sk_abc123...","name":"backend-service","organization_id":"org_demo123","permissions":["read","write"],"scopes":[],"status":"active","user_id":"usr_a1b2c3d4e5f6g7h"}]},"APIKeyType":{"type":"string","enum":["standard","marketplace_subscription","retriever","user_scoped","session","workload"],"title":"APIKeyType","description":"Type of API key determining its purpose and scope.\n\n- STANDARD: Regular organization API key with standard permissions.\n- MARKETPLACE_SUBSCRIPTION: Special key generated for marketplace subscriptions,\n  allowing cross-org access to specific marketplace retrievers.\n- RETRIEVER: Per-retriever API key scoped to execute a specific retriever.\n  Only the retriever owner can create these keys. Prefix: ret_sk_\n- SESSION: Short-lived key minted by Studio on each login to back the\n  authenticated UI. Hidden from the user-facing key list endpoints.\n- WORKLOAD: Short-lived key minted by ``POST /v1/auth/token-exchange`` for a\n  workload whose OIDC token matched a workload identity provider. Hidden\n  from the user-facing key list endpoints."},"APIKeyUpdateRequest":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name","description":"New key label."},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description","description":"Updated description for the key."},"permissions":{"anyOf":[{"items":{"$ref":"#/components/schemas/Permission"},"type":"array"},{"type":"null"}],"title":"Permissions","description":"Replace existing permissions with the provided list."},"scopes":{"anyOf":[{"items":{"$ref":"#/components/schemas/ResourceScope-Input"},"type":"array"},{"type":"null"}],"title":"Scopes","description":"Replace existing scopes. Use empty list for global access."},"rate_limit_override":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Rate Limit Override","description":"Updated per-key rate limit override."},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At","description":"New expiration timestamp. Use null to remove expiration."},"status":{"anyOf":[{"$ref":"#/components/schemas/KeyStatus"},{"type":"null"}],"description":"Manually set key status (e.g. revoke)."},"allowed_origins":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Allowed Origins","description":"Replace the key's allowed HTTP origins. Supports exact matches and wildcard subdomains (e.g., 'https://*.example.com'). Use an empty list to remove the origin restriction.","examples":[["https://docs.example.com","https://*.example.com"]]}},"type":"object","title":"APIKeyUpdateRequest","description":"Partial update payload for an API key."},"AcceptanceResult":{"properties":{"passed":{"type":"boolean","title":"Passed","description":"true only when every step, and the cost check, passed"},"steps":{"items":{"$ref":"#/components/schemas/AcceptanceStepResult"},"type":"array","title":"Steps","description":"Each step in manifest order"}},"type":"object","required":["passed"],"title":"AcceptanceResult","description":"The manifest's `acceptance:` steps, run after apply."},"AcceptanceStepResult":{"properties":{"name":{"type":"string","title":"Name","description":"Step name from the manifest"},"kind":{"type":"string","title":"Kind","description":"query, documents, alert or realtime, as the manifest declares; `cost` for the max_cost_usd check that closes the run"},"passed":{"type":"boolean","title":"Passed","description":"true only when the step ran and every expected outcome held. A step that could not run (deadline reached, seed batch failed, resource missing, cost cap reached) is false, with `error` saying why"},"expected":{"additionalProperties":true,"type":"object","title":"Expected","description":"The step's `expect` fields as declared"},"observed":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Observed","description":"What the step measured, e.g. results and top_value for a query, documents for a collection, fires for an alert, dims for a realtime call, spent_usd for the cost check. null when it did not run"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Why the step failed or could not run"}},"type":"object","required":["name","kind","passed"],"title":"AcceptanceStepResult","description":"The outcome of one `acceptance:` step."},"AccountTier":{"type":"string","enum":["build","scale","enterprise","free","pro","team"],"title":"AccountTier","description":"Account tier (2026-07 pricing overhaul).\n\nCurrent tiers (CC-required, tier minimum is a billing floor):\n    BUILD: $25/mo min — 100K objects/mo (managed) / 1M vectors (MVS)\n    SCALE: $250/mo min — 1M objects/mo (managed) / 25M vectors (MVS)\n    ENTERPRISE: Custom — dedicated compute, SLA\n\nLEGACY tiers — still stored on unmigrated orgs; resolvable until the\nPhase-4 migration completes (do NOT remove before then — org records in\nMongo carry these strings):\n    FREE (→ Build or read-only), PRO (→ Build), TEAM (→ Scale)"},"AddDomainRequest":{"properties":{"domain":{"type":"string","title":"Domain","description":"Customer domain (e.g. 'search.acme.com')"},"is_primary":{"type":"boolean","title":"Is Primary","description":"Set as primary domain","default":false}},"type":"object","required":["domain"],"title":"AddDomainRequest"},"AddObjectsToBatchRequest":{"properties":{"object_ids":{"items":{"type":"string"},"type":"array","minItems":1,"title":"Object Ids","description":"A list of object IDs to add to the batch.","examples":[["object_789","object_101"]]}},"type":"object","required":["object_ids"],"title":"AddObjectsToBatchRequest","description":"The request model for adding objects to an existing batch."},"AdhocExecuteRequest":{"properties":{"collection_identifiers":{"items":{"type":"string"},"type":"array","title":"Collection Identifiers","description":"Collection identifiers (names or IDs) to query. Can be collection names or IDs. Names are automatically resolved. Can be empty for query-only inference mode (e.g., LLM query analysis without documents). Also accepts 'collection_ids' as an alias for backward compatibility.","examples":[["my_collection"],["col_abc123","products"],[]]},"input_schema":{"additionalProperties":{"$ref":"#/components/schemas/RetrieverInputSchemaField-Input","description":"Schema definition for this input field. Defines type, description, examples, and validation rules. Supports all bucket types (string, number, image, etc.) plus document_reference. Frontend uses this to render the appropriate input component (text input, image upload, dropdown, etc.)"},"type":"object","title":"Input Schema","description":"OPTIONAL. Input schema defining expected inputs. Each key is an input name, value is a RetrieverInputSchemaField. Omit it (or pass {}) for a stages-only execute whose stages carry hardcoded query values — no dynamic inputs needed.","examples":[{"query":{"description":"Search query","required":true,"type":"text"}},{"query":{"required":true,"type":"text"},"top_k":{"required":false,"type":"integer"}}]},"stages":{"items":{"$ref":"#/components/schemas/StageConfig-Input"},"type":"array","minItems":1,"title":"Stages","description":"REQUIRED. Ordered list of stage configurations. At least one stage is required for execution."},"inputs":{"additionalProperties":true,"type":"object","title":"Inputs","description":"OPTIONAL. Input values matching the input_schema. These values are passed to stages for parameterization. Omit it (or pass {}) when the stages carry hardcoded query values.","examples":[{"query":"machine learning"},{"query":"AI trends","top_k":50}]},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","description":"OPTIONAL. Execute-time filters applied to the document search, the same key the by-id execute request accepts. Merged (AND) with any pre_filters already set inside the stages. Uses the standard LogicalOperator format: {\"AND\": [{\"field\": \"brand\", \"operator\": \"eq\", \"value\": \"Acme\"}]}. Supports operators: eq, ne, in, nin, gt, gte, lt, lte, contains, exists, is_null. A top-level 'pre_filters' is accepted as an alias.","examples":[{"AND":[{"field":"brand","operator":"eq","value":"Acme"}]}]},"budget_limits":{"anyOf":[{"$ref":"#/components/schemas/BudgetLimits"},{"type":"null"}],"description":"OPTIONAL. Budget limits for execution."},"pagination":{"anyOf":[{"oneOf":[{"$ref":"#/components/schemas/OffsetPaginationParams"},{"$ref":"#/components/schemas/CursorPaginationParams"},{"$ref":"#/components/schemas/ScrollPaginationParams"},{"$ref":"#/components/schemas/KeysetPaginationParams"}],"discriminator":{"propertyName":"method","mapping":{"cursor":"#/components/schemas/CursorPaginationParams","keyset":"#/components/schemas/KeysetPaginationParams","offset":"#/components/schemas/OffsetPaginationParams","scroll":"#/components/schemas/ScrollPaginationParams"}}},{"type":"null"}],"title":"Pagination","description":"OPTIONAL. Pagination for the result page, same contract as the by-id execute request (cursor/offset/keyset/scroll). When omitted, the page defaults to the pipeline's declared breadth (final_top_k, or the widest explicit per-search top_k when final_top_k is unset), falling back to 10 when the stages declare no breadth. Previously this field did not exist and a supplied value was silently ignored.","examples":[null,{"limit":50,"method":"cursor"}]},"limit":{"anyOf":[{"type":"integer","maximum":500.0,"minimum":1.0},{"type":"null"}],"title":"Limit","description":"Shorthand for the pagination page size: the most documents this response returns. A top-level 'page_size' is accepted as the same value. Honored only when 'pagination' is absent, as on the by-id execute request; the response's pagination cursor fetches the next page. Sending 'limit' and 'page_size' with different values is refused.","deprecated":true,"examples":[null,50]},"stream":{"type":"boolean","title":"Stream","description":"Enable streaming execution to receive real-time stage updates via Server-Sent Events (SSE). NOT REQUIRED - defaults to False for standard execution. \n\nWhen stream=True:\n- Response Content-Type: text/event-stream\n- Events emitted: stage_start, stage_complete, stage_error, execution_complete, execution_error\n- Each event is formatted as: data: {json}\\n\\n\n- StreamStageEvent contains: event_type, execution_id, stage_name, stage_index, total_stages, documents (intermediate), statistics, budget_used\n\n\nWhen to use streaming:\n- Progress tracking for multi-stage pipelines\n- Displaying intermediate results as stages complete\n- Real-time budget and performance monitoring\n- Debugging pipeline execution\n\n\nWhen to skip streaming:\n- Single-stage or fast pipelines (<100ms)\n- No need for intermediate results\n- Minimizing overhead is critical","default":false,"examples":[false,true]}},"type":"object","required":["stages"],"title":"AdhocExecuteRequest","description":"Request to execute a retriever ad-hoc without persistence.\n\nThis combines retriever creation parameters with execution inputs to allow\none-time retrieval without saving the retriever configuration.\n\nUse Cases:\n    - One-time queries without polluting retriever registry\n    - Testing retriever configurations before persisting\n    - Dynamic retrieval with varying stage configurations\n    - Temporary search operations\n\nBehavior:\n    - Retriever is NOT saved to database\n    - Execution history is logged but marked as ad-hoc\n    - Response includes X-Execution-Mode: adhoc header\n    - execution_metadata.retriever_persisted = False\n\nStreaming Execution (stream=True):\n    When streaming is enabled, the response uses Server-Sent Events (SSE) format\n    with Content-Type: text/event-stream. Each stage emits events as it executes:\n\n    Event Types:\n    - stage_start: Emitted when a stage begins execution\n    - stage_complete: Emitted when a stage finishes with results\n    - stage_error: Emitted if a stage encounters an error\n    - execution_complete: Emitted after all stages finish successfully\n    - execution_error: Emitted if the entire execution fails\n\n    Each event is a StreamStageEvent containing:\n    - event_type: The type of event\n    - execution_id: Unique execution identifier\n    - stage_name: Human-readable stage name\n    - stage_index: Zero-based stage position\n    - total_stages: Total number of stages\n    - documents: Intermediate results (for stage_complete)\n    - statistics: Stage metrics (duration_ms, input_count, output_count, etc.)\n    - budget_used: Cumulative resource consumption (credits, time, tokens)\n\n    Response Headers (streaming):\n    - Content-Type: text/event-stream\n    - Cache-Control: no-cache\n    - Connection: keep-alive\n    - X-Execution-Mode: adhoc\n\n    Example streaming request:\n    ```python\n    response = requests.post(\n        '/v1/retrievers/execute',\n        json={\n            'collection_identifiers': ['my_collection'],\n            'input_schema': {'query': {'type': 'text', 'required': True}},\n            'stages': [...],\n            'inputs': {'query': 'machine learning'},\n            'stream': True\n        },\n        stream=True\n    )\n    for line in response.iter_lines():\n        if line.startswith(b'data: '):\n            event = json.loads(line[6:])\n            print(f\"{event['event_type']}: {event.get('stage_name')}\")\n    ```\n\nStandard Execution (stream=False, default):\n    Returns a single ExecuteRetrieverResponse with final documents,\n    pagination, and aggregate statistics after all stages complete.\n\nExamples:\n    Simple ad-hoc search:\n        {\n            \"collection_identifiers\": [\"col_123\"],\n            \"input_schema\": {\"query\": {\"type\": \"text\", \"required\": True}},\n            \"stages\": [{\n                \"stage_name\": \"search\",\n                \"stage_type\": \"filter\",\n                \"config\": {\n                    \"stage_id\": \"feature_search\",\n                    \"parameters\": {\n                        \"searches\": [{\n                            \"feature_uri\": \"mixpeek://text_extractor@v1/embedding\",\n                            \"query\": {\n                                \"input_mode\": \"text\",\n                                \"text\": \"{{INPUT.query}}\"\n                            },\n                            \"top_k\": 100\n                        }],\n                        \"final_top_k\": 10\n                    }\n                }\n            }],\n            \"inputs\": {\"query\": \"machine learning\"},\n            \"stream\": false\n        }"},"AdhocExecutionDetail":{"properties":{"execution_id":{"type":"string","title":"Execution Id","description":"Unique execution identifier."},"execution_mode":{"type":"string","title":"Execution Mode","description":"Execution mode ('adhoc')."},"status":{"type":"string","title":"Status","description":"Execution status ('completed', 'failed', etc.)."},"timestamp":{"title":"Timestamp","description":"When the execution started (UTC)."},"duration_ms":{"type":"number","minimum":0.0,"title":"Duration Ms","description":"Total execution duration in milliseconds."},"credits_used":{"type":"number","minimum":0.0,"title":"Credits Used","description":"Credits consumed during execution."},"total_processed":{"type":"integer","minimum":0.0,"title":"Total Processed","description":"Total documents processed across all stages."},"total_returned":{"type":"integer","minimum":0.0,"title":"Total Returned","description":"Number of documents returned in final results."},"cache_hit_rate":{"anyOf":[{"type":"number","maximum":1.0,"minimum":0.0},{"type":"null"}],"title":"Cache Hit Rate","description":"Cache hit rate across stages (0.0-1.0)."},"query_summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Query Summary","description":"Brief summary of the query inputs."},"stages_completed":{"type":"integer","minimum":0.0,"title":"Stages Completed","description":"Number of stages completed."},"total_stages":{"type":"integer","minimum":0.0,"title":"Total Stages","description":"Total number of stages in the pipeline."},"collection_ids":{"items":{"type":"string"},"type":"array","title":"Collection Ids","description":"Collections queried during execution."},"inputs":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inputs","description":"Full input data provided for execution."},"inputs_hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inputs Hash","description":"SHA-1 hash of inputs for deduplication."}},"type":"object","required":["execution_id","execution_mode","status","timestamp","duration_ms","credits_used","total_processed","total_returned","stages_completed","total_stages"],"title":"AdhocExecutionDetail","description":"Detailed information about an ad-hoc retriever execution.\n\nExtends AdhocExecutionSummary with full input data and metadata\nfor comprehensive execution analysis."},"AdhocExecutionSummary":{"properties":{"execution_id":{"type":"string","title":"Execution Id","description":"Unique execution identifier."},"execution_mode":{"type":"string","title":"Execution Mode","description":"Execution mode ('adhoc')."},"status":{"type":"string","title":"Status","description":"Execution status ('completed', 'failed', etc.)."},"timestamp":{"title":"Timestamp","description":"When the execution started (UTC)."},"duration_ms":{"type":"number","minimum":0.0,"title":"Duration Ms","description":"Total execution duration in milliseconds."},"credits_used":{"type":"number","minimum":0.0,"title":"Credits Used","description":"Credits consumed during execution."},"total_processed":{"type":"integer","minimum":0.0,"title":"Total Processed","description":"Total documents processed across all stages."},"total_returned":{"type":"integer","minimum":0.0,"title":"Total Returned","description":"Number of documents returned in final results."},"cache_hit_rate":{"anyOf":[{"type":"number","maximum":1.0,"minimum":0.0},{"type":"null"}],"title":"Cache Hit Rate","description":"Cache hit rate across stages (0.0-1.0)."},"query_summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Query Summary","description":"Brief summary of the query inputs."},"stages_completed":{"type":"integer","minimum":0.0,"title":"Stages Completed","description":"Number of stages completed."},"total_stages":{"type":"integer","minimum":0.0,"title":"Total Stages","description":"Total number of stages in the pipeline."},"collection_ids":{"items":{"type":"string"},"type":"array","title":"Collection Ids","description":"Collections queried during execution."}},"type":"object","required":["execution_id","execution_mode","status","timestamp","duration_ms","credits_used","total_processed","total_returned","stages_completed","total_stages"],"title":"AdhocExecutionSummary","description":"Summary of an ad-hoc retriever execution from the analytics store.\n\nProvides high-level execution metadata for ad-hoc retrievers without\nfull document results. Used for listing and filtering execution history."},"AgentConfig":{"properties":{"model":{"type":"string","title":"Model","description":"Anthropic Claude model id the agent runs on, for example 'claude-sonnet-4-5-20250929' (default) or 'claude-haiku-4-5-20251001'. The agent runtime calls Anthropic only: other providers' models and Opus models are refused with 422 when the session is created.","default":"claude-sonnet-4-5-20250929"},"temperature":{"type":"number","maximum":2.0,"minimum":0.0,"title":"Temperature","description":"Sampling temperature for LLM responses (0.0-2.0). Lower values (0.0-0.3) are more deterministic. Higher values (0.8-2.0) are more creative.","default":0.7},"max_tokens":{"type":"integer","maximum":100000.0,"minimum":1.0,"title":"Max Tokens","description":"Maximum tokens per response","default":4096},"system_prompt":{"type":"string","title":"System Prompt","description":"System prompt that defines agent behavior and persona","default":"You are a helpful AI assistant with access to Mixpeek's data infrastructure."},"available_tools":{"items":{"type":"string"},"type":"array","title":"Available Tools","description":"List of API operations the agent is allowed to call. See AvailableTool enum for full list. When provided, the agent's meta-tools will restrict API calls to only these operations. When empty (default), the agent can call any API operation. Key operations: smart_search, execute_retriever, execute_adhoc_retriever, list_collections, list_retrievers, list_buckets, create_upload, analyze_sample_with_pipeline, export_manifest, generate_manifest, detect_intent."}},"type":"object","title":"AgentConfig","description":"Agent configuration for session.\n\nThis config is immutable after session creation (similar to RetrieverConfig).\nTo change agent config, create a new session.\n\nAttributes:\n    model: Anthropic Claude model id. The agent runtime calls Anthropic only;\n        other providers and Opus models are refused at session creation.\n    temperature: Sampling temperature for LLM responses (0.0-2.0)\n        - 0.0-0.3: More deterministic, focused responses\n        - 0.5-0.7: Balanced creativity and coherence\n        - 0.8-2.0: More creative, varied responses\n    max_tokens: Maximum tokens per response (1-100000)\n    system_prompt: System prompt that defines agent behavior and persona\n    available_tools: List of tools the agent can call (see AvailableTool enum)\n\nExample:\n    ```python\n    config = AgentConfig(\n        model=\"claude-sonnet-4-5-20250929\",\n        temperature=0.7,\n        max_tokens=4096,\n        system_prompt=\"You are a helpful video search assistant.\",\n        available_tools=[\n            \"smart_search\",\n            \"execute_retriever\",\n            \"list_collections\"\n        ]\n    )\n    ```","examples":[{"available_tools":["list_retrievers","get_retriever","execute_retriever","list_collections","get_collection"],"max_tokens":4096,"model":"claude-sonnet-4-5-20250929","system_prompt":"You are a video analysis assistant that helps users find and analyze video content.","temperature":0.7},{"available_tools":["list_retrievers","execute_retriever"],"max_tokens":2048,"model":"claude-3-haiku-20240307","system_prompt":"You are a quick search assistant. Be concise.","temperature":0.3}]},"AgentSignupRequest":{"properties":{"email":{"type":"string","format":"email","title":"Email","description":"Email of the person the agent works for. They get one email with a link to keep the key and a link to block it. Until they confirm, the key expires 72 hours after signup.","examples":["dev@example.com"]},"agent_name":{"anyOf":[{"type":"string","maxLength":80},{"type":"null"}],"title":"Agent Name","description":"Name of the agent or tool signing up, shown in that email.","examples":["Claude Code"]},"accept_terms":{"type":"boolean","title":"Accept Terms","description":"Must be true: the email owner's use is governed by the terms at https://mixpeek.com/terms"}},"type":"object","required":["email","accept_terms"],"title":"AgentSignupRequest","description":"What an agent sends to get its own API key."},"AgentSignupResponse":{"properties":{"api_key":{"type":"string","title":"Api Key","description":"Send as 'Authorization: Bearer <api_key>'. Returned once; Mixpeek stores only its hash."},"key_expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Key Expires At","description":"When the key stops working unless the email owner confirms."},"status":{"type":"string","title":"Status","description":"pending_confirmation until the email owner confirms."},"confirmation_sent_to":{"type":"string","title":"Confirmation Sent To","description":"The email that was sent."},"organization_id":{"type":"string","title":"Organization Id","description":"The new organization."},"namespace":{"type":"string","title":"Namespace","description":"Send as the 'X-Namespace' header. It holds a bucket, a collection and a retriever, ready to index and search."},"namespace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Namespace Id","description":"Namespace id, or null if it is still being created."},"bucket":{"type":"string","title":"Bucket","description":"Bucket to upload files into."},"retriever":{"type":"string","title":"Retriever","description":"Retriever to search with."},"credits":{"type":"integer","title":"Credits","description":"Credits the organization starts with."},"next_steps":{"items":{"type":"string"},"type":"array","title":"Next Steps","description":"The calls that take a file to a search result."},"docs_url":{"type":"string","title":"Docs Url","description":"Full API reference."}},"type":"object","required":["api_key","key_expires_at","status","confirmation_sent_to","organization_id","namespace","bucket","retriever","credits","next_steps","docs_url"],"title":"AgentSignupResponse","description":"The key and workspace an agent gets back. The key is shown only here."},"AgglomerativeParams":{"properties":{"n_clusters":{"anyOf":[{"type":"integer","minimum":2.0},{"type":"null"}],"title":"N Clusters","description":"Number of clusters to find. Can be None if distance_threshold is not None","default":2},"affinity":{"type":"string","title":"Affinity","description":"Metric used to compute linkage. Can be 'euclidean', 'l1', 'l2', 'manhattan', 'cosine', or 'precomputed'","default":"euclidean"},"memory":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Memory","description":"Path to the caching directory"},"connectivity":{"anyOf":[{},{"type":"null"}],"title":"Connectivity","description":"Connectivity matrix. Defines which samples are neighbors"},"compute_full_tree":{"type":"string","title":"Compute Full Tree","description":"Whether to compute the full tree ('auto', True, or False)","default":"auto"},"linkage":{"type":"string","title":"Linkage","description":"Linkage criterion ('ward', 'complete', 'average', 'single')","default":"ward"},"distance_threshold":{"anyOf":[{"type":"number","exclusiveMinimum":0.0},{"type":"null"}],"title":"Distance Threshold","description":"The linkage distance threshold above which clusters will not be merged"},"compute_distances":{"type":"boolean","title":"Compute Distances","description":"Whether to compute distances between clusters","default":false}},"type":"object","title":"AgglomerativeParams","description":"Parameters for Agglomerative clustering algorithm."},"AggregationFunction":{"type":"string","enum":["count","count_distinct","sum","avg","min","max","first","last","push","add_to_set"],"title":"AggregationFunction","description":"Supported aggregation functions.\n\nThese functions can be applied to fields during aggregation operations.\n\nValues:\n    COUNT: Count total number of items in each group\n    COUNT_DISTINCT: Count unique values in a field\n    SUM: Sum numeric values\n    AVG: Calculate average of numeric values\n    MIN: Find minimum value\n    MAX: Find maximum value\n    FIRST: Get first value in group\n    LAST: Get last value in group\n    PUSH: Collect all values into an array\n    ADD_TO_SET: Collect unique values into an array\n\nExamples:\n    - Use COUNT for total items per category\n    - Use COUNT_DISTINCT for unique users per day\n    - Use SUM for total revenue\n    - Use AVG for average video duration"},"AggregationOperation":{"properties":{"function":{"$ref":"#/components/schemas/AggregationFunction","description":"The aggregation function to apply. Different functions require different field types: COUNT: no field required. SUM/AVG: numeric fields only. MIN/MAX: numeric or date fields. COUNT_DISTINCT: any field type."},"field":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Field","description":"The field to aggregate. REQUIRED for all functions except COUNT. NOT REQUIRED for COUNT (counts documents). Supports dot notation for nested fields. Field type must be compatible with function.","examples":["metadata.views","metadata.duration","blobs.size","created_at"]},"alias":{"type":"string","title":"Alias","description":"Name for the aggregation result in output. REQUIRED for all operations. Should be descriptive of the calculation. Used to reference results in post-filtering.","examples":["total_count","total_views","avg_duration","max_size"]},"distinct_field":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Distinct Field","description":"Field to count distinct values from. Used by COUNT_DISTINCT; when omitted, `field` is used. Ignored by other functions. Supports dot notation for nested fields.","examples":["metadata.user_id","metadata.ip_address","object_id"]}},"type":"object","required":["function","alias"],"title":"AggregationOperation","description":"Configuration for an aggregation operation.\n\nDefines a calculation to perform on grouped data.\n\nRequirements:\n    - function: REQUIRED, the aggregation function to apply\n    - field: REQUIRED for most functions (except COUNT), field to aggregate\n    - alias: REQUIRED, name for the result in output\n\nExamples:\n    - Count: AggregationOperation(function=\"count\", alias=\"total_count\")\n    - Sum: AggregationOperation(function=\"sum\", field=\"metadata.views\", alias=\"total_views\")\n    - Average: AggregationOperation(function=\"avg\", field=\"metadata.duration\", alias=\"avg_duration\")","examples":[{"alias":"total_count","description":"Count total documents","function":"count"},{"alias":"total_views","description":"Sum all views","field":"metadata.views","function":"sum"},{"alias":"avg_duration","description":"Average duration","field":"metadata.duration","function":"avg"},{"alias":"unique_users","description":"Count unique users","distinct_field":"metadata.user_id","function":"count_distinct"}]},"AggregationResult":{"properties":{"group":{"additionalProperties":true,"type":"object","title":"Group","description":"Grouped field values that define this result row."},"metrics":{"additionalProperties":true,"type":"object","title":"Metrics","description":"Computed aggregation values for this group."}},"type":"object","required":["group","metrics"],"title":"AggregationResult","description":"Single aggregation result row.\n\nContains grouped field values and computed aggregations.","examples":[{"group":{"category":"sports"},"metrics":{"avg_duration":245.3,"total_count":1523}}]},"AlertApplicationConfig-Input":{"properties":{"alert_id":{"type":"string","title":"Alert Id","description":"ID of the alert to execute","examples":["alt_safety_001","alt_content_moderation"]},"execution_mode":{"$ref":"#/components/schemas/AlertExecutionMode","description":"When this alert should execute","default":"on_ingest"},"input_mappings":{"items":{"$ref":"#/components/schemas/AlertInputMapping"},"type":"array","minItems":1,"title":"Input Mappings","description":"Map document fields or constants to retriever input parameters"},"execution_phase":{"$ref":"#/components/schemas/PostProcessingPhase","description":"Which phase this alert runs in. Default: ALERT (phase 3, after taxonomies and clusters)","default":3},"priority":{"type":"integer","maximum":1000.0,"minimum":0.0,"title":"Priority","description":"Priority within the execution phase (higher = runs first)","default":0}},"additionalProperties":false,"type":"object","required":["alert_id","input_mappings"],"title":"AlertApplicationConfig","description":"Configuration for attaching an alert to a collection.\n\nThe key responsibility here is INPUT MAPPING: connecting document\nfields (or constants) to the retriever's expected inputs.\n\nNote: Filtering logic (scroll_filters, min_score, etc.) belongs in\nthe retriever, not here. The retriever owns all query semantics.\n\nUse Cases:\n    - Attach safety alert to video upload collection\n    - Configure different field mappings for different collections\n    - Set execution priority for multiple alerts\n\nAttributes:\n    alert_id: ID of the alert to execute\n    execution_mode: When this alert should execute\n    input_mappings: Map document fields or constants to retriever inputs\n    execution_phase: Which phase this alert runs in (default: ALERT)\n    priority: Priority within the execution phase (higher = runs first)","examples":[{"alert_id":"alt_safety_001","execution_mode":"on_ingest","execution_phase":3,"input_mappings":[{"input_key":"query_embedding","source":{"path":"features.video_embedding","source_type":"document_field"}},{"input_key":"target_collection","source":{"source_type":"constant","value":"col_known_incidents"}}],"priority":100}]},"AlertApplicationConfig-Output":{"properties":{"alert_id":{"type":"string","title":"Alert Id","description":"ID of the alert to execute","examples":["alt_safety_001","alt_content_moderation"]},"execution_mode":{"$ref":"#/components/schemas/AlertExecutionMode","description":"When this alert should execute","default":"on_ingest"},"input_mappings":{"items":{"$ref":"#/components/schemas/AlertInputMapping"},"type":"array","minItems":1,"title":"Input Mappings","description":"Map document fields or constants to retriever input parameters"},"execution_phase":{"$ref":"#/components/schemas/PostProcessingPhase","description":"Which phase this alert runs in. Default: ALERT (phase 3, after taxonomies and clusters)","default":3},"priority":{"type":"integer","maximum":1000.0,"minimum":0.0,"title":"Priority","description":"Priority within the execution phase (higher = runs first)","default":0}},"additionalProperties":false,"type":"object","required":["alert_id","input_mappings"],"title":"AlertApplicationConfig","description":"Configuration for attaching an alert to a collection.\n\nThe key responsibility here is INPUT MAPPING: connecting document\nfields (or constants) to the retriever's expected inputs.\n\nNote: Filtering logic (scroll_filters, min_score, etc.) belongs in\nthe retriever, not here. The retriever owns all query semantics.\n\nUse Cases:\n    - Attach safety alert to video upload collection\n    - Configure different field mappings for different collections\n    - Set execution priority for multiple alerts\n\nAttributes:\n    alert_id: ID of the alert to execute\n    execution_mode: When this alert should execute\n    input_mappings: Map document fields or constants to retriever inputs\n    execution_phase: Which phase this alert runs in (default: ALERT)\n    priority: Priority within the execution phase (higher = runs first)","examples":[{"alert_id":"alt_safety_001","execution_mode":"on_ingest","execution_phase":3,"input_mappings":[{"input_key":"query_embedding","source":{"path":"features.video_embedding","source_type":"document_field"}},{"input_key":"target_collection","source":{"source_type":"constant","value":"col_known_incidents"}}],"priority":100}]},"AlertChannelDelivery":{"properties":{"channel_type":{"type":"string","title":"Channel Type","description":"The channel's type, e.g. webhook"},"status":{"type":"string","title":"Status","description":"delivered, failed, deferred or not_configured"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Why the delivery failed, when it did"}},"type":"object","required":["channel_type","status"],"title":"AlertChannelDelivery","description":"The outcome of one notification channel for one alert execution."},"AlertExecutionListResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/AlertExecutionResult"},"type":"array","title":"Results","description":"List of execution results"},"pagination":{"$ref":"#/components/schemas/PaginationResponse","description":"Pagination information"},"total_count":{"type":"integer","title":"Total Count","description":"Total number of executions"}},"type":"object","required":["results","pagination","total_count"],"title":"AlertExecutionListResponse","description":"Response model for listing alert executions."},"AlertExecutionMode":{"type":"string","enum":["on_ingest","scheduled","on_demand"],"title":"AlertExecutionMode","description":"When the alert should execute."},"AlertExecutionResult":{"properties":{"alert_id":{"type":"string","title":"Alert Id","description":"ID of the alert that was executed"},"collection_id":{"type":"string","title":"Collection Id","description":"Collection the alert was executed against"},"execution_id":{"type":"string","title":"Execution Id","description":"Unique identifier for this execution"},"triggered":{"type":"boolean","title":"Triggered","description":"Whether the alert was triggered"},"match_count":{"type":"integer","minimum":0.0,"title":"Match Count","description":"Number of matches found"},"matches":{"anyOf":[{"items":{"$ref":"#/components/schemas/AlertMatchResult"},"type":"array"},{"type":"null"}],"title":"Matches","description":"List of match results"},"source_documents":{"items":{"type":"string"},"type":"array","title":"Source Documents","description":"Document IDs that triggered the alert check"},"executed_at":{"type":"string","title":"Executed At","description":"ISO 8601 timestamp when the alert was executed"},"duration_ms":{"type":"integer","minimum":0.0,"title":"Duration Ms","description":"How long the execution took in milliseconds"},"deliveries":{"anyOf":[{"items":{"$ref":"#/components/schemas/AlertChannelDelivery"},"type":"array"},{"type":"null"}],"title":"Deliveries","description":"What happened to each notification channel when the alert fired: delivered, failed (with the error), deferred to the end of the channel's delivery window, or not_configured. Null when the alert did not fire."}},"type":"object","required":["alert_id","collection_id","triggered","match_count","executed_at","duration_ms"],"title":"AlertExecutionResult","description":"Result of an alert execution.\n\nCaptures the outcome of running an alert against one or more documents,\nincluding whether the alert was triggered and what matched.\n\nAttributes:\n    alert_id: ID of the alert that was executed\n    collection_id: Collection the alert was executed against\n    execution_id: Unique identifier for this execution\n    triggered: Whether the alert was triggered (i.e., retriever returned results)\n    match_count: Number of matches found\n    matches: List of match results (if include_matches was True)\n    source_documents: Document IDs that triggered the alert check\n    executed_at: When the alert was executed\n    duration_ms: How long the execution took"},"AlertInputMapping":{"properties":{"input_key":{"type":"string","title":"Input Key","description":"The retriever input parameter name","examples":["query_embedding","collection_id","category_filter"]},"source":{"$ref":"#/components/schemas/InputMappingSource","description":"Where to get the value from"}},"type":"object","required":["input_key","source"],"title":"AlertInputMapping","description":"Maps a retriever input to a document field or constant.\n\nInput mappings define how to construct retriever inputs from the\ningested document. This allows the same alert to be used with\ndifferent collections that have different field structures.\n\nExamples:\n    # Map document embedding to retriever query\n    {\n        \"input_key\": \"query_embedding\",\n        \"source\": {\"source_type\": \"document_field\", \"path\": \"features.video_embedding\"}\n    }\n\n    # Use constant collection for search target\n    {\n        \"input_key\": \"collection_id\",\n        \"source\": {\"source_type\": \"constant\", \"value\": \"col_known_incidents\"}\n    }\n\nAttributes:\n    input_key: The retriever input parameter name\n    source: Where to get the value from","examples":[{"input_key":"query_embedding","source":{"path":"features.video_embedding","source_type":"document_field"}},{"input_key":"target_collection","source":{"source_type":"constant","value":"col_known_incidents"}}]},"AlertListStats":{"properties":{"total_alerts":{"type":"integer","title":"Total Alerts","description":"Total number of alerts","default":0},"enabled_alerts":{"type":"integer","title":"Enabled Alerts","description":"Number of enabled alerts","default":0},"disabled_alerts":{"type":"integer","title":"Disabled Alerts","description":"Number of disabled alerts","default":0},"alerts_by_channel_type":{"additionalProperties":{"type":"integer"},"type":"object","title":"Alerts By Channel Type","description":"Count of alerts by notification channel type"}},"type":"object","title":"AlertListStats","description":"Aggregate statistics for a list of alerts."},"AlertMatchResult":{"properties":{"document_id":{"type":"string","title":"Document Id","description":"ID of the matched document"},"asset_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Asset Id","description":"Asset ID of the matched document"},"score":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Score","description":"Similarity/relevance score"},"matched_features":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Matched Features","description":"Features that caused the match. A retriever using learned fusion returns a list with one entry per search that found the document (feature_uri, raw_score, rank, weight, contribution)."},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Metadata from the matched document"}},"type":"object","required":["document_id","score"],"title":"AlertMatchResult","description":"A single match from alert execution.\n\nRepresents a document that matched the retriever's query criteria.\n\nAttributes:\n    document_id: ID of the matched document\n    asset_id: Asset ID of the matched document\n    score: Similarity/relevance score\n    matched_features: Optional features that caused the match\n    metadata: Optional metadata from the matched document"},"AlertNotificationConfig":{"properties":{"channels":{"items":{"$ref":"#/components/schemas/NotificationChannelConfig"},"type":"array","minItems":1,"title":"Channels","description":"List of notification channels to send alerts to"},"include_matches":{"type":"boolean","title":"Include Matches","description":"Include matched documents in notification payload","default":true},"include_scores":{"type":"boolean","title":"Include Scores","description":"Include similarity scores in notification payload","default":true},"template_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Template Id","description":"Optional notification template for formatting"}},"type":"object","required":["channels"],"title":"AlertNotificationConfig","description":"How and where to send notifications when an alert is triggered.\n\nDefines the notification channels and what information to include\nin the notification payload.\n\nAttributes:\n    channels: List of channels to send notifications to\n    include_matches: Whether to include matched documents in the payload\n    include_scores: Whether to include similarity scores in the payload\n    template_id: Optional template for formatting the notification","examples":[{"channels":[{"channel_id":"wh_safety_team","channel_type":"webhook"},{"channel_id":"sl_alerts","channel_type":"slack"}],"include_matches":true,"include_scores":true}]},"AlertResponse":{"properties":{"alert_id":{"type":"string","title":"Alert Id","description":"Unique identifier for the alert","examples":["alt_abc123xyz789"]},"namespace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Namespace Id","description":"Namespace this alert belongs to","examples":["ns_production","ns_staging"]},"name":{"type":"string","maxLength":200,"minLength":1,"title":"Name","description":"Human-readable name for the alert","examples":["Safety Incident Detector","Prohibited Content Alert"]},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description","description":"Optional description of what this alert monitors","examples":["Alerts when new videos match known safety incidents"]},"source":{"$ref":"#/components/schemas/AlertSource","description":"Trigger source: 'retriever' (runs a retriever) or 'system' (built-in metric)","default":"retriever"},"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id","description":"ID of the retriever to execute (source=retriever only). The retriever defines filters, scoring, limits.","examples":["ret_safety_search","ret_prohibited_content"]},"trigger_on":{"$ref":"#/components/schemas/TriggerOn","description":"For source=retriever: fire on 'results' (matches found, narrowed by min_count and threshold when set) or 'no_results' (retriever went dark).","default":"results"},"min_count":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Min Count","description":"With trigger_on='results': fire only when the retriever returns at least this many rows.","examples":[3]},"threshold":{"anyOf":[{"$ref":"#/components/schemas/AlertThreshold"},{"type":"null"}],"description":"With trigger_on='results': fire only when the first result meets this comparison."},"inputs":{"additionalProperties":true,"type":"object","title":"Inputs","description":"Retriever inputs this alert runs with. The sweep runs the retriever with exactly these, so a templated window such as {{time_ago(minutes=INPUT.window_minutes)}} keeps its window. At ingest, inputs mapped from the document override keys set here.","examples":[{"window_minutes":60}]},"cooldown_seconds":{"type":"integer","maximum":2592000.0,"minimum":0.0,"title":"Cooldown Seconds","description":"After the alert fires, further fires within this many seconds are suppressed, on every path. 0 means no cooldown.","default":0,"examples":[3600]},"renotify_interval_seconds":{"anyOf":[{"type":"integer","maximum":2592000.0,"minimum":60.0},{"type":"null"}],"title":"Renotify Interval Seconds","description":"While the condition stays true, notify again at this interval. Unset means notify once per rise. Never fires inside cooldown_seconds.","examples":[21600]},"last_fired_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Fired At","description":"When the alert last notified. Set by the platform; read-only."},"system_condition":{"anyOf":[{"$ref":"#/components/schemas/SystemCondition"},{"type":"null"}],"description":"Built-in data-plane condition to watch (source=system only)"},"namespace_selector":{"anyOf":[{"$ref":"#/components/schemas/NamespaceSelector"},{"type":"null"}],"description":"Org-level namespace scoping (all vs selected). When omitted, the alert is scoped to its own namespace_id."},"notification_config":{"$ref":"#/components/schemas/AlertNotificationConfig","description":"How and where to send notifications when alert triggers"},"enabled":{"type":"boolean","title":"Enabled","description":"Whether the alert is active and will execute","default":true},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"Timestamp when the alert was created"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"Timestamp when the alert was last updated"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Additional user-defined metadata for the alert"}},"type":"object","required":["name","notification_config"],"title":"AlertResponse","description":"Response model for a single alert.","examples":[{"alert_id":"alt_safety_001","description":"Alerts when new videos match known safety incidents","enabled":true,"name":"Safety Incident Detector","notification_config":{"channels":[{"channel_id":"wh_safety_team","channel_type":"webhook"}],"include_matches":true,"include_scores":true},"retriever_id":"ret_safety_search"}]},"AlertSource":{"type":"string","enum":["retriever","system"],"title":"AlertSource","description":"Where an alert's trigger decision comes from.\n\nSend the lowercase wire value (shown in quotes), NOT the member name.\n\n\"retriever\": runs a retriever against ingested data and fires on (no-)match.\n             \"Does my data contain something?\"\n\"system\":    evaluates a built-in data-plane metric against a threshold.\n             \"Is my pipeline / data healthy?\" No retriever involved."},"AlertThreshold":{"properties":{"field":{"type":"string","minLength":1,"title":"Field","description":"Field of the first result to compare. A top-level key (score, an aggregate column) or a dot path; a bare name not at the top level is also read from the result's metadata.","examples":["score","metadata.price","count"]},"operator":{"type":"string","enum":["gt","gte","lt","lte","eq","ne"],"title":"Operator","description":"Comparison applied as <field value> <operator> <value>."},"value":{"title":"Value","description":"Value the field is compared against.","examples":[0.9,100,"failed"]}},"type":"object","required":["field","operator","value"],"title":"AlertThreshold","description":"A comparison on one field of the first result (with ``trigger_on='results'``)."},"AlignmentMetrics":{"properties":{"ndcg_at_k":{"additionalProperties":{"type":"number"},"type":"object","title":"Ndcg At K","description":"Normalized Discounted Cumulative Gain at various K values."},"mean_rank_clicked":{"type":"number","title":"Mean Rank Clicked","description":"Average position of clicked items in the new ranking."},"mean_rank_purchased":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Mean Rank Purchased","description":"Average position of purchased items (if any purchases observed)."},"recall_at_k":{"additionalProperties":{"type":"number"},"type":"object","title":"Recall At K","description":"Fraction of interacted items found in top K results."},"avg_position_delta":{"type":"number","title":"Avg Position Delta","description":"Average change in position for interacted items (negative = promoted)."},"items_promoted":{"type":"integer","minimum":0.0,"title":"Items Promoted","description":"Number of interacted items moved to higher positions."},"items_demoted":{"type":"integer","minimum":0.0,"title":"Items Demoted","description":"Number of interacted items moved to lower positions."},"sessions_improved":{"type":"integer","minimum":0.0,"title":"Sessions Improved","description":"Sessions where candidate outperformed baseline."},"sessions_degraded":{"type":"integer","minimum":0.0,"title":"Sessions Degraded","description":"Sessions where candidate underperformed baseline."},"sessions_neutral":{"type":"integer","minimum":0.0,"title":"Sessions Neutral","description":"Sessions with no significant difference."}},"type":"object","required":["ndcg_at_k","mean_rank_clicked","recall_at_k","avg_position_delta","items_promoted","items_demoted","sessions_improved","sessions_degraded","sessions_neutral"],"title":"AlignmentMetrics","description":"Metrics measuring how well a ranking aligns with observed user behavior.\n\nThese metrics compare a candidate pipeline's ranking against ground truth\nderived from actual user interactions (clicks, purchases, etc.).","examples":[{"avg_position_delta":-1.5,"items_demoted":45,"items_promoted":120,"mean_rank_clicked":4.2,"mean_rank_purchased":2.8,"ndcg_at_k":{"5":0.78,"10":0.82,"20":0.85},"recall_at_k":{"5":0.65,"10":0.8,"20":0.92},"sessions_degraded":210,"sessions_improved":580,"sessions_neutral":210}]},"AnalysisType":{"type":"string","enum":["transitions","paths"],"title":"AnalysisType","description":"Kind of taxonomy step-analytics computed for a persisted run.\n\nAttributes:\n    TRANSITIONS: Direct A→B transition analytics (conversion rate, durations,\n        predictor lifts) produced by the ``/analytics/transitions`` endpoint.\n    PATHS: Multi-step path discovery produced by the ``/analytics/paths``\n        endpoint."},"AnnotationResponse":{"properties":{"annotation_id":{"type":"string","title":"Annotation Id","description":"Unique annotation identifier."},"document_id":{"type":"string","title":"Document Id","description":"The document this annotation is attached to."},"collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Collection Id","description":"Collection the document belongs to."},"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace scope."},"label":{"type":"string","maxLength":100,"minLength":1,"title":"Label","description":"Human decision label. Domain-specific — e.g. 'approved', 'rejected', 'deferred', 'infringement', 'safe', 'confirmed_dupe'."},"confidence":{"anyOf":[{"type":"number","maximum":1.0,"minimum":0.0},{"type":"null"}],"title":"Confidence","description":"Human confidence in this decision (0.0–1.0)."},"reasoning":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}],"title":"Reasoning","description":"Why this decision was made. Stored for audit trail."},"payload":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Payload","description":"Use-case-specific structured data. E.g. {'codes_approved': ['E11.40'], 'raf_impact': 0.302}"},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Custom metadata attached by the caller. Stored and returned as-is, kept separate from the structured payload."},"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id","description":"Retriever that produced the document being annotated."},"execution_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Execution Id","description":"Retriever execution ID."},"stage_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stage Name","description":"Stage that produced the result (e.g. 'llm_enrich')."},"actor_id":{"type":"string","title":"Actor Id","description":"Who made the annotation (user ID or API key ID).","default":"system"},"actor_type":{"type":"string","title":"Actor Type","description":"Actor type: 'user', 'api_key', or 'system'.","default":"system"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"version":{"type":"integer","title":"Version","description":"Current version; starts at 1, bumps per edit.","default":1},"revisions":{"items":{"$ref":"#/components/schemas/AnnotationRevision"},"type":"array","title":"Revisions","description":"Backward deltas preserving every superseded version."}},"type":"object","required":["document_id","namespace_id","label"],"title":"AnnotationResponse","description":"Single annotation response.","examples":[{"actor_id":"user_eric","actor_type":"user","annotation_id":"ann_abc123def4567890","collection_id":"col_notes","confidence":0.95,"document_id":"doc_xyz","label":"approved","namespace_id":"ns_vitae","payload":{"codes_approved":["E11.40","E11.65"],"raf_impact":0.42},"reasoning":"Note clearly documents peripheral neuropathy.","retriever_id":"ret_hcc_review"}]},"AnnotationRevision":{"properties":{"version":{"type":"integer","title":"Version","description":"The version number this revision PRESERVES (pre-edit)."},"prior":{"additionalProperties":true,"type":"object","title":"Prior","description":"Pre-edit values of the fields the superseding edit changed. Applying these onto the next-newer state reconstructs this version."},"edited_at":{"type":"string","format":"date-time","title":"Edited At","description":"When the edit that superseded this version happened."},"edited_by":{"type":"string","title":"Edited By","description":"Actor who made the superseding edit (user or API key id)."},"edited_by_type":{"type":"string","title":"Edited By Type","description":"Actor type of the superseding editor."}},"type":"object","required":["version","prior","edited_at","edited_by","edited_by_type"],"title":"AnnotationRevision","description":"One superseded state of an edited annotation.\n\nA judgment edit must not destroy the judgment it replaces: evaluations\nthat scored against version N are unreproducible if N is gone. Each edit\nappends one of these BACKWARD deltas — the pre-edit values of exactly the\nfields the edit changed — so any prior version reconstructs by walking\nthe chain newest-to-oldest. Edits are rare, so the chain lives on the\nannotation document itself."},"AnnotationStatsResponse":{"properties":{"total":{"type":"integer","title":"Total","default":0},"by_label":{"additionalProperties":{"type":"integer"},"type":"object","title":"By Label"}},"type":"object","title":"AnnotationStatsResponse","description":"Aggregate stats for annotations."},"AnnotationVersionDescriptor":{"properties":{"version":{"type":"integer","title":"Version","description":"Version number."},"current":{"type":"boolean","title":"Current","description":"True for the live version.","default":false},"edited_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Edited At","description":"When this version was CREATED (the edit that produced it); None for version 1, whose creation time is the annotation's created_at."},"edited_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Edited By","description":"Who produced this version (None for version 1)."},"edited_by_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Edited By Type"},"changed_fields":{"items":{"type":"string"},"type":"array","title":"Changed Fields","description":"Fields the edit producing this version changed."}},"type":"object","required":["version"],"title":"AnnotationVersionDescriptor","description":"One entry in an annotation's version history."},"AnnotationVersionsResponse":{"properties":{"annotation_id":{"type":"string","title":"Annotation Id"},"current_version":{"type":"integer","title":"Current Version"},"versions":{"items":{"$ref":"#/components/schemas/AnnotationVersionDescriptor"},"type":"array","title":"Versions"}},"type":"object","required":["annotation_id","current_version"],"title":"AnnotationVersionsResponse","description":"Full version history of one annotation."},"AnthropicModel":{"type":"string","enum":["claude-sonnet-4-5-20250929","claude-haiku-4-5-20251001","claude-3-5-sonnet-20241022","claude-3-5-haiku-20241022"],"title":"AnthropicModel","description":"Anthropic Claude model identifiers for LLM generation.\n\nClaude models excel at long context, complex reasoning, and safety.\nAll models support text and images.\n\nValues:\n    CLAUDE_3_5_SONNET: Most capable Claude model\n        - Use for: Complex reasoning, long documents, safety-critical\n        - Context: 200K tokens\n        - Vision: Yes\n        - Cost: $3/1M input, $15/1M output\n        - Performance: 300-800ms per request\n        - When to use: Need best reasoning, safety, or long context\n\n    CLAUDE_3_5_HAIKU: Fast, cost-effective Claude model\n        - Use for: High-volume, quick summaries\n        - Context: 200K tokens\n        - Vision: Yes\n        - Cost: $0.25/1M input, $1.25/1M output\n        - Performance: 100-300ms per request\n        - When to use: Good balance of quality and cost\n\nExamples:\n    - Use CLAUDE_3_5_SONNET for complex entity extraction from contracts (best reasoning)\n    - Use CLAUDE_3_5_HAIKU for high-volume content moderation (cost-effective)"},"ApiAllowRule":{"properties":{"methods":{"items":{"type":"string"},"type":"array","title":"Methods","description":"HTTP methods this rule allows (e.g. ['GET', 'POST'])."},"pattern":{"type":"string","title":"Pattern","description":"URL path pattern the app may proxy (e.g. '/v1/retrievers/*/execute')."}},"additionalProperties":true,"type":"object","required":["pattern"],"title":"ApiAllowRule","description":"One per-app /api proxy allowlist rule.\n\nEach rule WIDENS the deny-by-default fleet allowlist for a single app: the\ncanvas /api proxy lets the app proxy requests matching ``pattern`` with one of\n``methods``. Absent api_allow means the fleet default allowlist only."},"AppAnalyticsResponse":{"properties":{"app_id":{"type":"string","title":"App Id"},"period_hours":{"type":"integer","title":"Period Hours"},"total_errors":{"type":"integer","title":"Total Errors"},"error_rate_per_minute":{"type":"number","title":"Error Rate Per Minute"},"errors_over_time":{"items":{"$ref":"#/components/schemas/ErrorBucket"},"type":"array","title":"Errors Over Time"},"vitals":{"items":{"$ref":"#/components/schemas/VitalsSummary"},"type":"array","title":"Vitals"},"recent_errors":{"items":{"$ref":"#/components/schemas/RecentError"},"type":"array","title":"Recent Errors"},"total_events":{"type":"integer","title":"Total Events"},"total_pageviews":{"type":"integer","title":"Total Pageviews"}},"type":"object","required":["app_id","period_hours","total_errors","error_rate_per_minute","errors_over_time","vitals","recent_errors","total_events","total_pageviews"],"title":"AppAnalyticsResponse"},"AppInvitationResponse":{"properties":{"invitation_id":{"type":"string","title":"Invitation Id"},"email_address":{"type":"string","title":"Email Address"},"role":{"type":"string","title":"Role"},"status":{"type":"string","title":"Status"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["invitation_id","email_address","role","status"],"title":"AppInvitationResponse"},"AppListItem":{"properties":{"app_id":{"type":"string","title":"App Id"},"slug":{"type":"string","title":"Slug"},"url":{"type":"string","title":"Url"},"meta":{"$ref":"#/components/schemas/PageMeta"},"is_active":{"type":"boolean","title":"Is Active"},"version":{"type":"integer","title":"Version"},"has_unpublished_changes":{"type":"boolean","title":"Has Unpublished Changes","default":false},"template":{"type":"string","title":"Template"},"custom_domains":{"items":{"$ref":"#/components/schemas/CustomDomainConfig"},"type":"array","title":"Custom Domains"},"auth_config":{"anyOf":[{"$ref":"#/components/schemas/AuthConfig-Output"},{"type":"null"}]},"build_config":{"anyOf":[{"$ref":"#/components/schemas/BuildConfig"},{"type":"null"}]},"monitoring_config":{"anyOf":[{"$ref":"#/components/schemas/MonitoringConfig"},{"type":"null"}]},"repo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repo Url"},"repo_branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repo Branch"},"environments":{"additionalProperties":true,"type":"object","title":"Environments"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["app_id","slug","url","meta","is_active","version","template","custom_domains"],"title":"AppListItem","description":"Lightweight app summary for list endpoints.\n\nExcludes heavy fields (sections, custom_html, tabs, versions,\nfeatured_gallery) that can make the full list response 10-30 MB.\nUse GET /apps/{app_id} for the complete record."},"AppLogsResponse":{"properties":{"app_id":{"type":"string","title":"App Id"},"log_type":{"type":"string","title":"Log Type"},"results":{"items":{},"type":"array","title":"Results","description":"Log entries — the platform-standard envelope key (every other list endpoint returns 'results'). Same content as 'entries'."},"entries":{"items":{},"type":"array","title":"Entries","description":"DEPRECATED alias of 'results', kept for existing consumers. This endpoint predated the platform envelope convention; parse 'results'.","deprecated":true}},"type":"object","required":["app_id","log_type"],"title":"AppLogsResponse"},"AppResponse":{"properties":{"app_id":{"type":"string","title":"App Id"},"slug":{"type":"string","title":"Slug"},"url":{"type":"string","title":"Url","description":"Canonical published URL (https://{slug}.mxp.co)"},"meta":{"$ref":"#/components/schemas/PageMeta"},"is_active":{"type":"boolean","title":"Is Active"},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings","description":"Non-fatal advisories about the request that was just applied. Currently used to spell out the effect of a takedown write, e.g. 'is_active: false' makes the canvas runtime refuse the app's URL with a 404 within its serving-cache window, and the note says how to verify that. Additive and safe to ignore."},"version":{"type":"integer","title":"Version"},"has_unpublished_changes":{"type":"boolean","title":"Has Unpublished Changes","default":false},"custom_domains":{"items":{"$ref":"#/components/schemas/CustomDomainConfig"},"type":"array","title":"Custom Domains"},"auth_config":{"anyOf":[{"$ref":"#/components/schemas/AuthConfig-Output"},{"type":"null"}]},"build_config":{"anyOf":[{"$ref":"#/components/schemas/BuildConfig"},{"type":"null"}]},"monitoring_config":{"anyOf":[{"$ref":"#/components/schemas/MonitoringConfig"},{"type":"null"}]},"repo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repo Url"},"repo_branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repo Branch"},"github_installation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Github Installation Id"},"versions":{"items":{"$ref":"#/components/schemas/VersionRecord"},"type":"array","title":"Versions","description":"Deploy version history with timestamps and environment info"},"environments":{"additionalProperties":true,"type":"object","title":"Environments"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"template":{"type":"string","title":"Template","deprecated":true},"sections":{"items":{"$ref":"#/components/schemas/SectionConfig"},"type":"array","title":"Sections","deprecated":true},"custom_html":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Html","deprecated":true},"hero":{"anyOf":[{"$ref":"#/components/schemas/HeroConfig"},{"type":"null"}],"deprecated":true},"theme":{"$ref":"#/components/schemas/ThemeConfig","deprecated":true},"seo":{"anyOf":[{"$ref":"#/components/schemas/SEOConfig"},{"type":"null"}],"deprecated":true},"stats":{"items":{"$ref":"#/components/schemas/StatItem"},"type":"array","title":"Stats","deprecated":true},"featured_gallery":{"anyOf":[{"$ref":"#/components/schemas/FeaturedGalleryConfig-Output"},{"type":"null"}],"deprecated":true},"tabs":{"items":{"$ref":"#/components/schemas/PageTab-Output"},"type":"array","title":"Tabs","deprecated":true},"password_protected":{"type":"boolean","title":"Password Protected","deprecated":true}},"type":"object","required":["app_id","slug","url","meta","is_active","version","custom_domains","auth_config","build_config","environments","created_at","updated_at","template","sections","custom_html","hero","theme","seo","stats","featured_gallery","tabs","password_protected"],"title":"AppResponse","description":"Response model for an App.\n\nDeploy-based apps use ``versions``, ``environments``, ``build_config``,\nand ``auth_config``.  Legacy page-builder fields (``template``,\n``sections``, ``custom_html``, ``hero``, ``theme``, ``seo``, ``stats``,\n``featured_gallery``, ``tabs``, ``password_protected``) are included\nfor backward compatibility but **deprecated**."},"AppUserResponse":{"properties":{"user_id":{"type":"string","title":"User Id"},"membership_id":{"type":"string","title":"Membership Id"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"avatar_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Avatar Url"},"role":{"type":"string","title":"Role"},"joined_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Joined At"}},"type":"object","required":["user_id","membership_id","role"],"title":"AppUserResponse"},"ApplyMode":{"type":"string","enum":["create_only","create_missing","upsert"],"title":"ApplyMode","description":"Mode for applying manifests."},"ApplyNextStep":{"properties":{"retriever":{"type":"string","title":"Retriever","description":"Retriever name from the manifest"},"retriever_id":{"type":"string","title":"Retriever Id","description":"The retriever's id"},"namespace":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Namespace","description":"Namespace name from the manifest, sent as X-Namespace"},"execute_url":{"type":"string","title":"Execute Url","description":"POST here with {\"inputs\": ...} to run the retriever"},"inputs":{"additionalProperties":true,"type":"object","title":"Inputs","description":"Inputs for a first query: the manifest's acceptance query for this retriever when it has one, otherwise each required input of the retriever's input_schema as a <placeholder> to fill in"},"inputs_proven":{"type":"boolean","title":"Inputs Proven","description":"true when `inputs` is the manifest's acceptance query. It answered only if that acceptance step passed on this apply","default":false},"curl":{"type":"string","title":"Curl","description":"A curl that runs the query; set MIXPEEK_API_KEY first"},"studio_url":{"type":"string","title":"Studio Url","description":"The retriever in Studio"}},"type":"object","required":["retriever","retriever_id","execute_url","curl","studio_url"],"title":"ApplyNextStep","description":"How to query one retriever the apply created or found."},"ApplyPromoRequest":{"properties":{"code":{"type":"string","maxLength":64,"minLength":1,"title":"Code"}},"type":"object","required":["code"],"title":"ApplyPromoRequest"},"ApplyPromoResponse":{"properties":{"applied":{"type":"boolean","title":"Applied"},"code":{"type":"string","title":"Code"},"percent_off":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Percent Off"},"amount_off_cents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Amount Off Cents"},"duration":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Duration"},"duration_in_months":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration In Months"},"expires_at":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Expires At"}},"type":"object","required":["applied","code"],"title":"ApplyPromoResponse"},"ApplyResult":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether all resources were created successfully"},"resources":{"items":{"$ref":"#/components/schemas/ResourceResult"},"type":"array","title":"Resources","description":"Results for each resource"},"created_count":{"type":"integer","title":"Created Count","description":"Number of resources created","default":0},"failed_count":{"type":"integer","title":"Failed Count","description":"Number of resources that failed","default":0},"skipped_count":{"type":"integer","title":"Skipped Count","description":"Number of resources skipped","default":0},"would_create_count":{"type":"integer","title":"Would Create Count","description":"On a dry run, the number of resources the real apply would create. Resources that already exist are reported with status `exists` and are not counted here. Always 0 on a real apply.","default":0},"updated_count":{"type":"integer","title":"Updated Count","description":"Resources that existed, differed, and were PATCHED to match. Only ever non-zero under `upsert`. Counted separately because without it an upsert that changed five running resources reports created 0, failed 0, skipped 0, a summary that reads as nothing having happened.","default":0},"errors":{"items":{"type":"string"},"type":"array","title":"Errors","description":"Error messages"},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings","description":"Non-fatal issues found while PARSING the manifest, chiefly keys the parser had to drop. the parser already detects these and /validate and /lint already surface them, but /apply computed them and threw them away — so anyone applying without validating first got a 201 and no hint that part of their manifest was ignored. A collection-level `field_passthrough:` is the case that cost a customer POC: detected, described, discarded."},"rollback_performed":{"type":"boolean","title":"Rollback Performed","description":"Whether a rollback was ATTEMPTED after a failure. this used to read as 'the namespace was returned to its prior state', which it does not mean — rollback deletes only namespaces and buckets today, so any other resource created before the failure SURVIVES. Read `rollback_orphans` to find out what is still there.","default":false},"rollback_orphans":{"items":{"type":"string"},"type":"array","title":"Rollback Orphans","description":"Resources created before the failure that rollback did NOT delete, as '<type>/<id>'. Non-empty means the namespace is in a PARTIAL state and a straight retry will hit AlreadyExists on these. previously these were silently skipped while rollback_performed=true claimed otherwise, which is the state that had to be unpicked by hand on the Radio-Canada POC."},"dry_run":{"type":"boolean","title":"Dry Run","description":"Whether this was a dry run (no changes made)","default":false},"task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id","description":"The apply's task: GET /v1/tasks/{task_id} returns every resource of the plan with its states in order (planned, creating, created, exists, updated or failed with the finding; for a collection, warming or ready), each with the time it was reached. Absent on a dry run"},"readiness":{"items":{"$ref":"#/components/schemas/CollectionReadiness"},"type":"array","title":"Readiness","description":"For each collection the manifest declares whose extractor needs Ray Serve applications for real-time inference: whether each one is served, read once from the live Serve list after apply. `realtime_available` true means every app is RUNNING. An app scaled to zero replicas is still RUNNING; its first call answers 503 with Retry-After (code model_warming) while it warms, so retry after that many seconds. Empty for collections whose extractor needs no Serve app."},"seed_batches":{"items":{"$ref":"#/components/schemas/SeedBatchStatus"},"type":"array","title":"Seed Batches","description":"With wait_for_seed or run_acceptance: each `seed:` batch and where it stood when apply stopped waiting. A batch that failed or did not finish in time also appears in `errors`. `success` still reports resource creation only"},"acceptance":{"anyOf":[{"$ref":"#/components/schemas/AcceptanceResult"},{"type":"null"}],"description":"With run_acceptance: the outcome of each `acceptance:` step. `acceptance.passed` false means the namespace exists but its use case did not prove out; `success` still reports resource creation only, and a failed run is also named in `errors`"},"next_steps":{"items":{"$ref":"#/components/schemas/ApplyNextStep"},"type":"array","title":"Next Steps","description":"On a successful real apply: for each retriever the manifest declares, its execute URL, a curl that queries it and its Studio page. Empty on a dry run, a failed apply, or a manifest with no retrievers"}},"type":"object","required":["success"],"title":"ApplyResult","description":"Result of applying a manifest.","examples":[{"created_count":2,"dry_run":false,"errors":[],"failed_count":0,"resources":[{"name":"video_search","resource_id":"ns_abc123","resource_type":"namespace","status":"created"},{"name":"raw_videos","resource_id":"bkt_xyz789","resource_type":"bucket","status":"created"}],"rollback_performed":false,"skipped_count":0,"success":true}]},"ApplyTaxonomyRequest":{"properties":{"taxonomy_id":{"type":"string","title":"Taxonomy Id","description":"ID of the taxonomy to apply. REQUIRED. Must be an existing taxonomy (tax_*). The taxonomy must already be in the collection's taxonomy_applications list.","examples":["tax_abc123","tax_products"]},"scroll_filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Scroll Filters","description":"Optional filters to limit which documents are enriched. NOT REQUIRED. If not provided, all documents in the collection will be enriched. Use to process specific subsets (e.g., documents missing enrichment).","examples":[{"must":[{"key":"metadata.category","match":{"value":"products"}}]},null]},"batch_size":{"type":"integer","maximum":5000.0,"minimum":100.0,"title":"Batch Size","description":"Number of documents to process in each parallel batch. NOT REQUIRED. Defaults to 1000. Larger batches = fewer Ray tasks but more memory per task. Smaller batches = more Ray tasks but lower memory per task.","default":1000,"examples":[1000,500,2000]},"parallelism":{"type":"integer","maximum":20.0,"minimum":1.0,"title":"Parallelism","description":"Number of parallel Ray workers to use for processing. NOT REQUIRED. Defaults to 4. Higher parallelism = faster processing but more cluster resources. Set based on available Ray cluster capacity.","default":4,"examples":[4,8,2]},"budget_limits":{"anyOf":[{"$ref":"#/components/schemas/BudgetLimits"},{"type":"null"}],"description":"Optional budget for this job. max_time_ms stops the job when it has run that long: documents already enriched keep their assignments, the task ends CANCELED, and its stats carry budget, spent and stopped_at. max_credits is refused: taxonomy enrichment bills 0 credits, so a credit cap could never stop this job.","examples":[{"max_time_ms":3600000}]}},"type":"object","required":["taxonomy_id"],"title":"ApplyTaxonomyRequest","description":"Request to apply a taxonomy to an existing collection.\n\nThis endpoint triggers retroactive taxonomy materialization on\nall documents in a collection using distributed Ray processing.\n\nUse Cases:\n    - Apply taxonomy to documents that were ingested before the taxonomy was created\n    - Re-apply taxonomy after taxonomy configuration changes\n    - Backfill enrichment data for existing collections\n\nRequirements:\n    - taxonomy_id: REQUIRED - Must be an existing, valid taxonomy\n    - The taxonomy must already be attached to the collection via taxonomy_applications\n    - Documents must exist in the collection","examples":[{"description":"Apply taxonomy to all documents","taxonomy_id":"tax_abc123"},{"description":"Apply taxonomy to filtered documents","scroll_filters":{"must":[{"key":"metadata.processed","match":{"value":false}}]},"taxonomy_id":"tax_products"},{"batch_size":500,"description":"Apply with custom batch settings","parallelism":8,"taxonomy_id":"tax_categories"}]},"ApplyTaxonomyResponse":{"properties":{"task_id":{"type":"string","title":"Task Id","description":"ID of the Ray task executing the materialization"},"status":{"type":"string","title":"Status","description":"Status of the materialization task","examples":["submitted","running","completed","failed"]},"collection_id":{"type":"string","title":"Collection Id","description":"Collection ID where taxonomy is being applied"},"taxonomy_id":{"type":"string","title":"Taxonomy Id","description":"Taxonomy ID being applied"},"estimated_documents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Estimated Documents","description":"Estimated number of documents to process (if available)"}},"type":"object","required":["task_id","status","collection_id","taxonomy_id"],"title":"ApplyTaxonomyResponse","description":"Response from applying taxonomy to collection.\n\nReturns statistics about the materialization process.","examples":[{"collection_id":"col_products","estimated_documents":15000,"status":"submitted","task_id":"ray_task_abc123","taxonomy_id":"tax_categories"}]},"ArtifactDigest":{"properties":{"sha256":{"type":"string","title":"Sha256"},"size":{"type":"integer","title":"Size"}},"type":"object","required":["sha256","size"],"title":"ArtifactDigest"},"AssignmentMetric":{"properties":{"time_bucket":{"type":"string","format":"date-time","title":"Time Bucket"},"assignment_count":{"type":"integer","title":"Assignment Count"},"avg_confidence":{"type":"number","title":"Avg Confidence"},"unique_labels":{"type":"integer","title":"Unique Labels"}},"type":"object","required":["time_bucket","assignment_count","avg_confidence","unique_labels"],"title":"AssignmentMetric","description":"Taxonomy assignment metrics."},"AssignmentMetricsResponse":{"properties":{"taxonomy_id":{"type":"string","title":"Taxonomy Id"},"time_range":{"$ref":"#/components/schemas/api__analytics__taxonomies__models__TimeRange"},"metrics":{"items":{"$ref":"#/components/schemas/AssignmentMetric"},"type":"array","title":"Metrics"},"summary":{"additionalProperties":true,"type":"object","title":"Summary"}},"type":"object","required":["taxonomy_id","time_range","metrics"],"title":"AssignmentMetricsResponse","description":"Taxonomy assignment metrics response."},"AttributeBasedConfig":{"properties":{"attributes":{"items":{"type":"string"},"type":"array","minItems":1,"title":"Attributes","description":"List of attribute field names to use for clustering. Documents will be grouped by unique combinations of these attribute values. Supports dot-notation for nested fields (e.g., 'metadata.category'). Order matters for hierarchical grouping: first attribute is top-level, subsequent are nested.","examples":[["category"],["category","brand"],["status","priority"],["metadata.author","metadata.topic"]]},"hierarchical_grouping":{"type":"boolean","title":"Hierarchical Grouping","description":"Whether to create hierarchical clusters based on attribute order. When True: Creates parent clusters for each unique value of the first attribute, then child clusters for subsequent attributes within each parent. When False: Creates flat clusters for each unique combination of all attributes. Example with ['category', 'brand']:   hierarchical=True → 'Electronics' (parent) → 'Apple', 'Samsung' (children).   hierarchical=False → 'Electronics_Apple', 'Electronics_Samsung' (flat).","default":false},"aggregation_method":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Aggregation Method","description":"Method for aggregating attribute values when creating cluster centroids. Options: 'most_frequent' (default), 'first', 'last'. Most use cases should use the default.","examples":["most_frequent","first","last"]}},"type":"object","required":["attributes"],"title":"AttributeBasedConfig","description":"Configuration for attribute-based clustering.\n\nAttribute-based clustering groups documents by metadata attributes (e.g., category, brand, status)\ninstead of vector similarity. This is useful for organizing content by business logic rather than\nsemantic similarity.\n\nExamples:\n    - Group products by category and brand\n    - Organize orders by status and priority\n    - Cluster content by author and topic","examples":[{"attributes":["category"],"description":"Simple category clustering","hierarchical_grouping":false},{"attributes":["category","brand"],"description":"Hierarchical category → brand clustering","hierarchical_grouping":true},{"aggregation_method":"most_frequent","attributes":["status","priority"],"description":"Order status and priority (flat)","hierarchical_grouping":false}]},"AudioFingerprintExtractorParams":{"properties":{"extractor_type":{"type":"string","const":"audio_fingerprint_extractor","title":"Extractor Type","description":"Discriminator field. Must be 'audio_fingerprint_extractor'.","default":"audio_fingerprint_extractor"},"segment_duration_sec":{"type":"number","maximum":30.0,"minimum":1.0,"title":"Segment Duration Sec","description":"Duration of each audio segment in seconds. 5.0: Recommended for sound mark matching. Shorter segments increase recall but reduce per-segment context.","default":5.0},"segment_hop_sec":{"type":"number","maximum":15.0,"minimum":0.5,"title":"Segment Hop Sec","description":"Hop size between segments in seconds. 2.5: 50% overlap (recommended). Set equal to segment_duration_sec for no overlap.","default":2.5},"sample_rate":{"type":"integer","title":"Sample Rate","description":"Target sample rate for audio. 48000: CLAP default (recommended). Audio is resampled to this rate before embedding.","default":48000},"normalize_embeddings":{"type":"boolean","title":"Normalize Embeddings","description":"L2-normalize embeddings to unit vectors (recommended for cosine similarity).","default":true},"max_audio_length_sec":{"type":"number","maximum":600.0,"minimum":1.0,"title":"Max Audio Length Sec","description":"Maximum audio length to process in seconds. 120: Default (2 minutes). Audio beyond this is truncated.","default":120.0}},"type":"object","title":"AudioFingerprintExtractorParams","description":"Parameters for the Audio Fingerprint Extractor.\n\nProcesses audio files (or audio extracted from video) through CLAP\n(Contrastive Language-Audio Pretraining) to produce 512-d embeddings\nsuitable for audio fingerprint matching.\n\nCore Pipeline:\n1. Audio extraction (if video input, via FFmpeg)\n2. Segmentation into fixed-length windows\n3. CLAP embedding (laion/clap-htsat-tiny, 512-d)\n4. L2 normalization\n\nUse Cases:\n    - Sound mark detection (IP safety)\n    - Audio similarity search\n    - Music/jingle identification\n    - Audio deduplication","examples":[{"description":"Sound mark detection (IP safety)","extractor_type":"audio_fingerprint_extractor","normalize_embeddings":true,"sample_rate":48000,"segment_duration_sec":5.0,"segment_hop_sec":2.5},{"description":"Music identification (longer segments)","extractor_type":"audio_fingerprint_extractor","sample_rate":48000,"segment_duration_sec":10.0,"segment_hop_sec":5.0}]},"AuditAction":{"type":"string","enum":["user_created","user_updated","user_deleted","api_key_created","api_key_rotated","api_key_revoked","api_key_scope_updated","api_key_internal_flagged","permission_updated","storage_connection_created","storage_connection_updated","storage_connection_deleted","storage_connection_tested","storage_connection_failed","namespace_created","namespace_updated","namespace_deleted","namespace_accessed","collection_created","collection_updated","collection_deleted","collection_accessed","document_deleted","document_bulk_soft_deleted","bucket_created","bucket_updated","bucket_deleted","bucket_accessed","retriever_created","retriever_updated","retriever_deleted","retriever_accessed","retriever_queried","cluster_created","cluster_updated","cluster_deleted","cluster_executed","cluster_accessed","taxonomy_created","taxonomy_updated","taxonomy_deleted","taxonomy_accessed","alert_created","alert_updated","alert_deleted","alert_accessed","alert_triggered","annotation_created","annotation_updated","annotation_deleted","secret_created","secret_updated","secret_deleted","secret_accessed","webhook_created","webhook_updated","webhook_deleted"],"title":"AuditAction","description":"Canonical audit log actions captured for organization events.\n\nThese events are written to the audit trail for compliance, security monitoring,\nand debugging. Each action includes actor, resource, timestamp, and change details.\n\nUser lifecycle actions:\n    - USER_CREATED: New user added to organization\n    - USER_UPDATED: User role, status, or metadata modified\n    - USER_DELETED: User removed from organization\n\nAPI key lifecycle actions:\n    - API_KEY_CREATED: New API key generated\n    - API_KEY_ROTATED: Key regenerated (old key revoked, new key issued)\n    - API_KEY_REVOKED: Key manually revoked\n    - API_KEY_SCOPE_UPDATED: Key permissions or scopes modified\n\nPermission actions:\n    - PERMISSION_UPDATED: User or key permissions modified\n\nStorage connection actions:\n    - STORAGE_CONNECTION_CREATED: New external storage connection configured\n    - STORAGE_CONNECTION_UPDATED: Connection settings or credentials updated\n    - STORAGE_CONNECTION_DELETED: Connection permanently removed\n    - STORAGE_CONNECTION_TESTED: Connection health check performed\n    - STORAGE_CONNECTION_FAILED: Connection health check or sync failed\n\nNamespace actions:\n    - NAMESPACE_CREATED: New namespace created\n    - NAMESPACE_UPDATED: Namespace configuration modified\n    - NAMESPACE_DELETED: Namespace permanently removed\n    - NAMESPACE_ACCESSED: Namespace read (when read auditing enabled)\n\nCollection actions:\n    - COLLECTION_CREATED: New collection created\n    - COLLECTION_UPDATED: Collection configuration modified\n    - COLLECTION_DELETED: Collection permanently removed\n    - COLLECTION_ACCESSED: Collection read (when read auditing enabled)\n\nDocument actions:\n    - DOCUMENT_DELETED: Single document removed by ID\n    - DOCUMENT_BULK_SOFT_DELETED: A bulk/batch document delete operation\n      ran (explicit IDs or filter mode). ONE event per operation, not\n      one per document — carries the count, the collection_id(s), an\n      optional caller-supplied reason, and the actor from request\n      context. Before this action existed, a document-level wipe\n      (bulk-soft-delete or any other document delete path) was\n      invisible to the audit trail entirely.\n\nBucket actions:\n    - BUCKET_CREATED: New bucket created\n    - BUCKET_UPDATED: Bucket configuration modified\n    - BUCKET_DELETED: Bucket permanently removed\n    - BUCKET_ACCESSED: Bucket read (when read auditing enabled)\n\nRetriever actions:\n    - RETRIEVER_CREATED: New retriever pipeline created\n    - RETRIEVER_UPDATED: Retriever configuration modified\n    - RETRIEVER_DELETED: Retriever permanently removed\n    - RETRIEVER_ACCESSED: Retriever read (when read auditing enabled)\n    - RETRIEVER_QUERIED: Retriever query executed (when read auditing enabled)\n\nCluster actions:\n    - CLUSTER_CREATED: New cluster created\n    - CLUSTER_UPDATED: Cluster configuration modified\n    - CLUSTER_DELETED: Cluster permanently removed\n    - CLUSTER_EXECUTED: Cluster job executed\n    - CLUSTER_ACCESSED: Cluster read (when read auditing enabled)\n\nTaxonomy actions:\n    - TAXONOMY_CREATED: New taxonomy created\n    - TAXONOMY_UPDATED: Taxonomy configuration modified\n    - TAXONOMY_DELETED: Taxonomy permanently removed\n    - TAXONOMY_ACCESSED: Taxonomy read (when read auditing enabled)"},"AuditEventListResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/AuditEventResponse"},"type":"array","title":"Results","description":"Audit events"},"total":{"type":"integer","title":"Total","description":"Total count matching filters"},"skip":{"type":"integer","title":"Skip","description":"Number of results skipped"},"limit":{"type":"integer","title":"Limit","description":"Number of results returned"}},"type":"object","required":["results","total","skip","limit"],"title":"AuditEventListResponse","description":"Response for listing audit events."},"AuditEventResponse":{"properties":{"audit_id":{"type":"string","title":"Audit Id","description":"Unique audit event identifier"},"timestamp":{"title":"Timestamp","description":"When the event occurred"},"resource_type":{"type":"string","title":"Resource Type","description":"Type of resource affected"},"resource_id":{"type":"string","title":"Resource Id","description":"ID of the affected resource"},"action":{"type":"string","title":"Action","description":"Action performed"},"actor_id":{"type":"string","title":"Actor Id","description":"Who performed the action"},"actor_type":{"type":"string","title":"Actor Type","description":"Type of actor","default":"user"},"status":{"type":"string","title":"Status","description":"Status of the action","default":"success"},"changes":{"title":"Changes","description":"What changed"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason","description":"Caller-supplied reason for the change (the WHY), captured from the X-Change-Reason request header when present."},"ip_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ip Address","description":"Request IP address"},"user_agent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Agent","description":"Request user agent"},"actor_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Actor Name","description":"Resolved actor display name"},"actor_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Actor Email","description":"Resolved actor email"},"actor_key_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Actor Key Name","description":"API key name used"}},"type":"object","required":["audit_id","timestamp","resource_type","resource_id","action","actor_id"],"title":"AuditEventResponse","description":"Single audit event in list response."},"AuditSettings":{"properties":{"read_auditing_enabled":{"type":"boolean","title":"Read Auditing Enabled","description":"When enabled, read operations (GET requests) are logged to the audit trail. This includes resource access like NAMESPACE_ACCESSED, BUCKET_ACCESSED, etc. Disabled by default to reduce audit log volume. Enable for compliance requirements that mandate tracking all resource access.","default":false}},"type":"object","title":"AuditSettings","description":"Organization audit configuration.\n\nControls audit logging behavior for the organization. Allows enabling\nread access auditing for compliance requirements.","examples":[{"read_auditing_enabled":false},{"read_auditing_enabled":true}]},"AuditSettingsUpdateRequest":{"properties":{"read_auditing_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Read Auditing Enabled","description":"Enable or disable read operation auditing."}},"type":"object","title":"AuditSettingsUpdateRequest","description":"Payload for updating audit settings."},"AuthConfig-Input":{"properties":{"mode":{"type":"string","enum":["public","clerk","password","api_key","jwt","sso_oidc","sso_saml"],"title":"Mode","description":"Authentication mode","default":"public"},"clerk_org_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Clerk Org Id","description":"Clerk Organization ID for this app (auto-provisioned)"},"clerk_allowed_providers":{"items":{"type":"string"},"type":"array","title":"Clerk Allowed Providers","description":"Enabled auth providers: google, github, email"},"password":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Password","description":"Plaintext password (write-only — hashed before storage, never returned in responses)"},"password_hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Password Hash","description":"Bcrypt hash of the password (internal — never exposed in API responses)"},"saml_idp_metadata_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Saml Idp Metadata Url"},"saml_sp_entity_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Saml Sp Entity Id"},"saml_acs_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Saml Acs Url"},"oidc_issuer":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Oidc Issuer"},"oidc_client_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Oidc Client Id"},"oidc_client_secret_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Oidc Client Secret Name","description":"Secrets vault key name (never stored inline)"},"oidc_scopes":{"items":{"type":"string"},"type":"array","title":"Oidc Scopes"},"jwt_jwks_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Jwt Jwks Url"},"jwt_audience":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Jwt Audience"},"jwt_issuer":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Jwt Issuer"},"api_keys":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Api Keys"}},"type":"object","title":"AuthConfig","description":"End-user authentication configuration for an App.\n\nSupported modes:\n- ``public``: No authentication required (default)\n- ``clerk``: Managed auth via Clerk Organizations — handles Google, GitHub,\n  email/password signup/login. Each canvas app maps to a Clerk Organization.\n  Users are synced to canvas_users via Clerk webhooks.\n- ``password``: Simple password gate — visitors must enter a password to\n  access the app. The password is hashed (bcrypt) before storage.\n- ``api_key``, ``jwt``, ``sso_oidc``, ``sso_saml``: Advanced modes\n  retained for future use."},"AuthConfig-Output":{"properties":{"mode":{"type":"string","enum":["public","clerk","password","api_key","jwt","sso_oidc","sso_saml"],"title":"Mode","description":"Authentication mode","default":"public"},"clerk_org_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Clerk Org Id","description":"Clerk Organization ID for this app (auto-provisioned)"},"clerk_allowed_providers":{"items":{"type":"string"},"type":"array","title":"Clerk Allowed Providers","description":"Enabled auth providers: google, github, email"},"password_hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Password Hash","description":"Bcrypt hash of the password (internal — never exposed in API responses)"},"saml_idp_metadata_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Saml Idp Metadata Url"},"saml_sp_entity_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Saml Sp Entity Id"},"saml_acs_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Saml Acs Url"},"oidc_issuer":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Oidc Issuer"},"oidc_client_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Oidc Client Id"},"oidc_client_secret_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Oidc Client Secret Name","description":"Secrets vault key name (never stored inline)"},"oidc_scopes":{"items":{"type":"string"},"type":"array","title":"Oidc Scopes"},"jwt_jwks_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Jwt Jwks Url"},"jwt_audience":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Jwt Audience"},"jwt_issuer":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Jwt Issuer"},"api_keys":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Api Keys"}},"type":"object","title":"AuthConfig","description":"End-user authentication configuration for an App.\n\nSupported modes:\n- ``public``: No authentication required (default)\n- ``clerk``: Managed auth via Clerk Organizations — handles Google, GitHub,\n  email/password signup/login. Each canvas app maps to a Clerk Organization.\n  Users are synced to canvas_users via Clerk webhooks.\n- ``password``: Simple password gate — visitors must enter a password to\n  access the app. The password is hashed (bcrypt) before storage.\n- ``api_key``, ``jwt``, ``sso_oidc``, ``sso_saml``: Advanced modes\n  retained for future use."},"AutoBillingToggleResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether the operation was successful","default":true},"auto_billing_enabled":{"type":"boolean","title":"Auto Billing Enabled","description":"New auto-billing status"},"message":{"type":"string","title":"Message","description":"Human-readable message"},"billing_period_start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Billing Period Start","description":"Billing period start (if enabled)"}},"type":"object","required":["auto_billing_enabled","message"],"title":"AutoBillingToggleResponse","description":"Response after toggling auto-billing."},"AvailableOrgModelItem":{"properties":{"model_id":{"type":"string","title":"Model Id"},"name":{"type":"string","title":"Name"},"version":{"type":"string","title":"Version"},"model_format":{"type":"string","title":"Model Format"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"framework":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Framework"},"task_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Type"},"enabled_in_namespace":{"type":"boolean","title":"Enabled In Namespace","description":"Whether already enabled in the target namespace"}},"type":"object","required":["model_id","name","version","model_format","enabled_in_namespace"],"title":"AvailableOrgModelItem","description":"Available org model item."},"AvailableOrgModelsResponse":{"properties":{"success":{"type":"boolean","title":"Success","default":true},"models":{"items":{"$ref":"#/components/schemas/AvailableOrgModelItem"},"type":"array","title":"Models"},"total":{"type":"integer","title":"Total"},"namespace_id":{"type":"string","title":"Namespace Id"}},"type":"object","required":["models","total","namespace_id"],"title":"AvailableOrgModelsResponse","description":"Response for listing available org models."},"AvailableStepsResponse":{"properties":{"taxonomy_id":{"type":"string","title":"Taxonomy Id","description":"Taxonomy ID"},"collection_id":{"type":"string","title":"Collection Id","description":"Collection ID"},"total_events":{"type":"integer","minimum":0.0,"title":"Total Events","description":"Total events in dataset"},"total_sequences":{"type":"integer","minimum":0.0,"title":"Total Sequences","description":"Total unique sequences"},"steps":{"items":{"$ref":"#/components/schemas/StepInfo"},"type":"array","title":"Steps","description":"Available steps sorted by count"}},"type":"object","required":["taxonomy_id","collection_id","total_events","total_sequences","steps"],"title":"AvailableStepsResponse","description":"Response containing all available steps for a taxonomy/collection.\n\nThis endpoint helps users discover what steps exist in their analytics data\nbefore querying transitions or paths.\n\nExample Response:\n    ```json\n    {\n        \"taxonomy_id\": \"tax_sales_stages\",\n        \"collection_id\": \"col_emails\",\n        \"total_events\": 5432,\n        \"total_sequences\": 1000,\n        \"steps\": [\n            {\n                \"step_key\": \"inquiry\",\n                \"event_count\": 1000,\n                \"sequence_count\": 1000,\n                \"first_seen\": \"2025-11-01T00:00:00Z\",\n                \"last_seen\": \"2025-12-07T00:00:00Z\"\n            },\n            {\n                \"step_key\": \"followup\",\n                \"event_count\": 450,\n                \"sequence_count\": 450,\n                \"first_seen\": \"2025-11-02T00:00:00Z\",\n                \"last_seen\": \"2025-12-06T00:00:00Z\"\n            },\n            {\n                \"step_key\": \"closed_won\",\n                \"event_count\": 350,\n                \"sequence_count\": 350,\n                \"first_seen\": \"2025-11-05T00:00:00Z\",\n                \"last_seen\": \"2025-12-07T00:00:00Z\"\n            }\n        ]\n    }\n    ```"},"AzureBlobConfig":{"properties":{"provider_type":{"type":"string","const":"azure_blob","title":"Provider Type","default":"azure_blob"},"credentials":{"oneOf":[{"$ref":"#/components/schemas/AzureStorageAccountKeyCredentials"},{"$ref":"#/components/schemas/AzureManagedIdentityCredentials"}],"title":"Credentials","description":"REQUIRED. Azure authentication credentials. Choose 'account_key' (account_name + account_key) or 'managed_identity' (RECOMMENDED for production, uses DefaultAzureCredential). The 'type' field determines which credential mechanism is used.","discriminator":{"propertyName":"type","mapping":{"account_key":"#/components/schemas/AzureStorageAccountKeyCredentials","managed_identity":"#/components/schemas/AzureManagedIdentityCredentials"}}},"account_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Name","description":"Storage account name (the '{account_name}' in https://{account_name}.blob.core.windows.net). REQUIRED for 'managed_identity' credentials, which carry no account name of their own. For 'account_key' credentials it is taken from the credentials and this field may be omitted.","examples":["mycompanymedia","prodassets"]},"container":{"type":"string","title":"Container","description":"REQUIRED. Name of the Azure Blob container to sync from. The identity or key must have read access to this container.","examples":["media","data-lake"]},"prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prefix","description":"NOT REQUIRED. Blob name prefix to scope the sync to a folder within the container (e.g. 'marketing/videos/'). When set, it is prepended to any requested list path.","examples":["marketing/videos/","2024/"]}},"type":"object","required":["credentials","container"],"title":"AzureBlobConfig","description":"Azure Blob Storage (native SDK) storage provider configuration.\n\nReads objects from an Azure Blob container using the native\n``azure-storage-blob`` SDK. Azure Blob has no S3-compatible surface, so this\nnative connector is the only supported path (there is no HMAC/S3 interim like\nGCS has).\n\nAuthentication:\n    - Storage account key (``account_key``), or\n    - Azure managed identity (``managed_identity``) via DefaultAzureCredential\n\nRequirements:\n    - An Azure Storage account with a blob container to read\n    - Read access on the container (account key, or the 'Storage Blob Data\n      Reader' role for managed identity)\n\nUse Cases:\n    - Ingest media/data-lake objects from Azure Blob containers\n    - Sync marketing/creative assets stored in Azure\n    - Unified search across Azure + other sources","examples":[{"container":"media","credentials":{"account_key":"base64accountkey==","account_name":"mycompanymedia","type":"account_key"},"description":"Azure Blob container sync via account key","prefix":"marketing/videos/","provider_type":"azure_blob"},{"account_name":"mycompanymedia","container":"media","credentials":{"client_id":"87654321-4321-4321-4321-cba987654321","type":"managed_identity"},"description":"Azure Blob container sync via managed identity","provider_type":"azure_blob"}]},"AzureManagedIdentityCredentials":{"properties":{"type":{"type":"string","const":"managed_identity","title":"Type","default":"managed_identity"},"client_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Id","description":"NOT REQUIRED. Client ID of a specific user-assigned managed identity. Provide this only when the workload has more than one user-assigned identity and you must select one. When omitted, DefaultAzureCredential resolves the ambient identity via its normal chain. Format: UUID.","examples":["87654321-4321-4321-4321-cba987654321"]}},"type":"object","title":"AzureManagedIdentityCredentials","description":"Azure managed-identity credentials (RECOMMENDED for production).\n\nUses ``azure.identity.DefaultAzureCredential`` so the connector authenticates\nas the workload's Azure identity (system- or user-assigned managed identity,\nworkload identity, or the ambient environment credential chain). No secret is\nstored on the connection.\n\nPrerequisites:\n    - The Mixpeek workload runs with an Azure identity\n    - That identity is granted the 'Storage Blob Data Reader' role on the\n      target container or storage account\n\nSecurity:\n    - No long-lived secret is stored; access is controlled by Azure RBAC and\n      can be revoked centrally.\n    - ``client_id`` is only needed to disambiguate a specific user-assigned\n      managed identity when several are available."},"AzureStorageAccountKeyCredentials":{"properties":{"type":{"type":"string","const":"account_key","title":"Type","default":"account_key"},"account_name":{"type":"string","minLength":1,"title":"Account Name","description":"REQUIRED. Azure Storage account name (the '{account_name}' in https://{account_name}.blob.core.windows.net). Lowercase alphanumeric, 3-24 chars.","examples":["mycompanymedia","prodassets"]},"account_key":{"type":"string","minLength":1,"title":"Account Key","description":"REQUIRED. One of the storage account's access keys. SECURITY: This is a secret credential, redacted on read. Never log or expose this value. Obtain from: Azure Portal > Storage account > Access keys (base64 string)."}},"type":"object","required":["account_name","account_key"],"title":"AzureStorageAccountKeyCredentials","description":"Azure Blob Storage account-key credentials.\n\nThe classic shared-key auth: the storage account name plus one of its two\naccount keys. The provider builds the client via\n``BlobServiceClient(account_url=\"https://{account_name}.blob.core.windows.net\",\ncredential=account_key)``.\n\nPrerequisites:\n    - An Azure Storage account with the target container\n    - One of the account's access keys (Portal > Storage account >\n      Security + networking > Access keys)\n\nSecurity:\n    - ``account_key`` is in the connection client's SENSITIVE_KEYS redaction\n      set, so it is masked on read.\n    - Prefer managed identity in production; rotate account keys regularly."},"BYODocument":{"properties":{"document_id":{"type":"string","title":"Document Id","description":"Unique document identifier. Upserting with an existing ID replaces the document."},"vectors":{"additionalProperties":{"anyOf":[{"items":{"type":"number"},"type":"array"},{"items":{"items":{"type":"number"},"type":"array"},"type":"array"},{"$ref":"#/components/schemas/BYOSparseVector"}]},"type":"object","title":"Vectors","description":"Named vectors as a map of vector_name -> value. The value's shape sets its type: a list of floats is dense, a list of float lists is a multi-vector (one row per token), and an object with indices and values is sparse. A document reads back every type it was written with when vectors are requested. Example: {\"text-embedding\": [0.1, 0.2, ...], \"splade\": {\"indices\": [3, 17], \"values\": [0.5, 1.2]}, \"colbert\": [[0.1, 0.2], [0.3, 0.4]]}"},"payload":{"additionalProperties":true,"type":"object","title":"Payload","description":"Arbitrary JSON payload stored alongside the vectors."},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Document metadata stored in _internal.metadata. Filterable via attribute queries."},"acl":{"anyOf":[{"$ref":"#/components/schemas/BYODocumentACL"},{"type":"null"}],"description":"Document ACL stored with the document (``_internal._acl``): the same read, write and public fields as the ACL update route, set in this call. Organization-scoped API keys only; a user-scoped key or end-user token is refused with 403. Omit it to store the document with no ACL, as before."},"source_type":{"anyOf":[{"type":"string","enum":["bucket","collection","direct_upsert","signal"]},{"type":"null"}],"title":"Source Type","description":"Immediate-parent type. Defaults to 'direct_upsert' when omitted. Set 'bucket'/'collection' to import a document carrying real lineage."},"root_object_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Root Object Id","description":"Root object id (decomposition-tree root). All documents derived from the same source object share it."},"root_bucket_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Root Bucket Id","description":"Bucket id holding the root object."},"source_object_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Object Id","description":"Immediate parent object id when source_type='bucket'."},"source_document_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Document Id","description":"Immediate parent document id when source_type='collection'."},"source_collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Collection Id","description":"Immediate parent collection id when source_type='collection'."},"lineage_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lineage Path","description":"Materialized lineage path (e.g. 'bkt_123/col_456/col_789')."},"lineage_chain":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Lineage Chain","description":"Ordered processing steps from root object to this document; each step carries collection_id, feature_extractor_id, document_id, timestamp."},"content_hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Content Hash","description":"SHA256 content hash of the source object. Supplying it lets a later heal/reprocess recognise the cached derivation potency and skip recompute. Stored at _internal.content_hash."}},"type":"object","required":["document_id","vectors"],"title":"BYODocument","description":"A single document with user-provided vectors and payload."},"BYODocumentACL":{"properties":{"read":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":256},{"type":"null"}],"title":"Read","description":"Principal ids that can read this document."},"write":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":256},{"type":"null"}],"title":"Write","description":"Principal ids that can write this document."},"public":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Public","description":"If true, any user-scoped key can read this document."}},"type":"object","title":"BYODocumentACL","description":"Access control list to store with a document at write time.\n\nSame fields and meaning as ``PATCH /collections/{id}/documents/{id}/acl``,\napplied in the same call that stores the document so a bulk loader does not\nneed one more request per document. Accepted only from an organization-scoped\nAPI key: a user-scoped key or end-user token gets the owner ACL the platform\nstamps and cannot choose another."},"BYOSparseVector":{"properties":{"indices":{"items":{"type":"integer"},"type":"array","title":"Indices","description":"Dimension indices of the non-zero entries, each unique."},"values":{"items":{"type":"number"},"type":"array","title":"Values","description":"Weight per index, the same length as indices."}},"type":"object","required":["indices","values"],"title":"BYOSparseVector","description":"Sparse vector: the non-zero dimensions and their weights."},"BYOUpsertRequest":{"properties":{"collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Collection Id","description":"Target collection. Documents are tagged with this collection_id so they appear in collection-scoped queries, list, and clustering. When omitted a namespace-level default collection is used."},"documents":{"items":{"$ref":"#/components/schemas/BYODocument"},"type":"array","maxItems":1000,"title":"Documents","description":"Documents to upsert. Maximum 1000 per call."},"options":{"anyOf":[{"$ref":"#/components/schemas/UpsertOptions"},{"type":"null"}],"description":"Optional upsert behavior flags."}},"type":"object","required":["documents"],"title":"BYOUpsertRequest","description":"Request body for BYO document upsert."},"BYOUpsertResponse":{"properties":{"inserted":{"type":"integer","title":"Inserted","description":"Number of documents upserted."},"document_ids":{"items":{"type":"string"},"type":"array","title":"Document Ids","description":"IDs of all upserted documents."},"write_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Write Token","description":"Opaque token for read-your-writes consistency (only when requested)."},"dropped_payload_fields":{"additionalProperties":{"items":{"type":"string"},"type":"array"},"type":"object","title":"Dropped Payload Fields","description":"document_id -> payload field names that were REMOVED before storage because they collide with reserved internal field names. Their values are not stored anywhere and are not readable back. Rename the field (e.g. 'source_type' -> 'my_source_type') or nest it under 'metadata' to keep the value. Empty when nothing was dropped."},"unsearchable_document_ids":{"items":{"type":"string"},"type":"array","title":"Unsearchable Document Ids","description":"document_ids that were stored but carry no vector for the collection's declared index, so a retriever search will not return them until you provide a vector for that index or run the collection's extractor. The documents are readable by list and get; they are only absent from search. Empty when every document is searchable."},"consistency":{"$ref":"#/components/schemas/WriteConsistency","description":"How and when this write becomes visible to retriever reads."},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings","description":"Advisories about this write that did not fail it: today, that the idempotency replay entry could not be stored, so a retry with the same idempotency_key would write again."}},"type":"object","required":["inserted","document_ids"],"title":"BYOUpsertResponse","description":"Response from a BYO document upsert."},"BackblazeConfig":{"properties":{"provider_type":{"type":"string","const":"backblaze","title":"Provider Type","default":"backblaze"},"credentials":{"$ref":"#/components/schemas/BackblazeCredentials","description":"REQUIRED. Backblaze B2 application key credentials."}},"type":"object","required":["credentials"],"title":"BackblazeConfig","description":"Backblaze B2 Cloud Storage configuration.\n\nBackblaze B2 is an S3-compatible object storage service. This provider\nauto-discovers the regional S3 endpoint via the B2 authorization API,\nso users only need to provide their key ID and application key.\n\nAuthentication:\n    - Application key ID + application key from Backblaze console\n\nRequirements:\n    - Active Backblaze account with B2 Cloud Storage enabled\n    - Application key with listBuckets, listFiles, and readFiles capabilities\n    - (Optional) Restrict key to specific bucket for scoped access\n\nUse Cases:\n    - Cold storage archive ingestion\n    - Media file sync from Backblaze-hosted assets\n    - Backup data processing\n    - Cost-effective large-file storage sync","examples":[{"credentials":{"application_key":"K005xxxxxxxxxxxxxxxxxxxxxxxxxxxx","key_id":"005870eff85b6c60000000001","type":"application_key"},"description":"Backblaze B2 bucket sync","provider_type":"backblaze"}]},"BackblazeCredentials":{"properties":{"type":{"type":"string","const":"application_key","title":"Type","default":"application_key"},"key_id":{"type":"string","title":"Key Id","description":"REQUIRED. Backblaze B2 application key ID. Found in: Backblaze Console > App Keys > keyID column.","examples":["005870eff85b6c60000000001"]},"application_key":{"type":"string","title":"Application Key","description":"REQUIRED. Backblaze B2 application key (secret). SECURITY: Encrypted at rest. Shown only once when key is created. Found in: Backblaze Console > App Keys — copy immediately on creation.","examples":["K005xxxxxxxxxxxxxxxxxxxxxxxxxxxx"]}},"type":"object","required":["key_id","application_key"],"title":"BackblazeCredentials","description":"Application key credentials for Backblaze B2 Cloud Storage.\n\nSecurity:\n    - application_key is a secret credential, redacted on read\n    - Keys can be created/rotated in the Backblaze console"},"BackupCoverage":{"properties":{"provider":{"type":"string","title":"Provider","description":"Backup binding that answered: 'pbm' or 'atlas'"},"covered":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Covered","description":"True when the instant is restorable from a completed base backup plus continuous oplog; False when it is not; null when the provider could not be asked"},"base_backup":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Base Backup","description":"Name of the base backup a restore starts from"},"base_backup_time":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Base Backup Time","description":"Cluster time seconds the base backup ends at"},"oplog_end_time":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Oplog End Time","description":"Cluster time seconds the continuous oplog reaches from the base backup"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason","description":"Why the instant is not covered or not known"}},"type":"object","required":["provider","covered"],"title":"BackupCoverage"},"BaseFeatureExtractorModel-Input":{"properties":{"feature_extractor_name":{"type":"string","title":"Feature Extractor Name","description":"Name of the feature extractor"},"version":{"type":"string","title":"Version","description":"Version of the feature extractor (e.g., 'v1', 'v2')"},"params":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Params","description":"Optional extractor parameters that affect vector index configuration. Parameters set here are locked at namespace creation and determine vector dimensions in the vector store. Collections using this extractor must use compatible params. Example: {'model': 'siglip_base'}"}},"type":"object","required":["feature_extractor_name","version"],"title":"BaseFeatureExtractorModel","description":"Minimum feature extractor definition."},"BaseFeatureExtractorModel-Output":{"properties":{"feature_extractor_name":{"type":"string","title":"Feature Extractor Name","description":"Name of the feature extractor"},"version":{"type":"string","title":"Version","description":"Version of the feature extractor (e.g., 'v1', 'v2')"},"params":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Params","description":"Optional extractor parameters that affect vector index configuration. Parameters set here are locked at namespace creation and determine vector dimensions in the vector store. Collections using this extractor must use compatible params. Example: {'model': 'siglip_base'}"},"feature_extractor_id":{"type":"string","title":"Feature Extractor Id","description":"Construct unique identifier for the feature extractor instance (name + version).","readOnly":true}},"type":"object","required":["feature_extractor_name","version","feature_extractor_id"],"title":"BaseFeatureExtractorModel","description":"Minimum feature extractor definition."},"BaseRateLimits":{"properties":{"metadata":{"type":"integer","minimum":1.0,"title":"Metadata","description":"REQUIRED. Rate limit for infrastructure and configuration operations (namespaces, collections, retrievers, taxonomies, clusters CRUD). These are zero-credit operations with highest rate limits since they're cheap to execute. Examples: creating collections, updating retrievers, listing namespaces.","default":10,"examples":[20,100,200]},"data":{"type":"integer","minimum":1.0,"title":"Data","description":"REQUIRED. Rate limit for data operations (objects, documents CRUD). Low-credit operations with high rate limits. Examples: creating documents, updating objects, batch document updates.","default":10,"examples":[10,60,100]},"search":{"type":"integer","minimum":1.0,"title":"Search","description":"REQUIRED. Rate limit for search and retrieval operations (retriever/taxonomy execution). Medium-credit operations with moderate rate limits. Examples: executing retrievers, running taxonomy matching.","default":10,"examples":[10,60,100]},"upload":{"type":"integer","minimum":1.0,"title":"Upload","description":"REQUIRED. Rate limit for file upload operations. Credit-intensive (1 credit/MB) with lower rate limits to prevent excessive resource consumption. Examples: uploading files, generating presigned URLs.","default":10,"examples":[5,30,50]},"compute":{"type":"integer","minimum":1.0,"title":"Compute","description":"REQUIRED. Rate limit for compute operations (cluster execution, batch processing). High-credit operations (10 credits/min video) with lowest rate limits. Examples: submitting batches, executing clusters, triggering syncs.","default":10,"examples":[5,30,50]}},"type":"object","title":"BaseRateLimits","description":"Rate limits by operation type (requests per minute).\n\nThe rate limiting system uses 5 categories aligned with actual resource consumption:\n\nCategories:\n    metadata: Infrastructure and configuration operations (namespaces, collections,\n             retrievers, taxonomies, clusters CRUD). Zero-credit operations with\n             highest rate limits.\n\n    data: Data operations (objects, documents CRUD). Low-credit operations with\n          high rate limits.\n\n    search: Search and retrieval operations (retriever/taxonomy execution).\n            Medium-credit operations with moderate rate limits.\n\n    upload: File upload operations (credit-intensive: 1 credit/MB). Variable-credit\n            operations with lower rate limits.\n\n    compute: Compute operations (cluster execution, batch processing). High-credit\n             operations (10 credits/min video) with lowest rate limits.\n\nRate Limit Strategy:\n    Higher limits for low-cost operations (metadata, data)\n    Lower limits for high-cost operations (upload, compute)\n    This aligns API throttling with actual infrastructure costs\n\nExamples:\n    - Creating a namespace: Uses 'metadata' category (fast, cheap)\n    - Uploading a file: Uses 'upload' category (slow, expensive per MB)\n    - Executing a retriever: Uses 'search' category (moderate cost)\n    - Running batch processing: Uses 'compute' category (very expensive)"},"BaseTemplateModel":{"properties":{"template_id":{"type":"string","pattern":"^tmpl_[a-z0-9_]+$","title":"Template Id","description":"Unique template identifier (e.g., 'tmpl_semantic_search')"},"template_type":{"$ref":"#/components/schemas/TemplateType","description":"Type of resource this template creates"},"mode":{"$ref":"#/components/schemas/TemplateMode","description":"Template instantiation mode: clone (with data), config (empty), or scaffold (preset)","default":"config"},"scope":{"$ref":"#/components/schemas/TemplateScope","description":"Template scope (system or organization)"},"internal_id":{"type":"string","title":"Internal Id","description":"Organization internal ID. For system templates, use 'system'. For org templates, use the actual internal_id."},"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Human-readable template name"},"description":{"type":"string","maxLength":1000,"minLength":1,"title":"Description","description":"Detailed description of the template's purpose"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category","description":"Optional category for organizing templates"},"configuration":{"additionalProperties":true,"type":"object","title":"Configuration","description":"Template-specific configuration (varies by template_type)"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Tags for categorizing and filtering templates"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether this template is available for use","default":true},"is_public":{"type":"boolean","title":"Is Public","description":"Whether this template is publicly discoverable without authentication","default":false},"use_cases":{"items":{"type":"string"},"type":"array","title":"Use Cases","description":"List of common use cases for this template"},"requirements":{"items":{"type":"string"},"type":"array","title":"Requirements","description":"List of requirements (e.g., 'Requires text embeddings')"},"created_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By","description":"User ID who created this template (for org templates)"},"source_resource_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Resource Id","description":"ID of the resource this template was created from (for org templates)"},"sample_namespace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sample Namespace Id","description":"Reference to a sample/golden namespace for this scaffold (used for Studio quickstart cloning)"},"example_queries":{"items":{"type":"string"},"type":"array","title":"Example Queries","description":"Runnable example queries for this template's sample data; the first renders on the card"},"whats_inside":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Whats Inside","description":"One-sentence description of the sample corpus (what you get, with counts)"},"materialize_estimate":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Materialize Estimate","description":"Honest time estimate for sample data to become searchable after instantiate"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Timestamp when template was created"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Timestamp when template was last updated"}},"type":"object","required":["template_id","template_type","scope","internal_id","name","description","configuration"],"title":"BaseTemplateModel","description":"Base template model with common fields for all template types.\n\nThis model is stored in MongoDB and supports three template scopes:\n- System: Mixpeek defaults (all orgs)\n- Organization: All users in the org\n- User: Only the creator","examples":[{"category":"semantic_search","configuration":{"input_schema":{},"stages":[]},"created_at":"2025-01-15T12:00:00Z","description":"Simple text-based semantic search","internal_id":"system","is_active":true,"is_public":true,"name":"Basic Semantic Search","scope":"system","template_id":"tmpl_semantic_search","template_type":"retriever"}]},"BatchChunkStats":{"properties":{"unit":{"type":"string","title":"Unit","description":"Realized unit the chunker grouped by: characters, words, sentences, paragraphs, pages, seconds (time_segments), or none (no chunking; one chunk per input row)."},"total_chunks":{"type":"integer","title":"Total Chunks","description":"Total chunks produced across all processed rows.","default":0},"mean_units_per_chunk":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Mean Units Per Chunk","description":"Mean realized chunk size, measured in `unit`. A value near 1 for a count unit (sentences/paragraphs/pages) with a larger configured chunk_size means the configuration is not taking effect as intended."}},"type":"object","required":["unit"],"title":"BatchChunkStats","description":"Realized chunking statistics reported by the text chunker.\n\nSurfaces what chunking ACTUALLY did, measured in the split strategy's\nown unit, so an inert or unit-confused chunking config (for example a\nchunk_size chosen in the wrong unit) is visible by reading the batch\ninstead of forensically diffing two configs' outputs."},"BatchConfirmRequest":{"properties":{"confirmations":{"items":{"additionalProperties":true,"type":"object"},"type":"array","maxItems":100,"minItems":1,"title":"Confirmations","description":"List of confirmations with upload_id, etag, file_size_bytes"}},"type":"object","required":["confirmations"],"title":"BatchConfirmRequest","description":"Request to confirm multiple uploads in batch.","examples":[{"confirmations":[{"etag":"d41d8cd98f00b204e9800998ecf8427e","file_size_bytes":10485760,"upload_id":"upl_abc123"},{"etag":"7f9c12ab56f4e12d80cf8d98fe12c4a9","file_size_bytes":5242880,"upload_id":"upl_def456"}]}]},"BatchConfirmResponse":{"properties":{"task_id":{"type":"string","title":"Task Id","description":"Task ID for tracking batch confirmation progress"},"status":{"$ref":"#/components/schemas/TaskStatusEnum","description":"Task status"},"confirmations_count":{"type":"integer","title":"Confirmations Count","description":"Number of confirmations being processed"},"task":{"$ref":"#/components/schemas/TaskResponse","description":"Full task details"},"message":{"type":"string","title":"Message","description":"Status message","default":"Batch confirmation is being processed in the background."}},"type":"object","required":["task_id","status","confirmations_count","task"],"title":"BatchConfirmResponse","description":"Response from batch confirmation."},"BatchCost":{"properties":{"credits_consumed":{"type":"integer","minimum":0.0,"title":"Credits Consumed","description":"Total credits recorded against this batch in usage_records (resource_type='batch'). 0 if no usage has been recorded yet (e.g. DRAFT batches, ENTERPRISE tiers that skip credit consumption, or batches submitted before metering existed).","default":0,"examples":[0,100,4820]},"cost_usd":{"type":"number","minimum":0.0,"title":"Cost Usd","description":"Derived dollar cost = credits_consumed * $0.001/credit (CREDIT_RATE_USD). Same rate used by monthly invoicing, so this matches what the batch contributes to the bill. Reads 0 for org classes the credits system floors or skips entirely (enterprise, internal, failed batches) -- see metered_model_usd for what this batch's work actually cost in that case.","default":0.0,"examples":[0.0,0.1,4.82]},"credit_rate_usd":{"type":"number","title":"Credit Rate Usd","description":"USD per credit used to derive cost_usd ($0.001/credit).","default":0.001},"metered_model_usd":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Metered Model Usd","description":"The batch's real metered provider cost (e.g. Gemini token spend), from its stored cost_plus block, when the batch has finished and that block exists. This is the figure that still reflects real spend for org classes cost_usd reads 0 for (enterprise, internal, failed batches) -- see shared/billing/cost_plus_floor.py. None, not 0, when no cost_plus block exists yet (not yet computed, or the batch predates the cost-plus floor).","examples":[null,0.064708,1.2]}},"type":"object","title":"BatchCost","description":"Dollar cost of a batch, derived from recorded credit usage.\n\nMixpeek meters work in *credits* (recorded in the usage_records\ncollection at credit-consume time, keyed by ``resource_id=batch_id`` /\n``resource_type=\"batch\"``). There is no separately-stored per-batch USD\nfigure, so cost is derived at read time as\n``credits_consumed * CREDIT_RATE_USD`` using the same canonical\n$0.001/credit rate the billing/invoicing path uses. This lets callers\nanswer \"what did this batch cost?\" from the batch GET response without\nGCP billing labels or a separate billing query.\n\ncredits_consumed/cost_usd read 0 for org classes the credits system was\nnever meant to charge at all (enterprise contract-billed, internal,\nfailed batches -- see shared/billing/cost_plus_floor.py), even though\nthose batches incurred real, known provider spend. metered_model_usd\nsurfaces that real figure (already computed and stored on the batch's own\ncost_plus block) so this response never reads a flat 0 for a batch that\nactually cost something. Additive only: cost_usd keeps its existing\ncredits*rate meaning for every consumer that already depends on it."},"BatchCostEstimate":{"properties":{"batch_id":{"type":"string","title":"Batch Id"},"collection_ids":{"items":{"type":"string"},"type":"array","title":"Collection Ids"},"dedup_strategy":{"type":"string","title":"Dedup Strategy","description":"skip | replace | force — controls re-extraction","default":"skip"},"object_count":{"type":"integer","title":"Object Count","description":"Objects this batch will process","default":0},"already_extracted_count":{"type":"integer","title":"Already Extracted Count","description":"Objects in this batch already extracted before (re-paid under force/replace)","default":0},"estimated_credits":{"type":"integer","title":"Estimated Credits","description":"Credits submitting this batch will consume (same calc as submit)","default":0},"estimated_usd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Estimated Usd","description":"Dollar cost of this batch under live v2 pricing (file type × amount × search-by features). Credits are milli-dollars of this value."},"estimated_repay_credits":{"type":"integer","title":"Estimated Repay Credits","description":"~credits re-paying already-extracted objects (force/replace only; linear approx)","default":0},"features":{"items":{"type":"string"},"type":"array","title":"Features","description":"What this batch searches by (dimension 3 of pricing): feature keys billed per file type; custom plugins as 'custom:<name>'."},"extractors":{"items":{"type":"string"},"type":"array","title":"Extractors","description":"Internal implementation of `features` — prefer rendering `features`; extractor names are the deeper disclosure layer."},"content_summary":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Content Summary","description":"Dimensions 1+2 of pricing: file types and how much of each (counts, video minutes, pages, tokens…)"},"documents_to_remove":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Documents To Remove","description":"OPTIONAL. For dedup_strategy replace: the documents the batch's objects have now in its collections. A replace removes each of these that its re-run does not overwrite in place, after the new documents are written, so this is the most it removes. Absent for skip and force."},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings"}},"type":"object","required":["batch_id"],"title":"BatchCostEstimate","description":"Dry-run estimate of what submitting a DRAFT batch will cost + re-pay."},"BatchDeleteDocumentsRequest":{"properties":{"document_ids":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":1000,"minItems":1},{"type":"null"}],"title":"Document Ids","description":"OPTIONAL. List of document IDs to delete. Use this mode when you know exact document IDs to delete. Mutually exclusive with filters mode. Maximum 1000 documents per batch request.","examples":[["doc_123","doc_456","doc_789"],["doc_frame_001","doc_frame_002"]]},"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"OPTIONAL. Filter conditions to match documents for deletion. Mutually exclusive with 'document_ids' array. If provided, deletes ALL documents matching the filters. Use with caution - can delete many documents at once. Uses the logical AND/OR/NOT shape (not MVS-native must/key).","examples":[{"AND":[{"field":"metadata.status","operator":"eq","value":"archived"}]}]},"reason":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Reason","description":"OPTIONAL. Why this bulk delete is happening — recorded on the DOCUMENT_BULK_SOFT_DELETED audit event so a document-level wipe carries the caller's own context, not just the actor and counts.","examples":["retention policy cleanup","customer-requested erasure"]}},"type":"object","title":"BatchDeleteDocumentsRequest","description":"Request model for batch deleting multiple documents by explicit IDs or filters.\n\nSupports TWO modes:\n1. Explicit IDs mode: Provide 'document_ids' array\n2. Filter mode: Provide 'filters' to delete all matching documents\n\nUse Cases:\n    - Delete 5 specific documents in one API call\n    - Delete all documents matching criteria\n    - Bulk cleanup operations\n\nRequirements:\n    - EITHER 'document_ids' OR 'filters' must be provided\n    - NOT BOTH modes simultaneously","examples":[{"description":"Explicit IDs mode: Delete 3 specific documents","document_ids":["doc_123","doc_456","doc_789"]},{"description":"Filter mode: Delete all archived documents","filters":{"AND":[{"field":"metadata.status","operator":"eq","value":"archived"}]}}]},"BatchDeleteDocumentsResponse":{"properties":{"task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id","description":"Id of the background task for a FILTER-mode delete. Null for explicit-IDs mode (which completes synchronously). Poll GET /v1/tasks/{task_id} for status and the final deleted_count."},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Task status at enqueue time (PENDING) for a filter-mode delete. Null for the synchronous explicit-IDs mode."},"deleted_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Deleted Count","description":"Total number of documents successfully deleted. Null on the async filter-mode enqueue response; populated on the task record when it completes, and returned synchronously in explicit-IDs mode."},"failed_count":{"type":"integer","title":"Failed Count","description":"Total number of documents that failed to delete","default":0},"results":{"items":{"$ref":"#/components/schemas/BatchDocumentDeleteResult"},"type":"array","title":"Results","description":"Detailed per-document results. Each entry shows document_id, success status, and error message (if failed). Empty list when using filter mode (only counts returned)."},"limits":{"anyOf":[{"additionalProperties":{"type":"integer"},"type":"object"},{"type":"null"}],"title":"Limits","description":"Filter mode only: the caps this request ran against. max_rows_inline is the row cap under which a delete by filter runs in the request; matched is how many documents the filter matched when the request arrived. Over the cap the delete runs as a task (task_id).","examples":[{"matched":5000,"max_rows_inline":10000}]},"message":{"type":"string","title":"Message","description":"Summary message of the operation","default":"Batch delete completed"}},"type":"object","title":"BatchDeleteDocumentsResponse","description":"Response model for batch document delete operation.\n\nTwo shapes, keyed on the request mode:\n- Explicit IDs mode is SYNCHRONOUS and fast (targets point ids directly):\n  deleted_count / failed_count / results are populated, task_id is null.\n- Filter mode is ASYNC: it scrolls matches on the shard, which can exceed a\n  request's connection window (same cost shape as bulk update), so\n  it enqueues a task and returns task_id + status=PENDING with deleted_count\n  null. Poll GET /v1/tasks/{task_id} for the terminal status and deleted_count.","examples":[{"deleted_count":3,"failed_count":0,"message":"Successfully deleted 3 document(s)","results":[{"document_id":"doc_123","success":true},{"document_id":"doc_456","success":true},{"document_id":"doc_789","success":true}]}]},"BatchDiagnostics":{"properties":{"batch_id":{"type":"string","title":"Batch Id","description":"Batch ID"},"batch_name":{"type":"string","title":"Batch Name","description":"Batch name"},"status":{"type":"string","title":"Status","description":"Overall batch status"},"bucket_id":{"type":"string","title":"Bucket Id","description":"Source bucket ID"},"current_tier":{"type":"integer","title":"Current Tier","description":"Current tier being processed","default":0},"total_tiers":{"type":"integer","title":"Total Tiers","description":"Total number of tiers","default":1},"overall_progress":{"type":"number","title":"Overall Progress","description":"Overall progress percentage (0-100)","default":0.0},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When batch was created"},"submitted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Submitted At","description":"When batch was submitted"},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At","description":"When processing started"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"When processing completed"},"duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Seconds","description":"Total duration in seconds"},"estimated_completion":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Estimated Completion","description":"Estimated completion time"},"tiers":{"items":{"$ref":"#/components/schemas/TierDiagnostic"},"type":"array","title":"Tiers","description":"Diagnostic info for each tier"},"collections":{"items":{"$ref":"#/components/schemas/CollectionDiagnostic"},"type":"array","title":"Collections","description":"Status of target collections"},"performance_summary":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Performance Summary","description":"Performance metrics summary (available after completion)"},"insights":{"items":{"$ref":"#/components/schemas/PerformanceInsight"},"type":"array","title":"Insights","description":"Performance insights and recommendations"},"has_failures":{"type":"boolean","title":"Has Failures","description":"Whether batch has any failures","default":false},"failed_tier_count":{"type":"integer","title":"Failed Tier Count","description":"Number of failed tiers","default":0},"health":{"type":"string","title":"Health","description":"Derived health signal: 'ok', 'scaling' (PROCESSING with no progress yet but still inside the GPU cold-start / cluster-provisioning window — a scale-from-zero node and image pull can take ~20 min, so this is expected, not stuck), 'stuck' (PROCESSING but no progress and the active tier's job has been PENDING past the cold-start window — its driver/worker may be unschedulable), or 'degraded' (has partial failures).","default":"ok"},"blocked_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Blocked Reason","description":"Human-readable reason the batch appears stuck/blocked, or — for health='scaling' — why it is legitimately waiting (e.g. 'cluster_cold_start: GPU workers scaling from zero'). None when health is 'ok' or 'degraded'."},"stuck_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stuck Seconds","description":"How long the batch has been making no progress while PROCESSING, in seconds. None when not stuck."},"total_objects":{"type":"integer","title":"Total Objects","description":"Total objects in batch","default":0},"next_actions":{"items":{"type":"string"},"type":"array","title":"Next Actions","description":"Recommended next steps for user"}},"type":"object","required":["batch_id","batch_name","status","bucket_id"],"title":"BatchDiagnostics","description":"Comprehensive batch diagnostics response.\n\nCombines batch status, task progress, collection info, and performance\ninsights into a single response for easy frontend rendering."},"BatchDocumentDeleteResult":{"properties":{"document_id":{"type":"string","title":"Document Id","description":"Document ID that was deleted"},"success":{"type":"boolean","title":"Success","description":"Whether the deletion succeeded"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if deletion failed"}},"type":"object","required":["document_id","success"],"title":"BatchDocumentDeleteResult","description":"Result of a single document deletion in a batch operation."},"BatchDocumentUpdate":{"properties":{"document_id":{"type":"string","title":"Document Id","description":"REQUIRED. Document ID to update. Must exist in the collection. Format: 'doc_' prefix + alphanumeric characters.","examples":["doc_abc123","doc_frame_001"]},"update_data":{"additionalProperties":true,"type":"object","title":"Update Data","description":"REQUIRED. Fields to update for this specific document. Can update any document field except vectors. Supported fields: metadata, source_blobs, document_blobs, lineage fields (root_object_id, source_type, etc.), and any custom fields. Each document in the batch can have different update_data. A dotted key sets one nested field and keeps its siblings: {'metadata.status': 'processed'} changes only metadata.status. A key without a dot replaces that whole top-level field, so {'metadata': {'status': 'processed'}} replaces the entire metadata object and drops its other keys. ","examples":[{"metadata.score":0.95,"metadata.status":"processed"},{"metadata.reviewed":true,"metadata.reviewer":"John"}]}},"type":"object","required":["document_id","update_data"],"title":"BatchDocumentUpdate","description":"Single document update specification for batch operations.\n\nRepresents one document's update within a batch request.","examples":[{"document_id":"doc_abc123","update_data":{"metadata.status":"processed"}}]},"BatchDocumentUpdateResult":{"properties":{"document_id":{"type":"string","title":"Document Id","description":"Document ID that was updated"},"success":{"type":"boolean","title":"Success","description":"Whether the update succeeded"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if update failed"}},"type":"object","required":["document_id","success"],"title":"BatchDocumentUpdateResult","description":"Result of a single document update in a batch operation."},"BatchErrorDetail":{"properties":{"error_type":{"$ref":"#/components/schemas/ErrorCategory","description":"REQUIRED. Category of error that occurred. Used for filtering, retry logic, and error analytics. DEPENDENCY: Missing packages/modules (e.g., google-genai not installed). AUTHENTICATION: Invalid credentials or expired tokens. VALIDATION: Schema mismatches or invalid input data. RUNTIME: Code exceptions or processing failures. NETWORK: Connectivity issues or timeouts. RESOURCE: Out of memory or disk space.","examples":["dependency","authentication","validation"]},"message":{"type":"string","title":"Message","description":"REQUIRED. Human-readable error message. Concise description of what went wrong. Should be actionable and help users understand the issue.","examples":["Missing required package: google-genai","Invalid API key for Vertex AI","Schema validation failed: missing required field 'products'"]},"component":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Component","description":"OPTIONAL. Component or service where the error occurred. Helps identify which part of the system failed. Examples: service class names, module names, or feature names.","examples":["VertexMultimodalService","WhisperTranscriptionService","GeminiExtractor"]},"stage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stage","description":"OPTIONAL. Processing stage where the error occurred. Identifies which pipeline stage failed. Examples: pipeline stage names from collection configuration.","examples":["gemini_extraction","whisper_transcription","embedding_generation"]},"traceback":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Traceback","description":"OPTIONAL. Full Python traceback for debugging. Includes stack trace for code-level troubleshooting. Should be truncated if too long (e.g., max 2000 chars).","x-mixpeek-redacted":"driver_text"},"timestamp":{"type":"string","format":"date-time","title":"Timestamp","description":"REQUIRED. ISO 8601 timestamp when the error occurred. Used for chronological error tracking and debugging.","examples":["2025-11-29T10:15:30Z"]},"affected_document_ids":{"items":{"type":"string"},"type":"array","title":"Affected Document Ids","description":"OPTIONAL. List of document IDs affected by this error. For object-level errors: contains single document ID. For batch-level aggregation: contains all affected document IDs. Used to identify scope of impact.","examples":[["doc_123"],["doc_123","doc_456","doc_789"]]},"affected_count":{"type":"integer","minimum":1.0,"title":"Affected Count","description":"REQUIRED. Number of documents affected by this error. For object-level: typically 1. For batch-level aggregation: total count of affected documents. Used for error impact analysis.","default":1,"examples":[1,10,50]},"recovery_suggestion":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recovery Suggestion","description":"OPTIONAL. Actionable suggestion for resolving the error. Helps users quickly fix common issues. Examples: install missing package, check credentials, update schema.","examples":["Install google-genai package: pip install google-genai","Verify your Vertex AI credentials are configured correctly","Update your schema to include required 'products' field"]},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"OPTIONAL. Additional error context and metadata. Free-form dictionary for error-specific details. Examples: retry_count, last_retry_at, error_code, http_status.","examples":[{"last_retry_at":"2025-11-29T10:10:00Z","retry_count":2},{"api_endpoint":"https://vertex.googleapis.com","http_status":401}]}},"type":"object","required":["error_type","message"],"title":"BatchErrorDetail","description":"Detailed error information for batch processing failures.\n\nProvides structured error tracking at both object and batch levels.\nEnables better debugging, retry logic, and error analytics.\n\nUse Cases:\n    - Track specific errors that occurred during processing\n    - Identify error patterns across multiple documents\n    - Provide actionable recovery suggestions\n    - Enable intelligent retry logic based on error type\n\nObject-level tracking: Attached to individual document processing failures\nBatch-level tracking: Aggregated summaries in batch metadata","examples":[{"affected_count":1,"affected_document_ids":["doc_123"],"component":"VertexMultimodalService","description":"Dependency error: Missing package","error_type":"dependency","message":"Cannot import 'genai' from 'google' package","metadata":{"import_path":"google.genai","package_name":"google-genai"},"recovery_suggestion":"Install google-genai package: pip install google-genai","stage":"gemini_extraction","timestamp":"2025-11-29T10:15:30Z","traceback":"ImportError: cannot import name 'genai' from 'google'..."},{"affected_count":2,"affected_document_ids":["doc_456","doc_789"],"component":"VertexMultimodalService","description":"Authentication error: Invalid credentials","error_type":"authentication","message":"Invalid grant: Bad Request","metadata":{"http_status":401,"retry_count":3},"recovery_suggestion":"Verify your Vertex AI service account credentials","stage":"gemini_extraction","timestamp":"2025-11-29T10:20:00Z"}]},"BatchExtractorProgress":{"properties":{"processed":{"type":"integer","title":"Processed","description":"Objects this extractor has fully processed so far.","default":0},"seconds_since_update":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Seconds Since Update","description":"Seconds since this extractor last reported activity, at the time the snapshot was written. A value that keeps growing while processed stays flat names the stuck step."}},"type":"object","title":"BatchExtractorProgress","description":"One extractor's progress within a multi-extractor tier."},"BatchGetDocumentsRequest":{"properties":{"document_ids":{"items":{"type":"string"},"type":"array","maxItems":1000,"minItems":1,"title":"Document Ids","description":"List of document IDs to retrieve."},"return_presigned_urls":{"type":"boolean","title":"Return Presigned Urls","description":"Generate presigned download URLs for document blobs. Defaults to true on this endpoint; set false to skip URL generation and receive raw storage URIs.","default":true}},"type":"object","required":["document_ids"],"title":"BatchGetDocumentsRequest","description":"Batch retrieve documents by their IDs."},"BatchGetDocumentsResponse":{"properties":{"documents":{"items":{"$ref":"#/components/schemas/DocumentResponse"},"type":"array","title":"Documents","description":"Retrieved documents."},"not_found":{"items":{"type":"string"},"type":"array","title":"Not Found","description":"Document IDs that were not found."}},"type":"object","title":"BatchGetDocumentsResponse","description":"Response for batch document retrieval."},"BatchListDocumentsRequest":{"properties":{"queries":{"items":{"$ref":"#/components/schemas/BatchListQuery"},"type":"array","maxItems":10,"minItems":1,"title":"Queries","description":"Queries to execute concurrently against the same namespace."}},"type":"object","required":["queries"],"title":"BatchListDocumentsRequest","description":"Batch-execute multiple namespace-scoped list-documents queries in parallel.\n\nIntended to collapse dossier / multi-collection UI N+1 patterns into one\nround-trip. Canvas pages that fan out 5–10 parallel `list_documents`\ncalls (e.g., scene counts + face clusters + scene archetypes filtered by\nthe same brand_slug) should bundle them here instead."},"BatchListDocumentsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/BatchListResult"},"type":"array","title":"Results","description":"One entry per input query, in the same order as requested."}},"type":"object","required":["results"],"title":"BatchListDocumentsResponse","description":"Response for `POST /v1/documents/list/batch`."},"BatchListQuery":{"properties":{"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key","description":"Client-supplied identifier echoed back in the response. Use anything unique within the batch (e.g., 'scenes', 'face_clusters')."},"request":{"$ref":"#/components/schemas/NamespaceListDocumentsRequest","description":"List-documents request body, identical to POST /v1/documents/list."}},"type":"object","required":["key","request"],"title":"BatchListQuery","description":"A single list-documents query within a batch-list request.\n\nEach query carries a client-supplied `key` used to correlate the result\nback to the caller, plus a full `NamespaceListDocumentsRequest` body —\nthe same shape accepted by `POST /v1/documents/list`."},"BatchListResult":{"properties":{"key":{"type":"string","title":"Key","description":"The client-supplied key from the request."},"response":{"anyOf":[{"$ref":"#/components/schemas/ListDocumentsResponse"},{"type":"null"}],"description":"List response on success; None when `error` is populated."},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Short human-readable error message if this sub-query failed. Per-query failures do not fail the whole batch."}},"type":"object","required":["key"],"title":"BatchListResult","description":"Single query result within a batch-list response."},"BatchMetadata":{"properties":{"campaign_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Campaign Id","description":"Identifier linking this batch to a marketing or processing campaign.","examples":["Q4_2025","onboarding_wave_3"]},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","description":"Origin of the batch data (e.g. an S3 prefix, partner name, or pipeline stage).","examples":["s3://raw-uploads/2026-05/","partner_acme"]},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags","description":"Free-form tags for filtering and grouping batches.","examples":[["video","high-priority"],["backfill","Q2"]]},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Free-form notes about this batch (intent, context, special handling).","examples":["Re-run after Whisper quota fix","Nightly uploads ingest"]}},"additionalProperties":true,"type":"object","title":"BatchMetadata","description":"Typed user-defined metadata for a batch.\n\nKnown fields are validated and surfaced in API docs. Additional\narbitrary keys are accepted via ``model_config extra=\"allow\"``."},"BatchModel":{"properties":{"batch_id":{"type":"string","title":"Batch Id","description":"OPTIONAL (auto-generated if not provided). Unique identifier for this batch. Format: 'btch_' prefix followed by 12-character secure token. Generated using generate_secure_token() from shared.utilities.helpers. Used to query batch status and track processing across tiers. Immutable after creation.","examples":["btch_abc123xyz789","btch_video_batch_01"]},"bucket_id":{"type":"string","title":"Bucket Id","description":"REQUIRED. Unique identifier of the bucket containing the objects to process. Must be a valid bucket ID that exists in the system. All object_ids must belong to this bucket. Format: Bucket ID as defined when bucket was created.","examples":["bkt_videos","bkt_documents_q4"]},"namespace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Namespace Id","description":"Namespace this batch belongs to. Stored at creation time."},"batch_name":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Batch Name","description":"OPTIONAL. Human-readable name given when the batch was created. Not unique; batch_id identifies the batch.","examples":["january_products","run-1"]},"status":{"$ref":"#/components/schemas/TaskStatusEnum","description":"OPTIONAL (defaults to DRAFT). Current processing status of the batch. Lifecycle: DRAFT → PENDING → IN_PROGRESS → COMPLETED/FAILED. DRAFT: Batch created but not yet submitted. PENDING: Batch submitted and queued for processing. IN_PROGRESS: Batch currently processing (one or more tiers active). COMPLETED: All tiers successfully completed. FAILED: One or more tiers failed. Aggregated from tier_tasks statuses during multi-tier processing.","default":"DRAFT","examples":["DRAFT","PENDING","IN_PROGRESS","COMPLETED","FAILED"]},"queue_context":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Queue Context","description":"The batch's wait for a processing slot. While the batch is PENDING/PROCESSING, a GET adds how many earlier active batches are ahead in this namespace's queue (batches_ahead) and its age (waiting_seconds). Once a batch that queued is admitted, the record keeps the wait for good: waited_seconds (total seconds spent queued, across tiers), reason (why it waited) and admitted_at; queued_at is set while it is waiting."},"object_ids":{"items":{"type":"string"},"type":"array","minItems":0,"title":"Object Ids","description":"List of object IDs to include in this batch. All objects must exist in the specified bucket_id. These objects are the source data for tier 0 processing. Collection-sourced batches may have empty object_ids. Objects are processed in parallel within each tier.","examples":[["obj_video_001","obj_video_002"],["obj_doc_123"]]},"dedup_strategy":{"$ref":"#/components/schemas/DedupStrategy","description":"Controls how objects already processed in prior batches are handled. Scoped to (bucket, collection). 'skip': Don't reprocess objects that already have documents. 'replace': Delete existing documents and reprocess. 'force': Process regardless, allowing duplicates.","default":"skip"},"effective_dedup_strategy":{"anyOf":[{"$ref":"#/components/schemas/DedupStrategy"},{"type":"null"}],"description":"The dedup strategy the batch actually ran with, when it differs from dedup_strategy. Set when the organization's spend policy blocks re-extraction, so a requested 'replace' or 'force' runs as 'skip'; progress.status_warnings carries the reason. Read-only, null when the requested strategy ran."},"submitted_by_key_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Submitted By Key Id","description":"key_id of the API key that submitted this batch, resolved server-side at creation. None for async/system-created batches with no request actor context. Audit only."},"submitted_by_key_prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Submitted By Key Prefix","description":"Display prefix of the submitting API key. Audit only."},"submitted_by_is_internal":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Submitted By Is Internal","description":"Whether the submitting key was server-verified internal AT SUBMIT TIME. None = no actor context (unattributable); never used for billing decisions (those read the live key marker)."},"dedup_audit":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Dedup Audit","description":"Per-collection dedup decisions. Keys are collection_ids; values contain dedup_strategy, total_input, skipped, processed, and skipped_object_ids (up to 1000). Written at TWO stages, deep-merged per collection: (1) the API at manifest build, when smart-skip enforcement excludes already-complete objects before any engine submission (fields prefixed manifest_*), and (2) the Engine after its resume filter runs on whatever residue was submitted."},"collection_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Collection Ids","description":"OPTIONAL. List of all collection IDs involved in this batch's processing. Automatically populated during DAG resolution from dag_tiers. Includes collections from all tiers (flattened view of dag_tiers). Used for quick lookups without traversing tier structure. Format: List of collection IDs across all tiers.","examples":[["col_chunks"],["col_chunks","col_frames","col_scenes"]]},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"OPTIONAL. Legacy error message field for backward compatibility. None if batch succeeded or is still processing. Contains human-readable error description from first failed tier. DEPRECATED: Use tier_tasks[].errors for detailed error information. For multi-tier batches, typically contains the error from the first failed tier. Check tier_tasks array for tier-specific error details and error_summary for aggregation.","examples":["Failed to process batch: Object not found","Tier 1 failed: Out of memory during frame extraction","Collection 'col_frames' not found"],"x-mixpeek-redacted":"driver_text"},"failure_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Failure Reason","description":"OPTIONAL. Human-readable explanation of why the batch failed. None if batch succeeded, is still processing, or is in DRAFT/PENDING state. Populated automatically when a batch transitions to FAILED status. Provides a concise, actionable summary of the root cause. Common reasons include: Ray job failure (spot preemption, OOM, code errors), 0 documents written (processing completed but produced no output), processing stall (no activity detected for extended period), or task exception (submission/validation failures). Use this field for user-facing error displays and alerting.","examples":["Ray job failed: ImportError: No module named 'google.genai'","Processing completed but produced 0 documents. Check Ray job logs for '[FailureAggregator]' entries.","Processing stalled: no activity for 30 minutes. Job was cancelled automatically.","Namespace ns_abc123 no longer exists (may have been deleted)."],"x-mixpeek-redacted":"driver_text"},"error_summary":{"anyOf":[{"additionalProperties":{"type":"integer"},"type":"object"},{"type":"null"}],"title":"Error Summary","description":"OPTIONAL. Aggregated summary of errors across ALL tiers in the batch. Maps error_type (category) to total count of affected DOCUMENTS across all tiers. None has THREE causes, not two: the batch succeeded, it is still processing, OR a tier FAILED AT TIER LEVEL and wrote zero documents, so no individual document carries an error and this histogram is legitimately empty. So None does NOT mean 'no errors', and None alongside COMPLETED_WITH_ERRORS is NOT a contradiction — read `failure_reason` and `tier_tasks[].error` for tier-level diagnosis. Provides quick batch-wide overview of error distribution. Example: {'dependency': 15, 'authentication': 25, 'validation': 5} means across all tiers, 15 documents failed with dependency errors, 25 with auth errors, 5 with validation errors. Automatically aggregated from tier_tasks[].error_summary. Used for batch health dashboard and error trend analysis.","examples":[null,{"dependency":15},{"authentication":25,"runtime":10,"validation":5}]},"failure_category":{"anyOf":[{"$ref":"#/components/schemas/FailureCategory"},{"type":"null"}],"description":"OPTIONAL. Machine-readable classification of the batch failure. None if batch succeeded or is still processing. Auto-derived from `failure_reason` if not explicitly set, so existing writers that only populate `failure_reason` still get a category on read. Categories: timeout (stall/no-progress), infrastructure (OOM, workers died, spot preemption), orphaned (RayJob CRD gone), pipeline (genuine extractor/pipeline failure), validation (submission/schema errors), unknown (uncategorized). Use this instead of parsing failure_reason.","examples":[null,"timeout","infrastructure","pipeline"]},"failed_objects":{"items":{"$ref":"#/components/schemas/FailedObjectRecord"},"type":"array","title":"Failed Objects","description":"OPTIONAL. List of per-object failure records from batch processing. Populated when individual objects fail while others succeed. Each record includes the object_id, error message, error classification (transient/permanent/resource), and timestamp. When this list is non-empty and some objects succeeded, batch status is COMPLETED_WITH_ERRORS. Enables targeted resubmission of only failed objects.","examples":[[],[{"error":"Unsupported codec: VP9","error_type":"permanent","object_id":"obj_video_001","timestamp":"2025-11-29T10:15:30Z"},{"error":"Connection timeout to embedding service","error_type":"transient","object_id":"obj_doc_123","timestamp":"2025-11-29T10:15:35Z"}]]},"failed_object_count":{"type":"integer","minimum":0.0,"title":"Failed Object Count","description":"OPTIONAL. Count of objects that failed during batch processing and wrote no documents (an object whose documents were written but one feature failed is in partial_objects instead). Shorthand for len(failed_objects). Stored separately for efficient queries and sorting without loading full failed_objects array.","default":0,"examples":[0,3,15]},"partial_objects":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Partial Objects","description":"Objects that wrote documents while one of their features failed, for example a transcription error on a video whose scenes, descriptions and embeddings were written. Each entry carries the object_id, the error and missing_feature, the feature the object has no documents for, or null when the error names none. An object with no document in one of the batch's collections also carries missing_collection_ids. These objects are searchable through the documents they wrote and are not counted in failed_object_count; they count in progress.errors."},"partial_object_count":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Partial Object Count","description":"Number of objects in partial_objects."},"unaccounted_object_count":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Unaccounted Object Count","description":"Objects that produced NEITHER a document NOR a failure entry — the per-tier balance audits' summed `lost` (submitted - processed - failed - skipped), rolled up at completion so the gap is STATED on the record instead of inferred by subtraction. None when every submitted object is accounted for; per-tier detail lives at tier_tasks[].audit.","examples":[38]},"type":{"$ref":"#/components/schemas/BatchType","description":"OPTIONAL (defaults to BUCKET). Type of batch. BUCKET: Standard batch processing bucket objects through collections. COLLECTION: Reserved for future collection-only batch processing. Currently only BUCKET type is supported.","default":"BUCKET","examples":["BUCKET"]},"manifest_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Manifest Key","description":"OPTIONAL. S3 key where the batch manifest is stored. Contains metadata and row data (Parquet) for Engine processing. For tier 0, points to bucket object manifest. For tier N+, points to collection document manifest. Format: S3 path (e.g., 'namespace_id/internal_id/manifests/tier_0.parquet'). Generated during batch submission.","examples":["ns_abc/org_123/manifests/tier_0.parquet","ns_xyz/org_456/manifests/tier_1.parquet"]},"task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id","description":"OPTIONAL. Primary task ID for the batch (typically tier 0 task). Used for backward compatibility with single-tier batch tracking. For multi-tier batches, prefer querying tier_tasks array for granular tracking. Format: Task ID as generated for tier 0.","examples":["task_tier0_abc123","task_batch_001"]},"loaded_object_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Loaded Object Ids","description":"OPTIONAL. List of object IDs that were successfully validated and loaded into the batch. Subset of object_ids that passed validation. Used to track which objects are ready for processing. None if batch hasn't been validated yet.","examples":[["obj_video_001","obj_video_002"]]},"internal_metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Internal Metadata","description":"OPTIONAL. Internal engine/job metadata for system use. May contain: job_id (provider-specific), engine_version, processing hints, last_health_check. last_health_check: Most recent health check results with health_status, enriched_documents, vector_populated_count, stall_duration_seconds, recommendations, missing_features. Populated asynchronously (non-blocking, best-effort). Used for troubleshooting batch processing issues via API. NOTE: In MongoDB, this is stored under '_internal.processing' path.","examples":[{"include_history":true,"last_health_check":{"enriched_documents":98,"health_status":"HEALTHY","missing_features":["text_embedding"],"processed_documents":100,"recommendations":[],"stall_duration_seconds":0,"timestamp":"2025-11-06T10:05:00Z","total_documents":100,"vector_populated_count":98}}]},"metadata":{"$ref":"#/components/schemas/BatchMetadata","description":"OPTIONAL. User-defined metadata for the batch. Has typed fields (campaign_id, source, tags, notes) and also accepts arbitrary extra keys. Persisted with the batch and returned in API responses. Not used by the system for processing logic.","examples":[{"campaign_id":"Q4_2025","tags":["video","high-priority"]},{"notes":"Nightly uploads ingest","source":"s3://raw-uploads/2026-05/"}]},"tier_tasks":{"items":{"$ref":"#/components/schemas/TierTaskInfo"},"type":"array","title":"Tier Tasks","description":"OPTIONAL. List of tier task tracking information for multi-tier processing. Each element represents one tier in the processing pipeline. Empty array for simple single-tier batches. Populated during batch submission with tier 0 info, then appended as tiers progress. Each TierTaskInfo contains: tier_num, task_id, status, collection_ids, timestamps. Used for granular monitoring: 'Show me status of tier 2' or 'Retry tier 1'. Array index typically matches tier_num (tier_tasks[0] = tier 0, tier_tasks[1] = tier 1, etc.).","examples":[[],[{"collection_ids":["col_chunks"],"status":"COMPLETED","task_id":"task_tier0_abc","tier_num":0}]]},"current_tier":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Current Tier","description":"OPTIONAL. Zero-based index of the currently processing tier. None if batch hasn't started processing (status=DRAFT or PENDING). Updated as batch progresses through tiers. Used to show processing progress: 'Processing tier 2 of 5'. Set to last tier number when batch completes. Example: If processing tier 1 (frames), current_tier=1.","examples":[0,1,2]},"total_tiers":{"type":"integer","minimum":1.0,"title":"Total Tiers","description":"OPTIONAL (defaults to 1). Total number of tiers in the collection DAG. Minimum 1 (tier 0 only = bucket → collection). Set during DAG resolution when batch is submitted. Equals len(dag_tiers) if dag_tiers is populated. Used to calculate progress: current_tier / total_tiers. Example: 5-tier pipeline (bucket → chunks → frames → scenes → summaries) has total_tiers=5.","default":1,"examples":[1,3,5]},"dag_tiers":{"anyOf":[{"items":{"items":{"type":"string"},"type":"array"},"type":"array"},{"type":"null"}],"title":"Dag Tiers","description":"OPTIONAL. Complete DAG tier structure for this batch. List of tiers, where each tier is a list of collection IDs to process at that stage. Tier 0 = bucket-sourced collections. Tier N (N > 0) = collection-sourced collections. Collections within same tier have no dependencies (can run in parallel). Collections in tier N+1 depend on collections in tier N. Populated during DAG resolution at batch submission. Used for tier-by-tier processing orchestration. Example: [['col_chunks'], ['col_frames', 'col_objects'], ['col_scenes']] = 3 tiers where frames and objects run in parallel at tier 1.","examples":[[["col_chunks"]],[["col_chunks"],["col_frames"]],[["col_chunks"],["col_frames","col_objects"],["col_scenes"]]]},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"OPTIONAL (auto-set on creation). ISO 8601 timestamp when batch was created. Set using current_time() from shared.utilities.helpers. Immutable after creation. Used for batch age tracking and cleanup of old batches.","examples":["2025-11-03T10:00:00Z"]},"progress":{"anyOf":[{"$ref":"#/components/schemas/BatchProgress"},{"type":"null"}],"description":"OPTIONAL. Live progress snapshot updated approximately every 10 seconds while the batch is IN_PROGRESS. Written by the Ray ProgressActor inside the engine job. None when status is DRAFT or PENDING (job not started), or after COMPLETED/FAILED. Use this to show real-time progress bars: processed/total objects, percent complete, throughput (items_per_second), and estimated time remaining (eta_seconds).","examples":[null,{"batch_count":703,"errors":0,"eta_seconds":7308.0,"items_per_second":12.5,"percent":33.0,"processed":45000,"total":136356}]},"documents_written":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Documents Written","description":"OPTIONAL. Read-time aggregate of documents_written from tier_tasks and extractor_jobs. None means the completion callback has not reported write accounting yet.","examples":[null,1000]},"documents_replaced":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Documents Replaced","description":"OPTIONAL. For dedup_strategy replace: documents this batch wrote for the objects it replaced, summed over its tiers. Absent when the batch is not a replace."},"documents_deleted":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Documents Deleted","description":"OPTIONAL. For dedup_strategy replace: the replaced objects' existing documents removed after the new ones were written, summed over its tiers. A failed or cancelled batch removes none. Absent when the batch is not a replace."},"pages_dropped":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Pages Dropped","description":"OPTIONAL. Read-time aggregate of pages NOT indexed across extractor jobs — multi-page inputs (PDFs) capped by max_document_pages or dropped by per-page failures. Only present when > 0: a COMPLETED batch with pages_dropped > 0 indexed its inputs PARTIALLY. See pages_dropped_reasons; raise the collection's max_document_pages to index more pages.","examples":[null,10,355]},"pages_dropped_reasons":{"anyOf":[{"additionalProperties":{"type":"integer"},"type":"object"},{"type":"null"}],"title":"Pages Dropped Reasons","description":"OPTIONAL. Read-time aggregate of dropped-page counts by reason: max_document_pages_cap (input exceeded the collection's max_document_pages) or page_processing_failure (per-page extract/embed errors).","examples":[null,{"max_document_pages_cap":10}]},"segments_dropped":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Segments Dropped","description":"OPTIONAL. Read-time aggregate of video segments NOT indexed across extractor jobs. Only present when > 0: a COMPLETED batch with segments_dropped > 0 indexed its videos PARTIALLY. segments_dropped_reasons says why: for config_cap_max_video_segments, raise max_video_segments to cover more of each video; segment_embedding_failure segments were not written because their embedding failed, which raising max_video_segments does not recover.","examples":[null,5]},"segments_dropped_reasons":{"anyOf":[{"additionalProperties":{"type":"integer"},"type":"object"},{"type":"null"}],"title":"Segments Dropped Reasons","description":"OPTIONAL. Read-time aggregate of dropped-segment counts by reason: config_cap_max_video_segments (video exceeded the collection's max_video_segments) or segment_embedding_failure (a segment's embedding failed, so the segment was not written).","examples":[null,{"config_cap_max_video_segments":5}]},"status_diagnostics":{"additionalProperties":true,"type":"object","title":"Status Diagnostics","description":"Read-time diagnostics explaining terminal status, error indicators, and document-write accounting."},"documents_resolvable":{"type":"boolean","title":"Documents Resolvable","description":"ALWAYS PRESENT. True only after the server CONFIRMED this terminal batch's just-written documents are actually queryable via the filtered document get path: a confirmation, never a prediction, timestamp, or elapsed time. A COMPLETED batch with documents_resolvable=false is still finalizing: its documents may 404 on direct GET even though they are durable (Studio renders status==COMPLETED && documents_resolvable==false as a 'Finalizing, indexing your results' state and keeps polling). Batches created before the feature shipped emit true (historical, long since resolvable); post-ship batches with no stored value emit false (fail toward not-ready). If the bounded post-completion confirm cannot succeed, documents_resolvable_error is set and this flag stays false.","default":false},"documents_resolvable_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Documents Resolvable Error","description":"Terminal failure signal for the bounded resolvability confirm. Set when the post-completion confirm loop could not confirm this batch's documents were queryable within its bound, the case where documents may NEVER become resolvable. When set, documents_resolvable stays false and will not flip: stop polling and surface a 'taking longer than expected' state instead of a spinner. Null while the confirm is pending or after it succeeded.","x-mixpeek-redacted":"driver_text"},"health":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Health","description":"OPTIONAL. Computed health status for actively processing batches. Only populated when status is PROCESSING or IN_PROGRESS. Values: 'healthy' (recent activity detected), 'stalled' (no activity for 5+ minutes), 'unknown' (no heartbeat data yet). Computed from tier_tasks[].last_activity_at and updated_at. Use this to detect stuck batches before the internal stall detector kills them.","examples":["healthy","stalled","unknown",null]},"cost":{"anyOf":[{"$ref":"#/components/schemas/BatchCost"},{"type":"null"}],"description":"OPTIONAL. Dollar cost of this batch, derived at read time from the credits recorded against it in usage_records (credits_consumed * $0.001/credit). Lets callers answer 'what did this batch cost?' from the batch response without GCP billing labels. None when cost could not be looked up (e.g. the usage store was unavailable); 0 credits/USD when no usage has been recorded for the batch yet."},"last_activity_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Activity At","description":"OPTIONAL. Timestamp of the most recent activity across all tier tasks. Aggregated from tier_tasks[].last_activity_at — the latest heartbeat from any tier. Updated approximately every 10 seconds by the BatchJobPoller while processing. A stale value (minutes old) while status is PROCESSING indicates the batch may be stalled. None for batches that have not started processing or have no heartbeat data."},"retry_count":{"type":"integer","minimum":0.0,"title":"Retry Count","description":"OPTIONAL (defaults to 0). Number of times this batch has been auto-retried due to transient infrastructure failures (spot node preemption, OOM, actor death). Incremented each time the batch is automatically requeued after a retryable failure. User-facing: lets users see that retries happened transparently.","default":0,"examples":[0,1,2,3]},"max_retries":{"type":"integer","minimum":0.0,"title":"Max Retries","description":"OPTIONAL (defaults to 3). Maximum number of automatic retries for transient failures. When retry_count reaches max_retries, the batch stays in FAILED state. Only transient/infrastructure failures trigger retries — validation and data errors do not.","default":3,"examples":[3,5]},"last_retry_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Retry At","description":"OPTIONAL. ISO 8601 timestamp of the most recent auto-retry attempt. None if the batch has never been retried. Used to calculate exponential backoff for subsequent retries.","examples":[null,"2025-11-03T10:35:00Z"]},"retry_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retry Reason","description":"OPTIONAL. Human-readable reason for the most recent auto-retry. None if the batch has never been retried. Describes the transient failure that triggered the retry (e.g., 'Spot node preempted', 'Ray actor died', 'OOM killed').","examples":[null,"Spot node preempted","Ray actor died unexpectedly","Worker node evicted (OOM)"],"x-mixpeek-redacted":"driver_text"},"node_death_resubmit_count":{"type":"integer","minimum":0.0,"title":"Node Death Resubmit Count","description":"OPTIONAL (defaults to 0). Number of times Mixpeek resubmitted this batch on its own after its job was lost to node loss (a spot preemption, a node that died, or the job reaped for its resources). Each resubmit resumes from the objects already finished, so completed work is not re-extracted. Compare with max_node_death_resubmits to see how many automatic resubmits remain.","default":0,"examples":[0,1,3]},"deploy_resubmit_count":{"type":"integer","minimum":0.0,"title":"Deploy Resubmit Count","description":"OPTIONAL (defaults to 0). Number of times Mixpeek resubmitted this batch on its own after an engine deploy interrupted its job. Compare with max_deploy_resubmits to see how many automatic resubmits remain.","default":0,"examples":[0,1,2]},"quota_block_first_seen_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Quota Block First Seen At","description":"OPTIONAL. Set the first time this batch's Ray submission hit a quota-exhaustion or engine-deploy-lock gate (K8s admission 429/503), and cleared once a submission succeeds or the block's requeue window expires. Distinct from retry_count/last_retry_at above, which track the transient-infrastructure-failure retry mechanism (worker died, OOM, spot preemption) rather than this pre-submission gate. Used to bound the requeue loop to a fixed wall-clock window instead of retrying indefinitely.","examples":[null,"2026-09-19T02:10:00Z"]},"webhook_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Webhook Url","description":"OPTIONAL. URL to receive an HTTP POST notification when the batch reaches a terminal state (COMPLETED, FAILED, or CANCELED). Set at submit time via SubmitBatchRequest. The webhook is fire-and-forget: delivery failures are logged but never affect batch processing.","examples":["https://example.com/webhooks/batch-complete",null]},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"OPTIONAL (auto-updated). ISO 8601 timestamp when batch was last modified. Updated using current_time() whenever batch status or tier_tasks change. Used to track batch activity and identify stale batches.","examples":["2025-11-03T10:30:00Z"]},"status_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status Message","description":"COMPUTED. Human-readable description of the current batch state. Examples: 'Processing 724/50,000 objects (1.4%)', 'Queued — 2 batches ahead', 'Completed in 5m 23s', 'Loading model (stage 1/3)'. Computed on read, not stored in the database."},"estimated_completion":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Estimated Completion","description":"COMPUTED. Estimated completion timestamp based on current throughput. Derived from progress.eta_seconds + now. None if throughput data is unavailable. Computed on read, not stored in the database."},"max_node_death_resubmits":{"type":"integer","title":"Max Node Death Resubmits","description":"Most times Mixpeek resubmits a batch on its own after node loss. Once node_death_resubmit_count reaches this number, Mixpeek stops resubmitting and the batch needs a manual resubmit.","readOnly":true,"examples":[3]},"max_deploy_resubmits":{"type":"integer","title":"Max Deploy Resubmits","description":"Most times Mixpeek resubmits a batch on its own after an engine deploy interrupted it. Once deploy_resubmit_count reaches this number, Mixpeek stops resubmitting and the batch needs a manual resubmit.","readOnly":true,"examples":[2]},"lifecycle":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lifecycle","description":"Where the batch is in its life, one word: 'accepted' (created, not submitted), 'queued' (submitted, waiting for a processing slot), 'admitted' (has a slot, the extraction job has not started), 'extracting' (the extraction job is running), 'indexed' (finished, documents written), 'failed' or 'canceled'. status alone reads PENDING for both queued and admitted batches; this field tells them apart. lifecycle_reason says why the batch is where it is.","readOnly":true,"examples":["queued","extracting","indexed"]},"lifecycle_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lifecycle Reason","description":"Why the batch is in its current lifecycle state, in a sentence: the queue reason while queued, the failure reason once failed. Null when there is nothing to add.","readOnly":true,"examples":["Waiting for a processing slot: 2 earlier batches ahead."]}},"type":"object","required":["bucket_id","max_node_death_resubmits","max_deploy_resubmits","lifecycle","lifecycle_reason"],"title":"BatchModel","description":"Model representing a batch of objects for processing through collections.\n\nA batch groups bucket objects together for processing through one or more collections.\nBatches support multi-tier processing where collections are processed in dependency order\n(e.g., bucket → chunks → frames → scenes). Each tier has independent task tracking.\n\nUse Cases:\n    - Process multiple objects through collections in a single batch\n    - Track progress of multi-tier decomposition pipelines\n    - Monitor and retry individual processing tiers\n    - Query batch status and tier-specific task information\n\nLifecycle:\n    1. Created in DRAFT status with object_ids\n    2. Submitted for processing → status changes to PENDING\n    3. Each tier processes sequentially (tier 0 → tier 1 → ... → tier N)\n    4. Batch completes when all tiers finish (status=COMPLETED) or any tier fails (status=FAILED)\n\nMulti-Tier Processing:\n    - Tier 0: Bucket objects → Collections (bucket as source)\n    - Tier N (N > 0): Collection documents → Collections (upstream collection as source)\n    - Each tier gets independent task tracking via tier_tasks array\n    - Processing proceeds tier-by-tier with automatic chaining\n\nRequirements:\n    - batch_id: OPTIONAL (auto-generated if not provided)\n    - bucket_id: REQUIRED\n    - status: OPTIONAL (defaults to DRAFT)\n    - object_ids: REQUIRED for processing (must have at least 1 object)\n    - collection_ids: OPTIONAL (discovered via DAG resolution)\n    - tier_tasks: OPTIONAL (populated during processing)\n    - current_tier: OPTIONAL (set during processing)\n    - total_tiers: OPTIONAL (defaults to 1, set during DAG resolution)\n    - dag_tiers: OPTIONAL (populated during DAG resolution)","examples":[{"batch_id":"btch_simple_001","bucket_id":"bkt_videos","collection_ids":["col_chunks"],"dag_tiers":[["col_chunks"]],"description":"Simple single-tier batch (DRAFT)","metadata":{"campaign_id":"Q4_2025"},"object_ids":["obj_video_001","obj_video_002"],"status":"DRAFT","tier_tasks":[],"total_tiers":1,"type":"BUCKET"},{"batch_id":"btch_multitier_002","bucket_id":"bkt_videos","collection_ids":["col_chunks","col_frames","col_scenes"],"current_tier":1,"dag_tiers":[["col_chunks"],["col_frames"],["col_scenes"]],"description":"Multi-tier batch (IN_PROGRESS): Currently processing tier 1","manifest_key":"ns_abc/org_123/manifests/tier_1.parquet","metadata":{"user_email":"user@example.com"},"object_ids":["obj_video_001"],"status":"IN_PROGRESS","task_id":"task_tier0_abc123","tier_tasks":[{"collection_ids":["col_chunks"],"completed_at":"2025-11-03T10:05:00Z","source_type":"bucket","started_at":"2025-11-03T10:00:00Z","status":"COMPLETED","task_id":"task_tier0_abc123","tier_num":0},{"collection_ids":["col_frames"],"parent_task_id":"task_tier0_abc123","source_collection_ids":["col_chunks"],"source_type":"collection","started_at":"2025-11-03T10:05:00Z","status":"IN_PROGRESS","task_id":"task_tier1_def456","tier_num":1},{"collection_ids":["col_scenes"],"source_collection_ids":["col_frames"],"source_type":"collection","status":"PENDING","tier_num":2}],"total_tiers":3,"type":"BUCKET"},{"batch_id":"btch_complete_003","bucket_id":"bkt_videos","collection_ids":["col_chunks","col_frames","col_scenes"],"current_tier":2,"dag_tiers":[["col_chunks"],["col_frames"],["col_scenes"]],"description":"Multi-tier batch (COMPLETED): All 3 tiers finished","object_ids":["obj_video_001"],"status":"COMPLETED","tier_tasks":[{"collection_ids":["col_chunks"],"completed_at":"2025-11-03T10:05:00Z","status":"COMPLETED","task_id":"task_tier0_abc","tier_num":0},{"collection_ids":["col_frames"],"completed_at":"2025-11-03T10:10:00Z","status":"COMPLETED","task_id":"task_tier1_def","tier_num":1},{"collection_ids":["col_scenes"],"completed_at":"2025-11-03T10:15:00Z","status":"COMPLETED","task_id":"task_tier2_ghi","tier_num":2}],"total_tiers":3,"type":"BUCKET"},{"batch_id":"btch_failed_004","bucket_id":"bkt_videos","collection_ids":["col_chunks","col_frames"],"current_tier":1,"dag_tiers":[["col_chunks"],["col_frames"]],"description":"Multi-tier batch (FAILED): Tier 1 failed with dependency error","error":"Tier 1 failed: Missing required package: google-genai","error_summary":{"authentication":2,"dependency":5},"object_ids":["obj_video_001"],"status":"FAILED","tier_tasks":[{"collection_ids":["col_chunks"],"completed_at":"2025-11-03T10:05:00Z","errors":[],"status":"COMPLETED","task_id":"task_tier0_abc","tier_num":0},{"collection_ids":["col_frames"],"completed_at":"2025-11-03T10:06:30Z","error_summary":{"authentication":2,"dependency":5},"errors":[{"affected_count":5,"component":"VertexMultimodalService","error_type":"dependency","message":"Missing required package: google-genai","recovery_suggestion":"Install google-genai package","stage":"gemini_extraction"},{"affected_count":2,"component":"VertexMultimodalService","error_type":"authentication","message":"Invalid Vertex AI credentials"}],"status":"FAILED","task_id":"task_tier1_def","tier_num":1}],"total_tiers":2,"type":"BUCKET"}]},"BatchObjectResult":{"properties":{"object_id":{"type":"string","title":"Object Id","description":"Unique identifier for the object"},"bucket_id":{"type":"string","title":"Bucket Id","description":"ID of the bucket this object belongs to"},"key_prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Key Prefix","description":"Storage key/path of the object, this will be used to retrieve the object from the storage. It is similar to a file path. If not provided, it will be placed in the root of the bucket."},"blobs":{"items":{"$ref":"#/components/schemas/BlobModel"},"type":"array","title":"Blobs","description":"List of blobs contained in this object"},"source_details":{"items":{"$ref":"#/components/schemas/SourceDetails"},"type":"array","title":"Source Details","description":"Lineage/source details for this object; used for downstream references."},"edges":{"items":{"$ref":"#/components/schemas/EdgeModel"},"type":"array","title":"Edges","description":"Typed, directed relationships from this object to other objects (customer-owned, root-level — never `_internal`). Flows to the document + MVS payload for the `traverse_edge` retriever stage."},"status":{"$ref":"#/components/schemas/TaskStatusEnum","description":"Processing status of the object. A new object is PENDING, which means it has not been processed yet: either no batch including it has been submitted, or it is in a submitted batch that has not finished. The status of the object's batch tells these apart. When a batch run finishes with the object it becomes COMPLETED or FAILED.","default":"PENDING"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"The error message if the object failed to process.","examples":["Failed to process object: Object not found"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"Timestamp when the object was created. Automatically populated by the system."},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"Timestamp when the object was last updated. Automatically populated by the system."},"document_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Document Count","description":"Number of documents your collections have produced from this object. The object's own record in its bucket is not counted, so the value stays 0 until a collection has processed the object. Populated on GET and list responses. Null when the count cannot be read in time or the store did not answer in full. Use this to check if an object has already been processed."},"consistency":{"anyOf":[{"$ref":"#/components/schemas/WriteConsistency"},{"type":"null"}],"description":"When and how this object becomes a searchable document. Set on write (create) responses: managed ingestion is visible only after a collection batch processes the object — poll until document_count > 0."},"object_index":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Object Index","description":"Position in the request's `objects` list that this row answers. Rows are returned in request order; a failed request has no row here and appears in `failed` with the same index."},"replayed":{"type":"boolean","title":"Replayed","description":"True when this request created nothing and an existing object is returned unchanged: its idempotency_key matched an object, or skip_duplicates matched the same content. Its fields, key_prefix included, are the existing object's, not this request's.","default":false},"replayed_by":{"anyOf":[{"type":"string","enum":["idempotency_key","skip_duplicates"]},{"type":"null"}],"title":"Replayed By","description":"What matched the existing object, when replayed is true."}},"additionalProperties":true,"type":"object","required":["bucket_id"],"title":"BatchObjectResult","description":"One succeeded row of a batch create: the object, the request it answers,\nand whether it was created or already existed.","examples":[{"blobs":[{"blob_id":"blob_1","data":{"num_pages":5,"title":"Service Agreement 2024"},"key_prefix":"/contract-2024/content.pdf","metadata":{"author":"John Doe","department":"Legal"},"property":"content","type":"PDF"}],"bucket_id":"bkt_9xy8z7","content_hash":"28a9f5e8...","created_at":"2024-10-21T10:30:00Z","key_prefix":"/contract-2024","metadata":{"category":"contracts","year":2024},"object_id":"obj_123abc456def","skip_duplicates":false,"status":"PENDING","updated_at":"2024-10-21T10:30:00Z"}]},"BatchOptions":{"properties":{"batch_size":{"type":"integer","maximum":1000.0,"minimum":1.0,"title":"Batch Size","description":"Documents per batch","default":100},"max_workers":{"type":"integer","maximum":50.0,"minimum":1.0,"title":"Max Workers","description":"Maximum parallel workers","default":10},"retry_failed":{"type":"boolean","title":"Retry Failed","description":"Retry failed batches","default":true}},"type":"object","title":"BatchOptions","description":"Options for batch processing in migration."},"BatchPhaseDetail":{"properties":{"processed":{"type":"integer","title":"Processed","description":"Items completed in this phase.","default":0},"total":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total","description":"Items expected in this phase; null when indeterminate."},"status":{"type":"string","enum":["pending","active","done","error"],"title":"Status","description":"Phase status: 'pending', 'active', 'done', or 'error'.","default":"pending","examples":["pending","active","done","error"]}},"type":"object","title":"BatchPhaseDetail","description":"Per-phase progress for one streaming phase.\n\nRay Data streams, so extraction and write run concurrently. Each phase\ncarries its own honest counters. ``status`` is one of pending|active|\ndone|error. Exactly one phase is ``active`` at a time, and it matches\n``BatchStageInfo.name``. ``total`` is null when indeterminate (the write\nphase stays null until extraction drains — expanding pipelines emit N\noutput points per input object)."},"BatchPhases":{"properties":{"dispatch":{"$ref":"#/components/schemas/BatchPhaseDetail"},"extraction":{"$ref":"#/components/schemas/BatchPhaseDetail"},"write":{"$ref":"#/components/schemas/BatchPhaseDetail"}},"type":"object","title":"BatchPhases","description":"Honest streaming-phase breakdown — the SOLE per-stage source.\n\ndispatch → extraction → write. Exactly one phase is ``active``, and its key\nequals ``BatchStageInfo.name``. Consumed by Studio's BatchProgressDetail."},"BatchProgress":{"properties":{"processed":{"type":"integer","title":"Processed","description":"Number of objects fully processed so far.","default":0},"total":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total","description":"Total objects to process. None until the dataset is loaded by the engine."},"percent":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Percent","description":"Completion percentage (0–100). None until total is known."},"items_per_second":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Items Per Second","description":"Current throughput. Averaged over elapsed time since job start."},"eta_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Eta Seconds","description":"Estimated seconds remaining. None until both total and throughput are known."},"batch_count":{"type":"integer","title":"Batch Count","description":"Number of Ray map_batch micro-batches completed.","default":0},"errors":{"type":"integer","title":"Errors","description":"Number of items that errored during processing.","default":0},"first_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Error","description":"First item-level error captured during processing (truncated to ~500 chars), e.g. 'ValueError: cannot embed empty text'. Explains WHAT the `errors` counter is counting. None when no item-level error has been captured (or the engine image pre-dates this field). See also batch-level error_summary (error-type counts) and failed_objects (per-object detail).","x-mixpeek-redacted":"driver_text"},"extraction_first_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Extraction First Error","description":"First map/extraction-stage error (rows dropped before the datasink). Distinct from datasink write errors. Typically equals first_error unless a later write-stage error was also captured.","x-mixpeek-redacted":"driver_text"},"documents_skipped":{"type":"integer","title":"Documents Skipped","description":"Number of input rows the processor explicitly marked skipped (metadata-only objects, missing required embedding fields, content-flag filtered, null-text chunks). Skipped rows are not failures and not successes; they count toward the tier-completion invariant via the audit. Phase 1.3 of INGESTION_RELIABILITY_PLAN.md.","default":0},"objects_extracted":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Objects Extracted","description":"Objects that finished extraction (their rows reached the write stage). The batch headline (`processed`, `percent`, the status message) counts these, never the dispatch counter, so a batch whose objects all fail extraction reads 0 here and 0 percent. Null when the engine has not reported extraction progress yet.","examples":[0,1,3414]},"objects_skipped":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Objects Skipped","description":"Objects the pipeline deliberately skipped (nothing to embed, already extracted under dedup_strategy skip). Skipped objects are neither extracted nor failed. Null when `objects_extracted` is null.","examples":[0,12]},"objects_failed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Objects Failed","description":"Objects whose extraction failed. `failed_objects` on the batch lists them (bounded) and carries each error. Null when `objects_extracted` is null.","examples":[0,1,3414]},"current_stage":{"anyOf":[{"$ref":"#/components/schemas/BatchStageInfo"},{"type":"null"}],"description":"Current processing stage as reported by the Ray engine. Populated once the engine begins work (may lag by ~10s). Useful to distinguish 'loading model' from 'no activity' during early processing."},"phases":{"anyOf":[{"$ref":"#/components/schemas/BatchPhases"},{"type":"null"}],"description":"Honest streaming-phase breakdown: dispatch → extraction → write, each with its own processed/total/status. Exactly one phase is 'active' and its key equals current_stage.name. The SOLE per-stage source of truth — use this rather than current_stage for per-phase counters. None on engine images that pre-date this field."},"active_step":{"anyOf":[{"$ref":"#/components/schemas/BatchStepInfo"},{"type":"null"}],"description":"Active pipeline step for multi-step extractors. Shows which processor is currently running (e.g., 'GroundingDINOProcessor 1/3'). None for single-step pipelines."},"overshoot_percent":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Overshoot Percent","description":"When processed exceeds total (due to Ray Data retries or pipeline data expansion), this field shows the excess percentage above 100%. For example, 32.0 means 132% of items have been processed. None when processed <= total."},"queue_position":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Queue Position","description":"1-based position in the Ray job submission queue. Non-null only while the batch is waiting for a concurrency slot. Once a slot is acquired (job submitted to Ray), this becomes null."},"queue_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Queue Reason","description":"Why the batch is waiting, while it is QUEUED: the cluster's extractor capacity (how many of its extractor jobs are running and how many this batch needs) or the tier's concurrent-batch limit. Null once the batch starts."},"stage_history":{"anyOf":[{"items":{"$ref":"#/components/schemas/BatchStageTiming"},"type":"array"},{"type":"null"}],"title":"Stage History","description":"Completed stage timing breakdown, newest last. Populated as stages complete, capped at 50 entries by the writer; the stage still running is in current_stage and is NOT here. Null on the batch LIST path, which strips it for payload size, and present on GET /v1/buckets/{bucket_id}/batches/{batch_id}: null here means not returned on this path, not that no stages ran."},"documents_written":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Documents Written","description":"Derived documents written across completed tier/extractor jobs."},"chunk_stats":{"anyOf":[{"$ref":"#/components/schemas/BatchChunkStats"},{"type":"null"}],"description":"Realized chunking statistics (unit, total_chunks, mean units per chunk) reported by the text chunker. None for non-chunking extractors or engine images that pre-date this field."},"first_record_at":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"First Record At","description":"Unix time (seconds) at which the tier's pipeline processed its first record. None until a record has been processed."},"seconds_to_first_record":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Seconds To First Record","description":"Seconds from the tier's job start to its first processed record. None until a record has been processed."},"extractors":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/BatchExtractorProgress"},"type":"object"},{"type":"null"}],"title":"Extractors","description":"Per-extractor progress for a tier that runs more than one extractor, keyed by '{extractor_name}:{collection_id}'. Lists an extractor that has reported activity but no processed batch at processed 0. None for a single-extractor tier."},"status_warnings":{"items":{"type":"string"},"type":"array","title":"Status Warnings","description":"Read-time warnings that explain ambiguous terminal status or accounting gaps."}},"type":"object","title":"BatchProgress","description":"Live progress snapshot written by ProgressPoller every ~10 seconds while a batch is IN_PROGRESS.\n\nPopulated by the Ray ProgressActor running inside the engine job.\nNone when the batch has not started processing yet (DRAFT/PENDING) or if the engine\nimage pre-dates this field."},"BatchQueryItem":{"properties":{"inputs":{"additionalProperties":true,"type":"object","title":"Inputs","description":"Runtime inputs for this query (e.g., {'query': 'https://example.com/img.jpg'})"},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","description":"Optional per-query filters."}},"type":"object","required":["inputs"],"title":"BatchQueryItem","description":"A single query within a batch execution request."},"BatchStageInfo":{"properties":{"name":{"type":"string","title":"Name","description":"Honest active streaming phase: 'dispatch', 'extraction', or 'write'. Equals the one phase in BatchProgress.phases whose status is 'active'.","examples":["dispatch","extraction","write"]},"index":{"type":"integer","title":"Index","description":"1-based stage index within the current job."},"total":{"type":"integer","title":"Total","description":"Total stages in the current job."},"stage_elapsed_seconds":{"type":"number","title":"Stage Elapsed Seconds","description":"Seconds spent in this stage so far.","default":0.0},"sub_stage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sub Stage","description":"Sub-stage within 'processing': 'model_loading' while models are initializing, 'inferring' once the first batch completes, 'preparing_write' while the results are handed to the datasink. Helps explain why processed=0.","examples":["model_loading","inferring","preparing_write"]},"sub_stage_elapsed_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Sub Stage Elapsed Seconds","description":"Seconds spent in the CURRENT sub-stage, which is a different clock from stage_elapsed_seconds: a batch can be 90s into 'processing' and 85s into 'model_loading'. Null when sub_stage is null, and null on an engine image that predates this field; null means not reported, never zero seconds.","examples":[85.0]}},"type":"object","required":["name","index","total"],"title":"BatchStageInfo","description":"Current processing stage reported by the Ray engine.\n\n``name`` is now the honest *active* streaming phase —\n\"dispatch\" → \"extraction\" → \"write\" — derived from the phase machine\n(the true bottleneck), NOT the premature \"writing\" label that the\ndatasink used to emit on the first row. It is a LABEL ONLY; per-phase\ncounters live in ``BatchProgress.phases``. ``index``/``total`` stay as\nN-of-3. The stage name resets the stall timer, so users can see *what*\nthe job is doing even when processed=0 (e.g., waiting for a model load)."},"BatchStageTiming":{"properties":{"name":{"type":"string","title":"Name","description":"Stage name as the extractor reported it, for example 'loading'.","examples":["model_loading"]},"index":{"type":"integer","title":"Index","description":"1-based position of this stage within the job.","examples":[2]},"total":{"type":"integer","title":"Total","description":"Total stages the job declared.","examples":[4]},"started_at":{"type":"number","title":"Started At","description":"Epoch seconds when the stage began.","examples":[1789630000.12]},"ended_at":{"type":"number","title":"Ended At","description":"Epoch seconds when the stage ended.","examples":[1789630042.51]},"duration_seconds":{"type":"number","title":"Duration Seconds","description":"Wall-clock seconds the stage took, rounded to 2dp by the writer.","examples":[42.39]}},"type":"object","required":["name","index","total","started_at","ended_at","duration_seconds"],"title":"BatchStageTiming","description":"One completed stage of a batch, with the time it took.\n\nThese entries were typed ``Dict[str, Any]``, so codegen emitted\n``{[key: string]: any}[]`` and every client hand-declared the shape to read\na duration the server already measured.\n\nMIRRORED, like ``TierAuditInfo`` above and for the same reason: the entries\nare built by ``ProgressTracker.set_stage`` in\n``engine/monitoring/performance/utils.py``, which this module cannot import.\n``test_stage_history_wire_contract.py`` asserts the writer's keys and this\nmodel's fields stay identical, so a rename on either side fails a test\nrather than silently emptying a field for every consumer.\n\nTimestamps are epoch SECONDS as floats, which is what ``time.time()`` returns\nat the writer. They are not ISO strings and not milliseconds."},"BatchStatistics":{"properties":{"total":{"type":"integer","title":"Total","description":"Total number of batches in this bucket. Equals the sum of active, completed, completed_with_errors, failed, canceled and other.","default":0},"active":{"type":"integer","title":"Active","description":"Number of batches that are not finished (DRAFT, PENDING, QUEUED, IN_PROGRESS, PROCESSING)","default":0},"completed":{"type":"integer","title":"Completed","description":"Number of batches that completed with no failed items","default":0},"completed_with_errors":{"type":"integer","title":"Completed With Errors","description":"Number of batches that finished with some items failed. Read the batch's failed objects for what did not process.","default":0},"failed":{"type":"integer","title":"Failed","description":"Number of failed batches","default":0},"canceled":{"type":"integer","title":"Canceled","description":"Number of canceled batches","default":0},"other":{"type":"integer","title":"Other","description":"Number of batches in any other status, such as SKIPPED or UNKNOWN","default":0}},"type":"object","title":"BatchStatistics","description":"Statistics about batches in a bucket."},"BatchStepInfo":{"properties":{"name":{"type":"string","title":"Name","description":"Processor class name (e.g., 'GroundingDINOProcessor', 'SigLIPProcessor')."},"index":{"type":"integer","title":"Index","description":"1-based step index within the pipeline."},"total":{"type":"integer","title":"Total","description":"Total number of steps in the pipeline."},"step_elapsed_seconds":{"type":"number","title":"Step Elapsed Seconds","description":"Seconds spent in this step so far."}},"type":"object","required":["name","index","total","step_elapsed_seconds"],"title":"BatchStepInfo","description":"Active pipeline step for multi-step extractors (e.g., GroundingDINO → SigLIP).\n\nSurfaces which step is currently running and its position in the pipeline,\nso users can track progress through complex multi-model pipelines."},"BatchType":{"type":"string","enum":["BUCKET","COLLECTION"],"title":"BatchType","description":"The type of batch."},"BatchUpdateDocumentsRequest":{"properties":{"updates":{"anyOf":[{"items":{"$ref":"#/components/schemas/BatchDocumentUpdate"},"type":"array","maxItems":1000,"minItems":1},{"type":"null"}],"title":"Updates","description":"OPTIONAL. List of document updates with explicit document IDs. Each entry specifies document_id and update_data. Use this mode when you know exact document IDs and want per-document control. Mutually exclusive with filters + update_data mode. Maximum 1000 documents per batch request.","examples":[[{"document_id":"doc_123","update_data":{"metadata.status":"processed"}},{"document_id":"doc_456","update_data":{"metadata.status":"archived"}}]]},"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"OPTIONAL. Filter conditions to match documents for update. Must be used with 'update_data' field. Mutually exclusive with 'updates' array. If provided, applies same update_data to all matching documents."},"update_data":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Update Data","description":"OPTIONAL. Update data to apply when using filters mode. Must be used with 'filters' field. All matched documents receive the same updates. Can update any document field except vectors. A dotted key sets one nested field and keeps its siblings: {'metadata.status': 'processed'} changes only metadata.status. A key without a dot replaces that whole top-level field, so {'metadata': {'status': 'processed'}} replaces the entire metadata object and drops its other keys."}},"type":"object","title":"BatchUpdateDocumentsRequest","description":"Request model for batch updating multiple documents by explicit IDs or filters.\n\nSupports TWO modes:\n1. Explicit IDs mode: Provide 'updates' array with document_id + update_data for each\n2. Filter mode: Provide 'filters' + 'update_data' to update all matching documents\n\nKey difference from BulkUpdateDocumentsRequest:\n- Batch (this): Can apply DIFFERENT updates to SPECIFIC documents by ID\n- Bulk: Applies SAME update to ALL documents matching filters\n\nUse Cases:\n    - Update 5 specific documents with different metadata values\n    - Update documents by IDs with per-document update control\n    - Combine with filters for targeted batch updates\n\nRequirements:\n    - EITHER 'updates' (explicit mode) OR 'filters' + 'update_data' (filter mode)\n    - NOT BOTH modes simultaneously","examples":[{"description":"Explicit IDs mode: Update 3 documents with different values","updates":[{"document_id":"doc_frame_001","update_data":{"metadata.quality_score":0.95,"metadata.reviewed":true}},{"document_id":"doc_frame_002","update_data":{"metadata.flagged":true,"metadata.quality_score":0.87}},{"document_id":"doc_frame_003","update_data":{"metadata.discarded":true,"metadata.quality_score":0.72}}]},{"description":"Filter mode: Update all pending documents","filters":{"AND":[{"field":"metadata.status","operator":"eq","value":"pending"}]},"update_data":{"metadata.status":"processed"}}]},"BatchUpdateDocumentsResponse":{"properties":{"updated_count":{"type":"integer","title":"Updated Count","description":"Total number of documents successfully updated"},"failed_count":{"type":"integer","title":"Failed Count","description":"Total number of documents that failed to update","default":0},"results":{"items":{"$ref":"#/components/schemas/BatchDocumentUpdateResult"},"type":"array","title":"Results","description":"Detailed per-document results. Each entry shows document_id, success status, and error message (if failed). Empty list when using filter mode (only counts returned)."},"message":{"type":"string","title":"Message","description":"Summary message of the operation","default":"Batch update completed"}},"type":"object","required":["updated_count"],"title":"BatchUpdateDocumentsResponse","description":"Response model for batch document update operation.\n\nProvides detailed per-document results showing success/failure for each update.","examples":[{"failed_count":0,"message":"Successfully updated 3 document(s)","results":[{"document_id":"doc_123","success":true},{"document_id":"doc_456","success":true},{"document_id":"doc_789","success":true}],"updated_count":3}]},"BatchUploadRequest":{"properties":{"uploads":{"items":{"$ref":"#/components/schemas/CreateUploadRequest"},"type":"array","maxItems":100,"minItems":1,"title":"Uploads","description":"List of upload requests (max 100)"},"shared_metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Shared Metadata","description":"Metadata to apply to all uploads (merged with individual metadata)"},"shared_object_metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Shared Object Metadata","description":"Object metadata to apply to all uploads (merged with individual)"}},"type":"object","required":["uploads"],"title":"BatchUploadRequest","description":"Request to generate multiple presigned URLs in a single request.","examples":[{"shared_metadata":{"campaign":"summer_2024"},"shared_object_metadata":{"category":"marketing"},"uploads":[{"blob_property":"video","content_type":"video/mp4","filename":"video1.mp4"},{"blob_property":"thumbnail","content_type":"image/jpeg","filename":"thumbnail1.jpg"}]}]},"BatchUploadResponse":{"properties":{"uploads":{"items":{"$ref":"#/components/schemas/UploadResponse"},"type":"array","title":"Uploads","description":"Generated uploads with presigned URLs"},"total":{"type":"integer","title":"Total","description":"Total number of uploads created"}},"type":"object","required":["uploads","total"],"title":"BatchUploadResponse","description":"Response from batch upload request.","examples":[{"total":2,"uploads":[{"filename":"video1.mp4","presigned_url":"https://s3.amazonaws.com/...","status":"PENDING","upload_id":"upl_abc123"}]}]},"BatchingConfig":{"properties":{"mode":{"type":"string","enum":["time_window","count","immediate"],"title":"Mode","default":"time_window"},"window_seconds":{"type":"integer","maximum":300.0,"minimum":5.0,"title":"Window Seconds","default":30},"max_batch_size":{"type":"integer","maximum":1000.0,"minimum":1.0,"title":"Max Batch Size","default":100},"auto_submit":{"type":"boolean","title":"Auto Submit","default":true}},"type":"object","title":"BatchingConfig"},"BenchmarkComparison":{"properties":{"baseline_retriever_id":{"type":"string","title":"Baseline Retriever Id","description":"ID of the baseline pipeline."},"comparisons":{"items":{"$ref":"#/components/schemas/PipelineComparison"},"type":"array","title":"Comparisons","description":"Comparison results for each candidate."},"recommendation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recommendation","description":"System-generated recommendation based on results."}},"type":"object","required":["baseline_retriever_id","comparisons"],"title":"BenchmarkComparison","description":"Comparison of all candidates against the baseline."},"BenchmarkListResponse":{"properties":{"benchmarks":{"items":{"$ref":"#/components/schemas/BenchmarkResponse"},"type":"array","title":"Benchmarks","description":"List of benchmarks."},"total":{"type":"integer","title":"Total","description":"Total count matching filter."},"page":{"type":"integer","title":"Page","description":"Current page.","default":1},"page_size":{"type":"integer","title":"Page Size","description":"Items per page.","default":20}},"type":"object","required":["benchmarks","total"],"title":"BenchmarkListResponse","description":"Response for listing benchmarks."},"BenchmarkResponse":{"properties":{"benchmark_id":{"type":"string","title":"Benchmark Id","description":"Unique benchmark identifier."},"benchmark_name":{"type":"string","title":"Benchmark Name","description":"Human-readable name."},"baseline_retriever_id":{"type":"string","title":"Baseline Retriever Id","description":"Baseline retriever ID."},"candidate_retriever_ids":{"items":{"type":"string"},"type":"array","title":"Candidate Retriever Ids","description":"Candidate retriever IDs."},"session_filter":{"anyOf":[{"$ref":"#/components/schemas/SessionFilter-Output"},{"type":"null"}],"description":"Filter criteria used."},"session_count":{"type":"integer","title":"Session Count","description":"Number of sessions in benchmark."},"status":{"$ref":"#/components/schemas/BenchmarkStatus","description":"Current benchmark status."},"results":{"anyOf":[{"items":{"$ref":"#/components/schemas/BenchmarkResult"},"type":"array"},{"type":"null"}],"title":"Results","description":"Results per pipeline (available when completed)."},"comparison":{"anyOf":[{"$ref":"#/components/schemas/BenchmarkComparison"},{"type":"null"}],"description":"Statistical comparison (available when completed)."},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp."},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At","description":"Execution start time."},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"Completion time."},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Error message if failed."}},"type":"object","required":["benchmark_id","benchmark_name","baseline_retriever_id","candidate_retriever_ids","session_count","status","created_at"],"title":"BenchmarkResponse","description":"Response containing benchmark details and results."},"BenchmarkResult":{"properties":{"retriever_id":{"type":"string","title":"Retriever Id","description":"ID of the retriever/pipeline tested."},"retriever_name":{"type":"string","title":"Retriever Name","description":"Human-readable name of the retriever."},"pipeline_hash":{"type":"string","title":"Pipeline Hash","description":"Hash of the pipeline configuration."},"metrics":{"$ref":"#/components/schemas/AlignmentMetrics","description":"Alignment metrics for this pipeline."},"taxonomy_deltas":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/AlignmentMetrics"},"type":"object"},{"type":"null"}],"title":"Taxonomy Deltas","description":"Metrics broken down by taxonomy node (for understanding category-level performance)."},"latency":{"$ref":"#/components/schemas/LatencyMetrics","description":"Performance timing statistics."},"failed_sessions":{"type":"integer","minimum":0.0,"title":"Failed Sessions","description":"Number of sessions that failed during replay."},"error_summary":{"additionalProperties":{"type":"integer"},"type":"object","title":"Error Summary","description":"Count of errors by type (error_type -> count)."}},"type":"object","required":["retriever_id","retriever_name","pipeline_hash","metrics","latency","failed_sessions"],"title":"BenchmarkResult","description":"Results for a single pipeline in a benchmark run."},"BenchmarkStatus":{"type":"string","enum":["pending","building_sessions","replaying","computing_metrics","completed","failed"],"title":"BenchmarkStatus","description":"Status of a benchmark run."},"BillingPeriodSummary":{"properties":{"billing_month":{"type":"string","title":"Billing Month"},"platform_fee_usd":{"type":"number","title":"Platform Fee Usd","default":0.0},"compute_base_cost_usd":{"type":"number","title":"Compute Base Cost Usd","default":0.0},"usage_cost_usd":{"type":"number","title":"Usage Cost Usd","default":0.0},"total_base_cost_usd":{"type":"number","title":"Total Base Cost Usd","default":0.0},"note":{"type":"string","title":"Note","default":"Base cost before margin"}},"type":"object","required":["billing_month"],"title":"BillingPeriodSummary"},"BillingPortalRequest":{"properties":{"return_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Return Url","description":"URL Stripe redirects back to when the customer leaves the portal","default":"https://studio.mixpeek.com/billing"}},"type":"object","title":"BillingPortalRequest","description":"Request to open the Stripe customer billing portal."},"BillingPortalResponse":{"properties":{"portal_url":{"type":"string","title":"Portal Url","description":"Stripe-hosted billing portal URL (redirect the user here)","examples":["https://billing.stripe.com/p/session/live_abc123"]},"session_id":{"type":"string","title":"Session Id","description":"Stripe billing portal session ID","examples":["bps_live_abc123"]}},"type":"object","required":["portal_url","session_id"],"title":"BillingPortalResponse","description":"Response with the Stripe-hosted billing portal URL.\n\nThe portal lets an existing customer update their card, view invoices, and\nchange or cancel their subscription — distinct from /subscribe, which starts\na NEW checkout (re-running checkout for an existing subscriber is wrong)."},"BlobDetails":{"properties":{"filename":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filename"},"size_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Size Bytes"},"mime_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mime Type"},"hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hash"}},"type":"object","title":"BlobDetails","description":"File details for a bucket object, these are automatically generated by the system."},"BlobMappingEntry":{"properties":{"target_type":{"type":"string","const":"blob","title":"Target Type","description":"Target type. Must be 'blob' for blob mappings.","default":"blob"},"source":{"oneOf":[{"$ref":"#/components/schemas/S3TagSource"},{"$ref":"#/components/schemas/S3MetadataSource"},{"$ref":"#/components/schemas/FilenameRegexSource"},{"$ref":"#/components/schemas/ColumnSource"},{"$ref":"#/components/schemas/DrivePropertySource"},{"$ref":"#/components/schemas/FolderPathSource"},{"$ref":"#/components/schemas/FileSource"},{"$ref":"#/components/schemas/ConstantSource"},{"$ref":"#/components/schemas/RSSFieldSource"},{"$ref":"#/components/schemas/RTSPFieldSource"}],"title":"Source","description":"Source extractor defining where to get the blob content or URL. Use 'file' for the synced file itself (most common). Use 'column' for database URL columns pointing to external content. Use 'metadata' for S3 metadata containing URLs.","discriminator":{"propertyName":"type","mapping":{"column":"#/components/schemas/ColumnSource","constant":"#/components/schemas/ConstantSource","drive_property":"#/components/schemas/DrivePropertySource","file":"#/components/schemas/FileSource","filename_regex":"#/components/schemas/FilenameRegexSource","folder_path":"#/components/schemas/FolderPathSource","metadata":"#/components/schemas/S3MetadataSource","rss_field":"#/components/schemas/RSSFieldSource","rtsp_field":"#/components/schemas/RTSPFieldSource","tag":"#/components/schemas/S3TagSource"}}},"blob_type":{"$ref":"#/components/schemas/BlobType","description":"Type of blob content. Determines which extractors can process it. 'auto' (default) infers type from mime_type - recommended for files. Explicit types: 'image', 'video', 'audio', 'text', 'document', 'json', 'binary'. Use explicit types when mime_type detection is unreliable.","default":"auto"},"blob_property":{"type":"string","minLength":1,"title":"Blob Property","description":"The blob property name in the bucket schema. This identifies which blob in the object's blobs array. Default: the key this entry is mapped under in schema_mapping (for example 'video' in {\"video\": {...}}); 'content' when the entry is used on its own. Must match a blob property defined in the bucket schema.","default":"content","examples":["content","thumbnail","profile_image","document","audio"]},"mime_type_override":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mime Type Override","description":"Optional mime_type to use instead of auto-detection. Useful when the source doesn't provide accurate mime_type. Format: 'type/subtype' (e.g., 'image/jpeg', 'video/mp4'). When set, this value is used for blob.details.mime_type.","examples":["image/jpeg","video/mp4","application/pdf","audio/mpeg"]}},"type":"object","required":["source"],"title":"BlobMappingEntry","description":"Maps a source to a blob in the bucket object.\n\nUsed for mapping files or URL references to blob fields. The blob_type\ndetermines how the content is processed by extractors. This is the\nprimary way to map synced files into the Mixpeek extraction pipeline.\n\nExample: Map the synced file to the primary \"content\" blob\n    {\n        \"target_type\": \"blob\",\n        \"source\": {\"type\": \"file\"},\n        \"blob_type\": \"auto\",\n        \"blob_property\": \"content\"\n    }\n\nExample: Map a database column URL to an image blob\n    {\n        \"target_type\": \"blob\",\n        \"source\": {\"type\": \"column\", \"name\": \"AVATAR_URL\"},\n        \"blob_type\": \"image\",\n        \"blob_property\": \"profile_image\"\n    }\n\nExample: Map with explicit mime_type override\n    {\n        \"target_type\": \"blob\",\n        \"source\": {\"type\": \"file\"},\n        \"blob_type\": \"video\",\n        \"blob_property\": \"content\",\n        \"mime_type_override\": \"video/mp4\"\n    }\n\nAttributes:\n    target_type: Must be \"blob\" for blob mappings\n    source: The source extractor (usually \"file\" for synced content)\n    blob_type: Content type hint for extractors (auto, image, video, etc.)\n    blob_property: Name of the blob property in the bucket schema\n    mime_type_override: Optional explicit mime_type to use"},"BlobModel":{"properties":{"blob_id":{"type":"string","title":"Blob Id","description":"Unique identifier for the blob","examples":["blob_a1b2c3d4e5f6"]},"property":{"type":"string","title":"Property","description":"Property name of the blob","examples":["video","thumbnail","content"]},"key_prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Key Prefix","description":"Storage key/path of the blob, this will be used to retrieve the blob from the storage. It is similar to a file path. If not provided, it will be placed in the root of the bucket.","examples":["/videos/video.mp4","/thumbnails/thumb.jpg"]},"type":{"$ref":"#/components/schemas/BucketSchemaFieldType","description":"The schema field type this blob corresponds to (e.g., IMAGE, PDF, DOCUMENT)","examples":["video","image","pdf","text"]},"properties":{"additionalProperties":true,"type":"object","title":"Properties","description":"All blob data and metadata unified (formerly separate 'data' and 'metadata' fields). Contains URLs, dimensions, metadata, and any other blob-specific information.","examples":[{"author":"John Doe","duration":120,"resolution":"1920x1080","tags":["product","demo"],"url":"s3://bucket/video.mp4"}]},"presigned_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Presigned Url","description":"Canonical top-level presigned URL for this blob. Matches the shape used by `document_blobs[].presigned_url` on document responses. Populated by the API when `?return_presigned_urls=true`. Also mirrored at `properties.presigned_url` for backward compatibility — prefer this top-level field; the nested path will be removed in a future release."},"details":{"$ref":"#/components/schemas/BlobDetails","description":"System-generated file details (filename, size, hash, etc.)"}},"type":"object","required":["property","type"],"title":"BlobModel","description":"Model for a blob within a bucket object.\n\nBlobs store file references with a flat properties structure.\nAll blob-specific data (formerly in separate 'data' and 'metadata' fields)\nis now unified in a single 'properties' dictionary.\n\nExample:\n    {\n        \"blob_id\": \"blob_xyz123\",\n        \"property\": \"video\",\n        \"type\": \"video\",\n        \"properties\": {\n            \"url\": \"s3://bucket/video.mp4\",\n            \"duration\": 120,\n            \"resolution\": \"1920x1080\",\n            \"author\": \"John Doe\"  # All data unified here\n        }\n    }"},"BlobSource":{"properties":{"file_field":{"type":"string","title":"File Field","description":"Dot-path into the payload or metadata to extract the downloadable URL"},"blob_type":{"type":"string","title":"Blob Type","description":"Blob type for the bucket schema (video, image, audio, etc.)","default":"video"},"target_property":{"type":"string","title":"Target Property","description":"Bucket schema field name to store the blob under"}},"type":"object","required":["file_field","target_property"],"title":"BlobSource"},"BlobType":{"type":"string","enum":["auto","image","video","audio","text","pdf","excel"],"title":"BlobType","description":"Type of blob content for schema mapping.\n\nDetermines how the blob content is processed and what extractors can operate on it.\nThis is critical for the extraction pipeline to route content correctly.\n\nValues:\n    auto: Automatically infer blob type from mime_type (recommended for files)\n    image: Image files (JPEG, PNG, WebP, BMP, TIFF, or GIF as static)\n    video: Video files (MP4, MOV, WebM, AVI, MKV, or GIF as animated frames)\n    audio: Audio files (MP3, WAV, FLAC, AAC, OGG)\n    text: Text files (TXT, MD, HTML, XML)\n    pdf: PDF documents\n    excel: Spreadsheet files (XLSX, XLS, CSV)\n\n**GIF Special Handling**:\n    GIF files are unique - they can be processed as either IMAGE or VIDEO:\n\n    - As IMAGE: Single static embedding (first frame), no decomposition\n    - As VIDEO: Frame-by-frame decomposition with per-frame embeddings\n\n    When using \"auto\", GIFs default to IMAGE. To get frame-level processing\n    for animated GIFs, explicitly set blob_type to VIDEO.\n\nUsage Guidelines:\n    - Use \"auto\" when syncing files with accurate mime_type headers\n    - Use explicit types when mime_type is missing or unreliable\n    - Use \"video\" for animated GIFs requiring frame-level search"},"BlobURLRef":{"properties":{"field":{"type":"string","minLength":1,"title":"Field","description":"REQUIRED. Stable semantic label for this blob. Use descriptive names like 'video_segment', 'thumbnail', 'source_video', etc. Avoid internal implementation details like array indices. This field is used for programmatic access and should be consistent across documents.","examples":["video_segment","thumbnail","source_video","processed_frame"]},"role":{"type":"string","enum":["source","processed","thumbnail","artifact","aux"],"title":"Role","description":"REQUIRED. Semantic role determining how this blob should be treated. 'source': Original input media from buckets or uploads. 'processed': Derived content created by feature extractors (segments, frames). 'thumbnail': Preview images for UI display. 'artifact': Generated outputs (reports, analysis results). 'aux': Supporting or auxiliary files. Used by UI for grouping and displaying blobs appropriately.","default":"source"},"type":{"type":"string","enum":["video","image","audio","text","pdf","other"],"title":"Type","description":"REQUIRED. Media type of the blob content. Determines how the blob should be rendered or processed. Use 'other' for custom or unknown types.","default":"other"},"url":{"type":"string","minLength":1,"title":"Url","description":"REQUIRED. Permanent URL to the blob content. S3 URLs (s3://bucket/key) are automatically converted to presigned HTTPS URLs by the API. HTTP/HTTPS URLs are returned as-is. This is the canonical reference to the blob that persists across API calls.","examples":["s3://mixpeek-storage/namespace_123/objects/obj_456/segment_0.mp4","https://example.com/media/video.mp4"]},"filename":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filename","description":"OPTIONAL. Original filename or leaf name of the blob. Useful for downloads and display purposes. Example: 'segment_0.mp4', 'thumbnail.jpg'","examples":["segment_0.mp4","thumbnail.jpg","analysis_report.pdf"]},"size_bytes":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Size Bytes","description":"OPTIONAL. Size of the blob in bytes. Useful for progress indicators and storage tracking.","examples":[1048576,524288]},"content_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Content Type","description":"OPTIONAL. MIME type of the blob content. Used for proper content-type headers when serving files. Example: 'video/mp4', 'image/jpeg', 'application/pdf'","examples":["video/mp4","image/jpeg","image/png","application/pdf"]},"checksum":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Checksum","description":"OPTIONAL. Checksum or hash of the blob content for integrity verification. Format: 'algorithm:hash' (e.g., 'sha256:abc123...')","examples":["sha256:a1b2c3d4e5f6...","md5:9e107d9d372bb6826bd81d3542a419d6"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"OPTIONAL. Timestamp when the blob was created or uploaded. ISO 8601 format. Useful for tracking blob lifecycle and cleanup."},"source_blob_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Blob Id","description":"OPTIONAL. Cross-reference to the source blob ID from the bucket object. Used for lineage tracking: connects processed blobs back to their original sources. Example: A video segment references the original video blob that it was extracted from.","examples":["blob_abc123","blob_xyz789"]},"presigned_url":{"anyOf":[{"type":"string","minLength":1,"format":"uri"},{"type":"null"}],"title":"Presigned Url","description":"RESPONSE ONLY. Time-limited HTTPS URL for direct access to the blob. Automatically generated by the API when documents are retrieved. NOT REQUIRED when creating blobs - leave empty, API will populate. Typically expires after 1 hour. Use for immediate media playback or download."},"unavailable_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unavailable Reason","description":"Why this blob has no presigned URL on this read, when it has none: for a thumbnail removed by storage tiering, the reason it could not be regenerated (for example its source media is gone, or regeneration is busy and a retry will serve it). Absent when the URL is served."}},"type":"object","required":["field","url"],"title":"BlobURLRef","description":"Reference to a document-related blob with automatic presigned URL generation.\n\nRepresents any file or asset associated with a document, including source media,\nprocessed outputs, thumbnails, and artifacts. All blobs with S3 URLs automatically\nreceive presigned URLs when documents are retrieved from the API.\n\nUse Cases:\n    - Track source media: Original videos, images, or files from buckets\n    - Reference processed outputs: Video segments, extracted frames, thumbnails\n    - Link artifacts: Generated reports, analysis results, derived media\n    - Maintain lineage: Connect processed blobs back to their source blobs\n\nRole Definitions:\n    - source: Original input media (e.g., uploaded video, bucket object)\n    - processed: Derived/transformed content (e.g., video segments, extracted frames)\n    - thumbnail: Preview images for visual content\n    - artifact: Generated files (reports, analysis outputs)\n    - aux: Supporting/auxiliary files\n\nPresigned URL Flow:\n    1. During processing: Store S3 URLs in document_blobs (no presigned URL yet)\n    2. During retrieval: API automatically adds presigned_url field to each blob\n    3. Client receives: Both permanent S3 URL and time-limited HTTPS presigned URL\n\nRequirements:\n    - field: REQUIRED. Semantic label for the blob (e.g., 'video_segment', 'thumbnail')\n    - url: REQUIRED. S3 or HTTP URL to the blob content\n    - role: REQUIRED. Semantic role for UX grouping and behavior\n    - All other fields: OPTIONAL but recommended for better tracking","examples":[{"content_type":"video/mp4","description":"Original source video from bucket","field":"source_video","role":"source","size_bytes":10485760,"source_blob_id":"blob_original123","type":"video","url":"s3://mixpeek-storage/ns_123/obj_456/original.mp4"},{"content_type":"video/mp4","description":"Processed video segment","field":"video_segment","filename":"segment_0.mp4","object_key":"ns_123/obj_456/segments/segment_0.mp4","role":"processed","size_bytes":524288,"source_blob_id":"blob_original123","type":"video","url":"s3://mixpeek-storage/ns_123/obj_456/segments/segment_0.mp4"},{"content_type":"image/jpeg","description":"Thumbnail image","field":"thumbnail","filename":"thumb_0.jpg","role":"thumbnail","size_bytes":51200,"type":"image","url":"s3://mixpeek-storage/ns_123/obj_456/thumbs/thumb_0.jpg"}]},"Body_advance_funnel_stage_v1_notifications_funnel_advance_post":{"properties":{"stage":{"type":"string","title":"Stage"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source"}},"type":"object","required":["stage"],"title":"Body_advance_funnel_stage_v1_notifications_funnel_advance_post"},"Body_apply_manifest_v1_manifest_apply_post":{"properties":{"manifest_file":{"type":"string","contentMediaType":"application/octet-stream","title":"Manifest File","description":"YAML manifest file"},"parameters":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parameters","description":"JSON object of values for the manifest's declared parameters, e.g. {\"camera_url\": \"rtsp://host/stream\", \"polling_seconds\": 300}. Each value must match its declared type. Omit when the manifest declares none."}},"type":"object","required":["manifest_file"],"title":"Body_apply_manifest_v1_manifest_apply_post"},"Body_create_subscription_v1_marketplace_subscriptions_post":{"properties":{"listing_id":{"type":"string","title":"Listing Id","description":"Marketplace listing ID"},"tier":{"$ref":"#/components/schemas/SubscriptionTier","description":"Subscription tier (free, basic, pro, enterprise)"}},"type":"object","required":["listing_id","tier"],"title":"Body_create_subscription_v1_marketplace_subscriptions_post"},"Body_diff_manifest_v1_manifest_diff_post":{"properties":{"manifest_file":{"type":"string","contentMediaType":"application/octet-stream","title":"Manifest File","description":"YAML manifest file"},"parameters":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parameters","description":"JSON object of values for the manifest's declared parameters, e.g. {\"camera_url\": \"rtsp://host/stream\", \"polling_seconds\": 300}. Each value must match its declared type. Omit when the manifest declares none."}},"type":"object","required":["manifest_file"],"title":"Body_diff_manifest_v1_manifest_diff_post"},"Body_generate_invoice_now_v1_organizations_billing_generate_invoice_post":{"properties":{"billing_month":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Billing Month","description":"Billing month (YYYY-MM). Defaults to previous month."},"dry_run":{"type":"boolean","title":"Dry Run","description":"If true, show what would be invoiced without creating Stripe invoice.","default":false}},"type":"object","title":"Body_generate_invoice_now_v1_organizations_billing_generate_invoice_post"},"Body_heal_tier_v1_buckets__bucket_identifier__batches__batch_id__tiers__tier_num__heal_post":{"properties":{"action":{"type":"string","title":"Action","description":"Self-healing action: 'kill_duplicates', 'detect_stuck', 'sync_status'."}},"type":"object","required":["action"],"title":"Body_heal_tier_v1_buckets__bucket_identifier__batches__batch_id__tiers__tier_num__heal_post"},"Body_lint_manifest_v1_manifest_lint_post":{"properties":{"manifest_file":{"type":"string","contentMediaType":"application/octet-stream","title":"Manifest File","description":"YAML manifest file"},"parameters":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parameters","description":"JSON object of values for the manifest's declared parameters, e.g. {\"camera_url\": \"rtsp://host/stream\", \"polling_seconds\": 300}. Each value must match its declared type. Omit when the manifest declares none."}},"type":"object","required":["manifest_file"],"title":"Body_lint_manifest_v1_manifest_lint_post"},"Body_upload_model_v1_namespaces__namespace_id__models_post":{"properties":{"file":{"type":"string","contentMediaType":"application/octet-stream","title":"File","description":"Model archive (.tar.gz)"},"name":{"type":"string","title":"Name","description":"Model name"},"version":{"type":"string","title":"Version","description":"Model version"},"model_format":{"type":"string","enum":["safetensors","onnx","pytorch","huggingface"],"title":"Model Format","description":"Model format"},"framework":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Framework","description":"ML framework (e.g., sentence-transformers)"},"task_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Type","description":"Task type (e.g., embedding, classification)"},"num_cpus":{"type":"number","title":"Num Cpus","description":"CPU requirements","default":1.0},"num_gpus":{"type":"integer","title":"Num Gpus","description":"GPU requirements","default":0},"memory_gb":{"type":"number","title":"Memory Gb","description":"Memory in GB","default":4.0}},"type":"object","required":["file","name","version","model_format"],"title":"Body_upload_model_v1_namespaces__namespace_id__models_post"},"Body_validate_manifest_v1_manifest_validate_post":{"properties":{"manifest_file":{"type":"string","contentMediaType":"application/octet-stream","title":"Manifest File","description":"YAML manifest file"},"parameters":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parameters","description":"JSON object of values for the manifest's declared parameters, e.g. {\"camera_url\": \"rtsp://host/stream\", \"polling_seconds\": 300}. Each value must match its declared type. Omit when the manifest declares none."}},"type":"object","required":["manifest_file"],"title":"Body_validate_manifest_v1_manifest_validate_post"},"Body_verify_marketplace_listing_password_v1_marketplace_catalog__public_name__verify_post":{"properties":{"password":{"type":"string","title":"Password","description":"Password to verify"}},"type":"object","required":["password"],"title":"Body_verify_marketplace_listing_password_v1_marketplace_catalog__public_name__verify_post"},"BoolIndexParams":{"properties":{"type":{"type":"string","title":"Type","default":"bool"}},"type":"object","title":"BoolIndexParams","description":"Configuration for boolean index."},"BottleneckAnalysis":{"properties":{"stage_name":{"type":"string","title":"Stage Name","description":"Stage name"},"component":{"type":"string","title":"Component","description":"Component"},"execution_count":{"type":"integer","title":"Execution Count","description":"Number of executions"},"total_time_ms":{"type":"number","title":"Total Time Ms","description":"Total time spent"},"avg_time_ms":{"type":"number","title":"Avg Time Ms","description":"Average time per execution"},"pct_of_total":{"type":"number","title":"Pct Of Total","description":"Percentage of total execution time"},"rank":{"type":"integer","title":"Rank","description":"Bottleneck ranking (1 = worst)"}},"type":"object","required":["stage_name","component","execution_count","total_time_ms","avg_time_ms","pct_of_total","rank"],"title":"BottleneckAnalysis","description":"Bottleneck analysis result."},"BottleneckResponse":{"properties":{"time_range":{"$ref":"#/components/schemas/api__analytics__models__TimeRange","description":"Time range of the analysis"},"bottlenecks":{"items":{"$ref":"#/components/schemas/BottleneckAnalysis"},"type":"array","title":"Bottlenecks","description":"Ranked list of bottlenecks"},"total_time_ms":{"type":"number","title":"Total Time Ms","description":"Total execution time across all components"}},"type":"object","required":["time_range","bottlenecks","total_time_ms"],"title":"BottleneckResponse","description":"Response for bottleneck analysis."},"BoxCCGCredentials":{"properties":{"type":{"type":"string","const":"ccg","title":"Type","default":"ccg"},"client_id":{"type":"string","title":"Client Id","description":"REQUIRED. Box application client ID from Developer Console.","examples":["abc123def456ghi789"]},"client_secret":{"type":"string","title":"Client Secret","description":"REQUIRED. Box application client secret. SECURITY: Secret credential, redacted on read. Never log or expose."},"enterprise_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Enterprise Id","description":"Enterprise ID to authenticate as. Required when using CCG to act as the enterprise (service account). Find in: Box Admin Console > Enterprise Settings.","examples":["12345678"]},"user_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id","description":"User ID to authenticate as. Used when the app needs to act as a specific managed user. Mutually exclusive with enterprise_id for token acquisition.","examples":["87654321"]}},"type":"object","required":["client_id","client_secret"],"title":"BoxCCGCredentials","description":"Credentials for Box Client Credentials Grant (CCG) authentication.\n\nCCG provides server-to-server authentication without user interaction.\nRecommended for enterprise and automated sync operations.\n\nPrerequisites:\n    - Create a Box application with Server Authentication (Client Credentials Grant)\n    - Authorize the application in the Box Admin Console\n    - Optionally configure an enterprise or user ID to act as\n\nSecurity:\n    - client_secret is a secret credential, redacted on read\n    - No user tokens involved; app authenticates as itself or as a user/enterprise"},"BoxConfig":{"properties":{"provider_type":{"type":"string","const":"box","title":"Provider Type","default":"box"},"credentials":{"oneOf":[{"$ref":"#/components/schemas/BoxOAuthCredentials"},{"$ref":"#/components/schemas/BoxCCGCredentials"},{"$ref":"#/components/schemas/BoxJWTCredentials"}],"title":"Credentials","description":"REQUIRED. Box authentication credentials. Choose 'oauth' for user-level access, 'ccg' for server-to-server (recommended), or 'jwt' for high-security enterprise. The 'type' field determines which authentication flow is used.","discriminator":{"propertyName":"type","mapping":{"ccg":"#/components/schemas/BoxCCGCredentials","jwt":"#/components/schemas/BoxJWTCredentials","oauth":"#/components/schemas/BoxOAuthCredentials"}}},"folder_id":{"type":"string","title":"Folder Id","description":"Box folder ID to sync from. Default '0' is the root folder. Find folder ID: Open folder in Box web UI, copy the numeric ID from the URL. Example URL: https://app.box.com/folder/123456789 → folder_id='123456789'","default":"0","examples":["0","123456789","987654321"]}},"type":"object","required":["credentials"],"title":"BoxConfig","description":"Box cloud content management and file sharing configuration.\n\nEnables Mixpeek to connect to Box for automated file ingestion and\nsynchronization. Supports enterprise-grade content management features\nincluding folder sync, metadata, versioning, and retention policies.\n\nAuthentication Methods:\n    1. OAuth 2.0 (for user-level access):\n        - Standard OAuth flow with access/refresh tokens\n        - Access scoped to the authorizing user's content\n\n    2. Client Credentials Grant (CCG) (RECOMMENDED for production):\n        - Server-to-server without user interaction\n        - Acts as service account or specific user\n        - Requires admin authorization in Box Admin Console\n\n    3. JWT (for high-security enterprise):\n        - RSA key pair for signing JWT assertions\n        - No user interaction required\n        - Highest security option\n\nRequirements:\n    - Box Developer account with an application\n    - Application authorized in Box Admin Console (for CCG/JWT)\n    - Network connectivity to api.box.com\n\nUse Cases:\n    - Sync enterprise document libraries\n    - Ingest compliance and legal documents\n    - Monitor collaboration folders for new content\n    - Archive and search enterprise content","examples":[{"credentials":{"client_id":"abc123def456","client_secret":"your-client-secret","enterprise_id":"12345678","type":"ccg"},"description":"Box with Client Credentials Grant (recommended)","folder_id":"0","provider_type":"box"},{"credentials":{"access_token":"your-access-token","client_id":"abc123def456","client_secret":"your-client-secret","refresh_token":"your-refresh-token","type":"oauth"},"description":"Box with OAuth 2.0 user authentication","folder_id":"987654321","provider_type":"box"},{"credentials":{"client_id":"abc123def456","client_secret":"your-client-secret","enterprise_id":"12345678","jwt_key_id":"abcdef12","private_key":"-----BEGIN ENCRYPTED PRIVATE KEY-----\n...\n-----END ENCRYPTED PRIVATE KEY-----\n","private_key_passphrase":"passphrase","type":"jwt"},"description":"Box with JWT authentication","folder_id":"0","provider_type":"box"}]},"BoxJWTCredentials":{"properties":{"type":{"type":"string","const":"jwt","title":"Type","default":"jwt"},"client_id":{"type":"string","title":"Client Id","description":"REQUIRED. Box application client ID.","examples":["abc123def456ghi789"]},"client_secret":{"type":"string","title":"Client Secret","description":"REQUIRED. Box application client secret. SECURITY: Secret credential, redacted on read. Never log or expose."},"enterprise_id":{"type":"string","title":"Enterprise Id","description":"REQUIRED. Box enterprise ID for JWT authentication. Find in: Box Admin Console > Enterprise Settings.","examples":["12345678"]},"jwt_key_id":{"type":"string","title":"Jwt Key Id","description":"REQUIRED. Public key ID registered with Box. Found in the JSON config file as 'publicKeyID'.","examples":["abcdef12"]},"private_key":{"type":"string","title":"Private Key","description":"REQUIRED. PEM-encoded RSA private key for JWT signing. SECURITY: Secret credential, redacted on read. Never log or expose. Found in the JSON config file as 'privateKey'."},"private_key_passphrase":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Private Key Passphrase","description":"Passphrase for the private key if it is encrypted. SECURITY: Secret credential, redacted on read. Never log or expose."}},"type":"object","required":["client_id","client_secret","enterprise_id","jwt_key_id","private_key"],"title":"BoxJWTCredentials","description":"Credentials for Box JWT (JSON Web Token) authentication.\n\nJWT provides server-to-server authentication using a public/private key pair.\nRecommended for enterprise integrations requiring high security.\n\nPrerequisites:\n    - Create a Box application with Server Authentication (with JWT)\n    - Generate a public/private key pair in the Developer Console\n    - Authorize the application in the Box Admin Console\n    - Download the JSON configuration file\n\nSecurity:\n    - private_key is a secret credential, redacted on read\n    - RSA key pair used for signing JWT assertions\n    - No user interaction required"},"BoxOAuthCredentials":{"properties":{"type":{"type":"string","const":"oauth","title":"Type","default":"oauth"},"client_id":{"type":"string","title":"Client Id","description":"REQUIRED. Box application client ID. Found in: Box Developer Console > Your App > Configuration > OAuth 2.0 Credentials.","examples":["abc123def456ghi789"]},"client_secret":{"type":"string","title":"Client Secret","description":"REQUIRED. Box application client secret. SECURITY: Secret credential, redacted on read. Never log or expose. Found in: Box Developer Console > Your App > Configuration."},"access_token":{"type":"string","title":"Access Token","description":"REQUIRED. Box OAuth 2.0 access token. SECURITY: Encrypted at rest. Expires in ~60 minutes."},"refresh_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Refresh Token","description":"Box OAuth 2.0 refresh token for automatic token renewal. Optional: the sync uses access_token directly, and Studio's Box form sends none. SECURITY: Encrypted at rest. Single-use; new one issued on each refresh."}},"type":"object","required":["client_id","client_secret","access_token"],"title":"BoxOAuthCredentials","description":"Credentials for Box OAuth 2.0 authentication.\n\nBox supports OAuth 2.0 with access and refresh tokens. The refresh token\nis used to automatically obtain new access tokens without user interaction.\n\nPrerequisites:\n    - Create a Box application at https://developer.box.com\n    - Configure OAuth 2.0 with the appropriate scopes\n    - Complete the OAuth consent flow to obtain tokens\n\nSecurity:\n    - client_secret, access_token, and refresh_token are secret credentials, redacted on read\n    - Access tokens expire in ~60 minutes; refresh tokens used for renewal\n    - Token refresh happens automatically during sync execution"},"BrightDataConfig":{"properties":{"provider_type":{"type":"string","const":"brightdata","title":"Provider Type","default":"brightdata"},"credentials":{"$ref":"#/components/schemas/BrightDataCredentials","description":"REQUIRED. BrightData API token credentials."},"customer_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Customer Id","description":"NOT REQUIRED. BrightData customer ID (zone-level auth). Required when using zone-specific API access. Find in: BrightData Dashboard > your zone settings.","examples":["hl_abc12345"]},"default_output_format":{"type":"string","enum":["jsonl","json","csv","ndjson"],"title":"Default Output Format","description":"Output format for downloaded dataset results. 'jsonl' (default) streams one JSON object per line. 'json' returns a full JSON array. 'csv' returns comma-separated values. 'ndjson' is equivalent to jsonl.","default":"jsonl"},"country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Country","description":"NOT REQUIRED. ISO 3166-1 alpha-2 country code for geo-targeted data collection. When set, the dataset snapshot targets data from this country. Examples: 'us', 'gb', 'de', 'jp'.","examples":["us","gb","de"]},"inputs":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Inputs","description":"NOT REQUIRED. Default seed inputs for datasets that require input URLs or records (e.g. LinkedIn company profiles). Each item is a JSON object passed to the BrightData trigger API. Overridden per-call when inputs are supplied at sync time.","examples":[[{"url":"https://www.linkedin.com/company/google"}]]}},"type":"object","required":["credentials"],"title":"BrightDataConfig","description":"BrightData web data platform configuration for dataset and scraper syncs.\n\nEnables Mixpeek to collect data from BrightData's pre-built datasets\n(LinkedIn, Amazon, Google Maps, etc.) or custom web scrapers. Each sync\ntriggers a new dataset snapshot, polls until ready, then downloads and\ningests each row as a bucket object.\n\nAuthentication:\n    - API token from BrightData dashboard\n\nRequirements:\n    - Active BrightData subscription with Datasets or Web Scraper access\n    - API token with appropriate dataset permissions\n    - Network connectivity to api.brightdata.com\n\nUse Cases:\n    - Ingest LinkedIn company/people datasets for lead generation\n    - Monitor e-commerce pricing via Amazon product datasets\n    - Collect Google Maps business data for location intelligence\n    - Run custom web scrapers and process results as documents\n    - Aggregate public social media data for trend analysis","examples":[{"credentials":{"api_token":"your-brightdata-api-token","type":"api_token"},"default_output_format":"jsonl","description":"BrightData dataset sync","provider_type":"brightdata"},{"country":"us","credentials":{"api_token":"your-brightdata-api-token","type":"api_token"},"customer_id":"hl_abc12345","default_output_format":"jsonl","description":"BrightData with geo-targeting","provider_type":"brightdata"}]},"BrightDataCredentials":{"properties":{"type":{"type":"string","const":"api_token","title":"Type","default":"api_token"},"api_token":{"type":"string","title":"Api Token","description":"REQUIRED. BrightData API token. SECURITY: Encrypted at rest. Never log or expose. Find in: BrightData Dashboard > Account > API Token.","examples":["xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"]}},"type":"object","required":["api_token"],"title":"BrightDataCredentials","description":"API token credentials for BrightData platform.\n\nSecurity:\n    - api_token is a secret credential, redacted on read\n    - Tokens can be created/rotated in the BrightData dashboard"},"BucketCreateRequest":{"properties":{"bucket_name":{"type":"string","title":"Bucket Name","description":"Human-readable name for the bucket"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Description of the bucket"},"bucket_schema":{"$ref":"#/components/schemas/BucketSchema-Input","description":"REQUIRED. Schema definition for objects in this bucket. Must include a 'properties' object mapping field names to type definitions. Use Mixpeek types (string, text, image, video, etc.) — NOT JSON Schema types like 'keyword'. Example: {\"properties\": {\"title\": {\"type\": \"string\"}, \"photo\": {\"type\": \"image\"}}}"},"unique_key":{"anyOf":[{"$ref":"#/components/schemas/UniqueKeyConfig"},{"type":"null"}],"description":"Unique key configuration for this bucket (OPTIONAL). Enables uniqueness enforcement and upsert operations on specified field(s) from the schema. Cannot be changed after bucket creation."},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Additional metadata for the bucket"},"storage_class":{"anyOf":[{"$ref":"#/components/schemas/StorageClass"},{"type":"null"}],"description":"OPTIONAL object-storage tier for this bucket's objects: standard | nearline | coldline | archive (provider-agnostic). NOTE: applied on write for sync-based ingestion (the primary media path); tiering for direct uploads (POST /objects) and presigned uploads, plus retroactive re-tiering of existing objects, are in progress. Omit for the provider default (standard)."},"destination":{"anyOf":[{"$ref":"#/components/schemas/BucketDestination"},{"type":"null"}],"description":"Write this bucket's extraction outputs to your own storage instead of Mixpeek's: a storage connection with write access and a prefix. None keeps outputs in Mixpeek's storage."},"ingest_filter":{"anyOf":[{"$ref":"#/components/schemas/IngestFilter"},{"type":"null"}],"description":"A pinned saved retriever every candidate object a sync brings in (an RTSP segment, a connector file) runs through before it is committed. A sync's own ingest_filter wins over its bucket's. Kept objects carry the filter's record (execution id included) in their ingest_filter field; dropped ones are never stored and are counted on the sync job by reason. None means no filter."},"source_adapter":{"anyOf":[{"$ref":"#/components/schemas/SourceAdapterConfig"},{"type":"null"}],"description":"OPTIONAL source connection for this bucket, stored exactly as PATCH /buckets/{bucket_id} stores it (the create path used to accept this field and silently drop it). adapter_type 'bucket' pulls objects from source_bucket_ids (fan-in); adapter_type 'collection' pulls documents from source_collection_id; any other adapter_type is an inbound webhook and is assigned a webhook_url. Bucket and collection sources are checked for dependency cycles at create time (409 names the cycle)."}},"type":"object","required":["bucket_name","bucket_schema"],"title":"BucketCreateRequest","description":"Request model for creating a new bucket.\n\nREQUIRED: A bucket_schema must be defined to enable data processing and validation.\n\nThe bucket_schema tells the system what fields your objects will have, enabling:\n- Collections to map your data fields to feature extractors via input_mappings\n- Validation of object structure at upload time\n- Type-safe data pipelines from bucket → collection → retrieval\n\nEvery bucket must have a schema that defines the structure of objects it will contain.","examples":[{"bucket_name":"product_images","bucket_schema":{"properties":{"image":{"description":"Product image blob","type":"image"},"metadata":{"description":"Product information","properties":{"title":{"type":"string"},"category":{"type":"string"},"price":{"type":"float"}},"type":"object"}}},"description":"Product images with metadata for e-commerce","metadata":{"department":"Sales","region":"US"}},{"bucket_name":"video_content","bucket_schema":{"properties":{"video":{"description":"Main video file","type":"video"},"transcript":{"description":"Video transcript text","type":"text"},"thumbnail":{"description":"Video thumbnail","type":"image"},"metadata":{"properties":{"duration_seconds":{"type":"integer"},"title":{"type":"string"},"tags":{"items":{"type":"string"},"type":"array"}},"type":"object"}}},"description":"Video files with transcripts and thumbnails","metadata":{"content_type":"educational"}},{"bucket_name":"text_documents","bucket_schema":{"properties":{"content":{"description":"Main text content","type":"text"},"metadata":{"properties":{"title":{"type":"string"},"author":{"type":"string"},"published_date":{"type":"datetime"}},"type":"object"}}},"description":"Text documents for NLP processing"}]},"BucketDestination":{"properties":{"connection_id":{"type":"string","title":"Connection Id","description":"A storage connection you own, with write access enabled (S3-compatible, including Cloudflare R2 through its endpoint_url, or GCS). Enable writes with PATCH /v1/organizations/connections/{connection_id} and {\"write_enabled\": true}."},"prefix":{"type":"string","title":"Prefix","description":"Key prefix inside the connection's bucket to write under, for example 'mixpeek-outputs/'. Empty writes at the root. A trailing slash is added if you omit it.","default":""}},"type":"object","required":["connection_id"],"title":"BucketDestination","description":"Where a bucket's extraction outputs are written: the customer's own storage.\n\nNames a storage connection with write access enabled, the same shape as a\ncollection export destination. Outputs and derived assets (segments,\nthumbnails, transcodes, renders) are written under the prefix, each carrying\nits lineage as object metadata, and Mixpeek's storage keeps no copy."},"BucketHealthResponse":{"properties":{"bucket_id":{"type":"string","title":"Bucket Id","description":"Bucket identifier"},"time_range":{"$ref":"#/components/schemas/api__analytics__buckets__models__TimeRange","description":"Query time range"},"overall_health":{"type":"string","title":"Overall Health","description":"Overall health status"},"total_errors":{"type":"integer","title":"Total Errors","description":"Total error count"},"error_breakdown":{"items":{"$ref":"#/components/schemas/ErrorBreakdown"},"type":"array","title":"Error Breakdown","description":"Errors by type"},"sync_health":{"items":{"$ref":"#/components/schemas/SyncHealthMetric"},"type":"array","title":"Sync Health","description":"Sync health per config"},"stuck_syncs":{"items":{"type":"string"},"type":"array","title":"Stuck Syncs","description":"Sync configs with no recent activity"}},"type":"object","required":["bucket_id","time_range","overall_health","total_errors","error_breakdown","sync_health","stuck_syncs"],"title":"BucketHealthResponse","description":"Bucket health monitoring response."},"BucketListStats":{"properties":{"total_objects":{"type":"integer","title":"Total Objects","description":"Total number of objects across all buckets","default":0},"total_size_bytes":{"type":"integer","title":"Total Size Bytes","description":"Total size in bytes across all buckets","default":0},"avg_objects_per_bucket":{"type":"number","title":"Avg Objects Per Bucket","description":"Average number of objects per bucket","default":0.0},"avg_size_per_bucket":{"type":"number","title":"Avg Size Per Bucket","description":"Average size in bytes per bucket","default":0.0}},"type":"object","title":"BucketListStats","description":"Aggregate statistics for a list of buckets."},"BucketPatchRequest":{"properties":{"bucket_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bucket Name","description":"Human-readable name for the bucket"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Description of the bucket"},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Additional metadata for the bucket"},"bucket_schema":{"anyOf":[{"$ref":"#/components/schemas/BucketSchema-Input"},{"type":"null"}],"description":"Schema definition for objects in this bucket"},"source_adapter":{"anyOf":[{"$ref":"#/components/schemas/SourceAdapterConfig"},{"type":"null"}],"description":"Source adapter configuration for inbound webhook-driven ingestion"},"unique_key":{"anyOf":[{"$ref":"#/components/schemas/UniqueKeyConfig"},{"type":"null"}],"description":"Change the bucket's unique key default_policy. `fields` must repeat the bucket's existing unique key fields: the key itself is fixed at creation, because every stored object is registered under it. Send `default_policy: null` to clear the default so each upload or object create must pass ?policy=. Rejected with 422 on a bucket created without a unique_key, or when `fields` differ from the stored key."},"destination":{"anyOf":[{"$ref":"#/components/schemas/BucketDestination"},{"type":"null"}],"description":"Write this bucket's extraction outputs to your own storage instead of Mixpeek's: a storage connection with write access and a prefix. Send null to unbind; later outputs go to Mixpeek's storage."},"ingest_filter":{"anyOf":[{"$ref":"#/components/schemas/IngestFilter"},{"type":"null"}],"description":"Set, replace or remove (null) the bucket's ingest filter: a pinned saved retriever every candidate object a sync brings in runs through before it is committed. The version is pinned on write; omit retriever_version to pin the retriever's current version."}},"type":"object","title":"BucketPatchRequest","description":"Request model for partial update of an existing bucket (PATCH operation)."},"BucketResponse":{"properties":{"bucket_id":{"type":"string","title":"Bucket Id","description":"Unique identifier for the bucket"},"bucket_name":{"type":"string","title":"Bucket Name","description":"Human-readable name for the bucket"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Description of the bucket"},"bucket_schema":{"anyOf":[{"$ref":"#/components/schemas/BucketSchema-Output"},{"type":"null"}],"description":"Schema definition for objects in this bucket"},"unique_key":{"anyOf":[{"$ref":"#/components/schemas/UniqueKeyConfig"},{"type":"null"}],"description":"Unique key configuration for this bucket (if configured)"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Additional metadata for the bucket"},"storage_class":{"anyOf":[{"$ref":"#/components/schemas/StorageClass"},{"type":"null"}],"description":"Object-storage tier for this bucket's objects: standard | nearline | coldline | archive. Provider-agnostic (GCS STANDARD/NEARLINE/COLDLINE/ARCHIVE; S3/MinIO STANDARD/STANDARD_IA/GLACIER_IR; archive is refused on S3, whose archive classes need a restore before a read). NOTE: applied on write for sync-based ingestion (the primary media path); tiering for direct/presigned uploads and retroactive re-tiering of existing objects are in progress. None = provider default."},"destination":{"anyOf":[{"$ref":"#/components/schemas/BucketDestination"},{"type":"null"}],"description":"Write this bucket's extraction outputs to your own storage instead of Mixpeek's: a storage connection with write access and a prefix. None keeps outputs in Mixpeek's storage."},"ingest_filter":{"anyOf":[{"$ref":"#/components/schemas/IngestFilter"},{"type":"null"}],"description":"A pinned saved retriever every candidate object a sync brings in (an RTSP segment, a connector file) runs through before it is committed. A sync's own ingest_filter wins over its bucket's. Kept objects carry the filter's record (execution id included) in their ingest_filter field; dropped ones are never stored and are counted on the sync job by reason. None means no filter."},"object_count":{"type":"integer","title":"Object Count","description":"Number of objects in the bucket"},"failed_object_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Failed Object Count","description":"Objects that permanently failed to become documents. They stay lifecycle_state=active and are counted in object_count, so without this a bucket where nothing can process reads as healthy. Null when the count has not been measured yet."},"failed_count_measured_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Failed Count Measured At","description":"When failed_object_count was last measured. On large buckets the count reruns at most once an hour, so it can lag object_count. Null when it has never been measured."},"total_size_bytes":{"type":"integer","title":"Total Size Bytes","description":"Total size of all objects in the bucket in bytes"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When the bucket was created"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"Last modification time of bucket metadata"},"last_upload_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Upload At","description":"When the last object was uploaded to this bucket"},"stats_updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Stats Updated At","description":"When bucket stats were last successfully recalculated"},"status":{"$ref":"#/components/schemas/TaskStatusEnum","description":"Bucket lifecycle status (ACTIVE, ARCHIVED, SUSPENDED, IN_PROGRESS for deleting)","default":"ACTIVE"},"is_locked":{"type":"boolean","title":"Is Locked","description":"Whether the bucket is locked (read-only)","default":false},"batch_stats":{"anyOf":[{"$ref":"#/components/schemas/BatchStatistics"},{"type":"null"}],"description":"Batch statistics for this bucket (calculated asynchronously, stored in DB)"},"storage_stats":{"anyOf":[{"$ref":"#/components/schemas/StorageStatistics"},{"type":"null"}],"description":"Storage statistics for this bucket (calculated asynchronously, stored in DB)"},"source_adapter":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Source Adapter","description":"Source adapter configuration for inbound webhook-driven ingestion"}},"type":"object","required":["bucket_name","object_count","total_size_bytes"],"title":"BucketResponse","description":"Response model for bucket operations."},"BucketSchema-Input":{"properties":{"properties":{"additionalProperties":{"$ref":"#/components/schemas/BucketSchemaField-Input"},"type":"object","title":"Properties","description":"REQUIRED. Map of field names to their type definitions. Each field must have a 'type' from the supported types: metadata types (string, number, integer, float, boolean, object, array, date, datetime) or file/blob types (text, image, audio, video, pdf, excel). NOTE: Use Mixpeek types, NOT JSON Schema types — e.g. use 'string' not 'keyword', 'text' for text blobs, 'image' for image blobs. Example: {\"title\": {\"type\": \"string\"}, \"photo\": {\"type\": \"image\"}}"}},"additionalProperties":true,"type":"object","required":["properties"],"title":"BucketSchema","description":"Schema definition for bucket objects.\n\nIMPORTANT: The bucket schema defines what fields your bucket objects will have.\nThis schema is REQUIRED if you want to:\n1. Create collections that use input_mappings to process your bucket data\n2. Validate object structure before ingestion\n3. Enable type-safe data pipelines\n\nThe schema defines the custom fields that will be used in:\n- Blob properties (e.g., \"content\", \"thumbnail\", \"transcript\")\n- Object metadata structure\n- Blob data structures\n\nExample workflow:\n1. Create bucket WITH schema defining your data structure\n2. Upload objects that conform to that schema\n3. Create collections that map schema fields to feature extractors\n\nWithout a bucket_schema, collections cannot use input_mappings."},"BucketSchema-Output":{"properties":{"properties":{"additionalProperties":{"$ref":"#/components/schemas/BucketSchemaField-Output"},"type":"object","title":"Properties","description":"REQUIRED. Map of field names to their type definitions. Each field must have a 'type' from the supported types: metadata types (string, number, integer, float, boolean, object, array, date, datetime) or file/blob types (text, image, audio, video, pdf, excel). NOTE: Use Mixpeek types, NOT JSON Schema types — e.g. use 'string' not 'keyword', 'text' for text blobs, 'image' for image blobs. Example: {\"title\": {\"type\": \"string\"}, \"photo\": {\"type\": \"image\"}}"}},"additionalProperties":true,"type":"object","required":["properties"],"title":"BucketSchema","description":"Schema definition for bucket objects.\n\nIMPORTANT: The bucket schema defines what fields your bucket objects will have.\nThis schema is REQUIRED if you want to:\n1. Create collections that use input_mappings to process your bucket data\n2. Validate object structure before ingestion\n3. Enable type-safe data pipelines\n\nThe schema defines the custom fields that will be used in:\n- Blob properties (e.g., \"content\", \"thumbnail\", \"transcript\")\n- Object metadata structure\n- Blob data structures\n\nExample workflow:\n1. Create bucket WITH schema defining your data structure\n2. Upload objects that conform to that schema\n3. Create collections that map schema fields to feature extractors\n\nWithout a bucket_schema, collections cannot use input_mappings."},"BucketSchemaField-Input":{"properties":{"type":{"$ref":"#/components/schemas/BucketSchemaFieldType"},"default":{"anyOf":[{},{"type":"null"}],"title":"Default"},"items":{"anyOf":[{"$ref":"#/components/schemas/BucketSchemaField-Input"},{"type":"null"}]},"properties":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/BucketSchemaField-Input"},"type":"object"},{"type":"null"}],"title":"Properties"},"examples":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Examples","description":"OPTIONAL. List of example values for this field. Used by Apps to show example inputs in the UI. Provide multiple diverse examples when possible."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"enum":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Enum"},"required":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Required","default":false}},"additionalProperties":true,"type":"object","required":["type"],"title":"BucketSchemaField","description":"Schema field definition for bucket objects."},"BucketSchemaField-Output":{"properties":{"type":{"$ref":"#/components/schemas/BucketSchemaFieldType"},"default":{"anyOf":[{},{"type":"null"}],"title":"Default"},"items":{"anyOf":[{"$ref":"#/components/schemas/BucketSchemaField-Output"},{"type":"null"}]},"properties":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/BucketSchemaField-Output"},"type":"object"},{"type":"null"}],"title":"Properties"},"examples":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Examples","description":"OPTIONAL. List of example values for this field. Used by Apps to show example inputs in the UI. Provide multiple diverse examples when possible."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"enum":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Enum"},"required":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Required","default":false}},"additionalProperties":true,"type":"object","required":["type"],"title":"BucketSchemaField","description":"Schema field definition for bucket objects."},"BucketSchemaFieldType":{"type":"string","enum":["string","number","integer","float","boolean","object","array","date","datetime","text","image","audio","video","pdf","excel"],"title":"BucketSchemaFieldType","description":"Supported data types for bucket schema fields.\n\nTypes fall into two categories:\n\n1. **Metadata Types** (JSON types):\n   - Stored as object metadata\n   - Standard JSON-compatible types\n   - Not processed by extractors (unless explicitly mapped)\n   - Examples: string, number, boolean, date\n\n2. **File Types** (blobs):\n   - Stored as files/blobs\n   - Processed by extractors\n   - Require file content (URL or base64)\n   - Examples: text, image, video, pdf\n\n**GIF Special Handling**:\n    GIF files can be declared as either IMAGE or VIDEO type:\n\n    - As IMAGE: GIF is embedded as a single static image (first frame)\n    - As VIDEO: GIF is decomposed frame-by-frame with embeddings per frame\n\n    The multimodal extractor detects GIFs via MIME type (image/gif) and routes\n    them based on your schema declaration. Use VIDEO for animated GIFs where\n    frame-level search is needed, IMAGE for static/thumbnail use cases.\n\nNOTE: For retriever input schemas that need to accept document references\n(e.g., \"find similar documents\"), use RetrieverInputSchemaFieldType instead,\nwhich includes all bucket types plus document_reference."},"BucketStorageResponse":{"properties":{"bucket_id":{"type":"string","title":"Bucket Id","description":"Bucket identifier"},"time_range":{"$ref":"#/components/schemas/api__analytics__buckets__models__TimeRange","description":"Query time range"},"metrics":{"items":{"$ref":"#/components/schemas/StorageMetric"},"type":"array","title":"Metrics","description":"Time-series storage metrics"},"summary":{"additionalProperties":true,"type":"object","title":"Summary","description":"Summary statistics"}},"type":"object","required":["bucket_id","time_range","metrics"],"title":"BucketStorageResponse","description":"Storage growth trends response."},"BucketUpdateRequest":{"properties":{"bucket_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bucket Name","description":"Human-readable name for the bucket"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Description of the bucket"},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Additional metadata for the bucket"},"bucket_schema":{"anyOf":[{"$ref":"#/components/schemas/BucketSchema-Input"},{"type":"null"}],"description":"Schema definition for objects in this bucket"},"storage_class":{"anyOf":[{"$ref":"#/components/schemas/StorageClass"},{"type":"null"}],"description":"Object-storage tier: standard | nearline | coldline | archive. NOTE: applied on write for sync-based ingestion (the primary media path); tiering for direct uploads (POST /objects) and presigned uploads, plus retroactive re-tiering of existing objects, are in progress."},"destination":{"anyOf":[{"$ref":"#/components/schemas/BucketDestination"},{"type":"null"}],"description":"Write this bucket's extraction outputs to your own storage instead of Mixpeek's: a storage connection with write access and a prefix. None keeps outputs in Mixpeek's storage."},"ingest_filter":{"anyOf":[{"$ref":"#/components/schemas/IngestFilter"},{"type":"null"}],"description":"Set, replace or remove (null) the bucket's ingest filter: a pinned saved retriever every candidate object a sync brings in runs through before it is committed. The version is pinned on write; omit retriever_version to pin the retriever's current version."},"unique_key":{"anyOf":[{"$ref":"#/components/schemas/UniqueKeyConfig"},{"type":"null"}],"description":"Change the bucket's unique key default_policy. `fields` must repeat the bucket's existing unique key fields: the key itself is fixed at creation, because every stored object is registered under it. Send `default_policy: null` to clear the default so each upload or object create must pass ?policy=. Rejected with 422 on a bucket created without a unique_key, or when `fields` differ from the stored key."}},"type":"object","title":"BucketUpdateRequest","description":"Request model for updating an existing bucket."},"BucketUsageResponse":{"properties":{"bucket_id":{"type":"string","title":"Bucket Id","description":"Bucket identifier"},"time_range":{"$ref":"#/components/schemas/api__analytics__buckets__models__TimeRange","description":"Query time range"},"metrics":{"items":{"$ref":"#/components/schemas/UsageMetric"},"type":"array","title":"Metrics","description":"Usage metrics"},"cost_breakdown":{"$ref":"#/components/schemas/CostBreakdown","description":"Cost breakdown"},"total_credits":{"type":"integer","title":"Total Credits","description":"Total credits consumed"},"total_cost_usd":{"type":"number","title":"Total Cost Usd","description":"Total cost in USD"}},"type":"object","required":["bucket_id","time_range","metrics","cost_breakdown","total_credits","total_cost_usd"],"title":"BucketUsageResponse","description":"Bucket usage and cost analytics response."},"BudgetLimits":{"properties":{"max_credits":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Max Credits","description":"Maximum credits allowed for a single execution (OPTIONAL)."},"max_time_ms":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Max Time Ms","description":"Maximum wall-clock time in milliseconds before forcing halt (OPTIONAL)."}},"type":"object","title":"BudgetLimits","description":"User-defined limits for time and credits during execution.","examples":[{"max_credits":100.0,"max_time_ms":60000},{"max_time_ms":120000}]},"BuildConfig":{"properties":{"entry":{"type":"string","title":"Entry","description":"Build entry point","default":"src/layout.jsx"},"framework":{"type":"string","const":"react","title":"Framework","default":"react"},"tailwind":{"type":"boolean","title":"Tailwind","default":true},"env_vars":{"additionalProperties":{"type":"string"},"type":"object","title":"Env Vars","description":"Build-time environment variables injected into the app. Set MIXPEEK_API_KEY here to enable the /_api server-side proxy — without it the proxy falls back to the canvas server's default key. NOTE: every key here EXCEPT MIXPEEK_API_KEY is injected into the browser's window.__MIXPEEK__. For third-party secrets that must stay server-side (e.g. SERPAPI_KEY for a /functions/* handler), use ``secrets`` below, not ``env_vars``."},"secrets":{"additionalProperties":{"type":"string"},"type":"object","title":"Secrets","description":"Server-only secrets for the app's /functions/* server-side handlers, exposed to them as ``ctx.env``. NEVER injected into the browser window.__MIXPEEK__ and masked ('***') in API responses. Use for third-party API keys (e.g. SERPAPI_KEY)."},"asset_prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Asset Prefix","description":"CDN asset prefix once deployed"},"api_allow":{"anyOf":[{"items":{"$ref":"#/components/schemas/ApiAllowRule"},"type":"array"},{"type":"null"}],"title":"Api Allow","description":"Per-app /api proxy allowlist: rules that WIDEN the deny-by-default fleet allowlist, each {methods, pattern}. Read by the canvas /api proxy. Absent means the fleet default allowlist only. Was silently dropped before because BuildConfig ignored unknown keys ."}},"type":"object","title":"BuildConfig","description":"JSX build configuration for an App.\n\nPhase 1: schema only. Phase 3: used by the build pipeline task."},"BulkAnnotationCreate":{"properties":{"document_id":{"type":"string","title":"Document Id","description":"Document to annotate."},"collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Collection Id"},"label":{"type":"string","maxLength":100,"minLength":1,"title":"Label"},"confidence":{"anyOf":[{"type":"number","maximum":1.0,"minimum":0.0},{"type":"null"}],"title":"Confidence"},"reasoning":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}],"title":"Reasoning"},"payload":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Payload"},"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id"},"execution_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Execution Id"},"stage_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stage Name"}},"type":"object","required":["document_id","label"],"title":"BulkAnnotationCreate","description":"Single create within a bulk request."},"BulkAnnotationResult":{"properties":{"annotation_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Annotation Id","description":"Annotation ID (set for create/update)."},"operation":{"type":"string","title":"Operation","description":"Operation type: create, update, or delete."},"success":{"type":"boolean","title":"Success","description":"Whether the operation succeeded."},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if failed."}},"type":"object","required":["operation","success"],"title":"BulkAnnotationResult","description":"Result of a single operation within a bulk request."},"BulkAnnotationUpdate":{"properties":{"annotation_id":{"type":"string","title":"Annotation Id","description":"Annotation to update."},"label":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Label"},"confidence":{"anyOf":[{"type":"number","maximum":1.0,"minimum":0.0},{"type":"null"}],"title":"Confidence"},"reasoning":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}],"title":"Reasoning"},"payload":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Payload"}},"type":"object","required":["annotation_id"],"title":"BulkAnnotationUpdate","description":"Single update within a bulk request."},"BulkAnnotationsRequest":{"properties":{"create":{"items":{"$ref":"#/components/schemas/BulkAnnotationCreate"},"type":"array","maxItems":1000,"title":"Create","description":"Annotations to create."},"update":{"items":{"$ref":"#/components/schemas/BulkAnnotationUpdate"},"type":"array","maxItems":1000,"title":"Update","description":"Annotations to update."},"delete":{"items":{"type":"string"},"type":"array","maxItems":1000,"title":"Delete","description":"Annotation IDs to delete."}},"type":"object","title":"BulkAnnotationsRequest","description":"Bulk create, update, and/or delete annotations in a single call.\n\nProvide any combination of creates, updates, and deletes. Each operation\nis independent — a failure in one does not roll back the others."},"BulkAnnotationsResponse":{"properties":{"created_count":{"type":"integer","title":"Created Count","default":0},"updated_count":{"type":"integer","title":"Updated Count","default":0},"deleted_count":{"type":"integer","title":"Deleted Count","default":0},"failed_count":{"type":"integer","title":"Failed Count","default":0},"results":{"items":{"$ref":"#/components/schemas/BulkAnnotationResult"},"type":"array","title":"Results"}},"type":"object","title":"BulkAnnotationsResponse","description":"Response for bulk annotation operations."},"BulkInteractionItemResult":{"properties":{"index":{"type":"integer","title":"Index","description":"0-based index of this item in the request."},"interaction_id":{"type":"string","title":"Interaction Id","description":"Assigned interaction ID."},"status":{"type":"string","title":"Status","description":"Item status: 'created' or 'failed'.","default":"created"}},"type":"object","required":["index","interaction_id"],"title":"BulkInteractionItemResult","description":"Per-item result from a bulk interaction write."},"BulkInteractionsRequest":{"properties":{"interactions":{"items":{"$ref":"#/components/schemas/SearchInteraction"},"type":"array","maxItems":1000,"minItems":1,"title":"Interactions","description":"Interactions to record (1-1000). For historical backfill, set each interaction's `occurred_at` to its true time."}},"type":"object","required":["interactions"],"title":"BulkInteractionsRequest","description":"Record many interactions in one call — for backfilling historical logs.\n\nThe intended use is migrating an existing click/purchase history into\nMixpeek: send the interactions in chunks (≤ 1000 per call) with each one's\n``occurred_at`` set to its true timestamp, so learned-fusion temporal decay\nweights them correctly. Backfilled events bypass the real-time session cache."},"BulkInteractionsResponse":{"properties":{"created":{"type":"integer","title":"Created","description":"Number of interactions accepted for write."},"failed":{"type":"integer","title":"Failed","description":"Number that could not be processed (see errors).","default":0},"errors":{"items":{"type":"string"},"type":"array","title":"Errors","description":"Per-interaction error messages (indexed), if any failed."},"results":{"items":{"$ref":"#/components/schemas/BulkInteractionItemResult"},"type":"array","title":"Results","description":"Per-item results with assigned interaction IDs."}},"type":"object","required":["created"],"title":"BulkInteractionsResponse","description":"Result of a bulk interaction write."},"BulkMarkDLQRequest":{"properties":{"error_types":{"items":{"type":"string"},"type":"array","minItems":1,"title":"Error Types","description":"Error type names to mark as permanently failed, e.g. ['NotFoundError', 'ValidationError']."}},"type":"object","required":["error_types"],"title":"BulkMarkDLQRequest","description":"Request to mark DLQ entries as permanently failed by error type."},"BulkMarkDLQResponse":{"properties":{"updated":{"type":"integer","title":"Updated","description":"Number of DLQ entries marked as permanently failed."}},"type":"object","required":["updated"],"title":"BulkMarkDLQResponse","description":"Response from bulk-marking DLQ entries as permanently failed."},"BulkRequeueDLQRequest":{"properties":{"error_types":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Error Types","description":"Optional error-type filter, e.g. ['S3StorageError', 'TimeoutError']. Omit to requeue every exhausted entry for the sync config. Entries that have not exhausted their retries are never touched — they are already retrying."}},"type":"object","title":"BulkRequeueDLQRequest","description":"Request to requeue exhausted DLQ entries back into the retry path."},"BulkRequeueDLQResponse":{"properties":{"requeued":{"type":"integer","title":"Requeued","description":"Number of DLQ entries returned to the retry path."}},"type":"object","required":["requeued"],"title":"BulkRequeueDLQResponse","description":"Response from requeuing DLQ entries."},"BulkSoftDeleteRequest":{"properties":{"object_ids":{"items":{"type":"string"},"type":"array","maxItems":5000,"minItems":1,"title":"Object Ids","description":"Object IDs to soft-delete (max 5000 per request). Records are retained and flipped to a non-active lifecycle state so retrieval excludes them. There is no self-service restore endpoint: clearing the marker is a support action."},"reason":{"type":"string","maxLength":500,"title":"Reason","description":"Why these objects are being soft-deleted (audit trail)."},"lifecycle_state":{"type":"string","title":"Lifecycle State","description":"Lifecycle state to flip to (default 'disabled').","default":"disabled"},"source":{"type":"string","title":"Source","description":"Marker source tag (default 'bulk_purge').","default":"bulk_purge"}},"type":"object","required":["object_ids","reason"],"title":"BulkSoftDeleteRequest","description":"Request model for bulk soft-deleting objects by id.\n\nRecords are retained and flipped to a non-active lifecycle state. There is no\nself-service restore endpoint; clearing the marker is a support action.","examples":[{"object_ids":["obj_abc123","obj_def456"],"reason":"scope footage bucket to 8 target brands"}]},"BulkSoftDeleteResponse":{"properties":{"soft_deleted":{"type":"integer","title":"Soft Deleted","description":"Number of object records flipped."},"requested":{"type":"integer","title":"Requested","description":"Number of object IDs requested."},"collections":{"type":"integer","title":"Collections","description":"Collections sourced from the bucket considered for propagation."}},"type":"object","required":["soft_deleted","requested","collections"],"title":"BulkSoftDeleteResponse","description":"Response for a bulk soft-delete operation."},"BulkSubmitBatchesRequest":{"properties":{"collection_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Collection Ids","description":"Collections to process. Omit to auto-discover all collections sourced from this bucket (plus downstream dependencies)."},"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"Optional filter to scope which objects are submitted. Omit to submit EVERY object in the bucket (the whole-bucket case)."},"chunk_size":{"type":"integer","maximum":50000.0,"minimum":1.0,"title":"Chunk Size","description":"Objects per batch. Clamped down to your tier's max_batch_size. Default 1000 — a good balance of parallelism and per-batch overhead. Sizing model: each batch runs as its own job whose workers scale at ~1 CPU worker per 500 objects up to a per-job worker ceiling, so 16k-20k objects saturates one job's parallelism — for large corpora (100k+ objects) prefer chunk_size 20000. Larger chunks don't run faster; they only raise the cost of a mid-run failure (progress is still resumable per-object via the processing ledger). Much smaller chunks pay one cluster cold-start each and queue behind your tier's concurrent-batch limit. Full guide: docs.mixpeek.com/operations/batch-ingestion-at-scale.","default":1000},"dedup_strategy":{"$ref":"#/components/schemas/DedupStrategy","description":"How already-processed objects are handled (skip/replace/force).","default":"skip"},"max_objects":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Max Objects","description":"Optional cap on total objects streamed (safety bound for very large buckets). Omit to submit the whole bucket."}},"type":"object","title":"BulkSubmitBatchesRequest","description":"Submit a WHOLE bucket as N auto-chunked, auto-queued batches in one call.\n\nThe server streams the bucket's objects (paginated), de-duplicates them,\nchunks them into ``chunk_size``-object batches, and submits each — so the\nclient makes ONE call instead of a paced chunk-loop. This kills the\nclient-side cursor-overlap (409 storm), the 5k object-count timeout, and the\nno-whole-bucket frustration at once (phase 4). Each batch is\naccepted and QUEUED (accept-and-queue admission); poll the returned\n``batch_group_id`` / batch ids for QUEUED -> PROCESSING."},"BulkSubmitBatchesResponse":{"properties":{"batch_group_id":{"type":"string","title":"Batch Group Id","description":"Correlates all batches created by this call."},"total_objects":{"type":"integer","title":"Total Objects","description":"Distinct objects streamed (post-dedup)."},"total_batches":{"type":"integer","title":"Total Batches","description":"Batches created."},"submitted":{"type":"integer","title":"Submitted","description":"Batches accepted/queued successfully."},"failed":{"type":"integer","title":"Failed","description":"Batches that failed admission/submit."},"chunk_size":{"type":"integer","title":"Chunk Size","description":"Effective per-batch object count used."},"batches":{"items":{"$ref":"#/components/schemas/BulkSubmittedBatch"},"type":"array","title":"Batches","description":"Per-batch results with status + queue position."}},"type":"object","required":["batch_group_id","total_objects","total_batches","submitted","failed","chunk_size","batches"],"title":"BulkSubmitBatchesResponse","description":"Result of a whole-bucket bulk submit."},"BulkSubmittedBatch":{"properties":{"batch_id":{"type":"string","title":"Batch Id"},"status":{"type":"string","title":"Status"},"object_count":{"type":"integer","title":"Object Count"},"queue_position":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Queue Position"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","x-mixpeek-redacted":"driver_text"},"estimate":{"anyOf":[{"$ref":"#/components/schemas/BatchCostEstimate"},{"type":"null"}],"description":"OPTIONAL. What this batch was estimated to cost when it was submitted: the same calculation submit bills by, read from the batch before it ran. Absent when the estimate could not be computed in time."}},"type":"object","required":["batch_id","status","object_count"],"title":"BulkSubmittedBatch","description":"One batch in a bulk-submit group."},"BulkUpdateDocumentsRequest":{"properties":{"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"OPTIONAL. Filter conditions to match documents for update. If not provided, updates ALL documents in the collection. Uses the logical AND/OR/NOT shape — a list of {field, operator, value} conditions (operators: eq, ne, in, nin, gt, gte, lt, lte, contains, exists, …). The MVS-native {'must': [{'key': ...}]} shape is NOT accepted here. Example: {'AND': [{'field': 'metadata.status', 'operator': 'eq', 'value': 'pending'}]}","examples":[{"AND":[{"field":"metadata.status","operator":"eq","value":"pending"}]},{"AND":[{"field":"metadata.created_at","operator":"gt","value":"2024-01-01"}]}]},"update_data":{"additionalProperties":true,"type":"object","title":"Update Data","description":"REQUIRED. Dictionary of field-value pairs to update on ALL matching documents. Can update any document field except vectors (metadata, source_blobs, etc.). All matched documents receive the SAME updates. A dotted key sets one nested field and keeps its siblings: {'metadata.status': 'processed'} changes only metadata.status. A key without a dot replaces that whole top-level field, so {'metadata': {'status': 'processed'}} replaces the entire metadata object and drops its other keys. Object values are stored as given, but read back with their keys in alphabetical order. Example: {'metadata.status': 'processed', 'metadata.reviewed': true}","examples":[{"metadata.reviewed":true,"metadata.status":"processed"},{"metadata.processing_complete":true}]}},"type":"object","required":["update_data"],"title":"BulkUpdateDocumentsRequest","description":"Request model for bulk updating documents by filters.\n\nUpdates ALL documents matching the provided filters with the SAME update_data.\nFor updating specific documents by ID or different values per document, use BatchUpdateDocumentsRequest.\n\nUse Cases:\n    - Update all pending documents to processed\n    - Update all documents from a specific date range\n    - Apply uniform changes across filtered document sets\n\nRequirements:\n    - update_data: REQUIRED - fields to update on all matching documents\n    - filters: OPTIONAL - if omitted, updates ALL documents in collection","examples":[{"description":"Update all pending documents to processed","filters":{"AND":[{"field":"metadata.status","operator":"eq","value":"pending"}]},"update_data":{"metadata.status":"processed"}},{"description":"Update all documents in collection (no filters)","update_data":{"metadata.version":2}}]},"BulkUpdateDocumentsResponse":{"properties":{"task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id","description":"Id of the background task running the bulk update. Poll GET /v1/tasks/{task_id} for status and the final updated_count."},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Task status at enqueue time (PENDING). The terminal status (COMPLETED / FAILED) and updated_count land on the task record."},"updated_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Updated Count","description":"Number of documents updated. Null on the async enqueue response; populated on the task record when the task completes."},"message":{"type":"string","title":"Message","default":"Bulk update enqueued"}},"type":"object","title":"BulkUpdateDocumentsResponse","description":"Response model for bulk document update operation.\n\nbulk update is ASYNC. A filtered update scrolls matches on the shard\nand can run far longer than a request should hold a connection (an\nunindexed filtered scroll scans the whole shard, so 172 matching docs on a\nshared 6.47M-vector shard exceeded 120s and the client saw a silent no-op). The\nendpoint now enqueues a task and returns immediately: poll\nGET /v1/tasks/{task_id} for the terminal status and updated_count."},"CacheConfig":{"properties":{"enabled":{"type":"boolean","title":"Enabled","description":"Whether caching is enabled for this retriever","default":true},"ttl_seconds":{"type":"integer","minimum":0.0,"title":"Ttl Seconds","description":"Time-to-live for cached results in seconds. Default: 1 hour","default":3600},"cache_stage_names":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Cache Stage Names","description":"List of stage names to cache results after. Stage names must match the stage_name field in the retriever's stages. If not specified, caches the final results after all stages. Examples: ['semantic_search'], ['semantic_search', 'rerank']"},"exclude_fields":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Exclude Fields","description":"Fields to exclude from caching (e.g., PII fields)"},"stats":{"anyOf":[{"$ref":"#/components/schemas/CacheStatistics"},{"type":"null"}],"description":"Cache performance statistics"}},"type":"object","title":"CacheConfig","description":"Configuration for retriever result caching.\n\nControls how retriever results are cached to improve performance\nand reduce redundant compute.\n\nCaching can be configured at specific stages in the retriever pipeline.\nIf no stages are specified, the final results are cached by default."},"CachePerformanceResponse":{"properties":{"retriever_id":{"type":"string","title":"Retriever Id","description":"Retriever identifier"},"time_range":{"$ref":"#/components/schemas/api__analytics__models__TimeRange","description":"Time range"},"cache_hit_rate":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Cache Hit Rate","description":"Overall cache hit rate"},"total_cache_hits":{"type":"integer","title":"Total Cache Hits","description":"Total cache hits"},"total_cache_misses":{"type":"integer","title":"Total Cache Misses","description":"Total cache misses"},"avg_cache_hit_latency_ms":{"type":"number","title":"Avg Cache Hit Latency Ms","description":"Average latency on cache hit"},"avg_cache_miss_latency_ms":{"type":"number","title":"Avg Cache Miss Latency Ms","description":"Average latency on cache miss"},"hourly_breakdown":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Hourly Breakdown","description":"Hourly cache performance"}},"type":"object","required":["retriever_id","time_range","cache_hit_rate","total_cache_hits","total_cache_misses","avg_cache_hit_latency_ms","avg_cache_miss_latency_ms","hourly_breakdown"],"title":"CachePerformanceResponse","description":"Cache performance metrics.","examples":[{"avg_cache_hit_latency_ms":5.2,"avg_cache_miss_latency_ms":145.8,"cache_hit_rate":0.78,"hourly_breakdown":[{"hit_rate":0.78,"hits":145,"hour":"2025-10-28T10:00:00Z","misses":42}],"retriever_id":"ret_abc123","time_range":{"end":"2025-10-29T00:00:00Z","start":"2025-10-28T00:00:00Z"},"total_cache_hits":3456,"total_cache_misses":978}]},"CacheStatistics":{"properties":{"hit_count":{"type":"integer","title":"Hit Count","description":"Number of cache hits","default":0},"miss_count":{"type":"integer","title":"Miss Count","description":"Number of cache misses","default":0},"hit_rate":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Hit Rate","description":"Cache hit rate (0.0 - 1.0)","default":0.0},"size_bytes":{"type":"integer","title":"Size Bytes","description":"Total size of cached data in bytes","default":0},"entry_count":{"type":"integer","title":"Entry Count","description":"Number of entries in cache","default":0},"last_invalidated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Invalidated At","description":"When the cache was last invalidated"}},"type":"object","title":"CacheStatistics","description":"Statistics about cache performance."},"CancelMigrationRequest":{"properties":{"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason","description":"Cancellation reason"}},"type":"object","title":"CancelMigrationRequest","description":"Request to cancel a migration."},"CancelMigrationResponse":{"properties":{"migration_id":{"type":"string","title":"Migration Id","description":"Migration ID"},"status":{"$ref":"#/components/schemas/MigrationStatus","description":"Current status"},"cancelled_at":{"type":"string","format":"date-time","title":"Cancelled At","description":"Cancellation timestamp"},"message":{"type":"string","title":"Message","description":"Human-readable message"}},"type":"object","required":["migration_id","status","cancelled_at","message"],"title":"CancelMigrationResponse","description":"Response after cancelling a migration."},"CancelSubscriptionRequest":{"properties":{"immediate":{"type":"boolean","title":"Immediate","description":"Cancel NOW (Stripe Subscription.cancel) instead of at period end. Default False preserves the period-end behavior.","default":false},"invoice_now":{"type":"boolean","title":"Invoice Now","description":"With immediate=true: generate a final proration invoice.","default":false}},"type":"object","title":"CancelSubscriptionRequest","description":"Options for subscription cancellation."},"CancelSubscriptionResponse":{"properties":{"subscription_id":{"type":"string","title":"Subscription Id"},"cancel_at_period_end":{"type":"boolean","title":"Cancel At Period End","default":true},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"message":{"type":"string","title":"Message","default":"Subscription will cancel at end of current billing period"}},"type":"object","required":["subscription_id"],"title":"CancelSubscriptionResponse","description":"Response after cancelling a subscription."},"CancellationOutcome":{"properties":{"ray_jobs_requested":{"type":"integer","title":"Ray Jobs Requested","description":"Ray jobs this cancel attempted to stop: accepted plus refused. Zero means the batch had no Ray jobs to stop, which is normal for a batch that had not been dispatched yet.","default":0,"examples":[3]},"ray_jobs_accepted":{"type":"integer","title":"Ray Jobs Accepted","description":"Ray jobs that accepted the stop. This reports DISPATCH, not completion: an accepted job may still be winding down.","default":0,"examples":[3]},"ray_jobs_refused":{"type":"integer","title":"Ray Jobs Refused","description":"Ray jobs that refused or errored on the stop. Non-zero means some work may still be running, and the caller should not report the cancellation as complete.","default":0,"examples":[0]}},"type":"object","title":"CancellationOutcome","description":"What a cancel request actually reached, as opposed to what it asked for.\n\nA cancel used to answer HTTP 200 whether or not a single worker was reached,\nso a caller could not tell \"the jobs are stopping\" from \"the request was\naccepted and nothing was dispatched\". A client showing \"successfully\ncancelled\" on that 200 is guessing.\n\nThe three counters are dispatch outcomes and do not describe the batch's\nfinal state: jobs can be accepted and still take time to wind down, so a\nfully accepted cancellation is not a claim that work has stopped.\n\nPresent-and-zero is meaningful and differs from absent. All zeroes means the\ncancel path ran and had nothing to dispatch. The field being absent means the\nresponse came from a path that never ran a dispatch at all."},"ChangeEventResponse":{"properties":{"seq":{"type":"integer","title":"Seq","description":"Monotonic position within this org's feed."},"cursor":{"type":"string","title":"Cursor","description":"Opaque cursor pointing AT this event."},"namespace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Namespace Id","description":"Namespace scope, if any."},"event_type":{"type":"string","title":"Event Type","description":"Same vocabulary as webhook subscriptions."},"resource_type":{"type":"string","title":"Resource Type","description":"First segment of event_type."},"operation":{"type":"string","title":"Operation","description":"insert | update | delete | other."},"payload":{"additionalProperties":true,"type":"object","title":"Payload","description":"Shape is PER-EVENT-TYPE, not a stable contract — it mirrors whatever the originating call site already passes to WebhookClient.emit() for this event_type, and that shape may change independently of this endpoint's own versioning."},"trace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trace Id","description":"Trace of the request that made the change. Look it up in the trace backend to see that request. Null for changes recorded before trace ids were stored, or made outside any trace."},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["seq","cursor","event_type","resource_type","operation","created_at"],"title":"ChangeEventResponse"},"ChunkStrategy":{"type":"string","enum":["none","sentences","paragraphs","words","characters"],"title":"ChunkStrategy","description":"Strategy for splitting page content into chunks."},"ClarificationOption":{"properties":{"label":{"type":"string","title":"Label","description":"Option label"},"description":{"type":"string","title":"Description","description":"Option description"},"action":{"type":"string","title":"Action","description":"Recommended action/tool"}},"type":"object","required":["label","description","action"],"title":"ClarificationOption","description":"A single option presented to the user for clarifying intent.\n\nAttributes:\n    label: Short label for the option (e.g., \"Search existing data\")\n    description: Detailed explanation of what this option means\n    action: Recommended tool/action to use if user selects this option"},"CloneCollectionRequest":{"properties":{"collection_name":{"type":"string","minLength":1,"title":"Collection Name","description":"REQUIRED. Name for the cloned collection. Must be unique and different from the source collection.","examples":["product_embeddings_v2","video_frames_clip_v2"]},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"OPTIONAL. Description override. If omitted, copies from source collection.","examples":["Cloned from product_embeddings with CLIP v2"]},"source":{"anyOf":[{"$ref":"#/components/schemas/SourceConfig-Input"},{"type":"null"}],"description":"OPTIONAL. Override source configuration. If omitted, copies from source collection. Allows switching between buckets or collections."},"feature_extractor":{"anyOf":[{"$ref":"#/components/schemas/shared__collection__features__extractors__models__FeatureExtractorConfig-Input"},{"type":"null"}],"description":"OPTIONAL. Override feature extractor configuration. If omitted, copies from source collection. This is where you'd change models, parameters, or field_passthrough."},"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled","description":"OPTIONAL. Override enabled status. If omitted, copies from source collection."},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"OPTIONAL. Override metadata. If omitted, copies from source collection."},"taxonomy_applications":{"anyOf":[{"items":{"$ref":"#/components/schemas/TaxonomyApplicationConfig-Input"},"type":"array"},{"type":"null"}],"title":"Taxonomy Applications","description":"OPTIONAL. Override taxonomy applications. If omitted, copies from source collection."}},"type":"object","required":["collection_name"],"title":"CloneCollectionRequest","description":"Request to clone a collection with optional modifications.\n\n**Purpose:**\nCloning creates a NEW collection (with new ID) based on an existing one,\nallowing you to make changes that aren't allowed via PATCH (source,\nfeature_extractor, field_passthrough). This is the recommended way to\niterate on collection designs.\n\n**Clone vs Template vs Version:**\n- **Clone**: Copy THIS collection and modify it (for iteration/fixes)\n- **Template**: Create collection from a reusable pattern (for new projects)\n- **Version**: (Not implemented) - Use clone instead\n\n**Use Cases:**\n- Change feature extractor configuration without breaking production\n- Modify field_passthrough to include/exclude fields\n- Switch to different source (bucket or collection)\n- Test modifications before replacing production collection\n- Create variants (e.g., different embedding models)\n\n**All fields are OPTIONAL:**\n- Omit a field to keep the original value\n- Provide a field to override the original value\n- collection_name is REQUIRED (clones must have unique names)","examples":[{"collection_name":"product_embeddings_backup","example_desc":"Clone with just a new name (exact copy)"},{"collection_name":"product_embeddings_clip_v2","description":"Updated to use CLIP v2 model","example_desc":"Clone with different feature extractor","feature_extractor":{"feature_extractor_name":"image_extractor","input_mappings":{"image":"product_image"},"parameters":{"model":"clip-vit-large-patch14"},"version":"v2"}},{"collection_name":"product_embeddings_staging","example_desc":"Clone to different source bucket","source":{"bucket_id":"bkt_products_staging","type":"bucket"}}]},"CloneCollectionResponse":{"properties":{"collection":{"$ref":"#/components/schemas/CollectionModel","description":"Cloned collection configuration with new collection_id."},"source_collection_id":{"type":"string","title":"Source Collection Id","description":"ID of the source collection that was cloned."}},"type":"object","required":["collection","source_collection_id"],"title":"CloneCollectionResponse","description":"Response after cloning a collection."},"CloneNamespaceRequest":{"properties":{"namespace_name":{"type":"string","minLength":1,"title":"Namespace Name","description":"Name for the cloned namespace (must be unique)","examples":["production_staging","backup_2024_01"]},"include_resources":{"anyOf":[{"$ref":"#/components/schemas/CloneNamespaceResourcesConfig"},{"type":"null"}],"description":"Which resources to include. Defaults to collections + retrievers."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Override description. If omitted, copies from source.","examples":["Staging clone from production"]},"source_organization_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Organization Id","description":"Source org ID for cross-org cloning (admin only).","examples":["org_abc123"]},"mode":{"type":"string","enum":["copy","branch"],"title":"Mode","description":"'copy' writes every vector into the new namespace. 'branch' will make a copy-on-write fork that shares the source's storage until either side writes; it is not available yet and is refused, naming what it waits on.","default":"copy","examples":["copy"]},"ttl_seconds":{"anyOf":[{"type":"integer","minimum":60.0},{"type":"null"}],"title":"Ttl Seconds","description":"Time-to-live in seconds for the new namespace, as on namespace create: it is deleted automatically after this duration. Omit for no expiry.","examples":[86400]}},"type":"object","required":["namespace_name"],"title":"CloneNamespaceRequest","description":"Request to clone a namespace with all its data.\n\nClone creates a full copy of a namespace including:\n- Namespace configuration (extractors, indexes)\n- Buckets (metadata, references same S3 files)\n- Collections (full copy of all vectors/embeddings)\n- Retrievers (pipeline configuration)\n\n**Use Cases:**\n- Create staging environment from production\n- Backup namespace with all data\n- Fork namespace for experimentation\n\n**For a config-only copy (no data):** export the namespace with\nPOST /v1/manifest/export and apply the manifest with POST /v1/manifest/apply.","examples":[{"description":"Staging clone with all data","namespace_name":"production_staging"},{"description":"Experiment fork - collections only","include_resources":{"collections":true,"retrievers":false,"taxonomies":false},"namespace_name":"ml_experiment"}]},"CloneNamespaceResourcesConfig":{"properties":{"collections":{"type":"boolean","title":"Collections","description":"Include collections (with all embeddings/vectors)","default":true},"retrievers":{"type":"boolean","title":"Retrievers","description":"Include retrievers","default":true},"taxonomies":{"type":"boolean","title":"Taxonomies","description":"Include taxonomies","default":false}},"type":"object","title":"CloneNamespaceResourcesConfig","description":"Configuration for which resources to include in clone."},"CloneNamespaceResponse":{"properties":{"namespace":{"$ref":"#/components/schemas/NamespaceModel","description":"Cloned namespace with new namespace_id"},"source_namespace_id":{"type":"string","title":"Source Namespace Id","description":"Source namespace that was cloned"},"status":{"type":"string","title":"Status","description":"Clone status: 'cloning', 'ready', or 'failed'","default":"cloning"},"task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id","description":"Task ID for tracking clone progress"},"cloned_resources":{"anyOf":[{"$ref":"#/components/schemas/ClonedResourceSummary"},{"type":"null"}],"description":"Summary of cloned resources (present when ready)"},"primary_retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Primary Retriever Id","description":"Pre-allocated retriever ID for the primary cloned retriever. Present immediately so callers can navigate to the retriever detail page while the background task hydrates the rest of the data. None if source namespace has no retrievers."}},"type":"object","required":["namespace","source_namespace_id"],"title":"CloneNamespaceResponse","description":"Response after initiating namespace clone."},"CloneRetrieverRequest":{"properties":{"retriever_name":{"type":"string","minLength":1,"title":"Retriever Name","description":"REQUIRED. Name for the cloned retriever. Must be unique and different from the source retriever.","examples":["product_search_v2","semantic_search_strict"]},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"OPTIONAL. Description override. If omitted, copies from source retriever.","examples":["Cloned from product_search with stricter filters"]},"collection_identifiers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Collection Identifiers","description":"OPTIONAL. Override target collections. If omitted, copies from source retriever. This allows you to apply the same retriever logic to different collections. Also accepts 'collection_ids' as an alias.","examples":[["products_v2"],["col_abc123","col_def456"]]},"stages":{"anyOf":[{"items":{"$ref":"#/components/schemas/StageConfig-Input"},"type":"array"},{"type":"null"}],"title":"Stages","description":"OPTIONAL. Override stage configurations. If omitted, copies from source retriever. This is where you'd fix typos, add stages, or tweak parameters."},"input_schema":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/RetrieverInputSchemaField-Input","description":"Schema definition for this input field. Defines type, description, examples, and validation rules. Supports all bucket types (string, number, image, etc.) plus document_reference. Frontend uses this to render the appropriate input component (text input, image upload, dropdown, etc.)"},"type":"object"},{"type":"null"}],"title":"Input Schema","description":"OPTIONAL. Override input schema. If omitted, copies from source retriever."},"budget_limits":{"anyOf":[{"$ref":"#/components/schemas/BudgetLimits"},{"type":"null"}],"description":"OPTIONAL. Override budget limits. If omitted, copies from source retriever."},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags","description":"OPTIONAL. Override tags. If omitted, copies from source retriever.","examples":[["v2","production"],["experimental","clone"]]},"display_config":{"anyOf":[{"$ref":"#/components/schemas/DisplayConfig-Input"},{"type":"null"}],"description":"OPTIONAL. Override display configuration. If omitted, copies from source retriever."}},"type":"object","required":["retriever_name"],"title":"CloneRetrieverRequest","description":"Request to clone a retriever with optional modifications.\n\n**Purpose:**\nCloning creates a NEW retriever (with new ID) based on an existing one,\nallowing you to make changes that aren't allowed via PATCH (stages,\ninput_schema, collections). This is the recommended way to iterate on\nretriever designs.\n\n**Clone vs Template vs Version:**\n- **Clone**: Copy THIS retriever and modify it (for iteration/fixes)\n- **Template**: Create retriever from a reusable pattern (for new projects)\n- **Version**: (Not implemented) - Use clone instead\n\n**Use Cases:**\n- Fix a typo in a stage name without losing execution history\n- Add/remove stages while keeping the original intact\n- Change collections while preserving the original retriever\n- Test modifications before replacing production retriever\n- Create variants (e.g., \"strict\" vs \"relaxed\" versions)\n\n**All fields are OPTIONAL:**\n- Omit a field to keep the original value\n- Provide a field to override the original value\n- retriever_name is REQUIRED (clones must have unique names)","examples":[{"example_desc":"Clone with just a new name (exact copy)","retriever_name":"product_search_backup"},{"description":"Stricter version with higher min_score","example_desc":"Clone with stricter filters","retriever_name":"product_search_strict","tags":["strict","production"]},{"collection_identifiers":["products_staging"],"example_desc":"Clone to different collections","retriever_name":"product_search_staging","tags":["staging"]}]},"CloneRetrieverResponse":{"properties":{"retriever":{"$ref":"#/components/schemas/RetrieverConfig","description":"Cloned retriever configuration with new retriever_id."},"source_retriever_id":{"type":"string","title":"Source Retriever Id","description":"ID of the source retriever that was cloned."}},"type":"object","required":["retriever","source_retriever_id"],"title":"CloneRetrieverResponse","description":"Response after cloning a retriever."},"CloneTaxonomyRequest":{"properties":{"taxonomy_name":{"type":"string","minLength":1,"title":"Taxonomy Name","description":"REQUIRED. Name for the cloned taxonomy. Must be unique and different from the source taxonomy.","examples":["product_tags_v2","org_hierarchy_strict"]},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"OPTIONAL. Description override. If omitted, copies from source taxonomy.","examples":["Cloned from product_tags with updated retriever"]},"config":{"anyOf":[{"oneOf":[{"$ref":"#/components/schemas/FlatTaxonomyConfig-Input"},{"$ref":"#/components/schemas/HierarchicalTaxonomyConfig-Input"}],"discriminator":{"propertyName":"taxonomy_type","mapping":{"flat":"#/components/schemas/FlatTaxonomyConfig-Input","hierarchical":"#/components/schemas/HierarchicalTaxonomyConfig-Input"}}},{"type":"null"}],"title":"Config","description":"OPTIONAL. Override taxonomy configuration. If omitted, copies from source taxonomy. This allows you to change retriever_id, input_mappings, enrichment_fields, or collection hierarchy."}},"type":"object","required":["taxonomy_name"],"title":"CloneTaxonomyRequest","description":"Request to clone a taxonomy with optional modifications.\n\n**Purpose:**\nCloning creates a NEW taxonomy (with new ID) based on an existing one,\nallowing you to make changes that aren't allowed via PATCH (config,\nretriever_id, collections). This is the recommended way to iterate on\ntaxonomy designs.\n\n**Clone vs Template vs Version:**\n- **Clone**: Copy THIS taxonomy and modify it (for iteration/fixes)\n- **Template**: Create taxonomy from a reusable pattern (for new projects)\n- **Version**: (Not implemented) - Use clone instead\n\n**Use Cases:**\n- Fix configuration errors without losing join history\n- Change retriever or input mappings\n- Change target collections\n- Test modifications before replacing production taxonomy\n- Create variants for different datasets\n\n**All fields are OPTIONAL:**\n- Omit a field to keep the original value\n- Provide a field to override the original value\n- taxonomy_name is REQUIRED (clones must have unique names)","examples":[{"example_desc":"Clone with just a new name (exact copy)","taxonomy_name":"product_tags_backup"},{"config":{"input_mappings":[{"input_key":"image_vector","path":"features.clip_v2","source_type":"vector"}],"retriever_id":"ret_clip_v2","source_collection":{"collection_id":"col_products_v1"},"taxonomy_type":"flat"},"description":"Updated with new CLIP retriever","example_desc":"Clone with different retriever","taxonomy_name":"product_tags_v2"}]},"CloneTaxonomyResponse":{"properties":{"taxonomy":{"$ref":"#/components/schemas/TaxonomyModel-Output","description":"Cloned taxonomy configuration with new taxonomy_id."},"source_taxonomy_id":{"type":"string","title":"Source Taxonomy Id","description":"ID of the source taxonomy that was cloned."}},"type":"object","required":["taxonomy","source_taxonomy_id"],"title":"CloneTaxonomyResponse","description":"Response after cloning a taxonomy."},"ClonedResourceSummary":{"properties":{"collections":{"type":"integer","title":"Collections","description":"Collections cloned","default":0},"retrievers":{"type":"integer","title":"Retrievers","description":"Retrievers cloned","default":0},"taxonomies":{"type":"integer","title":"Taxonomies","description":"Taxonomies cloned","default":0},"buckets":{"type":"integer","title":"Buckets","description":"Buckets cloned","default":0},"objects":{"type":"integer","title":"Objects","description":"Objects cloned","default":0},"points":{"type":"integer","title":"Points","description":"Vector points cloned","default":0}},"type":"object","title":"ClonedResourceSummary","description":"Summary of cloned resources."},"CloudCostCategorySummary":{"properties":{"category":{"type":"string","title":"Category"},"category_label":{"type":"string","title":"Category Label"},"cloud_cost_usd":{"type":"number","title":"Cloud Cost Usd"},"margin_usd":{"type":"number","title":"Margin Usd"},"total_usd":{"type":"number","title":"Total Usd"},"line_items":{"items":{"$ref":"#/components/schemas/CloudCostLineItem"},"type":"array","title":"Line Items"}},"type":"object","required":["category","category_label","cloud_cost_usd","margin_usd","total_usd","line_items"],"title":"CloudCostCategorySummary"},"CloudCostLineItem":{"properties":{"service":{"type":"string","title":"Service"},"description":{"type":"string","title":"Description"},"category":{"type":"string","title":"Category"},"cloud_cost_usd":{"type":"number","title":"Cloud Cost Usd"},"margin_usd":{"type":"number","title":"Margin Usd"},"total_usd":{"type":"number","title":"Total Usd"},"usage_amount":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Usage Amount"},"usage_unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Usage Unit"},"region":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Region"}},"type":"object","required":["service","description","category","cloud_cost_usd","margin_usd","total_usd"],"title":"CloudCostLineItem"},"ClusterApplicationConfig":{"properties":{"cluster_id":{"type":"string","title":"Cluster Id","description":"ID of the cluster to execute (must exist and use this collection as input)"},"auto_execute_on_batch":{"type":"boolean","title":"Auto Execute On Batch","description":"Automatically execute cluster when batch processing completes for this collection. If False, cluster must be executed manually via API.","default":true},"min_document_threshold":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Document Threshold","description":"Minimum number of documents required before executing cluster. If document_count < threshold, clustering is skipped. Useful to avoid clustering on small datasets."},"cooldown_seconds":{"type":"integer","title":"Cooldown Seconds","description":"Minimum time (in seconds) between automatic cluster executions. Prevents excessive re-clustering on frequent batch completions. Default: 3600 seconds (1 hour).","default":3600},"execution_phase":{"type":"integer","maximum":3.0,"minimum":1.0,"title":"Execution Phase","description":"Which phase this cluster runs in. Default: 2 (CLUSTER phase, after taxonomies). Valid values: 1=TAXONOMY, 2=CLUSTER, 3=ALERT. Lower phases run earlier.","default":2},"priority":{"type":"integer","maximum":1000.0,"minimum":0.0,"title":"Priority","description":"Priority within the execution phase (higher = runs first)","default":0}},"type":"object","required":["cluster_id"],"title":"ClusterApplicationConfig","description":"Configuration for automatic cluster execution on collection.\n\nSimilar to TaxonomyApplicationConfig, this attaches a cluster to a collection\nand defines when/how it should be automatically executed.\n\nUsed in CollectionModel.cluster_applications field.\n\nSupports execution phase ordering for unified post-processing with\ntaxonomies, clusters, and alerts.","examples":[{"auto_execute_on_batch":true,"cluster_id":"clust_product_categories","cooldown_seconds":3600,"min_document_threshold":100},{"auto_execute_on_batch":true,"cluster_id":"clust_user_segments","cooldown_seconds":7200,"execution_phase":2,"min_document_threshold":500,"priority":10}]},"ClusterCompositeSource":{"properties":{"source_run_id":{"type":"string","title":"Source Run Id","description":"The source execution (run_id) the centroid comes from."},"original_cluster_id":{"type":"string","title":"Original Cluster Id","description":"The centroid's cluster id within that source execution."},"num_members":{"type":"integer","title":"Num Members","description":"Members the source centroid had in its own execution.","default":0}},"type":"object","required":["source_run_id","original_cluster_id"],"title":"ClusterCompositeSource","description":"One source centroid a composite meta-cluster groups."},"ClusterExecutionCentroid":{"properties":{"cluster_id":{"type":"string","minLength":1,"title":"Cluster Id","description":"REQUIRED. Unique identifier for this cluster within the execution. Vector clustering uses a 'cl_' prefix with a numeric index (e.g., 'cl_0', 'cl_0_sub_1', 'cl_cluster_noise'); attribute clustering uses value-derived IDs (e.g., 'cl_cluster_0' flat, 'cl_photonics_2024' hierarchical). Used to reference this specific cluster in queries and enrichments. Consistent across executions if algorithm deterministic.","examples":["cl_0","cl_1","cl_0_sub_1","cl_0_sub_1_sub_0","cl_cluster_noise","cl_-1","cl_cluster_0","cl_photonics_2024"]},"num_members":{"type":"integer","minimum":0.0,"title":"Num Members","description":"REQUIRED. Number of documents/points assigned to this cluster. Indicates cluster size for sizing bubbles in visualizations. Minimum: 1 (K-Means forces assignment). Can be 0 for noise clusters in HDBSCAN (cluster_id = -1).","examples":[150,42,1]},"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label","description":"OPTIONAL. Human-readable label generated by LLM (e.g., GPT-4o-mini). Automatically generated when llm_labeling.enabled = true in cluster config. NOT REQUIRED when LLM labeling disabled. Describes the semantic meaning of documents in this cluster. Example: 'Product Reviews', 'Technical Documentation', 'Customer Support'.","examples":["Product Reviews","Technical Documentation","Customer Support",null]},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary","description":"OPTIONAL. Detailed description generated by LLM. Automatically generated when llm_labeling.include_summary = true. NOT REQUIRED when LLM labeling disabled or summary not requested. Provides context about what types of documents are in this cluster. Useful for tooltips, expanded views, or detailed explanations.","examples":["This cluster contains documents related to product reviews and customer feedback.","Technical documentation and API references are grouped here.",null]},"keywords":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Keywords","description":"OPTIONAL. List of semantic keywords generated by LLM. Automatically generated when llm_labeling.include_keywords = true. NOT REQUIRED when LLM labeling disabled or keywords not requested. Useful for search, filtering, and quick cluster understanding. Typically 3-5 keywords per cluster.","examples":[["reviews","products","feedback"],["technical","documentation","api"],["support","customer","help"],null]},"mean_cosine_similarity":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Mean Cosine Similarity","description":"Mean cosine similarity of members to centroid (higher = tighter cluster)."},"min_cosine_similarity":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Min Cosine Similarity","description":"Minimum cosine similarity of any member to centroid (cluster boundary)."},"centroid_vector":{"anyOf":[{"items":{"type":"number"},"type":"array"},{"type":"null"}],"title":"Centroid Vector","description":"OPTIONAL. The cluster centroid's embedding vector. Only populated when a single-execution GET is called with ?include_vectors=true (vectors are large — e.g. 15 centroids x 1024 floats ≈ 120KB — so they're opt-in and never included in execution LIST responses). Enables vector-input searches that use the centroid as the query even when the centroid document is no longer resolvable in the vector store (e.g. artifact-served clusters after a store wipe). Omitted from the response entirely when not requested."},"representative_ids":{"anyOf":[{"items":{"$ref":"#/components/schemas/RepresentativeDocument"},"type":"array"},{"type":"null"}],"title":"Representative Ids","description":"OPTIONAL. Representative documents (document_id + collection_id) offered to the LLM labeler for this cluster, capped upstream to a small sample (~16). Persisted so a labeling failure is diagnosable from the run record alone: absent/empty vs. present-but-unfetchable distinguishes 'no reps were ever selected' from 'reps existed but the fetch/resolution stage failed them' (durability)."}},"type":"object","required":["cluster_id","num_members"],"title":"ClusterExecutionCentroid","description":"Centroid information from a clustering execution.\n\nRepresents a single cluster center from a clustering run, including\nLLM-generated semantic labels for human understanding.\n\nUse Cases:\n    - Display cluster information in dashboards\n    - Show cluster labels and summaries in UI\n    - Group documents by semantic meaning\n    - Filter/search by cluster keywords\n\nNote:\n    This model is for execution metadata only (no visualization coordinates).\n    For scatter plot coordinates, use ArtifactCentroid from the artifacts endpoint.","examples":[{"cluster_id":"cl_0","description":"Cluster with full LLM labeling","keywords":["reviews","products","feedback","ratings"],"label":"Product Reviews","num_members":150,"summary":"This cluster contains documents related to product reviews and customer feedback."},{"cluster_id":"cl_1","description":"Cluster without LLM labeling","num_members":42},{"cluster_id":"cl_2","description":"Small cluster with label","keywords":["single","unique","isolation"],"label":"Single Member Cluster","num_members":1,"summary":"This cluster contains only one member."}]},"ClusterExecutionListStats":{"properties":{"total_executions":{"type":"integer","minimum":0.0,"title":"Total Executions","description":"OPTIONAL (always provided). Total number of executions in current result set. Equals length of results array. Use for:   - Display total count in UI ('Showing 10 of 100 executions').   - Validate pagination (total should match page_size × pages).   - Check if filters returned any results (0 = no matches). Note: This is the count in the current page, not all executions.","default":0,"examples":[10,25,100,0]},"executions_by_status":{"additionalProperties":{"type":"integer"},"type":"object","title":"Executions By Status","description":"OPTIONAL (always provided). Count of executions grouped by status. Keys: 'pending', 'processing', 'completed', 'failed'. Values: Number of executions in each status. Use for:   - Status distribution chart (pie/bar chart).   - Health monitoring (high failed count = problem).   - Progress tracking (pending + processing = in-flight jobs). Example: {'completed': 45, 'failed': 3, 'processing': 2, 'pending': 0}. Empty dict {} if no executions in result set.","examples":[{"completed":45,"failed":3,"processing":2},{"completed":100},{}]},"avg_execution_time_ms":{"type":"number","minimum":0.0,"title":"Avg Execution Time Ms","description":"OPTIONAL (always provided). Average execution duration in milliseconds. Calculated as: mean(completed_at - created_at) for completed/failed executions. Excludes pending/processing executions (no completed_at yet). Use for:   - Performance monitoring ('Average: 5.2 seconds').   - Trend analysis (is clustering getting slower over time?).   - Capacity planning (estimate time for future runs). 0.0 if: No completed/failed executions in result set. Typical values:   - Small datasets (< 100 docs): 1000-5000ms (1-5 seconds).   - Medium datasets (100-1000 docs): 5000-30000ms (5-30 seconds).   - Large datasets (1000+ docs): 30000-300000ms (30 seconds - 5 minutes).","default":0.0,"examples":[5234.5,12890.3,45678.9,0.0]},"total_documents_clustered":{"type":"integer","minimum":0.0,"title":"Total Documents Clustered","description":"OPTIONAL (always provided). Total documents processed across all executions. Calculated as: sum(num_points) for all executions in result set. Use for:   - Volume tracking ('Processed 10,000 documents').   - Cost estimation (larger datasets = more compute).   - Data growth monitoring (compare over time). 0 if: No executions in result set. Note: Same document may be counted multiple times if re-clustered.","default":0,"examples":[10000,50000,150000,0]},"avg_num_clusters":{"type":"number","minimum":0.0,"title":"Avg Num Clusters","description":"OPTIONAL (always provided). Average number of clusters found per execution. Calculated as: mean(num_clusters) for all executions in result set. Use for:   - Clustering consistency check (stable avg = consistent results).   - Algorithm tuning (avg too high/low may need parameter adjustment).   - Trend analysis (is clustering finding more/fewer clusters over time?). 0.0 if: No executions in result set. Typical values:   - Under-clustering: < 3 clusters (data may be too diverse).   - Good clustering: 3-20 clusters (manageable, meaningful groups).   - Over-clustering: > 20 clusters (too granular, hard to interpret).","default":0.0,"examples":[5.3,12.7,3.0,0.0]}},"type":"object","title":"ClusterExecutionListStats","description":"Aggregate statistics calculated across all executions in the current result set.\n\nProvides summary metrics for the filtered/searched execution history, useful for\ndashboards, monitoring, and trend analysis. Statistics are calculated only for\nthe executions returned in the current query (respects filters and pagination).\n\nUse Cases:\n    - Display execution summary cards (\"5 completed, 2 failed, 3 pending\")\n    - Show average execution time trend\n    - Monitor clustering performance over time\n    - Build execution health dashboard\n    - Compare stats across different time periods (via filters)\n\nImportant:\n    Stats reflect only the current result set, not all historical executions.\n    Apply filters to calculate stats for specific time ranges or statuses.","examples":[{"avg_execution_time_ms":8234.5,"avg_num_clusters":5.2,"description":"Healthy execution stats (mostly successful)","executions_by_status":{"completed":45,"failed":3,"pending":0,"processing":2},"total_documents_clustered":50000,"total_executions":50},{"avg_execution_time_ms":12890.3,"avg_num_clusters":7.5,"description":"All completed executions","executions_by_status":{"completed":10},"total_documents_clustered":15000,"total_executions":10},{"avg_execution_time_ms":0.0,"avg_num_clusters":0.0,"description":"Empty result set (no executions)","executions_by_status":{},"total_documents_clustered":0,"total_executions":0}]},"ClusterExecutionMetric":{"properties":{"execution_id":{"type":"string","title":"Execution Id","description":"Execution identifier"},"started_at":{"type":"string","format":"date-time","title":"Started At","description":"Execution start time"},"duration_seconds":{"type":"number","title":"Duration Seconds","description":"Execution duration"},"num_documents":{"type":"integer","title":"Num Documents","description":"Number of documents clustered"},"num_clusters":{"type":"integer","title":"Num Clusters","description":"Number of clusters created"},"status":{"type":"string","title":"Status","description":"Execution status"},"algorithm":{"type":"string","title":"Algorithm","description":"Clustering algorithm used"}},"type":"object","required":["execution_id","started_at","duration_seconds","num_documents","num_clusters","status","algorithm"],"title":"ClusterExecutionMetric","description":"Single cluster execution metrics."},"ClusterExecutionMetrics":{"properties":{"silhouette_score":{"anyOf":[{"type":"number","maximum":1.0,"minimum":-1.0},{"type":"null"}],"title":"Silhouette Score","description":"OPTIONAL. Silhouette score measuring cluster cohesion and separation. Range: -1 to +1. Interpretation:   +1.0 = Perfect clustering (documents far from other clusters, close to own cluster).   0.0 = Overlapping clusters (documents on cluster boundaries).   -1.0 = Poor clustering (documents assigned to wrong clusters). Practical thresholds:   0.7 to 1.0 = Excellent clustering.   0.5 to 0.7 = Good clustering.   0.25 to 0.5 = Weak clustering, consider different parameters.   Below 0.25 = Poor clustering, reconfigure or more data needed. null = metric not calculated (too few points or clustering failed).","examples":[0.85,0.67,0.42,null]},"davies_bouldin_index":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Davies Bouldin Index","description":"OPTIONAL. Davies-Bouldin index measuring cluster separation. Range: 0 to +∞ (lower is better, no upper bound). Interpretation:   0.0 = Perfect separation (impossible in practice).   0.0 to 1.0 = Excellent separation.   1.0 to 2.0 = Good separation.   Above 2.0 = Poor separation, clusters overlap. Formula: Average ratio of intra-cluster to inter-cluster distances. Use when: Validating that clusters are distinct and well-separated. null = metric not calculated (too few points or clustering failed).","examples":[0.45,1.23,2.67,null]},"calinski_harabasz_score":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Calinski Harabasz Score","description":"OPTIONAL. Calinski-Harabasz score (also called Variance Ratio Criterion). Range: 0 to +∞ (higher is better, no strict upper bound). Interpretation:   Higher values indicate denser, more compact clusters.   No universal threshold - compare relative values across runs.   Typical good values: 100-1000+ (dataset dependent). Formula: Ratio of between-cluster to within-cluster dispersion. Use when: Comparing different numbers of clusters for the same dataset. Note: Biased toward algorithms that produce spherical, equally-sized clusters. null = metric not calculated (too few points or clustering failed).","examples":[456.78,1234.56,89.12,null]},"degenerate":{"anyOf":[{"type":"boolean"},{"type":"string"},{"type":"null"}],"title":"Degenerate","description":"OPTIONAL, THREE-STATE. Whether this clustering carries any information. null/absent = not evaluated. false = evaluated and fine. A reason STRING = evaluated and degenerate, and the string says which kind: 'single_cluster' (one cluster holds every non-noise point), 'all_noise' (nothing was clustered), 'all_singletons' (almost every point is its own cluster), 'dominant_cluster' (more than one cluster, but one holds >=90% of clustered points — note the quality scores above DO compute for this shape, so they describe a near-single grouping and must not be read as evidence of success). Do NOT test this with `is False`: on some surfaces the false state is serialized as 0.0. Test falsiness, or test isinstance(x, str) for the bad case.","examples":[false,"dominant_cluster","single_cluster",null]},"degenerate_detail":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Degenerate Detail","description":"OPTIONAL. Human-readable explanation, present only when `degenerate` is a reason string. Carries the measured fraction, e.g. '1 of 3 cluster(s) holds 99.7% of the 3342 clustered point(s) (0 noise)'.","examples":["1 of 3 cluster(s) holds 99.7% of the 3342 clustered point(s) (0 noise) …",null]},"avg_cluster_size":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Cluster Size","description":"OPTIONAL. Mean number of documents per cluster, noise excluded.","examples":[125.4,null]},"noise_ratio":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Noise Ratio","description":"OPTIONAL. Fraction of points the algorithm rejected as noise, 0 to 1. Meaningful only for algorithms that HAVE a noise label (dbscan, hdbscan, optics); kmeans and spectral assign every point and report 0.","examples":[0.0,0.17,null]},"cluster_size_entropy":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cluster Size Entropy","description":"OPTIONAL. Shannon entropy of the cluster-size distribution. Low entropy with more than one cluster means the sizes are lopsided, which is the same shape `degenerate='dominant_cluster'` flags.","examples":[2.83,0.04,null]},"should_recluster":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Should Recluster","description":"OPTIONAL. Engine's own advice that this run is worth re-running with different parameters. 0 means no.","examples":[0.0,1.0,null]},"mean_cosine_to_centroid":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Mean Cosine To Centroid","description":"OPTIONAL. Mean cosine similarity of each clustered point to its own centroid. Higher is tighter.","examples":[0.81,null]},"min_cosine_to_centroid":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Min Cosine To Centroid","description":"OPTIONAL. Worst cosine similarity of any clustered point to its own centroid. A low value with a high mean means one cluster has a long tail.","examples":[0.12,null]}},"additionalProperties":true,"type":"object","title":"ClusterExecutionMetrics","description":"Quality metrics for evaluating clustering execution performance.\n\nProvides statistical measures to assess the quality of the clustering results.\nHigher quality clusters have better cohesion (documents within clusters are similar)\nand separation (clusters are distinct from each other).\n\nUse Cases:\n    - Compare quality across multiple clustering executions\n    - Determine optimal number of clusters for a dataset\n    - Validate clustering algorithm performance\n    - Track clustering quality over time\n    - Debug clustering issues (poor metrics indicate problems)\n\nInterpretation:\n    - Use silhouette_score as primary quality indicator (0.5+ = good, 0.7+ = excellent)\n    - Lower davies_bouldin_index indicates better-separated clusters\n    - Higher calinski_harabasz_score indicates denser, better-separated clusters\n\nNote:\n    All metrics are OPTIONAL and only present if clustering completed successfully.\n    Failed executions return null for all metrics.","examples":[{"calinski_harabasz_score":1234.56,"davies_bouldin_index":0.42,"description":"Excellent clustering quality","silhouette_score":0.85},{"calinski_harabasz_score":678.34,"davies_bouldin_index":0.89,"description":"Good clustering quality","silhouette_score":0.67},{"calinski_harabasz_score":45.12,"davies_bouldin_index":2.45,"description":"Poor clustering quality (needs tuning)","silhouette_score":0.23},{"description":"Metrics not available (failed execution)"}]},"ClusterExecutionResult":{"properties":{"run_id":{"type":"string","pattern":"^run_[a-zA-Z0-9]+$","title":"Run Id","description":"REQUIRED. Unique identifier for this specific clustering execution. Format: 'run_' prefix followed by random alphanumeric string. Used to retrieve specific execution artifacts and results. Each re-execution of the same cluster creates a new run_id. References execution artifacts in S3 and MongoDB.","examples":["run_a8e270953254754b","run_b3f58210ab","run_xyz789"]},"cluster_id":{"type":"string","pattern":"^clust_[a-zA-Z0-9]+$","title":"Cluster Id","description":"REQUIRED. Parent cluster configuration that was executed. Format: 'clust_' prefix followed by random alphanumeric string. Links this execution back to the cluster definition. Multiple executions can share the same cluster_id.","examples":["clust_ae3e28a429","clust_xyz789","clust_abc123"]},"status":{"type":"string","enum":["pending","processing","completed","failed","canceled"],"title":"Status","description":"REQUIRED. Current status of the clustering execution. Values:   'pending' = Job queued, waiting to start.   'processing' = Clustering algorithm running (may take minutes for large datasets).   'completed' = Clustering finished successfully, results available.   'failed' = Clustering failed or passed its deadline, check error_message for details.   'canceled' = Canceled through the cancel route. Status changes: pending → processing → (completed OR failed), or pending/processing → canceled. Poll this field to track job progress.","examples":["completed","processing","pending","failed"]},"num_clusters":{"type":"integer","minimum":0.0,"title":"Num Clusters","description":"REQUIRED. Number of clusters found by the clustering algorithm. Range: 1 to num_points (though typically much lower). Interpretation:   Too few clusters = overgeneralization, may need lower n_clusters param.   Too many clusters = overfitting, may need higher n_clusters param.   Optimal value depends on dataset and use case. Available immediately upon completion, even if metrics fail.","examples":[3,5,10,25]},"num_points":{"type":"integer","minimum":0.0,"title":"Num Points","description":"REQUIRED. Total number of documents/points that were clustered. Equals the count of documents in the collection at execution time. Note: This may differ across executions if documents were added/removed. Used to calculate metrics and validate clustering quality. Minimum 2 points required for clustering (1 cluster per point otherwise).","examples":[100,1000,50000]},"metrics":{"anyOf":[{"$ref":"#/components/schemas/ClusterExecutionMetrics"},{"type":"null"}],"description":"OPTIONAL. Quality metrics evaluating clustering performance. NOT REQUIRED - only present for successful executions. null if:   - Execution is still pending/processing.   - Execution failed.   - Too few points to calculate metrics (need 2+ points). Contains silhouette_score, davies_bouldin_index, calinski_harabasz_score. Use to compare quality across multiple executions."},"member_counts_stale":{"type":"boolean","title":"Member Counts Stale","description":"True when member documents were deleted after this run completed, so each centroid's num_members (and member_count on the centroid documents) counts some documents that no longer exist. Re-run the cluster for current counts.","default":false},"centroids":{"anyOf":[{"items":{"$ref":"#/components/schemas/ClusterExecutionCentroid"},"type":"array"},{"type":"null"}],"title":"Centroids","description":"OPTIONAL. List of cluster centroids with semantic labels. NOT REQUIRED - only present for completed executions with LLM labeling enabled. Length: equals num_clusters. Each centroid contains:   - cluster_id: Identifier for the cluster (e.g., 'cl_0').   - num_members: Count of documents in this cluster.   - label: Human-readable cluster name (e.g., 'Product Reviews').   - summary: Brief description of cluster content.   - keywords: Array of representative terms. null if:   - Execution pending/processing/failed.   - LLM labeling not configured. Use for: Displaying cluster summaries in UI, filtering by cluster."},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"REQUIRED. Timestamp when the clustering execution started. ISO 8601 format with timezone (UTC). Used to:   - Sort executions chronologically.   - Calculate execution duration (completed_at - created_at).   - Filter execution history by date range. Always present, even for failed executions.","examples":["2025-11-13T13:20:40.122000Z","2025-11-13T10:00:00.000000Z"]},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"OPTIONAL. Timestamp when the clustering execution finished. ISO 8601 format with timezone (UTC). NOT REQUIRED - only present for completed or failed executions. null if: status is 'pending' or 'processing'. Use to:   - Calculate execution duration (completed_at - created_at).   - Show when results became available. Present for both successful and failed executions.","examples":["2025-11-13T13:25:40.122000Z","2025-11-13T10:05:32.456000Z",null]},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"OPTIONAL. Error message if the clustering execution failed. NOT REQUIRED - only present when status is 'failed'. null if: execution succeeded or is still in progress. Contains:   - Human-readable error description.   - Possible causes and suggested fixes.   - Stack trace details (for debugging). Common errors:   - 'Insufficient documents for clustering' (need 2+ docs).   - 'Feature extractor not found' (invalid collection config).   - 'Out of memory' (dataset too large for algorithm). Use for: Debugging failed executions and user error messages.","examples":["Insufficient documents for clustering: need at least 2 documents","Feature extractor 'invalid_extractor' not found in collection","Clustering algorithm failed: NaN values in embeddings",null],"x-mixpeek-redacted":"driver_text"},"error_traceback":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Traceback","description":"OPTIONAL. Tail-truncated Python traceback captured where the execution failed (engine Ray driver or API-side submission). NOT REQUIRED - only present when status is 'failed' and a traceback was captured. null if: execution succeeded, is still in progress, or the failure predates traceback capture. Use for: debugging failed executions when error_message alone (e.g. a raw Ray internals string) is not actionable.","x-mixpeek-redacted":"driver_text"},"llm_labeling_errors":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Llm Labeling Errors","description":"OPTIONAL. List of errors encountered during LLM labeling. NOT REQUIRED - only present when LLM labeling was attempted and encountered errors. null if:   - LLM labeling was not enabled.   - LLM labeling succeeded for all clusters.   - Execution is still in progress. Each error is a JSON string containing:   - 'error': Human-readable error message.   - 'clusters': List of cluster IDs affected by this error. Common errors:   - 'LLM API timeout for 2 clusters' (network/API issues).   - 'OpenAI rate limit exceeded' (quota exhausted).   - 'Invalid model name: gpt-3.5' (config error).   - 'No representative documents for cluster cl_3' (empty cluster). Use for:   - Debugging why some clusters have fallback labels.   - Identifying LLM API issues without failing entire clustering.   - Warning users about partial labeling success.","examples":[["{\"error\": \"LLM API timeout\", \"clusters\": [\"cl_3\", \"cl_5\"]}","{\"error\": \"No representative documents\", \"clusters\": [\"cl_1\"]}"],["{\"error\": \"OpenAI rate limit exceeded\", \"clusters\": [\"cl_0\"]}"],null]},"source_documents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Source Documents","description":"OPTIONAL. Authoritative count of documents in the source collection(s) at cluster time — an INDEPENDENT Mongo count, not derived from the index/parquet path the clustering consumed. 'What SHOULD have clustered.' Compare with vectors_retrieved: a positive index_gap means the index could not serve some documents' vectors, so the result is computed on a biased sample."},"vectors_retrieved":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Vectors Retrieved","description":"OPTIONAL. Number of vectors the index actually SERVED into the clustering (parquet rows). Below source_documents ⇒ index gap (signature)."},"vectors_clustered":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Vectors Clustered","description":"OPTIONAL. Number of documents that left the algorithm with a cluster assignment. Below vectors_retrieved for an assign-every-point algorithm ⇒ a silent pipeline drop; for a noise-producing algorithm the gap is expected noise."},"index_gap":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Index Gap","description":"source_documents − vectors_retrieved (>0 = index gap)."},"pipeline_drop":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Pipeline Drop","description":"vectors_retrieved − vectors_clustered."},"input_reconciliation_ok":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Input Reconciliation Ok","description":"OPTIONAL. False when an UNEXPECTED input-count gap was detected (index gap, or a pipeline drop under an assign-every-point algorithm). Expected noise does not set this False."},"input_reconciliation_reasons":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Input Reconciliation Reasons","description":"Human-readable descriptions of any reconciliation gaps."},"pipeline_drop_expected_as_noise":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Pipeline Drop Expected As Noise","description":"OPTIONAL. True when the algorithm legitimately leaves points unassigned (HDBSCAN/DBSCAN/OPTICS/EVoC), so a positive pipeline_drop is expected noise rather than a silent drop."},"label_overrides":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Label Overrides","description":"OPTIONAL. User-applied cluster label renames for this run, keyed by cluster_id (e.g. {'cl_0': 'Gadget Reviews'}). Written via PATCH /v1/clusters/{cluster_id}/executions/{run_id}/labels and persisted on the execution record (per-run, since cluster_ids are per-run) — no re-execution required. When present, centroids[].label and the visualization endpoint's cluster_label fields are already remapped server-side; this map is returned so clients can distinguish user renames from LLM/auto labels. Omitted from the response entirely when no overrides exist (schema-additive).","examples":[{"cl_0":"Gadget Reviews"},null]},"run_name":{"anyOf":[{"type":"string","maxLength":120},{"type":"null"}],"title":"Run Name","description":"OPTIONAL. Human-friendly name for this execution run (e.g. 'July tuning baseline'), set via PATCH /v1/clusters/{cluster_id}/executions/{run_id}/name and persisted on the execution record — no re-execution required. Editable at any time; capped at 120 characters. Use it to tell runs apart in the run selector / execution history instead of raw run_ids. Omitted from the response entirely when the run was never named (schema-additive, same rule as label_overrides).","examples":["July tuning baseline",null]},"layout_stability_applied":{"anyOf":[{"type":"string","enum":["transform","aligned","none"]},{"type":"null"}],"title":"Layout Stability Applied","description":"OPTIONAL. What layout stabilization actually happened on this execution. 'transform' = coordinates were projected through the previous run's saved reducer (existing documents pixel-stable). 'aligned' = the fresh layout was registered onto the previous run's coordinates via a least-squares similarity transform over shared documents. 'none' = raw independent layout (stability disabled, first run, or a documented skip — see layout_stability_reason). Omitted for executions that predate (schema-additive).","examples":["aligned","transform","none",null]},"layout_stability_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Layout Stability Reason","description":"OPTIONAL. Human-readable explanation of layout_stability_applied — e.g. 'aligned to previous run on 412 shared documents' or 'only 3 shared documents with previous run (minimum 20)'. Omitted when absent (schema-additive).","examples":["aligned to previous run on 412 shared documents",null]},"generation_reap":{"anyOf":[{"items":{"$ref":"#/components/schemas/ClusterGenerationReap"},"type":"array"},{"type":"null"}],"title":"Generation Reap","description":"OPTIONAL. One record per output collection saying what this run did with the previous generation: deleted it, found nothing stale, or kept it (and why). Omitted for executions that predate the record (schema-additive)."},"mode":{"anyOf":[{"type":"string","enum":["full","assign","composite"]},{"type":"null"}],"title":"Mode","description":"OPTIONAL. How this execution ran: full, assign, or composite (a clustering of the centroids of earlier executions). Omitted for executions that predate the field."},"source_execution_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Source Execution Ids","description":"OPTIONAL. For a composite execution, the source executions (run_id) whose centroids it grouped. Omitted otherwise."},"composite_mapping":{"anyOf":[{"additionalProperties":{"items":{"$ref":"#/components/schemas/ClusterCompositeSource"},"type":"array"},"type":"object"},{"type":"null"}],"title":"Composite Mapping","description":"OPTIONAL. For a composite execution, each meta-cluster id mapped to the source centroids it holds. A meta-cluster's centroid is the unweighted mean of those source centroids. Omitted otherwise, and for composite executions that predate the field."}},"type":"object","required":["run_id","cluster_id","status","num_clusters","num_points","created_at"],"title":"ClusterExecutionResult","description":"Complete results from a single clustering execution.\n\nRepresents the outcome of running a clustering algorithm on a collection's documents.\nEach execution creates a snapshot of clustering results at a point in time, including\nthe clusters found, quality metrics, and semantic labels.\n\nUse Cases:\n    - Display clustering execution history in UI\n    - Compare clustering quality across multiple runs\n    - Track execution status for long-running jobs\n    - Debug failed clustering attempts\n    - View cluster summaries and labels for analysis\n\nWorkflow:\n    1. Create cluster configuration → POST /clusters\n    2. Execute clustering → POST /clusters/{id}/execute\n    3. Poll execution status → GET /clusters/{id}/executions\n    4. View execution history → POST /clusters/{id}/executions/list\n\nStatus Lifecycle:\n    pending → processing → completed (or failed)\n\nNote:\n    Execution results are immutable once completed. Re-running clustering\n    creates a new execution result with a new run_id.","examples":[{"centroids":[{"cluster_id":"cl_0","keywords":["product","review","quality"],"label":"Product Reviews","num_members":45,"summary":"Customer feedback about products"},{"cluster_id":"cl_1","keywords":["help","issue","support"],"label":"Support Tickets","num_members":35,"summary":"Technical support requests"},{"cluster_id":"cl_2","keywords":["feature","request","suggestion"],"label":"Feature Requests","num_members":20,"summary":"User feature suggestions"}],"cluster_id":"clust_ae3e28a429","completed_at":"2025-11-13T13:25:40.122000Z","created_at":"2025-11-13T13:20:40.122000Z","description":"Completed execution with excellent metrics","metrics":{"calinski_harabasz_score":1234.56,"davies_bouldin_index":0.42,"silhouette_score":0.85},"num_clusters":3,"num_points":100,"run_id":"run_a8e270953254754b","status":"completed"},{"cluster_id":"clust_xyz789","created_at":"2025-11-13T14:00:00.000000Z","description":"Execution in progress","num_clusters":0,"num_points":500,"run_id":"run_b3f58210ab","status":"processing"},{"cluster_id":"clust_abc123","completed_at":"2025-11-13T12:00:05.123000Z","created_at":"2025-11-13T12:00:00.000000Z","description":"Failed execution with error details","error_message":"Insufficient documents for clustering: need at least 2 documents, found 1","num_clusters":0,"num_points":1,"run_id":"run_xyz789","status":"failed"}]},"ClusterGenerationReap":{"properties":{"output_collection_id":{"type":"string","title":"Output Collection Id","description":"The output collection this record is about."},"decision":{"type":"string","enum":["deleted","nothing_stale","skipped_unconfirmed","skipped_unreadable","deleted_late","superseded"],"title":"Decision","description":"deleted: the stale prior points were removed. nothing_stale: the new generation rewrote every prior point. skipped_unconfirmed: the store had not durably confirmed the new generation inside the wait, so the prior generation was kept and recorded for a later sweep. deleted_late: that sweep removed them once the store confirmed the write. superseded: a newer run of the cluster completed first, so this record deleted nothing. skipped_unreadable: the prior generation could not be read, so nothing was deleted."},"pending":{"type":"boolean","title":"Pending","description":"True while a skipped reap waits for the store to confirm this run's write.","default":false},"partition_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Partition Key","description":"The run partition the generation belongs to."},"superseded_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Superseded By","description":"The newer run that superseded a pending reap."},"finished_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Finished At","description":"When a pending reap was finished or superseded."},"prior":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Prior","description":"Points of this cluster run's partition found before the write; null when unreadable."},"written":{"type":"integer","title":"Written","description":"Points this run wrote."},"stale":{"type":"integer","title":"Stale","description":"Prior points the write did not rewrite (candidates)."},"reaped":{"type":"integer","title":"Reaped","description":"Points deleted."},"wal_seq":{"type":"integer","title":"Wal Seq","description":"The write's highest store sequence, 0 when the store returned none.","default":0},"confirmed_seq":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Confirmed Seq","description":"The store's durable frontier when the run last read it; null when it could not answer."},"confirmed_unavailable_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Confirmed Unavailable Reason","description":"Why the durable frontier could not be read, when it could not. Null on every run that read it. Present because `skipped_unconfirmed` with a null `confirmed_seq` says WHAT happened and not why, and the cause is logged by the cluster driver, whose logs the job's own teardown deletes minutes after it finishes. That is the gap this record exists to close."}},"type":"object","required":["output_collection_id","decision","written","stale","reaped"],"title":"ClusterGenerationReap","description":"What the run did with the PREVIOUS generation of one output collection.\n\nA cluster run rewrites its generation (centroid and member documents) and\nthen deletes the prior generation's points it did not rewrite. That\ndelete is fail-closed: it runs only after the store has durably confirmed\nthe new generation, and only when the prior generation could be read. The\ndecision used to live in the Ray driver's log alone, which the job's own\nteardown removes minutes after it finishes, so a run that kept its old\ngeneration (a collection showing two sets of centroids) could not be\nexplained afterwards. This is the durable record."},"ClusterGroup":{"properties":{"cluster_id":{"type":"string","title":"Cluster Id","description":"Group identifier (e.g., 'cl_0')"},"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label","description":"Human-readable label"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary","description":"Group summary"},"keywords":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Keywords","description":"Semantic keywords"},"member_count":{"type":"integer","title":"Member Count","description":"Number of documents in this group"}},"type":"object","required":["cluster_id","member_count"],"title":"ClusterGroup","description":"A single cluster group."},"ClusterGroupsResponse":{"properties":{"cluster_id":{"type":"string","title":"Cluster Id"},"run_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Run Id"},"total_groups":{"type":"integer","title":"Total Groups"},"total_documents":{"type":"integer","title":"Total Documents"},"member_counts_stale":{"type":"boolean","title":"Member Counts Stale","description":"True when member documents were deleted after this run completed, so member_count counts some documents that no longer exist. Re-run the cluster for current counts.","default":false},"groups":{"items":{"$ref":"#/components/schemas/ClusterGroup"},"type":"array","title":"Groups"}},"type":"object","required":["cluster_id","total_groups","total_documents","groups"],"title":"ClusterGroupsResponse","description":"Response containing all groups for a cluster."},"ClusterListStats":{"properties":{"total_clusters":{"type":"integer","title":"Total Clusters","description":"Total number of clusters in the result","default":0},"total_documents":{"type":"integer","title":"Total Documents","description":"Total number of documents across all clusters","default":0},"avg_documents_per_cluster":{"type":"number","title":"Avg Documents Per Cluster","description":"Average number of documents per cluster","default":0.0},"clusters_by_status":{"additionalProperties":{"type":"integer"},"type":"object","title":"Clusters By Status","description":"Count of clusters grouped by status"}},"type":"object","title":"ClusterListStats","description":"Aggregate statistics for a list of clusters."},"ClusterMetadata":{"properties":{"cluster_id":{"type":"string","title":"Cluster Id","description":"Unique cluster job identifier"},"cluster_name":{"type":"string","title":"Cluster Name","description":"Human-readable cluster name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Cluster description"},"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace this cluster belongs to"},"input_collections":{"items":{"type":"string"},"type":"array","title":"Input Collections","description":"Source collection IDs that were clustered"},"source_cluster_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Source Cluster Ids","description":"Set on a composite cluster: the clusters whose run centroids it groups. Executing it without a mode runs mode 'composite' over the newest completed run of each source cluster, one per partition."},"source_bucket_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Source Bucket Ids","description":"Source bucket IDs that the input collections originated from. Enables bucket lineage tracking."},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","description":"Optional filters that were applied to pre-filter documents before clustering"},"cluster_type":{"type":"string","enum":["vector","attribute"],"title":"Cluster Type","description":"Type of clustering: vector (embedding-based) or attribute (metadata-based)"},"feature_uris":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Feature Uris","description":"Feature URIs that were clustered (mixpeek://{extractor}@{version}/{output}). Only for vector clustering."},"multi_feature_strategy":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Multi Feature Strategy","description":"Strategy used if multiple features (concatenate/independent/weighted). Only for vector clustering."},"learned_weights":{"anyOf":[{"additionalProperties":{"type":"number"},"type":"object"},{"type":"null"}],"title":"Learned Weights","description":"Automatically learned feature weights (when multi_feature_strategy='weighted'). Keys are feature URIs, values are learned weights. Only populated after clustering execution completes."},"learning_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Learning Quality Score","description":"Clustering quality score from weight learning (e.g., silhouette score). Only populated when multi_feature_strategy='weighted' and weights were learned."},"effective_feature_method":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Effective Feature Method","description":"Method for calculating cluster centroids (mean/median/medoid). Only for vector clustering."},"face_cluster_merge":{"anyOf":[{"$ref":"#/components/schemas/FaceClusterMergeConfig"},{"type":"null"}],"description":"Stored post-HDBSCAN face-identity merge config. Populated from `vector_config.face_cluster_merge` at cluster creation and replayed into `ClusteringConfig` on every execute. Only applies to vector clustering."},"sample_size":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Sample Size","description":"Stored per-execution document cap. Populated from `vector_config.sample_size` at cluster creation and replayed into `ClusteringConfig` on every `POST /v1/clusters/{id}/execute` so re-runs stay consistent with the original config. When None, the export is uncapped (bounded by the engine's 100,000 safety limit). Only applies to vector clustering."},"preprocessing_steps":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Preprocessing Steps","description":"Stored preprocessing steps from vector_config. Replayed into ClusteringConfig on every execute."},"hierarchical_vector":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Hierarchical Vector","description":"Whether recursive sub-clustering is enabled for vector clustering."},"max_hierarchy_depth":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Hierarchy Depth","description":"Maximum recursion depth for hierarchical sub-clustering."},"vis_n_components":{"anyOf":[{"type":"integer","enum":[2,3]},{"type":"null"}],"title":"Vis N Components","description":"Stored visualization dimensionality (2D or 3D). Replayed into ClusteringConfig on every execute as the default."},"layout_stability":{"anyOf":[{"type":"string","enum":["none","transform","align"]},{"type":"null"}],"title":"Layout Stability","description":"Stored layout-stability mode from vector_config.layout_stability. Replayed into ClusteringConfig on every execute. When unset, executions default to 'align' (keep the map stable across runs via post-hoc registration)."},"clustered_attributes":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Clustered Attributes","description":"Attribute field names that were clustered. Only for attribute clustering."},"hierarchical_grouping":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Hierarchical Grouping","description":"Whether hierarchical clustering was used. Only for attribute clustering."},"aggregation_method":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Aggregation Method","description":"Method for aggregating attributes (most_frequent/first/last). Only for attribute clustering."},"output_collection_ids":{"items":{"type":"string"},"type":"array","title":"Output Collection Ids","description":"Collection IDs where cluster documents are stored. Each holds one centroid document (is_centroid=true) per cluster and one member document (is_centroid=false) per clustered source document. A member carries cluster_id, cluster_label and source_document_id, the ID of the document you clustered, so filter on source_document_id to find a source document's cluster. For single output: list with one collection ID. For per-feature output: list with one collection ID per feature. With enrich_source_collection=true no output collection is created: this lists the source collections, and each source document carries its assignment as fields."},"output_collection_names":{"items":{"type":"string"},"type":"array","title":"Output Collection Names","description":"Names of output collections. Corresponds to output_collection_ids."},"algorithm":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Algorithm","description":"Clustering algorithm used (hdbscan, kmeans, attribute_based, etc.)"},"algorithm_params":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Algorithm Params","description":"Algorithm-specific parameters (not used for attribute_based)"},"enrich_source":{"type":"boolean","title":"Enrich Source","description":"Whether source documents were enriched with cluster_id","default":false},"source_enrichment_config":{"anyOf":[{"$ref":"#/components/schemas/SourceEnrichmentConfig"},{"type":"null"}],"description":"Configuration for source enrichment (if enrich_source=True)"},"llm_labeling":{"anyOf":[{"$ref":"#/components/schemas/LLMLabeling-Output"},{"type":"null"}],"description":"Configuration for LLM-based cluster labeling (applies to all cluster types)"},"num_clusters":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Num Clusters","description":"Number of clusters found (excludes noise/outliers, populated after execution)"},"num_documents_clustered":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Num Documents Clustered","description":"Total documents processed"},"execution_time_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Execution Time Seconds","description":"Time taken to complete clustering"},"quality_metrics":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Quality Metrics","description":"Clustering quality metrics (silhouette_score, davies_bouldin_score, calinski_harabasz_score, etc.). Open diagnostic bag like ClusteringResult.metrics: mostly numeric, but the three-state degenerate flag (False | reason string) and its prose degenerate_detail are non-numeric, so the value type is Any. A float-only type 400'd every GET on a cluster whose run flagged a degenerate result ('s read-path sibling: the write side persisted the string, this read side then rejected it)."},"hierarchy_detected":{"type":"boolean","title":"Hierarchy Detected","description":"Whether implicit hierarchy was detected (multi-feature independent) or created (hierarchical attributes)","default":false},"parent_cluster_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parent Cluster Id","description":"For child clusters in hierarchy"},"child_cluster_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Child Cluster Ids","description":"For parent clusters"},"hierarchy_relationships":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Hierarchy Relationships","description":"Parent-child relationships detected from cluster membership overlap"},"status":{"$ref":"#/components/schemas/TaskStatusEnum","description":"Cluster job status (propagated from TaskService)","default":"PENDING"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if cluster execution failed. Propagated from TaskService."},"failure_category":{"anyOf":[{"$ref":"#/components/schemas/FailureCategory"},{"type":"null"}],"description":"Machine-readable failure classification. Same enum as batch failure_category."},"last_execution_task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Execution Task Id","description":"Most recent task ID for this cluster"},"last_run_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Run Id","description":"Most recent execution run ID"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"When cluster was created"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"When cluster was last updated"},"last_executed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Executed At","description":"Last execution timestamp"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"When clustering completed successfully"},"llm_labeling_errors":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Llm Labeling Errors","description":"List of errors encountered during LLM labeling (if any). Stored in MongoDB cluster metadata only, NOT in vector store cluster documents. Used to track LLM failures while allowing fallback labels to work."},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Additional user-defined metadata"}},"type":"object","required":["cluster_name","namespace_id","input_collections","cluster_type"],"title":"ClusterMetadata","description":"Cluster job metadata stored in MongoDB clusters collection.\n\nThis is separate from cluster documents themselves. Tracks job-level\nconfiguration, status, and summary statistics.\n\nSupports both vector and attribute clustering with appropriate metadata."},"ClusterModel":{"properties":{"collection_ids":{"anyOf":[{"items":{"type":"string"},"type":"array","minItems":1},{"type":"null"}],"title":"Collection Ids","description":"Collections to cluster together"},"source_cluster_ids":{"anyOf":[{"items":{"type":"string"},"type":"array","minItems":1},{"type":"null"}],"title":"Source Cluster Ids","description":"Makes this a composite cluster: it groups the centroids of these clusters' runs instead of documents. Each id must be a vector cluster in this namespace with the same feature_uris as this one. Executing a composite cluster without a mode runs mode 'composite' over the newest completed run of each source cluster, one per partition (a partition is a run's filters). Vector clusters only."},"cluster_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cluster Name","description":"Optional human-friendly name for the clustering job"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Optional description of the cluster, stored with it"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Additional user-defined metadata for the cluster"},"cluster_type":{"$ref":"#/components/schemas/ClusterType","description":"Vector or attribute clustering","default":"vector"},"vector_config":{"anyOf":[{"$ref":"#/components/schemas/VectorBasedConfig-Output"},{"type":"null"}],"description":"Required when cluster_type is 'vector'"},"attribute_config":{"anyOf":[{"$ref":"#/components/schemas/AttributeBasedConfig"},{"type":"null"}],"description":"Required when cluster_type is 'attribute'"},"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Output"},{"type":"null"}],"description":"Optional filters to pre-filter documents before clustering (same format as list documents). Applied during the vector store scroll before parquet export. Useful for clustering subsets like: status='active', category='electronics', etc."},"llm_labeling":{"anyOf":[{"$ref":"#/components/schemas/LLMLabeling-Output"},{"type":"null"}],"description":"Optional configuration for LLM-based cluster labeling. When provided with enabled=True, clusters will have semantic labels generated by LLM instead of generic labels like 'Cluster 0'. When not provided or enabled=False, uses fallback labels."},"enrich_source_collection":{"type":"boolean","title":"Enrich Source Collection","description":"If True, cluster results are written back to source collection(s) in-place instead of creating new output collections. Documents will be enriched with cluster_id, cluster_label, distance_to_centroid, and optionally other metadata. Similar to taxonomy enrichment pattern.","default":false},"source_enrichment_config":{"anyOf":[{"$ref":"#/components/schemas/SourceEnrichmentConfig"},{"type":"null"}],"description":"Configuration for source collection enrichment (only used if enrich_source_collection=True). Controls which fields are added to source documents and field naming conventions."},"auto_execute_on_batch":{"type":"boolean","title":"Auto Execute On Batch","description":"Automatically execute this cluster whenever a batch completes on any of its input collections. When True, a ClusterApplicationConfig entry is added to each input collection's cluster_applications field at creation time. The cluster will then auto-trigger after each batch completion (subject to cooldown and document threshold). When False (default), the cluster must be executed manually via the API.","default":false},"auto_execute_min_documents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Auto Execute Min Documents","description":"Minimum number of documents required before auto-executing cluster. Only used when auto_execute_on_batch=True. If the collection has fewer documents than this threshold, clustering is skipped."},"auto_execute_cooldown_seconds":{"type":"integer","title":"Auto Execute Cooldown Seconds","description":"Minimum time (in seconds) between automatic cluster executions. Only used when auto_execute_on_batch=True. Default: 3600 (1 hour).","default":3600},"cluster_id":{"type":"string","title":"Cluster Id","description":"Unique cluster identifier"},"parquet_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parquet Path","description":"S3 path to parquet files with cluster data"},"members_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Members Key","description":"S3 key to members.parquet (if saved)"},"num_clusters":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Num Clusters","description":"Number of clusters found"},"cluster_stats":{"anyOf":[{"$ref":"#/components/schemas/ClusterStats"},{"type":"null"}],"description":"Clustering quality metrics"},"status":{"$ref":"#/components/schemas/TaskStatusEnum","description":"Clustering job status","default":"PENDING"},"task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id","description":"Associated task ID for clustering job"},"last_run_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Run Id","description":"Run ID of the most recent successful clustering execution. Used to retrieve execution results."},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"When the cluster was created"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"When the cluster was last updated"}},"type":"object","title":"ClusterModel","description":"Cluster metadata stored in MongoDB.","examples":[{"cluster_name":"products_clip_hdbscan","cluster_type":"vector","collection_ids":["col_products_v1","col_products_v2"],"llm_labeling":{"enabled":true,"labeling_inputs":{"input_mappings":[{"input_key":"text","path":"description","source_type":"payload"}]},"model_name":"gpt-4o-mini-2024-07-18","provider":"openai"},"vector_config":{"clustering_method":"hdbscan","feature_uri":"mixpeek://clip_vit_l_14@v1/embedding","hdbscan_parameters":{"min_cluster_size":10,"min_samples":5},"sample_size":5000}},{"cluster_name":"video_multimodal_clustering","cluster_type":"vector","collection_ids":["col_videos_v1"],"llm_labeling":{"enabled":true,"include_keywords":true,"include_summary":true,"labeling_inputs":{"input_mappings":[{"input_key":"text","path":"title","source_type":"payload"},{"input_key":"video_url","path":"video_url","source_type":"payload"}]},"model_name":"gemini-3.5-flash-lite","provider":"google"},"vector_config":{"clustering_method":"hdbscan","feature_uri":"mixpeek://clip_vit_l_14@v1/embedding","hdbscan_parameters":{"min_cluster_size":5,"min_samples":3},"sample_size":3000}},{"cluster_name":"image_multimodal_clustering","cluster_type":"vector","collection_ids":["col_images_v1"],"llm_labeling":{"enabled":true,"labeling_inputs":{"input_mappings":[{"input_key":"text","path":"caption","source_type":"payload"},{"input_key":"image_url","path":"image_url","source_type":"payload"}]},"model_name":"gemini-3.5-flash-lite","provider":"google"},"vector_config":{"clustering_method":"kmeans","feature_uri":"mixpeek://clip_vit_l_14@v1/embedding","kmeans_parameters":{"n_clusters":10},"sample_size":2000}},{"attribute_config":{"attributes":["status"],"hierarchical_grouping":true},"cluster_name":"orders_group_by_status","cluster_type":"attribute","collection_ids":["col_orders_v1","col_orders_v2","col_orders_v3"]}]},"ClusterOptions":{"properties":{"preserve_cluster_ids":{"type":"boolean","title":"Preserve Cluster Ids","description":"Keep same cluster IDs in target","default":true},"preserve_assignments":{"type":"boolean","title":"Preserve Assignments","description":"Keep cluster_id in documents","default":true},"migrate_artifacts":{"type":"boolean","title":"Migrate Artifacts","description":"Copy parquet artifacts from S3","default":true},"preserve_centroids":{"type":"boolean","title":"Preserve Centroids","description":"Keep centroid collections","default":true},"recompute_clusters":{"type":"boolean","title":"Recompute Clusters","description":"Recompute clusters instead of copying","default":false}},"type":"object","title":"ClusterOptions","description":"Options for cluster migration."},"ClusterRunSource":{"properties":{"cluster_id":{"type":"string","title":"Cluster Id","description":"The cluster that ran."},"run_id":{"type":"string","title":"Run Id","description":"The run to promote, exactly (GET /v1/clusters/{cluster_id}/executions lists them). A run's own artifact is read; no other run is substituted."}},"type":"object","required":["cluster_id","run_id"],"title":"ClusterRunSource","description":"A completed cluster run whose clusters become the taxonomy's nodes."},"ClusterStats":{"properties":{"num_clusters":{"type":"integer","title":"Num Clusters"},"noise_points":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Noise Points","description":"Number of noise points (for DBSCAN, etc.)"},"silhouette_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Silhouette Score","description":"Silhouette score (-1 to 1, higher is better)"},"extra":{"additionalProperties":true,"type":"object","title":"Extra"}},"type":"object","required":["num_clusters"],"title":"ClusterStats","description":"Basic clustering quality metrics."},"ClusterTime":{"properties":{"t":{"type":"integer","title":"T","description":"Mongo cluster time seconds component"},"i":{"type":"integer","title":"I","description":"Mongo cluster time increment component"}},"type":"object","required":["t","i"],"title":"ClusterTime"},"ClusterType":{"type":"string","enum":["vector","attribute"],"title":"ClusterType","description":"Type of clustering to perform.\n\nDetermines the clustering approach:\n- vector: Cluster documents by embedding similarity (semantic clustering)\n- attribute: Cluster documents by metadata attributes (business logic clustering)\n\nUse Cases:\n    vector:\n        - Group semantically similar content\n        - Find content with similar meaning\n        - Organize by topic/theme\n        - Requires vector embeddings\n\n    attribute:\n        - Group by business attributes (category, brand, status, etc.)\n        - Organize by explicit metadata\n        - Create hierarchical groupings\n        - No embeddings required"},"ClusteringAlgorithm":{"type":"string","enum":["kmeans","dbscan","hdbscan","agglomerative","spectral","gaussian_mixture","mean_shift","optics","leiden","evoc","attribute_based","auto"],"title":"ClusteringAlgorithm","description":"Supported clustering algorithms.\n\nTwo types of clustering are available:\n1. Vector-based: Clusters documents by embedding similarity\n2. Attribute-based: Clusters documents by metadata attributes\n\nVector-based algorithms (require feature_vector):\n    - kmeans: Partitions data into K clusters by minimizing within-cluster variance\n    - dbscan: Density-based clustering, finds clusters of arbitrary shape\n    - hdbscan: Hierarchical DBSCAN, auto-determines number of clusters\n    - agglomerative: Hierarchical clustering using linkage criteria\n    - spectral: Uses graph theory to find clusters\n    - gaussian_mixture: Probabilistic model assuming Gaussian distributions\n    - mean_shift: Finds clusters by locating density maxima\n    - optics: Ordering points to identify clustering structure\n    - leiden: Community detection on a kNN graph (fast at scale, auto cluster\n      count via resolution; skips the UMAP step that dominates KMeans)\n    - evoc: Embedding Vector Oriented Clustering (Tutte Institute) — built\n      for embeddings, discovers the cluster count automatically, less\n      parameter-sensitive than HDBSCAN and scales roughly linearly\n\nAttribute-based algorithm (requires attribute_config):\n    - attribute_based: Groups documents by metadata attributes (e.g., category, brand)"},"ColbertExtractorParams":{"properties":{"extractor_type":{"type":"string","const":"colbert_extractor","title":"Extractor Type","description":"Discriminator field for parameter type identification.","default":"colbert_extractor"},"split_by":{"$ref":"#/components/schemas/TextSplitStrategy","description":"Strategy for splitting text into multiple documents. ColBERT reads at most 512 tokens of each document, so long texts should be split.","default":"none"},"chunk_size":{"type":"integer","maximum":10000.0,"minimum":1.0,"title":"Chunk Size","description":"Target chunk size, counted in the split_by strategy's own unit.","default":300},"chunk_overlap":{"type":"integer","maximum":5000.0,"minimum":0.0,"title":"Chunk Overlap","description":"Overlap between consecutive chunks, in the same unit as chunk_size.","default":0}},"type":"object","title":"ColbertExtractorParams","description":"Parameters for the ColBERT extractor.","examples":[{"extractor_type":"colbert_extractor"},{"chunk_size":300,"extractor_type":"colbert_extractor","split_by":"words"}]},"CollectionDetail":{"properties":{"collection_id":{"type":"string","title":"Collection Id","description":"Collection identifier"},"collection_name":{"type":"string","title":"Collection Name","description":"Human-readable collection name"},"document_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Document Count","description":"Number of documents in the collection"},"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled","description":"Whether the collection is active"},"last_indexed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Indexed At","description":"When the collection was last indexed"}},"type":"object","required":["collection_id","collection_name"],"title":"CollectionDetail","description":"Detailed information about a collection referenced by a retriever."},"CollectionDiagnostic":{"properties":{"collection_id":{"type":"string","title":"Collection Id","description":"Collection ID"},"collection_name":{"type":"string","title":"Collection Name","description":"Collection name"},"document_count":{"type":"integer","title":"Document Count","description":"Number of documents in collection","default":0},"expected_documents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Expected Documents","description":"Expected document count"},"status":{"type":"string","title":"Status","description":"Collection status (ready, processing, empty)"}},"type":"object","required":["collection_id","collection_name","status"],"title":"CollectionDiagnostic","description":"Diagnostic information for a collection."},"CollectionDisabledReason":{"properties":{"code":{"type":"string","const":"source_collection_deleted","title":"Code","description":"Machine-readable cause. 'source_collection_deleted': the collection this one is sourced from (directly, or further upstream) was deleted, so this one can never run again. When a customer deleted it, this collection's documents were removed too; `message` says whether they were. A cluster's output collection is never disabled this way."},"message":{"type":"string","title":"Message","description":"The cause in plain words."},"source_collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Collection Id","description":"ID of the deleted collection."},"source_collection_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Collection Name","description":"Name the deleted collection had."},"disabled_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Disabled At","description":"When the platform disabled this collection."}},"type":"object","required":["code","message"],"title":"CollectionDisabledReason","description":"Why the platform disabled a collection, when it did."},"CollectionExportRequest":{"properties":{"format":{"$ref":"#/components/schemas/ExportFormat","description":"Export format: json (line-delimited), csv, or parquet (default).","default":"parquet"},"include_vectors":{"type":"boolean","title":"Include Vectors","description":"Whether to include vectors in the export. Vectors are exported to a separate file due to their large size. This significantly increases export time and file size.","default":false},"include_lineage":{"type":"boolean","title":"Include Lineage","description":"Add lineage columns to every row: lineage_chain (the processing steps from source object to document), source_content_hash (SHA-256 of the source content) and document_created_at (ISO 8601). Kept even when select_fields is set. In CSV and Parquet, lineage_chain is a JSON-encoded string.","default":false},"select_fields":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Select Fields","description":"Specific fields to include in the export. If not provided, all fields are exported. Supports dot notation for nested fields (e.g., 'metadata.title', 'metadata.author').","examples":[["document_id","metadata.title","metadata.category"]]},"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"Filter conditions to export only matching documents. Uses LogicalOperator format (AND/OR/NOT) same as document listing."},"sample_size":{"anyOf":[{"type":"integer","maximum":1000000.0,"minimum":1.0},{"type":"null"}],"title":"Sample Size","description":"Maximum number of documents to export. If not provided, exports all documents. Useful for testing exports or creating sample datasets."},"include_media":{"type":"boolean","title":"Include Media","description":"WebDataset only. Put the source object's bytes in each sample alongside its row, resolved through the document's root object. A document whose object is gone, or which never had one, ships with its row alone and is counted in the response's media summary. This moves the full media set, so expect a much larger export and a longer run.","default":false},"samples_per_shard":{"type":"integer","maximum":100000.0,"minimum":1.0,"title":"Samples Per Shard","description":"WebDataset only. Documents per tar shard. Smaller shards parallelize better across training workers; larger shards mean fewer files to move.","default":1000},"destination":{"anyOf":[{"$ref":"#/components/schemas/ExportDestination"},{"type":"null"}],"description":"Write the export into your own storage through a connection you own. The files and a manifest land under the prefix you give. The 7-day download copy is still written too, so the presigned URLs in the response keep working and nothing existing changes."}},"type":"object","title":"CollectionExportRequest","description":"Request model for exporting collection data.\n\n**Export Formats:**\n- **JSON**: Line-delimited JSON (JSONL) format, one document per line. Good for streaming and large files.\n- **CSV**: Comma-separated values. Best for tabular data analysis in spreadsheets.\n- **PARQUET**: Columnar format optimized for analytics. Best for large datasets and data pipelines.\n- **WEBDATASET**: Tar shards in the WebDataset layout, one sample per document.\n  Each sample carries `<key>.json` (the same row the other formats emit) and, with\n  `include_media=True`, the source object's bytes as `<key>.<ext>`. Read it with any\n  WebDataset loader. `samples_per_shard` sets the shard size.\n\n**Vector Export:**\nVectors are stored separately from document metadata due to their large size.\nWhen `include_vectors=True`, vectors are exported to a separate file with the naming convention:\n`{collection_name}_vectors.{format}`\n\n**Lineage:**\nWhen `include_lineage=True`, every row also carries `lineage_chain` (each processing\nstep from the source object to this document), `source_content_hash` (SHA-256 of the\nsource content) and `document_created_at` (ISO 8601). In JSON the chain is a list; in\nCSV and Parquet it is a JSON-encoded string so every row keeps one column type.\n\n**Field Selection:**\nUse `select_fields` to export only specific fields, reducing file size for large collections.\nSupports dot notation for nested fields (e.g., \"metadata.title\").\n\n**Filtering:**\nApply filters to export a subset of documents. Uses the same LogicalOperator format\nas the documents list endpoint."},"CollectionExportResponse":{"properties":{"download_url":{"type":"string","title":"Download Url","description":"Presigned URL for downloading the exported file. Valid for 1 hour."},"s3_path":{"type":"string","title":"S3 Path","description":"Full S3 path where the export is stored (for internal reference). For webdataset this is the prefix holding the shards, not a single file."},"format":{"$ref":"#/components/schemas/ExportFormat","description":"The format of the exported file."},"document_count":{"type":"integer","minimum":0.0,"title":"Document Count","description":"Number of documents included in the export."},"file_size_bytes":{"type":"integer","minimum":0.0,"title":"File Size Bytes","description":"Size of the exported file in bytes. For webdataset this is every shard added together."},"exported_at":{"type":"string","format":"date-time","title":"Exported At","description":"Timestamp when the export was completed."},"vectors_download_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vectors Download Url","description":"Presigned URL for downloading the vectors file (if include_vectors=True). Vectors are exported separately due to their large size."},"vectors_s3_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vectors S3 Path","description":"Full S3 path for the vectors file (if include_vectors=True)."},"shard_count":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Shard Count","description":"WebDataset only. Number of tar shards written. Always exact, even when the shards list below is capped."},"shard_pattern":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Shard Pattern","description":"WebDataset only. Brace pattern naming every shard, e.g. documents-{000000..000007}.tar. Most loaders take this directly."},"shards":{"anyOf":[{"items":{"$ref":"#/components/schemas/ExportShard"},"type":"array"},{"type":"null"}],"title":"Shards","description":"WebDataset only. Per-shard paths and presigned URLs, capped at 200 entries. When shard_count exceeds that, address the rest through s3_path and shard_pattern."},"media":{"anyOf":[{"$ref":"#/components/schemas/ExportMediaSummary"},{"type":"null"}],"description":"WebDataset only, present when include_media was set. Counts what media reached the shards and what did not."},"destination":{"anyOf":[{"$ref":"#/components/schemas/ExportDestinationResult"},{"type":"null"}],"description":"Present when the request named a destination. Lists what was written into your storage and where the manifest is."}},"type":"object","required":["download_url","s3_path","format","document_count","file_size_bytes","exported_at"],"title":"CollectionExportResponse","description":"Response model for collection export.\n\nContains the presigned URL for downloading the exported file.\nThe URL is valid for a limited time (typically 1 hour).","examples":[{"document_count":10000,"download_url":"https://s3.amazonaws.com/bucket/org_xxx/ns_xxx/api_collections_export/col_xxx/v1/documents.parquet?...","exported_at":"2024-01-15T10:30:00Z","file_size_bytes":5242880,"format":"parquet","s3_path":"s3://bucket/org_xxx/ns_xxx/api_collections_export/col_xxx/v1/documents.parquet"}]},"CollectionFeatureDescriptor":{"properties":{"feature_address":{"type":"string","title":"Feature Address","description":"Fully qualified feature address"},"feature_extractor_name":{"type":"string","title":"Feature Extractor Name","description":"Extractor name"},"version":{"type":"string","title":"Version","description":"Extractor version"},"vector_index":{"$ref":"#/components/schemas/VectorIndex","description":"Vector index configuration (name, dimensions, type, distance, inference_name)"},"primary":{"type":"boolean","title":"Primary","description":"True if this is the primary output (short address allowed)","default":false},"feature_uri":{"type":"string","title":"Feature Uri","description":"The feature's URI, the same string as feature_address. Requests take it under this name: feature_search's feature_uri, a cluster's feature_uri, and the key of a vector in a document upsert.","readOnly":true}},"type":"object","required":["feature_address","feature_extractor_name","version","vector_index","feature_uri"],"title":"CollectionFeatureDescriptor","description":"Descriptor for a collection's available feature using existing models/keys."},"CollectionListStats":{"properties":{"total_documents":{"type":"integer","title":"Total Documents","description":"Total number of documents across all collections","default":0},"avg_documents_per_collection":{"type":"number","title":"Avg Documents Per Collection","description":"Average number of documents per collection","default":0.0},"collections_with_taxonomies":{"type":"integer","title":"Collections With Taxonomies","description":"Number of collections with taxonomy applications","default":0},"total_feature_extractors":{"type":"integer","title":"Total Feature Extractors","description":"Total number of feature extractors across all collections","default":0},"total_taxonomies":{"type":"integer","title":"Total Taxonomies","description":"Total number of taxonomy connections across all collections","default":0},"total_retrievers":{"type":"integer","title":"Total Retrievers","description":"Total number of retriever connections across all collections","default":0}},"type":"object","title":"CollectionListStats","description":"Aggregate statistics for a list of collections."},"CollectionModel":{"properties":{"collection_id":{"type":"string","title":"Collection Id","description":"NOT REQUIRED (auto-generated). Unique identifier for this collection. Used for: API paths, document queries, pipeline references. Format: 'col_' prefix + 10 random alphanumeric characters. Stable after creation - use for all collection references.","examples":["col_a1b2c3d4e5","col_xyz789abc","col_video_frames"]},"collection_name":{"type":"string","maxLength":100,"minLength":3,"title":"Collection Name","description":"REQUIRED. Human-readable name for the collection. Must be unique within the namespace. Used for: Display, lookups (can query by name or ID), organization. Format: Alphanumeric with underscores/hyphens, 3-100 characters. Examples: 'product_embeddings', 'video_frames', 'customer_documents'.","examples":["video_frames","product_embeddings","customer_documents"]},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"NOT REQUIRED. Human-readable description of the collection's purpose. Use for: Documentation, team communication, UI display. Common pattern: Describe what the collection contains and what processing is applied.","examples":["Video frames extracted at 1 FPS with CLIP embeddings","Product catalog with image embeddings and metadata"]},"input_schema":{"anyOf":[{"$ref":"#/components/schemas/BucketSchema-Output"},{"type":"null"}],"description":"Auto-computed from source. Input schema defining fields available to the feature extractor. Source: bucket.bucket_schema (if source.type='bucket') OR upstream_collection.output_schema (if source.type='collection'). Determines: Which fields can be used in input_mappings and field_passthrough. This is the 'left side' of the transformation - what data goes IN. Format: BucketSchema with properties dict. Use for: Validating input_mappings, configuring field_passthrough.","examples":[{"properties":{"title":{"type":"string"},"content":{"type":"text"}}},{"properties":{"video":{"type":"video"},"campaign_id":{"type":"string"}}}]},"output_schema":{"anyOf":[{"$ref":"#/components/schemas/BucketSchema-Output"},{"type":"null"}],"description":"Auto-computed at creation. Output schema defining fields in final documents. Computed as: field_passthrough fields + extractor output fields (deterministic). Known IMMEDIATELY when collection is created - no waiting for documents! This is the 'right side' of the transformation - what data comes OUT. Use for: Understanding document structure, building queries, schema validation. Example: {title (passthrough), embedding (extractor output)} = output_schema.","examples":[{"properties":{"title":{"type":"string"},"text_extractor_v1_embedding":{"type":"array"}}},{"properties":{"campaign_id":{"type":"string"},"multimodal_extractor_v1_embedding":{"type":"array"}}}]},"feature_extractor":{"$ref":"#/components/schemas/shared__collection__features__extractors__models__FeatureExtractorConfig-Output","description":"REQUIRED. Single feature extractor configuration for this collection. For a transform-based collection (retriever_transform set) this is a placeholder sentinel; the retriever_transform defines the actual build. Defines: extractor name/version, input_mappings, field_passthrough, parameters. Task 9 change: ONE extractor per collection (previously supported multiple). For multiple extractors: Create multiple collections and use collection-to-collection pipelines. Use field_passthrough to include additional source fields beyond extractor outputs.","examples":[{"feature_extractor_name":"text_extractor","field_passthrough":[{"source_path":"title"}],"input_mappings":{"text":"content"},"version":"v1"}]},"source":{"$ref":"#/components/schemas/SourceConfig-Output","description":"REQUIRED. Source configuration defining where data comes from. Type 'bucket': Process objects from one or more buckets (tier 1). Type 'collection': Process documents from upstream collection(s) (tier 2+). For multi-bucket sources, all buckets must have compatible schemas. For multi-collection sources, all collections must have compatible schemas. Determines input_schema and enables decomposition trees.","examples":[{"bucket_ids":["bkt_articles"],"type":"bucket"},{"bucket_ids":["bkt_us_products","bkt_eu_products"],"type":"bucket"},{"collection_id":"col_video_frames","type":"collection"},{"collection_ids":["col_products_2023","col_products_2024"],"type":"collection"}]},"source_bucket_schemas":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/BucketSchema-Output"},"type":"object"},{"type":"null"}],"title":"Source Bucket Schemas","description":"NOT REQUIRED (auto-computed). Snapshot of bucket schemas at collection creation. Only populated for multi-bucket collections (source.type='bucket' with multiple bucket_ids). Key: bucket_id, Value: BucketSchema at time of collection creation. Used for: Schema compatibility validation, document lineage, debugging. Schema snapshot is immutable - bucket schema changes after collection creation do not affect this. Single-bucket collections may omit this field (schema in input_schema is sufficient).","examples":[null,{"bkt_eu_products":{"properties":{"image":{"type":"image"},"title":{"type":"string"},"price":{"type":"number"}},"required":["image","title"]},"bkt_us_products":{"properties":{"image":{"type":"image"},"title":{"type":"string"},"price":{"type":"number"}},"required":["image","title"]}}]},"source_lineage":{"items":{"$ref":"#/components/schemas/SingleLineageEntry"},"type":"array","title":"Source Lineage","description":"NOT REQUIRED (auto-computed). Lineage chain showing complete processing history. Each entry contains: source_config, feature_extractor, output_schema for one tier. Length indicates processing depth (1 = tier 1, 2 = tier 2, etc.). Use for: Understanding multi-tier pipelines, visualizing decomposition trees.","examples":[[],[{"output_schema":{},"source_config":{"bucket_id":"bkt_videos","type":"bucket"}}]]},"index_map":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Index Map","description":"Which feature URI answers each URI a search names, for a collection that opted into feature URIs as its version contract. Null (the default) means not opted in: a search uses the URI it names. Each key is one of the collection's own feature URIs; each value is a URI the collection holds vectors for, listed in `vector_indexes` (its own, or one a completed `reembed.target_feature_uri` added). Switching to a new embedding model and rolling back are both PATCH /v1/collections/{collection_id} with a new map; neither rewrites a vector. Every search result reports the URI that scored it in `feature_uri`.","examples":[{"mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1":"mixpeek://text_extractor@v1/all_minilm_l6_v2_v1"}]},"vector_indexes":{"items":{"properties":{"name":{"type":"string","description":"User-facing index name."},"feature_uri":{"type":["string","null"],"description":"mixpeek:// feature URI on extractor-backed collections; the bare index name on BYO indexes."},"type":{"type":["string","null"],"description":"single or multi."},"index":{"type":["object","null"],"description":"Nested index config: name (storage name), dimensions, distance, inference_name."},"source":{"type":["string","null"],"enum":["namespace_vector_config",null],"description":"'namespace_vector_config' when the entry was synthesized from a promoted/direct-upsert namespace vector config; absent for extractor-derived indexes."}},"additionalProperties":true,"type":"object","title":"CollectionVectorIndex","description":"One vector index exposed on a collection. Shape is stable for the fields below; additional keys may appear."},"type":"array","title":"Vector Indexes","description":"NOT REQUIRED (auto-computed). Vector indexes for semantic search. Populated from feature_extractor.required_vector_indexes on extractor-backed collections, and from the namespace vector config on promoted or direct-upsert (BYO) collections, where each entry carries source='namespace_vector_config'. Defines which embeddings are indexed, their dimensions and distance metric. Use for understanding search capabilities and debugging vector queries. An entry's `source` distinguishes a namespace-declared index from an extractor-derived one; extractor-derived entries omit it. The nested `index` object carries the storage name, dimensions, distance and inference_name.","examples":[[],[{"feature_uri":"emb","index":{"dimensions":3072,"distance":"cosine","inference_name":"text-embedding-3-large","name":"emb"},"name":"emb","source":"namespace_vector_config","type":"single"}]]},"payload_indexes":{"items":{},"type":"array","title":"Payload Indexes","description":"NOT REQUIRED (auto-computed from extractor + namespace). Payload indexes for filtering. Enables efficient filtering on metadata fields, timestamps, IDs. Populated from: extractor requirements + namespace defaults. Use for: Understanding which fields support fast filtering.","examples":[[],[{"field_name":"collection_id","type":"keyword"}]]},"embedding_task":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Embedding Task","description":"Override the embedding task hint for instruction-aware models (E5, Gemini). Defaults to 'retrieval_document' for indexing pipelines. Values: retrieval_document, retrieval_query, semantic_similarity, classification, clustering. Applied to all task-aware embedding models in this collection's extractor pipeline."},"enabled":{"type":"boolean","title":"Enabled","description":"NOT REQUIRED (defaults to True). Whether the collection accepts new documents. False: Collection exists but won't process new objects. True: Active and processing. Use for: Temporarily disabling collections without deletion.","default":true,"examples":[true,false]},"disabled_reason":{"anyOf":[{"$ref":"#/components/schemas/CollectionDisabledReason"},{"type":"null"}],"description":"Set when the platform disabled this collection, saying why; null when it is enabled or was disabled by a caller. A collection whose source collection was deleted reads code 'source_collection_deleted' with the deleted collection's id and name. Cleared when the collection is enabled again."},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"NOT REQUIRED. Additional user-defined metadata for the collection. Arbitrary key-value pairs for custom organization, tracking, configuration. Not used by the platform - purely for user purposes. Common uses: team ownership, project tags, deployment environment.","examples":[{"environment":"production","project":"Q4_campaign","team":"data-science"},null]},"schedule":{"anyOf":[{"$ref":"#/components/schemas/CollectionScheduleConfig"},{"type":"null"}],"description":"NOT REQUIRED. Schedule configuration for automatic re-processing. When set, a COLLECTION_TRIGGER trigger is created and linked to this collection."},"trigger_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trigger Id","description":"NOT REQUIRED. ID of the linked trigger for scheduled re-processing. Automatically set when a schedule is configured."},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"Timestamp when the collection was created. Automatically set by the system when the collection is first saved to the database."},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"Timestamp when the collection was last updated. Automatically updated by the system whenever the collection is modified."},"lifecycle_state":{"type":"string","title":"Lifecycle State","description":"Storage lifecycle state: 'active' (vector store + S3), 'cold' (S3 only), 'archived' (metadata only). Managed via lifecycle API.","default":"active"},"s3_vector_index":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"S3 Vector Index","description":"S3 Vectors index name for this collection (e.g. 'col_{collection_id}')."},"last_lifecycle_transition":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Lifecycle Transition","description":"Timestamp of the most recent lifecycle state change."},"tiering_rules":{"anyOf":[{"items":{"$ref":"#/components/schemas/TieringRule"},"type":"array"},{"type":"null"}],"title":"Tiering Rules","description":"Retired: stored and never enforced. Writes are refused; set `tiering` instead. Kept on reads so existing records still parse."},"tiering":{"anyOf":[{"$ref":"#/components/schemas/TieringOverride"},{"type":"null"}],"description":"This collection's override of the platform's collection tiering: `enabled`, `idle_days` ({cold, frozen}) and `exempt` with the reason. Unset parts inherit from the namespace, then from the platform default."},"document_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Document Count","description":"APPROXIMATE number of documents in the collection. This is NOT a stored counter maintained on every write — read endpoints DERIVE it from a live MVS count that is cached (~45s) and approximate (exact=False), so it can differ by a few from an exact documents/list enumeration and can lag very recent writes by the cache window. Use it for sorting/filtering and rough display; for an authoritative count, enumerate via documents/list. Do NOT treat a small document_count-vs-documents gap as row loss.","default":0,"examples":[0,100,50000]},"schema_version":{"type":"integer","title":"Schema Version","description":"Version number for the output_schema. Increments automatically when schema is updated via document sampling. Used to track schema evolution and trigger downstream collection schema updates.","default":1},"last_schema_sync":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Schema Sync","description":"Timestamp of last automatic schema sync from document sampling. Used to debounce schema updates (prevents thrashing)."},"schema_sync_enabled":{"type":"boolean","title":"Schema Sync Enabled","description":"Whether automatic schema discovery and sync is enabled for this collection. When True, schema is periodically updated by sampling documents. When False, schema remains fixed at creation time.","default":true},"document_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Document Schema","description":"NOT REQUIRED. JSON Schema for validating documents on create/update. When set with schema_validation='strict', non-conforming documents are rejected (422). When set with schema_validation='warn', violations are recorded but document is accepted. Schema follows JSON Schema draft-07 format. Only validates user-defined fields (system fields like _internal, collection_id, document_id are excluded from validation).","examples":[null,{"additionalProperties":true,"properties":{"title":{"maxLength":200,"type":"string"},"price":{"minimum":0,"type":"number"},"status":{"enum":["active","draft","archived"],"type":"string"}},"required":["title","price"],"type":"object"}]},"schema_validation":{"type":"string","enum":["strict","warn","off"],"title":"Schema Validation","description":"Document schema validation mode. 'strict': reject non-conforming documents with 422. 'warn': accept but attach _schema_violations field to the document. 'off': no validation (default, preserves current behavior).","default":"off","examples":["off","strict","warn"]},"taxonomy_applications":{"anyOf":[{"items":{"$ref":"#/components/schemas/TaxonomyApplicationConfig-Output"},"type":"array"},{"type":"null"}],"title":"Taxonomy Applications","description":"NOT REQUIRED. List of taxonomies to apply to documents in this collection. Each entry specifies: taxonomy_id, optional target_collection_id, optional filters. Enrichments are materialized (persisted to documents) during ingestion. Empty/null if no taxonomies attached. Use for: Categorization, hierarchical classification.","examples":[null,[{"execution_mode":"materialize","taxonomy_id":"tax_categories"},{"execution_mode":"materialize","taxonomy_id":"tax_brands"}]]},"cluster_applications":{"anyOf":[{"items":{"$ref":"#/components/schemas/ClusterApplicationConfig"},"type":"array"},{"type":"null"}],"title":"Cluster Applications","description":"NOT REQUIRED. List of clusters to automatically execute when batch processing completes. Each entry specifies: cluster_id, auto_execute_on_batch, min_document_threshold, cooldown_seconds. Clusters enrich source documents with cluster assignments (cluster_id, cluster_label, etc.). Empty/null if no clusters attached. Use for: Segmentation, grouping, pattern discovery.","examples":[null,[{"auto_execute_on_batch":true,"cluster_id":"clust_product_categories","cooldown_seconds":3600,"min_document_threshold":100}]]},"alert_applications":{"anyOf":[{"items":{"$ref":"#/components/schemas/AlertApplicationConfig-Output"},"type":"array"},{"type":"null"}],"title":"Alert Applications","description":"NOT REQUIRED. List of alerts to automatically execute when documents are ingested. Each entry specifies: alert_id, execution_mode, input_mappings, execution_phase, priority. Alerts run retrievers on ingested documents and send notifications when matches are found. Empty/null if no alerts attached. Use for: Content monitoring, safety detection, compliance alerts.","examples":[null,[{"alert_id":"alt_safety_001","execution_mode":"on_ingest","execution_phase":3,"input_mappings":[{"input_key":"query_embedding","source":{"path":"features.video_embedding","source_type":"document_field"}}],"priority":100}]]},"retriever_enrichments":{"anyOf":[{"items":{"$ref":"#/components/schemas/RetrieverEnrichmentConfig-Output"},"type":"array"},{"type":"null"}],"title":"Retriever Enrichments","description":"NOT REQUIRED. List of retriever enrichments to run on documents during post-processing. Each entry specifies: retriever_id, input_mappings, write_back_fields, execution_phase, priority. Retriever enrichments execute a retriever pipeline and write selected result fields back to documents. Empty/null if no enrichments attached. Use for: LLM classification, cross-collection joins, enrichment.","examples":[null,[{"execution_phase":4,"input_mappings":[{"input_key":"query","source":{"path":"title","source_type":"document_field"}}],"priority":0,"retriever_id":"ret_classifier_001","write_back_fields":[{"mode":"first","source_field":"category","target_field":"_enrichment_category"}]}]]},"retriever_transform":{"anyOf":[{"$ref":"#/components/schemas/RetrieverTransformConfig-Output"},{"type":"null"}],"description":"NOT REQUIRED. Set for a transform-based collection: the inline retriever pipeline (over an upstream collection) that defines this collection's documents. Mutually exclusive with feature_extractor. None for extractor-based collections."}},"type":"object","required":["collection_name","feature_extractor","source"],"title":"CollectionModel","description":"Collection model with single feature extractor and deterministic schema.\n\nCollections are processing pipelines that transform source data (from buckets or\nother collections) into searchable documents with features. Each collection\nrepresents ONE transformation step with ONE feature extractor.\n\nKey Concepts:\n    - Input Schema: What goes IN (from bucket or upstream collection)\n    - Feature Extractor: The transformation logic (text embedding, video processing, etc.)\n    - Field Passthrough: User-selected source fields to include in output\n    - Output Schema: What comes OUT (field_passthrough + extractor outputs)\n\nArchitecture (Task 9):\n    - ONE feature extractor per collection (not a list)\n    - output_schema computed at creation time (deterministic, no waiting)\n    - Multiple extractors = multiple collections\n    - Enables clean decomposition trees and clear lineage\n\nUse Cases:\n    - Create embeddings from text/images/video\n    - Build multi-tier pipelines (bucket → frames → scenes)\n    - Apply feature extraction with metadata passthrough\n    - Organize data processing into clear stages\n\nRequirements:\n    - collection_name: REQUIRED, unique within namespace\n    - source: REQUIRED, bucket or collection source\n    - feature_extractor: REQUIRED, single extractor configuration\n    - input_schema: Auto-computed from source (bucket_schema or upstream output_schema)\n    - output_schema: Auto-computed at creation (field_passthrough + extractor output)","examples":[{"collection_id":"col_a1b2c3d4e5","collection_name":"article_embeddings","description":"Simple text collection: News articles with text embeddings from bucket source","enabled":true,"feature_extractor":{"feature_extractor_name":"text_extractor","field_passthrough":[{"source_path":"title"}],"input_mappings":{"text":"content"},"version":"v1"},"input_schema":{"properties":{"title":{"type":"string"},"content":{"type":"text"}}},"output_schema":{"properties":{"title":{"type":"string"},"text_extractor_v1_embedding":{"type":"array"}}},"source":{"bucket_id":"bkt_articles","type":"bucket"}},{"collection_id":"col_xyz789abc","collection_name":"video_frames","description":"Video frames: Extracted at 1 FPS with CLIP embeddings and campaign_id passthrough","enabled":true,"feature_extractor":{"feature_extractor_name":"multimodal_extractor","field_passthrough":[{"source_path":"campaign_id"}],"input_mappings":{"video":"video"},"parameters":{"fps":1},"version":"v1"},"input_schema":{"properties":{"video":{"type":"video"},"campaign_id":{"type":"string"}}},"output_schema":{"properties":{"campaign_id":{"type":"string"},"multimodal_extractor_v1_embedding":{"type":"array"}}},"source":{"bucket_id":"bkt_marketing_videos","type":"bucket"}},{"collection_id":"col_scenes_def","collection_name":"detected_scenes","description":"Tier 2 decomposition: Scenes detected from frame embeddings (collection source)","enabled":true,"feature_extractor":{"feature_extractor_name":"scene_extractor","field_passthrough":[{"source_path":"campaign_id"}],"input_mappings":{"embedding":"multimodal_extractor_v1_embedding"},"version":"v1"},"input_schema":{"properties":{"campaign_id":{"type":"string"},"multimodal_extractor_v1_embedding":{"type":"array"}}},"output_schema":{"properties":{"campaign_id":{"type":"string"},"scene_extractor_v1_embedding":{"type":"array"}}},"source":{"collection_id":"col_video_frames","type":"collection"}}]},"CollectionOverviewResponse":{"properties":{"collection_id":{"type":"string","title":"Collection Id"},"collection_name":{"type":"string","title":"Collection Name"},"total_documents":{"type":"integer","title":"Total Documents"},"documents_last_24h":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Documents Last 24H","description":"Documents created in the last 24h. None means NOT YET COMPUTED here, which is different from zero: no faithful per-window document-created count is reachable from this service. A created_at range filter on the vector store silently matches nothing (the shard range compares numerics and created_at is an ISO-8601 string), and the analytics growth series counts distinct source objects rather than documents created."},"documents_last_7d":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Documents Last 7D","description":"Documents created in the last 7d. None means NOT YET COMPUTED here, which is different from zero; see documents_last_24h for why no faithful source is wired."},"avg_processing_time_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Processing Time Ms","description":"Mean extraction latency (ms) over the recent window, from the analytics store. None means NOT YET COMPUTED here, which is different from zero: the window held no timed events, or the analytics store was unavailable."},"success_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Success Rate","description":"Object to document conservation ratio (produced object count / source object count) from reconciliation. None means NOT YET COMPUTED here, which is different from 1.0: the collection has no source objects to conserve (a non-bucket source, or nothing ingested yet)."},"active_taxonomies":{"type":"integer","title":"Active Taxonomies"},"active_clusters":{"type":"integer","title":"Active Clusters"},"last_indexed":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Indexed","description":"When the collection was last updated or indexed (collection updated_at). None when the collection record carries no update timestamp."}},"type":"object","required":["collection_id","collection_name","total_documents","active_taxonomies","active_clusters"],"title":"CollectionOverviewResponse","description":"Collection overview metrics.\n\nHonesty contract: every field is computed from a real\nsource. A field whose source is not reachable from the analytics service is\nOptional and returned as None, meaning \"not yet computed here\", never a\nfabricated 0 or 1.0."},"CollectionReadiness":{"properties":{"collection":{"type":"string","title":"Collection","description":"Collection name from the manifest"},"feature_extractor":{"type":"string","title":"Feature Extractor","description":"Registry extractor id the collection runs, e.g. text_extractor_v1"},"realtime_available":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Realtime Available","description":"true when every Serve app below is RUNNING, false when one is absent or not RUNNING, null when the live Serve list could not be read"},"serve_apps":{"items":{"$ref":"#/components/schemas/ServeAppStatus"},"type":"array","title":"Serve Apps","description":"Each Ray Serve application the extractor needs, with its status"}},"type":"object","required":["collection","feature_extractor"],"title":"CollectionReadiness","description":"Whether one collection's real-time inference is served after apply."},"CollectionReconciliationResponse":{"properties":{"collection_id":{"type":"string","title":"Collection Id"},"source_object_count":{"type":"integer","title":"Source Object Count","description":"Distinct source objects submitted to this collection."},"produced_object_count":{"type":"integer","title":"Produced Object Count","description":"Distinct source objects that produced >=1 document."},"document_count":{"type":"integer","title":"Document Count","description":"Documents this collection has produced."},"delta":{"type":"integer","title":"Delta","description":"source_object_count - produced_object_count: source objects that produced no document. 0 means conservation holds."},"discrepancies":{"items":{"$ref":"#/components/schemas/ReconciliationDiscrepancy"},"type":"array","title":"Discrepancies","description":"Itemized objects that produced no document, up to `limit`."},"discrepancies_truncated":{"type":"boolean","title":"Discrepancies Truncated","description":"True when more discrepancies exist than `limit` returned.","default":false},"limit":{"type":"integer","title":"Limit","description":"The cap applied to `discrepancies`."}},"type":"object","required":["collection_id","source_object_count","produced_object_count","document_count","delta","limit"],"title":"CollectionReconciliationResponse","description":"Objects-vs-documents conservation for one collection.\n\n``delta`` is the headline conservation number (source objects that produced\nno document). ``discrepancies`` is a bounded, itemized sample of those\nobjects; ``discrepancies_truncated`` says whether more exist beyond\n``limit`` so the caller never mistakes the sample for the whole."},"CollectionResponse":{"properties":{"collection_id":{"type":"string","title":"Collection Id","description":"NOT REQUIRED (auto-generated). Unique identifier for this collection. Used for: API paths, document queries, pipeline references. Format: 'col_' prefix + 10 random alphanumeric characters. Stable after creation - use for all collection references.","examples":["col_a1b2c3d4e5","col_xyz789abc","col_video_frames"]},"collection_name":{"type":"string","maxLength":100,"minLength":3,"title":"Collection Name","description":"REQUIRED. Human-readable name for the collection. Must be unique within the namespace. Used for: Display, lookups (can query by name or ID), organization. Format: Alphanumeric with underscores/hyphens, 3-100 characters. Examples: 'product_embeddings', 'video_frames', 'customer_documents'.","examples":["video_frames","product_embeddings","customer_documents"]},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"NOT REQUIRED. Human-readable description of the collection's purpose. Use for: Documentation, team communication, UI display. Common pattern: Describe what the collection contains and what processing is applied.","examples":["Video frames extracted at 1 FPS with CLIP embeddings","Product catalog with image embeddings and metadata"]},"input_schema":{"anyOf":[{"$ref":"#/components/schemas/BucketSchema-Output"},{"type":"null"}],"description":"Auto-computed from source. Input schema defining fields available to the feature extractor. Source: bucket.bucket_schema (if source.type='bucket') OR upstream_collection.output_schema (if source.type='collection'). Determines: Which fields can be used in input_mappings and field_passthrough. This is the 'left side' of the transformation - what data goes IN. Format: BucketSchema with properties dict. Use for: Validating input_mappings, configuring field_passthrough.","examples":[{"properties":{"title":{"type":"string"},"content":{"type":"text"}}},{"properties":{"video":{"type":"video"},"campaign_id":{"type":"string"}}}]},"output_schema":{"anyOf":[{"$ref":"#/components/schemas/BucketSchema-Output"},{"type":"null"}],"description":"Auto-computed at creation. Output schema defining fields in final documents. Computed as: field_passthrough fields + extractor output fields (deterministic). Known IMMEDIATELY when collection is created - no waiting for documents! This is the 'right side' of the transformation - what data comes OUT. Use for: Understanding document structure, building queries, schema validation. Example: {title (passthrough), embedding (extractor output)} = output_schema.","examples":[{"properties":{"title":{"type":"string"},"text_extractor_v1_embedding":{"type":"array"}}},{"properties":{"campaign_id":{"type":"string"},"multimodal_extractor_v1_embedding":{"type":"array"}}}]},"feature_extractor":{"$ref":"#/components/schemas/shared__collection__features__extractors__models__FeatureExtractorConfig-Output","description":"REQUIRED. Single feature extractor configuration for this collection. For a transform-based collection (retriever_transform set) this is a placeholder sentinel; the retriever_transform defines the actual build. Defines: extractor name/version, input_mappings, field_passthrough, parameters. Task 9 change: ONE extractor per collection (previously supported multiple). For multiple extractors: Create multiple collections and use collection-to-collection pipelines. Use field_passthrough to include additional source fields beyond extractor outputs.","examples":[{"feature_extractor_name":"text_extractor","field_passthrough":[{"source_path":"title"}],"input_mappings":{"text":"content"},"version":"v1"}]},"source":{"$ref":"#/components/schemas/SourceConfig-Output","description":"REQUIRED. Source configuration defining where data comes from. Type 'bucket': Process objects from one or more buckets (tier 1). Type 'collection': Process documents from upstream collection(s) (tier 2+). For multi-bucket sources, all buckets must have compatible schemas. For multi-collection sources, all collections must have compatible schemas. Determines input_schema and enables decomposition trees.","examples":[{"bucket_ids":["bkt_articles"],"type":"bucket"},{"bucket_ids":["bkt_us_products","bkt_eu_products"],"type":"bucket"},{"collection_id":"col_video_frames","type":"collection"},{"collection_ids":["col_products_2023","col_products_2024"],"type":"collection"}]},"source_bucket_schemas":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/BucketSchema-Output"},"type":"object"},{"type":"null"}],"title":"Source Bucket Schemas","description":"NOT REQUIRED (auto-computed). Snapshot of bucket schemas at collection creation. Only populated for multi-bucket collections (source.type='bucket' with multiple bucket_ids). Key: bucket_id, Value: BucketSchema at time of collection creation. Used for: Schema compatibility validation, document lineage, debugging. Schema snapshot is immutable - bucket schema changes after collection creation do not affect this. Single-bucket collections may omit this field (schema in input_schema is sufficient).","examples":[null,{"bkt_eu_products":{"properties":{"image":{"type":"image"},"title":{"type":"string"},"price":{"type":"number"}},"required":["image","title"]},"bkt_us_products":{"properties":{"image":{"type":"image"},"title":{"type":"string"},"price":{"type":"number"}},"required":["image","title"]}}]},"source_lineage":{"items":{"$ref":"#/components/schemas/SingleLineageEntry"},"type":"array","title":"Source Lineage","description":"NOT REQUIRED (auto-computed). Lineage chain showing complete processing history. Each entry contains: source_config, feature_extractor, output_schema for one tier. Length indicates processing depth (1 = tier 1, 2 = tier 2, etc.). Use for: Understanding multi-tier pipelines, visualizing decomposition trees.","examples":[[],[{"output_schema":{},"source_config":{"bucket_id":"bkt_videos","type":"bucket"}}]]},"index_map":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Index Map","description":"Which feature URI answers each URI a search names, for a collection that opted into feature URIs as its version contract. Null (the default) means not opted in: a search uses the URI it names. Each key is one of the collection's own feature URIs; each value is a URI the collection holds vectors for, listed in `vector_indexes` (its own, or one a completed `reembed.target_feature_uri` added). Switching to a new embedding model and rolling back are both PATCH /v1/collections/{collection_id} with a new map; neither rewrites a vector. Every search result reports the URI that scored it in `feature_uri`.","examples":[{"mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1":"mixpeek://text_extractor@v1/all_minilm_l6_v2_v1"}]},"vector_indexes":{"items":{"properties":{"name":{"type":"string","description":"User-facing index name."},"feature_uri":{"type":["string","null"],"description":"mixpeek:// feature URI on extractor-backed collections; the bare index name on BYO indexes."},"type":{"type":["string","null"],"description":"single or multi."},"index":{"type":["object","null"],"description":"Nested index config: name (storage name), dimensions, distance, inference_name."},"source":{"type":["string","null"],"enum":["namespace_vector_config",null],"description":"'namespace_vector_config' when the entry was synthesized from a promoted/direct-upsert namespace vector config; absent for extractor-derived indexes."}},"additionalProperties":true,"type":"object","title":"CollectionVectorIndex","description":"One vector index exposed on a collection. Shape is stable for the fields below; additional keys may appear."},"type":"array","title":"Vector Indexes","description":"NOT REQUIRED (auto-computed). Vector indexes for semantic search. Populated from feature_extractor.required_vector_indexes on extractor-backed collections, and from the namespace vector config on promoted or direct-upsert (BYO) collections, where each entry carries source='namespace_vector_config'. Defines which embeddings are indexed, their dimensions and distance metric. Use for understanding search capabilities and debugging vector queries. An entry's `source` distinguishes a namespace-declared index from an extractor-derived one; extractor-derived entries omit it. The nested `index` object carries the storage name, dimensions, distance and inference_name.","examples":[[],[{"feature_uri":"emb","index":{"dimensions":3072,"distance":"cosine","inference_name":"text-embedding-3-large","name":"emb"},"name":"emb","source":"namespace_vector_config","type":"single"}]]},"payload_indexes":{"items":{},"type":"array","title":"Payload Indexes","description":"NOT REQUIRED (auto-computed from extractor + namespace). Payload indexes for filtering. Enables efficient filtering on metadata fields, timestamps, IDs. Populated from: extractor requirements + namespace defaults. Use for: Understanding which fields support fast filtering.","examples":[[],[{"field_name":"collection_id","type":"keyword"}]]},"embedding_task":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Embedding Task","description":"Override the embedding task hint for instruction-aware models (E5, Gemini). Defaults to 'retrieval_document' for indexing pipelines. Values: retrieval_document, retrieval_query, semantic_similarity, classification, clustering. Applied to all task-aware embedding models in this collection's extractor pipeline."},"enabled":{"type":"boolean","title":"Enabled","description":"NOT REQUIRED (defaults to True). Whether the collection accepts new documents. False: Collection exists but won't process new objects. True: Active and processing. Use for: Temporarily disabling collections without deletion.","default":true,"examples":[true,false]},"disabled_reason":{"anyOf":[{"$ref":"#/components/schemas/CollectionDisabledReason"},{"type":"null"}],"description":"Set when the platform disabled this collection, saying why; null when it is enabled or was disabled by a caller. A collection whose source collection was deleted reads code 'source_collection_deleted' with the deleted collection's id and name. Cleared when the collection is enabled again."},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"NOT REQUIRED. Additional user-defined metadata for the collection. Arbitrary key-value pairs for custom organization, tracking, configuration. Not used by the platform - purely for user purposes. Common uses: team ownership, project tags, deployment environment.","examples":[{"environment":"production","project":"Q4_campaign","team":"data-science"},null]},"schedule":{"anyOf":[{"$ref":"#/components/schemas/CollectionScheduleConfig"},{"type":"null"}],"description":"NOT REQUIRED. Schedule configuration for automatic re-processing. When set, a COLLECTION_TRIGGER trigger is created and linked to this collection."},"trigger_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trigger Id","description":"NOT REQUIRED. ID of the linked trigger for scheduled re-processing. Automatically set when a schedule is configured."},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"Timestamp when the collection was created. Automatically set by the system when the collection is first saved to the database."},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"Timestamp when the collection was last updated. Automatically updated by the system whenever the collection is modified."},"lifecycle_state":{"type":"string","title":"Lifecycle State","description":"Storage lifecycle state: 'active' (vector store + S3), 'cold' (S3 only), 'archived' (metadata only). Managed via lifecycle API.","default":"active"},"s3_vector_index":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"S3 Vector Index","description":"S3 Vectors index name for this collection (e.g. 'col_{collection_id}')."},"last_lifecycle_transition":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Lifecycle Transition","description":"Timestamp of the most recent lifecycle state change."},"tiering_rules":{"anyOf":[{"items":{"$ref":"#/components/schemas/TieringRule"},"type":"array"},{"type":"null"}],"title":"Tiering Rules","description":"Retired: stored and never enforced. Writes are refused; set `tiering` instead. Kept on reads so existing records still parse."},"tiering":{"anyOf":[{"$ref":"#/components/schemas/TieringOverride"},{"type":"null"}],"description":"This collection's override of the platform's collection tiering: `enabled`, `idle_days` ({cold, frozen}) and `exempt` with the reason. Unset parts inherit from the namespace, then from the platform default."},"document_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Document Count","description":"Number of documents in the collection"},"schema_version":{"type":"integer","title":"Schema Version","description":"Version number for the output_schema. Increments automatically when schema is updated via document sampling. Used to track schema evolution and trigger downstream collection schema updates.","default":1},"last_schema_sync":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Schema Sync","description":"Timestamp of last automatic schema sync from document sampling. Used to debounce schema updates (prevents thrashing)."},"schema_sync_enabled":{"type":"boolean","title":"Schema Sync Enabled","description":"Whether automatic schema discovery and sync is enabled for this collection. When True, schema is periodically updated by sampling documents. When False, schema remains fixed at creation time.","default":true},"document_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Document Schema","description":"NOT REQUIRED. JSON Schema for validating documents on create/update. When set with schema_validation='strict', non-conforming documents are rejected (422). When set with schema_validation='warn', violations are recorded but document is accepted. Schema follows JSON Schema draft-07 format. Only validates user-defined fields (system fields like _internal, collection_id, document_id are excluded from validation).","examples":[null,{"additionalProperties":true,"properties":{"title":{"maxLength":200,"type":"string"},"price":{"minimum":0,"type":"number"},"status":{"enum":["active","draft","archived"],"type":"string"}},"required":["title","price"],"type":"object"}]},"schema_validation":{"type":"string","enum":["strict","warn","off"],"title":"Schema Validation","description":"Document schema validation mode. 'strict': reject non-conforming documents with 422. 'warn': accept but attach _schema_violations field to the document. 'off': no validation (default, preserves current behavior).","default":"off","examples":["off","strict","warn"]},"taxonomy_applications":{"anyOf":[{"items":{"$ref":"#/components/schemas/TaxonomyApplicationConfig-Output"},"type":"array"},{"type":"null"}],"title":"Taxonomy Applications","description":"NOT REQUIRED. List of taxonomies to apply to documents in this collection. Each entry specifies: taxonomy_id, optional target_collection_id, optional filters. Enrichments are materialized (persisted to documents) during ingestion. Empty/null if no taxonomies attached. Use for: Categorization, hierarchical classification.","examples":[null,[{"execution_mode":"materialize","taxonomy_id":"tax_categories"},{"execution_mode":"materialize","taxonomy_id":"tax_brands"}]]},"cluster_applications":{"anyOf":[{"items":{"$ref":"#/components/schemas/ClusterApplicationConfig"},"type":"array"},{"type":"null"}],"title":"Cluster Applications","description":"NOT REQUIRED. List of clusters to automatically execute when batch processing completes. Each entry specifies: cluster_id, auto_execute_on_batch, min_document_threshold, cooldown_seconds. Clusters enrich source documents with cluster assignments (cluster_id, cluster_label, etc.). Empty/null if no clusters attached. Use for: Segmentation, grouping, pattern discovery.","examples":[null,[{"auto_execute_on_batch":true,"cluster_id":"clust_product_categories","cooldown_seconds":3600,"min_document_threshold":100}]]},"alert_applications":{"anyOf":[{"items":{"$ref":"#/components/schemas/AlertApplicationConfig-Output"},"type":"array"},{"type":"null"}],"title":"Alert Applications","description":"NOT REQUIRED. List of alerts to automatically execute when documents are ingested. Each entry specifies: alert_id, execution_mode, input_mappings, execution_phase, priority. Alerts run retrievers on ingested documents and send notifications when matches are found. Empty/null if no alerts attached. Use for: Content monitoring, safety detection, compliance alerts.","examples":[null,[{"alert_id":"alt_safety_001","execution_mode":"on_ingest","execution_phase":3,"input_mappings":[{"input_key":"query_embedding","source":{"path":"features.video_embedding","source_type":"document_field"}}],"priority":100}]]},"retriever_enrichments":{"anyOf":[{"items":{"$ref":"#/components/schemas/RetrieverEnrichmentConfig-Output"},"type":"array"},{"type":"null"}],"title":"Retriever Enrichments","description":"NOT REQUIRED. List of retriever enrichments to run on documents during post-processing. Each entry specifies: retriever_id, input_mappings, write_back_fields, execution_phase, priority. Retriever enrichments execute a retriever pipeline and write selected result fields back to documents. Empty/null if no enrichments attached. Use for: LLM classification, cross-collection joins, enrichment.","examples":[null,[{"execution_phase":4,"input_mappings":[{"input_key":"query","source":{"path":"title","source_type":"document_field"}}],"priority":0,"retriever_id":"ret_classifier_001","write_back_fields":[{"mode":"first","source_field":"category","target_field":"_enrichment_category"}]}]]},"retriever_transform":{"anyOf":[{"$ref":"#/components/schemas/RetrieverTransformConfig-Output"},{"type":"null"}],"description":"NOT REQUIRED. Set for a transform-based collection: the inline retriever pipeline (over an upstream collection) that defines this collection's documents. Mutually exclusive with feature_extractor. None for extractor-based collections."},"vector_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Vector Count","description":"Total number of vector entries across all documents in this collection. Computed as document_count * number_of_vector_indexes. Each document stores one vector per configured vector index (e.g. a collection with 1 embedding produces 1 vector per document)."},"taxonomy_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Taxonomy Count","description":"Number of taxonomies connected to this collection"},"retriever_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Retriever Count","description":"Number of retrievers connected to this collection"},"indexing_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Indexing Status","description":"Whether every vector the vector store has accepted for this collection's namespace is searchable now. This is separate from the collection's own RUNNING/COMPLETED status: a collection can be COMPLETED while this reads 'indexing'. One of: 'quiesced' (everything the store has accepted for this namespace is searchable; documents still moving through extraction have not reached the store yet, so compare document_count with what you sent if you need completeness), 'indexing' (some accepted vectors are waiting to become searchable and will be shortly; a search run now may miss them), 'blocked' (indexing cannot proceed without intervention, and waiting will not resolve it), 'unknown' (the signal is unavailable, for example an older store build or a transient error; treat it as not confirmed ready). Null when this endpoint did not compute it, for example a list request whose store reading took too long.","examples":["quiesced","indexing","blocked","unknown"]},"indexing_status_scoped":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Indexing Status Scoped","description":"True when indexing_status describes this collection's namespace alone. False when the store could only report the whole shard, which several namespaces can share, so an 'indexing' or 'blocked' value may come from another namespace's backlog. A 'quiesced' reading is always scoped."},"warnings":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Warnings","description":"NOT REQUIRED. Non-fatal problems detected while creating the collection. The collection WAS created; these describe things that will make it produce nothing at run time. The case this exists for: input_mappings can name a field that is valid in the bucket SCHEMA and absent from the bucket's OBJECTS, because a sync with no schema_mapping writes its blob to the default property instead. Schema validation passes, the batch then finds nothing, and the batch error arrives long after the decision was made. A warning here reaches the caller while they can still change it."}},"type":"object","required":["collection_name","feature_extractor","source"],"title":"CollectionResponse","description":"Response model for collection endpoints.","examples":[{"collection_id":"col_a1b2c3d4e5","collection_name":"article_embeddings","description":"Simple text collection: News articles with text embeddings from bucket source","enabled":true,"feature_extractor":{"feature_extractor_name":"text_extractor","field_passthrough":[{"source_path":"title"}],"input_mappings":{"text":"content"},"version":"v1"},"input_schema":{"properties":{"title":{"type":"string"},"content":{"type":"text"}}},"output_schema":{"properties":{"title":{"type":"string"},"text_extractor_v1_embedding":{"type":"array"}}},"source":{"bucket_id":"bkt_articles","type":"bucket"}},{"collection_id":"col_xyz789abc","collection_name":"video_frames","description":"Video frames: Extracted at 1 FPS with CLIP embeddings and campaign_id passthrough","enabled":true,"feature_extractor":{"feature_extractor_name":"multimodal_extractor","field_passthrough":[{"source_path":"campaign_id"}],"input_mappings":{"video":"video"},"parameters":{"fps":1},"version":"v1"},"input_schema":{"properties":{"video":{"type":"video"},"campaign_id":{"type":"string"}}},"output_schema":{"properties":{"campaign_id":{"type":"string"},"multimodal_extractor_v1_embedding":{"type":"array"}}},"source":{"bucket_id":"bkt_marketing_videos","type":"bucket"}},{"collection_id":"col_scenes_def","collection_name":"detected_scenes","description":"Tier 2 decomposition: Scenes detected from frame embeddings (collection source)","enabled":true,"feature_extractor":{"feature_extractor_name":"scene_extractor","field_passthrough":[{"source_path":"campaign_id"}],"input_mappings":{"embedding":"multimodal_extractor_v1_embedding"},"version":"v1"},"input_schema":{"properties":{"campaign_id":{"type":"string"},"multimodal_extractor_v1_embedding":{"type":"array"}}},"output_schema":{"properties":{"campaign_id":{"type":"string"},"scene_extractor_v1_embedding":{"type":"array"}}},"source":{"collection_id":"col_video_frames","type":"collection"}}]},"CollectionScheduleConfig":{"properties":{"trigger_type":{"type":"string","title":"Trigger Type","description":"Schedule type: 'cron' or 'interval'","examples":["cron","interval"]},"schedule_config":{"additionalProperties":true,"type":"object","title":"Schedule Config","description":"Schedule configuration. For cron: {cron_expression, timezone}. For interval: {interval_seconds, start_immediately}.","examples":[{"cron_expression":"0 2 * * *","timezone":"UTC"},{"interval_seconds":21600,"start_immediately":false}]},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Human-readable description of the schedule."}},"type":"object","required":["trigger_type","schedule_config"],"title":"CollectionScheduleConfig","description":"Schedule configuration for automatic collection re-processing.\n\nAttaches a cron or interval schedule to a collection, which creates\na COLLECTION_TRIGGER trigger behind the scenes. This is a DX convenience\nso users don't need to create triggers manually.\n\nExamples:\n    Daily re-crawl at 2am UTC:\n        {\"trigger_type\": \"cron\", \"schedule_config\": {\"cron_expression\": \"0 2 * * *\"}}\n\n    Every 6 hours:\n        {\"trigger_type\": \"interval\", \"schedule_config\": {\"interval_seconds\": 21600}}"},"ColqwenExtractorParams":{"properties":{"extractor_type":{"type":"string","const":"colqwen_extractor","title":"Extractor Type","description":"Discriminator field for parameter type identification.","default":"colqwen_extractor"},"enable_thumbnails":{"type":"boolean","title":"Enable Thumbnails","description":"Whether to generate a thumbnail of each image, page or frame.","default":true},"use_cdn":{"type":"boolean","title":"Use Cdn","description":"Whether to use CloudFront CDN for thumbnail delivery.","default":false}},"type":"object","title":"ColqwenExtractorParams","description":"Parameters for the ColQwen extractor.","examples":[{"extractor_type":"colqwen_extractor"},{"enable_thumbnails":false,"extractor_type":"colqwen_extractor"}]},"ColumnSource":{"properties":{"type":{"type":"string","const":"column","title":"Type","description":"Source type identifier. Must be 'column' for database columns.","default":"column"},"name":{"type":"string","minLength":1,"title":"Name","description":"The column name to extract from. Case handling depends on the database. Snowflake: case-insensitive (defaults to uppercase). PostgreSQL: case-sensitive unless quoted. Column must exist in the source table/view.","examples":["category","CUSTOMER_TYPE","metadata_json","image_url"]}},"type":"object","required":["name"],"title":"ColumnSource","description":"Extract value from a database column (Snowflake, PostgreSQL, etc.).\n\nFor database sync sources, maps a column from the source table/view\nto a bucket schema field. Column handling varies by database.\n\nProvider Compatibility: Snowflake, PostgreSQL (future), BigQuery (future)\n\nExample Snowflake table:\n    CREATE TABLE CUSTOMERS (\n        ID VARCHAR, NAME VARCHAR, CATEGORY VARCHAR,\n        CREATED_AT TIMESTAMP, PROFILE_IMAGE_URL VARCHAR\n    );\n\nExample mapping:\n    {\"type\": \"column\", \"name\": \"CATEGORY\"} -> extracts the CATEGORY column value\n\nDatabase-Specific Notes:\n    - Snowflake: Case-insensitive (internally uppercase), use unquoted names\n    - PostgreSQL: Case-sensitive if quoted, defaults to lowercase\n    - BigQuery: Case-sensitive\n\nAttributes:\n    type: Must be \"column\" to identify this source type\n    name: The column name to extract from"},"ComponentsConfig":{"properties":{"show_hero":{"type":"boolean","title":"Show Hero","description":"Whether to show the hero section with title and description","default":true},"show_search":{"type":"boolean","title":"Show Search","description":"Whether to show search input fields","default":true},"show_filters":{"type":"boolean","title":"Show Filters","description":"Whether to show filters sidebar","default":false},"show_results_header":{"type":"boolean","title":"Show Results Header","description":"Whether to show the results header with count and sorting options","default":true},"result_layout":{"type":"string","title":"Result Layout","description":"Layout mode for results display","default":"grid","examples":["grid","list","masonry"]},"result_card":{"anyOf":[{"$ref":"#/components/schemas/ResultCardProperties"},{"type":"null"}],"description":"Configuration for result card display"}},"type":"object","title":"ComponentsConfig","description":"Configuration for UI components.","examples":[{"result_card":{"card_click_action":"viewDetails","field_order":["title","description"],"layout":"vertical","show_find_similar":true,"show_thumbnail":true},"result_layout":"grid","show_filters":false,"show_hero":true,"show_results_header":true,"show_search":true}]},"CompoundIndexPattern":{"properties":{"field_combination":{"items":{"type":"string"},"type":"array","title":"Field Combination","description":"Fields used together"},"combination_count":{"type":"integer","title":"Combination Count","description":"Number of times this combination was used"},"avg_latency_ms":{"type":"number","title":"Avg Latency Ms","description":"Average latency for this combination"},"p95_latency_ms":{"type":"number","title":"P95 Latency Ms","description":"95th percentile latency"}},"type":"object","required":["field_combination","combination_count","avg_latency_ms","p95_latency_ms"],"title":"CompoundIndexPattern","description":"Pattern of fields commonly queried together."},"CompoundIndexResponse":{"properties":{"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace ID analyzed"},"time_range_days":{"type":"integer","title":"Time Range Days","description":"Number of days analyzed"},"patterns":{"items":{"$ref":"#/components/schemas/CompoundIndexPattern"},"type":"array","title":"Patterns","description":"Compound field patterns"},"total_patterns":{"type":"integer","title":"Total Patterns","description":"Total patterns found"}},"type":"object","required":["namespace_id","time_range_days","patterns","total_patterns"],"title":"CompoundIndexResponse","description":"Response for compound index patterns endpoint."},"ComputeCostSummary":{"properties":{"cpu_hours":{"type":"number","title":"Cpu Hours","default":0.0},"gpu_hours":{"type":"number","title":"Gpu Hours","default":0.0},"base_cost_usd":{"type":"number","title":"Base Cost Usd","default":0.0},"daily_breakdown":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Daily Breakdown"}},"type":"object","title":"ComputeCostSummary"},"ConfidenceDistribution":{"properties":{"confidence_range":{"type":"string","title":"Confidence Range","description":"Confidence range (e.g., '0.8-0.9')"},"count":{"type":"integer","title":"Count"},"percentage":{"type":"number","title":"Percentage"}},"type":"object","required":["confidence_range","count","percentage"],"title":"ConfidenceDistribution","description":"Confidence score distribution bucket."},"ConfidenceResponse":{"properties":{"taxonomy_id":{"type":"string","title":"Taxonomy Id"},"distribution":{"items":{"$ref":"#/components/schemas/ConfidenceDistribution"},"type":"array","title":"Distribution"},"avg_confidence":{"type":"number","title":"Avg Confidence"},"low_confidence_count":{"type":"integer","title":"Low Confidence Count","description":"Count of assignments below 0.5 confidence"}},"type":"object","required":["taxonomy_id","distribution","avg_confidence","low_confidence_count"],"title":"ConfidenceResponse","description":"Taxonomy confidence distribution response."},"ConfirmModelUploadRequest":{"properties":{"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag","description":"S3 ETag from upload response for integrity check"},"file_size_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"File Size Bytes","description":"Expected file size for validation"}},"type":"object","title":"ConfirmModelUploadRequest","description":"Request to confirm a model upload after S3 upload completes.\n\nOptional fields for integrity verification:\n- etag: S3 ETag returned from PUT response (recommended)\n- file_size_bytes: Expected file size for validation"},"ConfirmModelUploadResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether upload and validation succeeded"},"upload_id":{"type":"string","title":"Upload Id","description":"The upload ID"},"model_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Model Id","description":"Created model ID if successful"},"validation_status":{"type":"string","enum":["pending","passed","failed"],"title":"Validation Status","description":"Validation status"},"validation_errors":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Validation Errors","description":"Validation errors if any"},"s3_archive_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"S3 Archive Url","description":"S3 URL of the archive"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message","description":"Additional status message"}},"type":"object","required":["success","upload_id","validation_status"],"title":"ConfirmModelUploadResponse","description":"Response from confirming a model upload."},"ConfirmPaymentMethodRequest":{"properties":{"payment_method_id":{"type":"string","title":"Payment Method Id","description":"Stripe PaymentMethod ID from frontend","examples":["pm_1ABC2DEF3GHI456"]}},"type":"object","required":["payment_method_id"],"title":"ConfirmPaymentMethodRequest","description":"Request to confirm a payment method after collection."},"ConfirmPaymentMethodResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether payment method was successfully confirmed","default":true},"payment_method":{"$ref":"#/components/schemas/PaymentMethodInfo","description":"Confirmed payment method details"},"auto_billing_enabled":{"type":"boolean","title":"Auto Billing Enabled","description":"Whether auto-billing is now enabled"},"billing_period_start":{"type":"string","format":"date-time","title":"Billing Period Start","description":"When the current billing period started"}},"type":"object","required":["payment_method","auto_billing_enabled","billing_period_start"],"title":"ConfirmPaymentMethodResponse","description":"Response after confirming payment method."},"ConfirmSubmissionRequest":{"properties":{"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag","description":"S3 ETag for integrity check"},"file_size_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"File Size Bytes"}},"type":"object","title":"ConfirmSubmissionRequest"},"ConfirmSubmissionResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"submission_id":{"type":"string","title":"Submission Id"},"status":{"type":"string","title":"Status"},"security_scan_passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Security Scan Passed"},"security_violations":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Security Violations"},"manifest_valid":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Manifest Valid"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message"}},"type":"object","required":["success","submission_id","status"],"title":"ConfirmSubmissionResponse"},"ConfirmUploadRequest":{"properties":{"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag","description":"S3 ETag returned from the upload. OPTIONAL but RECOMMENDED. After uploading to S3, the response includes an ETag header. Providing this ensures the file wasn't corrupted during upload. If provided and doesn't match S3's ETag, confirmation will fail with error. Format: Usually an MD5 hash, may be enclosed in quotes.","examples":["d41d8cd98f00b204e9800998ecf8427e","\"a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6\""]},"file_size_bytes":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"File Size Bytes","description":"Actual file size uploaded, in bytes. OPTIONAL but RECOMMENDED. If provided, will be validated against the actual S3 object size. Mismatch indicates upload corruption or network issues. If not provided, size validation is skipped.","examples":[10485760,52428800]},"auto_submit_batch":{"type":"boolean","title":"Auto Submit Batch","description":"If true, automatically create AND submit a batch containing the newly created object after confirmation. The returned ``task_id`` will be the submitted batch's task id, and ``batch_id`` will be populated. Eliminates the need for separate POST /batches and POST /batches/{id}/submit calls during bulk ingest. Has no effect if ``create_object_on_confirm`` is false or the object is a duplicate. If the batch is created but the submit is refused (for example a namespace daily budget, a quota or a validation error), the request fails with that error, and its details carry ``upload_id``, ``object_id`` and the DRAFT ``batch_id``: the upload and object are kept, and the batch can be submitted later with POST /batches/{id}/submit. Defaults to false for backwards compatibility — existing flows that batch many objects into one submission still work.","default":false}},"type":"object","title":"ConfirmUploadRequest","description":"Request to confirm S3 upload completion and create bucket object.\n\n⚠️  THIS ENDPOINT IS REQUIRED AFTER UPLOADING TO S3!\n\nS3 presigned URLs have no callback mechanism - the API cannot detect when\nyour upload completes. You MUST call this endpoint to finalize the upload.\n\nWhy confirmation is required:\n    - S3 doesn't notify us when uploads complete\n    - We need to verify the file actually exists in S3\n    - We need to create the bucket object\n    - We need to update quotas and tracking\n\nThe system will:\n1. Verify the S3 object exists (HeadObject call)\n2. Validate ETag matches (if provided) - RECOMMENDED for integrity\n3. Validate file size matches (if provided)\n4. Create bucket object (default, unless create_object_on_confirm=false)\n5. Update upload status to COMPLETED\n\nIf you don't call confirm:\n    - Upload stays in PENDING status\n    - No bucket object is created\n    - File is orphaned in S3","examples":[{"description":"Confirm with ETag for integrity verification (recommended)","etag":"d41d8cd98f00b204e9800998ecf8427e","file_size_bytes":52428800},{"description":"Confirm with size only","file_size_bytes":10485760},{"auto_submit_batch":true,"description":"Auto-submit a batch after confirm (one-shot ingest)","etag":"d41d8cd98f00b204e9800998ecf8427e","file_size_bytes":52428800},{"description":"Basic confirmation without validation (not recommended)"}]},"ConfirmUploadResponse":{"properties":{"upload_id":{"type":"string","title":"Upload Id","description":"Upload ID that was confirmed"},"status":{"$ref":"#/components/schemas/TaskStatusEnum","description":"Updated upload status (COMPLETED or PROCESSING)"},"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag","description":"S3 ETag from uploaded object"},"file_size_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"File Size Bytes","description":"Actual file size from S3"},"file_hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"File Hash","description":"File content hash (from ETag)"},"verified_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Verified At","description":"When verification completed"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"When upload completed"},"object_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Object Id","description":"Created bucket object ID (if create_object_on_confirm was true)"},"task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id","description":"Task ID for async processing. Populated when auto_submit_batch=true (holds the submitted batch's first-tier task id) or when async=true."},"batch_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Batch Id","description":"Batch ID created and submitted by auto_submit_batch=true. Use it to poll status via GET /v1/buckets/{id}/batches/{batch_id}."},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message","description":"Confirmation message"}},"type":"object","required":["upload_id","status"],"title":"ConfirmUploadResponse","description":"Response from upload confirmation.","examples":[{"completed_at":"2024-01-15T10:35:00Z","description":"Synchronous confirmation with object creation","etag":"d41d8cd98f00b204e9800998ecf8427e","file_hash":"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855","file_size_bytes":52428800,"object_id":"obj_xyz789","status":"COMPLETED","upload_id":"upl_abc123","verified_at":"2024-01-15T10:35:00Z"},{"description":"Asynchronous confirmation","message":"Upload confirmation is being processed in the background.","status":"PROCESSING","task_id":"task_xyz789","upload_id":"upl_abc123"}]},"ConfirmationRequest":{"properties":{"approved":{"type":"boolean","title":"Approved","description":"True to approve, False to deny the action"}},"type":"object","required":["approved"],"title":"ConfirmationRequest","description":"Request to approve or deny a pending confirmation."},"ConnectRepoRequest":{"properties":{"repo_url":{"type":"string","title":"Repo Url","description":"GitHub repository URL"},"branch":{"type":"string","title":"Branch","description":"Branch to deploy from","default":"main"},"github_installation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Github Installation Id","description":"GitHub App installation ID"}},"type":"object","required":["repo_url"],"title":"ConnectRepoRequest","description":"Request to connect a GitHub repo for auto-deploy."},"ConstantSource":{"properties":{"type":{"type":"string","const":"constant","title":"Type","description":"Source type identifier. Must be 'constant' for static values.","default":"constant"},"value":{"title":"Value","description":"The constant value to use for all objects. Can be any JSON-serializable value: string, number, boolean, array, object. Arrays are useful for tags, objects for structured metadata.","examples":["production",42,true,["tag1","tag2"],{"env":"prod"}]}},"type":"object","required":["value"],"title":"ConstantSource","description":"Use a constant/static value for all synced objects.\n\nUseful for adding fixed metadata to all objects from a sync, such as:\n- Source system identifier\n- Environment tags\n- Default categories\n- Static labels\n\nProvider Compatibility: All providers\n\nExample mappings:\n    {\"type\": \"constant\", \"value\": \"tigris-cdn\"} -> All objects get \"tigris-cdn\"\n    {\"type\": \"constant\", \"value\": [\"tag1\", \"tag2\"]} -> All objects get this array\n    {\"type\": \"constant\", \"value\": {\"env\": \"prod\"}} -> All objects get this object\n\nAttributes:\n    type: Must be \"constant\" to identify this source type\n    value: The constant value (any JSON-serializable type)"},"CostBreakdown":{"properties":{"storage_percent":{"type":"number","title":"Storage Percent","description":"Storage cost percentage"},"upload_percent":{"type":"number","title":"Upload Percent","description":"Upload cost percentage"},"sync_percent":{"type":"number","title":"Sync Percent","description":"Sync cost percentage"},"other_percent":{"type":"number","title":"Other Percent","description":"Other cost percentage"}},"type":"object","required":["storage_percent","upload_percent","sync_percent","other_percent"],"title":"CostBreakdown","description":"Cost breakdown by category."},"CostBreakdownSummary":{"properties":{"billing_month":{"type":"string","title":"Billing Month"},"cloud_provider":{"type":"string","title":"Cloud Provider"},"data_as_of":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Data As Of"},"data_delay_note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Data Delay Note"},"cost_unavailable":{"type":"boolean","title":"Cost Unavailable","default":false},"attribution_scope":{"type":"string","title":"Attribution Scope","default":"dedicated_k8s_ns"},"total_cloud_cost_usd":{"type":"number","title":"Total Cloud Cost Usd","default":0.0},"margin_pct":{"type":"number","title":"Margin Pct","default":0.2},"total_margin_usd":{"type":"number","title":"Total Margin Usd","default":0.0},"platform_fee_usd":{"type":"number","title":"Platform Fee Usd","default":0.0},"platform_fee_billed_externally":{"type":"boolean","title":"Platform Fee Billed Externally","default":false},"total_invoice_usd":{"type":"number","title":"Total Invoice Usd","default":0.0},"categories":{"items":{"$ref":"#/components/schemas/CloudCostCategorySummary"},"type":"array","title":"Categories"},"all_line_items":{"items":{"$ref":"#/components/schemas/CloudCostLineItem"},"type":"array","title":"All Line Items"}},"type":"object","required":["billing_month","cloud_provider"],"title":"CostBreakdownSummary"},"CostRate":{"properties":{"unit":{"$ref":"#/components/schemas/CostUnit","description":"The billing unit type"},"credits_per_unit":{"type":"number","exclusiveMinimum":0.0,"title":"Credits Per Unit","description":"Credits charged per unit (1 credit = $0.001). Fractional when the per-unit price is not a whole number of credits, for example 1.5 for an image at $1.50 per 1,000."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Human-readable description of what this rate covers"}},"type":"object","required":["unit","credits_per_unit"],"title":"CostRate","description":"Cost rate for a specific billing unit.\n\nDefines how many credits are charged per unit of a specific type.\n\nExample:\n    CostRate(\n        unit=CostUnit.MINUTE,\n        credits_per_unit=200,\n        description=\"Video processing\"\n    )\n    # Means: 200 credits per minute of video"},"CostUnit":{"type":"string","enum":["minute","image","1k_tokens","page","face","extraction"],"title":"CostUnit","description":"Standard billing units aligned with extractor input types.\n\nEach unit represents a measurable quantity that extractors process:\n- MINUTE: Video/audio duration in minutes\n- IMAGE: Per image processed\n- TOKENS_1K: Text tokens in thousands\n- PAGE: Document pages (PDF, etc.)\n- FACE: Detected faces in images/video\n- EXTRACTION: Flat per-operation cost"},"CostsInfo":{"properties":{"tier":{"type":"integer","maximum":4.0,"minimum":1.0,"title":"Tier","description":"Cost tier (1-4): 1=SIMPLE, 2=MODERATE, 3=COMPLEX, 4=PREMIUM"},"tier_label":{"type":"string","title":"Tier Label","description":"Human-readable tier label (SIMPLE, MODERATE, COMPLEX, PREMIUM)"},"rates":{"items":{"$ref":"#/components/schemas/CostRate"},"type":"array","title":"Rates","description":"List of cost rates for different input types this extractor processes"}},"type":"object","required":["tier","tier_label","rates"],"title":"CostsInfo","description":"Credit cost information for a feature extractor.\n\nDescribes the pricing tier and standardized cost rates for using this extractor.\nRates are defined using CostUnit types that align with extractor input types."},"CovariateConfig":{"properties":{"field_path":{"type":"string","title":"Field Path","description":"Dot-notation path to covariate field (e.g., 'sender_domain', 'metadata.priority')","examples":["sender_domain","metadata.word_count","features.clip_embedding"]},"covariate_type":{"$ref":"#/components/schemas/CovariateType","description":"Type of covariate determines analysis strategy (categorical/numeric/embedding/cluster)"},"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Human-readable name for this covariate in analytics results","examples":["Sender Domain","Word Count","Visual Cluster"]},"binning_strategy":{"anyOf":[{"type":"string","enum":["quartiles","deciles","custom"]},{"type":"null"}],"title":"Binning Strategy","description":"How to bin numeric values for lift analysis (only used for NUMERIC type)","default":"quartiles"},"clustering_method":{"anyOf":[{"type":"string","enum":["kmeans","hdbscan"]},{"type":"null"}],"title":"Clustering Method","description":"Clustering algorithm for embedding analysis (only used for EMBEDDING type)","default":"kmeans"},"n_clusters":{"anyOf":[{"type":"integer","maximum":100.0,"minimum":2.0},{"type":"null"}],"title":"N Clusters","description":"Number of clusters for embedding-based predictors (only used for EMBEDDING type)","default":10}},"type":"object","required":["field_path","covariate_type","name"],"title":"CovariateConfig","description":"Configuration for a single covariate/predictor variable in step analytics.\n\nCovariates are used to identify which features predict conversion from one step\nto another. The system computes \"lift\" for each covariate value, showing whether\nit increases or decreases conversion likelihood.\n\nAttributes:\n    field_path: JSONPath to the field in document or metadata (e.g., \"sender_domain\")\n    covariate_type: How to analyze this covariate (categorical, numeric, embedding, cluster)\n    name: Human-readable name for analytics results\n    binning_strategy: For NUMERIC types, how to bin values (quartiles, deciles)\n    clustering_method: For EMBEDDING types, algorithm to use (kmeans, hdbscan)\n    n_clusters: For EMBEDDING types, number of clusters to create\n\nExamples:\n    ```python\n    # Analyze sender domains (categorical)\n    CovariateConfig(\n        field_path=\"sender_domain\",\n        covariate_type=\"categorical\",\n        name=\"Email Domain\"\n    )\n\n    # Analyze email length (numeric with quartile binning)\n    CovariateConfig(\n        field_path=\"word_count\",\n        covariate_type=\"numeric\",\n        name=\"Word Count\",\n        binning_strategy=\"quartiles\"\n    )\n\n    # Analyze visual similarity (embedding clustering)\n    CovariateConfig(\n        field_path=\"features.clip_embedding\",\n        covariate_type=\"embedding\",\n        name=\"Visual Cluster\",\n        clustering_method=\"kmeans\",\n        n_clusters=10\n    )\n    ```"},"CovariateType":{"type":"string","enum":["categorical","numeric","embedding","cluster_id"],"title":"CovariateType","description":"Type of covariate/predictor variable for conversion analysis.\n\nDifferent types enable different analysis strategies:\n- CATEGORICAL: String values, analyzed via grouping (e.g., sender_domain, priority)\n- NUMERIC: Continuous values, binned into quartiles/deciles (e.g., word_count, price)\n- EMBEDDING: Dense vectors, clustered for semantic analysis (e.g., CLIP embeddings)\n- CLUSTER_ID: Pre-computed cluster identifiers (e.g., topic_cluster, visual_cluster)\n\nExamples:\n    ```python\n    # Categorical: Which email domains convert better?\n    CovariateConfig(field_path=\"sender_domain\", covariate_type=\"categorical\")\n\n    # Numeric: Do longer emails convert faster?\n    CovariateConfig(field_path=\"word_count\", covariate_type=\"numeric\")\n\n    # Embedding: Do visually similar images follow similar paths?\n    CovariateConfig(field_path=\"features.clip\", covariate_type=\"embedding\")\n\n    # Cluster: Which topic clusters have highest conversion?\n    CovariateConfig(field_path=\"metadata.topic_id\", covariate_type=\"cluster_id\")\n    ```"},"CrawlMode":{"type":"string","enum":["deterministic","semantic"],"title":"CrawlMode","description":"Mode for crawling web pages.\n\nValues:\n    DETERMINISTIC: BFS crawl following all links up to max_depth\n    SEMANTIC: LLM-guided crawl prioritizing pages relevant to crawl_goal"},"CreateAlertRequest":{"properties":{"name":{"type":"string","maxLength":200,"minLength":1,"title":"Name","description":"Human-readable name for the alert","examples":["Safety Incident Detector","Prohibited Content Alert"]},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description","description":"Optional description of what this alert monitors","examples":["Alerts when new videos match known safety incidents"]},"source":{"$ref":"#/components/schemas/AlertSource","description":"Trigger source: 'retriever' (runs a retriever) or 'system' (built-in metric)","default":"retriever"},"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id","description":"ID of the retriever to execute (source=retriever only). The retriever defines filters, scoring, limits.","examples":["ret_safety_search","ret_prohibited_content"]},"trigger_on":{"$ref":"#/components/schemas/TriggerOn","description":"source=retriever: fire on 'results' (narrowed by min_count and threshold when set) or 'no_results'","default":"results"},"min_count":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Min Count","description":"With trigger_on='results': the fewest rows that fire the alert (default 1).","examples":[3]},"threshold":{"anyOf":[{"$ref":"#/components/schemas/AlertThreshold"},{"type":"null"}],"description":"With trigger_on='results': fire only when the first result meets this comparison."},"inputs":{"additionalProperties":true,"type":"object","title":"Inputs","description":"Retriever inputs the alert runs with. The sweep uses exactly these; at ingest, inputs mapped from the document override them.","examples":[{"window_minutes":60}]},"cooldown_seconds":{"type":"integer","maximum":2592000.0,"minimum":0.0,"title":"Cooldown Seconds","description":"Suppress further fires for this many seconds after a fire. 0 means none.","default":0,"examples":[3600]},"renotify_interval_seconds":{"anyOf":[{"type":"integer","maximum":2592000.0,"minimum":60.0},{"type":"null"}],"title":"Renotify Interval Seconds","description":"While the condition stays true, notify again at this interval. Unset means once per rise.","examples":[21600]},"system_condition":{"anyOf":[{"$ref":"#/components/schemas/SystemCondition"},{"type":"null"}],"description":"Built-in data-plane condition to watch (source=system only)"},"namespace_selector":{"anyOf":[{"$ref":"#/components/schemas/NamespaceSelector"},{"type":"null"}],"description":"Org-level namespace scoping (all vs selected)"},"notification_config":{"$ref":"#/components/schemas/AlertNotificationConfig","description":"How and where to send notifications when alert triggers"},"enabled":{"type":"boolean","title":"Enabled","description":"Whether the alert is active and will execute","default":true},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Additional user-defined metadata for the alert"}},"type":"object","required":["name","notification_config"],"title":"CreateAlertRequest","description":"Request model to create an alert.\n\nCreates a new alert that can be attached to collections to monitor\nfor matching content and send notifications when matches are found.\n\nNote: The alert references a retriever that contains all query logic\n(filters, min_score, limits, collection targeting). The alert's job\nis simply to run that retriever and notify if results exist.","examples":[{"description":"Alerts when new videos match known safety incidents","enabled":true,"name":"Safety Incident Detector","notification_config":{"channels":[{"channel_id":"wh_safety_team","channel_type":"webhook"}],"include_matches":true,"include_scores":true},"retriever_id":"ret_safety_search"}]},"CreateAnnotationRequest":{"properties":{"document_id":{"type":"string","title":"Document Id","description":"Document to annotate."},"collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Collection Id","description":"Collection the document belongs to."},"label":{"type":"string","maxLength":100,"minLength":1,"title":"Label","description":"Decision label (e.g. 'approved', 'rejected', 'deferred')."},"confidence":{"anyOf":[{"type":"number","maximum":1.0,"minimum":0.0},{"type":"null"}],"title":"Confidence","description":"Human confidence (0.0–1.0)."},"reasoning":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}],"title":"Reasoning","description":"Why this decision was made."},"payload":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Payload","description":"Structured payload (use-case-specific)."},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Optional custom metadata to attach to this annotation. Stored and returned as-is, and mirrored onto the mxp_document_annotations signal so it can be read and filtered alongside the annotation."},"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id"},"execution_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Execution Id"},"stage_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stage Name"}},"type":"object","required":["document_id","label"],"title":"CreateAnnotationRequest","description":"Create a new annotation on a document."},"CreateAppRequest":{"properties":{"slug":{"type":"string","maxLength":60,"minLength":3,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$","title":"Slug","description":"URL-safe slug (globally unique, lowercase + hyphens). Becomes your URL: {slug}.mxp.co","examples":["my-product-search","brand-dashboard"]},"meta":{"$ref":"#/components/schemas/PageMeta","description":"App metadata (title, logo, favicon)"},"auth_config":{"anyOf":[{"$ref":"#/components/schemas/AuthConfig-Input"},{"type":"null"}],"description":"End-user authentication. Set mode='clerk' for managed auth."},"build_config":{"anyOf":[{"$ref":"#/components/schemas/BuildConfig"},{"type":"null"}]},"monitoring_config":{"anyOf":[{"$ref":"#/components/schemas/MonitoringConfig"},{"type":"null"}]},"is_active":{"type":"boolean","title":"Is Active","default":true},"template":{"type":"string","title":"Template","default":"generic","deprecated":true},"sections":{"items":{"$ref":"#/components/schemas/SectionConfig"},"type":"array","title":"Sections","deprecated":true},"custom_html":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Html","deprecated":true},"hero":{"anyOf":[{"$ref":"#/components/schemas/HeroConfig"},{"type":"null"}],"deprecated":true},"theme":{"$ref":"#/components/schemas/ThemeConfig","deprecated":true},"seo":{"anyOf":[{"$ref":"#/components/schemas/SEOConfig"},{"type":"null"}],"deprecated":true},"stats":{"items":{"$ref":"#/components/schemas/StatItem"},"type":"array","title":"Stats","deprecated":true},"featured_gallery":{"anyOf":[{"$ref":"#/components/schemas/FeaturedGalleryConfig-Input"},{"type":"null"}],"deprecated":true},"tabs":{"items":{"$ref":"#/components/schemas/PageTab-Input"},"type":"array","title":"Tabs","deprecated":true},"password_secret_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Password Secret Name","deprecated":true}},"type":"object","required":["slug","meta"],"title":"CreateAppRequest","description":"Request to create a new App.\n\nOnly ``slug`` and ``meta`` are required.  After creation, deploy a zip\nbundle via ``POST /v1/apps/{app_id}/deploy``.\n\nLegacy page-builder fields (``template``, ``sections``, ``custom_html``,\n``hero``, ``theme``, ``seo``, ``stats``, ``featured_gallery``, ``tabs``,\n``password_secret_name``) are accepted for backward compatibility but\n**deprecated**.  New apps should not use them.","examples":[{"meta":{"title":"Product Search"},"slug":"my-product-search"},{"auth_config":{"mode":"clerk"},"meta":{"title":"Brand Dashboard"},"slug":"brand-dashboard"}]},"CreateBatchRequest":{"properties":{"object_ids":{"anyOf":[{"items":{"type":"string"},"type":"array","minItems":1},{"type":"null"}],"title":"Object Ids","description":"List of object IDs to include in the batch. Objects must exist in the bucket where the batch is created. Minimum 1 object, no maximum limit. Mutually exclusive with 'filters'.","examples":[["object_789","object_101"],["obj_video_001","obj_video_002","obj_video_003"]]},"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"Filter to select objects from the bucket. Resolved server-side into object IDs. Supports the same filter syntax as the object list endpoint. Mutually exclusive with 'object_ids'. Maximum 50,000 objects can be resolved from a filter."},"collection_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Collection Ids","description":"Optional list of collection IDs to process. When omitted, all collections sourced from this bucket (and their downstream dependencies) are auto-discovered. When provided, only these collections (plus their downstream dependencies) are included. Useful for submitting separate batches per collection to isolate failures. Accepts either 'collection_ids' or the shorthand 'collections'."},"limit":{"anyOf":[{"type":"integer","maximum":50000.0,"minimum":1.0},{"type":"null"}],"title":"Limit","description":"Maximum number of objects to include when using filters. If omitted, all matching objects are included (up to 50,000)."},"dedup_strategy":{"$ref":"#/components/schemas/DedupStrategy","description":"Controls how objects that were already processed in prior batches are handled. Scoped to (bucket, collection): checks if the target collection already has documents from the same source object, regardless of which batch created them. 'skip' (default): Don't reprocess objects that already have documents. 'replace': Delete existing documents and reprocess from scratch. 'force': Process regardless, allowing duplicate documents.","default":"skip","examples":["skip","replace","force"]},"metadata":{"anyOf":[{"$ref":"#/components/schemas/BatchMetadata"},{"type":"null"}],"description":"User-defined metadata for the batch. Has typed fields (campaign_id, source, tags, notes) and also accepts arbitrary extra keys. Persisted with the batch and returned in API responses.","examples":[{"campaign_id":"Q4_2025","tags":["backfill"]}]},"batch_name":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Batch Name","description":"Optional human-readable name for the batch. Stored on the batch and returned when you read it; batch_id stays the identifier.","examples":["january_products","run-1"]},"auto_submit":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Auto Submit","description":"Submit the batch for processing immediately after creation — same behavior as the ?auto_submit query parameter (the query parameter wins when both are supplied). Default false: the batch is created in DRAFT status and must be submitted with POST /submit before the draft TTL expires or the reaper cancels it. Accepted in the body because callers kept passing it here and it was silently ignored — the batch parked DRAFT and vanished ~30min later with no signal (FRUSTRATIONS L751)."},"trigger_processing":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Trigger Processing","description":"Deprecated alias of auto_submit (kept for callers taught by older docs/hints). auto_submit wins when both are supplied."}},"type":"object","title":"CreateBatchRequest","description":"Request model for creating a new batch.\n\nBatches group bucket objects for processing into collections. When you submit a batch,\nall objects in the batch are processed through the collections associated with the bucket.\n\nProvide **either** ``object_ids`` (explicit list) **or** ``filters`` (server-side query) — not both.\n\n- object_ids: Explicit list of object IDs that exist in the bucket\n- filters: A LogicalOperator filter that is resolved server-side against the bucket's objects\n\nBatch Processing Flow:\n1. Create batch with object_ids or filters → Batch created in DRAFT status, collections auto-discovered\n2. Submit batch → Processing begins for discovered collections\n3. Collections with collection sources (tier 2/3) are processed automatically\n4. Processing happens in topological order based on collection dependencies\n\nExamples:\n    Explicit object IDs:\n    {\"object_ids\": [\"obj_123\", \"obj_456\", \"obj_789\"]}\n\n    Filter-based (all objects with a tag):\n    {\"filters\": {\"AND\": [{\"field\": \"metadata.batch_tag\", \"operator\": \"eq\", \"value\": \"nfl_2025\"}]}}"},"CreateBenchmarkRequest":{"properties":{"benchmark_name":{"type":"string","maxLength":255,"minLength":1,"title":"Benchmark Name","description":"Human-readable name for this benchmark."},"baseline_retriever_id":{"type":"string","title":"Baseline Retriever Id","description":"ID of the baseline retriever pipeline to compare against."},"candidate_retriever_ids":{"items":{"type":"string"},"type":"array","minItems":1,"title":"Candidate Retriever Ids","description":"IDs of candidate retriever pipelines to evaluate."},"session_filter":{"anyOf":[{"$ref":"#/components/schemas/SessionFilter-Input"},{"type":"null"}],"description":"Optional filter criteria for selecting sessions to replay."},"session_count":{"type":"integer","maximum":10000.0,"minimum":10.0,"title":"Session Count","description":"Number of sessions to include in the benchmark.","default":1000}},"type":"object","required":["benchmark_name","baseline_retriever_id","candidate_retriever_ids"],"title":"CreateBenchmarkRequest","description":"Request to create a new benchmark run."},"CreateBlobRequest":{"properties":{"property":{"type":"string","maxLength":100,"minLength":1,"title":"Property","description":"REQUIRED. Property name from the bucket schema that this blob belongs to. Must match a field defined in the bucket's schema. Used to validate blob type compatibility and determine storage path. Common values: 'video', 'thumbnail', 'transcript', 'document', 'image'","examples":["video","thumbnail","transcript","image","document"]},"key_prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Key Prefix","description":"OPTIONAL. Storage path prefix for organizing blobs within the bucket. If not provided, uses default bucket organization. Use for: grouping blobs by campaign, date, category, etc. Example: 'campaigns/summer_2025' or 'products/electronics'","examples":["campaigns/summer_2025","products/electronics","2025/Q4"]},"type":{"$ref":"#/components/schemas/BucketSchemaFieldType","description":"REQUIRED. The schema field type for this blob. Must match the bucket schema definition for the property. Determines validation rules and processing pipeline. Common types: IMAGE, VIDEO, AUDIO, PDF, DOCUMENT, TEXT","examples":["VIDEO","IMAGE","PDF","AUDIO","TEXT","DOCUMENT"]},"data":{"anyOf":[{"type":"string","maxLength":2083,"minLength":1,"format":"uri"},{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"additionalProperties":true,"type":"object"},{"items":{},"type":"array"},{"type":"null"}],"title":"Data","description":"EITHER data OR upload_id must be provided (mutually exclusive). \n\nFile data in one of several INTERCHANGEABLE formats: \n\n**Format 1: URL String (HTTP/HTTPS/S3)** - Direct URL to file on the web or in S3 - Examples: 'https://example.com/video.mp4', 's3://bucket/key' - Use for: Public files, existing S3 objects, pre-signed URLs - File is downloaded and uploaded to internal S3 (if canonicalize_source=True) \n\n**Format 2: Data URI String (base64)** - Self-contained base64 data with MIME type - Format: 'data:<mime_type>;base64,<encoded_data>' - Example: 'data:image/jpeg;base64,/9j/4AAQSkZJRg...' - Use for: Small files (<5MB), mobile uploads, inline test data - MIME type automatically extracted from URI - Data is decoded, validated, and uploaded to S3 automatically \n\n**Format 3: Base64 Dictionary** - Structured format with explicit metadata - Required keys: 'base64' (encoded data) - Optional keys: 'mime_type', 'filename' - Example: {'base64': '/9j/4AAQ...', 'mime_type': 'image/jpeg', 'filename': 'photo.jpg'} - Use for: When you need explicit MIME type control - Data is decoded, validated, and uploaded to S3 automatically \n\n**Format 4: URL Dictionary** - Structured format for URL references - Required keys: 'url' - Example: {'url': 'https://example.com/file.jpg'} - Use for: Consistency with other dict formats \n\n**Format 5: Inline Text (type text only)** - The text itself, as a plain string - Example: {'property': 'content', 'type': 'text', 'data': 'The quarterly report is due Friday.'} - {'text': 'The quarterly report is due Friday.'} is accepted as well - A string that starts with 'http://', 'https://' or 's3://' is read as a URL (Format 1) - A bare base64 string that decodes to readable text is rejected with a 422. For encoded text send Format 2 ('data:text/plain;base64,<encoded_data>') or Format 3 with 'mime_type': 'text/plain' - Use for: Notes, captions, descriptions and other short text you already hold in memory - The text is also written to a file in Mixpeek storage when it is 5 MB or smaller, so extractors that read files can use it \n\n**Processing:** All formats are converted to internal S3 URLs before storage. The engine always receives S3 URLs regardless of input format. \n\n**Size Limits (Base64 only):** Base64 data: 5MB (free), 10MB (pro), 50MB (enterprise). URLs: No limit (downloaded on-demand). For files exceeding limits, use presigned upload workflow: POST /buckets/{id}/uploads \n\n**Validation:** - Base64: Encoding validated, MIME type detected, size checked - URLs: Accessibility verified, content-type validated - All: Schema type compatibility enforced","examples":["https://example.com/video.mp4","s3://my-bucket/path/to/image.jpg","data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==",{"base64":"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==","mime_type":"image/png"},{"base64":"/9j/4AAQSkZJRg...","filename":"photo.jpg","mime_type":"image/jpeg"},{"url":"https://cdn.example.com/files/document.pdf"},"Wireless headphones with active noise cancellation"]},"upload_id":{"anyOf":[{"type":"string","pattern":"^upl_[a-zA-Z0-9_-]+$"},{"type":"null"}],"title":"Upload Id","description":"EITHER upload_id OR data must be provided. Reference to an existing upload from the presigned URL workflow. \n\nPresigned URLs come from POST /v1/buckets/{bucket_id}/uploads, which handles presigned URL generation, upload tracking, and validation. \n\nWorkflow: 1. POST /v1/buckets/{bucket_id}/uploads → {upload_id, presigned_url} 2. User uploads file to presigned_url 3. POST /v1/buckets/{bucket_id}/uploads/{upload_id}/confirm → Validates upload 4. Use upload_id here to reference the uploaded file \n\nThe upload must be in CONFIRMED or ACTIVE status. Format: 'upl_' prefix followed by alphanumeric characters. \n\nUse Cases: - Combine multiple uploads into one object - Upload files in parallel, create object later - Reuse same upload across multiple objects \n\nSee: api/buckets/uploads/ for the complete upload system","examples":["upl_abc123def456","upl_xyz789"]},"checksum":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Checksum","description":"OPTIONAL. Content hash of the blob bytes, propagated verbatim to the system-generated `details.hash` on the stored blob (DM-1 content addressing). Format: 'algorithm:hash' (e.g. 'sha256:abc123...'); a bare 64-char hex string is accepted and normalized to 'sha256:<hex>'. A malformed value is rejected loudly (422) rather than silently dropped. When omitted, the platform fills `details.hash` itself wherever it touches the bytes (inline-text persistence, storage sync downloads).","examples":["sha256:a1b2c3d4e5f6...","md5:9e107d9d372bb6826bd81d3542a419d6"]},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Per-blob metadata. Promoted onto the object root at ingest so it reaches the processed document via field passthrough. Precedence: an explicit object-root field wins over a blob metadata key of the same name; across multiple blobs the first blob to set a key wins; system/reserved field names (object_id, collection_id, _internal, ...) are never overwritten. Put shared metadata at the object root directly; use blob metadata for per-blob attributes."},"canonicalize_source":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Canonicalize Source","description":"If set, override object-level default to control source canonicalization for this blob."},"force_remirror":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Force Remirror","description":"If set, override object-level default to force re-upload even if an identical blob exists."}},"type":"object","required":["property","type"],"title":"CreateBlobRequest","description":"Request model for creating a new blob.\n\n⚠️  IMPORTANT: For presigned URL uploads, use the existing /buckets/{id}/uploads system!\n    DO NOT create a new presigned upload endpoint - one already exists.\n\nSupports two modes:\n\nMode 1: Direct Data Upload\n    - Provide 'data' field with a URL, base64 content, or (for a text blob) the text itself\n    - File is processed immediately during object creation\n    - Use for: Small files, public URLs, inline data\n\nMode 2: Upload Reference (Recommended for large files)\n    - First: POST /buckets/{id}/uploads → Returns presigned_url + upload_id\n    - User uploads file directly to S3 via presigned_url\n    - Then: POST /v1/buckets/{bucket_id}/uploads/{upload_id}/confirm → Validates upload\n    - Finally: Reference upload_id in this blob request\n    - Use for: Large files, client-side uploads, multi-blob objects\n\nWhy upload_id?\n    - Combine multiple uploads into one object\n    - Upload files in parallel, create object later\n    - Reuse uploads across multiple objects\n    - Better UX: upload progress, retry logic, validation\n\nRelated Endpoints:\n    - POST /buckets/{id}/uploads - Generate presigned URLs (EXISTING SYSTEM)\n    - POST /v1/buckets/{bucket_id}/uploads/{upload_id}/confirm - Confirm upload completed\n    - See: api/buckets/uploads/services.py for full upload workflow\n\nExamples:\n    # Direct data (simple)\n    {\n      \"property\": \"thumbnail\",\n      \"type\": \"IMAGE\",\n      \"data\": \"https://example.com/image.jpg\"\n    }\n\n    # Upload reference (recommended)\n    {\n      \"property\": \"video\",\n      \"type\": \"VIDEO\",\n      \"upload_id\": \"upl_abc123\"  # From /uploads endpoint\n    }\n\n    # Multiple uploads → one object\n    {\n      \"blobs\": [\n        {\"property\": \"video\", \"upload_id\": \"upl_video123\"},\n        {\"property\": \"thumbnail\", \"upload_id\": \"upl_thumb456\"},\n        {\"property\": \"transcript\", \"upload_id\": \"upl_trans789\"}\n      ]\n    }","examples":[{"data":"https://example.com/image.jpg","description":"Direct data upload - Simple image from URL","metadata":{"alt_text":"Product thumbnail"},"property":"thumbnail","type":"IMAGE"},{"data":"data:image/jpeg;base64,/9j/4AAQSkZJRgABAQEAYABgAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAxNDQ0Hyc5PTgyPC4zNDL/wAARCAABAAEDASIAAhEBAxEB/8QAFQABAQAAAAAAAAAAAAAAAAAAAAv/xAAUEQEAAAAAAAAAAAAAAAAAAAAA/9oADAMBAAIRAxEAPwCwAA//2Q==","description":"Data URI upload - Mobile camera photo","metadata":{"device":"iPhone 13","location":"Store #42"},"property":"photo","type":"IMAGE"},{"data":{"base64":"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==","filename":"sales-chart-2025-11.png","mime_type":"image/png"},"description":"Base64 dict upload - Programmatically generated image","metadata":{"chart_type":"line","generated_at":"2025-11-08T10:30:00Z"},"property":"chart","type":"IMAGE"},{"description":"Upload reference - Video from presigned upload","metadata":{"duration_seconds":120},"property":"video","type":"VIDEO","upload_id":"upl_abc123def456"},{"canonicalize_source":false,"data":"s3://my-bucket/documents/contract-2025.pdf","description":"S3 reference - Existing object","metadata":{"department":"Legal","year":2025},"property":"archive","type":"PDF"},{"description":"Multiple uploads in one object - one blob of a media package","note":"Send one entry like this per file in the object's blobs array","property":"transcript","type":"TEXT","upload_id":"upl_trans789"}]},"CreateBroadcastRequest":{"properties":{"body":{"type":"string","maxLength":10000,"minLength":1,"title":"Body"},"scope":{"anyOf":[{"$ref":"#/components/schemas/SupportScope"},{"type":"null"}]},"organization_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Id"}},"type":"object","required":["body"],"title":"CreateBroadcastRequest","description":"Admin-only: a standalone communication not attached to a ticket."},"CreateCheckoutRequest":{"properties":{"package":{"type":"string","title":"Package","description":"Credit package to purchase: starter, growth, or scale","examples":["starter","growth","scale"]},"success_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Success Url","description":"Redirect URL after successful payment","default":"https://studio.mixpeek.com/billing?checkout=success"},"cancel_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cancel Url","description":"Redirect URL if checkout is cancelled","default":"https://studio.mixpeek.com/billing?checkout=cancelled"}},"type":"object","required":["package"],"title":"CreateCheckoutRequest","description":"Request to create a Stripe Checkout Session for credit purchase."},"CreateCheckoutResponse":{"properties":{"checkout_url":{"type":"string","title":"Checkout Url","description":"Stripe-hosted checkout page URL","examples":["https://checkout.stripe.com/c/pay/cs_live_abc123"]},"session_id":{"type":"string","title":"Session Id","description":"Stripe Checkout Session ID","examples":["cs_live_abc123"]}},"type":"object","required":["checkout_url","session_id"],"title":"CreateCheckoutResponse","description":"Response with Stripe Checkout Session URL."},"CreateClusterRequest":{"properties":{"collection_ids":{"anyOf":[{"items":{"type":"string"},"type":"array","minItems":1},{"type":"null"}],"title":"Collection Ids","description":"Collections to cluster together. Required unless source_cluster_ids is set, in which case it defaults to the source clusters' input collections."},"source_cluster_ids":{"anyOf":[{"items":{"type":"string"},"type":"array","minItems":1},{"type":"null"}],"title":"Source Cluster Ids","description":"Makes this a composite cluster: it groups the centroids of these clusters' runs instead of documents. Each id must be a vector cluster in this namespace with the same feature_uris as this one. Executing a composite cluster without a mode runs mode 'composite' over the newest completed run of each source cluster, one per partition (a partition is a run's filters). Vector clusters only."},"cluster_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cluster Name","description":"Optional human-friendly name for the clustering job"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Optional description of the cluster, stored with it"},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Optional caller metadata, stored with the cluster"},"cluster_type":{"$ref":"#/components/schemas/ClusterType","description":"Vector or attribute clustering","default":"vector"},"vector_config":{"anyOf":[{"$ref":"#/components/schemas/VectorBasedConfig-Input"},{"type":"null"}],"description":"Required when cluster_type is 'vector'"},"attribute_config":{"anyOf":[{"$ref":"#/components/schemas/AttributeBasedConfig"},{"type":"null"}],"description":"Required when cluster_type is 'attribute'"},"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"Optional filters to pre-filter documents before clustering (same format as list documents). Applied during the vector store scroll before parquet export. Useful for clustering subsets like: status='active', category='electronics', etc."},"llm_labeling":{"anyOf":[{"$ref":"#/components/schemas/LLMLabeling-Input"},{"type":"null"}],"description":"Optional configuration for LLM-based cluster labeling. When provided with enabled=True, clusters will have semantic labels generated by LLM instead of generic labels like 'Cluster 0'. When not provided or enabled=False, uses fallback labels."},"enrich_source_collection":{"type":"boolean","title":"Enrich Source Collection","description":"If True, cluster results are written back to source collection(s) in-place instead of creating new output collections. Documents will be enriched with cluster_id, cluster_label, distance_to_centroid, and optionally other metadata. Similar to taxonomy enrichment pattern.","default":false},"source_enrichment_config":{"anyOf":[{"$ref":"#/components/schemas/SourceEnrichmentConfig"},{"type":"null"}],"description":"Configuration for source collection enrichment (only used if enrich_source_collection=True). Controls which fields are added to source documents and field naming conventions."},"auto_execute_on_batch":{"type":"boolean","title":"Auto Execute On Batch","description":"Automatically execute this cluster whenever a batch completes on any of its input collections. When True, a ClusterApplicationConfig entry is added to each input collection's cluster_applications field at creation time. The cluster will then auto-trigger after each batch completion (subject to cooldown and document threshold). When False (default), the cluster must be executed manually via the API.","default":false},"auto_execute_min_documents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Auto Execute Min Documents","description":"Minimum number of documents required before auto-executing cluster. Only used when auto_execute_on_batch=True. If the collection has fewer documents than this threshold, clustering is skipped."},"auto_execute_cooldown_seconds":{"type":"integer","title":"Auto Execute Cooldown Seconds","description":"Minimum time (in seconds) between automatic cluster executions. Only used when auto_execute_on_batch=True. Default: 3600 (1 hour).","default":3600}},"type":"object","title":"CreateClusterRequest","description":"Create a clustering job for one or more collections.","examples":[{"cluster_name":"products_clip_hdbscan","cluster_type":"vector","collection_ids":["col_products_v1","col_products_v2"],"llm_labeling":{"enabled":true,"labeling_inputs":{"input_mappings":[{"input_key":"text","path":"description","source_type":"payload"}]},"model_name":"gpt-4o-mini-2024-07-18","provider":"openai"},"vector_config":{"clustering_method":"hdbscan","feature_uri":"mixpeek://clip_vit_l_14@v1/embedding","hdbscan_parameters":{"min_cluster_size":10,"min_samples":5},"sample_size":5000}},{"cluster_name":"video_multimodal_clustering","cluster_type":"vector","collection_ids":["col_videos_v1"],"llm_labeling":{"enabled":true,"include_keywords":true,"include_summary":true,"labeling_inputs":{"input_mappings":[{"input_key":"text","path":"title","source_type":"payload"},{"input_key":"video_url","path":"video_url","source_type":"payload"}]},"model_name":"gemini-3.5-flash-lite","provider":"google"},"vector_config":{"clustering_method":"hdbscan","feature_uri":"mixpeek://clip_vit_l_14@v1/embedding","hdbscan_parameters":{"min_cluster_size":5,"min_samples":3},"sample_size":3000}},{"cluster_name":"image_multimodal_clustering","cluster_type":"vector","collection_ids":["col_images_v1"],"llm_labeling":{"enabled":true,"labeling_inputs":{"input_mappings":[{"input_key":"text","path":"caption","source_type":"payload"},{"input_key":"image_url","path":"image_url","source_type":"payload"}]},"model_name":"gemini-3.5-flash-lite","provider":"google"},"vector_config":{"clustering_method":"kmeans","feature_uri":"mixpeek://clip_vit_l_14@v1/embedding","kmeans_parameters":{"n_clusters":10},"sample_size":2000}},{"attribute_config":{"attributes":["status"],"hierarchical_grouping":true},"cluster_name":"orders_group_by_status","cluster_type":"attribute","collection_ids":["col_orders_v1","col_orders_v2","col_orders_v3"]}]},"CreateCollectionRequest":{"properties":{"collection_name":{"type":"string","title":"Collection Name","description":"Name of the collection to create","examples":["video_frames","product_embeddings"]},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Description of the collection"},"source":{"$ref":"#/components/schemas/SourceConfig-Input","description":"Source configuration (bucket or collection) for this collection"},"input_schema":{"anyOf":[{"$ref":"#/components/schemas/BucketSchema-Input"},{"type":"null"}],"description":"Input schema for the collection. If not provided, inferred from source bucket's bucket_schema or source collection's output_schema. REQUIRED for input_mappings to work - defines what fields can be mapped to feature extractors."},"feature_extractor":{"anyOf":[{"$ref":"#/components/schemas/shared__collection__features__extractors__models__FeatureExtractorConfig-Input"},{"type":"null"}],"description":"Single feature extractor for this collection. Use field_passthrough within the extractor config to include additional source fields. For multiple extractors, create multiple collections and use collection-to-collection pipelines. DEPRECATED for direct use: prefer `features: [...]` (contract v2 §6.2, D9) — extractor names are internal implementation. MUTUALLY EXCLUSIVE with `retriever_transform` (provide exactly one)."},"features":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Features","description":"What you want to search by: feature keys from GET /v1/collections/features (e.g. ['faces'] or ['custom:<plugin>']). Resolved to the processing pipeline server-side — the preferred alternative to `feature_extractor`. Provide one or the other."},"enabled":{"type":"boolean","title":"Enabled","description":"Whether the collection is enabled","default":true},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Additional metadata for the collection"},"schedule":{"anyOf":[{"$ref":"#/components/schemas/CollectionScheduleConfig"},{"type":"null"}],"description":"Optional schedule for automatic re-processing. Creates a COLLECTION_TRIGGER trigger behind the scenes. Supports cron and interval schedules."},"taxonomy_applications":{"anyOf":[{"items":{"$ref":"#/components/schemas/TaxonomyApplicationConfig-Input"},"type":"array"},{"type":"null"}],"title":"Taxonomy Applications","description":"Optional taxonomy applications to automatically enrich documents in this collection. Each taxonomy will classify/enrich documents based on configured retriever matches."},"cluster_applications":{"anyOf":[{"items":{"$ref":"#/components/schemas/ClusterApplicationConfig"},"type":"array"},{"type":"null"}],"title":"Cluster Applications","description":"Optional cluster applications to automatically execute when batch processing completes. Each cluster enriches documents with cluster assignments (cluster_id, cluster_label, etc.)."},"alert_applications":{"anyOf":[{"items":{"$ref":"#/components/schemas/AlertApplicationConfig-Input"},"type":"array"},{"type":"null"}],"title":"Alert Applications","description":"Optional alert applications to automatically execute when documents are ingested. Each alert runs a retriever against new documents and sends notifications if matches are found. Supports both ON_INGEST (triggered per batch) and SCHEDULED (periodic) execution modes."},"retriever_enrichments":{"anyOf":[{"items":{"$ref":"#/components/schemas/RetrieverEnrichmentConfig-Input"},"type":"array"},{"type":"null"}],"title":"Retriever Enrichments","description":"Optional retriever enrichments to run on documents during post-processing. Each enrichment executes a retriever pipeline and writes selected result fields back to the document. Use for: LLM classification, cross-collection joins, multi-stage enrichment at ingestion time."},"retriever_transform":{"anyOf":[{"$ref":"#/components/schemas/RetrieverTransformConfig-Input"},{"type":"null"}],"description":"(#11): define this collection's BUILD STEP as an inline retriever pipeline run over its source (a materialized view). MUTUALLY EXCLUSIVE with feature_extractor/features — a collection is EITHER extractor-based OR transform-based. The source may be a collection or a bucket; a bucket is read through its system collection, one document per object, scoped to the objects in each batch. Distinct from retriever_enrichments (per-document post-processing referencing an existing retriever_id)."},"embedding_task":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Embedding Task","description":"Override the embedding task hint for instruction-aware models (E5, Gemini). Defaults to 'retrieval_document' for indexing pipelines. Values: retrieval_document, retrieval_query, semantic_similarity, classification, clustering. Only change this if your primary use case is not retrieval (e.g., clustering or classification). Applied to all task-aware embedding models in this collection's extractor pipeline."}},"type":"object","required":["collection_name","source"],"title":"CreateCollectionRequest","description":"Request model for creating a new collection.\n\nCollections process data from buckets or other collections using a single feature extractor.\n\nKEY ARCHITECTURAL CHANGE: Each collection has EXACTLY ONE feature extractor.\n- Use field_passthrough to include additional source fields in output documents\n- Multiple extractors = multiple collections\n- This simplifies processing and makes output schema deterministic\n\nCRITICAL: To use input_mappings:\n1. Your source bucket MUST have a bucket_schema defined\n2. The input_mappings reference fields from that bucket_schema\n3. The system validates that mapped fields exist in the source schema\n\nExample workflow:\n1. Create bucket with schema: { \"properties\": { \"image\": {\"type\": \"image\"}, \"title\": {\"type\": \"string\"} } }\n2. Upload objects conforming to that schema\n3. Create collection with:\n   - input_mappings: { \"image\": \"image\" }\n   - field_passthrough: [{\"source_path\": \"title\"}]\n4. Output documents will have both extractor outputs AND passthrough fields\n\nSchema Computation:\n- output_schema is computed IMMEDIATELY when collection is created\n- output_schema = field_passthrough fields + extractor output fields\n- No waiting for documents to be processed!","examples":[{"collection_name":"product_embeddings","description":"Generate image embeddings with passthrough fields","enabled":true,"feature_extractor":{"feature_extractor_name":"image_extractor","field_passthrough":[{"required":true,"source_path":"title"},{"source_path":"category"}],"input_mappings":{"image":"product_image"},"parameters":{"model":"clip-vit-base-patch32"},"version":"v1"},"source":{"bucket_ids":["bkt_products"],"type":"bucket"}},{"collection_name":"video_frames","description":"Extract frames from videos with metadata passthrough","feature_extractor":{"feature_extractor_name":"multimodal_extractor","field_passthrough":[{"source_path":"campaign_id"},{"source_path":"duration_seconds"}],"input_mappings":{"video":"video_url"},"parameters":{"fps":1},"version":"v1"},"source":{"bucket_ids":["bkt_videos"],"type":"bucket"}},{"collection_name":"scenes_from_frames","description":"Detect scenes from frame collection (collection-to-collection)","feature_extractor":{"feature_extractor_name":"scene_detector","field_passthrough":[{"source_path":"campaign_id"}],"input_mappings":{"image":"frame_url"},"version":"v1"},"source":{"collection_id":"col_video_frames","type":"collection"}}]},"CreateDatasetRequest":{"properties":{"dataset_name":{"type":"string","maxLength":200,"minLength":1,"title":"Dataset Name","description":"Unique name for this dataset"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Description of what this dataset measures"},"queries":{"items":{"$ref":"#/components/schemas/GroundTruthQuery"},"type":"array","minItems":1,"title":"Queries","description":"List of queries with ground truth relevance labels"},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Additional metadata"},"relevance_field":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Relevance Field","description":"Grade by this field of each result instead of its document id, for a retriever that groups documents (reduce or group_by). relevant_documents then lists values of the field, and results that share a value count once. Dotted paths reach nested fields, e.g. 'metadata.frame_key'.","examples":["metadata.frame_key"]}},"type":"object","required":["dataset_name","queries"],"title":"CreateDatasetRequest","description":"Request model for creating a new evaluation dataset."},"CreateMessageRequest":{"properties":{"body":{"type":"string","maxLength":10000,"minLength":1,"title":"Body"},"author_type":{"anyOf":[{"$ref":"#/components/schemas/SupportAuthorType"},{"type":"null"}]},"attachments":{"items":{"$ref":"#/components/schemas/SupportAttachment"},"type":"array","title":"Attachments"}},"type":"object","required":["body"],"title":"CreateMessageRequest"},"CreateMigrationRequest":{"properties":{"config":{"$ref":"#/components/schemas/MigrationConfig","description":"Migration configuration"},"start_immediately":{"type":"boolean","title":"Start Immediately","description":"Start execution immediately after validation","default":false}},"type":"object","required":["config"],"title":"CreateMigrationRequest","description":"Request to create a new migration.","example":{"config":{"feature_extractors":[{"feature_extractor_name":"openai_text_embedding","parameters":{"model":"text-embedding-3-large"},"version":"v3"}],"migration_type":"re_extract","source_namespace_id":"ns_abc123","target_namespace_name":"my_namespace_v2"},"start_immediately":false}},"CreateMigrationResponse":{"properties":{"migration_id":{"type":"string","title":"Migration Id","description":"Created migration ID"},"status":{"$ref":"#/components/schemas/MigrationStatus","description":"Current status"},"validation_result":{"anyOf":[{"$ref":"#/components/schemas/ValidationResult"},{"type":"null"}],"description":"Validation result if available"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"message":{"type":"string","title":"Message","description":"Human-readable message"}},"type":"object","required":["migration_id","status","created_at","message"],"title":"CreateMigrationResponse","description":"Response after creating a migration.","example":{"created_at":"2025-12-03T10:00:00Z","message":"Migration created successfully. Use POST /migrations/{id}/start to begin execution.","migration_id":"mig_abc123xyz789","status":"draft","validation_result":{"errors":[],"estimated_duration_seconds":1800,"estimated_resources":{"cluster":1,"collection":5,"taxonomy":2},"valid":true,"warnings":[]}}},"CreateModelUploadRequest":{"properties":{"name":{"type":"string","pattern":"^[a-zA-Z][a-zA-Z0-9_]{2,63}$","title":"Name","description":"Model name: 3-64 chars, letters/numbers/underscores, starts with a letter (no hyphens or spaces)","examples":["custom_embedder","sentiment_model","image_classifier"]},"version":{"type":"string","pattern":"^\\d+\\.\\d+\\.\\d+$","title":"Version","description":"Semantic version string","examples":["1.0.0","2.1.3","0.0.1"]},"model_format":{"type":"string","enum":["safetensors","onnx","pytorch","huggingface"],"title":"Model Format","description":"Format of the model weights","examples":["safetensors","onnx","pytorch","huggingface"]},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description","description":"Optional description of the model"},"file_size_bytes":{"anyOf":[{"type":"integer","maximum":5368709120.0,"exclusiveMinimum":0.0},{"type":"null"}],"title":"File Size Bytes","description":"Expected file size in bytes for quota validation"},"presigned_url_expiration":{"type":"integer","maximum":86400.0,"minimum":60.0,"title":"Presigned Url Expiration","description":"Presigned URL expiration time in seconds (1-24 hours)","default":3600},"resource_requirements":{"$ref":"#/components/schemas/ModelResourceRequirements","description":"Resource requirements for model deployment"},"framework":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Framework","description":"ML framework (e.g., sentence-transformers, transformers)"},"task_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Type","description":"Task type (e.g., embedding, classification, generation)"},"source":{"type":"string","enum":["customer","mixpeek","system"],"title":"Source","description":"Who is uploading: 'customer' (default) or 'mixpeek' (professional services). Mixpeek-sourced models are non-exportable by default.","default":"customer"}},"type":"object","required":["name","version","model_format"],"title":"CreateModelUploadRequest","description":"Request to generate a presigned URL for model archive upload.\n\nThis is step 1 of the presigned URL workflow:\n1. POST /models/uploads → Returns presigned_url + upload_id\n2. PUT presigned_url with model archive (client uploads directly to S3)\n3. POST /models/uploads/{upload_id}/confirm → Validates and creates model\n\nRequirements:\n    - name: Model name (e.g., 'my_custom_embedder')\n    - version: Semantic version (e.g., '1.0.0')\n    - model_format: Format of the model weights\n    - file_size_bytes: Expected archive size for quota validation"},"CreateNamespaceRequest":{"properties":{"namespace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Namespace Id","description":"Optional namespace ID override. Used for recovery/migration when recreating a namespace with a known ID. If not provided, a new ID is auto-generated."},"namespace_name":{"type":"string","maxLength":64,"minLength":3,"title":"Namespace Name","description":"Name of the namespace to create","example":"product-search"},"mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mode","description":"Namespace mode. 'managed' (default) uses Mixpeek feature extractors. 'standalone' allows BYO vectors without extractors. If omitted and ONLY `vector_configs` is provided (no `features`/`feature_extractors`), standalone is inferred.","default":"managed"},"namespace_type":{"anyOf":[{"$ref":"#/components/schemas/NamespaceType"},{"type":"null"}],"description":"Type of namespace. STANDARD for regular namespaces, MARKETPLACE for curated datasets.","default":"standard"},"scope":{"anyOf":[{"$ref":"#/components/schemas/NamespaceScope"},{"type":"null"}],"description":"Ownership scope. ORG (default) creates an org-scoped namespace. SYSTEM requires Mixpeek admin privileges and creates a namespace visible read-only to every org — used for curated sample corpora.","default":"org"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Description of the namespace","example":"This namespace contains playlists from Spotify"},"starred":{"type":"boolean","title":"Starred","description":"Show this namespace at the top of the organization's namespace list. Free, and it has no effect on capacity or billing.","default":false},"features":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Features","description":"Modality+features config (contract v2 §6.2, D9): feature keys from GET /v1/collections/features (e.g. ['image_search', 'faces'] or ['custom:<plugin>']). Resolved server-side to the UNION of feature extractors the namespace needs — the preferred alternative to `feature_extractors` (extractor names are internal implementation). A namespace hosts many collections, so multiple features spanning multiple extractors are fine here. May be combined with `feature_extractors` (the two merge as a union). If neither is provided, the namespace gets the standard baseline (same as the scaffolded default namespace). Managed mode only.","examples":[["image_search","text_search","faces"]]},"feature_extractors":{"anyOf":[{"items":{"$ref":"#/components/schemas/BaseFeatureExtractorModel-Input"},"type":"array"},{"type":"null"}],"title":"Feature Extractors","description":"List of feature extractors to configure for this namespace. DEPRECATED for direct use: prefer `features: [...]` (contract v2 §6.2, D9) — extractor names are internal implementation. Not used for standalone mode. If neither `features` nor `feature_extractors` is provided, the namespace defaults to the standard baseline. Each extractor requires 'feature_extractor_name' and 'version'. Optional 'params' can be specified for extractors with configurable settings (e.g., model selection) that affect vector dimensions. These params are locked at namespace creation time. Example: [{\"feature_extractor_name\": \"multimodal_extractor\", \"version\": \"v1\"}]","examples":[[{"feature_extractor_name":"multimodal_extractor","version":"v1"},{"feature_extractor_name":"image_extractor","params":{"model":"siglip_base"},"version":"v1"}]]},"vector_configs":{"anyOf":[{"items":{"$ref":"#/components/schemas/VectorConfigSpec"},"type":"array"},{"type":"null"}],"title":"Vector Configs","description":"Optional vector index configurations for standalone mode. Each entry defines a named vector index with dimension and distance metric. If omitted, indexes are auto-created on first upsert (schema-on-write).","examples":[[{"dimension":768,"metric":"cosine","name":"clip"}]]},"payload_indexes":{"anyOf":[{"items":{"$ref":"#/components/schemas/PayloadIndexConfig-Input"},"type":"array"},{"type":"null"}],"title":"Payload Indexes","description":"Optional list of custom payload index configurations. Indexes required by selected feature extractors will be added automatically.","example":[{"field_name":"metadata.title","field_schema":{"lowercase":true,"max_token_len":15,"min_token_len":2,"tokenizer":"word","type":"text"},"is_protected":false,"type":"text"},{"field_name":"metadata.description","field_schema":{"is_tenant":true,"type":"keyword"},"is_protected":false,"type":"keyword"}]},"auto_create_indexes":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Auto Create Indexes","description":"Enable automatic creation of vector store payload indexes based on filter usage patterns. When enabled, the system tracks which fields are most frequently filtered (>100 queries/24h) and automatically creates indexes to improve query performance. Background task runs every 6 hours. Expected performance improvement: 50-90% latency reduction for filtered queries. Defaults: managed namespaces off, standalone namespaces on. Set explicitly to false to opt out (including for standalone, so an agent can manage indexes itself).","example":true},"adaptive_indexing":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Adaptive Indexing","description":"Let the vector index re-tune its own partition size and flush threshold from observed search latency. Off by default. When on, every change it makes is recorded in the namespace's mxp_platform_events collection (event_type index_adaptation) with the parameter, its old and new value, the search count that triggered it, and p95 search latency before and after.","example":false},"ttl_seconds":{"anyOf":[{"type":"integer","minimum":60.0},{"type":"null"}],"title":"Ttl Seconds","description":"Time-to-live in seconds. Namespace will be auto-deleted after this duration."},"infrastructure":{"anyOf":[{"$ref":"#/components/schemas/NamespaceInfrastructure"},{"type":"null"}],"description":"Optional dedicated infrastructure configuration for this namespace. Required for custom plugins and custom models (Enterprise tier). If None, uses shared infrastructure or organization-level infrastructure."},"trusted_issuers":{"anyOf":[{"items":{"$ref":"#/components/schemas/NamespaceTrustedIssuer"},"type":"array","maxItems":5},{"type":"null"}],"title":"Trusted Issuers","description":"Identity providers whose end-user tokens (OIDC/JWT, verified against a JWKS) may call this namespace directly from a browser, each with the retrievers and collections it may use and the claims applied as filters. None or empty accepts no end-user tokens."},"tiering":{"anyOf":[{"$ref":"#/components/schemas/TieringOverride"},{"type":"null"}],"description":"This namespace's tiering override: enabled, idle_days {cold, frozen} and exempt (a reason). Each field left unset inherits the platform's data-class default, and each collection inherits from here. An exempt namespace is never demoted. The same override PATCH sets."},"spend_budget":{"anyOf":[{"$ref":"#/components/schemas/NamespaceSpendBudgetUpdate"},{"type":"null"}],"description":"Set this namespace's daily and monthly spend budget in USD. It must fit inside the organization's budget. A null field returns to the organization's namespace default. Each change is recorded with who made it, when, and the prior value."},"cost_cap_override":{"anyOf":[{"$ref":"#/components/schemas/NamespaceCostCapOverride"},{"type":"null"}],"description":"Start this namespace with an explicit daily inference cost cap instead of the tier default. Requires daily_usd, reason and owner."}},"type":"object","required":["namespace_name"],"title":"CreateNamespaceRequest","description":"Request schema for creating a new namespace.","examples":[{"features":["image_search","text_search","faces"],"namespace_name":"media_library"},{"feature_extractors":[{"feature_extractor_name":"multimodal_extractor","version":"v1"}],"namespace_name":"product_catalog"},{"description":"Video content with text and image embeddings","feature_extractors":[{"feature_extractor_name":"text_extractor","version":"v1"},{"feature_extractor_name":"image_extractor","version":"v1"}],"namespace_name":"video_library","payload_indexes":[{"field_name":"metadata.title","type":"text"}]}]},"CreateNodeFromDocumentsRequest":{"properties":{"node_label":{"type":"string","minLength":1,"title":"Node Label","description":"Label for the new node — the value copied onto documents that classify under it (canonical `label` field)."},"documents":{"items":{"$ref":"#/components/schemas/DocumentRef"},"type":"array","maxItems":200,"minItems":1,"title":"Documents","description":"Documents whose stored vectors define the node's anchor (centroid). 1-200 refs; for large selections send a sample — the centroid converges quickly."},"node_fields":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Node Fields","description":"Optional extra fields stored on the node document (e.g. `description`). Only fields listed in the taxonomy's enrichment_fields are copied during enrichment."},"vector_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vector Name","description":"Optional explicit vector (index) name for the anchor. If omitted, it is derived from the taxonomy's node collection vector indexes."},"provenance":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Provenance","description":"Optional freeform origin context (e.g. cluster_id, run_id, selection type). Stored on the node document under `metadata.promotion` for auditability."}},"type":"object","required":["node_label","documents"],"title":"CreateNodeFromDocumentsRequest","description":"Create a taxonomy node whose classification anchor derives from documents.\n\nMixpeek taxonomy nodes are documents in the taxonomy's source (node)\ncollection: at enrichment time, an incoming document's embedding queries\nthat collection through the taxonomy's retriever and the best-matching\nnode's fields (canonically `label`) are copied onto it.\n\nThis endpoint computes the CENTROID of the referenced documents' stored\nvectors and inserts it as a new node document — so future documents whose\nembeddings land near the referenced selection are classified under\n`node_label`. No re-embedding or GPU work happens; only stored vectors are\nread."},"CreateObjectRequest":{"properties":{"key_prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Key Prefix","description":"Storage key/path prefix of the object, this will be used to retrieve the object from the storage. It's at the root of the object.","examples":["/contract-2024"]},"blobs":{"items":{"$ref":"#/components/schemas/CreateBlobRequest"},"type":"array","title":"Blobs","description":"List of blobs to be created in this object"},"skip_duplicates":{"type":"boolean","title":"Skip Duplicates","description":"Skip duplicate blobs, if a blob with the same hash already exists, it will be skipped.","default":false},"canonicalize_source":{"type":"boolean","title":"Canonicalize Source","description":"Mirror non-S3 sources into internal S3 and reference canonically.","default":true},"force_remirror":{"type":"boolean","title":"Force Remirror","description":"Force re-upload to S3 even if a blob with identical content already exists.","default":false},"edges":{"items":{"$ref":"#/components/schemas/EdgeModel"},"type":"array","title":"Edges","description":"Typed, directed relationships from this object to other objects (customer-owned, root-level — never `_internal`). Populated by source adapters from companion/sidecar files, or directly on upsert. Flows to the document + MVS payload so the `traverse_edge` retriever stage can follow it."},"idempotency_key":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Idempotency Key","description":"Client-generated idempotency key for safe retries. If an object with the same idempotency_key already exists in this bucket, the existing object is returned instead of creating a duplicate. Use a UUID or deterministic hash per object."}},"additionalProperties":true,"type":"object","title":"CreateObjectRequest","description":"Request model for creating a bucket object.\n\nObjects can be created with blobs from two sources:\n1. Direct data (URLs, base64) - Use CreateBlobRequest.data field\n2. Upload references - Use CreateBlobRequest.upload_id field (from POST /buckets/{id}/uploads)\n\nUpload Reference Workflow:\n    For large files or client-side uploads, use the presigned URL workflow:\n    1. POST /buckets/{id}/uploads → Returns {upload_id, presigned_url}\n    2. User uploads file to presigned_url (client-side)\n    3. POST /uploads/{upload_id}/confirm → Validates upload\n    4. POST /buckets/{id}/objects with upload_id in blobs (this endpoint)\n\nUse Cases:\n    - Single blob with direct data (simple)\n    - Multiple blobs from presigned uploads (recommended for large files)\n    - Mix of direct data and upload references\n    - Combine multiple uploads into one object\n\na thin subclass of shared.buckets.objects.models.CreateObjectRequest.\nIt inherits the shared fields (key_prefix, blobs, skip_duplicates,\ncanonicalize_source, force_remirror) and the ONE canonical ``normalize_blobs``\nvalidator, adding only the api-surface fields below (idempotency_key, edges).\nBeing a subclass, the field surface can only be a SUPERSET of the shared model,\nso a consumer reading a field one twin declares can never find the other twin\nomitting it.\n\nSee Also:\n    - CreateBlobRequest for blob field documentation\n    - POST /buckets/{id}/uploads for presigned URL generation","example":{"blobs":[{"data":"https://example.com/contract-2024.pdf","key_prefix":"/contract-2024/content.pdf","metadata":{"author":"John Doe","department":"Legal","num_pages":5},"property":"content","type":"pdf"},{"data":{"filename":"https://example.com/images/smartphone-x1.jpg","mime_type":"image/jpeg"},"key_prefix":"/contract-2024/thumbnail.jpg","metadata":{"height":300,"width":200},"property":"thumbnail","type":"image"}],"category":"contracts","key_prefix":"/documents","title":"Service Agreement 2024","year":2024}},"CreateObjectsBatchRequest":{"properties":{"objects":{"items":{"$ref":"#/components/schemas/CreateObjectRequest"},"type":"array","maxItems":100,"title":"Objects","description":"List of objects to be created in this batch (max 100)."}},"type":"object","required":["objects"],"title":"CreateObjectsBatchRequest","description":"Request model for creating multiple bucket objects in a batch.","examples":[{"objects":[{"blobs":[{"data":"https://example.com/contract-2024.pdf","key_prefix":"/contract-2024/content.pdf","metadata":{"author":"John Doe","department":"Legal","num_pages":5},"property":"content","type":"pdf"}],"category":"contracts","key_prefix":"/documents","review_status":"draft","title":"Service Agreement 2024","year":2024}]}]},"CreateObjectsBatchResponse":{"properties":{"succeeded":{"items":{"$ref":"#/components/schemas/BatchObjectResult"},"type":"array","title":"Succeeded","description":"Objects for the requests that succeeded, in request order. A row with replayed true is an existing object returned for a reused idempotency_key or a skip_duplicates match."},"failed":{"items":{"$ref":"#/components/schemas/FailedObjectError"},"type":"array","title":"Failed","description":"List of objects that failed to create with error details"},"total_requested":{"type":"integer","title":"Total Requested","description":"Total number of objects in the batch request"},"succeeded_count":{"type":"integer","title":"Succeeded Count","description":"Number of objects successfully created"},"failed_count":{"type":"integer","title":"Failed Count","description":"Number of objects that failed"}},"type":"object","required":["succeeded","failed","total_requested","succeeded_count","failed_count"],"title":"CreateObjectsBatchResponse","description":"Response model for batch object creation with partial success support.\n\nThis endpoint uses partial success: valid objects are created even if some fail.\nFailed objects are tracked separately so users can fix and retry them.","examples":[{"failed":[{"error":"Schema validation failed: Missing required field 'title'","error_type":"ValidationError","object_index":15}],"failed_count":1,"succeeded":[{"bucket_id":"bkt_9xy8z7","object_id":"obj_123abc","status":"PENDING"}],"succeeded_count":99,"total_requested":100}]},"CreateRetrieverAPIKeyRequest":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Human-friendly key label for identification."},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description","description":"Optional description explaining the key's purpose."},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At","description":"Optional UTC timestamp when the key automatically expires."},"allowed_origins":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Allowed Origins","description":"Optional list of allowed HTTP origins for this API key. When set, browser requests must include a matching Origin header. Supports exact matches and wildcard subdomains (e.g., 'https://*.example.com'). Defense-in-depth: Origin headers can be spoofed from non-browser contexts.","examples":[["https://docs.example.com","https://*.example.com"]]}},"type":"object","required":["name"],"title":"CreateRetrieverAPIKeyRequest","description":"Request payload for creating a retriever-scoped API key.\n\nRetriever keys are automatically scoped to execute a specific retriever.\nThe scope and permissions are auto-populated by the service layer and cannot be modified.\n\nExample:\n    {\n        \"name\": \"production-api\",\n        \"description\": \"Production API key for customer integrations\",\n        \"expires_at\": \"2026-12-31T23:59:59Z\"\n    }","examples":[{"description":"Production API key for external service","expires_at":"2026-12-31T23:59:59Z","name":"production-key"}]},"CreateRetrieverRequest":{"properties":{"retriever_name":{"type":"string","minLength":1,"title":"Retriever Name","description":"Unique retriever name (REQUIRED)."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Human readable retriever description (OPTIONAL)."},"visibility":{"$ref":"#/components/schemas/RetrieverVisibility","description":"Visibility level: PRIVATE (owner only), PUBLIC (any valid API key), MARKETPLACE (requires subscription). Defaults to PRIVATE.","default":"private"},"marketplace_listing_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Marketplace Listing Id","description":"Associated marketplace listing ID when visibility is MARKETPLACE (OPTIONAL)."},"requires_subscription":{"type":"boolean","title":"Requires Subscription","description":"Whether this retriever requires an active subscription to access (marketplace only).","default":false},"collection_identifiers":{"items":{"type":"string"},"type":"array","title":"Collection Identifiers","description":"Collection identifiers (names or IDs) queried by the retriever (OPTIONAL). Identifiers can be collection names (e.g., 'my_collection') or collection IDs (e.g., 'col_abc123'). The system will resolve names to IDs automatically. Can be empty for inference-only pipelines (e.g., LLM query analysis without document retrieval). Also accepts 'collection_ids' as an alias for backward compatibility.","examples":[["my_collection","products"],["col_abc123","col_def456"],[]]},"stages":{"items":{"$ref":"#/components/schemas/StageConfig-Input"},"type":"array","minItems":1,"title":"Stages","description":"Ordered stage configurations (REQUIRED). Each stage is {\"stage_name\": <label>, \"config\": {\"stage_id\": <type>, \"parameters\": {...}}}. List available stage types + parameters via GET /v1/retrievers/stages, or POST /v1/templates/scaffolds/default for a ready-made retriever.","examples":[[{"config":{"parameters":{"final_top_k":50,"searches":[{"feature_uri":"mixpeek://multimodal_extractor@v1/vertex_multimodal_embedding","query":{"input_mode":"text","text":"{{INPUT.query}}"},"top_k":100}]},"stage_id":"feature_search"},"stage_name":"search"}]]},"input_schema":{"additionalProperties":{"$ref":"#/components/schemas/RetrieverInputSchemaField-Input","description":"Schema definition for this input field. Defines type, description, examples, and validation rules. Supports all bucket types (string, number, image, etc.) plus document_reference. Frontend uses this to render the appropriate input component (text input, image upload, dropdown, etc.)"},"type":"object","title":"Input Schema","description":"Input schema properties keyed by field name (OPTIONAL). Can be empty for static retrievers with hardcoded stage parameters. Each field can include: type, description, required, default, and examples. The 'examples' field (list) provides sample values that will be shown to users when the retriever is published with include_metadata=true.","examples":[{"category":{"description":"Filter by category","examples":["electronics","clothing"],"required":false,"type":"string"},"query":{"description":"Search query text","examples":["red sports car","sunset over ocean"],"required":true,"type":"text"}}]},"budget_limits":{"$ref":"#/components/schemas/BudgetLimits","description":"Budget limits for execution (OPTIONAL)."},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Optional retriever tags for search/filters."},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Custom key-value metadata stored on the retriever (OPTIONAL). Round-trips on create/get/list and is updatable via PATCH — useful for automation markers like seed/config versions. Previously this field was silently dropped on create (FRUSTRATIONS silent-drop class)."},"display_config":{"anyOf":[{"$ref":"#/components/schemas/DisplayConfig-Input"},{"type":"null"}],"description":"Display configuration for public retriever UI rendering (OPTIONAL). Defines how the search interface should appear when the retriever is published, including input fields, theme, layout, exposed result fields, and field formatting. This configuration is used as the default when publishing the retriever."}},"type":"object","required":["retriever_name","stages"],"title":"CreateRetrieverRequest","description":"Payload for creating a new retriever.","examples":[{"collection_identifiers":["product_embeddings"],"input_schema":{"query":{"description":"Search query","required":true,"type":"text"}},"retriever_name":"product_search","stages":[{"config":{"parameters":{"final_top_k":20,"searches":[{"feature_uri":"mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1","query":{"input_mode":"text","value":"{{INPUT.query}}"},"top_k":100}]},"stage_id":"feature_search"},"stage_name":"search","stage_type":"filter"}]},{"collection_identifiers":["product_images"],"description":"Find visually similar images","input_schema":{"image":{"description":"Reference image URL","required":true,"type":"image"}},"retriever_name":"image_similarity","stages":[{"config":{"parameters":{"final_top_k":10,"searches":[{"feature_uri":"mixpeek://image_extractor@v1/google_siglip_base_v1","query":{"input_mode":"content","value":"{{INPUT.image}}"},"top_k":50}]},"stage_id":"feature_search"},"stage_name":"search","stage_type":"filter"}]}]},"CreateRetrieverResponse":{"properties":{"retriever_id":{"type":"string","title":"Retriever Id","description":"Stable retriever identifier (REQUIRED)."},"retriever_name":{"type":"string","minLength":1,"title":"Retriever Name","description":"Unique retriever name within namespace (REQUIRED)."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Detailed description of retriever behaviour (OPTIONAL)."},"collection_ids":{"items":{"type":"string"},"type":"array","title":"Collection Ids","description":"Collections queried by the retriever. Can be empty for query-only inference mode."},"stages":{"items":{"$ref":"#/components/schemas/StageConfig-Output"},"type":"array","minItems":1,"title":"Stages","description":"Ordered list of stage configurations (REQUIRED)."},"input_schema":{"additionalProperties":{"$ref":"#/components/schemas/RetrieverInputSchemaField-Output","description":"Schema definition for this input field. Defines type, description, examples, and validation rules. Supports all bucket types (string, number, image, etc.) plus document_reference. Frontend uses this to render the appropriate input component (text input, image upload, dropdown, etc.)"},"type":"object","title":"Input Schema","description":"JSON Schema describing expected user inputs (REQUIRED). Properties must use RetrieverInputSchemaField which supports all bucket types plus document_reference."},"budget_limits":{"$ref":"#/components/schemas/BudgetLimits","description":"Execution budget limits for the retriever (OPTIONAL)."},"feature_dependencies":{"anyOf":[{"items":{"$ref":"#/components/schemas/FeatureAddress"},"type":"array"},{"type":"null"}],"title":"Feature Dependencies","description":"Feature addresses required by stages (OPTIONAL, aids validation)."},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Arbitrary tags to help organise retrievers (OPTIONAL)."},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Custom key-value metadata (OPTIONAL). Round-trips on create/get/list and is updatable via PATCH — useful for automation markers like seed/config versions."},"display_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Display Config","description":"Display configuration for public retriever UI rendering (OPTIONAL). Defines how the search interface should appear when the retriever is published, including input fields, theme, layout, exposed result fields, and field formatting. This configuration is used as the default when publishing the retriever."},"version":{"type":"integer","minimum":1.0,"title":"Version","description":"Version number that increments on each update (REQUIRED).","default":1},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp in UTC (REQUIRED)."},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp in UTC (REQUIRED)."},"created_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By","description":"Identifier of the user who created the retriever (OPTIONAL)."},"updated_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Updated By","description":"Identifier of the user who last updated the retriever (OPTIONAL)."},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings","description":"Advisory notes about the saved retriever. A stage that reads a field none of its target collections' synced schemas contain is named here: it will match nothing until documents carry that field. A collection with no documents yet has no schema and is not checked. Warnings never block creation."},"fusion":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fusion","description":"Fusion strategy used by this retriever's feature_search stage (e.g. 'learned', 'rrf', 'dbsf'). Null if no feature_search stage.","readOnly":true},"collection_identifiers":{"items":{"type":"string"},"type":"array","title":"Collection Identifiers","description":"Mirror of collection_ids under the field name CREATE accepts (collection_identifiers), so a create → read round-trip reads back the field it wrote. Always equal to collection_ids (FRUSTRATIONS 2026-07-16: SDKs/agents re-reading their own write saw collection_identifiers null and concluded the retriever was unscoped).","readOnly":true}},"type":"object","required":["retriever_name","stages","fusion","collection_identifiers"],"title":"CreateRetrieverResponse","description":"Response after creating a retriever.\n\nReturns the retriever configuration at top level (flat), consistent\nwith POST /namespaces and POST /collections which also return the\ncreated resource directly.","examples":[{"budget_limits":{"max_credits":100,"max_time_ms":60000},"collection_ids":["col_marketing_ads"],"input_schema":{"query_text":{"description":"Full-text query","type":"string"}},"retriever_id":"ret_abc123","retriever_name":"executive_ads_search","stages":[{"config":{"parameters":{"field":"metadata.spend","operator":"gt","value":1000},"stage_id":"attribute_filter"},"stage_name":"filter_high_spend","stage_type":"filter"}]}]},"CreateSecretRequest":{"properties":{"secret_name":{"type":"string","maxLength":100,"minLength":1,"title":"Secret Name","description":"REQUIRED. Name/key for the secret. Use descriptive names that indicate the service and purpose. Must be unique within the organization. Format: lowercase with underscores (e.g., 'stripe_api_key'). Common patterns: '{service}_{type}_{environment}' like 'stripe_api_key_prod'. This name is used to reference the secret in api_call stage configuration. Examples: 'stripe_api_key', 'github_token', 'openai_api_key', 'weather_api_key'.","examples":["stripe_api_key","github_token","openai_api_key","weather_api_key"]},"secret_value":{"type":"string","minLength":1,"title":"Secret Value","description":"REQUIRED. Plaintext secret value to encrypt and store. This value will be encrypted at rest using Fernet encryption. The encrypted value is stored in MongoDB with the organization document. The plaintext value is NEVER logged or exposed in API responses. Only the secret name is visible when listing secrets. Use this field to store: API keys, tokens, passwords, credentials. Format: any string (will be encrypted as-is). For Basic auth, use format 'username:password'.","examples":["sk_test_abc123...","ghp_abc123...","abc123def456"]}},"type":"object","required":["secret_name","secret_value"],"title":"CreateSecretRequest","description":"Request to create a new secret in the organization vault.\n\nSecrets are encrypted at rest using Fernet encryption and stored in the\norganization document. Use secrets to securely store API keys, tokens,\nand credentials for external services.\n\n**Use Cases**:\n- Store API keys for Stripe, GitHub, OpenAI, etc.\n- Manage authentication tokens for api_call retriever stage\n- Store credentials for third-party integrations\n\n**Security**:\n- Secret values are encrypted using ENCRYPTION_KEY from environment\n- Decrypted values are NEVER returned in API responses\n- Only secret names are exposed in list operations\n- Access is logged for audit trail\n\n**Requirements**:\n- secret_name: REQUIRED, must be unique within organization\n- secret_value: REQUIRED, plaintext value to encrypt\n\n**Permissions**: Requires ADMIN permission to create secrets.","examples":[{"description":"Store Stripe API key for payment processing","secret_name":"stripe_api_key","secret_value":"YOUR_STRIPE_API_KEY"},{"description":"Store GitHub Personal Access Token","secret_name":"github_pat","secret_value":"ghp_abc123def456ghi789jkl012mno345"},{"description":"Store OpenAI API key for LLM calls","secret_name":"openai_api_key","secret_value":"sk-proj-abc123def456ghi789"},{"description":"Store Weather API key","secret_name":"weather_api_key","secret_value":"abc123def456ghi789"}]},"CreateSessionRequest":{"properties":{"agent_config":{"$ref":"#/components/schemas/AgentConfig","description":"Agent configuration (REQUIRED)"},"quotas":{"anyOf":[{"$ref":"#/components/schemas/SessionQuotas"},{"type":"null"}],"description":"Session quotas and rate limits (OPTIONAL)"},"user_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id","description":"User identifier (OPTIONAL)"},"user_memory":{"additionalProperties":true,"type":"object","title":"User Memory","description":"Initial user memory/preferences (OPTIONAL)"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Session metadata (OPTIONAL)"},"enable_memory":{"type":"boolean","title":"Enable Memory","description":"Enable semantic memory for conversation context (OPTIONAL, default: True)","default":true}},"type":"object","required":["agent_config"],"title":"CreateSessionRequest","description":"Request payload for creating a new agent session.\n\nAttributes:\n    agent_config: Agent configuration (model, temperature, tools, etc.)\n    quotas: Optional session quotas and rate limits\n    user_id: Optional user identifier\n    user_memory: Optional initial user memory/preferences\n    metadata: Optional session metadata\n\nExample:\n    ```python\n    request = CreateSessionRequest(\n        agent_config=AgentConfig(\n            model=\"claude-3-5-sonnet-20241022\",\n            temperature=0.7,\n            available_tools=[\"search_retrievers\", \"execute_retriever\"]\n        ),\n        quotas=SessionQuotas(\n            max_messages=100,\n            max_tokens_total=100000\n        ),\n        user_id=\"user_123\",\n        user_memory={\"preferences\": {\"language\": \"en\"}}\n    )\n    ```","examples":[{"agent_config":{"available_tools":["search_retrievers","execute_retriever","list_collections"],"max_tokens":4096,"model":"claude-3-5-sonnet-20241022","system_prompt":"You are a helpful video search assistant.","temperature":0.7},"quotas":{"max_messages":100,"max_tokens_total":100000,"max_tool_calls":50},"user_id":"user_123","user_memory":{"preferences":{"domain":"tech","language":"en"}}}]},"CreateSessionResponse":{"properties":{"session_id":{"type":"string","title":"Session Id","description":"Unique session identifier"},"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace identifier"},"internal_id":{"type":"string","title":"Internal Id","description":"Organization internal ID"},"session_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Name","description":"Auto-generated session name based on first conversation (set after first message)"},"status":{"$ref":"#/components/schemas/SessionStatus","description":"Session status"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Session creation timestamp"},"expires_at":{"type":"string","format":"date-time","title":"Expires At","description":"Session expiration timestamp"}},"type":"object","required":["session_id","namespace_id","internal_id","status","created_at","expires_at"],"title":"CreateSessionResponse","description":"Response for session creation.\n\nAttributes:\n    session_id: Unique session identifier\n    namespace_id: Namespace identifier\n    internal_id: Organization internal ID\n    session_name: Auto-generated session name (null until first message)\n    status: Session status\n    created_at: Session creation timestamp\n    expires_at: Session expiration timestamp\n\nExample:\n    ```python\n    response = CreateSessionResponse(\n        session_id=\"ses_abc123\",\n        namespace_id=\"ns_xyz789\",\n        internal_id=\"int_abc123\",\n        session_name=None,  # Will be set after first message\n        status=\"active\",\n        created_at=current_time(),\n        expires_at=current_time() + timedelta(days=7)\n    )\n    ```"},"CreateSnapshotRequest":{"properties":{"copy_s3_objects":{"type":"boolean","title":"Copy S3 Objects","description":"If true, S3 objects are copied to the snapshot prefix (slower, uses more storage). Required for restoring after namespace deletion.","default":false},"include_vectors":{"type":"boolean","title":"Include Vectors","description":"If false, creates a metadata-only snapshot: the namespace's records without its vector points. Restoring it writes no vectors, so it is not a backup of the namespace's data.","default":true},"import_from":{"anyOf":[{"$ref":"#/components/schemas/SnapshotImportSource"},{"type":"null"}],"description":"Import a snapshot taken on another plane instead of taking one: its artifacts are copied from this bucket and prefix into this namespace's snapshots, every artifact is checked against the sha256 its manifest records, and the snapshot is completed only if verify finds it restorable. copy_s3_objects and include_vectors do not apply."}},"type":"object","title":"CreateSnapshotRequest"},"CreateSnapshotResponse":{"properties":{"task_id":{"type":"string","title":"Task Id"},"snapshot_id":{"type":"string","title":"Snapshot Id"},"message":{"type":"string","title":"Message"}},"type":"object","required":["task_id","snapshot_id","message"],"title":"CreateSnapshotResponse"},"CreateStandaloneNamespaceRequestModel":{"properties":{"namespace_id":{"type":"string","pattern":"^[A-Za-z0-9][A-Za-z0-9_-]{0,127}$","title":"Namespace Id","description":"Unique namespace identifier: 1 to 128 characters, letters, digits, '_' and '-', starting with a letter or digit.","examples":["ns_my_vectors"]},"vector_configs":{"items":{"$ref":"#/components/schemas/VectorConfigSpecModel"},"type":"array","title":"Vector Configs","description":"Vector index configurations. If omitted, indexes are inferred on first upsert."},"storage":{"anyOf":[{"$ref":"#/components/schemas/StandaloneStorageConfig"},{"type":"null"}],"description":"Optional BYO object storage connection"},"config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Config","description":"Optional configuration (retention, version_history, tiering)"},"auto_create_indexes":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Auto Create Indexes","description":"Adaptive payload indexing. Standalone namespaces default to on (indexes are inferred/created from filter usage). Set explicitly to false to opt out and manage payload indexes yourself."}},"type":"object","required":["namespace_id"],"title":"CreateStandaloneNamespaceRequestModel","description":"Request body for POST /v1/namespaces/standalone."},"CreateSubmissionUploadRequest":{"properties":{"name":{"type":"string","pattern":"^[a-zA-Z][a-zA-Z0-9_]{2,63}$","title":"Name","description":"Extractor name: 3-64 chars, letters/numbers/underscores, starts with a letter (no hyphens)"},"version":{"type":"string","title":"Version","description":"Version string (e.g., 'v1', '1.0.0')"},"description":{"type":"string","maxLength":1000,"title":"Description","description":"Human-readable description of the extractor","default":""},"file_size_bytes":{"anyOf":[{"type":"integer","maximum":524288000.0,"exclusiveMinimum":0.0},{"type":"null"}],"title":"File Size Bytes","description":"Expected archive size in bytes (500MB max)"},"file_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"File Name","description":"Optional archive filename hint. Must end in .zip — submissions only accept zip archives (upload Content-Type: application/zip)."}},"type":"object","required":["name","version"],"title":"CreateSubmissionUploadRequest"},"CreateTaxonomyFromDocumentsRequest":{"properties":{"node_label":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}],"title":"Node Label","description":"Label of the node created from `documents`. Required with `documents`; with `cluster_run` each node takes its cluster's label."},"documents":{"anyOf":[{"items":{"$ref":"#/components/schemas/DocumentRef"},"type":"array","maxItems":200,"minItems":1},{"type":"null"}],"title":"Documents","description":"Documents whose stored vectors are averaged into the one node's anchor. Give this or `cluster_run`."},"node_fields":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Node Fields","description":"Optional extra fields stored on the node document (e.g. `description`). Only fields listed in the taxonomy's enrichment_fields are copied during enrichment."},"vector_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vector Name","description":"Optional explicit vector (index) name for the anchor. If omitted, it is derived from the taxonomy's node collection vector indexes."},"provenance":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Provenance","description":"Optional freeform origin context (e.g. cluster_id, run_id, selection type). Stored on the node document under `metadata.promotion` for auditability."},"cluster_run":{"anyOf":[{"$ref":"#/components/schemas/ClusterRunSource"},{"type":"null"}],"description":"Promote a whole cluster run in one call: one node per cluster, labelled with the cluster label, anchored on the cluster's stored centroid vector (no re-embedding). Give this or `documents`."},"taxonomy_name":{"type":"string","minLength":1,"title":"Taxonomy Name","description":"Unique name for the new taxonomy."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Optional taxonomy description."},"enrichment_target_field":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Enrichment Target Field","description":"Field name written onto enriched documents (defaults to '<taxonomy_name>_label')."}},"type":"object","required":["taxonomy_name"],"title":"CreateTaxonomyFromDocumentsRequest","description":"One-gesture promotion: create a flat taxonomy (node collection +\nvector-search retriever) AND its nodes, from a document selection or from\na whole cluster run.\n\nThe node collection mirrors the source collection's vector index (same\nvector name / dimensions / feature_uri), so classification is guaranteed\ndimension-compatible with the data the nodes came from.\n\nGive exactly one source: ``documents`` with ``node_label`` (one node whose\nanchor averages the documents), or ``cluster_run`` (one node per cluster\nin that run, labelled with the cluster's label, its stored centroid as the\nanchor)."},"CreateTaxonomyRequest":{"properties":{"taxonomy_name":{"type":"string","title":"Taxonomy Name","description":"A unique name for the taxonomy within the namespace."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"An optional description of the taxonomy."},"config":{"oneOf":[{"$ref":"#/components/schemas/FlatTaxonomyConfig-Input"},{"$ref":"#/components/schemas/HierarchicalTaxonomyConfig-Input"}],"title":"Config","description":"Configuration specific to the taxonomy type.","discriminator":{"propertyName":"taxonomy_type","mapping":{"flat":"#/components/schemas/FlatTaxonomyConfig-Input","hierarchical":"#/components/schemas/HierarchicalTaxonomyConfig-Input"}}},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"OPTIONAL caller metadata, stored with the taxonomy and merged with the system entries (validation_warnings). PATCH /taxonomies/{id} accepted this field before create did."}},"type":"object","required":["taxonomy_name","config"],"title":"CreateTaxonomyRequest","description":"Request model to create a taxonomy.","examples":[{"config":{"input_mappings":[{"input_key":"image_vector","path":"features.clip","source_type":"vector"}],"retriever_id":"ret_clip_v1","source_collection":{"collection_id":"col_products_v1","enrichment_fields":[{"field_path":"metadata.tags","merge_mode":"append"}]},"taxonomy_type":"flat"},"taxonomy_name":"product_tags"},{"config":{"hierarchical_nodes":[{"collection_id":"col_employees_v1"},{"collection_id":"col_executives_v1","parent_collection_id":"col_employees_v1"}],"input_mappings":[{"input_key":"face_vec","path":"features.face","source_type":"vector"}],"retriever_id":"ret_face_v1","taxonomy_type":"hierarchical"},"taxonomy_name":"org_hierarchy"}]},"CreateTemplateFromResourceRequest":{"properties":{"template_name":{"type":"string","maxLength":100,"minLength":1,"title":"Template Name","description":"Name for the new template"},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description","description":"Description of the template's purpose (OPTIONAL)"},"scope":{"$ref":"#/components/schemas/TemplateScope","description":"Template scope: 'organization' (all users in org), 'user' (only you), or 'system' (all organizations - requires Mixpeek admin email)","default":"organization"},"category":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Category","description":"Optional category for organizing templates"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Optional tags for the template"},"is_public":{"type":"boolean","title":"Is Public","description":"Whether this template should be publicly discoverable","default":false}},"type":"object","required":["template_name"],"title":"CreateTemplateFromResourceRequest","description":"Request to create a template from an existing resource.","examples":[{"category":"ecommerce","description":"Semantic search optimized for product catalogs","is_public":false,"tags":["products","search"],"template_name":"My Product Search Pattern"}]},"CreateTemplateFromResourceResponse":{"properties":{"template_id":{"type":"string","title":"Template Id","description":"ID of the created template"},"template_name":{"type":"string","title":"Template Name","description":"Name of the created template"},"template_type":{"$ref":"#/components/schemas/TemplateType","description":"Type of template created"},"scope":{"$ref":"#/components/schemas/TemplateScope","description":"Template scope"},"source_resource_id":{"type":"string","title":"Source Resource Id","description":"ID of the resource used to create this template"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Timestamp when template was created"}},"type":"object","required":["template_id","template_name","template_type","scope","source_resource_id"],"title":"CreateTemplateFromResourceResponse","description":"Response after creating a template from a resource.","examples":[{"created_at":"2025-01-15T12:00:00Z","scope":"organization","source_resource_id":"ret_xyz789","template_id":"tmpl_custom_abc123","template_name":"My Product Search Pattern","template_type":"retriever"}]},"CreateTicketRequest":{"properties":{"subject":{"type":"string","maxLength":200,"minLength":3,"title":"Subject"},"category":{"$ref":"#/components/schemas/SupportTicketCategory","default":"other"},"description":{"type":"string","maxLength":10000,"minLength":1,"title":"Description"},"priority":{"$ref":"#/components/schemas/SupportTicketPriority","default":"medium"},"scope":{"anyOf":[{"$ref":"#/components/schemas/SupportScope"},{"type":"null"}]},"organization_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Id"}},"type":"object","required":["subject","description"],"title":"CreateTicketRequest"},"CreateUploadRequest":{"properties":{"filename":{"type":"string","maxLength":255,"minLength":1,"title":"Filename","description":"Name of the file to upload. REQUIRED. Must be a valid filename without path traversal characters (../, \\). The filename is used to derive the blob_property if not explicitly provided. Examples: 'product_video.mp4', 'thumbnail.jpg', 'transcript.txt'","examples":["product_video.mp4","thumbnail.jpg","document.pdf"]},"content_type":{"type":"string","title":"Content Type","description":"MIME type of the file. REQUIRED. Must be a valid MIME type (e.g., 'video/mp4', 'image/jpeg', 'application/pdf'). The presigned URL will enforce this content type during upload. Used to validate compatibility with bucket schema if create_object_on_confirm=true.","examples":["video/mp4","image/jpeg","image/png","application/pdf","text/plain"]},"file_size_bytes":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"File Size Bytes","description":"Expected file size in bytes. OPTIONAL but RECOMMENDED. If provided, will be validated against: 1. Tier-based file size limits (100MB free, 5GB pro, 50GB enterprise) 2. Storage quota availability 3. Actual uploaded file size during confirmation. If not provided, quota checking is skipped until confirmation.","examples":[10485760,104857600]},"presigned_url_expiration":{"type":"integer","maximum":86400.0,"minimum":60.0,"title":"Presigned Url Expiration","description":"How long the presigned URL is valid, in seconds. OPTIONAL, defaults to 3600 (1 hour). Valid range: 60 seconds (1 minute) to 86400 seconds (24 hours). After expiration, the URL cannot be used and you must request a new one. Recommendation: Use shorter expiration (300-900 seconds) for security-sensitive files, longer expiration (3600-7200 seconds) for large files that take time to upload.","default":3600,"examples":[3600,7200,900]},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Custom metadata for tracking purposes. OPTIONAL. Stored with the upload record for filtering and analytics. Does NOT affect the created bucket object (use object_metadata for that). Common uses: campaign tracking, user identification, upload source.","examples":[{"campaign":"summer_2024","source":"mobile_app","user_id":"user_123"},{"department":"marketing","priority":"high"}]},"create_object_on_confirm":{"type":"boolean","title":"Create Object On Confirm","description":"Whether to automatically create a bucket object when upload is confirmed. OPTIONAL, defaults to TRUE (object is created automatically). If true (default):   - Bucket MUST have a schema defined   - blob_property must exist in bucket schema   - content_type must match schema field type   - Validation happens BEFORE generating presigned URL   - Object is created automatically on confirmation.   - The object is created in PENDING status and is not processed.     Processing starts when it is added to a batch (POST /buckets/{id}/batches     then POST /buckets/{id}/batches/{batch_id}/submit), or when the confirm     call sets auto_submit_batch=true. If false:   - Upload is confirmed but no object is created   - Use this when combining multiple uploads into one object   - Reference the upload_id later in POST /buckets/{id}/objects.","default":true},"object_metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Object Metadata","description":"Metadata to attach to the created bucket object. OPTIONAL. Only used if create_object_on_confirm=true. This metadata will be:   1. Validated against bucket schema (if keys match schema fields)   2. Attached to the bucket object   3. Passed to downstream documents in connected collections. Example: {'priority': 'high', 'category': 'products', 'tags': ['featured']}","examples":[{"category":"products","priority":"high"},{"campaign":"q4_2024","status":"draft","tags":["review","featured"]}]},"blob_property":{"anyOf":[{"type":"string","pattern":"^[a-zA-Z0-9_]+$"},{"type":"null"}],"title":"Blob Property","description":"Property name for the blob in the bucket object. OPTIONAL. When omitted: defaults to the bucket schema's file-type property, if it declares exactly one; otherwise falls back to the filename without its extension (e.g. 'product_video.mp4' -> 'product_video'), which fails if the stem is not alphanumeric_with_underscores (a hyphenated filename, for example) -- pass this field explicitly to avoid that. If create_object_on_confirm=true:   - Must exist in bucket schema   - Must be alphanumeric with underscores only   - Will be validated BEFORE generating presigned URL. Common values: 'video', 'image', 'thumbnail', 'transcript', 'content'.","examples":["video","thumbnail","transcript","content"]},"blob_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Blob Type","description":"Type of blob. OPTIONAL. Defaults to type derived from content_type (e.g., 'video/mp4' → 'VIDEO'). Must be a valid BucketSchemaFieldType if provided. Valid values: IMAGE, VIDEO, AUDIO, TEXT, PDF, DOCUMENT, etc. If create_object_on_confirm=true, will be validated against bucket schema field type.","examples":["VIDEO","IMAGE","AUDIO","TEXT","PDF"]},"file_hash":{"anyOf":[{"type":"string","maxLength":64,"minLength":64,"pattern":"^[a-f0-9]{64}$"},{"type":"null"}],"title":"File Hash","description":"SHA256 hash of the file content for duplicate detection. OPTIONAL. If provided:   - System checks for existing confirmed uploads with same hash   - If duplicate found and skip_duplicates=true, returns existing upload   - The hash is kept as the content address for this upload, and is what later uploads are matched against   - It is taken on trust. A single-part ETag is an MD5 of the same bytes, so the object store cannot confirm a SHA256 against what it holds. Send a hash of the bytes you actually upload. If not provided:   - Hash is calculated from S3 ETag after upload   - Duplicate detection only happens during confirmation. Use case: Pre-calculate hash client-side to avoid uploading duplicates. Format: 64-character hexadecimal string (SHA256), lower case. An upper-case digest is rejected.","examples":["e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855","2c26b46b68ffc68ff99b453c1d30413413422d706483bfa0f98a5e886266e7ae"]},"skip_duplicates":{"type":"boolean","title":"Skip Duplicates","description":"Skip upload if a file with the same hash already exists. OPTIONAL, defaults to TRUE. If true (default):   - If file_hash provided: System checks MongoDB for existing completed upload with same hash   - If duplicate found: Returns existing upload details WITHOUT generating new presigned URL   - If file_hash NOT provided: Duplicate check happens during confirmation using S3 ETag   - Saves bandwidth, storage, and upload time by reusing existing files. If false:   - Always generates new presigned URL even if file already uploaded   - Creates separate upload record for same file content   - Useful when you need distinct upload tracking for identical files. Recommendation: Keep default (true) unless you specifically need multiple upload records for same file.","default":true}},"type":"object","required":["filename","content_type"],"title":"CreateUploadRequest","description":"Request to generate a presigned URL for direct S3 upload.\n\n⚠️  ⚠️  ⚠️  THIS IS THE PRESIGNED URL SYSTEM ⚠️  ⚠️  ⚠️\n\nThis endpoint (POST /buckets/{id}/uploads) is the COMPLETE presigned URL system.\nIt handles:\n- ✅ Presigned URL generation (S3 PUT URLs)\n- ✅ Upload tracking and status management\n- ✅ Validation (quotas, file size, content type, schema)\n- ✅ Duplicate detection\n- ✅ Auto object creation on confirmation\n- ✅ Returns upload_id for later reference\n\nDO NOT CREATE A NEW PRESIGNED UPLOAD ENDPOINT!\nIf you need presigned URLs, use this existing system.\n\nIf you think you need a new endpoint:\n1. Check if this system already does it (it probably does)\n2. Extend this system instead of creating redundancy\n3. See api/buckets/uploads/services.py for implementation\n\nIntegration Points:\n- Object creation: Use upload_id in CreateBlobRequest.upload_id field\n- See: shared/buckets/objects/blobs/models.py::CreateBlobRequest\n- See: api/buckets/objects/canonicalization.py::resolve_upload_reference()\n\nWorkflow:\n1. POST /buckets/{id}/uploads → Returns presigned_url + upload_id\n2. PUT presigned_url with file content (client uploads directly to S3)\n3. POST /uploads/{upload_id}/confirm → REQUIRED to finalize upload\n4. Object is created automatically (default behavior)\n\n⚠️  IMPORTANT: Step 3 (confirm) is REQUIRED!\nS3 presigned URLs have no callback mechanism - the API cannot detect when\nyour upload to S3 completes. You MUST call the confirm endpoint to:\n- Verify the file exists in S3\n- Validate integrity (ETag/size)\n- Create the bucket object\n- Mark upload as COMPLETED\n\nIf you don't confirm:\n- Upload stays in PENDING status forever\n- No object is created\n- File exists in S3 but is orphaned\n- Presigned URL expires (default: 1 hour)\n\nUse Cases:\n    - Simple: Upload → confirm → object created automatically (default)\n    - Advanced: Upload multiple files with create_object_on_confirm=false,\n      then POST /buckets/{id}/objects with all upload_ids to create one object\n\nRequirements:\n    - filename: REQUIRED, will be validated (no path traversal)\n    - content_type: REQUIRED, must be valid MIME type\n    - bucket_id: Comes from URL path parameter, not request body\n    - All other fields: OPTIONAL with sensible defaults\n\nNote:\n    The bucket_id comes from the URL path (/v1/buckets/{bucket_id}/uploads),\n    not from the request body. The bucket is validated before generating presigned URL.","examples":[{"content_type":"video/mp4","description":"Minimal upload - object created automatically on confirm (DEFAULT)","file_size_bytes":52428800,"filename":"product_demo.mp4"},{"blob_property":"image","content_type":"image/jpeg","description":"Upload with metadata - object still created automatically","file_size_bytes":2097152,"filename":"profile.jpg","object_metadata":{"category":"avatars","title":"Profile Image"}},{"blob_property":"raw_video","content_type":"video/quicktime","description":"Large file with extended expiration","file_size_bytes":5368709120,"filename":"4k_footage.mov","presigned_url_expiration":7200},{"content_type":"video/mp4","create_object_on_confirm":false,"description":"ADVANCED: Manual object creation - set create_object_on_confirm=false","file_size_bytes":104857600,"filename":"video.mp4","note":"Only use this when combining multiple uploads into one object","use_case":"Combine multiple uploads into one object","workflow":["1. POST /uploads (video) with create_object_on_confirm=false","2. POST /uploads (thumbnail) with create_object_on_confirm=false","3. Upload both files to S3","4. Confirm both uploads","5. POST /buckets/{id}/objects with both upload_ids:","   {blobs: [{property: 'video', upload_id: 'upl_video'}, {property: 'thumb', upload_id: 'upl_thumb'}]}"]}]},"CreateVideoRequest":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"source_type":{"$ref":"#/components/schemas/SupportVideoSource","default":"upload"},"storage_uri":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Storage Uri"},"external_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Url"},"mime_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mime Type","default":"video/mp4"},"duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Seconds"},"scope":{"anyOf":[{"$ref":"#/components/schemas/SupportScope"},{"type":"null"}]},"organization_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Id"},"video_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Video Id"},"analyze":{"type":"boolean","title":"Analyze","default":true}},"type":"object","title":"CreateVideoRequest"},"CreatorInfo":{"properties":{"user_id":{"type":"string","title":"User Id","description":"User identifier"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"User email address"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"User display name"}},"type":"object","required":["user_id"],"title":"CreatorInfo","description":"Information about who created or updated a resource."},"CreditBalanceResponse":{"properties":{"organization_id":{"type":"string","title":"Organization Id","description":"Organization identifier","examples":["org_demo123"]},"credit_balance":{"type":"integer","title":"Credit Balance","description":"Current credit balance. For FREE tier without auto-billing, this is remaining free tier credits. For auto-billing accounts, this shows current month usage (negative indicates consumption).","examples":[45230,750]},"account_tier":{"type":"string","title":"Account Tier","description":"Current account tier: free, pro, team, enterprise","examples":["free","pro","team"]},"next_tier":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Tier","description":"Next available tier or null if at max tier","examples":["pro","enterprise"]},"credits_until_next_tier":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Credits Until Next Tier","description":"Credits needed to reach next tier (null if at max tier or N/A)","examples":[954770,0]},"estimated_days_remaining":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Estimated Days Remaining","description":"Estimated days until credits depleted based on 7-day burn rate. Null if no usage history or unlimited (auto-billing enabled).","examples":[15,30]},"daily_burn_rate":{"type":"number","title":"Daily Burn Rate","description":"Average credits consumed per day (7-day rolling average)","default":0.0,"examples":[3015.3,142.5]}},"type":"object","required":["organization_id","credit_balance","account_tier"],"title":"CreditBalanceResponse","description":"Response with current credit balance and tier information."},"CurrentUsageResponse":{"properties":{"current_month_usage":{"type":"integer","title":"Current Month Usage","description":"Credits consumed in current billing cycle","examples":[23450]},"billing_month":{"type":"string","title":"Billing Month","description":"Current billing month (YYYY-MM)","examples":["2025-12"]},"billing_period_start":{"type":"string","format":"date-time","title":"Billing Period Start","description":"Start of current billing period"},"billing_period_end":{"type":"string","format":"date-time","title":"Billing Period End","description":"End of current billing period"},"estimated_cost_usd":{"type":"number","title":"Estimated Cost Usd","description":"Estimated cost for current usage","examples":[23.45]},"credit_rate":{"type":"number","title":"Credit Rate","description":"Cost per credit in USD","default":0.001},"auto_billing_enabled":{"type":"boolean","title":"Auto Billing Enabled","description":"Whether auto-billing is enabled"},"next_invoice_date":{"type":"string","format":"date-time","title":"Next Invoice Date","description":"When next invoice will be generated"},"plan_usage":{"anyOf":[{"$ref":"#/components/schemas/PlanUsage"},{"type":"null"}],"description":"Tier usage vs caps (objects for managed, vectors for MVS). None only if plan resolution fails."},"usage_v2":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Usage V2","description":"Modality+features usage for the period (contract v2 §2): dollars by modality and feature, unit counts, estimated flag. SHADOW data until cutover — informational alongside the credit fields above. None if no v2 records exist yet or aggregation fails (best-effort)."},"slack_invite":{"$ref":"#/components/schemas/SlackInviteStatus","description":"Slack Connect invite state for this org. ALWAYS present — the null state is an explicit 'never_attempted', never a missing key. The invite fires when the org PAYS (and at signup for business domains); studio's post-checkout success screen renders its card only for status sent/pending."}},"type":"object","required":["current_month_usage","billing_month","billing_period_start","billing_period_end","estimated_cost_usd","auto_billing_enabled","next_invoice_date"],"title":"CurrentUsageResponse","description":"Response with current month usage."},"CursorPaginationParams":{"properties":{"method":{"type":"string","const":"cursor","title":"Method","description":"Constant identifying cursor pagination (REQUIRED).","default":"cursor"},"limit":{"type":"integer","maximum":500.0,"minimum":1.0,"title":"Limit","description":"Maximum number of documents to return per page (REQUIRED). Default: 10.","default":10},"cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor","description":"Opaque base64 cursor from previous response (OPTIONAL). null for first page, then use cursor from response.pagination.cursor"}},"type":"object","title":"CursorPaginationParams","description":"Cursor-based pagination referencing last seen position.\n\nBest for: Infinite scroll UIs, mobile apps, real-time feeds\n\nHow it works:\n- First request: cursor=null\n- Response includes next cursor token\n- Next request: pass cursor from previous response\n- Stateless: no server-side state\n- Consistent: no duplicates/gaps even with concurrent writes\n\nUse when:\n- Building infinite scroll interfaces\n- Users scroll through results sequentially\n- You need consistency across pages\n- You don't need to jump to arbitrary pages\n\nExample flow:\n1. Request: {\"method\": \"cursor\", \"limit\": 20, \"cursor\": null}\n2. Response: {\"documents\": [...], \"pagination\": {\"cursor\": \"abc123\", \"has_next\": true}}\n3. Request: {\"method\": \"cursor\", \"limit\": 20, \"cursor\": \"abc123\"}"},"CustomCTA":{"properties":{"label":{"type":"string","maxLength":50,"minLength":1,"title":"Label","description":"Button label text displayed in the header","examples":["How to Use","Search Tips","About","Help"]},"markdown_content":{"type":"string","maxLength":50000,"minLength":1,"title":"Markdown Content","description":"Markdown content displayed in the modal when button is clicked. Supports standard markdown syntax.","examples":["# Getting Started\n\nThis search engine allows you to...\n\n## Tips\n\n- Use specific keywords\n- Try different queries"]}},"type":"object","required":["label","markdown_content"],"title":"CustomCTA","description":"Optional custom button in header that opens a markdown modal.\n\nAllows users to add a custom call-to-action button in the header bar\nthat opens a modal with markdown content when clicked.","examples":[{"label":"Search Tips","markdown_content":"# Search Tips\n\n- Use quotes for exact phrases\n- Filter by date using 'after:2024'"}]},"CustomDomainConfig":{"properties":{"domain":{"type":"string","title":"Domain","description":"Customer domain (e.g. 'search.acme.com')"},"status":{"type":"string","enum":["pending","verifying","provisioning_tls","active"],"title":"Status","description":"Domain verification and TLS lifecycle state","default":"pending"},"verification_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verification Token","description":"TXT record value for DNS ownership verification"},"cname_target":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cname Target","description":"CNAME target (e.g. '{slug}.mxp.co')"},"tls_cert_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tls Cert Id","description":"TLS certificate reference"},"tls_expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Tls Expires At","description":"TLS cert expiry"},"verified_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Verified At","description":"When domain was verified"},"is_primary":{"type":"boolean","title":"Is Primary","description":"Whether this is the primary domain","default":false}},"type":"object","required":["domain"],"title":"CustomDomainConfig","description":"A single custom domain attached to an App."},"CustomModelDocument":{"properties":{"model_id":{"type":"string","title":"Model Id","description":"Unique model identifier"},"namespace_id":{"type":"string","title":"Namespace Id","description":"Owner namespace ID"},"name":{"type":"string","title":"Name","description":"Model name"},"version":{"type":"string","title":"Version","description":"Model version"},"model_archive_url":{"type":"string","title":"Model Archive Url","description":"S3 URL to model archive"},"model_format":{"type":"string","enum":["safetensors","onnx","pytorch","huggingface"],"title":"Model Format","description":"Model format/framework"},"model_hash":{"type":"string","title":"Model Hash","description":"SHA256 hash of model file"},"deployed":{"type":"boolean","title":"Deployed","description":"Whether model is deployed","default":false},"deployment_info":{"anyOf":[{"$ref":"#/components/schemas/ModelDeploymentInfo"},{"type":"null"}],"description":"Deployment details"},"framework":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Framework","description":"ML framework (e.g., sentence-transformers)"},"task_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Type","description":"Task type (e.g., embedding, classification)"},"input_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Input Schema","description":"Input schema JSON"},"output_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Output Schema","description":"Output schema JSON"},"resource_requirements":{"$ref":"#/components/schemas/ModelResourceRequirements","description":"Resource requirements for deployment"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"}},"type":"object","required":["model_id","namespace_id","name","version","model_archive_url","model_format","model_hash"],"title":"CustomModelDocument","description":"Custom model document stored in MongoDB."},"CustomPluginParams":{"properties":{"extractor_type":{"type":"string","title":"Extractor Type","description":"Custom plugin extractor type (plugin name)"}},"additionalProperties":true,"type":"object","required":["extractor_type"],"title":"CustomPluginParams","description":"Parameters for custom plugin extractors.\n\nThis model accepts any extractor_type that doesn't match the builtin extractors,\nallowing custom plugins to define their own parameters."},"DBSCANParams":{"properties":{"eps":{"type":"number","exclusiveMinimum":0.0,"title":"Eps","description":"Maximum distance between two samples for one to be considered in the neighborhood of the other","default":0.5},"min_samples":{"type":"integer","minimum":1.0,"title":"Min Samples","description":"Number of samples in a neighborhood for a point to be considered a core point","default":5},"metric":{"type":"string","title":"Metric","description":"Metric to use for distance computation","default":"euclidean"},"metric_params":{"additionalProperties":true,"type":"object","title":"Metric Params","description":"Additional keyword arguments for the metric function"},"algorithm":{"type":"string","title":"Algorithm","description":"Algorithm to compute pointwise distances and find nearest neighbors ('auto', 'ball_tree', 'kd_tree', 'brute')","default":"auto"},"leaf_size":{"type":"integer","minimum":1.0,"title":"Leaf Size","description":"Leaf size passed to BallTree or KDTree","default":30},"p":{"type":"number","exclusiveMinimum":0.0,"title":"P","description":"The power of the Minkowski metric to be used to calculate distance between points","default":2},"n_jobs":{"type":"integer","title":"N Jobs","description":"The number of parallel jobs to run (-1 means using all processors)","default":1}},"type":"object","title":"DBSCANParams","description":"Parameters for DBSCAN clustering algorithm."},"DLQListResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/SyncDeadLetterObjectModel"},"type":"array","title":"Results"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["results","total"],"title":"DLQListResponse","description":"List of DLQ entries for a sync configuration."},"DSARDeleteResponse":{"properties":{"request_id":{"type":"string","title":"Request Id","description":"Unique DSAR request identifier"},"status":{"type":"string","title":"Status","description":"Request status"},"requested_at":{"type":"string","title":"Requested At","description":"ISO-8601 timestamp of the request"},"estimated_completion":{"type":"string","title":"Estimated Completion","description":"Estimated completion message"},"data_categories":{"items":{"type":"string"},"type":"array","title":"Data Categories","description":"Categories of data that will be deleted"},"warning":{"type":"string","title":"Warning","description":"Warning about irreversibility"}},"type":"object","required":["request_id","status","requested_at","estimated_completion","data_categories","warning"],"title":"DSARDeleteResponse","description":"Response for a data deletion request."},"DSARExportResponse":{"properties":{"request_id":{"type":"string","title":"Request Id","description":"Unique DSAR request identifier"},"status":{"type":"string","title":"Status","description":"Request status"},"requested_at":{"type":"string","title":"Requested At","description":"ISO-8601 timestamp of the request"},"estimated_completion":{"type":"string","title":"Estimated Completion","description":"Estimated completion message"},"data_categories":{"items":{"type":"string"},"type":"array","title":"Data Categories","description":"Categories of data included in the export"}},"type":"object","required":["request_id","status","requested_at","estimated_completion","data_categories"],"title":"DSARExportResponse","description":"Response for a data export request."},"DSARStatusResponse":{"properties":{"request_id":{"type":"string","title":"Request Id"},"type":{"type":"string","title":"Type","description":"export or deletion"},"status":{"type":"string","title":"Status"},"requested_at":{"type":"string","title":"Requested At"},"completed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completed At"},"erased":{"anyOf":[{"additionalProperties":{"type":"integer"},"type":"object"},{"type":"null"}],"title":"Erased","description":"For a finished deletion: records erased, by resource type, including stored_files and vector_indexes."},"kept":{"anyOf":[{"additionalProperties":{"type":"integer"},"type":"object"},{"type":"null"}],"title":"Kept","description":"For a finished deletion: records kept on purpose, by resource type (billing records and audit trails)."}},"type":"object","required":["request_id","type","status","requested_at"],"title":"DSARStatusResponse","description":"Response for checking DSAR request status."},"DataPlaneComponentSummary":{"properties":{"component":{"type":"string","title":"Component"},"component_label":{"type":"string","title":"Component Label"},"replicas":{"type":"integer","title":"Replicas"},"scaling":{"anyOf":[{"$ref":"#/components/schemas/ScalingConfig"},{"type":"null"}]},"resources":{"$ref":"#/components/schemas/ResourceAllocation"}},"type":"object","required":["component","component_label","replicas","resources"],"title":"DataPlaneComponentSummary","description":"Summary of a non-Ray data plane component, such as redis or mvs."},"DatasetListResponse":{"properties":{"datasets":{"items":{"$ref":"#/components/schemas/EvaluationDataset"},"type":"array","title":"Datasets","description":"List of datasets"},"total":{"type":"integer","title":"Total","description":"Total number of datasets"},"page":{"type":"integer","title":"Page","description":"Current page number"},"page_size":{"type":"integer","title":"Page Size","description":"Items per page"}},"type":"object","required":["datasets","total","page","page_size"],"title":"DatasetListResponse","description":"Response model for listing datasets."},"DatePartUnit":{"type":"string","enum":["year","month","week","day","dayOfWeek","dayOfYear","hour","minute","second"],"title":"DatePartUnit","description":"Date part extraction units.\n\nUsed to extract specific components from dates for grouping.\n\nValues:\n    YEAR: Extract year (2024)\n    MONTH: Extract month (1-12)\n    WEEK: Extract week of year (1-53)\n    DAY: Extract day of month (1-31)\n    DAY_OF_WEEK: Extract day of week (1=Sunday, 7=Saturday)\n    DAY_OF_YEAR: Extract day of year (1-366)\n    HOUR: Extract hour (0-23)\n    MINUTE: Extract minute (0-59)\n    SECOND: Extract second (0-59)\n\nExamples:\n    - Use DAY_OF_WEEK to analyze weekly patterns\n    - Use HOUR to find peak usage times"},"DateTruncUnit":{"type":"string","enum":["year","month","week","day","hour","minute","second"],"title":"DateTruncUnit","description":"Date truncation units for time-based grouping.\n\nUsed to group data by time periods.\n\nValues:\n    YEAR: Group by year\n    MONTH: Group by month\n    WEEK: Group by week\n    DAY: Group by day\n    HOUR: Group by hour\n    MINUTE: Group by minute\n    SECOND: Group by second\n\nExamples:\n    - Use DAY to group video uploads by day\n    - Use MONTH to analyze monthly trends"},"DatetimeIndexParams":{"properties":{"type":{"type":"string","title":"Type","default":"datetime"}},"type":"object","title":"DatetimeIndexParams","description":"Configuration for datetime index."},"DedupStrategy":{"type":"string","enum":["skip","replace","force"],"title":"DedupStrategy","description":"Controls how duplicate objects are handled during batch processing.\n\nDedup is scoped to (bucket_id, collection_id): an object is considered\na duplicate if the target collection already has documents produced from\nthe same source object in any prior batch."},"DegradedEntry":{"properties":{"resource":{"type":"string","title":"Resource","description":"Kind of resource skipped: stage, collection, taxonomy, retriever, namespace.","examples":["taxonomy"]},"id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id","description":"Identifier of the skipped resource, when it has one.","examples":["tax_abc123"]},"reason":{"type":"string","title":"Reason","description":"Why it was skipped.","examples":["not found in namespace"]},"next_step":{"type":"string","title":"Next Step","description":"What the caller can do about it.","examples":["Fix the taxonomy_id on the stage, or create the taxonomy."]},"stage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stage","description":"The stage that skipped it, when a stage did."}},"type":"object","required":["resource","reason","next_step"],"title":"DegradedEntry","description":"One resource a response could not include (plan 6.16).\n\nThe same shape 6.10's degradation contract uses for its stage and arm\nentries, so a client reads one structure for every kind of skip."},"DenseVector":{"properties":{},"additionalProperties":true,"type":"object","title":"DenseVector","description":"Basic dense vector representation with flexible key naming.\n\nAccepts a single key-value pair where the key can be any string\nand the value must be a list of floats.\n\nExample:\n```json\n{\n    \"embedding\": [0.1, 0.2, 0.3, 0.4, 0.5]\n}\n```\nor\n```json\n{\n    \"my_custom_vector\": [0.1, 0.2, 0.3, 0.4, 0.5]\n}\n```"},"DependencyGraph":{"properties":{"nodes":{"items":{"$ref":"#/components/schemas/DependencyNode"},"type":"array","title":"Nodes","description":"All resource nodes"},"execution_order":{"items":{"type":"string"},"type":"array","title":"Execution Order","description":"Topologically sorted execution order"}},"type":"object","title":"DependencyGraph","description":"Dependency graph for migration ordering."},"DependencyNode":{"properties":{"resource_id":{"type":"string","title":"Resource Id","description":"Resource ID"},"resource_type":{"$ref":"#/components/schemas/shared__namespaces__migrations__models__ResourceType","description":"Resource type"},"dependencies":{"items":{"type":"string"},"type":"array","title":"Dependencies","description":"IDs of resources this depends on"},"tier":{"type":"integer","minimum":0.0,"title":"Tier","description":"Dependency tier (0=no deps)","default":0}},"type":"object","required":["resource_id","resource_type"],"title":"DependencyNode","description":"Node in dependency graph."},"DeployRequest":{"properties":{"environment":{"type":"string","enum":["staging","production"],"title":"Environment","description":"Target environment for this deploy","default":"production"},"message":{"type":"string","title":"Message","description":"Deploy message describing what changed (like a git commit message)","default":"Deploy via bundle upload"},"source":{"type":"string","enum":["cli_upload","git"],"title":"Source","description":"Deploy source. 'cli_upload' = zip already uploaded to S3. 'git' = Phase 3b.","default":"cli_upload"},"bundle_s3_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bundle S3 Key","description":"S3 key of the uploaded source zip (required for source='cli_upload')"},"source_files":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Source Files","description":"Map of relative path → file content for source-level version diffs"},"git_commit_sha":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Commit Sha","description":"Git commit SHA associated with this deploy"},"git_commit_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Commit Message","description":"Git commit message associated with this deploy"},"git_author":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Author","description":"Git commit author (name <email>)"}},"type":"object","title":"DeployRequest","description":"Deploy a pre-built bundle (CLI path) or trigger a Git-based build."},"DeployResponse":{"properties":{"app_id":{"type":"string","title":"App Id"},"deploy_id":{"type":"string","title":"Deploy Id"},"status":{"type":"string","enum":["queued","building","complete","failed"],"title":"Status"},"environment":{"type":"string","title":"Environment"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message"}},"type":"object","required":["app_id","deploy_id","status","environment"],"title":"DeployResponse"},"DeployStatusResponse":{"properties":{"deploy_id":{"type":"string","title":"Deploy Id"},"status":{"type":"string","enum":["queued","building","complete","failed"],"title":"Status"},"environment":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Environment"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source"},"bundle_s3_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bundle S3 Key"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message"},"queued_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Queued At"},"queued_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Queued By"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"smoke_test":{"anyOf":[{"$ref":"#/components/schemas/SmokeTestResult"},{"type":"null"}]}},"type":"object","required":["deploy_id","status"],"title":"DeployStatusResponse","description":"Status of a specific deploy."},"DescribeCollectionFeaturesResponse":{"properties":{"features":{"items":{"$ref":"#/components/schemas/CollectionFeatureDescriptor"},"type":"array","title":"Features","description":"Feature extractors and fields enabled on this collection"}},"type":"object","required":["features"],"title":"DescribeCollectionFeaturesResponse","examples":[{"features":[{"feature_extractor_name":"text_extractor","inputs":[{"path":"text","type":"string"}],"outputs":[{"dim":1024,"path":"features.text_embedding","type":"vector"}],"version":"v1"}]}]},"DetectIntentRequest":{"properties":{"user_request":{"type":"string","title":"User Request","description":"User's natural language request"},"include_collection_analysis":{"type":"boolean","title":"Include Collection Analysis","description":"Whether to check existing collections","default":true}},"type":"object","required":["user_request"],"title":"DetectIntentRequest","description":"Request to detect intent from user input.\n\nAttributes:\n    user_request: The user's natural language request to analyze\n    include_collection_analysis: Whether to analyze existing collections"},"DiagnosticHistory":{"properties":{"entries":{"items":{"$ref":"#/components/schemas/DiagnosticHistoryEntry"},"type":"array","title":"Entries","description":"Ordered processing-history entries read from the document."},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason","description":"Present when no entries were found, naming what durability record would carry richer history but exposes no per-object read surface."}},"type":"object","title":"DiagnosticHistory","description":"The document's safe processing history."},"DiagnosticHistoryEntry":{"properties":{"source":{"type":"string","title":"Source","description":"Which record carried this entry (e.g. 'processing.history', 'lineage.chain', 'ingestion_status')."},"timestamp":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timestamp","description":"ISO-8601 timestamp of the entry, when available."},"detail":{"additionalProperties":true,"type":"object","title":"Detail","description":"The raw entry payload."}},"type":"object","required":["source"],"title":"DiagnosticHistoryEntry","description":"One processing-history entry for the document."},"DiffItem":{"properties":{"resource_type":{"type":"string","title":"Resource Type","description":"Type of resource"},"name":{"type":"string","title":"Name","description":"Resource name"},"action":{"type":"string","title":"Action","description":"Action: create, update, delete, unchanged"},"details":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Details","description":"Details about the difference"}},"type":"object","required":["resource_type","name","action"],"title":"DiffItem","description":"A single difference between manifest and current state."},"DiffResult":{"properties":{"to_create":{"items":{"$ref":"#/components/schemas/DiffItem"},"type":"array","title":"To Create","description":"Resources in manifest but not in system"},"in_system_only":{"items":{"$ref":"#/components/schemas/DiffItem"},"type":"array","title":"In System Only","description":"Resources in system but not in manifest"},"differences":{"items":{"$ref":"#/components/schemas/DiffItem"},"type":"array","title":"Differences","description":"Resources in both with differences"}},"type":"object","title":"DiffResult","description":"Result of comparing manifest to current state."},"DisableOrgModelResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether operation succeeded"},"model_id":{"type":"string","title":"Model Id","description":"Model identifier"},"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace where model was disabled"},"message":{"type":"string","title":"Message","description":"Status message"}},"type":"object","required":["success","model_id","namespace_id","message"],"title":"DisableOrgModelResponse","description":"Response from disabling an org-level model for a namespace."},"DiscoveryResponse":{"properties":{"extractors":{"items":{"$ref":"#/components/schemas/ExtractorDiscovery"},"type":"array","title":"Extractors","description":"Available feature extractors"},"stages":{"items":{"$ref":"#/components/schemas/StageDiscovery"},"type":"array","title":"Stages","description":"Available retriever stages"},"manifest_schema":{"anyOf":[{"$ref":"#/components/schemas/ManifestSchemaDiscovery"},{"type":"null"}],"description":"Manifest schema information"},"models":{"items":{"$ref":"#/components/schemas/ModelCatalogIndexEntry"},"type":"array","title":"Models","description":"Compact model catalog index, highest rank first. GET /v1/discovery/models/{model_id} returns a full record; an extractor source can name one as ref: catalog://<id>"}},"type":"object","title":"DiscoveryResponse","description":"Combined discovery response with all available resources."},"DisplayConfig-Input":{"properties":{"title":{"type":"string","title":"Title","description":"Title/heading for the public search page","examples":["Product Search","Video Library","Creative Assets"]},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Optional description/subtitle for the page","examples":["Search through thousands of products","Find the perfect video clip"]},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url","description":"URL to logo image","examples":["https://example.com/logo.png"]},"icon_base64":{"anyOf":[{"type":"string","maxLength":300000},{"type":"null"}],"title":"Icon Base64","description":"Base64 encoded icon/favicon (data URI format recommended). Max size: ~200KB encoded. Use for small icons that should be embedded. Example: 'data:image/png;base64,iVBORw0KGgo...'","examples":["data:image/png;base64,iVBORw0KGgoAAAANS..."]},"seo":{"anyOf":[{"$ref":"#/components/schemas/SEOConfig"},{"type":"null"}],"description":"SEO configuration for search engine and social media discoverability. Auto-generated during publishing with sensible defaults inferred from title, description, and retriever metadata. All fields can be overridden."},"markdowns":{"items":{"$ref":"#/components/schemas/MarkdownContent"},"type":"array","title":"Markdowns","description":"Array of markdown content sections for documentation, guides, or informational modals. Each section has a title and markdown-formatted content. Displayed in modals, expandable sections, or tabs on the public interface. Examples: 'How it Works', 'Search Guide', 'About', 'FAQ', etc."},"theme":{"$ref":"#/components/schemas/ThemeConfig","description":"Theme/styling configuration"},"inputs":{"items":{"$ref":"#/components/schemas/InputRenderingConfig-Input"},"type":"array","title":"Inputs","description":"List of input fields to render in the search interface. Each input maps to a field in the retriever's input_schema. Frontend uses the field_schema to render the appropriate component type."},"layout":{"$ref":"#/components/schemas/LayoutConfig","description":"Layout configuration for results"},"exposed_fields":{"items":{"type":"string"},"type":"array","minItems":1,"title":"Exposed Fields","description":"List of document metadata fields to show in results. Only these fields are returned to end users."},"components":{"$ref":"#/components/schemas/ComponentsConfig","description":"Configuration for UI components including search inputs, filters, and result card display options."},"field_config":{"additionalProperties":{"$ref":"#/components/schemas/FieldConfig"},"type":"object","title":"Field Config","description":"Configuration for how each field should be displayed. Keys are field names (must be subset of exposed_fields). Values are FieldConfig objects specifying format and display options.","examples":[{"created_at":{"format":"date","format_options":{"date_format":"relative","label":"Posted"}},"price":{"format":"number","format_options":{"decimals":2,"label":"Price","prefix":"$"}},"thumbnail_url":{"format":"image","format_options":{"aspect_ratio":"16/9","height":300,"width":400}},"title":{"format":"text","format_options":{"label":"Title","truncate_chars":60}}}]},"custom_cta":{"anyOf":[{"$ref":"#/components/schemas/CustomCTA"},{"type":"null"}],"description":"Optional custom call-to-action button displayed in the header bar. Opens a markdown modal when clicked."},"external_links":{"items":{"$ref":"#/components/schemas/ExternalLink"},"type":"array","title":"External Links","description":"External resource links for this retriever (GitHub repos, blog posts, docs, etc.). Displayed on homepage and retriever listing pages to provide additional context.","examples":[[{"name":"GitHub Repository","url":"https://github.com/org/repo"},{"name":"Blog Post","url":"https://blog.example.com/post"}]]},"template_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Template Type","description":"Template identifier for frontend rendering. Built-in templates: portrait-gallery, media-search, document-search. Custom templates can use any string identifier.","examples":["portrait-gallery","media-search","document-search"]},"field_mappings":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Field Mappings","description":"Field mappings from collection output fields to template display slots. Maps template slot names (e.g., 'thumbnail', 'title') to actual field names in the search results.","examples":[{"boundingBox":"ocr_bbox","extractedText":"ocr_text","thumbnail":"page_thumbnail_url","title":"document_title"}]},"extensions":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Extensions","description":"Generic extensions for template-specific configuration. Allows templates to store custom config without schema changes.","examples":[{"show_timestamps":true,"video_autoplay":true},{"bbox_highlight_color":"#FF0000","show_confidence_badge":true}]},"retriever_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Retriever Config","description":"Embedded retriever configuration (stages, feature extractors) for the View Config modal. Auto-populated at publish time."}},"additionalProperties":true,"type":"object","required":["title","inputs","exposed_fields"],"title":"DisplayConfig","description":"Display configuration for public retriever UI.\n\nThis model defines how the public search interface should be rendered,\nincluding input fields, theme, layout, and result card configuration.\n\nThe frontend (mxp.co) uses this to dynamically build the UI\nwithout hardcoded components.","examples":[{"components":{"result_card":{"card_click_action":"viewDetails","field_order":["title","description","price"],"layout":"vertical","show_find_similar":true,"show_thumbnail":true},"result_layout":"grid","show_hero":true,"show_results_header":true,"show_search":true},"custom_cta":{"label":"Search Tips","markdown_content":"# Search Tips\n\n- Use quotes for exact phrases\n- Try descriptive terms"},"description":"Search through our product catalog","exposed_fields":["title","description","price","image_url"],"external_links":[{"name":"GitHub Repository","url":"https://github.com/mixpeek/product-search"},{"name":"Blog Post","url":"https://blog.mixpeek.com/building-product-search"}],"field_config":{"price":{"format":"number","format_options":{"decimals":2,"label":"Price","prefix":"$"}},"title":{"format":"text","format_options":{"label":"Product Name","truncate_chars":60}}},"field_mappings":{"thumbnail":"image_url","title":"title"},"inputs":[{"field_name":"query","field_schema":{"description":"Search query","examples":["wireless headphones","laptop"],"type":"string"},"input_type":"text","label":"Search Products","order":0,"placeholder":"What are you looking for?","required":true}],"layout":{"columns":3,"gap":"16px","mode":"grid"},"logo_url":"https://example.com/logo.png","markdowns":[{"content":"# AI-Powered Product Search\n\nOur search uses **machine learning** to understand your queries and find the most relevant products.\n\n## Features\n\n- **Semantic Search**: Understands meaning, not just keywords\n- **Visual Search**: Upload images to find similar products\n- **Smart Filters**: Automatically suggests relevant filters","title":"How it Works"},{"content":"## Tips for Better Results\n\n1. Use descriptive terms (e.g., \"wireless noise-canceling headphones\")\n2. Try different keywords if you don't find what you're looking for\n3. Use filters to narrow down results\n\n*Happy searching!*","title":"Search Guide"}],"template_type":"media-search","theme":{"border_radius":"12px","card_style":"elevated","font_family":"Inter, sans-serif","primary_color":"#007AFF"},"title":"Product Search"}]},"DisplayConfig-Output":{"properties":{"title":{"type":"string","title":"Title","description":"Title/heading for the public search page","examples":["Product Search","Video Library","Creative Assets"]},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Optional description/subtitle for the page","examples":["Search through thousands of products","Find the perfect video clip"]},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url","description":"URL to logo image","examples":["https://example.com/logo.png"]},"icon_base64":{"anyOf":[{"type":"string","maxLength":300000},{"type":"null"}],"title":"Icon Base64","description":"Base64 encoded icon/favicon (data URI format recommended). Max size: ~200KB encoded. Use for small icons that should be embedded. Example: 'data:image/png;base64,iVBORw0KGgo...'","examples":["data:image/png;base64,iVBORw0KGgoAAAANS..."]},"seo":{"anyOf":[{"$ref":"#/components/schemas/SEOConfig"},{"type":"null"}],"description":"SEO configuration for search engine and social media discoverability. Auto-generated during publishing with sensible defaults inferred from title, description, and retriever metadata. All fields can be overridden."},"markdowns":{"items":{"$ref":"#/components/schemas/MarkdownContent"},"type":"array","title":"Markdowns","description":"Array of markdown content sections for documentation, guides, or informational modals. Each section has a title and markdown-formatted content. Displayed in modals, expandable sections, or tabs on the public interface. Examples: 'How it Works', 'Search Guide', 'About', 'FAQ', etc."},"theme":{"$ref":"#/components/schemas/ThemeConfig","description":"Theme/styling configuration"},"inputs":{"items":{"$ref":"#/components/schemas/InputRenderingConfig-Output"},"type":"array","title":"Inputs","description":"List of input fields to render in the search interface. Each input maps to a field in the retriever's input_schema. Frontend uses the field_schema to render the appropriate component type."},"layout":{"$ref":"#/components/schemas/LayoutConfig","description":"Layout configuration for results"},"exposed_fields":{"items":{"type":"string"},"type":"array","minItems":1,"title":"Exposed Fields","description":"List of document metadata fields to show in results. Only these fields are returned to end users."},"components":{"$ref":"#/components/schemas/ComponentsConfig","description":"Configuration for UI components including search inputs, filters, and result card display options."},"field_config":{"additionalProperties":{"$ref":"#/components/schemas/FieldConfig"},"type":"object","title":"Field Config","description":"Configuration for how each field should be displayed. Keys are field names (must be subset of exposed_fields). Values are FieldConfig objects specifying format and display options.","examples":[{"created_at":{"format":"date","format_options":{"date_format":"relative","label":"Posted"}},"price":{"format":"number","format_options":{"decimals":2,"label":"Price","prefix":"$"}},"thumbnail_url":{"format":"image","format_options":{"aspect_ratio":"16/9","height":300,"width":400}},"title":{"format":"text","format_options":{"label":"Title","truncate_chars":60}}}]},"custom_cta":{"anyOf":[{"$ref":"#/components/schemas/CustomCTA"},{"type":"null"}],"description":"Optional custom call-to-action button displayed in the header bar. Opens a markdown modal when clicked."},"external_links":{"items":{"$ref":"#/components/schemas/ExternalLink"},"type":"array","title":"External Links","description":"External resource links for this retriever (GitHub repos, blog posts, docs, etc.). Displayed on homepage and retriever listing pages to provide additional context.","examples":[[{"name":"GitHub Repository","url":"https://github.com/org/repo"},{"name":"Blog Post","url":"https://blog.example.com/post"}]]},"template_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Template Type","description":"Template identifier for frontend rendering. Built-in templates: portrait-gallery, media-search, document-search. Custom templates can use any string identifier.","examples":["portrait-gallery","media-search","document-search"]},"field_mappings":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Field Mappings","description":"Field mappings from collection output fields to template display slots. Maps template slot names (e.g., 'thumbnail', 'title') to actual field names in the search results.","examples":[{"boundingBox":"ocr_bbox","extractedText":"ocr_text","thumbnail":"page_thumbnail_url","title":"document_title"}]},"extensions":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Extensions","description":"Generic extensions for template-specific configuration. Allows templates to store custom config without schema changes.","examples":[{"show_timestamps":true,"video_autoplay":true},{"bbox_highlight_color":"#FF0000","show_confidence_badge":true}]},"retriever_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Retriever Config","description":"Embedded retriever configuration (stages, feature extractors) for the View Config modal. Auto-populated at publish time."}},"additionalProperties":true,"type":"object","required":["title","inputs","exposed_fields"],"title":"DisplayConfig","description":"Display configuration for public retriever UI.\n\nThis model defines how the public search interface should be rendered,\nincluding input fields, theme, layout, and result card configuration.\n\nThe frontend (mxp.co) uses this to dynamically build the UI\nwithout hardcoded components.","examples":[{"components":{"result_card":{"card_click_action":"viewDetails","field_order":["title","description","price"],"layout":"vertical","show_find_similar":true,"show_thumbnail":true},"result_layout":"grid","show_hero":true,"show_results_header":true,"show_search":true},"custom_cta":{"label":"Search Tips","markdown_content":"# Search Tips\n\n- Use quotes for exact phrases\n- Try descriptive terms"},"description":"Search through our product catalog","exposed_fields":["title","description","price","image_url"],"external_links":[{"name":"GitHub Repository","url":"https://github.com/mixpeek/product-search"},{"name":"Blog Post","url":"https://blog.mixpeek.com/building-product-search"}],"field_config":{"price":{"format":"number","format_options":{"decimals":2,"label":"Price","prefix":"$"}},"title":{"format":"text","format_options":{"label":"Product Name","truncate_chars":60}}},"field_mappings":{"thumbnail":"image_url","title":"title"},"inputs":[{"field_name":"query","field_schema":{"description":"Search query","examples":["wireless headphones","laptop"],"type":"string"},"input_type":"text","label":"Search Products","order":0,"placeholder":"What are you looking for?","required":true}],"layout":{"columns":3,"gap":"16px","mode":"grid"},"logo_url":"https://example.com/logo.png","markdowns":[{"content":"# AI-Powered Product Search\n\nOur search uses **machine learning** to understand your queries and find the most relevant products.\n\n## Features\n\n- **Semantic Search**: Understands meaning, not just keywords\n- **Visual Search**: Upload images to find similar products\n- **Smart Filters**: Automatically suggests relevant filters","title":"How it Works"},{"content":"## Tips for Better Results\n\n1. Use descriptive terms (e.g., \"wireless noise-canceling headphones\")\n2. Try different keywords if you don't find what you're looking for\n3. Use filters to narrow down results\n\n*Happy searching!*","title":"Search Guide"}],"template_type":"media-search","theme":{"border_radius":"12px","card_style":"elevated","font_family":"Inter, sans-serif","primary_color":"#007AFF"},"title":"Product Search"}]},"DistinctValue":{"properties":{"value":{"title":"Value","description":"The distinct field value. A JSON number or boolean when the namespace declares a payload index of type integer, float or bool on the field; any other field, including an undeclared numeric one, facets as strings."},"count":{"type":"integer","title":"Count","description":"Number of documents with this exact value."}},"type":"object","required":["value","count"],"title":"DistinctValue","description":"One distinct value and how many documents carry it."},"DistinctValuesRequest":{"properties":{"field":{"type":"string","title":"Field","description":"Document field whose distinct values should be returned. Dotted paths are supported (e.g. `metadata.brand_slug`). Null/missing values are excluded.","examples":["brand_slug","metadata.category"]},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","description":"Optional pre-aggregation filters, same syntax as the standard aggregation endpoint. Applied before distinct values are computed."},"limit":{"anyOf":[{"type":"integer","maximum":10000.0,"minimum":1.0},{"type":"null"}],"title":"Limit","description":"Maximum number of distinct values to return (sorted by count desc). Defaults to no limit on the server side; for high-cardinality fields always set a limit to keep the response bounded."}},"type":"object","required":["field"],"title":"DistinctValuesRequest","description":"Return the set of unique values for a single field across a collection.\n\nThin wrapper over the aggregation framework for the common `SELECT DISTINCT\n<field>` use case. Callers don't need to build a `group_by` + COUNT pipeline\nby hand — pass a field name and (optionally) pre-aggregation filters and\nget back a flat list of values plus per-value counts."},"DistinctValuesResponse":{"properties":{"field":{"type":"string","title":"Field","description":"The field that was queried."},"values":{"items":{"$ref":"#/components/schemas/DistinctValue"},"type":"array","title":"Values","description":"Distinct values sorted by descending count. Respects the `limit` argument; use the length of this list as the returned count."},"total_distinct":{"type":"integer","title":"Total Distinct","description":"Number of distinct values in the response (== len(values)). When `limit` is set this can be less than the true cardinality."},"query_info":{"additionalProperties":true,"type":"object","title":"Query Info","description":"Empty when the answer is complete. When a storage shard timed out or returned only part of its documents, this holds `truncated: true`, a `reason`, any `shard_warnings`, and a `warning`; the list may then be missing values and every count is a lower bound. Retrying usually gives the full answer."}},"type":"object","required":["field","values","total_distinct"],"title":"DistinctValuesResponse","description":"Flat list of distinct values for a single field."},"DocsSearchOptions":{"properties":{"enable_image_search":{"type":"boolean","title":"Enable Image Search","description":"Enable SigLIP image embeddings for diagram/screenshot search.","default":false},"enable_code_search":{"type":"boolean","title":"Enable Code Search","description":"Enable Jina Code embeddings for code-aware search.","default":true},"max_pages":{"type":"integer","maximum":5000.0,"minimum":1.0,"title":"Max Pages","description":"Maximum pages to crawl.","default":200},"max_depth":{"type":"integer","maximum":10.0,"minimum":1.0,"title":"Max Depth","description":"Maximum crawl depth from seed URL.","default":3},"chunk_strategy":{"type":"string","title":"Chunk Strategy","description":"Text chunking strategy.","default":"paragraphs"},"chunk_size":{"type":"integer","maximum":2000.0,"minimum":100.0,"title":"Chunk Size","description":"Chunk size in units of chunk_strategy.","default":500},"render_strategy":{"type":"string","title":"Render Strategy","description":"Page rendering strategy: static, javascript, or auto.","default":"auto"}},"type":"object","title":"DocsSearchOptions","description":"Optional configuration for docs search setup."},"DocsSearchRequest":{"properties":{"site_url":{"type":"string","minLength":1,"title":"Site Url","description":"Root URL of the documentation site to crawl.","examples":["https://docs.example.com","https://example.com/docs"]},"site_name":{"type":"string","maxLength":100,"minLength":1,"title":"Site Name","description":"Human-readable name for the docs site.","examples":["Example Docs","Acme API Reference"]},"include_patterns":{"items":{"type":"string"},"type":"array","title":"Include Patterns","description":"URL patterns to include (regex). Empty means include all.","examples":[["/docs/.*","/api/.*"]]},"exclude_patterns":{"items":{"type":"string"},"type":"array","title":"Exclude Patterns","description":"URL patterns to exclude (regex).","examples":[["*/changelog/*","*/blog/*"]]},"namespace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Namespace Id","description":"Existing namespace ID. If not provided, one will be created."},"options":{"$ref":"#/components/schemas/DocsSearchOptions","description":"Optional configuration overrides."}},"type":"object","required":["site_url","site_name"],"title":"DocsSearchRequest","description":"Request to provision a docs search pipeline."},"DocsSearchResponse":{"properties":{"project_key":{"type":"string","title":"Project Key","description":"Retriever-scoped API key (ret_sk_...) for widget authentication."},"public_name":{"type":"string","title":"Public Name","description":"Public retriever name for API access."},"retriever_id":{"type":"string","title":"Retriever Id","description":"ID of the created retriever."},"collection_id":{"type":"string","title":"Collection Id","description":"ID of the web crawl collection."},"batch_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Batch Id","description":"ID of the crawl batch (if processing started)."},"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace ID for all resources."},"bucket_id":{"type":"string","title":"Bucket Id","description":"Bucket ID where seed URLs are stored."},"embed_snippet":{"type":"string","title":"Embed Snippet","description":"HTML snippet for drop-in integration."},"react_snippet":{"type":"string","title":"React Snippet","description":"React component snippet."}},"type":"object","required":["project_key","public_name","retriever_id","collection_id","namespace_id","bucket_id","embed_snippet","react_snippet"],"title":"DocsSearchResponse","description":"Response after provisioning a docs search pipeline."},"DocumentAggregationRequest":{"properties":{"group_by":{"items":{"$ref":"#/components/schemas/GroupByField"},"type":"array","title":"Group By","description":"Fields to group results by. Results have one row per unique combination of group_by values. Can include field transformations (date_trunc, date_part). To count the documents that match `filters`, omit group_by and send only count aggregations, for example {\"aggregations\": [{\"function\": \"count\", \"alias\": \"total\"}]}: the response is one row whose metrics hold that count. Every other aggregation needs at least one group_by field."},"aggregations":{"items":{"$ref":"#/components/schemas/AggregationOperation"},"type":"array","minItems":1,"title":"Aggregations","description":"Aggregation operations to perform. REQUIRED, at least one operation. Each operation produces a calculated field in results. Can combine multiple functions (COUNT, SUM, AVG, etc.)."},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","description":"Pre-aggregation filters to apply to source data. OPTIONAL, filters data before grouping. Uses same syntax as standard query filters. Applied before GROUP BY.","examples":[{"metadata.status":"active"},{"created_at":{"$gte":"2024-01-01"},"metadata.type":"video"}]},"having":{"anyOf":[{"items":{"$ref":"#/components/schemas/HavingCondition"},"type":"array"},{"type":"null"}],"title":"Having","description":"Post-aggregation filters to apply to results. OPTIONAL, filters groups after aggregation. Uses aggregation aliases as field names. Applied after GROUP BY and aggregation calculations."},"unwind":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unwind","description":"Array field to unwind before aggregation. OPTIONAL, creates one document per array element. Useful for aggregating over array contents. Example: 'blobs' to analyze each blob separately.","examples":["blobs","metadata.tags","metadata.categories"]},"range_buckets":{"anyOf":[{"items":{"$ref":"#/components/schemas/RangeBucket"},"type":"array"},{"type":"null"}],"title":"Range Buckets","description":"Range-based bucketing for numeric fields. OPTIONAL, creates histogram-style buckets. Groups numeric values into defined ranges. Applied during grouping stage."},"sort_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sort By","description":"Field to sort results by. OPTIONAL, can be group_by field or aggregation alias. Defaults to no specific order. Use with sort_direction to control order.","examples":["total_count","avg_duration","category"]},"sort_direction":{"type":"string","title":"Sort Direction","description":"Sort direction. OPTIONAL, defaults to 'desc' (descending). Valid values: 'asc' (ascending), 'desc' (descending). Used with sort_by field.","default":"desc","examples":["asc","desc"]},"limit":{"anyOf":[{"type":"integer","exclusiveMinimum":0.0},{"type":"null"}],"title":"Limit","description":"Maximum number of results to return. OPTIONAL, no limit if not specified. Applied after sorting. Useful for 'top N' queries.","examples":[10,50,100]}},"type":"object","required":["aggregations"],"title":"DocumentAggregationRequest","description":"Aggregation request for collection documents.\n\nExtends the base AggregationRequest with document-specific context.\nInherits all fields from AggregationRequest.\n\nRequirements:\n    - group_by: fields to group by. May be omitted (or empty) only when every\n      aggregation is a count: the response is then one row holding the\n      number of documents matching ``filters``.\n    - aggregations: REQUIRED, aggregation operations to perform\n    - All other fields from AggregationRequest are available\n\nExamples:\n    - Count documents by feature type\n    - Daily processing statistics\n    - User-based analytics with filtering","examples":[{"aggregations":[{"alias":"total","function":"count"}],"description":"Count documents matching a filter","filters":{"metadata.status":"active"}},{"aggregations":[{"alias":"total","function":"count"}],"description":"Count documents by collection","group_by":[{"alias":"collection","field":"collection_id"}],"sort_by":"total","sort_direction":"desc"},{"aggregations":[{"alias":"documents","function":"count"},{"alias":"unique_objects","distinct_field":"object_id","function":"count_distinct"}],"description":"Daily document creation statistics","group_by":[{"alias":"date","date_trunc":"day","field":"created_at"}],"sort_by":"date","sort_direction":"asc"},{"aggregations":[{"alias":"count","function":"count"},{"alias":"avg_confidence","field":"features.confidence","function":"avg"}],"description":"Feature distribution with filtering","filters":{"collection_id":"my-collection"},"group_by":[{"alias":"feature_type","field":"features.type"}],"having":[{"field":"count","operator":"gte","value":10}],"sort_by":"count","sort_direction":"desc"}]},"DocumentAggregationResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/AggregationResult"},"type":"array","title":"Results","description":"List of aggregation results, one per group."},"total_groups":{"type":"integer","title":"Total Groups","description":"Total number of unique groups returned."},"query_info":{"additionalProperties":true,"type":"object","title":"Query Info","description":"Additional information about the query execution. May include collection info, pipeline stages, execution time, etc."}},"type":"object","required":["results","total_groups"],"title":"DocumentAggregationResponse","description":"Response containing document aggregation results.\n\nReturns aggregated statistics grouped by specified fields.","examples":[{"query_info":{"collection_id":"my-collection","execution_time_ms":32,"pipeline_stages":4},"results":[{"group":{"collection":"coll_123"},"metrics":{"total":523}},{"group":{"collection":"coll_456"},"metrics":{"total":187}}],"total_groups":2}]},"DocumentCountResponse":{"properties":{"collection_id":{"type":"string","title":"Collection Id","description":"The collection the count is for (resolved id)."},"count":{"type":"integer","title":"Count","description":"Total number of documents in the collection."}},"type":"object","required":["collection_id","count"],"title":"DocumentCountResponse","description":"Response model for the document-count endpoint.\n\nReturned by ``GET /v1/collections/{collection_id}/documents/count`` — the\nobvious REST guess for \"how many documents are in this collection?\" that\npreviously 404'd (the literal ``count`` segment was matched as a\n``{document_id}``). See FRUSTRATIONS 2026-06-29."},"DocumentCreateRequest":{"properties":{"collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Collection Id","description":"ID of the collection the document belongs to. Optional on POST /v1/collections/{collection_id}/documents — the collection is already identified by the URL path, so an omitted body collection_id is filled from the path (a mismatch is still rejected). Required when the request is not path-scoped.","example":"collection_123"},"root_object_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Root Object Id","description":"Optional denormalized root object identifier provided during creation."},"root_bucket_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Root Bucket Id","description":"Optional denormalized bucket identifier provided during creation."},"source_type":{"anyOf":[{"type":"string","enum":["bucket","collection","direct_upsert","signal"]},{"type":"null"}],"title":"Source Type","description":"Optional immediate parent type for the document."},"source_collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Collection Id","description":"Optional parent collection identifier when sourced from a collection."},"source_document_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Document Id","description":"Optional parent document identifier when sourced from a collection."},"source_object_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Object Id","description":"Optional parent object identifier when sourced directly from a bucket."},"lineage_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lineage Path","description":"Optional materialized lineage path to set during creation."},"lineage_chain":{"items":{"$ref":"#/components/schemas/LineageStep"},"type":"array","title":"Lineage Chain","description":"Processing steps from root object to this document. Recommended for decomposition trees."},"content_hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Content Hash","description":"Optional SHA256 content hash of the source object. Supplying it on a lineage-preserving import lets a later heal/reprocess recognise the cached derivation potency and skip recompute instead of re-spending GPU. Stored at _internal.content_hash."},"document_schema_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Schema Version","description":"Optional document schema version (v1 or v2). If not provided, uses system default."},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Optional metadata dictionary for user-defined fields and custom attributes."},"features":{"items":{"$ref":"#/components/schemas/FeatureModel"},"type":"array","title":"Features","description":"Features to associate with the document"},"vectors":{"anyOf":[{"additionalProperties":{"items":{"type":"number"},"type":"array"},"type":"object"},{"type":"null"}],"title":"Vectors","description":"Optional pre-computed vectors to store with the document. Keys are the names of the collection's vector indexes. A key is either the last segment of the index `feature_uri` (`multilingual_e5_large_instruct_v1` for `mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1`) or the full index name (`text_extractor_v1_embedding`). Either way the vector is stored under the full index name. Values are float arrays with the index dimensions. A key the collection does not have returns a 422 that lists the available index names and dimensions. Read the names from `vector_indexes` on `GET /v1/collections/{collection_id}`."}},"additionalProperties":true,"type":"object","title":"DocumentCreateRequest","description":"Request model for creating a document."},"DocumentDiagnosticsResponse":{"properties":{"document_id":{"type":"string","title":"Document Id"},"collection_id":{"type":"string","title":"Collection Id"},"source_object_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Object Id","description":"The document's originating bucket object id (lineage root)."},"visibility_reason":{"$ref":"#/components/schemas/VisibilityReason"},"recent_failures":{"$ref":"#/components/schemas/RecentFailures"},"diagnostic_history":{"$ref":"#/components/schemas/DiagnosticHistory"}},"type":"object","required":["document_id","collection_id","visibility_reason","recent_failures","diagnostic_history"],"title":"DocumentDiagnosticsResponse","description":"Support diagnostics for one document."},"DocumentGraphExtractorParams":{"properties":{"extractor_type":{"type":"string","const":"document_graph_extractor","title":"Extractor Type","description":"Discriminator field for parameter type identification. Must be 'document_graph_extractor'.","default":"document_graph_extractor"},"use_layout_detection":{"type":"boolean","title":"Use Layout Detection","description":"Enable ML-based layout detection to find ALL document elements (text, images, tables, figures). When enabled, uses the configured layout_detector to detect and extract both text regions AND non-text elements (scanned images, figures, charts) as separate documents. **Recommended for**: Scanned documents, image-heavy PDFs, mixed content documents. **When disabled**: Falls back to text-only extraction (faster but misses images). Default: True (detects all elements including images).","default":true},"layout_detector":{"type":"string","enum":["pymupdf","docling"],"title":"Layout Detector","description":"Layout detection engine to use when use_layout_detection=True. 'pymupdf': Fast, rule-based detection using PyMuPDF heuristics (~15 pages/sec). 'docling': SOTA ML-based detection using IBM Docling with DiT model (~3-8 sec/doc). **Docling advantages**: Better semantic type detection (section_header vs paragraph), true table structure extraction (rows/cols), more accurate figure detection. **PyMuPDF advantages**: Much faster, lower memory usage, simpler dependencies. Default: 'pymupdf' for speed. Use 'docling' for accuracy-critical applications.","default":"pymupdf"},"vertical_threshold":{"type":"number","maximum":100.0,"minimum":1.0,"title":"Vertical Threshold","description":"Maximum vertical gap (in points) between lines to be grouped in same block. Increase for looser grouping, decrease for tighter blocks. Default 15pt works well for standard documents.","default":15.0},"horizontal_threshold":{"type":"number","maximum":200.0,"minimum":1.0,"title":"Horizontal Threshold","description":"Maximum horizontal distance (in points) for overlap detection. Affects column detection and block merging. Increase for wider columns, decrease for narrow layouts.","default":50.0},"min_text_length":{"type":"integer","maximum":500.0,"minimum":1.0,"title":"Min Text Length","description":"Minimum text length (characters) to keep a block. Blocks with less text are filtered out. Helps remove noise and tiny fragments.","default":20},"base_confidence":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Base Confidence","description":"Base confidence score for embedded (native) text. Penalties are subtracted for OCR artifacts, encoding issues, etc.","default":0.85},"min_confidence_for_vlm":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Min Confidence For Vlm","description":"Confidence threshold below which VLM correction is triggered. Blocks with confidence < this value get sent to VLM for correction. Only applies when use_vlm_correction=True.","default":0.6},"use_vlm_correction":{"type":"boolean","title":"Use Vlm Correction","description":"Enable VLM (Vision Language Model) correction for low-confidence blocks. Uses Gemini/GPT-4V to correct OCR errors by analyzing the page image. Significantly slower (~1 page/sec) but improves accuracy for degraded docs.","default":true},"fast_mode":{"type":"boolean","title":"Fast Mode","description":"Skip VLM correction entirely for maximum throughput (~15 pages/sec). Overrides use_vlm_correction. Use when speed is more important than accuracy.","default":false},"vlm_provider":{"type":"string","title":"Vlm Provider","description":"LLM provider for VLM correction. Options: 'google' (Gemini), 'openai' (GPT-4V), 'anthropic' (Claude). Google recommended for best vision quality.","default":"google"},"vlm_model":{"type":"string","title":"Vlm Model","description":"Specific model for VLM correction. Examples: 'gemini-2.5-flash', 'gpt-4o', 'claude-3-5-sonnet'.","default":"gemini-2.5-flash"},"llm_api_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Llm Api Key","description":"API key for VLM correction (BYOK - Bring Your Own Key). Supports:\n- Direct key: 'sk-proj-abc123...'\n- Secret reference: '{{SECRET.openai_api_key}}'\n\nWhen using secret reference, the key is loaded from your organization's secrets vault at runtime. Store secrets via POST /v1/organizations/secrets.\n\nIf not provided, uses Mixpeek's default API keys."},"run_text_embedding":{"type":"boolean","title":"Run Text Embedding","description":"Generate text embeddings for semantic search over block content. Uses E5-Large (1024-dim) for multilingual support.","default":true},"render_dpi":{"type":"integer","maximum":300.0,"minimum":72.0,"title":"Render Dpi","description":"DPI for page rendering (used for VLM correction). 72: Fast, lower quality. 150: Balanced (recommended). 300: High quality, slower.","default":150},"generate_thumbnails":{"type":"boolean","title":"Generate Thumbnails","description":"Generate thumbnail images for blocks. Useful for visual previews and UI display.","default":true},"thumbnail_mode":{"type":"string","title":"Thumbnail Mode","description":"Thumbnail generation mode. 'full_page': Low-res thumbnail of entire page. 'segment': Cropped thumbnail of just the block's bounding box. 'both': Generate both types (recommended for flexibility).","default":"both"},"thumbnail_dpi":{"type":"integer","maximum":150.0,"minimum":36.0,"title":"Thumbnail Dpi","description":"DPI for thumbnail generation. Lower DPI = smaller files. 72: Standard web quality. 36: Very small thumbnails.","default":72}},"type":"object","title":"DocumentGraphExtractorParams","description":"Parameters for the document graph extractor.\n\nThis extractor decomposes PDFs into spatial blocks with layout classification,\nconfidence scoring, and optional VLM correction for degraded documents.\n\n**When to Use**:\n    - Historical/archival document processing (FBI files, old records)\n    - Scanned documents with mixed quality\n    - Documents requiring spatial understanding (forms, tables, multi-column)\n    - When you need block-level granularity with bounding boxes\n    - When confidence scoring is needed for downstream filtering\n\n**When NOT to Use**:\n    - Simple text-only documents -> Use text_extractor instead\n    - When page-level granularity is sufficient -> Use pdf_extractor instead\n    - Real-time processing requirements -> VLM correction adds latency","examples":[{"description":"Fast processing mode (no VLM, maximum throughput)","extractor_type":"document_graph_extractor","fast_mode":true,"generate_thumbnails":true,"layout_detector":"pymupdf","run_text_embedding":true,"use_case":"High-volume document ingestion where speed matters more than perfect accuracy","use_layout_detection":true},{"description":"Archival documents with VLM correction (recommended for old scans)","extractor_type":"document_graph_extractor","layout_detector":"pymupdf","min_confidence_for_vlm":0.6,"render_dpi":150,"run_text_embedding":true,"use_case":"Historical archives, FBI files, old scanned documents with degraded quality","use_layout_detection":true,"use_vlm_correction":true,"vlm_model":"gemini-2.5-flash","vlm_provider":"google"},{"description":"SOTA accuracy mode with Docling (best for tables/figures)","extractor_type":"document_graph_extractor","fast_mode":true,"generate_thumbnails":true,"layout_detector":"docling","run_text_embedding":true,"use_case":"Documents with complex tables, figures, or requiring accurate semantic typing","use_layout_detection":true}]},"DocumentGroup":{"properties":{"group_key":{"title":"Group Key","description":"The value that documents in this group share for the group_by field. Can be string, number, boolean, or null depending on the field type. Examples: 'obj_video123' (for source_object_id), 'Electronics' (for metadata.category).","examples":["obj_video123","Electronics","bucket",42,true,null]},"documents":{"items":{"$ref":"#/components/schemas/DocumentResponse"},"type":"array","title":"Documents","description":"List of documents that share the same group_key value. Documents within each group are sorted by relevance/score if applicable. Each document contains full document data including metadata, lineage, and blobs."},"count":{"type":"integer","title":"Count","description":"Number of documents in this group.","examples":[1,5,12]}},"type":"object","required":["group_key","documents","count"],"title":"DocumentGroup","description":"A group of documents with the same field value.\n\nUsed when group_by parameter is specified in ListDocumentsRequest.","examples":[{"count":120,"description":"Group by source_object_id - all frames from one video","documents":[{"collection_id":"col_video_frames","document_id":"doc_frame_001","metadata":{"frame_number":1,"timestamp":0.033},"source_object_id":"obj_video123"},{"collection_id":"col_video_frames","document_id":"doc_frame_002","metadata":{"frame_number":2,"timestamp":0.066},"source_object_id":"obj_video123"}],"group_key":"obj_video123"},{"count":15,"description":"Group by metadata.category - products by category","documents":[{"collection_id":"col_products","document_id":"doc_product_001","metadata":{"category":"Electronics","name":"Laptop"}}],"group_key":"Electronics"}]},"DocumentIdStrategy":{"type":"string","enum":["url","position","content"],"title":"DocumentIdStrategy","description":"Strategy for generating deterministic document IDs.\n\nValues:\n    URL: hash(page_url + chunk_index) - stable across re-crawls\n    POSITION: hash(seed_url + page_index + chunk_index) - order-based\n    CONTENT: hash(content) - deduplicates identical content"},"DocumentLineage":{"properties":{"root_object_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Root Object Id","description":"Object in the originating bucket that this document descends from.","examples":["obj_video123"]},"root_bucket_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Root Bucket Id","description":"Bucket the root object lives in. This is the field to compare against a bucket the caller selected, to confirm a result came from the intended source rather than from another bucket in the namespace.","examples":["bkt_marketing"]},"source_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Type","description":"Whether the immediate source was a bucket or an upstream collection.","examples":["collection"]},"source_object_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Object Id","description":"Immediate source object, when the source was a bucket."},"source_document_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Document Id","description":"Immediate source document, when the source was a collection."},"source_collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Collection Id","description":"Immediate source collection, when the source was one."},"source_row":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Source Row","description":"For a document imported from a database table: the source row it mirrors, as provider, schema, table and primary key (pk), with the origin of each vector it carries (model, dimensions, mode). Null for a document made from any other object.","examples":[{"pk":{"id":42},"provider":"postgresql","schema":"public","table":"scenes","vector_origin":{"embedding":{"dimensions":3072,"mode":"carry","model":"text-embedding-3-large"}}}]},"lineage_chain":{"items":{"$ref":"#/components/schemas/DocumentLineageStep"},"type":"array","title":"Lineage Chain","description":"Every processing step from the root object to this document, in order: the first entry is the document made directly from the root object, the last is this document. Each step names its collection, extractor, document and time. When an upstream document no longer exists the chain starts at the step that names it, and nothing above that step is listed."}},"type":"object","title":"DocumentLineage","description":"Where a document came from.\n\n`root_bucket_id` and `root_object_id` are the load-bearing fields and are\npopulated from the document's own flat lineage fields. They are what lets a\ncaller confirm a result traces to the bucket a user actually chose."},"DocumentLineageResponse":{"properties":{"document_id":{"type":"string","title":"Document Id","description":"Document that was traced."},"collection_id":{"type":"string","title":"Collection Id","description":"Collection it was traced in."},"lineage":{"anyOf":[{"$ref":"#/components/schemas/DocumentLineage"},{"type":"null"}],"description":"Null when the document carries no lineage, in which case `message` says why. Null is not an error and the response is still 200."},"depth":{"type":"integer","title":"Depth","description":"Processing steps between the root object and this document: 1 for a document made directly from a bucket object, 2 for one made from such a document, and so on. Equals total_steps unless an upstream document no longer exists, when it also counts the steps the chain cannot list. 0 only when the document has no lineage.","default":0},"total_steps":{"type":"integer","title":"Total Steps","description":"Number of entries in lineage.lineage_chain. 0 only when the document has no lineage.","default":0},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message","description":"Present only when `lineage` is null, explaining the absence. Absent on a successful trace.","examples":["Document does not have lineage information (created before Phase 2)"]}},"type":"object","required":["document_id","collection_id"],"title":"DocumentLineageResponse","description":"Lineage for one document, or a statement that it has none."},"DocumentLineageStep":{"properties":{"collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Collection Id","description":"Collection that performed this step."},"feature_extractor_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Feature Extractor Id","description":"Extractor that produced the document at this step."},"document_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Id","description":"Document produced at this step."},"timestamp":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timestamp","description":"When this step ran, ISO 8601."}},"type":"object","title":"DocumentLineageStep","description":"One processing step in a document's history: the document one\ncollection produced on the way from the root object to the traced one."},"DocumentListStats":{"properties":{"total_documents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Documents","description":"Number of documents matching the collection and filters across all pages. Populated only when the request sets `include_total=true` (a COUNT query, about 50-200ms). `null` means it was not requested, or it could not be computed and `warnings` says so. It is never the page size: use `len(results)` for this page's number."},"avg_blobs_per_document":{"type":"number","title":"Avg Blobs Per Document","description":"Average number of source blobs per document","default":0.0},"total_groups":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Groups","description":"Total number of groups when group_by is used. None for non-grouped results."},"avg_documents_per_group":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Documents Per Group","description":"Average number of documents per group when group_by is used. None for non-grouped results."}},"type":"object","title":"DocumentListStats","description":"Aggregate statistics for a list of documents."},"DocumentRef":{"properties":{"collection_id":{"type":"string","minLength":1,"title":"Collection Id","description":"Collection the document lives in."},"document_id":{"type":"string","minLength":1,"title":"Document Id","description":"The document's ID."}},"type":"object","required":["collection_id","document_id"],"title":"DocumentRef","description":"A reference to one document in one collection."},"DocumentResponse":{"properties":{"document_id":{"type":"string","title":"Document Id","description":"REQUIRED. Unique identifier for the document. Format: 'doc_' prefix + alphanumeric characters. Use for: API queries, references, filtering.","examples":["doc_f8966ff29c18e20c6b45e053","doc_abc123"]},"collection_id":{"type":"string","title":"Collection Id","description":"REQUIRED. ID of the collection this document belongs to. Format: 'col_' prefix + alphanumeric characters. Use for: Collection-scoped queries, filtering.","examples":["col_articles","col_video_frames"]},"vector_hydration_incomplete":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Vector Hydration Incomplete","description":"OPTIONAL. Present only when return_vectors/return_vector_names was requested on this read. True means this read did not return a vector the store holds: fetching errored or timed out, its partition was not paged in, or the store keeps it only as quantized codes. An empty or absent vector on THIS response is UNCERTAIN, not a confirmed absence, and should not be treated as proof the vector does not exist. False means hydration ran to completion (present or genuinely absent). On a large/BYO collection with evicted partitions, hydration can time out on most reads before a background page-in warms the index; retrying the same read later, once warm, is the correct response to True here, not re-deriving the vector from source."},"searchable_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Searchable At","description":"When the document's latest write became searchable on the shard that served this read (ISO 8601, UTC, to the write batch). Null means stored and not searchable yet: the write is acknowledged but this shard has not applied it, or a recovery replay still covers the namespace. A read after the apply returns the time. Computed when the document is read from the shard that serves it, and not stored on the document, so it cannot be used in filters, sorts or facets."},"document_blobs":{"items":{"$ref":"#/components/schemas/BlobURLRef"},"type":"array","title":"Document Blobs","description":"Document blobs with presigned URLs when requested"},"_internal":{"anyOf":[{"$ref":"#/components/schemas/InternalPayloadModel"},{"type":"null"}],"description":"System-managed internal fields. Contains all Mixpeek-managed metadata including lineage, processing info, timestamps, and blob references. User-defined fields appear at root level alongside document_id and collection_id."}},"additionalProperties":true,"type":"object","required":["document_id","collection_id"],"title":"DocumentResponse","description":"Response model for a single document.\n\nThis is the standard response format when fetching documents via API endpoints.\nContains all document data plus optional presigned URLs for S3 blobs.\n\nThe document payload structure follows the native vector store format:\n    - System fields are stored in `_internal` (lineage, metadata, blobs, etc.)\n    - User fields are at root level (brand_name, thumbnail_url, etc.)\n    - Only document_id and collection_id are Mixpeek IDs at root level\n    - No duplication between root and _internal\n\nQuery Parameters Affecting Response:\n    - return_url=true: Adds presigned_url to each document_blobs entry\n    - return_vectors=true: Includes embedding arrays in response\n\nUse Cases:\n    - Display document details in UI\n    - Download source files or generated artifacts\n    - Understand document provenance and processing\n    - Access enrichment fields (flat) for filtering/display","examples":[{"_internal":{"collection_id":"col_articles","created_at":"2025-10-31T10:00:00Z","document_id":"doc_f8966ff29c18e20c6b45e053","internal_id":"org_abc123","lineage":{"chain":[{"collection_id":"col_articles","feature_extractor_id":"text_extractor_v1","timestamp":"2025-10-31T10:00:00Z"}],"path":"bkt_content/col_articles","root_bucket_id":"bkt_content","root_object_id":"obj_article_001","source_object_id":"obj_article_001","source_type":"bucket"},"metadata":{"ingestion_status":"COMPLETED"},"modality":"text","namespace_id":"ns_xyz789","source_blobs":[{"blob_id":"blob_text_001","blob_property":"content","blob_type":"text"}],"updated_at":"2025-10-31T10:00:00Z"},"author":"Dr. Smith","collection_id":"col_articles","description":"Text document with _internal structure","document_id":"doc_f8966ff29c18e20c6b45e053","title":"AI in Healthcare"},{"_internal":{"collection_id":"col_video_frames","created_at":"2025-10-31T10:00:00Z","document_blobs":[{"field":"thumbnail","role":"thumbnail","type":"image","url":"s3://bucket/thumbnails/frame_050.jpg"}],"document_id":"doc_frame_050","internal_id":"org_abc123","lineage":{"path":"bkt_marketing/col_video_frames","root_bucket_id":"bkt_marketing","root_object_id":"obj_video_123","source_object_id":"obj_video_123","source_type":"bucket"},"mime_type":"video/mp4","modality":"video","namespace_id":"ns_xyz789","source_blobs":[{"blob_id":"blob_video_001","blob_property":"video","blob_type":"video"}],"updated_at":"2025-10-31T10:00:00Z"},"campaign_id":"Q4_2025","cluster_distance":0.15,"cluster_id":"cl_marketing","collection_id":"col_video_frames","description":"Video document with user fields and enrichments","document_id":"doc_frame_050","duration":120,"taxonomy_products_label":"Electronics","taxonomy_products_score":0.87},{"_internal":{"collection_id":"col_scenes","created_at":"2025-10-31T10:05:00Z","document_id":"doc_scene_042","internal_id":"org_abc123","lineage":{"chain":[{"collection_id":"col_frames","feature_extractor_id":"multimodal_extractor_v1","timestamp":"2025-10-31T10:00:00Z"},{"collection_id":"col_scenes","feature_extractor_id":"scene_detector_v1","timestamp":"2025-10-31T10:05:00Z"}],"path":"bkt_marketing/col_video_frames/col_scenes","root_bucket_id":"bkt_marketing","root_object_id":"obj_video_123","source_collection_id":"col_video_frames","source_document_id":"doc_frame_050","source_type":"collection"},"modality":"video","namespace_id":"ns_xyz789","updated_at":"2025-10-31T10:05:00Z"},"collection_id":"col_scenes","description":"Multi-tier document (collection→collection)","document_id":"doc_scene_042","end_time":62.3,"scene_type":"action","start_time":45.5}]},"DocumentUpdateRequest":{"properties":{},"additionalProperties":true,"type":"object","title":"DocumentUpdateRequest","description":"Request model for updating a document.\n\nFields you omit keep their stored values. PUT does not replace the document.\n\n`metadata` is an object of key-value pairs. Each key you send is set on the\nstored metadata. Keys you omit stay as they are. A key whose value is `null`\nis removed from the stored metadata. `metadata: null` returns a 422.\n\nA key at the top level of the body sets the document's top-level field of that\nname, which is a separate field from `metadata.<key>`."},"DomainResponse":{"properties":{"domain":{"type":"string","title":"Domain"},"status":{"type":"string","title":"Status"},"verification_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verification Token"},"cname_target":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cname Target"},"is_primary":{"type":"boolean","title":"Is Primary"},"verified_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verified At"}},"type":"object","required":["domain","status","is_primary"],"title":"DomainResponse"},"DownloadUrlResponse":{"properties":{"download_url":{"type":"string","title":"Download Url","description":"Presigned S3 GET URL for the version's bundle"},"version":{"type":"integer","title":"Version"},"asset_prefix":{"type":"string","title":"Asset Prefix"},"expires_in":{"type":"integer","title":"Expires In","description":"URL expiry in seconds","default":3600}},"type":"object","required":["download_url","version","asset_prefix"],"title":"DownloadUrlResponse","description":"Presigned download URL for a version's deployed assets."},"DrivePropertySource":{"properties":{"type":{"type":"string","const":"drive_property","title":"Type","description":"Source type identifier. Must be 'drive_property' for Google Drive.","default":"drive_property"},"key":{"type":"string","minLength":1,"title":"Key","description":"The property key to extract. Built-in: 'name', 'mimeType', 'description', 'starred', 'createdTime', 'modifiedTime', 'size', 'webViewLink', 'parents'. Custom: Any key set in the file's appProperties. Case-sensitive.","examples":["description","starred","category","modifiedTime"]}},"type":"object","required":["key"],"title":"DrivePropertySource","description":"Extract value from Google Drive file properties.\n\nGoogle Drive files have built-in properties (name, mimeType, etc.) and\ncustom properties (appProperties). This source extracts from either.\n\nProvider Compatibility: Google Drive, Google Workspace Shared Drives\n\nBuilt-in properties:\n    - name: File name\n    - mimeType: MIME type\n    - description: File description\n    - starred: Boolean star status\n    - trashed: Boolean trash status\n    - createdTime: Creation timestamp\n    - modifiedTime: Last modified timestamp\n    - size: File size in bytes\n\nCustom properties: Set via Drive API appProperties field\n\nExample mapping:\n    {\"type\": \"drive_property\", \"key\": \"description\"} -> extracts file description\n\nAttributes:\n    type: Must be \"drive_property\" to identify this source type\n    key: The property key to extract (case-sensitive)"},"DurationStats":{"properties":{"mean":{"type":"number","title":"Mean","description":"Average duration in seconds"},"median":{"type":"number","title":"Median","description":"Median duration in seconds"},"p50":{"type":"number","title":"P50","description":"50th percentile (same as median)"},"p90":{"type":"number","title":"P90","description":"90th percentile duration in seconds"},"p95":{"type":"number","title":"P95","description":"95th percentile duration in seconds"},"std_dev":{"type":"number","title":"Std Dev","description":"Standard deviation in seconds"},"min":{"type":"number","title":"Min","description":"Minimum duration observed in seconds"},"max":{"type":"number","title":"Max","description":"Maximum duration observed in seconds"}},"type":"object","required":["mean","median","p50","p90","p95","std_dev","min","max"],"title":"DurationStats","description":"Statistical distribution of durations for successful step transitions.\n\nProvides comprehensive percentile analysis to understand timing patterns.\n\nAttributes:\n    mean: Average duration (seconds)\n    median: Middle value (50th percentile)\n    p50: 50th percentile (same as median, included for consistency)\n    p90: 90th percentile (90% complete faster)\n    p95: 95th percentile (95% complete faster)\n    std_dev: Standard deviation (measure of spread)\n    min: Fastest observed duration\n    max: Slowest observed duration\n\nExample:\n    ```python\n    DurationStats(\n        mean=432000.0,     # 5 days average\n        median=345600.0,   # 4 days median\n        p50=345600.0,\n        p90=691200.0,      # 8 days (90th percentile)\n        p95=864000.0,      # 10 days (95th percentile)\n        std_dev=172800.0,  # 2 days std dev\n        min=86400.0,       # 1 day minimum\n        max=1209600.0      # 14 days maximum\n    )\n    ```"},"DynamicValue":{"properties":{"type":{"type":"string","const":"dynamic","title":"Type","default":"dynamic"},"field":{"type":"string","title":"Field","description":"The dot-notation path to the value in the runtime query request, e.g., 'inputs.user_id'","examples":["inputs.query_text","filters.AND[0].value"]}},"type":"object","required":["field"],"title":"DynamicValue","description":"A value that should be dynamically resolved from the query request."},"EVoCParams":{"properties":{"noise_level":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Noise Level","description":"How aggressively points are set aside as noise (cluster_id -1). Lower values keep more points in clusters; higher values demand denser, more confident clusters. 0.5 is a balanced default.","default":0.5},"base_min_cluster_size":{"type":"integer","minimum":2.0,"title":"Base Min Cluster Size","description":"Minimum number of points for a cluster at the base layer of the cluster hierarchy. Larger values create fewer, bigger clusters.","default":5},"approx_n_clusters":{"anyOf":[{"type":"integer","minimum":2.0},{"type":"null"}],"title":"Approx N Clusters","description":"Optional hint for roughly how many clusters to aim for. EVoC picks the hierarchy layer closest to this count. Leave unset to let EVoC choose the granularity from the data."},"n_neighbors":{"type":"integer","maximum":200.0,"minimum":2.0,"title":"N Neighbors","description":"Number of nearest neighbours per point when building the kNN graph. Larger values give a denser graph at higher build cost.","default":15},"min_samples":{"type":"integer","minimum":1.0,"title":"Min Samples","description":"Number of neighbouring samples for a point to be considered a core point (density estimation, as in HDBSCAN).","default":5},"random_state":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Random State","description":"Random seed for reproducible clusterings.","default":42}},"type":"object","title":"EVoCParams","description":"Parameters for EVoC (Embedding Vector Oriented Clustering)."},"EdgeModel":{"properties":{"type":{"type":"string","title":"Type","description":"Customer-defined edge type (their vocabulary), e.g. 'used_in_ad' or 'uses_footage'. Reciprocal edges use a type and its inverse."},"target_object_id":{"type":"string","title":"Target Object Id","description":"The endpoint object_id this edge points to (the linked object)."},"target_collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Collection Id","description":"Optional: narrow which derived documents of the target object a traverse_edge stage should pull (else all documents of the target)."},"direction":{"type":"string","enum":["out","in"],"title":"Direction","description":"'out' = this object → target; 'in' = target → this object. Reciprocal pairs are written on both endpoints so either side can traverse locally.","default":"out"},"attributes":{"additionalProperties":true,"type":"object","title":"Attributes","description":"Free-form customer attributes ON the edge itself, e.g. {'clip_order': 3, 'start_ticks_in': 123, 'start_ticks_out': 456}."}},"additionalProperties":true,"type":"object","required":["type","target_object_id"],"title":"EdgeModel","description":"A typed, directed, attributed relationship to another object.\n\nStored at the ROOT of an object/document under the ``edges`` list. Customer\ndata — the ``type`` vocabulary and ``attributes`` are entirely the customer's."},"EmailConfig-Input":{"properties":{"to_addresses":{"items":{"type":"string"},"type":"array","title":"To Addresses","description":"Email addresses to send to"},"subject_template":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject Template","description":"Template for email subject"},"body_template":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body Template","description":"Template for email body"},"content_type":{"$ref":"#/components/schemas/NotificationContentType","description":"Format of the email body","default":"html"},"cc_addresses":{"items":{"type":"string"},"type":"array","title":"Cc Addresses","description":"CC addresses"},"bcc_addresses":{"items":{"type":"string"},"type":"array","title":"Bcc Addresses","description":"BCC addresses"}},"type":"object","required":["to_addresses"],"title":"EmailConfig","description":"Configuration for email notifications."},"EmailCredentials":{"properties":{"type":{"type":"string","const":"webhook_secret","title":"Type","default":"webhook_secret"},"webhook_secret":{"type":"string","title":"Webhook Secret","description":"Shared secret for verifying inbound email webhook signatures. Auto-generated on connection creation if left empty. SECURITY: Secret credential, redacted on read. Never log or expose.","default":""}},"type":"object","title":"EmailCredentials","description":"Webhook signing credentials for inbound email verification.\n\nSecurity:\n    - webhook_secret is a secret credential, redacted on read\n    - Used to verify HMAC-SHA256 signatures on inbound email webhooks"},"EmbeddingModel":{"type":"string","enum":["laion_clip_vit_l_14_v1","multilingual_e5_large_instruct_v1","vertex_multimodal_embedding","multimodalembedding@001","gemini-embedding-2","google_siglip_base_v1","google_siglip_so400m_v1","text-embedding-3-small","text-embedding-3-large","face_identity_arcface_r100_v1","all_minilm_l6_v2_v1","colbertv2_v1","colqwen2_v1"],"title":"EmbeddingModel","description":"Embedding model identifiers.\n\nFormat: {provider}_{model_name}_{version}"},"EnableOrgModelRequest":{"properties":{"deploy":{"type":"boolean","title":"Deploy","description":"Whether to deploy the model to Ray immediately after enabling","default":false},"resource_overrides":{"anyOf":[{"$ref":"#/components/schemas/ModelResourceRequirements"},{"type":"null"}],"description":"Override resource requirements for this namespace deployment"}},"type":"object","title":"EnableOrgModelRequest","description":"Request to enable an org-level model for a namespace."},"EnableOrgModelResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether operation succeeded"},"model_id":{"type":"string","title":"Model Id","description":"Model identifier"},"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace where model was enabled"},"deployment_status":{"type":"string","title":"Deployment Status","description":"Deployment status (deployed, pending, skipped)"},"message":{"type":"string","title":"Message","description":"Status message"}},"type":"object","required":["success","model_id","namespace_id","deployment_status","message"],"title":"EnableOrgModelResponse","description":"Response from enabling an org-level model for a namespace."},"EnginePerformanceResponse":{"properties":{"time_range":{"$ref":"#/components/schemas/api__analytics__models__TimeRange","description":"Time range of the query"},"metrics":{"items":{"$ref":"#/components/schemas/PerformanceMetric"},"type":"array","title":"Metrics","description":"Time-series performance metrics"},"summary":{"anyOf":[{"$ref":"#/components/schemas/PerformanceSummary"},{"type":"null"}],"description":"Overall summary statistics"},"service_health":{"anyOf":[{"$ref":"#/components/schemas/ServiceHealth"},{"type":"null"}],"description":"Per-namespace service-health dimensions: availability, degraded/partial rates, timeout/throttle rates and dependency health. Unwired dimensions are None with a stated reason, never a fabricated zero."}},"type":"object","required":["time_range","metrics"],"title":"EnginePerformanceResponse","description":"Response for engine performance query."},"EngineStageBreakdownResponse":{"properties":{"time_range":{"$ref":"#/components/schemas/api__analytics__models__TimeRange","description":"Time range of the analysis"},"stages":{"items":{"$ref":"#/components/schemas/StagePerformance-Output"},"type":"array","title":"Stages","description":"Performance breakdown by stage"},"total_time_ms":{"type":"number","title":"Total Time Ms","description":"Total time across all stages (sum)"}},"type":"object","required":["time_range","stages","total_time_ms"],"title":"EngineStageBreakdownResponse","description":"Response for engine stage breakdown."},"EnrichmentField":{"properties":{"field_path":{"type":"string","title":"Field Path","description":"Dot-notation path of the field to copy from the taxonomy node."},"target_field":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Field","description":"Optional target field name in the enriched document. If specified, the source field will be renamed to this name. If not specified, the field_path is used as the target name. Use this to rename fields during enrichment (e.g., label → visual_style).","examples":["visual_style","style_description","brand_name"]},"merge_mode":{"$ref":"#/components/schemas/EnrichmentMergeMode","description":"Whether to overwrite the target's value or append (for arrays).","default":"replace"}},"type":"object","required":["field_path"],"title":"EnrichmentField","description":"Field-level enrichment behaviour specification.\n\nDefines how to copy fields from taxonomy source nodes to enriched documents.\nSupports field renaming via target_field parameter.\n\nExamples:\n    - Copy field as-is: {\"field_path\": \"category\", \"merge_mode\": \"replace\"}\n    - Rename field: {\"field_path\": \"label\", \"target_field\": \"visual_style\", \"merge_mode\": \"replace\"}\n    - Append to array: {\"field_path\": \"tags\", \"merge_mode\": \"append\"}","examples":[{"field_path":"metadata.tags","merge_mode":"append"},{"field_path":"category","merge_mode":"replace"},{"field_path":"label","merge_mode":"replace","target_field":"visual_style"},{"field_path":"description","merge_mode":"replace","target_field":"style_description"}]},"EnrichmentFieldMapping":{"properties":{"source_field":{"type":"string","title":"Source Field","description":"Field from cluster results to include. Available fields: cluster_id, cluster_label, distance_to_centroid, member_count, keywords, x, y, z (visualization coords), metadata.*. cluster_id is the run's cluster index (cl_0, cl_1, ...); an execution with a filters override writes it qualified by that partition (<partition>:cl_0), so partitions of one cluster never share a value."},"target_field":{"type":"string","title":"Target Field","description":"Target field name in enriched document. Example: 'category_id' for cluster_id, 'product_category' for cluster_label"}},"type":"object","required":["source_field","target_field"],"title":"EnrichmentFieldMapping","description":"Maps a cluster result field to a document enrichment field.\n\nSimilar to InputMapping pattern used throughout Mixpeek."},"EnrichmentHistoryResponse":{"properties":{"taxonomy_id":{"type":"string","title":"Taxonomy Id"},"time_range":{"$ref":"#/components/schemas/api__analytics__taxonomies__models__TimeRange"},"metrics":{"items":{"$ref":"#/components/schemas/EnrichmentMetric"},"type":"array","title":"Metrics"},"summary":{"additionalProperties":true,"type":"object","title":"Summary"}},"type":"object","required":["taxonomy_id","time_range","metrics"],"title":"EnrichmentHistoryResponse","description":"Taxonomy enrichment history response."},"EnrichmentInputMapping":{"properties":{"input_key":{"type":"string","title":"Input Key","description":"The retriever input parameter name","examples":["query","query_embedding","collection_id"]},"source":{"$ref":"#/components/schemas/InputMappingSource","description":"Where to get the value from (document field or constant)"}},"type":"object","required":["input_key","source"],"title":"EnrichmentInputMapping","description":"Maps a document field or constant to a retriever input parameter.\n\nDefines how to construct retriever inputs from the document being enriched.\n\nAttributes:\n    input_key: The retriever input parameter name\n    source: Where to get the value from (document field or constant)","examples":[{"input_key":"query","source":{"path":"title","source_type":"document_field"}},{"input_key":"collection_id","source":{"source_type":"constant","value":"col_reference_data"}}]},"EnrichmentMergeMode":{"type":"string","enum":["replace","append"],"title":"EnrichmentMergeMode","description":"How a field from the taxonomy node should be merged into the target doc."},"EnrichmentMetric":{"properties":{"time_bucket":{"type":"string","format":"date-time","title":"Time Bucket"},"enrichment_count":{"type":"integer","title":"Enrichment Count"},"success_count":{"type":"integer","title":"Success Count"},"failure_count":{"type":"integer","title":"Failure Count"},"avg_latency_ms":{"type":"number","title":"Avg Latency Ms"},"success_rate":{"type":"number","title":"Success Rate"}},"type":"object","required":["time_bucket","enrichment_count","success_count","failure_count","avg_latency_ms","success_rate"],"title":"EnrichmentMetric","description":"Taxonomy enrichment metrics."},"ErrorBreakdown":{"properties":{"error_type":{"type":"string","title":"Error Type","description":"Error type"},"count":{"type":"integer","title":"Count","description":"Error count"},"percentage":{"type":"number","title":"Percentage","description":"Percentage of total errors"},"first_seen":{"type":"string","format":"date-time","title":"First Seen","description":"First occurrence"},"last_seen":{"type":"string","format":"date-time","title":"Last Seen","description":"Last occurrence"}},"type":"object","required":["error_type","count","percentage","first_seen","last_seen"],"title":"ErrorBreakdown","description":"Error breakdown by type."},"ErrorBucket":{"properties":{"timestamp":{"type":"string","title":"Timestamp"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["timestamp","count"],"title":"ErrorBucket"},"ErrorCategory":{"type":"string","enum":["dependency","authentication","validation","runtime","network","resource"],"title":"ErrorCategory","description":"Categories for batch processing errors.\n\nUsed to classify errors for better observability, retry logic, and debugging.\nHelps distinguish between transient errors (worth retrying) and permanent errors."},"ErrorDetail":{"properties":{"message":{"type":"string","title":"Message","description":"Human-readable error message"},"type":{"type":"string","title":"Type","description":"Stable error type identifier (machine-readable)"},"code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Code","description":"Fine-grained error code for programmatic handling (e.g., namespace_name_taken, feature_extractor_not_found). Present only when consumers may need to branch on a specific error condition."},"details":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Details","description":"Optional structured details to help debugging (validation errors, IDs, etc.)"}},"type":"object","required":["message","type"],"title":"ErrorDetail","description":"Error detail model."},"ErrorMetrics":{"properties":{"error_type":{"type":"string","title":"Error Type"},"count":{"type":"integer","title":"Count"},"percentage":{"type":"number","title":"Percentage"},"recent_message":{"type":"string","title":"Recent Message"}},"type":"object","required":["error_type","count","percentage","recent_message"],"title":"ErrorMetrics","description":"Error analysis metrics."},"ErrorRateResponse":{"properties":{"app_id":{"type":"string","title":"App Id"},"error_count":{"type":"integer","title":"Error Count"},"period_minutes":{"type":"integer","title":"Period Minutes"},"rate_per_minute":{"type":"number","title":"Rate Per Minute"}},"type":"object","required":["app_id","error_count","period_minutes","rate_per_minute"],"title":"ErrorRateResponse"},"ErrorResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Always false for error responses","default":false},"status":{"type":"integer","title":"Status","description":"HTTP status code for this error"},"error":{"$ref":"#/components/schemas/ErrorDetail","description":"Error details payload"}},"type":"object","required":["status","error"],"title":"ErrorResponse","description":"Error response model.","examples":[{"error":{"details":{"id":"ns_123","resource":"namespace"},"message":"Namespace not found","type":"NotFoundError"},"status":404,"success":false}]},"EstimateItem":{"properties":{"mime_type":{"type":"string","title":"Mime Type","description":"MIME type (or registry input type) of the planned content"},"count":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Count","description":"Unit count (images, web pages)"},"minutes":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Minutes","description":"Duration (video/audio)"},"pages":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pages","description":"Page count (documents)"},"tokens":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Tokens","description":"Token count (text)"},"units":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Units","description":"Generic unit count (accepted for any modality)"}},"type":"object","required":["mime_type"],"title":"EstimateItem"},"EstimateRequest":{"properties":{"items":{"items":{"$ref":"#/components/schemas/EstimateItem"},"type":"array","title":"Items","description":"Planned content to ingest, priced per modality. Send this or `manifest`"},"features":{"items":{"type":"string"},"type":"array","title":"Features","description":"Feature keys to apply (see GET /v1/collections/features)"},"full_res":{"type":"boolean","title":"Full Res","description":"Opt out of mezzanine normalization (2x multiplier)","default":false},"manifest":{"anyOf":[{"type":"string"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Manifest","description":"A namespace manifest (YAML text or the parsed mapping), for example a template's or one from POST /v1/manifest/generate. Quoted collection by collection the way batch submit charges it"},"inventory":{"additionalProperties":{"additionalProperties":{"type":"number"},"type":"object"},"type":"object","title":"Inventory","description":"Per bucket name in `manifest`, the files it will hold: objects, videos, minutes, audio_minutes, images, pages, tokens. A bucket left out is quoted at zero files","examples":[{"footage":{"minutes":1900,"objects":400}}]},"queries_per_month":{"type":"integer","minimum":0.0,"title":"Queries Per Month","description":"Retriever queries a month, for the monthly price","default":0}},"type":"object","title":"EstimateRequest"},"EstimateResponse":{"properties":{"pricing_model":{"type":"string","title":"Pricing Model","default":"v2"},"placeholder_rates":{"type":"boolean","title":"Placeholder Rates","description":"True until the rate card locks — quote is provisional"},"line_items":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Line Items"},"total_usd":{"type":"number","title":"Total Usd"},"batch_minimum_applied":{"type":"boolean","title":"Batch Minimum Applied"},"allowance_pool_usd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Allowance Pool Usd","description":"The tier's monthly usage pool, if any"},"allowance_covered_usd":{"type":"number","title":"Allowance Covered Usd","description":"How much of this estimate falls inside the remaining pool (directional pre-cutover: the pool is not drawn down yet)"},"estimated_overage_usd":{"type":"number","title":"Estimated Overage Usd","description":"Overage beyond the pool, NET of any plan-level overage discount — matches what the invoice will charge"},"overage_discount_pct":{"type":"number","title":"Overage Discount Pct","description":"Plan-level overage discount applied (Scale 20%); 0 when the plan has none","default":0.0},"overage_discount_usd":{"type":"number","title":"Overage Discount Usd","description":"Dollar amount the overage discount saved this estimate","default":0.0},"manifest_quote":{"anyOf":[{"$ref":"#/components/schemas/ManifestQuote"},{"type":"null"}],"description":"Present when the request sent `manifest`"}},"type":"object","required":["placeholder_rates","line_items","total_usd","batch_minimum_applied","allowance_covered_usd","estimated_overage_usd"],"title":"EstimateResponse"},"EvaluationConfig":{"properties":{"k_values":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"K Values","description":"K values for Precision@K, Recall@K, NDCG@K, etc.","default":[1,5,10,20]},"metrics":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Metrics","description":"List of metrics to calculate. Available: precision, recall, f1, f2, map, ndcg, mrr. f2 is the recall-weighted F-beta (beta=2) — useful when missing a relevant doc costs more than a false positive.","default":["precision","recall","f1","map","ndcg","mrr"]},"k_multiples_of_relevant":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"K Multiples Of Relevant","description":"Also grade each query at its own k: this multiple of R, the number of entries in that query's relevant_documents. [1, 2] grades a query with 21 relevant documents at k=21 and k=42. Results use the suffix '1r', '2r': f2_at_2r in overall_metrics and in each query's metrics, and the key '2r' in metrics_by_k. k_values still apply. A query whose k exceeds the pagination limit of a retriever execution is skipped, with the reason in query_results.","examples":[[1,2]]}},"type":"object","title":"EvaluationConfig","description":"Configuration for an evaluation run."},"EvaluationDataset":{"properties":{"dataset_id":{"type":"string","title":"Dataset Id","description":"Unique dataset identifier"},"dataset_name":{"type":"string","title":"Dataset Name","description":"Human-readable dataset name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Dataset description"},"queries":{"items":{"$ref":"#/components/schemas/GroundTruthQuery"},"type":"array","title":"Queries","description":"List of queries with ground truth"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"When dataset was created"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"},"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace this dataset belongs to"},"internal_id":{"type":"string","title":"Internal Id","description":"Internal organization ID"},"query_count":{"type":"integer","title":"Query Count","description":"Number of queries in dataset"},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Additional metadata (e.g., labeling instructions, version info)"},"relevance_field":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Relevance Field","description":"Grade by this field of each result instead of its document id, for a retriever that groups documents (reduce or group_by). relevant_documents then lists values of the field, and results that share a value count once. Dotted paths reach nested fields, e.g. 'metadata.frame_key'.","examples":["metadata.frame_key"]}},"type":"object","required":["dataset_id","dataset_name","queries","created_at","updated_at","namespace_id","internal_id","query_count"],"title":"EvaluationDataset","description":"Complete evaluation dataset with metadata.\n\nAn evaluation dataset is a collection of queries with ground truth relevance labels,\nused to measure retriever quality."},"EvaluationListResponse":{"properties":{"evaluations":{"items":{"$ref":"#/components/schemas/EvaluationRecord"},"type":"array","title":"Evaluations","description":"List of evaluations"},"total":{"type":"integer","title":"Total","description":"Total count"},"page":{"type":"integer","title":"Page","description":"Current page"},"page_size":{"type":"integer","title":"Page Size","description":"Page size"}},"type":"object","required":["evaluations","total","page","page_size"],"title":"EvaluationListResponse","description":"Response for listing evaluations."},"EvaluationRecord":{"properties":{"evaluation_id":{"type":"string","title":"Evaluation Id","description":"Unique evaluation identifier"},"retriever_id":{"type":"string","title":"Retriever Id","description":"ID of retriever being evaluated"},"dataset_id":{"type":"string","title":"Dataset Id","description":"ID of dataset used for evaluation"},"dataset_name":{"type":"string","title":"Dataset Name","description":"Name of dataset"},"config":{"$ref":"#/components/schemas/EvaluationConfig","description":"Evaluation configuration"},"status":{"$ref":"#/components/schemas/EvaluationStatus","description":"Current status"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"When evaluation was created"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"When evaluation completed"},"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace ID"},"internal_id":{"type":"string","title":"Internal Id","description":"Internal organization ID"},"query_count":{"type":"integer","title":"Query Count","description":"Number of queries evaluated"},"overall_metrics":{"anyOf":[{"additionalProperties":{"type":"number"},"type":"object"},{"type":"null"}],"title":"Overall Metrics","description":"Aggregated metrics across all queries"},"metrics_by_k":{"anyOf":[{"additionalProperties":{"additionalProperties":{"type":"number"},"type":"object"},"type":"object"},{"type":"null"}],"title":"Metrics By K","description":"Metrics broken down by K value (keys are string K values like '5', '10', '20', plus '2r' for each multiple in k_multiples_of_relevant)"},"total_queries":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Queries","description":"Total queries in the dataset for this run (= evaluated_queries + skipped_queries)."},"evaluated_queries":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Evaluated Queries","description":"Number of queries that produced metrics. May be < total_queries when some queries were skipped (skip-and-continue on empty/failing input)."},"skipped_queries":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Skipped Queries","description":"Number of queries skipped during evaluation (empty query_input or a per-query execution failure) — these did not fail the whole eval."},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Error message if failed"},"query_results":{"anyOf":[{"items":{"$ref":"#/components/schemas/QueryOutcome"},"type":"array"},{"type":"null"}],"title":"Query Results","description":"Per-query outcomes: which branch each attempted query took and the actual error for skips, so an all-skipped run is actionable from the record without worker-log access."},"baseline_evaluation_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Baseline Evaluation Id","description":"For a trained weight set's evaluation: the evaluation of the live configuration on the same dataset that this run was gated against."},"weight_set_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Weight Set Id","description":"For a trained weight set's evaluation: the weight set this run scored. When the verdict passed, the stage's learning_config.shipped_weight_set carries the same id."},"verdict":{"anyOf":[{"$ref":"#/components/schemas/GateVerdict"},{"type":"null"}],"description":"For a trained weight set's evaluation: the gate verdict against baseline_evaluation_id, with both scores for every metric. A refused set keeps the live configuration."}},"type":"object","required":["evaluation_id","retriever_id","dataset_id","dataset_name","config","status","created_at","updated_at","namespace_id","internal_id","query_count"],"title":"EvaluationRecord","description":"Complete evaluation record with results."},"EvaluationStatus":{"type":"string","enum":["pending","in_progress","completed","failed"],"title":"EvaluationStatus","description":"Status of an evaluation run."},"EventFilter":{"properties":{"event_types":{"items":{"type":"string"},"type":"array","title":"Event Types"}},"type":"object","title":"EventFilter"},"ExecuteBatchRequest":{"properties":{"queries":{"items":{"$ref":"#/components/schemas/BatchQueryItem"},"type":"array","maxItems":16,"minItems":1,"title":"Queries","description":"List of queries to execute (1-16). Each gets the same retriever pipeline. A request over 16 is refused with 422 and error.details.limits.max_queries set to 16; split larger sets into several requests."},"settings":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Settings","description":"Shared settings applied to every query. Supports 'limit' (max results per query, default 10) and 'max_chunks' (for content-mode preprocessing)."},"concurrency":{"type":"integer","maximum":20.0,"minimum":1.0,"title":"Concurrency","description":"Max concurrent executions (1-20). Higher = faster but more resource usage.","default":5},"return_presigned_urls":{"type":"boolean","title":"Return Presigned Urls","description":"Generate presigned URLs for S3-backed blobs and url-shaped fields. Also accepted as a query param — if either source is true, presigning is enabled.","default":false},"return_vectors":{"type":"boolean","title":"Return Vectors","description":"Include vector embeddings in result documents. Also accepted as a query param — if either source is true, vectors are returned.","default":false},"stream":{"type":"boolean","title":"Stream","description":"Stream results via Server-Sent Events. Each query result is emitted as it completes, with keepalive pings every 15s to prevent proxy timeouts.","default":false}},"type":"object","required":["queries"],"title":"ExecuteBatchRequest","description":"Request to execute a retriever against multiple queries in a single call.\n\nThe retriever is fetched and optimized once, then executed concurrently\nagainst each query. Much more efficient than calling /execute N times\nwhen scanning multiple assets against the same retriever.\n\nTypical use case: IP safety and copyright clearance, checking up to 16\nmedia files against face, logo, or audio retrievers in one request."},"ExecuteClusterByIdRequest":{"properties":{"mode":{"type":"string","enum":["full","assign","composite"],"title":"Mode","description":"Execution mode:\n- full: Run complete clustering pipeline (default)\n- assign: Incremental assignment — assign new documents to existing cluster centroids without re-clustering. Requires a previous successful execution with centroids.\n- composite: Cluster centroids from multiple prior executions to create cross-execution cluster groupings. Uses source_execution_ids when given; otherwise, on a cluster created with source_cluster_ids, the newest completed run with centroids of each source cluster, one per partition.\nA cluster created with source_cluster_ids runs composite when the body names no mode.","default":"full"},"source_execution_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Source Execution Ids","description":"List of clustering execution run_ids whose centroids will be clustered together (only used when mode='composite'). Each referenced execution must have status='completed' and non-empty centroids. Minimum 2 executions required. Optional on a cluster created with source_cluster_ids, whose runs are picked when this is omitted."},"assignment_threshold":{"anyOf":[{"type":"number","maximum":1.0,"minimum":0.0},{"type":"null"}],"title":"Assignment Threshold","description":"Minimum cosine similarity to assign a document to a cluster (only used when mode='assign'). Documents below this threshold are marked as noise (cluster_id=-1). Range: 0.0-1.0.","default":0.5},"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"Optional filter override. When provided, this filter is used for this execution instead of the cluster's stored filters. The override is not persisted on the cluster."},"sample_size":{"anyOf":[{"type":"integer","maximum":1000000.0},{"type":"null"}],"title":"Sample Size","description":"Optional per-execution document cap. When provided, overrides the cluster's stored sample_size for this execution only. The override is not persisted on the cluster. KMeans supports up to 1M; O(N²) algorithms (HDBSCAN, Spectral, Agglomerative) are capped at 50K by the engine."},"vis_n_components":{"anyOf":[{"type":"integer","enum":[2,3]},{"type":"null"}],"title":"Vis N Components","description":"Number of dimensions for visualization coordinates (2 or 3). When 3, the z coordinate is populated for depth-based rendering."},"defer_visualization":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Defer Visualization","description":"When True, skip inline UMAP during clustering and compute the scatter coordinates lazily at /visualization time. UMAP is ~90% of the clustering critical path at scale, so this makes large runs complete much faster; the first scatter load pays a one-time bounded cost. The override is not persisted on the cluster."},"layout_stability":{"anyOf":[{"type":"string","enum":["none","transform","align"]},{"type":"null"}],"title":"Layout Stability","description":"Optional layout-stability override for this execution. 'align' registers the new layout onto the previous run's coordinates (default when the cluster stores nothing), 'transform' reuses the previous run's saved projection reducer when compatible, 'none' re-layouts independently. The override is not persisted on the cluster."},"llm_labeling":{"anyOf":[{"$ref":"#/components/schemas/LLMLabeling-Input"},{"type":"null"}],"description":"Optional inline LLM labeling override. When provided, this configuration is used for this execution instead of the cluster's stored llm_labeling. Use this to enable labeling for a single run without mutating the cluster definition. Set ``enabled: true`` to actually run labeling — passing the object alone is insufficient. The override is not persisted on the cluster."}},"type":"object","title":"ExecuteClusterByIdRequest","description":"Optional body for POST /v1/clusters/{cluster_id}/execute.\n\nLets callers override the cluster's stored filters for a single\nexecution without mutating the cluster definition — useful for\nper-partition re-runs (e.g., re-clustering one brand without\ndisturbing other partitions)."},"ExecuteRetrieverRequest":{"properties":{"inputs":{"additionalProperties":true,"type":"object","title":"Inputs","description":"Runtime inputs for the retriever mapped to the input schema. Keys must match the retriever's input_schema field names. Values depend on field types (text, vector, filters, etc.). REQUIRED unless all retriever inputs have defaults. \n\nCommon input keys:\n- 'query': Text search query\n- 'embedding': Pre-computed vector for search\n- 'top_k': Number of results to return\n- 'min_score': Minimum relevance threshold\n- Any custom fields defined in input_schema\n\n\n**Template Syntax** (Jinja2):\n\nNamespaces (uppercase or lowercase):\n- `INPUT` / `input`: Query inputs (e.g., `{{INPUT.query}}`)\n- `DOC` / `doc`: Document fields (e.g., `{{DOC.payload.title}}`)\n- `CONTEXT` / `context`: Execution context\n- `STAGE` / `stage`: Stage configuration\n- `SECRET` / `secret`: Vault secrets (e.g., `{{SECRET.api_key}}`)\n\nAccessing Data:\n- Dot notation: `{{DOC.payload.metadata.title}}`\n- Bracket notation: `{{DOC.payload['special-key']}}`\n- Array index: `{{DOC.items[0]}}`, `{{DOC.tags[2]}}`\n- Array first/last: `{{DOC.items | first}}`, `{{DOC.items | last}}`\n\nArray Operations:\n- Iterate: `{% for item in DOC.tags %}{{item}}{% endfor %}`\n- Extract key: `{{DOC.items | map(attribute='name') | list}}`\n- Join: `{{DOC.tags | join(', ')}}`\n- Length: `{{DOC.items | length}}`\n- Slice: `{{DOC.items[:5]}}`\n\nConditionals:\n- If: `{% if DOC.status == 'active' %}...{% endif %}`\n- If-else: `{% if DOC.score > 0.8 %}high{% else %}low{% endif %}`\n- Ternary: `{{'yes' if DOC.enabled else 'no'}}`\n\nBuilt-in Functions: `max`, `min`, `abs`, `round`, `ceil`, `floor`, `utc_now`, `time_ago`\nTime Functions: `{{utc_now()}}` returns current UTC as ISO-8601, `{{time_ago(minutes=5)}}` returns UTC minus duration\nCustom Filters: `slugify` (URL-safe), `bool` (truthy coercion), `tojson` (JSON encode), `regex_search(pattern, group=0, ignore_case=false)` (first match, or '')\n\nS3 URLs: Internal S3 URLs (s3://bucket/key) are automatically presigned when accessed via DOC namespace.","examples":[{"query":"artificial intelligence","top_k":25},{"min_score":0.7,"query":"customer feedback","top_k":50},{"category":"blog","embedding":[0.1,0.2,0.3],"top_k":10}]},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","description":"Optional ad-hoc filters applied at execution time. Merged (AND) with any filters already defined in the retriever's stages. Uses the standard LogicalOperator format: {\"AND\": [{\"field\": \"brand\", \"operator\": \"eq\", \"value\": \"Acme\"}]}. Supports operators: eq, ne, in, nin, gt, gte, lt, lte, contains, exists, is_null.","examples":[{"AND":[{"field":"brand","operator":"eq","value":"Acme"}]},{"AND":[{"field":"status","operator":"in","value":["active","pending"]},{"field":"score","operator":"gte","value":0.5}]}]},"pagination":{"oneOf":[{"$ref":"#/components/schemas/OffsetPaginationParams"},{"$ref":"#/components/schemas/CursorPaginationParams"},{"$ref":"#/components/schemas/ScrollPaginationParams"},{"$ref":"#/components/schemas/KeysetPaginationParams"}],"title":"Pagination","description":"Pagination strategy configuration. When omitted entirely, defaults to cursor-based pagination sized to the pipeline's declared final_top_k (author intent); pipelines that declare no final_top_k default to limit=10. Any explicit pagination (or the deprecated body 'limit') is honored exactly. \n\nIMPORTANT: Pagination params do NOT support template variables ({{INPUT.x}} or {{DOCUMENT.x}}). Pagination is a request-level parameter for slicing results, separate from pipeline business logic. Pass cursor/limit values directly from your client code. Cursor values come from the previous response's pagination.cursor field.\n\nSupported Methods:\n- CURSOR (default): Best for infinite scroll, stateless, opaque token\n- KEYSET: Most efficient, requires stable sort, stateless\n- OFFSET: Traditional page numbers, can have drift issues\n- SCROLL: Server-side state, best for bulk exports\n\n\nUse CURSOR for:\n- Infinite scroll UIs (mobile apps, feeds, timelines)\n- Real-time updates where consistency matters\n- When you can't jump to arbitrary pages\n\n\nUse KEYSET for:\n- Maximum performance with large result sets\n- Stable sort fields (e.g., score DESC, id ASC)\n- When you need truly stateless pagination\n\n\nUse OFFSET for:\n- Traditional page UIs with page numbers\n- When users need to jump to specific pages\n- Smaller result sets where drift is acceptable\n\n\nUse SCROLL for:\n- Bulk exports or processing large datasets\n- When you need to iterate through all results\n- Background jobs with progress tracking\n\n\nExample (cursor - first page):\n{\"method\": \"cursor\", \"limit\": 20, \"cursor\": null}\n\nExample (cursor - next page, using cursor from previous response):\n{\"method\": \"cursor\", \"limit\": 20, \"cursor\": \"eyJvZmZzZXQiOjIwfQ==\"}\n\nExample (offset):\n{\"method\": \"offset\", \"page_size\": 25, \"page_number\": 2}\n\nExample (keyset):\n{\"method\": \"keyset\", \"limit\": 20, \"after\": {\"score\": 0.73, \"id\": \"doc_20\"}}\n","discriminator":{"propertyName":"method","mapping":{"cursor":"#/components/schemas/CursorPaginationParams","keyset":"#/components/schemas/KeysetPaginationParams","offset":"#/components/schemas/OffsetPaginationParams","scroll":"#/components/schemas/ScrollPaginationParams"}}},"limit":{"anyOf":[{"type":"integer","maximum":500.0,"minimum":1.0},{"type":"null"}],"title":"Limit","description":"Shorthand for the pagination page size: the most documents this response returns. A top-level 'page_size' is accepted as the same value. Prefer 'pagination' (for example {\"method\": \"cursor\", \"limit\": 100}). When 'pagination' is absent, this value sizes the default cursor pagination of the final result set, and the response's pagination cursor fetches the next page. When both are sent and disagree, 'pagination' wins and a top-level response warning names the conflict. Sending 'limit' and 'page_size' with different values is refused.","deprecated":true,"examples":[null,25]},"stream":{"type":"boolean","title":"Stream","description":"Enable streaming execution to receive real-time stage updates via Server-Sent Events (SSE). NOT REQUIRED - defaults to False for standard execution. \n\nWhen stream=True:\n- Response uses text/event-stream content type\n- Each stage completion emits a StreamStageEvent\n- Events include: stage_start, stage_complete, stage_error, execution_complete\n- Clients receive intermediate results and statistics as stages execute\n- Useful for progress tracking, debugging, and partial result display\n\n\nWhen stream=False (default):\n- Response returns after all stages complete\n- Returns a single RetrieverExecutionResponse with final results\n- Lower overhead for simple queries\n\n\nUse streaming when:\n- You want to show real-time progress to users\n- You need to display intermediate results\n- Pipeline has many stages or long-running operations\n- Debugging or monitoring pipeline performance\n\n\nExample streaming client (JavaScript):\n```javascript\nconst eventSource = new EventSource('/v1/retrievers/ret_123/execute?stream=true');\neventSource.onmessage = (event) => {\n  const stageEvent = JSON.parse(event.data);\n  if (stageEvent.event_type === 'stage_complete') {\n    console.log(`Stage ${stageEvent.stage_name} completed`);\n    console.log(`Documents: ${stageEvent.documents.length}`);\n  }\n};\n```\n\n\nExample streaming client (Python):\n```python\nimport requests\nresponse = requests.post('/v1/retrievers/ret_123/execute',\n                        json={'inputs': {...}, 'stream': True},\n                        stream=True)\nfor line in response.iter_lines():\n    if line.startswith(b'data: '):\n        event = json.loads(line[6:])\n        print(f\"Stage {event['stage_name']}: {event['event_type']}\")\n```","default":false,"examples":[false,true]},"expand":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Expand","description":"OPTIONAL. List of fields containing document IDs to resolve inline. Referenced documents are fetched and attached under an '_expanded' key in each result document. Supports dot-notation for nested fields (e.g., 'items.product_id'). Max 50 unique references per request. Depth is limited to 1 (no recursive expansion).","examples":[["customer_id"],["customer_id","items.product_id"]]},"skip_cache":{"type":"boolean","title":"Skip Cache","description":"OPTIONAL. Bypass stage result cache for this execution. When True, all stages execute fresh without cache lookup. Useful after corpus updates, retriever config changes, or engine deploys. Results are still written to cache for future requests.","default":false,"examples":[false,true]},"return_presigned_urls":{"type":"boolean","title":"Return Presigned Urls","description":"Generate presigned URLs for S3-backed blobs and url-shaped fields in result documents. Also accepted as a `return_presigned_urls` query parameter; if either source is true, presigning is enabled.","default":false,"examples":[false,true]},"return_vectors":{"type":"boolean","title":"Return Vectors","description":"Include vector embeddings in result documents. Also accepted as a `return_vectors` query parameter; if either source is true, vectors are returned.","default":false,"examples":[false,true]},"write_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Write Token","description":"OPTIONAL. Pass the `write_token` returned by a prior direct upsert (options.write_token=true) to get read-your-writes consistency: the read is routed to the primary shard, where your just-written document is immediately searchable, instead of an eventually-consistent replica that can lag several seconds behind. Omit for normal (eventual) reads."},"consistency":{"anyOf":[{"$ref":"#/components/schemas/ReadConsistencyOption"},{"type":"null"}],"description":"OPTIONAL. The read consistency for this execution. Omit to use the deployment default. A write_token always reads strong."},"target_collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Collection Id","description":"OPTIONAL. A collection in this namespace to write this execution's results into. Each result document is written there as a document of its own: the result's fields as its payload, the source document's stored vectors (so the collection is searchable on the same features), and the execution in its lineage under _internal.lineage (the source document and collection, the execution id, the retriever id and the retriever version). Running the same retriever into the same collection again updates those documents in place. The written documents are billed as document writes. The response's written_to reports the collection and the number written. Not available with stream=true. To keep a collection filled from a retriever continuously, give the collection a transform that names the retriever instead.","examples":["col_shortlist"]},"explain":{"type":"boolean","title":"Explain","description":"OPTIONAL. When true, the response includes `explain_plan` — the query profile for THIS execution: per-stage timings + input/output counts, MVS execution stats, and the optimizer summary (and, once wired, the shard ExecutionTrace: chosen legs, fusion, push-downs, nprobe, served/shadow planner). Analogous to SQL `EXPLAIN ANALYZE` — the query still runs and returns documents; the plan is attached alongside. The same profile is auto-logged for every execution regardless of this flag (so Studio can read it); `explain=true` simply returns it inline in the response.","default":false}},"type":"object","title":"ExecuteRetrieverRequest","description":"Request to execute a retriever with optional streaming support.\n\nInherits all fields from RetrieverExecutionRequest including:\n- inputs: Runtime input values matching the retriever's input_schema\n- pagination: Pagination configuration (cursor, offset, etc.)\n- stream: Enable SSE streaming for real-time stage updates\n\nStreaming Execution (stream=True):\n    When streaming is enabled, the response uses Server-Sent Events (SSE) format\n    with Content-Type: text/event-stream. Each stage emits events as it executes:\n\n    Event Types:\n    - stage_start: Emitted when a stage begins execution\n    - stage_complete: Emitted when a stage finishes with results\n    - stage_error: Emitted if a stage encounters an error\n    - execution_complete: Emitted after all stages finish successfully\n    - execution_error: Emitted if the entire execution fails\n\n    Each event is a StreamStageEvent containing:\n    - event_type: The type of event\n    - execution_id: Unique execution identifier\n    - stage_name: Human-readable stage name\n    - stage_index: Zero-based stage position\n    - total_stages: Total number of stages\n    - documents: Intermediate results (for stage_complete)\n    - statistics: Stage metrics (duration, counts, etc.)\n    - budget_used: Cumulative resource consumption\n\n    Example streaming client:\n    ```python\n    response = requests.post(\n        '/v1/retrievers/{id}/execute',\n        json={'inputs': {...}, 'stream': True},\n        stream=True\n    )\n    for line in response.iter_lines():\n        if line.startswith(b'data: '):\n            event = json.loads(line[6:])\n            print(f\"{event['event_type']}: {event.get('stage_name')}\")\n    ```\n\nStandard Execution (stream=False, default):\n    Returns a single ExecuteRetrieverResponse with final documents,\n    pagination, and aggregate statistics after all stages complete.","examples":[{"description":"Simple query","inputs":{"query":"artificial intelligence trends","top_k":25}},{"description":"Query with stage-driven filtering via inputs","inputs":{"categories":["AI","ML"],"min_score":0.7,"published_after":"2024-01-01","query":"machine learning","top_k":100}},{"description":"Advanced query with multiple input parameters","inputs":{"date_range":{"end":"2024-12-31","start":"2024-01-01"},"query":"customer testimonials","sentiment":"positive","top_k":20}},{"description":"Infinite scroll with cursor pagination (first page)","inputs":{"query":"AI trends","top_k":50},"pagination":{"limit":20,"method":"cursor"}},{"description":"Infinite scroll (next page using cursor from previous response)","inputs":{"query":"AI trends","top_k":50},"pagination":{"cursor":"eyJvZmZzZXQiOjIwfQ==","limit":20,"method":"cursor"}},{"description":"Traditional pagination with page numbers","inputs":{"query":"ML papers"},"pagination":{"method":"offset","page_number":2,"page_size":25}},{"description":"High-performance keyset pagination","inputs":{"query":"customer reviews","top_k":100},"pagination":{"after":{"id":"doc_20","score":0.73},"limit":20,"method":"keyset"}},{"description":"Scroll pagination for bulk export","inputs":{"query":"all documents"},"pagination":{"limit":100,"method":"scroll","scroll_ttl":300}}]},"ExecuteRetrieverResponse":{"properties":{"retriever_id":{"type":"string","title":"Retriever Id","description":"The retriever that was executed. Use this to link interactions back to the retriever for learned fusion.","default":"","examples":["ret_abc123def456"]},"execution_id":{"type":"string","title":"Execution Id","description":"REQUIRED. Unique identifier for this execution run. Use this ID to track execution status, retrieve execution details, or query execution history. Format: 'exec_' prefix followed by alphanumeric token.","examples":["exec_abc123def456","exec_xyz789"]},"status":{"type":"string","title":"Status","description":"REQUIRED. Execution status indicating current state. Common values: 'completed', 'failed', 'processing', 'pending'. Check this field to determine if execution succeeded or requires retry.","examples":["completed","failed","processing"]},"degraded":{"items":{"$ref":"#/components/schemas/DegradedEntry"},"type":"array","title":"Degraded","description":"What this run skipped, one entry per resource, when status is 'degraded': the resource kind, its id, why it was skipped, and what to do about it. Empty on a clean run. A degraded run may return few or no documents; read these before treating an empty result as a real no-match."},"limits":{"anyOf":[{"items":{"$ref":"#/components/schemas/LimitEntry"},"type":"array"},{"type":"null"}],"title":"Limits","description":"OPTIONAL. Every cap that clamped this request: the setting, the value asked for, the value used, the cap's maximum and the stage that applied it. Absent when nothing was capped. A run that hit a cap can return fewer documents than asked; read this before treating a short result as everything that matched."},"documents":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Documents","description":"REQUIRED. Final document results after retriever completion, and the canonical result key: read `documents`, not `results` (the latter is a deprecated byte-for-byte alias, off unless include_legacy_results=true, and its ABSENCE on a normal response must not be read as zero results). Contains documents that passed through all retriever stages. Each document may include: document_id, payload (full document data), score (relevance score), metadata (collection-specific fields), and any fields added by enrichment/join stages. The moment_group reduce stage annotates each document with a `moments` array of merged time ranges; each moment has start_ms, end_ms, duration_ms, score, match_count and document_ids (see the moment-annotated example). Empty array indicates no documents matched the query criteria. Note: Legacy format may use 'final_results' instead of 'documents'.","examples":[[{"document_id":"doc_123","payload":{"metadata":{"category":"AI"},"text":"Sample content"},"score":0.95},{"document_id":"doc_456","payload":{"metadata":{"category":"ML"},"text":"Another document"},"score":0.88},{"document_id":"moment_vid_A_12000","moments":[{"document_ids":["frame_41","frame_42","frame_43"],"duration_ms":6500,"end_ms":18500,"match_count":3,"score":0.91,"start_ms":12000}],"parent_id":"vid_A","score":0.91}]]},"results":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Results","description":"DEPRECATED alias for `documents`. Previously a computed field that duplicated `documents` byte-for-byte in every response (~half the payload). It is no longer populated by default to cut response size; pass `?include_legacy_results=true` to restore it during migration. Prefer `documents` — it is and has always been the canonical field. OMITTED from the response when unpopulated while `documents` has data (an empty `results` next to populated `documents` misled readers into 'no results' — 2026-07-06 and again 2026-07-08). When present it is ALWAYS a JSON array, never null. See FRUSTRATIONS.md 2026-04-02 / 2026-06-29 / 2026-06-30.","deprecated":true},"pagination":{"additionalProperties":true,"type":"object","title":"Pagination","description":"REQUIRED. Pagination metadata structure. Format varies by pagination method: Offset: {method, page_number, page_size, returned, total, has_next}, Cursor: {method, limit, returned, total, cursor, has_next}, Scroll: {method, scroll_id, limit, returned, total, has_next}, Keyset: {method, limit, returned, total, after}. Every method reports 'total', the number of documents the pipeline computed for this execution BEFORE the page slice, so compare total against returned to detect that a page is a subset. Use this to navigate through result pages.","examples":[{"has_next":false,"limit":25,"method":"cursor","returned":25,"total":25},{"has_next":true,"method":"offset","page_number":1,"page_size":10,"returned":10,"total":40}]},"stage_statistics":{"$ref":"#/components/schemas/RetrieverExecutionStatistics","description":"REQUIRED. Per-stage execution statistics including timing, document counts, cache hit rates, and stage-specific metrics. Use this to understand retriever performance and identify bottlenecks."},"facets":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Facets","description":"Facet value-lists + counts computed by the feature_search stage(s), surfaced at the TOP LEVEL for discoverability: each entry is a FacetResult (a facet `key` plus value/count buckets). The same data also appears per-stage under `stage_statistics.stages.<stage>.metadata.facets`; this field is the predictable place a facet consumer looks. When more than one stage computes facets, the last stage's facets are surfaced here. None when no facets were requested."},"budget":{"additionalProperties":true,"type":"object","title":"Budget","description":"REQUIRED. This run's usage: credits_used, credits_limit, time_elapsed_ms, time_limit_ms, tokens_used, llm_calls, metering. credits_used is what was charged to this run; a plain text search and a cache hit read 0.0. metering is 'unmetered' where there is no billing path, and credits_used is no price.","examples":[{"credits_used":0.0,"llm_calls":0,"metering":"metered"}]},"cached_at":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cached At","description":"Unix timestamp when this result was stored in the retriever cache. Present (non-null) only on cache hits; null on fresh executions, so a caller can tell how old a cached page is."},"completeness":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Completeness","description":"Completeness by layer, so the claims never contradict: `embeddings` is complete, complete_after_retry or partial (some query embeddings were dropped); `page` is complete, not_known_complete (a retried stage answered an empty page) or the execution status; `overall` is complete only when both layers are. Filled in when the response is written."},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings","description":"OPTIONAL. Execution warnings that did not prevent results but indicate potential issues — e.g. filtering on unindexed fields. Empty when there are no warnings."},"interpretation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Interpretation","description":"OPTIONAL. What the platform UNDERSTOOD from your request, so a correction or relaxation is visible instead of silent. Keys: provided_input_keys (the inputs you sent), inferred_inputs (schema defaults applied because you omitted the field — name: value), ignored_input_keys (inputs nothing in the pipeline consumes; they had no effect), and relaxations (filter conditions removed because the input they reference was not provided — each names the field, the template, and where it sat; the result set is BROADER than the literal filter when this is non-empty). The literal query text is used AS PROVIDED — no spell-correction step exists; semantic search is typo-tolerant by embedding, which this block does not alter. Stage-level rewrites (e.g. query_expand) report their expansions in stage_statistics.stages.<stage>.metadata."},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"OPTIONAL. Retriever-level error message if execution failed. Only present when status='failed'. Contains human-readable error description to help diagnose the failure. Check stage_statistics for stage-specific errors.","examples":["Retriever execution failed: Collection not found","Budget exceeded: Maximum credits limit reached"]},"optimization_applied":{"type":"boolean","title":"Optimization Applied","description":"OPTIONAL. Whether automatic pipeline optimizations were applied before execution. Mixpeek automatically optimizes retrieval pipelines for performance by reordering stages, merging operations, and pushing work to the database layer. Optimizations preserve logical equivalence - you get the same results, just faster. When true, see optimization_summary for details about what changed.","default":false,"examples":[true,false]},"optimization_summary":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Optimization Summary","description":"OPTIONAL. Summary of pipeline optimizations applied before execution. Only present when optimization_applied=true. Contains: - original_stage_count: Number of stages in your original pipeline - optimized_stage_count: Number of stages after optimization - optimization_time_ms: Time spent optimizing (typically <100ms) - rules_applied: List of optimization rules that fired - stage_reduction_pct: Percentage reduction in stage count Use this to understand how the optimizer improved your pipeline. See OptimizationRuleType enum for detailed rule descriptions.","examples":[{"optimization_time_ms":8.2,"optimized_stage_count":3,"original_stage_count":5,"rules_applied":["push_down_filters","group_by_push_down"],"stage_reduction_pct":40.0},{"optimization_time_ms":2.1,"optimized_stage_count":3,"original_stage_count":3,"rules_applied":[],"stage_reduction_pct":0.0}]},"learned_fusion_context":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Learned Fusion Context","description":"OPTIONAL. Learned fusion context when the retriever uses learned fusion (auto-tune) for weight optimization. Contains: context_key (resolution level used), sampled_weights (per-feature weight vector), feature_uris (features that were weighted), effective_exploration (Thompson sampling exploration rate), context_level ('personal', 'segment', or 'global'). Only present when learned fusion is active on this retriever."},"written_to":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Written To","description":"Present when the request named target_collection_id: the collection_id written to, documents_written, and documents_skipped (results with no document id, which cannot be written)."},"cache_hit":{"type":"boolean","title":"Cache Hit","description":"True when this response was served from the retriever-level execute cache (cached_at then carries the storage timestamp); false on fresh executions. This is the canonical cache-hit signal: prefer it over inferring a hit from per-stage statistics, which on a cache hit reflect the original fresh run and read as cache_hit:false.","default":false},"consistency_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Consistency Mode","description":"Which read consistency served this execution. 'strong': the read saw every write acknowledged before it, including the write named by a write_token. 'eventual': the read may miss a recent write. A replica usually catches up within seconds, but a page computed while it was behind is cached, and can keep missing that write until the next write to the collections it reads or until the cached page expires, one hour by default. To read past a cached page, send a write_token, set consistency.mode to 'strong', or set skip_cache to true. Set from the request's consistency.mode, a write_token, or the deployment default."},"enrichment_skipped":{"type":"boolean","title":"Enrichment Skipped","description":"Whether any enrichment stages were skipped due to credit limits.","default":false},"enrichment_skipped_stages":{"items":{"type":"string"},"type":"array","title":"Enrichment Skipped Stages","description":"Names of enrichment stages that were skipped."},"enrichment_skip_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Enrichment Skip Reason","description":"Reason enrichment stages were skipped (e.g., credit limit reached)."},"diagnostics":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Diagnostics","description":"Agent-facing self-debugging aid: a human summary, per-stage input/output counts, and next_actions. Populated especially when a filter stage reduces candidates to zero so a caller can tell whether the field path was wrong, the field was absent, or values simply did not match — instead of guessing at a silent empty result."},"explain_plan":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Explain Plan","description":"Query profile for this execution, populated only when the request set `explain=true`: per-stage timings and input/output counts, MVS execution stats and the optimizer summary. `spans` lists each timed block of the request (phases, stages, MVS, Mongo and Redis calls) with `wall_ms`, `cpu_ms` and `exclusive`; `cpu_ms` is the request's own only when `exclusive` is true. The profile without spans is also logged as a `retriever_query_profile` event. Additive: tolerate new keys."}},"type":"object","required":["execution_id","status"],"title":"ExecuteRetrieverResponse","description":"Response from retriever execution (non-streaming mode).\n\nThis response is returned when stream=False (the default). For streaming\nexecution, the response is a Server-Sent Events stream of StreamStageEvent\nobjects instead of this model.\n\nContains:\n- execution_id: Unique identifier for this execution\n- status: Execution status ('completed', 'failed', etc.)\n- documents: Final document results after all stages complete\n- pagination: Pagination metadata for result navigation\n- stage_statistics: Per-stage execution metrics\n- budget: Resource consumption (credits, time, tokens)\n- optimization_applied: Whether pipeline was optimized\n- optimization_summary: Details of optimization transformations\n\nFor streaming responses (stream=True), see StreamStageEvent model which\ncontains event_type, stage progress, intermediate results, and statistics\nas each stage executes."},"ExecuteTaxonomyRequest":{"properties":{"taxonomy":{"$ref":"#/components/schemas/TaxonomyModel-Input","description":"Full taxonomy model with configuration (fetched from DB by controller)"},"retriever":{"anyOf":[{"$ref":"#/components/schemas/RetrieverModel-Input"},{"type":"null"}],"description":"Optional retriever configuration override for testing. If omitted, uses the retriever configured in the taxonomy."},"source_documents":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Source Documents","description":"Sample documents to test enrichment (typically 1-5 docs). Results are returned immediately, not persisted. ⚠️ Do NOT pass collection_id expecting batch processing!"},"source_collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Collection Id","description":"⚠️ IGNORED IN ON_DEMAND MODE. This field exists for legacy compatibility only. To enrich collections, use taxonomy_applications on the collection."},"target_collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Collection Id","description":"⚠️ IGNORED IN ON_DEMAND MODE. This field exists for legacy compatibility only. Results are never persisted via this endpoint."},"join_mode":{"$ref":"#/components/schemas/JoinMode","description":"Must be 'on_demand'. BATCH mode is NOT supported via API. Batch enrichment is automatic (triggered by engine during ingestion).","default":"on_demand"},"batch_size":{"type":"integer","maximum":10000.0,"minimum":1.0,"title":"Batch Size","description":"Batch size for the scroll iterator","default":1000},"scroll_filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"Additional filters applied to the source collection prior to enrichment."}},"type":"object","required":["taxonomy"],"title":"ExecuteTaxonomyRequest","description":"Request model for on-demand taxonomy validation and testing ONLY.\n\n⚠️ IMPORTANT: This endpoint is ONLY for testing taxonomy configuration with sample documents.\n\nDO NOT USE THIS FOR BATCH ENRICHMENT:\n❌ Do NOT use this to enrich an entire collection\n❌ Do NOT use source_collection_id expecting batch processing\n❌ Do NOT use target_collection_id expecting persistence\n\nHOW TAXONOMY ENRICHMENT ACTUALLY WORKS:\n✅ Automatic during ingestion: Attach taxonomies to collections via `taxonomy_applications`\n✅ On-the-fly in retrieval: Add `taxonomy_join` stage to retriever pipelines\n\nThis endpoint validates:\n- Taxonomy configuration is correct\n- Retriever can find matching taxonomy nodes\n- Enrichment fields are properly applied\n\nFor production enrichment, see:\n- Collections API: attach taxonomies via `taxonomy_applications` field\n- Retrievers API: add `taxonomy_join` stage for on-the-fly enrichment","examples":[{"batch_size":1000,"join_mode":"on_demand","source_collection_id":"col_catalog_v2","target_collection_id":"col_catalog_enriched_v2","taxonomy":{"config":{"input_mappings":[{"input_key":"image_vector","path":"features.clip","source_type":"vector"}],"retriever_id":"ret_clip_v1","source_collection":{"collection_id":"col_products_v1"},"taxonomy_type":"flat"},"input_mappings":[{"input_key":"image_vector","path":"features.clip","source_type":"vector"}],"namespace_id":"ns_123","retriever_id":"ret_clip_v1","taxonomy_name":"product_tags"}}]},"ExecutionDetail":{"properties":{"retriever_id":{"type":"string","title":"Retriever Id","description":"The retriever that was executed. Use this to link interactions back to the retriever for learned fusion.","default":"","examples":["ret_abc123def456"]},"execution_id":{"type":"string","title":"Execution Id","description":"REQUIRED. Unique identifier for this execution run. Use this ID to track execution status, retrieve execution details, or query execution history. Format: 'exec_' prefix followed by alphanumeric token.","examples":["exec_abc123def456","exec_xyz789"]},"status":{"type":"string","title":"Status","description":"REQUIRED. Execution status indicating current state. Common values: 'completed', 'failed', 'processing', 'pending'. Check this field to determine if execution succeeded or requires retry.","examples":["completed","failed","processing"]},"degraded":{"items":{"$ref":"#/components/schemas/DegradedEntry"},"type":"array","title":"Degraded","description":"What this run skipped, one entry per resource, when status is 'degraded': the resource kind, its id, why it was skipped, and what to do about it. Empty on a clean run. A degraded run may return few or no documents; read these before treating an empty result as a real no-match."},"limits":{"anyOf":[{"items":{"$ref":"#/components/schemas/LimitEntry"},"type":"array"},{"type":"null"}],"title":"Limits","description":"OPTIONAL. Every cap that clamped this request: the setting, the value asked for, the value used, the cap's maximum and the stage that applied it. Absent when nothing was capped. A run that hit a cap can return fewer documents than asked; read this before treating a short result as everything that matched."},"documents":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Documents","description":"REQUIRED. Final document results after retriever completion, and the canonical result key: read `documents`, not `results` (the latter is a deprecated byte-for-byte alias, off unless include_legacy_results=true, and its ABSENCE on a normal response must not be read as zero results). Contains documents that passed through all retriever stages. Each document may include: document_id, payload (full document data), score (relevance score), metadata (collection-specific fields), and any fields added by enrichment/join stages. The moment_group reduce stage annotates each document with a `moments` array of merged time ranges; each moment has start_ms, end_ms, duration_ms, score, match_count and document_ids (see the moment-annotated example). Empty array indicates no documents matched the query criteria. Note: Legacy format may use 'final_results' instead of 'documents'.","examples":[[{"document_id":"doc_123","payload":{"metadata":{"category":"AI"},"text":"Sample content"},"score":0.95},{"document_id":"doc_456","payload":{"metadata":{"category":"ML"},"text":"Another document"},"score":0.88},{"document_id":"moment_vid_A_12000","moments":[{"document_ids":["frame_41","frame_42","frame_43"],"duration_ms":6500,"end_ms":18500,"match_count":3,"score":0.91,"start_ms":12000}],"parent_id":"vid_A","score":0.91}]]},"results":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Results","description":"DEPRECATED alias for `documents`. Previously a computed field that duplicated `documents` byte-for-byte in every response (~half the payload). It is no longer populated by default to cut response size; pass `?include_legacy_results=true` to restore it during migration. Prefer `documents` — it is and has always been the canonical field. OMITTED from the response when unpopulated while `documents` has data (an empty `results` next to populated `documents` misled readers into 'no results' — 2026-07-06 and again 2026-07-08). When present it is ALWAYS a JSON array, never null. See FRUSTRATIONS.md 2026-04-02 / 2026-06-29 / 2026-06-30.","deprecated":true},"pagination":{"additionalProperties":true,"type":"object","title":"Pagination","description":"REQUIRED. Pagination metadata structure. Format varies by pagination method: Offset: {method, page_number, page_size, returned, total, has_next}, Cursor: {method, limit, returned, total, cursor, has_next}, Scroll: {method, scroll_id, limit, returned, total, has_next}, Keyset: {method, limit, returned, total, after}. Every method reports 'total', the number of documents the pipeline computed for this execution BEFORE the page slice, so compare total against returned to detect that a page is a subset. Use this to navigate through result pages.","examples":[{"has_next":false,"limit":25,"method":"cursor","returned":25,"total":25},{"has_next":true,"method":"offset","page_number":1,"page_size":10,"returned":10,"total":40}]},"stage_statistics":{"$ref":"#/components/schemas/RetrieverExecutionStatistics","description":"REQUIRED. Per-stage execution statistics including timing, document counts, cache hit rates, and stage-specific metrics. Use this to understand retriever performance and identify bottlenecks."},"facets":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Facets","description":"Facet value-lists + counts computed by the feature_search stage(s), surfaced at the TOP LEVEL for discoverability: each entry is a FacetResult (a facet `key` plus value/count buckets). The same data also appears per-stage under `stage_statistics.stages.<stage>.metadata.facets`; this field is the predictable place a facet consumer looks. When more than one stage computes facets, the last stage's facets are surfaced here. None when no facets were requested."},"budget":{"additionalProperties":true,"type":"object","title":"Budget","description":"REQUIRED. This run's usage: credits_used, credits_limit, time_elapsed_ms, time_limit_ms, tokens_used, llm_calls, metering. credits_used is what was charged to this run; a plain text search and a cache hit read 0.0. metering is 'unmetered' where there is no billing path, and credits_used is no price.","examples":[{"credits_used":0.0,"llm_calls":0,"metering":"metered"}]},"cached_at":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cached At","description":"OPTIONAL. Unix timestamp (seconds) when this result was cached. Present only when the full response was served from the retriever-level cache. Compute freshness as: time.time() - cached_at."},"completeness":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Completeness","description":"Completeness by layer, so the claims never contradict: `embeddings` is complete, complete_after_retry or partial (some query embeddings were dropped); `page` is complete, not_known_complete (a retried stage answered an empty page) or the execution status; `overall` is complete only when both layers are. Filled in when the response is written."},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings","description":"OPTIONAL. Execution warnings that did not prevent results but indicate potential issues — e.g. filtering on unindexed fields. Empty when there are no warnings."},"interpretation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Interpretation","description":"OPTIONAL. What the platform UNDERSTOOD from your request, so a correction or relaxation is visible instead of silent. Keys: provided_input_keys (the inputs you sent), inferred_inputs (schema defaults applied because you omitted the field — name: value), ignored_input_keys (inputs nothing in the pipeline consumes; they had no effect), and relaxations (filter conditions removed because the input they reference was not provided — each names the field, the template, and where it sat; the result set is BROADER than the literal filter when this is non-empty). The literal query text is used AS PROVIDED — no spell-correction step exists; semantic search is typo-tolerant by embedding, which this block does not alter. Stage-level rewrites (e.g. query_expand) report their expansions in stage_statistics.stages.<stage>.metadata."},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"OPTIONAL. Retriever-level error message if execution failed. Only present when status='failed'. Contains human-readable error description to help diagnose the failure. Check stage_statistics for stage-specific errors.","examples":["Retriever execution failed: Collection not found","Budget exceeded: Maximum credits limit reached"]},"optimization_applied":{"type":"boolean","title":"Optimization Applied","description":"OPTIONAL. Whether automatic pipeline optimizations were applied before execution. Mixpeek automatically optimizes retrieval pipelines for performance by reordering stages, merging operations, and pushing work to the database layer. Optimizations preserve logical equivalence - you get the same results, just faster. When true, see optimization_summary for details about what changed.","default":false,"examples":[true,false]},"optimization_summary":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Optimization Summary","description":"OPTIONAL. Summary of pipeline optimizations applied before execution. Only present when optimization_applied=true. Contains: - original_stage_count: Number of stages in your original pipeline - optimized_stage_count: Number of stages after optimization - optimization_time_ms: Time spent optimizing (typically <100ms) - rules_applied: List of optimization rules that fired - stage_reduction_pct: Percentage reduction in stage count Use this to understand how the optimizer improved your pipeline. See OptimizationRuleType enum for detailed rule descriptions.","examples":[{"optimization_time_ms":8.2,"optimized_stage_count":3,"original_stage_count":5,"rules_applied":["push_down_filters","group_by_push_down"],"stage_reduction_pct":40.0},{"optimization_time_ms":2.1,"optimized_stage_count":3,"original_stage_count":3,"rules_applied":[],"stage_reduction_pct":0.0}]},"learned_fusion_context":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Learned Fusion Context","description":"OPTIONAL. Learned fusion context when the retriever uses learned fusion (auto-tune) for weight optimization. Contains: context_key (resolution level used), sampled_weights (per-feature weight vector), feature_uris (features that were weighted), effective_exploration (Thompson sampling exploration rate), context_level ('personal', 'segment', or 'global'). Only present when learned fusion is active on this retriever."},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Timestamp when execution began"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"Timestamp when execution finished"},"current_stage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Stage","description":"Stage currently running when execution in-flight"},"stages_completed":{"type":"integer","minimum":0.0,"title":"Stages Completed","description":"Number of stages finished so far","default":0},"total_stages":{"type":"integer","minimum":0.0,"title":"Total Stages","description":"Total stages configured","default":0},"documents_retained":{"type":"boolean","title":"Documents Retained","description":"Whether the documents this run returned are stored with it. FALSE means `documents` is empty because nothing was persisted, NOT because the query matched nothing: a stored execution keeps the statistics and not the result rows. Read `total_returned` below for what the run actually returned. This exists because an empty `documents` on a completed run is otherwise indistinguishable from a real empty result, and the same reasoning is already written down one field over, where `documents` says the ABSENCE of `results` must not be read as zero results.","default":false},"total_returned":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Returned","description":"Documents this run returned to the caller, as recorded when it ran. Present on a stored read even when `documents` is empty and `documents_retained` is false, which is what lets a caller tell 'returned 3, not retained' from 'matched nothing'. None when the stored record does not carry it."},"trace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trace Id","description":"Trace identifier recorded when this execution ran. Quote it to Mixpeek support to find the request's trace. Null for executions recorded before trace ids were stored."}},"type":"object","required":["execution_id","status"],"title":"ExecutionDetail","description":"Alias wrapper for execution detail documentation."},"ExecutionHistoryResponse":{"properties":{"cluster_id":{"type":"string","title":"Cluster Id"},"time_range":{"$ref":"#/components/schemas/api__analytics__clusters__models__TimeRange"},"results":{"items":{"$ref":"#/components/schemas/ClusterExecutionMetric"},"type":"array","title":"Results"},"summary":{"additionalProperties":true,"type":"object","title":"Summary"}},"type":"object","required":["cluster_id","time_range","results"],"title":"ExecutionHistoryResponse","description":"Cluster execution history response."},"ExplainRetrieverRequest":{"properties":{"inputs":{"additionalProperties":true,"type":"object","title":"Inputs","description":"Hypothetical inputs for tailored execution plan estimation. These values are used to analyze stage behavior and estimate costs. \n\nNOT REQUIRED - if omitted, default/representative values are used. \n\nCommon inputs:\n- 'query': Search query text (for semantic search stages)\n- 'top_k': Number of results to return (affects search scope)\n- Filter parameters: Category, price range, etc.\n\n\nExamples:\n- {'query': 'laptop'} - Simple text query\n- {'query': 'laptop', 'top_k': 100} - Query with custom limit\n- {'query': 'laptop', 'category': 'electronics', 'price_max': 1000} - Query with filters\n\n\nNote: Inputs are for estimation only. No actual search is performed.","examples":[{"query":"test query","top_k":50},{"category":"electronics","query":"wireless headphones"},{"embedding":[0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1],"top_k":100},{}]}},"type":"object","title":"ExplainRetrieverRequest","description":"Request to get execution plan for a retriever.\n\nProvides optional hypothetical inputs to tailor the execution plan estimation.\nThe explain endpoint analyzes your retriever configuration and returns cost/latency\nestimates without actually executing the query.\n\nUse Cases:\n    - See how plan changes with different input values\n    - Estimate costs for different query patterns\n    - Understand impact of parameter changes (e.g., top_k)\n    - Test stage behavior with representative inputs\n\nBehavior:\n    - If inputs are provided, they're used for tailored estimation\n    - If inputs are not provided, default/representative values are used\n    - Inputs do NOT need to match your input_schema exactly\n    - No actual retrieval is performed (explain is analysis only)","examples":[{"description":"Explain with simple query input","inputs":{"query":"machine learning tutorials"}},{"description":"Explain with query and custom limit","inputs":{"query":"red sports car","top_k":100}},{"description":"Explain with multiple filter parameters","inputs":{"category":"electronics","price_max":200,"query":"wireless headphones"}},{"description":"Explain with default inputs (empty)","inputs":{}}]},"ExplainRetrieverResponse":{"properties":{"retriever_id":{"type":"string","title":"Retriever Id","description":"Unique identifier of the retriever being explained. REQUIRED.","examples":["ret_abc123","ret_product_search_v2"]},"retriever_name":{"type":"string","title":"Retriever Name","description":"Human-readable name of the retriever. REQUIRED.","examples":["product_search","customer_lookup"]},"estimated_cost":{"additionalProperties":{"type":"number"},"type":"object","title":"Estimated Cost","description":"Estimated total cost breakdown for executing this retriever. Contains: 'total_credits' (credit cost), 'total_duration_ms' (latency). Sum of all stage costs. Use for budget planning. REQUIRED.","examples":[{"total_credits":0.51,"total_duration_ms":220.0},{"total_credits":15.5,"total_duration_ms":8500.0}]},"execution_plan":{"items":{"$ref":"#/components/schemas/ExplainStagePlan"},"type":"array","title":"Execution Plan","description":"Ordered list of stage execution plans showing the OPTIMIZED pipeline. Each entry shows cost, latency, document flow, and warnings for one stage. Stages execute in this order. REQUIRED (may be empty for invalid retrievers)."},"optimization_suggestions":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Optimization Suggestions","description":"Actionable suggestions for improving retriever performance. Each suggestion includes: 'type' (suggestion category), 'stage' (affected stage name), 'message' (human-readable description). Common types: 'reduce_limit', 'add_filter', 'reorder_stages', 'enable_cache'. OPTIONAL (empty if no suggestions).","examples":[[{"message":"Consider reducing limit from 1000 to 100 to improve latency","stage":"semantic_search","type":"reduce_limit"},{"message":"Add attribute filter before this expensive stage","stage":"llm_quality_filter","type":"add_filter"}]]},"total_estimated_stages":{"type":"integer","minimum":0.0,"title":"Total Estimated Stages","description":"Total number of stages in the optimized execution plan. This may differ from your original stage count if optimizations were applied. Compare with optimization_details.original_stage_count to see reduction. REQUIRED.","examples":[2,5,10]},"bottleneck_stages":{"items":{"type":"string"},"type":"array","title":"Bottleneck Stages","description":"Names of stages expected to dominate execution time. Includes stages with duration >= 80%% of the slowest stage. Focus optimization efforts on these stages. OPTIONAL (empty if all stages have similar duration).","examples":[["semantic_search"],["llm_quality_filter","rerank"]]},"optimization_level":{"type":"string","title":"Optimization Level","description":"Optimization level applied by the optimizer. Values: 'none' (no optimization), 'mvp' (basic optimizations), 'advanced' (all optimizations). REQUIRED.","default":"mvp","examples":["none","mvp","advanced"]},"optimization_applied":{"type":"boolean","title":"Optimization Applied","description":"Whether automatic pipeline optimizations were applied. When true, execution_plan shows OPTIMIZED stages (after transformations like filter push-down, stage fusion, grouping optimization). When false, execution_plan matches your original configuration. Check optimization_details to see what changed. REQUIRED.","default":false},"optimization_details":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Optimization Details","description":"Detailed breakdown of optimization transformations applied. Only present when optimization_applied=true. \n\nFields:\n- original_stage_count: Stage count before optimization\n- optimized_stage_count: Stage count after optimization\n- optimization_time_ms: Time spent on optimization (typically <100ms)\n- stage_reduction_pct: Percentage reduction in stage count\n- decisions: Array of optimization decisions\n\n\nEach decision contains:\n- rule_type: Optimization rule that fired\n- applied: Whether the rule was applied\n- reason: Human-readable explanation\n- stages_before/after: Stage counts before/after this rule\n\n\nCommon rule types:\n- push_down_filters: Move filters earlier to reduce downstream work\n- group_by_push_down: Push grouping to database layer (10-100x faster)\n- merge_consecutive_filters: Combine adjacent filters\n- eliminate_redundant_sorts: Remove duplicate sort operations\n\n\nOPTIONAL (null when optimization_applied=false).","examples":[{"decisions":[{"applied":true,"reason":"Moved attribute_filter before semantic_search to reduce search scope by 50%","rule_type":"push_down_filters","stages_after":5,"stages_before":5},{"applied":true,"reason":"Merged group_by into feature_filter for database-level grouping (10x faster)","rule_type":"group_by_push_down","stages_after":3,"stages_before":5}],"optimization_time_ms":8.2,"optimized_stage_count":3,"original_stage_count":5,"stage_reduction_pct":40.0}]}},"type":"object","required":["retriever_id","retriever_name","estimated_cost","total_estimated_stages"],"title":"ExplainRetrieverResponse","description":"Execution plan analysis for a retriever.\n\nProvides comprehensive diagnostics about retriever execution characteristics\nwithout actually running the query. Similar to MongoDB's explain plan or SQL's\nEXPLAIN command, this helps troubleshoot performance, estimate costs, and\nunderstand optimizer behavior.\n\nUse Cases:\n    - Identify bottleneck stages before execution\n    - Estimate costs for budget planning\n    - Debug slow retrievers by analyzing stage efficiency\n    - Understand optimizer transformations\n    - Compare different retriever configurations\n    - Troubleshoot accuracy issues via document flow analysis","examples":[{"bottleneck_stages":["semantic_search"],"description":"Simple retriever with optimization applied","estimated_cost":{"total_credits":0.51,"total_duration_ms":220.0},"execution_plan":[{"cache_likely":true,"estimated_cost_credits":0.0,"estimated_duration_ms":20.0,"estimated_efficiency":0.5,"estimated_input":10000,"estimated_output":5000,"optimization_notes":["Pushed down from stage 2"],"stage_index":0,"stage_name":"attribute_filter","stage_type":"filter","warnings":[]},{"cache_likely":false,"estimated_cost_credits":0.5,"estimated_duration_ms":200.0,"estimated_efficiency":0.02,"estimated_input":5000,"estimated_output":100,"optimization_notes":[],"stage_index":1,"stage_name":"semantic_search","stage_type":"filter","warnings":[]}],"optimization_applied":true,"optimization_details":{"decisions":[{"applied":true,"reason":"Moved attribute_filter before semantic_search","rule_type":"push_down_filters"}],"optimization_time_ms":8.2,"optimized_stage_count":2,"original_stage_count":3,"stage_reduction_pct":33.3},"optimization_level":"mvp","optimization_suggestions":[{"message":"Consider reducing limit to improve latency","stage":"semantic_search","type":"reduce_limit"}],"retriever_id":"ret_abc123","retriever_name":"product_search","total_estimated_stages":2},{"bottleneck_stages":["llm_quality_filter"],"description":"Complex retriever with bottleneck LLM stage","estimated_cost":{"total_credits":15.5,"total_duration_ms":8500.0},"execution_plan":[{"cache_likely":false,"estimated_cost_credits":0.5,"estimated_duration_ms":200.0,"estimated_efficiency":0.01,"estimated_input":10000,"estimated_output":100,"optimization_notes":[],"stage_index":0,"stage_name":"semantic_search","stage_type":"filter","warnings":[]},{"cache_likely":false,"estimated_cost_credits":15.0,"estimated_duration_ms":8000.0,"estimated_efficiency":0.1,"estimated_input":100,"estimated_output":10,"optimization_notes":[],"stage_index":1,"stage_name":"llm_quality_filter","stage_type":"filter","warnings":["High cost stage - consider reducing input count","Bottleneck stage - dominates execution time"]}],"optimization_applied":false,"optimization_level":"mvp","optimization_suggestions":[{"message":"Add attribute filter before this expensive LLM stage","stage":"llm_quality_filter","type":"add_filter"}],"retriever_id":"ret_xyz789","retriever_name":"advanced_search","total_estimated_stages":2}]},"ExplainStagePlan":{"properties":{"stage_index":{"type":"integer","minimum":0.0,"title":"Stage Index","description":"Zero-based position of this stage in the execution pipeline. Stages execute sequentially in this order. REQUIRED.","examples":[0,1,2]},"stage_name":{"type":"string","title":"Stage Name","description":"Human-readable name of this stage instance. Corresponds to the 'stage_name' field in your retriever configuration. Use this to map explain plan output back to your pipeline definition. REQUIRED.","examples":["initial_filter","semantic_search","rerank_by_relevance"]},"stage_type":{"type":"string","title":"Stage Type","description":"Stage type identifier indicating the category of operation. Common types: 'filter' (reduce documents), 'sort' (reorder), 'reduce' (aggregate), 'apply' (transform/enrich). REQUIRED.","examples":["filter","sort","reduce","apply"]},"estimated_input":{"type":"integer","minimum":0.0,"title":"Estimated Input","description":"Estimated number of documents entering this stage. This is the output count from the previous stage (or initial collection size). Used to project document flow through the pipeline. REQUIRED.","examples":[10000,5000,100]},"estimated_output":{"type":"integer","minimum":0.0,"title":"Estimated Output","description":"Estimated number of documents leaving this stage. For filter stages, this is typically less than estimated_input. For sort/reduce stages, this may be the same or less. REQUIRED.","examples":[5000,100,10]},"estimated_efficiency":{"type":"number","minimum":0.0,"title":"Estimated Efficiency","description":"Stage selectivity ratio (estimated_output / estimated_input). Values closer to 0 indicate aggressive filtering. Values closer to 1 indicate most documents pass through. Use this to identify stages that might be too restrictive or too permissive. REQUIRED.","examples":[0.5,0.02,0.9]},"estimated_cost_credits":{"type":"number","minimum":0.0,"title":"Estimated Cost Credits","description":"Estimated credit cost for executing this stage. Credits are consumed for inference (embeddings, LLM calls), vector searches, and other computational operations. Filter/sort stages typically have near-zero cost. REQUIRED.","examples":[0.0,0.5,15.0]},"estimated_duration_ms":{"type":"number","minimum":0.0,"title":"Estimated Duration Ms","description":"Estimated latency contribution of this stage in milliseconds. High values indicate potential bottlenecks. Sum across stages gives total estimated execution time. REQUIRED.","examples":[20.0,200.0,5000.0]},"cache_likely":{"type":"boolean","title":"Cache Likely","description":"Whether this stage is likely to hit cache based on recent execution history. True = cache hit likely (near-zero actual latency/cost). False = cache miss likely (full cost incurred). Use this to understand when queries will be fast vs slow. REQUIRED."},"optimization_notes":{"items":{"type":"string"},"type":"array","title":"Optimization Notes","description":"Human-readable notes about optimizations applied to this stage. Examples: 'Pushed down from stage 2', 'Merged with previous filter', 'Grouping pushed to database layer'. Empty if no optimizations were applied. OPTIONAL.","examples":[["Pushed down from stage 3 to reduce search scope"],["Merged with previous filter for efficiency"],[]]},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings","description":"Performance warnings or potential issues with this stage. Examples: 'High cost stage - consider reducing limit', 'Very low efficiency - may need filter tuning', 'LLM stage without prior filtering - expensive'. Empty if no warnings. OPTIONAL.","examples":[["High cost stage - consider reducing limit"],["Very low selectivity (0.001) - may indicate poor filter tuning"],[]]}},"type":"object","required":["stage_index","stage_name","stage_type","estimated_input","estimated_output","estimated_efficiency","estimated_cost_credits","estimated_duration_ms","cache_likely"],"title":"ExplainStagePlan","description":"Stage-level execution plan details for retriever explain endpoint.\n\nProvides detailed cost, performance, and optimization information for a single\nstage in the retriever pipeline. Use this to understand stage behavior, identify\nbottlenecks, and troubleshoot performance issues.\n\nThis is analogous to a single row in MongoDB's explain plan output, showing\nhow documents flow through the stage and what resources are consumed.","examples":[{"cache_likely":true,"description":"Fast filter stage with cache hit","estimated_cost_credits":0.0,"estimated_duration_ms":20.0,"estimated_efficiency":0.5,"estimated_input":10000,"estimated_output":5000,"optimization_notes":["Pushed down from stage 2"],"stage_index":0,"stage_name":"attribute_filter","stage_type":"filter","warnings":[]},{"cache_likely":false,"description":"Expensive semantic search stage","estimated_cost_credits":0.5,"estimated_duration_ms":200.0,"estimated_efficiency":0.02,"estimated_input":5000,"estimated_output":100,"optimization_notes":[],"stage_index":1,"stage_name":"semantic_search","stage_type":"filter","warnings":[]},{"cache_likely":false,"description":"Bottleneck LLM stage with warnings","estimated_cost_credits":15.0,"estimated_duration_ms":8000.0,"estimated_efficiency":0.1,"estimated_input":100,"estimated_output":10,"optimization_notes":[],"stage_index":2,"stage_name":"llm_quality_filter","stage_type":"filter","warnings":["High cost stage - consider reducing input count","Bottleneck stage - dominates execution time"]}]},"ExplodeSpec":{"properties":{"explode_axis":{"type":"string","title":"Explode Axis","description":"Export path of the doc-generating array (e.g. 'scene_content')."},"vector_join":{"anyOf":[{"$ref":"#/components/schemas/VectorJoin"},{"type":"null"}]}},"type":"object","required":["explode_axis"],"title":"ExplodeSpec","description":"The document-explosion inputs the flat mapping does not carry."},"ExportDestination":{"properties":{"connection_id":{"type":"string","title":"Connection Id","description":"A storage connection you own, with write access enabled. Enable it with PATCH /v1/organizations/connections/{connection_id} and {\"write_enabled\": true}."},"prefix":{"type":"string","title":"Prefix","description":"Key prefix inside the connection's bucket to write under, for example 'releases/2026-09-20/'. Empty writes at the root of the bucket. A trailing slash is added if you omit it.","default":""}},"type":"object","required":["connection_id"],"title":"ExportDestination","description":"Where to write an export, when the caller wants it in their own storage.\n\nThe connection must have write access enabled. That is opt-in per connection and\nchecked only when the connection is named here, so every read-only connection keeps\nworking exactly as it does today."},"ExportDestinationResult":{"properties":{"connection_id":{"type":"string","title":"Connection Id","description":"The connection written through."},"prefix":{"type":"string","title":"Prefix","description":"The prefix the files were written under."},"files":{"items":{"type":"string"},"type":"array","title":"Files","description":"Every key written, the manifest included."},"manifest_key":{"type":"string","title":"Manifest Key","description":"The manifest's key. It describes the export: the files with their sizes and SHA-256 checksums, the document count, the format, and the selection that produced it, so a training run can pin this release and verify it."},"bytes_written":{"type":"integer","minimum":0.0,"title":"Bytes Written","description":"Total bytes written."}},"type":"object","required":["connection_id","prefix","files","manifest_key","bytes_written"],"title":"ExportDestinationResult","description":"What was written to the caller's own storage."},"ExportFormat":{"type":"string","enum":["json","csv","parquet","webdataset"],"title":"ExportFormat","description":"Supported export formats for collection data."},"ExportMediaSummary":{"properties":{"samples_with_media":{"type":"integer","minimum":0.0,"title":"Samples With Media"},"samples_without_media":{"type":"integer","minimum":0.0,"title":"Samples Without Media"},"members_written":{"type":"integer","minimum":0.0,"title":"Members Written"},"members_skipped_too_large":{"type":"integer","minimum":0.0,"title":"Members Skipped Too Large","description":"Blobs over the per-member size limit."},"objects_not_found":{"type":"integer","minimum":0.0,"title":"Objects Not Found","description":"Documents whose source object no longer exists."},"download_failures":{"type":"integer","minimum":0.0,"title":"Download Failures"},"media_bytes":{"type":"integer","minimum":0.0,"title":"Media Bytes"}},"type":"object","required":["samples_with_media","samples_without_media","members_written","members_skipped_too_large","objects_not_found","download_failures","media_bytes"],"title":"ExportMediaSummary","description":"What happened to media in a WebDataset export with include_media set.\n\nEvery outcome is counted. An export that dropped media silently would read as a\nsmaller dataset rather than an incomplete one."},"ExportRequest":{"properties":{"namespace_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Namespace Ids","description":"Specific namespace IDs to export (None = all)"},"include_secrets":{"type":"boolean","title":"Include Secrets","description":"Include secret placeholders in output","default":false},"manifest_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Manifest Name","description":"Name for the exported manifest"},"detail":{"type":"string","enum":["config","stats"],"title":"Detail","description":"'stats' adds a read-only `status` section describing what is in the data (one namespace only). Apply ignores it.","default":"config"}},"type":"object","title":"ExportRequest","description":"Request for exporting resources to manifest."},"ExportShard":{"properties":{"filename":{"type":"string","title":"Filename","description":"Shard file name, e.g. documents-000000.tar."},"s3_path":{"type":"string","title":"S3 Path","description":"Full S3 path to this shard."},"download_url":{"type":"string","title":"Download Url","description":"Presigned URL for this shard. Valid for 1 hour."},"sample_count":{"type":"integer","minimum":0.0,"title":"Sample Count","description":"Documents in this shard."},"file_size_bytes":{"type":"integer","minimum":0.0,"title":"File Size Bytes","description":"Size of this shard in bytes."}},"type":"object","required":["filename","s3_path","download_url","sample_count","file_size_bytes"],"title":"ExportShard","description":"One tar shard of a WebDataset export."},"ExternalConnection":{"properties":{"api_base_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Api Base Url"},"credentials":{"additionalProperties":true,"type":"object","title":"Credentials"}},"type":"object","title":"ExternalConnection"},"ExternalLink":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Display name for the link","examples":["GitHub Repository","Blog Post","Documentation","Demo Video"]},"url":{"type":"string","maxLength":2048,"minLength":1,"title":"Url","description":"URL to the external resource","examples":["https://github.com/org/repo","https://blog.example.com/post","https://docs.example.com"]}},"type":"object","required":["name","url"],"title":"ExternalLink","description":"External resource link for a published retriever.\n\nUsed to link to related resources like GitHub repos, blog posts,\ndocumentation, or other relevant URLs displayed on the homepage.","examples":[{"name":"GitHub Repository","url":"https://github.com/mixpeek/video-search"},{"name":"Blog Post","url":"https://blog.mixpeek.com/building-semantic-search"}]},"ExtractorBreakdownResponse":{"properties":{"time_range":{"$ref":"#/components/schemas/api__analytics__models__TimeRange","description":"Time range of the analysis"},"extractors":{"items":{"$ref":"#/components/schemas/ExtractorPerformance"},"type":"array","title":"Extractors","description":"Performance by extractor and stage"}},"type":"object","required":["time_range","extractors"],"title":"ExtractorBreakdownResponse","description":"Response for extractor performance breakdown."},"ExtractorCapability":{"type":"string","enum":["batch","realtime"],"title":"ExtractorCapability"},"ExtractorComputeSummary":{"properties":{"extractor_name":{"type":"string","title":"Extractor Name"},"version":{"type":"string","title":"Version"},"gke_profile":{"type":"string","title":"Gke Profile"},"workload_type":{"type":"string","title":"Workload Type"},"head":{"$ref":"#/components/schemas/ResourceAllocation"},"cpu_workers":{"$ref":"#/components/schemas/ResourceAllocation"},"cpu_worker_scaling":{"$ref":"#/components/schemas/ScalingConfig"},"gpu_workers":{"$ref":"#/components/schemas/ResourceAllocation"},"gpu_worker_scaling":{"$ref":"#/components/schemas/ScalingConfig"},"cost_per_hour_usd":{"type":"number","title":"Cost Per Hour Usd"}},"type":"object","required":["extractor_name","version","gke_profile","workload_type","head","cpu_workers","cpu_worker_scaling","gpu_workers","gpu_worker_scaling","cost_per_hour_usd"],"title":"ExtractorComputeSummary"},"ExtractorDiscovery":{"properties":{"name":{"type":"string","title":"Name","description":"Feature extractor name (e.g., 'multimodal_extractor')"},"version":{"type":"string","title":"Version","description":"Feature extractor version (e.g., 'v1')"},"description":{"type":"string","title":"Description","description":"Human-readable description of what this extractor does"},"supported_modalities":{"items":{"type":"string"},"type":"array","title":"Supported Modalities","description":"List of supported input modalities (text, image, video, audio)"},"output_features":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Output Features","description":"List of features produced by this extractor"},"input_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Input Schema","description":"JSON Schema for extractor inputs — what fields the extractor reads from source objects"},"parameter_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Parameter Schema","description":"JSON Schema for tunable parameters (defaults, ranges, descriptions for every knob)"},"output_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Output Schema","description":"JSON Schema for output documents — what fields appear in extracted documents"},"costs":{"anyOf":[{"$ref":"#/components/schemas/CostsInfo"},{"type":"null"}],"description":"Credit cost information (tier, per-unit rates)"},"type_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Type Mode","description":"What input types this extractor can handle: 'type_specific' (only one type, e.g. video-only) or 'multimodal' (handles multiple types with conditional processing). Type-specific extractors cannot use automatic-typed bucket properties."},"expected_input_types":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Expected Input Types","description":"For type-specific extractors: maps input keys to required types (e.g., {'video': 'video', 'thumbnail': 'image'}). For multimodal extractors: null."},"inference_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inference Type","description":"Kind of real-time inference this extractor provides: 'embedding', 'rerank', 'classify', 'generate', or 'general'. Determines which retriever stages are compatible. Null if the extractor is batch-only."},"supported_input_types":{"items":{"type":"string"},"type":"array","title":"Supported Input Types","description":"Accepted input types (e.g., ['video', 'image'])"},"max_inputs":{"additionalProperties":{"type":"integer"},"type":"object","title":"Max Inputs","description":"Maximum number of inputs per type (e.g., {'video': 1})"},"default_parameters":{"additionalProperties":true,"type":"object","title":"Default Parameters","description":"Default parameter values — use as a starting point for tuning"},"required_vector_indexes":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Required Vector Indexes","description":"Vector indexes produced by this extractor (name, dimensions, distance metric, feature_uri)"},"position_fields":{"items":{"type":"string"},"type":"array","title":"Position Fields","description":"Fields that uniquely identify each output document within a source object"},"capabilities":{"items":{"type":"string"},"type":"array","title":"Capabilities","description":"What this extractor can do: 'batch' (feature extraction during ingestion), 'realtime' (query-time inference for retriever stages)"},"example_usage":{"additionalProperties":true,"type":"object","title":"Example Usage","description":"Minimal working configuration for namespace + collection + input_mappings + parameters"},"realtime_available":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Realtime Available","description":"Whether every Ray Serve application this extractor needs for real-time inference is running on the deployment serving this request. True when all of them report RUNNING. False when one is absent or not running; see serve_apps for which. Null when the extractor needs none, or when the live list could not be read."},"serve_apps":{"items":{"$ref":"#/components/schemas/ServeAppStatus"},"type":"array","title":"Serve Apps","description":"The Ray Serve applications this extractor needs for real-time inference, each with its live status. Empty when it needs none."}},"type":"object","required":["name","version","description"],"title":"ExtractorDiscovery","description":"Feature extractor discovery information.\n\nProvides comprehensive information about a feature extractor\nfor agent-driven configuration and manifest generation.","examples":[{"costs":{"rates":[{"credits_per_unit":10,"description":"Per minute of video processed","unit":"minute"}],"tier":2,"tier_label":"STANDARD"},"description":"Extracts embeddings from text, images, and video frames","example_usage":{"collection":{"feature_extractor":{"input_mappings":{"content":"video"},"name":"multimodal_extractor","parameters":{"split_method":"time","time_split_interval":10},"version":"v1"}},"namespace":{"feature_extractors":[{"name":"multimodal_extractor","version":"v1"}]}},"name":"multimodal_extractor","output_features":[{"name":"multimodal_embedding","type":"embedding","uri":"mixpeek://multimodal_extractor@v1/multimodal_embedding"}],"parameter_schema":{"properties":{"split_method":{"default":"time","description":"Video splitting strategy","type":"string"},"time_split_interval":{"default":10,"description":"Interval in seconds for time splitting","type":"integer"}},"type":"object"},"supported_input_types":["video","image"],"supported_modalities":["video","image"],"version":"v1"}]},"ExtractorJobInfo":{"properties":{"rows_duplicate_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Rows Duplicate Id","description":"OPTIONAL. Set on a retriever_transform job. Rows not written because their document id repeated an earlier row from the same source document, in a pipeline with no group_by stage. This usually means the id key is missing the field that tells those rows apart, such as the position an unwind stage writes; add it to the transform's unique_id_field. The job's warnings name the fix when this is above 0.","examples":[0,2]},"rows_collapsed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Rows Collapsed","description":"OPTIONAL. Set on a retriever_transform job. Rows not written because their document id repeated an earlier row from a different source document under the transform's unique_id_field, or any repeated id after a group_by stage. The first row with an id is the one written.","examples":[0,1]},"first_duplicate_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Duplicate Key","description":"OPTIONAL. The identity key of the first row skipped for a repeated id, counted in rows_duplicate_id or rows_collapsed.","examples":["document_id=doc_abc123"]},"rows_skipped_by_stages":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Rows Skipped By Stages","description":"OPTIONAL. Set on a retriever_transform job. Rows the pipeline's json_transform stages dropped because the template failed on them and the stage has fail_on_error set to false. first_stage_error says why.","examples":[0,1]},"first_stage_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Stage Error","description":"OPTIONAL. The first error recorded by the earliest pipeline stage, in pipeline order, that recorded one during a retriever_transform build.","examples":["Document doc_abc123 transformation failed: unsupported operand type(s)"]},"extractor_type":{"type":"string","title":"Extractor Type","description":"Feature extractor type (e.g., 'image_extractor', 'face_identity_extractor')","examples":["image_extractor","face_identity_extractor","video_extractor"]},"collection_ids":{"items":{"type":"string"},"type":"array","minItems":1,"title":"Collection Ids","description":"Collections processed by this extractor job","examples":[["col_abc123"],["col_def456","col_ghi789"]]},"extractor_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Extractor Id","description":"Concrete extractor identifier used for this job, e.g. 'universal_extractor_v1'.","examples":["universal_extractor_v1"]},"ray_job_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ray Job Id","description":"Ray job ID for this extractor job","examples":["raysubmit_abc123"]},"celery_task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id","description":"Background task ID that submitted this processing job","examples":["celery_task_abc123"]},"callback_job_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Callback Job Id","description":"Job ID expected in the tier completion callback for this extractor job.","examples":["celery_fast_path_btch_abc123_0_universal_extractor_v1"]},"execution_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Execution Mode","description":"Execution backend used for this extractor job.","examples":["celery_fast_path_universal"]},"status":{"$ref":"#/components/schemas/TaskStatusEnum","description":"Current status of this extractor job","default":"PENDING","examples":["PENDING","IN_PROGRESS","COMPLETED","FAILED"]},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At","description":"When this extractor job started processing"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"When this extractor job finished processing"},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms","description":"Processing duration in milliseconds"},"documents_written":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Documents Written","description":"Number of documents written by this extractor job"},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings","description":"Caller-visible warnings this job produced (e.g. a retriever_transform stage's degradation warnings like document_enrich's 'direct join matched 0 of N', or feature_search fusion drops). Persisted here by the inline transform path so BatchModel.compute_observability can lift them to progress.status_warnings; without this declared field the persisted warnings are dropped on read (extra='ignore') and a COMPLETED[_WITH_ERRORS] batch surfaces an empty warnings list, the exact silent-forgiveness class this closes."},"pages_dropped":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Pages Dropped","description":"OPTIONAL. Pages of multi-page inputs (PDFs) that were NOT indexed by this job — capped by max_document_pages or dropped by per-page failures. Only present when > 0. A COMPLETED job with pages_dropped > 0 indexed the input PARTIALLY; see pages_dropped_reasons and raise max_document_pages to index more.","examples":[10,355]},"pages_dropped_reasons":{"anyOf":[{"additionalProperties":{"type":"integer"},"type":"object"},{"type":"null"}],"title":"Pages Dropped Reasons","description":"OPTIONAL. Dropped-page counts by reason: max_document_pages_cap (input exceeded the collection's max_document_pages) or page_processing_failure (per-page extract/embed errors).","examples":[{"max_document_pages_cap":10}]},"segments_dropped":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Segments Dropped","description":"OPTIONAL. Video segments that were NOT indexed by this job. Only present when > 0. A COMPLETED job with segments_dropped > 0 indexed the video PARTIALLY. segments_dropped_reasons says why: config_cap_max_video_segments means the video had more segments than the collection's max_video_segments, so raise that setting to cover more of the video; segment_embedding_failure means a segment's embedding failed and it was not written, which raising max_video_segments does not recover.","examples":[5]},"segments_dropped_reasons":{"anyOf":[{"additionalProperties":{"type":"integer"},"type":"object"},{"type":"null"}],"title":"Segments Dropped Reasons","description":"OPTIONAL. Dropped-segment counts by reason: config_cap_max_video_segments (video exceeded the collection's max_video_segments) or segment_embedding_failure (a segment's embedding failed, so the segment was not written).","examples":[{"config_cap_max_video_segments":5}]},"documents_skipped":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Documents Skipped","description":"OPTIONAL. Number of input rows skipped (not failed) — typically metadata-only objects with no embeddable content, content-flag filtered rows, or null-text chunks. Skipped rows count toward the tier-completion invariant (processed + failed + skipped == submitted) so a tier with 100 inputs and 100 skips still ends in a valid terminal state.","examples":[0,12,100]},"errors":{"items":{"$ref":"#/components/schemas/BatchErrorDetail"},"type":"array","title":"Errors","description":"Detailed errors from this extractor job"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"OPTIONAL. Simple error message string for quick debugging. Set when the Ray job fails with error details from JobStatusMonitor. For detailed error information, see errors array.","examples":["Ray job FAILED","Timeout waiting for job completion"],"x-mixpeek-redacted":"driver_text"},"last_activity_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Activity At","description":"OPTIONAL. Timestamp of the last BatchJobPoller heartbeat confirming this extractor job was non-terminal (RUNNING or PENDING). Updated approximately every 10 seconds while IN_PROGRESS. A stale value (minutes old) may indicate a stuck or lost job."},"ray_job_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ray Job Status","description":"OPTIONAL. Last observed Ray job status for this extractor job as of last_activity_at. Values: 'RUNNING', 'PENDING', 'SUCCEEDED', 'FAILED'. Use with last_activity_at to assess whether the job is actively running.","examples":["RUNNING","PENDING"]},"submission_params":{"anyOf":[{"$ref":"#/components/schemas/SubmissionParams"},{"type":"null"}],"description":"Parameters used for Ray/GKE job submission. Persisted at submit time for debugging."}},"type":"object","required":["extractor_type"],"title":"ExtractorJobInfo","description":"Tracking information for a single feature extractor job within a tier.\n\nEach tier can have multiple extractor jobs running in parallel, one per unique\nfeature_extractor_type. This allows different extractors to have independent:\n- Resource requirements (GPUs, CPU, memory)\n- Status tracking and retry logic\n- Ray job IDs and background work IDs\n- Completion times and performance metrics\n\nExample:\n    Tier 1 with collections using different extractors:\n    - col_A: image_extractor\n    - col_B: face_identity_extractor\n    - col_C: image_extractor\n\n    Creates 2 ExtractorJobInfo instances:\n    1. extractor_type=\"image_extractor\", collection_ids=[\"col_A\", \"col_C\"]\n    2. extractor_type=\"face_identity_extractor\", collection_ids=[\"col_B\"]\n\nLifecycle:\n    1. Created with status=PENDING when tier is scheduled\n    2. Updated to IN_PROGRESS when Ray job starts\n    3. Finalized to COMPLETED/FAILED when Ray job completes"},"ExtractorMetrics":{"properties":{"extractor_name":{"type":"string","title":"Extractor Name"},"version":{"type":"string","title":"Version"},"execution_count":{"type":"integer","title":"Execution Count"},"success_count":{"type":"integer","title":"Success Count"},"failure_count":{"type":"integer","title":"Failure Count"},"success_rate":{"type":"number","title":"Success Rate"},"avg_latency_ms":{"type":"number","title":"Avg Latency Ms"},"p95_latency_ms":{"type":"number","title":"P95 Latency Ms"},"p99_latency_ms":{"type":"number","title":"P99 Latency Ms"}},"type":"object","required":["extractor_name","version","execution_count","success_count","failure_count","success_rate","avg_latency_ms","p95_latency_ms","p99_latency_ms"],"title":"ExtractorMetrics","description":"Extractor performance metrics."},"ExtractorPerformance":{"properties":{"extractor_name":{"type":"string","title":"Extractor Name","description":"Name of the extractor"},"stage_name":{"type":"string","title":"Stage Name","description":"Name of the stage"},"execution_count":{"type":"integer","title":"Execution Count","description":"Number of executions"},"avg_latency_ms":{"type":"number","title":"Avg Latency Ms","description":"Average latency"},"p95_latency_ms":{"type":"number","title":"P95 Latency Ms","description":"95th percentile latency"},"max_latency_ms":{"type":"number","title":"Max Latency Ms","description":"Maximum latency"}},"type":"object","required":["extractor_name","stage_name","execution_count","avg_latency_ms","p95_latency_ms","max_latency_ms"],"title":"ExtractorPerformance","description":"Performance breakdown by extractor."},"ExtractorPerformanceResponse":{"properties":{"collection_id":{"type":"string","title":"Collection Id"},"time_range":{"$ref":"#/components/schemas/api__analytics__collections__models__TimeRange"},"extractors":{"items":{"$ref":"#/components/schemas/ExtractorMetrics"},"type":"array","title":"Extractors"},"summary":{"additionalProperties":true,"type":"object","title":"Summary"}},"type":"object","required":["collection_id","time_range","extractors"],"title":"ExtractorPerformanceResponse","description":"Extractor performance breakdown."},"ExtractorPricing":{"properties":{"feature_extractor_name":{"type":"string","title":"Feature Extractor Name"},"description":{"type":"string","title":"Description"},"costs":{"anyOf":[{"$ref":"#/components/schemas/CostsInfo"},{"type":"null"}]}},"type":"object","required":["feature_extractor_name","description"],"title":"ExtractorPricing"},"ExtractorSource":{"type":"string","enum":["builtin","custom","community"],"title":"ExtractorSource","description":"The source/origin of a feature extractor.\n\nValues:\n    BUILTIN: Core extractors shipped with Mixpeek (text, image, multimodal, etc.)\n    CUSTOM: User-created extractors uploaded to their namespace (Enterprise only)\n    COMMUNITY: Community-contributed extractors from the Mixpeek marketplace\n\nThis field helps API consumers understand:\n- What level of support/maintenance to expect\n- Whether the extractor is available to all users or namespace-specific\n- Licensing and attribution requirements"},"FaceClusterMergeConfig":{"properties":{"enabled":{"type":"boolean","title":"Enabled","description":"Run the merge pass. Set False to disable without removing the config.","default":true},"centroid_cosine_threshold":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Centroid Cosine Threshold","description":"Minimum centroid cosine similarity for a candidate merge.","default":0.55},"bbox_iou_threshold":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Bbox Iou Threshold","description":"Minimum bbox IoU on overlapping frames to satisfy the spatial half.","default":0.4},"scene_jaccard_threshold":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Scene Jaccard Threshold","description":"Minimum Jaccard similarity of scene-id sets to satisfy the spatial half.","default":0.3},"bbox_field":{"type":"string","title":"Bbox Field","description":"Document-payload field holding the face bbox (list/tuple of 4 floats).","default":"bbox"},"frame_field":{"type":"string","title":"Frame Field","description":"Document-payload field holding the frame identifier used to pair bboxes.","default":"frame_number"},"scene_field":{"type":"string","title":"Scene Field","description":"Document-payload field holding the scene identifier used for Jaccard.","default":"scene_id"}},"type":"object","title":"FaceClusterMergeConfig","description":"Configuration for the post-HDBSCAN face-identity merge pass.\n\nEnables an agglomerative merge after HDBSCAN labels are assigned but\nbefore centroid calculation. Two clusters merge when the centroid\ncosine meets the cosine threshold AND at least one of the spatial\nsignals (bbox IoU on overlapping frames, scene Jaccard) also clears\nits threshold. Defaults target ArcFace 512d face embeddings at the\nbrand-corpus scale (~10^4 faces, ~10^2 true identities)."},"FaceIdentityExtractorParams":{"properties":{"extractor_type":{"type":"string","const":"face_identity_extractor","title":"Extractor Type","description":"Discriminator field for parameter type identification. Must be 'face_identity_extractor'.","default":"face_identity_extractor"},"detection_model":{"type":"string","enum":["scrfd_500m","scrfd_2.5g","scrfd_10g"],"title":"Detection Model","description":"SCRFD model for face detection. 'scrfd_500m': Fastest (2-3ms). 'scrfd_2.5g': Balanced (5-7ms), recommended. 'scrfd_10g': Highest accuracy (10-15ms).","default":"scrfd_2.5g"},"min_face_size":{"type":"integer","maximum":200.0,"minimum":10.0,"title":"Min Face Size","description":"Minimum face size in pixels to detect. 20px: Balanced. 40px: Higher quality. 10px: Maximum recall.","default":20},"detection_threshold":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Detection Threshold","description":"Confidence threshold for face detection (0.0-1.0).","default":0.5},"max_faces_per_image":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Max Faces Per Image","description":"Maximum number of faces to process per image. None: Process all."},"normalize_embeddings":{"type":"boolean","title":"Normalize Embeddings","description":"L2-normalize embeddings to unit vectors (recommended).","default":true},"enable_quality_scoring":{"type":"boolean","title":"Enable Quality Scoring","description":"Compute quality scores (blur, size, landmarks). Adds ~5ms per face.","default":true},"quality_threshold":{"anyOf":[{"type":"number","maximum":1.0,"minimum":0.0},{"type":"null"}],"title":"Quality Threshold","description":"Minimum quality score to index faces. None: Index all faces. 0.5: Moderate filtering. 0.7: High quality only."},"max_video_length":{"type":"integer","maximum":300.0,"minimum":1.0,"title":"Max Video Length","description":"Maximum video length in seconds. 60: Default. 10: Recommended for retrieval. 300: Maximum (extraction only).","default":60},"video_sampling_fps":{"anyOf":[{"type":"number","maximum":60.0,"minimum":0.1},{"type":"null"}],"title":"Video Sampling Fps","description":"Frames per second to sample from video. 1.0: One frame per second (recommended).","default":1.0},"video_deduplication":{"type":"boolean","title":"Video Deduplication","description":"Remove duplicate faces across video frames (extraction only). Reduces 90-95% redundancy. NOT used in retrieval.","default":true},"video_deduplication_threshold":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Video Deduplication Threshold","description":"Cosine similarity threshold for deduplication. 0.8: Conservative (default).","default":0.8},"output_mode":{"type":"string","enum":["per_face","per_image"],"title":"Output Mode","description":"'per_face': One document per face (recommended). 'per_image': One doc per image with faces array.","default":"per_face"},"include_face_crops":{"type":"boolean","title":"Include Face Crops","description":"Include aligned 112×112 face crops as base64. Adds ~5KB per face. Required for LLM cluster labeling to see actual faces instead of hallucinating.","default":true},"include_source_frame_thumbnail":{"type":"boolean","title":"Include Source Frame Thumbnail","description":"Include resized source frame/image as base64 thumbnail (~15-30KB per face). Used for display with bounding box overlay.","default":false},"store_detection_metadata":{"type":"boolean","title":"Store Detection Metadata","description":"Store bbox, landmarks, detection scores. Recommended for debugging.","default":true}},"type":"object","title":"FaceIdentityExtractorParams","description":"Parameters for the Face Identity Extractor.\n\nThe Face Identity Extractor processes images or video frames to detect, align,\nand embed faces using production-grade SOTA models (SCRFD + ArcFace).\n\nCore Pipeline:\n1. SCRFD Detection → Bounding boxes + 5 landmarks\n2. 5-Point Affine Alignment → 112×112 canonical face\n3. ArcFace Embedding → 512-d L2-normalized vector\n4. Optional Quality Scoring → Filter low-quality faces\n\nUse Cases:\n    - Face verification (1:1 matching)\n    - Face identification (1:N search)\n    - Face clustering (group photos by person)\n    - Duplicate face detection","examples":[{"description":"Employee verification (high quality, 1:1 matching)","detection_model":"scrfd_2.5g","detection_threshold":0.7,"enable_quality_scoring":true,"extractor_type":"face_identity_extractor","max_faces_per_image":1,"min_face_size":40,"normalize_embeddings":true,"output_mode":"per_face","quality_threshold":0.5,"use_case":"Corporate access control, employee ID photos for badge matching"},{"description":"Photo library organization (multiple faces)","detection_model":"scrfd_2.5g","detection_threshold":0.6,"enable_quality_scoring":true,"extractor_type":"face_identity_extractor","min_face_size":30,"output_mode":"per_face","store_detection_metadata":true,"use_case":"Personal photo management: group photos by person"}]},"FailedObjectError":{"properties":{"object_index":{"type":"integer","title":"Object Index","description":"0-based index of the failed object in the batch request"},"error":{"type":"string","title":"Error","description":"Error message describing why the object failed"},"error_type":{"type":"string","title":"Error Type","description":"Type of error (e.g., 'ValidationError', 'URLValidationError')"}},"type":"object","required":["object_index","error","error_type"],"title":"FailedObjectError","description":"Error details for a failed object in a batch.","examples":[{"error":"Schema validation failed: Missing required field 'title'","error_type":"ValidationError","object_index":15},{"error":"URL validation failed: URL returned status 404","error_type":"URLValidationError","object_index":42}]},"FailedObjectRecord":{"properties":{"object_id":{"type":"string","title":"Object Id","description":"ID of the object that failed processing.","examples":["obj_video_001","obj_doc_123"]},"error":{"type":"string","title":"Error","description":"Human-readable error message describing what went wrong.","examples":["Invalid video format: unsupported codec","Connection timeout to embedding service","CUDA out of memory"],"x-mixpeek-redacted":"driver_text"},"error_type":{"type":"string","enum":["transient","permanent","resource"],"title":"Error Type","description":"Classification of the error for retry decisions. transient: network, timeout, temporary service issues (worth retrying). permanent: bad data, unsupported format (will never succeed). resource: GPU OOM, quota exceeded (may succeed with different resources).","examples":["transient","permanent","resource"]},"timestamp":{"type":"string","title":"Timestamp","description":"ISO 8601 timestamp when the error occurred.","examples":["2025-11-29T10:15:30Z"]}},"type":"object","required":["object_id","error","error_type","timestamp"],"title":"FailedObjectRecord","description":"Record of a single object that failed during batch processing.\n\nStored on the batch document in MongoDB to provide per-object error\nvisibility without requiring a separate query to the failed_documents\ncollection.\n\nUsed to:\n- Show users exactly which objects failed and why\n- Classify errors for retry decisions (transient vs permanent vs resource)\n- Enable selective resubmission of failed objects"},"FailureCategory":{"type":"string","enum":["timeout","infrastructure","orphaned","pipeline","mvs_durability","validation","unknown"],"title":"FailureCategory","description":"Batch-level failure classification.\n\nCoarser-grained than ErrorCategory (which classifies individual object\nerrors). FailureCategory is set on the batch itself to tell users\n*why the batch as a whole failed* — timeout, infra, orphan, pipeline,\nor unknown. Drives the \"Batch failed: <category>\" badge in Studio and\nlets callers distinguish retryable infra blips from genuine pipeline\nbugs without parsing human-readable strings."},"FailureMetric":{"properties":{"timestamp":{"type":"string","format":"date-time","title":"Timestamp"},"execution_id":{"type":"string","title":"Execution Id"},"error_message":{"type":"string","title":"Error Message"},"error_type":{"type":"string","title":"Error Type"}},"type":"object","required":["timestamp","execution_id","error_message","error_type"],"title":"FailureMetric","description":"Cluster failure metrics."},"FeatureAddress":{"properties":{"scheme":{"type":"string","title":"Scheme","default":"mixpeek"},"extractor":{"type":"string","title":"Extractor"},"version":{"type":"string","title":"Version"},"output":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Output"}},"type":"object","required":["extractor","version"],"title":"FeatureAddress","description":"Canonical feature address: mixpeek://{extractor}@{version}/{output}.\n\nThe output segment is the inference_name (embedding model identifier), which enables\ncross-extractor compatibility checking. Two feature URIs with the same inference_name\nin the output segment produce compatible embeddings that can be compared/fused.\n\nFormat examples:\n    - mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1\n    - mixpeek://multimodal_extractor@v1/multilingual_e5_large_instruct_v1  (compatible with above!)\n    - mixpeek://image_extractor@v1/google_siglip_base_v1  (different model = incompatible)\n\nShort form without the output segment is allowed only if the extractor has\na single vector output."},"FeatureDiscoveryResponse":{"properties":{"modalities":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Modalities","description":"Per file type (modality): its billing unit, base search feature, and the add-on search-by features available, with rates"},"custom_features":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Custom Features","description":"Org-scoped BYO plugin features (empty on the public route; populated when called with org auth — Phase 4b, collection config v2)"},"full_res_multiplier":{"type":"number","title":"Full Res Multiplier","description":"Multiplier applied when a collection opts out of mezzanine normalization (full_res)"}},"type":"object","required":["modalities","full_res_multiplier"],"title":"FeatureDiscoveryResponse","description":"Contract v2 §6.1 — the platform feature menu (D9: server-owned\nvocabulary; studio/homepage render these labels, never their own)."},"FeatureExtractorResponseModel":{"properties":{"feature_extractor_name":{"type":"string","title":"Feature Extractor Name"},"version":{"type":"string","title":"Version"},"feature_extractor_id":{"type":"string","title":"Feature Extractor Id"},"description":{"type":"string","title":"Description"},"icon":{"type":"string","title":"Icon"},"category":{"type":"string","title":"Category","description":"Category of this extractor, used for UI grouping and filtering. Examples: 'text', 'image', 'multimodal', 'audio', 'video', 'document', 'face', 'corpus', 'utility', 'safety', 'classification', 'web', 'custom'.","default":"general"},"source":{"$ref":"#/components/schemas/ExtractorSource","description":"The origin/source of this extractor: 'builtin' (shipped with Mixpeek), 'custom' (user-created), or 'community' (marketplace).","default":"builtin"},"type_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Type Mode","description":"What input types this extractor can handle: 'type_specific' (only one type) or 'multimodal' (handles multiple types). Type-specific extractors cannot use automatic-typed bucket properties."},"expected_input_types":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Expected Input Types","description":"For type-specific extractors: maps input keys to required types (e.g., {'video': 'video'}). For multimodal extractors: null."},"inference_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inference Type","description":"Kind of real-time inference this extractor provides: 'embedding', 'rerank', 'classify', 'generate', or 'general'. Null if batch-only."},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema"},"output_schema":{"additionalProperties":true,"type":"object","title":"Output Schema"},"parameter_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Parameter Schema"},"supported_input_types":{"items":{"type":"string"},"type":"array","title":"Supported Input Types"},"max_inputs":{"additionalProperties":{"type":"integer"},"type":"object","title":"Max Inputs"},"default_parameters":{"additionalProperties":true,"type":"object","title":"Default Parameters"},"costs":{"anyOf":[{"$ref":"#/components/schemas/CostsInfo"},{"type":"null"}],"description":"Credit cost information for this extractor"},"required_vector_indexes":{"anyOf":[{"items":{"$ref":"#/components/schemas/VectorIndexDefinition"},"type":"array"},{"type":"null"}],"title":"Required Vector Indexes"},"required_payload_indexes":{"anyOf":[{"items":{"$ref":"#/components/schemas/PayloadIndexConfig-Output"},"type":"array"},{"type":"null"}],"title":"Required Payload Indexes"},"position_fields":{"items":{"type":"string"},"type":"array","title":"Position Fields","description":"Output fields that uniquely identify each document within a source object. Enables idempotent reprocessing: rerunning a batch produces the same document IDs, so existing documents are updated instead of creating duplicates. Works with bucket `unique_key` to enable fully deterministic document IDs. Empty list means single-output extractor (one document per source). Read-only (set by extractor).","examples":[["start_time","end_time"],["chunk_index"],[]]},"capabilities":{"items":{"type":"string"},"type":"array","title":"Capabilities","description":"What this extractor can do: 'batch' (feature extraction during ingestion), 'realtime' (query-time inference for retriever stages)"},"example_usage":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Example Usage","description":"Minimal working configuration for namespace + collection + input_mappings + parameters"},"realtime_available":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Realtime Available","description":"Whether every Ray Serve application this extractor needs for real-time inference is running on the deployment serving this request. True when all of them report RUNNING. False when one is absent or not running; see serve_apps for which. Null when the extractor needs none, or when the live list could not be read."},"serve_apps":{"items":{"$ref":"#/components/schemas/ServeAppStatus"},"type":"array","title":"Serve Apps","description":"The Ray Serve applications this extractor needs for real-time inference, each with its live status. Empty when it needs none."}},"type":"object","required":["feature_extractor_name","version","feature_extractor_id","description","icon","input_schema","output_schema","parameter_schema","supported_input_types","max_inputs","default_parameters","required_vector_indexes","required_payload_indexes"],"title":"FeatureExtractorResponseModel","description":"Feature extractor response model for API responses."},"FeatureModel":{"properties":{"feature_extractor_id":{"type":"string","title":"Feature Extractor Id","description":"ID of the feature extractor that produced this response"},"payload":{"additionalProperties":true,"type":"object","title":"Payload","description":"Metadata of the feature"},"vectors":{"anyOf":[{"$ref":"#/components/schemas/DenseVector"},{"$ref":"#/components/schemas/SparseVector"},{"$ref":"#/components/schemas/MultiDenseVector"},{"$ref":"#/components/schemas/NamedDenseVectors"},{"type":"null"}],"title":"Vectors","description":"Vector representation of the feature. Can be any supported vector type."}},"additionalProperties":true,"type":"object","required":["feature_extractor_id"],"title":"FeatureModel","description":"Response from a feature extractor."},"FeatureSearchQuery":{"properties":{"input_mode":{"type":"string","title":"Input Mode","description":"Input mode: text, image, url, or vector.","default":"text"},"text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Text","description":"Text query (when input_mode=text)."},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url","description":"URL query (when input_mode=url)."},"image":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Image","description":"Base64 image (when input_mode=image)."},"vector":{"anyOf":[{"items":{"type":"number"},"type":"array"},{"items":{"items":{"type":"number"},"type":"array"},"type":"array"},{"type":"null"}],"title":"Vector","description":"Pre-computed query vector (when input_mode=vector). Either a single dense vector (list[float]) or multi-vector token embeddings (list[list[float]], e.g. ColBERT). NOTE — this field is specific to THIS convenience endpoint. In a retriever's feature_search STAGE the canonical carrier is 'value': {\"input_mode\": \"vector\", \"value\": [...]}. The stage also accepts 'vector' as a forgiving alias (normalized to 'value'), so the same shape works in both places."}},"type":"object","title":"FeatureSearchQuery"},"FeatureSearchRequest":{"properties":{"collection_identifiers":{"items":{"type":"string"},"type":"array","title":"Collection Identifiers","description":"Collection IDs or names to search. OPTIONAL: omit (or pass []) on standalone/BYOV namespaces to search the namespace's direct-upsert documents without naming a collection."},"query":{"$ref":"#/components/schemas/FeatureSearchQuery","description":"Search query."},"feature_uri":{"type":"string","title":"Feature Uri","description":"Feature URI to search against.","default":"mixpeek://text_extractor@v1/embedding"},"top_k":{"type":"integer","maximum":1000.0,"minimum":1.0,"title":"Top K","description":"Number of results to return.","default":25},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","description":"Pre-filters to apply before search."}},"type":"object","required":["query"],"title":"FeatureSearchRequest"},"FeaturedGalleryConfig-Input":{"properties":{"enabled":{"type":"boolean","title":"Enabled","description":"Whether the featured gallery is shown","default":true},"title":{"type":"string","title":"Title","description":"Gallery section title","default":"Featured"},"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id","description":"Internal retriever ID (defaults to first tab's retriever)"},"public_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Public Name","description":"Marketplace catalog public_name for gallery execution"},"default_inputs":{"additionalProperties":true,"type":"object","title":"Default Inputs","description":"Default inputs to auto-execute when page loads"},"layout":{"$ref":"#/components/schemas/LayoutConfig","description":"Layout configuration for gallery results"},"field_config":{"additionalProperties":{"$ref":"#/components/schemas/FieldConfig"},"type":"object","title":"Field Config","description":"Field display configuration for gallery results"}},"type":"object","title":"FeaturedGalleryConfig","description":"Configuration for the featured gallery section."},"FeaturedGalleryConfig-Output":{"properties":{"enabled":{"type":"boolean","title":"Enabled","description":"Whether the featured gallery is shown","default":true},"title":{"type":"string","title":"Title","description":"Gallery section title","default":"Featured"},"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id","description":"Internal retriever ID (defaults to first tab's retriever)"},"public_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Public Name","description":"Marketplace catalog public_name for gallery execution"},"default_inputs":{"additionalProperties":true,"type":"object","title":"Default Inputs","description":"Default inputs to auto-execute when page loads"},"layout":{"$ref":"#/components/schemas/LayoutConfig","description":"Layout configuration for gallery results"},"field_config":{"additionalProperties":{"$ref":"#/components/schemas/FieldConfig"},"type":"object","title":"Field Config","description":"Field display configuration for gallery results"}},"type":"object","title":"FeaturedGalleryConfig","description":"Configuration for the featured gallery section."},"FieldConfig":{"properties":{"format":{"$ref":"#/components/schemas/FieldFormatType","description":"Format type for this field (text, image, date, number, etc.)"},"format_options":{"$ref":"#/components/schemas/FieldFormatOptions","description":"Format-specific display options"}},"type":"object","required":["format"],"title":"FieldConfig","description":"Configuration for how to display a specific field in results.","examples":[{"format":"text","format_options":{"label":"Title","truncate_chars":60}},{"format":"image","format_options":{"aspect_ratio":"16/9","height":300,"lazy_load":true,"width":400}},{"format":"date","format_options":{"date_format":"relative","label":"Posted"}},{"format":"number","format_options":{"decimals":2,"label":"Price","prefix":"$"}}]},"FieldFormatOptions":{"properties":{"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label","description":"Display label for this field","examples":["Title","Price","Posted Date"]},"show_empty":{"type":"boolean","title":"Show Empty","description":"Whether to show the field if value is empty/null","default":true},"truncate_chars":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Truncate Chars","description":"Maximum characters before truncation (for text fields)","examples":[60,120,200]},"width":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Width","description":"Image width in pixels","examples":[400,800]},"height":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Height","description":"Image height in pixels","examples":[300,600]},"lazy_load":{"type":"boolean","title":"Lazy Load","description":"Enable lazy loading for images (default: true)","default":true},"aspect_ratio":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Aspect Ratio","description":"Aspect ratio for image container","examples":["16/9","4/3","1/1"]},"object_fit":{"type":"string","title":"Object Fit","description":"CSS object-fit property for images","default":"cover","examples":["cover","contain","fill"]},"date_format":{"type":"string","title":"Date Format","description":"Date format type: 'iso', 'relative', or custom format string","default":"relative","examples":["relative","iso","MMM DD, YYYY"]},"decimals":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Decimals","description":"Number of decimal places","examples":[0,1,2]},"prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prefix","description":"Prefix for number display","examples":["$","€","#"]},"suffix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Suffix","description":"Suffix for number display","examples":["%","k","M"]},"open_in_new_tab":{"type":"boolean","title":"Open In New Tab","description":"Open URLs in new tab (default: true)","default":true},"show_domain":{"type":"boolean","title":"Show Domain","description":"Show domain instead of full URL","default":false},"true_label":{"type":"string","title":"True Label","description":"Label for true values","default":"Yes"},"false_label":{"type":"string","title":"False Label","description":"Label for false values","default":"No"},"separator":{"type":"string","title":"Separator","description":"Separator for array items (default: ', ')","default":", "},"max_items":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Max Items","description":"Maximum array items to display"}},"type":"object","title":"FieldFormatOptions","description":"Format-specific options for field display.\n\nDifferent format types support different options:\n- text: label, truncate_chars, show_empty\n- image: width, height, lazy_load, aspect_ratio, object_fit\n- date: label, date_format (iso, relative, custom)\n- number: label, decimals, prefix, suffix, show_empty\n- url: label, open_in_new_tab, show_domain\n- boolean: label, true_label, false_label\n- array: label, separator, max_items","examples":[{"label":"Title","show_empty":false,"truncate_chars":60},{"aspect_ratio":"16/9","height":300,"label":"Thumbnail","lazy_load":true,"object_fit":"cover","width":400},{"date_format":"relative","label":"Posted"},{"decimals":2,"label":"Price","prefix":"$"}]},"FieldFormatType":{"type":"string","enum":["text","image","date","number","url","boolean","array","object"],"title":"FieldFormatType","description":"Supported field format types for result display."},"FieldMapping":{"properties":{"source_field":{"type":"string","title":"Source Field"},"target":{"$ref":"#/components/schemas/MappingTarget"}},"type":"object","required":["source_field","target"],"title":"FieldMapping"},"FieldMappingEntry":{"properties":{"target_type":{"type":"string","const":"field","title":"Target Type","description":"Target type. Must be 'field' for regular schema fields.","default":"field"},"source":{"oneOf":[{"$ref":"#/components/schemas/S3TagSource"},{"$ref":"#/components/schemas/S3MetadataSource"},{"$ref":"#/components/schemas/FilenameRegexSource"},{"$ref":"#/components/schemas/ColumnSource"},{"$ref":"#/components/schemas/DrivePropertySource"},{"$ref":"#/components/schemas/FolderPathSource"},{"$ref":"#/components/schemas/FileSource"},{"$ref":"#/components/schemas/ConstantSource"},{"$ref":"#/components/schemas/RSSFieldSource"},{"$ref":"#/components/schemas/RTSPFieldSource"}],"title":"Source","description":"Source extractor defining where to get the value. Options: tag, metadata, filename_regex, column, drive_property, folder_path, constant, rss_field, rtsp_field. The 'file' source is not valid for field mappings (use blob instead).","discriminator":{"propertyName":"type","mapping":{"column":"#/components/schemas/ColumnSource","constant":"#/components/schemas/ConstantSource","drive_property":"#/components/schemas/DrivePropertySource","file":"#/components/schemas/FileSource","filename_regex":"#/components/schemas/FilenameRegexSource","folder_path":"#/components/schemas/FolderPathSource","metadata":"#/components/schemas/S3MetadataSource","rss_field":"#/components/schemas/RSSFieldSource","rtsp_field":"#/components/schemas/RTSPFieldSource","tag":"#/components/schemas/S3TagSource"}}},"transform":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Transform","description":"Optional transformation to apply to the extracted value. Supported transforms: 'lowercase' - convert to lowercase, 'uppercase' - convert to uppercase, 'trim' - remove leading/trailing whitespace, 'json_parse' - parse JSON string to object/array. Transforms are applied after extraction, before storage.","examples":["lowercase","uppercase","trim","json_parse"]},"required":{"type":"boolean","title":"Required","description":"If True, the sync will fail if this field cannot be extracted. If False (default), missing values result in the field being omitted. Use required=True for critical fields that must be present.","default":false}},"type":"object","required":["source"],"title":"FieldMappingEntry","description":"Maps a source value to a bucket schema field.\n\nUsed for mapping metadata, tags, columns, or extracted values to\nregular fields in the bucket schema (strings, numbers, arrays, etc.).\nDoes NOT handle file content - use BlobMappingEntry for that.\n\nExample: Map S3 tag \"category\" to bucket field \"content_category\"\n    {\n        \"target_type\": \"field\",\n        \"source\": {\"type\": \"tag\", \"key\": \"category\"}\n    }\n\nExample: Map folder name to \"department\" with lowercase transform\n    {\n        \"target_type\": \"field\",\n        \"source\": {\"type\": \"folder_path\", \"segment\": 0},\n        \"transform\": \"lowercase\"\n    }\n\nExample: Map filename regex capture to \"date\" field\n    {\n        \"target_type\": \"field\",\n        \"source\": {\"type\": \"filename_regex\", \"pattern\": \"^(\\d{4}-\\d{2}-\\d{2})\"},\n        \"required\": true\n    }\n\nAttributes:\n    target_type: Must be \"field\" for schema field mappings\n    source: The source extractor defining where to get the value\n    transform: Optional transformation to apply (lowercase, uppercase, trim)\n    required: Whether missing values should fail the sync"},"FieldPassthrough":{"properties":{"source_path":{"type":"string","title":"Source Path","description":"REQUIRED. Path to the source field to copy. Simple fields: Use field name directly (e.g., 'title', 'campaign_id'). Nested fields: Use dot notation (e.g., 'metadata.author', 'config.model.version'). The field must exist in the source bucket schema or upstream collection schema. Without target_path, nested fields are flattened: 'metadata.author' becomes 'author' in output.","examples":["title","campaign_id","metadata.author","config.model_version","category"]},"target_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Path","description":"OPTIONAL. Target field name in output document. If NOT PROVIDED: Uses source_path name (or last component for nested paths).   - 'title' → 'title'   - 'metadata.author' → 'author' If PROVIDED: Uses this exact name in output.   - source_path='doc_title', target_path='title' → 'title'   - source_path='metadata.author', target_path='contributor' → 'contributor' Use cases:   - Rename fields for cleaner API schemas   - Avoid name conflicts with extractor outputs   - Standardize field names across different sources Constraints:   - Must not conflict with system fields (document_id, collection_id, etc.)   - Must not conflict with extractor output fields   - Must be a valid field name (alphanumeric, underscores, hyphens)","examples":["title","author","campaign_name","product_id","user_email"]},"default":{"anyOf":[{},{"type":"null"}],"title":"Default","description":"OPTIONAL. Default value if source field doesn't exist or is None. If NOT PROVIDED and field missing: Field is omitted from output document. If PROVIDED and field missing: Field is included with this default value. Type should match expected field type (string, int, list, dict, etc.).","examples":["Unknown","N/A",0,[],{},false]},"required":{"type":"boolean","title":"Required","description":"OPTIONAL. Whether this field MUST exist in source. If True and field missing: Raises validation error, processing fails. If False and field missing: Field omitted (or default used if provided). Use True for: Critical identifiers, required business fields. Use False for: Optional metadata, nice-to-have fields. Default: False (field is optional).","default":false}},"type":"object","required":["source_path"],"title":"FieldPassthrough","description":"Configuration for passing fields from source to output documents.\n\nSimple field passthrough: specify which fields to copy from source (bucket object\nor upstream collection document) to the output documents alongside extractor outputs.\n\nUse Cases:\n    - Preserve identifiers: campaign_id, product_sku, user_id\n    - Keep metadata: category, tags, author, timestamp\n    - Maintain business context: priority, status, region\n    - Extract nested values: metadata.author, config.model_version\n    - Rename fields for cleaner schemas: doc_title → title\n\nField Selection:\n    - WITHOUT field_passthrough: Only extractor outputs appear in documents\n    - WITH field_passthrough: Specified fields + extractor outputs\n    - WITH include_all_source_fields=True: All source fields + extractor outputs\n\nField Naming:\n    - WITHOUT target_path: Output uses source name (or last component for nested)\n      - \"title\" → \"title\"\n      - \"metadata.author\" → \"author\"\n    - WITH target_path: Output uses specified name\n      - source_path=\"doc_title\", target_path=\"title\" → \"title\"\n      - source_path=\"metadata.author\", target_path=\"contributor\" → \"contributor\"\n\nRequirements:\n    - source_path is REQUIRED - specifies which field to copy (supports dot notation)\n    - target_path is OPTIONAL - rename field in output (default: auto-derived name)\n    - default is OPTIONAL - provides fallback if field missing (default: omit field)\n    - required is OPTIONAL - errors if field missing (default: false, omit field)","examples":[{"description":"Simple field passthrough","required":true,"source_path":"title"},{"default":"uncategorized","description":"Field with default value","source_path":"category"},{"description":"Field renaming for cleaner schema","source_path":"doc_title","target_path":"title"},{"description":"Nested field extraction with custom name","source_path":"metadata.author","target_path":"contributor"},{"description":"Required field with renaming","required":true,"source_path":"campaign_id","target_path":"campaign"},{"default":"normal","description":"Optional field with default and renaming","required":false,"source_path":"metadata.priority","target_path":"priority"}]},"FieldPerformanceMetrics":{"properties":{"field_name":{"type":"string","title":"Field Name","description":"Metadata field name"},"usage_count":{"type":"integer","title":"Usage Count","description":"Number of times field was queried"},"avg_latency_ms":{"type":"number","title":"Avg Latency Ms","description":"Average latency when field is used"},"p50_latency_ms":{"type":"number","title":"P50 Latency Ms","description":"50th percentile latency"},"p95_latency_ms":{"type":"number","title":"P95 Latency Ms","description":"95th percentile latency"},"p99_latency_ms":{"type":"number","title":"P99 Latency Ms","description":"99th percentile latency"},"max_latency_ms":{"type":"number","title":"Max Latency Ms","description":"Maximum latency observed"},"index_priority_score":{"type":"number","title":"Index Priority Score","description":"Priority score for indexing (usage_count * avg_latency)"}},"type":"object","required":["field_name","usage_count","avg_latency_ms","p50_latency_ms","p95_latency_ms","p99_latency_ms","max_latency_ms","index_priority_score"],"title":"FieldPerformanceMetrics","description":"Performance correlation metrics for a field."},"FieldPerformanceResponse":{"properties":{"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace ID analyzed"},"time_range_days":{"type":"integer","title":"Time Range Days","description":"Number of days analyzed"},"fields":{"items":{"$ref":"#/components/schemas/FieldPerformanceMetrics"},"type":"array","title":"Fields","description":"Field performance metrics"},"total_fields":{"type":"integer","title":"Total Fields","description":"Total fields analyzed"},"coverage":{"anyOf":[{"$ref":"#/components/schemas/RecommendationCoverage"},{"type":"null"}],"description":"Scope of the numbers above: these fields were measured only from queries that filtered on something. Null when the analytics backend could not be read."}},"type":"object","required":["namespace_id","time_range_days","fields","total_fields"],"title":"FieldPerformanceResponse","description":"Response for field performance correlation endpoint."},"FieldQueryMetrics":{"properties":{"field_name":{"type":"string","title":"Field Name","description":"Metadata field name"},"query_count":{"type":"integer","title":"Query Count","description":"Number of queries using this field"},"avg_latency_ms":{"type":"number","title":"Avg Latency Ms","description":"Average query latency in milliseconds"},"p95_latency_ms":{"type":"number","title":"P95 Latency Ms","description":"95th percentile latency in milliseconds"}},"type":"object","required":["field_name","query_count","avg_latency_ms","p95_latency_ms"],"title":"FieldQueryMetrics","description":"Metrics for a metadata field's query usage."},"FieldUsageResponse":{"properties":{"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace being analyzed"},"period":{"type":"string","title":"Period","description":"Analysis period (24h, 7d, 30d)"},"fields":{"items":{"$ref":"#/components/schemas/FieldUsageStat"},"type":"array","title":"Fields","description":"Field usage statistics"},"total_fields":{"type":"integer","title":"Total Fields","description":"Total number of fields found"},"indexed_fields":{"type":"integer","title":"Indexed Fields","description":"Number of indexed fields"},"unindexed_fields":{"type":"integer","title":"Unindexed Fields","description":"Number of unindexed fields"}},"type":"object","required":["namespace_id","period","fields","total_fields","indexed_fields","unindexed_fields"],"title":"FieldUsageResponse","description":"Response containing field usage statistics."},"FieldUsageStat":{"properties":{"field_name":{"type":"string","title":"Field Name","description":"Field name"},"query_count":{"type":"integer","title":"Query Count","description":"Number of queries using this field"},"unique_queries":{"type":"integer","title":"Unique Queries","description":"Number of unique query executions"},"is_indexed":{"type":"boolean","title":"Is Indexed","description":"Whether field has an index"},"is_protected":{"type":"boolean","title":"Is Protected","description":"Whether field is system-protected"},"avg_latency_ms":{"type":"number","title":"Avg Latency Ms","description":"Average query latency"},"p95_latency_ms":{"type":"number","title":"P95 Latency Ms","description":"95th percentile latency"},"first_seen":{"type":"string","format":"date-time","title":"First Seen","description":"First usage timestamp"},"last_seen":{"type":"string","format":"date-time","title":"Last Seen","description":"Most recent usage timestamp"}},"type":"object","required":["field_name","query_count","unique_queries","is_indexed","is_protected","avg_latency_ms","p95_latency_ms","first_seen","last_seen"],"title":"FieldUsageStat","description":"Usage statistics for a filtered field."},"FileDiff":{"properties":{"path":{"type":"string","title":"Path"},"status":{"type":"string","enum":["added","removed","modified","unchanged"],"title":"Status"},"old_hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Old Hash"},"new_hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"New Hash"},"old_size":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Old Size"},"new_size":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"New Size"},"size_delta":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Size Delta"}},"type":"object","required":["path","status"],"title":"FileDiff","description":"A single file change between two versions."},"FileFilters":{"properties":{"include_patterns":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Include Patterns","description":"Glob patterns to include (e.g. ['*.mp4', '*.mov']). A pattern without '/' matches the file name in any folder; a pattern with '/' matches the path from the sync's source root (e.g. 'videos/*.mp4')."},"exclude_patterns":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Exclude Patterns","description":"Glob patterns to exclude (e.g. ['*/drafts/*', '*_temp.*']). Matched like include_patterns: without '/' against the file name, with '/' against the path from the sync's source root."},"min_size_bytes":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Min Size Bytes","description":"Minimum file size (bytes). Files smaller are skipped."},"max_size_bytes":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Max Size Bytes","description":"Maximum file size (bytes). Files larger are skipped."},"modified_after":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Modified After","description":"Only sync files modified after this timestamp."},"modified_before":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Modified Before","description":"Only sync files modified before this timestamp."},"mime_types":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Mime Types","description":"Optional list of MIME types to include."},"metadata_filters":{"anyOf":[{"items":{"$ref":"#/components/schemas/MetadataFilter"},"type":"array"},{"type":"null"}],"title":"Metadata Filters","description":"Filters applied to provider-specific metadata fields. All filters combined with AND logic."}},"type":"object","title":"FileFilters","description":"Filter rules controlling which files are synced from storage providers.\n\nAll filters are optional and combined with AND logic.\nFiles must pass ALL specified filters to be synced.\n\n**Pattern Matching:** Uses glob patterns (*, ?, [abc], etc.)\n**Size Filtering:** Bytes-based, inclusive bounds\n**Time Filtering:** ISO 8601 datetime, based on provider's modified timestamp"},"FileSource":{"properties":{"type":{"type":"string","const":"file","title":"Type","description":"Source type identifier. Must be 'file' for the synced file itself.","default":"file"}},"type":"object","title":"FileSource","description":"Use the synced file itself as the source (for blob mappings).\n\nThis is the primary source for blob-type mappings where the synced file\ncontent becomes the blob. The mime_type is automatically detected from\nthe file unless explicitly overridden in the BlobMappingEntry.\n\nProvider Compatibility: All providers (works on any synced file)\n\nExample usage:\n    {\"type\": \"file\"} -> The synced file becomes the blob content\n\nThis source type has no additional configuration - it simply indicates\nthat the synced file content should be used as the blob data.\n\nAttributes:\n    type: Must be \"file\" to identify this source type"},"FilenameRegexSource":{"properties":{"type":{"type":"string","const":"filename_regex","title":"Type","description":"Source type identifier. Must be 'filename_regex' for regex extraction.","default":"filename_regex"},"pattern":{"type":"string","minLength":1,"title":"Pattern","description":"Python regex pattern with exactly one capture group. The captured group becomes the extracted value. Pattern is applied to the filename only (not full path). Use non-capturing groups (?:...) for grouping without capturing. Remember to escape backslashes in JSON (\\\\d instead of \\d).","examples":["^(\\w+)_","_(\\d+)_","\\.(\\w+)$","^(\\d{4}-\\d{2}-\\d{2})"]},"default":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default","description":"Default value if regex doesn't match the filename. If None and regex doesn't match, the field is omitted from the object. Useful for ensuring a field always has a value.","examples":["unknown","default","unclassified"]}},"type":"object","required":["pattern"],"title":"FilenameRegexSource","description":"Extract value from filename using a regex pattern with capture groups.\n\nUseful when metadata is encoded in filenames following a naming convention.\nThe regex must contain exactly one capture group to extract the value.\n\nProvider Compatibility: All providers (works on any filename)\n\nExample filenames and patterns:\n    - \"marketing_Q4_2024_final.mp4\" with pattern \"^(\\w+)_Q\\d+_\" -> \"marketing\"\n    - \"user_12345_avatar.jpg\" with pattern \"user_(\\d+)_\" -> \"12345\"\n    - \"2024-01-15_meeting_notes.pdf\" with pattern \"^(\\d{4}-\\d{2}-\\d{2})\" -> \"2024-01-15\"\n    - \"IMG_20240115_143022.jpg\" with pattern \"IMG_(\\d{8})_\" -> \"20240115\"\n\nNote: Use raw strings in Python or double-escape backslashes in JSON.\n\nAttributes:\n    type: Must be \"filename_regex\" to identify this source type\n    pattern: Python regex with exactly one capture group\n    default: Optional default value if regex doesn't match"},"FilterCondition":{"properties":{"field":{"type":"string","title":"Field","description":"Field name to filter on"},"operator":{"$ref":"#/components/schemas/FilterOperator","description":"Comparison operator","default":"eq"},"value":{"anyOf":[{"$ref":"#/components/schemas/DynamicValue"},{}],"title":"Value","description":"Value to compare against"}},"type":"object","required":["field","value"],"title":"FilterCondition","description":"Represents a single filter condition.\n\nAttributes:\n    field: The field to filter on\n    operator: The comparison operator\n    value: The value to compare against"},"FilterOperator":{"type":"string","enum":["eq","ne","gt","lt","gte","lte","in","nin","contains","starts_with","ends_with","regex","exists","is_null","text","phrase","words","geo_radius","geo_bounding_box","geo_polygon"],"title":"FilterOperator","description":"Supported filter operators across database implementations.\n\n`text` is a case-insensitive substring match on the MVS vector store, in\nthe in-memory evaluator and in the collections list filter; it does not\ntokenize or rank. On the Mongo query translator it becomes a Mongo `$text`\nsearch, which needs a collection text index and searches every indexed\nfield. For whole-word matching on one field use `words`: every word of the\nvalue must appear as a whole word, compared on its English stem."},"FlatTaxonomyConfig-Input":{"properties":{"taxonomy_type":{"type":"string","const":"flat","title":"Taxonomy Type","description":"Discriminator identifying this as a flat taxonomy.","default":"flat"},"retriever_id":{"type":"string","title":"Retriever Id","description":"The retriever to use for matching against the source collection."},"input_mappings":{"items":{"$ref":"#/components/schemas/InputMapping"},"type":"array","title":"Input Mappings","description":"Input mappings defining how to construct retriever inputs."},"source_collection":{"$ref":"#/components/schemas/SourceCollection-Input","description":"The single source collection for this flat taxonomy."},"top_k":{"type":"integer","maximum":50.0,"minimum":1.0,"title":"Top K","description":"Maximum nodes a materialized run assigns to each document, best first, as the taxonomy_enrich stage's top_k does on demand. The best match fills the _internal._taxonomy_<id>_id, _label and _score fields. Above 1, every kept match is also listed, ranked, in _internal._taxonomy_<id>_assignments, and append-mode enrichment fields collect their values from every kept match. Default 1: one node per document.","default":1},"step_analytics":{"anyOf":[{"$ref":"#/components/schemas/StepAnalyticsConfig-Input"},{"type":"null"}],"description":"Optional configuration for step transition analytics. Enables tracking how documents progress through taxonomy labels over time (e.g., email thread progression from 'inquiry' to 'closed_won'). If not provided, only basic assignment events are logged."}},"type":"object","required":["retriever_id","input_mappings","source_collection"],"title":"FlatTaxonomyConfig","description":"Configuration for a *flat* taxonomy - single source collection with one retriever.","examples":[{"input_mappings":[{"input_key":"image_vector","path":"features.clip_vit_l_14","source_type":"vector"}],"retriever_id":"ret_clip_v1","source_collection":{"collection_id":"col_products_v1","enrichment_fields":[{"field_path":"metadata.tags","merge_mode":"append"}]},"taxonomy_type":"flat"}]},"FlatTaxonomyConfig-Output":{"properties":{"taxonomy_type":{"type":"string","const":"flat","title":"Taxonomy Type","description":"Discriminator identifying this as a flat taxonomy.","default":"flat"},"retriever_id":{"type":"string","title":"Retriever Id","description":"The retriever to use for matching against the source collection."},"input_mappings":{"items":{"$ref":"#/components/schemas/InputMapping"},"type":"array","title":"Input Mappings","description":"Input mappings defining how to construct retriever inputs."},"source_collection":{"$ref":"#/components/schemas/SourceCollection-Output","description":"The single source collection for this flat taxonomy."},"top_k":{"type":"integer","maximum":50.0,"minimum":1.0,"title":"Top K","description":"Maximum nodes a materialized run assigns to each document, best first, as the taxonomy_enrich stage's top_k does on demand. The best match fills the _internal._taxonomy_<id>_id, _label and _score fields. Above 1, every kept match is also listed, ranked, in _internal._taxonomy_<id>_assignments, and append-mode enrichment fields collect their values from every kept match. Default 1: one node per document.","default":1},"step_analytics":{"anyOf":[{"$ref":"#/components/schemas/StepAnalyticsConfig-Output"},{"type":"null"}],"description":"Optional configuration for step transition analytics. Enables tracking how documents progress through taxonomy labels over time (e.g., email thread progression from 'inquiry' to 'closed_won'). If not provided, only basic assignment events are logged."}},"type":"object","required":["retriever_id","input_mappings","source_collection"],"title":"FlatTaxonomyConfig","description":"Configuration for a *flat* taxonomy - single source collection with one retriever.","examples":[{"input_mappings":[{"input_key":"image_vector","path":"features.clip_vit_l_14","source_type":"vector"}],"retriever_id":"ret_clip_v1","source_collection":{"collection_id":"col_products_v1","enrichment_fields":[{"field_path":"metadata.tags","merge_mode":"append"}]},"taxonomy_type":"flat"}]},"FloatIndexParams":{"properties":{"type":{"type":"string","title":"Type","default":"float"}},"type":"object","title":"FloatIndexParams","description":"Configuration for float index."},"FolderItem":{"properties":{"id":{"type":"string","title":"Id","description":"REQUIRED. Folder ID in Google Drive. Use this ID when configuring sync operations. Format: Google Drive folder identifier (e.g., '0AH-Xabc123').","examples":["0AH-Xabc123","1ABCdef456GHI"]},"name":{"type":"string","title":"Name","description":"REQUIRED. Display name of the folder. Human-readable name shown in the Google Drive UI.","examples":["Marketing","2024 Campaigns","Assets"]},"path":{"type":"string","title":"Path","description":"REQUIRED. Full path from root to this folder. Format: '/' for root, '/FolderName' for first level, '/Parent/Child' for nested folders.","examples":["/","/Marketing","/Marketing/2024 Campaigns"]},"mime_type":{"type":"string","title":"Mime Type","description":"REQUIRED. MIME type identifier for folders. Always 'application/vnd.google-apps.folder' for folders.","examples":["application/vnd.google-apps.folder"]}},"type":"object","required":["id","name","path","mime_type"],"title":"FolderItem","description":"Represents a folder in Google Drive for folder selection in sync configuration.\n\nUsed by the list folders endpoint to help users browse and select folders\nfor sync operations. Only available for Google Drive connections.","examples":[{"description":"Root folder","id":"root","mime_type":"application/vnd.google-apps.folder","name":"My Drive","path":"/"},{"description":"Nested folder","id":"0AH-Xabc123","mime_type":"application/vnd.google-apps.folder","name":"Marketing","path":"/Marketing"}]},"FolderPathSource":{"properties":{"type":{"type":"string","const":"folder_path","title":"Type","description":"Source type identifier. Must be 'folder_path' for path extraction.","default":"folder_path"},"segment":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Segment","description":"Extract a specific path segment by index. 0 = first segment (root folder), 1 = second segment, etc. -1 = last segment (immediate parent), -2 = second to last, etc. If None and full_path is False, extracts the immediate parent folder.","examples":[0,1,2,-1,-2]},"full_path":{"type":"boolean","title":"Full Path","description":"If True, extracts the complete folder path (joined with '/'). If False, extracts only the segment specified or immediate parent. Does not include the filename.","default":false}},"type":"object","title":"FolderPathSource","description":"Extract value from the folder path structure.\n\nUseful for deriving categories or metadata from folder organization.\nCan extract the full path, a specific segment, or the immediate parent.\n\nProvider Compatibility: All providers with folder/prefix structure\n\nExample folder structure: /Marketing/Campaigns/Q4-2024/videos/\n    - segment=0 -> \"Marketing\"\n    - segment=1 -> \"Campaigns\"\n    - segment=2 -> \"Q4-2024\"\n    - segment=-1 -> \"videos\" (last segment)\n    - full_path=True -> \"Marketing/Campaigns/Q4-2024/videos\"\n    - Neither (default) -> \"videos\" (immediate parent)\n\nUse Cases:\n    - Derive category from top-level folder\n    - Extract project name from folder structure\n    - Preserve full path for hierarchical organization\n\nAttributes:\n    type: Must be \"folder_path\" to identify this source type\n    segment: Index of path segment to extract (0-based, negative for reverse)\n    full_path: Whether to extract complete path"},"GCSConfig":{"properties":{"provider_type":{"type":"string","const":"gcs","title":"Provider Type","default":"gcs"},"credentials":{"$ref":"#/components/schemas/GCSServiceAccountKeyCredentials","description":"REQUIRED. GCS service-account JSON key credentials."},"bucket":{"type":"string","title":"Bucket","description":"REQUIRED. Name of the GCS bucket to sync from (no 'gs://' prefix). The service account must have read access to this bucket.","examples":["my-media-bucket","company-data-lake"]},"prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prefix","description":"NOT REQUIRED. Object key prefix to scope the sync to a folder within the bucket (e.g. 'marketing/videos/'). When set, it is prepended to any requested list path.","examples":["marketing/videos/","2024/"]}},"type":"object","required":["credentials","bucket"],"title":"GCSConfig","description":"Google Cloud Storage (native SDK) storage provider configuration.\n\nReads objects from a GCS bucket using the native ``google-cloud-storage``\nSDK authenticated with a service-account JSON key. This is the documented,\ndiscoverable path (Storage Object Viewer + a JSON key) and does not require\nminting GCS HMAC interop keys or routing through the S3-compatible XML API.\n\nAuthentication:\n    - Service account JSON key (from ``storage.Client.from_service_account_info``)\n\nRequirements:\n    - Active GCP project with a bucket to read\n    - Service account granted read access (Storage Object Viewer) on the bucket\n    - A JSON key downloaded for that service account\n\nUse Cases:\n    - Ingest media/data-lake objects from GCS buckets\n    - Sync marketing/creative assets stored in Google Cloud\n    - Unified search across GCS + other sources","examples":[{"bucket":"my-media-bucket","credentials":{"service_account_json":{"client_email":"mixpeek-sync@my-project.iam.gserviceaccount.com","client_id":"123456789012345678901","private_key":"-----BEGIN PRIVATE KEY-----\n...\n-----END PRIVATE KEY-----\n","private_key_id":"abc123","project_id":"my-project","token_uri":"https://oauth2.googleapis.com/token","type":"service_account"},"type":"service_account"},"description":"GCS bucket sync via service account key","prefix":"marketing/videos/","provider_type":"gcs"}]},"GCSServiceAccountKeyCredentials":{"properties":{"type":{"type":"string","const":"service_account","title":"Type","default":"service_account"},"service_account_json":{"additionalProperties":true,"type":"object","title":"Service Account Json","description":"REQUIRED. The full service-account JSON key object (the contents of the downloaded key file). Must include at least 'client_email', 'private_key', and 'project_id'. SECURITY: This is a secret credential, redacted on read. Never log or expose it."}},"type":"object","required":["service_account_json"],"title":"GCSServiceAccountKeyCredentials","description":"Google Cloud Storage service-account JSON key credentials.\n\nNative GCS auth (NOT the S3-compatible XML API): the whole downloaded\nservice-account JSON key is supplied as a single object under\n``service_account_json``. The provider builds the client via\n``storage.Client.from_service_account_info(service_account_json)``.\n\nPrerequisites:\n    - Create a service account in Google Cloud Console\n    - Grant it the Storage Object Viewer role on the target bucket\n    - Create a JSON key for the service account and download it\n    - Paste the full JSON contents into ``service_account_json``\n\nSecurity:\n    - The embedded ``private_key`` is in the connection client's\n      SENSITIVE_KEYS redaction set, so it is masked on read.\n    - Never commit the JSON key to version control."},"GateMetricComparison":{"properties":{"baseline":{"type":"number","title":"Baseline","description":"Score of the live configuration."},"candidate":{"type":"number","title":"Candidate","description":"Score of the candidate."},"delta":{"type":"number","title":"Delta","description":"Candidate minus baseline."},"threshold":{"type":"number","title":"Threshold","description":"Largest relative drop allowed before it counts as a regression."},"pct_change":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pct Change","description":"Relative change against the baseline; null when the baseline is 0."},"regressed":{"type":"boolean","title":"Regressed","description":"True when the drop exceeds the threshold."},"comparable":{"type":"boolean","title":"Comparable","description":"False when the baseline is 0, so no relative change exists."}},"type":"object","required":["baseline","candidate","delta","threshold","regressed","comparable"],"title":"GateMetricComparison","description":"One metric of a gate verdict: the baseline and candidate scores."},"GateVerdict":{"properties":{"passed":{"type":"boolean","title":"Passed","description":"True only when the candidate shipped: no metric regressed and the primary metric scored strictly higher than the baseline."},"reason":{"type":"string","title":"Reason","description":"Why the candidate shipped or was refused."},"primary_metric":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Primary Metric","description":"Metric the candidate had to beat the baseline on."},"compared_metrics":{"type":"integer","title":"Compared Metrics","description":"Number of metrics compared between the two evaluations.","default":0},"regressed_metrics":{"items":{"type":"string"},"type":"array","title":"Regressed Metrics","description":"Metrics that dropped past their threshold."},"skipped_metrics":{"items":{"type":"string"},"type":"array","title":"Skipped Metrics","description":"Baseline metrics the candidate did not produce."},"per_metric":{"additionalProperties":{"$ref":"#/components/schemas/GateMetricComparison"},"type":"object","title":"Per Metric","description":"Baseline and candidate score for every compared metric."}},"type":"object","required":["passed","reason"],"title":"GateVerdict","description":"The evaluation gate's verdict on a candidate against the live baseline."},"GaussianMixtureParams":{"properties":{"n_components":{"type":"integer","minimum":1.0,"title":"N Components","description":"Number of mixture components","default":1},"covariance_type":{"type":"string","title":"Covariance Type","description":"Type of covariance parameters ('full', 'tied', 'diag', 'spherical')","default":"full"},"tol":{"type":"number","exclusiveMinimum":0.0,"title":"Tol","description":"Convergence threshold","default":0.001},"reg_covar":{"type":"number","minimum":0.0,"title":"Reg Covar","description":"Regularization added to the diagonal of covariance","default":1e-06},"max_iter":{"type":"integer","minimum":1.0,"title":"Max Iter","description":"Maximum number of EM iterations","default":100},"n_init":{"type":"integer","minimum":1.0,"title":"N Init","description":"Number of initializations to perform","default":1},"init_params":{"type":"string","title":"Init Params","description":"Method used to initialize weights, means and covariances ('kmeans' or 'random')","default":"kmeans"},"weights_init":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Weights Init","description":"Initial weights"},"means_init":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Means Init","description":"Initial means"},"precisions_init":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Precisions Init","description":"Initial precisions"},"random_state":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Random State","description":"Random seed for reproducibility","default":42},"warm_start":{"type":"boolean","title":"Warm Start","description":"If True, use the solution of the last fit as initialization","default":false},"verbose":{"type":"integer","minimum":0.0,"title":"Verbose","description":"Enable verbose output","default":0},"verbose_interval":{"type":"integer","minimum":1.0,"title":"Verbose Interval","description":"Number of iterations between each verbose message","default":10}},"type":"object","title":"GaussianMixtureParams","description":"Parameters for Gaussian Mixture Model clustering."},"GeminiMultifileExtractorParams":{"properties":{"extractor_type":{"type":"string","const":"gemini_multifile_extractor","title":"Extractor Type","description":"Discriminator field for parameter type identification.","default":"gemini_multifile_extractor"},"output_dimensionality":{"type":"integer","maximum":3072.0,"minimum":256.0,"title":"Output Dimensionality","description":"Output embedding dimensions. Gemini Embedding 2 supports 3072 (default), 768, or 256 via truncation. Lower dimensions reduce storage cost at slight quality loss.","default":3072},"task_type":{"type":"string","title":"Task Type","description":"Embedding intent used as a text instruction for Gemini Embedding 2. Common values: RETRIEVAL_DOCUMENT, RETRIEVAL_QUERY, SEMANTIC_SIMILARITY, CLASSIFICATION.","default":"RETRIEVAL_DOCUMENT"},"input_key":{"type":"string","title":"Input Key","description":"The input_mappings key whose value is the list of blob fields to embed together. Must match the key used in input_mappings (e.g., 'files'). Default: 'files'.","default":"files"}},"type":"object","title":"GeminiMultifileExtractorParams","description":"Parameters for the Gemini Multifile Extractor.\n\nUses Gemini Embedding 2 (gemini-embedding-2) to embed all files\nof an object into a single 3072-d vector in one API call. Supports images,\nvideo, audio, PDF, and text blobs.","examples":[{"extractor_type":"gemini_multifile_extractor","input_key":"files","output_dimensionality":3072,"task_type":"RETRIEVAL_DOCUMENT"}]},"GenerateFromInteractionsRequest":{"properties":{"dataset_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dataset Name","description":"Name for the generated dataset. If omitted, defaults to 'auto_{retriever_id}_{date}'."},"min_interactions":{"type":"integer","minimum":1.0,"title":"Min Interactions","description":"Minimum number of positive interactions a query must have to be included in the dataset. Queries with fewer interactions are excluded as low-confidence ground truth.","default":5},"lookback_days":{"type":"integer","maximum":365.0,"minimum":1.0,"title":"Lookback Days","description":"How many days of interaction history to consider.","default":30},"positive_interaction_types":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Positive Interaction Types","description":"Interaction types considered positive signals. Defaults to: click, purchase, positive_feedback, bookmark, share."}},"additionalProperties":false,"type":"object","title":"GenerateFromInteractionsRequest","description":"Request to auto-generate an evaluation dataset from user interactions."},"GenerateManifestRequest":{"properties":{"description":{"type":"string","minLength":1,"title":"Description","description":"What the namespace should do, in plain words"},"manifest_name":{"type":"string","title":"Manifest Name","description":"metadata.name","default":"generated-manifest"},"inventory":{"anyOf":[{"additionalProperties":{"additionalProperties":{"type":"number"},"type":"object"},"type":"object"},{"type":"null"}],"title":"Inventory","description":"Optional files per bucket name the manifest will declare (objects, videos, minutes, audio_minutes, images, pages, tokens). When given, the answer carries `quote`, priced as POST /v1/organizations/billing/estimate prices a manifest"},"queries_per_month":{"type":"integer","minimum":0.0,"title":"Queries Per Month","description":"For the quote's monthly price","default":0}},"type":"object","required":["description"],"title":"GenerateManifestRequest"},"GenerationConfig":{"properties":{"candidate_count":{"type":"integer","title":"Candidate Count","description":"Number of candidate responses to generate for video description.","default":1},"max_output_tokens":{"type":"integer","title":"Max Output Tokens","description":"Maximum number of tokens for the generated video description.","default":1024},"temperature":{"type":"number","title":"Temperature","description":"Controls randomness for video description generation. Higher is more random.","default":0.2},"top_p":{"type":"number","title":"Top P","description":"Nucleus sampling (top-p) for video description generation.","default":0.8},"video_fps":{"anyOf":[{"type":"number","maximum":24.0,"exclusiveMinimum":0.0},{"type":"null"}],"title":"Video Fps","description":"Frames per second the model reads from each video segment for the description. Unset uses the model's default of 1. Raise it (for example to 4 or 5) for fast or fine motion such as hand work; input tokens grow with the rate."},"response_mime_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Response Mime Type","description":"MIME type for response (e.g., 'application/json')"},"response_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Response Schema","description":"JSON schema for structured output"}},"type":"object","title":"GenerationConfig","description":"Configuration for generative models."},"GenericDeleteResponse":{"properties":{"message":{"type":"string","title":"Message","default":"Successfully deleted"},"success":{"type":"boolean","title":"Success","default":true}},"type":"object","title":"GenericDeleteResponse","description":"GenericDeleteResponse."},"GenericSuccessResponse":{"properties":{"message":{"type":"string","title":"Message","default":"Successfully completed"},"success":{"type":"boolean","title":"Success","default":true}},"type":"object","title":"GenericSuccessResponse","description":"GenericSuccessResponse."},"GeoIndexParams":{"properties":{"type":{"type":"string","title":"Type","default":"geo"}},"type":"object","title":"GeoIndexParams","description":"Configuration for geo index."},"GetHistoryResponse":{"properties":{"session_id":{"type":"string","title":"Session Id","description":"Session identifier"},"messages":{"items":{"$ref":"#/components/schemas/MessageHistoryItem"},"type":"array","title":"Messages","description":"Message history"},"total_messages":{"type":"integer","title":"Total Messages","description":"Total messages in session"},"returned_messages":{"type":"integer","title":"Returned Messages","description":"Messages returned"},"has_more":{"type":"boolean","title":"Has More","description":"Whether more messages available"}},"type":"object","required":["session_id","messages","total_messages","returned_messages","has_more"],"title":"GetHistoryResponse","description":"Response for retrieving conversation history.\n\nAttributes:\n    session_id: Session identifier\n    messages: List of messages in chronological order\n    total_messages: Total number of messages in session\n    returned_messages: Number of messages returned (may be limited)\n    has_more: Whether there are more messages available\n\nExample:\n    ```python\n    response = GetHistoryResponse(\n        session_id=\"ses_abc123\",\n        messages=[...],\n        total_messages=50,\n        returned_messages=20,\n        has_more=True\n    )\n    ```"},"GetMigrationResponse":{"properties":{"migration_id":{"type":"string","title":"Migration Id","description":"Migration ID"},"internal_id":{"type":"string","title":"Internal Id","description":"Organization internal ID"},"namespace_id":{"type":"string","title":"Namespace Id","description":"Source namespace ID"},"config":{"$ref":"#/components/schemas/MigrationConfig","description":"Migration configuration"},"status":{"$ref":"#/components/schemas/MigrationStatus","description":"Current status"},"progress":{"$ref":"#/components/schemas/MigrationProgress","description":"Progress tracking"},"validation_result":{"anyOf":[{"$ref":"#/components/schemas/ValidationResult"},{"type":"null"}],"description":"Validation result"},"dependency_graph":{"anyOf":[{"$ref":"#/components/schemas/DependencyGraph"},{"type":"null"}],"description":"Dependency graph"},"task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id","description":"Task ID for tracking migration progress"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At","description":"Start timestamp"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"Completion timestamp"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Error if failed"},"additional_data":{"additionalProperties":true,"type":"object","title":"Additional Data","description":"Additional metadata"}},"type":"object","required":["migration_id","internal_id","namespace_id","config","status","progress","created_at"],"title":"GetMigrationResponse","description":"Response for getting migration details."},"GetPaymentMethodResponse":{"properties":{"has_payment_method":{"type":"boolean","title":"Has Payment Method","description":"Whether organization has a payment method saved"},"payment_method":{"anyOf":[{"$ref":"#/components/schemas/PaymentMethodInfo"},{"type":"null"}],"description":"Payment method details (null if none saved)"},"auto_billing_enabled":{"type":"boolean","title":"Auto Billing Enabled","description":"Whether automatic billing is enabled"}},"type":"object","required":["has_payment_method","auto_billing_enabled"],"title":"GetPaymentMethodResponse","description":"Response with current payment method."},"GetSessionResponse":{"properties":{"session_id":{"type":"string","title":"Session Id","description":"Session identifier"},"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace identifier"},"internal_id":{"type":"string","title":"Internal Id","description":"Organization internal ID"},"user_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id","description":"User identifier"},"session_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Name","description":"Auto-generated session name based on first conversation"},"agent_config":{"$ref":"#/components/schemas/AgentConfig","description":"Agent configuration"},"user_memory":{"additionalProperties":true,"type":"object","title":"User Memory","description":"User memory/preferences"},"status":{"$ref":"#/components/schemas/SessionStatus","description":"Session status"},"message_count":{"type":"integer","title":"Message Count","description":"Total messages in session"},"stats":{"$ref":"#/components/schemas/SessionStats","description":"Session statistics"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"},"last_activity_at":{"type":"string","format":"date-time","title":"Last Activity At","description":"Last activity timestamp"},"expires_at":{"type":"string","format":"date-time","title":"Expires At","description":"Expiration timestamp"}},"type":"object","required":["session_id","namespace_id","internal_id","agent_config","status","message_count","stats","created_at","updated_at","last_activity_at","expires_at"],"title":"GetSessionResponse","description":"Response for retrieving session metadata.\n\nAttributes:\n    session_id: Session identifier\n    namespace_id: Namespace identifier\n    internal_id: Organization internal ID\n    user_id: Optional user identifier\n    session_name: Auto-generated session name (null until first message)\n    agent_config: Agent configuration\n    user_memory: User memory/preferences\n    status: Session status\n    message_count: Total messages in session\n    stats: Session statistics\n    created_at: Creation timestamp\n    updated_at: Last update timestamp\n    last_activity_at: Last activity timestamp\n    expires_at: Expiration timestamp\n\nExample:\n    ```python\n    response = GetSessionResponse(\n        session_id=\"ses_abc123\",\n        namespace_id=\"ns_xyz789\",\n        internal_id=\"int_abc123\",\n        session_name=\"Video search for ML tutorials\",\n        agent_config=AgentConfig(...),\n        status=\"active\",\n        message_count=10,\n        stats=SessionStats(...)\n    )\n    ```"},"GoogleDriveConfig":{"properties":{"provider_type":{"type":"string","const":"google_drive","title":"Provider Type","default":"google_drive"},"credentials":{"oneOf":[{"$ref":"#/components/schemas/GoogleDriveServiceAccountCredentials"},{"$ref":"#/components/schemas/GoogleDriveOAuthCredentials"}],"title":"Credentials","description":"REQUIRED. Authentication credentials for Google Drive API access. Choose service_account for production (recommended) or oauth for personal access. The 'type' field determines which credential type is used.","discriminator":{"propertyName":"type","mapping":{"oauth":"#/components/schemas/GoogleDriveOAuthCredentials","service_account":"#/components/schemas/GoogleDriveServiceAccountCredentials"}}},"shared_drive_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Shared Drive Id","description":"NOT REQUIRED. Google Workspace shared drive (Team Drive) identifier. When provided, sync operations are scoped to this shared drive only. When omitted, syncs from 'My Drive' of the authenticated account. Find ID: Open shared drive in browser, copy ID from URL. Format: 0A{alphanumeric-string}","examples":["0AH-Xabc123def456","0ABcDeFgHiJkLmNoPqR"]},"impersonate_user":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Impersonate User","description":"NOT REQUIRED. Email address to impersonate when using service account credentials. Requires domain-wide delegation to be enabled for the service account. Used in G Suite environments to access files as a specific user. When omitted, uses the service account's own access. Format: Valid email address in the G Suite domain.","examples":["user@example.com","admin@company.com"]}},"type":"object","required":["credentials"],"title":"GoogleDriveConfig","description":"Google Drive and Google Workspace shared drive configuration.\n\nThis configuration enables Mixpeek to connect to Google Drive for automated\nfile ingestion and synchronization. Supports both personal Drive and Google\nWorkspace shared drives (formerly Team Drives).\n\nAuthentication Options:\n    - Service Account: Recommended for production. No user interaction required.\n    - OAuth2: Suitable for personal Drive access or development.\n\nRequirements:\n    - Google Drive API enabled in Google Cloud Console\n    - Appropriate authentication credentials configured\n    - Files/folders shared with the service account or OAuth user\n    - Network connectivity to drive.googleapis.com\n\nUse Cases:\n    - Sync marketing materials from shared drives\n    - Ingest documents from team collaboration folders\n    - Monitor and process uploaded media files\n    - Archive and search historical documents","examples":[{"credentials":{"client_email":"sync@mixpeek-prod-456.iam.gserviceaccount.com","client_id":"123456789012345678901","private_key":"-----BEGIN PRIVATE KEY-----\n...\n-----END PRIVATE KEY-----\n","private_key_id":"a1b2c3d4e5f6...","project_id":"mixpeek-prod-456","type":"service_account"},"description":"Service account accessing shared drive","provider_type":"google_drive","shared_drive_id":"0AH-Xabc123def456"},{"credentials":{"client_id":"123456789012-abc.apps.googleusercontent.com","client_secret":"GOCSPX-abc123def456","refresh_token":"1//0abc123def456...","type":"oauth"},"description":"OAuth accessing personal Drive","provider_type":"google_drive"},{"credentials":{"client_email":"sync@enterprise-sync.iam.gserviceaccount.com","client_id":"987654321098765432109","private_key":"-----BEGIN PRIVATE KEY-----\n...\n-----END PRIVATE KEY-----\n","private_key_id":"xyz789...","project_id":"enterprise-sync","type":"service_account"},"description":"Service account with domain-wide delegation","impersonate_user":"admin@company.com","provider_type":"google_drive"}]},"GoogleDriveOAuthCredentials":{"properties":{"type":{"type":"string","const":"oauth","title":"Type","default":"oauth"},"client_id":{"type":"string","title":"Client Id","description":"REQUIRED. OAuth 2.0 client ID from Google Cloud Console. Found in the API credentials section. Format: {id}.apps.googleusercontent.com","examples":["123456789012-abcdefghijklmnop.apps.googleusercontent.com"]},"client_secret":{"type":"string","title":"Client Secret","description":"REQUIRED. OAuth 2.0 client secret from Google Cloud Console. SECURITY: This is a secret credential, redacted on read. Never log or expose this value. Format: Alphanumeric string from Google Cloud Console.","examples":["GOCSPX-abc123def456ghi789jkl012"]},"refresh_token":{"type":"string","title":"Refresh Token","description":"REQUIRED. Long-lived refresh token obtained during OAuth consent flow. Used to automatically obtain new access tokens without user interaction. SECURITY: Encrypted at rest. Can be revoked by user at any time. Obtain via: Complete OAuth flow with drive.readonly or drive scope."}},"type":"object","required":["client_id","client_secret","refresh_token"],"title":"GoogleDriveOAuthCredentials","description":"Credentials for Google Drive OAuth2 user authentication.\n\nOAuth2 credentials provide access to Google Drive on behalf of a specific user.\nThis authentication method is suitable when accessing personal Drive files or\nwhen service account delegation is not available.\n\nPrerequisites:\n    - Create OAuth 2.0 credentials in Google Cloud Console\n    - Configure authorized redirect URIs\n    - Complete OAuth consent flow to obtain refresh token\n    - Ensure appropriate OAuth scopes are granted (drive.readonly or drive)\n\nSecurity:\n    - client_secret and refresh_token are secret credentials, redacted on read\n    - Access tokens are automatically refreshed and cached temporarily\n    - Credentials are scoped to the user who granted consent\n\nUse Cases:\n    - Personal Drive file access for individual users\n    - Prototyping and development without service account setup\n    - Environments where service account delegation is not feasible\n\nLimitations:\n    - Requires user interaction during initial setup\n    - Access is limited to files the consenting user can access\n    - Refresh tokens can be revoked by the user"},"GoogleDriveServiceAccountCredentials":{"properties":{"type":{"type":"string","const":"service_account","title":"Type","default":"service_account"},"project_id":{"type":"string","title":"Project Id","description":"REQUIRED. Google Cloud project ID where the service account was created. Found in the JSON key file as 'project_id'. Format: lowercase alphanumeric with hyphens (e.g., 'my-project-123').","examples":["mixpeek-prod-456","customer-ingestion"]},"private_key_id":{"type":"string","title":"Private Key Id","description":"REQUIRED. Unique identifier for the private key. Found in the JSON key file as 'private_key_id'. Format: 40-character hexadecimal string.","examples":["a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6q7r8s9t0"]},"private_key":{"type":"string","title":"Private Key","description":"REQUIRED. PEM-encoded RSA private key for authentication. Found in the JSON key file as 'private_key'. SECURITY: This is a secret credential, redacted on read. Never log or expose this value. Format: Must include BEGIN/END PRIVATE KEY markers."},"client_email":{"type":"string","title":"Client Email","description":"REQUIRED. Service account email address. Found in the JSON key file as 'client_email'. Share Drive files/folders with this email to grant access. Format: {account-name}@{project-id}.iam.gserviceaccount.com","examples":["mixpeek-sync@my-project-123.iam.gserviceaccount.com","ingestion@customer-project.iam.gserviceaccount.com"]},"client_id":{"type":"string","title":"Client Id","description":"REQUIRED. Numeric service account identifier. Found in the JSON key file as 'client_id'. Format: 21-digit numeric string.","examples":["123456789012345678901"]}},"type":"object","required":["project_id","private_key_id","private_key","client_email","client_id"],"title":"GoogleDriveServiceAccountCredentials","description":"Credentials for Google Drive service account authentication.\n\nService accounts provide server-to-server authentication for Google Drive\nwithout requiring user interaction. They are ideal for automated sync operations.\n\nPrerequisites:\n    - Create a service account in Google Cloud Console\n    - Enable Google Drive API for the project\n    - Download the JSON key file\n    - Share target Drive files/folders with the service account email\n\nSecurity:\n    - private_key is a secret credential, redacted on read\n    - Credentials never appear in logs or API responses\n    - Use domain-wide delegation for G Suite environments\n\nUse Cases:\n    - Automated ingestion pipelines from shared drives\n    - Scheduled sync operations without user interaction\n    - Service-to-service integration for enterprise deployments"},"GoogleModel":{"type":"string","enum":["gemini-2.5-flash-lite","gemini-2.5-flash","gemini-2.5-pro","gemini-3.1-flash-lite","gemini-3.5-flash-lite"],"title":"GoogleModel","description":"Google Gemini model identifiers for LLM generation.\n\nGemini models excel at multimodal understanding with best-in-class video support.\nAll models support text, images, video, audio, and PDFs.\n\nValues:\n    GEMINI_3_5_FLASH_LITE: Gemini 3.5 Flash Lite model (recommended, the default)\n        - Use for: Fastest generation, cost-effective multimodal\n        - Context: 1M tokens\n        - Multimodal: Text, images, video, audio, PDFs\n        - When to use: Default choice for all Gemini use cases\n\n    GEMINI_2_5_FLASH_LITE: Gemini 2.5 Flash Lite model\n        - Kept so stored configs that name it still validate. The Gemini\n          developer API no longer serves it to new keys; Vertex does.\n\n    GEMINI_2_5_PRO: Gemini 2.5 Pro model\n        - Use for: Higher quality reasoning, complex tasks\n        - Context: 1M tokens\n\n    GEMINI_2_5_FLASH: Gemini 2.5 Flash model\n        - Kept for backward compatibility.\n\n    GEMINI_3_1_FLASH_LITE: Gemini 3.1 Flash-Lite model\n        - Use for: Fast, low-cost generation on the 3.1 generation"},"GroundTruthQuery":{"properties":{"query_id":{"type":"string","title":"Query Id","description":"Unique identifier for this query within the dataset"},"query_input":{"additionalProperties":true,"type":"object","title":"Query Input","description":"Query input in the same format as retriever execution (e.g., {'text': '...'})"},"relevant_documents":{"items":{"type":"string"},"type":"array","title":"Relevant Documents","description":"Document ids relevant to this query, or values of the dataset's relevance_field when it is set"},"relevance_scores":{"anyOf":[{"additionalProperties":{"type":"integer"},"type":"object"},{"type":"null"}],"title":"Relevance Scores","description":"Optional graded relevance scores (doc_id -> score, 0-5 where 5 is most relevant). Used for NDCG calculation."}},"type":"object","required":["query_id","query_input","relevant_documents"],"title":"GroundTruthQuery","description":"Single query with ground truth relevance labels.\n\nThis represents one query in an evaluation dataset, along with the list\nof documents that are considered relevant for that query."},"GroupByField":{"properties":{"field":{"type":"string","title":"Field","description":"The field path to group by. Supports dot notation for nested fields (e.g., 'metadata.category'). For date fields, can be combined with date_trunc or date_part.","examples":["metadata.category","status","created_at","metadata.user_id"]},"alias":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Alias","description":"Optional alias for the grouped field in results. If not provided, uses the field name. Useful for nested fields to create simpler result names.","examples":["category","upload_date","user"]},"date_trunc":{"anyOf":[{"$ref":"#/components/schemas/DateTruncUnit"},{"type":"null"}],"description":"Truncate date field to specified unit. REQUIRED when grouping by date/time periods. Only valid for date/datetime fields. Cannot be used with date_part.","examples":["day","month","hour"]},"date_part":{"anyOf":[{"$ref":"#/components/schemas/DatePartUnit"},{"type":"null"}],"description":"Extract specific part from date field. OPTIONAL for analyzing date patterns. Only valid for date/datetime fields. Cannot be used with date_trunc.","examples":["hour","dayOfWeek","month"]}},"type":"object","required":["field"],"title":"GroupByField","description":"Configuration for grouping by a field.\n\nDefines how to group data by a specific field, with optional transformations.\n\nRequirements:\n    - field: REQUIRED, the field to group by\n    - alias: OPTIONAL, name for the grouped field in results\n    - date_trunc: OPTIONAL, truncate date fields to time periods\n    - date_part: OPTIONAL, extract part of date field\n\nExamples:\n    - Simple grouping: GroupByField(field=\"metadata.category\")\n    - Daily grouping: GroupByField(field=\"created_at\", date_trunc=DateTruncUnit.DAY)\n    - Hour of day: GroupByField(field=\"created_at\", date_part=DatePartUnit.HOUR)","examples":[{"alias":"category","description":"Group by category","field":"metadata.category"},{"alias":"date","date_trunc":"day","description":"Group by day","field":"created_at"},{"alias":"hour","date_part":"hour","description":"Group by hour of day","field":"created_at"}]},"GrowthMetric":{"properties":{"time_bucket":{"type":"string","format":"date-time","title":"Time Bucket"},"documents_added":{"type":"integer","title":"Documents Added"},"success_rate":{"type":"number","title":"Success Rate"},"avg_latency_ms":{"type":"number","title":"Avg Latency Ms"}},"type":"object","required":["time_bucket","documents_added","success_rate","avg_latency_ms"],"title":"GrowthMetric","description":"Document growth metric."},"GrowthMetricsResponse":{"properties":{"collection_id":{"type":"string","title":"Collection Id"},"time_range":{"$ref":"#/components/schemas/api__analytics__collections__models__TimeRange"},"metrics":{"items":{"$ref":"#/components/schemas/GrowthMetric"},"type":"array","title":"Metrics"},"summary":{"additionalProperties":true,"type":"object","title":"Summary"}},"type":"object","required":["collection_id","time_range","metrics"],"title":"GrowthMetricsResponse","description":"Document growth trends."},"HDBSCANParams":{"properties":{"min_cluster_size":{"type":"integer","minimum":2.0,"title":"Min Cluster Size","description":"Minimum number of samples in a cluster","default":5},"min_samples":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Min Samples","description":"Number of samples in a neighborhood for a point to be considered a core point. Defaults to min_cluster_size if None"},"cluster_selection_epsilon":{"type":"number","minimum":0.0,"title":"Cluster Selection Epsilon","description":"A distance threshold for cluster selection. Clusters below this value will be merged","default":0.0},"max_cluster_size":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Max Cluster Size","description":"Maximum number of samples in a cluster. Clusters above this size will be split"},"metric":{"type":"string","title":"Metric","description":"Metric to use for distance computation","default":"euclidean"},"alpha":{"type":"number","exclusiveMinimum":0.0,"title":"Alpha","description":"A distance scaling parameter","default":1.0},"cluster_selection_method":{"type":"string","title":"Cluster Selection Method","description":"Method to select clusters from the condensed tree ('eom' or 'leaf')","default":"eom"},"allow_single_cluster":{"type":"boolean","title":"Allow Single Cluster","description":"Allow HDBSCAN to find only a single cluster","default":false},"prediction_data":{"type":"boolean","title":"Prediction Data","description":"Whether to generate extra data for predicting cluster membership","default":false},"match_reference_implementation":{"type":"boolean","title":"Match Reference Implementation","description":"Whether to match the reference implementation exactly","default":false}},"type":"object","title":"HDBSCANParams","description":"Parameters for HDBSCAN clustering algorithm."},"HTTPAPIConfig":{"properties":{"provider_type":{"type":"string","const":"http_api","title":"Provider Type","default":"http_api"},"credentials":{"anyOf":[{"$ref":"#/components/schemas/HTTPAPIHeaderCredentials"},{"type":"null"}],"description":"Optional HTTP headers for authenticated API endpoints."},"http_method":{"type":"string","enum":["GET","POST"],"title":"Http Method","description":"HTTP method to use when calling the API.","default":"GET"},"request_body":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Request Body","description":"Optional JSON body for POST requests."},"items_path":{"type":"string","title":"Items Path","description":"Dot-notation path to the array of items in the JSON response. Examples: 'hits' for {hits: [...]}, 'data.items' for {data: {items: [...]}}. Leave empty if the response is a top-level array.","default":""},"item_id_field":{"type":"string","title":"Item Id Field","description":"Defaults to 'id', as the sync does. Field name in each item used as a unique ID for deduplication. Examples: 'id', 'objectID', 'uuid'.","default":"id"},"item_modified_field":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Item Modified Field","description":"Optional field name for a timestamp used for incremental sync. Supports ISO 8601 strings and Unix timestamps. Examples: 'updated_at', 'created_at', 'modified'."},"response_content_type":{"type":"string","enum":["json","jsonl"],"title":"Response Content Type","description":"Response format: 'json' (default) or 'jsonl' (newline-delimited JSON).","default":"json"},"user_agent":{"type":"string","title":"User Agent","description":"User-Agent header for API requests.","default":"Mixpeek HTTP API Sync/1.0"},"request_timeout":{"type":"integer","maximum":120.0,"minimum":5.0,"title":"Request Timeout","description":"HTTP request timeout in seconds.","default":30}},"type":"object","title":"HTTPAPIConfig","description":"REST/HTTP JSON API configuration. source_path = API URL.\n\nEnables Mixpeek to sync items from any JSON REST API endpoint.\nEach item in the API response becomes a bucket object with its\nJSON body stored as the blob.\n\nAuthentication:\n    - Optional HTTP headers (API keys, Bearer tokens, etc.)\n\nRequirements:\n    - API must return JSON (or JSONL) response\n    - Response must contain an array of items (at root or nested path)\n    - Each item must have a unique ID field for deduplication\n\nUse Cases:\n    - Sync data from public APIs (Hacker News, GitHub, etc.)\n    - Ingest records from internal REST services\n    - Poll third-party APIs (Stripe, Shopify, etc.)\n    - Monitor any JSON endpoint for new items","examples":[{"description":"Public API (Hacker News Algolia)","item_id_field":"objectID","item_modified_field":"created_at_i","items_path":"hits","provider_type":"http_api","request_timeout":30},{"credentials":{"headers":{"Authorization":"Bearer your-api-key"},"type":"http_headers"},"description":"Authenticated API with Bearer token","item_id_field":"id","item_modified_field":"updated_at","items_path":"data","provider_type":"http_api"},{"description":"POST API with request body","http_method":"POST","item_id_field":"id","items_path":"results","provider_type":"http_api","request_body":{"limit":10,"query":"mixpeek"}},{"description":"JSONL endpoint","item_id_field":"id","items_path":"","provider_type":"http_api","response_content_type":"jsonl"}]},"HTTPAPIHeaderCredentials":{"properties":{"type":{"type":"string","const":"http_headers","title":"Type","default":"http_headers"},"headers":{"additionalProperties":{"type":"string"},"type":"object","title":"Headers","description":"HTTP headers for API requests (e.g., Authorization, X-API-Key)."}},"type":"object","title":"HTTPAPIHeaderCredentials","description":"Optional HTTP credentials for HTTP API endpoints.\n\nSupports arbitrary headers for authentication (API keys, Bearer tokens, etc.).\nSame pattern as RSS credentials but for REST API endpoints.\n\nSecurity:\n    - Header values containing secrets are redacted on read\n    - Common patterns: Authorization: Bearer <token>, X-API-Key: <key>"},"HavingCondition":{"properties":{"field":{"type":"string","title":"Field","description":"The aggregated field to filter on. REQUIRED, must match an aggregation operation alias. Used after aggregation to filter groups. Not a source field, but a computed field.","examples":["total_count","avg_duration","total_views"]},"operator":{"type":"string","title":"Operator","description":"Comparison operator. REQUIRED, valid operators: gt (greater than), gte (greater than or equal), lt (less than), lte (less than or equal), eq (equal), ne (not equal).","examples":["gt","gte","lt","lte","eq","ne"]},"value":{"anyOf":[{"type":"integer"},{"type":"number"},{"type":"string"}],"title":"Value","description":"Value to compare against. REQUIRED, type should match aggregation result type. Numeric for COUNT/SUM/AVG, string for grouped values.","examples":[100,60.0,"active"]}},"type":"object","required":["field","operator","value"],"title":"HavingCondition","description":"Filtering condition for aggregated results.\n\nFilters groups after aggregation (like SQL HAVING clause).\n\nRequirements:\n    - field: REQUIRED, the aggregation alias to filter on\n    - operator: REQUIRED, comparison operator\n    - value: REQUIRED, value to compare against\n\nExamples:\n    - Keep high-count groups: HavingCondition(field=\"total_count\", operator=\"gt\", value=100)\n    - Filter by average: HavingCondition(field=\"avg_duration\", operator=\"gte\", value=60)","examples":[{"description":"Groups with more than 100 items","field":"total_count","operator":"gt","value":100},{"description":"Average duration at least 60 seconds","field":"avg_duration","operator":"gte","value":60}]},"HealthCheck":{"properties":{"status":{"$ref":"#/components/schemas/HealthStatus-Input","description":"Current health status","default":"healthy"},"last_check":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Check","description":"When the health was last checked"},"issues":{"items":{"type":"string"},"type":"array","title":"Issues","description":"List of current issues if any"}},"type":"object","title":"HealthCheck","description":"Health check information for a retriever."},"HealthCheckResponse":{"properties":{"status":{"$ref":"#/components/schemas/HealthStatus-Output","description":"Overall API health status"},"data":{"$ref":"#/components/schemas/HealthServiceStatus","description":"Per-service health status flags"},"errors":{"anyOf":[{"$ref":"#/components/schemas/HealthServiceErrors"},{"type":"null"}],"description":"Optional per-service error messages when a service check fails"},"meta":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Meta","description":"Optional metadata such as configured object storage bucket/region/endpoint, API URL, and deployment health details (when deep=True)"}},"type":"object","required":["status","data"],"title":"HealthCheckResponse","description":"Health check response model."},"HealthServiceErrors":{"properties":{"cache":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cache","description":"Cache layer error message, if any"},"metadata":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Metadata","description":"Metadata store error message, if any"},"vector_store":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vector Store","description":"Vector database error message, if any"},"object_storage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Object Storage","description":"Object storage error message, if any"},"task_queue":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Queue","description":"Task queue error message, if any"},"inference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inference","description":"Inference engine error message, if any"},"analytics":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Analytics","description":"Analytics backend error message, if any"}},"type":"object","title":"HealthServiceErrors","description":"Optional error messages for dependent services (present when a check fails)."},"HealthServiceStatus":{"properties":{"cache":{"type":"boolean","title":"Cache","description":"Cache layer connectivity successful","examples":[true]},"metadata":{"type":"boolean","title":"Metadata","description":"Metadata store connectivity successful","examples":[true]},"vector_store":{"type":"boolean","title":"Vector Store","description":"Vector database connectivity successful","examples":[true]},"object_storage":{"type":"boolean","title":"Object Storage","description":"Object storage connectivity successful","examples":[true]},"task_queue":{"type":"boolean","title":"Task Queue","description":"Task queue execution successful","examples":[true]},"inference":{"type":"boolean","title":"Inference","description":"Inference engine health check successful","examples":[true]},"analytics":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Analytics","description":"Analytics backend healthy (optional, None if disabled)","examples":[true,null]}},"type":"object","required":["cache","metadata","vector_store","object_storage","task_queue","inference"],"title":"HealthServiceStatus","description":"Status flags for dependent services."},"HealthStatus-Input":{"type":"string","enum":["healthy","degraded","unhealthy"],"title":"HealthStatus","description":"Health status of a retriever."},"HealthStatus-Output":{"type":"string","enum":["OK","DEGRADED"],"title":"HealthStatus","description":"Overall health status."},"HeroConfig":{"properties":{"headline":{"type":"string","title":"Headline","description":"Main headline text"},"subheadline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subheadline","description":"Optional subheadline text"},"background_type":{"type":"string","enum":["image","video","gradient","solid"],"title":"Background Type","description":"Background type","default":"solid"},"background_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Background Url","description":"URL for image or video background"},"background_color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Background Color","description":"Background color for solid/gradient"},"text_color":{"type":"string","title":"Text Color","description":"Hero text color","default":"#FFFFFF"},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url","description":"Logo URL displayed in hero"},"height":{"type":"string","title":"Height","description":"Hero section height","default":"420px"},"cta_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cta Label","description":"Call-to-action button label"},"cta_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cta Url","description":"Call-to-action button URL"}},"type":"object","required":["headline"],"title":"HeroConfig","description":"Hero section configuration for a page."},"HierarchicalEnrichmentStyle":{"type":"string","enum":["full_chain","best_match","combined"],"title":"HierarchicalEnrichmentStyle","description":"How hierarchical taxonomy results should be structured in enriched documents.\n\nControls the field naming pattern for multi-tier taxonomy enrichment."},"HierarchicalNode-Input":{"properties":{"collection_id":{"type":"string","pattern":"^col_[a-zA-Z0-9_]+$","title":"Collection Id","description":"REQUIRED. Collection ID representing this node in the hierarchy. Must reference an existing collection containing documents for this hierarchy level. Format: 'col_' prefix followed by alphanumeric/underscore characters. Used to: Match documents against this level, identify node in path, store enrichment data. Example: 'col_executives' for executive level, 'col_products_phones' for phones category.","examples":["col_executives","col_managers","col_employees","col_products_phones","col_electronics"]},"parent_collection_id":{"anyOf":[{"type":"string","pattern":"^col_[a-zA-Z0-9_]+$"},{"type":"null"}],"title":"Parent Collection Id","description":"OPTIONAL. Collection ID of the parent node in the hierarchy. When None: This is a root node (top of hierarchy). When set: References parent node's collection_id, creating parent-child relationship. Format: Same as collection_id ('col_' prefix). Used to: Build hierarchy tree, determine inheritance order, construct path arrays. Example: 'col_managers' is parent of 'col_executives', 'col_products' is parent of 'col_electronics'. Validation: Must reference a valid collection_id from another node in same taxonomy.","examples":["col_employees","col_managers","col_products",null]},"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label","description":"OPTIONAL. Human-readable display name for this hierarchy node. Used in UI, visualizations, and taxonomy assignment results. NOT REQUIRED - When None: collection name or auto-generated label may be used. Format: Free text, typically title case, 2-50 characters. Examples: 'Executive Leadership', 'Mobile Phones', 'Engineering Team'. Can be LLM-generated or manually specified during taxonomy creation.","examples":["Executive Leadership","Management Team","All Employees","Mobile Phones","Electronics",null]},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary","description":"OPTIONAL. Brief description of this hierarchy level and its contents. Used for: Documentation, UI tooltips, understanding hierarchy structure. NOT REQUIRED - When None: no summary available for this node. Format: Free text, typically 1-3 sentences, up to 500 characters. Can be LLM-generated or manually provided.","examples":["Top-level executives with strategic decision-making authority","Mid-level managers overseeing teams and projects","High-end smartphones with premium features",null]},"keywords":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Keywords","description":"OPTIONAL. Keywords or tags describing this hierarchy level. Used for: Search, filtering, categorization, LLM understanding. NOT REQUIRED - When None: no keywords defined for this node. Format: List of strings, typically 3-10 keywords per node. Can be LLM-generated from collection contents or manually specified.","examples":[["executive","leadership","C-suite","strategic"],["manager","supervisor","team-lead"],["smartphone","mobile","premium","flagship"],null]},"retriever_id":{"anyOf":[{"type":"string","pattern":"^ret_[a-zA-Z0-9_]+$"},{"type":"null"}],"title":"Retriever Id","description":"OPTIONAL. Retriever to use for matching documents at this hierarchy level. When None: Uses taxonomy-level retriever_id (inheritance from parent config). When set: Overrides taxonomy-level retriever for this specific node. Format: 'ret_' prefix followed by alphanumeric characters. Use for: Specialized matching at certain levels (e.g., face recognition for employees, semantic search for products). Must reference an existing RetrieverModel.","examples":["ret_face_recognition","ret_clip_products","ret_text_semantic",null]},"enrichment_fields":{"anyOf":[{"items":{"$ref":"#/components/schemas/EnrichmentField"},"type":"array"},{"type":"null"}],"title":"Enrichment Fields","description":"OPTIONAL. Fields to enrich into documents when they match this hierarchy level. Specifies which properties from node collection to copy to matched documents. When None: No field-level enrichment (only taxonomy assignment recorded). Format: List of EnrichmentField objects with field_path and merge_mode. Inheritance: Child nodes inherit all parent enrichment_fields plus their own. Example: executives node adds 'executive_level' on top of inherited 'employee_id', 'department'.","examples":[[{"field_path":"executive_level","merge_mode":"replace"},{"field_path":"budget_authority","merge_mode":"replace"}],[{"field_path":"product_category","merge_mode":"replace"},{"field_path":"tags","merge_mode":"append"}],null]},"input_mappings":{"anyOf":[{"items":{"$ref":"#/components/schemas/InputMapping"},"type":"array"},{"type":"null"}],"title":"Input Mappings","description":"OPTIONAL. Custom input mappings for the retriever at this hierarchy level. Specifies how to construct retriever inputs from document features. When None: Uses taxonomy-level input_mappings (inheritance). When set: Overrides taxonomy-level mappings for this specific node. Format: List of InputMapping objects specifying input_key, source_type, path. Use for: Different matching strategies at different levels (e.g., face at employee level, text at department level).","examples":[[{"input_key":"face_embedding","path":"features.face","source_type":"vector"}],[{"input_key":"text","path":"description","source_type":"payload"}],null]}},"type":"object","required":["collection_id"],"title":"HierarchicalNode","description":"A node in a hierarchical taxonomy representing one level in the tree structure.\n\nEach node represents a collection containing documents at a specific hierarchy level.\nNodes form parent-child relationships to create multi-level taxonomies with\nproperty inheritance. When a document matches a child node, it inherits all\nproperties from parent nodes up to the root.\n\nUse Cases:\n    - Define organizational hierarchies: employees → managers → executives\n    - Create product categorizations: products → electronics → phones → smartphones\n    - Build classification trees: industries → technology → software\n    - Implement face recognition hierarchies: people → employees → team members\n    - Enable property inheritance: child nodes get all parent properties\n\nHierarchy Behavior:\n    - Root nodes: parent_collection_id = None (top of hierarchy)\n    - Child nodes: parent_collection_id references parent node's collection_id\n    - Property inheritance: Children inherit all parent enrichment_fields\n    - Path construction: Creates path array from root to leaf\n    - Multi-level matching: Documents matched at deepest applicable level\n\nConfiguration:\n    - Per-node retrievers: Override taxonomy-level retriever for specific nodes\n    - Per-node enrichment: Override which fields to enrich at each level\n    - Per-node input mappings: Customize retriever inputs per hierarchy level\n    - Labels/summaries: Human-readable metadata for UI display\n\nRelated Models:\n    - HierarchicalTaxonomyConfig: Contains list of hierarchical nodes\n    - TaxonomyAssignment: Result of matching documents to nodes\n    - EnrichmentField: Specifies which fields to enrich from node\n\nRequirements:\n    - collection_id: REQUIRED - must reference an existing collection\n    - parent_collection_id: REQUIRED for non-root nodes (None for root)\n    - All other fields: OPTIONAL with inheritance from taxonomy-level config","examples":[{"collection_id":"col_employees","description":"Root node - All employees (no parent)","enrichment_fields":[{"field_path":"employee_id","merge_mode":"replace"},{"field_path":"department","merge_mode":"replace"}],"input_mappings":[{"input_key":"face_embedding","path":"features.face","source_type":"vector"}],"keywords":["employee","staff","personnel"],"label":"All Employees","retriever_id":"ret_face_recognition","summary":"Complete employee directory with basic information"},{"collection_id":"col_managers","description":"Mid-level node - Managers (child of employees)","enrichment_fields":[{"field_path":"team_size","merge_mode":"replace"},{"field_path":"reports_to","merge_mode":"replace"}],"keywords":["manager","supervisor","team-lead"],"label":"Management Team","parent_collection_id":"col_employees","summary":"Managers overseeing teams and projects"},{"collection_id":"col_executives","description":"Leaf node - Executives (child of managers)","enrichment_fields":[{"field_path":"executive_level","merge_mode":"replace"},{"field_path":"budget_authority","merge_mode":"replace"}],"keywords":["executive","leadership","C-suite"],"label":"Executive Leadership","parent_collection_id":"col_managers","summary":"C-suite and VP-level executives with strategic authority"},{"collection_id":"col_products","description":"Product hierarchy - Root category","enrichment_fields":[{"field_path":"product_id","merge_mode":"replace"},{"field_path":"tags","merge_mode":"append"}],"keywords":["product","catalog","inventory"],"label":"All Products","retriever_id":"ret_clip_products","summary":"Complete product catalog"},{"collection_id":"col_electronics","description":"Product hierarchy - Electronics category","enrichment_fields":[{"field_path":"warranty_years","merge_mode":"replace"}],"keywords":["electronics","devices","tech"],"label":"Electronics","parent_collection_id":"col_products","summary":"Electronic devices and accessories"},{"collection_id":"col_test_category","description":"Minimal node - Only required fields","parent_collection_id":"col_test_root"}]},"HierarchicalNode-Output":{"properties":{"collection_id":{"type":"string","pattern":"^col_[a-zA-Z0-9_]+$","title":"Collection Id","description":"REQUIRED. Collection ID representing this node in the hierarchy. Must reference an existing collection containing documents for this hierarchy level. Format: 'col_' prefix followed by alphanumeric/underscore characters. Used to: Match documents against this level, identify node in path, store enrichment data. Example: 'col_executives' for executive level, 'col_products_phones' for phones category.","examples":["col_executives","col_managers","col_employees","col_products_phones","col_electronics"]},"parent_collection_id":{"anyOf":[{"type":"string","pattern":"^col_[a-zA-Z0-9_]+$"},{"type":"null"}],"title":"Parent Collection Id","description":"OPTIONAL. Collection ID of the parent node in the hierarchy. When None: This is a root node (top of hierarchy). When set: References parent node's collection_id, creating parent-child relationship. Format: Same as collection_id ('col_' prefix). Used to: Build hierarchy tree, determine inheritance order, construct path arrays. Example: 'col_managers' is parent of 'col_executives', 'col_products' is parent of 'col_electronics'. Validation: Must reference a valid collection_id from another node in same taxonomy.","examples":["col_employees","col_managers","col_products",null]},"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label","description":"OPTIONAL. Human-readable display name for this hierarchy node. Used in UI, visualizations, and taxonomy assignment results. NOT REQUIRED - When None: collection name or auto-generated label may be used. Format: Free text, typically title case, 2-50 characters. Examples: 'Executive Leadership', 'Mobile Phones', 'Engineering Team'. Can be LLM-generated or manually specified during taxonomy creation.","examples":["Executive Leadership","Management Team","All Employees","Mobile Phones","Electronics",null]},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary","description":"OPTIONAL. Brief description of this hierarchy level and its contents. Used for: Documentation, UI tooltips, understanding hierarchy structure. NOT REQUIRED - When None: no summary available for this node. Format: Free text, typically 1-3 sentences, up to 500 characters. Can be LLM-generated or manually provided.","examples":["Top-level executives with strategic decision-making authority","Mid-level managers overseeing teams and projects","High-end smartphones with premium features",null]},"keywords":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Keywords","description":"OPTIONAL. Keywords or tags describing this hierarchy level. Used for: Search, filtering, categorization, LLM understanding. NOT REQUIRED - When None: no keywords defined for this node. Format: List of strings, typically 3-10 keywords per node. Can be LLM-generated from collection contents or manually specified.","examples":[["executive","leadership","C-suite","strategic"],["manager","supervisor","team-lead"],["smartphone","mobile","premium","flagship"],null]},"retriever_id":{"anyOf":[{"type":"string","pattern":"^ret_[a-zA-Z0-9_]+$"},{"type":"null"}],"title":"Retriever Id","description":"OPTIONAL. Retriever to use for matching documents at this hierarchy level. When None: Uses taxonomy-level retriever_id (inheritance from parent config). When set: Overrides taxonomy-level retriever for this specific node. Format: 'ret_' prefix followed by alphanumeric characters. Use for: Specialized matching at certain levels (e.g., face recognition for employees, semantic search for products). Must reference an existing RetrieverModel.","examples":["ret_face_recognition","ret_clip_products","ret_text_semantic",null]},"enrichment_fields":{"anyOf":[{"items":{"$ref":"#/components/schemas/EnrichmentField"},"type":"array"},{"type":"null"}],"title":"Enrichment Fields","description":"OPTIONAL. Fields to enrich into documents when they match this hierarchy level. Specifies which properties from node collection to copy to matched documents. When None: No field-level enrichment (only taxonomy assignment recorded). Format: List of EnrichmentField objects with field_path and merge_mode. Inheritance: Child nodes inherit all parent enrichment_fields plus their own. Example: executives node adds 'executive_level' on top of inherited 'employee_id', 'department'.","examples":[[{"field_path":"executive_level","merge_mode":"replace"},{"field_path":"budget_authority","merge_mode":"replace"}],[{"field_path":"product_category","merge_mode":"replace"},{"field_path":"tags","merge_mode":"append"}],null]},"input_mappings":{"anyOf":[{"items":{"$ref":"#/components/schemas/InputMapping"},"type":"array"},{"type":"null"}],"title":"Input Mappings","description":"OPTIONAL. Custom input mappings for the retriever at this hierarchy level. Specifies how to construct retriever inputs from document features. When None: Uses taxonomy-level input_mappings (inheritance). When set: Overrides taxonomy-level mappings for this specific node. Format: List of InputMapping objects specifying input_key, source_type, path. Use for: Different matching strategies at different levels (e.g., face at employee level, text at department level).","examples":[[{"input_key":"face_embedding","path":"features.face","source_type":"vector"}],[{"input_key":"text","path":"description","source_type":"payload"}],null]}},"type":"object","required":["collection_id"],"title":"HierarchicalNode","description":"A node in a hierarchical taxonomy representing one level in the tree structure.\n\nEach node represents a collection containing documents at a specific hierarchy level.\nNodes form parent-child relationships to create multi-level taxonomies with\nproperty inheritance. When a document matches a child node, it inherits all\nproperties from parent nodes up to the root.\n\nUse Cases:\n    - Define organizational hierarchies: employees → managers → executives\n    - Create product categorizations: products → electronics → phones → smartphones\n    - Build classification trees: industries → technology → software\n    - Implement face recognition hierarchies: people → employees → team members\n    - Enable property inheritance: child nodes get all parent properties\n\nHierarchy Behavior:\n    - Root nodes: parent_collection_id = None (top of hierarchy)\n    - Child nodes: parent_collection_id references parent node's collection_id\n    - Property inheritance: Children inherit all parent enrichment_fields\n    - Path construction: Creates path array from root to leaf\n    - Multi-level matching: Documents matched at deepest applicable level\n\nConfiguration:\n    - Per-node retrievers: Override taxonomy-level retriever for specific nodes\n    - Per-node enrichment: Override which fields to enrich at each level\n    - Per-node input mappings: Customize retriever inputs per hierarchy level\n    - Labels/summaries: Human-readable metadata for UI display\n\nRelated Models:\n    - HierarchicalTaxonomyConfig: Contains list of hierarchical nodes\n    - TaxonomyAssignment: Result of matching documents to nodes\n    - EnrichmentField: Specifies which fields to enrich from node\n\nRequirements:\n    - collection_id: REQUIRED - must reference an existing collection\n    - parent_collection_id: REQUIRED for non-root nodes (None for root)\n    - All other fields: OPTIONAL with inheritance from taxonomy-level config","examples":[{"collection_id":"col_employees","description":"Root node - All employees (no parent)","enrichment_fields":[{"field_path":"employee_id","merge_mode":"replace"},{"field_path":"department","merge_mode":"replace"}],"input_mappings":[{"input_key":"face_embedding","path":"features.face","source_type":"vector"}],"keywords":["employee","staff","personnel"],"label":"All Employees","retriever_id":"ret_face_recognition","summary":"Complete employee directory with basic information"},{"collection_id":"col_managers","description":"Mid-level node - Managers (child of employees)","enrichment_fields":[{"field_path":"team_size","merge_mode":"replace"},{"field_path":"reports_to","merge_mode":"replace"}],"keywords":["manager","supervisor","team-lead"],"label":"Management Team","parent_collection_id":"col_employees","summary":"Managers overseeing teams and projects"},{"collection_id":"col_executives","description":"Leaf node - Executives (child of managers)","enrichment_fields":[{"field_path":"executive_level","merge_mode":"replace"},{"field_path":"budget_authority","merge_mode":"replace"}],"keywords":["executive","leadership","C-suite"],"label":"Executive Leadership","parent_collection_id":"col_managers","summary":"C-suite and VP-level executives with strategic authority"},{"collection_id":"col_products","description":"Product hierarchy - Root category","enrichment_fields":[{"field_path":"product_id","merge_mode":"replace"},{"field_path":"tags","merge_mode":"append"}],"keywords":["product","catalog","inventory"],"label":"All Products","retriever_id":"ret_clip_products","summary":"Complete product catalog"},{"collection_id":"col_electronics","description":"Product hierarchy - Electronics category","enrichment_fields":[{"field_path":"warranty_years","merge_mode":"replace"}],"keywords":["electronics","devices","tech"],"label":"Electronics","parent_collection_id":"col_products","summary":"Electronic devices and accessories"},{"collection_id":"col_test_category","description":"Minimal node - Only required fields","parent_collection_id":"col_test_root"}]},"HierarchicalTaxonomyConfig-Input":{"properties":{"taxonomy_type":{"type":"string","const":"hierarchical","title":"Taxonomy Type","description":"Discriminator identifying this as a hierarchical taxonomy.","default":"hierarchical"},"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id","description":"Default retriever to use for all nodes unless overridden per-node."},"input_mappings":{"anyOf":[{"items":{"$ref":"#/components/schemas/InputMapping"},"type":"array"},{"type":"null"}],"title":"Input Mappings","description":"Default input mappings for all nodes unless overridden per-node."},"inference_strategy":{"anyOf":[{"$ref":"#/components/schemas/HierarchyInferenceStrategy"},{"type":"null"}],"description":"Strategy for inferring hierarchy structure from collections. Can be 'schema' (overlap-based), 'cluster' (clustering-based), or 'llm' (AI-based). When set, will infer relationships from inference_collections."},"inference_collections":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Inference Collections","description":"Collection IDs to use for hierarchy inference. The inference_strategy will analyze these collections to discover relationships. Can be combined with hierarchical_nodes for hybrid configuration."},"llm_provider":{"anyOf":[{"type":"string","const":"openai_chat_v1"},{"type":"null"}],"title":"Llm Provider","description":"LLM provider to use for hierarchy inference (default openai_chat_v1)"},"llm_model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Llm Model","description":"LLM model name (e.g., gpt-4o-mini)"},"llm_prompt_template":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Llm Prompt Template","description":"Optional prompt template. Variables available: {collection_id}, {collection_name}."},"llm_sample_size":{"type":"integer","title":"Llm Sample Size","description":"Optional number of sample docs to include in prompts (0 = disabled).","default":0},"cluster_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Cluster Ids","description":"Cluster IDs to use for CLUSTER inference strategy"},"cluster_overlap_threshold":{"type":"number","title":"Cluster Overlap Threshold","description":"Minimum overlap ratio to establish parent-child relationship between clusters","default":0.7},"hierarchical_nodes":{"anyOf":[{"items":{"$ref":"#/components/schemas/HierarchicalNode-Input"},"type":"array"},{"type":"null"}],"title":"Hierarchical Nodes","description":"Explicit node definitions that either: 1) Define the entire hierarchy (when inference_strategy is None), 2) Add additional nodes to an inferred hierarchy, or 3) Override specific relationships in an inferred hierarchy. Supports true hybrid: infer from some collections, manually add others."},"step_analytics":{"anyOf":[{"$ref":"#/components/schemas/StepAnalyticsConfig-Input"},{"type":"null"}],"description":"Optional configuration for step transition analytics. Enables tracking how documents progress through hierarchical taxonomy nodes over time (e.g., content workflow tracking from 'draft' to 'published'). If not provided, only basic assignment events are logged."},"path_field":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Path Field","description":"Build the hierarchy from a field each document already carries, instead of from node collections or inference. The field holds the document's path: a delimited string ('footage/2024/q3', split on path_separator) or a list of ancestor ids, root first (['col_a', 'col_b']). One node exists per distinct prefix, with its parent; a document is assigned the deepest node its path names and inherits the nodes above it. Dot paths reach nested fields ('metadata.folder'). Not combined with hierarchical_nodes or inference_strategy.","examples":["folder_path","iconik_collection_ids"]},"path_separator":{"type":"string","minLength":1,"title":"Path Separator","description":"Separator for a string path_field. Ignored for list values.","default":"/"}},"type":"object","title":"HierarchicalTaxonomyConfig","description":"Hybrid hierarchical taxonomy configuration supporting inference with manual additions.\n\nAll hierarchical taxonomies are hybrid:\n- Base hierarchy can be inferred via schema, clustering, or LLM\n- Additional collections can be explicitly added with specific retrievers\n- Supports mixing inference strategies with manual additions/overrides\n\nExamples:\n1. Pure inference: Set inference_strategy + inference_collections\n2. Pure manual: Set hierarchical_nodes only\n3. Hybrid: Set inference_strategy + inference_collections + hierarchical_nodes\n   (infers base from collections, adds/overrides with explicit nodes)","examples":[{"hierarchical_nodes":[{"collection_id":"col_employees_v1"},{"collection_id":"col_executives_v1","parent_collection_id":"col_employees_v1"}],"input_mappings":[{"input_key":"face_vec","path":"features.face","source_type":"vector"}],"retriever_id":"ret_face_v1","taxonomy_type":"hierarchical"},{"inference_collections":["col_people_v1","col_employees_v1","col_managers_v1"],"inference_strategy":"schema","input_mappings":[{"input_key":"face_vec","path":"features.face","source_type":"vector"}],"retriever_id":"ret_face_v1","taxonomy_type":"hierarchical"},{"hierarchical_nodes":[{"collection_id":"col_special_products","enrichment_fields":[{"field_path":"premium_tags","merge_mode":"append"}],"parent_collection_id":"col_products_v1","retriever_id":"ret_special_v1"}],"inference_collections":["col_products_v1","col_categories_v1"],"inference_strategy":"cluster","retriever_id":"ret_clip_v1","taxonomy_type":"hierarchical"}]},"HierarchicalTaxonomyConfig-Output":{"properties":{"taxonomy_type":{"type":"string","const":"hierarchical","title":"Taxonomy Type","description":"Discriminator identifying this as a hierarchical taxonomy.","default":"hierarchical"},"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id","description":"Default retriever to use for all nodes unless overridden per-node."},"input_mappings":{"anyOf":[{"items":{"$ref":"#/components/schemas/InputMapping"},"type":"array"},{"type":"null"}],"title":"Input Mappings","description":"Default input mappings for all nodes unless overridden per-node."},"inference_strategy":{"anyOf":[{"$ref":"#/components/schemas/HierarchyInferenceStrategy"},{"type":"null"}],"description":"Strategy for inferring hierarchy structure from collections. Can be 'schema' (overlap-based), 'cluster' (clustering-based), or 'llm' (AI-based). When set, will infer relationships from inference_collections."},"inference_collections":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Inference Collections","description":"Collection IDs to use for hierarchy inference. The inference_strategy will analyze these collections to discover relationships. Can be combined with hierarchical_nodes for hybrid configuration."},"llm_provider":{"anyOf":[{"type":"string","const":"openai_chat_v1"},{"type":"null"}],"title":"Llm Provider","description":"LLM provider to use for hierarchy inference (default openai_chat_v1)"},"llm_model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Llm Model","description":"LLM model name (e.g., gpt-4o-mini)"},"llm_prompt_template":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Llm Prompt Template","description":"Optional prompt template. Variables available: {collection_id}, {collection_name}."},"llm_sample_size":{"type":"integer","title":"Llm Sample Size","description":"Optional number of sample docs to include in prompts (0 = disabled).","default":0},"cluster_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Cluster Ids","description":"Cluster IDs to use for CLUSTER inference strategy"},"cluster_overlap_threshold":{"type":"number","title":"Cluster Overlap Threshold","description":"Minimum overlap ratio to establish parent-child relationship between clusters","default":0.7},"hierarchical_nodes":{"anyOf":[{"items":{"$ref":"#/components/schemas/HierarchicalNode-Output"},"type":"array"},{"type":"null"}],"title":"Hierarchical Nodes","description":"Explicit node definitions that either: 1) Define the entire hierarchy (when inference_strategy is None), 2) Add additional nodes to an inferred hierarchy, or 3) Override specific relationships in an inferred hierarchy. Supports true hybrid: infer from some collections, manually add others."},"step_analytics":{"anyOf":[{"$ref":"#/components/schemas/StepAnalyticsConfig-Output"},{"type":"null"}],"description":"Optional configuration for step transition analytics. Enables tracking how documents progress through hierarchical taxonomy nodes over time (e.g., content workflow tracking from 'draft' to 'published'). If not provided, only basic assignment events are logged."},"path_field":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Path Field","description":"Build the hierarchy from a field each document already carries, instead of from node collections or inference. The field holds the document's path: a delimited string ('footage/2024/q3', split on path_separator) or a list of ancestor ids, root first (['col_a', 'col_b']). One node exists per distinct prefix, with its parent; a document is assigned the deepest node its path names and inherits the nodes above it. Dot paths reach nested fields ('metadata.folder'). Not combined with hierarchical_nodes or inference_strategy.","examples":["folder_path","iconik_collection_ids"]},"path_separator":{"type":"string","minLength":1,"title":"Path Separator","description":"Separator for a string path_field. Ignored for list values.","default":"/"}},"type":"object","title":"HierarchicalTaxonomyConfig","description":"Hybrid hierarchical taxonomy configuration supporting inference with manual additions.\n\nAll hierarchical taxonomies are hybrid:\n- Base hierarchy can be inferred via schema, clustering, or LLM\n- Additional collections can be explicitly added with specific retrievers\n- Supports mixing inference strategies with manual additions/overrides\n\nExamples:\n1. Pure inference: Set inference_strategy + inference_collections\n2. Pure manual: Set hierarchical_nodes only\n3. Hybrid: Set inference_strategy + inference_collections + hierarchical_nodes\n   (infers base from collections, adds/overrides with explicit nodes)","examples":[{"hierarchical_nodes":[{"collection_id":"col_employees_v1"},{"collection_id":"col_executives_v1","parent_collection_id":"col_employees_v1"}],"input_mappings":[{"input_key":"face_vec","path":"features.face","source_type":"vector"}],"retriever_id":"ret_face_v1","taxonomy_type":"hierarchical"},{"inference_collections":["col_people_v1","col_employees_v1","col_managers_v1"],"inference_strategy":"schema","input_mappings":[{"input_key":"face_vec","path":"features.face","source_type":"vector"}],"retriever_id":"ret_face_v1","taxonomy_type":"hierarchical"},{"hierarchical_nodes":[{"collection_id":"col_special_products","enrichment_fields":[{"field_path":"premium_tags","merge_mode":"append"}],"parent_collection_id":"col_products_v1","retriever_id":"ret_special_v1"}],"inference_collections":["col_products_v1","col_categories_v1"],"inference_strategy":"cluster","retriever_id":"ret_clip_v1","taxonomy_type":"hierarchical"}]},"HierarchyInferenceStrategy":{"type":"string","enum":["schema","cluster","llm"],"title":"HierarchyInferenceStrategy","description":"Strategy for inferring the base hierarchy structure.\n\nCan be combined with manual overrides via hierarchical_nodes for hybrid configuration:\n- SCHEMA: Infer based on overlapping collection schemas\n- CLUSTER: Infer based on clustering algorithms and overlap detection\n- LLM: Infer using AI/language models"},"IconikConfig":{"properties":{"provider_type":{"type":"string","const":"iconik","title":"Provider Type","default":"iconik"},"credentials":{"$ref":"#/components/schemas/IconikCredentials","description":"REQUIRED. Iconik App-ID + Auth-Token credentials."},"base_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Base Url","description":"Iconik API base URL, https://app.iconik.io by default. Override for on-premise Iconik installations."},"metadata_view_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Metadata View Id","description":"Iconik metadata view ID for fetching custom metadata fields. Found in: Iconik Admin > Metadata > Views. Set to 'none' to skip metadata view fetches entirely."},"rate_limit_rps":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Rate Limit Rps","description":"Max requests per second to the Iconik API (shared across all sync shards)."},"rate_limit_redis_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rate Limit Redis Url","description":"Redis URL for distributed rate limiting across workers."}},"type":"object","required":["credentials"],"title":"IconikConfig","description":"Iconik DAM platform configuration.\n\nIconik is a cloud-native DAM (Digital Asset Management) platform.\nThis provider syncs video/image/audio assets from an Iconik account\ninto Mixpeek for processing and analysis.\n\nAuthentication:\n    - App-ID + Auth-Token (HTTP headers)\n\nRequirements:\n    - Active Iconik account with API application configured\n    - Auth token with asset read permissions\n\nUse Cases:\n    - Video ad library ingestion and analysis\n    - Creative asset search and discovery\n    - Talent/cast identification across ad library","examples":[{"credentials":{"app_id":"e0f0ec84-...","auth_token":"eyJhbGciOi...","type":"app_token"},"description":"Iconik DAM sync","provider_type":"iconik"}]},"IconikCredentials":{"properties":{"type":{"type":"string","const":"app_token","title":"Type","default":"app_token"},"app_id":{"type":"string","title":"App Id","description":"REQUIRED. Iconik application ID. Found in: Iconik Admin > Settings > API Applications.","examples":["e0f0ec84-4d63-11f1-99fa-b221c0ff30c8"]},"auth_token":{"type":"string","title":"Auth Token","description":"REQUIRED. Iconik auth token (JWT or API token). SECURITY: Encrypted at rest. Found in: Iconik Admin > Settings > API Applications > Token."},"webhook_secret":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Webhook Secret","description":"NOT REQUIRED. Webhook secret for verifying inbound Iconik webhook events. Set this to enable webhook-driven sync (asset create/update/delete). SECURITY: Encrypted at rest."}},"type":"object","required":["app_id","auth_token"],"title":"IconikCredentials","description":"App-ID + Auth-Token credentials for Iconik DAM platform.\n\nSecurity:\n    - auth_token is a secret credential, redacted on read\n    - Tokens are created in Iconik Admin > Settings > API Applications"},"ImageExtractorParams":{"properties":{"extractor_type":{"type":"string","const":"image_extractor","title":"Extractor Type","description":"Discriminator field for parameter type identification.","default":"image_extractor"},"enable_thumbnails":{"type":"boolean","title":"Enable Thumbnails","description":"Whether to generate thumbnail images.","default":true},"use_cdn":{"type":"boolean","title":"Use Cdn","description":"Whether to use CloudFront CDN for thumbnail delivery.","default":false}},"type":"object","title":"ImageExtractorParams","description":"Parameters for the Image Extractor.","examples":[{"enable_thumbnails":true,"extractor_type":"image_extractor","use_cdn":false}]},"ImportMapping":{"properties":{"fields":{"items":{"$ref":"#/components/schemas/FieldMapping"},"type":"array","title":"Fields"},"source_type":{"anyOf":[{"type":"string","enum":["bucket","collection"]},{"type":"null"}],"title":"Source Type"},"chain_template":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Chain Template"}},"additionalProperties":true,"type":"object","title":"ImportMapping","description":"The finalized mapping. This IS the import config."},"ImportRequest":{"properties":{"export":{"additionalProperties":true,"type":"object","title":"Export","description":"One export object (e.g. an asset with its scene arrays)."},"mapping":{"$ref":"#/components/schemas/ImportMapping","description":"The finalized source->target mapping (validate it first)."},"explode":{"anyOf":[{"$ref":"#/components/schemas/ExplodeSpec"},{"type":"null"}],"description":"Document-explosion inputs when the export nests a doc-generating array."},"dry_run":{"type":"boolean","title":"Dry Run","description":"Reconstruct and validate only; write nothing.","default":false},"seed_ledger":{"type":"boolean","title":"Seed Ledger","description":"Seed the ledger for heal-skip (no-op until available).","default":false}},"additionalProperties":true,"type":"object","required":["mapping"],"title":"ImportRequest","description":"Request body for POST /v1/collections/{collection_id}/import."},"ImportResponse":{"properties":{"imported":{"type":"integer","title":"Imported","description":"Documents written (0 on dry_run).","default":0},"reconstructed":{"type":"integer","title":"Reconstructed","description":"Documents reconstructed from the export.","default":0},"skipped":{"type":"integer","title":"Skipped","description":"Rows that failed reconstruction.","default":0},"dry_run":{"type":"boolean","title":"Dry Run","default":false},"errors":{"items":{"$ref":"#/components/schemas/ImportRowError"},"type":"array","title":"Errors"},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings"}},"type":"object","title":"ImportResponse","description":"Result of a collection import."},"ImportRowError":{"properties":{"row":{"type":"integer","title":"Row","description":"Index of the exploded element that failed (-1 = whole-export)."},"error":{"type":"string","title":"Error"}},"type":"object","required":["row","error"],"title":"ImportRowError"},"IndexRecommendation":{"properties":{"field_name":{"type":"string","title":"Field Name","description":"Field to index"},"query_count":{"type":"integer","title":"Query Count","description":"Number of queries using this field"},"avg_latency_ms":{"type":"number","title":"Avg Latency Ms","description":"Average latency"},"p95_latency_ms":{"type":"number","title":"P95 Latency Ms","description":"95th percentile latency"},"slow_query_count":{"type":"integer","title":"Slow Query Count","description":"Queries slower than 500ms"},"very_slow_query_count":{"type":"integer","title":"Very Slow Query Count","description":"Queries slower than 1000ms"},"priority_score":{"type":"number","title":"Priority Score","description":"Priority score for indexing"},"recommendation":{"type":"string","title":"Recommendation","description":"Human-readable recommendation level"},"mongodb_index_command":{"type":"string","title":"Mongodb Index Command","description":"Ready-to-use MongoDB index command"},"index_kind":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Index Kind","description":"Recommended index KIND, derived from the operators observed with this field: 'keyword' (eq/ne/in/nin/exists/is_null), 'range' (gt/gte/lt/lte), 'text' (contains/starts_with/ends_with/regex/text/phrase/words), 'geo' (geo_*). None means no operator data exists for the field (rows written before filter_ops shipped) — treat as unknown, not as keyword."}},"type":"object","required":["field_name","query_count","avg_latency_ms","p95_latency_ms","slow_query_count","very_slow_query_count","priority_score","recommendation","mongodb_index_command"],"title":"IndexRecommendation","description":"MongoDB index recommendation."},"IndexRecommendationsResponse":{"properties":{"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace ID analyzed"},"time_range_days":{"type":"integer","title":"Time Range Days","description":"Number of days analyzed"},"recommendations":{"items":{"$ref":"#/components/schemas/IndexRecommendation"},"type":"array","title":"Recommendations","description":"Index recommendations"},"summary":{"additionalProperties":{"type":"integer"},"type":"object","title":"Summary","description":"Summary statistics (high_priority, medium_priority, low_priority counts)"},"coverage":{"anyOf":[{"$ref":"#/components/schemas/RecommendationCoverage"},{"type":"null"}],"description":"Scope of the recommendations above. An empty list next to a large `slow_queries` count means the slow traffic is not filter-driven, not that the namespace is healthy. Null when the analytics backend could not be read."}},"type":"object","required":["namespace_id","time_range_days","recommendations","summary"],"title":"IndexRecommendationsResponse","description":"Response for index recommendations endpoint."},"IndexSuggestion":{"properties":{"field_name":{"type":"string","title":"Field Name","description":"Field name to index"},"query_count_24h":{"type":"integer","title":"Query Count 24H","description":"Number of queries using this field in last 24 hours"},"query_count_7d":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Query Count 7D","description":"Number of queries in last 7 days"},"suggested_type":{"type":"string","title":"Suggested Type","description":"Suggested index type (keyword, integer, float, etc.)"},"is_indexed":{"type":"boolean","title":"Is Indexed","description":"Whether field is already indexed"},"first_seen":{"type":"string","format":"date-time","title":"First Seen","description":"First time field was seen in filters"},"last_seen":{"type":"string","format":"date-time","title":"Last Seen","description":"Most recent usage"},"estimated_performance_gain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Estimated Performance Gain","description":"Estimated query performance improvement (e.g., '60-80%')"}},"type":"object","required":["field_name","query_count_24h","suggested_type","is_indexed","first_seen","last_seen"],"title":"IndexSuggestion","description":"Suggestion for creating a payload index."},"IndexSuggestionsResponse":{"properties":{"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace being analyzed"},"analysis_period":{"type":"string","title":"Analysis Period","description":"Time period analyzed (e.g., '24h', '7d')"},"suggestions":{"items":{"$ref":"#/components/schemas/IndexSuggestion"},"type":"array","title":"Suggestions","description":"List of index suggestions"},"auto_create_enabled":{"type":"boolean","title":"Auto Create Enabled","description":"Whether auto-indexing is enabled for this namespace"},"next_auto_create_run":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Next Auto Create Run","description":"Next scheduled auto-creation run (if enabled)"}},"type":"object","required":["namespace_id","analysis_period","suggestions","auto_create_enabled"],"title":"IndexSuggestionsResponse","description":"Response containing index suggestions for a namespace."},"InferConfigRequest":{"properties":{"use_case_description":{"type":"string","maxLength":2000,"minLength":5,"title":"Use Case Description","description":"Free-text description of what the user wants to build.","examples":["I want to search my product catalog by image","I need to moderate user-generated content on my platform"]},"content_types":{"items":{"type":"string"},"type":"array","title":"Content Types","description":"Optional hint about data types the user has (e.g. 'video', 'pdf', 'image').","examples":[["video","image"],["pdf","text"]]}},"type":"object","required":["use_case_description"],"title":"InferConfigRequest"},"InferConfigResponse":{"properties":{"recommended_scaffold_id":{"type":"string","title":"Recommended Scaffold Id","description":"Template ID from the scaffold catalog (e.g. 'tmpl_scaffold_video_understanding')."},"scaffold_name":{"type":"string","title":"Scaffold Name","description":"Human-readable template name."},"confidence":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Confidence","description":"Model confidence in this recommendation."},"reasoning":{"type":"string","title":"Reasoning","description":"2-3 sentence explanation of why this scaffold was chosen."},"extractors":{"items":{"$ref":"#/components/schemas/SuggestedExtractor"},"type":"array","title":"Extractors","description":"Recommended feature extractors."},"retriever_stages":{"items":{"$ref":"#/components/schemas/SuggestedStage"},"type":"array","title":"Retriever Stages","description":"Recommended retriever pipeline stages."},"sample_queries":{"items":{"$ref":"#/components/schemas/SampleQuery"},"type":"array","title":"Sample Queries","description":"Example search queries the user could run."},"alternate_scaffold_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Alternate Scaffold Id","description":"Second-best template if the primary isn't a great fit."},"alternate_scaffold_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Alternate Scaffold Name"}},"type":"object","required":["recommended_scaffold_id","scaffold_name","confidence","reasoning","extractors","retriever_stages","sample_queries"],"title":"InferConfigResponse"},"InferredField":{"properties":{"path":{"type":"string","title":"Path"},"type":{"type":"string","enum":["string","integer","float","boolean","datetime","vector","object","null"],"title":"Type"},"cardinality":{"anyOf":[{"type":"string","enum":["low","high"]},{"type":"null"}],"title":"Cardinality"},"sample":{"anyOf":[{},{"type":"null"}],"title":"Sample"},"dim":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Dim"},"dtype":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dtype"},"suggested_target":{"$ref":"#/components/schemas/MappingTarget"}},"type":"object","required":["path","type","suggested_target"],"title":"InferredField","description":"One source field the inference discovered, with a suggested target."},"InfraEventType":{"type":"string","enum":["oom","preemption","node_failure","ray_bug","rolling_update","unknown"],"title":"InfraEventType"},"InfrastructureDetail":{"properties":{"event_type":{"$ref":"#/components/schemas/InfraEventType"},"detected_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Detected At"},"raw_signal":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Raw Signal","description":"The error text that triggered classification."},"node_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Node Id"},"pod_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pod Name"}},"type":"object","required":["event_type"],"title":"InfrastructureDetail","description":"A single infrastructure event correlated with a tier execution."},"InfrastructureSummaryResponse":{"properties":{"tenant_id":{"type":"string","title":"Tenant Id"},"namespace":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Namespace"},"region":{"type":"string","title":"Region","default":"us-east1"},"billing_mode":{"type":"string","title":"Billing Mode","default":"credits"},"extractors":{"items":{"$ref":"#/components/schemas/ExtractorComputeSummary"},"type":"array","title":"Extractors"},"data_plane_components":{"items":{"$ref":"#/components/schemas/DataPlaneComponentSummary"},"type":"array","title":"Data Plane Components"},"cost_breakdown":{"$ref":"#/components/schemas/CostBreakdownSummary"},"compute_costs":{"$ref":"#/components/schemas/ComputeCostSummary"},"billing_period":{"anyOf":[{"$ref":"#/components/schemas/BillingPeriodSummary"},{"type":"null"}]}},"type":"object","required":["tenant_id","cost_breakdown"],"title":"InfrastructureSummaryResponse"},"IngestFilter":{"properties":{"retriever_id":{"type":"string","minLength":1,"title":"Retriever Id","description":"The saved retriever every candidate object runs through.","examples":["ret_ab12cd34ef56"]},"retriever_version":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Retriever Version","description":"The retriever version the filter runs. Pinned when the bucket or sync is written: omit it to pin the retriever's current version. A later edit to the retriever does not change the filter until this number changes.","examples":[1,3]},"action":{"$ref":"#/components/schemas/IngestFilterAction","description":"keep: commit only the candidates the retriever returns something for. drop: commit only the candidates it returns nothing for. tag: commit every candidate and record the verdict on the object.","default":"keep","examples":["keep","drop","tag"]},"on_error":{"$ref":"#/components/schemas/IngestFilterOnError","description":"What happens to a candidate the filter could not judge (the retriever failed, timed out, or the candidate was too large to send). keep commits it with an error status on its ingest_filter record; drop drops it with reason filter_error. Either way the error is counted on the sync job.","default":"keep","examples":["keep","drop"]},"timeout_seconds":{"type":"integer","maximum":300.0,"minimum":1.0,"title":"Timeout Seconds","description":"The longest one retriever run may take for one candidate.","default":30,"examples":[30]}},"type":"object","required":["retriever_id"],"title":"IngestFilter","description":"A pinned saved retriever every candidate object runs through before commit.\n\nThe filter matches a candidate when the retriever returns at least one\ndocument for it. The candidate is offered to the retriever as a seed\ndocument (its mapped fields at the root, the source record under\n``source``) and as inputs (each declared input filled from the candidate\nfield of the same name, and one media-typed input given the bytes as\nbase64)."},"IngestFilterAction":{"type":"string","enum":["keep","drop","tag"],"title":"IngestFilterAction","description":"What a match means for a candidate object."},"IngestFilterOnError":{"type":"string","enum":["keep","drop"],"title":"IngestFilterOnError","description":"What happens to a candidate the filter could not judge."},"InputMapping":{"properties":{"input_key":{"type":"string","title":"Input Key","description":"Key used in the constructed inputs payload."},"source_type":{"anyOf":[{"$ref":"#/components/schemas/InputSourceType"},{"type":"null"}],"description":"Source of the value (payload, literal, vector)."},"path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Path","description":"Dot-notation path when source_type is PAYLOAD or VECTOR. PAYLOAD paths resolve from the document's ROOT fields — each document/source_document dict IS the payload (e.g. path 'text' reads {'text': ...}); a {'payload': {...}} envelope is also accepted as a fallback."},"override":{"anyOf":[{},{"type":"null"}],"title":"Override","description":"Static value used when source_type is LITERAL. Overrides any path."}},"type":"object","required":["input_key"],"title":"InputMapping","description":"Declarative mapping for building inputs from various sources.\n\n- input_key: The key used in the constructed inputs payload\n- source_type: Where to fetch the value (payload, literal, vector)\n- path: Dot-notation path when source_type is PAYLOAD or VECTOR\n- override: Static value when source_type is LITERAL","examples":[{"input_key":"query_text","path":"content.title","source_type":"payload"},{"input_key":"lang","override":"en","source_type":"literal"},{"input_key":"image_vector","path":"features.clip_vit_l_14","source_type":"vector"}]},"InputMappingSource":{"properties":{"source_type":{"type":"string","enum":["document_field","constant","source_blob"],"title":"Source Type","description":"Where the value comes from"},"path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Path","description":"JSONPath to document field (when source_type='document_field'), or blob property name (when source_type='source_blob', e.g. 'image')","examples":["features.video_embedding","metadata.category","_taxonomy_product_label","image"]},"value":{"anyOf":[{},{"type":"null"}],"title":"Value","description":"Constant value to use (when source_type='constant')","examples":["col_known_incidents",0.85,true]}},"type":"object","required":["source_type"],"title":"InputMappingSource","description":"Defines how to get a value for a retriever input.\n\nCan be a document field reference, a constant value, or a source blob URL.\n\nAttributes:\n    source_type: Where the value comes from\n    path: JSONPath to document field (when source_type='document_field'),\n          or blob property name (when source_type='source_blob', e.g. 'image')\n    value: Constant value to use (when source_type='constant')"},"InputRenderingConfig-Input":{"properties":{"field_name":{"type":"string","title":"Field Name","description":"Name of the input field (matches retriever input_schema key)","examples":["query","image_url","video_url","category"]},"field_schema":{"$ref":"#/components/schemas/RetrieverInputSchemaField-Input","description":"Schema definition for this input field. Defines type, description, examples, and validation rules. Supports all bucket types (string, number, image, etc.) plus document_reference. Frontend uses this to render the appropriate input component (text input, image upload, dropdown, etc.)"},"input_type":{"type":"string","title":"Input Type","description":"UI input component type. Determines how the input is rendered: text (single line), select (dropdown), file (upload), multiselect (multiple choice)","default":"text","examples":["text","select","file","multiselect"]},"label":{"type":"string","title":"Label","description":"Human-readable label for the input","examples":["Search Query","Upload Image","Select Category"]},"placeholder":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Placeholder","description":"Placeholder text for the input","examples":["Enter search terms...","Drag and drop or click to upload"]},"helper_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Helper Text","description":"Helper text displayed below the input to guide users","examples":["Describe the aesthetic, outfit, or vibe you're looking for","Enter keywords separated by commas","Use natural language to describe what you're searching for"]},"suggestions":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Suggestions","description":"Pre-filled suggestion chips that users can click to populate the input","examples":[["streetwear urban","clean girl minimal","summer haul bright"],["wireless headphones","laptop under $1000","gaming mouse"],["minimalist","oversized hoodie","aesthetic vibe"]]},"required":{"type":"boolean","title":"Required","description":"Whether this input is required","default":true},"order":{"type":"integer","minimum":0.0,"title":"Order","description":"Display order (lower numbers appear first)","default":0}},"type":"object","required":["field_name","field_schema","label"],"title":"InputRenderingConfig","description":"Configuration for how to render an input field in the public UI.\n\nMaps to BucketSchemaField structure for consistency with how we define\ninput types across the system.","examples":[{"field_name":"query","field_schema":{"description":"Text search query","examples":["red sports car","sunset over ocean"],"type":"string"},"helper_text":"Describe the aesthetic, outfit, or vibe you're looking for","label":"Search by style","order":0,"placeholder":"Try: oversized hoodie streetwear urban","required":true,"suggestions":["streetwear urban","clean girl minimal","summer haul bright","minimalist aesthetic"]},{"field_name":"image_url","field_schema":{"description":"Image for visual search","examples":["https://example.com/image.jpg"],"type":"image"},"helper_text":"Upload an image to find visually similar items","label":"Upload Image","order":1,"placeholder":"Drop image or paste URL","required":false}]},"InputRenderingConfig-Output":{"properties":{"field_name":{"type":"string","title":"Field Name","description":"Name of the input field (matches retriever input_schema key)","examples":["query","image_url","video_url","category"]},"field_schema":{"$ref":"#/components/schemas/RetrieverInputSchemaField-Output","description":"Schema definition for this input field. Defines type, description, examples, and validation rules. Supports all bucket types (string, number, image, etc.) plus document_reference. Frontend uses this to render the appropriate input component (text input, image upload, dropdown, etc.)"},"input_type":{"type":"string","title":"Input Type","description":"UI input component type. Determines how the input is rendered: text (single line), select (dropdown), file (upload), multiselect (multiple choice)","default":"text","examples":["text","select","file","multiselect"]},"label":{"type":"string","title":"Label","description":"Human-readable label for the input","examples":["Search Query","Upload Image","Select Category"]},"placeholder":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Placeholder","description":"Placeholder text for the input","examples":["Enter search terms...","Drag and drop or click to upload"]},"helper_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Helper Text","description":"Helper text displayed below the input to guide users","examples":["Describe the aesthetic, outfit, or vibe you're looking for","Enter keywords separated by commas","Use natural language to describe what you're searching for"]},"suggestions":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Suggestions","description":"Pre-filled suggestion chips that users can click to populate the input","examples":[["streetwear urban","clean girl minimal","summer haul bright"],["wireless headphones","laptop under $1000","gaming mouse"],["minimalist","oversized hoodie","aesthetic vibe"]]},"required":{"type":"boolean","title":"Required","description":"Whether this input is required","default":true},"order":{"type":"integer","minimum":0.0,"title":"Order","description":"Display order (lower numbers appear first)","default":0}},"type":"object","required":["field_name","field_schema","label"],"title":"InputRenderingConfig","description":"Configuration for how to render an input field in the public UI.\n\nMaps to BucketSchemaField structure for consistency with how we define\ninput types across the system.","examples":[{"field_name":"query","field_schema":{"description":"Text search query","examples":["red sports car","sunset over ocean"],"type":"string"},"helper_text":"Describe the aesthetic, outfit, or vibe you're looking for","label":"Search by style","order":0,"placeholder":"Try: oversized hoodie streetwear urban","required":true,"suggestions":["streetwear urban","clean girl minimal","summer haul bright","minimalist aesthetic"]},{"field_name":"image_url","field_schema":{"description":"Image for visual search","examples":["https://example.com/image.jpg"],"type":"image"},"helper_text":"Upload an image to find visually similar items","label":"Upload Image","order":1,"placeholder":"Drop image or paste URL","required":false}]},"InputSourceType":{"type":"string","enum":["payload","literal","vector","blob"],"title":"InputSourceType","description":"Where the value for an input should be retrieved from."},"InstagramConfig":{"properties":{"provider_type":{"type":"string","const":"instagram","title":"Provider Type","default":"instagram"},"credentials":{"$ref":"#/components/schemas/InstagramOAuthCredentials","description":"OAuth credentials for Instagram Graph API access."},"scopes":{"items":{"type":"string"},"type":"array","title":"Scopes","description":"OAuth scopes granted during authorization.","default":["instagram_basic","instagram_manage_insights","pages_show_list"]},"business_account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Business Account Id","description":"Instagram Business Account ID if different from the user ID. Auto-populated from OAuth flow."}},"type":"object","required":["credentials"],"title":"InstagramConfig","description":"Instagram Business/Creator account configuration via Meta Graph API.\n\nEnables Mixpeek to sync media (posts, reels, carousels) from Instagram\naccounts using the official Instagram Graph API. Each media item becomes\na bucket object with metadata (caption, likes, comments, permalink).\n\nAuthentication:\n    - OAuth 2.0 via Meta Developer Console\n    - Long-lived tokens (60 days) with automatic refresh\n\nRequirements:\n    - Instagram Business or Creator account\n    - Facebook Page linked to the Instagram account\n    - Meta app with instagram_basic permission\n\nUse Cases:\n    - Sync creator content for talent analysis\n    - Monitor competitor ad creatives\n    - Build social media content libraries for multimodal search","examples":[{"credentials":{"access_token":"IGQ...","client_id":"123456789","client_secret":"app_secret_here","instagram_user_id":"17841400000000000","instagram_username":"mybrand","token_expires_at":"2025-04-01T00:00:00Z","type":"oauth"},"description":"Instagram Business account via OAuth","provider_type":"instagram","scopes":["instagram_basic","instagram_manage_insights"]}]},"InstagramOAuthCredentials":{"properties":{"type":{"type":"string","const":"oauth","title":"Type","default":"oauth"},"client_id":{"type":"string","title":"Client Id","description":"Instagram App ID from Meta Developer Console."},"client_secret":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Secret","description":"SECURITY: Secret credential, redacted on read. Never log or expose. Instagram App Secret from Meta Developer Console. Optional: the token refresh sends an empty secret when it is absent."},"access_token":{"type":"string","title":"Access Token","description":"SECURITY: Encrypted at rest. Long-lived Instagram access token (60-day validity)."},"token_expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Token Expires At","description":"Token expiration timestamp. Used to trigger proactive refresh."},"instagram_user_id":{"type":"string","title":"Instagram User Id","description":"Instagram User ID of the account that authorized access."},"instagram_username":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Instagram Username","description":"Instagram username for display purposes."}},"type":"object","required":["client_id","access_token","instagram_user_id"],"title":"InstagramOAuthCredentials","description":"Credentials for Instagram Graph API OAuth2 authentication.\n\nInstagram uses Meta's OAuth2 flow to obtain access tokens. The flow\nproduces a short-lived token which is exchanged for a long-lived token\n(valid for 60 days). Long-lived tokens can be refreshed before expiry.\n\nPrerequisites:\n    - Meta Developer account with an Instagram app\n    - Instagram Business or Creator account linked to a Facebook Page\n    - App must have instagram_basic permission approved\n\nSecurity:\n    - client_secret and access_token are secret credentials, redacted on read\n    - Long-lived tokens must be refreshed before 60-day expiry\n    - Token refresh happens automatically during sync execution"},"InstallExtractorRequest":{"properties":{"public_name":{"type":"string","title":"Public Name","description":"Public name of the extractor to install"}},"type":"object","required":["public_name"],"title":"InstallExtractorRequest"},"InstallExtractorResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"installed_extractor_id":{"type":"string","title":"Installed Extractor Id"},"source_public_name":{"type":"string","title":"Source Public Name"},"source_version":{"type":"string","title":"Source Version"},"feature_uri":{"type":"string","title":"Feature Uri"}},"type":"object","required":["success","installed_extractor_id","source_public_name","source_version","feature_uri"],"title":"InstallExtractorResponse"},"InstantiateBucketTemplateRequest":{"properties":{"bucket_name":{"type":"string","maxLength":100,"minLength":1,"title":"Bucket Name","description":"Name for the new bucket"},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description","description":"Optional description override for the bucket"}},"type":"object","required":["bucket_name"],"title":"InstantiateBucketTemplateRequest","description":"Request to instantiate a bucket from a template.","examples":[{"bucket_name":"my_product_images","description":"Product images for e-commerce store"}]},"InstantiateClusterTemplateRequest":{"properties":{"cluster_name":{"type":"string","maxLength":100,"minLength":1,"title":"Cluster Name","description":"Name for the new cluster"},"collection_ids":{"items":{"type":"string"},"type":"array","minItems":1,"title":"Collection Ids","description":"Collection IDs to use for the cluster"},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description","description":"Optional description override for the cluster"}},"type":"object","required":["cluster_name","collection_ids"],"title":"InstantiateClusterTemplateRequest","description":"Request to instantiate a cluster from a template.","examples":[{"cluster_name":"my_product_clusters","collection_ids":["col_products"],"description":"Cluster products by visual similarity"}]},"InstantiateCollectionTemplateRequest":{"properties":{"collection_name":{"type":"string","maxLength":100,"minLength":1,"title":"Collection Name","description":"Name for the new collection"},"bucket_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Bucket Ids","description":"Bucket IDs to use for the collection (for bucket sources)"},"collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Collection Id","description":"Collection ID to use for the collection (for collection sources)"},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description","description":"Optional description override for the collection"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Optional tags for the collection"}},"type":"object","required":["collection_name"],"title":"InstantiateCollectionTemplateRequest","description":"Request to instantiate a collection from a template.","examples":[{"bucket_ids":["bkt_products"],"collection_name":"my_product_embeddings","description":"Image embeddings for product catalog","tags":["production","products"]}]},"InstantiateRetrieverTemplateRequest":{"properties":{"retriever_name":{"type":"string","maxLength":100,"minLength":1,"title":"Retriever Name","description":"Name for the new retriever"},"collection_identifiers":{"items":{"type":"string"},"type":"array","minItems":1,"title":"Collection Identifiers","description":"Collection identifiers to use for the retriever"},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description","description":"Optional description override for the retriever"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Optional tags for the retriever"}},"type":"object","required":["retriever_name","collection_identifiers"],"title":"InstantiateRetrieverTemplateRequest","description":"Request to instantiate a retriever from a template.","examples":[{"collection_identifiers":["products"],"description":"Semantic search for products","retriever_name":"my_product_search","tags":["production","products"]}]},"InstantiateScaffoldRequest":{"properties":{"namespace_name":{"type":"string","maxLength":20,"minLength":3,"title":"Namespace Name","description":"Name for the new namespace (required, must be unique)"},"namespace_description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Namespace Description","description":"Optional description for the namespace"},"bucket_name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Bucket Name","description":"Override default bucket name from scaffold"},"collection_name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Collection Name","description":"Override default collection name from scaffold"},"retriever_name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Retriever Name","description":"Override default retriever name from scaffold"},"include_sample_data":{"type":"boolean","title":"Include Sample Data","description":"If true, include sample data from demo namespace. If false, create empty resources.","default":false}},"type":"object","required":["namespace_name"],"title":"InstantiateScaffoldRequest","description":"Request to instantiate a scaffold template.\n\nOnly namespace_name is required. Other names use scaffold defaults.\n\nOptions:\n    include_sample_data: If true, clone from demo namespace with sample data.\n                        If false (default), create empty resources.\n\nExample:\n    # Empty scaffold\n    {\"namespace_name\": \"my_app\"}\n\n    # With sample data\n    {\"namespace_name\": \"my_app\", \"include_sample_data\": true}","examples":[{"namespace_name":"my_video_app"},{"include_sample_data":true,"namespace_name":"my_video_app"},{"bucket_name":"my_videos","collection_name":"video_embeddings","namespace_description":"Video search application","namespace_name":"my_video_app","retriever_name":"video_search"}]},"InstantiateTaxonomyTemplateRequest":{"properties":{"taxonomy_name":{"type":"string","maxLength":100,"minLength":1,"title":"Taxonomy Name","description":"Name for the new taxonomy"},"collection_config":{"additionalProperties":{"type":"string"},"type":"object","title":"Collection Config","description":"Collection configuration for the taxonomy. For flat taxonomies: {'collection_id': 'col_xxx'} For hierarchical taxonomies: maps node collection IDs to actual collection IDs, e.g., {'col_template_root': 'col_actual_root', 'col_template_child': 'col_actual_child'}"},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description","description":"Optional description override for the taxonomy"}},"type":"object","required":["taxonomy_name","collection_config"],"title":"InstantiateTaxonomyTemplateRequest","description":"Request to instantiate a taxonomy from a template.","examples":[{"collection_config":{"collection_id":"col_products_v1"},"description":"Product categorization taxonomy","taxonomy_name":"my_product_categories"},{"collection_config":{"col_employees":"col_my_employees","col_executives":"col_my_executives","col_managers":"col_my_managers"},"description":"Organization hierarchy taxonomy","taxonomy_name":"my_org_hierarchy"}]},"InstantiatedBucketTemplateResponse":{"properties":{"bucket_id":{"type":"string","title":"Bucket Id","description":"ID of the created bucket"},"bucket_name":{"type":"string","title":"Bucket Name","description":"Name of the created bucket"},"template_id":{"type":"string","title":"Template Id","description":"ID of the template used"},"status":{"type":"string","title":"Status","description":"Status of the instantiation","default":"created"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Timestamp when bucket was created"}},"type":"object","required":["bucket_id","bucket_name","template_id"],"title":"InstantiatedBucketTemplateResponse","description":"Response after instantiating a bucket template.","examples":[{"bucket_id":"bkt_abc123","bucket_name":"my_product_images","created_at":"2025-01-15T12:00:00Z","status":"created","template_id":"tmpl_image_bucket"}]},"InstantiatedClusterTemplateResponse":{"properties":{"cluster_id":{"type":"string","title":"Cluster Id","description":"ID of the created cluster"},"cluster_name":{"type":"string","title":"Cluster Name","description":"Name of the created cluster"},"template_id":{"type":"string","title":"Template Id","description":"ID of the template used"},"status":{"type":"string","title":"Status","description":"Status of the instantiation","default":"created"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Timestamp when cluster was created"}},"type":"object","required":["cluster_id","cluster_name","template_id"],"title":"InstantiatedClusterTemplateResponse","description":"Response after instantiating a cluster template.","examples":[{"cluster_id":"clust_abc123","cluster_name":"my_product_clusters","created_at":"2025-01-15T12:00:00Z","status":"created","template_id":"tmpl_visual_clustering"}]},"InstantiatedCollectionTemplateResponse":{"properties":{"collection_id":{"type":"string","title":"Collection Id","description":"ID of the created collection"},"collection_name":{"type":"string","title":"Collection Name","description":"Name of the created collection"},"template_id":{"type":"string","title":"Template Id","description":"ID of the template used"},"status":{"type":"string","title":"Status","description":"Status of the instantiation","default":"created"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Timestamp when collection was created"}},"type":"object","required":["collection_id","collection_name","template_id"],"title":"InstantiatedCollectionTemplateResponse","description":"Response after instantiating a collection template.","examples":[{"collection_id":"col_abc123","collection_name":"my_product_embeddings","created_at":"2025-01-15T12:00:00Z","status":"created","template_id":"tmpl_image_embeddings"}]},"InstantiatedRetrieverTemplateResponse":{"properties":{"retriever_id":{"type":"string","title":"Retriever Id","description":"ID of the created retriever"},"retriever_name":{"type":"string","title":"Retriever Name","description":"Name of the created retriever"},"template_id":{"type":"string","title":"Template Id","description":"ID of the template used"},"status":{"type":"string","title":"Status","description":"Status of the instantiation","default":"created"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Timestamp when retriever was created"}},"type":"object","required":["retriever_id","retriever_name","template_id"],"title":"InstantiatedRetrieverTemplateResponse","description":"Response after instantiating a retriever template.","examples":[{"created_at":"2025-01-15T12:00:00Z","retriever_id":"ret_abc123","retriever_name":"my_product_search","status":"created","template_id":"tmpl_semantic_search"}]},"InstantiatedScaffoldResponse":{"properties":{"namespace_id":{"type":"string","title":"Namespace Id","description":"Created namespace ID (ns_xxx)"},"namespace_name":{"type":"string","title":"Namespace Name","description":"Created namespace name"},"bucket_id":{"type":"string","title":"Bucket Id","description":"Created bucket ID (bkt_xxx)"},"bucket_name":{"type":"string","title":"Bucket Name","description":"Created bucket name"},"collection_id":{"type":"string","title":"Collection Id","description":"Created collection ID (col_xxx)"},"collection_name":{"type":"string","title":"Collection Name","description":"Created collection name"},"retriever_id":{"type":"string","title":"Retriever Id","description":"Created retriever ID (ret_xxx)"},"retriever_name":{"type":"string","title":"Retriever Name","description":"Created retriever name"},"template_id":{"type":"string","title":"Template Id","description":"Scaffold template ID used"},"status":{"type":"string","title":"Status","description":"Status: 'created' for a synchronous (empty) instantiation, 'cloning' when sample data is cloning in the background","default":"created"},"task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id","description":"Background clone task id when status='cloning' — poll the task, or GET the namespace and read clone_status, to track sample-data progress. Null for synchronous (empty) instantiation."},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"UTC timestamp of creation"}},"type":"object","required":["namespace_id","namespace_name","bucket_id","bucket_name","collection_id","collection_name","retriever_id","retriever_name","template_id"],"title":"InstantiatedScaffoldResponse","description":"Response after successful scaffold instantiation.\n\nContains IDs and names of all four created resources.\nUse these IDs for subsequent operations:\n- Upload data: POST /v1/buckets/{bucket_id}/objects\n- Process: POST /v1/collections/{collection_id}/batches\n- Search: POST /v1/retrievers/{retriever_id}/retrieve","examples":[{"bucket_id":"bkt_xyz789","bucket_name":"videos","collection_id":"col_def456","collection_name":"video_embeddings","created_at":"2025-01-15T12:00:00Z","namespace_id":"ns_abc123","namespace_name":"my_video_app","retriever_id":"ret_ghi012","retriever_name":"video_search","status":"created","template_id":"tmpl_scaffold_video_understanding"}]},"InstantiatedTaxonomyTemplateResponse":{"properties":{"taxonomy_id":{"type":"string","title":"Taxonomy Id","description":"ID of the created taxonomy"},"taxonomy_name":{"type":"string","title":"Taxonomy Name","description":"Name of the created taxonomy"},"template_id":{"type":"string","title":"Template Id","description":"ID of the template used"},"status":{"type":"string","title":"Status","description":"Status of the instantiation","default":"created"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Timestamp when taxonomy was created"}},"type":"object","required":["taxonomy_id","taxonomy_name","template_id"],"title":"InstantiatedTaxonomyTemplateResponse","description":"Response after instantiating a taxonomy template.","examples":[{"created_at":"2025-01-15T12:00:00Z","status":"created","taxonomy_id":"tax_abc123","taxonomy_name":"my_product_categories","template_id":"tmpl_product_taxonomy"}]},"IntegerIndexParams":{"properties":{"type":{"type":"string","title":"Type","default":"integer"},"lookup":{"type":"boolean","title":"Lookup","default":true},"range":{"type":"boolean","title":"Range","default":true}},"type":"object","title":"IntegerIndexParams","description":"Configuration for integer index."},"IntentClassification":{"properties":{"intent":{"type":"string","pattern":"^(execution|setup|ambiguous)$","title":"Intent","description":"Detected intent: 'execution', 'setup', or 'ambiguous'"},"confidence":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Confidence","description":"Confidence in classification"},"reasoning":{"type":"string","title":"Reasoning","description":"Why this intent was detected"},"suitable_collections":{"items":{"$ref":"#/components/schemas/SuitableCollection"},"type":"array","title":"Suitable Collections","description":"Existing collections that might help"},"recommended_action":{"type":"string","title":"Recommended Action","description":"Next action to take (e.g., 'setup_pipeline', 'execute_retriever')"},"clarification_needed":{"type":"boolean","title":"Clarification Needed","description":"Whether to ask user for clarification"},"clarification_options":{"items":{"$ref":"#/components/schemas/ClarificationOption"},"type":"array","title":"Clarification Options","description":"Options for user if clarification needed"},"keywords_found":{"additionalProperties":{"items":{"type":"string"},"type":"array"},"type":"object","title":"Keywords Found","description":"Keywords found (setup_keywords, execution_keywords, neutral_keywords)"}},"type":"object","required":["intent","confidence","reasoning","recommended_action","clarification_needed"],"title":"IntentClassification","description":"Result of intent detection analysis.\n\nThis model represents the agent's understanding of whether the user wants to:\n- Execute queries on existing data (execution mode)\n- Create new resources/infrastructure (setup mode)\n- Or if the request is ambiguous and needs clarification\n\nAttributes:\n    intent: The detected intent (\"execution\", \"setup\", or \"ambiguous\")\n    confidence: Confidence score 0.0-1.0\n    reasoning: Explanation of why this intent was detected\n    suitable_collections: Existing collections that might fulfill the request\n    recommended_action: What the agent should do next\n    clarification_needed: Whether to ask user for clarification\n    clarification_options: Options to present if clarification needed\n    keywords_found: Keywords that influenced the classification"},"InteractionRequest":{"properties":{"event_type":{"type":"string","title":"Event Type","description":"Interaction event type (e.g. 'click', 'search')"},"document_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Id","description":"ID of the document interacted with"},"position":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Position","description":"Zero-based position of the result"},"query":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Query","description":"Search query that produced the result"},"result_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Result Count","description":"Number of results returned"},"latency_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Latency Ms","description":"Time from request to first result (ms)"},"dwell_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Dwell Ms","description":"Time the user spent on the result (ms)"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id","description":"Client-side session identifier"},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Arbitrary extra metadata"}},"additionalProperties":true,"type":"object","required":["event_type"],"title":"InteractionRequest","description":"Request body for tracking a user interaction with a public App.\n\nExtra top-level fields are stored as-is alongside the standard fields,\nallowing callers to attach arbitrary metadata without schema changes."},"InteractionResponse":{"properties":{"feature_id":{"type":"string","title":"Feature Id","description":"ID of the document/feature that was interacted with. REQUIRED. This is the SAME value as the `document_id` returned in retriever execute results — you can pass it as either `feature_id` or `document_id` (the latter is accepted as an alias). Used to track which specific items users engage with.","examples":["doc_abc123","prod_xyz789","feat_12345"]},"interaction_type":{"items":{"$ref":"#/components/schemas/InteractionType"},"type":"array","minItems":1,"title":"Interaction Type","description":"List of interaction types that occurred. REQUIRED. Multiple types can be recorded simultaneously (e.g., VIEW + CLICK + LONG_VIEW for a result the user engaged with). Use the InteractionType enum values.","examples":[["click"],["positive_feedback","click","long_view"],["negative_feedback"],["purchase","click"]]},"position":{"type":"integer","minimum":0.0,"title":"Position","description":"Position in search results where interaction occurred (0-indexed). REQUIRED. Critical for Learning to Rank - helps identify position bias. E.g., position=0 means first result, position=9 means 10th result. Higher engagement at lower positions suggests higher quality.","examples":[0,1,5,15]},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Additional context about the interaction. NOT REQUIRED. Can include device, duration, viewport info, etc. Use this to enrich interaction data with application-specific context.","examples":[{"device":"mobile","duration_ms":5000,"page":"search_results","viewport_position":0.75},{"interaction_reason":"not_relevant","page_number":2,"results_count":50,"search_latency_ms":150}]},"user_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id","description":"Customer's authenticated user identifier. NOT REQUIRED. Persists across sessions for long-term tracking. Enables personalization and user-specific metrics. Use your application's user ID format.","examples":["user_abc123","customer_456","usr_xyz789"]},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id","description":"Temporary identifier for a single search session. NOT REQUIRED. Typically 30min-1hr duration. Tracks anonymous and authenticated users within a session. Use to group related queries and understand search journeys. Also used by learned fusion (auto-tune) for within-session real-time adaptation: interactions sharing a session_id allow the bandit to update feature weights mid-session without waiting for batch aggregation.","examples":["sess_abc123","session_xyz789_1234567890"]},"execution_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Execution Id","description":"ID of the retriever execution that generated these results. REQUIRED when retriever_id is set: every execute response returns it, and an interaction on a retriever's result without it is refused (422). Links the interaction back to the exact search query, pipeline configuration, and stage execution that produced the results the user saw. Essential for: fine-tuning embeddings, training rerankers, query understanding, and tracing which pipeline configs produce better user engagement. Retrieve from the retriever execution response and pass to interactions.","examples":["exec_abc123xyz","exec_550e8400e29b41d4"]},"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id","description":"ID of the retriever that was executed. NOT REQUIRED but RECOMMENDED for multi-retriever analytics. Enables comparing performance across different retriever configurations. If execution_id is provided, retriever_id can be inferred from the execution record.","examples":["ret_abc123","ret_product_search_v2"]},"query_snapshot":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Query Snapshot","description":"Snapshot of the query input that generated these results. HIGHLY RECOMMENDED for training optimization. Storing the query directly enables 10-100x faster training data extraction by avoiding expensive joins to execution records. Use the same format as retriever query input (e.g., {'text': '...', 'filters': {...}}). Essential for: embedding fine-tuning (query-document pairs), query expansion learning, and analyzing which query patterns lead to better engagement. NOT REQUIRED but strongly recommended for production use cases involving model training.","examples":[{"text":"wireless headphones"},{"filters":{"price":{"lte":1000}},"text":"laptop"},{"context":"summer collection","text":"red shoes"}]},"document_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Document Score","description":"Initial retrieval score of this document when shown to the user. HIGHLY RECOMMENDED for Learning to Rank (LTR). This is a critical feature for reranker training - helps the model learn how to adjust initial scores based on user engagement. Should match the score from the retriever execution results. NOT REQUIRED but strongly recommended for LTR and reranker training.","examples":[0.95,0.87,0.62]},"result_set_size":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Result Set Size","description":"Total number of results shown to the user in this search. NOT REQUIRED but useful for context. 0 is accepted only with interaction_type zero_results, for a search that returned nothing; every other interaction needs at least 1. Helps understand interaction patterns - clicking position 5 of 10 results is different from position 5 of 100 results. Useful for position bias correction and CTR analysis.","examples":[10,20,50,100]},"feature_uri":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Feature Uri","description":"Feature URI that produced the clicked result (e.g. 'mixpeek://text_extractor@v1/embedding'). Required for learned fusion — interactions without this field do not contribute to weight learning.","examples":["mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1","mixpeek://clip_extractor@v1/image_embedding"]},"occurred_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Occurred At","description":"When the interaction actually happened (ISO 8601). OPTIONAL. Omit for live interactions — the server stamps 'now'. Supply this ONLY to backfill historical interactions (e.g. migrating existing click logs) so learned-fusion temporal decay weights them by their TRUE age. A naive datetime is interpreted as UTC; a future value is clamped to now. Backfilled events bypass the real-time session cache.","examples":["2026-01-15T10:30:00Z","2025-12-01T00:00:00+00:00"]},"interaction_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Interaction Id","description":"Unique identifier for this interaction record. System-assigned UUID. Use this to reference the interaction in subsequent requests. Null when the interaction was deduplicated (see ``deduplicated`` field).","examples":["int_abc123xyz789","550e8400-e29b-41d4-a716-446655440000"]},"deduplicated":{"type":"boolean","title":"Deduplicated","description":"True when this interaction was a duplicate of a recently recorded interaction with the same (execution_id, feature_id, interaction_type) tuple and was silently dropped. The ``interaction_id`` will be null.","default":false},"timestamp":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timestamp","description":"ISO 8601 timestamp when the interaction was recorded. System-assigned. Used for time-based analysis, training data recency weighting, and temporal trends in user behavior.","examples":["2025-01-15T10:30:00Z","2025-01-15T14:45:30.123Z"]},"warning":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Warning","description":"Non-blocking warning about the interaction. Present when the request was accepted but may not behave as intended (e.g. missing feature_uri for learned fusion)."}},"type":"object","required":["feature_id","interaction_type","position"],"title":"InteractionResponse","description":"Response model for a stored interaction.\n\nExtends SearchInteraction with system-assigned fields.","examples":[{"description":"Minimal click interaction (query_snapshot and document_score optional)","execution_id":"exec_minimal_123","feature_id":"doc_abc123","interaction_type":["click"],"position":2,"session_id":"sess_minimal"},{"description":"Simple click interaction with recommended fields for training","document_score":0.85,"feature_id":"doc_abc123","interaction_type":["click"],"position":2,"query_snapshot":{"text":"machine learning tutorials"}},{"description":"Engaged view with metadata and execution tracking","document_score":0.92,"execution_id":"exec_abc123xyz","feature_id":"prod_xyz789","interaction_type":["view","click","long_view"],"metadata":{"device":"mobile","duration_ms":12000,"viewport_position":0.85},"position":0,"query_snapshot":{"filters":{"price":{"lte":100}},"text":"wireless headphones"},"result_set_size":20,"retriever_id":"ret_product_search","session_id":"sess_abc","user_id":"user_123"},{"description":"Negative feedback","document_score":0.78,"feature_id":"doc_bad456","interaction_type":["negative_feedback","return_to_results"],"metadata":{"interaction_reason":"not_relevant"},"position":5,"query_snapshot":{"text":"python tutorial"},"result_set_size":50,"session_id":"sess_xyz"},{"description":"Purchase conversion with full tracking (high-value signal for training)","document_score":0.88,"execution_id":"exec_purchase_789","feature_id":"prod_789","interaction_type":["purchase"],"metadata":{"conversion_time_seconds":120,"purchase_amount":199.99},"position":1,"query_snapshot":{"text":"noise cancelling headphones"},"result_set_size":50,"retriever_id":"ret_product_search","session_id":"sess_purchase_001","user_id":"user_456"}]},"InteractionTuningRecommendation":{"properties":{"recommendation_type":{"type":"string","title":"Recommendation Type","description":"Type of recommendation","examples":["increase_k","adjust_rerank_threshold","enable_cache"]},"current_value":{"anyOf":[{},{"type":"null"}],"title":"Current Value","description":"Current setting value"},"recommended_value":{"title":"Recommended Value","description":"Recommended value"},"expected_impact":{"type":"string","title":"Expected Impact","description":"Expected performance impact"},"confidence":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Confidence","description":"Confidence score"},"reasoning":{"type":"string","title":"Reasoning","description":"Explanation of recommendation"}},"type":"object","required":["recommendation_type","recommended_value","expected_impact","confidence","reasoning"],"title":"InteractionTuningRecommendation","description":"Recommendation for interaction tuning."},"InteractionTuningResponse":{"properties":{"retriever_id":{"type":"string","title":"Retriever Id","description":"Retriever identifier"},"analysis_period":{"$ref":"#/components/schemas/api__analytics__models__TimeRange","description":"Analysis period"},"recommendations":{"items":{"$ref":"#/components/schemas/InteractionTuningRecommendation"},"type":"array","title":"Recommendations","description":"Tuning recommendations"},"current_performance":{"additionalProperties":true,"type":"object","title":"Current Performance","description":"Current performance baseline"}},"type":"object","required":["retriever_id","analysis_period","recommendations","current_performance"],"title":"InteractionTuningResponse","description":"Response for interaction tuning analysis.","examples":[{"analysis_period":{"end":"2025-10-28T00:00:00Z","start":"2025-10-21T00:00:00Z"},"current_performance":{"avg_latency_ms":145.3,"avg_results":10,"cache_hit_rate":0.72,"p95_latency_ms":287.5},"recommendations":[{"confidence":0.85,"current_value":10,"expected_impact":"Improve recall by ~15%, increase latency by ~8ms","reasoning":"Query patterns show users often click beyond top 10 results","recommendation_type":"increase_k","recommended_value":20}],"retriever_id":"ret_abc123"}]},"InteractionType":{"type":"string","enum":["impression","view","click","dwell","positive_feedback","negative_feedback","purchase","add_to_cart","wishlist","long_view","share","bookmark","query_refinement","zero_results","filter_toggle","skip","return_to_results","play","download","save","add_to_project","rating"],"title":"InteractionType","description":"Types of user interactions with search results.\n\nThese interaction types are used to track user behavior and improve retrieval quality\nthrough Learning to Rank (LTR), collaborative filtering, and embedding fine-tuning.\n\nValues:\n    IMPRESSION: Result was rendered on screen (passive signal, no user action)\n    VIEW: User viewed a search result\n    CLICK: User clicked on a search result\n    DWELL: User lingered on a result (weaker than long_view, stronger than view)\n    POSITIVE_FEEDBACK: User explicitly marked result as relevant/helpful\n    NEGATIVE_FEEDBACK: User explicitly marked result as not relevant\n    PURCHASE: User purchased the item (high-value conversion signal)\n    ADD_TO_CART: User added item to cart (mid-funnel signal)\n    WISHLIST: User saved item for later (engagement signal)\n    LONG_VIEW: User spent significant time viewing (dwell time)\n    SHARE: User shared the result (strong engagement signal)\n    BOOKMARK: User bookmarked the result\n    QUERY_REFINEMENT: User modified their search query\n    ZERO_RESULTS: Query yielded no results (helps identify gaps)\n    FILTER_TOGGLE: User modified filters (helps understand intent)\n    SKIP: User skipped over result to click something lower (negative signal)\n    RETURN_TO_RESULTS: User quickly returned to results (negative signal)\n\nUsage in Retrieval Optimization:\n    - LTR (Learning to Rank): Train models to predict click-through rates\n    - Collaborative Filtering: Find similar users/items based on interactions\n    - Embedding Fine-tuning: Adjust embeddings based on what users actually click\n    - Query Understanding: Analyze refinements and zero-result queries\n    - Result Quality: Identify poorly-performing results via skip/return patterns"},"InteractionWeights":{"properties":{"weights":{"additionalProperties":{"type":"number"},"type":"object","title":"Weights","description":"Mapping of interaction_type -> weight (higher = more important)."}},"type":"object","title":"InteractionWeights","description":"Custom weights for different interaction types when computing metrics.\n\nHigher weights indicate more importance. Purchases typically have higher weight\nthan clicks because they're a stronger signal of user intent.\n\nExample: {\"click\": 1.0, \"purchase\": 5.0, \"add_to_cart\": 2.0, \"bookmark\": 1.5}"},"InternalACLModel":{"properties":{"owner":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Owner","description":"Principal ID of the document owner (the creator).","examples":["user_alice","usr_12345"]},"read":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Read","description":"List of principal IDs that can read this document.","examples":[["user_alice","user_bob"]]},"write":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Write","description":"List of principal IDs that can write/update this document.","examples":[["user_alice"]]},"public":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Public","description":"If true, any user-scoped key can read this document.","default":false}},"additionalProperties":true,"type":"object","title":"InternalACLModel","description":"Access control list for document-level security (row-level security).\n\nControls which end-user principals can read/write a document.\nUsed with user-scoped API keys (keys with principal_id set).\nOrg-scoped keys bypass ACL entirely."},"InternalLineageModel":{"properties":{"root_object_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Root Object Id","description":"Original object ID from bucket (root of decomposition tree). All documents derived from the same object share this ID.","examples":["obj_video123","obj_document456"]},"root_bucket_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Root Bucket Id","description":"Bucket ID containing the root object.","examples":["bkt_marketing","bkt_documents"]},"source_type":{"anyOf":[{"type":"string","enum":["bucket","collection","direct_upsert","signal"]},{"type":"null"}],"title":"Source Type","description":"Type of immediate parent source. 'bucket': Document created directly from bucket object (tier 1). 'collection': Document created from another collection (tier 2+).","examples":["bucket","collection"]},"source_object_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Object Id","description":"Object ID of immediate parent when source_type='bucket'.","examples":["obj_video123"]},"source_document_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Document Id","description":"Document ID of immediate parent when source_type='collection'.","examples":["doc_frame050"]},"source_collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Collection Id","description":"Collection ID of immediate parent when source_type='collection'.","examples":["col_video_frames"]},"path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Path","description":"Materialized lineage path string (e.g., 'bkt_123/col_456/col_789').","examples":["bkt_marketing/col_video_frames","bkt_docs/col_chapters/col_paragraphs"]},"chain":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Chain","description":"Ordered list of processing steps from root object to this document. Each step contains: collection_id, feature_extractor_id, document_id, timestamp.","examples":[[{"collection_id":"col_frames","feature_extractor_id":"multimodal_extractor_v1","timestamp":"2025-10-31T10:00:00Z"}]]}},"additionalProperties":true,"type":"object","title":"InternalLineageModel","description":"Lineage tracking information for document provenance.\n\nTracks the complete processing history from the original bucket object\nthrough all transformation stages in the decomposition tree."},"InternalPayloadModel":{"properties":{"internal_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Internal Id","description":"Organization/tenant identifier for multi-tenancy isolation.","examples":["org_abc123"]},"namespace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Namespace Id","description":"Namespace identifier within the organization.","examples":["ns_xyz789"]},"document_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Id","description":"Document identifier (also at root level for convenience).","examples":["doc_f8966ff29c18e20c6b45e053"]},"collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Collection Id","description":"Collection identifier (also at root level for convenience).","examples":["col_articles","col_video_frames"]},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At","description":"ISO 8601 timestamp when document was created.","examples":["2025-10-31T10:00:00Z"]},"updated_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Updated At","description":"ISO 8601 timestamp when document was last updated.","examples":["2025-10-31T10:05:00Z"]},"lineage":{"anyOf":[{"$ref":"#/components/schemas/InternalLineageModel"},{"type":"null"}],"description":"Document lineage and provenance tracking."},"processing":{"anyOf":[{"$ref":"#/components/schemas/InternalProcessingModel"},{"type":"null"}],"description":"Processing history and provenance metadata."},"source_blobs":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Source Blobs","description":"Blobs that constituted the original source object.","examples":[[{"blob_id":"blob_video_001","blob_property":"video","blob_type":"video"}]]},"document_blobs":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Document Blobs","description":"Blobs generated during document processing (thumbnails, etc.).","examples":[[{"field":"thumbnail","role":"thumbnail","type":"image","url":"s3://..."}]]},"source_details":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Source Details","description":"Enrichment tracking and source detail entries."},"modality":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Modality","description":"Content modality (text, image, video, audio, etc.).","examples":["text","image","video","audio"]},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"System metadata including ingestion_status, feature_extractor_config_hash, and other processing-related information.","examples":[{"feature_extractor_config_hash":"abc123","ingestion_status":"COMPLETED"}]},"mime_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mime Type","description":"MIME type of the source content.","examples":["video/mp4","image/jpeg","text/plain"]},"size_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Size Bytes","description":"Size of the source content in bytes.","examples":[1024000,5242880]},"content_hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Content Hash","description":"SHA256 hash of the source content for deduplication.","examples":["e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"]},"_acl":{"anyOf":[{"$ref":"#/components/schemas/InternalACLModel"},{"type":"null"}],"description":"Access control list for document-level security. Controls which user-scoped API keys can read/write this document. Org-scoped keys bypass ACL entirely."}},"additionalProperties":true,"type":"object","title":"InternalPayloadModel","description":"Complete _internal field structure for vector store document payloads.\n\nAll Mixpeek-managed system fields are namespaced under this structure to:\n- Prevent collision with user-defined fields\n- Provide clear separation of system vs user data\n- Enable filtering on internal fields via _internal.field_name paths\n\nThis structure is stored in the vector store and returned in API responses.","examples":[{"collection_id":"col_articles","created_at":"2025-10-31T10:00:00Z","document_id":"doc_f8966ff29c","internal_id":"org_abc123","lineage":{"path":"bkt_content/col_articles","root_bucket_id":"bkt_content","root_object_id":"obj_article_001","source_object_id":"obj_article_001","source_type":"bucket"},"metadata":{"ingestion_status":"COMPLETED"},"modality":"text","namespace_id":"ns_xyz789","updated_at":"2025-10-31T10:00:00Z"}]},"InternalProcessingModel":{"properties":{"source_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Url","description":"Original URL before S3 mirroring (for URL-based ingestion).","examples":["https://example.com/video.mp4"]},"object_key_source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Object Key Source","description":"S3 key source identifier."},"detected_mime_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Detected Mime Type","description":"MIME type detected during canonicalization.","examples":["video/mp4","image/jpeg","application/pdf"]},"history":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"History","description":"Processing steps history with timestamps and operations.","examples":[[{"operation":"taxonomy_join","taxonomy_ids_applied":["tax_industries"],"timestamp":"2025-10-22T11:03:22Z"}]]},"taxonomy_lineage":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Taxonomy Lineage","description":"Taxonomy enrichment entries applied to this document."},"last_health_check":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Last Health Check","description":"Last health check result (for batch processing)."}},"additionalProperties":true,"type":"object","title":"InternalProcessingModel","description":"Processing and provenance tracking information.\n\nConsolidates all processing-related metadata including source URLs,\nprocessing history, and taxonomy enrichment lineage."},"InviteUserRequest":{"properties":{"email_address":{"type":"string","title":"Email Address","description":"Email address to invite"},"role":{"type":"string","title":"Role","description":"Clerk org role (org:admin or org:member)","default":"org:member"}},"type":"object","required":["email_address"],"title":"InviteUserRequest"},"InvoiceInfo":{"properties":{"invoice_id":{"type":"string","title":"Invoice Id","description":"Stripe Invoice ID","examples":["in_1ABC2DEF3GHI"]},"invoice_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Invoice Url","description":"Stripe-hosted invoice URL (None if not yet finalized)","examples":["https://invoice.stripe.com/i/inv_1ABC2DEF3GHI"]},"invoice_pdf":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Invoice Pdf","description":"PDF download URL (None if not yet finalized)","examples":["https://invoice.stripe.com/i/inv_1ABC2DEF3GHI/pdf"]},"amount_due":{"type":"integer","title":"Amount Due","description":"Amount due in cents","examples":[2345]},"amount_paid":{"type":"integer","title":"Amount Paid","description":"Amount paid in cents","examples":[2345]},"status":{"type":"string","title":"Status","description":"Invoice status","examples":["paid","open","void","uncollectible"]},"billing_month":{"type":"string","title":"Billing Month","description":"Billing month (YYYY-MM)","examples":["2025-11"]},"total_credits":{"type":"integer","title":"Total Credits","description":"Total credits billed","examples":[23450]},"created":{"type":"string","format":"date-time","title":"Created","description":"When invoice was created"},"paid_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Paid At","description":"When invoice was paid"},"platform_fee_cents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Platform Fee Cents","description":"Monthly platform fee component in cents (delineated)"},"cloud_fee_cents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Cloud Fee Cents","description":"Cloud passthrough + markup (platform_fee mode) or metered usage (platform_only mode) component in cents"},"platform_fee_billed_externally":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Platform Fee Billed Externally","description":"True when the platform fee is settled outside this system — it is then excluded from amount_due and should render as 'billed externally' rather than unpaid"}},"type":"object","required":["invoice_id","amount_due","amount_paid","status","billing_month","total_credits","created"],"title":"InvoiceInfo","description":"Information about a monthly invoice."},"InvoiceListResponse":{"properties":{"invoices":{"items":{"$ref":"#/components/schemas/InvoiceInfo"},"type":"array","title":"Invoices","description":"List of invoices"},"total":{"type":"integer","title":"Total","description":"Total number of invoices"},"has_more":{"type":"boolean","title":"Has More","description":"Whether there are more invoices"}},"type":"object","required":["total","has_more"],"title":"InvoiceListResponse","description":"Response with list of invoices."},"JoinMode":{"type":"string","enum":["on_demand","batch"],"title":"JoinMode"},"JoinResponse":{"properties":{"stats":{"$ref":"#/components/schemas/JoinStats"},"results":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Results"},"matches":{"anyOf":[{"items":{"$ref":"#/components/schemas/TaxonomyMatch"},"type":"array"},{"type":"null"}],"title":"Matches","description":"Flattened per-document match summaries extracted from processing_history — convenience for clients so they don't have to spelunk metadata.processing_history."}},"type":"object","required":["stats"],"title":"JoinResponse"},"JoinStats":{"properties":{"processed_docs":{"type":"integer","title":"Processed Docs","default":0},"batches":{"type":"integer","title":"Batches","default":0},"errors":{"type":"integer","title":"Errors","default":0},"enriched":{"type":"integer","title":"Enriched","default":0}},"type":"object","title":"JoinStats"},"KMeansParams":{"properties":{"n_clusters":{"type":"integer","maximum":1000.0,"minimum":2.0,"title":"N Clusters","description":"Number of clusters to form","default":8},"max_iter":{"type":"integer","maximum":10000.0,"minimum":1.0,"title":"Max Iter","description":"Maximum number of iterations","default":300},"random_state":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Random State","description":"Random seed for reproducibility","default":42},"n_init":{"type":"integer","minimum":1.0,"title":"N Init","description":"Number of times k-means will run with different centroid seeds","default":10},"tol":{"type":"number","exclusiveMinimum":0.0,"title":"Tol","description":"Tolerance for convergence","default":0.0001},"init":{"type":"string","title":"Init","description":"Method for initialization ('k-means++' or 'random')","default":"k-means++"},"verbose":{"type":"integer","minimum":0.0,"title":"Verbose","description":"Verbosity mode","default":0},"copy_x":{"type":"boolean","title":"Copy X","description":"If True, the original data is not modified","default":true},"algorithm":{"type":"string","title":"Algorithm","description":"K-means algorithm to use ('lloyd', 'elkan', or 'auto')","default":"lloyd"}},"type":"object","title":"KMeansParams","description":"Parameters for K-Means clustering algorithm."},"KeyStatus":{"type":"string","enum":["active","revoked","expired"],"title":"KeyStatus","description":"Lifecycle state of an API key.\n\nStatus determines whether an API key can be used for authentication:\n\n- ACTIVE: Key is valid and can be used for API requests. Last_used_at timestamp\n  is updated on each successful authentication.\n- REVOKED: Key has been manually revoked by an admin or user. Cannot be\n  reactivated. A new key must be created instead.\n- EXPIRED: Key has passed its expires_at timestamp. Automatically set by the\n  authentication system, and derived from expires_at: extending expires_at\n  past now makes the key ACTIVE again on its next use (only from EXPIRED,\n  never from REVOKED)."},"KeysetPaginationParams":{"properties":{"method":{"type":"string","const":"keyset","title":"Method","description":"Constant identifying keyset pagination (REQUIRED).","default":"keyset"},"limit":{"type":"integer","maximum":500.0,"minimum":1.0,"title":"Limit","description":"Maximum number of documents to return per page (REQUIRED). Default: 10.","default":10},"after":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"After","description":"Last seen keyset marker from previous response (OPTIONAL). Must include all sort fields. Example: {'score': 0.73, 'id': 'doc_20'}. null for first page, then use next_cursor from response"}},"type":"object","title":"KeysetPaginationParams","description":"Stateless keyset pagination relying on last seen sort key.\n\nBest for: High-performance pagination, large result sets, stable sorting\n\nHow it works:\n- Uses actual field values as pagination markers\n- Database can use indexes efficiently (WHERE score < 0.73)\n- No offset calculation or server state\n- Requires deterministic sort order (e.g., score DESC, id ASC)\n- Most efficient pagination method\n\nRequirements:\n- Results must be sorted consistently\n- Sort fields must be in the \"after\" marker\n- Example: sorted by (score DESC, id ASC) → after: {score: 0.73, id: \"doc_20\"}\n\nAdvantages:\n- No server-side state (truly stateless)\n- Consistent even with concurrent writes\n- Database can use indexes (fast for large datasets)\n- No offset performance degradation\n\nUse when:\n- You have stable, deterministic sort fields\n- Working with large result sets (10k+ docs)\n- Maximum performance is critical\n- You need infinite scroll with best efficiency\n\nExample flow:\n1. Request: {\"method\": \"keyset\", \"limit\": 20, \"after\": null}\n2. Response: {\"documents\": [...], \"next_cursor\": {\"score\": 0.85, \"id\": \"doc_20\"}}\n3. Request: {\"method\": \"keyset\", \"limit\": 20, \"after\": {\"score\": 0.85, \"id\": \"doc_20\"}}"},"KeywordIndexParams":{"properties":{"type":{"type":"string","title":"Type","default":"keyword"},"is_tenant":{"type":"boolean","title":"Is Tenant","default":false}},"type":"object","title":"KeywordIndexParams","description":"Configuration for keyword index."},"LLMLabeling-Input":{"properties":{"enabled":{"type":"boolean","title":"Enabled","description":"Whether to generate labels for clusters using LLM. When enabled, clusters will have semantic labels like 'High-Performance Laptops' instead of generic labels like 'Cluster 0'.","default":false},"labeling_inputs":{"anyOf":[{"$ref":"#/components/schemas/LLMLabelingInput-Input"},{"type":"null"}],"description":"Input configuration for LLM labeling. Supports flexible input mappings for multimodal inputs (text, images, videos, audio). Use input_mappings for advanced multimodal labeling with providers like Gemini. If not provided (null/undefined), the full document payload is serialized as JSON and sent to the LLM — WARNING: in practice this produces schema-metadata labels (e.g. 'Mid-Timeline Video Events' with keywords like ['start_time', 'end_time']) because the LLM describes whatever field names it sees. For meaningful labels, set input_mappings that point at semantic fields (title, description, thumbnail_url, document_blobs[].url for image/video content) rather than relying on the default."},"provider":{"anyOf":[{"$ref":"#/components/schemas/LLMProvider"},{"type":"null"}],"description":"LLM provider to use for labeling. Supported providers:\n- openai: GPT models (GPT-4o, GPT-4o-mini, GPT-4.1, O3-mini)\n- google: Gemini models (Gemini 2.5 Flash, Gemini 1.5 Flash)\n- anthropic: Claude models (Claude 3.5 Sonnet, Claude 3.5 Haiku)\n- typesafe: Jev (jev-latest). Picks each cluster's label from candidate_labels with a calibrated probability instead of writing one. Text only: it reads the representative documents' text fields.\n\nIf not specified, automatically inferred from model_name.","examples":["openai","google","anthropic"]},"model_name":{"anyOf":[{"$ref":"#/components/schemas/OpenAIModel"},{"$ref":"#/components/schemas/GoogleModel"},{"$ref":"#/components/schemas/AnthropicModel"},{"$ref":"#/components/schemas/TypeSafeModel"},{"type":"null"}],"title":"Model Name","description":"REQUIRED when enabled=True. Specific LLM model to use for cluster labeling. All models are defined as enums for type safety.\n\nOpenAI Models (provider='openai'):\n- gpt-4o-2024-08-06: Highest quality, best for production ($2.50/$10 per 1M tokens)\n- gpt-4o-mini-2024-07-18: Cost-effective, recommended for most use cases ($0.15/$0.60 per 1M tokens)\n- gpt-4.1-2025-04-14: Latest model, future-proofed\n- gpt-4.1-mini-2025-04-14: Latest cost-optimized model\n- o3-mini-2025-01-31: Advanced reasoning, best for complex clustering\n\nGoogle Models (provider='google'):\n- gemini-3.5-flash-lite: Fastest, latest multimodal model, recommended ($0.30/$2.50 per 1M tokens)\n\nAnthropic Models (provider='anthropic'):\n- claude-3-5-sonnet-20241022: Best reasoning, 200K context ($3/$15 per 1M tokens)\n- claude-3-5-haiku-20241022: Fast, cost-effective ($0.25/$1.25 per 1M tokens)\n\nRecommendation:\n- Use gemini-3.5-flash-lite (DEFAULT) - multimodal support\n- Use gpt-4o-mini-2024-07-18 for OpenAI compatibility\n- Use gpt-4o-2024-08-06 for highest quality when cost is not a concern","examples":["gemini-3.5-flash-lite","gemini-2.5-pro","gpt-4o-mini-2024-07-18","gpt-4o-2024-08-06","claude-sonnet-4-5-20250929","claude-haiku-4-5-20251001","gpt-4.1-2025-04-14","gpt-4.1-mini-2025-04-14","o3-mini-2025-01-31"]},"include_summary":{"type":"boolean","title":"Include Summary","description":"Whether to generate cluster summaries","default":true},"include_keywords":{"type":"boolean","title":"Include Keywords","description":"Whether to extract keywords for clusters","default":true},"max_samples_per_cluster":{"anyOf":[{"type":"integer","maximum":20.0,"minimum":1.0},{"type":"null"}],"title":"Max Samples Per Cluster","description":"Maximum representative documents to send to LLM per cluster for semantic analysis. When null (default), automatically scales based on cluster size and spread — smaller/tighter clusters get fewer samples, larger/sparser clusters get more (range 3-20). Set explicitly to override with a fixed value."},"sample_text_max_length":{"type":"integer","maximum":500.0,"minimum":50.0,"title":"Sample Text Max Length","description":"Maximum characters per document sample text","default":200},"sample_selection_strategy":{"type":"string","enum":["nearest","representative"],"title":"Sample Selection Strategy","description":"How representative documents are chosen for the labeling LLM. 'nearest' (default): the N members closest to the cluster centroid — maximally prototypical, but adjacent clusters can yield near-identical sample sets and therefore near-identical labels. 'representative': a mixed panel of ~40% nearest-to-centroid, ~40% diversity picks (farthest-point coverage of the cluster's extent), and ~20% high-density examples — differentiates similar clusters at the same sample count and LLM cost.","default":"nearest"},"use_embedding_dedup":{"type":"boolean","title":"Use Embedding Dedup","description":"Enable embedding-based label deduplication to prevent near-duplicate labels (requires sentence-transformers)","default":true},"embedding_similarity_threshold":{"type":"number","maximum":1.0,"minimum":0.5,"title":"Embedding Similarity Threshold","description":"Cosine similarity threshold for duplicate label detection (labels above this are considered duplicates)","default":0.8},"cache_ttl_seconds":{"type":"integer","maximum":2592000.0,"minimum":0.0,"title":"Cache Ttl Seconds","description":"Time-to-live for cached labels in seconds. Labels for clusters with identical representative documents will be reused within this TTL window, reducing LLM API costs. Default: 604800 (7 days). Set to 0 to disable caching.","default":604800},"labeling_context":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Labeling Context","description":"OPTIONAL. Freeform domain context about the data being clustered, injected into the labeling prompt as a clearly-delimited 'Domain context provided by the user' block. Unlike custom_prompt, this does NOT replace the default prompt — it grounds the default labeler so labels use the right domain vocabulary. Example: 'These are scenes from pharmaceutical TV ads' turns generic labels like 'People Talking Outdoors' into 'Patient Testimonial Scenes'. Max 2000 characters.","examples":["These are scenes from pharmaceutical TV advertisements","Customer support tickets for a video streaming platform",null]},"custom_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Prompt","description":"OPTIONAL. Custom prompt template for LLM labeling. NOT REQUIRED - uses default discriminative prompt if not provided. When provided, completely replaces the default prompt. Your custom prompt receives cluster information but you must format it yourself. Use when:   - Need domain-specific labeling (e.g., medical, legal, technical)   - Want different label format (e.g., emoji labels, code names)   - Require specific output structure   - Have custom business logic for categorization Default prompt includes: cluster document samples, forbidden labels for uniqueness, and JSON response format. See engine/clusters/labeling/prompts.py for reference. Example: 'Analyze these product clusters and generate SHORT category names (2-3 words max) focusing on product type and price range. Return JSON: [{\"cluster_id\": \"cl_0\", \"label\": \"...\"}]'","examples":["Analyze these document clusters and generate technical labels (2-3 words). Focus on programming languages and frameworks mentioned. Return JSON: [{'cluster_id': 'cl_0', 'label': '...', 'keywords': [...]}]","Generate emoji-based labels for these clusters. Use 1-2 emojis that represent the main theme. Return JSON: [{'cluster_id': 'cl_0', 'label': '🚀 Tech Innovation'}]",null]},"response_shape":{"anyOf":[{"type":"string"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Response Shape","description":"OPTIONAL. Define custom structured output for LLM labeling. NOT REQUIRED - uses default structure (label, summary, keywords) if not provided. When provided, LLM output will match this structure and be stored in cluster documents. \n\nTwo modes supported:\n1. Natural language prompt (string): Describe desired output in plain English\n   - Service automatically infers JSON schema from your description\n   - Example: 'Extract cluster category, confidence score (0-1), and top 3 representative terms'\n   - Auto-generates schema with appropriate types (string, number, array, etc.)\n\n2. Explicit JSON schema (dict): Provide complete JSON schema for output structure\n   - Full control over output structure, types, and constraints\n   - Example: {'type': 'object', 'properties': {'category': {'type': 'string'}, ...}}\n\n\nUse when:\n  - Need custom metadata fields (confidence scores, sentiment, complexity)\n  - Want domain-specific structure (taxonomy hierarchies, entity extractions)\n  - Require specific data types (arrays, nested objects, enums)\n  - Have downstream schema requirements\n\n\nOutput fields are automatically added to cluster collection schema and stored in metadata.\nDefault behavior (if not provided): label (string), summary (string), keywords (array of strings)\n","examples":["Extract cluster category, confidence score between 0 and 1, and top 3 representative keywords","Generate cluster theme, sentiment (positive/negative/neutral), and list of key entities",{"properties":{"category":{"description":"Main category","type":"string"},"subcategory":{"description":"Subcategory if applicable","type":"string"},"confidence":{"maximum":1,"minimum":0,"type":"number"},"keywords":{"items":{"type":"string"},"maxItems":5,"type":"array"}},"required":["category","confidence"],"type":"object"},null]},"parameters":{"additionalProperties":true,"type":"object","title":"Parameters","description":"Provider-specific parameters forwarded to the LLM service. For OpenAI: temperature, max_tokens, top_p, json_output, etc. For Google: temperature, top_k, max_output_tokens, json_output, etc."},"candidate_labels":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"null"}]},"type":"object"},{"type":"null"}],"title":"Candidate Labels","description":"OPTIONAL. A fixed vocabulary to label clusters from. Each cluster gets the candidate that best fits its representative documents, instead of a freshly written name. Pass a list of labels, or a map of label to a one-line description of what belongs under it. Up to 255 labels. REQUIRED when provider is 'typesafe' (Jev) unless response_shape is an explicit schema of closed-set fields, because Jev picks from options and does not write text. The picked label's probability is stored as label_confidence. Useful for mapping clusters onto an existing taxonomy level, and for labeling every level of a hierarchical run with a consistent vocabulary.","examples":[["Skateboarding","Surfing","Snowboarding","Cooking"],{"Product Demo":"Someone shows how a product works","Testimonial":"A customer talks about their experience"},null]}},"type":"object","title":"LLMLabeling","description":"Configuration for LLM-based cluster labeling.\n\nSupports multiple LLM providers with comprehensive model selection:\n- OpenAI: GPT-4o, GPT-4o-mini, GPT-4.1, O3-mini (best for quality)\n- Google: Gemini 2.5 Flash, Gemini 1.5 Flash (best for speed and cost)\n- Anthropic: Claude 3.5 Sonnet, Claude 3.5 Haiku (best for reasoning)\n\nAll models are defined as enums and validated at API level.","examples":[{"description":"Text-only labeling with multiple fields","enabled":true,"include_keywords":true,"include_summary":true,"labeling_inputs":{"input_mappings":[{"input_key":"title","path":"title","source_type":"payload"},{"input_key":"description","path":"description","source_type":"payload"},{"input_key":"text","path":"text","source_type":"payload"}]},"model_name":"gpt-4o-mini-2024-07-18","provider":"openai"},{"description":"Multimodal labeling with images (Gemini)","enabled":true,"include_keywords":true,"include_summary":true,"labeling_inputs":{"input_mappings":[{"input_key":"text","path":"headline","source_type":"payload"},{"input_key":"image_url","path":"thumbnail_url","source_type":"payload"}]},"model_name":"gemini-3.5-flash-lite","provider":"google"},{"description":"Multimodal labeling with video (Gemini)","enabled":true,"include_keywords":true,"include_summary":true,"labeling_inputs":{"input_mappings":[{"input_key":"text","path":"description","source_type":"payload"},{"input_key":"video_url","path":"video_url","source_type":"payload"}]},"model_name":"gemini-3.5-flash-lite","provider":"google"},{"description":"OpenAI GPT-4o (highest quality, text-only)","enabled":true,"include_keywords":true,"include_summary":true,"labeling_inputs":{"input_mappings":[{"input_key":"text","path":"text","source_type":"payload"}]},"model_name":"gpt-4o-2024-08-06","provider":"openai"},{"description":"Anthropic Claude 3.5 Sonnet (best reasoning)","enabled":true,"include_keywords":true,"include_summary":true,"labeling_inputs":{"input_mappings":[{"input_key":"text","path":"text","source_type":"payload"}]},"model_name":"claude-sonnet-4-5-20250929","provider":"anthropic"},{"description":"Minimal configuration (uses defaults: text field from payload)","enabled":true},{"custom_prompt":"You are a medical document classifier. Analyze the following patient record clusters and generate HIPAA-compliant category labels (2-3 words) that describe the medical condition or treatment type. DO NOT include patient names or identifiers. Return JSON array: [{\"cluster_id\": \"cl_0\", \"label\": \"...\", \"keywords\": [...]}]","description":"Custom prompt for domain-specific labeling","enabled":true,"labeling_inputs":{"input_mappings":[{"input_key":"text","path":"text","source_type":"payload"}]},"model_name":"gpt-4o-mini-2024-07-18","provider":"openai"}]},"LLMLabeling-Output":{"properties":{"enabled":{"type":"boolean","title":"Enabled","description":"Whether to generate labels for clusters using LLM. When enabled, clusters will have semantic labels like 'High-Performance Laptops' instead of generic labels like 'Cluster 0'.","default":false},"labeling_inputs":{"anyOf":[{"$ref":"#/components/schemas/LLMLabelingInput-Output"},{"type":"null"}],"description":"Input configuration for LLM labeling. Supports flexible input mappings for multimodal inputs (text, images, videos, audio). Use input_mappings for advanced multimodal labeling with providers like Gemini. If not provided (null/undefined), the full document payload is serialized as JSON and sent to the LLM — WARNING: in practice this produces schema-metadata labels (e.g. 'Mid-Timeline Video Events' with keywords like ['start_time', 'end_time']) because the LLM describes whatever field names it sees. For meaningful labels, set input_mappings that point at semantic fields (title, description, thumbnail_url, document_blobs[].url for image/video content) rather than relying on the default."},"provider":{"anyOf":[{"$ref":"#/components/schemas/LLMProvider"},{"type":"null"}],"description":"LLM provider to use for labeling. Supported providers:\n- openai: GPT models (GPT-4o, GPT-4o-mini, GPT-4.1, O3-mini)\n- google: Gemini models (Gemini 2.5 Flash, Gemini 1.5 Flash)\n- anthropic: Claude models (Claude 3.5 Sonnet, Claude 3.5 Haiku)\n- typesafe: Jev (jev-latest). Picks each cluster's label from candidate_labels with a calibrated probability instead of writing one. Text only: it reads the representative documents' text fields.\n\nIf not specified, automatically inferred from model_name.","examples":["openai","google","anthropic"]},"model_name":{"anyOf":[{"$ref":"#/components/schemas/OpenAIModel"},{"$ref":"#/components/schemas/GoogleModel"},{"$ref":"#/components/schemas/AnthropicModel"},{"$ref":"#/components/schemas/TypeSafeModel"},{"type":"null"}],"title":"Model Name","description":"REQUIRED when enabled=True. Specific LLM model to use for cluster labeling. All models are defined as enums for type safety.\n\nOpenAI Models (provider='openai'):\n- gpt-4o-2024-08-06: Highest quality, best for production ($2.50/$10 per 1M tokens)\n- gpt-4o-mini-2024-07-18: Cost-effective, recommended for most use cases ($0.15/$0.60 per 1M tokens)\n- gpt-4.1-2025-04-14: Latest model, future-proofed\n- gpt-4.1-mini-2025-04-14: Latest cost-optimized model\n- o3-mini-2025-01-31: Advanced reasoning, best for complex clustering\n\nGoogle Models (provider='google'):\n- gemini-3.5-flash-lite: Fastest, latest multimodal model, recommended ($0.30/$2.50 per 1M tokens)\n\nAnthropic Models (provider='anthropic'):\n- claude-3-5-sonnet-20241022: Best reasoning, 200K context ($3/$15 per 1M tokens)\n- claude-3-5-haiku-20241022: Fast, cost-effective ($0.25/$1.25 per 1M tokens)\n\nRecommendation:\n- Use gemini-3.5-flash-lite (DEFAULT) - multimodal support\n- Use gpt-4o-mini-2024-07-18 for OpenAI compatibility\n- Use gpt-4o-2024-08-06 for highest quality when cost is not a concern","examples":["gemini-3.5-flash-lite","gemini-2.5-pro","gpt-4o-mini-2024-07-18","gpt-4o-2024-08-06","claude-sonnet-4-5-20250929","claude-haiku-4-5-20251001","gpt-4.1-2025-04-14","gpt-4.1-mini-2025-04-14","o3-mini-2025-01-31"]},"include_summary":{"type":"boolean","title":"Include Summary","description":"Whether to generate cluster summaries","default":true},"include_keywords":{"type":"boolean","title":"Include Keywords","description":"Whether to extract keywords for clusters","default":true},"max_samples_per_cluster":{"anyOf":[{"type":"integer","maximum":20.0,"minimum":1.0},{"type":"null"}],"title":"Max Samples Per Cluster","description":"Maximum representative documents to send to LLM per cluster for semantic analysis. When null (default), automatically scales based on cluster size and spread — smaller/tighter clusters get fewer samples, larger/sparser clusters get more (range 3-20). Set explicitly to override with a fixed value."},"sample_text_max_length":{"type":"integer","maximum":500.0,"minimum":50.0,"title":"Sample Text Max Length","description":"Maximum characters per document sample text","default":200},"sample_selection_strategy":{"type":"string","enum":["nearest","representative"],"title":"Sample Selection Strategy","description":"How representative documents are chosen for the labeling LLM. 'nearest' (default): the N members closest to the cluster centroid — maximally prototypical, but adjacent clusters can yield near-identical sample sets and therefore near-identical labels. 'representative': a mixed panel of ~40% nearest-to-centroid, ~40% diversity picks (farthest-point coverage of the cluster's extent), and ~20% high-density examples — differentiates similar clusters at the same sample count and LLM cost.","default":"nearest"},"use_embedding_dedup":{"type":"boolean","title":"Use Embedding Dedup","description":"Enable embedding-based label deduplication to prevent near-duplicate labels (requires sentence-transformers)","default":true},"embedding_similarity_threshold":{"type":"number","maximum":1.0,"minimum":0.5,"title":"Embedding Similarity Threshold","description":"Cosine similarity threshold for duplicate label detection (labels above this are considered duplicates)","default":0.8},"cache_ttl_seconds":{"type":"integer","maximum":2592000.0,"minimum":0.0,"title":"Cache Ttl Seconds","description":"Time-to-live for cached labels in seconds. Labels for clusters with identical representative documents will be reused within this TTL window, reducing LLM API costs. Default: 604800 (7 days). Set to 0 to disable caching.","default":604800},"labeling_context":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Labeling Context","description":"OPTIONAL. Freeform domain context about the data being clustered, injected into the labeling prompt as a clearly-delimited 'Domain context provided by the user' block. Unlike custom_prompt, this does NOT replace the default prompt — it grounds the default labeler so labels use the right domain vocabulary. Example: 'These are scenes from pharmaceutical TV ads' turns generic labels like 'People Talking Outdoors' into 'Patient Testimonial Scenes'. Max 2000 characters.","examples":["These are scenes from pharmaceutical TV advertisements","Customer support tickets for a video streaming platform",null]},"custom_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Prompt","description":"OPTIONAL. Custom prompt template for LLM labeling. NOT REQUIRED - uses default discriminative prompt if not provided. When provided, completely replaces the default prompt. Your custom prompt receives cluster information but you must format it yourself. Use when:   - Need domain-specific labeling (e.g., medical, legal, technical)   - Want different label format (e.g., emoji labels, code names)   - Require specific output structure   - Have custom business logic for categorization Default prompt includes: cluster document samples, forbidden labels for uniqueness, and JSON response format. See engine/clusters/labeling/prompts.py for reference. Example: 'Analyze these product clusters and generate SHORT category names (2-3 words max) focusing on product type and price range. Return JSON: [{\"cluster_id\": \"cl_0\", \"label\": \"...\"}]'","examples":["Analyze these document clusters and generate technical labels (2-3 words). Focus on programming languages and frameworks mentioned. Return JSON: [{'cluster_id': 'cl_0', 'label': '...', 'keywords': [...]}]","Generate emoji-based labels for these clusters. Use 1-2 emojis that represent the main theme. Return JSON: [{'cluster_id': 'cl_0', 'label': '🚀 Tech Innovation'}]",null]},"response_shape":{"anyOf":[{"type":"string"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Response Shape","description":"OPTIONAL. Define custom structured output for LLM labeling. NOT REQUIRED - uses default structure (label, summary, keywords) if not provided. When provided, LLM output will match this structure and be stored in cluster documents. \n\nTwo modes supported:\n1. Natural language prompt (string): Describe desired output in plain English\n   - Service automatically infers JSON schema from your description\n   - Example: 'Extract cluster category, confidence score (0-1), and top 3 representative terms'\n   - Auto-generates schema with appropriate types (string, number, array, etc.)\n\n2. Explicit JSON schema (dict): Provide complete JSON schema for output structure\n   - Full control over output structure, types, and constraints\n   - Example: {'type': 'object', 'properties': {'category': {'type': 'string'}, ...}}\n\n\nUse when:\n  - Need custom metadata fields (confidence scores, sentiment, complexity)\n  - Want domain-specific structure (taxonomy hierarchies, entity extractions)\n  - Require specific data types (arrays, nested objects, enums)\n  - Have downstream schema requirements\n\n\nOutput fields are automatically added to cluster collection schema and stored in metadata.\nDefault behavior (if not provided): label (string), summary (string), keywords (array of strings)\n","examples":["Extract cluster category, confidence score between 0 and 1, and top 3 representative keywords","Generate cluster theme, sentiment (positive/negative/neutral), and list of key entities",{"properties":{"category":{"description":"Main category","type":"string"},"subcategory":{"description":"Subcategory if applicable","type":"string"},"confidence":{"maximum":1,"minimum":0,"type":"number"},"keywords":{"items":{"type":"string"},"maxItems":5,"type":"array"}},"required":["category","confidence"],"type":"object"},null]},"parameters":{"additionalProperties":true,"type":"object","title":"Parameters","description":"Provider-specific parameters forwarded to the LLM service. For OpenAI: temperature, max_tokens, top_p, json_output, etc. For Google: temperature, top_k, max_output_tokens, json_output, etc."},"candidate_labels":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"null"}]},"type":"object"},{"type":"null"}],"title":"Candidate Labels","description":"OPTIONAL. A fixed vocabulary to label clusters from. Each cluster gets the candidate that best fits its representative documents, instead of a freshly written name. Pass a list of labels, or a map of label to a one-line description of what belongs under it. Up to 255 labels. REQUIRED when provider is 'typesafe' (Jev) unless response_shape is an explicit schema of closed-set fields, because Jev picks from options and does not write text. The picked label's probability is stored as label_confidence. Useful for mapping clusters onto an existing taxonomy level, and for labeling every level of a hierarchical run with a consistent vocabulary.","examples":[["Skateboarding","Surfing","Snowboarding","Cooking"],{"Product Demo":"Someone shows how a product works","Testimonial":"A customer talks about their experience"},null]}},"type":"object","title":"LLMLabeling","description":"Configuration for LLM-based cluster labeling.\n\nSupports multiple LLM providers with comprehensive model selection:\n- OpenAI: GPT-4o, GPT-4o-mini, GPT-4.1, O3-mini (best for quality)\n- Google: Gemini 2.5 Flash, Gemini 1.5 Flash (best for speed and cost)\n- Anthropic: Claude 3.5 Sonnet, Claude 3.5 Haiku (best for reasoning)\n\nAll models are defined as enums and validated at API level.","examples":[{"description":"Text-only labeling with multiple fields","enabled":true,"include_keywords":true,"include_summary":true,"labeling_inputs":{"input_mappings":[{"input_key":"title","path":"title","source_type":"payload"},{"input_key":"description","path":"description","source_type":"payload"},{"input_key":"text","path":"text","source_type":"payload"}]},"model_name":"gpt-4o-mini-2024-07-18","provider":"openai"},{"description":"Multimodal labeling with images (Gemini)","enabled":true,"include_keywords":true,"include_summary":true,"labeling_inputs":{"input_mappings":[{"input_key":"text","path":"headline","source_type":"payload"},{"input_key":"image_url","path":"thumbnail_url","source_type":"payload"}]},"model_name":"gemini-3.5-flash-lite","provider":"google"},{"description":"Multimodal labeling with video (Gemini)","enabled":true,"include_keywords":true,"include_summary":true,"labeling_inputs":{"input_mappings":[{"input_key":"text","path":"description","source_type":"payload"},{"input_key":"video_url","path":"video_url","source_type":"payload"}]},"model_name":"gemini-3.5-flash-lite","provider":"google"},{"description":"OpenAI GPT-4o (highest quality, text-only)","enabled":true,"include_keywords":true,"include_summary":true,"labeling_inputs":{"input_mappings":[{"input_key":"text","path":"text","source_type":"payload"}]},"model_name":"gpt-4o-2024-08-06","provider":"openai"},{"description":"Anthropic Claude 3.5 Sonnet (best reasoning)","enabled":true,"include_keywords":true,"include_summary":true,"labeling_inputs":{"input_mappings":[{"input_key":"text","path":"text","source_type":"payload"}]},"model_name":"claude-sonnet-4-5-20250929","provider":"anthropic"},{"description":"Minimal configuration (uses defaults: text field from payload)","enabled":true},{"custom_prompt":"You are a medical document classifier. Analyze the following patient record clusters and generate HIPAA-compliant category labels (2-3 words) that describe the medical condition or treatment type. DO NOT include patient names or identifiers. Return JSON array: [{\"cluster_id\": \"cl_0\", \"label\": \"...\", \"keywords\": [...]}]","description":"Custom prompt for domain-specific labeling","enabled":true,"labeling_inputs":{"input_mappings":[{"input_key":"text","path":"text","source_type":"payload"}]},"model_name":"gpt-4o-mini-2024-07-18","provider":"openai"}]},"LLMLabelingInput-Input":{"properties":{"input_mappings":{"items":{"$ref":"#/components/schemas/InputMapping"},"type":"array","minItems":1,"title":"Input Mappings","description":"Flexible input mappings for constructing LLM context. Supports multimodal inputs (text, image_url, video_url, audio_url). Each mapping specifies how to extract data from document payloads. At least one input mapping is required."}},"type":"object","required":["input_mappings"],"title":"LLMLabelingInput","description":"Input configuration for LLM-based cluster labeling.\n\nSupports flexible input mappings similar to retrievers and buckets,\nallowing multimodal inputs (text, images, videos, audio) for providers\nlike Gemini that support native multimodal understanding.\n\nExamples:\n    # Text-only labeling:\n    LLMLabelingInput(input_mappings=[\n        InputMapping(input_key=\"headline\", source_type=\"payload\", path=\"headline\"),\n        InputMapping(input_key=\"description\", source_type=\"payload\", path=\"description\")\n    ])\n\n    # Multimodal labeling with images:\n    LLMLabelingInput(input_mappings=[\n        InputMapping(input_key=\"text\", source_type=\"payload\", path=\"headline\"),\n        InputMapping(input_key=\"image_url\", source_type=\"payload\", path=\"thumbnail_url\")\n    ])\n\n    # Multimodal with video (for Gemini):\n    LLMLabelingInput(input_mappings=[\n        InputMapping(input_key=\"text\", source_type=\"payload\", path=\"description\"),\n        InputMapping(input_key=\"video_url\", source_type=\"payload\", path=\"video_url\")\n    ])"},"LLMLabelingInput-Output":{"properties":{"input_mappings":{"items":{"$ref":"#/components/schemas/InputMapping"},"type":"array","minItems":1,"title":"Input Mappings","description":"Flexible input mappings for constructing LLM context. Supports multimodal inputs (text, image_url, video_url, audio_url). Each mapping specifies how to extract data from document payloads. At least one input mapping is required."}},"type":"object","required":["input_mappings"],"title":"LLMLabelingInput","description":"Input configuration for LLM-based cluster labeling.\n\nSupports flexible input mappings similar to retrievers and buckets,\nallowing multimodal inputs (text, images, videos, audio) for providers\nlike Gemini that support native multimodal understanding.\n\nExamples:\n    # Text-only labeling:\n    LLMLabelingInput(input_mappings=[\n        InputMapping(input_key=\"headline\", source_type=\"payload\", path=\"headline\"),\n        InputMapping(input_key=\"description\", source_type=\"payload\", path=\"description\")\n    ])\n\n    # Multimodal labeling with images:\n    LLMLabelingInput(input_mappings=[\n        InputMapping(input_key=\"text\", source_type=\"payload\", path=\"headline\"),\n        InputMapping(input_key=\"image_url\", source_type=\"payload\", path=\"thumbnail_url\")\n    ])\n\n    # Multimodal with video (for Gemini):\n    LLMLabelingInput(input_mappings=[\n        InputMapping(input_key=\"text\", source_type=\"payload\", path=\"description\"),\n        InputMapping(input_key=\"video_url\", source_type=\"payload\", path=\"video_url\")\n    ])"},"LLMProvider":{"type":"string","enum":["openai","google","anthropic","typesafe"],"title":"LLMProvider","description":"Supported LLM providers for content generation.\n\nEach provider has different strengths, pricing, and multimodal capabilities.\nChoose based on your use case, performance requirements, and budget.\n\nValues:\n    OPENAI: OpenAI GPT models (GPT-4o, GPT-4.1, O3-mini)\n        - Best for: General purpose, vision tasks, structured outputs\n        - Multimodal: Text, images\n        - Performance: Fast (100-500ms), reliable\n        - Cost: Moderate to high ($0.15-$10 per 1M tokens)\n        - Use when: Need high-quality generation with vision support\n\n    GOOGLE: Google Gemini models (Gemini 3.1 Flash Lite, Gemini 2.5 Pro)\n        - Best for: Fast generation, video understanding, cost-efficiency\n        - Multimodal: Text, images, video, audio, PDFs\n        - Performance: Very fast (50-200ms)\n        - Cost: Low to moderate ($0.075-$0.40 per 1M tokens)\n        - Use when: Need video/audio/PDF support or cost-efficiency\n\n    ANTHROPIC: Anthropic Claude models (Claude 3.5 Sonnet, Claude 3.5 Haiku)\n        - Best for: Long context, complex reasoning, safety\n        - Multimodal: Text, images\n        - Performance: Moderate (200-800ms)\n        - Cost: Moderate to high ($0.25-$15 per 1M tokens)\n        - Use when: Need long context or complex reasoning\n\nExamples:\n    - Use OPENAI for production with structured JSON outputs\n    - Use GOOGLE for video summarization and cost-sensitive workloads\n    - Use ANTHROPIC for complex reasoning with long documents\n\n    TYPESAFE: TypeSafe AI's Jev evaluation model\n        - Best for: classification, yes/no filtering, relevance scoring,\n          picking a label or branch from a fixed set\n        - Input: text only. Output: typed answers with calibrated\n          probabilities (choice, score, yes/no). It does not generate text.\n        - Cost: $0.042 per 1M input tokens, output free\n        - Use when: the step is a decision over a closed set of values"},"LabelDistributionResponse":{"properties":{"taxonomy_id":{"type":"string","title":"Taxonomy Id"},"labels":{"items":{"$ref":"#/components/schemas/LabelMetric"},"type":"array","title":"Labels"},"total_labels":{"type":"integer","title":"Total Labels","description":"Distinct labels that received at least one assignment in the window. This is the TRUE count and is not capped by `limit`; it used to be len(labels), i.e. the page size. Note it counts labels SEEN, so it is not the taxonomy's label vocabulary and cannot tell you which nodes are empty."},"labels_returned":{"type":"integer","title":"Labels Returned","description":"How many labels this page actually carries. Lower than `total_labels` means the response is truncated by `limit`.","default":0},"total_assignments":{"type":"integer","title":"Total Assignments","description":"Assignments across ALL labels in the window, uncapped. Each `LabelMetric.percentage` is computed against this, so the percentages are shares of the whole rather than of the page.","default":0},"truncated":{"type":"boolean","title":"Truncated","description":"True when labels were dropped by `limit`.","default":false}},"type":"object","required":["taxonomy_id","labels","total_labels"],"title":"LabelDistributionResponse","description":"Taxonomy label distribution response."},"LabelMetric":{"properties":{"label":{"type":"string","title":"Label"},"count":{"type":"integer","title":"Count"},"percentage":{"type":"number","title":"Percentage"},"avg_confidence":{"type":"number","title":"Avg Confidence"}},"type":"object","required":["label","count","percentage","avg_confidence"],"title":"LabelMetric","description":"Label distribution metrics."},"LatencyMetric":{"properties":{"time_bucket":{"type":"string","format":"date-time","title":"Time Bucket"},"document_count":{"type":"integer","title":"Document Count"},"avg_latency_ms":{"type":"number","title":"Avg Latency Ms"},"p95_latency_ms":{"type":"number","title":"P95 Latency Ms"},"p99_latency_ms":{"type":"number","title":"P99 Latency Ms"}},"type":"object","required":["time_bucket","document_count","avg_latency_ms","p95_latency_ms","p99_latency_ms"],"title":"LatencyMetric","description":"Latency distribution metric."},"LatencyMetrics":{"properties":{"p50_ms":{"type":"number","minimum":0.0,"title":"P50 Ms","description":"50th percentile latency in milliseconds."},"p90_ms":{"type":"number","minimum":0.0,"title":"P90 Ms","description":"90th percentile latency in milliseconds."},"p99_ms":{"type":"number","minimum":0.0,"title":"P99 Ms","description":"99th percentile latency in milliseconds."},"mean_ms":{"type":"number","minimum":0.0,"title":"Mean Ms","description":"Mean latency in milliseconds."},"stage_latencies":{"additionalProperties":{"type":"number"},"type":"object","title":"Stage Latencies","description":"Per-stage latency breakdown (stage_name -> avg_ms)."}},"type":"object","required":["p50_ms","p90_ms","p99_ms","mean_ms"],"title":"LatencyMetrics","description":"Performance timing statistics for a pipeline."},"LatencyResponse":{"properties":{"collection_id":{"type":"string","title":"Collection Id"},"time_range":{"$ref":"#/components/schemas/api__analytics__collections__models__TimeRange"},"metrics":{"items":{"$ref":"#/components/schemas/LatencyMetric"},"type":"array","title":"Metrics"},"slowest_documents":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Slowest Documents"}},"type":"object","required":["collection_id","time_range","metrics"],"title":"LatencyResponse","description":"Processing latency distribution."},"LayoutConfig":{"properties":{"mode":{"type":"string","title":"Mode","description":"Display mode for results","default":"grid","examples":["grid","list","masonry"]},"columns":{"type":"integer","maximum":6.0,"minimum":1.0,"title":"Columns","description":"Number of columns for grid/masonry layouts","default":3},"gap":{"type":"string","title":"Gap","description":"Gap between items","default":"16px","examples":["8px","16px","24px"]},"full_width":{"type":"boolean","title":"Full Width","description":"Whether to use full viewport width for the layout (edge-to-edge)","default":false}},"type":"object","title":"LayoutConfig","description":"Layout configuration for search results display."},"LeidenParams":{"properties":{"resolution":{"type":"number","maximum":100.0,"exclusiveMinimum":0.0,"title":"Resolution","description":"Resolution for the Leiden objective. Higher values yield more, smaller communities; lower values yield fewer, larger ones. Leiden discovers the cluster count from the graph — there is no fixed n_clusters.","default":1.0},"n_neighbors":{"type":"integer","maximum":200.0,"minimum":2.0,"title":"N Neighbors","description":"Number of nearest neighbours per node when building the kNN graph. Larger values give a denser graph (smoother communities) at higher build cost.","default":30},"metric":{"type":"string","title":"Metric","description":"Distance metric for kNN graph construction (cosine or euclidean).","default":"cosine"},"min_cluster_size":{"type":"integer","minimum":0.0,"title":"Min Cluster Size","description":"Communities smaller than this are relabelled as noise (cluster_id -1). 0 keeps every community.","default":0},"objective_function":{"type":"string","enum":["RBConfiguration","modularity","CPM"],"title":"Objective Function","description":"Leiden quality function. RBConfiguration and CPM honour the resolution parameter; modularity ignores it.","default":"RBConfiguration"},"n_iterations":{"type":"integer","title":"N Iterations","description":"Leiden optimisation passes. -1 runs until no further improvement; a small positive value (e.g. 2) is faster and usually sufficient.","default":2},"random_state":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Random State","description":"Random seed for reproducible partitions.","default":42}},"type":"object","title":"LeidenParams","description":"Parameters for Leiden graph community-detection clustering."},"LifecycleState":{"type":"string","enum":["active","cold","archived","frozen"],"title":"LifecycleState"},"LifecycleStatusResponse":{"properties":{"collection_id":{"type":"string","title":"Collection Id"},"lifecycle_state":{"$ref":"#/components/schemas/LifecycleState"},"s3_vector_index":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"S3 Vector Index"},"vector_document_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Vector Document Count"},"s3_vector_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"S3 Vector Count"},"last_transitioned_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Transitioned At"},"task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id"},"warning":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Warning"},"namespace_storage_tier":{"anyOf":[{"$ref":"#/components/schemas/NamespaceStorageTier"},{"type":"null"}],"description":"The storage rung of the namespace this collection belongs to. Absent until the namespace has been rated once."}},"type":"object","required":["collection_id","lifecycle_state"],"title":"LifecycleStatusResponse"},"LimitEntry":{"properties":{"name":{"type":"string","title":"Name","description":"The setting that was capped.","examples":["final_top_k","pagination_depth"]},"requested":{"type":"integer","title":"Requested","description":"The value the request asked for.","examples":[2000]},"applied":{"type":"integer","title":"Applied","description":"The value the platform used.","examples":[500]},"ceiling":{"type":"integer","title":"Ceiling","description":"The cap's maximum for this setting.","examples":[500]},"stage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stage","description":"The stage that applied the cap, when a stage did."}},"type":"object","required":["name","requested","applied","ceiling"],"title":"LimitEntry","description":"One cap that clamped a request (plan 6.10's ``limits``).\n\nReported when the platform applied a smaller value than the request asked\nfor, so a short result reads as the cap rather than as a no-match."},"LineageStep":{"properties":{"collection_id":{"type":"string","title":"Collection Id","description":"Collection ID where this processing step occurred","examples":["col_video_frames","col_scenes","col_embeddings"]},"feature_extractor_id":{"type":"string","title":"Feature Extractor Id","description":"Feature extractor that processed the data in this step","examples":["multimodal_extractor_v1","scene_detector_v1","text_extractor_v1"]},"document_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Id","description":"Document ID from this step (for intermediate steps). Allows tracing back through the decomposition tree.","examples":["doc_frame001","doc_scene005"]},"timestamp":{"type":"string","format":"date-time","title":"Timestamp","description":"When this processing step occurred","examples":["2025-10-18T10:30:00Z"]}},"type":"object","required":["collection_id","feature_extractor_id"],"title":"LineageStep","description":"Single processing step in a document's lineage chain.\n\nEach step represents one transformation in the decomposition tree,\ntracking which collection and feature extractor produced the document.\n\nExample:\n    ```python\n    step = LineageStep(\n        collection_id=\"col_video_frames\",\n        feature_extractor_id=\"multimodal_extractor_v1\",\n        document_id=\"doc_frame123\",\n        timestamp=datetime.now()\n    )\n    ```","examples":[{"collection_id":"col_video_frames","document_id":"doc_frame123","feature_extractor_id":"multimodal_extractor_v1","timestamp":"2025-10-18T10:30:00Z"}]},"LintResponse":{"properties":{"valid":{"type":"boolean","title":"Valid","description":"Whether the manifest is valid (no errors, warnings OK)"},"results":{"items":{"$ref":"#/components/schemas/LintResult"},"type":"array","title":"Results","description":"List of lint results"},"summary":{"additionalProperties":{"type":"integer"},"type":"object","title":"Summary","description":"Count of results by severity"}},"type":"object","required":["valid"],"title":"LintResponse","description":"Response from the lint endpoint.\n\nExample:\n    {\n        \"valid\": true,\n        \"results\": [...],\n        \"summary\": {\"error\": 0, \"warning\": 2, \"info\": 3}\n    }","examples":[{"results":[{"code":"UNUSED_COLLECTION","location":"collections[2]","message":"Collection 'orphan_data' is not referenced by any retriever","severity":"warning","suggestion":"Add a retriever that uses this collection or remove it"}],"summary":{"error":0,"info":0,"warning":1},"valid":true}]},"LintResult":{"properties":{"code":{"type":"string","title":"Code","description":"Lint rule code (e.g., 'UNUSED_EXTRACTOR', 'MISSING_INPUT_SCHEMA')"},"severity":{"$ref":"#/components/schemas/LintSeverity","description":"Severity level: error, warning, or info"},"message":{"type":"string","title":"Message","description":"Human-readable description of the issue"},"location":{"type":"string","title":"Location","description":"Path to the problematic element (e.g., 'retrievers[0].stages[2]')"},"suggestion":{"type":"string","title":"Suggestion","description":"Actionable suggestion for fixing the issue"},"fix_example":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fix Example","description":"Optional YAML example showing the correct configuration"}},"type":"object","required":["code","severity","message","location","suggestion"],"title":"LintResult","description":"A single lint result with actionable suggestion.\n\nExample:\n    {\n        \"code\": \"UNUSED_EXTRACTOR\",\n        \"severity\": \"warning\",\n        \"message\": \"Feature extractor 'text_extractor' in namespace 'my_ns' is not used by any collection\",\n        \"location\": \"namespaces[0].feature_extractors[1]\",\n        \"suggestion\": \"Remove the unused extractor or add a collection that uses it\",\n        \"fix_example\": \"collections:\\n  - name: text_docs\\n    feature_extractor:\\n      name: text_extractor\"\n    }","examples":[{"code":"MISSING_INPUT_SCHEMA","fix_example":"input_schema:\n  type: object\n  properties:\n    query:\n      type: string","location":"retrievers[0]","message":"Retriever 'product_search' uses template variables but has no input_schema defined","severity":"warning","suggestion":"Define input_schema to document and validate retriever inputs"}]},"LintSeverity":{"type":"string","enum":["error","warning","info"],"title":"LintSeverity","description":"Severity level for lint results."},"ListAdhocExecutionsRequest":{"properties":{"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Filter by execution status. Common values: 'completed', 'failed'. OPTIONAL - omit to see all statuses.","examples":["completed","failed"]},"start_time":{"anyOf":[{},{"type":"null"}],"title":"Start Time","description":"Filter executions after this timestamp (inclusive). OPTIONAL - omit for no start time filter."},"end_time":{"anyOf":[{},{"type":"null"}],"title":"End Time","description":"Filter executions before this timestamp (inclusive). OPTIONAL - omit for no end time filter."},"count_only":{"type":"boolean","title":"Count Only","description":"When true, return ONLY the total count and skip fetching the execution rows. Use for a badge/total (the Executions-tab count) — it avoids the ORDER BY full-row scan that made a limit:1 count take 15s+.","default":false}},"type":"object","title":"ListAdhocExecutionsRequest","description":"Request to list ad-hoc retriever executions with filtering.\n\nAllows filtering by status, time range, and searching by query summary.\nResults are ordered by timestamp descending (most recent first)."},"ListAdhocExecutionsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/AdhocExecutionSummary"},"type":"array","title":"Results","description":"List of ad-hoc execution summaries."},"total":{"type":"integer","title":"Total","description":"Total number of ad-hoc executions matching filters.","default":0},"pagination":{"title":"Pagination","description":"Pagination metadata."}},"type":"object","required":["pagination"],"title":"ListAdhocExecutionsResponse","description":"Response from listing ad-hoc retriever executions."},"ListAlertsRequest":{"properties":{"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search","description":"Search term for wildcard search across alert_id, name, description"},"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"Filters to apply to the alert list"},"sort":{"anyOf":[{"$ref":"#/components/schemas/SortOption"},{"type":"null"}],"description":"Sort configuration for the alert list"},"case_sensitive":{"type":"boolean","title":"Case Sensitive","description":"If True, filters and search will be case-sensitive","default":false}},"type":"object","title":"ListAlertsRequest","description":"Request model to list alerts."},"ListAlertsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/AlertResponse"},"type":"array","title":"Results","description":"List of alerts"},"pagination":{"$ref":"#/components/schemas/PaginationResponse","description":"Pagination information"},"total_count":{"type":"integer","title":"Total Count","description":"Total number of alerts matching query"},"stats":{"anyOf":[{"$ref":"#/components/schemas/AlertListStats"},{"type":"null"}],"description":"Aggregate statistics across all alerts in the result"}},"type":"object","required":["results","pagination","total_count"],"title":"ListAlertsResponse","description":"Response model for listing alerts."},"ListAnnotationsRequest":{"properties":{"document_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Id","description":"Filter by document."},"collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Collection Id","description":"Filter by collection."},"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label","description":"Filter by label."},"actor_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Actor Id","description":"Filter by who annotated."},"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id","description":"Filter by retriever."},"as_of":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"As Of","description":"Return the judgment set AS IT STOOD at this instant — annotations created later are excluded, and each remaining annotation is reconstructed to its state at that time from its revision chain. This is the reproducible-evaluation handle: an evaluation pins its as_of and re-reads the identical set later."}},"type":"object","title":"ListAnnotationsRequest","description":"Query parameters for listing annotations."},"ListAnnotationsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/AnnotationResponse"},"type":"array","title":"Results"},"total_count":{"type":"integer","title":"Total Count","default":0}},"type":"object","title":"ListAnnotationsResponse","description":"Paginated annotation list."},"ListAppsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/AppListItem"},"type":"array","title":"Results"},"total_count":{"type":"integer","title":"Total Count"},"limit":{"type":"integer","title":"Limit"},"offset":{"type":"integer","title":"Offset"},"max_apps":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Apps","description":"Maximum Canvas Apps allowed on the caller's tier (Free=1, Pro=10, Enterprise=unlimited). null means unlimited."}},"type":"object","required":["results","total_count","limit","offset"],"title":"ListAppsResponse","description":"Paginated list of apps."},"ListBatchesRequest":{"properties":{"status":{"anyOf":[{"$ref":"#/components/schemas/TaskStatusEnum"},{"type":"null"}],"description":"Filter batches by status."},"collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Collection Id","description":"Filter batches to only those associated with a specific collection ID. Useful for tracking the processing state of all batches for a given collection."},"bucket_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bucket Id","description":"Filter batches to only those belonging to a specific bucket. Useful with the org-level POST /v1/batches/list endpoint to scope results."},"namespace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Namespace Id","description":"Filter batches to a single namespace, by name or ns_ id. The X-Namespace header does the same; if both are sent they must agree (a conflict is a 400). Omit both for the organization-wide view."},"offset":{"type":"integer","minimum":0.0,"title":"Offset","description":"The number of batches to skip.","default":0},"limit":{"type":"integer","maximum":1000.0,"minimum":1.0,"title":"Limit","description":"The maximum number of batches to return.","default":100},"cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor","description":"Cursor for deep pagination. Use next_cursor from a previous response to fetch the next page. More efficient than offset for large result sets."}},"additionalProperties":false,"type":"object","title":"ListBatchesRequest","description":"The request model for listing batches."},"ListBatchesResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/BatchModel"},"type":"array","title":"Results","description":"A list of batches."},"total_count":{"type":"integer","title":"Total Count","description":"The total number of batches found."},"pagination":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Pagination","description":"Pagination metadata including next_cursor for deep pagination."}},"type":"object","required":["results","total_count"],"title":"ListBatchesResponse","description":"The response model for listing batches.\n\nEach batch in results includes bucket_id, enabling callers to build\nbatch-to-bucket mappings without additional queries."},"ListBucketsRequest":{"properties":{"limit":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":1.0},{"type":"null"}],"title":"Limit","description":"Page size. A body value wins over the `limit` query param."},"page_size":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":1.0},{"type":"null"}],"title":"Page Size","description":"Alias for `limit` (page size). If both are given, `limit` wins."},"offset":{"anyOf":[{"type":"integer","maximum":10000.0,"minimum":0.0},{"type":"null"}],"title":"Offset","description":"Number of results to skip (legacy, use cursor instead). A body value wins over the `offset` query param."},"page":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Page","description":"1-indexed page number. Folds to offset = (page-1) * limit. If both `page` and `offset` are given, `offset` wins."},"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search","description":"Search term for wildcard search across bucket_id, bucket_name, description, and other text fields"},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","description":"Filters to apply to the bucket list. Supports filtering by bucket_id or bucket_name."},"sort":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Sort","description":"Sort options for the bucket list (single-column, legacy)"},"sorts":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Sorts","description":"Sort options for the bucket list as a list of {field, direction} — the shape Studio datatables and the retriever list send. The first entry is the primary sort. Takes precedence over the singular `sort`."},"case_sensitive":{"type":"boolean","title":"Case Sensitive","description":"If True, filters and search will be case-sensitive","default":false}},"type":"object","title":"ListBucketsRequest","description":"Request model for listing buckets.\n\nInherits body-level limit/page_size/offset/page. The old\nhardcoded limit=10/offset=0 defaults moved to the controller so an unset\nbody field can fall back to query-string pagination (body wins when set)."},"ListBucketsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/BucketResponse"},"type":"array","title":"Results"},"total_count":{"type":"integer","title":"Total Count","description":"Total number of buckets matching the query"},"pagination":{"$ref":"#/components/schemas/PaginationResponse"},"stats":{"anyOf":[{"$ref":"#/components/schemas/BucketListStats"},{"type":"null"}],"description":"Aggregate statistics across all buckets in the result"},"warnings":{"items":{"$ref":"#/components/schemas/DegradedEntry"},"type":"array","title":"Warnings","description":"Why this page may not be the whole answer. An entry with resource 'namespace' and reason 'unresolved' means X-Namespace did not resolve for this API key, so the empty list is not that namespace's contents (the same condition as the X-Namespace-Unresolved response header). Empty when the namespace resolved."}},"type":"object","required":["results","total_count","pagination"],"title":"ListBucketsResponse","description":"Response model for listing buckets."},"ListClusterExecutionsRequest":{"properties":{"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"OPTIONAL. Complex filtering conditions for execution history. NOT REQUIRED - omit to return all executions. Structure: Logical operator (AND/OR) with array of conditions. Supported filter fields:   - status: Filter by execution status (pending/processing/completed/failed).   - created_at: Filter by execution start date (use gte/lte for ranges).   - num_clusters: Filter by number of clusters found.   - metrics.silhouette_score: Filter by quality threshold. Example filters:   - Status is completed: {AND: [{field: 'status', operator: 'eq', value: 'completed'}]}.   - Created in last 7 days: {AND: [{field: 'created_at', operator: 'gte', value: '2025-11-06T00:00:00Z'}]}.   - Good quality (silhouette > 0.5): {AND: [{field: 'metrics.silhouette_score', operator: 'gt', value: 0.5}]}. Combine with OR: Status completed OR failed (exclude in-progress)."},"sort":{"anyOf":[{"$ref":"#/components/schemas/SortOption"},{"type":"null"}],"description":"OPTIONAL. Sorting configuration for results. NOT REQUIRED - defaults to created_at descending (newest first). Structure: {field: 'field_name', direction: 'asc' or 'desc'}. Sortable fields:   - created_at: Sort by execution start time (default).   - completed_at: Sort by execution finish time.   - num_clusters: Sort by cluster count.   - num_points: Sort by document count.   - metrics.silhouette_score: Sort by quality score.   - status: Sort by execution status. Common use cases:   - Newest first (default): {field: 'created_at', direction: 'desc'}.   - Best quality first: {field: 'metrics.silhouette_score', direction: 'desc'}.   - Failed executions first: {field: 'status', direction: 'asc'} (alphabetical)."},"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search","description":"OPTIONAL. Full-text search query across execution metadata. NOT REQUIRED - omit for no search filtering. Searches in:   - run_id: Search by execution identifier.   - error_message: Find executions with specific error text.   - centroids.label: Search by cluster label names.   - centroids.summary: Search by cluster descriptions. Behavior:   - Case-insensitive partial matching.   - Multiple terms are AND-ed together.   - Combines with filters for complex queries. Examples:   - 'failed' → Find executions with 'failed' in error messages.   - 'product review' → Find executions with clusters about products/reviews.   - 'run_abc123' → Find specific execution by ID.","examples":["failed","product review","insufficient documents","run_abc123"]}},"type":"object","title":"ListClusterExecutionsRequest","description":"Request parameters for listing and filtering cluster execution history.\n\nProvides flexible querying of historical clustering executions with filtering,\nsorting, and search capabilities. Use to build execution history UIs, compare\nruns over time, and analyze clustering performance trends.\n\nUse Cases:\n    - Display execution history table with sorting and filtering\n    - Find failed executions for debugging\n    - Compare metrics across successful runs\n    - Search executions by date range or status\n    - Build execution timeline visualization\n\nQuery Behavior:\n    - Empty request {} returns all executions sorted by created_at (newest first)\n    - Filters, sort, and search can be combined for complex queries\n    - Results are paginated (use page/page_size query params)\n\nNote:\n    All fields are OPTIONAL. Omit for default behavior (all executions, newest first).","examples":[{"description":"Get all executions (default behavior)"},{"description":"Get only completed executions","filters":{"AND":[{"field":"status","operator":"eq","value":"completed"}]}},{"description":"Get failed executions in last 7 days, sorted by date","filters":{"AND":[{"field":"status","operator":"eq","value":"failed"},{"field":"created_at","operator":"gte","value":"2025-11-06T00:00:00Z"}]},"sort":{"direction":"desc","field":"created_at"}},{"description":"Get high-quality executions (silhouette > 0.7)","filters":{"AND":[{"field":"metrics.silhouette_score","operator":"gt","value":0.7}]},"sort":{"direction":"desc","field":"metrics.silhouette_score"}},{"description":"Search executions mentioning 'product'","search":"product","sort":{"direction":"desc","field":"created_at"}}]},"ListClusterExecutionsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/ClusterExecutionResult"},"type":"array","title":"Results","description":"REQUIRED. Array of cluster execution results for the current page. Length: 0 to page_size (default 10, max typically 100). Empty array [] if:   - No executions exist for this cluster.   - Filters matched no results.   - Requested page beyond available pages. Sorted by: created_at descending (newest first) by default. Override with sort parameter in request. Each item contains:   - run_id: Unique execution identifier.   - status: pending/processing/completed/failed.   - num_clusters: Clusters found.   - metrics: Quality scores (if available).   - centroids: Cluster labels and summaries (if available).   - created_at/completed_at: Timestamps.   - error_message: Error details (if failed). Use for: Rendering execution history table rows."},"pagination":{"$ref":"#/components/schemas/PaginationResponse","description":"REQUIRED. Pagination metadata for navigating result pages. Contains:   - total: Total items across all pages (same as total_count).   - page: Current page number (1-indexed).   - page_size: Items per page.   - total_pages: Total number of pages.   - next_cursor: Opaque cursor for the next page; send it back as the cursor param, and stop paging once it is absent.   - next_page, previous_page: Always null. Deprecated; do not use them to decide whether more pages exist (see /docs/platform/pagination). Use for:   - Pagination controls ('Page 2 of 5').   - Showing X-Y of Z results calculations."},"total_count":{"type":"integer","minimum":0.0,"title":"Total Count","description":"REQUIRED. Total number of executions matching the query across ALL pages. Use for:   - Display total count ('Found 127 executions').   - Calculate pagination ('Showing 1-10 of 127').   - Validate filters (0 = no matches, refine query). Behavior:   - Includes all filtered results, not just current page.   - Changes when filters are applied.   - Equals len(results) only if all results fit on one page. Example:   - Query returns 127 executions total.   - Page size = 10.   - Current page (1) shows results[0:10].   - total_count = 127 (not 10).","examples":[127,50,10,0]},"stats":{"anyOf":[{"$ref":"#/components/schemas/ClusterExecutionListStats"},{"type":"null"}],"description":"OPTIONAL. Aggregate statistics for executions in current result set. NOT REQUIRED - may be null if stats calculation disabled. Typically always provided for execution listing. Contains:   - total_executions: Count in current page.   - executions_by_status: Status distribution {'completed': 45, 'failed': 3}.   - avg_execution_time_ms: Mean duration.   - total_documents_clustered: Sum of all processed documents.   - avg_num_clusters: Mean clusters per execution. Use for:   - Summary cards above table.   - Status pie chart.   - Performance metrics dashboard. Note:   - Stats calculated for current page only (or all if no pagination).   - Respects filters (stats for filtered subset)."}},"type":"object","required":["results","pagination","total_count"],"title":"ListClusterExecutionsResponse","description":"Complete response for cluster execution history listing endpoint.\n\nReturns paginated execution history with filtering, sorting, and aggregate statistics.\nUse to build execution history UIs, monitoring dashboards, and performance analytics.\n\nResponse Structure:\n    - results: Array of execution details (paginated)\n    - pagination: Page navigation info (current page, total pages, etc.)\n    - total_count: Total matching executions (across all pages)\n    - stats: Aggregated metrics for current result set\n\nUse Cases:\n    - Build execution history table with pagination\n    - Display execution status dashboard with charts\n    - Monitor clustering performance trends\n    - Debug failed executions\n    - Compare quality metrics across runs\n\nPagination Behavior:\n    - Default: 10 executions per page\n    - Use query params: ?page=1&page_size=20\n    - results contains current page only\n    - total_count shows all matching executions\n    - pagination provides navigation links\n\nExample Workflow:\n    1. Request: POST /clusters/{id}/executions/list with filters\n    2. Response: 50 total executions, showing page 1 (10 results)\n    3. Display: Show 10 results + \"Page 1 of 5\" + aggregate stats\n    4. Navigate: Use pagination.next_cursor for the next page; next_page\n       and previous_page are always null (see /docs/platform/pagination)","examples":[{"description":"Typical paginated response with executions","pagination":{"page":1,"page_size":10,"total":127,"total_pages":13},"results":[{"centroids":[{"cluster_id":"cl_0","label":"Product Reviews","num_members":45}],"cluster_id":"clust_ae3e28a429","completed_at":"2025-11-13T13:25:40.122000Z","created_at":"2025-11-13T13:20:40.122000Z","metrics":{"silhouette_score":0.85},"num_clusters":3,"num_points":100,"run_id":"run_a8e270953254754b","status":"completed"}],"stats":{"avg_execution_time_ms":8234.5,"avg_num_clusters":5.2,"executions_by_status":{"completed":8,"failed":2},"total_documents_clustered":1000,"total_executions":10},"total_count":127},{"description":"Empty result (no executions found)","pagination":{"page":1,"page_size":10,"total":0,"total_pages":0},"results":[],"stats":{"avg_execution_time_ms":0.0,"avg_num_clusters":0.0,"executions_by_status":{},"total_documents_clustered":0,"total_executions":0},"total_count":0},{"description":"Last page of results (10 total, 3 on last page)","pagination":{"page":2,"page_size":5,"total":10,"total_pages":2},"results":[{"cluster_id":"clust_abc123","completed_at":"2025-11-13T12:05:00.000000Z","created_at":"2025-11-13T12:00:00.000000Z","num_clusters":5,"num_points":200,"run_id":"run_xyz789","status":"completed"}],"stats":{"avg_execution_time_ms":12000.0,"avg_num_clusters":5.0,"executions_by_status":{"completed":3},"total_documents_clustered":600,"total_executions":3},"total_count":10}]},"ListClustersRequest":{"properties":{"limit":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":1.0},{"type":"null"}],"title":"Limit","description":"Page size. A body value wins over the `limit` query param."},"page_size":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":1.0},{"type":"null"}],"title":"Page Size","description":"Alias for `limit` (page size). If both are given, `limit` wins."},"offset":{"anyOf":[{"type":"integer","maximum":10000.0,"minimum":0.0},{"type":"null"}],"title":"Offset","description":"Number of results to skip (legacy, use cursor instead). A body value wins over the `offset` query param."},"page":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Page","description":"1-indexed page number. Folds to offset = (page-1) * limit. If both `page` and `offset` are given, `offset` wins."},"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"Filters to apply when listing clusters"},"sort":{"anyOf":[{"$ref":"#/components/schemas/SortOption"},{"type":"null"}],"description":"Sort options for the results (single-column, legacy)"},"sorts":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Sorts","description":"Sort options as a list of {field, direction} — the shape Studio datatables and the retriever list send. The first entry is the primary sort. Takes precedence over the singular `sort`."},"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search","description":"Search term for wildcard search across cluster_id, cluster_name, description, and other text fields"}},"type":"object","title":"ListClustersRequest","description":"Request model for listing clusters.\n\nInherits body-level limit/page_size/offset/page — body values\nwin over query pagination via merge_body_pagination."},"ListClustersResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/ClusterMetadata"},"type":"array","title":"Results","description":"List of cluster metadata"},"pagination":{"$ref":"#/components/schemas/PaginationResponse","description":"Pagination information"},"total_count":{"type":"integer","title":"Total Count","description":"Total number of clusters matching the query"},"stats":{"anyOf":[{"$ref":"#/components/schemas/ClusterListStats"},{"type":"null"}],"description":"Aggregate statistics across all clusters in the result"}},"type":"object","required":["results","pagination","total_count"],"title":"ListClustersResponse","description":"Response model for listing clusters."},"ListCollectionsRequest":{"properties":{"limit":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":1.0},{"type":"null"}],"title":"Limit","description":"Page size. A body value wins over the `limit` query param."},"page_size":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":1.0},{"type":"null"}],"title":"Page Size","description":"Alias for `limit` (page size). If both are given, `limit` wins."},"offset":{"anyOf":[{"type":"integer","maximum":10000.0,"minimum":0.0},{"type":"null"}],"title":"Offset","description":"Number of results to skip (legacy, use cursor instead). A body value wins over the `offset` query param."},"page":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Page","description":"1-indexed page number. Folds to offset = (page-1) * limit. If both `page` and `offset` are given, `offset` wins."},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","description":"Filters to apply when listing collections. Supports nested field filtering like 'taxonomy_applications.taxonomy_id'. Format: {\"AND\": [{\"field\": \"field_name\", \"operator\": \"eq\", \"value\": \"value\"}]}"},"sort":{"anyOf":[{"$ref":"#/components/schemas/SortOption"},{"type":"null"}],"description":"Sort options for the results (single-column, legacy)"},"sorts":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Sorts","description":"Sort options as a list of {field, direction} — the shape Studio datatables and the retriever list send. The first entry is the primary sort. Takes precedence over the singular `sort`."},"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search","description":"Search term for wildcard search across collection_id, collection_name, description, and other text fields"},"include_system":{"type":"boolean","title":"Include System","description":"Include the namespace's system collections: today the per-namespace `_direct_upsert` default that `POST /v1/namespaces/{ns}/documents/upsert` writes to (it is also addressable by that name at GET /v1/collections/_direct_upsert). Off by default so the list shows the collections you created.","default":false},"case_sensitive":{"type":"boolean","title":"Case Sensitive","description":"If True, filters and search will be case-sensitive","default":false}},"type":"object","title":"ListCollectionsRequest","description":"Request model for listing collections.\n\nInherits body-level limit/page_size/offset/page — body values\nwin over query pagination via merge_body_pagination.\n\nTo filter by taxonomy, use dot notation in filters:\nfilters.AND = [{\"field\": \"taxonomy_applications.taxonomy_id\", \"operator\": \"eq\", \"value\": \"tax_123\"}]"},"ListCollectionsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/CollectionResponse"},"type":"array","title":"Results","description":"List of collections"},"pagination":{"$ref":"#/components/schemas/PaginationResponse","description":"Pagination information"},"total_count":{"type":"integer","title":"Total Count","description":"Total number of collections matching the query"},"stats":{"anyOf":[{"$ref":"#/components/schemas/CollectionListStats"},{"type":"null"}],"description":"Aggregate statistics across all collections in the result"},"warnings":{"items":{"$ref":"#/components/schemas/DegradedEntry"},"type":"array","title":"Warnings","description":"Why this page may not be the whole answer. An entry with resource 'namespace' and reason 'unresolved' means X-Namespace did not resolve for this API key, so the empty list is not that namespace's contents (the same condition as the X-Namespace-Unresolved response header). Empty when the namespace resolved."}},"type":"object","required":["results","pagination","total_count"],"title":"ListCollectionsResponse","description":"Response model for listing collections."},"ListCommsRequest":{"properties":{"scope":{"anyOf":[{"$ref":"#/components/schemas/SupportScope"},{"type":"null"}]},"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search"}},"type":"object","title":"ListCommsRequest"},"ListCommsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/MessageResponse"},"type":"array","title":"Results"},"pagination":{"$ref":"#/components/schemas/PaginationResponse"},"messages":{"items":{"$ref":"#/components/schemas/MessageResponse"},"type":"array","title":"Messages","description":"Deprecated alias of `results`, kept for existing clients. Read `results`, the row key every list route shares.","deprecated":true,"readOnly":true}},"type":"object","required":["results","pagination","messages"],"title":"ListCommsResponse"},"ListDLQRequest":{"properties":{"only_max_retries":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Only Max Retries","description":"If True, only return entries that exhausted all retries.","default":false},"error_types":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Error Types","description":"Filter by error type names, e.g. ['NotFoundError', 'ValidationError']."}},"type":"object","title":"ListDLQRequest","description":"Request to list Dead Letter Queue entries for a sync configuration."},"ListDocumentsRequest":{"properties":{"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"Filters to apply."},"sort":{"anyOf":[{"$ref":"#/components/schemas/SortOption"},{"type":"null"}],"description":"Sort options."},"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search","description":"Search term."},"cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor","description":"OPTIONAL cursor for efficient deep pagination. Pass the 'pagination.next_cursor' value from a previous response to fetch the next page. When cursor is provided, the page/offset query params are ignored. Use cursor-based pagination when: (1) paginating beyond page ~100, (2) sorting large datasets, or (3) you need consistent iteration. Use offset-based pagination (default) for: simple use cases, random page access, or when page numbers are needed in the UI."},"partition":{"anyOf":[{"$ref":"#/components/schemas/ListPartition"},{"type":"null"}],"description":"OPTIONAL. Read one of `count` disjoint partitions of the matching documents, so several workers can page through a large collection in parallel, each with its own cursor and with no offset cap. The documents are split on their document id and every document falls in exactly one partition. Page each partition with its `pagination.next_cursor` until that is null; the cursor carries its partition, so sending the cursor alone stays inside it. Example: four workers send {\"index\": 0, \"count\": 4} through {\"index\": 3, \"count\": 4}. The split points are even over Mixpeek-generated document ids (doc_ followed by hex). Documents written with your own document_id values can all fall in one partition, which can be slower than one sequential listing; to split those, give each worker a range filter on document_id instead.","examples":[{"count":4,"index":0}]},"include_total":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Include Total","description":"Set true to count the documents that match this request. pagination.total and total_documents then hold the number of matching documents across all pages, filters included (0 when nothing matches); without it, or with a warning if the count fails, both are null. Runs a COUNT query that adds about 50-200ms. To get only the count, send limit 1. Accepted in the body or as the ?include_total=true query parameter; the body value wins when both are set."},"return_presigned_urls":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Return Presigned Urls","description":"Whether to return presigned URLs for object keys.","default":false},"return_vectors":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Return Vectors","description":"Whether to return vector embeddings in the document results.","default":false},"return_vector_names":{"anyOf":[{"type":"boolean"},{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Return Vector Names","description":"Controls vector data in the response. Pass `true` to get a `_vectors` field listing available vector names (no embedding data). Pass a list of vector names (e.g. `[\"fashionsiglip_v1_embedding\"]`) to return the actual float arrays for those specific vectors, keyed by name.","default":false},"group_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Group By","description":"OPTIONAL. Field to group documents by. Supports dot notation for nested fields (e.g., 'metadata.category', 'source_type'). Accepts either a bare string (``'metadata.category'``) or an object form (``{'field': 'metadata.category'}``) for consistency with other API parameters. When specified, documents are grouped by the field value and returned as grouped results. Requires a payload index on the field in the vector store for optimal performance. If no index exists, the operation will fail with a validation error. Common groupable fields: 'source_object_id', 'root_object_id', 'collection_id', 'metadata.category'.","examples":["source_object_id","metadata.category","root_object_id","source_type"]},"select":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Select","description":"OPTIONAL. List of fields to include in the response. Supports dot notation for nested fields (e.g., 'metadata.title', 'content'). When specified, only the selected fields will be returned in the document results, reducing response size. System fields like '_id' and 'document_id' are always included. Vectors requested with return_vectors or return_vector_names are returned whether or not select names them, along with '_vectors'. Use this to optimize response size when working with large documents.","examples":[["metadata.title","content"],["document_id","metadata"],["source_type","created_at"]]},"expand":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Expand","description":"OPTIONAL. List of fields containing document IDs to resolve inline. Referenced documents are fetched and attached under an '_expanded' key. Supports dot-notation for nested fields (e.g., 'items.product_id'). Max 50 unique references per request. Depth is limited to 1 (no recursive expansion).","examples":[["customer_id"],["customer_id","items.product_id"]]},"limit":{"type":"integer","maximum":1000.0,"minimum":1.0,"title":"Limit","description":"Number of documents to return per page. Capped at 1000. Accepts ``page_size`` as an alias (POST body only).","default":10},"offset":{"type":"integer","minimum":0.0,"title":"Offset","description":"Number of documents to skip (offset-based pagination).","default":0}},"type":"object","title":"ListDocumentsRequest","description":"Request model for listing documents.\n\nSupports two pagination strategies:\n\n**Offset-based (default)**: Use query params `?page=2&page_size=10`\n- Simple and familiar\n- Works well for shallow pagination (first ~100 pages)\n- Less efficient for deep pagination with sorting\n\n**Cursor-based (optional)**: Pass `cursor` from previous response's `next_cursor`\n- More efficient for deep pagination (page 100+)\n- Required for consistent results when sorting large datasets\n- When cursor is provided, offset is ignored"},"ListDocumentsResponse":{"properties":{"results":{"anyOf":[{"items":{"$ref":"#/components/schemas/DocumentResponse"},"type":"array"},{"type":"null"}],"title":"Results","description":"List of documents when group_by is NOT specified. Contains flat list of documents with pagination applied. Mutually exclusive with 'groups' field."},"groups":{"anyOf":[{"items":{"$ref":"#/components/schemas/DocumentGroup"},"type":"array"},{"type":"null"}],"title":"Groups","description":"List of document groups when group_by IS specified. Each group contains documents sharing the same field value. Pagination applies to groups, not individual documents. Mutually exclusive with 'results' field."},"unknown_collection_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Unknown Collection Ids","description":"Requested collection_ids that do NOT exist in this namespace. Present only on the namespace-scoped list when SOME requested ids resolved and others did not — so a typo'd or deleted collection id is distinguishable from a real-but-empty collection instead of silently contributing zero results forever. When NONE of the requested ids resolve, the endpoint returns 404 instead."},"pagination":{"$ref":"#/components/schemas/PaginationResponse","description":"Pagination information. Includes next_cursor for cursor-based pagination. pagination.total is the number of matching documents when the request sets include_total=true, and null otherwise. When group_by is used, pagination applies to groups (not individual documents) and pagination.total counts groups."},"warnings":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Warnings","description":"Result-shape warnings the caller must not ignore. Present when the listing is silently incomplete — e.g. a sorted listing scanned only the first 10,000 matching points, so the sort ranks a truncated subset and pagination ends at the cap rather than the end of the collection. Absent when the result is complete."},"total_documents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Documents","description":"Number of documents matching the query across all pages, filters included. null unless the request set include_total=true. A request that set it gets null only when the count could not be computed, and warnings then says so. Same value as stats.total_documents."},"stats":{"anyOf":[{"$ref":"#/components/schemas/DocumentListStats"},{"type":"null"}],"description":"Aggregate statistics across all documents in the result"},"group_by_field":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Group By Field","description":"The field that was used for grouping when group_by was specified. None for non-grouped results. Useful for clients to understand the grouping structure.","examples":["source_object_id","metadata.category"]}},"type":"object","required":["pagination"],"title":"ListDocumentsResponse","description":"Response model for listing documents.\n\nSupports both regular document lists and grouped results based on the group_by parameter.\nWhen group_by is specified, results are returned as groups instead of a flat list.\n\nPagination strategies:\n- **Offset-based (default)**: Use `pagination.page` and `pagination.page_size`\n- **Cursor-based (optional)**: Use `pagination.next_cursor` for efficient deep pagination","examples":[{"description":"Regular document list (no grouping)","pagination":{"has_more":false,"limit":10,"offset":0,"total_count":1},"results":[{"collection_id":"col_articles","document_id":"doc_123","metadata":{"title":"AI Article"}}],"stats":{"avg_blobs_per_document":1.0,"total_documents":1}},{"description":"Grouped document list (group_by specified)","group_by_field":"source_object_id","groups":[{"count":2,"documents":[{"collection_id":"col_frames","document_id":"doc_frame_001","source_object_id":"obj_video123"},{"collection_id":"col_frames","document_id":"doc_frame_002","source_object_id":"obj_video123"}],"group_key":"obj_video123"}],"pagination":{"has_more":false,"limit":10,"offset":0,"total_count":1},"stats":{"avg_blobs_per_document":1.0,"avg_documents_per_group":2.0,"total_documents":2,"total_groups":1}}]},"ListDomainsResponse":{"properties":{"domains":{"items":{"$ref":"#/components/schemas/DomainResponse"},"type":"array","title":"Domains"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["domains","total"],"title":"ListDomainsResponse"},"ListEventsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/ChangeEventResponse"},"type":"array","title":"Results"},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor","description":"Pass as `cursor` on the next call to resume after these results. Unchanged from the request's cursor when this page was empty."},"has_more":{"type":"boolean","title":"Has More","description":"Whether another page is available beyond this one."}},"type":"object","required":["results","has_more"],"title":"ListEventsResponse"},"ListExecutionsRequest":{"properties":{"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters"},"sorts":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Sorts"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Optional status filter (completed, failed, running)."}},"type":"object","title":"ListExecutionsRequest","description":"Request to list retriever executions."},"ListExecutionsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/RetrieverExecutionSummary"},"type":"array","title":"Results","description":"Execution summaries"},"pagination":{"$ref":"#/components/schemas/PaginationMetadata","description":"Pagination metadata"}},"type":"object","required":["pagination"],"title":"ListExecutionsResponse","description":"Re-export shared execution listing response for OpenAPI docs."},"ListFoldersResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/FolderItem"},"type":"array","title":"Results","description":"List of folders found at the specified parent path. Only includes folders (not files). Empty list if no folders found or path doesn't exist."},"parent_path":{"type":"string","title":"Parent Path","description":"The parent folder path that was queried. This is the path specified in the request (or '/' for root). Use this to show breadcrumb navigation in UI.","examples":["/","/Marketing","/Marketing/2024 Campaigns"]}},"type":"object","required":["results","parent_path"],"title":"ListFoldersResponse","description":"Response payload for listing Google Drive folders.\n\nReturns a list of folders available at the specified path, enabling users\nto browse and select folders for sync configuration.","examples":[{"description":"List of folders at root","folders":[{"id":"0AH-Xabc123","mime_type":"application/vnd.google-apps.folder","name":"Marketing","path":"/Marketing"},{"id":"0AH-Xdef456","mime_type":"application/vnd.google-apps.folder","name":"Sales","path":"/Sales"}],"parent_path":"/"}]},"ListInteractionsRequest":{"properties":{"execution_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Execution Id","description":"Filter by retriever execution ID. Most common query: find all interactions from a specific search execution. Example: 'exec_abc123'","examples":["exec_abc123","exec_550e8400e29b"]},"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id","description":"Filter by retriever ID. Compare performance across different retriever configurations. Example: 'ret_product_search_v2'","examples":["ret_product_search","ret_baseline_v1"]},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id","description":"Filter by session ID. Track user journey across multiple searches within a session. Example: 'sess_xyz789'","examples":["sess_abc123","sess_xyz789_1234567890"]},"user_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id","description":"Filter by user ID. Analyze behavior of specific users for personalization insights. Example: 'user_456'","examples":["user_abc123","customer_456"]},"feature_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Feature Id","description":"Filter by feature/document ID. Find all interactions with a specific document across all searches. Example: 'doc_abc123'","examples":["doc_abc123","prod_xyz789"]},"interaction_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Interaction Type","description":"Filter by interaction type. Use to find specific behaviors like clicks, purchases, or feedback. Example: 'click', 'positive_feedback'","examples":["click","positive_feedback","purchase"]},"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"Advanced filters using LogicalOperator for complex analytics queries. Supports shorthand syntax and complex AND/OR/NOT logic. Use this for: range queries, complex conditions, metadata filtering. Examples:   - Position range: {'position': {'lte': 5}}   - Time range: {'timestamp': {'gte': '2025-01-01'}}   - Complex: {'AND': [{'field': 'position', 'operator': 'lte', 'value': 5},                       {'field': 'interaction_type', 'operator': 'in', 'value': ['click', 'purchase']}]} See LogicalOperator documentation for full syntax.","examples":[{"position":{"lte":5}},{"AND":[{"field":"position","operator":"lte","value":5},{"field":"interaction_type","operator":"in","value":["click","purchase"]}]},{"OR":[{"field":"interaction_type","operator":"eq","value":"purchase"},{"field":"metadata.duration_ms","operator":"gte","value":10000}]}]},"sort":{"anyOf":[{"$ref":"#/components/schemas/SortOption"},{"type":"null"}],"description":"Sort options for ordering results. Default: timestamp descending (newest first). Examples:   - Sort by timestamp: {'field': 'timestamp', 'direction': 'desc'}   - Sort by position: {'field': 'position', 'direction': 'asc'}","examples":[{"direction":"desc","field":"timestamp"},{"direction":"asc","field":"position"}]},"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search","description":"Full-text search across metadata fields. NOT REQUIRED. Use to search interaction metadata content.","examples":["mobile device","campaign_summer_2024"]}},"type":"object","title":"ListInteractionsRequest","description":"Request for listing interactions with filters.\n\nSupports both simple field filters (for common queries) and advanced\nLogicalOperator filters (for complex analytics). This hybrid approach\nfollows the same pattern as the Tasks module.\n\nCommon Queries (Simple Fields):\n    - Filter by execution: {\"execution_id\": \"exec_abc\"}\n    - Filter by session: {\"session_id\": \"sess_xyz\"}\n    - Filter by user: {\"user_id\": \"user_123\"}\n\nAdvanced Queries (LogicalOperator):\n    - Range queries: {\"filters\": {\"position\": {\"lte\": 5}}}\n    - Complex logic: {\"filters\": {\"AND\": [...]}}\n    - Time ranges: {\"filters\": {\"created_at\": {\"gte\": \"2025-01-01\"}}}"},"ListInteractionsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/InteractionResponse"},"type":"array","title":"Results","description":"List of interactions matching the query filters"},"pagination":{"$ref":"#/components/schemas/PaginationResponse","description":"Pagination information for navigating result pages"},"items":{"items":{"$ref":"#/components/schemas/InteractionResponse"},"type":"array","title":"Items","description":"Deprecated alias of `results`, kept for existing clients. Read `results`, the row key every list route shares.","deprecated":true,"readOnly":true}},"type":"object","required":["results","pagination","items"],"title":"ListInteractionsResponse","description":"Response for listing interactions with pagination.\n\nReturns a paginated list of interaction records matching the query filters."},"ListInvitationsResponse":{"properties":{"invitations":{"items":{"$ref":"#/components/schemas/AppInvitationResponse"},"type":"array","title":"Invitations"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["invitations","total"],"title":"ListInvitationsResponse"},"ListMigrationsRequest":{"properties":{"status":{"anyOf":[{"$ref":"#/components/schemas/MigrationStatus"},{"type":"null"}],"description":"Filter by status"},"migration_type":{"anyOf":[{"$ref":"#/components/schemas/MigrationType"},{"type":"null"}],"description":"Filter by type"},"source_namespace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Namespace Id","description":"Filter by source namespace"},"limit":{"type":"integer","maximum":1000.0,"minimum":1.0,"title":"Limit","description":"Maximum results","default":20},"offset":{"type":"integer","minimum":0.0,"title":"Offset","description":"Result offset for pagination","default":0}},"type":"object","title":"ListMigrationsRequest","description":"Request to list migrations with filters."},"ListMigrationsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/GetMigrationResponse"},"type":"array","title":"Results","description":"List of migrations"},"total":{"type":"integer","title":"Total","description":"Total count matching filters"},"limit":{"type":"integer","title":"Limit","description":"Results limit"},"offset":{"type":"integer","title":"Offset","description":"Results offset"}},"type":"object","required":["results","total","limit","offset"],"title":"ListMigrationsResponse","description":"Response for listing migrations."},"ListNamespacesRequest":{"properties":{"limit":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":1.0},{"type":"null"}],"title":"Limit","description":"Page size. A body value wins over the `limit` query param."},"page_size":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":1.0},{"type":"null"}],"title":"Page Size","description":"Alias for `limit` (page size). If both are given, `limit` wins."},"offset":{"anyOf":[{"type":"integer","maximum":10000.0,"minimum":0.0},{"type":"null"}],"title":"Offset","description":"Number of results to skip (legacy, use cursor instead). A body value wins over the `offset` query param."},"page":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Page","description":"1-indexed page number. Folds to offset = (page-1) * limit. If both `page` and `offset` are given, `offset` wins."},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","description":"Optional filters to apply to the namespace list. Supports filtering by namespace_id or namespace_name.","example":{"namespace_id":"ns_abc123","namespace_name":{"$regex":"^my_namespace"}}},"sort":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Sort","description":"Optional sort criteria for the namespace list (single-column, legacy). With no sort at all, starred namespaces come first. A sort on any other field is applied exactly as given, so starred namespaces get no special place in it.","example":{"direction":"asc","field":"namespace_name"}},"sorts":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Sorts","description":"Sort criteria as a list of {field, direction} — the shape Studio datatables and the retriever list send. The first entry is the primary sort. Takes precedence over the singular `sort`. To keep starred namespaces on top of another order, name starred first: the second entry then orders the namespaces inside each group. Any other second entry is ignored.","example":[{"direction":"desc","field":"starred"},{"direction":"desc","field":"created_at"}]},"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search","description":"Search term for wildcard search across namespace_id, namespace_name, description, and other text fields.","example":"ns_abc123"},"case_sensitive":{"type":"boolean","title":"Case Sensitive","description":"If True, filters and search will be case-sensitive","default":false}},"type":"object","title":"ListNamespacesRequest","description":"Request schema for listing namespaces.\n\nInherits body-level limit/page_size/offset/page — body values\nwin over query pagination via merge_body_pagination.","examples":[{"filters":{"namespace_id":"ns_abc123"},"sort":{"direction":"asc","field":"namespace_name"}},{"search":"ns_abc123"}]},"ListNamespacesResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/NamespaceModel"},"type":"array","title":"Results","description":"List of namespaces matching the query"},"pagination":{"$ref":"#/components/schemas/PaginationResponse","description":"Pagination information for the current result window"},"total_count":{"type":"integer","title":"Total Count","description":"Total number of namespaces that match the query"},"stats":{"anyOf":[{"$ref":"#/components/schemas/NamespaceListStats"},{"type":"null"}],"description":"Aggregate statistics across all namespaces in the result"}},"type":"object","required":["results","pagination","total_count"],"title":"ListNamespacesResponse","description":"Response schema for listing namespaces.","examples":[{"pagination":{"has_more":false,"limit":10,"skip":0},"results":[{"created_at":"2024-01-15T10:30:00Z","description":"This namespace contains playlists from Spotify","feature_extractors":[{"feature_extractor_name":"multimodal_extractor","version":"v1"},{"feature_extractor_name":"image_extractor","params":{"model":"siglip_base"},"version":"v1"}],"namespace_id":"ns_ab12cd34ef","namespace_name":"spotify_playlists_dev","payload_indexes":[{"field_name":"metadata.title","type":"text"}],"updated_at":"2024-01-15T10:30:00Z"}],"total_count":1}]},"ListNotificationsRequest":{"properties":{"notification_type":{"anyOf":[{"$ref":"#/components/schemas/NotificationType"},{"type":"null"}],"description":"Filter by notification type"},"priority":{"anyOf":[{"$ref":"#/components/schemas/NotificationPriority"},{"type":"null"}],"description":"Filter by priority"},"read":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Read","description":"Filter by read status"},"user_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id","description":"Filter by user ID"}},"type":"object","title":"ListNotificationsRequest","description":"Request model for listing notifications."},"ListNotificationsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/Notification"},"type":"array","title":"Results","description":"List of notifications"},"pagination":{"additionalProperties":true,"type":"object","title":"Pagination","description":"Pagination information"},"total":{"type":"integer","title":"Total","description":"Total number of notifications"}},"type":"object","required":["results","pagination","total"],"title":"ListNotificationsResponse","description":"Response model for listing notifications."},"ListObjectsRequest":{"properties":{"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"Filters to apply to the object list"},"sort":{"anyOf":[{"$ref":"#/components/schemas/SortOption"},{"type":"null"}],"description":"Sort options for the object list"},"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search","description":"Search term to filter objects by key or metadata"},"select":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Select","description":"OPTIONAL. List of fields to include in the response. Supports dot notation for nested fields (e.g., 'metadata.title', 'status'). When specified, only the selected fields will be returned in the object results, reducing response size. System fields like 'object_id' and 'bucket_id' are always included. Use this to optimize response size when working with large objects.","examples":[["metadata","status","created_at"],["object_id","file_extension","size"],["metadata.title","content_type"]]},"return_presigned_urls":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Return Presigned Urls","description":"Generate fresh presigned download URLs for all blobs with S3 storage. When true, each blob will include a 'presigned_url' in its properties. URLs expire after 1 hour.","default":false}},"additionalProperties":false,"type":"object","title":"ListObjectsRequest","description":"Request model for listing objects in a bucket."},"ListObjectsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/ObjectResponse"},"type":"array","title":"Results","description":"List of objects matching the query"},"pagination":{"$ref":"#/components/schemas/PaginationResponse","description":"Pagination information"},"stats":{"anyOf":[{"$ref":"#/components/schemas/ObjectListStats"},{"type":"null"}],"description":"Aggregate statistics over the returned page of objects. For bucket-wide totals use ?include_total=true and read pagination.total instead."}},"type":"object","required":["results","pagination"],"title":"ListObjectsResponse","description":"Response model for listing objects in a bucket.","examples":[{"pagination":{"has_more":false,"limit":10,"skip":0},"results":[{"blobs":[],"bucket_id":"bkt_9xy8z7","created_at":"2024-10-21T10:30:00Z","key_prefix":"/contract-2024","metadata":{"category":"contracts","year":2024},"object_id":"obj_123abc456def","status":"PENDING","updated_at":"2024-10-21T10:30:00Z"}]}]},"ListPartition":{"properties":{"index":{"type":"integer","minimum":0.0,"title":"Index","description":"This worker's partition, from 0 to count - 1.","examples":[0]},"count":{"type":"integer","maximum":256.0,"minimum":1.0,"title":"Count","description":"How many partitions the documents are split into. Every document falls in exactly one.","examples":[4]}},"type":"object","required":["index","count"],"title":"ListPartition","description":"One of ``count`` disjoint partitions of a list's matching documents."},"ListPublicExtractorsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/PublicExtractorListItem"},"type":"array","title":"Results"},"total_count":{"type":"integer","title":"Total Count"},"page":{"type":"integer","title":"Page"},"page_size":{"type":"integer","title":"Page Size"},"total_pages":{"type":"integer","title":"Total Pages"}},"type":"object","required":["results","total_count","page","page_size","total_pages"],"title":"ListPublicExtractorsResponse"},"ListPublicRetrieversResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/PublicRetrieverListItem"},"type":"array","title":"Results","description":"List of public retrievers"},"total_count":{"type":"integer","title":"Total Count","description":"Total number of public retrievers matching the query"},"page":{"type":"integer","title":"Page","description":"Current page number"},"page_size":{"type":"integer","title":"Page Size","description":"Results per page"},"total_pages":{"type":"integer","title":"Total Pages","description":"Total number of pages"},"stats":{"anyOf":[{"$ref":"#/components/schemas/PublicRetrieverListStats"},{"type":"null"}],"description":"Aggregate statistics across all public retrievers"}},"type":"object","required":["results","total_count","page","page_size","total_pages"],"title":"ListPublicRetrieversResponse","description":"Response for listing public retrievers.\n\nFollows the same pattern as ListCollectionsResponse for consistent developer experience."},"ListRetrieversRequest":{"properties":{"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search","description":"Search term for wildcard search across retriever_id, retriever_name, description, and other text fields"},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","description":"Filters applied directly to the query — any stored field works, e.g. {\"collection_ids\": {\"$in\": [\"col_x\"]}} to filter by collection, or {\"retriever_name\": \"...\"}."},"sorts":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Sorts","description":"Sort options for the retriever list"},"sort":{"anyOf":[{"$ref":"#/components/schemas/SortOption"},{"type":"null"}],"description":"Single sort option (alias for the first entry of `sorts`). Every other list resource accepts this shape, so callers reach for it here too; without it, a `sort` on retrievers was silently dropped and DESC returned ASC order (class)."},"case_sensitive":{"type":"boolean","title":"Case Sensitive","description":"If True, filters and search will be case-sensitive","default":false}},"type":"object","title":"ListRetrieversRequest","description":"Request to list retrievers."},"ListRetrieversResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/RetrieverModel-Output"},"type":"array","title":"Results","description":"List of retrievers in the namespace."},"total":{"type":"integer","title":"Total","description":"Total number of retrievers.","default":0},"pagination":{"anyOf":[{"$ref":"#/components/schemas/PaginationResponse"},{"type":"null"}],"description":"Pagination details (next/previous cursors and total)."},"warnings":{"items":{"$ref":"#/components/schemas/DegradedEntry"},"type":"array","title":"Warnings","description":"Why this page may not be the whole answer. An entry with resource 'namespace' and reason 'unresolved' means X-Namespace did not resolve for this API key, so the empty list is not that namespace's contents (the same condition as the X-Namespace-Unresolved response header). Empty when the namespace resolved."}},"type":"object","title":"ListRetrieversResponse","description":"Response from listing retrievers."},"ListSessionsRequest":{"properties":{"status":{"anyOf":[{"$ref":"#/components/schemas/SessionStatus"},{"type":"null"}],"description":"Filter by session status"},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","description":"Additional filters"},"sort":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Sort","description":"Sort configuration"}},"type":"object","title":"ListSessionsRequest","description":"Request payload for listing sessions.\n\nAttributes:\n    status: Optional status filter\n    filters: Optional additional filters\n    sort: Optional sort configuration\n\nExample:\n    ```python\n    request = ListSessionsRequest(\n        status=\"active\",\n        filters={\"user_id\": \"user_123\"}\n    )\n    ```"},"ListSessionsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/GetSessionResponse"},"type":"array","title":"Results","description":"Session list"},"total":{"type":"integer","title":"Total","description":"Total matching sessions"},"pagination":{"additionalProperties":true,"type":"object","title":"Pagination","description":"Pagination information"}},"type":"object","required":["results","total","pagination"],"title":"ListSessionsResponse","description":"Response for listing sessions.\n\nAttributes:\n    results: List of session summaries\n    total: Total number of sessions matching query\n    pagination: Pagination information\n\nExample:\n    ```python\n    response = ListSessionsResponse(\n        results=[...],\n        total=50,\n        pagination={...}\n    )\n    ```"},"ListSnapshotsRequest":{"properties":{"skip":{"type":"integer","minimum":0.0,"title":"Skip","default":0},"limit":{"type":"integer","maximum":100.0,"minimum":1.0,"title":"Limit","default":20}},"type":"object","title":"ListSnapshotsRequest"},"ListSnapshotsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/SnapshotModel"},"type":"array","title":"Results"},"total_count":{"type":"integer","title":"Total Count"}},"type":"object","required":["results","total_count"],"title":"ListSnapshotsResponse"},"ListStorageConnectionsRequest":{"properties":{"provider_type":{"anyOf":[{"$ref":"#/components/schemas/StorageProvider"},{"type":"null"}],"description":"OPTIONAL. Filter connections by provider type. Supported: google_drive, s3, snowflake, sharepoint, tigris. If not provided, returns connections of all types.","examples":["google_drive","s3","snowflake","sharepoint","tigris"]},"status":{"anyOf":[{"$ref":"#/components/schemas/TaskStatusEnum"},{"type":"null"}],"description":"OPTIONAL. Filter connections by operational status. ACTIVE: Healthy and ready for use. SUSPENDED: Temporarily disabled. FAILED: Health checks failing. ARCHIVED: Permanently retired."},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active","description":"OPTIONAL. Filter by active flag. True: Returns only active connections (status=ACTIVE). False: Returns only inactive connections (SUSPENDED/FAILED/ARCHIVED). If not provided, returns connections of all active states."}},"type":"object","title":"ListStorageConnectionsRequest","description":"Request payload for listing storage connections with filters.\n\nUse this to filter connections by provider type, status, or active flag.\nResults are paginated automatically.\n\n**Use Cases:**\n- List all active Google Drive connections\n- Find failed connections that need attention\n- Filter by provider type for sync configuration\n\n**Examples:**\n```python\n# List all active Google Drive connections\n{\n    \"provider_type\": \"google_drive\",\n    \"is_active\": True\n}\n\n# Find failed connections\n{\n    \"status\": \"FAILED\"\n}\n```","examples":[{"description":"List active Google Drive connections","is_active":true,"provider_type":"google_drive"},{"description":"Find failed connections","status":"FAILED"},{"description":"List all connections (no filters)"}]},"ListSyncConfigurationsRequest":{"properties":{"connection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Connection Id","description":"Filter sync configurations by connection ID. NOT REQUIRED. When provided, only returns syncs using this connection. Useful for managing syncs across multiple storage providers. Example: 'conn_abc123'","examples":["conn_abc123","conn_s3_prod"]},"status":{"anyOf":[{"$ref":"#/components/schemas/TaskStatusEnum"},{"type":"null"}],"description":"Filter sync configurations by status. NOT REQUIRED. Valid values: 'PENDING', 'PROCESSING', 'COMPLETED', 'FAILED' (any TaskStatusEnum value). Use is_active=false to find paused syncs. Useful for finding syncs that need attention or monitoring. Example: 'FAILED' to find syncs with errors.","examples":["PENDING","PROCESSING","FAILED"]},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active","description":"Filter sync configurations by active status. NOT REQUIRED. True: Only active syncs that are currently monitoring/processing. False: Only paused/disabled syncs. Omit to include both active and inactive.","examples":[true,false]}},"type":"object","title":"ListSyncConfigurationsRequest","description":"Request to filter sync configurations for listing.\n\nAll filters are optional - when omitted, returns all sync configurations\nfor the bucket. Multiple filters can be combined for precise queries.\n\nUse Cases:\n    - Find all syncs for a specific connection\n    - List only active or paused syncs\n    - Filter by status to find failed syncs\n\nRequirements:\n    - All fields are OPTIONAL\n    - Multiple filters are combined with AND logic\n    - Empty request returns all configurations","examples":[{"description":"List all configurations (no filters)"},{"description":"Find active syncs only","is_active":true},{"connection_id":"conn_s3_prod","description":"Find failed syncs for a specific connection","status":"FAILED"},{"description":"Find paused syncs","is_active":false}]},"ListSyncJobsRequest":{"properties":{"status":{"anyOf":[{"$ref":"#/components/schemas/SyncJobStatus"},{"type":"null"}],"description":"Filter jobs by status (running, completed, failed)."}},"type":"object","title":"ListSyncJobsRequest","description":"Request to list sync job history for a sync configuration."},"ListTasksRequest":{"properties":{"status":{"anyOf":[{"$ref":"#/components/schemas/TaskStatusEnum"},{"type":"null"}],"description":"Filter by specific task status (PENDING, IN_PROGRESS, PROCESSING, COMPLETED, FAILED, CANCELED, etc.)."},"task_type":{"anyOf":[{"$ref":"#/components/schemas/TaskType"},{"type":"null"}],"description":"Filter by task type (e.g., API_BUCKETS_OBJECTS_CREATE, BATCH_CONFIRM, etc.)"},"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"Advanced filters to apply."},"sort":{"anyOf":[{"$ref":"#/components/schemas/SortOption"},{"type":"null"}],"description":"Sort options."},"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search","description":"Search term."}},"type":"object","title":"ListTasksRequest","description":"Request model for listing tasks.\n\nFilter tasks by status, type, or other criteria."},"ListTasksResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/TaskResponse"},"type":"array","title":"Results"},"pagination":{"$ref":"#/components/schemas/PaginationResponse"}},"type":"object","required":["results","pagination"],"title":"ListTasksResponse","description":"Response model for listing tasks."},"ListTaxonomiesRequest":{"properties":{"limit":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":1.0},{"type":"null"}],"title":"Limit","description":"Page size. A body value wins over the `limit` query param."},"page_size":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":1.0},{"type":"null"}],"title":"Page Size","description":"Alias for `limit` (page size). If both are given, `limit` wins."},"offset":{"anyOf":[{"type":"integer","maximum":10000.0,"minimum":0.0},{"type":"null"}],"title":"Offset","description":"Number of results to skip (legacy, use cursor instead). A body value wins over the `offset` query param."},"page":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Page","description":"1-indexed page number. Folds to offset = (page-1) * limit. If both `page` and `offset` are given, `offset` wins."},"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search","description":"Search term for wildcard search across taxonomy_id, taxonomy_name, description, and other text fields"},"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"Filters to apply to the taxonomy list. Supports filtering by taxonomy_id or taxonomy_name."},"sort":{"anyOf":[{"$ref":"#/components/schemas/SortOption"},{"type":"null"}],"description":"Sort configuration for the taxonomy list (single-column, legacy)"},"sorts":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Sorts","description":"Sort configuration as a list of {field, direction} — the shape Studio datatables and the retriever list send. The first entry is the primary sort. Takes precedence over the singular `sort`."},"case_sensitive":{"type":"boolean","title":"Case Sensitive","description":"If True, filters and search will be case-sensitive","default":false}},"type":"object","title":"ListTaxonomiesRequest","description":"Request model to list taxonomies.\n\nInherits body-level limit/page_size/offset/page — body values\nwin over query pagination via merge_body_pagination."},"ListTaxonomiesResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/TaxonomyResponse"},"type":"array","title":"Results"},"pagination":{"additionalProperties":true,"type":"object","title":"Pagination"},"total_count":{"type":"integer","title":"Total Count"},"stats":{"anyOf":[{"$ref":"#/components/schemas/TaxonomyListStats"},{"type":"null"}],"description":"Aggregate statistics across all taxonomies in the result"}},"type":"object","required":["results","pagination","total_count"],"title":"ListTaxonomiesResponse","description":"Response model for listing taxonomies."},"ListTemplatesRequest":{"properties":{"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","description":"Filters to apply when listing templates. Format: {\"AND\": [{\"field\": \"field_name\", \"operator\": \"eq\", \"value\": \"value\"}]}"},"sort":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Sort","description":"Sort options for the results. Format: {'field': 'name', 'direction': 'asc'}"},"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search","description":"Search term for wildcard search across template_id, name, description, and tags"},"scope":{"anyOf":[{"$ref":"#/components/schemas/TemplateScope"},{"type":"null"}],"description":"Filter by scope (system, organization, or user)"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category","description":"Filter by category"},"is_active":{"type":"boolean","title":"Is Active","description":"Show only active templates","default":true},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags","description":"Filter by tags (templates must have ALL specified tags)"}},"type":"object","title":"ListTemplatesRequest","description":"Request model for listing templates.\n\nProvides the same filtering, sorting, and search capabilities as other\nlist operations (list collections, list buckets, etc.).","examples":[{"category":"semantic_search","is_active":true,"scope":"system","search":"semantic"},{"filters":{"AND":[{"field":"category","operator":"eq","value":"advanced_search"}]},"sort":{"direction":"asc","field":"name"}}]},"ListTemplatesResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/BaseTemplateModel"},"type":"array","title":"Results","description":"List of templates"},"total_count":{"type":"integer","title":"Total Count","description":"Total number of templates matching the query"}},"type":"object","required":["results","total_count"],"title":"ListTemplatesResponse","description":"Response model for listing templates.","examples":[{"results":[{"category":"semantic_search","description":"Simple text-based semantic search","internal_id":"system","is_active":true,"is_public":true,"name":"Basic Semantic Search","scope":"system","template_id":"tmpl_semantic_search","template_type":"retriever"}],"total_count":1}]},"ListTicketsRequest":{"properties":{"status":{"anyOf":[{"$ref":"#/components/schemas/SupportTicketStatus"},{"type":"null"}]},"category":{"anyOf":[{"$ref":"#/components/schemas/SupportTicketCategory"},{"type":"null"}]},"scope":{"anyOf":[{"$ref":"#/components/schemas/SupportScope"},{"type":"null"}]},"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search"}},"type":"object","title":"ListTicketsRequest"},"ListTicketsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/TicketResponse"},"type":"array","title":"Results"},"pagination":{"$ref":"#/components/schemas/PaginationResponse"},"tickets":{"items":{"$ref":"#/components/schemas/TicketResponse"},"type":"array","title":"Tickets","description":"Deprecated alias of `results`, kept for existing clients. Read `results`, the row key every list route shares.","deprecated":true,"readOnly":true}},"type":"object","required":["results","pagination","tickets"],"title":"ListTicketsResponse"},"ListToolsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/ToolInfo"},"type":"array","title":"Results","description":"Available tools"},"total":{"type":"integer","title":"Total","description":"Total number of tools"},"categories":{"items":{"type":"string"},"type":"array","title":"Categories","description":"Unique tool categories"}},"type":"object","required":["results","total","categories"],"title":"ListToolsResponse","description":"Response for listing available agent tools.\n\nUse this endpoint to discover available tools before creating a session.\nPass tool names to available_tools in AgentConfig when creating a session.\n\nAttributes:\n    results: List of available tools with descriptions\n    total: Total number of tools available\n    categories: Unique tool categories\n\nExample:\n    ```python\n    response = ListToolsResponse(\n        results=[\n            ToolInfo(name=\"smart_search\", description=\"...\", category=\"search\"),\n            ToolInfo(name=\"list_collections\", description=\"...\", category=\"read\"),\n        ],\n        total=25,\n        categories=[\"search\", \"read\", \"create\"]\n    )\n    ```"},"ListUploadsRequest":{"properties":{"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"Complex filters using logical operators (AND, OR, NOT). Supports shorthand syntax: pass field-value pairs for equality matching. Examples:   - Filter by status: {'status': 'PENDING'}   - Filter by metadata: {'metadata.campaign': 'summer_2024'}   - Complex: {'AND': [{'field': 'status', 'operator': 'eq', 'value': 'PENDING'},                       {'field': 'file_size_bytes', 'operator': 'gte', 'value': 1000000}]} See LogicalOperator documentation for full syntax.","examples":[{"status":"PENDING"},{"metadata.campaign":"summer_2024"},{"AND":[{"field":"status","operator":"eq","value":"COMPLETED"},{"field":"created_at","operator":"gte","value":"2024-01-01T00:00:00Z"}]}]},"sort":{"anyOf":[{"$ref":"#/components/schemas/SortOption"},{"type":"null"}],"description":"Sort options for ordering results. Can sort by any field including metadata fields using dot notation. Default: created_at descending (newest first). Examples:   - Sort by creation date: {'field': 'created_at', 'direction': 'desc'}   - Sort by file size: {'field': 'file_size_bytes', 'direction': 'asc'}   - Sort by metadata: {'field': 'metadata.priority', 'direction': 'desc'}","examples":[{"direction":"desc","field":"created_at"},{"direction":"asc","field":"file_size_bytes"},{"direction":"desc","field":"metadata.priority"}]},"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search","description":"Full-text search across filename and metadata fields. Case-insensitive partial matching. Searches in: filename, metadata values (converted to strings). Examples:   - 'video' - finds 'product_video.mp4', 'tutorial_video.mov'   - 'summer' - finds uploads with metadata.campaign='summer_2024'","examples":["video","summer_2024","profile"]},"return_presigned_urls":{"type":"boolean","title":"Return Presigned Urls","description":"Whether to regenerate presigned URLs for S3 access in the response. OPTIONAL, defaults to false. If true:   - Generates new GET presigned URLs for completed uploads   - Useful for downloading files from S3   - Adds ~50ms per upload to response time. If false:   - No presigned URLs in response   - Faster response time. Note: Original PUT presigned URLs are never returned (security).","default":false},"limit":{"type":"integer","maximum":100.0,"minimum":1.0,"title":"Limit","description":"Maximum number of uploads to return. OPTIONAL, defaults to 20.","default":20,"examples":[20,50,100]},"offset":{"type":"integer","minimum":0.0,"title":"Offset","description":"Number of uploads to skip for pagination. OPTIONAL, defaults to 0.","default":0,"examples":[0,20,100]}},"type":"object","title":"ListUploadsRequest","description":"Request model for listing uploads with filtering, sorting, and search.\n\nProvides flexible querying capabilities using the same filter/sort framework\nas documents, objects, and other list endpoints.\n\nSupports:\n    - Complex filters using LogicalOperator (AND, OR, NOT)\n    - Shorthand filter syntax: {\"metadata.campaign\": \"summer_2024\"}\n    - Full-text search across filename and metadata\n    - Multi-field sorting\n    - Pagination with limit/offset\n\nExamples:\n    - List all pending uploads in a bucket\n    - Find uploads by metadata campaign\n    - Search for uploads by filename pattern\n    - Sort by file size or creation date","examples":[{"description":"List all pending uploads","filters":{"status":"PENDING"},"limit":20,"offset":0,"sort":{"direction":"desc","field":"created_at"}},{"description":"Find large completed uploads","filters":{"AND":[{"field":"status","operator":"eq","value":"COMPLETED"},{"field":"file_size_bytes","operator":"gte","value":10485760}]},"limit":50,"sort":{"direction":"desc","field":"file_size_bytes"}},{"description":"Search for video uploads in summer campaign","filters":{"metadata.campaign":"summer_2024"},"limit":100,"search":"video"},{"description":"List failed uploads for debugging","filters":{"status":"FAILED"},"limit":50,"return_presigned_urls":true,"sort":{"direction":"desc","field":"created_at"}}]},"ListUploadsResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/UploadResponse"},"type":"array","title":"Results","description":"List of upload records matching the query"},"pagination":{"$ref":"#/components/schemas/PaginationResponse","description":"Pagination metadata including total count, limit, offset, has_more"},"stats":{"$ref":"#/components/schemas/UploadListStats","description":"Aggregate statistics across all uploads in the result"}},"type":"object","required":["results","pagination","stats"],"title":"ListUploadsResponse","description":"Response model for listing uploads.","examples":[{"pagination":{"has_more":true,"limit":20,"offset":0,"total_count":42},"results":[{"bucket_id":"bkt_prod","created_at":"2024-01-15T10:30:00Z","file_size_bytes":52428800,"filename":"video1.mp4","status":"COMPLETED","upload_id":"upl_abc123"}],"stats":{"avg_file_size_bytes":12483047,"total_size_bytes":524288000,"total_uploads":42,"unique_buckets":3,"uploads_by_status":{"COMPLETED":35,"FAILED":2,"PENDING":5}}}]},"ListUsersResponse":{"properties":{"users":{"items":{"$ref":"#/components/schemas/AppUserResponse"},"type":"array","title":"Users"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["users","total"],"title":"ListUsersResponse"},"ListVideosRequest":{"properties":{"scope":{"anyOf":[{"$ref":"#/components/schemas/SupportScope"},{"type":"null"}]},"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search"}},"type":"object","title":"ListVideosRequest"},"ListVideosResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/VideoResponse"},"type":"array","title":"Results"},"pagination":{"$ref":"#/components/schemas/PaginationResponse"},"videos":{"items":{"$ref":"#/components/schemas/VideoResponse"},"type":"array","title":"Videos","description":"Deprecated alias of `results`, kept for existing clients. Read `results`, the row key every list route shares.","deprecated":true,"readOnly":true}},"type":"object","required":["results","pagination","videos"],"title":"ListVideosResponse"},"ListWebhooksRequest":{"properties":{"event_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Event Type","description":"Filter by event type"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active","description":"Filter by active status"}},"type":"object","title":"ListWebhooksRequest","description":"Request for listing webhooks with filters.\n\nFilters webhooks by various criteria."},"ListWebhooksResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/Webhook-Output"},"type":"array","title":"Results","description":"List of webhooks"},"pagination":{"$ref":"#/components/schemas/PaginationResponse","description":"Pagination information"},"total":{"type":"integer","title":"Total","description":"Total number of webhooks"}},"type":"object","required":["results","pagination","total"],"title":"ListWebhooksResponse","description":"Response for listing webhooks with pagination.\n\nReturns a paginated list of webhook records."},"ListingStatus":{"type":"string","enum":["draft","published","archived","suspended"],"title":"ListingStatus","description":"Status of a marketplace listing."},"ListingVisibility":{"type":"string","enum":["listed","unlisted"],"title":"ListingVisibility","description":"Visibility level for a marketplace listing.\n\n- LISTED: Appears in marketplace catalog, homepage showcase, and sitemap.\n- UNLISTED: Accessible via direct link but hidden from catalog/showcase."},"LogicalOperator-Input":{"properties":{"AND":{"anyOf":[{"items":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"$ref":"#/components/schemas/FilterCondition"}]},"type":"array"},{"type":"null"}],"title":"And","description":"Logical AND operation - all conditions must be true","example":[{"field":"name","operator":"eq","value":"John"},{"field":"age","operator":"gte","value":30}]},"OR":{"anyOf":[{"items":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"$ref":"#/components/schemas/FilterCondition"}]},"type":"array"},{"type":"null"}],"title":"Or","description":"Logical OR operation - at least one condition must be true","example":[{"field":"status","operator":"eq","value":"active"},{"field":"role","operator":"eq","value":"admin"}]},"NOT":{"anyOf":[{"items":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"$ref":"#/components/schemas/FilterCondition"}]},"type":"array"},{"type":"null"}],"title":"Not","description":"Logical NOT operation - all conditions must be false","example":[{"field":"department","operator":"eq","value":"HR"},{"field":"location","operator":"eq","value":"remote"}]},"case_sensitive":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Case Sensitive","description":"Whether to perform case-sensitive matching","default":false,"example":true}},"additionalProperties":true,"type":"object","title":"LogicalOperator","description":"Represents a logical operation (AND, OR, NOT) on filter conditions.\n\nAllows nesting with a defined depth limit.\n\nAlso supports shorthand syntax where field names can be passed directly\nas key-value pairs for equality filtering (e.g., {\"metadata.title\": \"value\"})."},"LogicalOperator-Output":{"properties":{"AND":{"anyOf":[{"items":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Output"},{"$ref":"#/components/schemas/FilterCondition"}]},"type":"array"},{"type":"null"}],"title":"And","description":"Logical AND operation - all conditions must be true","example":[{"field":"name","operator":"eq","value":"John"},{"field":"age","operator":"gte","value":30}]},"OR":{"anyOf":[{"items":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Output"},{"$ref":"#/components/schemas/FilterCondition"}]},"type":"array"},{"type":"null"}],"title":"Or","description":"Logical OR operation - at least one condition must be true","example":[{"field":"status","operator":"eq","value":"active"},{"field":"role","operator":"eq","value":"admin"}]},"NOT":{"anyOf":[{"items":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Output"},{"$ref":"#/components/schemas/FilterCondition"}]},"type":"array"},{"type":"null"}],"title":"Not","description":"Logical NOT operation - all conditions must be false","example":[{"field":"department","operator":"eq","value":"HR"},{"field":"location","operator":"eq","value":"remote"}]},"case_sensitive":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Case Sensitive","description":"Whether to perform case-sensitive matching","default":false,"example":true}},"additionalProperties":true,"type":"object","title":"LogicalOperator","description":"Represents a logical operation (AND, OR, NOT) on filter conditions.\n\nAllows nesting with a defined depth limit.\n\nAlso supports shorthand syntax where field names can be passed directly\nas key-value pairs for equality filtering (e.g., {\"metadata.title\": \"value\"})."},"ManifestParameterSpec":{"properties":{"name":{"type":"string","pattern":"^[a-zA-Z_][a-zA-Z0-9_]*$","title":"Name","description":"Parameter name, referenced as ${{ params.<name> }}","examples":["camera_url"]},"type":{"type":"string","enum":["string","integer","number","boolean","array"],"title":"Type","description":"Value type: string, integer, number, boolean or array. An array is a list of scalars, set with items, and is referenced as the whole value of a field.","default":"string"},"items":{"anyOf":[{"type":"string","enum":["string","integer","number","boolean"]},{"type":"null"}],"title":"Items","description":"Type of each list item when type is array: string (the default), integer, number or boolean. Not allowed on other types."},"enum":{"anyOf":[{"items":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"}]},"type":"array","minItems":1},{"type":"null"}],"title":"Enum","description":"Allowed values. A supplied value, and the default, must be one of them. On an array, every item must be one of them.","examples":[["image","video","audio"]]},"required":{"type":"boolean","title":"Required","description":"Whether a value must be supplied. Ignored when a default is set.","default":true},"default":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"items":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"}]},"type":"array"},{"type":"null"}],"title":"Default","description":"Value used when none is supplied. A list for an array parameter."},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description","description":"What the value is for, shown next to the input"}},"additionalProperties":false,"type":"object","required":["name"],"title":"ManifestParameterSpec","description":"One value a manifest needs from whoever applies it.","examples":[{"description":"Your camera's rtsp:// url","name":"camera_url","required":true,"type":"string"},{"default":300,"name":"polling_seconds","type":"integer"},{"default":["image","video"],"enum":["image","video","audio"],"items":"string","name":"modalities","type":"array"}]},"ManifestQuote":{"properties":{"index_usd":{"type":"number","title":"Index Usd","description":"What indexing the inventory is charged, once (per bucket batch, minimum included)"},"monthly_usd":{"type":"number","title":"Monthly Usd","description":"Storage for what the inventory produces plus the stated queries"},"storage_usd":{"type":"number","title":"Storage Usd"},"queries_usd":{"type":"number","title":"Queries Usd"},"unit_prices":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Unit Prices","description":"The rate-card line each added unit is charged at: modality, feature, rate_usd per `per` units"},"collections":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Collections","description":"Per collection: extractor, charges, documents out, vector indexes, and `unpriced` with the reason when billing cannot price it"},"unpriced_collections":{"items":{"type":"string"},"type":"array","title":"Unpriced Collections"},"assumptions":{"items":{"type":"string"},"type":"array","title":"Assumptions"}},"type":"object","required":["index_usd","monthly_usd","storage_usd","queries_usd","unit_prices","collections","unpriced_collections","assumptions"],"title":"ManifestQuote"},"ManifestSchemaDiscovery":{"properties":{"manifest_version":{"type":"string","title":"Manifest Version","description":"Current manifest schema version"},"resource_types":{"items":{"type":"string"},"type":"array","title":"Resource Types","description":"List of supported resource types"},"schemas":{"additionalProperties":true,"type":"object","title":"Schemas","description":"JSON Schema for each resource type"},"dependency_graph":{"additionalProperties":{"items":{"type":"string"},"type":"array"},"type":"object","title":"Dependency Graph","description":"Resource dependencies (key depends on values)"},"examples":{"additionalProperties":{"type":"string"},"type":"object","title":"Examples","description":"YAML example for each resource type"},"example_manifest":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Example Manifest","description":"One complete manifest in YAML that uses parameters, a storage connection with a bucket sync, a seed, collections, a retriever, a taxonomy, a cluster and an acceptance block. It validates as written once its parameters are supplied."},"authoring_loop":{"items":{"type":"string"},"type":"array","title":"Authoring Loop","description":"The steps to write, check and apply a manifest, in order"},"extractor_catalog":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Extractor Catalog","description":"Extractors this plane serves: name, version, input types, the feature URIs they write and their parameters with defaults. Use GET /v1/discovery/extractors for the full schemas."},"stage_catalog":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Stage Catalog","description":"Retriever stage ids with category and parameter names. Use GET /v1/discovery/stages for example configurations."}},"type":"object","required":["manifest_version","resource_types","schemas","dependency_graph"],"title":"ManifestSchemaDiscovery","description":"Manifest schema discovery for agent-driven configuration.","examples":[{"dependency_graph":{"bucket":["namespace"],"collection":["namespace","bucket"],"retriever":["namespace","collection"]},"examples":{"namespace":"namespaces:\n  - name: my_ns\n    feature_extractors:\n      - name: multimodal_extractor"},"manifest_version":"1.0","resource_types":["namespace","bucket","collection","retriever"],"schemas":{"namespace":{"properties":{},"type":"object"}}}]},"MappingTarget":{"properties":{"kind":{"type":"string","enum":["metadata","vector","identity","parent","ignore"],"title":"Kind","description":"metadata | vector | identity | parent | ignore"},"path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Path","description":"Target path for kind=metadata (e.g. 'metadata.brand')."},"index":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Index","description":"Vector index name for kind=vector."},"dim":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Dim","description":"Vector dimension for kind=vector."},"dtype":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dtype","description":"Source vector dtype for kind=vector (e.g. 'float16-base64')."},"role":{"anyOf":[{"type":"string","enum":["root_object_id","root_bucket_id","source_object_id","source_document_id","source_collection_id","document_id","content_hash"]},{"type":"null"}],"title":"Role","description":"Lineage role for kind=identity."},"chain_position":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Chain Position","description":"Position in chain[] for kind=parent."},"expected_type":{"anyOf":[{"type":"string","enum":["string","integer","float","boolean","datetime","vector","object","null"]},{"type":"null"}],"title":"Expected Type","description":"The source type this target requires. When set and the inferred source type differs, validate_mapping flags it (unhappy case f)."}},"additionalProperties":true,"type":"object","required":["kind"],"title":"MappingTarget","description":"Where a source field lands in the Mixpeek document."},"MappingValidationError":{"properties":{"field":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Field","description":"Source field the error is about; None for whole-mapping errors."},"error":{"type":"string","title":"Error"}},"type":"object","required":["error"],"title":"MappingValidationError"},"MappingValidationRequest":{"properties":{"source_fields":{"items":{"$ref":"#/components/schemas/SourceField"},"type":"array","title":"Source Fields","description":"The declared source fields."},"mapping":{"$ref":"#/components/schemas/ImportMapping","description":"The finalized source->target mapping to validate."},"known_index_dims":{"anyOf":[{"additionalProperties":{"type":"integer"},"type":"object"},{"type":"null"}],"title":"Known Index Dims","description":"Known target vector index dims, for dim-mismatch checks."}},"type":"object","required":["mapping"],"title":"MappingValidationRequest","description":"Request body for POST /v1/collections/import/validate-mapping."},"MappingValidationResult":{"properties":{"ok":{"type":"boolean","title":"Ok"},"errors":{"items":{"$ref":"#/components/schemas/MappingValidationError"},"type":"array","title":"Errors"}},"type":"object","required":["ok"],"title":"MappingValidationResult"},"MarkAsReadRequest":{"properties":{"user_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id","description":"User ID to mark all as read for"}},"type":"object","title":"MarkAsReadRequest","description":"Request model for marking notifications as read."},"MarkdownContent":{"properties":{"title":{"type":"string","maxLength":200,"minLength":1,"title":"Title","description":"Title for the markdown content section","examples":["How it Works","Getting Started","About This Search","Search Tips"]},"content":{"type":"string","maxLength":50000,"minLength":1,"title":"Content","description":"Markdown-formatted content. Supports standard markdown syntax including headers, lists, links, images, code blocks, and emphasis. Limited to 50KB to prevent database issues.","examples":["# Welcome\n\nThis search uses **AI** to understand your queries.","## Features\n\n- Semantic search\n- Multi-modal\n- Fast results","### Tips\n\n1. Use specific terms\n2. Try multiple queries\n\n[Learn more](https://docs.example.com)"]}},"type":"object","required":["title","content"],"title":"MarkdownContent","description":"Reusable markdown content model with title and content.\n\nThis model provides a structured way to include rich markdown content\nanywhere in the published retriever configuration. Includes safety\nconstraints to prevent database issues."},"MarketplaceCatalogListing":{"properties":{"listing_id":{"type":"string","title":"Listing Id","description":"Unique identifier for the listing"},"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace containing the retriever"},"retriever_id":{"type":"string","title":"Retriever Id","description":"Retriever being offered in the marketplace"},"title":{"type":"string","title":"Title","description":"Public display title","examples":["Brand Safety Classification API","Video Search Engine"]},"description":{"type":"string","title":"Description","description":"Public description of what this listing provides"},"public_name":{"type":"string","maxLength":50,"minLength":3,"title":"Public Name","description":"Public URL-safe slug for the listing (e.g., 'video-search'). Used in public URL: mxp.co/m/{public_name}. Must be globally unique.","examples":["brand-safety-api","video-search","product-catalog"]},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category","description":"Catalog category. One of: Brand Safety, Advertising, Media, Faces & People, Art & Archives, Personalization, Content Safety, Spatial, Ecommerce. Writes also accept the slug form (e.g., 'faces-and-people') and store the label.","examples":["Brand Safety","Media"]},"groups":{"items":{"type":"string"},"type":"array","title":"Groups","description":"Curated groups this listing belongs to, as lowercase slugs (e.g., 'ip-screening'). Filter the catalog by one with ?group=.","examples":[["ip-screening"],["media-archives"]]},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Tags for discovery"},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url","description":"URL to listing logo/icon"},"app_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"App Url","description":"Optional URL to a live canvas app powered by this retriever (e.g., 'https://nga.mxp.co'). When set, the listing appears in the public showcase at mixpeek.com/showcase.","examples":["https://nga.mxp.co","https://mxp.co/r/superbowl"]},"icon_base64":{"anyOf":[{"type":"string","maxLength":300000},{"type":"null"}],"title":"Icon Base64","description":"Base64 encoded icon/favicon (data URI format). Max size: ~200KB encoded. Use for small icons.","examples":["data:image/png;base64,iVBORw0KGgoAAAANS..."]},"available_tiers":{"items":{"$ref":"#/components/schemas/SubscriptionTierConfig"},"type":"array","title":"Available Tiers","description":"Available subscription tiers (must include at least one tier, typically FREE for public listings)"},"display_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Display Config","description":"JSON-based UI configuration for the public interface. Follows a component-based schema (inspired by json-render): { 'components': [...], 'theme': {...}, 'layout': {...} }. If not provided, a default UI is generated from retriever input_schema.","examples":[{"components":[{"props":{"field":"video_url","label":"Enter video URL"},"type":"SearchInput"},{"props":{"fields":["title","description","score"],"layout":"grid"},"type":"ResultCard"}],"theme":{"fontFamily":"Inter, sans-serif","primaryColor":"#007AFF"}}]},"status":{"$ref":"#/components/schemas/ListingStatus","description":"Publication status","default":"draft"},"visibility":{"$ref":"#/components/schemas/ListingVisibility","description":"Visibility level. 'listed' = shown in marketplace catalog & homepage showcase. 'unlisted' = accessible via direct link only (not in catalog).","default":"unlisted"},"is_active":{"type":"boolean","title":"Is Active","description":"DEPRECATED: Use 'status' field instead. Computed from status (True if PUBLISHED, False otherwise).","default":true,"deprecated":true},"featured_rank":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Featured Rank","description":"Editorial ordering for the catalog. Lower sorts first (1 = top slot). Listings without a rank fall back to subscriber-count ordering and always sort after ranked ones. This is the single source of truth for catalog order — the homepage showcase, the homepage landing-page showcase strip, and the Studio marketplace all read it, so ordering never has to be hardcoded per-surface.","examples":[1,2,3]},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"When the listing was created"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"When the listing was last updated"},"published_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Published At","description":"When the listing was first published"},"total_subscribers":{"type":"integer","title":"Total Subscribers","description":"Total number of active subscribers","default":0},"total_queries":{"type":"integer","title":"Total Queries","description":"Total queries executed across all subscribers","default":0}},"type":"object","required":["namespace_id","retriever_id","title","description","public_name","available_tiers"],"title":"MarketplaceCatalogListing","description":"A listing as the public catalog serves it, to callers with no credential.\n\nThe owner org's internal_id and the name of its access-password secret stay\non the record and out of the response: elsewhere the API keeps internal_id\nout of what it returns (users/controllers.py, blobs/models.py)."},"MarketplaceListing":{"properties":{"listing_id":{"type":"string","title":"Listing Id","description":"Unique identifier for the listing"},"internal_id":{"type":"string","title":"Internal Id","description":"Organization that owns this listing (provider)"},"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace containing the retriever"},"retriever_id":{"type":"string","title":"Retriever Id","description":"Retriever being offered in the marketplace"},"title":{"type":"string","title":"Title","description":"Public display title","examples":["Brand Safety Classification API","Video Search Engine"]},"description":{"type":"string","title":"Description","description":"Public description of what this listing provides"},"public_name":{"type":"string","maxLength":50,"minLength":3,"title":"Public Name","description":"Public URL-safe slug for the listing (e.g., 'video-search'). Used in public URL: mxp.co/m/{public_name}. Must be globally unique.","examples":["brand-safety-api","video-search","product-catalog"]},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category","description":"Catalog category. One of: Brand Safety, Advertising, Media, Faces & People, Art & Archives, Personalization, Content Safety, Spatial, Ecommerce. Writes also accept the slug form (e.g., 'faces-and-people') and store the label.","examples":["Brand Safety","Media"]},"groups":{"items":{"type":"string"},"type":"array","title":"Groups","description":"Curated groups this listing belongs to, as lowercase slugs (e.g., 'ip-screening'). Filter the catalog by one with ?group=.","examples":[["ip-screening"],["media-archives"]]},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Tags for discovery"},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url","description":"URL to listing logo/icon"},"app_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"App Url","description":"Optional URL to a live canvas app powered by this retriever (e.g., 'https://nga.mxp.co'). When set, the listing appears in the public showcase at mixpeek.com/showcase.","examples":["https://nga.mxp.co","https://mxp.co/r/superbowl"]},"icon_base64":{"anyOf":[{"type":"string","maxLength":300000},{"type":"null"}],"title":"Icon Base64","description":"Base64 encoded icon/favicon (data URI format). Max size: ~200KB encoded. Use for small icons.","examples":["data:image/png;base64,iVBORw0KGgoAAAANS..."]},"available_tiers":{"items":{"$ref":"#/components/schemas/SubscriptionTierConfig"},"type":"array","title":"Available Tiers","description":"Available subscription tiers (must include at least one tier, typically FREE for public listings)"},"display_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Display Config","description":"JSON-based UI configuration for the public interface. Follows a component-based schema (inspired by json-render): { 'components': [...], 'theme': {...}, 'layout': {...} }. If not provided, a default UI is generated from retriever input_schema.","examples":[{"components":[{"props":{"field":"video_url","label":"Enter video URL"},"type":"SearchInput"},{"props":{"fields":["title","description","score"],"layout":"grid"},"type":"ResultCard"}],"theme":{"fontFamily":"Inter, sans-serif","primaryColor":"#007AFF"}}]},"password_secret_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Password Secret Name","description":"Optional organization secret name containing password for access protection. If set, users must provide password to subscribe (even for free tier).","examples":["marketplace_password","demo_access_password"]},"status":{"$ref":"#/components/schemas/ListingStatus","description":"Publication status","default":"draft"},"visibility":{"$ref":"#/components/schemas/ListingVisibility","description":"Visibility level. 'listed' = shown in marketplace catalog & homepage showcase. 'unlisted' = accessible via direct link only (not in catalog).","default":"unlisted"},"is_active":{"type":"boolean","title":"Is Active","description":"DEPRECATED: Use 'status' field instead. Computed from status (True if PUBLISHED, False otherwise).","default":true,"deprecated":true},"featured_rank":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Featured Rank","description":"Editorial ordering for the catalog. Lower sorts first (1 = top slot). Listings without a rank fall back to subscriber-count ordering and always sort after ranked ones. This is the single source of truth for catalog order — the homepage showcase, the homepage landing-page showcase strip, and the Studio marketplace all read it, so ordering never has to be hardcoded per-surface.","examples":[1,2,3]},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"When the listing was created"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"When the listing was last updated"},"published_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Published At","description":"When the listing was first published"},"total_subscribers":{"type":"integer","title":"Total Subscribers","description":"Total number of active subscribers","default":0},"total_queries":{"type":"integer","title":"Total Queries","description":"Total queries executed across all subscribers","default":0}},"type":"object","required":["internal_id","namespace_id","retriever_id","title","description","public_name","available_tiers"],"title":"MarketplaceListing","description":"A marketplace listing for a retriever.\n\nThis is the unified model for all public and marketplace retrievers.\nReplaces the PublishedRetriever system with a simpler, more flexible approach.\n\nFree tier = public retriever (anyone can subscribe for free)\nPaid tiers = monetized marketplace offering"},"MarketplaceListingDetail":{"properties":{"listing_id":{"type":"string","title":"Listing Id","description":"Unique identifier for the listing"},"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace containing the retriever"},"retriever_id":{"type":"string","title":"Retriever Id","description":"Retriever being offered in the marketplace"},"title":{"type":"string","title":"Title","description":"Public display title","examples":["Brand Safety Classification API","Video Search Engine"]},"description":{"type":"string","title":"Description","description":"Public description of what this listing provides"},"public_name":{"type":"string","maxLength":50,"minLength":3,"title":"Public Name","description":"Public URL-safe slug for the listing (e.g., 'video-search'). Used in public URL: mxp.co/m/{public_name}. Must be globally unique.","examples":["brand-safety-api","video-search","product-catalog"]},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category","description":"Catalog category. One of: Brand Safety, Advertising, Media, Faces & People, Art & Archives, Personalization, Content Safety, Spatial, Ecommerce. Writes also accept the slug form (e.g., 'faces-and-people') and store the label.","examples":["Brand Safety","Media"]},"groups":{"items":{"type":"string"},"type":"array","title":"Groups","description":"Curated groups this listing belongs to, as lowercase slugs (e.g., 'ip-screening'). Filter the catalog by one with ?group=.","examples":[["ip-screening"],["media-archives"]]},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Tags for discovery"},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url","description":"URL to listing logo/icon"},"app_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"App Url","description":"Optional URL to a live canvas app powered by this retriever (e.g., 'https://nga.mxp.co'). When set, the listing appears in the public showcase at mixpeek.com/showcase.","examples":["https://nga.mxp.co","https://mxp.co/r/superbowl"]},"icon_base64":{"anyOf":[{"type":"string","maxLength":300000},{"type":"null"}],"title":"Icon Base64","description":"Base64 encoded icon/favicon (data URI format). Max size: ~200KB encoded. Use for small icons.","examples":["data:image/png;base64,iVBORw0KGgoAAAANS..."]},"available_tiers":{"items":{"$ref":"#/components/schemas/SubscriptionTierConfig"},"type":"array","title":"Available Tiers","description":"Available subscription tiers (must include at least one tier, typically FREE for public listings)"},"display_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Display Config","description":"JSON-based UI configuration for the public interface. Follows a component-based schema (inspired by json-render): { 'components': [...], 'theme': {...}, 'layout': {...} }. If not provided, a default UI is generated from retriever input_schema.","examples":[{"components":[{"props":{"field":"video_url","label":"Enter video URL"},"type":"SearchInput"},{"props":{"fields":["title","description","score"],"layout":"grid"},"type":"ResultCard"}],"theme":{"fontFamily":"Inter, sans-serif","primaryColor":"#007AFF"}}]},"status":{"$ref":"#/components/schemas/ListingStatus","description":"Publication status","default":"draft"},"visibility":{"$ref":"#/components/schemas/ListingVisibility","description":"Visibility level. 'listed' = shown in marketplace catalog & homepage showcase. 'unlisted' = accessible via direct link only (not in catalog).","default":"unlisted"},"is_active":{"type":"boolean","title":"Is Active","description":"DEPRECATED: Use 'status' field instead. Computed from status (True if PUBLISHED, False otherwise).","default":true,"deprecated":true},"featured_rank":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Featured Rank","description":"Editorial ordering for the catalog. Lower sorts first (1 = top slot). Listings without a rank fall back to subscriber-count ordering and always sort after ranked ones. This is the single source of truth for catalog order — the homepage showcase, the homepage landing-page showcase strip, and the Studio marketplace all read it, so ordering never has to be hardcoded per-surface.","examples":[1,2,3]},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"When the listing was created"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"When the listing was last updated"},"published_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Published At","description":"When the listing was first published"},"total_subscribers":{"type":"integer","title":"Total Subscribers","description":"Total number of active subscribers","default":0},"total_queries":{"type":"integer","title":"Total Queries","description":"Total queries executed across all subscribers","default":0},"input_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Input Schema","description":"JSON Schema for the `inputs` object of POST /v1/marketplace/catalog/{public_name}/execute. File inputs (image, video, audio, pdf) take a public http(s) URL. `x-mixpeek-type` on each property is the Mixpeek input type. Null when the retriever declares no inputs."},"example_request":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Example Request","description":"A complete request body for the execute endpoint, built from the listing's own examples. Null when a required input has no example."},"anonymous_rate_limit":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Anonymous Rate Limit","description":"The limit a call without an API key runs under: `requests` per `period_seconds`, counted per IP address per listing. Null when the listing needs an access token."}},"type":"object","required":["namespace_id","retriever_id","title","description","public_name","available_tiers"],"title":"MarketplaceListingDetail","description":"A catalog listing plus the contract a caller needs to execute it."},"MeKeyInfo":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"The key's human-assigned name."},"key_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Key Type","description":"Key type (e.g. SECRET, SESSION, PUBLIC)."},"permissions":{"items":{"type":"string"},"type":"array","title":"Permissions","description":"Permissions granted to this key (READ/WRITE/DELETE/ADMIN)."},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At","description":"Key expiry, if the key expires."}},"type":"object","title":"MeKeyInfo","description":"Metadata of the API key that made this request. No key material."},"MeResponse":{"properties":{"organization_id":{"type":"string","title":"Organization Id","description":"User-facing organization id (safe to log)."},"organization_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Name","description":"The organization's display name."},"account_type":{"type":"string","title":"Account Type","description":"Account tier (e.g. FREE, BUILD, SCALE)."},"user_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Email","description":"Email of the user owning the API key."},"key":{"$ref":"#/components/schemas/MeKeyInfo","description":"The requesting key's metadata."},"rate_limits":{"additionalProperties":{"type":"integer"},"type":"object","title":"Rate Limits","description":"Effective per-minute rate limits by category (metadata/data/search/upload/compute) for this organization."},"principal_scoped":{"type":"boolean","title":"Principal Scoped","description":"True when this key is end-user scoped (document ACL filtering applies to reads).","default":false}},"type":"object","required":["organization_id","account_type","key"],"title":"MeResponse","description":"Who am I? — the identity of the caller, discoverable with any valid key.\n\nExists because tier/identity were previously discoverable only via\n/v1/organizations (its own permission surface, and more than identity):\nevery agent/SDK session burned calls rediscovering who it was.","examples":[{"account_type":"BUILD","key":{"key_type":"SECRET","name":"backend-service","permissions":["READ","WRITE"]},"organization_id":"org_demo123","organization_name":"Acme Corporation","principal_scoped":false,"rate_limits":{"compute":15,"data":120,"metadata":120,"search":300,"upload":30},"user_email":"alice@example.com"}]},"MeanShiftParams":{"properties":{"bandwidth":{"anyOf":[{"type":"number","exclusiveMinimum":0.0},{"type":"null"}],"title":"Bandwidth","description":"Bandwidth used in the RBF kernel. If None, estimated using sklearn.cluster.estimate_bandwidth"},"bandwidth_quantile":{"type":"number","maximum":1.0,"exclusiveMinimum":0.0,"title":"Bandwidth Quantile","description":"Quantile of pairwise distances used to estimate bandwidth when bandwidth is None. sklearn's own default of 0.3 merges every cluster into one on embedding data: with k equally sized clusters only 1/k of pairs are within-cluster, so a quantile above 1/k measures the distance BETWEEN clusters. 0.1 suits up to roughly ten clusters; lower it if you expect more.","default":0.1},"seeds":{"anyOf":[{"items":{"items":{"type":"number"},"type":"array"},"type":"array"},{"type":"null"}],"title":"Seeds","description":"Seeds used to initialize kernels. If None, all points are used as seeds"},"bin_seeding":{"type":"boolean","title":"Bin Seeding","description":"If true, initial kernel locations are discretized into a grid to speed up algorithm","default":false},"min_bin_freq":{"type":"integer","minimum":1.0,"title":"Min Bin Freq","description":"Minimum number of seeds within a bin for the bin to be considered","default":1},"cluster_all":{"type":"boolean","title":"Cluster All","description":"If true, all points are clustered, even orphans. If false, orphans are given label -1","default":true},"n_jobs":{"type":"integer","title":"N Jobs","description":"Number of parallel jobs to run (-1 means using all processors)","default":1},"max_iter":{"type":"integer","minimum":1.0,"title":"Max Iter","description":"Maximum number of iterations per seed point before the algorithm stops","default":300}},"type":"object","title":"MeanShiftParams","description":"Parameters for Mean Shift clustering algorithm."},"MessageHistoryItem":{"properties":{"message_id":{"type":"string","title":"Message Id","description":"Message identifier"},"role":{"type":"string","title":"Role","description":"Message role"},"content":{"type":"string","title":"Content","description":"Message content"},"content_type":{"type":"string","title":"Content Type","description":"Content type"},"tool_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tool Name","description":"Tool name (if tool message)"},"tool_inputs":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tool Inputs","description":"Tool inputs (if tool call)"},"tool_outputs":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tool Outputs","description":"Tool outputs (if tool result)"},"tool_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tool Status","description":"Tool status (if tool message)"},"timestamp":{"type":"string","format":"date-time","title":"Timestamp","description":"Message timestamp"}},"type":"object","required":["message_id","role","content","content_type","timestamp"],"title":"MessageHistoryItem","description":"Single message in conversation history.\n\nAttributes:\n    message_id: Message identifier\n    role: Message role (user, assistant, tool)\n    content: Message text content\n    content_type: Content type (text, tool_call, tool_result)\n    tool_name: Tool name (if tool message)\n    tool_inputs: Tool inputs (if tool call)\n    tool_outputs: Tool outputs (if tool result)\n    tool_status: Tool execution status (if tool message)\n    timestamp: Message timestamp"},"MessageResponse":{"properties":{"message_id":{"type":"string","title":"Message Id"},"ticket_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ticket Id"},"organization_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Id"},"author_type":{"$ref":"#/components/schemas/SupportAuthorType"},"author":{"anyOf":[{"$ref":"#/components/schemas/SupportActor"},{"type":"null"}]},"body":{"type":"string","title":"Body"},"attachments":{"items":{"$ref":"#/components/schemas/SupportAttachment"},"type":"array","title":"Attachments"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["message_id","author_type","body"],"title":"MessageResponse"},"MetadataFilter":{"properties":{"field":{"type":"string","title":"Field"},"operator":{"type":"string","enum":["equals","not_equals","contains","not_contains","gt","lt","gte","lte","exists"],"title":"Operator","default":"contains"},"value":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Value"}},"type":"object","required":["field"],"title":"MetadataFilter","description":"Filter on a provider-specific metadata field."},"MigrationConfig":{"properties":{"migration_type":{"$ref":"#/components/schemas/MigrationType","description":"Type of migration to perform"},"source_namespace_id":{"type":"string","title":"Source Namespace Id","description":"Source namespace ID"},"target_namespace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Namespace Id","description":"Target namespace ID (auto-generated if not provided)"},"target_namespace_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Namespace Name","description":"Name for target namespace"},"feature_extractors":{"anyOf":[{"items":{"$ref":"#/components/schemas/shared__namespaces__migrations__models__FeatureExtractorConfig"},"type":"array"},{"type":"null"}],"title":"Feature Extractors","description":"New extractors to use (RE_EXTRACT only)"},"filters":{"anyOf":[{"$ref":"#/components/schemas/ResourceFilter"},{"type":"null"}],"description":"Resource selection filters"},"batch_options":{"anyOf":[{"$ref":"#/components/schemas/BatchOptions"},{"type":"null"}],"description":"Batch processing options"},"taxonomy_options":{"anyOf":[{"$ref":"#/components/schemas/TaxonomyOptions"},{"type":"null"}],"description":"Taxonomy migration options"},"cluster_options":{"anyOf":[{"$ref":"#/components/schemas/ClusterOptions"},{"type":"null"}],"description":"Cluster migration options"},"retriever_options":{"anyOf":[{"$ref":"#/components/schemas/RetrieverOptions"},{"type":"null"}],"description":"Retriever migration options"},"preserve_resource_ids":{"type":"boolean","title":"Preserve Resource Ids","description":"Preserve original resource IDs in target","default":false},"dry_run":{"type":"boolean","title":"Dry Run","description":"Validate only, don't execute","default":false},"webhook_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Webhook Url","description":"Webhook URL for status notifications"}},"type":"object","required":["migration_type","source_namespace_id"],"title":"MigrationConfig","description":"Configuration for a namespace migration."},"MigrationProgress":{"properties":{"overall_status":{"$ref":"#/components/schemas/MigrationStatus","description":"Overall migration status"},"overall_progress_percent":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Overall Progress Percent","description":"Overall progress %","default":0.0},"current_stage":{"anyOf":[{"$ref":"#/components/schemas/MigrationStage"},{"type":"null"}],"description":"Currently executing stage"},"stages":{"items":{"$ref":"#/components/schemas/StageProgress"},"type":"array","title":"Stages","description":"Progress for each stage"},"resources":{"items":{"$ref":"#/components/schemas/ResourceProgress"},"type":"array","title":"Resources","description":"Progress for each resource"},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At","description":"Migration start time"},"estimated_completion":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Estimated Completion","description":"Estimated completion time"}},"type":"object","required":["overall_status"],"title":"MigrationProgress","description":"Overall progress tracking for a migration."},"MigrationStage":{"type":"string","enum":["namespace_setup","batch_creation","batch_processing","cluster_execution","taxonomy_enrichment","benchmark_evaluation","finalization"],"title":"MigrationStage","description":"Stages of migration execution."},"MigrationStatus":{"type":"string","enum":["draft","validating","pending","in_progress","completed","failed","cancelled"],"title":"MigrationStatus","description":"Migration execution status."},"MigrationType":{"type":"string","enum":["re_extract","copy","extend"],"title":"MigrationType","description":"Types of namespace migrations."},"ModelCatalogIndexEntry":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"task":{"type":"string","title":"Task"},"modalities_in":{"items":{"type":"string"},"type":"array","title":"Modalities In"},"modalities_out":{"items":{"type":"string"},"type":"array","title":"Modalities Out"},"status":{"type":"string","title":"Status"},"use_cases":{"items":{"type":"string"},"type":"array","title":"Use Cases"},"refs":{"items":{"type":"string"},"type":"array","title":"Refs"},"templates":{"items":{"type":"string"},"type":"array","title":"Templates"},"commercial_use":{"type":"boolean","title":"Commercial Use"},"rank_score":{"type":"number","title":"Rank Score"}},"type":"object","required":["id","name","task","modalities_in","modalities_out","status","commercial_use","rank_score"],"title":"ModelCatalogIndexEntry","description":"One line of the compact model index carried by GET /v1/discovery."},"ModelCatalogListResponse":{"properties":{"total":{"type":"integer","title":"Total","description":"Records that match the filters"},"count":{"type":"integer","title":"Count","description":"Records in this page"},"offset":{"type":"integer","title":"Offset","description":"Index of the first record in this page"},"limit":{"type":"integer","title":"Limit","description":"Page size requested"},"sort":{"type":"string","title":"Sort","description":"Sort key applied"},"order":{"type":"string","title":"Order","description":"asc or desc"},"view":{"type":"string","title":"View","description":"full (whole records) or compact (index lines)"},"facets":{"additionalProperties":{"additionalProperties":{"type":"integer"},"type":"object"},"type":"object","title":"Facets","description":"Counts per value over the matching records, for each filterable field: status, category, modalities_in, modalities_out, license, commercial_use, use_cases, gpu and templates"},"models":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Models","description":"Model records: identity, task, input and output schema, how the model is wired into extractors and retriever stages, how it runs (status, weights, scale to zero), cost, evaluation evidence, references (hf://, mixpeek://, github://, api://, url://), the templates that use it, usage, rank and flat facets"},"rank_formula":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rank Formula","description":"How rank_score is computed"}},"type":"object","required":["total","count","offset","limit","sort","order","view"],"title":"ModelCatalogListResponse","description":"A filtered, sorted page of the model catalog."},"ModelDeleteResponse":{"properties":{"success":{"type":"boolean","title":"Success","default":true},"model_id":{"type":"string","title":"Model Id"},"message":{"type":"string","title":"Message"}},"type":"object","required":["model_id","message"],"title":"ModelDeleteResponse","description":"Response model for model deletion."},"ModelDependency":{"properties":{"name":{"type":"string","title":"Name","description":"Model name or identifier"},"source":{"type":"string","title":"Source","description":"Where model comes from: 'builtin' (platform service), 'bundled' (in archive), 'org_model' (separate upload)","default":"builtin"},"format":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Format","description":"Model format (safetensors, onnx, pytorch, huggingface)"},"required":{"type":"boolean","title":"Required","description":"Whether this dependency is required","default":true}},"type":"object","required":["name"],"title":"ModelDependency"},"ModelDeployResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether deployment succeeded"},"model_id":{"type":"string","title":"Model Id","description":"Model identifier"},"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace ID"},"deployment_status":{"type":"string","title":"Deployment Status","description":"Deployment status (deployed, failed)"},"cached":{"type":"boolean","title":"Cached","description":"Whether model is cached in object store","default":false},"message":{"type":"string","title":"Message","description":"Status message"}},"type":"object","required":["success","model_id","namespace_id","deployment_status","message"],"title":"ModelDeployResponse","description":"Response model for model deployment.\n\nDeploying a model pre-loads the weights into the Ray object store,\nmaking them available for zero-copy access by plugins."},"ModelDeploymentInfo":{"properties":{"ray_cluster_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ray Cluster Url","description":"Ray cluster URL where model is deployed"},"ray_deployment_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ray Deployment Name","description":"Ray deployment name"},"endpoint":{"type":"string","title":"Endpoint","description":"HTTP endpoint for model inference"},"base_image":{"type":"string","title":"Base Image","description":"Docker image used for deployment"},"deployed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Deployed At","description":"When the model was deployed"}},"type":"object","required":["endpoint","base_image"],"title":"ModelDeploymentInfo","description":"Deployment information for a model."},"ModelDetailResponse":{"properties":{"success":{"type":"boolean","title":"Success","default":true},"model":{"$ref":"#/components/schemas/CustomModelDocument"}},"type":"object","required":["model"],"title":"ModelDetailResponse","description":"Response model for model details."},"ModelListItem":{"properties":{"model_id":{"type":"string","title":"Model Id"},"name":{"type":"string","title":"Name"},"version":{"type":"string","title":"Version"},"model_format":{"type":"string","title":"Model Format"},"source":{"type":"string","enum":["customer","mixpeek","system"],"title":"Source","default":"customer"},"framework":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Framework"},"task_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Type"},"deployed":{"type":"boolean","title":"Deployed"},"endpoint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Endpoint"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["model_id","name","version","model_format","deployed","created_at","updated_at"],"title":"ModelListItem","description":"Model item in list response."},"ModelListResponse":{"properties":{"success":{"type":"boolean","title":"Success","default":true},"models":{"items":{"$ref":"#/components/schemas/ModelListItem"},"type":"array","title":"Models"},"total":{"type":"integer","title":"Total"},"namespace_id":{"type":"string","title":"Namespace Id"}},"type":"object","required":["models","total","namespace_id"],"title":"ModelListResponse","description":"Response model for listing models."},"ModelPresignedURLResponse":{"properties":{"upload_id":{"type":"string","title":"Upload Id","description":"Upload ID to use when confirming"},"presigned_url":{"type":"string","title":"Presigned Url","description":"S3 presigned URL for PUT upload"},"required_content_type":{"type":"string","title":"Required Content Type","description":"Content-Type the presigned PUT is signed with. Send this exact value as the Content-Type header on the upload PUT, or object storage rejects it with 403 SignatureDoesNotMatch. Parity with the extractor upload.","default":"application/gzip"},"s3_key":{"type":"string","title":"S3 Key","description":"S3 object key where file will be stored"},"expires_at":{"type":"string","format":"date-time","title":"Expires At","description":"When the presigned URL expires"},"organization_id":{"type":"string","title":"Organization Id","description":"Organization ID"},"name":{"type":"string","title":"Name","description":"Model name"},"version":{"type":"string","title":"Version","description":"Model version"},"model_format":{"type":"string","enum":["safetensors","onnx","pytorch","huggingface"],"title":"Model Format","description":"Model format"}},"type":"object","required":["upload_id","presigned_url","s3_key","expires_at","organization_id","name","version","model_format"],"title":"ModelPresignedURLResponse","description":"Response containing presigned URL for model upload.\n\nAfter receiving this response:\n1. PUT the model archive to `presigned_url` with the `required_content_type`\n   header (the value the URL is signed with)\n2. Call POST /models/uploads/{upload_id}/confirm to finalize"},"ModelRegistryIdentity":{"properties":{"registry_id":{"type":"string","title":"Registry Id","description":"Org-scoped registry key: org:<organization_id>:<model_id>."},"shared_model_key":{"type":"string","title":"Shared Model Key","description":"The key Serve deployments share the weights under: the model_id."},"inference_service_id":{"type":"string","title":"Inference Service Id","description":"The inference service and deployment name derived from registry_id."}},"type":"object","required":["registry_id","shared_model_key","inference_service_id"],"title":"ModelRegistryIdentity","description":"The ids a model's registry entry derives from its ``model_id`` (plan 11.2).\n\nComputed on every read from the upload's id, so a model uploaded before these\nfields existed carries them too and nothing is stored twice."},"ModelResourceRequirements":{"properties":{"num_cpus":{"type":"number","maximum":64.0,"minimum":0.1,"title":"Num Cpus","description":"Number of CPUs","default":1.0},"num_gpus":{"type":"integer","maximum":8.0,"minimum":0.0,"title":"Num Gpus","description":"Number of GPUs","default":0},"memory":{"type":"integer","title":"Memory","description":"Memory in bytes (default 4GB)","default":4294967296}},"type":"object","title":"ModelResourceRequirements","description":"Resource requirements for model deployment."},"ModelTieringView":{"properties":{"tier":{"type":"string","enum":["warm","cold","frozen"],"title":"Tier","description":"The ladder rung the weights archive is on: warm, cold or frozen.","default":"warm"},"storage_tier":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Storage Tier","description":"The storage tier the weights archive is held in: standard, nearline or coldline. It stays standard on a store without colder classes, where the tier is recorded and the archive is not moved."},"tier_changed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Tier Changed At","description":"When the archive last moved to this tier."},"retrieval_usd_per_gb":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Retrieval Usd Per Gb","description":"The storage class's retrieval fee per GiB read, charged when the model wakes from this tier."},"archive_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Archive Bytes","description":"The weights archive's size, recorded at registration."},"wake_retrieval_usd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Wake Retrieval Usd","description":"The retrieval fee for one wake from this tier: the fee per GiB times the archive size. Null when the size is not recorded."},"declared_wake_seconds":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Declared Wake Seconds","description":"The declared wake time for this tier: how long a call may take to start answering."},"exempt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Exempt","description":"Why this model never demotes, when it is exempt."}},"type":"object","title":"ModelTieringView","description":"Where a model's weights sit on the tiering ladder and what waking it costs (plan 7.10)."},"ModelUploadResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether upload succeeded"},"model_id":{"type":"string","title":"Model Id","description":"Unique model identifier"},"deployment_status":{"type":"string","enum":["deployed","pending","failed","not_deployed"],"title":"Deployment Status","description":"Deployment status"},"endpoint":{"type":"string","title":"Endpoint","description":"Model inference endpoint"},"model_archive_url":{"type":"string","title":"Model Archive Url","description":"S3 URL where archive is stored"}},"type":"object","required":["success","model_id","deployment_status","endpoint","model_archive_url"],"title":"ModelUploadResponse","description":"Response model for model upload."},"MongoFrontier":{"properties":{"read_concern":{"type":"string","title":"Read Concern","description":"Read concern the cluster time was read under","default":"snapshot"},"cluster_time_start":{"anyOf":[{"$ref":"#/components/schemas/ClusterTime"},{"type":"null"}],"description":"Cluster time read before the collection dumps began"},"cluster_time_end":{"anyOf":[{"$ref":"#/components/schemas/ClusterTime"},{"type":"null"}],"description":"Cluster time read after the collection dumps finished"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Why a cluster time could not be read, when it could not"}},"type":"object","title":"MongoFrontier"},"MonitoringConfig":{"properties":{"enabled":{"type":"boolean","title":"Enabled","description":"Master switch — must be true for any monitoring to activate","default":true},"error_boundary_enabled":{"type":"boolean","title":"Error Boundary Enabled","description":"Wrap app in a React Error Boundary that shows a fallback UI on crash. Client-side only — no data is sent externally. Enabled by default.","default":true},"sentry_enabled":{"type":"boolean","title":"Sentry Enabled","description":"Capture unhandled exceptions to Mixpeek-internal Sentry. No PII is captured (beforeSend strips it).","default":true},"posthog_enabled":{"type":"boolean","title":"Posthog Enabled","description":"Capture pageviews and error counts to Mixpeek-internal PostHog. No text content, no session recordings.","default":true},"custom_error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Error Message","description":"Custom message shown in the Error Boundary fallback UI"},"auto_fix_enabled":{"type":"boolean","title":"Auto Fix Enabled","description":"When true, error spikes trigger the Claude-powered auto-fix pipeline. Requires source_files on the latest version or a connected GitHub repo.","default":true}},"type":"object","title":"MonitoringConfig","description":"Opt-in monitoring configuration for a Canvas app.\n\nAll monitoring is off by default except ``error_boundary_enabled``, which\nis a client-side UX safety net (shows fallback UI instead of blank page)\nand sends no data externally.\n\nWhen ``sentry_enabled`` or ``posthog_enabled`` are turned on, monitoring\ndata is sent to **Mixpeek-internal** Sentry/PostHog — never to the\ncustomer's own observability stack. PII is stripped via ``beforeSend`` /\n``mask_all_text``, and session replay is always off."},"MostQueriedFieldsResponse":{"properties":{"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace ID analyzed"},"time_range_days":{"type":"integer","title":"Time Range Days","description":"Number of days analyzed"},"fields":{"items":{"$ref":"#/components/schemas/FieldQueryMetrics"},"type":"array","title":"Fields","description":"Most queried fields"},"total_fields":{"type":"integer","title":"Total Fields","description":"Total unique fields found"}},"type":"object","required":["namespace_id","time_range_days","fields","total_fields"],"title":"MostQueriedFieldsResponse","description":"Response for most queried fields endpoint."},"MultiDenseVector":{"properties":{},"additionalProperties":true,"type":"object","title":"MultiDenseVector","description":"Multi-dimensional dense vector representation with flexible key naming.\n\nAccepts a single key-value pair where the key can be any string\nand the value must be a list of lists of floats.\nUseful for late interaction models and other multi-dimensional embeddings.\n\nExample:\n```json\n{\n    \"embeddings\": [\n        [0.1, 0.2, 0.3],\n        [0.4, 0.5, 0.6],\n        [0.7, 0.8, 0.9]\n    ]\n}\n```\nor\n```json\n{\n    \"multi_vectors\": [\n        [0.1, 0.2, 0.3],\n        [0.4, 0.5, 0.6],\n        [0.7, 0.8, 0.9]\n    ]\n}\n```"},"MultiVectorIndex":{"properties":{"name":{"type":"string","minLength":1,"title":"Name","description":"REQUIRED. Fully-qualified name for the multi-vector index. Format: {extractor}_{version}_{output} (e.g., 'hybrid_extractor_v1_multi'). Must be unique across namespace.","examples":["hybrid_extractor_v1_multi","ensemble_v1_combined"]},"description":{"type":"string","minLength":10,"title":"Description","description":"REQUIRED. Human-readable description of the multi-vector index. Explain what vector types are included and their purposes. Describe use cases for this multi-vector configuration.","examples":["Hybrid dense + sparse embeddings for enhanced retrieval","Multi-model ensemble with BERT + RoBERTa embeddings"]},"vectors":{"additionalProperties":{"$ref":"#/components/schemas/VectorIndex"},"type":"object","title":"Vectors","description":"REQUIRED. Dictionary mapping vector output names to their VectorIndex configurations. Each key is a unique identifier for that vector type within this multi-index. Each value is a complete VectorIndex with its own dimensions, type, and inference service. Example keys: 'dense', 'sparse', 'primary', 'secondary'.","examples":[{"dense":{"dimensions":1024,"inference_name":"e5_large","name":"hybrid_v1_dense","type":"dense"},"sparse":{"inference_name":"splade","name":"hybrid_v1_sparse","type":"sparse"}}]}},"type":"object","required":["name","description","vectors"],"title":"MultiVectorIndex","description":"Configuration for multi-vector indexes.\n\nAllows a single extractor to produce multiple named vector outputs in one index.\nUseful for hybrid search combining different embedding types or multiple models.\n\nUse Cases:\n    - Hybrid dense + sparse embeddings in one index\n    - Multiple models for ensemble retrieval\n    - Different granularities (sentence + paragraph embeddings)\n\nRequirements:\n    - name: REQUIRED - Full qualified name for the multi-vector index\n    - description: REQUIRED - Explain what vector combinations are included\n    - vectors: REQUIRED - Dictionary mapping output names to VectorIndex configs\n\nNote: Currently less common than single VectorIndex. Most extractors use\nseparate VectorIndexDefinitions for each output instead.","examples":[{"description":"Combined dense and sparse embeddings for hybrid search. Dense provides semantic understanding, sparse adds keyword precision.","name":"hybrid_extractor_v1_multi","vectors":{"dense":{"datatype":"float32","description":"Dense semantic embedding","dimensions":1024,"distance":"cosine","inference_name":"multilingual_e5_large_instruct_v1","name":"hybrid_v1_dense","type":"dense"},"sparse":{"datatype":"float32","description":"Sparse keyword embedding","distance":"dot","inference_name":"splade_plus_plus_v1","name":"hybrid_v1_sparse","type":"sparse"}}}]},"MultimodalExtractorParams":{"properties":{"extractor_type":{"type":"string","const":"multimodal_extractor","title":"Extractor Type","description":"Discriminator field. Must be 'multimodal_extractor'.","default":"multimodal_extractor"},"split_method":{"$ref":"#/components/schemas/SplitMethod","description":"Video splitting strategy.","default":"time"},"description_prompt":{"type":"string","title":"Description Prompt","description":"Prompt for description generation.","default":"Watch this video segment carefully and describe exactly what you see. Do not make up or infer details that are not visible in the footage. Include: who is shown (gender, appearance, actions), what they are doing, the setting/location, and any products, text, or branding visible on screen."},"time_split_interval":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Time Split Interval","description":"Interval in seconds for 'time' splitting.","default":10},"silence_db_threshold":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Silence Db Threshold","description":"Decibel threshold for silence detection. Recommended: -40."},"scene_detection_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Scene Detection Threshold","description":"Scene detection threshold (0.0-1.0). Recommended: 0.5."},"run_transcription":{"type":"boolean","title":"Run Transcription","description":"Run Whisper transcription on segments.","default":false},"transcription_language":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Transcription Language","description":"ISO-639-1 code that forces the transcription language, e.g. `ru`, `fa`, `zh`. Leave unset to detect the language per segment, which is the right choice for a mixed-language corpus."},"run_video_description":{"type":"boolean","title":"Run Video Description","description":"Generate Gemini descriptions for segments.","default":false},"run_transcription_embedding":{"type":"boolean","title":"Run Transcription Embedding","description":"Generate E5 embeddings for transcriptions (1024D).","default":false},"run_ocr_embedding":{"type":"boolean","title":"Run Ocr Embedding","description":"Generate E5 embeddings for OCR text (1024D). Requires run_ocr.","default":false},"run_description_embedding":{"type":"boolean","title":"Run Description Embedding","description":"Generate E5 embeddings for descriptions (1024D). Requires run_video_description.","default":false},"run_multimodal_embedding":{"type":"boolean","title":"Run Multimodal Embedding","description":"Generate Gemini Embedding 2 multimodal embeddings (3072D). Creates unified embeddings across video, image, text, audio, and GIF content.","default":true},"run_ocr":{"type":"boolean","title":"Run Ocr","description":"Extract text from video frames via Gemini OCR.","default":false},"max_segment_duration":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Max Segment Duration","description":"Maximum duration in seconds for any single segment. Scene/silence segments longer than this are subdivided. Set to None to disable. Default: 30s.","default":30.0},"sensitivity":{"type":"string","title":"Sensitivity","description":"Scene detection sensitivity.","default":"low"},"enable_thumbnails":{"type":"boolean","title":"Enable Thumbnails","description":"Generate thumbnail images for segments.","default":true},"use_cdn":{"type":"boolean","title":"Use Cdn","description":"Use CloudFront CDN for thumbnail delivery.","default":false},"generation_config":{"$ref":"#/components/schemas/GenerationConfig"},"output_dimensionality":{"type":"integer","title":"Output Dimensionality","description":"Output embedding dimensions. Gemini Embedding 2 supports Matryoshka dimension reduction: 3072 (full), 1536, or 768.","default":3072},"task_type":{"type":"string","title":"Task Type","description":"Embedding task type hint. Options: RETRIEVAL_DOCUMENT, RETRIEVAL_QUERY, SEMANTIC_SIMILARITY, CLASSIFICATION.","default":"RETRIEVAL_DOCUMENT"},"response_shape":{"anyOf":[{"type":"string"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Response Shape","description":"Custom structured output schema for Gemini extraction. String for natural language prompt, dict for explicit JSON schema."},"embedding_task":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Embedding Task","description":"Embedding task hint for instruction-aware models (E5). Prefer setting this at collection level (embedding_task on the collection) rather than here. Collection-level overrides this value. Defaults to 'retrieval_document'. Values: retrieval_document, retrieval_query, semantic_similarity, classification, clustering. Note: Vertex AI multimodal embeddings ignore this — only E5 transcription embeddings use it."}},"type":"object","title":"MultimodalExtractorParams","description":"Parameters for multimodal extractor v2.\n\nSame pipeline as v1 but uses Gemini Embedding 2 (3072D) for the\nmultimodal embedding step. Supports configurable output dimensions\nvia Matryoshka representation learning (3072/1536/768)."},"MuxConfig":{"properties":{"provider_type":{"type":"string","const":"mux","title":"Provider Type","default":"mux"},"credentials":{"$ref":"#/components/schemas/MuxCredentials","description":"REQUIRED. Mux access token credentials."}},"type":"object","required":["credentials"],"title":"MuxConfig","description":"Mux video infrastructure platform configuration.\n\nMux is a video API platform that provides video hosting, encoding,\nand streaming. This provider syncs video assets from a Mux account\ninto Mixpeek for processing and analysis.\n\nAuthentication:\n    - Access token ID + secret from Mux dashboard (HTTP Basic Auth)\n\nRequirements:\n    - Active Mux account with video assets\n    - Access token with Mux Video read permissions\n    - Assets must have playback IDs for download\n\nUse Cases:\n    - Video library ingestion and analysis\n    - Media asset processing pipelines\n    - Content moderation and classification\n    - Video search and discovery","examples":[{"credentials":{"access_token_id":"abc123def456","access_token_secret":"xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx","type":"access_token"},"description":"Mux video sync","provider_type":"mux"}]},"MuxCredentials":{"properties":{"type":{"type":"string","const":"access_token","title":"Type","default":"access_token"},"access_token_id":{"type":"string","title":"Access Token Id","description":"REQUIRED. Mux access token ID. Found in: Mux Dashboard > Settings > Access Tokens.","examples":["abc123def456"]},"access_token_secret":{"type":"string","title":"Access Token Secret","description":"REQUIRED. Mux access token secret. SECURITY: Encrypted at rest. Shown only once when created. Found in: Mux Dashboard > Settings > Access Tokens — copy immediately on creation.","examples":["xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"]},"webhook_secret":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Webhook Secret","description":"NOT REQUIRED. Mux webhook signing secret for verifying inbound webhook events (e.g. video.asset.deleted, which cascades deletes to Mixpeek bucket objects synced from this connection). Set this to enable cascade deletion when assets are removed from Mux. SECURITY: Encrypted at rest. Find in: Mux Dashboard > Settings > Webhooks > {webhook} > Signing Secret. After saving, register the URL https://api.mixpeek.com/v1/webhooks/mux/{connection_id} in your Mux dashboard."}},"type":"object","required":["access_token_id","access_token_secret"],"title":"MuxCredentials","description":"Access token credentials for Mux video infrastructure platform.\n\nSecurity:\n    - access_token_secret is a secret credential, redacted on read\n    - Tokens can be created/rotated in the Mux dashboard"},"NamedDenseVectors":{"additionalProperties":{"items":{"type":"number"},"type":"array"},"type":"object","title":"NamedDenseVectors","description":"Root model mapping vector names → dense float lists.\n\nAccepts JSON like:\n```json\n{\n    \"vector_a\": [0.1, 0.2, 0.3],\n    \"vector_b\": [0.4, 0.5, 0.6]\n}\n```"},"NamespaceAdminClaim":{"properties":{"claim":{"type":"string","minLength":1,"title":"Claim","description":"Dotted path of the claim in the verified token, e.g. 'app_metadata.internal' or 'app_metadata.roles'.","examples":["app_metadata.internal"]},"values":{"items":{"type":"string"},"type":"array","minItems":1,"title":"Values","description":"Claim values that mark an admin (booleans compare as 'true' and 'false'). A token whose claim holds one of them is not held to claim_filters: it reads and writes across every value of the namespace. Document ACLs still apply.","examples":[["true"]]}},"additionalProperties":false,"type":"object","required":["claim","values"],"title":"NamespaceAdminClaim","description":"A claim value that gives an end-user token reach across claim filters."},"NamespaceAuthorizationConfig":{"properties":{"enabled":{"type":"boolean","title":"Enabled","description":"Master switch. False (default) = no authorization enforcement, namespace unchanged. True = document-level authorized retrieval is active for this namespace.","default":false},"provider":{"type":"string","const":"openfga","title":"Provider","description":"External authorization provider. Only OpenFGA is supported.","default":"openfga"},"api_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Api Url","description":"Base URL of the customer's OpenFGA HTTP API.","examples":["https://openfga.customer.example.com","http://localhost:8080"]},"store_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Store Id","description":"OpenFGA store id holding the customer's relationship tuples."},"model_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Model Id","description":"OpenFGA authorization-model id. When None, the store's latest model is used."},"api_token_secret_ref":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Api Token Secret Ref","description":"Name of an organization-vault secret (OrganizationSecretsService) holding the OpenFGA bearer token. PREFERRED: the token is resolved from the encrypted org vault at call time and never stored in this config. Required for any non-local (https) OpenFGA deployment."},"api_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Api Token","description":"DEPRECATED / dev-only plaintext bearer token. Rejected when enabled=True against a non-local OpenFGA URL — use api_token_secret_ref (org vault) instead. Allowed only for local dev (http:// or localhost), where the e2e OpenFGA runs without auth."},"object_type":{"type":"string","title":"Object Type","description":"FGA object type that represents a Mixpeek document.","default":"document"},"relation":{"type":"string","title":"Relation","description":"OpenFGA relation that grants read/retrieve access.","default":"viewer"},"user_type":{"type":"string","title":"User Type","description":"FGA subject type for the acting principal (user:<id>).","default":"user"},"mode":{"type":"string","enum":["push","pull_list_objects","pull_batch_check","auto"],"title":"Mode","description":"push = filter on the synced _acl payload field (fast, eventually consistent). pull_list_objects = ListObjects->document_id pre-filter (strongly consistent, bounded sets). pull_batch_check = unfiltered search then BatchCheck post-filter (strongly consistent, any size). auto = ListObjects when the result is under list_objects_max, else fall back to BatchCheck post-filter.","default":"auto"},"list_objects_max":{"type":"integer","maximum":100000.0,"minimum":1.0,"title":"List Objects Max","description":"Max objects ListObjects may return before auto mode falls back to BatchCheck post-filter (avoids the ListObjects explosion).","default":1000},"over_fetch_factor":{"type":"integer","maximum":10.0,"minimum":1.0,"title":"Over Fetch Factor","description":"Post-filter (BatchCheck) over-fetch multiplier. Standard authorized-search guidance: over-fetch >=2x from the vector DB so that after dropping inaccessible documents the requested page is still full. Only applies in post-filter / auto-capped mode.","default":2},"cache_ttl_seconds":{"type":"integer","maximum":3600.0,"minimum":0.0,"title":"Cache Ttl Seconds","description":"TTL for cached authorization decisions (subject->allowed set).","default":30}},"type":"object","title":"NamespaceAuthorizationConfig","description":"Opt-in external authorization config for document-level\nauthorized retrieval.\n\nWhen ``enabled`` is False (the default) the namespace behaves EXACTLY as\nbefore: no ``_acl`` enforcement at retrieval, no ``_acl`` write at\ningestion, no FGA calls. The whole feature is gated on this flag so a\nnamespace that does not opt in is byte-for-byte unchanged.\n\nThe customer runs their OWN OpenFGA; Mixpeek is a relying party. The\ndocument object id in OpenFGA must equal the Mixpeek ``document_id``\n(e.g. ``document:doc_abc123``). At retrieval we enforce the configured\n``relation`` for the acting subject.\n\nEnforcement is fail-closed: a document with no resolvable grant is\nexcluded, never leaked.","examples":[{"api_token_secret_ref":"openfga_bearer_token","api_url":"https://openfga.customer.example.com","enabled":true,"mode":"auto","object_type":"document","provider":"openfga","relation":"viewer","store_id":"01J0X..."}]},"NamespaceBucketsHealthResponse":{"properties":{"time_range":{"$ref":"#/components/schemas/api__analytics__buckets__models__TimeRange","description":"Query time range"},"buckets":{"items":{"$ref":"#/components/schemas/BucketHealthResponse"},"type":"array","title":"Buckets","description":"Per-bucket health, one entry per bucket with events in the window. Absent bucket == healthy/no activity."}},"type":"object","required":["time_range","buckets"],"title":"NamespaceBucketsHealthResponse","description":"Batch health for all buckets in the namespace (single request).\n\nReplaces the per-bucket GET /{bucket_id}/health fan-out on monitoring\nsurfaces (browser N+1 that scaled with bucket count). Only\nbuckets with events in the window appear — a bucket absent from `buckets`\nhad no errors and no sync activity and should render as healthy."},"NamespaceClaimFilter":{"properties":{"claim":{"type":"string","minLength":1,"title":"Claim","description":"Dotted path of the claim in the verified token, e.g. 'brands' or 'app_metadata.brands'. Its value (a string or a list of strings) is the set of allowed values.","examples":["brands"]},"field":{"type":"string","minLength":1,"title":"Field","description":"Document field the claim values must match, e.g. 'brand_id'. A document is visible only when this field holds one of the values.","examples":["brand_id"]},"collections":{"items":{"type":"string"},"type":"array","title":"Collections","description":"Collections (names or ids) this filter applies to. Empty applies it to every read. A retriever run reading any listed collection is held to it for all its results, and so is a run whose collection is templated. The scope narrows which documents the filter hides, not which calls need the claim: a token without the claim is refused on every call, including writes to collections this filter does not list.","examples":[["scenes"]]}},"type":"object","required":["claim","field"],"title":"NamespaceClaimFilter","description":"One token claim applied as a document filter for end-user tokens."},"NamespaceCostCapOverride":{"properties":{"daily_usd":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Daily Usd","description":"Cap in USD per UTC day of inference cost for this namespace. Required. null removes the cap, which needs Mixpeek support.","examples":[250.0]},"reason":{"type":"string","maxLength":500,"minLength":10,"title":"Reason","description":"Why this namespace needs a cap other than its tier default.","examples":["Nightly re-index of the full catalog, about $180/day, approved by finance"]},"owner":{"type":"string","maxLength":200,"minLength":3,"title":"Owner","description":"Who is accountable for spend in this namespace, for example an email address.","examples":["data-platform@example.com"]},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At","description":"When the override lapses and the tier default applies again. Omit for no expiry."},"set_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Set By","description":"Set by the server: the authenticated user who applied the override."},"set_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Set At","description":"Set by the server: when the override was applied."}},"type":"object","required":["daily_usd","reason","owner"],"title":"NamespaceCostCapOverride","description":"An explicit daily inference cost cap for one namespace.\n\nEvery namespace already has a cap from its organization's tier. An override\nreplaces it and must say why and who is accountable. Setting one above the\ntier's self-serve maximum, or removing the cap with null, needs Mixpeek\nsupport."},"NamespaceErrorsResponse":{"properties":{"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace ID analyzed"},"hours":{"type":"integer","title":"Hours","description":"Hours of history analyzed"},"collections":{"items":{"$ref":"#/components/schemas/ResourceErrorCount"},"type":"array","title":"Collections","description":"Collections with extraction errors (the extraction_events analytics collection)"},"clusters":{"items":{"$ref":"#/components/schemas/ResourceErrorCount"},"type":"array","title":"Clusters","description":"Clusters with execution failures (Mongo clustering_results)"},"total_errors":{"type":"integer","title":"Total Errors","description":"Total errors + failures across all resources in the window"}},"type":"object","required":["namespace_id","hours","total_errors"],"title":"NamespaceErrorsResponse","description":"Per-resource error counts across a namespace in one response.\n\nBatches what used to be one ``/analytics/{collections,clusters}/{id}/failures``\ncall per resource (the Studio Monitoring \"Errors & Health\" N+1) into a single\nnamespace-scoped query pair. Only resources with at least one error/failure in\nthe window are returned, so an empty ``collections``/``clusters`` list means\nthat resource type is healthy for the window."},"NamespaceGroupClaim":{"properties":{"claim":{"type":"string","minLength":1,"title":"Claim","description":"Dotted path of the claim in the verified token, e.g. 'app_metadata.brands'. Each value (a string, number or boolean, or a list of them) becomes the group principal prefix + value.","examples":["app_metadata.brands"]},"prefix":{"type":"string","maxLength":64,"minLength":1,"title":"Prefix","description":"Prefix of the group principals, e.g. 'brand:' gives 'brand:<id>'. A document whose ACL read or write list holds a group principal grants that access to every token holding it.","examples":["brand:"]}},"additionalProperties":false,"type":"object","required":["claim","prefix"],"title":"NamespaceGroupClaim","description":"A token claim whose values become group principals for end-user tokens."},"NamespaceInfrastructure":{"properties":{"ray_cluster_id":{"anyOf":[{"type":"string","pattern":"^ray_[a-zA-Z0-9_]{3,64}$"},{"type":"null"}],"title":"Ray Cluster Id","description":"Dedicated Ray cluster identifier for this namespace.","examples":["ray_shared","ray_prod_gpu_cluster",null]},"ray_dashboard_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ray Dashboard Url","description":"Ray dashboard URL for monitoring (http://host:8265).","examples":["http://ray-dashboard-prod:8265"]},"s3_vector_bucket":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"S3 Vector Bucket","description":"S3 Vectors bucket name for vector tiering. When set, vectors are durably stored in S3."},"max_concurrent_jobs":{"type":"integer","maximum":1000.0,"minimum":1.0,"title":"Max Concurrent Jobs","description":"Maximum concurrent Ray jobs allowed for the namespace.","default":10,"examples":[10,50,20]},"autoscaling_enabled":{"type":"boolean","title":"Autoscaling Enabled","description":"Toggle autoscaling for dedicated clusters (ignored for shared tier).","default":true},"min_workers":{"type":"integer","maximum":100.0,"minimum":0.0,"title":"Min Workers","description":"Lower bound for Ray workers when autoscaling is enabled.","default":1},"max_workers":{"type":"integer","maximum":100.0,"minimum":1.0,"title":"Max Workers","description":"Upper bound for Ray workers when autoscaling is enabled.","default":10},"gpu_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gpu Type","description":"GPU type for dedicated GPU clusters (e.g. A100, T4).","examples":["A100","T4",null]},"gpus_per_worker":{"type":"integer","maximum":8.0,"minimum":0.0,"title":"Gpus Per Worker","description":"Number of GPUs allocated to each Ray worker when using GPUs.","default":1},"compute_profiles":{"additionalProperties":{"additionalProperties":true,"type":"object"},"type":"object","title":"Compute Profiles","description":"Per-extractor compute profile overrides keyed by feature_extractor_id (e.g. 'text_extractor_v1'). Values are partial ComputeProfile dicts merged on top of the extractor's built-in profile at batch build time.","examples":[{"text_extractor_v1":{"batch_size":64,"resource_type":"gpu"}}]},"s3_plugin_bucket":{"type":"string","title":"S3 Plugin Bucket","description":"S3 bucket for storing custom plugins and model weights.","default":"mixpeek-plugins"},"s3_plugin_prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"S3 Plugin Prefix","description":"S3 prefix for namespace-scoped plugin storage. Format: {namespace_id}/ when custom plugins are enabled.","examples":["ns_abc123/"]},"max_custom_plugins":{"type":"integer","maximum":100.0,"minimum":0.0,"title":"Max Custom Plugins","description":"Maximum number of custom plugins allowed for this namespace. 0 = custom plugins disabled (shared tier). Set to >0 for dedicated tiers to enable custom plugins.","default":0},"max_custom_models":{"type":"integer","maximum":50.0,"minimum":0.0,"title":"Max Custom Models","description":"Maximum number of custom model weights allowed for this namespace. 0 = custom models disabled (shared tier). Set to >0 for dedicated tiers to enable custom model uploads.","default":0},"authorization":{"anyOf":[{"$ref":"#/components/schemas/NamespaceAuthorizationConfig"},{"type":"null"}],"description":"Opt-in document-level authorization (external auth provider) for authorized retrieval. None or enabled=False (default) means the namespace is unchanged: no _acl enforcement and no authz calls."}},"type":"object","title":"NamespaceInfrastructure","description":"Infrastructure configuration associated with a namespace.\n\nDefines infrastructure resources for a specific namespace. This configuration\ncan override organization-level defaults, enabling flexible deployment patterns\nwhere different namespaces use different infrastructure.\n\nray_head_node_url and compute_tier were removed (2026-09-10): both were\nwrite-only on this model -- customer-settable via PATCH, published in the\nOpenAPI schema and both SDKs, and read by nothing. Advertising dedicated-Ray\nrouting that does not exist is worse than advertising none, and wiring\nray_head_node_url as a batch target would have let any write-scoped API key\npoint Mixpeek's background workers at a URL the caller controls -- SSRF from the\ncontrol plane, with credentials in what gets sent. ray_dashboard_url stays:\nit is genuinely wired as the namespace-level batch target\n(engine/jobs/services.py:_get_ray_dashboard_url), which is not the same\nsurface and was audited separately.\n\nThe per-namespace vector-store connection fields (the URL, the API key, its\n\"provided\" flag and the required collection name) were removed on\n2026-09-26, when MVS became the only vector store. It addresses a namespace's\nvectors by namespace_id, so nothing read them.\n\nA stored document that still carries a removed key is accepted and\nignored (see the deprecation validator below), never rejected.\n\nExamples:\n    Namespace-level Ray dashboard override:\n        NamespaceInfrastructure(\n            ray_dashboard_url=\"http://ray-ns-dashboard:8265\",\n            max_concurrent_jobs=50\n        )","examples":[{"autoscaling_enabled":false,"description":"Shared development namespace","max_concurrent_jobs":10},{"autoscaling_enabled":true,"description":"Dedicated production CPU cluster","max_concurrent_jobs":50,"max_workers":20,"min_workers":3,"ray_cluster_id":"ray_prod_cluster","ray_dashboard_url":"http://prod-dashboard:8265"}]},"NamespaceListDocumentsRequest":{"properties":{"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"Filters to apply."},"sort":{"anyOf":[{"$ref":"#/components/schemas/SortOption"},{"type":"null"}],"description":"Sort options."},"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search","description":"Search term."},"cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor","description":"OPTIONAL cursor for efficient deep pagination. Pass the 'pagination.next_cursor' value from a previous response to fetch the next page. When cursor is provided, the page/offset query params are ignored. Use cursor-based pagination when: (1) paginating beyond page ~100, (2) sorting large datasets, or (3) you need consistent iteration. Use offset-based pagination (default) for: simple use cases, random page access, or when page numbers are needed in the UI."},"partition":{"anyOf":[{"$ref":"#/components/schemas/ListPartition"},{"type":"null"}],"description":"OPTIONAL. Read one of `count` disjoint partitions of the matching documents, so several workers can page through a large collection in parallel, each with its own cursor and with no offset cap. The documents are split on their document id and every document falls in exactly one partition. Page each partition with its `pagination.next_cursor` until that is null; the cursor carries its partition, so sending the cursor alone stays inside it. Example: four workers send {\"index\": 0, \"count\": 4} through {\"index\": 3, \"count\": 4}. The split points are even over Mixpeek-generated document ids (doc_ followed by hex). Documents written with your own document_id values can all fall in one partition, which can be slower than one sequential listing; to split those, give each worker a range filter on document_id instead.","examples":[{"count":4,"index":0}]},"include_total":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Include Total","description":"Set true to count the documents that match this request. pagination.total and total_documents then hold the number of matching documents across all pages, filters included (0 when nothing matches); without it, or with a warning if the count fails, both are null. Runs a COUNT query that adds about 50-200ms. To get only the count, send limit 1. Accepted in the body or as the ?include_total=true query parameter; the body value wins when both are set."},"return_presigned_urls":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Return Presigned Urls","description":"Whether to return presigned URLs for object keys.","default":false},"return_vectors":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Return Vectors","description":"Whether to return vector embeddings in the document results.","default":false},"return_vector_names":{"anyOf":[{"type":"boolean"},{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Return Vector Names","description":"Controls vector data in the response. Pass `true` to get a `_vectors` field listing available vector names (no embedding data). Pass a list of vector names (e.g. `[\"fashionsiglip_v1_embedding\"]`) to return the actual float arrays for those specific vectors, keyed by name.","default":false},"group_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Group By","description":"OPTIONAL. Field to group documents by. Supports dot notation for nested fields (e.g., 'metadata.category', 'source_type'). Accepts either a bare string (``'metadata.category'``) or an object form (``{'field': 'metadata.category'}``) for consistency with other API parameters. When specified, documents are grouped by the field value and returned as grouped results. Requires a payload index on the field in the vector store for optimal performance. If no index exists, the operation will fail with a validation error. Common groupable fields: 'source_object_id', 'root_object_id', 'collection_id', 'metadata.category'.","examples":["source_object_id","metadata.category","root_object_id","source_type"]},"select":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Select","description":"OPTIONAL. List of fields to include in the response. Supports dot notation for nested fields (e.g., 'metadata.title', 'content'). When specified, only the selected fields will be returned in the document results, reducing response size. System fields like '_id' and 'document_id' are always included. Vectors requested with return_vectors or return_vector_names are returned whether or not select names them, along with '_vectors'. Use this to optimize response size when working with large documents.","examples":[["metadata.title","content"],["document_id","metadata"],["source_type","created_at"]]},"expand":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Expand","description":"OPTIONAL. List of fields containing document IDs to resolve inline. Referenced documents are fetched and attached under an '_expanded' key. Supports dot-notation for nested fields (e.g., 'items.product_id'). Max 50 unique references per request. Depth is limited to 1 (no recursive expansion).","examples":[["customer_id"],["customer_id","items.product_id"]]},"limit":{"type":"integer","maximum":1000.0,"minimum":1.0,"title":"Limit","description":"Number of documents to return per page. Capped at 1000. Accepts ``page_size`` as an alias (POST body only).","default":10},"offset":{"type":"integer","minimum":0.0,"title":"Offset","description":"Number of documents to skip (offset-based pagination).","default":0},"collection_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Collection Ids","description":"Optional list of collection IDs (or collection names) to filter by. When omitted, returns documents from all collections in the namespace. Also accepted as collection_id or collections. An unrecognised top-level key in this body is rejected with 422 naming the accepted keys."}},"type":"object","title":"NamespaceListDocumentsRequest","description":"Request model for listing documents across all collections in a namespace.\n\nExtends ListDocumentsRequest with an optional collection_ids filter.\nWhen collection_ids is omitted, documents from all collections are returned."},"NamespaceListStats":{"properties":{"total_feature_extractors":{"type":"integer","title":"Total Feature Extractors","description":"Total number of feature extractors across all namespaces","default":0},"total_payload_indexes":{"type":"integer","title":"Total Payload Indexes","description":"Total number of payload indexes across all namespaces","default":0},"total_documents":{"type":"integer","title":"Total Documents","description":"Total number of documents across all namespaces","default":0},"total_documents_complete":{"type":"boolean","title":"Total Documents Complete","description":"Whether every namespace's document count in this list finished. False when any namespace has document_count_complete false, so total_documents is a lower bound.","default":true},"total_buckets":{"type":"integer","title":"Total Buckets","description":"Total number of buckets across all namespaces","default":0},"total_collections":{"type":"integer","title":"Total Collections","description":"Total number of collections across all namespaces","default":0},"total_objects":{"type":"integer","title":"Total Objects","description":"Total number of objects across all namespaces","default":0},"avg_feature_extractors_per_namespace":{"type":"number","title":"Avg Feature Extractors Per Namespace","description":"Average number of feature extractors per namespace","default":0.0},"avg_payload_indexes_per_namespace":{"type":"number","title":"Avg Payload Indexes Per Namespace","description":"Average number of payload indexes per namespace","default":0.0},"avg_documents_per_namespace":{"type":"number","title":"Avg Documents Per Namespace","description":"Average number of documents per namespace","default":0.0},"avg_buckets_per_namespace":{"type":"number","title":"Avg Buckets Per Namespace","description":"Average number of buckets per namespace","default":0.0},"avg_collections_per_namespace":{"type":"number","title":"Avg Collections Per Namespace","description":"Average number of collections per namespace","default":0.0},"avg_objects_per_namespace":{"type":"number","title":"Avg Objects Per Namespace","description":"Average number of objects per namespace","default":0.0}},"type":"object","title":"NamespaceListStats","description":"Aggregate statistics for a list of namespaces."},"NamespaceModel":{"properties":{"object":{"type":"string","title":"Object","description":"Resource type identifier, always 'namespace'.","default":"namespace","readOnly":true},"namespace_id":{"type":"string","title":"Namespace Id","description":"Unique identifier for the namespace. Format: ns_<random>."},"namespace_name":{"type":"string","maxLength":64,"title":"Namespace Name","description":"Name of the namespace","example":"product-search"},"namespace_type":{"$ref":"#/components/schemas/NamespaceType","description":"Type of namespace. STANDARD for regular namespaces, MARKETPLACE for curated datasets that can be subscribed to.","default":"standard"},"scope":{"$ref":"#/components/schemas/NamespaceScope","description":"Ownership scope. ORG (default) is org-scoped — only visible to members of the owning organization. SYSTEM is Mixpeek-owned and visible read-only to every authenticated org; used for curated sample corpora. Mutations on SYSTEM namespaces require admin auth.","default":"org"},"infrastructure":{"anyOf":[{"$ref":"#/components/schemas/NamespaceInfrastructure"},{"type":"null"}],"description":"Infrastructure configuration for the namespace."},"trusted_issuers":{"anyOf":[{"items":{"$ref":"#/components/schemas/NamespaceTrustedIssuer"},"type":"array","maxItems":5},{"type":"null"}],"title":"Trusted Issuers","description":"Identity providers whose end-user tokens (OIDC/JWT, verified against a JWKS) may call this namespace directly from a browser, each with the retrievers and collections it may use and the claims applied as filters. None or empty accepts no end-user tokens."},"cost_cap_override":{"anyOf":[{"$ref":"#/components/schemas/NamespaceCostCapOverride"},{"type":"null"}],"description":"Deprecated: use spend_budget. Explicit daily inference cost cap for this namespace, kept working for existing callers."},"tiering":{"anyOf":[{"$ref":"#/components/schemas/TieringOverride"},{"type":"null"}],"description":"This namespace's tiering override: enabled, idle_days and exempt (a reason). Each field left unset inherits the platform's data-class default, and each collection inherits from here. An exempt namespace is never demoted."},"pinned":{"anyOf":[{"$ref":"#/components/schemas/NamespacePin"},{"type":"null"}],"description":"This namespace's pin: enabled, warm_query_encoder, and who set it when. A pinned namespace with warm_query_encoder keeps one replica of each query encoder its searches call running, billed per replica-hour as its own invoice line. Absent means not pinned."},"starred":{"type":"boolean","title":"Starred","description":"Shows this namespace at the top of the organization's namespace list. A display preference shared by everyone in the organization: free, with no limit on how many, and no effect on capacity or billing. Separate from pinned, which keeps capacity warm.","default":false},"spend_budget":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Spend Budget","description":"This namespace's own spend budget as stored: daily_usd, monthly_usd and the change history. Absent until someone sets it; the organization's namespace default applies until then."},"budget":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Budget","description":"Read-only. The namespace's effective daily and monthly budget, where each number comes from, spend to date, and the headroom left under the organization's budget. Computed on GET; never stored."},"cluster_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cluster Id","description":"Infrastructure cluster ID for this namespace (Enterprise only). When set, this namespace uses a dedicated compute and vector cluster. If None, uses shared infrastructure or organization-level infrastructure. Format: iclstr_xxx","examples":["iclstr_abc123xyz",null]},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Description of the namespace"},"feature_extractors":{"items":{"$ref":"#/components/schemas/BaseFeatureExtractorModel-Output"},"type":"array","title":"Feature Extractors","description":"List of feature extractors configured for this namespace"},"payload_indexes":{"anyOf":[{"items":{"$ref":"#/components/schemas/PayloadIndexConfig-Output"},"type":"array"},{"type":"null"}],"title":"Payload Indexes","description":"Custom payload indexes configured for this namespace"},"payload_index_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Payload Index Count","description":"Number of USER (non-protected) payload indexes on this namespace — the same count the Studio Namespaces table shows per row. Populated even in the summary LIST view, which omits the heavy `payload_indexes` array itself (the array is ~75% of the list payload, but its count is a single integer). Without it the table can only show '—'."},"document_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Document Count","description":"Total number of documents in this namespace"},"document_count_complete":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Document Count Complete","description":"False when the live vector-store count above did not finish in time (e.g. a shard still replaying its WAL after a restart) and document_count is therefore null rather than a real count, including a genuine zero. True (the default) covers every non-degraded response, including an empty namespace, whose document_count is 0 with this true.","default":true},"bucket_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Bucket Count","description":"Total number of buckets in this namespace"},"collection_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Collection Count","description":"Total number of collections in this namespace"},"object_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Object Count","description":"Total number of objects across all buckets in this namespace"},"auto_create_indexes":{"type":"boolean","title":"Auto Create Indexes","description":"Enable automatic creation of vector store payload indexes based on filter usage patterns. When enabled, the system tracks which fields are most frequently filtered (>100 queries/24h) and automatically creates indexes to improve query performance. Background task runs every 6 hours. Expected performance improvement: 50-90% latency reduction for filtered queries.","default":false},"adaptive_indexing":{"type":"boolean","title":"Adaptive Indexing","description":"Let the vector index re-tune its own partition size and flush threshold from observed search latency. Off by default. When on, every change it makes is recorded in the namespace's mxp_platform_events collection (event_type index_adaptation) with the parameter, its old and new value, the search count that triggered it, and p95 search latency before and after.","default":false},"vector_inference_map":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Vector Inference Map","description":"Mapping of vector index names to inference service names. Built at namespace creation based on extractor configurations. Used by feature search to determine correct inference service for queries. Example: {'image_extractor_v1_embedding': 'google_siglip_base_v1'}"},"dynamic_vector_indexes":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Dynamic Vector Indexes","description":"Creation-time marker for BYO vector-name handling. False = the namespace was created with EXPLICIT vector_configs, so upserting a vector name outside those configs is rejected (422) instead of silently auto-indexed under a name nothing searches. True = fully dynamic BYO namespace (created without vector_configs): new vector names keep being inferred on first upsert. Null (namespaces that predate the marker) behaves as True so existing flows are unchanged."},"mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mode","description":"Namespace mode: 'managed' (Mixpeek manages vector schemas and inference) or 'standalone' (bring-your-own vectors). Populated from the stored mvs_mode; null for namespaces that predate BYOV."},"vector_configs":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Vector Configs","description":"For standalone / promoted (BYO-vector) namespaces, the per-vector configs: name, dimension, metric. Populated from the stored mvs_vector_configs; null for managed namespaces with no BYO vectors."},"clone_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Clone Status","description":"Deep-clone / scaffold sample-data progress: 'cloning' (in flight), 'ready' (completed), 'failed' (see clone_error). Null for namespaces that were never cloned. Poll this after a scaffold instantiate with include_sample_data=true."},"clone_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Clone Error","description":"Error detail when clone_status='failed'; null otherwise."},"clone_phase":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Clone Phase","description":"Fine-grained clone progress: 'queued' (dispatched, waiting for a worker — a clone can wait many minutes behind tenant heavy-queue backlogs), 'copying' (the clone task is actively running), null once terminal (see clone_status) or for namespaces never cloned. Distinguishes a queue-starved clone from a dead one."},"clone_task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Clone Task Id","description":"Work id of the in-flight or last deep clone, for diagnosing a stalled clone from the namespace record alone."},"clone_dispatched_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Clone Dispatched At","description":"When the deep-clone task was dispatched; with clone_phase='queued' this measures time spent waiting for a worker."},"source_namespace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Namespace Id","description":"For a cloned namespace, the source (golden/sample) namespace id it was cloned from."},"namespace_ready":{"type":"boolean","title":"Namespace Ready","description":"ALWAYS PRESENT. True only after the server CONFIRMED this namespace is usable: its vector collection exists and is reachable (a served live count, the readiness signal) and no clone is in flight. Never a prediction or timestamp. A wizard-created namespace mid-provision reads false (poll the namespace GET; it flips true on the first confirming read and the flip is persisted). Namespaces created before the feature shipped emit true; post-ship namespaces with no stored value emit false (fail toward not-ready).","default":false},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When the namespace was created"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"When the namespace was last updated"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At","description":"UTC timestamp after which the namespace is deleted automatically. Set at create time from ttl_seconds, and changed or cleared with PATCH (expires_at or ttl_seconds). An hourly sweep records a namespace_expiring event in the namespace's mxp_platform_events collection about an hour before, and deletes the namespace once the expiry has passed and that warning is an hour old. Null means the namespace never expires."}},"type":"object","required":["namespace_name"],"title":"NamespaceModel","description":"Namespace model."},"NamespaceOperation":{"type":"string","enum":["read_data","write_data","delete_data","execute_retriever","create_retriever","delete_retriever","execute_job","cancel_job","create_cluster","delete_cluster","modify_cluster","modify_infrastructure","manage_permissions"],"title":"NamespaceOperation","description":"Granular operations that can be scoped inside a namespace.\n\nThese operations are used to define fine-grained permissions for API keys and users\nwithin specific namespaces. Operations can be granted individually or in combination\nto implement least-privilege access control.\n\nData operations:\n    - READ_DATA: View and search documents, retrieve objects from buckets\n    - WRITE_DATA: Create and update documents, upload objects to buckets\n    - DELETE_DATA: Remove documents and objects permanently\n\nRetrieval operations:\n    - EXECUTE_RETRIEVER: Run search queries using configured retrievers\n    - CREATE_RETRIEVER: Define new retrieval pipelines with custom stages\n    - DELETE_RETRIEVER: Remove retrieval pipeline configurations\n\nJob execution:\n    - EXECUTE_JOB: Trigger ingestion pipelines and batch processing jobs\n    - CANCEL_JOB: Abort running jobs before completion\n\nCluster management (Ray infrastructure):\n    - CREATE_CLUSTER: Provision new Ray compute clusters\n    - DELETE_CLUSTER: Tear down existing compute clusters\n    - MODIFY_CLUSTER: Scale or reconfigure running clusters\n\nInfrastructure configuration:\n    - MODIFY_INFRASTRUCTURE: Change namespace settings, storage connections\n    - MANAGE_PERMISSIONS: Grant and revoke user access within the namespace\n\nExamples:\n    - Read-only access: [READ_DATA, EXECUTE_RETRIEVER]\n    - Data engineer access: [READ_DATA, WRITE_DATA, EXECUTE_JOB]\n    - Full namespace admin: All operations granted"},"NamespacePin":{"properties":{"enabled":{"type":"boolean","title":"Enabled","description":"Pin the namespace. false unpins it.","default":true},"warm_query_encoder":{"type":"boolean","title":"Warm Query Encoder","description":"While pinned, keep one replica of each query encoder this namespace's searches call running, so a search never waits for the encoder to start. Billed per replica-hour to this namespace as its own invoice line. Without it, encoders scale to zero when idle.","default":false},"set_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Set At","description":"Read-only. When the pin was last changed."},"set_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Set By","description":"Read-only. Who last changed the pin."}},"additionalProperties":false,"type":"object","title":"NamespacePin","description":"``pinned`` on a namespace: the customer's opt-in, stamped by the server."},"NamespaceScope":{"type":"string","enum":["org","system"],"title":"NamespaceScope","description":"Ownership scope for a namespace.\n\nORG: owned by a single organization (default). Internal_id-scoped.\nSYSTEM: owned by Mixpeek, visible read-only to every authenticated user.\n    Used for curated sample corpora that power the onboarding experience.\n    Mutations require MIXPEEK_PRIVATE_TOKEN admin auth."},"NamespaceSelector":{"properties":{"mode":{"$ref":"#/components/schemas/NamespaceSelectorMode","description":"Whether the alert applies to all namespaces or a selected set","default":"all"},"namespace_ids":{"items":{"type":"string"},"type":"array","title":"Namespace Ids","description":"Namespace IDs the alert applies to (when mode=selected)","examples":[["ns_production","ns_staging"]]}},"type":"object","title":"NamespaceSelector","description":"Selects which namespaces an org-level alert applies to.\n\nmode=all   → every namespace in the org (resolved at evaluation time).\nmode=selected → an explicit allow-list; must be non-empty.\n\nAttributes:\n    mode: ``all`` or ``selected``.\n    namespace_ids: Allow-list used when mode=selected."},"NamespaceSelectorMode":{"type":"string","enum":["all","selected"],"title":"NamespaceSelectorMode","description":"How an org-level alert chooses which namespaces it applies to."},"NamespaceSpendBudgetUpdate":{"properties":{"daily_usd":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Daily Usd","description":"This namespace's daily spend budget in USD."},"monthly_usd":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Monthly Usd","description":"This namespace's monthly spend budget in USD."}},"additionalProperties":false,"type":"object","title":"NamespaceSpendBudgetUpdate","description":"Namespace budget fields. Null resets a field to the org's namespace default."},"NamespaceStatsBatchRequest":{"properties":{"namespace_ids":{"items":{"type":"string"},"type":"array","maxItems":100,"title":"Namespace Ids","description":"Namespace IDs to fetch counts for (the visible rows)."}},"type":"object","required":["namespace_ids"],"title":"NamespaceStatsBatchRequest","description":"Request for batch namespace stats — the visible page of namespace IDs."},"NamespaceStatsBatchResponse":{"properties":{"stats":{"additionalProperties":{"$ref":"#/components/schemas/NamespaceStatsResponse"},"type":"object","title":"Stats","description":"Map of namespace_id → its counts. Namespaces the caller cannot see are omitted."}},"type":"object","title":"NamespaceStatsBatchResponse","description":"Per-namespace stats keyed by namespace_id, returned in ONE call.\n\nReplaces the Studio namespaces-list N+1 that fired one\n``GET /namespaces/{id}/stats`` per visible row (each a live MVS doc-count).\nCounts are batch-aggregated (buckets/collections/objects in 3 queries) and\ndoc counts are gathered concurrently server-side."},"NamespaceStatsResponse":{"properties":{"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace identifier"},"document_count":{"type":"integer","title":"Document Count","description":"Total number of documents in this namespace. With document_count_complete false the count did not finish and this is a lower bound (the documents counted before it stopped, 0 when none were).","default":0},"document_count_complete":{"type":"boolean","title":"Document Count Complete","description":"Whether document_count finished. False when a collection's or the vector store's count timed out or failed, in which case document_count is a lower bound and a 0 does not mean the namespace is empty; ask again shortly.","default":true},"bucket_count":{"type":"integer","title":"Bucket Count","description":"Total number of buckets in this namespace","default":0},"collection_count":{"type":"integer","title":"Collection Count","description":"Total number of collections in this namespace","default":0},"object_count":{"type":"integer","title":"Object Count","description":"Total number of objects across all buckets in this namespace","default":0}},"type":"object","required":["namespace_id"],"title":"NamespaceStatsResponse","description":"Per-namespace statistics (counts) returned by the stats endpoint."},"NamespaceStorageTier":{"properties":{"rung":{"type":"string","title":"Rung","description":"The namespace's storage rung: hot, warm, cold or frozen. It moves down when the namespace goes unqueried and back to hot after sustained queries. A query answers on every rung."},"storage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Storage","description":"The storage class the index files are in (standard, nearline, coldline), or autoclass when the bucket chooses its own classes."},"changed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Changed At","description":"When the rung last changed."}},"type":"object","required":["rung"],"title":"NamespaceStorageTier","description":"Where the namespace's vector index files sit in object storage."},"NamespaceSummaryResponse":{"properties":{"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace ID analyzed"},"time_range_days":{"type":"integer","title":"Time Range Days","description":"Number of days analyzed"},"summary":{"additionalProperties":true,"type":"object","title":"Summary","description":"Summary statistics (total_fields_analyzed, high_priority_indexes, etc.)"},"recommendations":{"items":{"$ref":"#/components/schemas/IndexRecommendation"},"type":"array","title":"Recommendations","description":"Top index recommendations"},"most_queried_fields":{"items":{"$ref":"#/components/schemas/FieldQueryMetrics"},"type":"array","title":"Most Queried Fields","description":"Most frequently queried fields"},"slowest_fields":{"items":{"$ref":"#/components/schemas/FieldPerformanceMetrics"},"type":"array","title":"Slowest Fields","description":"Fields with highest latency"},"compound_indexes":{"items":{"$ref":"#/components/schemas/CompoundIndexPattern"},"type":"array","title":"Compound Indexes","description":"Compound index opportunities"}},"type":"object","required":["namespace_id","time_range_days","summary","recommendations","most_queried_fields","slowest_fields","compound_indexes"],"title":"NamespaceSummaryResponse","description":"Comprehensive namespace analytics summary."},"NamespaceTrustedIssuer":{"properties":{"issuer":{"type":"string","minLength":1,"title":"Issuer","description":"Exact value of the token's 'iss' claim, e.g. 'https://<project>.supabase.co/auth/v1'."},"jwks_url":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}],"title":"Jwks Url","description":"URL of the provider's JSON Web Key Set, e.g. 'https://<project>.supabase.co/auth/v1/.well-known/jwks.json'. Must be https outside local deployments. Set exactly one of jwks_url or jwks."},"jwks":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Jwks","description":"The provider's public signing keys inline, as a JSON Web Key Set: {\"keys\": [...]}. Use it when the provider publishes no JWKS URL the API can reach. Tokens are verified against these keys with no network fetch, by 'kid' and the accepted algorithms. At most 10 keys; each needs a 'kid' and must be a public RSA or EC key. Private key members and symmetric ('oct') keys are refused. Keys are public and are returned in GET responses. Set exactly one of jwks_url or jwks.","examples":[{"keys":[{"alg":"ES256","crv":"P-256","kid":"key-1","kty":"EC","x":"<base64url>","y":"<base64url>"}]}]},"audience":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audience","description":"Accepted values of the token's 'aud' claim (Supabase: ['authenticated']). When set, a token for another audience is refused."},"algorithms":{"items":{"type":"string","enum":["RS256","RS384","RS512","ES256","ES384","PS256"]},"type":"array","minItems":1,"title":"Algorithms","description":"Signature algorithms accepted. Only asymmetric algorithms are supported, so a shared secret never leaves the provider."},"principal_claim":{"type":"string","minLength":1,"title":"Principal Claim","description":"Claim that identifies the end user (the document owner).","default":"sub"},"principal_prefix":{"type":"string","maxLength":64,"title":"Principal Prefix","description":"Prefix added to the principal claim to form the principal stored as a document's owner, so users of different issuers cannot collide.","default":"jwt:"},"claim_filters":{"items":{"$ref":"#/components/schemas/NamespaceClaimFilter"},"type":"array","title":"Claim Filters","description":"Claims applied as filters on every read. A token without one of these claims is refused."},"retrievers":{"items":{"type":"string"},"type":"array","title":"Retrievers","description":"Retrievers (names or ids) these tokens may execute. Results are limited by claim_filters. Any other retriever is refused."},"collections":{"items":{"type":"string"},"type":"array","title":"Collections","description":"Collections (names or ids) these tokens may read documents from, limited by claim_filters. Read-only."},"owner_writable_collections":{"items":{"type":"string"},"type":"array","title":"Owner Writable Collections","description":"Collections (names or ids) where these tokens may create documents. A created document is owned by the token's principal; reads return the documents the principal owns or was granted, and only a principal with write access can change or delete a document."},"create_principals":{"additionalProperties":{"items":{"type":"string"},"type":"array"},"type":"object","title":"Create Principals","description":"Optional create rule per owner-writable collection: collection (name or id) to the principals that may create documents in it, for example {'warnings': ['internal:true']}. A token holding none of the listed principals (its own principal or a group from group_claims) may not create or upsert documents there. Changes to existing documents still follow the document ACL. Collections not listed are unchanged."},"allowed_origins":{"items":{"type":"string"},"type":"array","title":"Allowed Origins","description":"Browser origins allowed to send these tokens (fnmatch patterns such as 'https://*.example.com'). Empty allows any origin."},"group_claims":{"items":{"$ref":"#/components/schemas/NamespaceGroupClaim"},"type":"array","maxItems":8,"title":"Group Claims","description":"Claims whose values become group principals of the token (e.g. 'brand:<id>' from a brand claim). Documents in owner-writable collections whose ACL names a group are readable (read list) or writable (write list) by every token holding it, and the owner of a document may add groups to its ACL."},"admin_claim":{"anyOf":[{"$ref":"#/components/schemas/NamespaceAdminClaim"},{"type":"null"}],"description":"A claim value (an internal or admin role) whose tokens are not held to claim_filters. Unset: every token is held to them."},"enabled":{"type":"boolean","title":"Enabled","description":"False keeps the entry stored but refuses its tokens.","default":true}},"additionalProperties":false,"type":"object","required":["issuer"],"title":"NamespaceTrustedIssuer","description":"An identity provider whose end-user tokens this namespace accepts.\n\nA browser sends ``Authorization: Bearer <token from the provider>`` with\n``X-Namespace: <namespace_id>``. Mixpeek verifies the token's signature\nagainst ``jwks_url`` (or the inline ``jwks``) and its issuer, audience and expiry, then serves the\nrequest as a scoped principal: read-only by default, limited to the named\nretrievers and collections, with ``claim_filters`` applied to every read."},"NamespaceType":{"type":"string","enum":["standard","marketplace"],"title":"NamespaceType","description":"Type of namespace defining its access control and billing model."},"NewVectorConfigSpecModel":{"properties":{"name":{"type":"string","title":"Name","description":"New vector index name"},"dimension":{"type":"integer","minimum":1.0,"title":"Dimension","description":"Vector dimension"},"metric":{"type":"string","title":"Metric","description":"Distance metric","default":"cosine"},"inference_service":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inference Service","description":"Optional inference service binding"}},"type":"object","required":["name","dimension"],"title":"NewVectorConfigSpecModel"},"NoReduction":{"properties":{"method":{"type":"string","const":"none","title":"Method","default":"none"}},"type":"object","title":"NoReduction"},"Notification":{"properties":{"id":{"type":"string","title":"Id","description":"Unique ID"},"type":{"$ref":"#/components/schemas/NotificationType","description":"Notification type"},"priority":{"$ref":"#/components/schemas/NotificationPriority","description":"Priority level"},"title":{"type":"string","title":"Title","description":"Notification title"},"content":{"type":"string","title":"Content","description":"Notification content"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"organization_id":{"type":"string","title":"Organization Id","description":"Organization ID"},"user_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id","description":"User ID (if applicable)"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Additional metadata"},"delivery_status":{"additionalProperties":{"type":"string"},"propertyNames":{"$ref":"#/components/schemas/NotificationChannel"},"type":"object","title":"Delivery Status","description":"Delivery status by channel"},"read":{"type":"boolean","title":"Read","description":"Whether the notification has been read","default":false},"read_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Read At","description":"When the notification was read"}},"type":"object","required":["type","priority","title","content","organization_id"],"title":"Notification","description":"Model for a notification instance."},"NotificationChannel":{"type":"string","enum":["email","slack","webhook"],"title":"NotificationChannel","description":"Enum for notification delivery channels."},"NotificationChannelConfig":{"properties":{"channel_type":{"type":"string","title":"Channel Type","description":"Type of channel: 'webhook', 'slack', 'email', or 'batch'. 'batch' processes the bucket objects behind the matching documents through a user-defined collection (config: collection_id, and optionally bucket_id and dedup_strategy).","examples":["webhook","slack","email","batch"]},"channel_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Channel Id","description":"Reference to a pre-configured notification channel in the organization","examples":["wh_safety_team","sl_alerts","em_security"]},"config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Config","description":"Channel-specific configuration overrides (e.g., webhook URL, Slack channel, or the target collection for a 'batch' channel)","examples":[{"url":"https://example.com/webhook"},{"channel":"#alerts"},{"to":["admin@example.com"]},{"collection_id":"col_alert_frames"}]}},"type":"object","required":["channel_type"],"title":"NotificationChannelConfig","description":"Configuration for a notification channel.\n\nChannels define what happens when an alert is triggered. Three deliver a\nnotification (webhook, Slack, email). The fourth, 'batch', processes the\nbucket objects behind the matching documents into a user-defined collection.\n\nAttributes:\n    channel_type: Type of channel (webhook, slack, email, batch)\n    channel_id: Optional reference to a pre-configured channel in the organization\n    config: Optional channel-specific configuration overrides"},"NotificationContentType":{"type":"string","enum":["plain_text","html","markdown","json"],"title":"NotificationContentType","description":"Enum for content formats."},"NotificationPriority":{"type":"string","enum":["low","medium","high","critical"],"title":"NotificationPriority","description":"Enum for notification priority levels."},"NotificationType":{"type":"string","enum":["pipeline_success","pipeline_failure","feature_extraction_success","feature_extraction_failure","system_alert","billing_alert","quota_alert","audit_alert","maintenance_alert","custom","onboarding_nudge","engagement_nudge","feature_tip"],"title":"NotificationType","description":"Enum for notification types."},"OPTICSParams":{"properties":{"min_samples":{"type":"integer","minimum":2.0,"title":"Min Samples","description":"Number of samples in a neighborhood for a point to be considered a core point","default":5},"max_eps":{"anyOf":[{"type":"number","exclusiveMinimum":0.0},{"type":"null"}],"title":"Max Eps","description":"Maximum distance between two samples. Default (None) means no maximum distance"},"metric":{"type":"string","title":"Metric","description":"Metric to use for distance computation","default":"minkowski"},"p":{"type":"number","exclusiveMinimum":0.0,"title":"P","description":"Parameter for the Minkowski metric","default":2},"metric_params":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metric Params","description":"Additional keyword arguments for the metric function"},"cluster_method":{"type":"string","title":"Cluster Method","description":"Method to extract clusters ('xi' or 'dbscan')","default":"xi"},"eps":{"anyOf":[{"type":"number","exclusiveMinimum":0.0},{"type":"null"}],"title":"Eps","description":"Maximum distance for DBSCAN cluster extraction method"},"xi":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Xi","description":"Minimum steepness on the reachability plot for cluster boundary (xi method)","default":0.05},"predecessor_correction":{"type":"boolean","title":"Predecessor Correction","description":"Correct clusters based on predecessors (xi method)","default":true},"min_cluster_size":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Min Cluster Size","description":"Minimum number of samples in a cluster. Can be a fraction if < 1.0"},"algorithm":{"type":"string","title":"Algorithm","description":"Algorithm to compute pointwise distances ('auto', 'ball_tree', 'kd_tree', 'brute')","default":"auto"},"leaf_size":{"type":"integer","minimum":1.0,"title":"Leaf Size","description":"Leaf size passed to BallTree or KDTree","default":30},"n_jobs":{"type":"integer","title":"N Jobs","description":"Number of parallel jobs to run (-1 means using all processors)","default":1}},"type":"object","title":"OPTICSParams","description":"Parameters for OPTICS clustering algorithm."},"ObjectAggregationRequest":{"properties":{"group_by":{"items":{"$ref":"#/components/schemas/GroupByField"},"type":"array","minItems":1,"title":"Group By","description":"Fields to group results by. REQUIRED, at least one field. Can include field transformations (date_trunc, date_part). Results will have one row per unique combination of group_by values."},"aggregations":{"items":{"$ref":"#/components/schemas/AggregationOperation"},"type":"array","minItems":1,"title":"Aggregations","description":"Aggregation operations to perform. REQUIRED, at least one operation. Each operation produces a calculated field in results. Can combine multiple functions (COUNT, SUM, AVG, etc.)."},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","description":"Pre-aggregation filters to apply to source data. OPTIONAL, filters data before grouping. Uses same syntax as standard query filters. Applied before GROUP BY.","examples":[{"metadata.status":"active"},{"created_at":{"$gte":"2024-01-01"},"metadata.type":"video"}]},"having":{"anyOf":[{"items":{"$ref":"#/components/schemas/HavingCondition"},"type":"array"},{"type":"null"}],"title":"Having","description":"Post-aggregation filters to apply to results. OPTIONAL, filters groups after aggregation. Uses aggregation aliases as field names. Applied after GROUP BY and aggregation calculations."},"unwind":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unwind","description":"Array field to unwind before aggregation. OPTIONAL, creates one document per array element. Useful for aggregating over array contents. Example: 'blobs' to analyze each blob separately.","examples":["blobs","metadata.tags","metadata.categories"]},"range_buckets":{"anyOf":[{"items":{"$ref":"#/components/schemas/RangeBucket"},"type":"array"},{"type":"null"}],"title":"Range Buckets","description":"Range-based bucketing for numeric fields. OPTIONAL, creates histogram-style buckets. Groups numeric values into defined ranges. Applied during grouping stage."},"sort_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sort By","description":"Field to sort results by. OPTIONAL, can be group_by field or aggregation alias. Defaults to no specific order. Use with sort_direction to control order.","examples":["total_count","avg_duration","category"]},"sort_direction":{"type":"string","title":"Sort Direction","description":"Sort direction. OPTIONAL, defaults to 'desc' (descending). Valid values: 'asc' (ascending), 'desc' (descending). Used with sort_by field.","default":"desc","examples":["asc","desc"]},"limit":{"anyOf":[{"type":"integer","exclusiveMinimum":0.0},{"type":"null"}],"title":"Limit","description":"Maximum number of results to return. OPTIONAL, no limit if not specified. Applied after sorting. Useful for 'top N' queries.","examples":[10,50,100]}},"type":"object","required":["group_by","aggregations"],"title":"ObjectAggregationRequest","description":"Aggregation request for bucket objects.\n\nExtends the base AggregationRequest with object-specific context.\nInherits all fields from AggregationRequest.\n\nRequirements:\n    - group_by: REQUIRED, fields to group by\n    - aggregations: REQUIRED, aggregation operations to perform\n    - All other fields from AggregationRequest are available\n\nExamples:\n    - Count objects by status\n    - Daily upload statistics\n    - Category-based analytics with filtering","examples":[{"aggregations":[{"alias":"total","function":"count"}],"description":"Count objects by status","group_by":[{"alias":"status","field":"status"}],"sort_by":"total","sort_direction":"desc"},{"aggregations":[{"alias":"uploads","function":"count"},{"alias":"unique_users","distinct_field":"metadata.user_id","function":"count_distinct"}],"description":"Daily upload statistics","group_by":[{"alias":"date","date_trunc":"day","field":"created_at"}],"sort_by":"date","sort_direction":"asc"},{"aggregations":[{"alias":"count","function":"count"},{"alias":"total_size","field":"metadata.size","function":"sum"},{"alias":"avg_size","field":"metadata.size","function":"avg"}],"description":"Content type distribution with size stats","group_by":[{"alias":"type","field":"content_type"}],"having":[{"field":"count","operator":"gte","value":5}],"sort_by":"total_size","sort_direction":"desc"}]},"ObjectAggregationResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/AggregationResult"},"type":"array","title":"Results","description":"List of aggregation results, one per group."},"total_groups":{"type":"integer","title":"Total Groups","description":"Total number of unique groups returned."},"query_info":{"additionalProperties":true,"type":"object","title":"Query Info","description":"Additional information about the query execution. May include pipeline stages, execution time, etc."}},"type":"object","required":["results","total_groups"],"title":"ObjectAggregationResponse","description":"Response containing object aggregation results.\n\nReturns aggregated statistics grouped by specified fields.","examples":[{"query_info":{"execution_time_ms":45,"pipeline_stages":5},"results":[{"group":{"status":"completed"},"metrics":{"total":1523}},{"group":{"status":"pending"},"metrics":{"total":87}}],"total_groups":2}]},"ObjectFrontier":{"properties":{"generation_cutoff":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Generation Cutoff","description":"Highest object generation in the recorded inventory (GCS); null on stores without generations"},"last_modified_cutoff":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Modified Cutoff","description":"Latest last-modified time in the recorded inventory"},"objects_listed":{"type":"integer","title":"Objects Listed","default":0}},"type":"object","title":"ObjectFrontier"},"ObjectListStats":{"properties":{"total_objects":{"type":"integer","title":"Total Objects","description":"Number of objects in THIS PAGE of results, not the bucket total. Use ?include_total=true to get the bucket-wide count in pagination.total.","default":0},"total_blobs":{"type":"integer","title":"Total Blobs","description":"Total number of blobs across the objects in this page","default":0},"avg_blobs_per_object":{"type":"number","title":"Avg Blobs Per Object","description":"Average number of blobs per object, over this page","default":0.0},"objects_by_status":{"additionalProperties":true,"type":"object","title":"Objects By Status","description":"Count of objects in this page grouped by status, not a bucket-wide breakdown"}},"type":"object","title":"ObjectListStats","description":"Statistics over the returned page of objects, not the whole bucket.\n\nFor a bucket-wide count use ?include_total=true, which populates\npagination.total instead."},"ObjectResponse":{"properties":{"object_id":{"type":"string","title":"Object Id","description":"Unique identifier for the object"},"bucket_id":{"type":"string","title":"Bucket Id","description":"ID of the bucket this object belongs to"},"key_prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Key Prefix","description":"Storage key/path of the object, this will be used to retrieve the object from the storage. It is similar to a file path. If not provided, it will be placed in the root of the bucket."},"blobs":{"items":{"$ref":"#/components/schemas/BlobModel"},"type":"array","title":"Blobs","description":"List of blobs contained in this object"},"source_details":{"items":{"$ref":"#/components/schemas/SourceDetails"},"type":"array","title":"Source Details","description":"Lineage/source details for this object; used for downstream references."},"edges":{"items":{"$ref":"#/components/schemas/EdgeModel"},"type":"array","title":"Edges","description":"Typed, directed relationships from this object to other objects (customer-owned, root-level — never `_internal`). Flows to the document + MVS payload for the `traverse_edge` retriever stage."},"status":{"$ref":"#/components/schemas/TaskStatusEnum","description":"Processing status of the object. A new object is PENDING, which means it has not been processed yet: either no batch including it has been submitted, or it is in a submitted batch that has not finished. The status of the object's batch tells these apart. When a batch run finishes with the object it becomes COMPLETED or FAILED.","default":"PENDING"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"The error message if the object failed to process.","examples":["Failed to process object: Object not found"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"Timestamp when the object was created. Automatically populated by the system."},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"Timestamp when the object was last updated. Automatically populated by the system."},"document_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Document Count","description":"Number of documents your collections have produced from this object. The object's own record in its bucket is not counted, so the value stays 0 until a collection has processed the object. Populated on GET and list responses. Null when the count cannot be read in time or the store did not answer in full. Use this to check if an object has already been processed."},"consistency":{"anyOf":[{"$ref":"#/components/schemas/WriteConsistency"},{"type":"null"}],"description":"When and how this object becomes a searchable document. Set on write (create) responses: managed ingestion is visible only after a collection batch processes the object — poll until document_count > 0."}},"additionalProperties":true,"type":"object","required":["bucket_id"],"title":"ObjectResponse","description":"Response model for bucket objects.","examples":[{"blobs":[{"blob_id":"blob_1","data":{"num_pages":5,"title":"Service Agreement 2024"},"key_prefix":"/contract-2024/content.pdf","metadata":{"author":"John Doe","department":"Legal"},"property":"content","type":"PDF"}],"bucket_id":"bkt_9xy8z7","content_hash":"28a9f5e8...","created_at":"2024-10-21T10:30:00Z","key_prefix":"/contract-2024","metadata":{"category":"contracts","year":2024},"object_id":"obj_123abc456def","skip_duplicates":false,"status":"PENDING","updated_at":"2024-10-21T10:30:00Z"}]},"OffsetPaginationParams":{"properties":{"method":{"type":"string","const":"offset","title":"Method","description":"Constant identifying offset pagination (REQUIRED).","default":"offset"},"page_size":{"type":"integer","maximum":500.0,"minimum":1.0,"title":"Page Size","description":"Number of documents per page (REQUIRED). Default: 10.","default":10},"page_number":{"type":"integer","minimum":1.0,"title":"Page Number","description":"1-based page index to retrieve (REQUIRED). Default: 1.","default":1}},"type":"object","title":"OffsetPaginationParams","description":"Offset-based pagination using page number sizing.\n\nBest for: Traditional page UIs with page number navigation\n\nHow it works:\n- Uses page numbers (1, 2, 3...) and page size\n- Calculates offset as: (page_number - 1) * page_size\n- Simple and familiar for users\n- Can jump to any page directly\n\nTradeoffs:\n- Can have \"page drift\" if data changes between requests\n- Example: Items added/deleted causes duplicates or gaps\n- Less efficient for large offsets (database must skip N rows)\n\nUse when:\n- Building traditional page-numbered UIs\n- Users need to jump to specific pages\n- Result set is relatively stable\n- Working with smaller datasets\n\nExample:\nPage 1: {\"method\": \"offset\", \"page_size\": 25, \"page_number\": 1}\nPage 2: {\"method\": \"offset\", \"page_size\": 25, \"page_number\": 2}"},"OnboardingAnswers":{"properties":{"building":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Building","description":"What are you building?"},"referral_source":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Referral Source","description":"How did you hear about Mixpeek?"}},"type":"object","title":"OnboardingAnswers","description":"Optional signup questions — each non-empty answer takes $5 off the\nfirst invoice (max $10). Answers are persisted for GTM attribution."},"OpenAIModel":{"type":"string","enum":["gpt-4o-2024-08-06","gpt-4o-mini-2024-07-18","gpt-4.1-2025-04-14","gpt-4.1-mini-2025-04-14","o3-mini-2025-01-31"],"title":"OpenAIModel","description":"OpenAI model identifiers for LLM generation.\n\nModels listed in order of capability and cost (highest to lowest).\nAll models support vision (images) except O3-mini.\n\nValues:\n    GPT_4O: Latest GPT-4 Omni model (2024-08-06)\n        - Use for: Production, highest quality generation\n        - Context: 128K tokens\n        - Vision: Yes\n        - Cost: $2.50/1M input, $10/1M output\n        - Performance: 200-500ms per request\n        - When to use: Need best quality, willing to pay premium\n\n    GPT_41: GPT-4.1 (2025-04-14)\n        - Use for: Future-proofed pipelines\n        - Context: 128K tokens\n        - Vision: Yes\n        - Cost: TBD (expected similar to GPT-4o)\n        - When to use: Want latest model features\n\n    GPT_4O_MINI: Smaller, faster GPT-4 Omni (2024-07-18)\n        - Use for: High-volume, cost-sensitive workloads\n        - Context: 128K tokens\n        - Vision: Yes\n        - Cost: $0.15/1M input, $0.60/1M output\n        - Performance: 100-200ms per request\n        - When to use: Good balance of quality and cost\n\n    GPT_41_MINI: Smaller GPT-4.1 (2025-04-14)\n        - Use for: Future cost-optimized pipelines\n        - Context: 128K tokens\n        - Vision: Yes\n        - Cost: TBD (expected similar to GPT-4o-mini)\n        - When to use: Want latest features at lower cost\n\n    O3_MINI: Reasoning-optimized model (2025-01-31)\n        - Use for: Complex reasoning, math, code\n        - Context: 200K tokens\n        - Vision: No\n        - Cost: TBD\n        - When to use: Need advanced reasoning capabilities\n\nExamples:\n    - Use GPT_4O for caption generation with images (best quality)\n    - Use GPT_4O_MINI for high-volume video scene summarization (cost-effective)\n    - Use O3_MINI for complex entity extraction requiring reasoning"},"OrgModelDeleteResponse":{"properties":{"success":{"type":"boolean","title":"Success","default":true},"model_id":{"type":"string","title":"Model Id"},"message":{"type":"string","title":"Message"}},"type":"object","required":["model_id","message"],"title":"OrgModelDeleteResponse","description":"Response model for org model deletion."},"OrgModelDeploymentInfo":{"properties":{"ray_cluster_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ray Cluster Url","description":"Ray cluster URL where model is deployed"},"ray_deployment_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ray Deployment Name","description":"Ray deployment name"},"deployed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Deployed At","description":"When the model was deployed"}},"type":"object","title":"OrgModelDeploymentInfo","description":"Deployment information for an org-level model."},"OrgModelDetailResponse":{"properties":{"success":{"type":"boolean","title":"Success","default":true},"model":{"$ref":"#/components/schemas/OrgModelDocument"}},"type":"object","required":["model"],"title":"OrgModelDetailResponse","description":"Response model for org model details."},"OrgModelDocument":{"properties":{"model_id":{"type":"string","title":"Model Id","description":"Unique model identifier"},"organization_id":{"type":"string","title":"Organization Id","description":"Owner organization ID"},"name":{"type":"string","title":"Name","description":"Model name"},"version":{"type":"string","title":"Version","description":"Model version (semver)"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Model description"},"source":{"type":"string","enum":["customer","mixpeek","system"],"title":"Source","description":"Who created this model: 'customer' (org-uploaded), 'mixpeek' (professional services), or 'system' (globally available)","default":"customer"},"exportable":{"type":"boolean","title":"Exportable","description":"Whether the model archive can be downloaded by the customer. Auto-set to False for source='mixpeek'.","default":true},"license":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"License","description":"License of a model imported from the Hugging Face Hub, as its model card declares it ('unspecified' when the card names none)."},"s3_archive_url":{"type":"string","title":"S3 Archive Url","description":"S3 URL to model archive"},"model_format":{"type":"string","enum":["safetensors","onnx","pytorch","huggingface"],"title":"Model Format","description":"Model format/framework"},"model_hash":{"type":"string","title":"Model Hash","description":"SHA256 hash of model archive"},"validation_status":{"type":"string","enum":["passed","failed","pending"],"title":"Validation Status","description":"Validation status"},"validation_errors":{"items":{"type":"string"},"type":"array","title":"Validation Errors","description":"Validation error messages"},"validation_traceback":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Validation Traceback","description":"When the validation job failed: the end of the traceback from loading the model or running its sample inference."},"validation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Validation","description":"What the validation job measured when it passed: validated_at, the engine_revision it ran on, the digest of the weights, peak_rss_bytes of the replica, and deploy_s, first_inference_s and cold_start_s."},"deployed":{"type":"boolean","title":"Deployed","description":"Whether model has been deployed to any namespace","default":false},"deployment_info":{"anyOf":[{"$ref":"#/components/schemas/OrgModelDeploymentInfo"},{"type":"null"}],"description":"Deployment details"},"framework":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Framework","description":"ML framework (e.g., sentence-transformers)"},"task_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Type","description":"Task type (e.g., embedding, classification)"},"embedding_dim":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Embedding Dim","description":"Output dimension of an embedding model, measured by its validation job's sample inference. A collection on an extractor that serves it needs it before its vector index can be built."},"input_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Input Schema","description":"Input schema JSON"},"output_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Output Schema","description":"Output schema JSON"},"resource_requirements":{"$ref":"#/components/schemas/ModelResourceRequirements","description":"Resource requirements for deployment"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"},"tiering":{"anyOf":[{"$ref":"#/components/schemas/ModelTieringView"},{"type":"null"}],"description":"The model's tier on the tiering ladder and its wake cost and time."},"registry":{"$ref":"#/components/schemas/ModelRegistryIdentity","description":"The ids this entry derives: registry id, shared model key, service id.","readOnly":true}},"type":"object","required":["model_id","organization_id","name","version","s3_archive_url","model_format","model_hash","validation_status","registry"],"title":"OrgModelDocument","description":"Org-level model document stored in MongoDB.\n\nOrg-scoped: Uses organization_id instead of namespace_id.\nModels belong to an organization and can be enabled in any namespace within that org."},"OrgModelListItem":{"properties":{"model_id":{"type":"string","title":"Model Id"},"name":{"type":"string","title":"Name"},"version":{"type":"string","title":"Version"},"model_format":{"type":"string","enum":["safetensors","onnx","pytorch","huggingface"],"title":"Model Format"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"source":{"type":"string","enum":["customer","mixpeek","system"],"title":"Source","default":"customer"},"exportable":{"type":"boolean","title":"Exportable","default":true},"framework":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Framework"},"task_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Type"},"deployed":{"type":"boolean","title":"Deployed"},"validation_status":{"type":"string","title":"Validation Status"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"registry":{"anyOf":[{"$ref":"#/components/schemas/ModelRegistryIdentity"},{"type":"null"}],"description":"The ids this entry derives: registry id, shared model key, service id."},"tiering":{"anyOf":[{"$ref":"#/components/schemas/ModelTieringView"},{"type":"null"}],"description":"The model's tier on the tiering ladder and its wake cost and time."}},"type":"object","required":["model_id","name","version","model_format","deployed","validation_status","created_at","updated_at"],"title":"OrgModelListItem","description":"Model item in list response."},"OrgModelListResponse":{"properties":{"success":{"type":"boolean","title":"Success","default":true},"models":{"items":{"$ref":"#/components/schemas/OrgModelListItem"},"type":"array","title":"Models"},"total":{"type":"integer","title":"Total"},"organization_id":{"type":"string","title":"Organization Id"}},"type":"object","required":["models","total","organization_id"],"title":"OrgModelListResponse","description":"Response model for listing org models."},"OrganizationModelResponse":{"properties":{"organization_id":{"type":"string","title":"Organization Id"},"organization_name":{"type":"string","title":"Organization Name"},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url"},"account_type":{"$ref":"#/components/schemas/AccountTier"},"credit_count":{"type":"integer","title":"Credit Count"},"effective_monthly_credit_cap":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Effective Monthly Credit Cap"},"onboarding_answers":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Onboarding Answers"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata"},"billing_email":{"anyOf":[{"type":"string","format":"email"},{"type":"null"}],"title":"Billing Email"},"notifications_email":{"anyOf":[{"type":"string","format":"email"},{"type":"null"}],"title":"Notifications Email"},"notifications_email_delivery_status":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Notifications Email Delivery Status","description":"Delivery health of notifications_email. Set when the email vendor reports the address undeliverable; cleared when the address is re-saved. None = no known problem."},"rate_limits":{"$ref":"#/components/schemas/BaseRateLimits"},"auto_billing_enabled":{"type":"boolean","title":"Auto Billing Enabled","default":false},"billing_cycle_start":{"type":"integer","title":"Billing Cycle Start","default":1},"current_month_usage":{"type":"integer","title":"Current Month Usage","default":0},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"users":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Users"},"auth_provider_org_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Auth Provider Org Id"},"default_llm_credentials":{"additionalProperties":{"type":"string"},"type":"object","title":"Default Llm Credentials"},"workload_identity_providers":{"items":{"$ref":"#/components/schemas/WorkloadIdentityProvider"},"type":"array","title":"Workload Identity Providers"},"api_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Api Url"},"spend_limits":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Spend Limits","description":"The organization's effective spend budget: daily_usd, monthly_usd, the namespace defaults, the plan's safety ceilings, spend to date, headroom, where each number comes from, and the change history."},"requires_plan":{"type":"boolean","title":"Requires Plan","description":"True when this workspace must pick a plan before it can create namespaces or run billable work. When gated, write endpoints return 403 PlanRequiredError linking to https://studio.mixpeek.com/signup/plan where the workspace picks one.","default":false},"is_internal":{"type":"boolean","title":"Is Internal","description":"True when this org is Mixpeek-internal (team/dogfood/ops), derived server-side at read time. Analytics consumers should exclude internal orgs from customer metrics.","default":false}},"type":"object","required":["organization_id","organization_name","account_type","credit_count","rate_limits","created_at","updated_at"],"title":"OrganizationModelResponse","description":"Response model for organization endpoints.\n\nSECURITY: Does NOT expose internal_id to prevent leakage of high-entropy secrets.\nOnly organization_id (public identifier) is included in API responses.","examples":[{"account_type":"pro","created_at":"2025-01-01T00:00:00Z","credit_count":250000,"logo_url":"https://www.google.com/s2/favicons?domain=acme.com&sz=128","organization_id":"org_demo123","organization_name":"Acme Corporation"}]},"OrganizationPublishStatsResponse":{"properties":{"current_count":{"type":"integer","title":"Current Count","description":"Number of retrievers currently published from this namespace"},"max_allowed":{"type":"integer","title":"Max Allowed","description":"Maximum number of published retrievers allowed per namespace"},"remaining":{"type":"integer","title":"Remaining","description":"Number of remaining publish slots"},"at_limit":{"type":"boolean","title":"At Limit","description":"Whether this namespace has reached the publish limit"}},"type":"object","required":["current_count","max_allowed","remaining","at_limit"],"title":"OrganizationPublishStatsResponse","description":"Publish quota stats for the namespace in the request."},"OrganizationUpdateRequest":{"properties":{"organization_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Name","description":"Updated display name for the organization."},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url","description":"Updated organization logo URL (e.g., custom logo to override auto-generated logo)."},"billing_email":{"anyOf":[{"type":"string","format":"email"},{"type":"null"}],"title":"Billing Email","description":"Updated billing contact email."},"notifications_email":{"anyOf":[{"type":"string","format":"email"},{"type":"null"}],"title":"Notifications Email","description":"Set the opt-in single address that receives alert/system notifications (None leaves it unchanged via exclude_unset)."},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Replace metadata with provided dictionary when set."},"rate_limit_overrides":{"anyOf":[{"$ref":"#/components/schemas/BaseRateLimits"},{"type":"null"}],"description":"Per-org rate-limit overrides (merged on top of tier defaults)."},"default_llm_credentials":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Default Llm Credentials","description":"Map of provider names to secret names for org-wide LLM credentials."},"spend_limits":{"anyOf":[{"$ref":"#/components/schemas/SpendLimitsUpdate"},{"type":"null"}],"description":"Set the organization's spend budget and the default budget every namespace gets. Each value is in USD of metered spend; null resets it to the plan default. The organization budget cannot exceed the plan's safety ceiling without Mixpeek support, and a namespace default cannot exceed the organization budget. Every change is recorded with who made it, when, and the prior value."},"nsfw_check_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Nsfw Check Enabled","description":"Toggle NSFW upload classification + hard-reject for this organization. Applies only to SHARED-plane tenants (infrastructure is None). None leaves the current setting unchanged."},"nsfw_fail_closed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Nsfw Fail Closed","description":"Toggle fail-closed behaviour for the NSFW gate (reject uploads when the classifier is unavailable instead of allowing them). None leaves the current setting unchanged."},"workload_identity_providers":{"anyOf":[{"items":{"$ref":"#/components/schemas/WorkloadIdentityProviderInput"},"type":"array"},{"type":"null"}],"title":"Workload Identity Providers","description":"Replace the organization's workload identity providers. Send the full list: keep each existing provider's provider_id to preserve it, omit provider_id to add one, leave a provider out to remove it. Requires admin."}},"type":"object","title":"OrganizationUpdateRequest","description":"Partial update payload for organization metadata."},"PageMeta":{"properties":{"title":{"type":"string","title":"Title","description":"Page title displayed in the browser tab and page header.","examples":["My Product Search","Brand Compliance Dashboard"]},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Short page description shown in the page header or subtitle area.","examples":["Search across 10k+ product images"]},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url","description":"URL of the logo displayed in the page header.","examples":["https://cdn.example.com/logo.png"]},"favicon_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Favicon Url","description":"URL of the favicon for the browser tab.","examples":["https://cdn.example.com/favicon.ico"]},"indexable":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Indexable","description":"When true, opts the app in to search-engine and AI crawler indexing. Canvas serves an Allow robots.txt and omits X-Robots-Tag/noindex. Defaults to false (noindex) for all apps.","examples":[false,true]}},"type":"object","required":["title"],"title":"PageMeta","description":"Page-level metadata (REQUIRED when creating a page).\n\nThis object is separate from the optional ``seo`` field.\n``meta`` controls the visible page chrome (browser tab title, logo, favicon),\nwhile ``seo`` controls search-engine tags (og:title, og:description, etc.)."},"PageTab-Input":{"properties":{"tab_id":{"type":"string","title":"Tab Id","description":"Unique identifier for this tab"},"label":{"type":"string","title":"Label","description":"Display label for the tab"},"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id","description":"Internal retriever ID (use for private retrievers)"},"public_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Public Name","description":"Marketplace catalog public_name (proxies execution via public API)"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Optional tab description shown as subtitle"},"display_config":{"$ref":"#/components/schemas/DisplayConfig-Input","description":"Display configuration for this tab's search UI"}},"type":"object","required":["tab_id","label","display_config"],"title":"PageTab","description":"A single tab in a Page."},"PageTab-Output":{"properties":{"tab_id":{"type":"string","title":"Tab Id","description":"Unique identifier for this tab"},"label":{"type":"string","title":"Label","description":"Display label for the tab"},"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id","description":"Internal retriever ID (use for private retrievers)"},"public_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Public Name","description":"Marketplace catalog public_name (proxies execution via public API)"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Optional tab description shown as subtitle"},"display_config":{"$ref":"#/components/schemas/DisplayConfig-Output","description":"Display configuration for this tab's search UI"}},"type":"object","required":["tab_id","label","display_config"],"title":"PageTab","description":"A single tab in a Page."},"PaginationMetadata":{"properties":{"total":{"type":"integer","minimum":0.0,"title":"Total","description":"Total number of records"},"limit":{"type":"integer","minimum":0.0,"title":"Limit","description":"Requested page size"},"offset":{"type":"integer","minimum":0.0,"title":"Offset","description":"Offset applied to query"},"has_next":{"type":"boolean","title":"Has Next","description":"Whether additional pages exist"}},"type":"object","required":["total","limit","offset","has_next"],"title":"PaginationMetadata","description":"Pagination metadata envelope."},"PaginationResponse":{"properties":{"total":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total","description":"Number of items matching the request across all pages, filters included. null unless the request set include_total=true (in the body or as ?include_total=true). A counted request that matches nothing returns 0."},"page":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Page"},"page_size":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Page Size"},"total_pages":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Pages","description":"Number of pages at page_size. null unless include_total=true."},"next_page":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Page"},"previous_page":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Previous Page"},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},"type":"object","title":"PaginationResponse","description":"PaginationResponse.\n\nCursor-based pagination response:\n- Use next_cursor for navigation\n- Total count fields only populated when include_total=true"},"PassthroughExtractorParams":{"properties":{"extractor_type":{"type":"string","const":"passthrough_extractor","title":"Extractor Type","description":"Discriminator field for parameter type identification.","default":"passthrough_extractor"},"preserve_metadata":{"type":"boolean","title":"Preserve Metadata","description":"Preserve source object metadata in output document.","default":true},"vector_fields":{"items":{"$ref":"#/components/schemas/VectorFieldSpec"},"type":"array","title":"Vector Fields","description":"Precomputed vectors to store from a JSONL or Parquet object. When set, every row of the object becomes its own document: the row's other fields are stored on the document, and each listed vector is stored under its own vector index, searchable with a raw vector in a feature_search stage. Leave empty, and leave row_format unset, to store one document per object.","examples":[[{"dimensions":384,"distance":"cosine","field":"embedding","name":"text_embedding"}]]},"row_format":{"anyOf":[{"type":"string","enum":["jsonl","parquet"]},{"type":"null"}],"title":"Row Format","description":"Read each row of a JSONL or Parquet object as its own document. Set it without vector_fields for payload-only rows (events, spans, logs). With vector_fields set, leave it unset to read the format from the object's file extension (.jsonl or .ndjson for JSONL, .parquet for Parquet)."}},"type":"object","title":"PassthroughExtractorParams","description":"Parameters for passthrough extractor.\n\nMinimal configuration - just passes data through with canonicalization.\nWith ``vector_fields`` set, each row of a JSONL or Parquet object becomes\nits own document carrying the row's precomputed vectors."},"PatchAlertRequest":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":200,"minLength":1},{"type":"null"}],"title":"Name","description":"Updated name for the alert"},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description","description":"Updated description for the alert"},"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id","description":"Updated retriever ID (source=retriever only)"},"trigger_on":{"anyOf":[{"$ref":"#/components/schemas/TriggerOn"},{"type":"null"}],"description":"Updated trigger condition: 'results' or 'no_results'"},"min_count":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Min Count","description":"Updated min_count (trigger_on='results')"},"threshold":{"anyOf":[{"$ref":"#/components/schemas/AlertThreshold"},{"type":"null"}],"description":"Updated threshold (trigger_on='results')"},"inputs":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Inputs","description":"Updated retriever inputs (replaces the whole set)"},"cooldown_seconds":{"anyOf":[{"type":"integer","maximum":2592000.0,"minimum":0.0},{"type":"null"}],"title":"Cooldown Seconds","description":"Updated cooldown in seconds. 0 removes the cooldown."},"renotify_interval_seconds":{"anyOf":[{"type":"integer","maximum":2592000.0,"minimum":60.0},{"type":"null"}],"title":"Renotify Interval Seconds","description":"Updated re-notify interval in seconds"},"system_condition":{"anyOf":[{"$ref":"#/components/schemas/SystemCondition"},{"type":"null"}],"description":"Updated system condition (source=system only)"},"namespace_selector":{"anyOf":[{"$ref":"#/components/schemas/NamespaceSelector"},{"type":"null"}],"description":"Updated org-level namespace scoping"},"notification_config":{"anyOf":[{"$ref":"#/components/schemas/AlertNotificationConfig"},{"type":"null"}],"description":"Updated notification configuration"},"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled","description":"Updated enabled status"},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Updated metadata"}},"type":"object","title":"PatchAlertRequest","description":"Request model to update an alert.\n\nAll fields are optional - provide only what you want to update.\nCore fields (retriever_id, notification_config) can be updated since\nalerts don't have join history like taxonomies."},"PatchAnnotationRequest":{"properties":{"label":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Label"},"confidence":{"anyOf":[{"type":"number","maximum":1.0,"minimum":0.0},{"type":"null"}],"title":"Confidence"},"reasoning":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}],"title":"Reasoning"},"payload":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Payload"},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Custom metadata to attach or replace."}},"type":"object","title":"PatchAnnotationRequest","description":"Partial update to an annotation."},"PatchBatchRequest":{"properties":{"metadata":{"anyOf":[{"$ref":"#/components/schemas/BatchMetadata"},{"type":"null"}],"description":"User-defined metadata for the batch. Has typed fields (campaign_id, source, tags, notes) and also accepts arbitrary extra keys."}},"type":"object","title":"PatchBatchRequest","description":"Request model for partially updating a batch (PATCH operation)."},"PatchClusterRequest":{"properties":{"cluster_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cluster Name","description":"Updated name for the cluster"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Updated description for the cluster"},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Updated metadata for the cluster"},"llm_labeling":{"anyOf":[{"$ref":"#/components/schemas/LLMLabeling-Input"},{"type":"null"}],"description":"Updated LLM labeling configuration. Takes effect on the next `POST /v1/clusters/{id}/execute` — use this to correct a null `labeling_inputs` mapping that produced schema-metadata labels, without re-embedding or re-running HDBSCAN."},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","description":"Updated pre-filter for clustering input documents. Overrides the cluster's stored filter on subsequent execute calls."},"face_cluster_merge":{"anyOf":[{"$ref":"#/components/schemas/FaceClusterMergeConfig"},{"type":"null"}],"description":"Updated post-HDBSCAN face-identity merge configuration. Takes effect on the next `POST /v1/clusters/{id}/execute`. Pass an object with enabled=false to turn the merge pass off without removing the config; pass null in the patch to leave the stored value untouched."},"sample_size":{"anyOf":[{"type":"integer","maximum":1000000.0},{"type":"null"}],"title":"Sample Size","description":"Updated per-execution document cap. Takes effect on the next `POST /v1/clusters/{id}/execute`. Omit to leave the stored value untouched; set to an integer to change it. KMeans supports up to 1M; O(N²) algorithms are capped at 100K by the engine."},"algorithm_params":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Algorithm Params","description":"Updated algorithm parameters (e.g. min_cluster_size, min_samples for HDBSCAN). Takes effect on the next `POST /v1/clusters/{id}/execute`."},"source_cluster_ids":{"anyOf":[{"items":{"type":"string"},"type":"array","minItems":1},{"type":"null"}],"title":"Source Cluster Ids","description":"Updated source clusters of a composite cluster. Each must be a vector cluster in this namespace with this cluster's feature_uris, and a cluster cannot name itself. The cluster's input collections become the sources' input collections. Takes effect on the next `POST /v1/clusters/{id}/execute`."},"layout_stability":{"anyOf":[{"type":"string","enum":["none","transform","align"]},{"type":"null"}],"title":"Layout Stability","description":"Updated layout-stability mode: 'align' keeps the map stable across runs (default behavior), 'transform' reuses the previous run's saved projection when compatible, 'none' re-layouts every run. Takes effect on the next `POST /v1/clusters/{id}/execute`. Omit to leave the stored value untouched."}},"type":"object","title":"PatchClusterRequest","description":"Request model for partially updating a cluster (PATCH operation)."},"PatchDocumentRequest":{"properties":{},"additionalProperties":true,"type":"object","title":"PatchDocumentRequest","description":"Request model for partially updating a document (PATCH operation).\n\n`metadata` is an object of key-value pairs. Each key you send is set on the\nstored metadata. Keys you omit stay as they are. A key whose value is `null`\nis removed from the stored metadata. `metadata: null` returns a 422. PUT and\nPATCH treat `metadata` the same way.\n\nA key at the top level of the body sets the document's top-level field of that\nname. It is a separate field from `metadata.<key>`: a passthrough field such\nas `brand_id` sits at the top level, so send `{\"brand_id\": \"x\"}` to change\nit; `{\"metadata\": {\"brand_id\": \"x\"}}` adds `metadata.brand_id` and leaves the\ntop-level `brand_id` as it was."},"PatchExecutionLabelsRequest":{"properties":{"labels":{"additionalProperties":{"type":"string"},"type":"object","title":"Labels","description":"Map of cluster_id -> new label (e.g. {'cl_0': 'Gadget Reviews'}). Values are trimmed; a non-empty value sets/replaces the override for that cluster_id, an empty string deletes it. Labels are capped at 200 characters. At least one entry is required.","examples":[{"cl_0":"Gadget Reviews"},{"cl_2":""}]}},"type":"object","required":["labels"],"title":"PatchExecutionLabelsRequest","description":"Body for PATCH /v1/clusters/{cluster_id}/executions/{run_id}/labels.\n\nRenames cluster labels for a single execution without re-running\nclustering. Entries merge into the execution record's\n``label_overrides`` map (per-key upsert); an empty-string value deletes\nthat key's override, restoring the original (LLM/auto) label."},"PatchExecutionLabelsResponse":{"properties":{"cluster_id":{"type":"string","title":"Cluster Id","description":"Cluster the execution belongs to"},"run_id":{"type":"string","title":"Run Id","description":"Execution whose labels were patched"},"label_overrides":{"additionalProperties":{"type":"string"},"type":"object","title":"Label Overrides","description":"The execution's full label_overrides map AFTER applying this patch (merged; deleted keys removed). Empty dict when the last override was just deleted."}},"type":"object","required":["cluster_id","run_id"],"title":"PatchExecutionLabelsResponse","description":"Response for PATCH .../executions/{run_id}/labels: the merged overrides."},"PatchExecutionRunNameRequest":{"properties":{"run_name":{"type":"string","title":"Run Name","description":"Human-friendly name for the run (e.g. 'July tuning baseline'). Trimmed; a non-empty value sets/replaces the name, an empty string clears it. Capped at 120 characters.","examples":["July tuning baseline",""]}},"type":"object","required":["run_name"],"title":"PatchExecutionRunNameRequest","description":"Body for PATCH /v1/clusters/{cluster_id}/executions/{run_id}/name.\n\nNames (or renames) a single execution run without re-running clustering.\nThe value is trimmed; an empty string (after trimming) CLEARS the name,\nrestoring the unnamed state (run_id-only display). Strict single-field\nmodel — the run name is the only mutable display field here, mirroring\nthe field-scoped ``.../labels`` PATCH."},"PatchExecutionRunNameResponse":{"properties":{"cluster_id":{"type":"string","title":"Cluster Id","description":"Cluster the execution belongs to"},"run_id":{"type":"string","title":"Run Id","description":"Execution whose name was patched"},"run_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Run Name","description":"The run's name AFTER applying this patch. None when the name was just cleared (empty-string request)."}},"type":"object","required":["cluster_id","run_id"],"title":"PatchExecutionRunNameResponse","description":"Response for PATCH .../executions/{run_id}/name: the persisted name."},"PatchNamespaceRequest":{"properties":{"namespace_name":{"anyOf":[{"type":"string","maxLength":64,"minLength":3},{"type":"null"}],"title":"Namespace Name","description":"Updated name for the namespace","example":"product-search"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Updated description for the namespace"},"feature_extractors":{"anyOf":[{"items":{"$ref":"#/components/schemas/BaseFeatureExtractorModel-Input"},"type":"array"},{"type":"null"}],"title":"Feature Extractors","description":"Feature extractors to add to this namespace. Existing extractors are preserved; only new ones are appended. Each extractor must be a registered builtin plugin."},"payload_indexes":{"anyOf":[{"items":{"$ref":"#/components/schemas/PayloadIndexConfig-Input"},"type":"array"},{"type":"null"}],"title":"Payload Indexes","description":"Updated list of custom payload indexes for this namespace."},"auto_create_indexes":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Auto Create Indexes","description":"Enable automatic creation of vector store payload indexes based on filter usage patterns. When enabled, the system tracks which fields are most frequently filtered (>100 queries/24h) and automatically creates indexes to improve query performance. Background task runs every 6 hours. Expected performance improvement: 50-90% latency reduction for filtered queries. Default: False.","example":true},"adaptive_indexing":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Adaptive Indexing","description":"Let the vector index re-tune its own partition size and flush threshold from observed search latency. Off by default. When on, every change it makes is recorded in the namespace's mxp_platform_events collection (event_type index_adaptation) with the parameter, its old and new value, the search count that triggered it, and p95 search latency before and after.","example":false},"repair_vectors":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Repair Vectors","description":"When True, verify all registered feature extractors have their corresponding vector indexes in the vector store and add any missing ones. Use this to fix namespaces where vector schema is out of sync with registered extractors."},"infrastructure":{"anyOf":[{"$ref":"#/components/schemas/NamespaceInfrastructure"},{"type":"null"}],"description":"Infrastructure configuration for this namespace."},"trusted_issuers":{"anyOf":[{"items":{"$ref":"#/components/schemas/NamespaceTrustedIssuer"},"type":"array","maxItems":5},{"type":"null"}],"title":"Trusted Issuers","description":"Identity providers whose end-user tokens (OIDC/JWT, verified against a JWKS) may call this namespace directly from a browser, each with the retrievers and collections it may use and the claims applied as filters. Replaces the stored list; send [] to stop accepting end-user tokens."},"spend_budget":{"anyOf":[{"$ref":"#/components/schemas/NamespaceSpendBudgetUpdate"},{"type":"null"}],"description":"Set this namespace's daily and monthly spend budget in USD. It must fit inside the organization's budget. A null field returns to the organization's namespace default. Each change is recorded with who made it, when, and the prior value."},"pinned":{"anyOf":[{"$ref":"#/components/schemas/NamespacePin"},{"type":"null"}],"description":"Pin or unpin this namespace. true (or {\"enabled\": true}) pins it; false unpins it. Add \"warm_query_encoder\": true to keep one replica of each query encoder its searches call running while it is pinned, billed per replica-hour to this namespace as its own invoice line. Refused for a free organization, and past the plane's pin cap with the cap named. Unpinning releases the encoder within its idle window."},"starred":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Starred","description":"true shows this namespace at the top of the organization's namespace list; false returns it to its usual place. Free, with no limit on how many, and no effect on capacity or billing."},"tiering":{"anyOf":[{"$ref":"#/components/schemas/TieringOverride"},{"type":"null"}],"description":"Replace this namespace's tiering override: enabled, idle_days {cold, frozen} and exempt (a reason). Send {} to inherit every field from the platform default again."},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At","description":"When the namespace is deleted automatically (UTC). Set it, move it, or send null to remove the expiry. About an hour before deletion a namespace_expiring event is recorded in the namespace's mxp_platform_events collection, and the namespace is deleted only after that warning is an hour old. Send expires_at or ttl_seconds, not both."},"ttl_seconds":{"anyOf":[{"type":"integer","minimum":60.0},{"type":"null"}],"title":"Ttl Seconds","description":"Set expires_at to now plus this many seconds. Send null to remove the expiry. Send expires_at or ttl_seconds, not both."},"cost_cap_override":{"anyOf":[{"$ref":"#/components/schemas/NamespaceCostCapOverride"},{"type":"null"}],"description":"Replace this namespace's daily inference cost cap. Requires daily_usd, reason and owner. Send null to remove the override and return to the tier default."}},"type":"object","title":"PatchNamespaceRequest","description":"Request schema for partially updating a namespace (PATCH operation)."},"PatchObjectRequest":{"properties":{"key_prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Key Prefix","description":"Updated storage key/path prefix of the object"},"skip_duplicates":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Skip Duplicates","description":"Skip duplicate blobs"}},"additionalProperties":true,"type":"object","title":"PatchObjectRequest","description":"Request model for partially updating a bucket object (PATCH operation).\n\nSend the object's custom fields flat at the root of the body. Only the fields\nyou send change. An object created with a `metadata` object keeps its fields\nthere: a `metadata` object in the body merges into it (a null value removes\na key), see ``merge_patch_metadata``."},"PatchRetrieverRequest":{"properties":{"retriever_name":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}],"title":"Retriever Name","description":"Updated retriever name. OPTIONAL - only provide if you want to rename the retriever.","examples":["product_search_v2","customer_lookup_enhanced"]},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Updated human-readable description. OPTIONAL - only provide if you want to update the description.","examples":["Enhanced version with better caching","Updated for Q4 2025"]},"visibility":{"anyOf":[{"$ref":"#/components/schemas/RetrieverVisibility"},{"type":"null"}],"description":"Updated visibility level. OPTIONAL - only provide if you want to change the visibility."},"marketplace_listing_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Marketplace Listing Id","description":"Updated marketplace listing ID. OPTIONAL - only provide if you want to update the marketplace listing."},"requires_subscription":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Requires Subscription","description":"Updated subscription requirement. OPTIONAL - only provide if you want to change the subscription requirement."},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags","description":"Updated tags for organization and filtering. OPTIONAL - replaces existing tags if provided.","examples":[["production","v2"],["experimental","ml-enhanced"]]},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Updated custom key-value metadata. OPTIONAL - replaces existing metadata if provided.","examples":[{"seed_config_version":2}]},"display_config":{"anyOf":[{"$ref":"#/components/schemas/DisplayConfig-Input"},{"type":"null"}],"description":"Updated display configuration for public retriever UI rendering. OPTIONAL - only provide if you want to update the display settings. Defines how the search interface should appear when published."},"collection_identifiers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Collection Identifiers","description":"Updated target collection IDs or names. OPTIONAL - provide to re-point the retriever at different collections. Feature URIs in stages will be re-validated against the new collections.","examples":[["col_abc123","col_def456"]]},"stages":{"anyOf":[{"items":{"$ref":"#/components/schemas/StageConfig-Input"},"type":"array"},{"type":"null"}],"title":"Stages","description":"Edit the retriever's stages IN PLACE (change a filter, operator, rerank params, etc.) without a clone+repoint+delete. OPTIONAL. The full stage list is REPLACED and re-validated exactly as on create (feature URIs resolved against the retriever's collections). Only allowed on UNPUBLISHED retrievers — a published retriever's stages stay immutable for consumer stability; clone or unpublish to change it."},"input_schema":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/RetrieverInputSchemaField-Input"},"type":"object"},{"type":"null"}],"title":"Input Schema","description":"OPTIONAL. Update the input field definitions — but ONLY as a NON-BREAKING evolution of the current schema, so dependent taxonomies and existing callers keep working. Allowed: add `default`/`examples`/`description` to existing fields (e.g. clickable default queries in Studio), add a new OPTIONAL field. REJECTED (422, with the specific reason): removing a field, changing a field's type, or making a field newly required. For those breaking changes, clone the retriever. The full schema is REPLACED after the non-breaking check passes."}},"additionalProperties":false,"type":"object","title":"PatchRetrieverRequest","description":"Request to update a retriever's metadata.\n\n**IMPORTANT: Partial Updates with Controlled Mutability**\n\nThis endpoint allows updating ONLY metadata fields. Core retriever logic is immutable\nto ensure consistency for dependent resources (taxonomies, cached results, etc.).\n\n**✅ Fields You CAN Update (Metadata Only):**\n- `retriever_name`: Rename the retriever\n- `description`: Update documentation\n- `tags`: Update organization tags\n- `display_config`: Update display configuration for publishing\n\n**✅ Fields You CAN Also Update (With Re-validation):**\n- `collection_identifiers`: Target collections (re-validates feature URIs in stages)\n\n**✅ Fields You CAN Update on UNPUBLISHED retrievers (With Re-validation):**\n- `stages`: Retriever stages/configs. Edit a filter/operator/rerank\n  in place instead of clone+repoint+delete. Re-validated as on create; a\n  PUBLISHED retriever's stages stay immutable (clone/unpublish to change).\n\n**✅ Fields You CAN Update as a NON-BREAKING Evolution:**\n- `input_schema`: Add `default`/`examples`/`description` to existing fields, or\n  add a new OPTIONAL field. Breaking changes — removing a field, changing a\n  field's type, making a field newly required — are rejected with 422 naming\n  each one (dependent taxonomies and existing callers rely on the schema).\n\n**❌ Fields You CANNOT Update (Immutable Core Logic):**\n- `budget_limits`: Budget constraints (affects execution behavior)\n\n**Need a BREAKING Change?**\nUse POST /retrievers/{retriever_id}/clone instead. Cloning creates a new retriever\nwith a new ID, allowing you to:\n- Make breaking input_schema changes (remove a field, change a type,\n  make a field required)\n- Modify budget_limits\n- Edit the stages of a PUBLISHED retriever (as an edited variant)\n\n**Behavior:**\n- All fields are OPTIONAL - provide only what you want to update\n- Version number automatically increments on each update\n- Empty updates (no fields provided) will be rejected with 400 error\n- Original retriever remains unchanged (no destructive operations)\n\n**Why This Design?**\n- Taxonomies reference retrievers by ID and expect consistent behavior\n- Cached results remain valid after metadata-only changes\n- Version tracking enables auditing and rollback\n- Published retrievers maintain stable behavior for consumers","examples":[{"retriever_name":"product_search_v2"},{"description":"Enhanced with better caching","tags":["production","cached"]},{"description":"Latest version with improved performance","retriever_name":"customer_lookup_v3","tags":["production","optimized","v3"]}]},"PatchRetrieverResponse":{"properties":{"retriever":{"$ref":"#/components/schemas/RetrieverConfig","description":"Updated retriever configuration."}},"type":"object","required":["retriever"],"title":"PatchRetrieverResponse","description":"Response after updating a retriever."},"PatchSessionRequest":{"properties":{"user_memory":{"additionalProperties":true,"type":"object","title":"User Memory","description":"Updated user memory (REQUIRED)"}},"type":"object","required":["user_memory"],"title":"PatchSessionRequest","description":"Request payload for updating session metadata.\n\nOnly user_memory can be updated after session creation.\nTo change agent_config or quotas, create a new session.\n\nAttributes:\n    user_memory: Updated user memory/preferences\n\nExample:\n    ```python\n    request = PatchSessionRequest(\n        user_memory={\n            \"preferences\": {\"language\": \"es\", \"domain\": \"science\"},\n            \"learned_context\": {\"favorite_topics\": [\"AI\", \"robotics\"]}\n        }\n    )\n    ```"},"PatchSessionResponse":{"properties":{"session_id":{"type":"string","title":"Session Id","description":"Session identifier"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Update timestamp"}},"type":"object","required":["session_id","updated_at"],"title":"PatchSessionResponse","description":"Response for session update.\n\nAttributes:\n    session_id: Session identifier\n    updated_at: Update timestamp"},"PatchTaxonomyRequest":{"properties":{"taxonomy_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Taxonomy Name","description":"Updated name for the taxonomy"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Updated description for the taxonomy"},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Updated metadata for the taxonomy"}},"type":"object","title":"PatchTaxonomyRequest","description":"Request to update a taxonomy's metadata.\n\n**IMPORTANT: Partial Updates with Controlled Mutability**\n\nThis endpoint allows updating ONLY metadata fields. Core taxonomy logic is immutable\nto ensure consistency for join history and dependent resources.\n\n**✅ Fields You CAN Update (Metadata Only):**\n- `taxonomy_name`: Rename the taxonomy\n- `description`: Update documentation\n- `metadata`: Update custom metadata fields\n\n**❌ Fields You CANNOT Update (Immutable Core Logic):**\n- `config`: Taxonomy configuration (retriever_id, input_mappings, collections, hierarchy)\n- `taxonomy_type`: Type (flat vs hierarchical)\n- `retriever_id`: Associated retriever\n- `input_mappings`: Field mappings\n- `enrichment_fields`: Enrichment configuration\n\n**Need to Modify Core Logic?**\nUse POST /taxonomies/{taxonomy_id}/clone instead. Cloning creates a new taxonomy\nwith a new ID, allowing you to:\n- Change retriever or input mappings\n- Modify enrichment fields\n- Update collection configuration\n- Change taxonomy hierarchy\n\n**Behavior:**\n- All fields are OPTIONAL - provide only what you want to update\n- Empty updates (no fields provided) will be rejected with 400 error\n- Original taxonomy remains unchanged (no destructive operations)\n\n**Why This Design?**\n- Join history is tied to specific taxonomy configuration\n- Changing retriever would invalidate previous joins\n- Version tracking enables auditing and rollback"},"PathAnalysisRequest":{"properties":{"collection_id":{"type":"string","title":"Collection Id","description":"Collection to analyze"},"taxonomy_id":{"type":"string","title":"Taxonomy Id","description":"Taxonomy ID"},"from_step":{"type":"string","title":"From Step","description":"Starting step"},"to_step":{"type":"string","title":"To Step","description":"Ending step"},"max_path_length":{"type":"integer","maximum":20.0,"minimum":2.0,"title":"Max Path Length","description":"Maximum number of steps in a path","default":10},"min_support":{"type":"integer","minimum":1.0,"title":"Min Support","description":"Minimum sequences required to include a path","default":5},"max_window_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Window Days","description":"Maximum duration for path completion (in days)"},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","description":"Optional event filters"}},"type":"object","required":["collection_id","taxonomy_id","from_step","to_step"],"title":"PathAnalysisRequest","description":"API request model for multi-step path analysis.\n\nDiscovers the most common sequences of intermediate steps documents take\nwhen progressing from from_step to to_step.\n\nUnlike the transitions endpoint which only analyzes direct A→B progressions,\nthis endpoint reveals the actual paths taken (e.g., A → X → Y → B).\n\nExample:\n    ```json\n    {\n        \"collection_id\": \"col_emails\",\n        \"taxonomy_id\": \"tax_sales_stages\",\n        \"from_step\": \"inquiry\",\n        \"to_step\": \"closed_won\",\n        \"max_path_length\": 10,\n        \"min_support\": 5\n    }\n    ```\n\nResponse includes:\n    - Most common paths sorted by frequency\n    - Count and percentage for each path\n    - Average duration per path"},"PathAnalysisResponse":{"properties":{"from_step":{"type":"string","title":"From Step"},"to_step":{"type":"string","title":"To Step"},"total_sequences":{"type":"integer","title":"Total Sequences","description":"Total sequences that started at from_step"},"completed_sequences":{"type":"integer","title":"Completed Sequences","description":"Number of sequences that reached to_step"},"completion_rate":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Completion Rate","description":"Percentage that completed the path"},"paths":{"items":{"$ref":"#/components/schemas/TransitionPath"},"type":"array","maxItems":100,"title":"Paths","description":"List of paths sorted by frequency (most common first)"}},"type":"object","required":["from_step","to_step","total_sequences","completed_sequences","completion_rate","paths"],"title":"PathAnalysisResponse","description":"API response model for multi-step path analysis.\n\nContains discovered transition paths with frequency and duration statistics.\n\nExample Response:\n    ```json\n    {\n        \"from_step\": \"inquiry\",\n        \"to_step\": \"closed_won\",\n        \"total_sequences\": 1000,\n        \"completed_sequences\": 350,\n        \"completion_rate\": 0.35,\n        \"paths\": [\n            {\n                \"path\": [\"inquiry\", \"followup\", \"proposal\", \"closed_won\"],\n                \"count\": 120,\n                \"percentage\": 34.3,\n                \"avg_duration_sec\": 604800.0\n            },\n            {\n                \"path\": [\"inquiry\", \"proposal\", \"closed_won\"],\n                \"count\": 90,\n                \"percentage\": 25.7,\n                \"avg_duration_sec\": 432000.0\n            },\n            {\n                \"path\": [\"inquiry\", \"closed_won\"],\n                \"count\": 70,\n                \"percentage\": 20.0,\n                \"avg_duration_sec\": 172800.0\n            }\n        ]\n    }\n    ```"},"PayloadIndexConfig-Input":{"properties":{"field_name":{"type":"string","maxLength":255,"minLength":1,"title":"Field Name","description":"Name of the payload field to index. Must be unique within the namespace. Use dot notation for nested fields (e.g., 'metadata.title'). Cannot use protected system field names when is_protected=False.","examples":["metadata.title","user_id","tags"]},"type":{"$ref":"#/components/schemas/PayloadSchemaType","description":"Data type of the indexed field. Determines query capabilities and storage optimization. TEXT: Full-text search. KEYWORD: Exact matching, filtering. INTEGER/FLOAT: Range queries, sorting. DATETIME: Temporal queries. GEO: geospatial filtering — the geo_radius, geo_bounding_box and geo_polygon operators. Store the point as {lat, lon} or as a [lon, lat] GeoJSON array; a field holding a list of points matches if ANY point matches. NOTE: geo conditions are evaluated by a payload SCAN, not by this index — declaring GEO does not yet accelerate them, so AND a geo condition with a selective non-geo condition on a large collection. BOOL: Boolean filtering. UUID: Unique identifier matching."},"field_schema":{"anyOf":[{"$ref":"#/components/schemas/TextIndexParams"},{"$ref":"#/components/schemas/IntegerIndexParams"},{"$ref":"#/components/schemas/KeywordIndexParams"},{"$ref":"#/components/schemas/FloatIndexParams"},{"$ref":"#/components/schemas/GeoIndexParams"},{"$ref":"#/components/schemas/DatetimeIndexParams"},{"$ref":"#/components/schemas/UuidIndexParams"},{"$ref":"#/components/schemas/BoolIndexParams"},{"type":"null"}],"title":"Field Schema","description":"Optional schema configuration for the index. If not provided, uses default parameters for the specified type. Different types support different parameters (e.g., KeywordIndexParams.is_tenant)."},"is_protected":{"type":"boolean","title":"Is Protected","description":"Whether this index is system-managed and cannot be modified by users. Protected indexes (is_protected=True) are created automatically by Mixpeek and are essential for internal operations like tenant isolation, lineage tracking, and document management. Users cannot create, modify, or delete protected indexes. User-created indexes always have is_protected=False.","default":false}},"type":"object","required":["field_name","type"],"title":"PayloadIndexConfig","description":"Configuration for a payload index.\n\nDefines the structure and behavior of a payload field index in vector store collections.\nPayload indexes enable efficient filtering and searching on document metadata.\n\nProtected Indexes:\n    System-managed indexes (is_protected=True) cannot be modified or deleted by users.\n    These are essential for Mixpeek's internal operations:\n    - internal_id: Tenant isolation\n    - namespace_id: Namespace scoping\n    - collection_id, document_id: Document lineage\n    - bucket_id, object_id, root_object_id, root_bucket_id, source_object_id: Object lineage\n    - created_at, updated_at: Timestamps\n\nUse Cases:\n    - Create custom metadata indexes for efficient filtering\n    - Configure full-text search on text fields\n    - Set up geospatial queries on location data\n    - Enable range queries on numeric fields\n\nRequirements:\n    - field_name: REQUIRED - Must be unique within the namespace\n    - type: REQUIRED - Must match PayloadSchemaType enum\n    - field_schema: OPTIONAL - Auto-generated from type if not provided\n    - is_protected: OPTIONAL - Defaults to False (user-managed index)","examples":[{"description":"User-created text index for full-text search","field_name":"metadata.description","is_protected":false,"type":"text"},{"description":"User-created keyword index for exact filtering","field_name":"user_id","is_protected":false,"type":"keyword"},{"description":"System-managed protected index (created automatically)","field_name":"internal_id","field_schema":{"is_tenant":true},"is_protected":true,"type":"keyword"}]},"PayloadIndexConfig-Output":{"properties":{"field_name":{"type":"string","maxLength":255,"minLength":1,"title":"Field Name","description":"Name of the payload field to index. Must be unique within the namespace. Use dot notation for nested fields (e.g., 'metadata.title'). Cannot use protected system field names when is_protected=False.","examples":["metadata.title","user_id","tags"]},"type":{"$ref":"#/components/schemas/PayloadSchemaType","description":"Data type of the indexed field. Determines query capabilities and storage optimization. TEXT: Full-text search. KEYWORD: Exact matching, filtering. INTEGER/FLOAT: Range queries, sorting. DATETIME: Temporal queries. GEO: geospatial filtering — the geo_radius, geo_bounding_box and geo_polygon operators. Store the point as {lat, lon} or as a [lon, lat] GeoJSON array; a field holding a list of points matches if ANY point matches. NOTE: geo conditions are evaluated by a payload SCAN, not by this index — declaring GEO does not yet accelerate them, so AND a geo condition with a selective non-geo condition on a large collection. BOOL: Boolean filtering. UUID: Unique identifier matching."},"field_schema":{"anyOf":[{"$ref":"#/components/schemas/TextIndexParams"},{"$ref":"#/components/schemas/IntegerIndexParams"},{"$ref":"#/components/schemas/KeywordIndexParams"},{"$ref":"#/components/schemas/FloatIndexParams"},{"$ref":"#/components/schemas/GeoIndexParams"},{"$ref":"#/components/schemas/DatetimeIndexParams"},{"$ref":"#/components/schemas/UuidIndexParams"},{"$ref":"#/components/schemas/BoolIndexParams"},{"type":"null"}],"title":"Field Schema","description":"Optional schema configuration for the index. If not provided, uses default parameters for the specified type. Different types support different parameters (e.g., KeywordIndexParams.is_tenant)."},"is_protected":{"type":"boolean","title":"Is Protected","description":"Whether this index is system-managed and cannot be modified by users. Protected indexes (is_protected=True) are created automatically by Mixpeek and are essential for internal operations like tenant isolation, lineage tracking, and document management. Users cannot create, modify, or delete protected indexes. User-created indexes always have is_protected=False.","default":false}},"type":"object","required":["field_name","type"],"title":"PayloadIndexConfig","description":"Configuration for a payload index.\n\nDefines the structure and behavior of a payload field index in vector store collections.\nPayload indexes enable efficient filtering and searching on document metadata.\n\nProtected Indexes:\n    System-managed indexes (is_protected=True) cannot be modified or deleted by users.\n    These are essential for Mixpeek's internal operations:\n    - internal_id: Tenant isolation\n    - namespace_id: Namespace scoping\n    - collection_id, document_id: Document lineage\n    - bucket_id, object_id, root_object_id, root_bucket_id, source_object_id: Object lineage\n    - created_at, updated_at: Timestamps\n\nUse Cases:\n    - Create custom metadata indexes for efficient filtering\n    - Configure full-text search on text fields\n    - Set up geospatial queries on location data\n    - Enable range queries on numeric fields\n\nRequirements:\n    - field_name: REQUIRED - Must be unique within the namespace\n    - type: REQUIRED - Must match PayloadSchemaType enum\n    - field_schema: OPTIONAL - Auto-generated from type if not provided\n    - is_protected: OPTIONAL - Defaults to False (user-managed index)","examples":[{"description":"User-created text index for full-text search","field_name":"metadata.description","is_protected":false,"type":"text"},{"description":"User-created keyword index for exact filtering","field_name":"user_id","is_protected":false,"type":"keyword"},{"description":"System-managed protected index (created automatically)","field_name":"internal_id","field_schema":{"is_tenant":true},"is_protected":true,"type":"keyword"}]},"PayloadSchemaType":{"type":"string","enum":["keyword","integer","float","bool","geo","datetime","text","uuid"],"title":"PayloadSchemaType","description":"Payload schema type."},"PaymentMethodInfo":{"properties":{"payment_method_id":{"type":"string","title":"Payment Method Id","description":"Stripe PaymentMethod ID"},"type":{"type":"string","title":"Type","description":"Payment method type","examples":["card"]},"card_last4":{"type":"string","title":"Card Last4","description":"Last 4 digits of card","examples":["4242"]},"card_brand":{"type":"string","title":"Card Brand","description":"Card brand","examples":["visa","mastercard","amex"]}},"type":"object","required":["payment_method_id","type","card_last4","card_brand"],"title":"PaymentMethodInfo","description":"Payment method details."},"PerformanceInsight":{"properties":{"type":{"type":"string","title":"Type","description":"Insight type (bottleneck, optimization, warning)"},"severity":{"type":"string","title":"Severity","description":"Severity (info, warning, critical)"},"message":{"type":"string","title":"Message","description":"Human-readable message"},"stage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stage","description":"Related stage name"},"metric_value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Metric Value","description":"Related metric value"},"recommendation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recommendation","description":"Recommended action"}},"type":"object","required":["type","severity","message"],"title":"PerformanceInsight","description":"Performance insight or recommendation."},"PerformanceMetric":{"properties":{"time_bucket":{"type":"string","format":"date-time","title":"Time Bucket","description":"Time bucket for this metric (hour, day, etc.)"},"execution_count":{"type":"integer","title":"Execution Count","description":"Number of executions in this period"},"avg_latency_ms":{"type":"number","title":"Avg Latency Ms","description":"Average latency in milliseconds"},"p50_latency_ms":{"type":"number","title":"P50 Latency Ms","description":"50th percentile (median) latency"},"p95_latency_ms":{"type":"number","title":"P95 Latency Ms","description":"95th percentile latency"},"p99_latency_ms":{"type":"number","title":"P99 Latency Ms","description":"99th percentile latency"},"max_latency_ms":{"type":"number","title":"Max Latency Ms","description":"Maximum latency observed"}},"type":"object","required":["time_bucket","execution_count","avg_latency_ms","p50_latency_ms","p95_latency_ms","p99_latency_ms","max_latency_ms"],"title":"PerformanceMetric","description":"Single performance metric data point."},"PerformanceSummary":{"properties":{"total_executions":{"type":"integer","title":"Total Executions","description":"Total number of executions","default":0},"avg_latency_ms":{"type":"number","title":"Avg Latency Ms","description":"Average latency","default":0.0},"p50_latency_ms":{"type":"number","title":"P50 Latency Ms","description":"Median latency","default":0.0},"p95_latency_ms":{"type":"number","title":"P95 Latency Ms","description":"95th percentile latency","default":0.0},"p99_latency_ms":{"type":"number","title":"P99 Latency Ms","description":"99th percentile latency","default":0.0},"max_latency_ms":{"type":"number","title":"Max Latency Ms","description":"Maximum latency","default":0.0},"total_time_seconds":{"type":"number","title":"Total Time Seconds","description":"Total time spent across all executions","default":0.0}},"type":"object","title":"PerformanceSummary","description":"Summary statistics for performance."},"Permission":{"type":"string","enum":["read","write","delete","admin"],"title":"Permission","description":"Simplified API key permissions.\n\nThis four-value enum replaces the legacy 16-permission model. Keep usage\nsimple: prefer the least privileged option that satisfies the workflow.\n\nHierarchy (strongest -> weakest): ADMIN > DELETE > WRITE > READ."},"PipelineComparison":{"properties":{"candidate_retriever_id":{"type":"string","title":"Candidate Retriever Id","description":"ID of the candidate pipeline."},"ndcg_delta":{"additionalProperties":{"type":"number"},"type":"object","title":"Ndcg Delta","description":"Change in NDCG at each K (positive = candidate better)."},"recall_delta":{"additionalProperties":{"type":"number"},"type":"object","title":"Recall Delta","description":"Change in recall at each K (positive = candidate better)."},"latency_delta_ms":{"type":"number","title":"Latency Delta Ms","description":"Change in mean latency (positive = candidate slower)."},"p_value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P Value","description":"Statistical significance of the difference (paired t-test)."},"confidence_interval":{"anyOf":[{"prefixItems":[{"type":"number"},{"type":"number"}],"type":"array","maxItems":2,"minItems":2},{"type":"null"}],"title":"Confidence Interval","description":"95% confidence interval for NDCG@10 delta."},"taxonomy_wins":{"items":{"type":"string"},"type":"array","title":"Taxonomy Wins","description":"Taxonomy nodes where candidate significantly outperforms."},"taxonomy_losses":{"items":{"type":"string"},"type":"array","title":"Taxonomy Losses","description":"Taxonomy nodes where candidate significantly underperforms."}},"type":"object","required":["candidate_retriever_id","ndcg_delta","recall_delta","latency_delta_ms"],"title":"PipelineComparison","description":"Statistical comparison between a candidate and baseline pipeline."},"PlanDefinitionResponse":{"properties":{"product":{"type":"string","title":"Product","description":"Product line this plan belongs to"},"tier":{"type":"string","title":"Tier","description":"Tier identifier (free, build, scale, ...)"},"name":{"type":"string","title":"Name","description":"Human-readable plan name"},"monthly_price_cents":{"type":"integer","title":"Monthly Price Cents","description":"Flat recurring monthly fee in cents. Metered usage is billed on top of it; on plans with a usage_pool_usd, only usage beyond that pool is billed."},"self_serve":{"type":"boolean","title":"Self Serve","description":"True when the plan can be bought without sales contact"},"features":{"items":{"type":"string"},"type":"array","title":"Features","description":"Feature flags enabled on this plan"},"included_credits":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Included Credits","description":"Prepaid credit entitlement in v1 semantics (1 credit = $0.001). This is NOT the metered usage allowance; read usage_pool_usd for that. See included_credits_semantics, which states the same thing in the payload so no caller has to infer it."},"included_credits_semantics":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Included Credits Semantics","description":"The server's own statement of what included_credits means, carried in the response so a renderer cannot disagree with the rate card."},"usage_pool_usd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Usage Pool Usd","description":"The plan's included METERED usage allowance, in USD. This is the figure to render as 'included', and it is smaller than included_credits converted at the credit rate."},"overage_rate_usd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Overage Rate Usd","description":"USD charged per credit beyond the allowance"},"overage_discount_pct":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Overage Discount Pct","description":"Discount applied to overage, as a percentage"},"volume_discounts":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Volume Discounts","description":"Spend thresholds mapped to their discount"},"resource_limits":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Resource Limits","description":"Per-plan ceilings on namespaces, collections, buckets, retrievers, webhooks, documents, batches, storage and objects"},"rate_limits":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Rate Limits","description":"Per-plan requests-per-minute ceilings by request class"},"mvs_limits":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Mvs Limits","description":"Vector-store ceilings, present on MVS plans only"}},"additionalProperties":true,"type":"object","required":["product","tier","name","monthly_price_cents","self_serve"],"title":"PlanDefinitionResponse","description":"One plan from the public rate card.\n\nDECLARED, not `dict`, on purpose. `managed_plans` and `mvs_plans` were\n`list[dict]`, so not one plan field reached server/openapi.json and codegen\nemitted no type for them. Studio then hand-declared the shape locally\n(`ApiManagedPlan` in PlanCard.tsx), which is the failure class this repo\nalready names: a hand-written mirror compiles forever and renders nothing\nthe day the server's shape moves.\n\nThe field set is the measured union of `PlanDefinition.to_dict()` across\nevery plan in MANAGED_PLANS and MVS_PLANS, not a guess. `extra=\"allow\"`\nkeeps that safe: FastAPI filters a response to the declared fields, so a\nkey added to `to_dict()` without a field here would VANISH from the live\npayload. Allowing extras makes this model additive rather than a gate."},"PlanUsage":{"properties":{"product":{"type":"string","title":"Product","examples":["managed"]},"tier":{"type":"string","title":"Tier","examples":["build"]},"plan_name":{"type":"string","title":"Plan Name","examples":["Build"]},"monthly_minimum_cents":{"type":"integer","title":"Monthly Minimum Cents","examples":[2500]},"period_start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Period Start"},"period_end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Period End"},"objects_processed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Objects Processed","examples":[41230]},"object_cap":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Object Cap","examples":[100000]},"vectors_stored":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Vectors Stored","description":"Documents stored across the organization's namespaces: each namespace's own documents, counted exactly by the vector store. This is the same number the invoice bills as documents stored. The field keeps its historical name; its unit is documents, not index vectors.","examples":[41230]},"vectors_stored_complete":{"type":"boolean","title":"Vectors Stored Complete","description":"Whether `vectors_stored` counted every namespace. The total is the sum of each namespace's live count, and a namespace whose count does not finish in time contributes 0 rather than failing the request. When this is false the total is a FLOOR: real usage is higher, so `usage_pct` and `cap_state` are under-reported and a plan at its cap can read as ok. Retrying usually resolves it, since the slow count is cached only briefly.","default":true,"examples":[true]},"vector_cap":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Vector Cap"},"usage_pct":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Usage Pct","description":"Percent of the relevant cap consumed.","examples":[41.2]},"cap_state":{"type":"string","title":"Cap State","default":"ok","examples":["ok","warning","exceeded"]}},"type":"object","required":["product","tier","plan_name","monthly_minimum_cents"],"title":"PlanUsage","description":"Tier usage vs caps (2026-07 overhaul) — powers the billing page's\nusage bar and the 80% upgrade CTA. Managed plans report objects; MVS\nplans report vectors; the irrelevant pair is null. cap_state: ok |\nwarning (>=80%) | exceeded (>=100%; further ingest is rejected with\ntype=QuotaExceededError — reads keep working)."},"PostProcessingPhase":{"type":"integer","enum":[1,2,3,4],"title":"PostProcessingPhase","description":"Execution phases for post-processing applications.\n\nApplications execute in phase order (lower = earlier).\nWithin a phase, applications execute by priority (higher = earlier).\n\nPhases:\n    TAXONOMY (1): Classification and labeling operations\n    CLUSTER (2): Grouping and clustering operations\n    ALERT (3): Notifications and alerts (default for alerts)\n    RETRIEVER_ENRICHMENT (4): Retriever-based enrichment operations\n\nThe default phase for each application type:\n    - TaxonomyApplicationConfig: TAXONOMY\n    - ClusterApplicationConfig: CLUSTER\n    - AlertApplicationConfig: ALERT\n    - RetrieverEnrichmentConfig: RETRIEVER_ENRICHMENT\n\nUsers can override the phase via the `execution_phase` field to run\napplications in non-default order. For example, an alert can be configured\nto run in Phase 1 alongside taxonomies if early notification is needed.\n\nExample:\n    # Default: Alert runs after taxonomies and clusters\n    AlertApplicationConfig(alert_id=\"alt_123\", execution_phase=PostProcessingPhase.ALERT)\n\n    # Override: Run alert early, in taxonomy phase\n    AlertApplicationConfig(alert_id=\"alt_urgent\", execution_phase=PostProcessingPhase.TAXONOMY)"},"PostgreSQLConfig":{"properties":{"provider_type":{"type":"string","const":"postgresql","title":"Provider Type","default":"postgresql"},"credentials":{"$ref":"#/components/schemas/PostgreSQLCredentials","description":"REQUIRED. PostgreSQL authentication credentials. Currently supports username/password authentication."},"host":{"type":"string","title":"Host","description":"REQUIRED. PostgreSQL server hostname or IP address. Examples: 'localhost', 'db.example.com', '192.168.1.100'","examples":["localhost","db.example.com","192.168.1.100"]},"port":{"type":"integer","maximum":65535.0,"minimum":1.0,"title":"Port","description":"PostgreSQL server port. Default: 5432 (standard PostgreSQL port)","default":5432},"database":{"type":"string","title":"Database","description":"REQUIRED. Database name to connect to. User must have CONNECT privilege on this database.","examples":["production","analytics","customer_data"]},"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Schema","description":"Schema name for default context. Default: 'public'. User must have USAGE privilege on this schema.","default":"public","examples":["public","raw_data","transformed"]},"ssl_mode":{"type":"string","title":"Ssl Mode","description":"SSL/TLS connection mode. Options: 'disable', 'allow', 'prefer', 'require', 'verify-ca', 'verify-full'. Default: 'prefer'. RECOMMENDED: Use 'require' or stricter for production environments.","default":"prefer","examples":["disable","prefer","require","verify-full"]},"incremental_column":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Incremental Column","description":"NOT REQUIRED. Column name for incremental sync watermark. Should be a TIMESTAMP or DATE column that tracks row modifications. Common values: updated_at, modified_at, last_updated. If omitted, full table scan on every sync.","examples":["updated_at","modified_at","last_updated"]},"primary_key_columns":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Primary Key Columns","description":"NOT REQUIRED. Column names forming the primary key for stable object IDs. Used to generate deterministic file_id for deduplication. If omitted, uses hash of entire row content.","examples":[["id"],["user_id","timestamp"],["customer_id","order_id"]]},"query_timeout_seconds":{"type":"integer","maximum":3600.0,"minimum":1.0,"title":"Query Timeout Seconds","description":"Query timeout in seconds. Default: 300 seconds (5 minutes). Increase for large tables or complex queries.","default":300},"fetch_size":{"type":"integer","maximum":10000.0,"minimum":100.0,"title":"Fetch Size","description":"Number of rows to fetch per batch. Higher values reduce network overhead but increase memory usage. Default: 1000 rows.","default":1000}},"type":"object","required":["credentials","host","database"],"title":"PostgreSQLConfig","description":"PostgreSQL database configuration for table-based sync and SQL queries.\n\nEnables syncing PostgreSQL table rows as JSON objects and running SQL queries\nvia the SQL Lookup retriever stage. Each row becomes one object, with\nincremental sync via watermark columns.\n\nAuthentication:\n    - Username/Password: Standard PostgreSQL authentication\n\nRequirements:\n    - PostgreSQL 12+ recommended\n    - Read access to target tables\n    - Network connectivity to PostgreSQL server\n\nUse Cases:\n    - Sync customer data tables for AI/ML pipelines\n    - Run SQL lookups to enrich documents in retriever pipelines\n    - Ingest product catalog for search/recommendations\n    - Process transaction logs for analytics\n\nExample:\n    ```python\n    config = {\n        \"provider_type\": \"postgresql\",\n        \"credentials\": {\n            \"type\": \"username_password\",\n            \"username\": \"mixpeek_sync\",\n            \"password\": \"secure_password\",\n        },\n        \"host\": \"db.example.com\",\n        \"port\": 5432,\n        \"database\": \"production\",\n        \"schema\": \"public\",\n        \"ssl_mode\": \"require\",\n    }\n    ```","examples":[{"credentials":{"password":"dev_password","type":"username_password","username":"mixpeek_user"},"database":"mixpeek_test","description":"Local PostgreSQL development setup","host":"localhost","port":5432,"provider_type":"postgresql","schema":"public","ssl_mode":"disable"},{"credentials":{"password":"secure_password_here","type":"username_password","username":"mixpeek_sync"},"database":"production","description":"Production PostgreSQL with SSL and incremental sync","host":"db.example.com","incremental_column":"updated_at","port":5432,"primary_key_columns":["id"],"provider_type":"postgresql","schema":"public","ssl_mode":"require"}]},"PostgreSQLCredentials":{"properties":{"type":{"type":"string","const":"username_password","title":"Type","default":"username_password"},"username":{"type":"string","title":"Username","description":"REQUIRED. PostgreSQL username for authentication.","examples":["mixpeek_sync","readonly_user"]},"password":{"type":"string","title":"Password","description":"REQUIRED. PostgreSQL password for authentication. SECURITY: This is a secret credential, redacted on read. Never log or expose."}},"type":"object","required":["username","password"],"title":"PostgreSQLCredentials","description":"PostgreSQL username/password authentication.\n\nStandard username/password authentication for PostgreSQL databases.\n\nSecurity:\n    - password is a secret credential, redacted on read\n    - Consider using SSL mode 'require' for production\n    - Use dedicated read-only database user for sync operations"},"PredictorLift":{"properties":{"field":{"type":"string","title":"Field","description":"Covariate field name"},"value":{"type":"string","title":"Value","description":"Specific value or bin label"},"count":{"type":"integer","minimum":0.0,"title":"Count","description":"Number of sequences with this value"},"conversion_rate":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Conversion Rate","description":"Conversion rate for this value"},"lift":{"type":"number","title":"Lift","description":"Lift relative to baseline (>1.0 = positive, <1.0 = negative)"}},"type":"object","required":["field","value","count","conversion_rate","lift"],"title":"PredictorLift","description":"Lift calculation for a specific covariate value.\n\nLift measures how much a specific value increases/decreases conversion likelihood\ncompared to the baseline. Lift > 1.0 means the value helps conversion.\n\nAttributes:\n    field: Name of the covariate (e.g., \"Sender Domain\", \"Word Count Q3\")\n    value: Specific value or bin (e.g., \"gmail.com\", \"Q3\")\n    count: Number of sequences with this value\n    conversion_rate: Conversion rate for this value (0.0 to 1.0)\n    lift: Conversion rate / baseline rate (1.0 = no effect, >1.0 = positive, <1.0 = negative)\n\nExample:\n    ```python\n    # Sender domain \"enterprise.com\" has 2.5x baseline conversion\n    PredictorLift(\n        field=\"Sender Domain\",\n        value=\"enterprise.com\",\n        count=150,\n        conversion_rate=0.75,  # 75% conversion\n        lift=2.5  # 2.5x the baseline rate\n    )\n    ```\n\nInterpretation:\n    - lift = 1.5: This value increases conversion by 50%\n    - lift = 1.0: No effect on conversion\n    - lift = 0.5: This value decreases conversion by 50%"},"PricingConfigResponse":{"properties":{"credit_rate_usd":{"type":"number","title":"Credit Rate Usd","description":"USD cost per credit (e.g. 0.001 = $0.001/credit)"},"managed_plans":{"items":{"$ref":"#/components/schemas/PlanDefinitionResponse"},"type":"array","title":"Managed Plans","description":"Managed Mixpeek plans (Free/Pro/Team/Enterprise)"},"mvs_plans":{"items":{"$ref":"#/components/schemas/PlanDefinitionResponse"},"type":"array","title":"Mvs Plans","description":"MVS standalone plans (Free/Pro/Business/Enterprise)"},"mvs_usage_rates":{"additionalProperties":true,"type":"object","title":"Mvs Usage Rates","description":"MVS per-unit usage rates (storage, queries, writes)"},"enterprise_defaults":{"additionalProperties":true,"type":"object","title":"Enterprise Defaults","description":"Default enterprise/tenant billing parameters"},"extractors":{"items":{"$ref":"#/components/schemas/ExtractorPricing"},"type":"array","title":"Extractors","description":"All available extractors with their cost rates. DEPRECATED for display: v2 surfaces render `v2.modalities` features instead (D9 — extractors are internal implementation)."},"pricing_model":{"type":"string","title":"Pricing Model","description":"Pricing model discriminator (v2 = modality+features)","default":"v2"},"currency":{"type":"string","title":"Currency","default":"usd"},"placeholder_rates":{"type":"boolean","title":"Placeholder Rates","description":"True only pre-cutover; consumers must not render dollars while true (contract §5 display gate).","default":false},"modalities":{"items":{},"type":"array","title":"Modalities","description":"Per file type (modality): its billing unit, base rate, and the search-by features you can add (D9: the public vocabulary — render these, never extractors)."},"usage_pools":{"additionalProperties":true,"type":"object","title":"Usage Pools","description":"Tier usage pools (dollar-denominated, natural-unit equivalents)"},"reads":{"additionalProperties":true,"type":"object","title":"Reads"},"full_res_multiplier":{"type":"number","title":"Full Res Multiplier","default":2.0}},"type":"object","required":["credit_rate_usd","managed_plans","mvs_plans","mvs_usage_rates","enterprise_defaults","extractors"],"title":"PricingConfigResponse"},"PromoteNamespaceRequestModel":{"properties":{"vector_mappings":{"items":{"$ref":"#/components/schemas/VectorMappingModel"},"type":"array","title":"Vector Mappings","description":"Map existing vector indexes to inference services"},"add_vectors":{"items":{"$ref":"#/components/schemas/NewVectorConfigSpecModel"},"type":"array","title":"Add Vectors","description":"New vector indexes to add during promotion"}},"type":"object","title":"PromoteNamespaceRequestModel"},"PromoteNamespaceResponseModel":{"properties":{"namespace_id":{"type":"string","title":"Namespace Id"},"previous_mode":{"type":"string","title":"Previous Mode"},"mode":{"type":"string","title":"Mode"},"status":{"type":"string","title":"Status"},"vector_configs":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Vector Configs"},"vector_inference_map":{"additionalProperties":{"type":"string"},"type":"object","title":"Vector Inference Map"}},"type":"object","required":["namespace_id","previous_mode","mode","status"],"title":"PromoteNamespaceResponseModel"},"PromoteResponse":{"properties":{"app_id":{"type":"string","title":"App Id"},"version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Version"},"deploy_id":{"type":"string","title":"Deploy Id"},"environment":{"type":"string","title":"Environment","default":"production"},"asset_prefix":{"type":"string","title":"Asset Prefix"}},"type":"object","required":["app_id","deploy_id","asset_prefix"],"title":"PromoteResponse","description":"Response after promoting staging to production."},"PromoteValidateResponseModel":{"properties":{"namespace_id":{"type":"string","title":"Namespace Id"},"current_mode":{"type":"string","title":"Current Mode"},"valid":{"type":"boolean","title":"Valid"},"vector_configs":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Vector Configs"},"suggestions":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Suggestions"},"errors":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Errors"},"required_user_action":{"type":"string","title":"Required User Action"}},"type":"object","required":["namespace_id","current_mode","valid","required_user_action"],"title":"PromoteValidateResponseModel"},"PromotedNode":{"properties":{"node_document_id":{"type":"string","title":"Node Document Id"},"node_label":{"type":"string","title":"Node Label"},"cluster_id":{"type":"string","title":"Cluster Id"},"member_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Member Count"}},"type":"object","required":["node_document_id","node_label","cluster_id"],"title":"PromotedNode","description":"One taxonomy node created from a cluster run."},"PublicAppConfigResponse":{"properties":{"slug":{"type":"string","title":"Slug"},"template":{"type":"string","title":"Template"},"sections":{"items":{"$ref":"#/components/schemas/SectionConfig"},"type":"array","title":"Sections"},"custom_html":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Html"},"bundle_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bundle Url","description":"URL of the deployed bundle index.html (set when app is deployed via CLI upload)."},"meta":{"$ref":"#/components/schemas/PageMeta"},"hero":{"anyOf":[{"$ref":"#/components/schemas/HeroConfig"},{"type":"null"}]},"theme":{"$ref":"#/components/schemas/ThemeConfig"},"seo":{"anyOf":[{"$ref":"#/components/schemas/SEOConfig"},{"type":"null"}]},"stats":{"items":{"$ref":"#/components/schemas/StatItem"},"type":"array","title":"Stats"},"featured_gallery":{"anyOf":[{"$ref":"#/components/schemas/FeaturedGalleryConfig-Output"},{"type":"null"}]},"tabs":{"items":{"$ref":"#/components/schemas/PageTab-Output"},"type":"array","title":"Tabs"},"is_active":{"type":"boolean","title":"Is Active"},"password_protected":{"type":"boolean","title":"Password Protected"}},"type":"object","required":["slug","template","meta","hero","theme","seo","stats","featured_gallery","tabs","is_active","password_protected"],"title":"PublicAppConfigResponse","description":"Public app configuration (strips internal fields).\n\nReturned by GET /v1/public/apps/{slug}/config — used by the canvas/\nhost runtime and the @mixpeek/canvas-sdk useApp() hook."},"PublicAppSearchRequest":{"properties":{"tab_id":{"type":"string","title":"Tab Id","description":"Tab ID to search within"},"inputs":{"additionalProperties":true,"type":"object","title":"Inputs"},"settings":{"additionalProperties":true,"type":"object","title":"Settings"}},"additionalProperties":true,"type":"object","required":["tab_id"],"title":"PublicAppSearchRequest","description":"Request to execute a search on a specific tab of an App.\n\nExtra top-level fields are merged into ``inputs`` automatically so\ncallers can pass retriever inputs without extra nesting."},"PublicExtractorDetailResponse":{"properties":{"public_name":{"type":"string","title":"Public Name"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"publisher_organization_name":{"type":"string","title":"Publisher Organization Name"},"version":{"type":"string","title":"Version"},"trust_tier":{"$ref":"#/components/schemas/TrustTier"},"capabilities":{"items":{"$ref":"#/components/schemas/ExtractorCapability"},"type":"array","title":"Capabilities"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"icon_base64":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Icon Base64"},"manifest":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Manifest"},"model_dependencies":{"items":{"$ref":"#/components/schemas/ModelDependency"},"type":"array","title":"Model Dependencies"},"readme_markdown":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Readme Markdown"},"code_hash":{"type":"string","title":"Code Hash"},"install_count":{"type":"integer","title":"Install Count","default":0},"presigned_download_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Presigned Download Url"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["public_name","publisher_organization_name","version","trust_tier","code_hash","created_at","updated_at"],"title":"PublicExtractorDetailResponse"},"PublicExtractorListItem":{"properties":{"public_name":{"type":"string","title":"Public Name"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"publisher_organization_name":{"type":"string","title":"Publisher Organization Name"},"version":{"type":"string","title":"Version"},"trust_tier":{"$ref":"#/components/schemas/TrustTier"},"capabilities":{"items":{"$ref":"#/components/schemas/ExtractorCapability"},"type":"array","title":"Capabilities"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"icon_base64":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Icon Base64"},"install_count":{"type":"integer","title":"Install Count","default":0},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["public_name","publisher_organization_name","version","trust_tier","created_at","updated_at"],"title":"PublicExtractorListItem"},"PublicInteractionBatchRequest":{"properties":{"interactions":{"items":{"$ref":"#/components/schemas/PublicInteractionRequest"},"type":"array","maxItems":100,"minItems":1,"title":"Interactions","description":"List of interactions to track (max 100 per batch)"}},"type":"object","required":["interactions"],"title":"PublicInteractionBatchRequest","description":"Request to track multiple interactions in batch."},"PublicInteractionRequest":{"properties":{"document_id":{"type":"string","title":"Document Id","description":"ID of the document that was interacted with (from search results)","examples":["doc_abc123","prod_xyz789"]},"interaction_type":{"items":{"$ref":"#/components/schemas/InteractionType"},"type":"array","minItems":1,"title":"Interaction Type","description":"Type(s) of interaction that occurred","examples":[["click"],["view","click"],["positive_feedback"]]},"position":{"type":"integer","minimum":0.0,"title":"Position","description":"Position in search results (0-indexed)","examples":[0,1,5,15]},"execution_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Execution Id","description":"REQUIRED. ID of the retriever execution that generated these results, as returned by the search. An interaction without it is refused (422).","examples":["exec_abc123xyz"]},"query_snapshot":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Query Snapshot","description":"Snapshot of the query that generated these results. HIGHLY RECOMMENDED for training optimization.","examples":[{"text":"wireless headphones"},{"filters":{"price":{"lte":1000}},"text":"laptop"}]},"document_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Document Score","description":"Initial retrieval score of this document","examples":[0.95,0.87,0.62]},"result_set_size":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Result Set Size","description":"Total number of results shown","examples":[10,20,50]},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id","description":"Session identifier for tracking user journey","examples":["sess_abc123"]},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Additional context about the interaction"}},"type":"object","required":["document_id","interaction_type","position"],"title":"PublicInteractionRequest","description":"Request to track a single interaction from public retriever.\n\nSimplified wrapper around SearchInteraction for public API use."},"PublicNameAvailabilityResponse":{"properties":{"name":{"type":"string","title":"Name","description":"The public name that was checked"},"available":{"type":"boolean","title":"Available","description":"Whether the name is available for use"}},"type":"object","required":["name","available"],"title":"PublicNameAvailabilityResponse","description":"Response for public name availability check."},"PublicRetrieverConfigResponse":{"properties":{"public_name":{"type":"string","title":"Public Name","description":"Public name of the retriever"},"public_api_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Public Api Key","description":"DEPRECATED: API keys are no longer required for public access. The execute endpoint can be called without authentication."},"display_config":{"$ref":"#/components/schemas/DisplayConfig-Output","description":"Display configuration for rendering the UI. Includes inputs, theme, layout, and exposed fields."},"password_protected":{"type":"boolean","title":"Password Protected","description":"Whether this retriever requires password authentication"},"retriever_metadata":{"anyOf":[{"$ref":"#/components/schemas/RetrieverMetadata"},{"type":"null"}],"description":"OPTIONAL. Technical metadata about how the retriever works. Only present if include_metadata=True was set during publishing."}},"type":"object","required":["public_name","display_config","password_protected"],"title":"PublicRetrieverConfigResponse","description":"Response for fetching public retriever configuration (for UI rendering).\n\nThis is what the public frontend (mxp.co/r/{name}) fetches to render\nthe search interface. It includes everything needed for UI rendering.\n\nNote: API keys are no longer required. The execute endpoint can be called\nwithout authentication - rate limiting and optional password protection\nprovide security."},"PublicRetrieverListItem":{"properties":{"public_name":{"type":"string","title":"Public Name","description":"Public URL-safe name used in the public URL"},"public_url":{"type":"string","title":"Public Url","description":"Full public URL to the retriever page","examples":["https://mxp.co/r/video-search"]},"title":{"type":"string","title":"Title","description":"Display title from display_config","examples":["Video Search","Product Catalog"]},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Display description from display_config"},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url","description":"Logo URL from display_config"},"icon_base64":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Icon Base64","description":"Base64 encoded icon/favicon from display_config"},"og_image_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Og Image Url","description":"Social preview/OG image URL from display_config"},"password_protected":{"type":"boolean","title":"Password Protected","description":"Whether password authentication is required"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether the retriever is active"},"external_links":{"items":{"$ref":"#/components/schemas/ExternalLink"},"type":"array","title":"External Links","description":"External resource links (GitHub, blog posts, docs, etc.)"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"When the retriever was published"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"When the retriever was last updated"}},"type":"object","required":["public_name","public_url","title","password_protected","is_active","created_at","updated_at"],"title":"PublicRetrieverListItem","description":"Simplified retriever information for public listing.\n\nProvides essential details for browsing public retrievers without\nexposing sensitive configuration or credentials."},"PublicRetrieverListStats":{"properties":{"total_active":{"type":"integer","title":"Total Active","description":"Number of active public retrievers","default":0},"total_password_protected":{"type":"integer","title":"Total Password Protected","description":"Number of password-protected retrievers","default":0},"total_open":{"type":"integer","title":"Total Open","description":"Number of fully open (no password) retrievers","default":0}},"type":"object","title":"PublicRetrieverListStats","description":"Aggregate statistics for public retrievers list."},"PublicRetrieverTemplateResponse":{"properties":{"retriever_name":{"type":"string","title":"Retriever Name","description":"Original retriever name (you'll change this when creating your own). Provided as reference.","examples":["video-search-example","product-catalog-demo"]},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Original retriever description (you can use or modify this). Provides context about what this retriever does."},"collection_identifiers":{"items":{"type":"string"},"type":"array","title":"Collection Identifiers","description":"IMPORTANT: These are the original collections. You MUST replace these with your own collection identifiers when creating a retriever from this template.","examples":[["public_videos"],["demo_products","demo_images"]]},"stages":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Stages","description":"Pipeline stages configuration. You can use as-is or modify for your needs. This is the core retrieval logic."},"input_schema":{"additionalProperties":{"$ref":"#/components/schemas/RetrieverInputSchemaField-Output","description":"Schema definition for this input field. Defines type, description, examples, and validation rules. Supports all bucket types (string, number, image, etc.) plus document_reference. Frontend uses this to render the appropriate input component (text input, image upload, dropdown, etc.)"},"type":"object","title":"Input Schema","description":"Input schema defining expected inputs. If you change the input field names, make sure to update references in stages (e.g., {{inputs.query}})."},"budget_limits":{"additionalProperties":true,"type":"object","title":"Budget Limits","description":"Budget limits for execution. You can adjust these based on your needs."},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Original tags (optional, for reference)"},"display_config":{"anyOf":[{"$ref":"#/components/schemas/DisplayConfig-Output"},{"type":"null"}],"description":"OPTIONAL: Display configuration used for the public interface. Include this if you plan to publish your retriever and want to use a similar UI design. Otherwise, you can omit it."},"source_public_name":{"type":"string","title":"Source Public Name","description":"Public name of the source retriever (for reference)","examples":["video-search","product-catalog"]},"source_public_url":{"type":"string","title":"Source Public Url","description":"Public URL of the source retriever (to view it in action)","examples":["https://mxp.co/r/video-search"]},"feature_extractors":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Feature Extractors","description":"Feature extractors from all collections used by this retriever. Each extractor includes: feature_extractor_name, version, params, input_mappings, collection_id, and collection_name for reference. Shows how each collection processes data into searchable features."}},"type":"object","required":["retriever_name","collection_identifiers","stages","input_schema","budget_limits","source_public_name","source_public_url"],"title":"PublicRetrieverTemplateResponse","description":"Response containing public retriever configuration as a reusable template.\n\nThis returns the retriever's configuration in a format that can be directly\nused in a CreateRetrieverRequest. Users can copy this config, modify it for\ntheir needs (e.g., change collection_identifiers), and create their own retriever.\n\nUse Case:\n    1. Browse public retrievers to find patterns you like\n    2. GET /public/retrievers/{public_name}/template to get the config\n    3. Modify collection_identifiers and other fields as needed\n    4. POST /retrievers to create your own retriever with this config\n    5. Optionally POST /retrievers/{id}/publish to publish it similarly","examples":[{"budget_limits":{"max_credits":10.0,"max_time_ms":30000},"collection_identifiers":["demo_videos"],"description":"AI-powered video search using semantic understanding","display_config":{"components":{"result_layout":"grid","show_search":true},"description":"Search through video content","exposed_fields":["title","thumbnail_url","duration"],"inputs":[{"field_name":"query","field_schema":{"type":"text"},"label":"Search Videos","order":0,"placeholder":"Describe what you're looking for...","required":true}],"title":"Video Search"},"input_schema":{"query":{"description":"Search query","examples":["action scenes","romantic moments"],"required":true,"type":"text"}},"retriever_name":"video-search-demo","source_public_name":"video-search","source_public_url":"https://mxp.co/r/video-search","stages":[{"config":{"parameters":{"final_top_k":25,"searches":[{"feature_uri":"mixpeek://text_extractor@v1/embedding","query":{"input_mode":"text","text":"{{inputs.query}}"},"top_k":100}]},"stage_id":"feature_search"},"stage_name":"semantic_search","stage_type":"filter"}],"tags":["video","semantic-search","demo"]}]},"PublishAppRequest":{"properties":{"message":{"type":"string","title":"Message","description":"Publish message describing what changed (required, like a git commit message)"}},"type":"object","required":["message"],"title":"PublishAppRequest","description":"Body for publish — message is required (like a git commit message)."},"PublishExtractorRequest":{"properties":{"public_name":{"anyOf":[{"type":"string","maxLength":50,"minLength":3,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},{"type":"null"}],"title":"Public Name","description":"URL-safe slug. Auto-generated from display_name if not provided."},"display_name":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Display Name"},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description"},"icon_base64":{"anyOf":[{"type":"string","maxLength":300000},{"type":"null"}],"title":"Icon Base64"},"readme_markdown":{"anyOf":[{"type":"string","maxLength":50000},{"type":"null"}],"title":"Readme Markdown"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags"},"category":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Category"},"model_dependencies":{"items":{"$ref":"#/components/schemas/ModelDependency"},"type":"array","title":"Model Dependencies"}},"type":"object","title":"PublishExtractorRequest"},"PublishExtractorResponse":{"properties":{"public_id":{"type":"string","title":"Public Id"},"extractor_id":{"type":"string","title":"Extractor Id"},"public_name":{"type":"string","title":"Public Name"},"public_url":{"type":"string","title":"Public Url"}},"type":"object","required":["public_id","extractor_id","public_name","public_url"],"title":"PublishExtractorResponse"},"PublishRetrieverRequest":{"properties":{"display_name":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Display Name","description":"Human-readable display name for this retriever (free-form text). Example: 'Peptide Evidence Search'. A URL-safe slug is auto-generated from this if `public_name` is not provided.","examples":["Peptide Evidence Search","Product Catalog","Video Library"]},"public_name":{"anyOf":[{"type":"string","maxLength":50,"minLength":3,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},{"type":"null"}],"title":"Public Name","description":"URL-safe slug (lowercase letters, digits, hyphens only). Must start and end with an alphanumeric character. Example: 'peptide-evidence-search'. Used in the public URL: mxp.co/r/{public_name}. Auto-generated from `display_name` if not provided.","examples":["video-search","product-catalog","creative-assets"]},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description","description":"Description of this public retriever. Explains what the retriever does and what it searches. Displayed in public listings and search results.","examples":["AI-powered video search using semantic understanding","Search through product catalog with visual similarity"]},"icon_base64":{"anyOf":[{"type":"string","maxLength":300000},{"type":"null"}],"title":"Icon Base64","description":"Base64 encoded icon/favicon for this public retriever. Data URI format recommended. Max size: ~200KB encoded. Displayed in public listings and as the retriever's icon.","examples":["data:image/png;base64,iVBORw0KGgoAAAANS..."]},"display_config":{"anyOf":[{"$ref":"#/components/schemas/DisplayConfig-Input"},{"type":"null"}],"description":"Display configuration defining how the public UI should be rendered. Includes input fields, theme, layout, and exposed result fields. If not provided, uses the retriever's stored display_config."},"rate_limit_config":{"$ref":"#/components/schemas/RateLimitConfig","description":"Rate limiting configuration for public endpoint. Defaults to STANDARD tier (10/min, 100/hour, 1k/day). Use ELEVATED tier for trusted public apps (30/min, 500/hour, 5k/day). Use ENTERPRISE tier for monitored deployments (100/min, 2k/hour, 20k/day). Custom limits override tier defaults."},"password_secret_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Password Secret Name","description":"OPTIONAL. Name of organization secret containing password for access protection. If provided, users must send password via X-Retriever-Password header.","examples":["published_retriever_password","demo_password"]},"include_metadata":{"type":"boolean","title":"Include Metadata","description":"Whether to capture and store retriever metadata (stages, collections, capabilities). Recommended: True for better developer experience and debugging. Default: True.","default":true},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Tags for categorizing this retriever. Used for filtering in public listings and gallery views.","examples":[["sandbox","demo","video"],["marketplace","adtech"]]},"category":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Category","description":"Primary category for this retriever. Examples: 'sandbox', 'marketplace', 'demo', 'production'.","examples":["sandbox","marketplace"]}},"type":"object","title":"PublishRetrieverRequest","description":"Request to publish a retriever.\n\nEither `public_name` (slug) or `display_name` (human-readable) is required.\nIf only `display_name` is provided, a slug is auto-generated from it.\nIf `display_config` is not provided, the retriever's stored display_config will be used."},"PublishRetrieverResponse":{"properties":{"public_id":{"type":"string","title":"Public Id","description":"Public identifier for this published retriever"},"retriever_id":{"type":"string","title":"Retriever Id","description":"ID of the underlying retriever"},"public_url":{"type":"string","title":"Public Url","description":"Full public URL to the retriever page","examples":["https://mxp.co/r/video-search"]},"short_url":{"type":"string","title":"Short Url","description":"Short URL via mxp.co redirect (same as public_url)","examples":["https://mxp.co/r/video-search"]},"public_api_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Public Api Key","description":"DEPRECATED: API keys are no longer required for public retriever access. For programmatic SDK access, create a ret_sk_ key via the retrievers/{id}/keys endpoint."}},"type":"object","required":["public_id","retriever_id","public_url","short_url"],"title":"PublishRetrieverResponse","description":"Response after successfully publishing a retriever."},"PublishedExtractorResponse":{"properties":{"extractor_id":{"type":"string","title":"Extractor Id"},"public_id":{"type":"string","title":"Public Id"},"public_name":{"type":"string","title":"Public Name"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"version":{"type":"string","title":"Version"},"trust_tier":{"$ref":"#/components/schemas/TrustTier"},"capabilities":{"items":{"$ref":"#/components/schemas/ExtractorCapability"},"type":"array","title":"Capabilities"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"install_count":{"type":"integer","title":"Install Count","default":0},"is_active":{"type":"boolean","title":"Is Active","default":true},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["extractor_id","public_id","public_name","version","trust_tier","created_at","updated_at"],"title":"PublishedExtractorResponse"},"PublishedRetrieverResponse":{"properties":{"retriever_id":{"type":"string","title":"Retriever Id","description":"ID of the underlying retriever"},"public_id":{"type":"string","title":"Public Id","description":"Public identifier for this published retriever"},"public_name":{"type":"string","title":"Public Name","description":"Public URL-safe name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Description of this public retriever"},"icon_base64":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Icon Base64","description":"Base64 encoded icon/favicon for this retriever"},"public_api_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Public Api Key","description":"DEPRECATED: Public API key (prk_). API keys are no longer required for public retriever access. For SDK access, use ret_sk_ keys."},"display_config":{"$ref":"#/components/schemas/DisplayConfig-Output","description":"Display configuration for UI rendering"},"rate_limit_config":{"$ref":"#/components/schemas/RateLimitConfig","description":"Rate limiting configuration"},"password_protected":{"type":"boolean","title":"Password Protected","description":"Whether password protection is enabled"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether the published retriever is active"},"retriever_metadata":{"anyOf":[{"$ref":"#/components/schemas/RetrieverMetadata"},{"type":"null"}],"description":"Optional technical metadata about the retriever"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Tags for categorizing this retriever"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category","description":"Primary category for this retriever"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Timestamp when published"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Timestamp when last updated"}},"type":"object","required":["retriever_id","public_id","public_name","display_config","rate_limit_config","password_protected","is_active","created_at","updated_at"],"title":"PublishedRetrieverResponse","description":"Response model for GET published retriever.\n\nReturns the full published retriever config including the public API key\nsince the user already has access to it."},"QueryOutcome":{"properties":{"query_id":{"type":"string","title":"Query Id","description":"Ground-truth query id from the dataset"},"status":{"type":"string","title":"Status","description":"'evaluated' (produced metrics) or 'skipped' (see error)"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"The per-query execution error when status='skipped'; null otherwise."},"retrieved_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Retrieved Count","description":"Documents retrieved when status='evaluated'; null for skips."},"relevant_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Relevant Count","description":"R: entries in this query's relevant_documents when status='evaluated'. A key like f2_at_2r was graded at k = 2 * relevant_count."},"metrics":{"anyOf":[{"additionalProperties":{"type":"number"},"type":"object"},{"type":"null"}],"title":"Metrics","description":"This query's score for each metric at each k, under the same keys as overall_metrics, e.g. recall_at_10 or f2_at_2r. Set when status='evaluated' on the single evaluation record; null on skips, on the evaluation list and on runs from before this field existed."}},"type":"object","required":["query_id","status"],"title":"QueryOutcome","description":"Per-query outcome on an evaluation record.\n\nBoth TS eval runs failed 0-of-N with one pooled message while the\nper-query cause (\"Unknown input field(s) 'top_k'\") lived only in worker\nlogs. Each attempted query records which branch it took and, for skips,\nthe actual error — actionable from the record alone."},"RSSConfig":{"properties":{"provider_type":{"type":"string","const":"rss","title":"Provider Type","default":"rss"},"credentials":{"anyOf":[{"$ref":"#/components/schemas/RSSHttpHeaderCredentials"},{"type":"null"}],"description":"Optional HTTP headers for private feeds."},"user_agent":{"type":"string","title":"User Agent","description":"User-Agent header for feed requests.","default":"Mixpeek RSS Sync/1.0"},"request_timeout":{"type":"integer","maximum":120.0,"minimum":5.0,"title":"Request Timeout","description":"HTTP request timeout in seconds.","default":30}},"type":"object","title":"RSSConfig","description":"RSS/Atom feed configuration. source_path = feed URL.","examples":[{"description":"Public RSS feed","provider_type":"rss","request_timeout":30,"user_agent":"Mixpeek RSS Sync/1.0"},{"credentials":{"headers":{"Authorization":"Bearer your-token-here"},"type":"http_headers"},"description":"Private RSS feed with auth header","provider_type":"rss","request_timeout":30,"user_agent":"Mixpeek RSS Sync/1.0"}]},"RSSFieldSource":{"properties":{"type":{"type":"string","const":"rss_field","title":"Type","description":"Source type identifier.","default":"rss_field"},"field":{"type":"string","title":"Field","description":"RSS entry field: title, author, link, categories, summary, published"}},"type":"object","required":["field"],"title":"RSSFieldSource","description":"Extract value from an RSS entry field.\n\nProvider Compatibility: RSS only\n\nAvailable fields: title, author, link, categories, summary, published\n\nExample mapping:\n    {\"type\": \"rss_field\", \"field\": \"title\"} -> extracts entry title\n    {\"type\": \"rss_field\", \"field\": \"categories\"} -> extracts list of category terms\n\nAttributes:\n    type: Must be \"rss_field\" to identify this source type\n    field: RSS entry field name to extract"},"RSSHttpHeaderCredentials":{"properties":{"type":{"type":"string","const":"http_headers","title":"Type","default":"http_headers"},"headers":{"additionalProperties":{"type":"string"},"type":"object","title":"Headers","description":"HTTP headers for feed requests (e.g., Authorization)."}},"type":"object","title":"RSSHttpHeaderCredentials","description":"Optional HTTP credentials for private RSS feeds."},"RTSPBasicCredentials":{"properties":{"type":{"type":"string","const":"basic","title":"Type","default":"basic"},"username":{"type":"string","minLength":1,"title":"Username","description":"REQUIRED. RTSP username."},"password":{"type":"string","minLength":1,"title":"Password","description":"REQUIRED. RTSP password. Secret credential, redacted on read. Never log or expose."}},"type":"object","required":["username","password"],"title":"RTSPBasicCredentials","description":"RTSP basic-auth credentials for a password-protected stream.\n\nThe discriminator string is `basic` and it is part of the API contract: the\nStudio connection form is hand-written per provider and matches on this\nliteral, so renaming it breaks the form silently rather than loudly.\n\nCredentials are held here rather than embedded in `url` on purpose. An RTSP\nURL carrying `user:pass@` is a credential that travels through every log\nline, error message and connection listing that prints the endpoint."},"RTSPConfig":{"properties":{"provider_type":{"type":"string","const":"rtsp","title":"Provider Type","default":"rtsp"},"url":{"type":"string","title":"Url","description":"REQUIRED. RTSP endpoint, for example rtsp://camera.example.com:554/stream1. Must use the rtsp:// or rtsps:// scheme. Must NOT embed credentials; supply those in `credentials` so the URL stays safe to log and display.","examples":["rtsp://camera.example.com:554/stream1","rtsps://nvr.example.com:322/cam/2"]},"credentials":{"anyOf":[{"$ref":"#/components/schemas/RTSPBasicCredentials"},{"type":"null"}],"description":"NOT REQUIRED. Basic-auth credentials for a protected stream. Omit for an open endpoint."},"transport":{"type":"string","enum":["tcp","udp"],"title":"Transport","description":"RTP transport. Defaults to tcp, which is interleaved over the RTSP control connection and survives NAT and packet loss without dropping frames. Choose udp only when the camera does not implement interleaved mode; udp trades reliability for a little latency.","default":"tcp"},"segment_seconds":{"type":"integer","maximum":300.0,"minimum":5.0,"title":"Segment Seconds","description":"Length of each captured segment in seconds. One segment is one object and one retriever invocation, so this sets the granularity of what lands in the bucket and how often the per-segment pipeline runs. Default 30. APPROXIMATE, NOT EXACT: cuts land on keyframes, so a camera sending a keyframe every 10 seconds cannot produce 5 second segments. Measured against a live camera, a request for 6 gave 6.0/6.0/6.0/5.2 and a request for 8 gave 8.8/9.0/6.2. Size downstream limits against the request plus the camera's keyframe interval. WHAT IT COSTS: shorter is not cheaper. Capture overhead was measured at 9.4 seconds fixed per run and effectively zero per segment, and capture uses stream copy so more segments does not mean more keyframes or more bytes. What shortening buys is latency, roughly segment_seconds plus 10 seconds to the first result. What it costs is downstream: each segment is one more object write and one more retriever invocation, so halving the length doubles the invocation count for the same footage.","default":30},"segments_per_run":{"type":"integer","maximum":20.0,"minimum":1.0,"title":"Segments Per Run","description":"How many consecutive segments to capture per sync run. Total capture per run is segment_seconds * segments_per_run and a run holds the stream open for that whole window, so keep the product below the sync's polling interval or runs overlap. COVERAGE is (segment_seconds * segments_per_run) / polling_interval, so this field and segment_seconds raise it EQUALLY: 30s x 1 on a 300s interval and 15s x 2 on the same interval are both 10 percent. Only the product matters for how much of the stream you keep. WHICH ONE TO RAISE is decided downstream, not here. Each segment is one more object write and one more gate invocation, so 270s x 1 and 30s x 9 give the same 90 percent coverage for one invocation instead of nine. Prefer longer segments when the per-segment pipeline costs anything, and raise this instead when you need finer granularity, because dedup and gating decide per segment.","default":1},"connect_timeout_seconds":{"type":"integer","maximum":120.0,"minimum":5.0,"title":"Connect Timeout Seconds","description":"How long to wait for the stream to start delivering before treating the endpoint as unreachable. Applies to connection tests and to the start of each capture.","default":15},"scene_change_threshold":{"anyOf":[{"type":"integer","maximum":64.0,"minimum":0.0},{"type":"null"}],"title":"Scene Change Threshold","description":"NOT REQUIRED. Drop a segment whose scene has not changed from the previous one. Omit it and every captured segment is published. The value is a Hamming distance over a 64-bit perceptual hash of each segment's first frame: a segment is DROPPED when its distance from the previous KEPT segment is at or below this number. 0 means drop only pixel-identical scenes; 5 is the platform's existing default elsewhere for 'the same frame modulo compression noise'; higher collapses more aggressively. WHY IT IS SEPARATE FROM gate_inference_name: this needs no model and no GPU. It is a few milliseconds of CPU per segment, so it runs FIRST and a segment it drops never reaches the gate at all. On an overnight camera that is the difference between paying inference on every segment and paying it on the ones where something happened.","examples":[5]},"gate_inference_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gate Inference Name","description":"NOT REQUIRED. Name of a real-time inference plugin to run on each captured segment before it is published. The plugin decides whether the segment is worth keeping, so an unchanging camera does not pay full extraction on footage that did not change. Omit it and every captured segment is published. The plugin is a pure function: segment in, verdict out. It returns `keep` (bool) and may return any additional fields, which are attached to the object for schema mapping. PLUGIN VS RETRIEVER: use `gate_retriever_id` instead when the decision is 'does this segment resemble what I care about', because that is a saved retriever you can read and edit per camera rather than a plugin you must deploy. Use a plugin when the decision is a pure computation over the pixels, like motion or a frame diff. The one thing a retriever still cannot do is run with NO collections: its document stream starts empty, so it returns success over zero documents and never runs its stages. See research/streaming-ingest/RTSP-INGEST-DESIGN.md.","examples":["scene_change_gate_v1","person_counter_v1"]},"gate_retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gate Retriever Id","description":"NOT REQUIRED, and mutually exclusive with `gate_inference_name`. Id of a SAVED RETRIEVER to run on each captured segment before it is published. The segment is passed as the retriever's query content, so the question it answers is 'does this segment resemble anything in the collections this retriever searches'. Keep the ones that match; drop the rest. WHY THIS RATHER THAN A PLUGIN: the policy becomes an object the customer can read, edit and version per camera, instead of a plugin that needs a deploy to change. A loading dock and a server room want different collections and different thresholds. COST: a retriever query is an embedding plus a vector search PER SEGMENT, against a few milliseconds of CPU for `scene_change_threshold`. Set that first so a segment it drops never reaches this.","examples":["ret_31bd0a81720dd9"]},"gate_retriever_min_score":{"anyOf":[{"type":"number","maximum":1.0,"minimum":0.0},{"type":"null"}],"title":"Gate Retriever Min Score","description":"Only meaningful with `gate_retriever_id`. Keep the segment when the retriever's top result scores at or above this. Leave it unset to keep the segment whenever the retriever returns ANY result, which is the right default for a retriever whose stages already filter. A threshold here is a second filter on top of whatever the retriever itself does, not a replacement for it.","examples":[0.35]},"gate_output_stage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gate Output Stage","description":"Gate on a NAMED STAGE OUTPUT instead of the search result set, so a YOLO or dedup retriever can gate. Names the stage whose output carries the verdict (a count, a hash distance, a boolean). Requires gate_retriever_id (the stage belongs to that retriever) plus gate_output_field and gate_output_threshold. Mutually exclusive with gate_retriever_min_score, which reads the result set instead. An absent stage or field is a gate FAILURE (gate_on_error), never a drop.","examples":["count_faces"]},"gate_output_field":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gate Output Field","description":"The key in the named stage's output holding the verdict value (for example face_count, hash_distance). Required when gate_output_stage is set.","examples":["face_count"]},"gate_output_op":{"type":"string","enum":["gte","lte","gt","lt","eq"],"title":"Gate Output Op","description":"How to compare the stage output against gate_output_threshold; the result IS keep/drop. gte for a count (keep when face_count >= N). gt for a dedup distance (keep when the scene changed, i.e. distance > N; a near-duplicate with a small distance is dropped). The direction is explicit so dedup versus detection is a config choice, not baked in.","default":"gte"},"gate_output_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Gate Output Threshold","description":"The value the stage output is compared against. Required when gate_output_stage is set.","examples":[2]},"gate_on_error":{"type":"string","enum":["publish","drop"],"title":"Gate On Error","description":"What to do with a segment when the gate itself fails: the plugin is down, times out, or returns something unreadable. Defaults to publish, so a broken gate costs extraction rather than footage. Choose drop only when storing an unjudged segment is worse than losing it, which is unusual: a dropped segment of a live stream is gone, and the moment it covered cannot be recaptured.","default":"publish"},"gate_timeout_seconds":{"type":"integer","maximum":300.0,"minimum":1.0,"title":"Gate Timeout Seconds","description":"How long to wait for the gate's verdict on one segment. On timeout the segment takes the gate_on_error path. Keep it well below segment_seconds * segments_per_run or the gate becomes the bottleneck and runs start overlapping.","default":30}},"type":"object","required":["url"],"title":"RTSPConfig","description":"Live RTSP stream configuration. source_path = the stream path.\n\nOne connection is one camera or encoder endpoint. The stream is cut into\nfixed-length segments and each completed segment becomes one object.\n\nWHAT LANDS IN THE BUCKET. A saved retriever, selected on the bucket sync\nrather than here, runs per segment and its outputs are what get persisted.\nRetrievers are namespace-scoped and a connection is organization-scoped, so\nthe retriever cannot live on this model without pinning one org-level\nconnection to a single namespace.\n\nCAPTURE IS WINDOWED. Each sync run opens the stream, captures\n`segment_seconds * segments_per_run` seconds, and closes it. Whatever the\ncamera shows between runs is not captured. That makes this a sampler, and\na config that samples 60 seconds out of every 300 should say so to whoever\nreads it back.","examples":[{"description":"Open camera, 30 second segments","provider_type":"rtsp","segment_seconds":30,"transport":"tcp","url":"rtsp://camera.example.com:554/stream1"},{"credentials":{"password":"your-password-here","type":"basic","username":"mixpeek"},"description":"Protected NVR re-stream, five 20 second segments per run","provider_type":"rtsp","segment_seconds":20,"segments_per_run":5,"transport":"tcp","url":"rtsps://nvr.example.com:322/cam/2"}]},"RTSPFieldSource":{"properties":{"type":{"type":"string","const":"rtsp_field","title":"Type","description":"Source type identifier.","default":"rtsp_field"},"field":{"type":"string","title":"Field","description":"RTSP segment field, without its prefix. Capture: source_url, segment_index, segment_duration_seconds, captured_at, transport. Inference-gate: whatever the plugin returned besides `keep`. Retriever-gate: applied, match_count, top_score, retriever_id. Stage-output gate: output_value. Either gate on failure: `error`, `applied`.","examples":["segment_duration_seconds","captured_at","person_count","top_score","error"]}},"type":"object","required":["field"],"title":"RTSPFieldSource","description":"Extract a value the RTSP connector attached to a captured segment.\n\nProvider Compatibility: RTSP only\n\nCapture fields, always present:\n    source_url, segment_index, segment_duration_seconds, captured_at, transport\n\nGate fields, present when the connection runs an admission gate. Two gate\nkinds attach fields here, and both drop the `gate_` prefix in a mapping.\n\nAn INFERENCE gate (gate_inference_name) runs a real-time plugin per segment;\nanything it returns alongside its `keep` verdict is reachable, so a plugin\nreturning `{\"keep\": true, \"person_count\": 4}` gives field \"person_count\":\n\n    {\"type\": \"rtsp_field\", \"field\": \"person_count\"}\n\nA RETRIEVER gate (gate_retriever_id) decides admission from a saved\nretriever and attaches its verdict: `applied` (true once the gate ran),\n`match_count` (results the retriever returned), `top_score` (the best\nresult's score), and `retriever_id` (which gate ran). A stage-output gate\nadditionally exposes `output_value`. Mapping `top_score` or `match_count`\nis how a downstream alert filters on the verdict instead of firing on every\nsegment:\n\n    {\"type\": \"rtsp_field\", \"field\": \"top_score\"}\n\nWhen either gate FAILS, `error` carries the reason and `applied` is false.\nMapping them is how a caller tells an unjudged segment from a judged one\nafter the fact, which the object itself otherwise cannot express.\n\nAttributes:\n    type: Must be \"rtsp_field\" to identify this source type\n    field: Field name WITHOUT the rtsp_ or gate_ prefix"},"RangeBucket":{"properties":{"field":{"type":"string","title":"Field","description":"Numeric field to create buckets for. REQUIRED, must be a numeric field. Supports dot notation for nested fields. Values will be grouped into ranges defined by boundaries.","examples":["metadata.duration","metadata.views","metadata.file_size"]},"boundaries":{"items":{"anyOf":[{"type":"integer"},{"type":"number"}]},"type":"array","minItems":1,"title":"Boundaries","description":"List of boundary values defining bucket ranges. REQUIRED, must be sorted in ascending order. Creates N+1 buckets for N boundaries: [0, 10, 20] creates: <0, 0-10, 10-20, >20. Values on boundaries go into the lower bucket.","examples":[[0,60,300,600],[0,100,1000,10000]]},"default_bucket":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default Bucket","description":"Name for values outside defined boundaries. OPTIONAL, defaults to 'other'. Used for values below min or above max boundary.","examples":["other","outliers","unknown"]}},"type":"object","required":["field","boundaries"],"title":"RangeBucket","description":"Configuration for range-based bucketing.\n\nGroups numeric values into ranges/buckets for histogram-style analysis.\n\nRequirements:\n    - field: REQUIRED, numeric field to bucket\n    - boundaries: REQUIRED, list of boundary values defining buckets\n    - default_bucket: OPTIONAL, name for values outside boundaries\n\nExamples:\n    - Video duration buckets: [0, 60, 300, 600] creates: 0-60s, 60-300s, 300-600s, 600+s\n    - View count buckets: [0, 100, 1000, 10000] creates: 0-100, 100-1K, 1K-10K, 10K+ views","examples":[{"boundaries":[0,60,300,600],"default_bucket":"over_600s","description":"Duration buckets (0-60s, 60-300s, 300-600s, 600+s)","field":"metadata.duration"},{"boundaries":[0,100,1000,10000],"default_bucket":"viral","description":"View count buckets","field":"metadata.views"}]},"RateLimitConfig":{"properties":{"enabled":{"type":"boolean","title":"Enabled","description":"Enable rate limiting for this published retriever. Set to False to disable all rate limiting (not recommended for public retrievers).","default":true},"tier":{"$ref":"#/components/schemas/RateLimitTier","description":"Rate limit tier preset. STANDARD (default): 60/min, 1k/hour, 10k/day. ELEVATED: 300/min, 10k/hour, 100k/day. ENTERPRISE: 1000/min, 50k/hour, 500k/day. UNLIMITED: No limits. Custom limits override tier defaults.","default":"standard","examples":["standard","elevated","enterprise"]},"requests_per_minute":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Requests Per Minute","description":"Maximum requests per minute (OPTIONAL). If not specified, uses tier default. If specified, overrides tier default."},"requests_per_hour":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Requests Per Hour","description":"Maximum requests per hour (OPTIONAL). If not specified, uses tier default. If specified, overrides tier default."},"requests_per_day":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Requests Per Day","description":"Maximum requests per day (OPTIONAL). If not specified, uses tier default. If specified, overrides tier default."},"max_results_per_query":{"type":"integer","maximum":1000.0,"minimum":1.0,"title":"Max Results Per Query","description":"Maximum number of results per search query (1-1000)","default":100},"enable_ip_limits":{"type":"boolean","title":"Enable Ip Limits","description":"Enable IP-based rate limiting in addition to retriever-level limits. Useful for preventing individual IPs from monopolizing the retriever.","default":false},"max_requests_per_ip_hour":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Max Requests Per Ip Hour","description":"Maximum requests per IP address per hour (OPTIONAL). Only enforced if enable_ip_limits=True. Recommended: 100-500 for standard tier, 1000+ for elevated/enterprise."}},"type":"object","title":"RateLimitConfig","description":"Rate limiting configuration for public retriever API.\n\nControls how many requests can be made to the public endpoint\nto prevent abuse and manage infrastructure costs.\n\nYou can either use a preset tier or specify custom limits.\nIf both tier and custom limits are provided, custom limits override the tier defaults.","examples":[{"description":"Standard tier (default) - 10/min, 100/hour, 1k/day","enabled":true,"max_results_per_query":50,"tier":"standard"},{"description":"Elevated tier - 30/min, 500/hour, 5k/day","enable_ip_limits":true,"enabled":true,"max_requests_per_ip_hour":100,"max_results_per_query":100,"tier":"elevated"},{"description":"Enterprise tier - 100/min, 2k/hour, 20k/day","enable_ip_limits":true,"enabled":true,"max_requests_per_ip_hour":500,"max_results_per_query":200,"tier":"enterprise"},{"description":"Custom limits overriding standard tier","enabled":true,"max_results_per_query":100,"requests_per_hour":200,"requests_per_minute":20,"tier":"standard"}]},"RateLimitTier":{"type":"string","enum":["standard","elevated","enterprise","unlimited"],"title":"RateLimitTier","description":"Rate limit tier for public retrievers.\n\nDefines preset rate limit configurations for different use cases.\n\nTiers:\n    STANDARD: Default tier for most public retrievers\n        - 10 requests/minute\n        - 100 requests/hour\n        - 1,000 requests/day\n        - Suitable for demos, prototypes, and low-traffic public applications\n\n    ELEVATED: Higher limits for trusted public applications\n        - 30 requests/minute (3x standard)\n        - 500 requests/hour (5x standard)\n        - 5,000 requests/day (5x standard)\n        - Suitable for production public apps with moderate traffic\n\n    ENTERPRISE: High limits for enterprise public deployments\n        - 100 requests/minute (10x standard)\n        - 2,000 requests/hour (20x standard)\n        - 20,000 requests/day (20x standard)\n        - Suitable for high-traffic public applications with monitoring\n\n    UNLIMITED: No rate limiting\n        - Use with extreme caution - only for fully trusted deployments\n        - Still respects max_results_per_query and IP limits if enabled"},"RawInferenceRequest":{"properties":{"provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider","description":"Provider name: openai, google (or its alias gemini), anthropic (required if inference_name not set)","examples":["openai","google","anthropic"]},"model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Model","description":"Model identifier specific to the provider (required if inference_name not set)","examples":["gpt-4o-mini","gemini-1.5-flash","claude-3-5-sonnet","text-embedding-3-large","whisper-1"]},"inference_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inference Name","description":"Custom plugin inference name (alternative to provider+model)","examples":["my_text_embedder_1_0_0","custom_reranker_2_0_0"]},"feature_uri":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Feature Uri","description":"Feature URI to resolve to inference_name (alternative to inference_name). Format: mixpeek://{extractor}@{version}/{vector_index_name}","examples":["mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1","mixpeek://my_custom_embedder@1.0.0/embedding"]},"inputs":{"additionalProperties":true,"type":"object","title":"Inputs","description":"Model-specific inputs. Chat: {prompts: [str]}, Embeddings: {text: str} or {texts: [str]}, Transcription: {audio_url: str}, Vision: {prompts: [str], image_url: str}","examples":[{"prompts":["What is the capital of France?"]},{"text":"machine learning"},{"audio_url":"https://example.com/audio.mp3"}]},"parameters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Parameters","description":"Optional parameters for inference. Common: temperature (float), max_tokens (int), schema (dict for structured output)","examples":[{"max_tokens":500,"temperature":0.7}]},"enable_semantic_cache":{"type":"boolean","title":"Enable Semantic Cache","description":"Enable semantic caching (vCache) for LLM chat operations. When enabled, semantically similar prompts may return cached responses, reducing latency and cost. Only applies to chat/completion models.","default":false},"cache_delta":{"anyOf":[{"type":"number","maximum":1.0,"minimum":0.0},{"type":"null"}],"title":"Cache Delta","description":"Maximum error rate for semantic cache (0.0-1.0). Lower values are more conservative. Default uses system setting (0.02 = 2%)."}},"type":"object","required":["inputs"],"title":"RawInferenceRequest","description":"Request for raw inference without retriever framework.\n\nThis endpoint provides direct access to inference services with minimal configuration.\nIdeal for simple LLM calls, embeddings, transcription, or vision tasks without\nrequiring collection setup or retriever configuration.\n\nYou can either use:\n- `provider` + `model` for standard providers (openai, google, anthropic)\n- `inference_name` for custom plugins\n\nExamples:\n    # Chat completion (provider + model)\n    {\n        \"provider\": \"openai\",\n        \"model\": \"gpt-4o-mini\",\n        \"inputs\": {\"prompts\": [\"What is AI?\"]},\n        \"parameters\": {\"temperature\": 0.7, \"max_tokens\": 500}\n    }\n\n    # Text embedding (provider + model)\n    {\n        \"provider\": \"openai\",\n        \"model\": \"text-embedding-3-large\",\n        \"inputs\": {\"text\": \"machine learning\"},\n        \"parameters\": {}\n    }\n\n    # Custom plugin (inference_name)\n    {\n        \"inference_name\": \"my_text_embedder_1_0_0\",\n        \"inputs\": {\"text\": \"hello world\"},\n        \"parameters\": {}\n    }\n\n    # Audio transcription\n    {\n        \"provider\": \"openai\",\n        \"model\": \"whisper-1\",\n        \"inputs\": {\"audio_url\": \"https://example.com/audio.mp3\"},\n        \"parameters\": {}\n    }\n\n    # Vision (multimodal)\n    {\n        \"provider\": \"openai\",\n        \"model\": \"gpt-4o\",\n        \"inputs\": {\n            \"prompts\": [\"Describe this image\"],\n            \"image_url\": \"https://example.com/image.jpg\"\n        },\n        \"parameters\": {\"temperature\": 0.5}\n    }"},"RawInferenceResponse":{"properties":{"data":{"title":"Data","description":"Inference results (structure varies by modality)"},"provider":{"type":"string","title":"Provider","description":"Provider that was used"},"model":{"type":"string","title":"Model","description":"Model that was used"},"tokens_used":{"anyOf":[{"additionalProperties":{"type":"integer"},"type":"object"},{"type":"null"}],"title":"Tokens Used","description":"Token usage statistics (if available)","examples":[{"completion":120,"prompt":15,"total":135}]},"latency_ms":{"type":"number","title":"Latency Ms","description":"Total inference latency in milliseconds"},"cached":{"type":"boolean","title":"Cached","description":"Whether the response was served from semantic cache (vCache)","default":false}},"type":"object","required":["data","provider","model","latency_ms"],"title":"RawInferenceResponse","description":"Response from raw inference.\n\nReturns the inference results along with metadata about the request."},"ReadConsistencyOption":{"properties":{"mode":{"type":"string","enum":["strong","eventual"],"title":"Mode","description":"'strong': the read sees every write acknowledged before it. 'eventual': the read may be served from a replica or a cached page and miss recent writes, in exchange for lower latency and less load on primaries. consistency_mode on the response says for how long."},"max_staleness_ms":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Max Staleness Ms","description":"With mode='eventual', the most a serving replica may lag the primary, in milliseconds. A replica further behind is skipped and the read goes to the primary. Ignored for 'strong'."}},"type":"object","required":["mode"],"title":"ReadConsistencyOption","description":"How fresh a retriever read must be (plan 6.14)."},"RecentError":{"properties":{"timestamp":{"type":"string","title":"Timestamp"},"error_type":{"type":"string","title":"Error Type"},"error_message":{"type":"string","title":"Error Message"},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url"}},"type":"object","required":["timestamp","error_type","error_message"],"title":"RecentError"},"RecentFailure":{"properties":{"source":{"type":"string","title":"Source","description":"Where the failure was read from (e.g. 'object')."},"object_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Object Id","description":"The source object's id, when known."},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"The object's processing status at read time."},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"The object's recorded error message."}},"type":"object","required":["source"],"title":"RecentFailure","description":"One recorded failure for the document's source object."},"RecentFailures":{"properties":{"failures":{"items":{"$ref":"#/components/schemas/RecentFailure"},"type":"array","title":"Failures","description":"Per-object failures found (object status/error)."},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason","description":"Present when the list is empty, or to note coverage limits (e.g. structured batch errors are aggregate-only, not queryable per object)."}},"type":"object","title":"RecentFailures","description":"The source object's failure history, with an honest coverage note."},"RecommendationCoverage":{"properties":{"total_queries":{"type":"integer","title":"Total Queries","description":"All queries in the window"},"filtered_queries":{"type":"integer","title":"Filtered Queries","description":"Queries carrying at least one filter field. These, and only these, are what the recommendations above were computed from."},"slow_queries":{"type":"integer","title":"Slow Queries","description":"Queries over the slow threshold, filtered or not"},"slow_filtered_queries":{"type":"integer","title":"Slow Filtered Queries","description":"Slow queries carrying a filter field. The gap between this and `slow_queries` is slow traffic no index recommendation can address — look at embedding, vector search or stage cost for those."},"threshold_ms":{"type":"number","title":"Threshold Ms","description":"Latency above which a query counts as slow here","default":500}},"type":"object","required":["total_queries","filtered_queries","slow_queries","slow_filtered_queries"],"title":"RecommendationCoverage","description":"What share of the namespace's traffic these recommendations were computed from.\n\nIndex recommendations are derived only from queries that FILTERED on a\nfield (``length(filter_fields) > 0``), since an index is only meaningful for\na filtered field. Without this block an empty ``recommendations`` list is\nindistinguishable from \"this namespace is fine\", and on 2026-08-22 that is\nexactly how it read: 184 slow queries in ``ns_7aa8b538a5`` against a\n``NO ACTION - Low usage`` verdict computed from 8."},"ReconcileSettings":{"properties":{"on_delete":{"type":"boolean","title":"On Delete","description":"When a source asset is deleted, cascade-delete the corresponding Mixpeek objects (and their collection documents). Default True.","default":true},"on_update":{"type":"boolean","title":"On Update","description":"When a source asset's metadata changes, propagate the update to the Mixpeek object and re-process it through connected collections. Default True. On an Iconik sync, True makes the per-asset Iconik calls for every listed asset on every walk. False lets the sync skip assets whose stored modified time matches the listing before it makes those calls, and metadata edits that leave the modified time unchanged are then not picked up.","default":true},"on_filter_drift":{"type":"boolean","title":"On Filter Drift","description":"During reconciliation, remove objects whose source asset no longer matches the configured metadata_filters. Default True.","default":true},"re_extract_on_update":{"type":"boolean","title":"Re Extract On Update","description":"When on_update is True, also re-extract (rebatch) the object through its connected collections. Set to False to propagate metadata changes without triggering re-extraction. Default True.","default":true},"re_extract_fields":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Re Extract Fields","description":"When set, only re-extract if one of these specific fields changed. Field names are matched against the source metadata keys. If None (default), any metadata change triggers re-extraction (when re_extract_on_update is True). Example: ['title', 'description', 'media_type']"}},"type":"object","title":"ReconcileSettings","description":"Controls how Mixpeek reconciles objects when the source changes."},"ReconciliationDiscrepancy":{"properties":{"object_id":{"type":"string","title":"Object Id","description":"The source object's id."},"bucket_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bucket Id","description":"The bucket the object belongs to."},"reason":{"$ref":"#/components/schemas/ReconciliationReason","description":"Why the object produced no document."},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"The object's processing status at read time."},"age_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Age Seconds","description":"Seconds since the object was created, so a stuck object is distinguishable from one that is merely still in flight."},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"The object's own error message, when it failed."}},"type":"object","required":["object_id","reason"],"title":"ReconciliationDiscrepancy","description":"One source object that did not produce a document."},"ReconciliationReason":{"type":"string","enum":["no_document","failed","processing","skipped","unknown"],"title":"ReconciliationReason","description":"Why a source object produced no document."},"RedeemPromoRequest":{"properties":{"code":{"type":"string","maxLength":64,"minLength":1,"title":"Code"},"plan":{"type":"string","title":"Plan","description":"Plan slug to start on the comped window (product_tier, e.g. managed_build). Must be self-serve and match the code's product restriction.","default":"managed_build"},"onboarding_answers":{"anyOf":[{"$ref":"#/components/schemas/OnboardingAnswers"},{"type":"null"}],"description":"Signup questions — persisted server-side for GTM attribution, parity with the card path (the no-CC cohort is the highest-sales-relevance cohort; client-event-only isn't joinable with the server-side funnel data). The $5/answer credit is NOT minted here — the comped window bills $0, so there is nothing to offset."}},"type":"object","required":["code"],"title":"RedeemPromoRequest"},"RedeemPromoResponse":{"properties":{"redeemed":{"type":"boolean","title":"Redeemed"},"code":{"type":"string","title":"Code"},"plan":{"type":"string","title":"Plan"},"account_type":{"type":"string","title":"Account Type"},"subscription_id":{"type":"string","title":"Subscription Id"},"poc_usage_cap_cents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Poc Usage Cap Cents","description":"POC promo usage ceiling (cents), granted via the subscription webhook (cap_source=poc_promo:*)."},"duration_in_months":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration In Months"}},"type":"object","required":["redeemed","code","plan","account_type","subscription_id"],"title":"RedeemPromoResponse"},"ReminderPreferences":{"properties":{"enabled":{"type":"boolean","title":"Enabled","description":"Master toggle for all reminder emails","default":true},"onboarding_nudges":{"type":"boolean","title":"Onboarding Nudges","description":"Funnel progression nudges","default":true},"engagement_reminders":{"type":"boolean","title":"Engagement Reminders","description":"Re-engagement emails for inactivity","default":true},"feature_tips":{"type":"boolean","title":"Feature Tips","description":"Helpful tips and inspiration","default":true},"quiet_hours_start":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Quiet Hours Start","description":"Hour (0-23) to start quiet period (UTC)"},"quiet_hours_end":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Quiet Hours End","description":"Hour (0-23) to end quiet period (UTC)"}},"type":"object","title":"ReminderPreferences","description":"User preferences for reminder/nudge emails."},"ReminderPreferencesResponse":{"properties":{"reminders":{"$ref":"#/components/schemas/ReminderPreferences","description":"Reminder/nudge email preferences"}},"type":"object","required":["reminders"],"title":"ReminderPreferencesResponse","description":"Response model for reminder preferences."},"RenderStrategy":{"type":"string","enum":["static","javascript","auto"],"title":"RenderStrategy","description":"Strategy for rendering web pages.\n\nValues:\n    STATIC: Fast HTTP fetch, works for most sites\n    JAVASCRIPT: Browser rendering via Playwright for SPAs\n    AUTO: Try static first, fall back to JS if content too short"},"RepresentativeDocument":{"properties":{"document_id":{"type":"string","title":"Document Id","description":"Document ID"},"collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Collection Id","description":"Collection ID for efficient vector filtering"}},"type":"object","required":["document_id"],"title":"RepresentativeDocument","description":"Represents a document used for LLM labeling with collection tracking."},"ResourceAllocation":{"properties":{"cpu_request":{"type":"string","title":"Cpu Request"},"cpu_limit":{"type":"string","title":"Cpu Limit"},"memory_request":{"type":"string","title":"Memory Request"},"memory_limit":{"type":"string","title":"Memory Limit"},"gpu":{"type":"integer","title":"Gpu","default":0}},"type":"object","required":["cpu_request","cpu_limit","memory_request","memory_limit"],"title":"ResourceAllocation"},"ResourceDimension":{"type":"string","enum":["cpu_utilization","mem_utilization","gpu_duty_cycle","ray_replicas"],"title":"ResourceDimension","description":"The resource dimensions the audit names as in scope for phase 1\n(§5, proposed shape). Per-extractor/per-serve-instance granularity is\ndeliberately deferred (G8) — same doctrine's rollup already\napplied to SLO surfaces."},"ResourceErrorCount":{"properties":{"resource_id":{"type":"string","title":"Resource Id","description":"Collection ID or cluster ID"},"error_count":{"type":"integer","title":"Error Count","description":"Number of errors/failures in the analyzed window"}},"type":"object","required":["resource_id","error_count"],"title":"ResourceErrorCount","description":"Error/failure count for a single collection or cluster."},"ResourceFilter":{"properties":{"collection_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Collection Ids","description":"Specific collection IDs to migrate"},"taxonomy_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Taxonomy Ids","description":"Specific taxonomy IDs to migrate"},"cluster_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Cluster Ids","description":"Specific cluster IDs to migrate"},"retriever_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Retriever Ids","description":"Specific retriever IDs to migrate"},"date_range":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Date Range","description":"Date range filter (after, before)"},"auto_include_dependencies":{"type":"boolean","title":"Auto Include Dependencies","description":"Automatically include required dependencies","default":true}},"type":"object","title":"ResourceFilter","description":"Filters for selective resource migration."},"ResourceProgress":{"properties":{"resource_id":{"type":"string","title":"Resource Id","description":"Resource ID"},"resource_type":{"$ref":"#/components/schemas/shared__namespaces__migrations__models__ResourceType","description":"Resource type"},"status":{"$ref":"#/components/schemas/MigrationStatus","description":"Resource status"},"progress_percent":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Progress Percent","description":"Progress %","default":0.0},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Error if failed","x-mixpeek-redacted":"driver_text"}},"type":"object","required":["resource_id","resource_type","status"],"title":"ResourceProgress","description":"Progress tracking for individual resources."},"ResourceResult":{"properties":{"resource_type":{"type":"string","title":"Resource Type","description":"Type of resource (namespace, bucket, etc.)"},"name":{"type":"string","title":"Name","description":"Resource name from manifest"},"resource_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Id","description":"Created resource ID"},"status":{"$ref":"#/components/schemas/ResourceResultStatus","description":"What apply did to this resource. `created` and `skipped` are what they sound like. `would_create` appears only on a dry run, for a resource the real apply would create. `exists` means it was already what the manifest declares. `drifted` means it differs and still does. `updated` means apply patched it. `pending` means the resource exists but waits on something apply cannot do itself, named in `pending_reason`. READ `updated` WITH `refused`: a resource can be `updated` AND carry refused fields, because apply patches what the update surface accepts and reports the rest. `updated` on its own does not mean every declared field was applied, and a caller that treats it as reconciled will report a partly-applied manifest as complete."},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if failed"},"generated_for":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Generated For","description":"Present when the manifest did not declare this resource itself: the name of the taxonomy whose inline labels generated it (its label bucket, collection, retriever or seed). Edit the taxonomy's labels to change it."},"pending_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pending Reason","description":"Present when status is `pending`: what the resource waits for and what happens when it arrives."},"drift":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Drift","description":"Fields the manifest DECLARES that differ from the live resource. Present when status is `drifted`, and ALSO on an `updated` resource, where it is HISTORICAL: the record of what apply changed, not a difference that is still there. A caller that renders any non-empty value as 'differs' will announce the opposite of what happened on every patched row. Named rather than counted: 'collection c1 differs: schedule' is actionable, 'exists' is not. Only fields the manifest explicitly set are compared — an omitted field asserts nothing, and treating an omission as drift would make every apply drift on server-set defaults.","examples":[["schedule","feature_extractor"]]},"refused":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Refused","description":"Fields the manifest declares, and that DIFFER, which apply would not change. Present under `upsert` when the resource's own update surface does not accept a field or refuses the value. A refusal is reported per field rather than as a failed apply: the rest of the manifest still applies, and the caller learns exactly which resource and which field to take up by hand. A bucket's schema is the standing example — it is patchable through the API and a destructive change is refused, so upsert does not route around that guard.","examples":[["budget_limits"]]},"drift_not_compared":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Drift Not Compared","description":"Fields the manifest declares that could NOT be compared, because the live resource has no corresponding key. Reported rather than dropped: a field silently excluded from the comparison is indistinguishable from one that matched, and that is the exact ambiguity `drifted` exists to remove."}},"type":"object","required":["resource_type","name","status"],"title":"ResourceResult","description":"Result of applying a single resource.","examples":[{"name":"video_search","resource_id":"ns_abc123","resource_type":"namespace","status":"created"}]},"ResourceResultStatus":{"type":"string","enum":["created","skipped","failed","exists","drifted","updated","would_create","pending"],"title":"ResourceResultStatus","description":"Status of a resource creation attempt."},"ResourceScope-Input":{"properties":{"resource_type":{"$ref":"#/components/schemas/ResourceType-Input","description":"Resource type this scope governs. Use ResourceType enum values to scope a key to namespaces, collections, clusters, etc."},"resource_id":{"type":"string","maxLength":100,"minLength":1,"title":"Resource Id","description":"Identifier or pattern for the resource. Accepts a literal ID (e.g. 'ns_production') or wildcard forms such as '*' or 'ns_customer_*'."},"operations":{"anyOf":[{"items":{"$ref":"#/components/schemas/NamespaceOperation"},"type":"array"},{"type":"null"}],"title":"Operations","description":"Subset of operations allowed within the scope. When omitted the key may perform any operation permitted by its Permission list."}},"type":"object","required":["resource_type","resource_id"],"title":"ResourceScope","description":"Fine-grained restriction applied to an API key.","examples":[{"description":"Full namespace access (data + infrastructure)","resource_id":"ns_production","resource_type":"namespace"},{"description":"Analytics-only access in namespace","operations":["read_data","execute_retriever"],"resource_id":"ns_customer_123","resource_type":"namespace"},{"description":"Specific collection only","resource_id":"col_products","resource_type":"collection"}]},"ResourceScope-Output":{"properties":{"resource_type":{"$ref":"#/components/schemas/shared__organizations__enums__ResourceType","description":"Resource type this scope governs. Use ResourceType enum values to scope a key to namespaces, collections, clusters, etc."},"resource_id":{"type":"string","maxLength":100,"minLength":1,"title":"Resource Id","description":"Identifier or pattern for the resource. Accepts a literal ID (e.g. 'ns_production') or wildcard forms such as '*' or 'ns_customer_*'."},"operations":{"anyOf":[{"items":{"$ref":"#/components/schemas/NamespaceOperation"},"type":"array"},{"type":"null"}],"title":"Operations","description":"Subset of operations allowed within the scope. When omitted the key may perform any operation permitted by its Permission list."}},"type":"object","required":["resource_type","resource_id"],"title":"ResourceScope","description":"Fine-grained restriction applied to an API key.","examples":[{"description":"Full namespace access (data + infrastructure)","resource_id":"ns_production","resource_type":"namespace"},{"description":"Analytics-only access in namespace","operations":["read_data","execute_retriever"],"resource_id":"ns_customer_123","resource_type":"namespace"},{"description":"Specific collection only","resource_id":"col_products","resource_type":"collection"}]},"ResourceTarget":{"properties":{"dimension":{"$ref":"#/components/schemas/ResourceDimension"},"target_min":{"type":"number","title":"Target Min","description":"Lower bound of the target band."},"target_max":{"type":"number","title":"Target Max","description":"Upper bound of the target band."},"unit":{"type":"string","enum":["ratio","count"],"title":"Unit","description":"'ratio' for a 0-1 utilization fraction, 'count' for a unit quantity (e.g. Ray replicas)."}},"type":"object","required":["dimension","target_min","target_max","unit"],"title":"ResourceTarget","description":"A target range for one resource dimension. ``target_min``/\n``target_max`` bound the band a controller should hold the resource\ninside — below is over-provisioned (safe, wastes money), above is HOT\n(unsafe), matching the semantics already established in\noperations/finances/utilization_convergence.py's TENANCY_BANDS."},"ResourceType-Input":{"type":"string","enum":["organization","user","api_key","namespace","collection","document","bucket","retriever","cluster","taxonomy","storage_connection","alert","annotation","secret","webhook"],"title":"ResourceType","description":"Resource surfaces supported by scoped API keys and audit events.\n\nThese resource types can be used in:\n- API key scopes to restrict access to specific resources\n- Audit logs to identify what type of resource was affected\n- Permission systems to grant/deny access to resource categories\n\nResource hierarchy:\n    ORGANIZATION -> USER, API_KEY, STORAGE_CONNECTION\n    NAMESPACE -> COLLECTION, BUCKET, RETRIEVER, CLUSTER, TAXONOMY\n\nResource types:\n    - ORGANIZATION: Top-level tenant entity\n    - USER: Organization member with authentication credentials\n    - API_KEY: Authentication token for programmatic access\n    - NAMESPACE: Isolated environment for data and compute resources\n    - COLLECTION: Vector database collection for searchable documents\n    - DOCUMENT: A single searchable document within a collection\n    - BUCKET: Object storage container for raw files\n    - RETRIEVER: Configured search/retrieval pipeline\n    - CLUSTER: Ray compute cluster for distributed processing\n    - TAXONOMY: Hierarchical classification system for documents\n    - STORAGE_CONNECTION: External storage provider integration"},"RestoreCollectionOutcome":{"properties":{"collection":{"type":"string","title":"Collection"},"expected":{"type":"integer","title":"Expected"},"restored":{"type":"integer","title":"Restored"},"status":{"type":"string","title":"Status","description":"'restored' (full), 'partial' (restored < expected), 'failed', or 'skipped' (left out on purpose: a restore beside the source does not clone history, telemetry or secrets)"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"}},"type":"object","required":["collection","expected","restored","status"],"title":"RestoreCollectionOutcome"},"RestoreReport":{"properties":{"snapshot_id":{"type":"string","title":"Snapshot Id"},"target_namespace_id":{"type":"string","title":"Target Namespace Id"},"complete":{"type":"boolean","title":"Complete","description":"True iff every non-empty collection AND the vectors were fully restored"},"collections":{"items":{"$ref":"#/components/schemas/RestoreCollectionOutcome"},"type":"array","title":"Collections"},"vector_expected":{"type":"integer","title":"Vector Expected","default":0},"vector_restored":{"type":"integer","title":"Vector Restored","default":0},"vector_source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vector Source"},"vector_status":{"type":"string","title":"Vector Status","description":"'restored', 'partial', 'failed', or 'none' (snapshot carried no vectors)","default":"none"},"skipped_summary":{"items":{"type":"string"},"type":"array","title":"Skipped Summary","description":"Human-readable list of everything not fully restored (empty when complete)"},"retriever_parity":{"items":{"$ref":"#/components/schemas/RetrieverParityResult"},"type":"array","title":"Retriever Parity","description":"Top-k parity per retriever between the source and the restored namespace; filled for a restore into a different namespace"},"restore_point":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Restore Point","description":"The restore_point the vectors were restored to"},"resolved_seq":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Resolved Seq","description":"The WAL seq the shard's replica actually reached (frontier_seq)"},"fork_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fork Id","description":"The point-in-time replica the vectors were read from"},"write_gap":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Write Gap","description":"For a restore beside the source: objects the source gained or changed after the snapshot's capture began, copied into the copy and re-queued for extraction (cutoff, new_since_snapshot, changed_since_snapshot, requeued, batches, refused with reasons)"}},"type":"object","required":["snapshot_id","target_namespace_id","complete"],"title":"RestoreReport","description":"Outcome of a restore: exactly what was restored vs skipped.\n\nRestore is lenient (it warns + continues on a missing/corrupt dump), so a\n'completed' restore can be silently incomplete. This report records the\nper-collection and vector outcomes and a single ``complete`` flag so a\npartial restore is never mistaken for a clean one."},"RestoreSnapshotRequest":{"properties":{"target_namespace_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Namespace Name","description":"Name for the restored namespace. If omitted, restores in-place (deletes current data and replaces with snapshot data), which requires confirm_in_place."},"confirm_in_place":{"type":"boolean","title":"Confirm In Place","description":"Required to restore in place (no target_namespace_name): the namespace's current data is deleted and replaced by the snapshot's. While the restore runs the namespace is read-only; writes are refused with a 409 to retry after it completes.","default":false},"restore_point":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"null"}],"title":"Restore Point","description":"Restore the namespace as it was at this point: an RFC 3339 instant (e.g. 2026-10-01T18:00:00Z) or a vector-store WAL seq. Requires target_namespace_name. The snapshot must have been taken at or before the point. For an instant, the configuration (the namespace, its buckets, collections and retrievers) is rebuilt as it was at the instant from the namespace's configuration history; for a WAL seq it is the snapshot's. An instant the history cannot rebuild exactly is refused, naming why. The vectors and payloads are the shard's state at the point, replayed from its retained WAL. A restore can reach any point from the vector store's most recent checkpoint up to its newest durable write. A point outside that range is refused, and the error names the oldest and newest instants you can restore to now. Omit to restore the snapshot as taken.","examples":["2026-10-01T18:00:00Z",48210]},"isolated":{"type":"boolean","title":"Isolated","description":"Restore beside the source onto a temporary vector shard of its own instead of the plane's shared one. Requires target_namespace_name. The copy is for checking or measuring a restore: its shard stops after six hours, and deleting the copy's namespace stops it sooner. One isolated copy runs at a time; a second request while one is up is refused naming the namespace that holds it.","default":false}},"type":"object","title":"RestoreSnapshotRequest"},"RestoreSnapshotResponse":{"properties":{"task_id":{"type":"string","title":"Task Id"},"snapshot_id":{"type":"string","title":"Snapshot Id"},"target_namespace_id":{"type":"string","title":"Target Namespace Id"},"message":{"type":"string","title":"Message"},"restore_point":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Restore Point","description":"The restore_point requested, normalized"},"fork_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fork Id","description":"Identifies the point-in-time replica this restore reads from; the task's restore_report carries the same id"},"resolved_seq":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Resolved Seq","description":"The WAL seq the restore targets. Known here when restore_point is a seq; for an instant the shard resolves it during the restore, and the task's restore_report records it."},"isolated":{"type":"boolean","title":"Isolated","description":"True when the copy goes onto a temporary shard of its own; the task creates the namespace once that shard is up","default":false}},"type":"object","required":["task_id","snapshot_id","target_namespace_id","message"],"title":"RestoreSnapshotResponse"},"RestoreVersionRequest":{"properties":{"environment":{"type":"string","enum":["staging","production"],"title":"Environment","description":"Target environment to restore","default":"production"}},"type":"object","title":"RestoreVersionRequest","description":"Restore a previous version to an environment."},"RestoreVersionResponse":{"properties":{"app_id":{"type":"string","title":"App Id"},"version":{"type":"integer","title":"Version"},"deploy_id":{"type":"string","title":"Deploy Id"},"environment":{"type":"string","title":"Environment"},"asset_prefix":{"type":"string","title":"Asset Prefix"}},"type":"object","required":["app_id","version","deploy_id","environment","asset_prefix"],"title":"RestoreVersionResponse"},"ResultCardProperties":{"properties":{"layout":{"type":"string","title":"Layout","description":"Card layout orientation","default":"vertical","examples":["vertical","horizontal"]},"show_thumbnail":{"type":"boolean","title":"Show Thumbnail","description":"Whether to show thumbnail image in results","default":true},"thumbnail_aspect_ratio":{"type":"string","title":"Thumbnail Aspect Ratio","description":"Aspect ratio for thumbnail images","default":"16/9","examples":["16/9","4/3","1/1"]},"thumbnail_fit":{"type":"string","title":"Thumbnail Fit","description":"How thumbnail should fit in container","default":"cover","examples":["cover","contain"]},"show_score":{"type":"boolean","title":"Show Score","description":"Whether to display relevance score","default":false},"truncate_title":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Truncate Title","description":"Maximum characters for title before truncation","examples":[60,80,100]},"truncate_description":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Truncate Description","description":"Maximum characters for description before truncation","examples":[120,150,200]},"field_order":{"items":{"type":"string"},"type":"array","title":"Field Order","description":"Order of fields to display in result card. Fields not in this list won't be shown. Must be subset of exposed_fields.","examples":[["title","description","category","created_at"],["thumbnail_url","title","price","views"]]},"show_find_similar":{"type":"boolean","title":"Show Find Similar","description":"Whether to show a 'Find Similar' button on result cards","default":false},"card_click_action":{"type":"string","title":"Card Click Action","description":"Action when card is clicked: none (no action), findSimilar (trigger similar search), viewDetails (open detail modal)","default":"viewDetails","examples":["none","findSimilar","viewDetails"]},"thumbnail_field":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Thumbnail Field","description":"Field name to use as thumbnail image source","examples":["thumbnail_url","image_url","page_image"]},"title_field":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title Field","description":"Field name to use as card title","examples":["title","name","document_title"]},"card_fields":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Card Fields","description":"Fields to display on the card (alternative to field_order for template compatibility)","examples":[["title","description","price"]]},"modal_fields":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Modal Fields","description":"Fields to display in the detail modal when card is clicked","examples":[["title","description","full_text","metadata"]]},"card_style":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Card Style","description":"Card style preset: default, portrait-discovery, media-search, document-search, or custom template-specific styles","default":"default","examples":["default","portrait-discovery","media-search","document-search"]}},"type":"object","title":"ResultCardProperties","description":"Properties for result card display configuration.","examples":[{"card_click_action":"viewDetails","card_style":"default","field_order":["title","description","category","created_at"],"layout":"vertical","show_find_similar":true,"show_score":true,"show_thumbnail":true,"thumbnail_aspect_ratio":"16/9","thumbnail_field":"image_url","thumbnail_fit":"cover","title_field":"title","truncate_description":120,"truncate_title":60}]},"RetrieverAPIKeyListResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/APIKeyModel"},"type":"array","title":"Results","description":"List of API keys for the retriever (plaintext key never included)."},"total":{"type":"integer","title":"Total","description":"Total number of keys (including revoked if requested).","default":0}},"type":"object","title":"RetrieverAPIKeyListResponse","description":"Response for listing retriever API keys."},"RetrieverAPIKeyResponse":{"properties":{"key_id":{"type":"string","title":"Key Id","description":"Public identifier for the API key."},"key_hash":{"type":"string","title":"Key Hash","description":"SHA-256 hash of the plaintext key."},"key_prefix":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Key Prefix","description":"Visible prefix of the API key for user identification (e.g., 'sk_abc123...'). Shows the first 10 characters of the plaintext key to help users identify which key is which in lists, without exposing the full secret. This follows industry best practices from GitHub, Stripe, and AWS. Generated automatically for new keys. Older keys may not have this field.","examples":["sk_abc123...","sk_xyz789..."]},"key_type":{"$ref":"#/components/schemas/APIKeyType","description":"Type of API key. STANDARD for regular organization keys, MARKETPLACE_SUBSCRIPTION for marketplace subscription access tokens.","default":"standard"},"subscription_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subscription Id","description":"Marketplace subscription ID if this is a marketplace subscription key. Only set when key_type is MARKETPLACE_SUBSCRIPTION."},"is_internal":{"type":"boolean","title":"Is Internal","description":"SERVER-VERIFIED internal-actor marker. When True, this key belongs to Mixpeek's own operations (e.g. the in-org ops/health probe that must authenticate under a dedicated tenant's internal_id because the single-tenant pod gate fail-closes cross-org auth) and its usage is NOT billed to the org: accrue_mvs_usage skips the accrual and consume_credits skips the direct charge. FAIL CLOSED — absent/False means BILL. This is the ONLY server-side source a billing skip may key on; never the client-influenced X-Mixpeek-Traffic header or mixpeek-loop-* User-Agent. Set only by an admin provisioning an internal key, never from a create request.","default":false},"internal_id":{"type":"string","title":"Internal Id","description":"Organization internal identifier."},"organization_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Id","description":"Organization public identifier (denormalized)."},"user_id":{"type":"string","title":"User Id","description":"Identifier of the user who owns the key."},"name":{"type":"string","title":"Name","description":"Human-friendly key label."},"description":{"type":"string","title":"Description","description":"Optional description explaining the key usage.","default":""},"permissions":{"items":{"$ref":"#/components/schemas/Permission"},"type":"array","title":"Permissions","description":"Permissions granted to the key."},"scopes":{"items":{"$ref":"#/components/schemas/ResourceScope-Output"},"type":"array","title":"Scopes","description":"Resource-level scopes restricting the key."},"rate_limit_override":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Rate Limit Override","description":"Optional per-key rate limit override in requests per minute."},"status":{"$ref":"#/components/schemas/KeyStatus","description":"Lifecycle status of the key (active, revoked, expired).","default":"active"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At","description":"UTC timestamp when the key automatically expires."},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At","description":"UTC timestamp of the last successful request using the key."},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"UTC timestamp when the key was created."},"created_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By","description":"User identifier that created the key."},"revoked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Revoked At","description":"UTC timestamp when the key was revoked (if applicable)."},"revoked_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Revoked By","description":"User identifier that revoked the key (if applicable)."},"allowed_origins":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Allowed Origins","description":"Optional list of allowed HTTP origins for this API key. When set, requests must include an Origin header matching one of these values. Supports exact matches (e.g., 'https://docs.example.com') and wildcard subdomains (e.g., 'https://*.example.com'). Only enforced for browser requests (defense-in-depth, not a security boundary). Null means no origin restriction.","examples":[["https://docs.example.com","https://*.example.com"]]},"principal_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Principal Id","description":"End-user identifier for document-level ACL (row-level security). When set, this key is user-scoped: all document reads are automatically filtered to documents the principal owns or has been granted access to. This represents an end-user in your application, NOT an org user."},"key":{"type":"string","title":"Key","description":"Plaintext API key (shown only once). Prefix: ret_sk_. Store securely immediately after creation."}},"type":"object","required":["key_hash","internal_id","user_id","name","key"],"title":"RetrieverAPIKeyResponse","description":"Response model including the plaintext key (shown only once).\n\nThis response is returned immediately after key creation. The plaintext key\nis shown ONLY in this response and cannot be retrieved later. Users should\nsave the key immediately for secure storage.\n\nSecurity note:\n    The `key` field contains the plaintext secret and should be:\n    - Stored securely by the user (environment variables, secrets manager)\n    - Never committed to version control\n    - Never logged or exposed in error messages\n    - Rotated/revoked if accidentally exposed","examples":[{"created_at":"2025-01-01T00:00:00Z","created_by":"usr_admin","description":"Service account for ingestion","internal_id":"int_x1y2z3","key_hash":"2c26b46b68ffc68ff99b453c1d304134","key_id":"key_a1b2c3d4e5f6g7h","key_prefix":"sk_abc123...","name":"backend-service","organization_id":"org_demo123","permissions":["read","write"],"scopes":[],"status":"active","user_id":"usr_a1b2c3d4e5f6g7h"}]},"RetrieverConfig":{"properties":{"retriever_id":{"type":"string","title":"Retriever Id","description":"Stable retriever identifier (REQUIRED)."},"retriever_name":{"type":"string","minLength":1,"title":"Retriever Name","description":"Unique retriever name within namespace (REQUIRED)."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Detailed description of retriever behaviour (OPTIONAL)."},"collection_ids":{"items":{"type":"string"},"type":"array","title":"Collection Ids","description":"Collections queried by the retriever. Can be empty for query-only inference mode."},"stages":{"items":{"$ref":"#/components/schemas/StageConfig-Output"},"type":"array","minItems":1,"title":"Stages","description":"Ordered list of stage configurations (REQUIRED)."},"input_schema":{"additionalProperties":{"$ref":"#/components/schemas/RetrieverInputSchemaField-Output","description":"Schema definition for this input field. Defines type, description, examples, and validation rules. Supports all bucket types (string, number, image, etc.) plus document_reference. Frontend uses this to render the appropriate input component (text input, image upload, dropdown, etc.)"},"type":"object","title":"Input Schema","description":"JSON Schema describing expected user inputs (REQUIRED). Properties must use RetrieverInputSchemaField which supports all bucket types plus document_reference."},"budget_limits":{"$ref":"#/components/schemas/BudgetLimits","description":"Execution budget limits for the retriever (OPTIONAL)."},"feature_dependencies":{"anyOf":[{"items":{"$ref":"#/components/schemas/FeatureAddress"},"type":"array"},{"type":"null"}],"title":"Feature Dependencies","description":"Feature addresses required by stages (OPTIONAL, aids validation)."},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Arbitrary tags to help organise retrievers (OPTIONAL)."},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Custom key-value metadata (OPTIONAL). Round-trips on create/get/list and is updatable via PATCH — useful for automation markers like seed/config versions."},"display_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Display Config","description":"Display configuration for public retriever UI rendering (OPTIONAL). Defines how the search interface should appear when the retriever is published, including input fields, theme, layout, exposed result fields, and field formatting. This configuration is used as the default when publishing the retriever."},"version":{"type":"integer","minimum":1.0,"title":"Version","description":"Version number that increments on each update (REQUIRED).","default":1},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp in UTC (REQUIRED)."},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp in UTC (REQUIRED)."},"created_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By","description":"Identifier of the user who created the retriever (OPTIONAL)."},"updated_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Updated By","description":"Identifier of the user who last updated the retriever (OPTIONAL)."},"fusion":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fusion","description":"Fusion strategy used by this retriever's feature_search stage (e.g. 'learned', 'rrf', 'dbsf'). Null if no feature_search stage.","readOnly":true},"collection_identifiers":{"items":{"type":"string"},"type":"array","title":"Collection Identifiers","description":"Mirror of collection_ids under the field name CREATE accepts (collection_identifiers), so a create → read round-trip reads back the field it wrote. Always equal to collection_ids (FRUSTRATIONS 2026-07-16: SDKs/agents re-reading their own write saw collection_identifiers null and concluded the retriever was unscoped).","readOnly":true}},"type":"object","required":["retriever_name","stages","fusion","collection_identifiers"],"title":"RetrieverConfig","description":"Full retriever definition persisted in MongoDB.","examples":[{"budget_limits":{"max_credits":100,"max_time_ms":60000},"collection_ids":["col_marketing_ads"],"input_schema":{"query_text":{"description":"Full-text query","type":"string"}},"retriever_id":"ret_abc123","retriever_name":"executive_ads_search","stages":[{"config":{"parameters":{"field":"metadata.spend","operator":"gt","value":1000},"stage_id":"attribute_filter"},"stage_name":"filter_high_spend","stage_type":"filter"}]}]},"RetrieverEnrichmentConfig-Input":{"properties":{"retriever_id":{"type":"string","title":"Retriever Id","description":"ID of the retriever to execute","examples":["ret_classifier_001","ret_cross_reference"]},"input_mappings":{"items":{"$ref":"#/components/schemas/EnrichmentInputMapping"},"type":"array","minItems":1,"title":"Input Mappings","description":"Map document fields or constants to retriever input parameters"},"write_back_fields":{"items":{"$ref":"#/components/schemas/WriteBackFieldMapping"},"type":"array","minItems":1,"title":"Write Back Fields","description":"Which retriever result fields to write back to the document"},"execution_phase":{"$ref":"#/components/schemas/PostProcessingPhase","description":"Which phase this enrichment runs in. Default: RETRIEVER_ENRICHMENT (phase 4, after taxonomies, clusters, and alerts)","default":4},"priority":{"type":"integer","maximum":1000.0,"minimum":0.0,"title":"Priority","description":"Priority within the execution phase (higher = runs first)","default":0},"scroll_filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"Optional filters to select which documents to enrich"},"enabled":{"type":"boolean","title":"Enabled","description":"Whether this enrichment is active","default":true}},"type":"object","required":["retriever_id","input_mappings","write_back_fields"],"title":"RetrieverEnrichmentConfig","description":"Configuration for attaching a retriever enrichment to a collection.\n\nRetriever enrichments run a retriever pipeline on each document during\npost-processing and write selected result fields back to the document.\n\nAttributes:\n    retriever_id: ID of the retriever to execute\n    input_mappings: How to map document fields to retriever inputs\n    write_back_fields: Which result fields to write back to the document\n    execution_phase: Which post-processing phase to run in (default: RETRIEVER_ENRICHMENT)\n    priority: Priority within the execution phase (higher = runs first)\n    scroll_filters: Optional filters to select which documents to enrich\n    enabled: Whether this enrichment is active","examples":[{"enabled":true,"input_mappings":[{"input_key":"query","source":{"path":"title","source_type":"document_field"}}],"retriever_id":"ret_classifier_001","write_back_fields":[{"mode":"first","source_field":"category","target_field":"_enrichment_category"}]}]},"RetrieverEnrichmentConfig-Output":{"properties":{"retriever_id":{"type":"string","title":"Retriever Id","description":"ID of the retriever to execute","examples":["ret_classifier_001","ret_cross_reference"]},"input_mappings":{"items":{"$ref":"#/components/schemas/EnrichmentInputMapping"},"type":"array","minItems":1,"title":"Input Mappings","description":"Map document fields or constants to retriever input parameters"},"write_back_fields":{"items":{"$ref":"#/components/schemas/WriteBackFieldMapping"},"type":"array","minItems":1,"title":"Write Back Fields","description":"Which retriever result fields to write back to the document"},"execution_phase":{"$ref":"#/components/schemas/PostProcessingPhase","description":"Which phase this enrichment runs in. Default: RETRIEVER_ENRICHMENT (phase 4, after taxonomies, clusters, and alerts)","default":4},"priority":{"type":"integer","maximum":1000.0,"minimum":0.0,"title":"Priority","description":"Priority within the execution phase (higher = runs first)","default":0},"scroll_filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Output"},{"type":"null"}],"description":"Optional filters to select which documents to enrich"},"enabled":{"type":"boolean","title":"Enabled","description":"Whether this enrichment is active","default":true}},"type":"object","required":["retriever_id","input_mappings","write_back_fields"],"title":"RetrieverEnrichmentConfig","description":"Configuration for attaching a retriever enrichment to a collection.\n\nRetriever enrichments run a retriever pipeline on each document during\npost-processing and write selected result fields back to the document.\n\nAttributes:\n    retriever_id: ID of the retriever to execute\n    input_mappings: How to map document fields to retriever inputs\n    write_back_fields: Which result fields to write back to the document\n    execution_phase: Which post-processing phase to run in (default: RETRIEVER_ENRICHMENT)\n    priority: Priority within the execution phase (higher = runs first)\n    scroll_filters: Optional filters to select which documents to enrich\n    enabled: Whether this enrichment is active","examples":[{"enabled":true,"input_mappings":[{"input_key":"query","source":{"path":"title","source_type":"document_field"}}],"retriever_id":"ret_classifier_001","write_back_fields":[{"mode":"first","source_field":"category","target_field":"_enrichment_category"}]}]},"RetrieverExecutionRequest":{"properties":{"inputs":{"additionalProperties":true,"type":"object","title":"Inputs","description":"Runtime inputs for the retriever mapped to the input schema. Keys must match the retriever's input_schema field names. Values depend on field types (text, vector, filters, etc.). REQUIRED unless all retriever inputs have defaults. \n\nCommon input keys:\n- 'query': Text search query\n- 'embedding': Pre-computed vector for search\n- 'top_k': Number of results to return\n- 'min_score': Minimum relevance threshold\n- Any custom fields defined in input_schema\n\n\n**Template Syntax** (Jinja2):\n\nNamespaces (uppercase or lowercase):\n- `INPUT` / `input`: Query inputs (e.g., `{{INPUT.query}}`)\n- `DOC` / `doc`: Document fields (e.g., `{{DOC.payload.title}}`)\n- `CONTEXT` / `context`: Execution context\n- `STAGE` / `stage`: Stage configuration\n- `SECRET` / `secret`: Vault secrets (e.g., `{{SECRET.api_key}}`)\n\nAccessing Data:\n- Dot notation: `{{DOC.payload.metadata.title}}`\n- Bracket notation: `{{DOC.payload['special-key']}}`\n- Array index: `{{DOC.items[0]}}`, `{{DOC.tags[2]}}`\n- Array first/last: `{{DOC.items | first}}`, `{{DOC.items | last}}`\n\nArray Operations:\n- Iterate: `{% for item in DOC.tags %}{{item}}{% endfor %}`\n- Extract key: `{{DOC.items | map(attribute='name') | list}}`\n- Join: `{{DOC.tags | join(', ')}}`\n- Length: `{{DOC.items | length}}`\n- Slice: `{{DOC.items[:5]}}`\n\nConditionals:\n- If: `{% if DOC.status == 'active' %}...{% endif %}`\n- If-else: `{% if DOC.score > 0.8 %}high{% else %}low{% endif %}`\n- Ternary: `{{'yes' if DOC.enabled else 'no'}}`\n\nBuilt-in Functions: `max`, `min`, `abs`, `round`, `ceil`, `floor`, `utc_now`, `time_ago`\nTime Functions: `{{utc_now()}}` returns current UTC as ISO-8601, `{{time_ago(minutes=5)}}` returns UTC minus duration\nCustom Filters: `slugify` (URL-safe), `bool` (truthy coercion), `tojson` (JSON encode), `regex_search(pattern, group=0, ignore_case=false)` (first match, or '')\n\nS3 URLs: Internal S3 URLs (s3://bucket/key) are automatically presigned when accessed via DOC namespace.","examples":[{"query":"artificial intelligence","top_k":25},{"min_score":0.7,"query":"customer feedback","top_k":50},{"category":"blog","embedding":[0.1,0.2,0.3],"top_k":10}]},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","description":"Optional ad-hoc filters applied at execution time. Merged (AND) with any filters already defined in the retriever's stages. Uses the standard LogicalOperator format: {\"AND\": [{\"field\": \"brand\", \"operator\": \"eq\", \"value\": \"Acme\"}]}. Supports operators: eq, ne, in, nin, gt, gte, lt, lte, contains, exists, is_null.","examples":[{"AND":[{"field":"brand","operator":"eq","value":"Acme"}]},{"AND":[{"field":"status","operator":"in","value":["active","pending"]},{"field":"score","operator":"gte","value":0.5}]}]},"pagination":{"oneOf":[{"$ref":"#/components/schemas/OffsetPaginationParams"},{"$ref":"#/components/schemas/CursorPaginationParams"},{"$ref":"#/components/schemas/ScrollPaginationParams"},{"$ref":"#/components/schemas/KeysetPaginationParams"}],"title":"Pagination","description":"Pagination strategy configuration. When omitted entirely, defaults to cursor-based pagination sized to the pipeline's declared final_top_k (author intent); pipelines that declare no final_top_k default to limit=10. Any explicit pagination (or the deprecated body 'limit') is honored exactly. \n\nIMPORTANT: Pagination params do NOT support template variables ({{INPUT.x}} or {{DOCUMENT.x}}). Pagination is a request-level parameter for slicing results, separate from pipeline business logic. Pass cursor/limit values directly from your client code. Cursor values come from the previous response's pagination.cursor field.\n\nSupported Methods:\n- CURSOR (default): Best for infinite scroll, stateless, opaque token\n- KEYSET: Most efficient, requires stable sort, stateless\n- OFFSET: Traditional page numbers, can have drift issues\n- SCROLL: Server-side state, best for bulk exports\n\n\nUse CURSOR for:\n- Infinite scroll UIs (mobile apps, feeds, timelines)\n- Real-time updates where consistency matters\n- When you can't jump to arbitrary pages\n\n\nUse KEYSET for:\n- Maximum performance with large result sets\n- Stable sort fields (e.g., score DESC, id ASC)\n- When you need truly stateless pagination\n\n\nUse OFFSET for:\n- Traditional page UIs with page numbers\n- When users need to jump to specific pages\n- Smaller result sets where drift is acceptable\n\n\nUse SCROLL for:\n- Bulk exports or processing large datasets\n- When you need to iterate through all results\n- Background jobs with progress tracking\n\n\nExample (cursor - first page):\n{\"method\": \"cursor\", \"limit\": 20, \"cursor\": null}\n\nExample (cursor - next page, using cursor from previous response):\n{\"method\": \"cursor\", \"limit\": 20, \"cursor\": \"eyJvZmZzZXQiOjIwfQ==\"}\n\nExample (offset):\n{\"method\": \"offset\", \"page_size\": 25, \"page_number\": 2}\n\nExample (keyset):\n{\"method\": \"keyset\", \"limit\": 20, \"after\": {\"score\": 0.73, \"id\": \"doc_20\"}}\n","discriminator":{"propertyName":"method","mapping":{"cursor":"#/components/schemas/CursorPaginationParams","keyset":"#/components/schemas/KeysetPaginationParams","offset":"#/components/schemas/OffsetPaginationParams","scroll":"#/components/schemas/ScrollPaginationParams"}}},"limit":{"anyOf":[{"type":"integer","maximum":500.0,"minimum":1.0},{"type":"null"}],"title":"Limit","description":"Shorthand for the pagination page size: the most documents this response returns. A top-level 'page_size' is accepted as the same value. Prefer 'pagination' (for example {\"method\": \"cursor\", \"limit\": 100}). When 'pagination' is absent, this value sizes the default cursor pagination of the final result set, and the response's pagination cursor fetches the next page. When both are sent and disagree, 'pagination' wins and a top-level response warning names the conflict. Sending 'limit' and 'page_size' with different values is refused.","deprecated":true,"examples":[null,25]},"stream":{"type":"boolean","title":"Stream","description":"Enable streaming execution to receive real-time stage updates via Server-Sent Events (SSE). NOT REQUIRED - defaults to False for standard execution. \n\nWhen stream=True:\n- Response uses text/event-stream content type\n- Each stage completion emits a StreamStageEvent\n- Events include: stage_start, stage_complete, stage_error, execution_complete\n- Clients receive intermediate results and statistics as stages execute\n- Useful for progress tracking, debugging, and partial result display\n\n\nWhen stream=False (default):\n- Response returns after all stages complete\n- Returns a single RetrieverExecutionResponse with final results\n- Lower overhead for simple queries\n\n\nUse streaming when:\n- You want to show real-time progress to users\n- You need to display intermediate results\n- Pipeline has many stages or long-running operations\n- Debugging or monitoring pipeline performance\n\n\nExample streaming client (JavaScript):\n```javascript\nconst eventSource = new EventSource('/v1/retrievers/ret_123/execute?stream=true');\neventSource.onmessage = (event) => {\n  const stageEvent = JSON.parse(event.data);\n  if (stageEvent.event_type === 'stage_complete') {\n    console.log(`Stage ${stageEvent.stage_name} completed`);\n    console.log(`Documents: ${stageEvent.documents.length}`);\n  }\n};\n```\n\n\nExample streaming client (Python):\n```python\nimport requests\nresponse = requests.post('/v1/retrievers/ret_123/execute',\n                        json={'inputs': {...}, 'stream': True},\n                        stream=True)\nfor line in response.iter_lines():\n    if line.startswith(b'data: '):\n        event = json.loads(line[6:])\n        print(f\"Stage {event['stage_name']}: {event['event_type']}\")\n```","default":false,"examples":[false,true]},"expand":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Expand","description":"OPTIONAL. List of fields containing document IDs to resolve inline. Referenced documents are fetched and attached under an '_expanded' key in each result document. Supports dot-notation for nested fields (e.g., 'items.product_id'). Max 50 unique references per request. Depth is limited to 1 (no recursive expansion).","examples":[["customer_id"],["customer_id","items.product_id"]]},"skip_cache":{"type":"boolean","title":"Skip Cache","description":"OPTIONAL. Bypass stage result cache for this execution. When True, all stages execute fresh without cache lookup. Useful after corpus updates, retriever config changes, or engine deploys. Results are still written to cache for future requests.","default":false,"examples":[false,true]},"return_presigned_urls":{"type":"boolean","title":"Return Presigned Urls","description":"Generate presigned URLs for S3-backed blobs and url-shaped fields in result documents. Also accepted as a `return_presigned_urls` query parameter; if either source is true, presigning is enabled.","default":false,"examples":[false,true]},"return_vectors":{"type":"boolean","title":"Return Vectors","description":"Include vector embeddings in result documents. Also accepted as a `return_vectors` query parameter; if either source is true, vectors are returned.","default":false,"examples":[false,true]},"write_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Write Token","description":"OPTIONAL. Pass the `write_token` returned by a prior direct upsert (options.write_token=true) to get read-your-writes consistency: the read is routed to the primary shard, where your just-written document is immediately searchable, instead of an eventually-consistent replica that can lag several seconds behind. Omit for normal (eventual) reads."},"consistency":{"anyOf":[{"$ref":"#/components/schemas/ReadConsistencyOption"},{"type":"null"}],"description":"OPTIONAL. The read consistency for this execution. Omit to use the deployment default. A write_token always reads strong."}},"type":"object","title":"RetrieverExecutionRequest","description":"Request payload for executing a retriever.\n\nExecutes a predefined retriever with runtime inputs. The retriever uses the\ncollections it was created with - collection overrides are not supported at\nexecution time to ensure feature_uri and schema validation integrity.\n\nAll filtering, pagination, and result shaping is handled by the individual stages\nbased on the inputs provided.\n\nUse Cases:\n    - Execute retriever with its configured collections\n    - Pass inputs that stages use to determine filtering/pagination behavior\n\nDesign Philosophy:\n    - Retrievers are validated at creation time against their collections\n    - Feature URIs, input schemas, and stage configs are tightly coupled to collections\n    - Filters, limits, and offsets are NOT top-level request fields\n    - These are handled by stages when they receive inputs\n    - Example: A stage might read {INPUT.top_k} to determine result limit\n\nExamples:\n    Simple query:\n        {\"inputs\": {\"query\": \"AI\", \"top_k\": 50}}\n\n    Different inputs for stage behavior:\n        {\"inputs\": {\n            \"query\": \"machine learning\",\n            \"top_k\": 100,\n            \"min_score\": 0.7,\n            \"published_after\": \"2024-01-01\"\n         }}","examples":[{"description":"Simple query","inputs":{"query":"artificial intelligence trends","top_k":25}},{"description":"Query with stage-driven filtering via inputs","inputs":{"categories":["AI","ML"],"min_score":0.7,"published_after":"2024-01-01","query":"machine learning","top_k":100}},{"description":"Advanced query with multiple input parameters","inputs":{"date_range":{"end":"2024-12-31","start":"2024-01-01"},"query":"customer testimonials","sentiment":"positive","top_k":20}},{"description":"Infinite scroll with cursor pagination (first page)","inputs":{"query":"AI trends","top_k":50},"pagination":{"limit":20,"method":"cursor"}},{"description":"Infinite scroll (next page using cursor from previous response)","inputs":{"query":"AI trends","top_k":50},"pagination":{"cursor":"eyJvZmZzZXQiOjIwfQ==","limit":20,"method":"cursor"}},{"description":"Traditional pagination with page numbers","inputs":{"query":"ML papers"},"pagination":{"method":"offset","page_number":2,"page_size":25}},{"description":"High-performance keyset pagination","inputs":{"query":"customer reviews","top_k":100},"pagination":{"after":{"id":"doc_20","score":0.73},"limit":20,"method":"keyset"}},{"description":"Scroll pagination for bulk export","inputs":{"query":"all documents"},"pagination":{"limit":100,"method":"scroll","scroll_ttl":300}}]},"RetrieverExecutionStatistics":{"properties":{"stages":{"additionalProperties":{"$ref":"#/components/schemas/StageStatistics"},"type":"object","title":"Stages","description":"Per-stage statistics keyed by stage instance name (REQUIRED)."},"total_time_ms":{"type":"number","minimum":0.0,"title":"Total Time Ms","description":"Total retriever execution time in milliseconds (REQUIRED).","default":0.0},"credits_used":{"type":"number","minimum":0.0,"title":"Credits Used","description":"Same value as budget.credits_used on an execute response.","default":0.0},"server_service_ms":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Server Service Ms","description":"Controller-measured service span in ms: the wall time of the service.execute_retriever call, stamped by the API controller after execution. Partitions request latency beyond the stages: middleware total minus this = pre-body (DI/auth/tenant resolution); this minus the stage sum = service-outside-stages (cache lookup, plan build, serialization). None on cache-hit replays, whose statistics belong to a different execution."}},"type":"object","title":"RetrieverExecutionStatistics","description":"Aggregated execution statistics for an entire retriever execution run."},"RetrieverExecutionSummary":{"properties":{"execution_id":{"type":"string","title":"Execution Id","description":"Execution identifier"},"status":{"type":"string","title":"Status","description":"Execution status"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"Completion timestamp when available"},"duration_ms":{"type":"number","minimum":0.0,"title":"Duration Ms","description":"Total execution time in ms"},"credits_used":{"type":"number","minimum":0.0,"title":"Credits Used","description":"Credits consumed"},"total_processed":{"type":"integer","minimum":0.0,"title":"Total Processed","description":"Documents processed across stages"},"total_returned":{"type":"integer","minimum":0.0,"title":"Total Returned","description":"Documents returned to caller"},"cache_hit_rate":{"anyOf":[{"type":"number","maximum":1.0,"minimum":0.0},{"type":"null"}],"title":"Cache Hit Rate","description":"Average cache hit rate for stages"},"inputs_hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inputs Hash","description":"Stable hash of retriever inputs for dedupe"},"query_summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Query Summary","description":"Representative snippet of query inputs"},"trace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trace Id","description":"Trace identifier recorded when this execution ran. Quote it to Mixpeek support to find the request's trace. Null for executions recorded before trace ids were stored."}},"type":"object","required":["execution_id","status","created_at","duration_ms","credits_used","total_processed","total_returned"],"title":"RetrieverExecutionSummary","description":"Summary document used for execution history listings."},"RetrieverInputSchemaField-Input":{"properties":{"type":{"$ref":"#/components/schemas/RetrieverInputSchemaFieldType"},"default":{"anyOf":[{},{"type":"null"}],"title":"Default"},"items":{"anyOf":[{"$ref":"#/components/schemas/RetrieverInputSchemaField-Input"},{"type":"null"}]},"properties":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/RetrieverInputSchemaField-Input"},"type":"object"},{"type":"null"}],"title":"Properties"},"examples":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Examples","description":"OPTIONAL. List of example values for this field. Used by Apps to show example inputs in the UI. Provide multiple diverse examples when possible."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"enum":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Enum"},"required":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Required","default":false}},"additionalProperties":true,"type":"object","required":["type"],"title":"RetrieverInputSchemaField","description":"Schema field definition for retriever input parameters.\n\nIdentical structure to BucketSchemaField but uses RetrieverInputSchemaFieldType\nwhich includes additional reference types like document_reference.\n\nThis allows retrievers to accept:\n1. Metadata inputs (strings, numbers, dates, etc.)\n2. File inputs (images, videos, documents for search)\n3. Reference inputs (document_reference for \"find similar\" queries)"},"RetrieverInputSchemaField-Output":{"properties":{"type":{"$ref":"#/components/schemas/RetrieverInputSchemaFieldType"},"default":{"anyOf":[{},{"type":"null"}],"title":"Default"},"items":{"anyOf":[{"$ref":"#/components/schemas/RetrieverInputSchemaField-Output"},{"type":"null"}]},"properties":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/RetrieverInputSchemaField-Output"},"type":"object"},{"type":"null"}],"title":"Properties"},"examples":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Examples","description":"OPTIONAL. List of example values for this field. Used by Apps to show example inputs in the UI. Provide multiple diverse examples when possible."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"enum":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Enum"},"required":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Required","default":false}},"additionalProperties":true,"type":"object","required":["type"],"title":"RetrieverInputSchemaField","description":"Schema field definition for retriever input parameters.\n\nIdentical structure to BucketSchemaField but uses RetrieverInputSchemaFieldType\nwhich includes additional reference types like document_reference.\n\nThis allows retrievers to accept:\n1. Metadata inputs (strings, numbers, dates, etc.)\n2. File inputs (images, videos, documents for search)\n3. Reference inputs (document_reference for \"find similar\" queries)"},"RetrieverInputSchemaFieldType":{"type":"string","enum":["string","number","integer","float","boolean","object","array","date","datetime","text","image","audio","video","pdf","excel","document_reference"],"title":"RetrieverInputSchemaFieldType","description":"Supported data types for retriever input schema fields.\n\nRetriever input schemas define what parameters users can provide when executing\na retriever. This includes all bucket schema types plus additional reference types.\n\nTypes fall into three categories:\n\n1. **Metadata Types** (JSON types):\n   - Standard JSON-compatible types\n   - Examples: string, number, boolean, date\n   - Inherited from BucketSchemaFieldType\n\n2. **File Types** (blobs):\n   - Users can upload files/content as search inputs\n   - Examples: text, image, video, pdf\n   - Inherited from BucketSchemaFieldType\n\n3. **Reference Types** (structured metadata):\n   - Special types for referencing existing documents\n   - Examples: document_reference\n   - Only available in retriever input schemas (NOT in bucket schemas)\n\n**DOCUMENT_REFERENCE Usage**:\n    Accept document reference for \"find similar\" queries.\n\n    Example - Find similar products retriever:\n    {\n        \"reference_product\": {\n            \"type\": \"document_reference\",\n            \"description\": \"Find products similar to this one\",\n            \"required\": true\n        }\n    }\n\n    Execution input:\n    {\n        \"inputs\": {\n            \"reference_product\": {\n                \"collection_id\": \"col_products\",\n                \"document_id\": \"doc_item_123\"\n            }\n        }\n    }\n\n    The system will use the pre-computed features from doc_item_123\n    to find similar documents without re-processing."},"RetrieverMetadata":{"properties":{"stages":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Stages","description":"Pipeline stages used in this retriever","examples":[[{"stage_name":"feature_filter","stage_type":"filter"},{"stage_name":"llm_filter","stage_type":"filter"}]]},"collections":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Collections","description":"Collections and feature extractors used","examples":[[{"collection_id":"col_abc123","collection_name":"Products","feature_extractor":{"name":"multimodal_extractor","version":"v1"}}]]},"capabilities":{"additionalProperties":true,"type":"object","title":"Capabilities","description":"Capabilities and features of this retriever","examples":[{"multi_stage_pipeline":true,"stage_count":2,"supports_image_search":true,"supports_text_search":true}]}},"type":"object","title":"RetrieverMetadata","description":"Metadata explaining how the retriever works.\n\nThis is separate from DisplayConfig and provides technical information\nabout the retriever's architecture for developers/debugging."},"RetrieverModel-Input":{"properties":{"retriever_id":{"type":"string","title":"Retriever Id","description":"Unique identifier for the retriever"},"retriever_name":{"type":"string","title":"Retriever Name","description":"Name of the retriever"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Description of the retriever"},"visibility":{"$ref":"#/components/schemas/RetrieverVisibility","description":"Visibility level: PRIVATE (owner only), PUBLIC (any valid API key), MARKETPLACE (requires subscription)","default":"private"},"marketplace_listing_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Marketplace Listing Id","description":"Associated marketplace listing ID when visibility is MARKETPLACE"},"requires_subscription":{"type":"boolean","title":"Requires Subscription","description":"Whether this retriever requires an active subscription to access (marketplace only)","default":false},"input_schema":{"$ref":"#/components/schemas/RetrieverSchema","description":"Input schema for the retriever"},"collection_ids":{"items":{"type":"string"},"type":"array","title":"Collection Ids","description":"List of collection IDs"},"stages":{"items":{"$ref":"#/components/schemas/StageInstanceConfig"},"type":"array","title":"Stages","description":"List of stage configurations"},"cache_config":{"anyOf":[{"$ref":"#/components/schemas/CacheConfig"},{"type":"null"}],"description":"Cache configuration for this retriever. If not provided, caching is disabled."},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"When the retriever was created"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"When the retriever was last modified"},"last_executed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Executed At","description":"When the retriever was last executed"},"enabled":{"type":"boolean","title":"Enabled","description":"Whether the retriever is enabled (can be toggled on/off)","default":true},"status":{"$ref":"#/components/schemas/RetrieverStatus","description":"Current operational status","default":"active"},"usage_stats":{"anyOf":[{"$ref":"#/components/schemas/UsageStatistics"},{"type":"null"}],"description":"Usage and performance statistics"},"collections":{"anyOf":[{"items":{"$ref":"#/components/schemas/CollectionDetail"},"type":"array"},{"type":"null"}],"title":"Collections","description":"Expanded collection details with names and metadata"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Custom key-value metadata"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Tags for organization and filtering"},"created_by":{"anyOf":[{"$ref":"#/components/schemas/CreatorInfo"},{"type":"null"}],"description":"Information about who created this retriever"},"updated_by":{"anyOf":[{"$ref":"#/components/schemas/CreatorInfo"},{"type":"null"}],"description":"Information about who last updated this retriever"},"version":{"type":"integer","title":"Version","description":"Version number (increments on each update)","default":1},"revision_history":{"items":{"$ref":"#/components/schemas/RevisionHistoryEntry"},"type":"array","title":"Revision History","description":"History of changes (optional, last N changes)"},"health":{"anyOf":[{"$ref":"#/components/schemas/HealthCheck"},{"type":"null"}],"description":"Health status and diagnostics"}},"type":"object","required":["retriever_name","input_schema","collection_ids","stages"],"title":"RetrieverModel","description":"Retriever model."},"RetrieverModel-Output":{"properties":{"retriever_id":{"type":"string","title":"Retriever Id","description":"Stable retriever identifier (REQUIRED)."},"retriever_name":{"type":"string","minLength":1,"title":"Retriever Name","description":"Unique retriever name within namespace (REQUIRED)."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Detailed description of retriever behaviour (OPTIONAL)."},"collection_ids":{"items":{"type":"string"},"type":"array","title":"Collection Ids","description":"Collections queried by the retriever. Can be empty for query-only inference mode."},"stages":{"items":{"$ref":"#/components/schemas/StageConfig-Output"},"type":"array","minItems":1,"title":"Stages","description":"Ordered list of stage configurations (REQUIRED)."},"input_schema":{"additionalProperties":{"$ref":"#/components/schemas/RetrieverInputSchemaField-Output","description":"Schema definition for this input field. Defines type, description, examples, and validation rules. Supports all bucket types (string, number, image, etc.) plus document_reference. Frontend uses this to render the appropriate input component (text input, image upload, dropdown, etc.)"},"type":"object","title":"Input Schema","description":"JSON Schema describing expected user inputs (REQUIRED). Properties must use RetrieverInputSchemaField which supports all bucket types plus document_reference."},"budget_limits":{"$ref":"#/components/schemas/BudgetLimits","description":"Execution budget limits for the retriever (OPTIONAL)."},"feature_dependencies":{"anyOf":[{"items":{"$ref":"#/components/schemas/FeatureAddress"},"type":"array"},{"type":"null"}],"title":"Feature Dependencies","description":"Feature addresses required by stages (OPTIONAL, aids validation)."},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Arbitrary tags to help organise retrievers (OPTIONAL)."},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Custom key-value metadata (OPTIONAL). Round-trips on create/get/list and is updatable via PATCH — useful for automation markers like seed/config versions."},"display_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Display Config","description":"Display configuration for public retriever UI rendering (OPTIONAL). Defines how the search interface should appear when the retriever is published, including input fields, theme, layout, exposed result fields, and field formatting. This configuration is used as the default when publishing the retriever."},"version":{"type":"integer","minimum":1.0,"title":"Version","description":"Version number that increments on each update (REQUIRED).","default":1},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp in UTC (REQUIRED)."},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp in UTC (REQUIRED)."},"created_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By","description":"Identifier of the user who created the retriever (OPTIONAL)."},"updated_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Updated By","description":"Identifier of the user who last updated the retriever (OPTIONAL)."},"is_published":{"type":"boolean","title":"Is Published","description":"Whether this retriever is currently published (either as public retriever or in marketplace)","default":false},"marketplace_listing_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Marketplace Listing Id","description":"Marketplace listing ID if this retriever is published to the marketplace, None otherwise"},"fusion":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fusion","description":"Fusion strategy used by this retriever's feature_search stage (e.g. 'learned', 'rrf', 'dbsf'). Null if no feature_search stage.","readOnly":true},"collection_identifiers":{"items":{"type":"string"},"type":"array","title":"Collection Identifiers","description":"Mirror of collection_ids under the field name CREATE accepts (collection_identifiers), so a create → read round-trip reads back the field it wrote. Always equal to collection_ids (FRUSTRATIONS 2026-07-16: SDKs/agents re-reading their own write saw collection_identifiers null and concluded the retriever was unscoped).","readOnly":true}},"type":"object","required":["retriever_name","stages","fusion","collection_identifiers"],"title":"RetrieverModel","description":"Retriever configuration model exposed via API.","examples":[{"budget_limits":{"max_credits":100,"max_time_ms":60000},"collection_ids":["col_marketing_ads"],"input_schema":{"query_text":{"description":"Full-text query","type":"string"}},"retriever_id":"ret_abc123","retriever_name":"executive_ads_search","stages":[{"config":{"parameters":{"field":"metadata.spend","operator":"gt","value":1000},"stage_id":"attribute_filter"},"stage_name":"filter_high_spend","stage_type":"filter"}]}]},"RetrieverOptions":{"properties":{"preserve_retriever_ids":{"type":"boolean","title":"Preserve Retriever Ids","description":"Keep same retriever IDs (avoid conflicts)","default":false},"migrate_interactions":{"type":"boolean","title":"Migrate Interactions","description":"Migrate user interaction data","default":false},"migrate_execution_history":{"type":"boolean","title":"Migrate Execution History","description":"Migrate past execution history","default":false},"validate_references":{"type":"boolean","title":"Validate References","description":"Pre-flight check all references exist","default":true}},"type":"object","title":"RetrieverOptions","description":"Options for retriever migration."},"RetrieverParityResult":{"properties":{"retriever_name":{"type":"string","title":"Retriever Name"},"status":{"type":"string","title":"Status","description":"'match' (same ordered top-k), 'mismatch', 'skipped' (no probe input), 'missing_in_target', or 'error'"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"},"probe_inputs":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Probe Inputs"},"source_top_k":{"items":{"type":"string"},"type":"array","title":"Source Top K"},"target_top_k":{"items":{"type":"string"},"type":"array","title":"Target Top K"},"overlap":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Overlap","description":"Document ids the two top-k lists share"}},"type":"object","required":["retriever_name","status"],"title":"RetrieverParityResult","description":"One retriever's top-k answer in the source vs the restored namespace."},"RetrieverPerformanceResponse":{"properties":{"retriever_id":{"type":"string","title":"Retriever Id","description":"Retriever identifier","examples":["ret_abc123"]},"time_range":{"$ref":"#/components/schemas/api__analytics__models__TimeRange","description":"Time range of the data"},"metrics":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Metrics","description":"Time-series performance metrics"},"summary":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Summary","description":"Aggregated summary statistics"}},"type":"object","required":["retriever_id","time_range","metrics"],"title":"RetrieverPerformanceResponse","description":"Retriever performance metrics response.","examples":[{"metrics":[{"avg_latency_ms":145.3,"avg_results":10.5,"p95_latency_ms":287.5,"p99_latency_ms":456.2,"query_count":245,"time_bucket":"2025-10-28T00:00:00Z"}],"retriever_id":"ret_abc123","summary":{"avg_latency_ms":152.8,"p95_latency_ms":295.2,"p99_latency_ms":502.1,"total_queries":5234},"time_range":{"end":"2025-10-29T00:00:00Z","start":"2025-10-28T00:00:00Z"}}]},"RetrieverSchema":{"properties":{"properties":{"additionalProperties":{"$ref":"#/components/schemas/RetrieverInputSchemaField-Input","description":"Schema definition for this input field. Defines type, description, examples, and validation rules. Supports all bucket types (string, number, image, etc.) plus document_reference. Frontend uses this to render the appropriate input component (text input, image upload, dropdown, etc.)"},"type":"object","title":"Properties","description":"Schema properties for retriever inputs"}},"additionalProperties":true,"type":"object","title":"RetrieverSchema","description":"Schema definition for retriever inputs."},"RetrieverSignal":{"properties":{"timestamp":{"type":"string","format":"date-time","title":"Timestamp","description":"Event timestamp"},"execution_id":{"type":"string","title":"Execution Id","description":"Execution identifier"},"signal_type":{"type":"string","title":"Signal Type","description":"Type of signal","examples":["cache_hit","rerank_scores","filter_reduction"]},"signal_data":{"additionalProperties":true,"type":"object","title":"Signal Data","description":"Signal-specific data"},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Additional metadata"}},"type":"object","required":["timestamp","execution_id","signal_type","signal_data"],"title":"RetrieverSignal","description":"Single retriever signal event."},"RetrieverStageDefinition":{"properties":{"stage_id":{"type":"string","title":"Stage Id","description":"REQUIRED. Unique identifier for the stage type. Use this ID in the 'stage_id' field when configuring stages in a retriever. Common stage IDs: 'attribute_filter', 'feature_filter', 'llm_filter', 'sort_relevance', 'document_enrich', 'taxonomy_enrich'. Stage IDs are immutable and versioned separately from implementation.","examples":["attribute_filter","feature_filter","llm_filter","sort_relevance","document_enrich"]},"description":{"type":"string","title":"Description","description":"REQUIRED. Human-readable description of what the stage does. Explains the stage's purpose, behavior, and when to use it. Use this to understand stage capabilities before using in pipelines.","examples":["Filter documents by attribute conditions with boolean logic","Unified multi-vector search with N feature URIs and fusion","Filter documents using LLM-based reasoning and natural language criteria","Sort documents by relevance scores"]},"category":{"$ref":"#/components/schemas/StageCategory","description":"REQUIRED. Transformation category defining how the stage processes documents. Categories: 'filter' (subset, N→≤N), 'sort' (reorder, N→N), 'reduce' (aggregate, N→1), 'apply' (enrich/expand, N→N or N→N*M). Use category to understand stage's impact on document flow.","examples":["filter","sort","reduce","apply"]},"icon":{"type":"string","title":"Icon","description":"REQUIRED. Lucide React icon identifier for UI rendering. Used by frontend clients to display stage icons in pipeline builders. See https://lucide.dev for available icon names. Common icons: 'filter' (attribute_filter), 'search' (semantic), 'brain-circuit' (LLM), 'arrow-up-down' (sort).","examples":["filter","search","brain-circuit","arrow-up-down","database"]},"parameter_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Parameter Schema","description":"OPTIONAL. JSON Schema defining the parameters this stage accepts. Contains full Pydantic schema including types, descriptions, examples, and validation rules for all stage parameters. Use this schema to validate stage configurations before submission. Null if stage requires no parameters (rare). Schema includes: field types, required fields, defaults, validation constraints, field descriptions, and usage examples.","examples":[{"properties":{"field":{"description":"Dot-delimited field path to evaluate","examples":["metadata.status","metadata.priority"],"type":"string"},"operator":{"description":"Comparison operator","enum":["eq","ne","gt","gte","lt","lte","in","nin"]},"value":{"description":"Comparison value (type depends on field)"}},"required":["field","operator","value"],"type":"object"},null]}},"type":"object","required":["stage_id","description","category","icon"],"title":"RetrieverStageDefinition","description":"Public definition of a retriever stage available in the system.\n\nEach stage represents a specific operation in a retrieval pipeline (filter, sort,\nenrich, etc). Use the `/v1/retrievers/stages` endpoint to discover available stages\nand their parameter schemas before creating retrievers.\n\nStage Registration:\n    - Stages are registered in the retriever stage registry\n    - Each stage has a unique ID, category, and parameter schema\n    - Parameter schemas are Pydantic models with full validation\n\nUsage Flow:\n    1. Call GET /v1/retrievers/stages to list all available stages\n    2. Review parameter_schema for each stage to understand requirements\n    3. Compose stages into a retrieval pipeline\n    4. Create retriever via POST /v1/collections/{id}/retrievers\n\nExample Workflow:\n    ```\n    # 1. Discover stages\n    GET /v1/retrievers/stages\n\n    # 2. Review attribute_filter schema\n    {\n      \"stage_id\": \"attribute_filter\",\n      \"description\": \"Filter documents by attribute conditions\",\n      \"category\": \"filter\",\n      \"parameter_schema\": {\n        \"type\": \"object\",\n        \"properties\": {\n          \"field\": {\"type\": \"string\"},\n          \"operator\": {\"enum\": [\"eq\", \"ne\", \"gt\", \"gte\", \"lt\", \"lte\", \"in\", \"nin\"]},\n          \"value\": {}\n        }\n      }\n    }\n\n    # 3. Create retriever using discovered stage\n    POST /v1/collections/col_123/retrievers\n    {\n      \"stages\": [\n        {\n          \"stage_name\": \"filter_active\",\n          \"stage_type\": \"filter\",\n          \"config\": {\n            \"stage_id\": \"attribute_filter\",\n            \"parameters\": {\n              \"field\": \"status\",\n              \"operator\": \"eq\",\n              \"value\": \"active\"\n            }\n          }\n        }\n      ]\n    }\n    ```\n\nRequirements:\n    - stage_id: REQUIRED, unique identifier for the stage\n    - description: REQUIRED, human-readable description of stage purpose\n    - category: REQUIRED, transformation category (filter/sort/reduce/apply)\n    - icon: REQUIRED, UI icon identifier (Lucide React)\n    - parameter_schema: OPTIONAL, JSON Schema for stage parameters (null if no params)","examples":[{"category":"filter","description":"Filter documents by attribute conditions with boolean logic (AND/OR/NOT). Fast, operates on metadata fields.","icon":"filter","parameter_schema":{"properties":{"field":{"description":"Dot-delimited field path","examples":["metadata.status","metadata.category"],"type":"string"},"operator":{"description":"Comparison operator","enum":["eq","ne","gt","gte","lt","lte"]},"value":{"description":"Comparison value"}},"required":["field","operator","value"],"type":"object"},"stage_id":"attribute_filter"},{"category":"filter","description":"Filter documents using LLM-based reasoning. Slow but powerful for complex semantic filtering.","icon":"brain-circuit","parameter_schema":{"properties":{"provider":{"description":"LLM provider (google, openai, anthropic)","examples":["google","openai","anthropic"],"type":"string"},"model_name":{"description":"Specific model name","examples":["gemini-2.5-flash","gpt-4o-mini","claude-3-5-haiku-20241022"],"type":"string"},"criteria":{"description":"Natural language filtering criteria","examples":["Keep only enterprise-focused content","Discard negative sentiment"],"type":"string"}},"required":["criteria"],"type":"object"},"stage_id":"llm_filter"},{"category":"sort","description":"Sort documents by relevance scores in ascending or descending order.","icon":"arrow-up-down","parameter_schema":{"properties":{"order":{"default":"desc","description":"Sort order","enum":["asc","desc"]}},"type":"object"},"stage_id":"sort_relevance"}]},"RetrieverStatus":{"type":"string","enum":["active","draft","disabled","error"],"title":"RetrieverStatus","description":"Status of a retriever."},"RetrieverTransformConfig-Input":{"properties":{"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id","description":"The saved retriever whose pipeline builds this collection. Name it with retriever_version to pin the version: the collection keeps running that version after the retriever is updated, until the pin moves. Give this or stages, not both.","examples":["ret_brand_rollup"]},"retriever_version":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Retriever Version","description":"The retriever version this collection runs (needs retriever_id). Omitted: the retriever's current version at each run."},"stages":{"anyOf":[{"items":{"$ref":"#/components/schemas/StageConfig-Input"},"type":"array","minItems":1},{"type":"null"}],"title":"Stages","description":"Deprecated: name a saved retriever with retriever_id instead. Inline retriever pipeline run over the source collection. Same stage shape as a retriever's ``stages`` (StageConfig: stage_name, optional stage_type, config:{stage_id, parameters}); stage_id validates against the retriever stage registry. A group_by/reduce stage defines output document cardinality (N source rows -> M output documents).","deprecated":true},"input_mappings":{"anyOf":[{"items":{"$ref":"#/components/schemas/EnrichmentInputMapping"},"type":"array"},{"type":"null"}],"title":"Input Mappings","description":"Optional. Map source-collection document fields (or constants) to the pipeline's input parameters. When omitted, the pipeline runs over the source documents directly."},"write_back_fields":{"anyOf":[{"items":{"$ref":"#/components/schemas/WriteBackFieldMapping"},"type":"array"},{"type":"null"}],"title":"Write Back Fields","description":"Optional. Which pipeline result fields land on the output documents and under what names — this is the collection's output_schema source. When omitted, the reduce/group_by output defines the schema (1:1 passthrough of the pipeline result)."},"unique_id_field":{"anyOf":[{"type":"string"},{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Unique Id Field","description":"Optional (TS ingestion #12). Designate a field, or a list of fields for a composite key, from the pipeline OUTPUT rows whose value becomes each output document's stable, addressable document id. Rows sharing that value collapse to ONE document, and a re-run REPLACES rather than duplicating (deterministic id, upserted by id). Dot-notation paths are supported (e.g. 'metadata.brand'). When omitted, identity falls back to the pipeline's group_by field, then the source document id. This is the transform-collection analogue of a bucket's unique_key. Lineage fields such as source_document_id are not kept on output rows, so a key naming one is refused on create; write the value under another name and key on that.","examples":["video_id",["brand","region"]]}},"type":"object","title":"RetrieverTransformConfig","description":"Whole-collection transform: run a retriever pipeline over this\ncollection's source and write its output as the collection's documents.\n\nName a saved retriever with ``retriever_id``, and pin its version with\n``retriever_version``: the collection keeps running that version after the\nretriever changes, until a PATCH moves the pin. Inline ``stages`` still work\nand are deprecated. A collection is either extractor-based or\ntransform-based. The source may be a collection, or a bucket, in which case\nthe transform reads the bucket's objects through its system collection.\nRe-runs update documents in place: a document's id comes from\n``unique_id_field``, the pipeline's group_by field, or the source document's\nid. ``write_back_fields`` (optional) picks the output fields; without it the\npipeline's output defines them."},"RetrieverTransformConfig-Output":{"properties":{"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id","description":"The saved retriever whose pipeline builds this collection. Name it with retriever_version to pin the version: the collection keeps running that version after the retriever is updated, until the pin moves. Give this or stages, not both.","examples":["ret_brand_rollup"]},"retriever_version":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Retriever Version","description":"The retriever version this collection runs (needs retriever_id). Omitted: the retriever's current version at each run."},"stages":{"anyOf":[{"items":{"$ref":"#/components/schemas/StageConfig-Output"},"type":"array","minItems":1},{"type":"null"}],"title":"Stages","description":"Deprecated: name a saved retriever with retriever_id instead. Inline retriever pipeline run over the source collection. Same stage shape as a retriever's ``stages`` (StageConfig: stage_name, optional stage_type, config:{stage_id, parameters}); stage_id validates against the retriever stage registry. A group_by/reduce stage defines output document cardinality (N source rows -> M output documents).","deprecated":true},"input_mappings":{"anyOf":[{"items":{"$ref":"#/components/schemas/EnrichmentInputMapping"},"type":"array"},{"type":"null"}],"title":"Input Mappings","description":"Optional. Map source-collection document fields (or constants) to the pipeline's input parameters. When omitted, the pipeline runs over the source documents directly."},"write_back_fields":{"anyOf":[{"items":{"$ref":"#/components/schemas/WriteBackFieldMapping"},"type":"array"},{"type":"null"}],"title":"Write Back Fields","description":"Optional. Which pipeline result fields land on the output documents and under what names — this is the collection's output_schema source. When omitted, the reduce/group_by output defines the schema (1:1 passthrough of the pipeline result)."},"unique_id_field":{"anyOf":[{"type":"string"},{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Unique Id Field","description":"Optional (TS ingestion #12). Designate a field, or a list of fields for a composite key, from the pipeline OUTPUT rows whose value becomes each output document's stable, addressable document id. Rows sharing that value collapse to ONE document, and a re-run REPLACES rather than duplicating (deterministic id, upserted by id). Dot-notation paths are supported (e.g. 'metadata.brand'). When omitted, identity falls back to the pipeline's group_by field, then the source document id. This is the transform-collection analogue of a bucket's unique_key. Lineage fields such as source_document_id are not kept on output rows, so a key naming one is refused on create; write the value under another name and key on that.","examples":["video_id",["brand","region"]]}},"type":"object","title":"RetrieverTransformConfig","description":"Whole-collection transform: run a retriever pipeline over this\ncollection's source and write its output as the collection's documents.\n\nName a saved retriever with ``retriever_id``, and pin its version with\n``retriever_version``: the collection keeps running that version after the\nretriever changes, until a PATCH moves the pin. Inline ``stages`` still work\nand are deprecated. A collection is either extractor-based or\ntransform-based. The source may be a collection, or a bucket, in which case\nthe transform reads the bucket's objects through its system collection.\nRe-runs update documents in place: a document's id comes from\n``unique_id_field``, the pipeline's group_by field, or the source document's\nid. ``write_back_fields`` (optional) picks the output fields; without it the\npipeline's output defines them."},"RetrieverVisibility":{"type":"string","enum":["private","public","marketplace"],"title":"RetrieverVisibility","description":"Visibility level of a retriever determining who can access it."},"RetryBatchRequest":{"properties":{"retry_mode":{"type":"string","enum":["transient_only","all"],"title":"Retry Mode","description":"Determines which types of failed documents to retry. 'transient_only': Only retry documents that failed with transient errors (network issues, timeouts, rate limits). This is the recommended default as it avoids retrying documents with permanent failures (invalid data, missing fields, incompatible formats). 'all': Retry all failed documents regardless of error type. Use this for force retries after fixing data issues or updating extraction logic.","default":"transient_only","examples":["transient_only","all"]},"tier_nums":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Tier Nums","description":"List of specific tier numbers to retry failures from. OPTIONAL - If not provided or empty list, retries failures from all tiers. Use this to selectively retry a specific processing stage. Example: [2] would only retry failures from tier 2 (the third processing stage). Tier numbering starts at 0 (bucket → collection), tier 1+ are collection → collection.","examples":[[2],[1,2],null]},"max_retry_count":{"type":"integer","maximum":10.0,"minimum":1.0,"title":"Max Retry Count","description":"Maximum number of times a document can be retried. Documents that have been retried this many times already are excluded. Prevents infinite retry loops for documents with persistent issues. Default is 3 retries per document. Set to higher value for more aggressive retries.","default":3,"examples":[3,5,1]}},"type":"object","title":"RetryBatchRequest","description":"Request to retry failed documents in a batch.\n\nAllows selective retry of failed documents with intelligent filtering by error type\nand tier. Retries use exponential backoff and respect max retry limits.\n\nUse Cases:\n    - Retry only transient errors after resolving temporary infrastructure issues\n    - Retry specific processing tiers that failed\n    - Retry all failed documents regardless of error type (force retry)\n\nRequirements:\n    - retry_mode: REQUIRED. Determines which documents to retry\n    - tier_nums: OPTIONAL. Only retry failures from specific tiers (empty = all tiers)\n    - max_retry_count: OPTIONAL. Skip documents that have been retried this many times\n\nBehavior:\n    - 'transient_only': Retries only transient errors (network, timeout, rate limit)\n    - 'all': Retries both transient and permanent errors\n    - Documents beyond max_retry_count are excluded from retry\n    - Each retry increments the document's retry_count","examples":[{"description":"Retry only transient errors (default, recommended)","retry_mode":"transient_only"},{"description":"Retry only tier 2 transient failures","retry_mode":"transient_only","tier_nums":[2]},{"description":"Force retry all failures (after fixing data issues)","retry_mode":"all"},{"description":"Aggressive retry with higher max attempts","max_retry_count":5,"retry_mode":"transient_only"}]},"RevisionHistoryEntry":{"properties":{"version":{"type":"integer","title":"Version","description":"Version number"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"When this version was created"},"updated_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Updated By","description":"User who made the change"},"changes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Changes","description":"Description of changes made"}},"type":"object","required":["version","updated_at"],"title":"RevisionHistoryEntry","description":"A single entry in the revision history."},"S3AccessKeyCredentials":{"properties":{"type":{"type":"string","const":"access_key","title":"Type","default":"access_key"},"access_key_id":{"type":"string","maxLength":128,"minLength":1,"title":"Access Key Id","description":"REQUIRED. AWS access key ID for authentication. Format: 20-character alphanumeric string starting with 'AKIA' (long-term) or 'ASIA' (temporary). Obtain from: AWS Console > IAM > Users > Security Credentials","examples":["AKIAIOSFODNN7EXAMPLE","ASIAIOSFODNN7EXAMPLE"]},"secret_access_key":{"type":"string","minLength":1,"title":"Secret Access Key","description":"REQUIRED. AWS secret access key for authentication. SECURITY: This is a secret credential, redacted on read. Never log or expose this value. Format: 40-character base64-encoded string. Obtain from: AWS Console when creating/viewing access key (shown only once). An S3-compatible store (endpoint_url set) issues its own format."},"session_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Token","description":"NOT REQUIRED. Temporary session token for AWS STS credentials. REQUIRED when using temporary security credentials from AWS STS. NOT REQUIRED for long-term IAM user access keys. SECURITY: Encrypted at rest. Automatically expires after session duration. Format: Base64-encoded string, typically several hundred characters. Use case: Enhanced security with automatic credential rotation"}},"type":"object","required":["access_key_id","secret_access_key"],"title":"S3AccessKeyCredentials","description":"AWS S3 access key and secret credentials.\n\nAccess keys provide programmatic access to S3 buckets using long-lived credentials.\nThis authentication method is straightforward but less secure than IAM role assumption.\n\nPrerequisites:\n    - IAM user or role with S3 access permissions\n    - Access key and secret key generated in AWS Console\n    - Appropriate bucket policies or IAM policies configured\n\nSecurity Considerations:\n    - Access keys are long-lived and don't automatically expire\n    - secret_access_key is a secret credential (redacted on read) and should be rotated regularly\n    - Consider using IAM role assumption (S3RoleCredentials) for production\n    - Never commit access keys to version control\n\nUse Cases:\n    - Quick prototyping and development\n    - Testing S3 integrations\n    - Temporary credentials with session_token for enhanced security\n    - Accessing S3-compatible services (MinIO, DigitalOcean Spaces)\n\nRecommended Alternative:\n    For production deployments, use S3RoleCredentials with IAM role assumption\n    instead of access keys for better security and credential management."},"S3Config":{"properties":{"provider_type":{"type":"string","const":"s3","title":"Provider Type","default":"s3"},"credentials":{"oneOf":[{"$ref":"#/components/schemas/S3AccessKeyCredentials"},{"$ref":"#/components/schemas/S3RoleCredentials"}],"title":"Credentials","description":"REQUIRED. AWS authentication credentials configuration. Choose 'iam_role' for production deployments (recommended) or 'access_key' for development, testing, or S3-compatible services. The 'type' field determines which credential mechanism is used.","discriminator":{"propertyName":"type","mapping":{"access_key":"#/components/schemas/S3AccessKeyCredentials","iam_role":"#/components/schemas/S3RoleCredentials"}}},"region":{"type":"string","title":"Region","description":"Defaults to us-east-1, as the sync does. AWS region where the S3 bucket is located. Must match the bucket's actual region to avoid routing errors. For S3-compatible services, use their documented region value or 'us-east-1' as a default if regions are not applicable. Format: AWS region code (e.g., us-east-1, eu-west-1)","default":"us-east-1","examples":["us-east-1","us-west-2","eu-west-1","ap-southeast-1","ca-central-1"]},"endpoint_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Endpoint Url","description":"NOT REQUIRED for AWS S3 (uses default AWS endpoints). REQUIRED for S3-compatible services to specify custom endpoint URL. Must be a valid HTTPS or HTTP URL without trailing slash. Examples: - MinIO: https://minio.example.com - DigitalOcean Spaces: https://nyc3.digitaloceanspaces.com - Wasabi: https://s3.wasabisys.com","examples":["https://s3.wasabisys.com","https://nyc3.digitaloceanspaces.com","https://minio.company.com","http://localhost:9000"]},"use_ssl":{"type":"boolean","title":"Use Ssl","description":"Whether to use TLS/SSL encryption for connections to S3. RECOMMENDED: Always True for production environments. Set to False only for local development with unencrypted endpoints. Default: True","default":true},"verify_ssl":{"type":"boolean","title":"Verify Ssl","description":"Whether to verify TLS/SSL certificates when connecting. RECOMMENDED: Always True for production to prevent MITM attacks. Set to False only for development with self-signed certificates. Requires use_ssl=True to have any effect. Default: True","default":true}},"type":"object","required":["credentials"],"title":"S3Config","description":"Amazon S3 and S3-compatible storage provider configuration.\n\nThis configuration enables Mixpeek to connect to Amazon S3 or S3-compatible\nstorage services (MinIO, DigitalOcean Spaces, Wasabi, Backblaze B2, etc.)\nfor automated object ingestion and synchronization.\n\nAuthentication Methods:\n    1. IAM Role Assumption (RECOMMENDED for production):\n        - Most secure option with automatic credential rotation\n        - No long-lived credentials shared\n        - Ideal for customer-owned S3 buckets\n\n    2. Access Keys:\n        - Simpler setup for development and testing\n        - Works with S3-compatible services\n        - Requires manual credential rotation\n\nRequirements:\n    - Valid AWS credentials or IAM role configuration\n    - S3 bucket with appropriate permissions (s3:GetObject, s3:ListBucket)\n    - Network connectivity to S3 endpoint\n    - Correct region configuration\n\nSupported Services:\n    - Amazon S3 (all regions)\n    - MinIO (self-hosted or cloud)\n    - DigitalOcean Spaces\n    - Wasabi Cloud Storage\n    - Backblaze B2\n    - Any S3-compatible storage with compatible API\n\nUse Cases:\n    - Ingest videos from data lakes\n    - Sync images from marketing asset buckets\n    - Process documents from archive storage\n    - Monitor and index uploaded files\n    - Backup and disaster recovery workflows","examples":[{"credentials":{"external_id":"mixpeek-org_abc123","role_arn":"arn:aws:iam::123456789012:role/mixpeek-storage-sync-role","type":"iam_role"},"description":"Production AWS S3 with IAM role (recommended)","provider_type":"s3","region":"us-east-1","use_ssl":true,"verify_ssl":true},{"credentials":{"access_key_id":"AKIAIOSFODNN7EXAMPLE","secret_access_key":"wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY","type":"access_key"},"description":"Development AWS S3 with access keys","provider_type":"s3","region":"us-west-2","use_ssl":true,"verify_ssl":true},{"credentials":{"access_key_id":"AKIAIOSFODNN7EXAMPLE","secret_access_key":"wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY","type":"access_key"},"description":"MinIO self-hosted S3-compatible storage","endpoint_url":"https://minio.company.com","provider_type":"s3","region":"us-east-1","use_ssl":true,"verify_ssl":true},{"credentials":{"access_key_id":"AKIAIOSFODNN7EXAMPLE","secret_access_key":"wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY","type":"access_key"},"description":"DigitalOcean Spaces","endpoint_url":"https://nyc3.digitaloceanspaces.com","provider_type":"s3","region":"nyc3","use_ssl":true,"verify_ssl":true},{"credentials":{"access_key_id":"AKIAIOSFODNN7EXAMPLE","secret_access_key":"wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY","type":"access_key"},"description":"Local development MinIO without SSL","endpoint_url":"http://localhost:9000","provider_type":"s3","region":"us-east-1","use_ssl":false,"verify_ssl":false}]},"S3MetadataSource":{"properties":{"type":{"type":"string","const":"metadata","title":"Type","description":"Source type identifier. Must be 'metadata' for S3/Tigris user metadata.","default":"metadata"},"key":{"type":"string","maxLength":1024,"minLength":1,"title":"Key","description":"The metadata key to extract (without 'x-amz-meta-' prefix). Case-insensitive (S3 lowercases all metadata keys). Common examples: 'author', 'version', 'source-system', 'original-filename'. Note: S3 automatically lowercases keys, so 'Author' becomes 'author'.","examples":["author","version","original-filename","source-system"]}},"type":"object","required":["key"],"title":"S3MetadataSource","description":"Extract value from S3/Tigris object user metadata.\n\nS3 user metadata (x-amz-meta-*) provides custom key-value pairs stored\nwith the object. Unlike tags, metadata is set at upload time and is\nimmutable without re-uploading the object.\n\nProvider Compatibility: S3, Tigris, MinIO, DigitalOcean Spaces, Wasabi\n\nExample S3 CLI to set metadata:\n    aws s3 cp video.mp4 s3://bucket/ --metadata '{\"author\":\"john\",\"version\":\"1.0\"}'\n\nExample boto3 upload with metadata:\n    s3.put_object(Bucket='b', Key='k', Body=data, Metadata={'author': 'john'})\n\nExample mapping:\n    {\"type\": \"metadata\", \"key\": \"author\"} -> extracts \"john\" from x-amz-meta-author\n\nAttributes:\n    type: Must be \"metadata\" to identify this source type\n    key: The metadata key without 'x-amz-meta-' prefix (case-insensitive)"},"S3RoleCredentials":{"properties":{"type":{"type":"string","const":"iam_role","title":"Type","default":"iam_role"},"role_arn":{"type":"string","pattern":"^arn:aws:iam::\\d{12}:role/[\\w+=,.@-]+$","title":"Role Arn","description":"REQUIRED. Amazon Resource Name (ARN) of the IAM role to assume. This role must exist in the customer's AWS account and have a trust relationship configured to allow Mixpeek to assume it. Format: arn:aws:iam::{account-id}:role/{role-name} Example trust policy should allow principal: arn:aws:iam::{mixpeek-account}:root Recommended role name: mixpeek-storage-sync-role","examples":["arn:aws:iam::123456789012:role/mixpeek-storage-sync-role","arn:aws:iam::999888777666:role/external-ingestion-access"]},"external_id":{"type":"string","maxLength":128,"minLength":8,"title":"External Id","description":"REQUIRED. External ID for secure role assumption (prevents confused deputy attacks). This value should be unique to your organization and kept confidential. Mixpeek provides this value during connection setup. Must match the ExternalId condition in the role's trust policy. Format: Recommended pattern is mixpeek-{organization_id} Security: Include this in the trust policy Condition statement","examples":["mixpeek-org_abc123def456ghi","mixpeek-customer-enterprise-xyz"]}},"type":"object","required":["role_arn","external_id"],"title":"S3RoleCredentials","description":"AWS S3 IAM role assumption credentials (RECOMMENDED for production).\n\nIAM role assumption provides secure, temporary credentials for accessing customer\nS3 buckets without sharing long-lived access keys. This is the recommended\nauthentication method for production deployments.\n\nHow It Works:\n    1. Customer creates an IAM role in their AWS account\n    2. Role trust policy allows Mixpeek AWS account to assume the role\n    3. External ID provides additional security against confused deputy attacks\n    4. Mixpeek assumes the role and receives temporary credentials (auto-renewed)\n    5. Temporary credentials are used to access the customer's S3 bucket\n\nPrerequisites:\n    1. Create IAM role in customer AWS account\n    2. Attach policy granting s3:GetObject, s3:ListBucket permissions\n    3. Configure trust relationship to allow Mixpeek account\n    4. Use organization-specific external_id for security\n    5. Share role ARN with Mixpeek\n\nSecurity Advantages:\n    - No long-lived credentials shared with third parties\n    - Temporary credentials automatically rotate (1-hour sessions by default)\n    - Customer retains full control and can revoke access anytime\n    - External ID prevents confused deputy attacks\n    - Audit trail in CloudTrail for all access\n\nUse Cases:\n    - Production deployments accessing customer S3 buckets\n    - Enterprise integrations requiring strong security\n    - Multi-tenant environments with customer-owned storage\n    - Compliance-sensitive workloads (HIPAA, SOC 2, etc.)","examples":[{"description":"Production role assumption with external ID","external_id":"mixpeek-org_abc123def456ghi","role_arn":"arn:aws:iam::123456789012:role/mixpeek-storage-sync-role","type":"iam_role"}],"trust_policy_example":{"Statement":[{"Action":"sts:AssumeRole","Condition":{"StringEquals":{"sts:ExternalId":"mixpeek-org_abc123def456ghi"}},"Effect":"Allow","Principal":{"AWS":"arn:aws:iam::{mixpeek-account-id}:root"}}],"Version":"2012-10-17"}},"S3TagSource":{"properties":{"type":{"type":"string","const":"tag","title":"Type","description":"Source type identifier. Must be 'tag' for S3/Tigris object tags.","default":"tag"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key","description":"The tag key to extract. Case-sensitive. Must match the exact tag key on the S3/Tigris object. Common examples: 'category', 'project', 'owner', 'environment'. Maximum length: 128 characters.","examples":["category","project","content-type","cost-center"]}},"type":"object","required":["key"],"title":"S3TagSource","description":"Extract value from an S3/Tigris object tag.\n\nS3 object tags are key-value pairs attached to objects, commonly used for\ncategorization, cost allocation, and metadata. Tags are limited to 10 per object\nwith keys up to 128 chars and values up to 256 chars.\n\nProvider Compatibility: S3, Tigris, MinIO, DigitalOcean Spaces, Wasabi\n\nExample S3 CLI to set tag:\n    aws s3api put-object-tagging --bucket my-bucket --key video.mp4 \\\n        --tagging 'TagSet=[{Key=category,Value=marketing}]'\n\nExample mapping:\n    {\"type\": \"tag\", \"key\": \"category\"} -> extracts \"marketing\" from the tag\n\nAttributes:\n    type: Must be \"tag\" to identify this source type\n    key: The tag key to extract (case-sensitive, max 128 chars)"},"SEOConfig":{"properties":{"meta_title":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}],"title":"Meta Title","description":"SEO-optimized page title (50-60 chars recommended). Auto-generated from display_config.title + site_name if not provided.","examples":["Fitness Video Search | Mixpeek","Product Catalog | Your Brand"]},"meta_description":{"anyOf":[{"type":"string","maxLength":160},{"type":"null"}],"title":"Meta Description","description":"Meta description for search engine snippets (max 160 chars). Auto-generated from display_config.description if not provided.","examples":["Search and discover fitness videos using AI-powered semantic search.","Browse our product catalog with intelligent visual search."]},"keywords":{"items":{"type":"string"},"type":"array","title":"Keywords","description":"Relevant keywords for search engines. Auto-inferred from title, description, and retriever tags.","examples":[["fitness","yoga","workout","exercise videos"],["products","catalog","search","e-commerce"]]},"og_image_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Og Image Url","description":"URL to OG image for social previews (1200x630px recommended). Auto-generated and uploaded to public S3 bucket during publishing.","examples":["https://mixpeek-public-pages.s3.amazonaws.com/org/ns/og/video-search/og.png"]},"og_image_alt":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Og Image Alt","description":"Alt text for OG image (accessibility and SEO)","examples":["Fitness video search interface","Product catalog preview"]},"og_type":{"type":"string","title":"Og Type","description":"Open Graph content type","default":"website","examples":["website","article","product"]},"twitter_card":{"type":"string","title":"Twitter Card","description":"Twitter card display style","default":"summary_large_image","examples":["summary","summary_large_image","app"]},"twitter_site":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Twitter Site","description":"Twitter @handle for the site","default":"@mixpeek","examples":["@mixpeek","@yourbrand"]},"twitter_creator":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Twitter Creator","description":"Twitter @handle for content creator (optional)","examples":["@johndoe","@yourbrand"]},"robots":{"type":"string","title":"Robots","description":"Robots meta directive for search engine crawlers. Use 'noindex, nofollow' to hide from search engines.","default":"index, follow","examples":["index, follow","noindex, nofollow","index, nofollow"]},"canonical_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Url","description":"Canonical URL if different from default. Auto-set to https://mxp.co/r/{public_name} if not provided.","examples":["https://yourdomain.com/search","https://mxp.co/r/video-search"]},"site_name":{"type":"string","title":"Site Name","description":"Site name for OG tags and branding","default":"Mixpeek","examples":["Mixpeek","Your Brand","Company Name"]},"author":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Author","description":"Content author/creator name","examples":["Mixpeek","Your Organization"]},"locale":{"type":"string","title":"Locale","description":"Content language/locale","default":"en_US","examples":["en_US","en_GB","es_ES","fr_FR"]},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url","description":"URL to organization/brand logo for SEO and branding. Used in structured data and can be displayed in search results.","examples":["https://example.com/logo.png","https://cdn.mixpeek.com/logos/acme.png"]},"favicon_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Favicon Url","description":"URL to favicon/icon for the public retriever page. Recommended sizes: 32x32, 48x48, or 180x180 for Apple touch icon.","examples":["https://example.com/favicon.ico","https://cdn.mixpeek.com/icons/acme.png"]},"structured_data":{"$ref":"#/components/schemas/StructuredDataConfig","description":"Schema.org structured data for rich search results"}},"type":"object","title":"SEOConfig","description":"SEO configuration for public retriever discoverability.\n\nAuto-generated during publishing with sensible defaults inferred from\nthe retriever's display_config. All fields can be overridden manually.\n\nThis configuration controls how the public retriever appears in:\n- Search engine results (Google, Bing, etc.)\n- Social media shares (Twitter, Facebook, LinkedIn)\n- Link previews in messaging apps","examples":[{"author":"Mixpeek","favicon_url":"https://example.com/favicon.ico","keywords":["fitness","yoga","workout","exercise videos"],"locale":"en_US","logo_url":"https://example.com/logo.png","meta_description":"Search and discover fitness videos using AI-powered semantic search.","meta_title":"Fitness Video Search | Mixpeek","og_image_alt":"Fitness video search interface","og_image_url":"https://mixpeek-public-pages.s3.amazonaws.com/og.png","og_type":"website","robots":"index, follow","site_name":"Mixpeek","structured_data":{"additional_properties":{"applicationCategory":"Search"},"type":"WebApplication"},"twitter_card":"summary_large_image","twitter_site":"@mixpeek"}]},"SLOSurface":{"type":"string","enum":["indexing","retrieval","clustering"],"title":"SLOSurface","description":"The three surfaces's SLO rollup already computes\nattainment INPUTS for — kept identical here so a future attainment\ncomputation (reading both TargetSpec and slo_rollup_hourly) never has\nto reconcile two different surface vocabularies."},"SLOTarget":{"properties":{"surface":{"$ref":"#/components/schemas/SLOSurface"},"p95_latency_ms_target":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P95 Latency Ms Target","description":"Target p95 latency in milliseconds for this surface."},"error_budget_pct":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Error Budget Pct","description":"Target maximum error rate (percent) for this surface."}},"type":"object","required":["surface"],"title":"SLOTarget","description":"The SLO block for one surface. Both fields are nullable — G3\n(latency/error SLO layer) has not declared numeric targets for any\nsurface yet; a null here is honest (\"nothing declared\"), not a\nfabricated default the way resource targets can safely default from\nthe existing tenancy bands."},"SampleQuery":{"properties":{"query":{"type":"string","title":"Query"},"description":{"type":"string","title":"Description"}},"type":"object","required":["query","description"],"title":"SampleQuery"},"ScaffoldManifestResponse":{"properties":{"template_id":{"type":"string","title":"Template Id","description":"Scaffold template ID"},"name":{"type":"string","title":"Name","description":"Scaffold template display name"},"manifest_yaml":{"type":"string","title":"Manifest Yaml","description":"Manifest rendered as YAML (same style as manifest export)"},"manifest":{"additionalProperties":true,"type":"object","title":"Manifest","description":"Manifest as a JSON-safe dict (parseable by the manifest parser)"}},"type":"object","required":["template_id","name","manifest_yaml","manifest"],"title":"ScaffoldManifestResponse","description":"A scaffold template rendered as a Mixpeek manifest.\n\nReturned by GET /templates/scaffolds/{template_id}/manifest (authenticated)\nand GET /public/templates/scaffolds/{template_id}/manifest (public browse).","examples":[{"manifest":{"metadata":{"name":"Video Understanding"},"namespaces":[],"version":"1.0"},"manifest_yaml":"version: '1.0'\nmetadata:\n  name: Video Understanding\n...","name":"Video Understanding","template_id":"tmpl_scaffold_video_understanding"}]},"ScaffoldSampleCollection":{"properties":{"collection_id":{"type":"string","title":"Collection Id"},"collection_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Collection Name"},"document_count":{"type":"integer","title":"Document Count"}},"type":"object","required":["collection_id","document_count"],"title":"ScaffoldSampleCollection"},"ScaffoldSampleDataResponse":{"properties":{"template_id":{"type":"string","title":"Template Id"},"sample_namespace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sample Namespace Id"},"available":{"type":"boolean","title":"Available","description":"False when the scaffold has no sample namespace or it could not be read; collections/total are then empty."},"total_documents":{"type":"integer","title":"Total Documents","default":0},"collections":{"items":{"$ref":"#/components/schemas/ScaffoldSampleCollection"},"type":"array","title":"Collections","default":[]}},"type":"object","required":["template_id","available"],"title":"ScaffoldSampleDataResponse","description":"Live contents of a scaffold's golden sample namespace.\n\nGround truth for the Studio pre-clone preview: golden namespaces 404 for\nnormal org keys (they belong to the Demos org and are not the shared\n``sample-data`` remap), so the counts must be server-derived. Curated copy\n(``whats_inside``) can lie; these counts cannot — a dark golden shows its\nreal zeros here."},"ScalingConfig":{"properties":{"min_replicas":{"type":"integer","title":"Min Replicas"},"max_replicas":{"type":"integer","title":"Max Replicas"}},"type":"object","required":["min_replicas","max_replicas"],"title":"ScalingConfig"},"SceneDownloadResponse":{"properties":{"download_url":{"type":"string","title":"Download Url","description":"Presigned URL for the frame-accurate media cut."},"cached":{"type":"boolean","title":"Cached","description":"Whether the cut was served from cache."},"start_time":{"type":"number","title":"Start Time","description":"Scene start time in seconds."},"end_time":{"type":"number","title":"End Time","description":"Scene end time in seconds."}},"type":"object","required":["download_url","cached","start_time","end_time"],"title":"SceneDownloadResponse"},"SchemaInferenceRequest":{"properties":{"sample_rows":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Sample Rows","description":"A sample of export rows to infer from."},"source_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Source Schema","description":"Optional declared source schema (advisory)."},"sample_size":{"type":"integer","title":"Sample Size","description":"Max rows to consider from sample_rows.","default":100},"known_index_dims":{"anyOf":[{"additionalProperties":{"type":"integer"},"type":"object"},{"type":"null"}],"title":"Known Index Dims","description":"Known target vector index dims, used to recognise base64 vectors."}},"type":"object","title":"SchemaInferenceRequest","description":"Request body for POST /v1/collections/import/infer."},"SchemaInferenceResult":{"properties":{"fields":{"items":{"$ref":"#/components/schemas/InferredField"},"type":"array","title":"Fields"},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings"}},"type":"object","title":"SchemaInferenceResult"},"SchemaMapping-Input":{"properties":{"mappings":{"additionalProperties":{"oneOf":[{"$ref":"#/components/schemas/FieldMappingEntry"},{"$ref":"#/components/schemas/BlobMappingEntry"}],"discriminator":{"propertyName":"target_type","mapping":{"blob":"#/components/schemas/BlobMappingEntry","field":"#/components/schemas/FieldMappingEntry"}}},"type":"object","title":"Mappings","description":"Dictionary mapping target field names to their source extractors. Keys are bucket schema field names (e.g., 'content', 'category'). Values are mapping entries defining how to extract and store the data. At least one blob mapping (target_type='blob') is recommended for file syncs."}},"type":"object","required":["mappings"],"title":"SchemaMapping","description":"Complete schema mapping configuration for a sync.\n\nDefines how source data (files, tags, metadata, columns) maps to the\ntarget bucket schema. Each key is a target field/blob name in the bucket.\n\n**Key Concepts:**\n- Keys are target bucket schema field names\n- Values define the source and extraction method\n- At least one blob mapping is typically required for file syncs\n- Field mappings extract metadata alongside the file content\n\n**Provider Examples:**\n\n**S3/Tigris Video Sync:**\n```json\n{\n    \"content\": {\n        \"target_type\": \"blob\",\n        \"source\": {\"type\": \"file\"},\n        \"blob_type\": \"video\"\n    },\n    \"category\": {\n        \"target_type\": \"field\",\n        \"source\": {\"type\": \"tag\", \"key\": \"category\"}\n    },\n    \"source_bucket\": {\n        \"target_type\": \"field\",\n        \"source\": {\"type\": \"constant\", \"value\": \"production-videos\"}\n    }\n}\n```\n\n**Snowflake Customer Table Sync:**\n```json\n{\n    \"customer_name\": {\n        \"target_type\": \"field\",\n        \"source\": {\"type\": \"column\", \"name\": \"NAME\"}\n    },\n    \"profile_image\": {\n        \"target_type\": \"blob\",\n        \"source\": {\"type\": \"column\", \"name\": \"AVATAR_URL\"},\n        \"blob_type\": \"image\"\n    },\n    \"segment\": {\n        \"target_type\": \"field\",\n        \"source\": {\"type\": \"column\", \"name\": \"CUSTOMER_SEGMENT\"},\n        \"transform\": \"lowercase\"\n    }\n}\n```\n\n**Google Drive with Folder Categories:**\n```json\n{\n    \"content\": {\n        \"target_type\": \"blob\",\n        \"source\": {\"type\": \"file\"},\n        \"blob_type\": \"auto\"\n    },\n    \"department\": {\n        \"target_type\": \"field\",\n        \"source\": {\"type\": \"folder_path\", \"segment\": 0},\n        \"transform\": \"lowercase\"\n    },\n    \"description\": {\n        \"target_type\": \"field\",\n        \"source\": {\"type\": \"drive_property\", \"key\": \"description\"}\n    }\n}\n```\n\nAttributes:\n    mappings: Dictionary mapping target field names to their source extractors"},"SchemaMapping-Output":{"properties":{"mappings":{"additionalProperties":{"oneOf":[{"$ref":"#/components/schemas/FieldMappingEntry"},{"$ref":"#/components/schemas/BlobMappingEntry"}],"discriminator":{"propertyName":"target_type","mapping":{"blob":"#/components/schemas/BlobMappingEntry","field":"#/components/schemas/FieldMappingEntry"}}},"type":"object","title":"Mappings","description":"Dictionary mapping target field names to their source extractors. Keys are bucket schema field names (e.g., 'content', 'category'). Values are mapping entries defining how to extract and store the data. At least one blob mapping (target_type='blob') is recommended for file syncs."}},"type":"object","required":["mappings"],"title":"SchemaMapping","description":"Complete schema mapping configuration for a sync.\n\nDefines how source data (files, tags, metadata, columns) maps to the\ntarget bucket schema. Each key is a target field/blob name in the bucket.\n\n**Key Concepts:**\n- Keys are target bucket schema field names\n- Values define the source and extraction method\n- At least one blob mapping is typically required for file syncs\n- Field mappings extract metadata alongside the file content\n\n**Provider Examples:**\n\n**S3/Tigris Video Sync:**\n```json\n{\n    \"content\": {\n        \"target_type\": \"blob\",\n        \"source\": {\"type\": \"file\"},\n        \"blob_type\": \"video\"\n    },\n    \"category\": {\n        \"target_type\": \"field\",\n        \"source\": {\"type\": \"tag\", \"key\": \"category\"}\n    },\n    \"source_bucket\": {\n        \"target_type\": \"field\",\n        \"source\": {\"type\": \"constant\", \"value\": \"production-videos\"}\n    }\n}\n```\n\n**Snowflake Customer Table Sync:**\n```json\n{\n    \"customer_name\": {\n        \"target_type\": \"field\",\n        \"source\": {\"type\": \"column\", \"name\": \"NAME\"}\n    },\n    \"profile_image\": {\n        \"target_type\": \"blob\",\n        \"source\": {\"type\": \"column\", \"name\": \"AVATAR_URL\"},\n        \"blob_type\": \"image\"\n    },\n    \"segment\": {\n        \"target_type\": \"field\",\n        \"source\": {\"type\": \"column\", \"name\": \"CUSTOMER_SEGMENT\"},\n        \"transform\": \"lowercase\"\n    }\n}\n```\n\n**Google Drive with Folder Categories:**\n```json\n{\n    \"content\": {\n        \"target_type\": \"blob\",\n        \"source\": {\"type\": \"file\"},\n        \"blob_type\": \"auto\"\n    },\n    \"department\": {\n        \"target_type\": \"field\",\n        \"source\": {\"type\": \"folder_path\", \"segment\": 0},\n        \"transform\": \"lowercase\"\n    },\n    \"description\": {\n        \"target_type\": \"field\",\n        \"source\": {\"type\": \"drive_property\", \"key\": \"description\"}\n    }\n}\n```\n\nAttributes:\n    mappings: Dictionary mapping target field names to their source extractors"},"SchemaSyncRequest":{"properties":{"sample_size":{"type":"integer","maximum":10000.0,"minimum":1.0,"title":"Sample Size","description":"Number of documents to sample for schema discovery","default":1000},"force":{"type":"boolean","title":"Force","description":"Force schema sync even if within debounce window. Default: false (respects 5-minute debounce)","default":false},"cascade_to_downstream":{"type":"boolean","title":"Cascade To Downstream","description":"Automatically update downstream collections that use this collection as source. Default: true","default":true}},"type":"object","title":"SchemaSyncRequest","description":"Request to sync a collection's schema by sampling documents.\n\nUsed by:\n- Manual API calls from users\n- Automatic triggers from BatchJobPoller"},"SchemaSyncResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether schema sync succeeded"},"collection_id":{"type":"string","title":"Collection Id","description":"Collection that was synced"},"schema_version":{"type":"integer","title":"Schema Version","description":"New schema version"},"previous_version":{"type":"integer","title":"Previous Version","description":"Previous schema version"},"fields_added":{"items":{"type":"string"},"type":"array","title":"Fields Added","description":"List of new fields discovered"},"fields_total":{"type":"integer","title":"Fields Total","description":"Total fields in output_schema"},"documents_sampled":{"type":"integer","title":"Documents Sampled","description":"Number of documents sampled"},"downstream_collections_updated":{"items":{"type":"string"},"type":"array","title":"Downstream Collections Updated","description":"Downstream collections that were updated"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message","description":"Additional message or error"}},"type":"object","required":["success","collection_id","schema_version","previous_version","fields_total","documents_sampled"],"title":"SchemaSyncResponse","description":"Response from schema sync operation."},"SchemaSyncSkippedResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Request succeeded","default":true},"skipped":{"type":"boolean","title":"Skipped","description":"Schema sync was skipped","default":true},"reason":{"type":"string","title":"Reason","description":"Why sync was skipped"},"collection_id":{"type":"string","title":"Collection Id","description":"Collection ID"},"schema_version":{"type":"integer","title":"Schema Version","description":"Current schema version"},"last_sync":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Sync","description":"Last sync timestamp"}},"type":"object","required":["reason","collection_id","schema_version"],"title":"SchemaSyncSkippedResponse","description":"Response when schema sync was skipped (debounce or disabled)."},"ScoreItem":{"properties":{"predicted":{"items":{"type":"string"},"type":"array","title":"Predicted","description":"Predicted terms or ids (treated as a set)."},"ground_truth":{"items":{"type":"string"},"type":"array","title":"Ground Truth","description":"Ground-truth terms or ids (treated as a set)."}},"additionalProperties":false,"type":"object","title":"ScoreItem","description":"One prediction to score: predicted terms/ids vs the ground truth.\n\nBoth are treated as SETS (the underlying metrics are set-membership), so\nduplicates do not change the score."},"ScorePredictionsRequest":{"properties":{"predicted":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Predicted","description":"Single-pair form: predicted terms/ids. Pair with ground_truth."},"ground_truth":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Ground Truth","description":"Single-pair form: ground-truth terms/ids. Pair with predicted."},"items":{"anyOf":[{"items":{"$ref":"#/components/schemas/ScoreItem"},"type":"array"},{"type":"null"}],"title":"Items","description":"Batch form: a list of {predicted, ground_truth} pairs."},"metrics":{"items":{"type":"string"},"type":"array","title":"Metrics","description":"Metrics to compute. Allowed: precision, recall, f1, f2."},"k":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"K","description":"Cutoff: score only the first k predicted items. Default: all."}},"additionalProperties":false,"type":"object","title":"ScorePredictionsRequest","description":"Score precomputed predictions vs ground truth, statelessly.\n\nSend EITHER a single pair (``predicted`` + ``ground_truth``) or an ``items``\nbatch (score many predictions in one call — the shape a benchmark of N\npredictions wants). Exactly one form is required."},"ScorePredictionsResponse":{"properties":{"metrics":{"items":{"type":"string"},"type":"array","title":"Metrics","description":"Metrics computed, in request order."},"k":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"K","description":"Cutoff applied, if any."},"count":{"type":"integer","title":"Count","description":"Number of items scored."},"per_item":{"items":{"additionalProperties":{"type":"number"},"type":"object"},"type":"array","title":"Per Item","description":"Each item's {metric: value} in [0.0, 1.0]."},"aggregate":{"additionalProperties":{"type":"number"},"type":"object","title":"Aggregate","description":"Macro-average (mean over items) of each metric."}},"type":"object","required":["metrics","count","per_item","aggregate"],"title":"ScorePredictionsResponse","description":"Per-item and aggregate (macro-mean) scores."},"ScrollPaginationParams":{"properties":{"method":{"type":"string","const":"scroll","title":"Method","description":"Constant identifying scroll pagination (REQUIRED).","default":"scroll"},"limit":{"type":"integer","maximum":1000.0,"minimum":1.0,"title":"Limit","description":"Number of documents to fetch per scroll page (REQUIRED). Default: 100.","default":100},"scroll_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scroll Id","description":"Server-issued scroll session identifier (OPTIONAL). null for first request, then use scroll_id from response"},"scroll_ttl":{"type":"integer","maximum":3600.0,"minimum":60.0,"title":"Scroll Ttl","description":"Seconds to keep scroll context alive (REQUIRED). Default: 300 (5 minutes).","default":300}},"type":"object","title":"ScrollPaginationParams","description":"Scroll-style pagination maintaining server-side context for TTL.\n\nBest for: Bulk exports, batch processing, iterating through all results\n\nHow it works:\n- Server maintains a snapshot of results\n- First request: scroll_id=null, returns scroll_id\n- Subsequent requests: use scroll_id from response\n- Context expires after scroll_ttl seconds\n- Consistent view of data (point-in-time snapshot)\n\nTradeoffs:\n- Requires server-side state (memory/cache)\n- TTL means sessions can expire\n- Not suitable for long-lived sessions\n- Good for background jobs, not user-facing UIs\n\nUse when:\n- Exporting large datasets\n- Batch processing all results\n- Background jobs iterating through results\n- You need consistent point-in-time view\n\nExample flow:\n1. Request: {\"method\": \"scroll\", \"limit\": 100, \"scroll_id\": null}\n2. Response: {\"documents\": [...], \"scroll_id\": \"xyz789\", \"has_next\": true}\n3. Request: {\"method\": \"scroll\", \"limit\": 100, \"scroll_id\": \"xyz789\"}"},"ScrollingTextExtractorParams":{"properties":{"extractor_type":{"type":"string","const":"scrolling_text_extractor","title":"Extractor Type","description":"Discriminator field. Must be 'scrolling_text_extractor'.","default":"scrolling_text_extractor"},"fps":{"type":"number","maximum":30.0,"minimum":1.0,"title":"Fps","description":"Frame sampling rate for analysis. Higher values improve detection accuracy for fast-scrolling text but increase processing time. 5 FPS works well for most video ads and tickers.","default":5.0},"strip_height":{"type":"integer","maximum":200.0,"minimum":10.0,"title":"Strip Height","description":"Height (in pixels) of each scanning strip used for phase correlation. Should roughly match the height of the scrolling text band. Smaller values detect narrower text bands; larger values are more robust but may miss thin tickers. 40px works for most standard video ads.","default":40},"min_shift_px":{"type":"number","maximum":20.0,"minimum":0.5,"title":"Min Shift Px","description":"Minimum pixel shift per frame to consider a strip as 'scrolling'. Lower values detect slower-moving text; higher values filter out noise. 2.0px is a good default for 5 FPS sampling.","default":2.0},"consistency_ratio":{"type":"number","maximum":1.0,"minimum":0.3,"title":"Consistency Ratio","description":"Fraction of frame pairs that must show consistent shift for a band to be classified as scrolling. 0.6 means 60% of frames must agree. Lower values detect intermittent scrolling; higher values reduce false positives.","default":0.6},"pad":{"type":"integer","maximum":50.0,"minimum":0.0,"title":"Pad","description":"Pixel padding above/below detected band when cropping for stitching.","default":8},"static_ocr":{"type":"boolean","title":"Static Ocr","description":"Also OCR STATIC on-screen text (title cards, disclaimers, CTAs, captions) — the majority of text in ad creative. Distinct keyframes are stitched into one grid image and read with a single VLM call, so a fully static video costs one OCR call. Disable only if you strictly want scrolling-band text.","default":true},"max_static_frames":{"type":"integer","maximum":12.0,"minimum":1.0,"title":"Max Static Frames","description":"Maximum number of visually distinct keyframes sampled for the static-text OCR grid. Identical frames collapse to one; scene changes contribute additional frames up to this cap.","default":4}},"type":"object","title":"ScrollingTextExtractorParams","description":"Parameters for the on-screen text extractor.\n\nExtracts ALL on-screen text from video: STATIC overlays (title cards,\ndisclaimers, captions, CTAs — the majority of ad-creative text) via\nkeyframe-grid VLM OCR, and SCROLLING/marquee text via computer vision\n(phase-correlation band detection + panoramic stitching) + VLM OCR.\n\n**When to Use**:\n    - Ad creative with static overlay text (disclaimers, CTAs, titles)\n    - Video ads with scrolling promotional banners or tickers\n    - News broadcasts with scrolling chyrons or tickers\n    - Videos with terms & conditions or disclaimers (static or scrolling)\n    - Social media content with text overlays\n    - Credits sequences in film/TV content\n    - Live event streams with scrolling info bars\n\n**When NOT to Use**:\n    - Spoken content → use multimodal_extractor with run_transcription=True\n    - Text documents/PDFs → use text_extractor\n\n**How It Works**:\n    Static pass (static_ocr=True, default):\n    1. Select visually distinct keyframes (identical frames collapse to one)\n    2. Stitch them into a single grid image\n    3. OCR the grid with one vision-language-model call (Gemini)\n\n    Scrolling pass:\n    1. Sample frames from video at configurable FPS\n    2. Split each frame into horizontal and vertical strips\n    3. Phase-correlate consecutive frames to measure per-strip pixel shift\n    4. Strips with consistent shift in one direction = scrolling band\n    5. Stitch the band across frames into a single wide/tall panorama image\n    6. OCR the panorama using a vision language model (Gemini)\n    7. Deduplicate repeated marquee loops (e.g. \"SALE • SALE • SALE •\" → \"SALE\")\n\n**Performance**:\n    - Processing speed: ~2-5x realtime (depends on video resolution and FPS)\n    - Accuracy: Best with consistent scroll speed; handles variable speed with degradation\n    - Minimum video length: ~2 seconds (needs 3+ frames for correlation)\n\n**Supported Scroll Directions**:\n    - Horizontal: Right-to-left (most common), Left-to-right\n    - Vertical: Bottom-to-top (credits), Top-to-bottom","examples":[{"description":"Standard video ad with scrolling banner","extractor_type":"scrolling_text_extractor","fps":5.0,"strip_height":40,"use_case":"Extract promotional text from video ad tickers"},{"description":"Fast-scrolling news ticker","extractor_type":"scrolling_text_extractor","fps":10.0,"min_shift_px":3.0,"strip_height":30,"use_case":"Capture rapidly scrolling chyron text from news broadcasts"},{"consistency_ratio":0.5,"description":"Credits / disclaimer scroll","extractor_type":"scrolling_text_extractor","fps":5.0,"min_shift_px":1.5,"strip_height":60,"use_case":"Extract vertically scrolling credits or legal disclaimers"}]},"SearchInteraction":{"properties":{"feature_id":{"type":"string","title":"Feature Id","description":"ID of the document/feature that was interacted with. REQUIRED. This is the SAME value as the `document_id` returned in retriever execute results — you can pass it as either `feature_id` or `document_id` (the latter is accepted as an alias). Used to track which specific items users engage with.","examples":["doc_abc123","prod_xyz789","feat_12345"]},"interaction_type":{"items":{"$ref":"#/components/schemas/InteractionType"},"type":"array","minItems":1,"title":"Interaction Type","description":"List of interaction types that occurred. REQUIRED. Multiple types can be recorded simultaneously (e.g., VIEW + CLICK + LONG_VIEW for a result the user engaged with). Use the InteractionType enum values.","examples":[["click"],["positive_feedback","click","long_view"],["negative_feedback"],["purchase","click"]]},"position":{"type":"integer","minimum":0.0,"title":"Position","description":"Position in search results where interaction occurred (0-indexed). REQUIRED. Critical for Learning to Rank - helps identify position bias. E.g., position=0 means first result, position=9 means 10th result. Higher engagement at lower positions suggests higher quality.","examples":[0,1,5,15]},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Additional context about the interaction. NOT REQUIRED. Can include device, duration, viewport info, etc. Use this to enrich interaction data with application-specific context.","examples":[{"device":"mobile","duration_ms":5000,"page":"search_results","viewport_position":0.75},{"interaction_reason":"not_relevant","page_number":2,"results_count":50,"search_latency_ms":150}]},"user_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id","description":"Customer's authenticated user identifier. NOT REQUIRED. Persists across sessions for long-term tracking. Enables personalization and user-specific metrics. Use your application's user ID format.","examples":["user_abc123","customer_456","usr_xyz789"]},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id","description":"Temporary identifier for a single search session. NOT REQUIRED. Typically 30min-1hr duration. Tracks anonymous and authenticated users within a session. Use to group related queries and understand search journeys. Also used by learned fusion (auto-tune) for within-session real-time adaptation: interactions sharing a session_id allow the bandit to update feature weights mid-session without waiting for batch aggregation.","examples":["sess_abc123","session_xyz789_1234567890"]},"execution_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Execution Id","description":"ID of the retriever execution that generated these results. REQUIRED when retriever_id is set: every execute response returns it, and an interaction on a retriever's result without it is refused (422). Links the interaction back to the exact search query, pipeline configuration, and stage execution that produced the results the user saw. Essential for: fine-tuning embeddings, training rerankers, query understanding, and tracing which pipeline configs produce better user engagement. Retrieve from the retriever execution response and pass to interactions.","examples":["exec_abc123xyz","exec_550e8400e29b41d4"]},"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id","description":"ID of the retriever that was executed. NOT REQUIRED but RECOMMENDED for multi-retriever analytics. Enables comparing performance across different retriever configurations. If execution_id is provided, retriever_id can be inferred from the execution record.","examples":["ret_abc123","ret_product_search_v2"]},"query_snapshot":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Query Snapshot","description":"Snapshot of the query input that generated these results. HIGHLY RECOMMENDED for training optimization. Storing the query directly enables 10-100x faster training data extraction by avoiding expensive joins to execution records. Use the same format as retriever query input (e.g., {'text': '...', 'filters': {...}}). Essential for: embedding fine-tuning (query-document pairs), query expansion learning, and analyzing which query patterns lead to better engagement. NOT REQUIRED but strongly recommended for production use cases involving model training.","examples":[{"text":"wireless headphones"},{"filters":{"price":{"lte":1000}},"text":"laptop"},{"context":"summer collection","text":"red shoes"}]},"document_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Document Score","description":"Initial retrieval score of this document when shown to the user. HIGHLY RECOMMENDED for Learning to Rank (LTR). This is a critical feature for reranker training - helps the model learn how to adjust initial scores based on user engagement. Should match the score from the retriever execution results. NOT REQUIRED but strongly recommended for LTR and reranker training.","examples":[0.95,0.87,0.62]},"result_set_size":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Result Set Size","description":"Total number of results shown to the user in this search. NOT REQUIRED but useful for context. 0 is accepted only with interaction_type zero_results, for a search that returned nothing; every other interaction needs at least 1. Helps understand interaction patterns - clicking position 5 of 10 results is different from position 5 of 100 results. Useful for position bias correction and CTR analysis.","examples":[10,20,50,100]},"feature_uri":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Feature Uri","description":"Feature URI that produced the clicked result (e.g. 'mixpeek://text_extractor@v1/embedding'). Required for learned fusion — interactions without this field do not contribute to weight learning.","examples":["mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1","mixpeek://clip_extractor@v1/image_embedding"]},"occurred_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Occurred At","description":"When the interaction actually happened (ISO 8601). OPTIONAL. Omit for live interactions — the server stamps 'now'. Supply this ONLY to backfill historical interactions (e.g. migrating existing click logs) so learned-fusion temporal decay weights them by their TRUE age. A naive datetime is interpreted as UTC; a future value is clamped to now. Backfilled events bypass the real-time session cache.","examples":["2026-01-15T10:30:00Z","2025-12-01T00:00:00+00:00"]}},"type":"object","required":["feature_id","interaction_type","position"],"title":"SearchInteraction","description":"Records a user interaction with a search result.\n\nThis model captures user behavior signals that can be used to improve retrieval quality.\nEach interaction represents a user action (click, view, feedback) on a specific document\nreturned by a retriever.\n\nUse Cases:\n    - Track which search results users actually click on\n    - Collect explicit feedback (thumbs up/down) on result quality\n    - Monitor engagement metrics (time spent viewing, sharing)\n    - Identify problematic queries (zero results, immediate refinements)\n    - Power Learning to Rank models with real user behavior\n\nRequirements:\n    - feature_id: REQUIRED - The document/feature that was interacted with\n    - interaction_type: REQUIRED - Type(s) of interaction that occurred\n    - position: REQUIRED - Where in results list the interaction occurred (for LTR)\n    - query_snapshot: HIGHLY RECOMMENDED - Query input for training optimization\n    - document_score: HIGHLY RECOMMENDED - Initial score for LTR training\n    - result_set_size: OPTIONAL - Total results shown (for context)\n    - metadata: OPTIONAL - Additional context about the interaction\n    - user_id: OPTIONAL - For personalization and user-specific metrics\n    - session_id: OPTIONAL - For tracking multi-query sessions\n    - execution_id: REQUIRED with retriever_id - Link to full execution context\n    - retriever_id: OPTIONAL - For multi-retriever analytics\n\nRelated Concepts:\n    - Retrievers: Interactions measure retriever performance\n    - Evaluations: Interactions provide real-world complement to offline evaluation\n    - Learning to Rank: Interactions train ranking models","examples":[{"description":"Minimal click interaction (query_snapshot and document_score optional)","execution_id":"exec_minimal_123","feature_id":"doc_abc123","interaction_type":["click"],"position":2,"session_id":"sess_minimal"},{"description":"Simple click interaction with recommended fields for training","document_score":0.85,"feature_id":"doc_abc123","interaction_type":["click"],"position":2,"query_snapshot":{"text":"machine learning tutorials"}},{"description":"Engaged view with metadata and execution tracking","document_score":0.92,"execution_id":"exec_abc123xyz","feature_id":"prod_xyz789","interaction_type":["view","click","long_view"],"metadata":{"device":"mobile","duration_ms":12000,"viewport_position":0.85},"position":0,"query_snapshot":{"filters":{"price":{"lte":100}},"text":"wireless headphones"},"result_set_size":20,"retriever_id":"ret_product_search","session_id":"sess_abc","user_id":"user_123"},{"description":"Negative feedback","document_score":0.78,"feature_id":"doc_bad456","interaction_type":["negative_feedback","return_to_results"],"metadata":{"interaction_reason":"not_relevant"},"position":5,"query_snapshot":{"text":"python tutorial"},"result_set_size":50,"session_id":"sess_xyz"},{"description":"Purchase conversion with full tracking (high-value signal for training)","document_score":0.88,"execution_id":"exec_purchase_789","feature_id":"prod_789","interaction_type":["purchase"],"metadata":{"conversion_time_seconds":120,"purchase_amount":199.99},"position":1,"query_snapshot":{"text":"noise cancelling headphones"},"result_set_size":50,"retriever_id":"ret_product_search","session_id":"sess_purchase_001","user_id":"user_456"}]},"SearchRequest":{"properties":{"query":{"type":"string","minLength":1,"title":"Query","description":"Search term to match against resource names and IDs. REQUIRED. Minimum 1 character. Case-insensitive partial matching is performed. Matches against: bucket_name, bucket_id, collection_name, collection_id, retriever_name, retriever_id, taxonomy_name, taxonomy_id, cluster_name, cluster_id, namespace_name, namespace_id. Example: 'prod' matches 'production-videos', 'bkt_prod123', 'Products Collection'.","examples":["product","bkt_","video","prod"]},"resource_types":{"anyOf":[{"items":{"type":"string","enum":["bucket","collection","retriever","taxonomy","cluster","published_retriever","namespace"]},"type":"array"},{"type":"null"}],"title":"Resource Types","description":"Filter search to specific resource types. OPTIONAL - If not provided, searches all resource types. Valid values: 'bucket', 'collection', 'retriever', 'taxonomy', 'cluster', 'published_retriever', 'namespace'. Example: ['bucket', 'collection'] searches only buckets and collections.","examples":[["bucket","collection"],["retriever","published_retriever"],null]},"limit":{"type":"integer","maximum":100.0,"minimum":1.0,"title":"Limit","description":"Maximum number of results to return. OPTIONAL - Defaults to 20. Minimum: 1, Maximum: 100. Use with offset for pagination.","default":20,"examples":[20,50,100]},"offset":{"type":"integer","minimum":0.0,"title":"Offset","description":"Number of results to skip for pagination. OPTIONAL - Defaults to 0. Minimum: 0. Use with limit for pagination. Example: offset=20 with limit=20 returns results 21-40.","default":0,"examples":[0,20,40]}},"type":"object","required":["query"],"title":"SearchRequest","description":"Request model for searching across resource names and IDs.\n\nSearch is performed across all resource types within the authenticated namespace.\nThe search is case-insensitive and supports partial matching on both names and IDs.\n\nUse Cases:\n    - Find resources by partial name match\n    - Locate resources by ID prefix\n    - Filter search to specific resource types\n    - Paginate through large result sets\n\nRequirements:\n    - query: REQUIRED - Search term (minimum 1 character)\n    - resource_types: OPTIONAL - Filter by specific types\n    - limit: OPTIONAL - Results per page (1-100, default 20)\n    - offset: OPTIONAL - Pagination offset (default 0)","examples":[{"description":"Search all resources for 'product'","limit":20,"offset":0,"query":"product"},{"description":"Search only buckets and collections for 'video'","limit":50,"offset":0,"query":"video","resource_types":["bucket","collection"]},{"description":"Search by ID prefix with pagination","limit":20,"offset":20,"query":"bkt_","resource_types":["bucket"]},{"description":"Search retrievers and taxonomies","limit":10,"offset":0,"query":"recommendation","resource_types":["retriever","taxonomy"]}]},"SearchResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/SearchResultItem"},"type":"array","title":"Results","description":"List of matched resources. REQUIRED. May be empty if no matches found. Sorted by: 1) Exact matches first, 2) Partial matches, 3) Created timestamp descending. Length is min(total - offset, limit). Each result contains full resource metadata for display.","examples":[[{"created_at":"2024-01-15T10:30:00Z","description":"Product catalog","resource_id":"bkt_abc123","resource_name":"products","resource_type":"bucket"}],[]]},"total":{"type":"integer","minimum":0.0,"title":"Total","description":"Total number of matches across all pages. REQUIRED. Count before pagination is applied. Use to calculate total pages: ceil(total / limit). May be 0 if no matches found. Example: total=50 with limit=20 means 3 pages of results.","examples":[0,15,100]},"limit":{"type":"integer","maximum":100.0,"minimum":1.0,"title":"Limit","description":"Results per page (from request). REQUIRED. Echo of the limit parameter from the request. Range: 1-100.","examples":[20,50,100]},"offset":{"type":"integer","minimum":0.0,"title":"Offset","description":"Current pagination offset (from request). REQUIRED. Echo of the offset parameter from the request. Number of results skipped. Example: offset=20 means results start from the 21st match.","examples":[0,20,40]}},"type":"object","required":["results","total","limit","offset"],"title":"SearchResponse","description":"Response model for resource search results.\n\nContains paginated search results with metadata about total matches\nand pagination state. Results are sorted by relevance (exact matches first,\nthen partial matches) and creation time (newest first).\n\nUse Cases:\n    - Display search results to users\n    - Implement pagination UI\n    - Show total result counts\n    - Navigate through large result sets\n\nFields:\n    - results: List of matched resources\n    - total: Total number of matches (before pagination)\n    - limit: Results per page (from request)\n    - offset: Current pagination offset (from request)","examples":[{"description":"Successful search with multiple results","limit":20,"offset":0,"results":[{"created_at":"2024-01-15T10:30:00Z","description":"Production video content","resource_id":"bkt_prod123","resource_name":"production-videos","resource_type":"bucket","updated_at":"2024-01-20T14:22:00Z"},{"created_at":"2024-02-01T08:15:00Z","description":"Product catalog embeddings","resource_id":"col_prod456","resource_name":"Product Embeddings","resource_type":"collection"}],"total":15},{"description":"Empty search results","limit":20,"offset":0,"results":[],"total":0},{"description":"Paginated results (page 2)","limit":20,"offset":20,"results":[{"created_at":"2024-03-10T12:00:00Z","resource_id":"ret_search789","resource_name":"Search Pipeline","resource_type":"retriever","updated_at":"2024-03-15T16:45:00Z"}],"total":25}]},"SearchResultItem":{"properties":{"resource_type":{"type":"string","enum":["bucket","collection","retriever","taxonomy","cluster","published_retriever","namespace"],"title":"Resource Type","description":"Type of resource this result represents. REQUIRED. One of: 'bucket', 'collection', 'retriever', 'taxonomy', 'cluster', 'published_retriever', 'namespace'. Used to identify which resource type was matched and how to navigate to it. Example: 'bucket' indicates this is a bucket resource.","examples":["bucket","collection","retriever","taxonomy","cluster","published_retriever","namespace"]},"resource_id":{"type":"string","title":"Resource Id","description":"Unique identifier for the resource. REQUIRED. Format depends on resource_type: - bucket: 'bkt_XXXXXXXX' - collection: 'col_XXXXXXXXXX' - retriever: 'ret_XXXXXXXXXXXXXX' - taxonomy: 'tax_XXXXXXXXXXXX' - cluster: 'clust_XXXXXXXXXX' - published_retriever: 'pk_XXXXXXXXXX' - namespace: 'ns_XXXXXXXXXX'. Use this ID to fetch the full resource or perform operations on it.","examples":["bkt_abc12345","col_xyz7890123","ret_prod4567890abc","tax_categories01","clust_video0987","ns_1669d9e1ca"]},"resource_name":{"type":"string","title":"Resource Name","description":"Human-readable name of the resource. REQUIRED. This is the field that was matched in the search. Corresponds to: bucket_name, collection_name, retriever_name, taxonomy_name, cluster_name, or public_name. Example: 'Production Videos', 'Product Embeddings', 'Recommendation Engine', 'my-public-search'.","examples":["Production Videos","Product Embeddings","Recommendation Engine","Employee Taxonomy"]},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Description of the resource if provided. OPTIONAL - May be null if no description was set. Provides additional context about the resource's purpose or contents.","examples":["Video content for production environment","Product catalog with CLIP embeddings",null]},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Timestamp when the resource was created. REQUIRED. ISO 8601 format with UTC timezone. Used for sorting results by creation time."},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"Timestamp when the resource was last updated. OPTIONAL - May be null if resource has never been updated. ISO 8601 format with UTC timezone."}},"type":"object","required":["resource_type","resource_id","resource_name","created_at"],"title":"SearchResultItem","description":"Individual search result representing a matched resource.\n\nContains essential metadata about the matched resource including type,\nID, name, description, and timestamps. Results are sorted by relevance\n(exact matches first) and creation time.\n\nUse Cases:\n    - Display search results in UI\n    - Navigate to specific resources by ID\n    - Show resource metadata in search results\n    - Filter or sort results client-side\n\nFields:\n    - resource_type: Type of resource (bucket, collection, etc.)\n    - resource_id: Unique identifier for the resource\n    - resource_name: Human-readable name\n    - description: Optional description text\n    - created_at: When the resource was created\n    - updated_at: When the resource was last updated (if applicable)","examples":[{"created_at":"2024-01-15T10:30:00Z","description":"Video content for production environment","resource_id":"bkt_abc12345","resource_name":"production-videos","resource_type":"bucket","updated_at":"2024-01-20T14:22:00Z"},{"created_at":"2024-02-01T08:15:00Z","description":"Product catalog with CLIP embeddings","resource_id":"col_xyz7890123","resource_name":"Product Embeddings","resource_type":"collection"},{"created_at":"2024-03-10T12:00:00Z","resource_id":"ret_prod4567890abc","resource_name":"Recommendation Engine","resource_type":"retriever","updated_at":"2024-03-15T16:45:00Z"}]},"SecretResponse":{"properties":{"secret_name":{"type":"string","title":"Secret Name","description":"Name of the secret that was operated on. This is the same name provided in the request. Use this name to reference the secret in api_call stage configuration.","examples":["stripe_api_key","github_token","openai_api_key"]},"created":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Created","description":"True if this secret was created, null otherwise. Only set for POST /secrets operations."},"updated":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Updated","description":"True if this secret was updated, null otherwise. Only set for PUT /secrets/{name} operations."},"deleted":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Deleted","description":"True if this secret was deleted, null otherwise. Only set for DELETE /secrets/{name} operations."}},"type":"object","required":["secret_name"],"title":"SecretResponse","description":"Response for secret operations (NEVER includes actual decrypted value).\n\nThis response is returned after creating, updating, or deleting a secret.\nFor security, the actual secret value is NEVER included in API responses.\nOnly the secret name and operation status are returned.\n\n**Security**:\n- Decrypted secret values are NEVER included\n- Only secret name and operation status returned\n- Actual value only accessible by internal services\n\n**Fields**:\n- secret_name: Name of the secret that was operated on\n- created: True if secret was created (null for other operations)\n- updated: True if secret was updated (null for other operations)\n- deleted: True if secret was deleted (null for other operations)","examples":[{"created":true,"description":"Secret created successfully","secret_name":"stripe_api_key"},{"description":"Secret updated successfully","secret_name":"github_token","updated":true},{"deleted":true,"description":"Secret deleted successfully","secret_name":"old_api_key"}]},"SecretVersion":{"properties":{"name":{"type":"string","title":"Name"},"version":{"type":"string","title":"Version","description":"Version name of the stored value at snapshot time; the value itself is never recorded"}},"type":"object","required":["name","version"],"title":"SecretVersion"},"SecretsListResponse":{"properties":{"secrets":{"items":{"type":"string"},"type":"array","title":"Secrets","description":"List of secret names in the organization vault. Only names are returned, never decrypted values. Use these names as references in api_call stage configuration. Names are unique within the organization. Empty list if no secrets are configured.","examples":[["stripe_api_key","github_token"],["openai_api_key"],[]]},"count":{"type":"integer","title":"Count","description":"Total number of secrets in the organization vault. This is the length of the secrets array. Useful for monitoring and auditing secret inventory.","examples":[4,1,0]}},"type":"object","required":["secrets","count"],"title":"SecretsListResponse","description":"Response for listing secrets in the organization vault.\n\nReturns ONLY secret names, never decrypted values. Use this endpoint to\ndiscover which secrets are configured in your organization.\n\n**Security**:\n- Returns ONLY secret names, never values\n- Decrypted values never exposed via API\n- Use for auditing which secrets are configured\n\n**Use Cases**:\n- Discover which secrets are configured\n- Audit secret inventory\n- Check if a secret exists before using it\n- Verify secret name spelling before referencing in api_call\n\n**Permissions**: Requires READ permission to list secrets.","examples":[{"count":4,"description":"Organization with multiple API keys configured","secrets":["stripe_api_key","github_token","openai_api_key","weather_api_key"]},{"count":1,"description":"Organization with single secret","secrets":["stripe_api_key"]},{"count":0,"description":"Organization with no secrets configured","secrets":[]}]},"SectionConfig":{"properties":{"section_id":{"type":"string","title":"Section Id","description":"Auto-generated section identifier"},"type":{"type":"string","title":"Type","description":"Section type: 'hero', 'stats-bar', 'featured-gallery', 'search-tabs', 'results-grid', 'results-list', 'markdown-content', 'iframe-embed'"},"props":{"additionalProperties":true,"type":"object","title":"Props","description":"Section-specific configuration properties"},"order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Order","description":"Explicit render order; falls back to array position if omitted"}},"type":"object","required":["type"],"title":"SectionConfig","description":"A single section/block in a page layout."},"SeedBatchStatus":{"properties":{"bucket":{"type":"string","title":"Bucket","description":"Bucket name the seed ingested into"},"batch_id":{"type":"string","title":"Batch Id","description":"The seed batch's id"},"status":{"type":"string","title":"Status","description":"The batch status when apply stopped waiting: COMPLETED, COMPLETED_WITH_ERRORS, FAILED, CANCELED, PROCESSING and so on. UNKNOWN when the batch could not be read"},"terminal":{"type":"boolean","title":"Terminal","description":"true when the batch finished, whether or not it succeeded"},"usable":{"type":"boolean","title":"Usable","description":"true when the batch finished COMPLETED or COMPLETED_WITH_ERRORS, so its documents can be queried"},"documents_written":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Documents Written","description":"Documents the batch wrote, when the batch reports it"},"failed_objects":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Failed Objects","description":"Objects the batch could not process"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Why the batch could not be read"}},"type":"object","required":["bucket","batch_id","status","terminal","usable"],"title":"SeedBatchStatus","description":"Where one `seed:` batch stands, read while apply waits for it."},"SendMessageRequest":{"properties":{"content":{"type":"string","minLength":1,"title":"Content","description":"Message text content (REQUIRED)"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Message metadata (OPTIONAL)"},"stream":{"type":"boolean","title":"Stream","description":"Stream response as SSE (default: True)","default":true}},"type":"object","required":["content"],"title":"SendMessageRequest","description":"Request payload for sending a message to the agent.\n\nAttributes:\n    content: Message text content\n    metadata: Optional message metadata\n    stream: Whether to stream response as SSE (default: True)\n\nNote:\n    When stream=True, the response will be Server-Sent Events (SSE).\n    When stream=False, the response will be a MessageResponse object.\n\nExample:\n    ```python\n    # Streaming request (SSE)\n    request = SendMessageRequest(\n        content=\"Find videos about machine learning\",\n        stream=True\n    )\n\n    # Non-streaming request\n    request = SendMessageRequest(\n        content=\"Find videos about machine learning\",\n        stream=False\n    )\n    ```","examples":[{"content":"Find videos about machine learning","metadata":{"source":"web_app"},"stream":true}]},"ServeAppStatus":{"properties":{"name":{"type":"string","title":"Name","description":"Ray Serve application name, as the engine deploys it."},"status":{"type":"string","title":"Status","description":"Live status of that application on the deployment serving this request. A Ray Serve status such as 'RUNNING', 'DEPLOYING' or 'UNHEALTHY'; 'absent' when the deployment does not serve it; 'unconfigured' when it runs but the deployment lacks the model provider's key or credentials; 'unknown' when the live list could not be read."}},"type":"object","required":["name","status"],"title":"ServeAppStatus","description":"One Ray Serve application an extractor needs, with its live status."},"ServiceHealth":{"properties":{"availability":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Availability","description":"Success rate over the latest rollup window: 1 - failed_rate from the namespace `_signals` rollup doc. None = no rollup doc for the window yet, not zero."},"degraded_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Degraded Rate","description":"Fraction of executions that degraded, read from the namespace rollup doc's degraded_rate. None = not yet computed here, not zero."},"partial_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Partial Rate","description":"Fraction of executions that degraded but still returned results, from the rollup doc's partial_rate. None = not yet computed here, not zero."},"timeout_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Timeout Rate","description":"Fraction of executions that hit a stage-budget ceiling (a stage cancelled/skipped for exceeding its hard latency ceiling), read from the namespace rollup doc's timeout_rate. None = no rollup doc for the window yet, or the doc predates the flag; not zero. A real 0.0 means no timeouts in the window."},"throttle_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Throttle Rate","description":"Fraction of executions rejected by a credit/quota cap (the UnauthorizedError-on-cap class), read from the namespace rollup doc's throttle_rate. None = no rollup doc for the window yet, or the doc predates the flag; not zero. A real 0.0 means no cap rejections in the window."},"dependency_health":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Dependency Health","description":"Per-dependency status (shard / embedding / redis / object-store). None = no readable per-dependency health registry exists yet; the Ownership registry is not present in this codebase, so there is nothing to join per-tenant. Not an empty object."},"window_end_ts":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Window End Ts","description":"Epoch seconds of the rollup window the rates were read from. None when no rollup doc was found."},"freshness_seconds":{"type":"integer","title":"Freshness Seconds","description":"Metrics-availability budget: these health dimensions reflect state within this many seconds (the 'within 2 minutes' guarantee). Rollup docs are folded at the signals sweep cadence.","default":120},"reconciliation":{"type":"string","title":"Reconciliation","description":"Stated tolerance for how these counts tie to request logs.","default":"Rates come from the unsampled per-execution `_signals` ledger (one doc per execution) folded into the latest complete rollup window. They reconcile to request logs within one rollup window (default 60 minutes); executions in the in-progress window may not be folded yet."}},"type":"object","title":"ServiceHealth","description":"Per-namespace service-health dimensions.\n\nHonest health is the whole point of this block. Every dimension whose\nsource is not wired returns None with the reason stated in its Field\ndescription. None means \"not yet computed here\", never zero: a fabricated\n0.0 or 1.0 would read as perfect health and hide the gap.\n\nThe rollup-backed dimensions (availability, degraded_rate, partial_rate,\nand — timeout_rate, throttle_rate) are READ from the namespace\nrollup doc the signals sweep already writes (api/documents/signals_rollup.py,\nnamespace_rollup_doc). This block never recomputes the rollup.\ndependency_health remains unwired (None) until a per-dependency registry\nexists."},"SessionFilter-Input":{"properties":{"retriever_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Retriever Ids","description":"Filter to sessions from these retrievers."},"taxonomy_node_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Taxonomy Node Ids","description":"Filter to sessions with these taxonomy classifications."},"time_range":{"anyOf":[{"$ref":"#/components/schemas/TimeRange-Input"},{"type":"null"}],"description":"Filter to sessions within this time window."},"min_interactions":{"type":"integer","minimum":1.0,"title":"Min Interactions","description":"Minimum number of user interactions required.","default":1},"interaction_types":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Interaction Types","description":"Filter to sessions with these interaction types (e.g., ['click', 'purchase'])."},"sample_strategy":{"type":"string","title":"Sample Strategy","description":"How to sample sessions: 'random', 'recent', or 'stratified'.","default":"random"},"interaction_weights":{"$ref":"#/components/schemas/InteractionWeights","description":"Custom weights for interaction types when computing relevance scores."}},"type":"object","title":"SessionFilter","description":"Criteria for selecting historical sessions to replay."},"SessionFilter-Output":{"properties":{"retriever_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Retriever Ids","description":"Filter to sessions from these retrievers."},"taxonomy_node_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Taxonomy Node Ids","description":"Filter to sessions with these taxonomy classifications."},"time_range":{"anyOf":[{"$ref":"#/components/schemas/shared__retrievers__benchmarks__models__TimeRange"},{"type":"null"}],"description":"Filter to sessions within this time window."},"min_interactions":{"type":"integer","minimum":1.0,"title":"Min Interactions","description":"Minimum number of user interactions required.","default":1},"interaction_types":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Interaction Types","description":"Filter to sessions with these interaction types (e.g., ['click', 'purchase'])."},"sample_strategy":{"type":"string","title":"Sample Strategy","description":"How to sample sessions: 'random', 'recent', or 'stratified'.","default":"random"},"interaction_weights":{"$ref":"#/components/schemas/InteractionWeights","description":"Custom weights for interaction types when computing relevance scores."}},"type":"object","title":"SessionFilter","description":"Criteria for selecting historical sessions to replay."},"SessionQuotas":{"properties":{"max_messages":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Max Messages","description":"Maximum messages allowed in session. Unset = unlimited."},"max_tokens_total":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Max Tokens Total","description":"Maximum cumulative tokens for session. Unset = unlimited."},"max_tool_calls":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Max Tool Calls","description":"Maximum tool calls per session. Unset = unlimited."},"max_session_duration_minutes":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Max Session Duration Minutes","description":"Maximum session lifetime in minutes. Unset = no time limit."},"rate_limit_messages_per_minute":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Rate Limit Messages Per Minute","description":"Max messages per minute to prevent spam. Unset = unlimited."}},"type":"object","title":"SessionQuotas","description":"Session-level quotas and rate limits.\n\nThese limits are enforced per-session to prevent runaway costs.\nAll fields are optional - unset means unlimited.\n\nAttributes:\n    max_messages: Maximum messages allowed in session (prevents long conversations)\n    max_tokens_total: Maximum cumulative tokens for session (cost control)\n    max_tool_calls: Maximum tool calls per session (limits API usage)\n    max_session_duration_minutes: Maximum session lifetime in minutes\n    rate_limit_messages_per_minute: Max messages per minute (prevents spam)\n\nExample:\n    ```python\n    # Basic quotas for a demo session\n    quotas = SessionQuotas(\n        max_messages=50,\n        max_tokens_total=50000,\n        max_tool_calls=25\n    )\n\n    # Strict quotas for production\n    quotas = SessionQuotas(\n        max_messages=100,\n        max_tokens_total=100000,\n        max_tool_calls=50,\n        max_session_duration_minutes=60,\n        rate_limit_messages_per_minute=10\n    )\n    ```","examples":[{"max_messages":100,"max_tokens_total":100000,"max_tool_calls":50,"rate_limit_messages_per_minute":10}]},"SessionStats":{"properties":{"total_messages":{"type":"integer","minimum":0.0,"title":"Total Messages","description":"Total messages sent in session","default":0},"total_tokens":{"type":"integer","minimum":0.0,"title":"Total Tokens","description":"Cumulative tokens used (for cost tracking)","default":0},"total_tool_calls":{"type":"integer","minimum":0.0,"title":"Total Tool Calls","description":"Total tool invocations","default":0},"avg_latency_ms":{"type":"number","minimum":0.0,"title":"Avg Latency Ms","description":"Average message latency in milliseconds","default":0.0}},"type":"object","title":"SessionStats","description":"Session usage statistics.\n\nTracked in MongoDB session document, updated on each message.\nUse this to display usage metrics in your UI.\n\nAttributes:\n    total_messages: Total messages sent in session\n    total_tokens: Cumulative tokens used (for cost tracking)\n    total_tool_calls: Total tool invocations\n    avg_latency_ms: Average message latency in milliseconds\n\nExample:\n    ```python\n    # Display in UI\n    stats = session_response.stats\n    print(f\"Messages: {stats.total_messages}\")\n    print(f\"Tokens used: {stats.total_tokens}\")\n    print(f\"Tool calls: {stats.total_tool_calls}\")\n    print(f\"Avg latency: {stats.avg_latency_ms:.0f}ms\")\n    ```"},"SessionStatus":{"type":"string","enum":["active","idle","archived","terminated"],"title":"SessionStatus","description":"Session lifecycle states.\n\nAttributes:\n    ACTIVE: Session is actively processing messages\n    IDLE: Session exists but no recent activity\n    ARCHIVED: Session archived (read-only)\n    TERMINATED: Session permanently closed"},"SetupPaymentMethodResponse":{"properties":{"setup_intent_id":{"type":"string","title":"Setup Intent Id","description":"Stripe SetupIntent ID","examples":["seti_1ABC2DEF3GHI"]},"client_secret":{"type":"string","title":"Client Secret","description":"Client secret for Stripe Elements","examples":["seti_1ABC2DEF3GHI_secret_XYZ"]},"customer_id":{"type":"string","title":"Customer Id","description":"Stripe Customer ID","examples":["cus_ABC123DEF456"]}},"type":"object","required":["setup_intent_id","client_secret","customer_id"],"title":"SetupPaymentMethodResponse","description":"Response after creating a SetupIntent."},"ShardFrontier":{"properties":{"history_id":{"type":"string","title":"History Id","description":"WAL lineage of the shard","default":""},"durable_confirmed_seq":{"type":"integer","title":"Durable Confirmed Seq","description":"WAL seq of the shard's last durable snapshot","default":0},"shipped_wal_highwater":{"type":"integer","title":"Shipped Wal Highwater","description":"Newest sealed and shipped WAL seq","default":0},"frontier_seq":{"type":"integer","title":"Frontier Seq","description":"max(durable_confirmed_seq, shipped_wal_highwater): every write at or below this seq survives a cold restore of the shard","default":0},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note","description":"Why the shard reported no WAL lineage for this namespace, e.g. a namespace served from a shared dataset"}},"type":"object","title":"ShardFrontier"},"SharePointClientCredentials":{"properties":{"type":{"type":"string","const":"client_credentials","title":"Type","default":"client_credentials"},"tenant_id":{"type":"string","title":"Tenant Id","description":"REQUIRED. Azure AD tenant ID (directory ID). Find in: Azure Portal > Azure Active Directory > Overview. Format: UUID (e.g., '12345678-1234-1234-1234-123456789abc')","examples":["12345678-1234-1234-1234-123456789abc"]},"client_id":{"type":"string","title":"Client Id","description":"REQUIRED. Azure AD application (client) ID. Find in: Azure Portal > App Registrations > Your App > Overview. Format: UUID","examples":["87654321-4321-4321-4321-cba987654321"]},"client_secret":{"type":"string","title":"Client Secret","description":"REQUIRED. Azure AD client secret for authentication. SECURITY: This is a secret credential, redacted on read. Never log or expose. Generate in: Azure Portal > App Registrations > Your App > Certificates & secrets. Note: Secrets expire; consider using certificates for production."}},"type":"object","required":["tenant_id","client_id","client_secret"],"title":"SharePointClientCredentials","description":"SharePoint/OneDrive client credentials (app-only) authentication.\n\nClient credentials flow provides application-level access without user interaction.\nRecommended for automated sync operations in enterprise environments.\n\nPrerequisites:\n    1. Register an application in Azure AD (portal.azure.com)\n    2. Grant Microsoft Graph API permissions:\n       - Sites.Read.All (Application) - for SharePoint site access\n       - Files.Read.All (Application) - for file access\n    3. Admin consent granted for the permissions\n    4. Generate client secret\n\nSecurity:\n    - client_secret is a secret credential, redacted on read\n    - Provides application-level access to all sites (based on permissions)\n    - No user context - accesses files as the application itself\n    - Consider using certificate-based auth for production\n\nUse Cases:\n    - Automated enterprise-wide document ingestion\n    - Background sync without user interaction\n    - Multi-tenant applications with admin consent"},"SharePointConfig":{"properties":{"provider_type":{"type":"string","const":"sharepoint","title":"Provider Type","default":"sharepoint"},"credentials":{"oneOf":[{"$ref":"#/components/schemas/SharePointClientCredentials"},{"$ref":"#/components/schemas/SharePointDelegatedCredentials"}],"title":"Credentials","description":"REQUIRED. Azure AD authentication credentials. Choose client_credentials for production (app-only) or delegated for user-level access. The 'type' field determines which authentication flow is used.","discriminator":{"propertyName":"type","mapping":{"client_credentials":"#/components/schemas/SharePointClientCredentials","delegated":"#/components/schemas/SharePointDelegatedCredentials"}}},"site_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Id","description":"NOT REQUIRED if using personal OneDrive. SharePoint site identifier for targeting a specific site. Format: '{hostname},{site-collection-id},{web-id}' or site URL. Find via: Microsoft Graph API GET /sites?search={keyword} Example: 'contoso.sharepoint.com,12345678-...,87654321-...'","examples":["contoso.sharepoint.com,12345678-1234-1234-1234-123456789abc,87654321-4321-4321-4321-cba987654321","root"]},"drive_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Drive Id","description":"NOT REQUIRED if you want to use the default document library. Specific drive (document library) ID within the site. Find via: GET /sites/{site-id}/drives Format: Base64-encoded ID starting with 'b!'","examples":["b!abc123def456..."]},"folder_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Folder Path","description":"NOT REQUIRED. Path within the drive to sync from. If omitted, syncs from the root of the drive. Format: Forward-slash separated path (e.g., '/Documents/Marketing'). Note: Leading slash is optional.","examples":["/Shared Documents/Marketing","Projects/2024","/"]}},"type":"object","required":["credentials"],"title":"SharePointConfig","description":"Microsoft SharePoint and OneDrive for Business configuration.\n\nEnables Mixpeek to connect to SharePoint sites, document libraries, and\nOneDrive for Business for automated file ingestion and synchronization.\n\nArchitecture:\n    SharePoint hierarchy: Tenant → Sites → Drives (Document Libraries) → Items\n    - site_id: Identifies the SharePoint site\n    - drive_id: Identifies a specific document library within the site\n    - folder_path: Path within the document library\n\nAuthentication Methods:\n    1. Client Credentials (RECOMMENDED for production):\n        - App-only access without user interaction\n        - Requires admin consent for Graph API permissions\n        - Access level determined by app permissions\n\n    2. Delegated:\n        - User-level access via OAuth consent\n        - Access limited to user's permissions\n        - Requires refresh token management\n\nRequirements:\n    - Azure AD application registration\n    - Microsoft Graph API permissions (Sites.Read.All, Files.Read.All)\n    - Network connectivity to graph.microsoft.com\n\nUse Cases:\n    - Sync SharePoint document libraries\n    - Ingest enterprise collaboration files\n    - Monitor and process uploaded documents\n    - Archive compliance-sensitive materials\n\nExample:\n    ```python\n    config = {\n        \"provider_type\": \"sharepoint\",\n        \"credentials\": {\n            \"type\": \"client_credentials\",\n            \"tenant_id\": \"12345678-...\",\n            \"client_id\": \"87654321-...\",\n            \"client_secret\": \"your-secret\",\n        },\n        \"site_id\": \"contoso.sharepoint.com,guid1,guid2\",\n        \"drive_id\": \"b!abc123...\",\n        \"folder_path\": \"/Shared Documents/Marketing\",\n    }\n    ```","examples":[{"credentials":{"client_id":"87654321-4321-4321-4321-cba987654321","client_secret":"your-client-secret-here","tenant_id":"12345678-1234-1234-1234-123456789abc","type":"client_credentials"},"description":"Production SharePoint with client credentials","drive_id":"b!abc123def456ghi789","folder_path":"/Shared Documents/Marketing","provider_type":"sharepoint","site_id":"contoso.sharepoint.com,12345678-1234-1234-1234-123456789abc,87654321-4321-4321-4321-cba987654321"},{"credentials":{"client_id":"87654321-4321-4321-4321-cba987654321","client_secret":"your-client-secret","refresh_token":"0.AAAA...","tenant_id":"common","type":"delegated"},"description":"Personal OneDrive with delegated auth","folder_path":"/Documents/Projects","provider_type":"sharepoint"},{"credentials":{"client_id":"87654321-4321-4321-4321-cba987654321","client_secret":"your-client-secret","tenant_id":"12345678-1234-1234-1234-123456789abc","type":"client_credentials"},"description":"SharePoint root site, default document library","provider_type":"sharepoint","site_id":"root"}]},"SharePointDelegatedCredentials":{"properties":{"type":{"type":"string","const":"delegated","title":"Type","default":"delegated"},"tenant_id":{"type":"string","title":"Tenant Id","description":"REQUIRED. Azure AD tenant ID. Use 'common' for multi-tenant apps, or specific tenant ID for single-tenant.","examples":["12345678-1234-1234-1234-123456789abc","common"]},"client_id":{"type":"string","title":"Client Id","description":"REQUIRED. Azure AD application (client) ID.","examples":["87654321-4321-4321-4321-cba987654321"]},"client_secret":{"type":"string","title":"Client Secret","description":"REQUIRED. Azure AD client secret. SECURITY: Secret credential, redacted on read. Never log or expose."},"refresh_token":{"type":"string","title":"Refresh Token","description":"REQUIRED. OAuth2 refresh token obtained from consent flow. SECURITY: Encrypted at rest. Can be revoked by user. Obtain via: Complete OAuth flow with Files.Read.All scope."}},"type":"object","required":["tenant_id","client_id","client_secret","refresh_token"],"title":"SharePointDelegatedCredentials","description":"SharePoint/OneDrive delegated (user) authentication via OAuth2.\n\nDelegated flow provides access on behalf of a specific user.\nUseful when you need to access files with user-level permissions.\n\nPrerequisites:\n    1. Register an application in Azure AD\n    2. Grant Microsoft Graph API permissions:\n       - Sites.Read.All (Delegated) or Sites.Selected\n       - Files.Read.All (Delegated) or Files.Read\n    3. Configure redirect URI for OAuth flow\n    4. Complete OAuth consent to obtain refresh token\n\nSecurity:\n    - client_secret and refresh_token are secret credentials, redacted on read\n    - Access scoped to what the consenting user can access\n    - Refresh tokens can be revoked by user or admin\n\nUse Cases:\n    - Personal OneDrive access\n    - User-specific SharePoint sites\n    - Respecting per-user permissions"},"SingleLineageEntry":{"properties":{"source_config":{"$ref":"#/components/schemas/SourceConfig-Output","description":"Configuration of the source for this lineage entry"},"feature_extractor":{"$ref":"#/components/schemas/shared__collection__features__extractors__models__FeatureExtractorConfig-Output","description":"Single feature extractor applied at this stage"},"output_schema":{"$ref":"#/components/schemas/BucketSchema-Output","description":"Output schema produced by this processing stage"}},"type":"object","required":["source_config","feature_extractor","output_schema"],"title":"SingleLineageEntry","description":"Single entry in the lineage chain of a collection.\n\nEach lineage entry represents one processing stage with one feature extractor."},"SkippedDocumentRef":{"properties":{"collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Collection Id"},"document_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Id"},"reason":{"type":"string","title":"Reason"}},"type":"object","required":["reason"],"title":"SkippedDocumentRef","description":"A document reference that could not contribute to the node anchor."},"SlackConfig":{"properties":{"webhook_url":{"type":"string","title":"Webhook Url","description":"Slack webhook URL"},"channel":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Channel","description":"Slack channel to send to"},"username":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Username","description":"Username to use for the message"},"icon_emoji":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Icon Emoji","description":"Emoji to use as the icon"},"icon_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Icon Url","description":"URL to an image to use as the icon"},"blocks_template":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Blocks Template","description":"Template for Slack blocks"}},"type":"object","required":["webhook_url"],"title":"SlackConfig","description":"Configuration for Slack notifications."},"SlackInviteStatus":{"properties":{"status":{"type":"string","enum":["never_attempted","pending","sent","failed","skipped"],"title":"Status","description":"never_attempted: no invite attempt recorded for this org. pending: attempt in flight. sent: Slack Connect shared-channel invite delivered (Slack emails the recipient). failed: the attempt errored (nothing delivered). skipped: the automation ran and declined this user.","default":"never_attempted"},"channel_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Channel Name","description":"The per-customer Slack Connect channel name, once known.","examples":["ext-mixpeek-acme-com"]},"invited_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Invited At","description":"When the invite was sent (status 'sent' only)."}},"type":"object","title":"SlackInviteStatus","description":"Slack Connect invite state exposed on usage/current (contract).\n\nFive states. 'never_attempted' (the automation never ran for this org) is\nDISTINCT from 'skipped' (the automation ran and declined this user, e.g.\ngmail on the free signup path) — collapsing them would tell a paying gmail\ncustomer 'we skipped you' when the path was actually dormant."},"SlowOperation":{"properties":{"timestamp":{"type":"string","format":"date-time","title":"Timestamp","description":"When the operation occurred"},"stage_name":{"type":"string","title":"Stage Name","description":"Stage name"},"component":{"type":"string","title":"Component","description":"Component"},"latency_ms":{"type":"number","title":"Latency Ms","description":"Operation latency"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Additional context from profiling"}},"type":"object","required":["timestamp","stage_name","component","latency_ms"],"title":"SlowOperation","description":"Details of a slow operation."},"SlowOperationsResponse":{"properties":{"time_range":{"$ref":"#/components/schemas/api__analytics__models__TimeRange","description":"Time range of the query"},"operations":{"items":{"$ref":"#/components/schemas/SlowOperation"},"type":"array","title":"Operations","description":"List of slowest operations"},"threshold_ms":{"type":"number","title":"Threshold Ms","description":"Latency threshold used for filtering"}},"type":"object","required":["time_range","operations","threshold_ms"],"title":"SlowOperationsResponse","description":"Response for slowest operations query."},"SlowQueriesResponse":{"properties":{"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace ID analyzed"},"time_range_days":{"type":"integer","title":"Time Range Days","description":"Number of days analyzed"},"latency_threshold_ms":{"type":"number","title":"Latency Threshold Ms","description":"Latency threshold used"},"slow_queries":{"items":{"$ref":"#/components/schemas/SlowQueryDetails"},"type":"array","title":"Slow Queries","description":"Slow query details, newest-slowest first, capped at `limit`"},"total_slow_queries":{"type":"integer","title":"Total Slow Queries","description":"Slow queries in the whole window, NOT the length of `slow_queries`. Falls back to the returned count when `total_is_exact` is false."},"returned_count":{"type":"integer","title":"Returned Count","description":"How many entries `slow_queries` actually contains"},"total_is_exact":{"type":"boolean","title":"Total Is Exact","description":"False when the total could not be counted (analytics backend unreachable) and `total_slow_queries` is a floor, not a total."}},"type":"object","required":["namespace_id","time_range_days","latency_threshold_ms","slow_queries","total_slow_queries","returned_count","total_is_exact"],"title":"SlowQueriesResponse","description":"Response for slow queries endpoint."},"SlowQueryDetails":{"properties":{"retriever_id":{"type":"string","title":"Retriever Id","description":"Retriever that executed the query"},"query":{"type":"string","title":"Query","description":"Query input string"},"latency_ms":{"type":"number","title":"Latency Ms","description":"Query latency in milliseconds"},"results_count":{"type":"integer","title":"Results Count","description":"Number of results returned"},"queried_fields":{"items":{"type":"string"},"type":"array","title":"Queried Fields","description":"List of metadata fields queried"}},"type":"object","required":["retriever_id","query","latency_ms","results_count","queried_fields"],"title":"SlowQueryDetails","description":"Details of a slow query."},"SmokeTestResult":{"properties":{"passed":{"type":"boolean","title":"Passed"},"url":{"type":"string","title":"Url"},"errors":{"items":{"type":"string"},"type":"array","title":"Errors","default":[]},"duration_ms":{"type":"integer","title":"Duration Ms","default":0},"tested_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tested At"}},"type":"object","required":["passed","url"],"title":"SmokeTestResult","description":"Result of a post-deploy smoke test."},"SnapshotCopyOut":{"properties":{"status":{"type":"string","title":"Status","description":"'copied', 'failed', 'not_configured' (no backup bucket on this plane), or 'skipped' (a daily snapshot, covered by retention)"},"bucket":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bucket"},"objects":{"type":"integer","title":"Objects","default":0},"bytes":{"type":"integer","title":"Bytes","default":0},"mismatched":{"items":{"type":"string"},"type":"array","title":"Mismatched","description":"Artifacts whose copy did not hash to the manifest's digest"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"}},"type":"object","required":["status"],"title":"SnapshotCopyOut","description":"The snapshot's copy in the plane's backup bucket (plan 18.4)."},"SnapshotDetailResponse":{"properties":{"snapshot_id":{"type":"string","title":"Snapshot Id"},"namespace_id":{"type":"string","title":"Namespace Id"},"namespace_name":{"type":"string","title":"Namespace Name"},"internal_id":{"type":"string","title":"Internal Id"},"snapshot_type":{"$ref":"#/components/schemas/SnapshotType"},"status":{"$ref":"#/components/schemas/SnapshotStatus","default":"pending"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"dispatch_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Dispatch At","description":"When the snapshot's work was due to start (created_at plus any dispatch stagger)"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"schema_version":{"type":"integer","title":"Schema Version","default":1},"s3_prefix":{"type":"string","title":"S3 Prefix","default":""},"s3_objects_copied":{"type":"boolean","title":"S3 Objects Copied","default":false},"manifest":{"anyOf":[{"$ref":"#/components/schemas/SnapshotManifest"},{"type":"null"}]},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id"},"include_vectors":{"type":"boolean","title":"Include Vectors","description":"False for a metadata-only snapshot, which holds the namespace's records but no vector points; restoring it writes no vectors.","default":true},"vector_shard_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vector Shard Key"},"copy_out":{"anyOf":[{"$ref":"#/components/schemas/SnapshotCopyOut"},{"type":"null"}],"description":"The copy of this snapshot in the plane's backup bucket"},"imported_from":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Imported From","description":"For an imported snapshot, the bucket and prefix it was copied from and the source snapshot's id"},"last_restore":{"anyOf":[{"$ref":"#/components/schemas/RestoreReport"},{"type":"null"}],"description":"Outcome of the most recent restore FROM this snapshot (what was restored vs skipped); null if never restored."},"download":{"anyOf":[{"$ref":"#/components/schemas/SnapshotDownload"},{"type":"null"}],"description":"Signed URLs for every artifact, with each one's sha256. Present only when the request sets download=true."}},"type":"object","required":["namespace_id","namespace_name","internal_id","snapshot_type"],"title":"SnapshotDetailResponse"},"SnapshotDownload":{"properties":{"expires_at":{"type":"string","format":"date-time","title":"Expires At","description":"When every URL in artifacts stops working"},"artifacts":{"items":{"$ref":"#/components/schemas/SnapshotDownloadArtifact"},"type":"array","title":"Artifacts","description":"Every artifact of the snapshot: manifest.json, config.yaml, the Mongo dumps, the vector export and the object manifest"}},"type":"object","required":["expires_at","artifacts"],"title":"SnapshotDownload"},"SnapshotDownloadArtifact":{"properties":{"path":{"type":"string","title":"Path","description":"The artifact's path inside the snapshot, e.g. mongo/buckets.ndjson.gz"},"url":{"type":"string","title":"Url","description":"A signed GET URL for the artifact; expires at download.expires_at"},"sha256":{"type":"string","title":"Sha256","description":"The artifact's sha256, recorded when the snapshot was taken"},"size":{"type":"integer","title":"Size","description":"The artifact's size in bytes"}},"type":"object","required":["path","url","sha256","size"],"title":"SnapshotDownloadArtifact"},"SnapshotFrontier":{"properties":{"consistency":{"type":"string","title":"Consistency","description":"'bracketed': each store's capture lies between its recorded start and end positions","default":"bracketed"},"mongo":{"$ref":"#/components/schemas/MongoFrontier"},"vectors":{"$ref":"#/components/schemas/VectorFrontier"},"objects":{"$ref":"#/components/schemas/ObjectFrontier"},"config_yaml":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Config Yaml","description":"The namespace's configuration exported as a manifest YAML, secrets replaced by placeholders"},"config_yaml_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Config Yaml Error"},"digests":{"additionalProperties":{"$ref":"#/components/schemas/ArtifactDigest"},"type":"object","title":"Digests","description":"sha256 and size of every artifact, keyed by path under the snapshot prefix"},"schema_versions":{"additionalProperties":{"anyOf":[{"type":"integer"},{"type":"string"}]},"type":"object","title":"Schema Versions","description":"Format version of the manifest and of each artifact kind"},"secrets":{"items":{"$ref":"#/components/schemas/SecretVersion"},"type":"array","title":"Secrets","description":"Organization secrets by name and version at snapshot time"}},"type":"object","title":"SnapshotFrontier","description":"Where each store stood when the snapshot was taken.\n\nEach half is read before and after its capture, so a restore knows the window\nthe data lies in. ``consistency`` names that tier."},"SnapshotImportSource":{"properties":{"bucket":{"type":"string","title":"Bucket","description":"A backup bucket snapshots can be imported from, such as the source plane's (copy_out.bucket on the source snapshot)"},"prefix":{"type":"string","title":"Prefix","description":"The source snapshot's path in that bucket (its s3_prefix), such as <org>/<namespace_id>/_snapshots/<snapshot_id>/"}},"additionalProperties":false,"type":"object","required":["bucket","prefix"],"title":"SnapshotImportSource","description":"Where a snapshot taken on another plane is read from (plan 18.8)."},"SnapshotManifest":{"properties":{"snapshot_id":{"type":"string","title":"Snapshot Id"},"namespace_id":{"type":"string","title":"Namespace Id"},"namespace_name":{"type":"string","title":"Namespace Name"},"schema_version":{"type":"integer","title":"Schema Version","default":1},"created_at":{"type":"string","format":"date-time","title":"Created At"},"snapshot_type":{"type":"string","title":"Snapshot Type"},"mongo_collections":{"additionalProperties":{"type":"integer"},"type":"object","title":"Mongo Collections","description":"Map of collection name to document count"},"vector_point_count":{"type":"integer","title":"Vector Point Count","default":0},"s3_object_count":{"type":"integer","title":"S3 Object Count","default":0},"s3_total_bytes":{"type":"integer","title":"S3 Total Bytes","default":0},"s3_objects_copied":{"type":"boolean","title":"S3 Objects Copied","default":false},"include_vectors":{"type":"boolean","title":"Include Vectors","description":"Whether this snapshot exported the namespace's own vector points. Daily and manual snapshots export them. False marks a metadata-only snapshot: it holds the namespace's records but no vector points, and restoring it writes no vectors.","default":true},"vector_shard_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vector Shard Key","description":"Physical shard this namespace's vectors lived on when the snapshot was taken."},"frontier":{"anyOf":[{"$ref":"#/components/schemas/SnapshotFrontier"},{"type":"null"}],"description":"Store positions, configuration, digests and secret versions recorded at capture; null on manifests older than schema version 2"}},"type":"object","required":["snapshot_id","namespace_id","namespace_name","created_at","snapshot_type"],"title":"SnapshotManifest"},"SnapshotModel":{"properties":{"snapshot_id":{"type":"string","title":"Snapshot Id"},"namespace_id":{"type":"string","title":"Namespace Id"},"namespace_name":{"type":"string","title":"Namespace Name"},"internal_id":{"type":"string","title":"Internal Id"},"snapshot_type":{"$ref":"#/components/schemas/SnapshotType"},"status":{"$ref":"#/components/schemas/SnapshotStatus","default":"pending"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"dispatch_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Dispatch At","description":"When the snapshot's work was due to start (created_at plus any dispatch stagger)"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"schema_version":{"type":"integer","title":"Schema Version","default":1},"s3_prefix":{"type":"string","title":"S3 Prefix","default":""},"s3_objects_copied":{"type":"boolean","title":"S3 Objects Copied","default":false},"manifest":{"anyOf":[{"$ref":"#/components/schemas/SnapshotManifest"},{"type":"null"}]},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id"},"include_vectors":{"type":"boolean","title":"Include Vectors","description":"False for a metadata-only snapshot, which holds the namespace's records but no vector points; restoring it writes no vectors.","default":true},"vector_shard_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vector Shard Key"},"copy_out":{"anyOf":[{"$ref":"#/components/schemas/SnapshotCopyOut"},{"type":"null"}],"description":"The copy of this snapshot in the plane's backup bucket"},"imported_from":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Imported From","description":"For an imported snapshot, the bucket and prefix it was copied from and the source snapshot's id"},"last_restore":{"anyOf":[{"$ref":"#/components/schemas/RestoreReport"},{"type":"null"}],"description":"Outcome of the most recent restore FROM this snapshot (what was restored vs skipped); null if never restored."}},"type":"object","required":["namespace_id","namespace_name","internal_id","snapshot_type"],"title":"SnapshotModel"},"SnapshotStatus":{"type":"string","enum":["pending","in_progress","completed","partial","failed","expired"],"title":"SnapshotStatus"},"SnapshotType":{"type":"string","enum":["daily","pre_delete","manual"],"title":"SnapshotType"},"SnapshotVerifyIssue":{"properties":{"code":{"type":"string","title":"Code","description":"Machine-readable issue code, e.g. 'missing_collection_dump'"},"severity":{"type":"string","title":"Severity","description":"'error' (blocks a clean restore) or 'warning' (degraded but restorable)"},"detail":{"type":"string","title":"Detail","description":"Human-readable explanation of what restore would do/lose"}},"type":"object","required":["code","severity","detail"],"title":"SnapshotVerifyIssue"},"SnapshotVerifyResponse":{"properties":{"snapshot_id":{"type":"string","title":"Snapshot Id"},"status":{"type":"string","title":"Status"},"restorable":{"type":"boolean","title":"Restorable","description":"True iff there are no error-severity issues (a clean restore is possible)"},"issues":{"items":{"$ref":"#/components/schemas/SnapshotVerifyIssue"},"type":"array","title":"Issues"},"collections_verified":{"type":"integer","title":"Collections Verified","description":"Count of expected (non-empty) collection dumps found present","default":0},"vector_source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vector Source","description":"Where vectors would restore from: 'self', the shard-representative prefix (coalesced), 'none', or null if unresolved"},"vector_capture":{"type":"string","title":"Vector Capture","description":"Deep-verify per-point vector NON-emptiness verdict. 'measured_ok': captured points carry non-empty vectors. 'measured_degraded': a significant fraction carry EMPTY vectors — the Raw-absence signature (a raw-less point scrolls back with vectors=[] yet counts as captured), so a restore would be searchable-degraded even though the point-count guard passed. 'could_not_measure': not deep-verified, metadata-only, or unreadable. Three-valued by design — could_not_measure must never render as ok (a boolean would collapse incapacity into the healthy value).","default":"could_not_measure"},"frontier":{"anyOf":[{"$ref":"#/components/schemas/SnapshotFrontier"},{"type":"null"}],"description":"The frontier read back from the stored manifest.json"},"mongo_backup":{"anyOf":[{"$ref":"#/components/schemas/BackupCoverage"},{"type":"null"}],"description":"Whether the plane's Mongo backups can restore to the snapshot's recorded cluster time, asked at verify time"},"digests_verified":{"type":"integer","title":"Digests Verified","description":"Artifacts whose sha256 was recomputed and matched the manifest (deep verify only)","default":0},"last_restore":{"anyOf":[{"$ref":"#/components/schemas/RestoreReport"},{"type":"null"}],"description":"The report of the most recent restore from this snapshot: what each collection restored, the vector counts, and retriever parity. Absent until a restore from this snapshot finishes."}},"type":"object","required":["snapshot_id","status","restorable"],"title":"SnapshotVerifyResponse","description":"Result of a read-only pre-flight check that a snapshot can be restored.\n\nRestore itself is LENIENT — a missing collection dump is caught and logged\nas a warning, so restore reports success while SILENTLY dropping data. This\ncheck surfaces exactly what restore would skip BEFORE you depend on it in a\nrecovery, by re-validating the snapshot's object-store artifacts against the\nmanifest it claims to hold (no materialization)."},"SnowflakeConfig":{"properties":{"provider_type":{"type":"string","const":"snowflake","title":"Provider Type","default":"snowflake"},"credentials":{"oneOf":[{"$ref":"#/components/schemas/SnowflakeKeyPairCredentials"},{"$ref":"#/components/schemas/SnowflakeUsernamePasswordCredentials"}],"title":"Credentials","description":"REQUIRED. Authentication credentials for Snowflake. Choose key_pair for production (recommended) or username_password for simpler setup. The 'type' field determines which credential mechanism is used.","discriminator":{"propertyName":"type","mapping":{"key_pair":"#/components/schemas/SnowflakeKeyPairCredentials","username_password":"#/components/schemas/SnowflakeUsernamePasswordCredentials"}}},"account":{"type":"string","title":"Account","description":"REQUIRED. Snowflake account identifier. Format: {account_locator}.{cloud_region} or {org_name}-{account_name} Find in: Snowflake UI > Account dropdown > Account URL","examples":["xy12345.us-east-1","myorg-prod","acme-analytics"]},"warehouse":{"type":"string","title":"Warehouse","description":"REQUIRED. Warehouse name for compute resources. Must have USAGE privilege on this warehouse. Warehouse will be used for all sync queries. Consider: Use dedicated warehouse for sync operations to isolate costs.","examples":["COMPUTE_WH","MIXPEEK_SYNC_WH","ETL_SMALL"]},"database":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Database","description":"NOT REQUIRED if fully qualified table name used in source_path. Database name for default context. Can be omitted if source_path uses {DATABASE}.{SCHEMA}.{TABLE} format. Must have USAGE privilege if specified.","examples":["PRODUCTION","ANALYTICS_DB","CUSTOMER_DATA"]},"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Schema","description":"NOT REQUIRED if fully qualified table name used in source_path. Schema name for default context. Can be omitted if source_path uses {SCHEMA}.{TABLE} or {DATABASE}.{SCHEMA}.{TABLE}. Must have USAGE privilege if specified.","examples":["PUBLIC","RAW_DATA","TRANSFORMED"]},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role","description":"NOT REQUIRED. Snowflake role to use for operations. If omitted, uses user's default role. Role must have SELECT on target tables and USAGE on database/schema/warehouse. Best practice: Create dedicated read-only role for sync operations.","examples":["MIXPEEK_SYNC_ROLE","READ_ONLY","DATA_ENGINEER"]},"incremental_column":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Incremental Column","description":"NOT REQUIRED. Column name for incremental sync watermark. Should be a TIMESTAMP, TIMESTAMP_NTZ, or DATE column that tracks row modifications. When set, only rows with {incremental_column} > last_sync_watermark are synced. Common values: updated_at, modified_at, last_updated, ingestion_timestamp. If omitted, full table scan on every sync (not recommended for large tables).","examples":["updated_at","modified_at","last_updated","ingestion_timestamp"]},"primary_key_columns":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Primary Key Columns","description":"NOT REQUIRED. Column names forming the primary key for stable object IDs. Used to generate deterministic file_id for deduplication. If omitted, uses hash of entire row content (less stable). Recommendation: Always specify for production to ensure idempotent syncs.","examples":[["id"],["user_id","timestamp"],["customer_id","order_id"]]},"query_timeout_seconds":{"type":"integer","maximum":3600.0,"minimum":30.0,"title":"Query Timeout Seconds","description":"Query timeout in seconds. Prevents long-running queries from blocking sync operations. Default: 300 seconds (5 minutes). Increase for large tables or complex queries.","default":300},"fetch_size":{"type":"integer","maximum":10000.0,"minimum":100.0,"title":"Fetch Size","description":"Number of rows to fetch per network round-trip. Higher values reduce network overhead but increase memory usage. Default: 1000 rows. Tune based on row size and available memory.","default":1000}},"type":"object","required":["credentials","account","warehouse"],"title":"SnowflakeConfig","description":"Snowflake data warehouse configuration for table-based sync.\n\nEnables syncing Snowflake table rows as JSON objects in Mixpeek buckets.\nEach row becomes one object, with incremental sync via watermark columns.\n\nAuthentication Options:\n    - Key Pair: Recommended for production (secure, password-less)\n    - Username/Password: Fallback option (simpler setup)\n\nRequirements:\n    - Snowflake account with read access to target tables\n    - Warehouse with compute resources\n    - SELECT permissions on target tables/schemas\n    - USAGE permissions on database, schema, warehouse\n\nUse Cases:\n    - Sync customer data tables for AI/ML pipelines\n    - Ingest product catalog for search/recommendations\n    - Process transaction logs for analytics\n    - Mirror metadata tables for vector search\n\nExample:\n    Production setup with key pair auth:\n    ```python\n    config = {\n        \"provider_type\": \"snowflake\",\n        \"credentials\": {\n            \"type\": \"key_pair\",\n            \"username\": \"MIXPEEK_SYNC\",\n            \"private_key\": \"-----BEGIN PRIVATE KEY-----\\n...\\n-----END PRIVATE KEY-----\\n\",\n        },\n        \"account\": \"xy12345.us-east-1\",\n        \"warehouse\": \"MIXPEEK_SYNC_WH\",\n        \"database\": \"PRODUCTION\",\n        \"schema\": \"PUBLIC\",\n        \"role\": \"SYNC_ROLE\",\n        \"incremental_column\": \"updated_at\",\n        \"primary_key_columns\": [\"id\"],\n    }\n    ```","examples":[{"account":"xy12345.us-east-1","credentials":{"private_key":"-----BEGIN PRIVATE KEY-----\n...\n-----END PRIVATE KEY-----\n","type":"key_pair","username":"MIXPEEK_SYNC"},"database":"PRODUCTION","description":"Production setup with key pair auth and incremental sync","incremental_column":"updated_at","primary_key_columns":["id"],"provider_type":"snowflake","role":"MIXPEEK_SYNC_ROLE","schema":"PUBLIC","warehouse":"MIXPEEK_SYNC_WH"},{"account":"myorg-analytics","credentials":{"password":"secure_password_here","type":"username_password","username":"SYNC_USER"},"database":"ANALYTICS","description":"Simple username/password setup","incremental_column":"modified_at","primary_key_columns":["customer_id","event_id"],"provider_type":"snowflake","schema":"RAW","warehouse":"COMPUTE_WH"}]},"SnowflakeKeyPairCredentials":{"properties":{"type":{"type":"string","const":"key_pair","title":"Type","default":"key_pair"},"username":{"type":"string","title":"Username","description":"Snowflake username for authentication","examples":["MIXPEEK_SYNC_USER","data_ingestion"]},"private_key":{"type":"string","title":"Private Key","description":"REQUIRED. PEM-encoded RSA private key for authentication. SECURITY: This is a secret credential, redacted on read. Never log or expose. Format: -----BEGIN PRIVATE KEY-----...-----END PRIVATE KEY----- "},"private_key_passphrase":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Private Key Passphrase","description":"NOT REQUIRED. Passphrase for encrypted private key. SECURITY: Encrypted at rest if provided. Use only if private key is passphrase-protected."}},"type":"object","required":["username","private_key"],"title":"SnowflakeKeyPairCredentials","description":"Snowflake key pair authentication (RECOMMENDED for production).\n\nKey pair authentication provides secure, password-less access to Snowflake.\n\nPrerequisites:\n    1. Generate RSA key pair (2048-bit minimum)\n    2. Extract public key and assign to Snowflake user\n    3. Store private key securely (encrypted)\n\nSecurity:\n    - Private key is a secret credential, redacted on read\n    - No password exposure\n    - Key rotation supported\n    - Recommended for production\n\nExample:\n    Generate key pair:\n    ```bash\n    openssl genrsa 2048 | openssl pkcs8 -topk8 -inform PEM -out rsa_key.p8 -nocrypt\n    openssl rsa -in rsa_key.p8 -pubout -out rsa_key.pub\n    ```\n\n    Assign public key to Snowflake user:\n    ```sql\n    ALTER USER mixpeek_sync SET RSA_PUBLIC_KEY='MIIBIjANBg...';\n    ```"},"SnowflakeUsernamePasswordCredentials":{"properties":{"type":{"type":"string","const":"username_password","title":"Type","default":"username_password"},"username":{"type":"string","title":"Username","description":"REQUIRED. Snowflake username (case-insensitive).","examples":["MIXPEEK_SYNC_USER","data_ingestion"]},"password":{"type":"string","title":"Password","description":"REQUIRED. Snowflake password for authentication. SECURITY: This is a secret credential, redacted on read. Never log or expose."}},"type":"object","required":["username","password"],"title":"SnowflakeUsernamePasswordCredentials","description":"Snowflake username/password authentication (FALLBACK option).\n\nTraditional username/password authentication for Snowflake.\nLess secure than key pair authentication but simpler to set up.\n\nSecurity:\n    - Password is a secret credential, redacted on read\n    - Consider using key pair auth for production\n    - Enable MFA on Snowflake user account"},"SortDirection":{"type":"string","enum":["asc","desc"],"title":"SortDirection","description":"Sort direction options."},"SortOption":{"properties":{"field":{"type":"string","title":"Field","description":"Field to sort by, supports dot notation for nested fields","example":"created_at"},"direction":{"$ref":"#/components/schemas/SortDirection","description":"Sort direction","default":"asc","example":"desc"}},"type":"object","required":["field"],"title":"SortOption","description":"Specifies how to sort query results.\n\nAttributes:\n    field: Field to sort by\n    direction: Sort direction (ascending or descending)"},"SourceAdapterConfig":{"properties":{"adapter_type":{"type":"string","title":"Adapter Type","description":"Adapter type. Webhook sources: mux, iconik, generic_webhook. Internal pull-based sources, which have no webhook adapter and are refresh-triggered: collection, which demotes a source collection's documents into this bucket as first-class objects (see source_collection_id and source_filters), and bucket, which fans a set of source buckets' objects into this bucket (see source_bucket_ids)."},"enabled":{"type":"boolean","title":"Enabled","default":true},"connection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Connection Id","description":"Reference to an org-level StorageConnectionModel (conn_...). Credentials are resolved at runtime."},"connection":{"$ref":"#/components/schemas/ExternalConnection","description":"Deprecated — use connection_id. Inline credentials for backward compat."},"event_filter":{"$ref":"#/components/schemas/EventFilter"},"field_mapping":{"additionalProperties":{"type":"string"},"type":"object","title":"Field Mapping","description":"Map of external dot-paths to bucket schema field names"},"blob_source":{"anyOf":[{"$ref":"#/components/schemas/BlobSource"},{"type":"null"}]},"batching":{"$ref":"#/components/schemas/BatchingConfig"},"dedup_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dedup Key"},"webhook_secret":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Webhook Secret"},"webhook_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Webhook Url"},"source_collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Collection Id","description":"For adapter_type 'collection': the source collection whose documents are demoted into this bucket as first-class objects."},"source_filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Source Filters","description":"For adapter_type 'collection': optional documents/list filter (LogicalOperator shape) selecting which source documents to demote."},"source_bucket_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Source Bucket Ids","description":"For adapter_type 'bucket': the source buckets whose objects are fanned into this bucket as first-class objects (fan-in)."}},"type":"object","required":["adapter_type"],"title":"SourceAdapterConfig"},"SourceCollection-Input":{"properties":{"collection_id":{"type":"string","title":"Collection Id","description":"The ID of the source collection for the taxonomy."},"enrichment_fields":{"anyOf":[{"items":{"$ref":"#/components/schemas/EnrichmentField"},"type":"array"},{"type":"null"}],"title":"Enrichment Fields","description":"Fields to copy from matched taxonomy node when enriching (append/replace semantics). If omitted, the full payload is copied."}},"type":"object","required":["collection_id"],"title":"SourceCollection","description":"A source collection for a flat taxonomy.","examples":[{"collection_id":"col_products_v1","enrichment_fields":[{"field_path":"metadata.tags","merge_mode":"append"}],"input_mappings":[{"input_key":"image_vector","path":"features.clip_vit_l_14","source_type":"vector"}],"retriever_id":"ret_clip_v1"}]},"SourceCollection-Output":{"properties":{"collection_id":{"type":"string","title":"Collection Id","description":"The ID of the source collection for the taxonomy."},"enrichment_fields":{"anyOf":[{"items":{"$ref":"#/components/schemas/EnrichmentField"},"type":"array"},{"type":"null"}],"title":"Enrichment Fields","description":"Fields to copy from matched taxonomy node when enriching (append/replace semantics). If omitted, the full payload is copied."}},"type":"object","required":["collection_id"],"title":"SourceCollection","description":"A source collection for a flat taxonomy.","examples":[{"collection_id":"col_products_v1","enrichment_fields":[{"field_path":"metadata.tags","merge_mode":"append"}],"input_mappings":[{"input_key":"image_vector","path":"features.clip_vit_l_14","source_type":"vector"}],"retriever_id":"ret_clip_v1"}]},"SourceConfig-Input":{"properties":{"type":{"$ref":"#/components/schemas/SourceType","description":"REQUIRED. Type of source for this collection. 'bucket': Process objects from one or more buckets (first-stage processing). 'collection': Process documents from another collection (downstream processing). Use 'bucket' for initial data ingestion, 'collection' for decomposition trees.","examples":["bucket","collection"]},"bucket_ids":{"anyOf":[{"items":{"type":"string"},"type":"array","minItems":1},{"type":"null"}],"title":"Bucket Ids","description":"List of bucket IDs when type='bucket'. REQUIRED when type='bucket'. NOT ALLOWED when type='collection'. Can specify one or more buckets to process. Single bucket: Use array with one element ['bkt_id']. Multiple buckets: All buckets MUST have compatible schemas. Schema compatibility validated at collection creation. Compatible schemas have: 1) Same field names, 2) Same field types, 3) Same required status. Documents will include root_bucket_id to track which bucket they came from. Use cases: multi-region data, multi-team consolidation, environment aggregation.","examples":[["bkt_marketing_videos"],["bkt_us_products","bkt_eu_products","bkt_asia_products"],["bkt_staging_data","bkt_production_data"]]},"source_namespace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Namespace Id","description":"Namespace ID where the source buckets reside. Use this to process buckets from a different namespace within the same organization. When omitted, buckets are looked up in the current (collection's) namespace. Only valid when type='bucket'."},"collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Collection Id","description":"Collection ID when type='collection' (single collection). Use this OR collection_ids (not both). REQUIRED when type='collection' and processing single collection. NOT ALLOWED when type='bucket'. The collection will process documents from this upstream collection. The upstream collection's output_schema becomes this collection's input_schema. This enables decomposition trees (multi-stage pipelines). Example: Process frames collection → create scenes collection.","examples":["col_video_frames","col_book_chapters","col_product_images"]},"collection_ids":{"anyOf":[{"items":{"type":"string"},"type":"array","minItems":1},{"type":"null"}],"title":"Collection Ids","description":"List of collection IDs when type='collection' (multiple collections). Use this OR collection_id (not both). REQUIRED when type='collection' and processing multiple collections. NOT ALLOWED when type='bucket'. Used for operations that consolidate multiple upstream collections. Example: Clustering across multiple collections → cluster output collection. All collections must have compatible schemas for consolidation operations.","examples":[["col_us_products","col_eu_products"],["col_images_2023","col_images_2024"]]},"inherited_bucket_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Inherited Bucket Ids","description":"List of original bucket IDs that source collections originated from. OPTIONAL. Only used when type='collection'. Tracks the complete lineage chain: buckets → collections → derived collections. Extracted from upstream collection metadata at collection creation time. Enables tracing derived collections (like cluster outputs) back to original data sources. Example: Cluster output collection inherits bucket IDs from its source collections. Format: List of bucket IDs with 'bkt_' prefix.","examples":[["bkt_marketing_videos"],["bkt_us_products","bkt_eu_products"],null]},"source_filters":{"anyOf":[{"$ref":"#/components/schemas/SourceFilters-Input"},{"type":"null"}],"description":"Optional filters to apply to source data. When specified, only objects/documents matching these filters will be processed by this collection. Filters are evaluated at batch creation time. Uses same LogicalOperator model as list APIs for consistency.","examples":[{"filters":{"AND":[{"field":"blobs.type","operator":"eq","value":"video"}]}},{"filters":{"AND":[{"field":"metadata.status","operator":"eq","value":"active"}]}},{}]},"field_map":{"anyOf":[{"additionalProperties":{"items":{"$ref":"#/components/schemas/FieldPassthrough"},"type":"array"},"type":"object"},{"type":"null"}],"title":"Field Map","description":"Optional per-source field selection for multi-source collections (multiple bucket_ids or collection_ids, possibly with DIFFERENT schemas). Maps each source id (a bucket_id or collection_id) to a list of FieldPassthrough entries choosing which of THAT source's fields land in the merged collection, and where (source_path -> target_path). OMITTED SOURCE: a source declared in bucket_ids/collection_ids but absent from field_map passes ALL of its fields through unchanged — field_map is a narrowing, not a required allowlist. TARGET-PATH COLLISION: if two sources (or two entries) map fields to the same target_path, collection creation fails with 422 naming the colliding target_path and the source ids. No silent first/last-wins — rename one target_path to resolve.","examples":[{"bkt_mosaic":[{"source_path":"headline","target_path":"title"},{"required":true,"source_path":"take","target_path":"take"}],"col_iconik_legacy":[{"default":"untitled","source_path":"name","target_path":"display_name"}]},null]}},"type":"object","required":["type"],"title":"SourceConfig","description":"Configuration for collection source (bucket(s) or collection).\n\nCollections can process data from two types of sources:\n\n1. **Bucket Source**: Process raw objects from one or more buckets (first-stage processing)\n   - Use this to create your initial collections from uploaded data\n   - Can specify multiple buckets to consolidate data from different sources\n   - All buckets must have compatible schemas (validated at creation)\n   - Example: Videos from multiple regions → Frame extraction collection\n\n2. **Collection Source**: Process documents from another collection (decomposition trees)\n   - Use this to create multi-stage processing pipelines\n   - Example: Frames collection → Scene detection collection\n\nMulti-Bucket Requirements:\n- All buckets must have compatible schemas (same fields, types, and required status)\n- Schema compatibility is validated when the collection is created\n- Documents track which specific bucket they came from via root_bucket_id\n- Useful for consolidating data from multiple regions, teams, or environments\n\nThe source determines:\n- What data the feature extractor receives as input\n- The input_schema available for input_mappings and field_passthrough\n- The lineage tracking in output documents\n\nExamples:\n    Single bucket: {\"type\": \"bucket\", \"bucket_ids\": [\"bkt_products\"]}\n    Multi-bucket: {\"type\": \"bucket\", \"bucket_ids\": [\"bkt_us\", \"bkt_eu\", \"bkt_asia\"]}\n    Collection: {\"type\": \"collection\", \"collection_id\": \"col_frames\"}","examples":[{"bucket_ids":["bkt_marketing_videos"],"description":"Single bucket source","type":"bucket"},{"bucket_ids":["bkt_marketing_ads"],"description":"Bucket source with video-only filter","source_filters":{"filters":{"AND":[{"field":"blobs.type","operator":"eq","value":"video"}]}},"type":"bucket"},{"bucket_ids":["bkt_us_products","bkt_eu_products","bkt_asia_products"],"description":"Multi-bucket source (region consolidation)","type":"bucket"},{"bucket_ids":["bkt_us_ads","bkt_eu_ads","bkt_asia_ads"],"description":"Multi-bucket source with brand filter","source_filters":{"filters":{"OR":[{"field":"brand_name","operator":"in","value":["Acme","TechCo"]},{"field":"category","operator":"eq","value":"premium"}]}},"type":"bucket"},{"collection_id":"col_video_frames","description":"Collection source (decomposition tree)","type":"collection"},{"collection_id":"col_raw_frames","description":"Collection source with active documents only","source_filters":{"filters":{"AND":[{"field":"__fully_enriched","operator":"eq","value":true},{"field":"quality_score","operator":"gte","value":0.8}]}},"type":"collection"},{"collection_ids":["col_us_products","col_eu_products","col_asia_products"],"description":"Multi-collection source (cluster output)","type":"collection"}]},"SourceConfig-Output":{"properties":{"type":{"$ref":"#/components/schemas/SourceType","description":"REQUIRED. Type of source for this collection. 'bucket': Process objects from one or more buckets (first-stage processing). 'collection': Process documents from another collection (downstream processing). Use 'bucket' for initial data ingestion, 'collection' for decomposition trees.","examples":["bucket","collection"]},"bucket_ids":{"anyOf":[{"items":{"type":"string"},"type":"array","minItems":1},{"type":"null"}],"title":"Bucket Ids","description":"List of bucket IDs when type='bucket'. REQUIRED when type='bucket'. NOT ALLOWED when type='collection'. Can specify one or more buckets to process. Single bucket: Use array with one element ['bkt_id']. Multiple buckets: All buckets MUST have compatible schemas. Schema compatibility validated at collection creation. Compatible schemas have: 1) Same field names, 2) Same field types, 3) Same required status. Documents will include root_bucket_id to track which bucket they came from. Use cases: multi-region data, multi-team consolidation, environment aggregation.","examples":[["bkt_marketing_videos"],["bkt_us_products","bkt_eu_products","bkt_asia_products"],["bkt_staging_data","bkt_production_data"]]},"source_namespace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Namespace Id","description":"Namespace ID where the source buckets reside. Use this to process buckets from a different namespace within the same organization. When omitted, buckets are looked up in the current (collection's) namespace. Only valid when type='bucket'."},"collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Collection Id","description":"Collection ID when type='collection' (single collection). Use this OR collection_ids (not both). REQUIRED when type='collection' and processing single collection. NOT ALLOWED when type='bucket'. The collection will process documents from this upstream collection. The upstream collection's output_schema becomes this collection's input_schema. This enables decomposition trees (multi-stage pipelines). Example: Process frames collection → create scenes collection.","examples":["col_video_frames","col_book_chapters","col_product_images"]},"collection_ids":{"anyOf":[{"items":{"type":"string"},"type":"array","minItems":1},{"type":"null"}],"title":"Collection Ids","description":"List of collection IDs when type='collection' (multiple collections). Use this OR collection_id (not both). REQUIRED when type='collection' and processing multiple collections. NOT ALLOWED when type='bucket'. Used for operations that consolidate multiple upstream collections. Example: Clustering across multiple collections → cluster output collection. All collections must have compatible schemas for consolidation operations.","examples":[["col_us_products","col_eu_products"],["col_images_2023","col_images_2024"]]},"inherited_bucket_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Inherited Bucket Ids","description":"List of original bucket IDs that source collections originated from. OPTIONAL. Only used when type='collection'. Tracks the complete lineage chain: buckets → collections → derived collections. Extracted from upstream collection metadata at collection creation time. Enables tracing derived collections (like cluster outputs) back to original data sources. Example: Cluster output collection inherits bucket IDs from its source collections. Format: List of bucket IDs with 'bkt_' prefix.","examples":[["bkt_marketing_videos"],["bkt_us_products","bkt_eu_products"],null]},"source_filters":{"anyOf":[{"$ref":"#/components/schemas/SourceFilters-Output"},{"type":"null"}],"description":"Optional filters to apply to source data. When specified, only objects/documents matching these filters will be processed by this collection. Filters are evaluated at batch creation time. Uses same LogicalOperator model as list APIs for consistency.","examples":[{"filters":{"AND":[{"field":"blobs.type","operator":"eq","value":"video"}]}},{"filters":{"AND":[{"field":"metadata.status","operator":"eq","value":"active"}]}},{}]},"field_map":{"anyOf":[{"additionalProperties":{"items":{"$ref":"#/components/schemas/FieldPassthrough"},"type":"array"},"type":"object"},{"type":"null"}],"title":"Field Map","description":"Optional per-source field selection for multi-source collections (multiple bucket_ids or collection_ids, possibly with DIFFERENT schemas). Maps each source id (a bucket_id or collection_id) to a list of FieldPassthrough entries choosing which of THAT source's fields land in the merged collection, and where (source_path -> target_path). OMITTED SOURCE: a source declared in bucket_ids/collection_ids but absent from field_map passes ALL of its fields through unchanged — field_map is a narrowing, not a required allowlist. TARGET-PATH COLLISION: if two sources (or two entries) map fields to the same target_path, collection creation fails with 422 naming the colliding target_path and the source ids. No silent first/last-wins — rename one target_path to resolve.","examples":[{"bkt_mosaic":[{"source_path":"headline","target_path":"title"},{"required":true,"source_path":"take","target_path":"take"}],"col_iconik_legacy":[{"default":"untitled","source_path":"name","target_path":"display_name"}]},null]}},"type":"object","required":["type"],"title":"SourceConfig","description":"Configuration for collection source (bucket(s) or collection).\n\nCollections can process data from two types of sources:\n\n1. **Bucket Source**: Process raw objects from one or more buckets (first-stage processing)\n   - Use this to create your initial collections from uploaded data\n   - Can specify multiple buckets to consolidate data from different sources\n   - All buckets must have compatible schemas (validated at creation)\n   - Example: Videos from multiple regions → Frame extraction collection\n\n2. **Collection Source**: Process documents from another collection (decomposition trees)\n   - Use this to create multi-stage processing pipelines\n   - Example: Frames collection → Scene detection collection\n\nMulti-Bucket Requirements:\n- All buckets must have compatible schemas (same fields, types, and required status)\n- Schema compatibility is validated when the collection is created\n- Documents track which specific bucket they came from via root_bucket_id\n- Useful for consolidating data from multiple regions, teams, or environments\n\nThe source determines:\n- What data the feature extractor receives as input\n- The input_schema available for input_mappings and field_passthrough\n- The lineage tracking in output documents\n\nExamples:\n    Single bucket: {\"type\": \"bucket\", \"bucket_ids\": [\"bkt_products\"]}\n    Multi-bucket: {\"type\": \"bucket\", \"bucket_ids\": [\"bkt_us\", \"bkt_eu\", \"bkt_asia\"]}\n    Collection: {\"type\": \"collection\", \"collection_id\": \"col_frames\"}","examples":[{"bucket_ids":["bkt_marketing_videos"],"description":"Single bucket source","type":"bucket"},{"bucket_ids":["bkt_marketing_ads"],"description":"Bucket source with video-only filter","source_filters":{"filters":{"AND":[{"field":"blobs.type","operator":"eq","value":"video"}]}},"type":"bucket"},{"bucket_ids":["bkt_us_products","bkt_eu_products","bkt_asia_products"],"description":"Multi-bucket source (region consolidation)","type":"bucket"},{"bucket_ids":["bkt_us_ads","bkt_eu_ads","bkt_asia_ads"],"description":"Multi-bucket source with brand filter","source_filters":{"filters":{"OR":[{"field":"brand_name","operator":"in","value":["Acme","TechCo"]},{"field":"category","operator":"eq","value":"premium"}]}},"type":"bucket"},{"collection_id":"col_video_frames","description":"Collection source (decomposition tree)","type":"collection"},{"collection_id":"col_raw_frames","description":"Collection source with active documents only","source_filters":{"filters":{"AND":[{"field":"__fully_enriched","operator":"eq","value":true},{"field":"quality_score","operator":"gte","value":0.8}]}},"type":"collection"},{"collection_ids":["col_us_products","col_eu_products","col_asia_products"],"description":"Multi-collection source (cluster output)","type":"collection"}]},"SourceDetails":{"properties":{"type":{"$ref":"#/components/schemas/SourceType","description":"Immediate origin type from which this entity was derived."},"source_id":{"type":"string","title":"Source Id","description":"Identifier of the immediate source entity (e.g., bucket_id, collection_id, taxonomy_id)."}},"type":"object","required":["type","source_id"],"title":"SourceDetails","description":"Source details for any document/point.\n\nKeep this intentionally minimal so specialized models (e.g., DocumentSourceDetails)\ncan extend it with domain-specific fields."},"SourceEnrichmentConfig":{"properties":{"field_mappings":{"items":{"$ref":"#/components/schemas/EnrichmentFieldMapping"},"type":"array","title":"Field Mappings","description":"List of field mappings from cluster results to document fields. Default includes cluster_id and cluster_label. Can include: distance_to_centroid, member_count, keywords, visualization coords (x, y, z), etc."}},"type":"object","title":"SourceEnrichmentConfig","description":"Configuration for enriching source collection documents with cluster assignments.\n\nWhen enrich_source_collection=True, cluster assignments are written back to\nthe original source documents, similar to taxonomy enrichment.\n\nUses flexible field mapping pattern to support any cluster result fields.","examples":[{"field_mappings":[{"source_field":"cluster_id","target_field":"category_id"},{"source_field":"cluster_label","target_field":"category_name"},{"source_field":"distance_to_centroid","target_field":"category_confidence"}]},{"field_mappings":[{"source_field":"cluster_id","target_field":"segment"},{"source_field":"cluster_label","target_field":"segment_label"},{"source_field":"x","target_field":"viz_x"},{"source_field":"y","target_field":"viz_y"}]}]},"SourceField":{"properties":{"path":{"type":"string","title":"Path"},"type":{"type":"string","enum":["string","integer","float","boolean","datetime","vector","object","null"],"title":"Type"}},"type":"object","required":["path","type"],"title":"SourceField","description":"A declared source field (validate-mapping input)."},"SourceFilters-Input":{"properties":{"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"Optional logical filters to apply to source data. Uses LogicalOperator model with AND/OR/NOT support. When specified, only objects/documents matching these filters will be processed by this collection. When null, all source data is processed (no filtering). Filters are consistent across all batch runs for this collection.","examples":[{"AND":[{"field":"blobs.type","operator":"eq","value":"video"}]},{"AND":[{"field":"metadata.status","operator":"eq","value":"active"},{"field":"created_at","operator":"gte","value":"2025-10-01T00:00:00Z"}]},{"OR":[{"field":"brand_name","operator":"in","value":["Acme","TechCo"]},{"field":"category","operator":"eq","value":"premium"}]}]}},"type":"object","title":"SourceFilters","description":"Filters applied to source data when processing collections.\n\nSource filters determine which objects (from buckets) or documents (from collections)\nare processed by this collection. Filters use the same LogicalOperator model as\nlist APIs throughout the system, supporting complex AND/OR/NOT logic.\n\nUse Cases:\n    - Process only specific content types from mixed-content buckets\n    - Filter by metadata fields (status, category, tags, dates)\n    - Create specialized collections from broader sources\n    - Exclude certain objects or documents from processing\n\nExamples:\n    Process only video content:\n        {\n            \"AND\": [\n                {\"field\": \"blobs.type\", \"operator\": \"eq\", \"value\": \"video\"}\n            ]\n        }\n\n    Process only active, published content:\n        {\n            \"AND\": [\n                {\"field\": \"metadata.status\", \"operator\": \"eq\", \"value\": \"active\"},\n                {\"field\": \"metadata.published\", \"operator\": \"eq\", \"value\": true}\n            ]\n        }\n\n    Process content from last 30 days:\n        {\n            \"AND\": [\n                {\"field\": \"created_at\", \"operator\": \"gte\", \"value\": \"2025-10-08T00:00:00Z\"}\n            ]\n        }\n\n    Process specific brands OR categories:\n        {\n            \"OR\": [\n                {\"field\": \"brand_name\", \"operator\": \"in\", \"value\": [\"Acme\", \"TechCo\"]},\n                {\"field\": \"category\", \"operator\": \"eq\", \"value\": \"premium\"}\n            ]\n        }\n\nFilter Operators:\n    - eq (equals)\n    - ne (not equals)\n    - gt (greater than)\n    - gte (greater than or equal)\n    - lt (less than)\n    - lte (less than or equal)\n    - in (value in list)\n    - nin (value not in list)\n    - contains (string contains)\n    - starts_with (string starts with)\n    - ends_with (string ends with)\n\nPerformance Considerations:\n    - Filters are evaluated at batch creation time\n    - Only matching objects/documents are included in processing\n    - More selective filters = smaller batches = faster processing\n    - Use indexed fields (metadata, timestamps) for better performance\n\nRelationship to Batch Filters:\n    - Source filters: Applied at collection definition (consistent across all batches)\n    - Batch filters: Applied at batch creation (ad-hoc, per-batch basis)\n    - Both can be used together: source filters + batch filters = intersection","examples":[{"description":"Filter only video content","filters":{"AND":[{"field":"blobs.type","operator":"eq","value":"video"}]}},{"description":"Filter active content from specific brands","filters":{"AND":[{"field":"metadata.status","operator":"eq","value":"active"},{"field":"brand_name","operator":"in","value":["Acme","TechCo","Innovate"]}]}},{"description":"Filter by content type and date range","filters":{"AND":[{"OR":[{"field":"blobs.type","operator":"eq","value":"video"},{"field":"blobs.type","operator":"eq","value":"image"}]},{"field":"created_at","operator":"gte","value":"2025-10-01T00:00:00Z"},{"field":"created_at","operator":"lte","value":"2025-10-31T23:59:59Z"}]}},{"description":"No filters - process all source data"}]},"SourceFilters-Output":{"properties":{"filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Output"},{"type":"null"}],"description":"Optional logical filters to apply to source data. Uses LogicalOperator model with AND/OR/NOT support. When specified, only objects/documents matching these filters will be processed by this collection. When null, all source data is processed (no filtering). Filters are consistent across all batch runs for this collection.","examples":[{"AND":[{"field":"blobs.type","operator":"eq","value":"video"}]},{"AND":[{"field":"metadata.status","operator":"eq","value":"active"},{"field":"created_at","operator":"gte","value":"2025-10-01T00:00:00Z"}]},{"OR":[{"field":"brand_name","operator":"in","value":["Acme","TechCo"]},{"field":"category","operator":"eq","value":"premium"}]}]}},"type":"object","title":"SourceFilters","description":"Filters applied to source data when processing collections.\n\nSource filters determine which objects (from buckets) or documents (from collections)\nare processed by this collection. Filters use the same LogicalOperator model as\nlist APIs throughout the system, supporting complex AND/OR/NOT logic.\n\nUse Cases:\n    - Process only specific content types from mixed-content buckets\n    - Filter by metadata fields (status, category, tags, dates)\n    - Create specialized collections from broader sources\n    - Exclude certain objects or documents from processing\n\nExamples:\n    Process only video content:\n        {\n            \"AND\": [\n                {\"field\": \"blobs.type\", \"operator\": \"eq\", \"value\": \"video\"}\n            ]\n        }\n\n    Process only active, published content:\n        {\n            \"AND\": [\n                {\"field\": \"metadata.status\", \"operator\": \"eq\", \"value\": \"active\"},\n                {\"field\": \"metadata.published\", \"operator\": \"eq\", \"value\": true}\n            ]\n        }\n\n    Process content from last 30 days:\n        {\n            \"AND\": [\n                {\"field\": \"created_at\", \"operator\": \"gte\", \"value\": \"2025-10-08T00:00:00Z\"}\n            ]\n        }\n\n    Process specific brands OR categories:\n        {\n            \"OR\": [\n                {\"field\": \"brand_name\", \"operator\": \"in\", \"value\": [\"Acme\", \"TechCo\"]},\n                {\"field\": \"category\", \"operator\": \"eq\", \"value\": \"premium\"}\n            ]\n        }\n\nFilter Operators:\n    - eq (equals)\n    - ne (not equals)\n    - gt (greater than)\n    - gte (greater than or equal)\n    - lt (less than)\n    - lte (less than or equal)\n    - in (value in list)\n    - nin (value not in list)\n    - contains (string contains)\n    - starts_with (string starts with)\n    - ends_with (string ends with)\n\nPerformance Considerations:\n    - Filters are evaluated at batch creation time\n    - Only matching objects/documents are included in processing\n    - More selective filters = smaller batches = faster processing\n    - Use indexed fields (metadata, timestamps) for better performance\n\nRelationship to Batch Filters:\n    - Source filters: Applied at collection definition (consistent across all batches)\n    - Batch filters: Applied at batch creation (ad-hoc, per-batch basis)\n    - Both can be used together: source filters + batch filters = intersection","examples":[{"description":"Filter only video content","filters":{"AND":[{"field":"blobs.type","operator":"eq","value":"video"}]}},{"description":"Filter active content from specific brands","filters":{"AND":[{"field":"metadata.status","operator":"eq","value":"active"},{"field":"brand_name","operator":"in","value":["Acme","TechCo","Innovate"]}]}},{"description":"Filter by content type and date range","filters":{"AND":[{"OR":[{"field":"blobs.type","operator":"eq","value":"video"},{"field":"blobs.type","operator":"eq","value":"image"}]},{"field":"created_at","operator":"gte","value":"2025-10-01T00:00:00Z"},{"field":"created_at","operator":"lte","value":"2025-10-31T23:59:59Z"}]}},{"description":"No filters - process all source data"}]},"SourceType":{"type":"string","enum":["bucket","collection","taxonomy","cluster","direct_upsert","signals","none"],"title":"SourceType","description":"Source types for any document/point."},"SparseVector":{"properties":{"indices":{"items":{"anyOf":[{"type":"integer"},{"type":"number"}]},"type":"array","title":"Indices","description":"Indices of non-zero elements"},"values":{"items":{"type":"number"},"type":"array","title":"Values","description":"Values of non-zero elements"}},"type":"object","required":["indices","values"],"title":"SparseVector","description":"Sparse vector representation with indices and values.\n\nOnly non-zero elements are stored for efficiency.\n\nExample:\n```json\n{\n    \"indices\": [0, 2, 4],\n    \"values\": [0.1, 0.3, 0.5]\n}\n```"},"SpectralParams":{"properties":{"n_clusters":{"type":"integer","minimum":2.0,"title":"N Clusters","description":"Number of clusters to form","default":8},"eigen_solver":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Eigen Solver","description":"The eigenvalue decomposition strategy ('arpack', 'lobpcg', 'amg', or None)"},"n_components":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"N Components","description":"Number of eigenvectors to use for spectral embedding"},"random_state":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Random State","description":"Random seed for reproducibility","default":42},"n_init":{"type":"integer","minimum":1.0,"title":"N Init","description":"Number of times k-means will run with different centroid seeds","default":10},"gamma":{"type":"number","exclusiveMinimum":0.0,"title":"Gamma","description":"Kernel coefficient for rbf, poly, sigmoid, laplacian and chi2 kernels","default":1.0},"affinity":{"type":"string","title":"Affinity","description":"How to construct the affinity matrix ('nearest_neighbors', 'rbf', 'precomputed', 'precomputed_nearest_neighbors')","default":"rbf"},"n_neighbors":{"type":"integer","minimum":1.0,"title":"N Neighbors","description":"Number of neighbors to use when constructing the affinity matrix using nearest neighbors","default":10},"eigen_tol":{"type":"number","minimum":0.0,"title":"Eigen Tol","description":"Stopping criterion for eigendecomposition","default":0.0},"assign_labels":{"type":"string","title":"Assign Labels","description":"Strategy to assign labels in the embedding space ('kmeans' or 'discretize')","default":"kmeans"},"degree":{"type":"number","title":"Degree","description":"Degree of the polynomial kernel. Ignored by other kernels","default":3},"coef0":{"type":"number","title":"Coef0","description":"Zero coefficient for polynomial and sigmoid kernels","default":1},"kernel_params":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Kernel Params","description":"Parameters for the kernel function"},"n_jobs":{"type":"integer","title":"N Jobs","description":"Number of parallel jobs to run (-1 means using all processors)","default":1},"verbose":{"type":"boolean","title":"Verbose","description":"Verbosity mode","default":false}},"type":"object","title":"SpectralParams","description":"Parameters for Spectral clustering algorithm."},"SpendLimitsUpdate":{"properties":{"daily_usd":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Daily Usd","description":"The organization's daily spend budget in USD."},"monthly_usd":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Monthly Usd","description":"The organization's monthly spend budget in USD."},"namespace_default_daily_usd":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Namespace Default Daily Usd","description":"Daily budget every namespace gets unless it sets its own."},"namespace_default_monthly_usd":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Namespace Default Monthly Usd","description":"Monthly budget every namespace gets unless it sets its own."}},"additionalProperties":false,"type":"object","title":"SpendLimitsUpdate","description":"Org budget fields a customer may set. Null resets a field to its default."},"SpendingCapsResponse":{"properties":{"monthly_spending_budget":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Monthly Spending Budget","description":"Soft spending limit in USD cents (null = unlimited)","examples":[10000,50000,100000]},"monthly_spending_budget_usd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Monthly Spending Budget Usd","description":"Soft spending limit in USD","examples":[100.0,500.0,1000.0]},"spending_alert_thresholds":{"items":{"type":"integer"},"type":"array","title":"Spending Alert Thresholds","description":"Percentage thresholds for spending alerts","examples":[[50,75,90,100]]},"spending_alerts_enabled":{"type":"boolean","title":"Spending Alerts Enabled","description":"Whether spending alerts are enabled","default":true},"spending_alerts_sent":{"items":{"type":"integer"},"type":"array","title":"Spending Alerts Sent","description":"Alert thresholds triggered in current billing cycle","examples":[[50,75]]},"hard_spending_cap":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Hard Spending Cap","description":"Hard spending limit in USD cents (null = no hard cap)","examples":[50000,100000,500000]},"hard_spending_cap_usd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Hard Spending Cap Usd","description":"Hard spending limit in USD","examples":[500.0,1000.0,5000.0]},"hard_cap_enabled":{"type":"boolean","title":"Hard Cap Enabled","description":"Whether hard spending cap is enforced","default":false},"current_spending_cents":{"type":"integer","title":"Current Spending Cents","description":"Current spending in current billing cycle (cents)","examples":[23450]},"current_spending_usd":{"type":"number","title":"Current Spending Usd","description":"Current spending in current billing cycle (USD)","examples":[234.5]},"budget_percentage_used":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Budget Percentage Used","description":"Percentage of budget used (null if no budget set)","examples":[46.9,78.2]}},"type":"object","required":["current_spending_cents","current_spending_usd"],"title":"SpendingCapsResponse","description":"Response with spending cap configuration."},"SplitMethod":{"type":"string","enum":["time","scene","silence"],"title":"SplitMethod"},"StageBreakdownResponse":{"properties":{"retriever_id":{"type":"string","title":"Retriever Id","description":"Retriever identifier"},"stages":{"items":{"$ref":"#/components/schemas/StagePerformanceMetrics"},"type":"array","title":"Stages","description":"Stage metrics"},"total_latency_ms":{"type":"number","title":"Total Latency Ms","description":"Total pipeline latency"}},"type":"object","required":["retriever_id","stages","total_latency_ms"],"title":"StageBreakdownResponse","description":"Stage breakdown response.","examples":[{"retriever_id":"ret_abc123","stages":[{"avg_documents_in":0,"avg_documents_out":100,"avg_latency_ms":45.3,"execution_count":1234,"p95_latency_ms":89.2,"stage_name":"knn_search","stage_type":"vector_search"},{"avg_documents_in":100,"avg_documents_out":10,"avg_latency_ms":102.5,"execution_count":1234,"p95_latency_ms":198.7,"stage_name":"rerank","stage_type":"reranking"}],"total_latency_ms":147.8}]},"StageCategory":{"type":"string","enum":["filter","sort","reduce","apply","enrich"],"title":"StageCategory","description":"Retriever stage categories organized by transformation pattern.\n\nValues:\n    FILTER: Subset of input documents (N → ≤N, same schema)\n        - Removes documents that don't match criteria\n        - Examples: attribute_filter, feature_filter, llm_filter\n        - Use for: Removing irrelevant results, applying business rules\n        - Performance: Fast (attribute) to slow (LLM)\n\n    SORT: Reorders documents (N → N, same schema, different order)\n        - Changes document ordering based on criteria\n        - Examples: sort_relevance, sort_attribute\n        - Use for: Ordering by relevance, recency, custom fields\n        - Performance: Fast (in-memory sort)\n\n    REDUCE: Aggregates to summary (N → 1, new schema)\n        - Combines multiple documents into one summary\n        - Examples: aggregate_stats, group_by\n        - Use for: Summaries, statistics, reports\n        - Performance: Varies by aggregation logic\n\n    APPLY: Enrichment or expansion (N → N or N*M)\n        - 1-1: Enriches each doc (N → N, expanded schema)\n        - 1-N: Expands each doc (N → N*M, new/same schema)\n        - Examples: document_enrich, taxonomy_enrich, llm_enrich\n        - Use for: Adding related data, tagging, recursive lookups\n        - Performance: Moderate (DB) to slow (LLM)\n\n    ENRICH: Document enrichment (N → N, potentially expanded schema)\n        - Adds computed fields to each document\n        - Examples: code_execution, llm_enrich, taxonomy_enrich\n        - Use for: Custom transformations, data extraction, LLM processing\n        - Performance: Varies (fast for code, slow for LLM)\n\nPipeline Patterns:\n    - Basic: FILTER → SORT\n    - Enriched: FILTER → SORT → APPLY\n    - Tag expansion: FILTER → APPLY (1-N)\n    - Summary: FILTER → SORT → REDUCE"},"StageConfig-Input":{"properties":{"stage_name":{"type":"string","minLength":1,"title":"Stage Name","description":"Human-readable stage instance name (REQUIRED)."},"stage_type":{"anyOf":[{"$ref":"#/components/schemas/StageType"},{"type":"null"}],"description":"Functional category of the stage. Optional for creation requests; auto-inferred from `stage_id` when omitted."},"config":{"additionalProperties":true,"type":"object","title":"Config","description":"Stage implementation parameters (REQUIRED). Must include `stage_id` key referencing a registered retriever stage. Supports template expressions using Jinja2 syntax resolved at execution time. Template namespaces support both uppercase and lowercase formats: {{INPUT.field}} or {{inputs.field}}, {{DOC.field}} or {{doc.field}}, {{CONTEXT.field}} or {{context.field}}, {{STAGE.field}} or {{stage.field}}. All formats work identically. Provide stage-specific configuration under `parameters`. Optional `pre_filters` and `post_filters` are placed as SIBLINGS of `parameters` (NOT nested inside). Pre-filters require payload indexes on the filtered fields."},"batch_size":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Batch Size","description":"Optional templated batch size expression evaluated per execution. Supports template variables: {{INPUT.page_size}}, {{inputs.page_size}}, {{CONTEXT.budget_remaining}}, etc. Both uppercase and lowercase namespace names are supported (e.g., INPUT/inputs, DOC/doc, CONTEXT/context, STAGE/stage). Defaults to stage-specific value when omitted."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"User-facing description of the stage (OPTIONAL)."},"on_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"On Error","description":"Behavior when this stage fails. 'skip' continues execution with results from previous stages (graceful degradation). 'error' (default) fails the entire retriever. Useful for optional enrichment or multi-modal stages where one modality may not apply (e.g., face search on logo-only images)."},"output_alias":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Output Alias","description":"Optional alias to persist this stage's results in the execution context. When set, results are stored in CONTEXT.<alias> in addition to replacing current_results. Downstream stages can reference them via {{CONTEXT.<alias>}} in templates. Useful for multi-stage pipelines where later stages should not overwrite earlier results (e.g., face search + logo search producing independent result sets)."}},"type":"object","required":["stage_name","config"],"title":"StageConfig","description":"Configuration for a single stage within a retriever.\n\nStages support dynamic configuration through template expressions using Jinja2 syntax.\n\nIMPORTANT - Template Syntax:\n    - Use DOUBLE curly braces: {{INPUT.query}} (correct)\n    - Single curly braces will NOT work: {INPUT.query} (wrong - not substituted)\n    - Namespace names are CASE-INSENSITIVE: {{INPUT.query}}, {{inputs.query}}, {{input.query}}\n      all work identically\n\nTemplate Namespaces (case-insensitive):\n    - INPUT / inputs / input: User-provided query parameters and inputs\n    - DOC / doc: Current document fields (for per-document logic)\n    - CONTEXT / context: Execution state (budget, timing, retriever metadata)\n    - STAGE / stage: Previous stage outputs (for cascading logic)\n\nExamples:\n    Correct: {{INPUT.query_text}}, {{inputs.query}}, {{DOC.content_type}}\n    Correct: {{CONTEXT.budget_remaining}}, {{context.budget_remaining}}\n    Wrong:   {INPUT.query} - single braces won't be substituted","examples":[{"config":{"parameters":{"final_top_k":25,"searches":[{"feature_uri":"mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1","query":{"input_mode":"text","value":"{{INPUT.query_text}}"},"top_k":100}]},"stage_id":"feature_search"},"description":"Feature search stage with uppercase template namespace","stage_name":"semantic_search","stage_type":"filter"},{"batch_size":"{{20 * inputs.page_size}}","config":{"parameters":{"field":"metadata.price","operator":"gt","value":"{{inputs.min_price}}"},"stage_id":"attribute_filter"},"description":"Attribute filter with lowercase template namespace","stage_name":"price_filter","stage_type":"filter"},{"config":{"parameters":{"batch_size":"{{CONTEXT.budget_remaining > 50 ? 200 : 50}}","criteria":"{{inputs.quality_criteria}}","field":"{{DOC.media_type == 'image' ? 'image_url' : 'video_url'}}"},"stage_id":"llm_filter"},"description":"Mixed case templates in same stage","stage_name":"llm_filter","stage_type":"filter"},{"config":{"parameters":{"final_top_k":10,"searches":[{"feature_uri":"mixpeek://web_scraper@v1/jinaai__jina_embeddings_v2_base_code","query":{"input_mode":"text","value":"{{INPUT.query}}"},"top_k":50}]},"pre_filters":{"AND":[{"field":"doc_type","operator":"eq","value":"code"}]},"stage_id":"feature_search"},"description":"Feature search with pre_filters (sibling of parameters, NOT inside)","stage_name":"search_code_blocks","stage_type":"filter"}]},"StageConfig-Output":{"properties":{"stage_name":{"type":"string","minLength":1,"title":"Stage Name","description":"Human-readable stage instance name (REQUIRED)."},"stage_type":{"anyOf":[{"$ref":"#/components/schemas/StageType"},{"type":"null"}],"description":"Functional category of the stage. Optional for creation requests; auto-inferred from `stage_id` when omitted."},"config":{"additionalProperties":true,"type":"object","title":"Config","description":"Stage implementation parameters (REQUIRED). Must include `stage_id` key referencing a registered retriever stage. Supports template expressions using Jinja2 syntax resolved at execution time. Template namespaces support both uppercase and lowercase formats: {{INPUT.field}} or {{inputs.field}}, {{DOC.field}} or {{doc.field}}, {{CONTEXT.field}} or {{context.field}}, {{STAGE.field}} or {{stage.field}}. All formats work identically. Provide stage-specific configuration under `parameters`. Optional `pre_filters` and `post_filters` are placed as SIBLINGS of `parameters` (NOT nested inside). Pre-filters require payload indexes on the filtered fields."},"batch_size":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Batch Size","description":"Optional templated batch size expression evaluated per execution. Supports template variables: {{INPUT.page_size}}, {{inputs.page_size}}, {{CONTEXT.budget_remaining}}, etc. Both uppercase and lowercase namespace names are supported (e.g., INPUT/inputs, DOC/doc, CONTEXT/context, STAGE/stage). Defaults to stage-specific value when omitted."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"User-facing description of the stage (OPTIONAL)."},"on_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"On Error","description":"Behavior when this stage fails. 'skip' continues execution with results from previous stages (graceful degradation). 'error' (default) fails the entire retriever. Useful for optional enrichment or multi-modal stages where one modality may not apply (e.g., face search on logo-only images)."},"output_alias":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Output Alias","description":"Optional alias to persist this stage's results in the execution context. When set, results are stored in CONTEXT.<alias> in addition to replacing current_results. Downstream stages can reference them via {{CONTEXT.<alias>}} in templates. Useful for multi-stage pipelines where later stages should not overwrite earlier results (e.g., face search + logo search producing independent result sets)."},"parameters":{"additionalProperties":true,"type":"object","title":"Parameters","description":"Mirror of config.parameters at the stage top level, so anything round-tripping a stage (clone-by-GET, UI re-save, an agent verifying its own write) reads a populated stage instead of an empty one. Always equal to config['parameters'] (FRUSTRATIONS 2026-07-22: a retriever cloned from GET output was created with NO searches because the real stage config only lived under config.parameters). Read-only — on input this key is ignored and recomputed from config, so the two can't drift; config stays the source of truth.","readOnly":true}},"type":"object","required":["stage_name","config","parameters"],"title":"StageConfig","description":"Configuration for a single stage within a retriever.\n\nStages support dynamic configuration through template expressions using Jinja2 syntax.\n\nIMPORTANT - Template Syntax:\n    - Use DOUBLE curly braces: {{INPUT.query}} (correct)\n    - Single curly braces will NOT work: {INPUT.query} (wrong - not substituted)\n    - Namespace names are CASE-INSENSITIVE: {{INPUT.query}}, {{inputs.query}}, {{input.query}}\n      all work identically\n\nTemplate Namespaces (case-insensitive):\n    - INPUT / inputs / input: User-provided query parameters and inputs\n    - DOC / doc: Current document fields (for per-document logic)\n    - CONTEXT / context: Execution state (budget, timing, retriever metadata)\n    - STAGE / stage: Previous stage outputs (for cascading logic)\n\nExamples:\n    Correct: {{INPUT.query_text}}, {{inputs.query}}, {{DOC.content_type}}\n    Correct: {{CONTEXT.budget_remaining}}, {{context.budget_remaining}}\n    Wrong:   {INPUT.query} - single braces won't be substituted","examples":[{"config":{"parameters":{"final_top_k":25,"searches":[{"feature_uri":"mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1","query":{"input_mode":"text","value":"{{INPUT.query_text}}"},"top_k":100}]},"stage_id":"feature_search"},"description":"Feature search stage with uppercase template namespace","stage_name":"semantic_search","stage_type":"filter"},{"batch_size":"{{20 * inputs.page_size}}","config":{"parameters":{"field":"metadata.price","operator":"gt","value":"{{inputs.min_price}}"},"stage_id":"attribute_filter"},"description":"Attribute filter with lowercase template namespace","stage_name":"price_filter","stage_type":"filter"},{"config":{"parameters":{"batch_size":"{{CONTEXT.budget_remaining > 50 ? 200 : 50}}","criteria":"{{inputs.quality_criteria}}","field":"{{DOC.media_type == 'image' ? 'image_url' : 'video_url'}}"},"stage_id":"llm_filter"},"description":"Mixed case templates in same stage","stage_name":"llm_filter","stage_type":"filter"},{"config":{"parameters":{"final_top_k":10,"searches":[{"feature_uri":"mixpeek://web_scraper@v1/jinaai__jina_embeddings_v2_base_code","query":{"input_mode":"text","value":"{{INPUT.query}}"},"top_k":50}]},"pre_filters":{"AND":[{"field":"doc_type","operator":"eq","value":"code"}]},"stage_id":"feature_search"},"description":"Feature search with pre_filters (sibling of parameters, NOT inside)","stage_name":"search_code_blocks","stage_type":"filter"}]},"StageDiscovery":{"properties":{"stage_id":{"type":"string","title":"Stage Id","description":"Unique identifier for the stage"},"description":{"type":"string","title":"Description","description":"Human-readable description of stage behavior"},"category":{"type":"string","title":"Category","description":"Transformation category: filter, sort, reduce, apply, enrich"},"icon":{"type":"string","title":"Icon","description":"Lucide React icon identifier"},"parameter_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Parameter Schema","description":"JSON Schema for stage parameters"},"example_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Example Config","description":"Example stage configuration"},"common_use_cases":{"items":{"type":"string"},"type":"array","title":"Common Use Cases","description":"Common scenarios where this stage is useful"},"cost_tier":{"type":"string","title":"Cost Tier","description":"Relative cost tier: cheap, moderate, expensive","default":"moderate"},"requires_collections":{"type":"boolean","title":"Requires Collections","description":"Whether this stage requires collection access","default":true}},"type":"object","required":["stage_id","description","category","icon"],"title":"StageDiscovery","description":"Extended stage discovery information with examples.\n\nIncludes everything from RetrieverStageDefinition plus\nusage examples and common patterns.","examples":[{"category":"filter","common_use_cases":["Semantic search over embeddings","Multi-modal retrieval","Hybrid search with fusion"],"cost_tier":"moderate","description":"Unified multi-vector search with N feature URIs and fusion","example_config":{"parameters":{"feature_uri":"multimodal_extractor.v1.embedding","query":"{{ INPUT.query }}","top_k":25},"stage_id":"feature_filter","stage_name":"semantic_search"},"icon":"search","parameter_schema":{"properties":{"feature_uri":{"type":"string"},"top_k":{"default":25,"type":"integer"}},"type":"object"},"requires_collections":true,"stage_id":"feature_filter"}]},"StageInstanceConfig":{"properties":{"stage_name":{"type":"string","title":"Stage Name"},"stage_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stage Id","description":"Stage implementation ID (overrides stage_name for lookups)"},"parameters":{"additionalProperties":true,"type":"object","title":"Parameters","description":"Stage parameters"},"pre_filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"Filters to apply to the documents *before* this stage is executed.These filters are combined with any global retriever filters."},"post_filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"NOT APPLIED. This field is accepted, template-evaluated and resolved, but no stage reads it, so supplying a predicate here returns UNFILTERED results with HTTP 200 and no warning. It is retained only so existing configs keep validating. Use `pre_filters` to restrict the documents this stage sees."},"stats":{"anyOf":[{"$ref":"#/components/schemas/StagePerformance-Input"},{"type":"null"}],"description":"Performance statistics for this stage"}},"type":"object","required":["stage_name"],"title":"StageInstanceConfig","description":"User-provided configuration for a stage instance in a retriever pipeline.\n\nThis model is used when creating a retriever to define the specific\nparameters for each stage."},"StagePerformance-Input":{"properties":{"avg_execution_ms":{"type":"number","title":"Avg Execution Ms","description":"Average execution time in milliseconds","default":0.0},"execution_count":{"type":"integer","title":"Execution Count","description":"Number of times executed","default":0},"error_count":{"type":"integer","title":"Error Count","description":"Number of errors encountered","default":0},"last_executed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Executed At","description":"Last time this stage was executed"}},"type":"object","title":"StagePerformance","description":"Performance statistics for a retriever stage."},"StagePerformance-Output":{"properties":{"stage_name":{"type":"string","title":"Stage Name","description":"Name of the profiled stage"},"component":{"type":"string","title":"Component","description":"Component (e.g., extractor, cluster)"},"execution_count":{"type":"integer","title":"Execution Count","description":"Number of executions"},"avg_latency_ms":{"type":"number","title":"Avg Latency Ms","description":"Average latency"},"p95_latency_ms":{"type":"number","title":"P95 Latency Ms","description":"95th percentile latency"},"max_latency_ms":{"type":"number","title":"Max Latency Ms","description":"Maximum latency"},"total_time_ms":{"type":"number","title":"Total Time Ms","description":"Total time spent in this stage"},"pct_of_total":{"type":"number","title":"Pct Of Total","description":"Percentage of total time spent in this stage"}},"type":"object","required":["stage_name","component","execution_count","avg_latency_ms","p95_latency_ms","max_latency_ms","total_time_ms","pct_of_total"],"title":"StagePerformance","description":"Performance breakdown by stage."},"StagePerformanceMetrics":{"properties":{"stage_name":{"type":"string","title":"Stage Name","description":"Name of the stage"},"stage_type":{"type":"string","title":"Stage Type","description":"Type of the stage"},"execution_count":{"type":"integer","title":"Execution Count","description":"Number of executions"},"avg_latency_ms":{"type":"number","title":"Avg Latency Ms","description":"Average latency"},"p95_latency_ms":{"type":"number","title":"P95 Latency Ms","description":"P95 latency"},"avg_documents_in":{"type":"number","title":"Avg Documents In","description":"Average documents input"},"avg_documents_out":{"type":"number","title":"Avg Documents Out","description":"Average documents output"}},"type":"object","required":["stage_name","stage_type","execution_count","avg_latency_ms","p95_latency_ms","avg_documents_in","avg_documents_out"],"title":"StagePerformanceMetrics","description":"Stage-level performance metrics."},"StageProgress":{"properties":{"stage":{"$ref":"#/components/schemas/MigrationStage","description":"Stage name"},"status":{"$ref":"#/components/schemas/MigrationStatus","description":"Stage status"},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At","description":"Stage start time"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"Stage completion time"},"progress_percent":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Progress Percent","description":"Progress %","default":0.0},"items_total":{"type":"integer","minimum":0.0,"title":"Items Total","description":"Total items to process","default":0},"items_completed":{"type":"integer","minimum":0.0,"title":"Items Completed","description":"Items completed","default":0},"items_failed":{"type":"integer","minimum":0.0,"title":"Items Failed","description":"Items failed","default":0},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Error if failed","x-mixpeek-redacted":"driver_text"}},"type":"object","required":["stage","status"],"title":"StageProgress","description":"Progress tracking for a migration stage."},"StageStatistics":{"properties":{"input_count":{"type":"integer","minimum":0.0,"title":"Input Count","description":"Number of documents received by the stage (REQUIRED)."},"output_count":{"type":"integer","minimum":0.0,"title":"Output Count","description":"Number of documents emitted by the stage (REQUIRED)."},"duration_ms":{"type":"number","minimum":0.0,"title":"Duration Ms","description":"Wall-clock duration in milliseconds (REQUIRED)."},"efficiency":{"type":"number","minimum":0.0,"title":"Efficiency","description":"Output/Input ratio. 0 when input_count is 0 (REQUIRED)."},"cache_hit":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Cache Hit","description":"Deprecated alias for stage_cache_hit, kept for existing callers (OPTIONAL). Despite the name, this describes only THIS stage's own cache, not the retriever-level execute cache reported by cache_hit on the top-level response -- the two fields have shared this name across different response levels and that has misled multiple verification passes. Prefer stage_cache_hit."},"stage_cache_hit":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Stage Cache Hit","description":"Indicates whether THIS stage served its result from its own stage cache (OPTIONAL). Distinct from cache_hit on the top-level retriever execution response, which describes a separate, retriever-level execute cache; a stage can report stage_cache_hit=true on a response whose top-level cache_hit is false, and that is not a contradiction."},"cached_at":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cached At","description":"Unix timestamp when this stage result was cached. Present only on cache hits."},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Stage-specific error message if execution failed but retriever execution continued (OPTIONAL)."},"llm_calls":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Llm Calls","description":"Number of LLM invocations performed by the stage (OPTIONAL)."},"tokens_used":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Tokens Used","description":"Total tokens consumed by the stage (OPTIONAL, only for LLM stages)."},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Stage-specific metadata containing additional execution details (OPTIONAL). For example, join stages include: join_strategy, join_type, matched_count, match_rate, etc. LLM stages may include: model_name, temperature, max_tokens, etc."}},"type":"object","required":["input_count","output_count","duration_ms","efficiency"],"title":"StageStatistics","description":"Execution metrics for a single stage in a retriever execution run.","examples":[{"cache_hit":false,"duration_ms":123.4,"efficiency":0.05,"input_count":5000,"output_count":250,"stage_cache_hit":false}]},"StageType":{"type":"string","enum":["filter","sort","reduce","apply","enrich"],"title":"StageType","description":"Categorisation of stage behaviour within a retrieval flow.\n\nThese functional categories describe how stages transform the document stream:\n\n- FILTER: N → ≤N documents (subset, same schema)\n- SORT: N → N documents (same docs, different order, same schema)\n- REDUCE: N → 1 document (aggregation, new schema)\n- APPLY: N → N or N*M documents (enrichment/expansion, expanded/new schema)\n- ENRICH: N → N documents (enrichment with computed fields)"},"StandaloneNamespaceResponseModel":{"properties":{"namespace_id":{"type":"string","title":"Namespace Id"},"mode":{"type":"string","title":"Mode","default":"standalone"},"status":{"type":"string","title":"Status","default":"active"},"vector_configs":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Vector Configs"},"tiering":{"type":"string","title":"Tiering","default":"auto"},"document_count":{"type":"integer","title":"Document Count","default":0}},"type":"object","required":["namespace_id"],"title":"StandaloneNamespaceResponseModel","description":"Response from standalone namespace creation."},"StandaloneStorageConfig":{"properties":{"connection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Connection Id","description":"Existing org storage connection ID"}},"type":"object","title":"StandaloneStorageConfig","description":"BYO object storage connection for WAL/snapshots/cold data."},"StartEvaluationRequest":{"properties":{"dataset_name":{"type":"string","minLength":1,"title":"Dataset Name","description":"Name of the evaluation dataset to use"},"evaluation_config":{"anyOf":[{"$ref":"#/components/schemas/EvaluationConfig"},{"type":"null"}],"description":"Optional evaluation configuration (uses defaults if not provided)"}},"type":"object","required":["dataset_name"],"title":"StartEvaluationRequest","description":"Request to start an evaluation."},"StartEvaluationResponse":{"properties":{"task_id":{"type":"string","title":"Task Id","description":"Task ID for tracking progress"},"evaluation_id":{"type":"string","title":"Evaluation Id","description":"Evaluation ID"},"task_type":{"type":"string","title":"Task Type","description":"Task type","default":"retriever.evaluation"},"status":{"type":"string","title":"Status","description":"Initial status","default":"pending"},"created_at":{"type":"string","title":"Created At","description":"Creation timestamp"}},"type":"object","required":["task_id","evaluation_id","created_at"],"title":"StartEvaluationResponse","description":"Response when starting an evaluation."},"StartMigrationRequest":{"properties":{"force":{"type":"boolean","title":"Force","description":"Force start even if validation warnings exist","default":false}},"type":"object","title":"StartMigrationRequest","description":"Request to start a migration."},"StartMigrationResponse":{"properties":{"migration_id":{"type":"string","title":"Migration Id","description":"Migration ID"},"status":{"$ref":"#/components/schemas/MigrationStatus","description":"Current status"},"task_id":{"type":"string","title":"Task Id","description":"Task ID for tracking migration progress"},"started_at":{"type":"string","format":"date-time","title":"Started At","description":"Start timestamp"},"message":{"type":"string","title":"Message","description":"Human-readable message"}},"type":"object","required":["migration_id","status","task_id","started_at","message"],"title":"StartMigrationResponse","description":"Response after starting a migration.","example":{"message":"Migration started successfully. Track progress at GET /migrations/{id}","migration_id":"mig_abc123xyz789","started_at":"2025-12-03T10:05:00Z","status":"pending","task_id":"task_xyz789"}},"StatItem":{"properties":{"label":{"type":"string","title":"Label","description":"Stat label (e.g. 'Total Ads')"},"value":{"type":"string","title":"Value","description":"Stat value (e.g. '12,400+')"}},"type":"object","required":["label","value"],"title":"StatItem","description":"A single stat item for the stats bar."},"StepAnalyticsConfig-Input":{"properties":{"timestamp_field":{"type":"string","title":"Timestamp Field","description":"Document field containing event timestamp (e.g., 'Date', 'created_at', 'metadata.timestamp')","examples":["Date","metadata.timestamp","created_at"]},"sequence_id_field":{"type":"string","title":"Sequence Id Field","description":"Document field that groups related items into a sequence (e.g., 'Thread-Index', 'session_id', 'user_id')","examples":["Thread-Index","metadata.session_id","user_id"]},"step_key_source":{"$ref":"#/components/schemas/StepKeySource","description":"How to determine the 'step' for each document (label, node_id, or custom field)","default":"assignment_label"},"step_key_field_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Step Key Field Path","description":"Required if step_key_source='field_path'. Dot-notation path to step value in document.","examples":["metadata.workflow_stage","status","enrichments.stage"]},"covariates":{"items":{"$ref":"#/components/schemas/CovariateConfig"},"type":"array","maxItems":20,"title":"Covariates","description":"Predictor fields to analyze for conversion lift (categorical, numeric, embedding, cluster)"},"max_sequence_duration_days":{"anyOf":[{"type":"integer","maximum":365.0,"minimum":1.0},{"type":"null"}],"title":"Max Sequence Duration Days","description":"Maximum allowed duration for a sequence. Sequences beyond this are flagged as data quality issues."}},"type":"object","required":["timestamp_field","sequence_id_field"],"title":"StepAnalyticsConfig","description":"Configuration for step-by-step transition analytics on taxonomy assignments.\n\nEnables analysis of how documents progress through taxonomy labels as a temporal\nsequence, answering questions like:\n- How long from \"inquiry\" to \"closed_won\"?\n- What % of \"inquiry\" emails reach \"proposal\"?\n- Which sender domains correlate with faster progression?\n\nUse Cases:\n    1. Email Thread Analysis:\n       - Track progression: inquiry → followup → proposal → closed_won\n       - Identify which subject lines correlate with faster closure\n\n    2. Content Workflow Tracking:\n       - Monitor: draft → review → approved → published\n       - Find bottlenecks and optimization opportunities\n\n    3. Safety Compliance Monitoring:\n       - Trace: violation_detected → investigated → resolved\n       - Track resolution times and success rates\n\nAttributes:\n    timestamp_field: Document field containing event timestamp\n    sequence_id_field: Field that groups related documents into sequences\n    step_key_source: How to extract the step identifier (label/node_id/custom field)\n    step_key_field_path: Required if step_key_source='field_path'\n    covariates: List of predictor variables to analyze for conversion lift\n    max_sequence_duration_days: Filter out sequences longer than this (data quality)\n\nExample:\n    ```python\n    # Email thread analysis configuration\n    StepAnalyticsConfig(\n        timestamp_field=\"Date\",  # Email timestamp\n        sequence_id_field=\"Thread-Index\",  # Groups emails in same thread\n        step_key_source=\"assignment_label\",  # Use taxonomy label as step\n        covariates=[\n            CovariateConfig(\n                field_path=\"sender_domain\",\n                covariate_type=\"categorical\",\n                name=\"Sender Domain\"\n            ),\n            CovariateConfig(\n                field_path=\"word_count\",\n                covariate_type=\"numeric\",\n                name=\"Email Length\"\n            )\n        ],\n        max_sequence_duration_days=90  # Ignore threads >90 days\n    )\n    ```"},"StepAnalyticsConfig-Output":{"properties":{"timestamp_field":{"type":"string","title":"Timestamp Field","description":"Document field containing event timestamp (e.g., 'Date', 'created_at', 'metadata.timestamp')","examples":["Date","metadata.timestamp","created_at"]},"sequence_id_field":{"type":"string","title":"Sequence Id Field","description":"Document field that groups related items into a sequence (e.g., 'Thread-Index', 'session_id', 'user_id')","examples":["Thread-Index","metadata.session_id","user_id"]},"step_key_source":{"$ref":"#/components/schemas/StepKeySource","description":"How to determine the 'step' for each document (label, node_id, or custom field)","default":"assignment_label"},"step_key_field_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Step Key Field Path","description":"Required if step_key_source='field_path'. Dot-notation path to step value in document.","examples":["metadata.workflow_stage","status","enrichments.stage"]},"covariates":{"items":{"$ref":"#/components/schemas/CovariateConfig"},"type":"array","maxItems":20,"title":"Covariates","description":"Predictor fields to analyze for conversion lift (categorical, numeric, embedding, cluster)"},"max_sequence_duration_days":{"anyOf":[{"type":"integer","maximum":365.0,"minimum":1.0},{"type":"null"}],"title":"Max Sequence Duration Days","description":"Maximum allowed duration for a sequence. Sequences beyond this are flagged as data quality issues."}},"type":"object","required":["timestamp_field","sequence_id_field"],"title":"StepAnalyticsConfig","description":"Configuration for step-by-step transition analytics on taxonomy assignments.\n\nEnables analysis of how documents progress through taxonomy labels as a temporal\nsequence, answering questions like:\n- How long from \"inquiry\" to \"closed_won\"?\n- What % of \"inquiry\" emails reach \"proposal\"?\n- Which sender domains correlate with faster progression?\n\nUse Cases:\n    1. Email Thread Analysis:\n       - Track progression: inquiry → followup → proposal → closed_won\n       - Identify which subject lines correlate with faster closure\n\n    2. Content Workflow Tracking:\n       - Monitor: draft → review → approved → published\n       - Find bottlenecks and optimization opportunities\n\n    3. Safety Compliance Monitoring:\n       - Trace: violation_detected → investigated → resolved\n       - Track resolution times and success rates\n\nAttributes:\n    timestamp_field: Document field containing event timestamp\n    sequence_id_field: Field that groups related documents into sequences\n    step_key_source: How to extract the step identifier (label/node_id/custom field)\n    step_key_field_path: Required if step_key_source='field_path'\n    covariates: List of predictor variables to analyze for conversion lift\n    max_sequence_duration_days: Filter out sequences longer than this (data quality)\n\nExample:\n    ```python\n    # Email thread analysis configuration\n    StepAnalyticsConfig(\n        timestamp_field=\"Date\",  # Email timestamp\n        sequence_id_field=\"Thread-Index\",  # Groups emails in same thread\n        step_key_source=\"assignment_label\",  # Use taxonomy label as step\n        covariates=[\n            CovariateConfig(\n                field_path=\"sender_domain\",\n                covariate_type=\"categorical\",\n                name=\"Sender Domain\"\n            ),\n            CovariateConfig(\n                field_path=\"word_count\",\n                covariate_type=\"numeric\",\n                name=\"Email Length\"\n            )\n        ],\n        max_sequence_duration_days=90  # Ignore threads >90 days\n    )\n    ```"},"StepInfo":{"properties":{"step_key":{"type":"string","title":"Step Key","description":"Step identifier"},"event_count":{"type":"integer","minimum":0.0,"title":"Event Count","description":"Total events for this step"},"sequence_count":{"type":"integer","minimum":0.0,"title":"Sequence Count","description":"Unique sequences with this step"},"first_seen":{"type":"string","title":"First Seen","description":"Earliest event timestamp (ISO format)"},"last_seen":{"type":"string","title":"Last Seen","description":"Most recent event timestamp (ISO format)"}},"type":"object","required":["step_key","event_count","sequence_count","first_seen","last_seen"],"title":"StepInfo","description":"Information about a single step in the taxonomy analytics data.\n\nAttributes:\n    step_key: The step identifier (e.g., \"inquiry\", \"closed_won\")\n    event_count: Number of events with this step\n    sequence_count: Number of unique sequences with this step\n    first_seen: ISO timestamp of earliest event with this step\n    last_seen: ISO timestamp of most recent event with this step"},"StepKeySource":{"type":"string","enum":["assignment_label","assignment_node_id","field_path"],"title":"StepKeySource","description":"Defines how to extract the step key from documents for sequence analysis.\n\nThe step key identifies which stage/state a document is in for transition analytics.\n\nExamples:\n    ASSIGNMENT_LABEL: Use the taxonomy's assigned label (e.g., \"inquiry\", \"proposal\")\n    ASSIGNMENT_NODE_ID: Use the taxonomy node ID (e.g., \"node_sales_inquiry\")\n    FIELD_PATH: Use a custom document field (e.g., \"metadata.workflow_stage\")"},"StepTransitionRequest":{"properties":{"collection_id":{"type":"string","title":"Collection Id","description":"Collection to analyze for step transitions"},"taxonomy_id":{"type":"string","title":"Taxonomy Id","description":"Taxonomy ID (each taxonomy_id is immutable, clone creates new ID)"},"from_step":{"type":"string","title":"From Step","description":"Starting step label (e.g., 'inquiry', 'draft')","examples":["inquiry","draft","violation_detected"]},"to_step":{"type":"string","title":"To Step","description":"Ending step label (e.g., 'closed_won', 'published')","examples":["closed_won","published","resolved"]},"max_window_days":{"anyOf":[{"type":"integer","maximum":365.0,"minimum":1.0},{"type":"null"}],"title":"Max Window Days","description":"Maximum days between from_step and to_step. Sequences exceeding this are excluded."},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","description":"Optional filters for events (e.g., {'metadata.region': 'US'})"},"override_step_analytics":{"anyOf":[{"$ref":"#/components/schemas/StepAnalyticsConfig-Input"},{"type":"null"}],"description":"Override taxonomy's default step_analytics config for this query"},"min_support":{"type":"integer","minimum":1.0,"title":"Min Support","description":"Minimum number of sequences required for valid analysis","default":10}},"type":"object","required":["collection_id","taxonomy_id","from_step","to_step"],"title":"StepTransitionRequest","description":"API request model for step transition analytics.\n\nThis model extends the engine query model with API-specific validation\nand documentation.\n\nUse this to analyze how documents transition from one taxonomy step to another,\ncomputing conversion rates, durations, and predictor lifts.\n\nExample:\n    ```json\n    {\n        \"collection_id\": \"col_emails\",\n        \"taxonomy_id\": \"tax_sales_stages\",\n        \"from_step\": \"inquiry\",\n        \"to_step\": \"closed_won\",\n        \"max_window_days\": 90,\n        \"min_support\": 10\n    }\n    ```\n\nResponse includes:\n    - Conversion rate (% reaching to_step)\n    - Duration statistics (mean, median, p90, p95)\n    - Top predictors (covariates with highest lift)"},"StepTransitionResponse":{"properties":{"from_step":{"type":"string","title":"From Step","description":"Starting step"},"to_step":{"type":"string","title":"To Step","description":"Ending step"},"count":{"type":"integer","minimum":0.0,"title":"Count","description":"Total number of sequences starting at from_step"},"converted":{"type":"integer","minimum":0.0,"title":"Converted","description":"Number of sequences that reached to_step"},"conversion_rate":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Conversion Rate","description":"Percentage that converted (converted / count)"},"durations_sec":{"anyOf":[{"$ref":"#/components/schemas/DurationStats"},{"type":"null"}],"description":"Duration statistics (None if no conversions)"},"top_predictors":{"items":{"$ref":"#/components/schemas/PredictorLift"},"type":"array","maxItems":50,"title":"Top Predictors","description":"Covariates with highest lift (sorted by absolute lift)"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Additional metadata (collection_id, event counts, etc.)"}},"type":"object","required":["from_step","to_step","count","converted","conversion_rate"],"title":"StepTransitionResponse","description":"API response model for step transition analytics.\n\nContains comprehensive statistics about the A→B transition including\nconversion metrics, duration analysis, and predictor insights.\n\nExample Response:\n    ```json\n    {\n        \"from_step\": \"inquiry\",\n        \"to_step\": \"closed_won\",\n        \"count\": 1000,\n        \"converted\": 350,\n        \"conversion_rate\": 0.35,\n        \"durations_sec\": {\n            \"mean\": 432000.0,\n            \"median\": 345600.0,\n            \"p50\": 345600.0,\n            \"p90\": 691200.0,\n            \"p95\": 864000.0,\n            \"std_dev\": 172800.0,\n            \"min\": 86400.0,\n            \"max\": 1209600.0\n        },\n        \"top_predictors\": [\n            {\n                \"field\": \"Sender Domain\",\n                \"value\": \"enterprise.com\",\n                \"count\": 150,\n                \"conversion_rate\": 0.75,\n                \"lift\": 2.14\n            }\n        ],\n        \"metadata\": {\n            \"collection_id\": \"col_emails\",\n            \"taxonomy_id\": \"tax_sales_stages\",\n            \"total_events_analyzed\": 5432\n        }\n    }\n    ```"},"StorageClass":{"type":"string","enum":["standard","nearline","coldline","archive"],"title":"StorageClass","description":"Provider-agnostic object-storage tier for a bucket.\n\nThe mixpeek API stays provider-agnostic; the object-storage factory maps each\nvalue to the underlying provider's equivalent on write (and, where supported,\nretroactively via lifecycle/rewrite):\n\n| mixpeek   | GCS       | S3 / MinIO     |\n|-----------|-----------|----------------|\n| standard  | STANDARD  | STANDARD       |\n| nearline  | NEARLINE  | STANDARD_IA    |\n| coldline  | COLDLINE  | GLACIER_IR     |\n| archive   | ARCHIVE   | refused        |\n\nEvery mapped tier is readable without a restore step. S3 has no archive\nclass with instant reads (GLACIER and DEEP_ARCHIVE need an asynchronous\nrestore, which the read path cannot do), so ``archive`` is refused for an\nS3 backend when a bucket is created or updated\n(``assert_supported_by_backend``).\n\nSet per-bucket so hot retriever-source buckets stay `standard` while large\nwrite-once/read-occasionally media buckets (footage, creatives) opt into a\ncheaper tier (e.g. ~50% on Nearline for the TS iconik ~13TB footage sync)."},"StorageConnectionCreateRequest":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"REQUIRED. Human-readable name for the storage connection. Must be unique within the organization. Displayed in dashboards and sync logs. Format: 1-100 characters, descriptive of the connection's purpose.","examples":["Marketing Google Drive","Production S3 Bucket","Customer Assets Archive"]},"provider_type":{"$ref":"#/components/schemas/StorageProvider","description":"REQUIRED. Storage provider to connect to. Supported providers: google_drive, s3, snowflake, sharepoint, tigris. Determines which authentication and sync logic is used.","examples":["google_drive","s3","snowflake","sharepoint","tigris"]},"provider_config":{"additionalProperties":true,"type":"object","title":"Provider Config","description":"REQUIRED. Provider-specific configuration including credentials. Structure varies by provider_type. SECURITY: Credential fields never appear in responses or logs; a read returns provider_config.credentials with only its type.","examples":[{"credentials":{"client_email":"sync@project.iam.gserviceaccount.com","type":"service_account"},"description":"Google Drive configuration","shared_drive_id":"0AH-Xabc123"},{"bucket":"my-bucket","credentials":{"access_key_id":"AKIA...","secret_access_key":"wJalrXUtnFEMI...","type":"access_key"},"description":"S3 configuration","region":"us-east-1"}]},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description","description":"OPTIONAL. Description explaining the connection's purpose and scope. Helpful for team collaboration and documentation. Format: Up to 500 characters.","examples":["Shared drive for marketing team assets and campaign materials","Production S3 bucket containing customer-uploaded videos"]},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"OPTIONAL. Arbitrary key-value metadata for tagging and categorization. Common uses: team tags, cost center codes, project identifiers.","examples":[{"cost_center":"CC-1234","team":"marketing"},{"environment":"production","project":"q4-campaign"}]},"write_enabled":{"type":"boolean","title":"Write Enabled","description":"Allow Mixpeek to WRITE to this connection's storage. Off by default, and consulted only when this connection is named as an export destination, so a read-only connection is unaffected. Your side needs the matching permission too: s3:PutObject for S3, storage.objects.create for GCS.","default":false},"test_before_save":{"type":"boolean","title":"Test Before Save","description":"OPTIONAL. Whether to validate credentials before saving the connection. Defaults to True. If True, connection will be tested against the provider before creation. If False, connection is saved without validation (use with caution).","default":true}},"type":"object","required":["name","provider_type","provider_config"],"title":"StorageConnectionCreateRequest","description":"Request payload for creating a new storage connection.\n\nUse this to connect Mixpeek to external storage providers like Google Drive\nor S3. The connection will be tested before being saved (unless\ntest_before_save is False).\n\n**Use Cases:**\n- Connect to team Google Drive for automated file ingestion\n- Link customer S3 buckets for batch processing\n- Set up storage connections for sync operations\n\n**Security:**\n- Credentials never appear in API responses or logs; a read returns only the credential type\n- Connection is tested before saving to validate credentials\n\n**Examples:**\n```python\n# Google Drive connection\n{\n    \"name\": \"Marketing Drive\",\n    \"provider_type\": \"google_drive\",\n    \"provider_config\": {\n        \"credentials\": {...},\n        \"shared_drive_id\": \"0AH-Xabc123\"\n    },\n    \"description\": \"Team drive for marketing assets\"\n}\n```","examples":[{"description":"Team drive for marketing assets","name":"Marketing Google Drive","provider_config":{"credentials":{"client_email":"sync@project.iam.gserviceaccount.com","type":"service_account"},"shared_drive_id":"0AH-Xabc123"},"provider_type":"google_drive","test_before_save":true},{"metadata":{"environment":"production"},"name":"Production S3 Bucket","provider_config":{"bucket":"my-bucket","credentials":{"access_key_id":"AKIA..."},"region":"us-east-1"},"provider_type":"s3","test_before_save":false}]},"StorageConnectionListResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/StorageConnectionModel"},"type":"array","title":"Results","description":"List of storage connections matching the request filters. Results are paginated according to the pagination parameters. SECURITY: credential fields are not returned; only the credential type is."},"pagination":{"$ref":"#/components/schemas/PaginationResponse","description":"Pagination metadata including total count, page number, page size, and navigation links for next/previous pages."},"total":{"type":"integer","minimum":0.0,"title":"Total","description":"Total number of connections matching the filters (before pagination). Use this to calculate total pages and display pagination controls.","examples":[0,5,42]}},"type":"object","required":["results","pagination","total"],"title":"StorageConnectionListResponse","description":"Response envelope for listing storage connections.\n\nContains paginated results and metadata about the listing operation.","examples":[{"description":"Paginated list response","pagination":{"page":1,"page_size":10,"total":10,"total_pages":1},"results":[{"connection_id":"conn_abc123","is_active":true,"name":"Marketing Drive","provider_type":"google_drive","status":"active"}],"total":10}]},"StorageConnectionModel":{"properties":{"connection_id":{"type":"string","title":"Connection Id","description":"Unique identifier for the storage connection. Auto-generated with 'conn_' prefix followed by secure random token. Format: conn_{15-character alphanumeric}. Used for API operations and audit trails.","examples":["conn_abc123def456ghi","conn_xyz789uvw012qrs"]},"internal_id":{"type":"string","title":"Internal Id","description":"REQUIRED. Organization internal identifier for multi-tenancy scoping. All connection operations are scoped to this organization. Format: int_{24-character secure token}.","examples":["int_org123abc456def789xyz012"]},"provider_type":{"$ref":"#/components/schemas/StorageProvider","description":"REQUIRED. Storage provider implementation to use. Determines which client adapter is loaded for sync operations. Supported: google_drive, s3, snowflake, sharepoint, tigris."},"provider_config":{"anyOf":[{"$ref":"#/components/schemas/GoogleDriveConfig"},{"$ref":"#/components/schemas/S3Config"},{"$ref":"#/components/schemas/SnowflakeConfig"},{"$ref":"#/components/schemas/SharePointConfig"},{"$ref":"#/components/schemas/TigrisConfig"},{"$ref":"#/components/schemas/PostgreSQLConfig"},{"$ref":"#/components/schemas/InstagramConfig"},{"$ref":"#/components/schemas/TikTokConfig"},{"$ref":"#/components/schemas/RSSConfig"},{"$ref":"#/components/schemas/HTTPAPIConfig"},{"$ref":"#/components/schemas/BoxConfig"},{"$ref":"#/components/schemas/BrightDataConfig"},{"$ref":"#/components/schemas/BackblazeConfig"},{"$ref":"#/components/schemas/MuxConfig"},{"$ref":"#/components/schemas/IconikConfig"},{"$ref":"#/components/schemas/shared__organizations__connections__provider_configs__EmailConfig"},{"$ref":"#/components/schemas/GCSConfig"},{"$ref":"#/components/schemas/AzureBlobConfig"},{"$ref":"#/components/schemas/RTSPConfig"},{"additionalProperties":true,"type":"object"}],"title":"Provider Config","description":"REQUIRED. Provider-specific configuration payload including credentials. Type depends on provider_type (GoogleDriveConfig, S3Config, etc.). SECURITY: Credentials never appear in API responses or logs; a read returns credentials with only its type. See provider_configs.py for detailed schemas."},"write_enabled":{"type":"boolean","title":"Write Enabled","description":"Explicitly permit exports to write to this connection. Defaults to false; enabling requires the provider credentials to grant destination write access.","default":false},"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"REQUIRED. Human-readable connection name for identification. Displayed in dashboards, sync logs, and API responses. Must be unique within the organization for clarity. Format: 1-100 characters, descriptive of the connection's purpose.","examples":["Marketing Google Drive","Production S3 Bucket","Customer Assets Archive"]},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description","description":"NOT REQUIRED. Optional description explaining the connection's purpose and scope. Helpful for team collaboration and documentation. Format: Up to 500 characters.","examples":["Shared drive for marketing team assets and campaign materials","Production S3 bucket containing customer-uploaded videos"]},"status":{"$ref":"#/components/schemas/TaskStatusEnum","description":"Operational status of the connection. ACTIVE: Connection is healthy and ready for use in sync operations. SUSPENDED: Temporarily disabled by user, credentials preserved but sync paused. FAILED: Health checks failing, credentials may be invalid or expired. ARCHIVED: Permanently retired, cannot be reactivated. Status transitions automatically based on health checks and user actions.","default":"ACTIVE"},"is_active":{"type":"boolean","title":"Is Active","description":"Quick boolean flag for filtering active connections in queries. True when status is ACTIVE, False for SUSPENDED/FAILED/ARCHIVED. Maintained automatically when status changes. Use for efficient filtering: db.connections.find({'is_active': True})","default":true},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At","description":"NOT REQUIRED. UTC timestamp of the most recent successful sync operation. Updated automatically after each successful file sync/list operation. None if connection has never been used. Useful for identifying stale connections and usage analytics."},"last_error":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Last Error","description":"NOT REQUIRED. Most recent error message from failed health check or sync. Populated when authentication fails, network errors occur, or permissions denied. None when connection is healthy. Format: Error message truncated to 1000 characters. Used for diagnostics and troubleshooting.","examples":["Authentication failed: Invalid credentials","Permission denied: Unable to access shared drive","Network timeout: Failed to connect to storage.googleapis.com"]},"consecutive_failures":{"type":"integer","minimum":0.0,"title":"Consecutive Failures","description":"Counter tracking consecutive failed health checks or sync attempts. Incremented on each failure, reset to 0 on success. Used to implement automatic connection suspension. Auto-suspend after 5 consecutive failures to prevent account lockout. Range: 0 to infinity (typically 0-10).","default":0},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"UTC timestamp when the connection was created. Auto-generated using shared.utilities.helpers.current_time(). Immutable after creation. Format: ISO 8601 datetime."},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"UTC timestamp of the most recent update to the connection. Updated automatically on any field modification. Tracks configuration changes, status updates, and credential refreshes. Format: ISO 8601 datetime."},"created_by_user_id":{"type":"string","title":"Created By User Id","description":"REQUIRED. User identifier of the user who created this connection. Used for audit trails and permission checks. Format: usr_{15-character alphanumeric}. Immutable after creation.","examples":["usr_34bbf6ded1b749"]},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Arbitrary key-value metadata provided by the user. Useful for tagging, categorization, and custom annotations. NOT REQUIRED - defaults to empty dictionary. Common uses: team tags, cost center codes, project identifiers.","examples":[{"cost_center":"CC-1234","team":"marketing"},{"environment":"production","project":"q4-campaign"},{"tags":["customer-facing","high-priority"]}]}},"type":"object","required":["internal_id","provider_type","provider_config","name","created_by_user_id"],"title":"StorageConnectionModel","description":"Canonical representation of an external storage provider connection.\n\nStorage connections enable Mixpeek to access external cloud storage providers\n(Google Drive, S3, etc.) for automated file ingestion and synchronization.\nEach connection represents a configured integration with credentials, health\nmonitoring, and usage tracking.\n\nLifecycle States:\n    - ACTIVE: Connection is healthy and ready for sync operations\n    - SUSPENDED: Temporarily disabled by user (credentials preserved)\n    - FAILED: Health checks failing (may need credential refresh)\n    - ARCHIVED: Permanently retired (cannot be reactivated)\n\nSecurity:\n    - Credentials never appear in API responses or logs; a read returns only\n      the credential type\n    - Failed authentication attempts are logged in last_error\n    - Consecutive failures trigger automatic suspension\n\nUse Cases:\n    - Connect to team Google Drive for document ingestion\n    - Sync files from customer S3 buckets\n    - Monitor and process uploaded media files\n    - Schedule periodic sync operations\n\nHealth Monitoring:\n    - Automatic health checks validate connectivity and credentials\n    - consecutive_failures tracks authentication/network issues\n    - Auto-disable after 5 consecutive failures to prevent lockout\n    - last_error stores diagnostic information for debugging","examples":[{"connection_id":"conn_abc123def456ghi","created_by_user_id":"usr_admin123abc456","description":"Team drive for marketing assets","internal_id":"int_org123","is_active":true,"metadata":{"team":"marketing"},"name":"Marketing Google Drive","provider_config":{"credentials":{"client_email":"sync@project.iam.gserviceaccount.com","type":"service_account"},"provider_type":"google_drive","shared_drive_id":"0AH-Xabc123"},"provider_type":"google_drive","status":"active"},{"connection_id":"conn_xyz789uvw012qrs","created_by_user_id":"usr_admin123abc456","internal_id":"int_org123","is_active":true,"name":"Production S3 Bucket","provider_config":{"credentials":{"access_key_id":"AKIA..."},"provider_type":"s3","region":"us-east-1"},"provider_type":"s3","status":"active"}]},"StorageConnectionTestResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether the connection test succeeded. True: Credentials are valid and connection is accessible. False: Authentication failed, network error, or permissions denied.","examples":[true,false]},"message":{"type":"string","title":"Message","description":"Human-readable message describing the test result. Success: 'Connection test succeeded' or similar. Failure: Error message explaining what went wrong.","examples":["Connection test succeeded","Authentication failed: Invalid credentials","Permission denied: Unable to access shared drive"]},"details":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Details","description":"OPTIONAL. Additional diagnostic information about the test result. May include error details, provider-specific information, or success metadata. Format varies by provider.","examples":[{"provider_response":"...","result":"success"},{"error":"Invalid credentials","error_code":"AUTH_FAILED"}]}},"type":"object","required":["success","message"],"title":"StorageConnectionTestResponse","description":"Response payload for connection test endpoint.\n\nReturns the result of testing connection credentials against the external\nprovider. Used to validate credentials before saving or to diagnose issues.","examples":[{"description":"Successful test","details":{"result":"success"},"message":"Connection test succeeded","success":true},{"description":"Failed test","details":{"error":"Invalid credentials","error_code":"AUTH_FAILED"},"message":"Authentication failed: Invalid credentials","success":false}]},"StorageConnectionUpdateRequest":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name","description":"OPTIONAL. New name for the connection. Must be unique within the organization if provided. Format: 1-100 characters.","examples":["Updated Drive Name","New S3 Connection"]},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description","description":"OPTIONAL. New description for the connection. Set to empty string to clear existing description. Format: Up to 500 characters."},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"OPTIONAL. New metadata dictionary. Replaces existing metadata entirely (partial updates not supported). Set to empty dict {} to clear all metadata."},"status":{"anyOf":[{"$ref":"#/components/schemas/TaskStatusEnum"},{"type":"null"}],"description":"OPTIONAL. New operational status. ACTIVE: Connection is healthy and ready for use. SUSPENDED: Temporarily disabled, credentials preserved. FAILED: Health checks failing. ARCHIVED: Permanently retired (cannot be reactivated)."},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active","description":"OPTIONAL. Quick boolean flag for filtering. True when status is ACTIVE, False otherwise. Automatically maintained when status changes."},"write_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Write Enabled","description":"Turn write access to this connection's storage on or off. Omitted leaves it as it is; a connection that has never had it set cannot be written to."},"provider_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Provider Config","description":"OPTIONAL. Updated provider configuration including credentials. Replaces provider_config, except that credential fields you omit are kept when the credential type is unchanged, so a read-modify-write of one setting does not drop the stored secret. Send a credential field to replace it. SECURITY: credential fields never appear in read responses."}},"additionalProperties":false,"type":"object","title":"StorageConnectionUpdateRequest","description":"Request payload for updating storage connection metadata.\n\nAllows partial updates to connection metadata without changing credentials.\nCredentials can be updated via provider_config.\n\n**What You Can Update:**\n- Connection name and description\n- Metadata tags\n- Status (active/suspended)\n- Provider credentials (via provider_config)\n\n**Examples:**\n```python\n# Update name and description\n{\n    \"name\": \"Updated Drive Name\",\n    \"description\": \"New description\"\n}\n\n# Suspend connection\n{\n    \"status\": \"SUSPENDED\",\n    \"is_active\": False\n}\n\n# Refresh credentials\n{\n    \"provider_config\": {\n        \"credentials\": {...}\n    }\n}\n```","examples":[{"description":"New description","name":"Updated Drive Name"},{"is_active":false,"status":"SUSPENDED"},{"provider_config":{"credentials":{"access_key_id":"AKIA..."}}}]},"StorageMetric":{"properties":{"time_bucket":{"type":"string","format":"date-time","title":"Time Bucket","description":"Time bucket timestamp"},"total_size_bytes":{"type":"integer","title":"Total Size Bytes","description":"Total storage size in bytes"},"object_count":{"type":"integer","title":"Object Count","description":"Number of objects"},"avg_size_bytes":{"type":"integer","title":"Avg Size Bytes","description":"Average object size in bytes"},"growth_rate_percent":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Growth Rate Percent","description":"Growth rate vs previous period"}},"type":"object","required":["time_bucket","total_size_bytes","object_count","avg_size_bytes"],"title":"StorageMetric","description":"Single time bucket storage metric."},"StorageProvider":{"type":"string","enum":["google_drive","s3","snowflake","sharepoint","tigris","postgresql","instagram","tiktok","rss","http_api","box","brightdata","backblaze","mux","email","supabase","iconik","gcs","azure_blob","rtsp"],"title":"StorageProvider","description":"Supported external storage providers for ingestion and sync.\n\nMixpeek can connect to external storage providers to automatically\ningest objects and keep them synchronized with your namespaces.\n\nProviders:\n    GOOGLE_DRIVE: Google Drive and Google Workspace shared drives.\n        - Authentication: Service account or OAuth2\n        - Features: Shared drive support, real-time sync, metadata preservation\n        - Use cases: Marketing assets, team documents, knowledge bases\n        - Limitations: Rate limits apply (10,000 requests/100 seconds per user)\n\n    S3: Amazon S3 and S3-compatible storage (MinIO, DigitalOcean Spaces, etc).\n        - Authentication: Access keys or IAM role assumption\n        - Features: Bucket notifications, prefix filtering, versioning support\n        - Use cases: Data lakes, video archives, ML datasets, backups\n        - Limitations: IAM role assumption preferred over access keys\n\n    SNOWFLAKE: Snowflake data warehouse tables.\n        - Authentication: Key pair or username/password\n        - Features: Incremental sync via watermarks, row-level mapping, schema introspection\n        - Use cases: Customer data tables, product catalogs, transaction logs, metadata tables\n        - Limitations: Each row becomes one object; large tables require incremental column\n\n    SHAREPOINT: Microsoft SharePoint and OneDrive for Business.\n        - Authentication: Azure AD OAuth2 (client credentials or delegated)\n        - Features: Site/drive selection, folder sync, delta queries for incremental sync\n        - Use cases: Enterprise documents, team collaboration files, compliance archives\n        - Limitations: Requires Azure AD app registration; throttling limits apply\n\nConnection Requirements:\n    - Valid credentials with read access to target files/buckets\n    - Network connectivity from Mixpeek infrastructure\n    - Appropriate IAM policies or share permissions configured\n\nExamples:\n    - Use GOOGLE_DRIVE for syncing team marketing materials\n    - Use S3 for ingesting video archives from data lakes\n    - Use S3 with IAM role for secure production deployments\n    - Use SHAREPOINT for syncing enterprise SharePoint document libraries\n\n    TIGRIS: Tigris Data globally distributed object storage (S3-compatible).\n        - Authentication: Access keys (same format as S3)\n        - Features: S3-compatible API, global distribution, zero egress fees\n        - Use cases: Globally distributed media, low-latency content delivery\n        - Endpoint: https://fly.storage.tigris.dev\n\n    POSTGRESQL: PostgreSQL relational database.\n        - Authentication: Username/password\n        - Features: SQL queries, incremental sync via watermarks, row-level mapping\n        - Use cases: Customer data tables, product catalogs, transaction logs\n        - Limitations: Each row becomes one object; large tables require incremental column\n\n    INSTAGRAM: Instagram Business/Creator accounts via Meta Graph API.\n        - Authentication: OAuth 2.0 via Meta Developer Console\n        - Features: Media sync (posts, reels, carousels), engagement metrics, captions\n        - Use cases: Social media content analysis, talent scouting, competitor monitoring\n        - Limitations: Requires Instagram Business/Creator account; long-lived tokens (60 days) need refresh\n\n    TIKTOK: TikTok accounts via TikTok Content API.\n        - Authentication: OAuth 2.0 via TikTok Login Kit\n        - Features: Video sync, engagement metrics (likes, views, shares), descriptions\n        - Use cases: Social media content analysis, creator discovery, trend monitoring\n        - Limitations: Access tokens expire in 24h (refresh_token flow); rate limits apply\n\n    RSS: RSS/Atom feed entries.\n        - Authentication: Optional HTTP headers (most feeds are public)\n        - Features: Entry-level sync with title, author, categories, content\n        - Use cases: News monitoring, blog ingestion, content aggregation\n        - Limitations: No pagination; feeds are fetched in full each poll\n\n    HTTP_API: Arbitrary REST/HTTP JSON APIs.\n        - Authentication: Optional HTTP headers (API keys, Bearer tokens, etc.)\n        - Features: Configurable JSONPath to items array, dedup via item ID field,\n          incremental sync via timestamp field, GET or POST methods, JSON or JSONL responses\n        - Use cases: Public APIs (Hacker News, GitHub), private APIs (Stripe, internal services),\n          any JSON endpoint that returns a list of items\n        - Limitations: No built-in pagination; API is fetched in full each poll\n\n    BOX: Box cloud content management and file sharing.\n        - Authentication: OAuth 2.0 (JWT or Client Credentials Grant with CCG)\n        - Features: Folder sync, enterprise content management, metadata, versioning\n        - Use cases: Enterprise document management, compliance archives, collaboration files\n        - Limitations: Rate limits apply (10 API calls per second per user)\n\n    BRIGHTDATA: BrightData web data platform for dataset collection and web scraping.\n        - Authentication: API token from BrightData dashboard\n        - Features: Pre-built datasets (LinkedIn, Amazon, etc.), custom scrapers,\n          scheduled collection, geo-targeting, output format selection\n        - Use cases: Competitor monitoring, market research, lead generation,\n          e-commerce pricing, social media data ingestion\n        - Limitations: Dataset availability depends on subscription; rate limits vary\n\n    BACKBLAZE: Backblaze B2 Cloud Storage (S3-compatible object storage).\n        - Authentication: Application key ID + application key from Backblaze console\n        - Features: S3-compatible API, auto-discovers regional endpoint via B2 auth,\n          full bucket/prefix sync, include/exclude patterns, modified_since filtering\n        - Use cases: Cold storage sync, media archives, backup ingestion\n        - Limitations: Buckets are region-specific; key must have listFiles/readFiles\n\n    MUX: Mux video infrastructure platform.\n        - Authentication: Access token ID + access token secret (HTTP Basic Auth)\n        - Features: Video asset listing, static rendition download (MP4), metadata sync\n        - Use cases: Video library ingestion, media asset processing, content analysis\n        - Limitations: Assets must be in 'ready' status; static renditions must be enabled\n\n    EMAIL: Inbound email connector (push-based).\n        - Authentication: Per-connection webhook signing secret (HMAC-SHA256)\n        - Features: MIME parsing, attachment extraction, sender allowlist, raw .eml archival\n        - Use cases: Document intake via email forwarding, compliance mailbox, support inbox\n        - Limitations: Requires external inbound email service (SES/Postmark/CloudMailin)\n\n    SUPABASE: Supabase Storage (S3-compatible object storage built on open source).\n        - Authentication: Dedicated S3 access keys (recommended) OR service_role JWT as\n          session token (access_key_id=project_ref, secret=anon_key, session_token=service_role)\n        - Features: S3-compatible API, per-project endpoint auto-derived from project_ref,\n          bucket-scoped sync, include/exclude patterns, modified_since incremental sync\n        - Use cases: Syncing user-uploaded assets from Supabase-backed apps, unified\n          search across Supabase Storage + other sources\n        - Limitations: Endpoint is project-specific (https://<ref>.storage.supabase.co);\n          S3 keys must be generated from the Supabase dashboard (Storage → S3 Access Keys)\n\n    GCS: Google Cloud Storage via the native google-cloud-storage SDK (service-account JSON).\n        - Authentication: Service account JSON key (from a service account granted the\n          Storage Object Viewer role on the target bucket)\n        - Features: Native GCS API (not the S3-compatible XML API), bucket + prefix sync,\n          include/exclude patterns, min/max size + mime_type filtering, modified_since\n          incremental sync, md5_hash change detection\n        - Use cases: Ingesting media/data-lake objects from GCS buckets, unified search\n          across GCS + other sources without minting HMAC interop keys\n        - Limitations: Requires a service account JSON key with read access to the bucket;\n          the key's private_key is a secret credential, redacted on read\n\n    AZURE_BLOB: Azure Blob Storage via the native azure-storage-blob SDK.\n        - Authentication: Storage account key (account_name + account_key) or Azure\n          managed identity (DefaultAzureCredential, optional client_id). Azure Blob has\n          no S3-compatible surface, so this native connector is the only path.\n        - Features: Native Blob API, container + prefix sync, include/exclude patterns,\n          min/max size + mime_type filtering, modified_since incremental sync, etag\n          change detection\n        - Use cases: Ingesting media/data-lake objects from Azure Blob containers,\n          unified search across Azure + other sources\n        - Limitations: For managed-identity auth the workload must run with an Azure\n          identity that has read access (Storage Blob Data Reader) on the container;\n          the account_key is a secret credential, redacted on read\n\n    RTSP: Live RTSP video streams (IP cameras, encoders, NVR re-streams).\n        - Authentication: none, or RTSP basic auth (username + password). Credentials\n          are held as separate fields rather than embedded in the URL, so the URL can\n          be logged and displayed without leaking them.\n        - Features: the stream is cut into fixed-length segments, each segment is one\n          object. A saved retriever configured on the bucket sync runs per segment and\n          its OUTPUTS are what land in the bucket, so an unchanging camera does not\n          pay extraction on every segment.\n        - Use cases: traffic and city cameras, site/security monitoring, broadcast\n          contribution feeds, any always-on camera whose interesting minutes are a\n          small fraction of its wall-clock hours.\n        - Limitations: capture is windowed, not gapless. Each sync poll opens the\n          stream, captures one window, and closes it, so footage between polls is not\n          retained. A gapless consumer is separate work; until it lands, treat an RTSP\n          connection as a sampler of the stream and not an archive of it."},"StorageStatistics":{"properties":{"total_size_bytes":{"type":"integer","title":"Total Size Bytes","description":"Total size of all objects/blobs in the bucket in bytes","default":0},"avg_size_bytes":{"type":"integer","title":"Avg Size Bytes","description":"Average object size in bytes","default":0},"max_size_bytes":{"type":"integer","title":"Max Size Bytes","description":"Size of the largest object in bytes","default":0},"min_size_bytes":{"type":"integer","title":"Min Size Bytes","description":"Size of the smallest object in bytes","default":0}},"type":"object","title":"StorageStatistics","description":"Statistics about object storage in a bucket."},"StoredTextReembedRequest":{"properties":{"outputs":{"items":{"type":"string","const":"transcription_embedding"},"type":"array","title":"Outputs","description":"The embedding outputs to recompute from stored text. `transcription_embedding` re-embeds each document's stored `transcription` into the multimodal_extractor v2 transcription index (requires a multimodal_extractor v2 collection with run_transcription_embedding enabled). Give `outputs` or `target_feature_uri`."},"target_feature_uri":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Feature Uri","description":"Re-embed each document's stored text with another embedding model, named by its feature URI: the collection's own URI with the new model's name as the output, for example `mixpeek://text_extractor@v1/all_minilm_l6_v2_v1` on a text_extractor v1 collection. The vectors are written under the new model's own index beside the existing ones, so searches keep answering from the current URI while this runs. When it completes the collection lists the new URI in `vector_indexes`, and setting `index_map` makes it answer searches. Give `outputs` or `target_feature_uri`.","examples":["mixpeek://text_extractor@v1/all_minilm_l6_v2_v1"]},"document_ids":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10000,"minItems":1},{"type":"null"}],"title":"Document Ids","description":"Limit the re-embed to these document ids. When omitted, every document in the collection is considered."},"only_missing":{"type":"boolean","title":"Only Missing","description":"Re-embed only documents that have text but no vector in the target index. Documents whose vector cannot be confirmed present are re-embedded, which is safe because the same text always produces the same vector. Set false to re-embed every document with text.","default":true},"dry_run":{"type":"boolean","title":"Dry Run","description":"Count what would be re-embedded without writing anything. The counts are recorded on the task (GET /v1/tasks/{task_id}).","default":false}},"type":"object","title":"StoredTextReembedRequest","description":"Re-embed stored document text into an existing vector index.\n\nRecomputes one text embedding output from the text the collection already\nstored on each document, and writes the vector back onto the same document.\nNothing else runs: no media download, no transcription, no other\nembeddings. Document ids, payload fields and every other vector are left as\nthey are."},"StructuredDataConfig":{"properties":{"type":{"type":"string","title":"Type","description":"Schema.org type for structured data","default":"WebApplication","examples":["WebApplication","SearchAction","WebPage","SoftwareApplication"]},"additional_properties":{"additionalProperties":true,"type":"object","title":"Additional Properties","description":"Additional Schema.org properties","examples":[{"applicationCategory":"Search","operatingSystem":"Web"},{"potentialAction":{"@type":"SearchAction","target":"{search_term}"}}]}},"type":"object","title":"StructuredDataConfig","description":"Schema.org structured data configuration for search engines.\n\nEnables rich search results and better understanding of the page content."},"SubmissionDetailResponse":{"properties":{"success":{"type":"boolean","title":"Success","default":true},"submission":{"additionalProperties":true,"type":"object","title":"Submission"}},"type":"object","required":["submission"],"title":"SubmissionDetailResponse"},"SubmissionListItem":{"properties":{"submission_id":{"type":"string","title":"Submission Id"},"extractor_name":{"type":"string","title":"Extractor Name"},"version":{"type":"string","title":"Version"},"description":{"type":"string","title":"Description","default":""},"status":{"type":"string","title":"Status"},"security_scan_passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Security Scan Passed"},"visibility":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Visibility"},"submitted_at":{"type":"string","format":"date-time","title":"Submitted At"},"reviewed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Reviewed At"}},"type":"object","required":["submission_id","extractor_name","version","status","submitted_at"],"title":"SubmissionListItem"},"SubmissionListResponse":{"properties":{"success":{"type":"boolean","title":"Success","default":true},"submissions":{"items":{"$ref":"#/components/schemas/SubmissionListItem"},"type":"array","title":"Submissions"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["submissions","total"],"title":"SubmissionListResponse"},"SubmissionParams":{"properties":{"entrypoint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entrypoint"},"deployment_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Deployment Mode","description":"'ray' (local/dev) or 'gke' (production)."},"requires_gpu":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Requires Gpu"},"num_cpus":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Num Cpus"},"num_gpus":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Num Gpus"},"memory_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Memory Bytes"},"priority":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Priority"},"plugin_archives":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Plugin Archives"},"plugin_dependencies":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Plugin Dependencies"},"image_uri":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Image Uri"},"extractor_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Extractor Name"},"extractor_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Extractor Version"},"env_vars_keys":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Env Vars Keys","description":"Environment variable keys (values omitted for security)."},"manifest_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Manifest Key","description":"S3 key of the batch manifest (metadata.json) used for this job. The manifest survives Ray cluster rebuilds, so the poller can resubmit an in-cluster (raysubmit_*) job killed by a redeploy."},"submitted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Submitted At"}},"type":"object","title":"SubmissionParams","description":"Parameters used when submitting a Ray/GKE job, persisted for post-hoc debugging."},"SubmissionPresignedURLResponse":{"properties":{"submission_id":{"type":"string","title":"Submission Id"},"presigned_url":{"type":"string","title":"Presigned Url"},"s3_key":{"type":"string","title":"S3 Key"},"required_content_type":{"type":"string","title":"Required Content Type","default":"application/zip"},"expires_at":{"type":"string","format":"date-time","title":"Expires At"},"name":{"type":"string","title":"Name"},"version":{"type":"string","title":"Version"}},"type":"object","required":["submission_id","presigned_url","s3_key","expires_at","name","version"],"title":"SubmissionPresignedURLResponse"},"SubmitBatchRequest":{"properties":{"include_processing_history":{"type":"boolean","title":"Include Processing History","description":"OPTIONAL (defaults to True). Controls whether processing operations are tracked in document internal_metadata.processing_history. When True: Each enrichment operation (taxonomy application, clustering, etc.) adds an audit trail entry. When False: Documents are enriched without processing history tracking, resulting in cleaner metadata. Use True for: Debugging, audit requirements, lineage tracking, understanding document transformations. Use False for: Production workloads where metadata size matters, simplified document structure. Processing history entries include: operation type, timestamp, and IDs of applied resources (taxonomies, clusters, etc.).","default":true,"examples":[true,false]},"collection_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Collection Ids","description":"DEPRECATED submit-time compatibility field. Collection scope is resolved when the batch is created via CreateBatchRequest.collection_ids. If provided at submit time, it must match the batch's tier-0 scope; otherwise submission fails closed instead of silently processing unexpected collections.","examples":[["col_text_only"],null]},"webhook_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Webhook Url","description":"OPTIONAL. URL to receive an HTTP POST notification when the batch reaches a terminal state (COMPLETED, FAILED, or CANCELED). The payload includes batch_id, status, failure_reason, documents_written, progress, and completed_at. The webhook is fire-and-forget: delivery failures are logged but do not affect batch processing. Must be an HTTPS or HTTP URL reachable from the server.","examples":["https://example.com/webhooks/batch-complete",null]}},"type":"object","title":"SubmitBatchRequest","description":"Request model for submitting a batch for processing.\n\nThis model allows configuration of processing behavior for the batch,\nsuch as whether to track processing history in document metadata.\n\nUse Cases:\n    - Submit batch with full audit trail (include_processing_history=True)\n    - Submit batch without processing history for cleaner metadata (include_processing_history=False)\n    - Default behavior includes processing history for debugging and lineage tracking\n\nRequirements:\n    - include_processing_history: OPTIONAL, defaults to True","examples":[{"description":"Submit batch with processing history (default)","include_processing_history":true},{"description":"Submit batch without processing history","include_processing_history":false},{"description":"Submit batch with webhook notification","webhook_url":"https://example.com/webhooks/batch-complete"},{"description":"Submit batch with default settings (includes processing history)"}]},"SubmitFeedbackRequest":{"properties":{"message_id":{"type":"string","title":"Message Id","description":"Assistant message ID (REQUIRED)"},"rating":{"type":"string","pattern":"^(positive|negative)$","title":"Rating","description":"Feedback rating: 'positive' or 'negative' (REQUIRED)"},"feedback_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Feedback Text","description":"Additional feedback text (OPTIONAL)"}},"type":"object","required":["message_id","rating"],"title":"SubmitFeedbackRequest","description":"Request payload for submitting feedback on a message.\n\nAttributes:\n    message_id: The assistant message ID to provide feedback for\n    rating: Feedback rating (positive or negative)\n    feedback_text: Optional additional feedback text\n\nExample:\n    ```python\n    request = SubmitFeedbackRequest(\n        message_id=\"msg_abc123\",\n        rating=\"positive\",\n        feedback_text=\"This was very helpful!\"\n    )\n    ```","examples":[{"feedback_text":"Great response!","message_id":"msg_abc123","rating":"positive"}]},"SubmitFeedbackResponse":{"properties":{"session_id":{"type":"string","title":"Session Id","description":"Session identifier"},"message_id":{"type":"string","title":"Message Id","description":"Message identifier"},"rating":{"type":"string","title":"Rating","description":"Feedback rating submitted"},"stored":{"type":"boolean","title":"Stored","description":"Whether exchange was stored to memory"},"recorded_at":{"type":"string","format":"date-time","title":"Recorded At","description":"Feedback timestamp"}},"type":"object","required":["session_id","message_id","rating","stored","recorded_at"],"title":"SubmitFeedbackResponse","description":"Response for feedback submission.\n\nAttributes:\n    session_id: Session identifier\n    message_id: Message that received feedback\n    rating: The feedback rating submitted\n    stored: Whether the exchange was stored to memory\n    recorded_at: Timestamp when feedback was recorded\n\nExample:\n    ```python\n    response = SubmitFeedbackResponse(\n        session_id=\"ses_abc123\",\n        message_id=\"msg_xyz789\",\n        rating=\"positive\",\n        stored=True,\n        recorded_at=current_time()\n    )\n    ```"},"SubscribeRequest":{"properties":{"plan":{"type":"string","title":"Plan","description":"Plan slug: managed_build, managed_scale, mvs_build, mvs_scale. The tier minimum is a billing floor — usage above it bills automatically at the plan's rates.","examples":["managed_build","mvs_scale"]},"success_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Success Url","description":"Redirect URL after successful subscription","default":"https://studio.mixpeek.com/billing?subscription=success"},"cancel_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cancel Url","description":"Redirect URL if subscription is cancelled","default":"https://studio.mixpeek.com/billing?subscription=cancelled"},"onboarding_answers":{"anyOf":[{"$ref":"#/components/schemas/OnboardingAnswers"},{"type":"null"}],"description":"Optional signup questions; each non-empty answer = $5 off the first invoice (max $10)."},"promo_code":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Promo Code","description":"Optional promo code to pre-apply at checkout. When combined with onboarding answers, the promo takes checkout's single discount slot and the onboarding credit lands on the customer balance."}},"type":"object","required":["plan"],"title":"SubscribeRequest","description":"Request to subscribe to a plan."},"SubscribeResponse":{"properties":{"checkout_url":{"type":"string","title":"Checkout Url","description":"Stripe Checkout URL for subscription","examples":["https://checkout.stripe.com/c/pay/cs_live_abc123"]},"session_id":{"type":"string","title":"Session Id","description":"Stripe Checkout Session ID (empty string for inline upgrades)","examples":["cs_live_abc123",""]}},"type":"object","required":["checkout_url","session_id"],"title":"SubscribeResponse","description":"Response with Stripe Checkout Session URL for subscription."},"SubscriptionStatus":{"type":"string","enum":["active","cancelled","expired","suspended","pending"],"title":"SubscriptionStatus","description":"Status of a marketplace subscription."},"SubscriptionStatusResponse":{"properties":{"has_subscription":{"type":"boolean","title":"Has Subscription","default":false},"subscription_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subscription Id"},"plan_slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Plan Slug"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"current_period_end":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Current Period End"},"cancel_at_period_end":{"type":"boolean","title":"Cancel At Period End","default":false}},"type":"object","title":"SubscriptionStatusResponse","description":"Current subscription status."},"SubscriptionTier":{"type":"string","enum":["free","basic","pro","enterprise"],"title":"SubscriptionTier","description":"Subscription tier levels for marketplace offerings."},"SubscriptionTierConfig":{"properties":{"tier":{"$ref":"#/components/schemas/SubscriptionTier","description":"Tier level"},"price_per_month":{"type":"number","minimum":0.0,"title":"Price Per Month","description":"Monthly price in USD (0.0 for free tier)","default":0.0},"limits":{"$ref":"#/components/schemas/TierLimits","description":"Rate limits and quotas for this tier"},"features":{"items":{"type":"string"},"type":"array","title":"Features","description":"List of features included in this tier"},"stripe_price_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stripe Price Id","description":"Stripe price ID for paid tiers"}},"type":"object","required":["tier"],"title":"SubscriptionTierConfig","description":"Configuration for a subscription tier."},"SuggestedConfigResponse":{"properties":{"exists":{"type":"boolean","title":"Exists","description":"Whether a suggestion record exists for this org."},"namespace_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Namespace Name","description":"Name of the suggested (and provisioned) namespace."},"rationale":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rationale","description":"One-sentence, user-facing reason this setup was suggested."},"manifest_applied":{"type":"boolean","title":"Manifest Applied","description":"True only if the suggested namespace was actually provisioned.","default":false},"applied_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Applied At"},"sample_queries":{"items":{"type":"string"},"type":"array","title":"Sample Queries"}},"type":"object","required":["exists"],"title":"SuggestedConfigResponse","description":"The org's signup-time suggested namespace, if one was provisioned.\n\nStudio uses this to badge the suggested namespace with a \"suggested from\nour research\" indicator. ``exists`` is False when the signup was skipped\n(personal domain, no enrichment signal, feature disabled) or the org\npredates the feature; ``manifest_applied`` is False when a suggestion was\ngenerated but provisioning failed — show no indicator in either case."},"SuggestedExtractor":{"properties":{"name":{"type":"string","title":"Name","description":"Feature extractor name (e.g. 'image_extractor')."},"version":{"type":"string","title":"Version","default":"v1"},"reason":{"type":"string","title":"Reason","description":"One-sentence explanation of why this extractor fits."}},"type":"object","required":["name","reason"],"title":"SuggestedExtractor"},"SuggestedStage":{"properties":{"stage_name":{"type":"string","title":"Stage Name"},"stage_type":{"type":"string","title":"Stage Type","default":"filter"},"description":{"type":"string","title":"Description"}},"type":"object","required":["stage_name","description"],"title":"SuggestedStage"},"SuitableCollection":{"properties":{"collection_id":{"type":"string","title":"Collection Id","description":"Collection ID"},"collection_name":{"type":"string","title":"Collection Name","description":"Collection name"},"feature_extractor":{"type":"string","title":"Feature Extractor","description":"Feature extractor name"},"capabilities":{"items":{"type":"string"},"type":"array","title":"Capabilities","description":"Collection capabilities"},"match_score":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Match Score","description":"Match confidence"}},"type":"object","required":["collection_id","collection_name","feature_extractor","match_score"],"title":"SuitableCollection","description":"Information about a collection that might fulfill the user's request.\n\nAttributes:\n    collection_id: Collection identifier\n    collection_name: Human-readable collection name\n    feature_extractor: Extractor used in this collection\n    capabilities: What this collection can do (e.g., \"video search\", \"face detection\")\n    match_score: How well this collection matches the request (0.0-1.0)"},"SupportActor":{"properties":{"user_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"}},"type":"object","title":"SupportActor","description":"Lightweight snapshot of who created a ticket/message."},"SupportAttachment":{"properties":{"filename":{"type":"string","title":"Filename"},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url"},"storage_uri":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Storage Uri"},"mime_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mime Type"},"size_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Size Bytes"}},"type":"object","required":["filename"],"title":"SupportAttachment"},"SupportAuthorType":{"type":"string","enum":["customer","mixpeek"],"title":"SupportAuthorType","description":"Who wrote a message — the customer or the Mixpeek team."},"SupportScope":{"type":"string","enum":["global","organization"],"title":"SupportScope"},"SupportTicketCategory":{"type":"string","enum":["technical","billing","feature","onboarding","other"],"title":"SupportTicketCategory"},"SupportTicketPriority":{"type":"string","enum":["low","medium","high","urgent"],"title":"SupportTicketPriority"},"SupportTicketStatus":{"type":"string","enum":["open","pending","resolved","closed"],"title":"SupportTicketStatus"},"SupportVideoAnalysisStatus":{"type":"string","enum":["pending","processing","completed","failed","skipped"],"title":"SupportVideoAnalysisStatus"},"SupportVideoChapter":{"properties":{"start_seconds":{"type":"number","minimum":0.0,"title":"Start Seconds"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"}},"type":"object","required":["start_seconds","title"],"title":"SupportVideoChapter","description":"A Gemini-generated chapter marker; the UI seeks to ``start_seconds``."},"SupportVideoSource":{"type":"string","enum":["upload","external"],"title":"SupportVideoSource"},"SyncComparisonResponse":{"properties":{"bucket_id":{"type":"string","title":"Bucket Id","description":"Bucket identifier"},"time_range":{"$ref":"#/components/schemas/api__analytics__buckets__models__TimeRange","description":"Query time range"},"configs":{"items":{"$ref":"#/components/schemas/SyncConfigMetric"},"type":"array","title":"Configs","description":"Metrics per sync config"}},"type":"object","required":["bucket_id","time_range","configs"],"title":"SyncComparisonResponse","description":"Sync configuration comparison response."},"SyncConfigMetric":{"properties":{"sync_config_id":{"type":"string","title":"Sync Config Id","description":"Sync config identifier"},"provider_type":{"type":"string","title":"Provider Type","description":"Provider type"},"avg_duration_seconds":{"type":"number","title":"Avg Duration Seconds","description":"Average sync duration"},"avg_throughput_mbps":{"type":"number","title":"Avg Throughput Mbps","description":"Average throughput"},"success_rate":{"type":"number","title":"Success Rate","description":"Success rate (0-1)"},"total_files_synced":{"type":"integer","title":"Total Files Synced","description":"Total files synced"},"total_bytes_synced":{"type":"integer","title":"Total Bytes Synced","description":"Total bytes synced"}},"type":"object","required":["sync_config_id","provider_type","avg_duration_seconds","avg_throughput_mbps","success_rate","total_files_synced","total_bytes_synced"],"title":"SyncConfigMetric","description":"Sync configuration comparison metrics."},"SyncConfigurationModel":{"properties":{"sync_config_id":{"type":"string","title":"Sync Config Id","description":"Unique identifier for the sync configuration."},"bucket_id":{"type":"string","title":"Bucket Id","description":"Target bucket identifier (e.g. 'bkt_marketing_assets')."},"connection_id":{"type":"string","title":"Connection Id","description":"Storage connection identifier (e.g. 'conn_abc123')."},"internal_id":{"type":"string","title":"Internal Id","description":"Organization internal identifier (multi-tenancy scope)."},"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace identifier owning the bucket."},"source_path":{"type":"string","title":"Source Path","description":"Source path in the external storage provider. Format varies by provider: s3/tigris='bucket/prefix', google_drive='folder_id', sharepoint='/sites/Name/Documents', snowflake='DB.SCHEMA.TABLE'."},"file_filters":{"anyOf":[{"$ref":"#/components/schemas/FileFilters"},{"type":"null"}],"description":"Optional filter rules limiting which files are synced."},"schema_mapping":{"anyOf":[{"$ref":"#/components/schemas/SchemaMapping-Output"},{"type":"null"}],"description":"Schema mapping defining how source data maps to bucket schema fields. Maps external storage attributes (tags, metadata, columns, filenames) to bucket schema fields and blob properties. When provided, enables structured extraction of metadata from the sync source. See SchemaMapping for detailed configuration options."},"sync_mode":{"$ref":"#/components/schemas/SyncMode","description":"Sync mode controlling lifecycle (initial_only or continuous).","default":"continuous"},"polling_interval_seconds":{"type":"integer","maximum":86400.0,"minimum":30.0,"title":"Polling Interval Seconds","description":"Polling interval in seconds (continuous mode). Up to 86400 (1 day) — slow intervals are a legitimate ops throttle (e.g. deliberately deprioritizing freshness lanes during a backfill), and the read model must accept any value the platform itself may have stored.","default":300},"batch_size":{"type":"integer","maximum":100.0,"minimum":1.0,"title":"Batch Size","description":"Number of files processed per sync batch.","default":50},"create_object_on_confirm":{"type":"boolean","title":"Create Object On Confirm","description":"Whether objects should be created immediately after confirmation.","default":true},"skip_duplicates":{"type":"boolean","title":"Skip Duplicates","description":"Skip files whose hashes already exist in the bucket.","default":true},"skip_batch_submission":{"type":"boolean","title":"Skip Batch Submission","description":"Sync-only mode: download and store files in the bucket without running them through the collection processing pipeline. Set to True during initial bulk ingestion, then flip to False to trigger processing once all files are synced.","default":false},"batch_collection_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Batch Collection Ids","description":"Collections this sync's auto-batch processes. None auto-discovers every enabled collection sourced from the bucket, which is the historical behaviour. Name a subset when a collection on the same bucket is fed some other way, for example a collection that only an alert's batch action writes to: without this the sync would process every synced object into it and the alert's selection would mean nothing."},"ingest_filter":{"anyOf":[{"$ref":"#/components/schemas/IngestFilter"},{"type":"null"}],"description":"A pinned saved retriever every candidate object this sync brings in runs through before it is committed. Wins over the bucket's own ingest_filter. None falls back to the bucket's."},"reconcile":{"$ref":"#/components/schemas/ReconcileSettings","description":"Controls how Mixpeek reconciles objects when the source changes. on_delete: cascade-delete when source asset is removed. on_update: propagate metadata changes and re-process. on_filter_drift: remove objects that no longer match filters. All default to True for full consistency."},"status":{"$ref":"#/components/schemas/TaskStatusEnum","description":"Current lifecycle status for the sync configuration. PENDING: Not yet started. ACTIVE: Currently running/polling. SUSPENDED: Temporarily paused. COMPLETED: Initial sync completed (for initial_only mode). FAILED: Sync encountered errors.","default":"PENDING"},"is_active":{"type":"boolean","title":"Is Active","description":"Convenience flag used for filtering active syncs.","default":true},"total_files_discovered":{"type":"integer","minimum":0.0,"title":"Total Files Discovered","description":"Cumulative count of files found in source across all runs.","default":0},"total_files_synced":{"type":"integer","minimum":0.0,"title":"Total Files Synced","description":"Cumulative count of successfully synced files.","default":0},"total_files_failed":{"type":"integer","minimum":0.0,"title":"Total Files Failed","description":"Cumulative count of failed files (sent to DLQ after 3 retries).","default":0},"total_bytes_synced":{"type":"integer","minimum":0.0,"title":"Total Bytes Synced","description":"Cumulative bytes transferred across all runs.","default":0},"stats":{"anyOf":[{"$ref":"#/components/schemas/SyncStatsModel"},{"type":"null"}],"description":"Throughput and volume metrics aggregated by the sync pipeline on every run: cumulative totals, the peak object rate, and a full breakdown of the most recent run. Present once a run has completed."},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"When sync configuration was created."},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last modification timestamp."},"last_sync_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Sync At","description":"When last successful sync completed. Used for incremental syncs."},"per_shard_last_sync_at":{"additionalProperties":{"type":"string","format":"date-time"},"type":"object","title":"Per Shard Last Sync At","description":"Per-shard last-sync timestamps keyed by shard value (e.g. collection_id). When a new shard is added, its absence here forces a full scan even if the global last_sync_at is set."},"next_sync_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Next Sync At","description":"Scheduled time for next sync (continuous/scheduled modes)."},"created_by_user_id":{"type":"string","title":"Created By User Id","description":"User identifier that created the sync configuration."},"last_error":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Last Error","description":"Most recent error message if sync attempts failed."},"consecutive_failures":{"type":"integer","minimum":0.0,"title":"Consecutive Failures","default":0},"provider_filters":{"additionalProperties":true,"type":"object","title":"Provider Filters","description":"Provider-specific pre-filters pushed down to the API call. The sync engine passes these to iter_objects() without interpretation. Each provider defines its own schema. Applied BEFORE file_filters. Examples: Iconik {'collection_ids': [...]}, Google Drive {'shared_drive_id': '...'}"},"source_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Type","description":"Storage provider type for API progress views (for example: s3, google_drive, iconik)."},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Arbitrary metadata supplied by the user."},"locked_by_worker_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Locked By Worker Id","description":"Worker ID that currently holds the lock for this sync"},"locked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Locked At","description":"Timestamp when lock was acquired"},"lock_expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lock Expires At","description":"Timestamp when lock expires (for stale lock recovery)"},"pending_full_sync":{"type":"boolean","title":"Pending Full Sync","description":"A full sweep was requested (trigger?full_sync=true) while a run held the lock. The finishing run dispatches it automatically on lock release.","default":false},"paused":{"type":"boolean","title":"Paused","description":"Whether sync is currently paused (user-controlled)","default":false},"pause_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pause Reason","description":"Reason for pause"},"paused_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Paused At","description":"Timestamp when paused"},"paused_by_user_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Paused By User Id","description":"User who paused the sync"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Sync configuration description"},"max_objects_per_run":{"type":"integer","minimum":1.0,"title":"Max Objects Per Run","description":"Hard cap on objects per sync run (prevents runaway syncs)","default":100000},"max_batch_chunk_size":{"type":"integer","maximum":1000.0,"minimum":1.0,"title":"Max Batch Chunk Size","description":"Maximum objects per batch chunk","default":1000},"batch_chunk_size":{"type":"integer","maximum":1000.0,"minimum":1.0,"title":"Batch Chunk Size","description":"Number of objects per batch chunk (for concurrent processing)","default":100},"sync_concurrency":{"anyOf":[{"type":"integer","maximum":100.0,"minimum":1.0},{"type":"null"}],"title":"Sync Concurrency","description":"Per-sync override for concurrent object processing during a sync run. OPTIONAL. When unset, falls back to the SYNC_OBJECT_CONCURRENCY worker env default (8)."},"current_sync_run_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Sync Run Id","description":"UUID for current/last sync run"},"sync_run_counter":{"type":"integer","minimum":0.0,"title":"Sync Run Counter","description":"Increments on each sync execution","default":0},"batch_ids":{"items":{"type":"string"},"type":"array","title":"Batch Ids","description":"List of batch IDs created by this sync"},"task_ids":{"items":{"type":"string"},"type":"array","title":"Task Ids","description":"List of task IDs for batches"},"batches_created":{"type":"integer","minimum":0.0,"title":"Batches Created","description":"Total number of batches created","default":0},"resume_enabled":{"type":"boolean","title":"Resume Enabled","description":"Whether resuming partial runs is enabled","default":true},"resume_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resume Cursor","description":"Last page/cursor processed (for paginated APIs like Google Drive)"},"resume_last_primary_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resume Last Primary Key","description":"Last primary key processed (for database syncs with stable ordering)"},"resume_objects_processed":{"type":"integer","minimum":0.0,"title":"Resume Objects Processed","description":"Count of objects processed in current/last run","default":0},"resume_checkpoint_frequency":{"type":"integer","maximum":10000.0,"minimum":100.0,"title":"Resume Checkpoint Frequency","description":"How often to checkpoint (in objects). Default: every 1000 objects","default":1000},"current_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Cursor","description":"Convenience mirror of the current resume cursor for API progress views."},"sync_checkpoints":{"additionalProperties":{"additionalProperties":true,"type":"object"},"type":"object","title":"Sync Checkpoints","description":"Per-(config, shard) high-water checkpoints keyed by shard key (e.g. collection_id for parallel fan-outs, 'pages_N_M' for page-range shards, '__default__' for unsharded runs). Each entry holds: pass_id (lexicographically-ordered pass marker), cursor (provider cursor, e.g. JSON-encoded Iconik search_after), objects_processed (forward-only progress guard), modified_since (incremental filter frozen at pass start), completed_at (set when the shard drained its source — the next cycle wraps around to a fresh full pass only after the polling cadence elapses), and updated_at. A NEW job resumes each shard from its checkpoint instead of re-walking from page 1 (2026-06-11 re-scan treadmill)."},"schedule":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Schedule","description":"Derived scheduling summary: mode, interval, next run, and last successful run."},"sync_progress":{"additionalProperties":true,"type":"object","title":"Sync Progress","description":"Derived progress summary for API observability."},"locked":{"type":"boolean","title":"Locked","description":"Whether a worker currently holds this sync's run lock.","readOnly":true}},"type":"object","required":["bucket_id","connection_id","internal_id","namespace_id","source_path","created_by_user_id","locked"],"title":"SyncConfigurationModel","description":"Bucket-scoped configuration for automated storage synchronization.\n\nDefines how files are synced from external storage providers to a Mixpeek bucket.\nIncludes configuration, status, metrics, and robustness control fields.\n\n**Supported Providers:** google_drive, s3, snowflake, sharepoint, tigris\n\n**Built-in Robustness:**\n- Distributed locking (locked_by_worker_id, lock_expires_at)\n- Pause/resume control (paused, pause_reason, paused_at)\n- Safety limits (max_objects_per_run, batch_chunk_size)\n- Resume checkpointing (resume_cursor, resume_objects_processed)\n- Batch tracking (batch_ids, task_ids, batches_created)\n\n**Metrics Fields:**\n- total_files_discovered: Files found in source\n- total_files_synced: Successfully synced files\n- total_files_failed: Files that failed (check DLQ)\n- total_bytes_synced: Total data transferred\n- consecutive_failures: Failure count for auto-suspend"},"SyncCreateRequest":{"properties":{"connection_id":{"type":"string","title":"Connection Id","description":"REQUIRED. Storage connection identifier to sync from. Must reference an existing connection created via POST /organizations/connections. The connection defines the storage provider and credentials. Supported providers: google_drive, s3, snowflake, sharepoint, tigris.","examples":["conn_abc123","conn_s3_prod"]},"source_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Path","description":"REQUIRED unless provider_filters.use_search_api is true (search-API syncs don't traverse a path; defaults to '/'). Source path within the storage provider to monitor and sync. Path format varies by provider: - s3/tigris: 'bucket-name/prefix' or 'bucket-name'. - google_drive: folder ID or path like '/Marketing/Assets'. - sharepoint: '/sites/SiteName/Shared Documents/folder'. - snowflake: 'DATABASE.SCHEMA.TABLE' or just 'TABLE' if defaults set.","examples":["my-bucket/videos","0AH-Xabc123","PROD.PUBLIC.CUSTOMERS"]},"sync_mode":{"$ref":"#/components/schemas/SyncMode","description":"Synchronization mode determining how files are monitored and ingested. OPTIONAL. Defaults to 'continuous'. 'continuous': keeps watching the source. Set polling_interval_seconds to make it periodic rather than immediate; a recurring or 'scheduled' import is this mode. 'initial_only': syncs the files already present once, then stops.","default":"continuous","examples":["continuous","initial_only"]},"file_filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"File Filters","description":"OPTIONAL. Filters to control which files are synced. When omitted, all files in source_path are synced. Supported filters: - include_patterns: Glob patterns to include (e.g., ['*.mp4', '*.mov']). - exclude_patterns: Glob patterns to exclude (e.g., ['*.tmp', '.DS_Store']). A pattern without '/' matches the file name in any folder; a pattern with '/' matches the path from the sync's source root. - extensions: File extensions to include (e.g., ['.mp4', '.jpg']). - min_size_bytes: Minimum file size in bytes. - max_size_bytes: Maximum file size in bytes. - modified_after: ISO datetime, only sync files modified after this time. - mime_types: List of MIME types to include (e.g., ['video/*', 'image/jpeg']).","examples":[{"extensions":[".mp4",".mov"]},{"include_patterns":["*.jpg","*.png"],"min_size_bytes":1024},{"exclude_patterns":["*.tmp","thumbs/*"],"max_size_bytes":52428800},{"mime_types":["video/*"],"modified_after":"2024-01-01T00:00:00Z"}]},"schema_mapping":{"anyOf":[{"$ref":"#/components/schemas/SchemaMapping-Input"},{"type":"null"}],"description":"OPTIONAL. Defines how source data maps to bucket schema fields and blobs. When provided, enables structured extraction of metadata from the sync source. Keys are target bucket schema field names, values define the source extraction method. \n\n**Blob Mappings** (target_type='blob'): Map files or URLs to blob fields. Use source.type='file' for the synced file itself, or source.type='column'/'metadata' for URLs. \n\n**Field Mappings** (target_type='field'): Map metadata to schema fields. Source options by provider: - S3/Tigris: 'tag' (object tags), 'metadata' (x-amz-meta-*) - Snowflake: 'column' (table columns) - Google Drive: 'drive_property' (file properties) - All: 'filename_regex', 'folder_path', 'constant' \n\nIf omitted, default behavior depends on provider - typically maps file to 'content' blob.","examples":[{"mappings":{"category":{"source":{"key":"category","type":"tag"},"target_type":"field"},"content":{"blob_type":"auto","source":{"type":"file"},"target_type":"blob"}}},{"mappings":{"content":{"blob_type":"video","source":{"type":"file"},"target_type":"blob"},"project":{"source":{"segment":0,"type":"folder_path"},"target_type":"field","transform":"lowercase"}}}]},"polling_interval_seconds":{"type":"integer","maximum":86400.0,"minimum":30.0,"title":"Polling Interval Seconds","description":"Interval in seconds between polling checks for new files. OPTIONAL. Defaults to 300 seconds (5 minutes). Must be between 30 and 86400 seconds (0.5 minutes to 1 day). Only applies to the 'continuous' sync mode. Lower values mean faster detection but higher API usage.","default":300,"examples":[60,300,600]},"batch_size":{"type":"integer","maximum":100.0,"minimum":1.0,"title":"Batch Size","description":"Number of files to process in each batch during sync. OPTIONAL. Defaults to 50 files per batch. Must be between 1 and 100. Larger batches improve throughput but require more memory. Smaller batches provide more granular progress tracking.","default":50,"examples":[10,50,100]},"skip_batch_submission":{"type":"boolean","title":"Skip Batch Submission","description":"If True, sync objects to the bucket without creating or submitting batches for collection processing. Objects are created in the bucket but no tier processing is triggered. Useful for bulk data migration or when you want to manually control when processing occurs. While True, nothing this sync ingests is processed or searchable: objects keep arriving and no batch is ever created. OPTIONAL. Defaults to False (batches are created and submitted).","default":false,"examples":[false,true]},"batch_collection_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Batch Collection Ids","description":"Collections this sync's auto-batch processes, by id or name. OPTIONAL. When omitted, every enabled collection sourced from the bucket is auto-discovered, which is the default behaviour. Name a subset when another collection on the same bucket is fed some other way, for example one that only an alert's batch action writes to: without this the sync processes every synced object into it and the alert's selection stops meaning anything. Ignored when skip_batch_submission is True.","examples":[["col_chunks_abc","col_frames_xyz"],["segments-index"]]},"ingest_filter":{"anyOf":[{"$ref":"#/components/schemas/IngestFilter"},{"type":"null"}],"description":"A pinned saved retriever every candidate object this sync brings in runs through before it is committed. action keep commits only what the retriever returns something for, drop commits only what it returns nothing for, tag commits everything with the verdict. Kept objects carry the filter's record (execution id included) in their ingest_filter field; dropped ones are never stored and are counted on the sync job by reason. OPTIONAL. Omit retriever_version to pin the retriever's current version. When omitted, the bucket's own ingest_filter applies, if it has one."},"skip_duplicates":{"type":"boolean","title":"Skip Duplicates","description":"If True, skip files whose source ID already exists in the bucket. If False, replace existing objects when re-syncing. OPTIONAL. Defaults to True.","default":true,"examples":[true,false]},"reconcile":{"anyOf":[{"$ref":"#/components/schemas/ReconcileSettings"},{"type":"null"}],"description":"Controls how Mixpeek reconciles objects when the source changes. on_delete: cascade-delete when source asset is removed (default True). on_update: propagate metadata changes and re-process (default True). on_filter_drift: remove objects that no longer match filters (default True). OPTIONAL. Defaults to all enabled for full consistency.","examples":[{"on_delete":true,"on_filter_drift":true,"on_update":true},{"on_delete":true,"on_filter_drift":false,"on_update":false}]},"sync_from":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Sync From","description":"OPTIONAL. Seed the incremental watermark: only assets modified after this timestamp are ingested — the historical backlog is skipped. Use for a 'freshness lane': a second config on an already-backfilling source (with a distinct source_path label) that keeps NEW uploads landing within minutes while the backfill config churns. Omit for a full sync from the beginning.","examples":["2026-07-07T00:00:00Z"]},"provider_filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Provider Filters","description":"OPTIONAL. Provider-specific pre-filters pushed down to the storage API call. Applied BEFORE file_filters (which are client-side). Each provider defines its own filter schema. Examples: - Iconik: {'collection_ids': ['col_abc']} - Google Drive: {'shared_drive_id': '0AH-Xabc123'} - S3: {'prefix': 'videos/'}","examples":[{"collection_ids":["col_abc","col_def"]},{"shared_drive_id":"0AH-Xabc123"}]},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"OPTIONAL description of this sync configuration. PATCH accepted it before create did."},"max_objects_per_run":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Max Objects Per Run","description":"OPTIONAL hard cap on objects processed per sync run (default 100000). PATCH accepted it before create did."},"sync_concurrency":{"anyOf":[{"type":"integer","maximum":100.0,"minimum":1.0},{"type":"null"}],"title":"Sync Concurrency","description":"OPTIONAL per-sync override for concurrent object processing. Must be between 1 and 100 if provided. Defaults to the SYNC_OBJECT_CONCURRENCY worker env (8) when unset.","examples":[1,4,8]},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Optional custom metadata to attach to the sync configuration. NOT REQUIRED. Arbitrary key-value pairs for tagging and organization. Common uses: project tags, environment labels, cost centers. Maximum 50 keys, values must be JSON-serializable.","examples":[{"environment":"production","project":"video-pipeline"},{"cost_center":"marketing","owner":"data-team"}]}},"additionalProperties":false,"type":"object","required":["connection_id"],"title":"SyncCreateRequest","description":"Request to create a bucket sync configuration.\n\nEstablishes automated synchronization between a storage connection and a bucket.\nThe sync monitors the source path for changes and ingests files according to\nthe specified mode and filters.\n\nSupported Storage Providers:\n    - google_drive: Google Drive and Workspace shared drives\n    - s3: Amazon S3 and S3-compatible (MinIO, DigitalOcean Spaces, Wasabi)\n    - snowflake: Snowflake data warehouse tables (rows become objects)\n    - sharepoint: Microsoft SharePoint and OneDrive for Business\n    - tigris: Tigris globally distributed object storage\n\nRobustness Features (built-in):\n    - Dead Letter Queue (DLQ): Failed objects tracked with 3 retries before quarantine\n    - Idempotent ingestion: Deduplication via (bucket_id, source_provider, source_object_id)\n    - Distributed locking: Prevents concurrent execution of same sync config\n    - Rate limit handling: Automatic backoff on provider 429 responses\n    - Metrics: Duration, files synced/failed, batches created, rate limit hits\n\nSync Modes (SyncMode has exactly two members):\n    - continuous: Keeps monitoring the source; polling_interval_seconds is\n      what makes it periodic, so recurring/scheduled imports are this mode\n    - initial_only: Single import of what is already there, then stops\n\nRequirements:\n    - connection_id: REQUIRED, must be an existing connection\n    - source_path: REQUIRED, path must exist in the storage provider\n    - sync_mode: OPTIONAL, defaults to 'continuous'\n    - All other fields are OPTIONAL with sensible defaults","examples":[{"batch_size":50,"connection_id":"conn_s3_prod","file_filters":{"extensions":[".mp4",".mov"],"min_size_bytes":1024},"metadata":{"project":"video-analysis"},"polling_interval_seconds":300,"source_path":"media-bucket/videos/raw","sync_mode":"continuous"},{"batch_size":100,"connection_id":"conn_gdrive_marketing","file_filters":{"mime_types":["image/*","video/*"]},"source_path":"0AH-Xabc123def456","sync_mode":"initial_only"},{"batch_size":100,"connection_id":"conn_snowflake_prod","metadata":{"incremental":true},"polling_interval_seconds":900,"source_path":"ANALYTICS.PUBLIC.CUSTOMERS","sync_mode":"continuous"},{"connection_id":"conn_sharepoint_legal","file_filters":{"extensions":[".pdf",".docx"]},"polling_interval_seconds":600,"source_path":"/sites/Legal/Shared Documents/Contracts","sync_mode":"continuous"},{"batch_size":100,"connection_id":"conn_tigris_cdn","file_filters":{"include_patterns":["*.jpg","*.webp"]},"source_path":"cdn-assets/media","sync_mode":"continuous"}]},"SyncDeadLetterObjectModel":{"properties":{"dlq_id":{"type":"string","title":"Dlq Id","description":"Unique identifier for the DLQ entry"},"sync_config_id":{"type":"string","title":"Sync Config Id","description":"ID of the sync configuration that failed"},"sync_job_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sync Job Id","description":"ID of the sync job where failure occurred"},"source_object_id":{"type":"string","title":"Source Object Id","description":"Provider's native ID for the failed object"},"source_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Path","description":"Path to the object in the source system"},"error_type":{"type":"string","title":"Error Type","description":"Type of error (validation_error, download_failed, schema_mismatch)"},"error_message":{"type":"string","title":"Error Message","description":"Human-readable error message"},"error_stack_trace":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Stack Trace","description":"Full stack trace for debugging"},"first_seen_at":{"type":"string","format":"date-time","title":"First Seen At","description":"When object first failed"},"last_seen_at":{"type":"string","format":"date-time","title":"Last Seen At","description":"When the object last failed BEFORE quarantine. once max_retries_reached is set this stops being refreshed by the sweep's healing re-attempts (those stamp last_reattempt_at instead), so it freezes at the moment of quarantine and drives the 7-day disposal clock (_dispose_stale_dlq_entries)"},"last_reattempt_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Reattempt At","description":"Timestamp of the most recent post-quarantine healing re-attempt. Separate from last_seen_at so the back-off timer (how long to wait before re-attempting a quarantined object) and the disposal clock (how long since quarantine) do not share one field — sharing it let the once/24h re-attempt reset the disposal clock forever, so a permanently-failing object was never retired"},"retry_count":{"type":"integer","minimum":0.0,"title":"Retry Count","description":"Number of retry attempts","default":0},"max_retries_reached":{"type":"boolean","title":"Max Retries Reached","description":"Whether max retries have been exhausted","default":false},"requeued_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Requeued At","description":"When user manually requeued this object"},"resolved_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Resolved At","description":"When object was successfully processed after requeue"},"disposal_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Disposal Reason","description":"Why the retry task permanently retired this entry (sync_config_not_found, sync_config_deactivated, connection_not_found) — set alongside max_retries_reached so stale entries stop being re-walked every run"},"internal_id":{"type":"string","title":"Internal Id","description":"Organization internal identifier (multi-tenancy scope)"},"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace identifier"},"bucket_id":{"type":"string","title":"Bucket Id","description":"Target bucket identifier"}},"type":"object","required":["sync_config_id","source_object_id","error_type","error_message","internal_id","namespace_id","bucket_id"],"title":"SyncDeadLetterObjectModel","description":"Objects that failed sync after all retries.\n\nThis model tracks objects that permanently failed during sync operations.\nAfter MAX_RETRIES attempts, objects are placed here for manual review/requeue."},"SyncHealthMetric":{"properties":{"sync_config_id":{"type":"string","title":"Sync Config Id","description":"Sync config identifier"},"consecutive_failures":{"type":"integer","title":"Consecutive Failures","description":"Consecutive failure count"},"last_success_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Success At","description":"Last successful sync"},"last_failure_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Failure At","description":"Last failed sync"},"failure_rate":{"type":"number","title":"Failure Rate","description":"Failure rate (0-1)"}},"type":"object","required":["sync_config_id","consecutive_failures","failure_rate"],"title":"SyncHealthMetric","description":"Sync health metrics per config."},"SyncJobListResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/SyncJobModel"},"type":"array","title":"Results"},"pagination":{"$ref":"#/components/schemas/PaginationResponse"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["results","pagination","total"],"title":"SyncJobListResponse","description":"Paginated list of sync jobs."},"SyncJobModel":{"properties":{"sync_job_id":{"type":"string","title":"Sync Job Id","description":"Unique identifier for the sync job."},"sync_config_id":{"type":"string","title":"Sync Config Id","description":"Identifier of the sync configuration that spawned this job."},"internal_id":{"type":"string","title":"Internal Id","description":"Organization scope identifier."},"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace scope identifier."},"status":{"$ref":"#/components/schemas/SyncJobStatus","description":"Current status of the sync job.","default":"running"},"trigger":{"anyOf":[{"$ref":"#/components/schemas/SyncJobTrigger"},{"type":"null"}],"description":"What started this job: scheduled (the polling loop), manual (a person, through the trigger endpoint), or resume (continuation of a sliced run). None on records written before this field shipped, which means 'not recorded' and NOT 'unknown trigger' — those jobs carry the free-form metadata.triggered_by string instead."},"phase":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phase","description":"Human-readable phase within a RUNNING job for observability (e.g. 'queued' until a worker starts the job, then 'discovering', 'downloading', 'verifying', 're-verifying', 'idle'). Optional and descriptive — distinct from `status`, which is the coarse lifecycle state. Lets a sync that is re-verifying already-synced files (low net-new throughput, low percent) read as healthy rather than stuck. Back-compatible: older jobs have None."},"total_files":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Total Files","description":"Total files expected for this sync run."},"files_synced":{"type":"integer","minimum":0.0,"title":"Files Synced","description":"Number of files synced successfully in this job.","default":0},"files_failed":{"type":"integer","minimum":0.0,"title":"Files Failed","description":"Number of files that failed to sync in this job.","default":0},"files_verified":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Files Verified","description":"OPTIONAL. Files the run re-checked and found already present, as opposed to newly transferred. A re-scan of a settled source is mostly this, so a run with files_synced=0 and files_verified>0 did work and found nothing new, which is a different state from a run that did nothing."},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At","description":"Execution start of the CURRENT attempt, stamped at the RUNNING transition. None = not yet started (queued/pre-dispatch). Legacy rows (no metadata.started_at_source) hold a record-construction time instead — not execution evidence."},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"Timestamp when the job completed."},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"Last progress update timestamp for this job."},"error":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Error","description":"Last error encountered during the job."},"resumed_via":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resumed Via","description":"Set when this job record was reopened and re-run after its worker died without finalizing (value 'acks_late_redelivery': the broker redelivered the original message against the reaped record). On rows that predate per-attempt history (metadata.prior_attempts), this is the only retry signal; its absence proves nothing about whether a job retried."},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Optional metadata captured during execution (provider stats, cursors, etc.)."},"progress_percent":{"anyOf":[{"type":"number","maximum":100.0,"minimum":0.0},{"type":"null"}],"title":"Progress Percent","description":"Percent complete: files with an outcome (synced, failed, re-verified, unchanged or quarantined) / total_files when the total is known (total_files, or metadata.total_files_discovered on rows written before total_files was stored); otherwise 100 for a completed or skipped run and 0 for a run that has counted no file yet. Null only for a row with files counted and no total, which no current writer produces: every count write carries the total."},"throughput_files_per_min":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Throughput Files Per Min","description":"Derived successful-file throughput for the job."},"lag_seconds":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Lag Seconds","description":"Seconds since the latest progress update for running jobs."},"current_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Cursor","description":"Latest provider cursor/page token captured for this job."},"progress":{"additionalProperties":true,"type":"object","title":"Progress","description":"Derived progress summary for API observability."}},"type":"object","required":["sync_config_id","internal_id","namespace_id"],"title":"SyncJobModel","description":"Execution record for a single storage sync run.\n\nCreated when a sync is triggered (manually or by scheduler).\nTracks progress, metrics, and errors for the sync execution.\n\n**Job Lifecycle:** records are BORN status=RUNNING (pre-dispatch, before\nthe lock attempt) → COMPLETED/FAILED/INTERRUPTED. started_at=None marks\nthe born-but-not-yet-executing window; there is no PENDING status.\n\n**Tracked Metrics:**\n- files_synced: Successfully created objects\n- files_failed: Objects sent to Dead Letter Queue\n- started_at/completed_at: Timing for duration calculation.\n  started_at is the CURRENT ATTEMPT's execution start, stamped at the\n  RUNNING transition (mark_sync_job_running) — None while queued. The\n  document's provider-level created_at is record creation, so\n  created_at→started_at is record-creation-to-execution-start (dispatch\n  + admission + pre-RUNNING setup), NOT queue time alone. Rows written\n  before this stamping existed (no metadata.started_at_source) carry a\n  construction time here; their execution duration is unknown, not\n  measured."},"SyncJobStatus":{"type":"string","enum":["running","completed","failed","interrupted","skipped"],"title":"SyncJobStatus","description":"Lifecycle states for individual storage sync jobs."},"SyncJobTrigger":{"type":"string","enum":["scheduled","manual","resume"],"title":"SyncJobTrigger","description":"What started a sync job.\n\nThe job record already carried this as a free-form ``metadata.triggered_by``\nstring, which is fine for a log line and unusable as a query: a caller\nasking \"has this sync completed a SCHEDULED run since the user connected it\"\nhad to match on prose. Those strings STAY, because\n``reap_stale_running_jobs`` matches on ``triggered_by == \"queued_full_sync\"``\nto restore ``pending_full_sync``; this enum is additive beside them.\n\nTHERE IS DELIBERATELY NO ``api`` MEMBER. The trigger endpoint reads\n``request.state.auth.user.user_id`` unconditionally, so a key-only caller is\nnot distinguishable from a person there, and a member nothing can emit is a\ndead field that reads as a real one. Add it when the endpoint can tell the\ntwo apart."},"SyncListResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/SyncConfigurationModel"},"type":"array","title":"Results","description":"List of sync configurations matching the query filters. ALWAYS PRESENT. May be empty if no configurations match. Each item is a complete SyncConfigurationModel. Ordered by creation date (newest first)."},"pagination":{"$ref":"#/components/schemas/PaginationResponse","description":"Pagination metadata for navigating result sets. ALWAYS PRESENT. Contains next/previous links, current page info. Use the provided links for cursor-based pagination."},"total":{"type":"integer","title":"Total","description":"Total number of sync configurations matching the filters. ALWAYS PRESENT. Useful for progress indicators and UI display. Note: This is the total across all pages, not just current page.","examples":[0,5,42]}},"type":"object","required":["results","pagination","total"],"title":"SyncListResponse","description":"Response containing a list of sync configurations with pagination.\n\nWraps the list of sync configurations with pagination metadata\nto support efficient browsing of large result sets.\n\nResponse Structure:\n    - results: The actual sync configuration objects\n    - pagination: Links and metadata for navigation\n    - total: Total count for client-side progress indicators","examples":[{"description":"Empty result set","pagination":{"limit":10,"offset":0},"results":[],"total":0},{"description":"Single page with results","pagination":{"limit":10,"offset":0},"results":[{"bucket_id":"bucket_xyz","connection_id":"conn_s3_prod","is_active":true,"source_path":"videos/raw","status":"processing","sync_config_id":"sync_abc123","sync_mode":"continuous"}],"total":1}]},"SyncMetricsResponse":{"properties":{"sync_config_id":{"type":"string","title":"Sync Config Id"},"status":{"type":"string","title":"Status","description":"Sync config status (e.g. ACTIVE)."},"is_active":{"type":"boolean","title":"Is Active"},"paused":{"type":"boolean","title":"Paused","default":false},"total_files_discovered":{"type":"integer","title":"Total Files Discovered","default":0},"total_files_synced":{"type":"integer","title":"Total Files Synced","default":0},"total_files_failed":{"type":"integer","title":"Total Files Failed","default":0},"batches_created":{"type":"integer","title":"Batches Created","default":0},"sync_run_counter":{"type":"integer","title":"Sync Run Counter","default":0},"consecutive_failures":{"type":"integer","title":"Consecutive Failures","default":0},"last_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Error"},"last_sync_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Sync At"},"next_sync_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Next Sync At"},"seconds_since_last_sync":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Seconds Since Last Sync","description":"Age of last successful sync; None if never synced."},"is_stale":{"type":"boolean","title":"Is Stale","description":"True when a continuous sync has not progressed for more than TWO of its own polling intervals. Previously the bar was three intervals OR 600 seconds, whichever was larger, so a one-minute sync could miss ten consecutive runs and still read healthy while an hourly one got three. Read it beside intervals_since_last_sync and stale_after_seconds rather than on its own.","default":false},"intervals_since_last_sync":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Intervals Since Last Sync","description":"How overdue the sync is, measured in its OWN polling intervals: seconds_since_last_sync / polling_interval_seconds. 1.0 means one interval has elapsed, which is normal for a sync about to run. None when the sync has never run. Present so a caller can judge lateness without knowing where the threshold happens to sit.","examples":[0.4,1.0,3.15]},"stale_after_seconds":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Stale After Seconds","description":"The threshold is_stale was evaluated against, in seconds, so the verdict can be checked rather than trusted. max(2 * polling_interval_seconds, 120).","examples":[600,120,7200]},"failure_rate":{"type":"number","title":"Failure Rate","description":"total_files_failed / total_files_discovered (0..1).","default":0.0},"healthy":{"type":"boolean","title":"Healthy","description":"Composite: active, not paused, no consecutive failures, not stale, running job not stalled. Because it folds in is_stale, a sync more than two intervals overdue reports healthy=false rather than true.","default":true},"dlq_total":{"type":"integer","title":"Dlq Total","description":"Objects stuck after all retries.","default":0},"dlq_by_error":{"additionalProperties":{"type":"integer"},"type":"object","title":"Dlq By Error","description":"DLQ counts grouped by normalized error reason (IDs stripped)."},"running_job":{"type":"boolean","title":"Running Job","default":false},"stalled":{"type":"boolean","title":"Stalled","description":"The running job has made no progress: no heartbeat, or nothing discovered or synced, for longer than max(stale_after_seconds, 300). A first run that has not finished yet has no last sync to be stale against, so this is how it reports a stall. Folds into healthy.","default":false},"stalled_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stalled Reason","description":"Why the running job counts as stalled, when it does."},"last_job":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Last Job","description":"Summary of the most recent job: status, files_synced/failed, throughput_files_per_min, duration_seconds."}},"type":"object","required":["sync_config_id","status","is_active"],"title":"SyncMetricsResponse","description":"Operational metrics for a sync configuration, in one call.\n\nFolds together what previously required stitching the config + /jobs + /dlq:\nlifetime totals, health/staleness, the DLQ failure breakdown (grouped by\nnormalized error reason), and the most-recent job's throughput. Lets callers\nanswer \"is this sync healthy and is anything backlogged?\" without circumventing\nthe API with kubectl/log spelunking."},"SyncMode":{"type":"string","enum":["initial_only","continuous"],"title":"SyncMode","description":"Supported sync modes for external storage ingestion."},"SyncPerformanceResponse":{"properties":{"bucket_id":{"type":"string","title":"Bucket Id","description":"Bucket identifier"},"sync_config_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sync Config Id","description":"Optional sync config filter"},"time_range":{"$ref":"#/components/schemas/api__analytics__buckets__models__TimeRange","description":"Query time range"},"runs":{"items":{"$ref":"#/components/schemas/SyncRunMetric"},"type":"array","title":"Runs","description":"Sync run metrics"},"summary":{"additionalProperties":true,"type":"object","title":"Summary","description":"Summary statistics"}},"type":"object","required":["bucket_id","time_range","runs"],"title":"SyncPerformanceResponse","description":"Sync performance analytics response."},"SyncRunMetric":{"properties":{"sync_run_id":{"type":"string","title":"Sync Run Id","description":"Sync run identifier"},"started_at":{"type":"string","format":"date-time","title":"Started At","description":"Sync start time"},"duration_seconds":{"type":"number","title":"Duration Seconds","description":"Sync duration in seconds"},"files_discovered":{"type":"integer","title":"Files Discovered","description":"Files discovered"},"files_synced":{"type":"integer","title":"Files Synced","description":"Files successfully synced"},"files_failed":{"type":"integer","title":"Files Failed","description":"Files that failed"},"bytes_synced":{"type":"integer","title":"Bytes Synced","description":"Bytes synced"},"throughput_mbps":{"type":"number","title":"Throughput Mbps","description":"Throughput in MB/s"},"status":{"type":"string","title":"Status","description":"Sync status"},"provider_type":{"type":"string","title":"Provider Type","description":"Provider type (s3, gcs, etc)"}},"type":"object","required":["sync_run_id","started_at","duration_seconds","files_discovered","files_synced","files_failed","bytes_synced","throughput_mbps","status","provider_type"],"title":"SyncRunMetric","description":"Single sync run metrics."},"SyncStatsModel":{"properties":{"total_objects_synced":{"type":"integer","minimum":0.0,"title":"Total Objects Synced","description":"Objects successfully synced across all runs.","default":0},"total_objects_verified":{"type":"integer","minimum":0.0,"title":"Total Objects Verified","description":"Objects verified across all runs.","default":0},"total_objects_failed":{"type":"integer","minimum":0.0,"title":"Total Objects Failed","description":"Objects that failed across all runs.","default":0},"total_objects_discovered":{"type":"integer","minimum":0.0,"title":"Total Objects Discovered","description":"Objects discovered in source across all runs.","default":0},"total_objects_skipped":{"type":"integer","minimum":0.0,"title":"Total Objects Skipped","description":"Objects skipped (already synced) across all runs.","default":0},"total_bytes_synced":{"type":"integer","minimum":0.0,"title":"Total Bytes Synced","description":"Bytes transferred across all runs.","default":0},"total_duration_seconds":{"type":"number","minimum":0.0,"title":"Total Duration Seconds","description":"Summed run duration in seconds across all runs.","default":0.0},"total_runs_completed":{"type":"integer","minimum":0.0,"title":"Total Runs Completed","description":"Runs that completed with no failures.","default":0},"total_runs_failed":{"type":"integer","minimum":0.0,"title":"Total Runs Failed","description":"Runs that ended with at least one failure.","default":0},"peak_objects_per_min":{"type":"number","minimum":0.0,"title":"Peak Objects Per Min","description":"Highest objects-per-minute rate seen in any run.","default":0.0},"last_run_objects_synced":{"type":"integer","minimum":0.0,"title":"Last Run Objects Synced","description":"Objects synced in the most recent run.","default":0},"last_run_objects_verified":{"type":"integer","minimum":0.0,"title":"Last Run Objects Verified","description":"Objects verified in the most recent run.","default":0},"last_run_objects_failed":{"type":"integer","minimum":0.0,"title":"Last Run Objects Failed","description":"Objects that failed in the most recent run.","default":0},"last_run_objects_discovered":{"type":"integer","minimum":0.0,"title":"Last Run Objects Discovered","description":"Objects discovered in the most recent run.","default":0},"last_run_objects_skipped":{"type":"integer","minimum":0.0,"title":"Last Run Objects Skipped","description":"Objects skipped in the most recent run.","default":0},"last_run_bytes_synced":{"type":"integer","minimum":0.0,"title":"Last Run Bytes Synced","description":"Bytes transferred in the most recent run.","default":0},"last_run_duration_seconds":{"type":"number","minimum":0.0,"title":"Last Run Duration Seconds","description":"Duration of the most recent run in seconds.","default":0.0},"last_run_throughput_objects_per_min":{"type":"number","minimum":0.0,"title":"Last Run Throughput Objects Per Min","description":"Objects-per-minute rate of the most recent run.","default":0.0},"last_run_throughput_mbps":{"type":"number","minimum":0.0,"title":"Last Run Throughput Mbps","description":"Throughput of the most recent run in MB/s.","default":0.0},"last_run_avg_object_size_bytes":{"type":"integer","minimum":0.0,"title":"Last Run Avg Object Size Bytes","description":"Average object size in the most recent run, in bytes.","default":0},"last_run_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Run At","description":"When the most recent run completed."},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"When these stats were last updated."}},"type":"object","title":"SyncStatsModel","description":"Throughput and volume metrics the sync pipeline aggregates on every run.\n\nCumulative fields sum over all runs; last_run_* fields describe the most\nrecent run only. Present once a run has completed. Every field is optional so\na partial document still validates."},"SyncUpdateRequest":{"properties":{"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Optional human-readable description of the sync configuration. NOT REQUIRED. Used for documentation and UI display. Maximum 500 characters.","examples":["Daily video ingestion from production bucket"]},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Optional custom metadata to replace existing metadata. NOT REQUIRED. Completely replaces existing metadata (not merged). Use for tagging, categorization, or custom attributes. Maximum 50 keys, values must be JSON-serializable.","examples":[{"environment":"production","project":"video-pipeline"},{"last_updated":"2025-11-01","owner":"data-team"}]},"status":{"anyOf":[{"$ref":"#/components/schemas/TaskStatusEnum"},{"type":"null"}],"description":"Optional status to set for the sync configuration. NOT REQUIRED. Valid values: 'pending', 'processing', 'completed', 'failed', 'paused'. Typically managed automatically but can be manually overridden. Use pause/resume endpoints instead for active control.","examples":["pending","processing","completed"]},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active","description":"Optional flag to enable or disable the sync configuration. NOT REQUIRED. When False, sync will not process new files. Prefer using the /pause and /resume endpoints for clarity. Changes take effect immediately.","examples":[true,false]},"polling_interval_seconds":{"anyOf":[{"type":"integer","maximum":86400.0,"minimum":30.0},{"type":"null"}],"title":"Polling Interval Seconds","description":"Optional new polling interval in seconds. NOT REQUIRED. Must be between 30 and 86400 seconds if provided. Only applies to the 'continuous' sync mode. Lower values increase responsiveness but API usage.","examples":[60,300,600]},"batch_size":{"anyOf":[{"type":"integer","maximum":100.0,"minimum":1.0},{"type":"null"}],"title":"Batch Size","description":"Optional new batch size for file processing. NOT REQUIRED. Must be between 1 and 100 if provided. Larger batches improve throughput but use more memory. Changes apply to subsequent batches only.","examples":[10,50,100]},"schema_mapping":{"anyOf":[{"$ref":"#/components/schemas/SchemaMapping-Input"},{"type":"null"}],"description":"Optional schema mapping to replace existing mapping. NOT REQUIRED. Completely replaces existing schema_mapping (not merged). Defines how source data maps to bucket schema fields and blobs. See SyncCreateRequest.schema_mapping for detailed documentation."},"skip_batch_submission":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Skip Batch Submission","description":"If True, sync objects to the bucket without creating or submitting batches for collection processing. Objects are created in the bucket but no tier processing is triggered. While True, nothing this sync ingests is processed or searchable. NOT REQUIRED. When omitted, existing value is preserved.","examples":[false,true]},"batch_collection_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Batch Collection Ids","description":"Collections this sync's auto-batch processes, by id or name. NOT REQUIRED. When omitted, the existing value is preserved. Send an empty list to clear it and return to auto-discovery.","examples":[["col_chunks_abc"],[]]},"ingest_filter":{"anyOf":[{"$ref":"#/components/schemas/IngestFilter"},{"type":"null"}],"description":"Set or replace this sync's ingest filter (a pinned saved retriever every candidate object runs through before commit), or send null to remove it so the bucket's own filter applies. NOT REQUIRED. When omitted, the existing value is preserved."},"max_objects_per_run":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Max Objects Per Run","description":"Hard cap on objects processed per sync run. NOT REQUIRED. When omitted, existing value is preserved. Use to limit runaway syncs or control ingestion volume.","examples":[100,50000,100000]},"sync_concurrency":{"anyOf":[{"type":"integer","maximum":100.0,"minimum":1.0},{"type":"null"}],"title":"Sync Concurrency","description":"Per-sync override for concurrent object processing. NOT REQUIRED. Must be between 1 and 100 if provided. When omitted, existing value is preserved.","examples":[1,4,8]},"reconcile":{"anyOf":[{"$ref":"#/components/schemas/ReconcileSettings"},{"type":"null"}],"description":"Controls how Mixpeek reconciles objects when the source changes. on_delete: cascade-delete when source asset is removed. on_update: propagate metadata changes and re-process. on_filter_drift: remove objects that no longer match filters. NOT REQUIRED. When omitted, existing value is preserved.","examples":[{"on_delete":true,"on_filter_drift":true,"on_update":true},{"on_delete":true,"on_filter_drift":false,"on_update":false}]},"provider_filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Provider Filters","description":"Provider-specific pre-filters pushed down to the storage API call. NOT REQUIRED. Completely replaces existing provider_filters (not merged). Each provider defines its own filter schema. Examples: - Iconik: {'collection_ids': [...], 'media_type': 'video,image', 'path_patterns': ['*/Footage/*']} - Google Drive: {'shared_drive_id': '0AH-Xabc123'} - S3: {'prefix': 'videos/'}","examples":[{"collection_ids":["col_abc","col_def"],"media_type":"video,image"}]}},"additionalProperties":false,"type":"object","title":"SyncUpdateRequest","description":"Request to update an existing sync configuration.\n\nAllows partial updates to sync settings without recreating the configuration.\nAll fields are optional - only provided fields will be updated.\n\nUse Cases:\n    - Pause/resume syncs by toggling is_active\n    - Adjust polling intervals based on activity patterns\n    - Update batch sizes for performance tuning\n    - Add metadata tags for organization\n\nRequirements:\n    - All fields are OPTIONAL\n    - At least one field should be provided for the update\n    - Changes take effect on the next sync cycle","examples":[{"description":"Pause sync temporarily","is_active":false},{"description":"Adjust polling frequency","polling_interval_seconds":600},{"batch_size":75,"description":"Update batch size and metadata","metadata":{"last_tuned":"2025-11-01","optimized":true}},{"batch_size":100,"description":"Production video sync - optimized settings","is_active":true,"metadata":{"priority":"high","project":"video-ai"},"polling_interval_seconds":120},{"description":"Resume batch processing for synced objects","skip_batch_submission":false},{"description":"Update Iconik collection filters","provider_filters":{"collection_ids":["8f833e78-92fd-11ef-99d4-36417797d291"],"media_type":"video,image"}}]},"SystemCondition":{"properties":{"type":{"$ref":"#/components/schemas/SystemConditionType","description":"Which built-in data-plane condition to evaluate"},"params":{"additionalProperties":true,"type":"object","title":"Params","description":"Per-condition threshold overrides (evaluator supplies defaults)","examples":[{"stall_minutes":30},{"error_rate_threshold":0.1}]}},"type":"object","required":["type"],"title":"SystemCondition","description":"A built-in data-plane condition for a system-source alert.\n\nThe condition `type` selects which metric is evaluated; `params` carries\nper-type thresholds (e.g. ``stall_minutes``, ``latency_multiplier``,\n``error_rate_threshold``, ``drop_fraction``). All params are optional and\nfall back to sensible defaults in the evaluator.\n\nAttributes:\n    type: Which system condition to evaluate.\n    params: Optional per-condition threshold overrides."},"SystemConditionType":{"type":"string","enum":["collection_empty","batch_failed","batch_stalled","retriever_latency","retriever_no_results","batch_error_rate","collection_drift","retriever_accuracy","retriever_alignment_regression","task_queue_degraded","dlq_growth","provider_quota_exhausted","retriever_no_interactions","collection_stale","budget_threshold","ingest_stalled"],"title":"SystemConditionType","description":"Built-in data-plane conditions a system-source alert can watch."},"TSNEParams":{"properties":{"method":{"type":"string","const":"tsne","title":"Method","default":"tsne"},"n_components":{"type":"integer","maximum":256.0,"minimum":2.0,"title":"N Components","default":2},"random_state":{"type":"integer","title":"Random State","default":42},"perplexity":{"type":"number","exclusiveMinimum":0.0,"title":"Perplexity","default":30.0},"learning_rate":{"type":"number","exclusiveMinimum":0.0,"title":"Learning Rate","default":200.0}},"type":"object","title":"TSNEParams"},"TargetSpec":{"properties":{"internal_id":{"type":"string","title":"Internal Id"},"plane":{"type":"string","enum":["shared","dedicated"],"title":"Plane"},"resource_targets":{"items":{"$ref":"#/components/schemas/ResourceTarget"},"type":"array","title":"Resource Targets"},"slo_targets":{"items":{"$ref":"#/components/schemas/SLOTarget"},"type":"array","title":"Slo Targets"},"is_platform_default":{"type":"boolean","title":"Is Platform Default","description":"True when no org-specific TargetSpec has been written yet and these values are the platform default band for this org's plane. Always true today — no write path exists."},"targets_writable":{"type":"boolean","title":"Targets Writable","description":"Whether this org can write its own TargetSpec. Always false for shared-plane orgs by design, regardless of is_platform_default."}},"type":"object","required":["internal_id","plane","resource_targets","slo_targets","is_platform_default","targets_writable"],"title":"TargetSpec","description":"Per-tenant (or plane) resource targets + SLO block.\n\nTenancy rule. Dedicated tenants hold write access to their own\nTargetSpec. Shared tenants are read-only, scoped to their own workloads,\nand cannot set utilization targets, because shared-plane targets are\nplatform policy: one tenant's aggressiveness is another tenant's\nstarvation.\n\n``targets_writable`` is an explicit capability to read rather than to\ninfer from ``plane``, so a client never reconstructs dedicated-versus-\nshared logic itself."},"TaskProgress":{"properties":{"processed_documents":{"type":"integer","title":"Processed Documents","description":"Number of documents processed","default":0},"total_documents":{"type":"integer","title":"Total Documents","description":"Total documents to process","default":0},"percentage":{"type":"number","title":"Percentage","description":"Progress percentage (0-100)","default":0.0}},"type":"object","title":"TaskProgress","description":"Progress information for a task."},"TaskResponse":{"properties":{"task_id":{"type":"string","title":"Task Id","description":"Unique identifier for the task. REQUIRED. Used to poll task status via GET /v1/tasks/{task_id}. This ID is also stored on parent resources (batches, clusters, etc.) for cross-referencing. Format: UUID v4 or custom string identifier.","examples":["task_abc123def456","550e8400-e29b-41d4-a716-446655440000"]},"task_type":{"$ref":"#/components/schemas/TaskType","description":"Type of operation this task represents. REQUIRED. Identifies the specific async operation being performed. Used for filtering and categorizing tasks. Common types: api_buckets_batches_process, engine_cluster_build, api_taxonomies_execute. See TaskType enum for complete list of supported operations.","examples":["api_buckets_batches_process","engine_cluster_build","api_taxonomies_execute"]},"status":{"$ref":"#/components/schemas/TaskStatusEnum","description":"Current status of the task. REQUIRED. Indicates the current state of the async operation. Terminal statuses (COMPLETED, FAILED, CANCELED) indicate the task has finished and will not change. Active statuses (PENDING, IN_PROGRESS, PROCESSING) indicate the task is still running and should be polled. Use this field to determine when to stop polling.","examples":["PENDING","PROCESSING","COMPLETED","FAILED"]},"inputs":{"anyOf":[{"items":{"anyOf":[{"type":"string"},{"additionalProperties":true,"type":"object"}]},"type":"array"},{"type":"null"}],"title":"Inputs","description":"Input parameters or data used to start the task. OPTIONAL. May include IDs, configuration objects, or file references. Useful for debugging and understanding what data the task processed. Format: List of strings (IDs) or objects (configuration). Example: ['batch_id_123'] or [{'bucket_id': 'bkt_abc', 'config': {...}}]","examples":[["batch_xyz789"],["obj_123","obj_456","obj_789"],[{"bucket_id":"bkt_abc","collection_ids":["col_1","col_2"]}]]},"outputs":{"anyOf":[{"items":{"anyOf":[{"type":"string"},{"additionalProperties":true,"type":"object"}]},"type":"array"},{"type":"null"}],"title":"Outputs","description":"Output results produced by the task. OPTIONAL. Populated when task completes successfully. May include processed file IDs, result metrics, or status summaries. Check this field after task reaches COMPLETED status to get results. Format: List of strings (output IDs) or objects (result data).","examples":[["document_123","document_456"],[{"failed_count":2,"processed_count":100,"success_rate":0.98}],[{"cluster_id":"cl_abc123","num_clusters":5}]]},"additional_data":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Additional Data","description":"Additional metadata and context for the task. OPTIONAL. Contains job IDs, error details, progress info, and other task-specific metadata. \n\nCommon fields (all task types): - 'error': Error message if task failed - 'job_id': Ray job ID for engine tasks - 'from_mongodb': True if retrieved from MongoDB fallback (not Redis) \n\nBatch-specific fields (task_type=api_buckets_batches_process): - 'batch_id': Batch identifier (REQUIRED) - 'bucket_id': Source bucket identifier (REQUIRED) - 'namespace_id': Namespace identifier (REQUIRED) - 'current_tier': Currently processing tier number, 0-indexed (OPTIONAL, None if not started) - 'total_tiers': Total number of tiers in the batch pipeline (REQUIRED) - 'collection_ids': Array of ALL collection IDs across all tiers (REQUIRED) - 'object_count': Number of objects being processed (REQUIRED) - 'sample_object_ids': First 5 object IDs for debugging/display (OPTIONAL) \n\nPerformance Note: Full object_ids array is NOT stored in task metadata to avoid bloating task documents (batches with 10k+ objects would add 200KB+ per task). For full object list, query the batch directly via GET /v1/buckets/{bucket_id}/batches/{batch_id}. \n\nNote: For detailed per-tier status, use GET /v1/buckets/{bucket_id}/batches/{batch_id} to access the tier_tasks[] array which contains individual tier statuses, collection_ids, and timestamps for each tier.","examples":[{"batch_id":"btch_xyz789","bucket_id":"bkt_products","collection_ids":["col_tier0","col_tier1","col_tier2"],"current_tier":1,"job_id":"ray_job_123","namespace_id":"ns_abc123","object_count":10000,"sample_object_ids":["obj_001","obj_002","obj_003","obj_004","obj_005"],"total_tiers":3},{"error":"Failed to process object: Invalid file format","job_id":"123"},{"cluster_id":"cl_abc","collection_ids":["col_1"],"from_mongodb":true}]},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Flattened error message for convenient error handling. OPTIONAL. Automatically populated from additional_data['error'] when the task has FAILED status. This is a convenience field - the full error details are always available in additional_data['error']. Use this field for displaying errors to users or logging. Will be None if task has not failed or if no error details are available. Serialized as 'error' in API responses for backward compatibility.","examples":["Failed to process batch: Object not found","Invalid file format: Expected PDF, got PNG","Clustering failed: Insufficient data points",null]},"cancellation":{"anyOf":[{"$ref":"#/components/schemas/CancellationOutcome"},{"type":"null"}],"description":"Dispatch outcome of a cancel request, present on responses from the batch cancel endpoints. Absent on every other task response, and on a cancel that returned before any dispatch ran. Absent and all-zero are different answers: all-zero means the cancel dispatched to nothing."},"queue_position":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Queue Position","description":"1-based position in the Ray processing waitlist. None if the batch was dispatched immediately (no queue). Position 1 means this batch will be processed next."},"estimated_wait_minutes":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Estimated Wait Minutes","description":"Estimated minutes until this batch starts processing, based on queue position and average batch duration. None if the batch was dispatched immediately."}},"type":"object","required":["task_id","task_type","status"],"title":"TaskResponse","description":"Task response model returned by the API.\n\nExtends TaskModel with additional convenience fields for API responses.\nThis is the model returned when you GET /v1/tasks/{task_id}.\n\nAdditional Fields:\n    error_message: Convenience field that surfaces errors from additional_data\n                  for easier error handling in client code.\n\nInheritance:\n    Inherits all fields and documentation from TaskModel, including:\n    - task_id: Unique identifier\n    - task_type: Operation type\n    - status: Current status\n    - inputs: Input parameters\n    - outputs: Output results\n    - additional_data: Metadata and context\n\nStorage Architecture:\n    Same as TaskModel - stored in Redis (24hr TTL) with MongoDB fallback.\n\nUsage:\n    This model is automatically returned by task API endpoints. You don't\n    need to construct it manually - just call GET /v1/tasks/{task_id}.\n\nError Handling:\n    Check the error_message field for a user-friendly error string, or\n    additional_data['error'] for the full error details.\n\nExample Response:\n    {\n        \"task_id\": \"task_abc123\",\n        \"task_type\": \"api_buckets_batches_process\",\n        \"status\": \"FAILED\",\n        \"inputs\": [\"batch_xyz\"],\n        \"outputs\": null,\n        \"additional_data\": {\n            \"error\": \"Failed to process batch: Object not found\",\n            \"batch_id\": \"batch_xyz\"\n        },\n        \"error_message\": \"Failed to process batch: Object not found\"\n    }","examples":[{"additional_data":{"batch_id":"btch_xyz789","bucket_id":"bkt_products","collection_ids":["col_tier0","col_tier1","col_tier2"],"current_tier":1,"job_id":"ray_job_123","namespace_id":"ns_abc123","object_count":10000,"sample_object_ids":["obj_001","obj_002","obj_003","obj_004","obj_005"],"total_tiers":3},"description":"Multi-tier batch processing task in progress (tier 1 of 3) with 10k objects","inputs":["batch_xyz789"],"status":"IN_PROGRESS","task_id":"2d322a05-3178-4eca-aac6-b82b0a0313aa","task_type":"api_buckets_batches_process"},{"additional_data":{"cluster_id":"cl_abc123","job_id":"ray_job_456"},"description":"Completed clustering task with results","inputs":[{"collection_ids":["col_products"],"config":{"algorithm":"kmeans","k":5}}],"outputs":[{"cluster_id":"cl_abc123","num_clusters":5,"silhouette_score":0.78}],"status":"COMPLETED","task_id":"task_cluster_789","task_type":"engine_cluster_build"},{"additional_data":{"bucket_id":"bkt_test","error":"Invalid file format: Expected PDF, got PNG","object_id":"obj_123"},"description":"Failed object creation task with error","inputs":[{"bucket_id":"bkt_test","object_id":"obj_123"}],"status":"FAILED","task_id":"task_failed_123","task_type":"api_buckets_objects_create"},{"additional_data":{"batch_id":"batch_old_123","from_mongodb":true,"note":"Retrieved from persistent storage after 24hr Redis expiry"},"description":"Task retrieved from MongoDB fallback (Redis expired)","inputs":["batch_old_123"],"outputs":["Processed 500 objects"],"status":"COMPLETED","task_id":"taYOUR_OLD_API_KEY","task_type":"api_buckets_batches_process"}]},"TaskStatusEnum":{"type":"string","enum":["PENDING","QUEUED","IN_PROGRESS","PROCESSING","COMPLETED","COMPLETED_WITH_ERRORS","FAILED","CANCELED","INTERRUPTED","UNKNOWN","SKIPPED","DRAFT","ACTIVE","ARCHIVED","SUSPENDED","DEACTIVATED"],"title":"TaskStatusEnum","description":"Enumeration of task statuses for tracking asynchronous operations.\n\nTask statuses indicate the current state of asynchronous operations like\nbatch processing, object ingestion, clustering, and taxonomy execution.\n\nStatus Categories:\n    Operation Statuses: Track progress of async operations\n    Lifecycle Statuses: Track entity state (buckets, collections, namespaces)\n\nValues:\n    PENDING: Task is queued but has not started processing yet\n    IN_PROGRESS: Task is currently being executed\n    PROCESSING: Task is actively processing data (similar to IN_PROGRESS)\n    COMPLETED: Task finished successfully with no errors\n    COMPLETED_WITH_ERRORS: Task finished but some items failed (partial success)\n    FAILED: Task encountered an error and could not complete\n    CANCELED: Task was manually canceled by a user or system\n    UNKNOWN: Task status could not be determined\n    SKIPPED: Task was intentionally skipped\n    DRAFT: Task is in draft state and not yet submitted\n\n    ACTIVE: Entity is active and operational (for buckets, collections, etc.)\n    ARCHIVED: Entity has been archived\n    SUSPENDED: Entity has been temporarily suspended\n\nTerminal Statuses:\n    COMPLETED, COMPLETED_WITH_ERRORS, FAILED, CANCELED are terminal statuses.\n    A task in one of them changes again only when it is restarted: a\n    retry moves a failed batch back to PENDING, and a resubmit or rerun\n    moves any finished batch back to DRAFT. INTERRUPTED is not terminal: an\n    infrastructure failure stopped the batch, and Mixpeek either resubmits\n    it or marks it FAILED.\n\nPartial Success Handling:\n    COMPLETED_WITH_ERRORS indicates that the operation completed but some\n    documents/items failed. The task result includes:\n    - List of successful items\n    - List of failed items with error details\n    - Success rate percentage\n    This allows clients to handle partial success scenarios appropriately.\n\nPolling Guidance:\n    - Poll tasks in PENDING, QUEUED, IN_PROGRESS, PROCESSING or\n      INTERRUPTED states\n    - Stop polling when task reaches COMPLETED, COMPLETED_WITH_ERRORS, FAILED, or CANCELED\n    - Use exponential backoff (1s to 30s) when polling"},"TaskType":{"type":"string","enum":["api_namespaces_create","api_namespaces_delete","api_namespaces_snapshot_create","api_namespaces_snapshot_restore","api_namespaces_migrations_run","api_buckets_objects_create","api_buckets_delete","api_buckets_batches_process","api_buckets_batches_submit","api_buckets_uploads_create","api_buckets_uploads_confirm","api_buckets_uploads_batch_confirm","api_collections_documents_create","api_collections_documents_bulk_update","api_collections_documents_bulk_delete","api_collections_reembed","api_collections_extraction_artifacts","api_taxonomies_create","api_taxonomies_execute","api_taxonomies_materialize","api_evaluations_run","api_evaluations_dataset_create","api_retrievers_publish","api_manifest_apply","api_retrievers_execute","api_collections_export","api_collections_trigger","engine_feature_extractor_run","engine_inference_run","engine_object_processing","engine_cluster_build","thumbnail","video_segment","audio_segment","converted_video","materialize","plugin_custom","model_custom"],"title":"TaskType","description":"Types of asynchronous tasks that can be performed in the system.\n\nTask types identify the specific operation being performed. This helps with\ntracking, debugging, and filtering tasks by operation type.\n\nCategories:\n    API Tasks: User-initiated operations via API endpoints\n    Engine Tasks: Background processing tasks\n    Inference Tasks: Specialized inference operations\n\nAPI Task Types:\n    API_NAMESPACES_CREATE: Creating a new namespace\n    API_NAMESPACES_MIGRATIONS_RUN: Running a namespace migration\n    API_BUCKETS_OBJECTS_CREATE: Creating objects in a bucket\n    API_BUCKETS_DELETE: Deleting a bucket and its contents\n    API_BUCKETS_BATCHES_PROCESS: Processing a batch of objects\n    API_BUCKETS_BATCHES_SUBMIT: Submitting a batch for processing\n    API_BUCKETS_UPLOADS_CREATE: Creating an upload session\n    API_BUCKETS_UPLOADS_CONFIRM: Confirming an upload completion\n    API_BUCKETS_UPLOADS_BATCH_CONFIRM: Confirming batch upload completion\n    API_TAXONOMIES_CREATE: Creating a new taxonomy\n    API_TAXONOMIES_EXECUTE: Executing taxonomy classification\n    API_TAXONOMIES_MATERIALIZE: Materializing taxonomy results\n    API_RETRIEVERS_PUBLISH: Publishing retriever assets (OG images, etc.)\n\nEngine Task Types:\n    ENGINE_FEATURE_EXTRACTOR_RUN: Running feature extraction on data\n    ENGINE_INFERENCE_RUN: Running inference operations\n    ENGINE_OBJECT_PROCESSING: Processing object data\n    ENGINE_CLUSTER_BUILD: Building clusters from data\n\nInference Task Types:\n    THUMBNAIL: Generating thumbnails\n    MATERIALIZE: Materializing processed data\n\nUsage:\n    Task types are automatically assigned when tasks are created. You can\n    filter tasks by type when listing or searching for specific operations."},"TaxonomyAnalyticsRun":{"properties":{"run_id":{"type":"string","title":"Run Id","description":"Stable run identifier (taxrun_...)"},"taxonomy_id":{"type":"string","title":"Taxonomy Id","description":"Taxonomy analyzed"},"collection_id":{"type":"string","title":"Collection Id","description":"Collection analyzed"},"analysis_type":{"$ref":"#/components/schemas/AnalysisType","description":"transitions or paths"},"params":{"additionalProperties":true,"type":"object","title":"Params","description":"Request params used for the run"},"params_hash":{"type":"string","title":"Params Hash","description":"De-dup hash of the normalized params"},"from_step":{"type":"string","title":"From Step","description":"Starting step"},"to_step":{"type":"string","title":"To Step","description":"Ending step"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Optional run label"},"result":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Result","description":"Computed analytics result"},"status":{"type":"string","title":"Status","description":"Run status","default":"completed"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Error message if the run failed"},"run_count":{"type":"integer","title":"Run Count","description":"Number of times these params have been executed","default":1},"namespace_id":{"type":"string","title":"Namespace Id","description":"Tenant namespace","default":""},"internal_id":{"type":"string","title":"Internal Id","description":"Tenant/org id","default":""},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"First persisted at"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"Last (re-)executed at"}},"type":"object","required":["run_id","taxonomy_id","collection_id","analysis_type","params_hash","from_step","to_step"],"title":"TaxonomyAnalyticsRun","description":"A persisted taxonomy step-analytics run.\n\nEvery time a user runs a transitions or paths analysis, the request\nparameters and the computed result are stored (upserted, de-duplicated by a\nhash of the normalized params) so the run can be listed, reviewed, and\nre-run later. Re-running the same parameters updates the existing record and\nincrements ``run_count`` rather than creating a duplicate.\n\nAttributes:\n    run_id: Stable identifier for the run (``taxrun_<token>``).\n    taxonomy_id: Taxonomy the analytics were computed against.\n    collection_id: Collection the analytics were computed against.\n    analysis_type: ``transitions`` or ``paths``.\n    params: The request parameters used (``exclude_none`` dump of the\n        request body). Enough to reconstruct and re-run the analysis.\n    params_hash: SHA-256 of the normalized params (plus analysis_type and\n        collection_id) — the upsert de-duplication key.\n    from_step: Convenience copy of the transition's starting step.\n    to_step: Convenience copy of the transition's ending step.\n    name: Optional user-provided label for the run.\n    result: The computed analytics result (``model_dump`` of the response).\n    status: Run status; ``completed`` on success.\n    error_message: Populated only when a run failed.\n    run_count: Number of times these exact params have been executed.\n    namespace_id: Tenant namespace (auto-populated by the provider).\n    internal_id: Tenant/org id (auto-populated by the provider).\n    created_at: When the run was first persisted.\n    updated_at: When the run was last (re-)executed."},"TaxonomyAnalyticsRunListResponse":{"properties":{"runs":{"items":{"$ref":"#/components/schemas/TaxonomyAnalyticsRun"},"type":"array","title":"Runs","description":"Runs on this page"},"total":{"type":"integer","title":"Total","description":"Total matching runs"},"page":{"type":"integer","title":"Page","description":"1-indexed page number"},"page_size":{"type":"integer","title":"Page Size","description":"Runs per page"}},"type":"object","required":["runs","total","page","page_size"],"title":"TaxonomyAnalyticsRunListResponse","description":"Paginated list of persisted taxonomy analytics runs.\n\nAttributes:\n    runs: The runs on this page (sorted newest-executed first).\n    total: Total number of runs matching the filters.\n    page: 1-indexed page number.\n    page_size: Number of runs per page."},"TaxonomyApplicationConfig-Input":{"properties":{"taxonomy_id":{"type":"string","title":"Taxonomy Id","description":"ID of the `TaxonomyModel` to execute."},"execution_mode":{"$ref":"#/components/schemas/TaxonomyExecutionMode","description":"Execution mode for taxonomy enrichment. Materializes results during ingestion.","default":"materialize"},"target_collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Collection Id","description":"Optional collection to persist results into when `execution_mode` is 'materialize'. If omitted, the source collection is updated in-place."},"scroll_filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"Additional filters applied when scrolling the source collection before enrichment."},"execution_phase":{"type":"integer","maximum":3.0,"minimum":1.0,"title":"Execution Phase","description":"Which phase this taxonomy runs in. Default: 1 (TAXONOMY phase, runs first). Valid values: 1=TAXONOMY, 2=CLUSTER, 3=ALERT. Lower phases run earlier.","default":1},"priority":{"type":"integer","maximum":1000.0,"minimum":0.0,"title":"Priority","description":"Priority within the execution phase (higher = runs first)","default":0},"hierarchical_enrichment_style":{"$ref":"#/components/schemas/HierarchicalEnrichmentStyle","description":"For hierarchical taxonomies, controls how enrichment fields are structured. 'full_chain': Each tier writes to tier-prefixed fields (tier1_id, tier2_id, etc.). 'best_match': Only deepest match stored (category_id, category_name, path[]). 'combined' (default): Both full chain AND best match summary fields.","default":"combined"}},"additionalProperties":false,"type":"object","required":["taxonomy_id"],"title":"TaxonomyApplicationConfig","description":"Configuration block that attaches a taxonomy to a collection.\n\nSupports execution phase ordering for unified post-processing with\ntaxonomies, clusters, and alerts.","examples":[{"execution_mode":"materialize","taxonomy_id":"tax_abc123"},{"execution_mode":"materialize","execution_phase":1,"priority":10,"target_collection_id":"col_enriched_v1","taxonomy_id":"tax_abc123"},{"execution_mode":"materialize","hierarchical_enrichment_style":"full_chain","taxonomy_id":"tax_iab_content"}]},"TaxonomyApplicationConfig-Output":{"properties":{"taxonomy_id":{"type":"string","title":"Taxonomy Id","description":"ID of the `TaxonomyModel` to execute."},"execution_mode":{"$ref":"#/components/schemas/TaxonomyExecutionMode","description":"Execution mode for taxonomy enrichment. Materializes results during ingestion.","default":"materialize"},"target_collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Collection Id","description":"Optional collection to persist results into when `execution_mode` is 'materialize'. If omitted, the source collection is updated in-place."},"scroll_filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Output"},{"type":"null"}],"description":"Additional filters applied when scrolling the source collection before enrichment."},"execution_phase":{"type":"integer","maximum":3.0,"minimum":1.0,"title":"Execution Phase","description":"Which phase this taxonomy runs in. Default: 1 (TAXONOMY phase, runs first). Valid values: 1=TAXONOMY, 2=CLUSTER, 3=ALERT. Lower phases run earlier.","default":1},"priority":{"type":"integer","maximum":1000.0,"minimum":0.0,"title":"Priority","description":"Priority within the execution phase (higher = runs first)","default":0},"hierarchical_enrichment_style":{"$ref":"#/components/schemas/HierarchicalEnrichmentStyle","description":"For hierarchical taxonomies, controls how enrichment fields are structured. 'full_chain': Each tier writes to tier-prefixed fields (tier1_id, tier2_id, etc.). 'best_match': Only deepest match stored (category_id, category_name, path[]). 'combined' (default): Both full chain AND best match summary fields.","default":"combined"}},"additionalProperties":false,"type":"object","required":["taxonomy_id"],"title":"TaxonomyApplicationConfig","description":"Configuration block that attaches a taxonomy to a collection.\n\nSupports execution phase ordering for unified post-processing with\ntaxonomies, clusters, and alerts.","examples":[{"execution_mode":"materialize","taxonomy_id":"tax_abc123"},{"execution_mode":"materialize","execution_phase":1,"priority":10,"target_collection_id":"col_enriched_v1","taxonomy_id":"tax_abc123"},{"execution_mode":"materialize","hierarchical_enrichment_style":"full_chain","taxonomy_id":"tax_iab_content"}]},"TaxonomyExecutionMode":{"type":"string","enum":["materialize"],"title":"TaxonomyExecutionMode","description":"How a taxonomy should be executed when attached to a collection."},"TaxonomyListStats":{"properties":{"total_taxonomies":{"type":"integer","title":"Total Taxonomies","description":"Total number of taxonomies in the result","default":0},"flat_taxonomies":{"type":"integer","title":"Flat Taxonomies","description":"Number of flat taxonomies","default":0},"hierarchical_taxonomies":{"type":"integer","title":"Hierarchical Taxonomies","description":"Number of hierarchical taxonomies","default":0},"taxonomies_with_retrievers":{"type":"integer","title":"Taxonomies With Retrievers","description":"Number of taxonomies with retriever configured","default":0}},"type":"object","title":"TaxonomyListStats","description":"Aggregate statistics for a list of taxonomies."},"TaxonomyMatch":{"properties":{"document_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Id"},"taxonomy_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Taxonomy Id"},"taxonomy_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Taxonomy Name"},"node_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Node Id"},"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"path":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Path"},"hierarchy_level":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Hierarchy Level"},"enriched_fields":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Enriched Fields"}},"type":"object","title":"TaxonomyMatch","description":"Flattened, UI-friendly summary of one taxonomy assignment extracted from a validate/execute result."},"TaxonomyModel-Input":{"properties":{"taxonomy_id":{"type":"string","title":"Taxonomy Id","description":"Unique identifier for the taxonomy"},"version":{"type":"integer","minimum":1.0,"title":"Version","description":"Monotonic version number of the taxonomy configuration","default":1},"taxonomy_name":{"type":"string","title":"Taxonomy Name","description":"A unique name for the taxonomy within the namespace."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Optional human-readable description."},"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id","description":"Optional taxonomy-level retriever (prefer per-layer)."},"input_mappings":{"anyOf":[{"items":{"$ref":"#/components/schemas/InputMapping"},"type":"array"},{"type":"null"}],"title":"Input Mappings","description":"Optional taxonomy-level inputs (prefer per-layer)."},"config":{"oneOf":[{"$ref":"#/components/schemas/FlatTaxonomyConfig-Input"},{"$ref":"#/components/schemas/HierarchicalTaxonomyConfig-Input"}],"title":"Config","description":"Configuration specific to the taxonomy type.","discriminator":{"propertyName":"taxonomy_type","mapping":{"flat":"#/components/schemas/FlatTaxonomyConfig-Input","hierarchical":"#/components/schemas/HierarchicalTaxonomyConfig-Input"}}},"nodes":{"anyOf":[{"items":{"$ref":"#/components/schemas/TaxonomyPathNode"},"type":"array"},{"type":"null"}],"title":"Nodes","description":"For a hierarchy built from config.path_field: one node per distinct path prefix seen in enriched documents, with its parent. Grows as enrichment meets new paths. None for other taxonomies."},"ready":{"type":"boolean","title":"Ready","description":"Whether the taxonomy is ready for use. False for async inference (cluster/LLM) that needs processing. True for flat/explicit hierarchies.","default":true},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp for this taxonomy record"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Additional user-defined metadata for the taxonomy"}},"type":"object","required":["taxonomy_name","config"],"title":"TaxonomyModel","description":"Primary Pydantic model representing a taxonomy definition.","examples":[{"config":{"default_input_mappings":[{"input_key":"image_vector","path":"features.clip_vit_l_14","source_type":"vector"}],"default_retriever_id":"ret_clip_v1","source_collection":{"collection_id":"col_products_v1"},"taxonomy_type":"flat"},"namespace_id":"ns_123","taxonomy_name":"product_tags","taxonomy_type":"flat"},{"config":{"build_mode":"explicit","default_input_mappings":[{"input_key":"face_vec","path":"features.face","source_type":"vector"}],"default_retriever_id":"ret_face_v1","hierarchical_nodes":[{"collection_id":"col_employees_v1"},{"collection_id":"col_executives_v1","parent_collection_id":"col_employees_v1"}],"taxonomy_type":"hierarchical"},"namespace_id":"ns_123","taxonomy_name":"org_hierarchy","taxonomy_type":"hierarchical"}]},"TaxonomyModel-Output":{"properties":{"taxonomy_id":{"type":"string","title":"Taxonomy Id","description":"Unique identifier for the taxonomy"},"version":{"type":"integer","minimum":1.0,"title":"Version","description":"Monotonic version number of the taxonomy configuration","default":1},"taxonomy_name":{"type":"string","title":"Taxonomy Name","description":"A unique name for the taxonomy within the namespace."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Optional human-readable description."},"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id","description":"Optional taxonomy-level retriever (prefer per-layer)."},"input_mappings":{"anyOf":[{"items":{"$ref":"#/components/schemas/InputMapping"},"type":"array"},{"type":"null"}],"title":"Input Mappings","description":"Optional taxonomy-level inputs (prefer per-layer)."},"config":{"oneOf":[{"$ref":"#/components/schemas/FlatTaxonomyConfig-Output"},{"$ref":"#/components/schemas/HierarchicalTaxonomyConfig-Output"}],"title":"Config","description":"Configuration specific to the taxonomy type.","discriminator":{"propertyName":"taxonomy_type","mapping":{"flat":"#/components/schemas/FlatTaxonomyConfig-Output","hierarchical":"#/components/schemas/HierarchicalTaxonomyConfig-Output"}}},"nodes":{"anyOf":[{"items":{"$ref":"#/components/schemas/TaxonomyPathNode"},"type":"array"},{"type":"null"}],"title":"Nodes","description":"For a hierarchy built from config.path_field: one node per distinct path prefix seen in enriched documents, with its parent. Grows as enrichment meets new paths. None for other taxonomies."},"ready":{"type":"boolean","title":"Ready","description":"Whether the taxonomy is ready for use. False for async inference (cluster/LLM) that needs processing. True for flat/explicit hierarchies.","default":true},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp for this taxonomy record"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Additional user-defined metadata for the taxonomy"}},"type":"object","required":["taxonomy_name","config"],"title":"TaxonomyModel","description":"Primary Pydantic model representing a taxonomy definition.","examples":[{"config":{"default_input_mappings":[{"input_key":"image_vector","path":"features.clip_vit_l_14","source_type":"vector"}],"default_retriever_id":"ret_clip_v1","source_collection":{"collection_id":"col_products_v1"},"taxonomy_type":"flat"},"namespace_id":"ns_123","taxonomy_name":"product_tags","taxonomy_type":"flat"},{"config":{"build_mode":"explicit","default_input_mappings":[{"input_key":"face_vec","path":"features.face","source_type":"vector"}],"default_retriever_id":"ret_face_v1","hierarchical_nodes":[{"collection_id":"col_employees_v1"},{"collection_id":"col_executives_v1","parent_collection_id":"col_employees_v1"}],"taxonomy_type":"hierarchical"},"namespace_id":"ns_123","taxonomy_name":"org_hierarchy","taxonomy_type":"hierarchical"}]},"TaxonomyNodeFromDocumentsResponse":{"properties":{"taxonomy_id":{"type":"string","title":"Taxonomy Id"},"taxonomy_name":{"type":"string","title":"Taxonomy Name"},"node_document_id":{"type":"string","title":"Node Document Id","description":"ID of the created node document (the taxonomy node)."},"node_collection_id":{"type":"string","title":"Node Collection Id","description":"The taxonomy's node (source) collection."},"node_label":{"type":"string","title":"Node Label"},"vector_name":{"type":"string","title":"Vector Name","description":"Vector index name the anchor was stored under."},"vector_dimensions":{"type":"integer","title":"Vector Dimensions"},"documents_used":{"type":"integer","title":"Documents Used","description":"How many referenced documents contributed to the anchor."},"documents_skipped":{"items":{"$ref":"#/components/schemas/SkippedDocumentRef"},"type":"array","title":"Documents Skipped"},"taxonomy_created":{"type":"boolean","title":"Taxonomy Created","description":"True when this call also created the taxonomy (one-gesture mode).","default":false},"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id","description":"Retriever created for the taxonomy (one-gesture mode only)."},"enrichment_hint":{"type":"string","title":"Enrichment Hint","description":"Plain-language description of how the new node will be applied to future data."},"nodes":{"anyOf":[{"items":{"$ref":"#/components/schemas/PromotedNode"},"type":"array"},{"type":"null"}],"title":"Nodes","description":"Every node created, when the source was a `cluster_run` (one per cluster). `node_document_id` and `node_label` name the first."}},"type":"object","required":["taxonomy_id","taxonomy_name","node_document_id","node_collection_id","node_label","vector_name","vector_dimensions","documents_used","enrichment_hint"],"title":"TaxonomyNodeFromDocumentsResponse","description":"Result of promoting a document selection to a taxonomy node."},"TaxonomyOptions":{"properties":{"preserve_taxonomy_ids":{"type":"boolean","title":"Preserve Taxonomy Ids","description":"Keep same taxonomy IDs in target","default":true},"preserve_enrichment_fields":{"type":"boolean","title":"Preserve Enrichment Fields","description":"Keep _taxonomy_* fields in documents","default":true},"re_run_enrichment":{"type":"boolean","title":"Re Run Enrichment","description":"Re-run taxonomy enrichment after migration","default":false},"migrate_reference_collections":{"type":"boolean","title":"Migrate Reference Collections","description":"Automatically migrate reference collections","default":true}},"type":"object","title":"TaxonomyOptions","description":"Options for taxonomy migration."},"TaxonomyPathNode":{"properties":{"node_id":{"type":"string","title":"Node Id","description":"Stable id derived from the path."},"label":{"type":"string","title":"Label","description":"The prefix's last segment."},"path":{"items":{"type":"string"},"type":"array","title":"Path","description":"The segments from the root to here."},"parent_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parent Id","description":"node_id of the parent prefix; None at the root."},"level":{"type":"integer","minimum":0.0,"title":"Level","description":"Depth; 0 at the root."}},"type":"object","required":["node_id","label","path","level"],"title":"TaxonomyPathNode","description":"One node of a path-built hierarchy (plan 6.22): a distinct path prefix."},"TaxonomyResponse":{"properties":{"taxonomy_id":{"type":"string","title":"Taxonomy Id","description":"Unique identifier for the taxonomy"},"version":{"type":"integer","minimum":1.0,"title":"Version","description":"Monotonic version number of the taxonomy configuration","default":1},"taxonomy_name":{"type":"string","title":"Taxonomy Name","description":"A unique name for the taxonomy within the namespace."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Optional human-readable description."},"retriever_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Retriever Id","description":"Optional taxonomy-level retriever (prefer per-layer)."},"input_mappings":{"anyOf":[{"items":{"$ref":"#/components/schemas/InputMapping"},"type":"array"},{"type":"null"}],"title":"Input Mappings","description":"Optional taxonomy-level inputs (prefer per-layer)."},"config":{"oneOf":[{"$ref":"#/components/schemas/FlatTaxonomyConfig-Output"},{"$ref":"#/components/schemas/HierarchicalTaxonomyConfig-Output"}],"title":"Config","description":"Configuration specific to the taxonomy type.","discriminator":{"propertyName":"taxonomy_type","mapping":{"flat":"#/components/schemas/FlatTaxonomyConfig-Output","hierarchical":"#/components/schemas/HierarchicalTaxonomyConfig-Output"}}},"nodes":{"anyOf":[{"items":{"$ref":"#/components/schemas/TaxonomyPathNode"},"type":"array"},{"type":"null"}],"title":"Nodes","description":"For a hierarchy built from config.path_field: one node per distinct path prefix seen in enriched documents, with its parent. Grows as enrichment meets new paths. None for other taxonomies."},"ready":{"type":"boolean","title":"Ready","description":"Whether the taxonomy is ready for use. False for async inference (cluster/LLM) that needs processing. True for flat/explicit hierarchies.","default":true},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp for this taxonomy record"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Additional user-defined metadata for the taxonomy"}},"type":"object","required":["taxonomy_name","config"],"title":"TaxonomyResponse","description":"Response model for a taxonomy.","examples":[{"config":{"default_input_mappings":[{"input_key":"image_vector","path":"features.clip_vit_l_14","source_type":"vector"}],"default_retriever_id":"ret_clip_v1","source_collection":{"collection_id":"col_products_v1"},"taxonomy_type":"flat"},"namespace_id":"ns_123","taxonomy_name":"product_tags","taxonomy_type":"flat"},{"config":{"build_mode":"explicit","default_input_mappings":[{"input_key":"face_vec","path":"features.face","source_type":"vector"}],"default_retriever_id":"ret_face_v1","hierarchical_nodes":[{"collection_id":"col_employees_v1"},{"collection_id":"col_executives_v1","parent_collection_id":"col_employees_v1"}],"taxonomy_type":"hierarchical"},"namespace_id":"ns_123","taxonomy_name":"org_hierarchy","taxonomy_type":"hierarchical"}]},"TaxonomyTreeResponse":{"properties":{"taxonomy_id":{"type":"string","title":"Taxonomy Id","description":"ID of the taxonomy"},"nodes":{"items":{},"type":"array","title":"Nodes","description":"Taxonomy node tree"}},"type":"object","required":["taxonomy_id"],"title":"TaxonomyTreeResponse","description":"Response for a public taxonomy tree lookup."},"TemplateMode":{"type":"string","enum":["scaffold","config","clone","manifest"],"title":"TemplateMode","description":"Mode of template instantiation.\n\nscaffold: Create from pre-built preset\n    - Creates: namespace + bucket + collection + retriever\n    - Endpoint: POST /templates/scaffolds/{id}/instantiate\n    - All resources empty, ready for data\n\nconfig: Copy resource configuration only\n    - Creates: empty resource with same settings\n    - Endpoint: POST /templates/{resource}/{id}/instantiate\n    - No data copied\n\nclone: Copy resource with all data\n    - Creates: full copy including vectors/embeddings\n    - Endpoint: POST /namespaces/{id}/clone\n    - For a config-only namespace copy, export a manifest and apply it\n\nmanifest: A whole pipeline as a Mixpeek manifest\n    - Creates: every resource the manifest declares (connections, buckets,\n      syncs, collections, retrievers, alerts, triggers)\n    - Endpoint: POST /manifest/apply with configuration[\"manifest\"]\n    - For templates that need more than extractors and indexes"},"TemplateScope":{"type":"string","enum":["system","organization","user","public"],"title":"TemplateScope","description":"Scope of template availability.\n\nsystem: Mixpeek-provided, available to all orgs\norganization: Private to org members\nuser: Private to creator only\npublic: User-created, discoverable by all orgs (marketplace)"},"TemplateType":{"type":"string","enum":["namespace","retriever","cluster","collection","bucket","taxonomy","scaffold"],"title":"TemplateType","description":"Types of resources that can be templated."},"TerminateSessionResponse":{"properties":{"session_id":{"type":"string","title":"Session Id","description":"Session identifier"},"status":{"$ref":"#/components/schemas/SessionStatus","description":"Session status (terminated)"},"terminated_at":{"type":"string","format":"date-time","title":"Terminated At","description":"Termination timestamp"}},"type":"object","required":["session_id","status","terminated_at"],"title":"TerminateSessionResponse","description":"Response for session termination.\n\nAttributes:\n    session_id: Session identifier\n    status: New session status (terminated)\n    terminated_at: Termination timestamp"},"TextExtractorParams":{"properties":{"extractor_type":{"type":"string","const":"text_extractor","title":"Extractor Type","description":"Discriminator field for parameter type identification.","default":"text_extractor"},"source_type":{"type":"string","enum":["text","youtube"],"title":"Source Type","description":"Source content type. Use 'youtube' to resolve YouTube URLs to caption text before embedding. Default: 'text' (plain text input).","default":"text"},"split_by":{"$ref":"#/components/schemas/TextSplitStrategy","description":"Strategy for splitting text into multiple documents. 'markdown' makes one document per heading section and one per fenced code block, each carrying heading_path, chunk_kind ('section' or 'code') and, for code, code_language.","default":"none"},"chunk_size":{"type":"integer","maximum":10000.0,"minimum":1.0,"title":"Chunk Size","description":"Target chunk size, counted in the split_by strategy's own unit: characters for split_by='characters', words for 'words', sentences for 'sentences', paragraphs for 'paragraphs', pages for 'pages', and words of prose per section chunk for 'markdown' (a longer section splits at paragraph boundaries; code blocks are never split). For example split_by='sentences' with chunk_size=5 produces chunks of 5 sentences. Not used for 'none' or 'time_segments' (use segment_length_seconds there).","default":1000},"chunk_overlap":{"type":"integer","maximum":5000.0,"minimum":0.0,"title":"Chunk Overlap","description":"Overlap between consecutive chunks, counted in the same unit as chunk_size (characters, words, sentences, paragraphs, or pages). For example split_by='sentences' with chunk_overlap=1 carries one sentence from the end of each chunk into the next. Not used for 'markdown'.","default":0},"segment_length_seconds":{"type":"integer","maximum":600.0,"minimum":30.0,"title":"Segment Length Seconds","description":"Length of each transcript segment in seconds (for time_segments split strategy). Shorter segments give more precise search results but more documents.","default":120},"language":{"type":"string","title":"Language","description":"Preferred language code for YouTube captions (when source_type='youtube').","default":"en"},"extract_captions":{"type":"boolean","title":"Extract Captions","description":"Extract auto-captions or manual subtitles from YouTube videos (when source_type='youtube'). Falls back to video description if False.","default":true},"response_shape":{"anyOf":[{"type":"string"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Response Shape","description":"Define custom structured output using LLM extraction."},"llm_provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Llm Provider","description":"LLM provider for structured extraction (openai, google, anthropic, typesafe). 'typesafe' runs Jev, which answers each response_shape field as a typed question (enum -> choice, boolean -> yes/no, bounded integer -> score) and needs response_shape as a JSON schema of closed-set fields."},"llm_model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Llm Model","description":"Specific LLM model for structured extraction, e.g. gemini-2.5-flash or jev-latest."},"llm_api_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Llm Api Key","description":"API key for LLM operations (BYOK - Bring Your Own Key). Supports:\n- Direct key: 'sk-proj-abc123...'\n- Secret reference: '{{SECRET.openai_api_key}}'\n\nWhen using secret reference, the key is loaded from your organization's secrets vault at runtime. Store secrets via POST /v1/organizations/secrets.\n\nIf not provided, uses Mixpeek's default API keys."},"embedding_model":{"anyOf":[{"$ref":"#/components/schemas/EmbeddingModel"},{"type":"null"}],"description":"Embedding model to use. Defaults to the current TEXT modality default in the central embedding registry. Changing this on an existing namespace requires a migration — dimensions are fixed at namespace creation."},"embedding_task":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Embedding Task","description":"Embedding task hint for instruction-aware models (E5, Gemini). Prefer setting this at collection level (embedding_task on the collection) rather than here. Collection-level overrides this value. Defaults to 'retrieval_document'. Values: retrieval_document, retrieval_query, semantic_similarity, classification, clustering."}},"type":"object","title":"TextExtractorParams","description":"Parameters for the text extractor.\n\nThe text extractor generates dense vector embeddings optimized for semantic similarity search.\nIt uses the E5-Large multilingual model to convert text into 1024-dimensional vectors.\n\nWhen ``source_type`` is ``\"youtube\"``, the extractor first resolves YouTube URLs\nto caption text via yt-dlp before chunking and embedding. Use ``split_by=\"time_segments\"``\nwith ``segment_length_seconds`` to segment captions by time window.","examples":[{"chunk_overlap":0,"chunk_size":1000,"extractor_type":"text_extractor","split_by":"none"},{"chunk_overlap":1,"chunk_size":5,"extractor_type":"text_extractor","split_by":"sentences"},{"extractor_type":"text_extractor","language":"en","segment_length_seconds":120,"source_type":"youtube","split_by":"time_segments"}]},"TextIndexParams":{"properties":{"type":{"type":"string","title":"Type","default":"text"},"tokenizer":{"$ref":"#/components/schemas/TokenizerType","default":"word"},"min_token_len":{"type":"integer","title":"Min Token Len","default":2},"max_token_len":{"type":"integer","title":"Max Token Len","default":15},"lowercase":{"type":"boolean","title":"Lowercase","default":true},"analyzer":{"anyOf":[{"type":"string","enum":["default","english"]},{"type":"null"}],"title":"Analyzer","description":"How the BM25 keyword index splits and normalises the field's text, applied to the stored text and to the query alike. 'default': split on non-alphanumeric characters and lowercase. 'english': the same, then common English stopwords dropped and each word reduced to its Snowball English stem, so 'running' matches 'runs'. Unset keeps the field's current analyzer ('default' for a new field). Changing it reindexes the field. Used by lexical searches (feature_search `lexical`, `lexical_field`)."}},"type":"object","title":"TextIndexParams","description":"Configuration for text index."},"TextSplitStrategy":{"type":"string","enum":["characters","words","sentences","paragraphs","pages","time_segments","markdown","none"],"title":"TextSplitStrategy","description":"Strategy for splitting text into chunks."},"ThemeConfig":{"properties":{"primary_color":{"type":"string","title":"Primary Color","description":"Primary brand color (hex code)","default":"#007AFF","examples":["#007AFF","#FF6B6B","#4ECDC4"]},"secondary_color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Secondary Color","description":"Secondary/accent color (hex code)","examples":["#FF6B6B","#95E1D3"]},"font_family":{"type":"string","title":"Font Family","description":"Font family for text","default":"system-ui, -apple-system, sans-serif","examples":["Inter, sans-serif","Roboto, sans-serif"]},"background_color":{"type":"string","title":"Background Color","description":"Background color (hex code)","default":"#FFFFFF"},"text_color":{"type":"string","title":"Text Color","description":"Primary text color (hex code)","default":"#374151"},"heading_font_family":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Heading Font Family","description":"Optional separate font family for headings","examples":["Georgia, serif","Playfair Display, serif"]},"surface_color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Surface Color","description":"Surface/card background color (hex code)","examples":["#F9FAFB","#F3F4F6"]},"muted_color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Muted Color","description":"Muted/secondary text color (hex code)","examples":["#6B7280","#9CA3AF"]},"border_color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Border Color","description":"Border color for cards and elements (hex code)","examples":["#E5E7EB","#D1D5DB"]},"border_radius":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Border Radius","description":"Default border radius for cards and elements","default":"12px","examples":["8px","12px","16px","24px"]},"card_style":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Card Style","description":"Card visual style: elevated (shadow), flat (no shadow), bordered, or glass (frosted glass effect)","default":"elevated","examples":["elevated","flat","bordered","glass"]},"card_hover_effect":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Card Hover Effect","description":"Card hover animation effect: lift (move up), glow, scale, or none","default":"lift","examples":["lift","glow","scale","none"]}},"type":"object","title":"ThemeConfig","description":"Theme configuration for public retriever UI.\n\nDefines colors, fonts, and visual styling for the public search interface."},"TicketResponse":{"properties":{"ticket_id":{"type":"string","title":"Ticket Id"},"organization_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Id"},"subject":{"type":"string","title":"Subject"},"category":{"$ref":"#/components/schemas/SupportTicketCategory"},"priority":{"$ref":"#/components/schemas/SupportTicketPriority"},"status":{"$ref":"#/components/schemas/SupportTicketStatus"},"created_by":{"anyOf":[{"$ref":"#/components/schemas/SupportActor"},{"type":"null"}]},"message_count":{"type":"integer","title":"Message Count","default":0},"last_message_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Message At"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"messages":{"anyOf":[{"items":{"$ref":"#/components/schemas/MessageResponse"},"type":"array"},{"type":"null"}],"title":"Messages"}},"type":"object","required":["ticket_id","subject","category","priority","status"],"title":"TicketResponse"},"TierAuditInfo":{"properties":{"tier_num":{"type":"integer","title":"Tier Num","description":"Zero-based index of the tier."},"submitted":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Submitted","description":"Objects submitted to this tier. None when not yet recorded, which is the normal state for a tier still in flight."},"processed":{"type":"integer","title":"Processed","description":"Objects that produced a document.","default":0},"failed":{"type":"integer","title":"Failed","description":"Objects recorded in failed_documents.","default":0},"skipped":{"type":"integer","title":"Skipped","description":"Objects deliberately not processed.","default":0},"lost":{"type":"integer","title":"Lost","description":"max(0, submitted - processed - failed - skipped), and 0 when the tier balances. Above 0 means objects were submitted and are absent from BOTH processed and failed, which is the case worth escalating.","default":0},"balanced":{"type":"boolean","title":"Balanced","description":"True only when submitted is known AND equals processed + failed + skipped.","default":false},"notes":{"items":{"type":"string"},"type":"array","title":"Notes","description":"Human-readable notes recorded while auditing the tier."},"durability":{"anyOf":[{"type":"string","enum":["confirmed","lagging","untracked","frontier_unknown"]},{"type":"null"}],"title":"Durability","description":"Write-durability verdict for this tier. 'confirmed' means the namespace's durable frontier had caught up to the highest write this batch recorded. 'lagging' means it had not, and that is the only value that downgrades the tier to COMPLETED_WITH_ERRORS, so it is how you tell a durability lag apart from lost rows. 'untracked' means the batch recorded no durably-tracked write to confirm. 'frontier_unknown' means the frontier could not be read, and a tier is never downgraded on that. Null means no verdict was recorded, which includes the single-tier finalize path that can downgrade without writing an audit at all. Null is not a statement that the writes are durable."}},"type":"object","required":["tier_num"],"title":"TierAuditInfo","description":"Per-tier completion accounting, as returned on the wire.\n\nMirrors the ``TierAudit`` dataclass in\n``shared/batches/durability/audit.py``, which is what actually computes and\npersists these numbers. It is MIRRORED rather than imported because that\nmodule pulls in the Mongo provider, and this one is imported by the response\nmodels. ``test_tier_audit_wire_contract.py`` asserts the two field sets stay\nidentical, so a rename on either side fails a test instead of silently\nemptying a field for every consumer."},"TierDiagnostic":{"properties":{"tier_num":{"type":"integer","title":"Tier Num","description":"Tier number"},"task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id","description":"Task ID for this tier"},"status":{"type":"string","title":"Status","description":"Tier status (PENDING, PROCESSING, COMPLETED, FAILED)"},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At","description":"When tier started"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"When tier completed"},"duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Seconds","description":"Duration in seconds"},"progress":{"anyOf":[{"$ref":"#/components/schemas/TaskProgress"},{"type":"null"}],"description":"Progress information"},"ray_job_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ray Job Id","description":"Ray job ID"},"ray_dashboard_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ray Dashboard Url","description":"Link to Ray dashboard"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if failed"},"error_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Type","description":"Error type if failed"},"requires_gpu":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Requires Gpu","description":"Whether this tier's Ray job targets a GPU worker group. GPU jobs may wait minutes for a scale-from-zero node to come up plus image pull, so this widens the cold-start window before a no-progress tier is flagged stuck."},"ray_job_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ray Job Status","description":"Last observed Ray job status (RUNNING, PENDING, SUCCEEDED, FAILED). PENDING means the job is queued waiting for a worker — i.e. the cluster may be provisioning rather than the job being stuck."},"submission_params":{"anyOf":[{"$ref":"#/components/schemas/SubmissionParams"},{"type":"null"}],"description":"What the tier was submitted to the engine with: deployment mode, GPU and memory request, image, extractor name and version, priority. Present on tiers submitted through the engine and absent on fast-path tiers. A tier that never went through the engine has none."}},"type":"object","required":["tier_num","status"],"title":"TierDiagnostic","description":"Diagnostic information for a single tier."},"TierLimits":{"properties":{"requests_per_minute":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Requests Per Minute","description":"Maximum requests per minute (None = unlimited)"},"requests_per_hour":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Requests Per Hour","description":"Maximum requests per hour (None = unlimited)"},"requests_per_day":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Requests Per Day","description":"Maximum requests per day (None = unlimited)"},"requests_per_month":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Requests Per Month","description":"Maximum requests per month (None = unlimited)"}},"type":"object","title":"TierLimits","description":"Rate limits and quotas for a subscription tier."},"TierTaskInfo":{"properties":{"scoped_sources":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Scoped Sources","description":"OPTIONAL. How many source collections this tier read for the batch's own objects only, summed over its extractor groups. 0 means every source was read in full. Set on collection-sourced tiers of a bucket batch.","examples":[0,1,2]},"skipped_collection_reasons":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Skipped Collection Reasons","description":"OPTIONAL. Why a collection of this tier submitted no work, keyed by collection id. 'scoped_read_empty' means none of the batch's objects has documents in that collection's sources. Empty when no collection was skipped for a recorded reason.","examples":[{},{"col_frames":"scoped_read_empty"}]},"replace_cleanup_skipped_collections":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Replace Cleanup Skipped Collections","description":"OPTIONAL. For dedup_strategy replace: collections of this tier whose old documents were left in place because their extractor job did not end COMPLETED or COMPLETED_WITH_ERRORS (for example it failed or was still pending).","examples":[[],["col_frames"]]},"tier_num":{"type":"integer","minimum":0.0,"title":"Tier Num","description":"REQUIRED. Zero-based tier number indicating the processing stage. Tier 0 = initial bucket-to-collection processing (bucket objects as source). Tier N (N > 0) = collection-to-collection processing (upstream documents as source). Used to determine processing order and identify which stage a task represents. Example: In a 5-tier pipeline (bucket → chunks → frames → scenes → summaries), chunks=tier 0, frames=tier 1, scenes=tier 2, summaries=tier 3.","examples":[0,1,2]},"task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id","description":"OPTIONAL. Unique task identifier for this tier's processing task. None if tier has not yet started (status=PENDING). Assigned when tier processing begins (status=IN_PROGRESS). Used to query task status via GET /v1/tasks/{task_id}. Format: 'task_' prefix followed by secure token. Generated using generate_secure_token() from shared.utilities.helpers.","examples":["task_tier0_abc123","task_tier1_def456","task_tier2_ghi789"]},"status":{"$ref":"#/components/schemas/TaskStatusEnum","description":"REQUIRED. Current processing status of this tier's task. Lifecycle: PENDING → IN_PROGRESS → COMPLETED/FAILED. PENDING: Tier scheduled but not yet started. IN_PROGRESS: Tier currently processing documents. COMPLETED: Tier successfully processed all documents. FAILED: Tier encountered an error and stopped processing. Used to determine overall batch status and whether to proceed to next tier.","default":"PENDING","examples":["PENDING","IN_PROGRESS","COMPLETED","FAILED"]},"collection_ids":{"items":{"type":"string"},"type":"array","minItems":1,"title":"Collection Ids","description":"REQUIRED. List of collection IDs being processed in this tier. Flattened from extractor_jobs for convenience. Each tier can process one or more collections in parallel. Collections in the same tier have no dependencies on each other. Format: Collection IDs as defined when collections were created. Minimum 1 collection per tier. Example: Tier 1 might process ['col_frames_30fps', 'col_frames_60fps'] in parallel.","examples":[["col_chunks"],["col_frames","col_scenes"],["col_summaries"]]},"extractor_jobs":{"items":{"$ref":"#/components/schemas/ExtractorJobInfo"},"type":"array","title":"Extractor Jobs","description":"List of extractor jobs for this tier (one per unique feature_extractor_type). NEW as of 2025-12-31: Tiers now support multiple Ray jobs. Empty list for backwards compatibility with old batches. Tier completes when ALL extractor_jobs reach COMPLETED status."},"source_type":{"type":"string","title":"Source Type","description":"REQUIRED. Type of data source for this tier's processing. 'bucket': Tier 0 processing where source is bucket objects from the objects table. 'collection': Tier N+ processing where source is documents from upstream collection(s). Determines how the API prepares the input dataset manifest for the Engine. Bucket sources query the objects table and include file blobs. Collection sources query the documents table and include processed features.","examples":["bucket","collection"]},"source_collection_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Source Collection Ids","description":"OPTIONAL for tier 0 (must be None). REQUIRED for tier N+ (N > 0). List of upstream collection IDs that provide documents as input to this tier. Typically contains collection IDs from the previous tier (tier_num - 1). Used by the API to query documents from these collections for processing. These upstream documents are converted to a Parquet manifest for the Engine. Example: If tier 1 processes 'col_frames' and sources from tier 0's 'col_chunks', then source_collection_ids=['col_chunks'].","examples":[["col_chunks"],["col_frames"],["col_scenes","col_objects"]]},"parent_task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parent Task Id","description":"OPTIONAL. Task ID of the previous tier (tier_num - 1) that processed before this tier. Used to link tiers together for audit trail and lineage tracking. None for tier 0 (no parent). Enables queries like 'show all tiers that processed after tier 0' or 'trace back through all parent tiers to find the original batch'. Format: Same as task_id (e.g., 'task_tier0_abc123').","examples":["task_tier0_abc123","task_tier1_def456"]},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At","description":"OPTIONAL. ISO 8601 timestamp when this tier began processing. None if tier has not yet started (status=PENDING). Set using current_time() from shared.utilities.helpers when tier starts. Used to calculate tier processing duration and identify long-running tiers. Example: '2025-11-03T10:00:00Z'.","examples":["2025-11-03T10:00:00Z","2025-11-03T14:30:15Z"]},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"OPTIONAL. ISO 8601 timestamp when this tier finished processing (success or failure). None if tier has not yet completed (status=PENDING or IN_PROGRESS). Set using current_time() from shared.utilities.helpers when tier completes. Used to calculate tier processing duration (completed_at - started_at). Set for both COMPLETED and FAILED statuses. Example: '2025-11-03T10:05:00Z'.","examples":["2025-11-03T10:05:00Z","2025-11-03T14:35:42Z"]},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms","description":"OPTIONAL. Processing duration in milliseconds for this tier. Calculated as (completed_at - started_at) when tier completes. None if tier has not yet completed or if started_at was not set. Provides a pre-computed duration for easy querying without timestamp math. Set for both COMPLETED and FAILED statuses.","examples":[300000.0,5000.5,12345.67]},"errors":{"items":{"$ref":"#/components/schemas/BatchErrorDetail"},"type":"array","title":"Errors","description":"OPTIONAL. List of detailed errors that occurred during tier processing. Empty list if tier succeeded or has not yet completed. Each error includes: error_type, message, component, stage, traceback, timestamp. Multiple errors may occur if different documents fail with different issues. Used for detailed error analysis, debugging, and intelligent retry logic. Example: Multiple documents failing with different errors (dependency vs auth). For backward compatibility, check if list is empty for success/in-progress status.","examples":[[],[{"affected_count":5,"component":"VertexMultimodalService","error_type":"dependency","message":"Missing required package: google-genai","recovery_suggestion":"Install google-genai package","stage":"gemini_extraction"}],[{"affected_count":10,"component":"VertexMultimodalService","error_type":"authentication","message":"Invalid Vertex AI credentials"},{"affected_count":3,"component":"GeminiExtractor","error_type":"validation","message":"Schema validation failed"}]]},"error_summary":{"anyOf":[{"additionalProperties":{"type":"integer"},"type":"object"},{"type":"null"}],"title":"Error Summary","description":"OPTIONAL. Aggregated summary of errors by error type. Maps error_type (category) to count of affected DOCUMENTS. None has THREE causes, not two: the tier succeeded, the tier has not yet completed, OR the tier FAILED AT TIER LEVEL — it wrote zero documents (infrastructure failure, job crash, no resolvable inputs), so no individual document carries an error and this histogram is legitimately empty. So None does NOT mean 'no errors', and None alongside COMPLETED_WITH_ERRORS is NOT a contradiction. For a tier-level failure the diagnosis is in `failure_reason` and `tier_tasks[].error`, which carry the Ray job id and where to look. Provides quick overview of error distribution without parsing full error list. Example: {'dependency': 5, 'authentication': 10, 'validation': 3} means 5 documents failed with dependency errors, 10 with auth errors, 3 with validation. Automatically generated from errors list for convenience. Used for batch health monitoring and error trend analysis.","examples":[null,{"dependency":5},{"authentication":10,"runtime":2,"validation":3}]},"performance":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Performance","description":"OPTIONAL. Performance metrics summary for this tier's execution. Automatically populated after tier completion by collecting data from the analytics store. Contains: total_time_ms (total execution time), avg_latency_ms (average operation latency), bottlenecks (list of slowest operations), stage_count (number of profiled stages). Used for troubleshooting performance issues and identifying bottlenecks. None if tier has not completed or performance data collection failed. Populated asynchronously (non-blocking, best-effort).","examples":[{"avg_latency_ms":234.56,"bottlenecks":[{"avg_time_ms":113.58,"execution_count":50,"max_time_ms":234.56,"stage_name":"gcs_batch_upload_all_segments","total_time_ms":5678.9},{"avg_time_ms":69.14,"execution_count":50,"max_time_ms":123.45,"stage_name":"pipeline_run","total_time_ms":3456.78}],"stage_count":5,"timestamp":"2025-11-06T10:05:00Z","total_time_ms":12345.67}]},"ray_job_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ray Job Id","description":"OPTIONAL. Ray/Anyscale job ID for tracking the infrastructure-level processing job. None if tier has not yet started or if the job ID was not returned by the engine. Set when tier processing is submitted to Ray/Anyscale via the Engine. Used for cancelling running jobs and monitoring infrastructure-level status. Format: 'raysubmit_' prefix followed by job identifier (e.g., 'raysubmit_9pDAyZbd5MN281TB'). This is the job ID that appears in the Ray/Anyscale dashboard.","examples":["raysubmit_9pDAyZbd5MN281TB","raysubmit_ABC123XYZ456"]},"ray_job_started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Ray Job Started At","description":"OPTIONAL. When the Ray job itself began running, as reported by Ray/KubeRay (RayJob CR status.startTime), NOT when the API claimed the tier. Differs from started_at, which is stamped by the background worker before the job is even submitted, so started_at includes manifest build and submission time. Use this to separate control-plane overhead from actual engine execution.","examples":[null,"2026-08-15T10:36:31.000Z"]},"ray_job_completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Ray Job Completed At","description":"OPTIONAL. When the Ray job finished, as reported by Ray/KubeRay (RayJob CR status.endTime). Paired with ray_job_started_at; the difference between them is the engine-side execution time, whereas completed_at - started_at also contains API and background-worker time.","examples":[null,"2026-08-15T10:46:24.000Z"]},"requires_gpu":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Requires Gpu","description":"OPTIONAL. Whether this tier's Ray job was scheduled onto a GPU worker group. Populated at submit time from the engine's requires_gpu decision (built-in extractors default to GPU; custom plugins opt in via compute_profile). Lets users confirm a custom plugin actually landed on a GPU without kubectl access.","examples":[null,true,false]},"worker_groups":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Worker Groups","description":"OPTIONAL. Names of the Ray worker groups this tier's job is eligible to run on. Derived from the compute profile chosen at submit time (e.g., ['gpu-workers'] for requires_gpu=True, ['cpu-workers'] otherwise). Surfaces resource allocation in the batch response so users don't need kubectl access to debug scheduling.","examples":[null,["gpu-workers"],["cpu-workers"]]},"celery_task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id","description":"OPTIONAL. Background task ID for tracking the worker processing this tier. None if tier has not yet started or is not processed via background task. Set when the tier processing task is triggered. Used for revoking pending/running tasks during batch cancellation or deletion. Format: UUID string (e.g., 'a1b2c3d4-e5f6-7890-abcd-ef1234567890').","examples":["a1b2c3d4-e5f6-7890-abcd-ef1234567890"]},"source_documents_fetched":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Source Documents Fetched","description":"OPTIONAL. Number of documents fetched from source collection(s) for Tier N processing. For Tier 0 (bucket source), this is the number of objects from the bucket. For Tier N+ (collection source), this is the count of documents from upstream collection(s). Set at the start of tier artifact building in build_tier_n_artifacts(). If 0, the source collection is empty - check upstream tier completion.","examples":[100,0,1500]},"documents_after_source_filter":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Documents After Source Filter","description":"OPTIONAL. Number of documents remaining after applying source_filters. source_filters are optional conditions that exclude documents from processing. If this is 0 but source_documents_fetched > 0, your source_filters are too restrictive. Check that filter fields exist in source documents and conditions match expected values.","examples":[95,0,1200]},"documents_missing_input_fields":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Documents Missing Input Fields","description":"OPTIONAL. Number of documents missing required input_mapping fields. input_mappings define which fields from source documents map to extractor inputs. If this equals documents_after_source_filter, ALL documents are missing required fields. Common cause: upstream extractor didn't produce expected output (e.g., video_segment_url). Check upstream extractor configuration and verify output field names.","examples":[0,95,50]},"documents_submitted_to_engine":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Documents Submitted To Engine","description":"OPTIONAL. Number of documents actually submitted to the Ray/Engine for processing. This is documents_after_source_filter minus documents_missing_input_fields. If 0, no documents were sent to the engine - check source_filters and input_mappings. If > 0 but documents_written = 0, the engine failed to process documents.","examples":[95,0,1150]},"documents_written":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Documents Written","description":"OPTIONAL. Documents THIS BATCH wrote in this tier. Sourced from the tier's extractor jobs (extractor_jobs[].documents_written), which report per batch. It is NOT a collection total: do not subtract documents_before_processing from it. If 0 but documents_submitted_to_engine > 0, check tier errors for processing failures.","examples":[95,0,1150]},"documents_replaced":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Documents Replaced","description":"OPTIONAL. For dedup_strategy replace: documents this tier wrote for objects it replaced. Absent when the batch is not a replace."},"documents_deleted":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Documents Deleted","description":"OPTIONAL. For dedup_strategy replace: existing documents of the replaced objects removed from this tier's collections after the new ones were written. Absent when the batch is not a replace."},"documents_before_processing":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Documents Before Processing","description":"OPTIONAL. Document count in target collection(s) before this tier started processing. DIAGNOSTIC ONLY. Do NOT compute (documents_written - documents_before_processing): documents_written is already this batch's own output, and this field is a WHOLE-COLLECTION count, so the difference attributes concurrent batches' writes to this one . It is retained as the input to a fallback used only when no extractor reported a count.","examples":[0,50,1000]},"last_activity_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Activity At","description":"OPTIONAL. Timestamp of the last BatchJobPoller heartbeat confirming the tier's Ray job(s) were non-terminal (RUNNING or PENDING). Updated approximately every 10 seconds while the tier is IN_PROGRESS. A stale last_activity_at (minutes old) indicates the job may be stalled or lost. Use this to distinguish an actively running batch from one that is silently stuck."},"ray_job_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ray Job Status","description":"OPTIONAL. Last observed Ray job status as of last_activity_at. Values: 'RUNNING' (actively processing), 'PENDING' (queued, not yet started), 'SUCCEEDED', 'FAILED', 'DEDUP_SKIPPED' (every object was already processed, so no job ran), 'REEXTRACT_GUARD_SKIPPED' (the organization does not allow re-extraction, so this tier did not run and wrote nothing; see status_message), 'SCOPED_EMPTY' (none of the batch's objects has documents in this tier's sources). For multi-extractor tiers, see extractor_jobs[].ray_job_status for per-job granularity.","examples":["RUNNING","PENDING"]},"ray_job_logs":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ray Job Logs","description":"OPTIONAL. Persisted Ray job logs captured when the job reached a terminal state (SUCCEEDED or FAILED). Contains the last 500 lines of the head pod's stdout. Populated automatically by the batch poller before pods are cleaned up by K8s, so logs remain available for debugging after the job's infrastructure is gone."},"ray_job_logs_captured_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Ray Job Logs Captured At","description":"OPTIONAL. Timestamp when ray_job_logs were captured."},"submission_params":{"anyOf":[{"$ref":"#/components/schemas/SubmissionParams"},{"type":"null"}],"description":"OPTIONAL. Parameters used for the first Ray/GKE job submission in this tier. For per-extractor params, see extractor_jobs[].submission_params."},"infrastructure_events":{"items":{"$ref":"#/components/schemas/InfrastructureDetail"},"type":"array","title":"Infrastructure Events","description":"Infrastructure-level events correlated with this tier's execution (OOM, preemption, etc.)."},"audit":{"anyOf":[{"$ref":"#/components/schemas/TierAuditInfo"},{"type":"null"}],"description":"OPTIONAL. Tier completion invariant audit, persisted by the complete_tier callback. Phase 1 of INGESTION_RELIABILITY_PLAN.md. ``lost > 0`` means objects were submitted but absent from both processed_objects and failed_documents — investigate via the /audit endpoint."},"audit_override_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Audit Override Reason","description":"OPTIONAL. Set when the audit overrode the orchestrator-supplied tier status (e.g. promoted COMPLETED → COMPLETED_WITH_ERRORS because of lost objects)."}},"type":"object","required":["tier_num","source_type"],"title":"TierTaskInfo","description":"Tracking information for a single collection processing tier's task.\n\nIn multi-tier collection processing, each tier represents a processing stage in the\ndecomposition pipeline (e.g., bucket → chunks → frames → scenes). Each tier gets its\nown independent task for granular monitoring, status tracking, and retry capabilities.\n\nUse Cases:\n    - Monitor progress of individual tiers in a multi-tier batch\n    - Retry failed tiers without reprocessing successful ones\n    - Track lineage of processing through parent_task_id linkage\n    - Query task status for specific processing stages\n\nTier Definitions:\n    - Tier 0: Bucket → Collection (bucket objects as source)\n    - Tier N (N > 0): Collection → Collection (upstream collection documents as source)\n\nLifecycle:\n    1. Created with status=PENDING when tier is scheduled\n    2. Updated to status=IN_PROGRESS when processing starts (task_id assigned)\n    3. Finalized to status=COMPLETED or status=FAILED when tier completes\n\nRequirements:\n    - tier_num: REQUIRED. Zero-based tier number indicating processing stage\n    - task_id: OPTIONAL. None until tier processing starts\n    - status: REQUIRED. Defaults to PENDING\n    - collection_ids: REQUIRED. Collections being processed in this tier\n    - source_type: REQUIRED. \"bucket\" for tier 0, \"collection\" for tier N+\n    - source_collection_ids: OPTIONAL. Required for tier N+ (collection sources)\n    - parent_task_id: OPTIONAL. Links to previous tier for audit trail\n    - started_at: OPTIONAL. Set when tier processing begins\n    - completed_at: OPTIONAL. Set when tier processing finishes\n    - error: OPTIONAL. Set if tier fails with error details","examples":[{"collection_ids":["col_chunks"],"completed_at":"2025-11-03T10:05:00Z","description":"Tier 0 task (completed): Bucket → Collection","errors":[],"ray_job_id":"raysubmit_ABC123","source_type":"bucket","started_at":"2025-11-03T10:00:00Z","status":"COMPLETED","task_id":"task_tier0_abc123","tier_num":0},{"collection_ids":["col_frames"],"description":"Tier 1 task (in progress): Collection → Collection","errors":[],"parent_task_id":"task_tier0_abc123","ray_job_id":"raysubmit_DEF456","source_collection_ids":["col_chunks"],"source_type":"collection","started_at":"2025-11-03T10:05:00Z","status":"IN_PROGRESS","task_id":"task_tier1_def456","tier_num":1},{"collection_ids":["col_scenes"],"description":"Tier 2 task (pending): Not yet started","errors":[],"source_collection_ids":["col_frames"],"source_type":"collection","status":"PENDING","tier_num":2},{"collection_ids":["col_frames"],"completed_at":"2025-11-03T10:06:30Z","description":"Tier 1 task (failed): Processing errors","error_summary":{"dependency":2},"errors":[{"affected_count":2,"affected_document_ids":["doc_123","doc_456"],"component":"VertexMultimodalService","error_type":"dependency","message":"Missing required package: google-genai","recovery_suggestion":"Install google-genai package: pip install google-genai","stage":"gemini_extraction","timestamp":"2025-11-03T10:06:00Z"}],"parent_task_id":"task_tier0_abc123","ray_job_id":"raysubmit_XYZ789","source_collection_ids":["col_chunks"],"source_type":"collection","started_at":"2025-11-03T10:05:00Z","status":"FAILED","task_id":"task_tier1_xyz789","tier_num":1}]},"TieringIdleDays":{"properties":{"cold":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Cold","description":"Days without a use before the cold tier."},"frozen":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Frozen","description":"Days without a use before the frozen tier."}},"additionalProperties":false,"type":"object","title":"TieringIdleDays"},"TieringOverride":{"properties":{"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled","description":"Turn tiering on or off here; unset inherits from above."},"idle_days":{"anyOf":[{"$ref":"#/components/schemas/TieringIdleDays"},{"type":"null"}],"description":"Idle windows here; unset parts inherit from above."},"exempt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Exempt","description":"Opt out of tiering, with the reason (for example a legal hold). An exempt namespace or collection is never demoted."}},"additionalProperties":false,"type":"object","title":"TieringOverride","description":"A namespace's or collection's override of its data class's tiering."},"TieringRule":{"properties":{"rule_type":{"type":"string","enum":["auto_evict","auto_archive","auto_rehydrate"],"title":"Rule Type"},"enabled":{"type":"boolean","title":"Enabled","default":false},"threshold_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Threshold Days"}},"type":"object","required":["rule_type"],"title":"TieringRule","description":"A single automatic storage tiering rule (V1: stored but not enforced)."},"TigrisAccessKeyCredentials":{"properties":{"type":{"type":"string","const":"access_key","title":"Type","default":"access_key"},"access_key_id":{"type":"string","minLength":1,"title":"Access Key Id","description":"REQUIRED. Tigris access key ID for authentication. Obtain from: Tigris Console > Access Keys","examples":["tid_AzureDiamond"]},"secret_access_key":{"type":"string","minLength":1,"title":"Secret Access Key","description":"REQUIRED. Tigris secret access key for authentication. SECURITY: This is a secret credential, redacted on read. Never log or expose this value. Obtain from: Tigris Console when creating access key (shown only once)"}},"type":"object","required":["access_key_id","secret_access_key"],"title":"TigrisAccessKeyCredentials","description":"Tigris Data access key credentials.\n\nTigris uses S3-compatible authentication with access keys.\nThe Tigris dashboard at https://console.tigris.dev issues the access keys.\n\nPrerequisites:\n    - Create a Tigris account at https://www.tigrisdata.com\n    - Create a bucket in the Tigris console\n    - Generate access keys from the dashboard\n\nSecurity:\n    - secret_access_key is a secret credential, redacted on read\n    - Rotate keys regularly via the Tigris dashboard\n    - Use bucket-scoped keys when possible for least privilege\n\nUse Cases:\n    - Globally distributed object storage\n    - Low-latency content delivery\n    - S3-compatible workflows with zero egress fees"},"TigrisConfig":{"properties":{"provider_type":{"type":"string","const":"tigris","title":"Provider Type","default":"tigris"},"credentials":{"$ref":"#/components/schemas/TigrisAccessKeyCredentials","description":"REQUIRED. Tigris access key credentials. Obtain from Tigris Console at https://console.tigris.dev"},"region":{"type":"string","title":"Region","description":"Region for Tigris. Typically 'auto' for automatic global distribution. Tigris automatically distributes data globally, so region is usually 'auto'. Default: auto","default":"auto","examples":["auto"]},"endpoint_url":{"type":"string","title":"Endpoint Url","description":"Tigris S3-compatible endpoint URL. Default: https://fly.storage.tigris.dev This is the standard Tigris endpoint and usually doesn't need to be changed.","default":"https://fly.storage.tigris.dev","examples":["https://fly.storage.tigris.dev"]}},"type":"object","required":["credentials"],"title":"TigrisConfig","description":"Tigris Data globally distributed object storage configuration.\n\nTigris is an S3-compatible object storage service with automatic global\ndistribution, zero egress fees, and built-in CDN capabilities. It uses\nthe AWS S3 API, making integration straightforward.\n\nKey Features:\n    - S3-compatible API (drop-in replacement)\n    - Automatic global data distribution\n    - Zero egress fees\n    - Built-in CDN and caching\n    - Strong consistency guarantees\n\nAuthentication:\n    - Access keys only (similar to S3 access keys)\n    - No IAM role assumption (Tigris is not AWS)\n\nRequirements:\n    - Tigris account with access keys\n    - Bucket created in Tigris console\n    - Network connectivity to fly.storage.tigris.dev\n\nUse Cases:\n    - Globally distributed media assets\n    - Low-latency content delivery worldwide\n    - Cost-effective storage with no egress fees\n    - S3-compatible workflows outside AWS","examples":[{"credentials":{"access_key_id":"tid_your_access_key","secret_access_key":"tsec_your_secret_key","type":"access_key"},"description":"Standard Tigris configuration","endpoint_url":"https://fly.storage.tigris.dev","provider_type":"tigris","region":"auto"},{"credentials":{"access_key_id":"tid_example_key","secret_access_key":"tsec_example_secret","type":"access_key"},"description":"Tigris with explicit endpoint (default)","provider_type":"tigris"}]},"TikTokConfig":{"properties":{"provider_type":{"type":"string","const":"tiktok","title":"Provider Type","default":"tiktok"},"credentials":{"$ref":"#/components/schemas/TikTokOAuthCredentials","description":"OAuth credentials for TikTok Content API access."},"scopes":{"items":{"type":"string"},"type":"array","title":"Scopes","description":"OAuth scopes granted during authorization.","default":["user.info.basic","video.list"]}},"type":"object","required":["credentials"],"title":"TikTokConfig","description":"TikTok account configuration via TikTok Content API.\n\nEnables Mixpeek to sync videos from TikTok accounts using the official\nTikTok API. Each video becomes a bucket object with metadata (description,\nlikes, views, shares, comments).\n\nAuthentication:\n    - OAuth 2.0 via TikTok Login Kit\n    - Access tokens expire in 24h (refresh_token flow)\n\nRequirements:\n    - TikTok Developer account with approved app\n    - user.info.basic and video.list scopes\n\nUse Cases:\n    - Sync creator video content for talent analysis\n    - Monitor trending content and competitors\n    - Build video content libraries for multimodal search","examples":[{"credentials":{"access_token":"act.xxx","client_key":"your_client_key","client_secret":"your_client_secret","open_id":"user_open_id","refresh_token":"rft.xxx","token_expires_at":"2025-03-02T00:00:00Z","type":"oauth"},"description":"TikTok account via OAuth","provider_type":"tiktok","scopes":["user.info.basic","video.list"]}]},"TikTokOAuthCredentials":{"properties":{"type":{"type":"string","const":"oauth","title":"Type","default":"oauth"},"client_key":{"type":"string","title":"Client Key","description":"TikTok App Client Key from Developer Portal."},"client_secret":{"type":"string","title":"Client Secret","description":"SECURITY: Secret credential, redacted on read. Never log or expose. TikTok App Client Secret from Developer Portal."},"access_token":{"type":"string","title":"Access Token","description":"SECURITY: Encrypted at rest. TikTok access token (24h validity)."},"refresh_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Refresh Token","description":"SECURITY: Encrypted at rest. Used to obtain new access tokens. Optional: without one the sync skips refreshing and uses access_token."},"token_expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Token Expires At","description":"Access token expiration timestamp."},"open_id":{"type":"string","title":"Open Id","description":"TikTok user's open_id from the authorization response."}},"type":"object","required":["client_key","client_secret","access_token","open_id"],"title":"TikTokOAuthCredentials","description":"Credentials for TikTok Content API OAuth2 authentication.\n\nTikTok uses OAuth2 via TikTok Login Kit. Access tokens are short-lived\n(24 hours) and must be refreshed using the refresh token.\n\nPrerequisites:\n    - TikTok Developer account with an approved app\n    - App must have user.info.basic and video.list scopes\n\nSecurity:\n    - client_secret, access_token, and refresh_token are secret credentials, redacted on read\n    - Access tokens expire in 24h; refresh tokens used for renewal\n    - Token refresh happens automatically during sync execution"},"TimeRange-Input":{"properties":{"start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start","description":"Start of time range (inclusive)."},"end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End","description":"End of time range (inclusive)."}},"type":"object","title":"TimeRange","description":"Time range filter for session queries."},"TokenExchangeRequest":{"properties":{"provider_id":{"type":"string","minLength":1,"title":"Provider Id","description":"The workload identity provider configured on the organization."},"subject_token":{"type":"string","minLength":1,"title":"Subject Token","description":"The OIDC token the workload's platform issued: on Vercel, getVercelOidcToken() or the x-vercel-oidc-token header; on GitHub Actions, core.getIDToken(audience)."},"ttl_seconds":{"anyOf":[{"type":"integer","maximum":3600.0,"minimum":60.0},{"type":"null"}],"title":"Ttl Seconds","description":"Requested key lifetime. Capped at the provider's token_ttl_seconds and at the subject token's own expiry plus the provider lifetime."}},"additionalProperties":false,"type":"object","required":["provider_id","subject_token"],"title":"TokenExchangeRequest","description":"Exchange a workload's OIDC token for a short-lived Mixpeek API key.","examples":[{"provider_id":"wip_abc123","subject_token":"<the workload's OIDC token>"}]},"TokenExchangeResponse":{"properties":{"access_token":{"type":"string","title":"Access Token","description":"The API key. Shown once."},"token_type":{"type":"string","const":"Bearer","title":"Token Type","default":"Bearer"},"expires_in":{"type":"integer","title":"Expires In","description":"Seconds until the key expires."},"expires_at":{"type":"string","format":"date-time","title":"Expires At","description":"When the key expires (UTC)."},"key_id":{"type":"string","title":"Key Id","description":"Identifier of the minted key, for audit."},"organization_id":{"type":"string","title":"Organization Id","description":"Organization the key belongs to."},"permissions":{"items":{"$ref":"#/components/schemas/Permission"},"type":"array","title":"Permissions","description":"Permissions of the key."}},"type":"object","required":["access_token","expires_in","expires_at","key_id","organization_id","permissions"],"title":"TokenExchangeResponse","description":"A short-lived API key. Send it as ``Authorization: Bearer <access_token>``."},"TokenizerType":{"type":"string","enum":["word","whitespace","prefix","multilingual"],"title":"TokenizerType","description":"Tokenizer type."},"ToolInfo":{"properties":{"name":{"type":"string","title":"Name","description":"Tool name"},"description":{"type":"string","title":"Description","description":"Tool description"},"category":{"type":"string","title":"Category","description":"Tool category"},"parameters":{"additionalProperties":true,"type":"object","title":"Parameters","description":"Parameter definitions"},"required_params":{"items":{"type":"string"},"type":"array","title":"Required Params","description":"Required parameters"},"requires_confirmation":{"type":"boolean","title":"Requires Confirmation","description":"Whether the tool requires user confirmation","default":false}},"type":"object","required":["name","description","category"],"title":"ToolInfo","description":"Information about an available agent tool.\n\nAttributes:\n    name: Tool name (use this in available_tools)\n    description: What the tool does\n    category: Tool category (search, read, create, etc.)\n    parameters: Parameter definitions\n    required_params: List of required parameter names\n    requires_confirmation: Whether the tool requires user confirmation before execution"},"TransactionInfo":{"properties":{"record_id":{"type":"string","title":"Record Id","description":"Unique usage-record ID"},"occurred_at":{"type":"string","format":"date-time","title":"Occurred At","description":"When the credits were consumed"},"billing_month":{"type":"string","title":"Billing Month","description":"Billing month (YYYY-MM)"},"credits_consumed":{"type":"integer","title":"Credits Consumed","description":"Credits consumed by this operation"},"cost_usd":{"type":"number","title":"Cost Usd","description":"Approx USD cost (credits * $0.001)"},"operation_type":{"type":"string","title":"Operation Type","description":"Operation that consumed credits (extractor, upload, batch, search)"},"extractor_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Extractor Name","description":"Extractor name, if operation was an extraction"},"resource_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Id","description":"ID of the resource processed (collection/object/batch)"},"resource_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Type","description":"Type of resource processed"},"namespace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Namespace Id","description":"Namespace this charge is attributed to, so the per-row ledger is traceable per namespace for chargeback. None for namespace-less / pre-attribution records."},"app_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"App Id","description":"Canvas App ID, if attributed"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Operation context (tokens, pages, minutes, etc.)"}},"type":"object","required":["record_id","occurred_at","billing_month","credits_consumed","cost_usd","operation_type"],"title":"TransactionInfo","description":"A single credit-usage transaction (per-operation ledger entry)."},"TransactionsListResponse":{"properties":{"transactions":{"items":{"$ref":"#/components/schemas/TransactionInfo"},"type":"array","title":"Transactions","description":"Credit-usage transactions, newest first"},"total":{"type":"integer","title":"Total","description":"Total matching transactions"},"limit":{"type":"integer","title":"Limit","description":"Page size"},"offset":{"type":"integer","title":"Offset","description":"Records skipped"},"has_more":{"type":"boolean","title":"Has More","description":"Whether more transactions exist beyond this page"}},"type":"object","required":["total","limit","offset","has_more"],"title":"TransactionsListResponse","description":"Paginated list of credit-usage transactions (most recent first)."},"TranscodingExtractorParams":{"properties":{"extractor_type":{"type":"string","const":"transcoding_extractor","title":"Extractor Type","description":"Discriminator field. Must be 'transcoding_extractor'.","default":"transcoding_extractor"},"output_codec":{"type":"string","enum":["libx264","libx265"],"title":"Output Codec","description":"Output video codec. libx264 (H.264) for maximum player compatibility; libx265 (H.265) for smaller files.","default":"libx264"},"crf":{"type":"integer","maximum":51.0,"minimum":0.0,"title":"Crf","description":"Constant Rate Factor. Lower is higher quality and larger files. 18-23 is the usual H.264 range; 23 is a good default mezzanine.","default":23},"preset":{"type":"string","enum":["ultrafast","superfast","veryfast","faster","fast","medium","slow","slower","veryslow"],"title":"Preset","description":"FFmpeg encoding speed preset. Slower presets compress better at the same quality but take more CPU time.","default":"medium"},"max_resolution":{"anyOf":[{"type":"integer","maximum":4320.0,"minimum":144.0},{"type":"null"}],"title":"Max Resolution","description":"Cap output height in pixels (width scales proportionally). Set null to keep the source resolution.","default":1080},"audio_codec":{"type":"string","enum":["aac","mp3","copy"],"title":"Audio Codec","description":"Audio codec for the output ('copy' passes audio through).","default":"aac"},"require_native_sdks":{"type":"boolean","title":"Require Native Sdks","description":"If true, fail a RED/ARRI file instead of falling back to plain FFmpeg when the REDline/art-cmd CLI is not installed on the engine image. Leave false to get best-effort conversion.","default":false}},"type":"object","title":"TranscodingExtractorParams","description":"Parameters for the Transcoding Extractor.\n\nTranscodes source video (RED R3D, ARRI RAW, MXF, or any FFmpeg-decodable\nformat) to a web-playable H.264/H.265 MP4 uploaded to object storage.\nThe output document carries the converted file's URL in `converted_url`.","examples":[{"crf":23,"description":"Default mezzanine (H.264, 1080p cap)","extractor_type":"transcoding_extractor","max_resolution":1080,"output_codec":"libx264","preset":"medium"},{"crf":18,"description":"High-quality proxy from RAW camera originals","extractor_type":"transcoding_extractor","max_resolution":2160,"preset":"slow","require_native_sdks":true}]},"TransitionLifecycleRequest":{"properties":{"lifecycle_state":{"$ref":"#/components/schemas/LifecycleState","description":"Target lifecycle state for the collection. active and cold move vectors between the live store and object storage; archived is terminal. frozen refuses every document write while reads, search and export keep working, so a training run can pin the collection. Freezing and unfreezing move no data and complete within the request."},"async_transition":{"type":"boolean","title":"Async Transition","description":"If False, block until the transition completes. Ignored for frozen, which moves no data and always completes within the request.","default":true}},"type":"object","required":["lifecycle_state"],"title":"TransitionLifecycleRequest"},"TransitionPath":{"properties":{"path":{"items":{"type":"string"},"type":"array","minItems":2,"title":"Path","description":"Ordered sequence of steps","examples":[["inquiry","followup","closed_won"],["draft","review","published"]]},"count":{"type":"integer","minimum":0.0,"title":"Count","description":"Number of sequences following this path"},"percentage":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Percentage","description":"Percentage of total completing sequences"},"avg_duration_sec":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Duration Sec","description":"Average time to complete this path (seconds)"}},"type":"object","required":["path","count","percentage"],"title":"TransitionPath","description":"Represents a multi-step path between two steps.\n\nTracks the intermediate steps documents take when transitioning from\nfrom_step to to_step.\n\nAttributes:\n    path: Ordered sequence of steps (e.g., [\"inquiry\", \"followup\", \"proposal\", \"closed_won\"])\n    count: Number of sequences that followed this exact path\n    percentage: Percentage of all completing sequences that used this path\n    avg_duration_sec: Average time to complete this path\n\nExample:\n    ```python\n    # 30% of successful conversions took this 4-step path\n    TransitionPath(\n        path=[\"inquiry\", \"followup\", \"proposal\", \"closed_won\"],\n        count=120,\n        percentage=34.3,\n        avg_duration_sec=604800.0  # 7 days average\n    )\n    ```"},"TriggerActionType":{"type":"string","enum":["cluster","taxonomy_enrichment","batch_rerun","collection_trigger","retriever_execution","alert_evaluation"],"title":"TriggerActionType","description":"Type of action to execute when trigger fires.\n\nSupported action types:\n- **cluster**: Execute clustering on a cluster definition\n- **taxonomy_enrichment**: Apply taxonomy enrichment to a collection\n- **batch_rerun**: Re-execute a completed/failed batch\n- **collection_trigger**: Re-process a collection from its sources\n- **retriever_execution**: Execute a saved retriever with fixed inputs on a\n  schedule (a canary / search probe), optionally judged against acceptance\n  criteria (latency ceilings, minimum results, per-document LLM verdicts)\n- **alert_evaluation**: Evaluate a retriever alert in the trigger's namespace\n  on the trigger's schedule. The periodic alert sweep then skips that alert\n  in that namespace, so it runs on this schedule only"},"TriggerCollectionRequest":{"properties":{"include_buckets":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Include Buckets","description":"Limit processing to objects from these specific buckets (IDs or names). Only applies to bucket-sourced collections. If not provided, all configured source buckets are used."},"include_collections":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Include Collections","description":"Limit processing to documents from these specific collections (IDs or names). Only applies to collection-sourced collections. If not provided, all configured source collections are used."},"object_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Object Ids","description":"Limit processing to these specific object IDs. Only applies to bucket-sourced collections. This is a convenience shorthand — equivalent to using source_filters with {\"AND\": [{\"field\": \"object_id\", \"operator\": \"in\", \"value\": [...]}]}."},"source_filters":{"anyOf":[{"$ref":"#/components/schemas/LogicalOperator-Input"},{"type":"null"}],"description":"Field-level filters for objects (bucket-sourced) or documents (collection-sourced). Uses LogicalOperator format (AND/OR/NOT). Use this to filter by metadata fields, status, or any other object/document properties.","examples":[{"AND":[{"field":"status","operator":"eq","value":"pending"}]},{"AND":[{"field":"object_id","operator":"in","value":["obj_1","obj_2"]}]}]},"dedup_strategy":{"anyOf":[{"$ref":"#/components/schemas/DedupStrategy"},{"type":"null"}],"description":"How to handle sources already processed in prior batches. `skip` (default): skip sources already materialized in this collection. `replace`: delete existing documents for the re-processed sources and re-materialize them — this also clears the processed-objects resume ledger, so use it to recover a collection stuck with ledger entries but 0 materialized documents (the orphan/divergence state). `force`: process regardless, allowing duplicates."},"inputs":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Inputs","description":"Values for the retriever transform's INPUT fields, for a collection built by a retriever transform from source collections. The build runs the transform's retriever with these inputs, so one view definition can build per scope: trigger it once per brand, team or tenant with that scope's values, and combine source_filters to read only that scope's source documents. Checked against the transform retriever's input_schema like an execute request: a missing required field is a 422, an unknown key a 400, and a field left out takes its schema default. Refused for a collection with no retriever transform, and together with dedup_strategy 'replace', which could delete rows another scope's build wrote from the same sources. A transform's own templates can write an input into each output row, and a composite unique_id_field keeps one row per scope and source. A build adds and updates rows and deletes none: when a source document leaves a scope, its row for that scope stays until you delete it with DELETE /v1/collections/{collection_id}/documents/batch. A build that starts without inputs (an ingest into a source collection, an alert, a backfill or a refresh) fails its job when the retriever requires an input.","examples":[{"brand_id":"brand_42"}]},"reembed":{"anyOf":[{"$ref":"#/components/schemas/StoredTextReembedRequest"},{"type":"null"}],"description":"Re-embed stored document text instead of reprocessing sources. When set, no batch is created: the collection's existing documents are read, the selected embedding outputs are recomputed from the text each document already stores, and the vectors are written back onto the same documents. Progress is reported on the returned task. Source selection fields (include_buckets, include_collections, object_ids, source_filters, dedup_strategy) cannot be combined with it.","examples":[{"dry_run":true,"outputs":["transcription_embedding"]},{"document_ids":["doc_1","doc_2"],"outputs":["transcription_embedding"]}]}},"type":"object","title":"TriggerCollectionRequest","description":"Request to trigger (re)processing through a collection.\n\n**For bucket-sourced collections (tier 0):**\nDiscovers objects from source bucket(s) and creates a batch for processing.\nUse `include_buckets` to limit which source buckets to process from.\n\n**For collection-sourced collections (tier N):**\nProcesses existing documents from upstream collection(s).\nUse `include_collections` to limit which source collections to process from.\n\nUse `source_filters` for field-level filtering on objects or documents.\n\n**Document Overwrite Behavior:**\n- If source bucket has `unique_key` configured: Documents are UPSERTED (overwrites existing)\n- If source bucket has NO `unique_key`: New documents are CREATED (may cause duplicates)\n\nTo enable idempotent re-processing, configure `unique_key` on the source bucket."},"TriggerCollectionResponse":{"properties":{"batch_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Batch Id","description":"ID of the created batch for tracking progress. Null for a stored-text re-embed (`reembed`), which runs as a task, not a batch."},"task_id":{"type":"string","title":"Task Id","description":"Task ID for monitoring via GET /v1/tasks/{task_id}."},"collection_id":{"type":"string","title":"Collection Id","description":"ID of the collection being processed."},"source_bucket_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Source Bucket Ids","description":"Bucket IDs that objects were discovered from (bucket-sourced collections)."},"source_collection_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Source Collection Ids","description":"Collection IDs that documents were read from (collection-sourced collections)."},"object_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Object Count","description":"Number of objects in the trigger (bucket-sourced collections). Null when the trigger answered before reading the bucket; the count is then on the task, as `additional_data.trigger.object_count`."},"batch_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Batch Ids","description":"All batch IDs created for this trigger. Present when a large load was auto-chunked into multiple right-sized batches; `batch_id` is the first of these. Null (absent) for a single-batch trigger, and when the trigger answered before reading the bucket: the task then lists them as `additional_data.trigger.batch_ids`."},"task_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Task Ids","description":"Task IDs for each created batch, aligned with `batch_ids`."},"batch_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Batch Count","description":"Number of batches created. Null for a single-batch trigger; set when the load was auto-chunked into multiple batches."},"document_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Document Count","description":"Total number of documents to process (collection-sourced collections)."},"total_tiers":{"type":"integer","title":"Total Tiers","description":"Number of processing tiers in the DAG."},"message":{"type":"string","title":"Message","description":"Human-readable status message."},"estimate":{"anyOf":[{"$ref":"#/components/schemas/BatchCostEstimate"},{"type":"null"}],"description":"OPTIONAL. What this trigger was estimated to cost when it was submitted: the same calculation submit bills by, read from each batch before it ran, summed over the batches when the load was split. Absent for a collection-sourced trigger, when the estimate could not be computed in time, and when the trigger answered before reading the bucket: each batch's task then carries it as `additional_data.estimate`."}},"type":"object","required":["task_id","collection_id","total_tiers","message"],"title":"TriggerCollectionResponse","description":"Response after triggering collection processing.\n\nUse `batch_id` or `task_id` to monitor progress via GET /v1/batches/{batch_id}\nor GET /v1/tasks/{task_id}. A bucket-sourced trigger answers before it has\nread the bucket: the batch starts in DRAFT with no objects, and the task\nreads FAILED with the reason if the bucket has no matching objects or the\nsubmission is refused."},"TriggerExecutionConfig":{"properties":{"collection_ids":{"items":{"type":"string"},"type":"array","minItems":1,"title":"Collection Ids","description":"REQUIRED. List of collection IDs to cluster when trigger fires. Must contain at least one collection ID. All collections will be clustered together using the specified algorithm.","examples":[["col_abc123"],["col_products","col_inventory"]]},"config":{"additionalProperties":true,"type":"object","title":"Config","description":"REQUIRED. Clustering algorithm configuration. Must include 'algorithm' field ('kmeans', 'hdbscan', 'hierarchical'). Additional fields depend on algorithm choice. K-means requires 'n_clusters'. HDBSCAN requires 'min_cluster_size'.","examples":[{"algorithm":"kmeans","min_cluster_size":2,"n_clusters":5},{"algorithm":"hdbscan","min_cluster_size":10}]}},"type":"object","required":["collection_ids","config"],"title":"TriggerExecutionConfig","description":"Configuration for cluster execution when trigger fires.\n\nDefines what clustering algorithm and parameters to use when the trigger executes.\n\nExamples:\n    K-means clustering on 3 collections:\n        {\n            \"collection_ids\": [\"col_abc123\", \"col_def456\", \"col_ghi789\"],\n            \"config\": {\n                \"algorithm\": \"kmeans\",\n                \"n_clusters\": 5,\n                \"min_cluster_size\": 2\n            }\n        }\n\n    HDBSCAN clustering on single collection:\n        {\n            \"collection_ids\": [\"col_products\"],\n            \"config\": {\n                \"algorithm\": \"hdbscan\",\n                \"min_cluster_size\": 10,\n                \"min_samples\": 5\n            }\n        }"},"TriggerExecutionHistory":{"properties":{"task_id":{"type":"string","title":"Task Id","description":"Task ID"},"triggered_at":{"type":"string","format":"date-time","title":"Triggered At","description":"When trigger fired"},"status":{"type":"string","title":"Status","description":"Execution status"},"execution_time_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Execution Time Ms","description":"Execution time in milliseconds"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if failed","x-mixpeek-redacted":"driver_text"}},"type":"object","required":["task_id","triggered_at","status"],"title":"TriggerExecutionHistory","description":"Single execution history item."},"TriggerExecutionHistoryItem":{"properties":{"job_id":{"type":"string","title":"Job Id","description":"Job ID"},"triggered_at":{"type":"string","format":"date-time","title":"Triggered At","description":"When trigger fired"},"status":{"type":"string","title":"Status","description":"Execution status"},"execution_time_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Execution Time Ms","description":"Execution time in milliseconds"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if failed","x-mixpeek-redacted":"driver_text"},"num_clusters":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Num Clusters","description":"Number of clusters created"},"num_documents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Num Documents","description":"Number of documents processed"}},"type":"object","required":["job_id","triggered_at","status"],"title":"TriggerExecutionHistoryItem","description":"Single execution history item."},"TriggerHistoryRequest":{"properties":{"offset":{"type":"integer","minimum":0.0,"title":"Offset","description":"Pagination offset","default":0},"limit":{"type":"integer","maximum":1000.0,"minimum":1.0,"title":"Limit","description":"Results per page","default":50},"status_filter":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status Filter","description":"Filter by execution status"}},"type":"object","title":"TriggerHistoryRequest","description":"Request for trigger execution history."},"TriggerOn":{"type":"string","enum":["results","no_results"],"title":"TriggerOn","description":"For retriever-source alerts, which retriever outcome fires the alert.\n\nSend the lowercase wire value (shown in quotes), NOT the member name.\n\n\"results\":    fire when the retriever returns matches (the classic behavior).\n\"no_results\": fire when the retriever returns nothing — catches a retriever\n              that has silently gone dark (empty collection, broken pipeline).\n\n\"results\" can be narrowed by two alert fields: ``min_count`` (at least that\nmany rows) and ``threshold`` (a field of the FIRST result meets a\ncomparison, for example ``score >= 0.9`` or an aggregate's ``count > 100``).\nThey are fields rather than further values here so that a release which\npredates them still reads the alert, as a plain \"results\" alert."},"TrustTier":{"type":"string","enum":["community","verified","official"],"title":"TrustTier"},"TypeSafeModel":{"type":"string","enum":["jev-latest","jev-preview","jev-1.13.0"],"title":"TypeSafeModel","description":"TypeSafe AI Jev model identifiers.\n\nJev answers typed questions (choice, score, yes/no) with calibrated\nprobabilities. It reads text only and does not generate text, so it fits\ndecision steps: classification, filtering, relevance scoring, and choosing\na label or cluster branch from a fixed set.\n\nValues:\n    JEV_LATEST: Most recent stable Jev release (moves on new releases)\n    JEV_PREVIEW: Most recent Jev release, stable or not\n    JEV_1_13: Pinned Jev 1.13; use when you tuned thresholds on it"},"TypeaheadCollectionSuggestion":{"properties":{"collection_id":{"type":"string","title":"Collection Id","description":"Collection ID."},"collection_name":{"type":"string","title":"Collection Name","description":"Collection name."}},"type":"object","required":["collection_id","collection_name"],"title":"TypeaheadCollectionSuggestion","description":"A collection in the caller's namespace whose name matches the prefix."},"TypeaheadResponse":{"properties":{"query":{"type":"string","title":"Query","description":"The prefix that was matched."},"suggestions":{"items":{"type":"string"},"type":"array","title":"Suggestions","description":"Flat ranked suggestion texts across all sources."},"values":{"items":{"$ref":"#/components/schemas/TypeaheadValueSuggestion"},"type":"array","title":"Values","description":"Field-value suggestions with per-value document counts."},"collections":{"items":{"$ref":"#/components/schemas/TypeaheadCollectionSuggestion"},"type":"array","title":"Collections","description":"Collections whose name matches the prefix."},"recent_searches":{"items":{"type":"string"},"type":"array","title":"Recent Searches","description":"The caller's own recent queries matching the prefix, newest first."},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings","description":"Sources that could not be consulted this request."}},"type":"object","required":["query"],"title":"TypeaheadResponse","description":"Prefix suggestions for a search box.\n\nThree sources, each scoped to the caller's namespace and organization:\nmetadata-field values (index-backed facet, prefix-filtered), collection\nnames, and the caller's own recent search queries. ``suggestions`` is the\nflat ranked convenience list (recent searches first, then field values by\ncount, then collection names, case-insensitively deduplicated). A source\nthat fails or times out is dropped and named in ``warnings`` instead of\nfailing the request."},"TypeaheadValueSuggestion":{"properties":{"field":{"type":"string","title":"Field","description":"The metadata field path the value came from."},"value":{"type":"string","title":"Value","description":"The suggested value."},"count":{"type":"integer","title":"Count","description":"Documents carrying this value inside the caller's namespace."}},"type":"object","required":["field","value","count"],"title":"TypeaheadValueSuggestion","description":"A metadata-field value whose text starts with the typed prefix."},"UMAPParams":{"properties":{"method":{"type":"string","const":"umap","title":"Method","default":"umap"},"n_components":{"type":"integer","maximum":256.0,"minimum":2.0,"title":"N Components","default":50},"random_state":{"type":"integer","title":"Random State","default":42},"n_neighbors":{"type":"integer","minimum":2.0,"title":"N Neighbors","default":30},"min_dist":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Min Dist","default":0.0},"metric":{"type":"string","title":"Metric","description":"Distance metric for UMAP. 'cosine' is best for normalized embeddings.","default":"cosine"}},"type":"object","title":"UMAPParams"},"UnifiedExtractorListResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether the request succeeded","default":true},"extractors":{"items":{"$ref":"#/components/schemas/UnifiedExtractorResponse"},"type":"array","title":"Extractors","description":"List of all available extractors"},"total":{"type":"integer","title":"Total","description":"Total number of extractors"},"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace ID"},"builtin_count":{"type":"integer","title":"Builtin Count","description":"Number of builtin extractors"},"custom_count":{"type":"integer","title":"Custom Count","description":"Number of custom extractors (org + namespace level)"}},"type":"object","required":["extractors","total","namespace_id","builtin_count","custom_count"],"title":"UnifiedExtractorListResponse","description":"Response for listing all extractors available to a namespace."},"UnifiedExtractorResponse":{"properties":{"feature_extractor_name":{"type":"string","title":"Feature Extractor Name","description":"Name of the feature extractor"},"version":{"type":"string","title":"Version","description":"Version of the feature extractor"},"feature_extractor_id":{"type":"string","title":"Feature Extractor Id","description":"Unique identifier (name_version)"},"source":{"$ref":"#/components/schemas/ExtractorSource","description":"Origin of this extractor: 'builtin' (shipped with Mixpeek), 'custom' (user-uploaded plugin), or 'community' (marketplace)"},"description":{"type":"string","title":"Description","description":"Human-readable description"},"icon":{"type":"string","title":"Icon","description":"Lucide-react icon name for frontend rendering","default":"box"},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema","description":"JSON schema for input data"},"output_schema":{"additionalProperties":true,"type":"object","title":"Output Schema","description":"JSON schema for output data"},"parameter_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Parameter Schema","description":"JSON schema for parameters"},"type_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Type Mode","description":"What input types this extractor can handle: 'type_specific' (only one type, e.g. video-only) or 'multimodal' (handles multiple types with conditional processing). Type-specific extractors cannot use automatic-typed bucket properties."},"expected_input_types":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Expected Input Types","description":"For type-specific extractors: maps input keys to required types (e.g., {'video': 'video', 'thumbnail': 'image'}). For multimodal extractors: null."},"inference_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inference Type","description":"Kind of real-time inference this extractor provides: 'embedding', 'rerank', 'classify', 'generate', or 'general'. Determines which retriever stages are compatible. Null if the extractor is batch-only."},"supported_input_types":{"items":{"type":"string"},"type":"array","title":"Supported Input Types","description":"Supported input types (video, image, text, etc.)"},"max_inputs":{"additionalProperties":{"type":"integer"},"type":"object","title":"Max Inputs","description":"Maximum number of inputs per type"},"default_parameters":{"additionalProperties":true,"type":"object","title":"Default Parameters","description":"Default parameter values"},"costs":{"anyOf":[{"$ref":"#/components/schemas/CostsInfo"},{"type":"null"}],"description":"Credit cost information (builtin extractors only)"},"required_vector_indexes":{"anyOf":[{"items":{"$ref":"#/components/schemas/VectorIndexDefinition"},"type":"array"},{"type":"null"}],"title":"Required Vector Indexes","description":"Vector indexes this extractor produces"},"required_payload_indexes":{"anyOf":[{"items":{"$ref":"#/components/schemas/PayloadIndexConfig-Output"},"type":"array"},{"type":"null"}],"title":"Required Payload Indexes","description":"Payload indexes required by this extractor"},"position_fields":{"items":{"type":"string"},"type":"array","title":"Position Fields","description":"Fields that identify unique positions within output documents. Used for deterministic document ID generation."},"feature_uri":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Feature Uri","description":"Primary feature URI (e.g., mixpeek://text_extractor@v1/embedding)"},"capabilities":{"items":{"type":"string"},"type":"array","title":"Capabilities","description":"What this extractor can do: 'batch' (feature extraction during ingestion), 'realtime' (query-time inference for retriever stages)"},"example_usage":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Example Usage","description":"Minimal working configuration for namespace + collection + input_mappings + parameters"},"realtime_available":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Realtime Available","description":"Whether every Ray Serve application this extractor needs for real-time inference is running on the deployment serving this request. True when all of them report RUNNING. False when one is absent, not running, or missing its model provider's credentials; see serve_apps for which. Null when the extractor needs none, or when the live list could not be read."},"serve_apps":{"items":{"$ref":"#/components/schemas/ServeAppStatus"},"type":"array","title":"Serve Apps","description":"The Ray Serve applications this extractor needs for real-time inference, each with its live status. Empty when it needs none."},"plugin_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Plugin Id","description":"Plugin ID (custom plugins only)"},"deployed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Deployed","description":"Whether the plugin is deployed (custom plugins only)"},"validation_status":{"anyOf":[{"type":"string","enum":["passed","failed","pending"]},{"type":"null"}],"title":"Validation Status","description":"Validation status (custom plugins only)"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"Creation timestamp (custom plugins only)"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"Last update timestamp (custom plugins only)"}},"type":"object","required":["feature_extractor_name","version","feature_extractor_id","source","description","input_schema","output_schema"],"title":"UnifiedExtractorResponse","description":"Unified extractor response combining builtin and custom plugins.\n\nThis model provides a consistent view of all extractors available\nto a namespace, regardless of whether they are builtin or custom."},"UniqueKeyConfig":{"properties":{"fields":{"items":{"type":"string"},"type":"array","minItems":1,"title":"Fields","description":"Field name(s) from bucket schema to use as unique constraint. REQUIRED - must provide at least one field name. \n\nSingle field example: ['video_id'] - Enforces uniqueness on video_id alone. Compound example: ['sensor_id', 'timestamp'] - Uniqueness requires BOTH fields to match. \n\nAll specified fields must:\n  - Exist in the bucket schema\n  - Be scalar types (string, integer, float, uuid - NOT objects or arrays)\n  - Have non-null, non-empty values in all uploaded objects\n  - Be 255 characters or less per string field value\n\n\nField order doesn't matter (sorted internally for consistency). ['timestamp', 'sensor_id'] is equivalent to ['sensor_id', 'timestamp'].","examples":[["video_id"],["product_sku"],["user_id","session_id"],["sensor_id","timestamp"],["product_id","size","color"]]},"default_policy":{"anyOf":[{"type":"string","enum":["insert","update","upsert"]},{"type":"null"}],"title":"Default Policy","description":"Default insertion policy for this bucket when not specified per request. OPTIONAL - if omitted, you must provide ?policy= parameter on each upload request.\n\nPolicies:\n  - 'insert': Create new object only. Fail with 409 Conflict if unique key already exists.\n              Use when: You want to prevent accidental overwrites (safest option).\n\n  - 'update': Update existing object only. Fail with 404 Not Found if unique key doesn't exist.\n              Use when: You only want to update existing records, never create new ones.\n\n  - 'upsert': Update if exists, create if not (idempotent operation).\n              Use when: You want idempotent ingestion (re-running is safe).\n\nPolicy Resolution:\n  1. Request-level ?policy= parameter takes precedence (if provided)\n  2. Falls back to this default_policy (if configured)\n  3. Returns 400 Bad Request if neither is specified\n\nRecommendation: Omit default_policy if you want explicit control on each upload. Set default_policy='upsert' for idempotent pipelines.","examples":["insert","update","upsert"]}},"type":"object","required":["fields"],"title":"UniqueKeyConfig","description":"Configuration for bucket unique key enforcement.\n\nEnables automatic uniqueness enforcement on one or more fields from the bucket schema.\nSupports both single field and compound (multi-field) uniqueness constraints.\n\nWhen configured, the bucket will maintain a lookup table mapping unique key values\nto document IDs, enabling efficient upsert operations and preventing duplicates.\n\n**Impact on Collection Trigger/Re-processing:**\nWhen a collection is triggered (POST /collections/{id}/trigger), the unique_key\ndetermines whether documents are overwritten or duplicated:\n- WITH unique_key: Documents get deterministic IDs → re-triggering OVERWRITES existing docs\n- WITHOUT unique_key: Documents get random IDs → re-triggering CREATES DUPLICATES\n\nFor idempotent pipelines where re-triggering is safe, configure a unique_key.\n\n**Relationship to Extractor position_fields:**\nThe `unique_key` (bucket-level) and `position_fields` (extractor-level) work together\nto generate deterministic document IDs:\n\n- `unique_key`: Identifies unique SOURCE OBJECTS in the bucket (e.g., video_id)\n- `position_fields`: Identifies unique OUTPUT DOCUMENTS from a single object (e.g., start_time, end_time)\n\nDocument ID Formula:\n    document_id = hash(source_object_key + extractor_id + collection_id + position_field_values)\n\nExample - Processing a 60-second video with 10-second segments:\n    - Bucket unique_key: [\"video_id\"] → Identifies the source video\n    - Extractor position_fields: [\"start_time\", \"end_time\"] → Identifies each segment\n    - Result: 6 unique document IDs (one per segment), all deterministic\n\nWithout position_fields, all segments would get the SAME document_id and overwrite each other.\nWithout unique_key, reprocessing would create DUPLICATE documents instead of updating.\n\nRequirements:\n    - fields: REQUIRED - Array of field names from bucket schema to use as unique constraint\n    - default_policy: OPTIONAL - Bucket-level default insertion policy (can be overridden per request)\n    - All specified fields must exist in the bucket schema\n    - All fields must be scalar types (string, integer, float, uuid)\n    - Field values cannot be null or empty in uploaded objects\n    - Cannot be changed after bucket creation (v1 limitation)\n\nUse Cases:\n    - Single field uniqueness: [\"video_id\"], [\"product_sku\"], [\"user_email\"]\n    - Compound uniqueness: [\"sensor_id\", \"timestamp\"], [\"product_id\", \"size\", \"color\"]\n    - With default policy: Enables idempotent ingestion without per-request policy\n    - Without default: Requires explicit policy on each upload (safer, more intentional)\n\nInsertion Policies:\n    - 'insert': Fail with 409 Conflict if key exists (prevents accidental overwrites)\n    - 'update': Fail with 404 Not Found if key doesn't exist (updates only)\n    - 'upsert': Update if exists, insert if not (idempotent ingestion)\n\nPolicy Resolution (when uploading objects):\n    1. Use request-level ?policy= parameter if provided (highest priority)\n    2. Fall back to bucket-level default_policy if configured\n    3. Return 400 Bad Request if neither is specified (prevents accidental operations)\n\nExamples:\n    Single field with upsert default (idempotent video ingestion):\n        {\n            \"fields\": [\"video_id\"],\n            \"default_policy\": \"upsert\"\n        }\n\n    Single field with insert default (prevent duplicate products):\n        {\n            \"fields\": [\"product_sku\"],\n            \"default_policy\": \"insert\"\n        }\n\n    Compound fields with upsert (time-series sensor data):\n        {\n            \"fields\": [\"sensor_id\", \"timestamp\"],\n            \"default_policy\": \"upsert\"\n        }\n\n    Compound fields without default (explicit policy required):\n        {\n            \"fields\": [\"user_id\", \"session_id\"]\n        }","examples":[{"default_policy":"upsert","description":"Single field, upsert by default (idempotent video ingestion)","fields":["video_id"]},{"default_policy":"insert","description":"Single field, insert by default (prevent duplicate products)","fields":["product_sku"]},{"description":"Single field, no default policy (explicit required per upload)","fields":["user_id"]},{"default_policy":"insert","description":"Compound fields, insert by default (time-series with duplicate prevention)","fields":["sensor_id","timestamp"]},{"default_policy":"upsert","description":"Compound fields, upsert by default (product variants, idempotent)","fields":["product_id","size","color"]},{"description":"Compound fields, no default (explicit policy required)","fields":["user_id","session_id"]},{"default_policy":"update","description":"Three-field compound key, update only (profile updates)","fields":["tenant_id","user_id","profile_version"]}]},"UniversalExtractorParams":{"properties":{"extractor_type":{"type":"string","const":"universal_extractor","title":"Extractor Type","description":"Discriminator field for parameter type identification.","default":"universal_extractor"},"output_dimensionality":{"type":"integer","maximum":3072.0,"minimum":256.0,"title":"Output Dimensionality","description":"Output embedding dimensions (Gemini Embedding 2 supports 256-3072).","default":3072},"task_type":{"type":"string","title":"Task Type","description":"Embedding intent used as a text instruction for Gemini Embedding 2. Common values: RETRIEVAL_DOCUMENT, RETRIEVAL_QUERY, SEMANTIC_SIMILARITY.","default":"RETRIEVAL_DOCUMENT"},"generate_description":{"type":"boolean","title":"Generate Description","description":"Generate a text description of the content via Gemini vision/understanding.","default":true},"extract_text":{"type":"boolean","title":"Extract Text","description":"Extract text content (OCR for images/docs, transcription for audio/video).","default":true},"max_video_segments":{"type":"integer","maximum":50.0,"minimum":1.0,"title":"Max Video Segments","description":"Maximum number of 30s segments to process for video files.","default":10},"max_document_pages":{"type":"integer","maximum":200.0,"minimum":1.0,"title":"Max Document Pages","description":"Maximum number of pages to process for document files.","default":50},"max_file_download_mb":{"type":"integer","maximum":1024.0,"minimum":1.0,"title":"Max File Download Mb","description":"Maximum file download size in MB for fast-path processing.","default":500},"max_concurrency":{"type":"integer","maximum":32.0,"minimum":1.0,"title":"Max Concurrency","description":"Maximum per-task object concurrency for fast-path processing.","default":4}},"type":"object","title":"UniversalExtractorParams","description":"Parameters for the Universal Extractor.","examples":[{"extract_text":true,"extractor_type":"universal_extractor","generate_description":true,"max_concurrency":4,"max_file_download_mb":500,"output_dimensionality":3072,"task_type":"RETRIEVAL_DOCUMENT"}]},"UpdateAppRequest":{"properties":{"slug":{"anyOf":[{"type":"string","maxLength":60,"minLength":3,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},{"type":"null"}],"title":"Slug"},"meta":{"anyOf":[{"$ref":"#/components/schemas/PageMeta"},{"type":"null"}]},"auth_config":{"anyOf":[{"$ref":"#/components/schemas/AuthConfig-Input"},{"type":"null"}]},"build_config":{"anyOf":[{"$ref":"#/components/schemas/BuildConfig"},{"type":"null"}]},"monitoring_config":{"anyOf":[{"$ref":"#/components/schemas/MonitoringConfig"},{"type":"null"}]},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"publish":{"type":"boolean","title":"Publish","description":"When true, applies the update and immediately publishes.","default":false},"template":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Template","deprecated":true},"sections":{"anyOf":[{"items":{"$ref":"#/components/schemas/SectionConfig"},"type":"array"},{"type":"null"}],"title":"Sections","deprecated":true},"custom_html":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Html","deprecated":true},"hero":{"anyOf":[{"$ref":"#/components/schemas/HeroConfig"},{"type":"null"}],"deprecated":true},"theme":{"anyOf":[{"$ref":"#/components/schemas/ThemeConfig"},{"type":"null"}],"deprecated":true},"seo":{"anyOf":[{"$ref":"#/components/schemas/SEOConfig"},{"type":"null"}],"deprecated":true},"stats":{"anyOf":[{"items":{"$ref":"#/components/schemas/StatItem"},"type":"array"},{"type":"null"}],"title":"Stats","deprecated":true},"featured_gallery":{"anyOf":[{"$ref":"#/components/schemas/FeaturedGalleryConfig-Input"},{"type":"null"}],"deprecated":true},"tabs":{"anyOf":[{"items":{"$ref":"#/components/schemas/PageTab-Input"},"type":"array"},{"type":"null"}],"title":"Tabs","deprecated":true},"password_secret_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Password Secret Name","deprecated":true}},"type":"object","title":"UpdateAppRequest","description":"Request to update an existing App (all fields optional).\n\nFor deploy-based apps, typically only ``auth_config``, ``build_config``,\n``meta``, and ``slug`` are updated here.  Code changes go through the\ndeploy pipeline.\n\nLegacy page-builder fields are accepted for backward compatibility but\n**deprecated**."},"UpdateDocumentACLRequest":{"properties":{"read":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Read","description":"List of principal IDs that can read this document. Replaces existing list.","examples":[["user_alice","user_bob"]]},"write":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Write","description":"List of principal IDs that can write this document. Replaces existing list.","examples":[["user_alice"]]},"public":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Public","description":"If true, any user-scoped key can read this document."}},"type":"object","title":"UpdateDocumentACLRequest","description":"Request model for updating a document's ACL (access control list).\n\nOnly the document owner or an org-scoped key can modify ACL."},"UpdateNamespaceRequest":{"properties":{"namespace_name":{"anyOf":[{"type":"string","maxLength":64,"minLength":3},{"type":"null"}],"title":"Namespace Name","description":"Name of the namespace to update","example":"product-search"},"payload_indexes":{"anyOf":[{"items":{"$ref":"#/components/schemas/PayloadIndexConfig-Input"},"type":"array"},{"type":"null"}],"title":"Payload Indexes","description":"Updated list of payload index configurations","example":[{"field_name":"metadata.title","field_schema":{"lowercase":true,"max_token_len":15,"min_token_len":2,"tokenizer":"word","type":"text"},"is_protected":false,"type":"text"},{"field_name":"metadata.description","field_schema":{"is_tenant":false,"type":"keyword"},"is_protected":false,"type":"keyword"}]}},"type":"object","title":"UpdateNamespaceRequest","description":"Request schema for updating a namespace's payload indexes."},"UpdateObjectRequest":{"properties":{"key_prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Key Prefix","description":"Updated storage key/path prefix of the object, this will be used to retrieve the object from the storage. It's at the root of the object."},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Custom fields to change. A key the object holds inside its own `metadata` object (because it was created with one) is updated there; any other key is set at the root of the object, the same place PATCH writes it. Fields you leave out keep their values."},"skip_duplicates":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Skip Duplicates","description":"Skip duplicate blobs, if a blob with the same hash already exists, it will be skipped."}},"additionalProperties":false,"type":"object","title":"UpdateObjectRequest","description":"Request model for updating an existing bucket object."},"UpdatePreferencesRequest":{"properties":{"preferences":{"additionalProperties":true,"type":"object","title":"Preferences","description":"Updated notification preferences"}},"type":"object","required":["preferences"],"title":"UpdatePreferencesRequest","description":"Request model for updating notification preferences."},"UpdatePublishedExtractorRequest":{"properties":{"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description"},"icon_base64":{"anyOf":[{"type":"string","maxLength":300000},{"type":"null"}],"title":"Icon Base64"},"readme_markdown":{"anyOf":[{"type":"string","maxLength":50000},{"type":"null"}],"title":"Readme Markdown"},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags"},"category":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Category"},"model_dependencies":{"anyOf":[{"items":{"$ref":"#/components/schemas/ModelDependency"},"type":"array"},{"type":"null"}],"title":"Model Dependencies"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"UpdatePublishedExtractorRequest"},"UpdatePublishedRetrieverRequest":{"properties":{"display_config":{"anyOf":[{"$ref":"#/components/schemas/DisplayConfig-Input"},{"type":"null"}],"description":"Update the display configuration"},"rate_limit_config":{"anyOf":[{"$ref":"#/components/schemas/RateLimitConfig"},{"type":"null"}],"description":"Update rate limiting configuration"},"password_secret_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Password Secret Name","description":"Update or remove password protection (set to empty string to remove)"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active","description":"Activate or deactivate the published retriever"},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags","description":"Update tags for categorizing this retriever"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category","description":"Update the primary category for this retriever"}},"additionalProperties":false,"type":"object","title":"UpdatePublishedRetrieverRequest","description":"Request to update a published retriever configuration."},"UpdateReminderPreferencesRequest":{"properties":{"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled","description":"Master toggle for all reminders"},"onboarding_nudges":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Onboarding Nudges","description":"Enable/disable onboarding nudges"},"engagement_reminders":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Engagement Reminders","description":"Enable/disable engagement reminders"},"feature_tips":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Feature Tips","description":"Enable/disable feature tips"},"quiet_hours_start":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Quiet Hours Start","description":"Hour (0-23) to start quiet period (UTC)"},"quiet_hours_end":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Quiet Hours End","description":"Hour (0-23) to end quiet period (UTC)"}},"type":"object","title":"UpdateReminderPreferencesRequest","description":"Request model for updating reminder preferences."},"UpdateRoleRequest":{"properties":{"role":{"type":"string","title":"Role","description":"New Clerk org role (org:admin or org:member)"}},"type":"object","required":["role"],"title":"UpdateRoleRequest"},"UpdateSecretRequest":{"properties":{"secret_value":{"type":"string","minLength":1,"title":"Secret Value","description":"REQUIRED. New plaintext value for the secret. This will replace the existing encrypted value. The old value is permanently overwritten with no history. The new value will be encrypted at rest using Fernet encryption. Use this to rotate keys, update expired tokens, or change credentials. Format: any string (will be encrypted as-is).","examples":["YOUR_STRIPE_API_KEY","ghp_rotated_token_def456","new_api_key_ghi789"]}},"type":"object","required":["secret_value"],"title":"UpdateSecretRequest","description":"Request to update an existing secret in the organization vault.\n\nUpdates the encrypted value of an existing secret. The old value is\npermanently overwritten with no history or rollback capability.\n\n**Use Cases**:\n- Rotate API keys periodically for security\n- Update expired tokens\n- Change credentials after security incident\n- Switch from test to production keys\n\n**Security**:\n- Old value is permanently overwritten (no history)\n- New value is encrypted before storage\n- No rollback or undo capability\n- Update is logged for audit trail\n\n**Requirements**:\n- secret_value: REQUIRED, new plaintext value\n- Secret must already exist (use POST to create)\n\n**Permissions**: Requires ADMIN permission to update secrets.","examples":[{"description":"Rotate Stripe API key","secret_value":"YOUR_STRIPE_API_KEY"},{"description":"Update expired GitHub token","secret_value":"ghp_new_token_def456"},{"description":"Switch from test to production key","secret_value":"YOUR_STRIPE_API_KEY"}]},"UpdateSpendingCapsRequest":{"properties":{"monthly_spending_budget":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Monthly Spending Budget","description":"Soft spending limit in USD cents. Triggers alerts but doesn't block API access. Set to null to remove budget limit.","examples":[10000,50000,100000]},"spending_alert_thresholds":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Spending Alert Thresholds","description":"Percentage thresholds for spending alerts (0-100). When current spending reaches each threshold, an alert is sent.","examples":[[50,75,90,100],[80,100]]},"spending_alerts_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Spending Alerts Enabled","description":"Whether to send spending alerts when thresholds are crossed."},"hard_spending_cap":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Hard Spending Cap","description":"Hard spending limit in USD cents. When reached, API access is blocked. Set to null to remove hard cap.","examples":[50000,100000,500000]},"hard_cap_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Hard Cap Enabled","description":"Whether to enforce the hard spending cap."}},"additionalProperties":false,"type":"object","title":"UpdateSpendingCapsRequest","description":"Request to update spending cap configuration."},"UpdateTicketRequest":{"properties":{"status":{"anyOf":[{"$ref":"#/components/schemas/SupportTicketStatus"},{"type":"null"}]},"priority":{"anyOf":[{"$ref":"#/components/schemas/SupportTicketPriority"},{"type":"null"}]}},"type":"object","title":"UpdateTicketRequest"},"UploadListStats":{"properties":{"total_uploads":{"type":"integer","title":"Total Uploads","description":"Total number of uploads in the result set"},"total_size_bytes":{"type":"integer","title":"Total Size Bytes","description":"Total size of all files in bytes"},"uploads_by_status":{"additionalProperties":{"type":"integer"},"type":"object","title":"Uploads By Status","description":"Count of uploads grouped by status","examples":[{"COMPLETED":35,"FAILED":2,"PENDING":5}]},"avg_file_size_bytes":{"type":"number","title":"Avg File Size Bytes","description":"Average file size across all uploads"},"unique_buckets":{"type":"integer","title":"Unique Buckets","description":"Number of unique buckets in the result set"}},"type":"object","required":["total_uploads","total_size_bytes","uploads_by_status","avg_file_size_bytes","unique_buckets"],"title":"UploadListStats","description":"Aggregate statistics for a list of uploads."},"UploadPerformanceMetric":{"properties":{"time_bucket":{"type":"string","format":"date-time","title":"Time Bucket","description":"Time bucket timestamp"},"upload_count":{"type":"integer","title":"Upload Count","description":"Number of uploads"},"avg_latency_ms":{"type":"number","title":"Avg Latency Ms","description":"Average upload latency"},"p95_latency_ms":{"type":"number","title":"P95 Latency Ms","description":"95th percentile latency"},"p99_latency_ms":{"type":"number","title":"P99 Latency Ms","description":"99th percentile latency"},"avg_throughput_mbps":{"type":"number","title":"Avg Throughput Mbps","description":"Average throughput in MB/s"},"error_rate":{"type":"number","title":"Error Rate","description":"Error rate (0-1)"}},"type":"object","required":["time_bucket","upload_count","avg_latency_ms","p95_latency_ms","p99_latency_ms","avg_throughput_mbps","error_rate"],"title":"UploadPerformanceMetric","description":"Upload performance metrics for a time bucket."},"UploadPerformanceResponse":{"properties":{"bucket_id":{"type":"string","title":"Bucket Id","description":"Bucket identifier"},"time_range":{"$ref":"#/components/schemas/api__analytics__buckets__models__TimeRange","description":"Query time range"},"metrics":{"items":{"$ref":"#/components/schemas/UploadPerformanceMetric"},"type":"array","title":"Metrics","description":"Upload performance metrics"},"summary":{"additionalProperties":true,"type":"object","title":"Summary","description":"Summary statistics"}},"type":"object","required":["bucket_id","time_range","metrics"],"title":"UploadPerformanceResponse","description":"Upload performance analytics response."},"UploadResponse":{"properties":{"upload_id":{"type":"string","title":"Upload Id","description":"Unique identifier for this upload. Auto-generated. \n\n⚠️  NEXT STEP: After uploading to S3, you MUST confirm:   POST /v1/uploads/{upload_id}/confirm \n\nOther operations:   - Check status: GET /v1/uploads/{upload_id}   - Cancel upload: DELETE /v1/uploads/{upload_id} \n\nFormat: 'upl_' followed by 16 random characters.","examples":["upl_a1b2c3d4e5f6","upl_x9y8z7w6v5u4"]},"bucket_id":{"type":"string","title":"Bucket Id","description":"Target bucket ID where object will be created","examples":["bkt_abc123"]},"filename":{"type":"string","title":"Filename","description":"Name of the file to upload","examples":["product_video.mp4"]},"content_type":{"type":"string","title":"Content Type","description":"MIME type enforced by the presigned URL","examples":["video/mp4"]},"file_size_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"File Size Bytes","description":"Expected file size in bytes if provided in request. Will be validated during confirmation.","examples":[10485760]},"presigned_url":{"anyOf":[{"type":"string","maxLength":2083,"minLength":1,"format":"uri"},{"type":"null"}],"title":"Presigned Url","description":"Time-limited HTTPS URL for uploading directly to S3. \n\n**Step 1 - Upload to S3:**   curl -X PUT '{presigned_url}' -H 'Content-Type: {content_type}' --upload-file {filename} \n\n**Step 2 - REQUIRED: Confirm the upload:**   POST /v1/uploads/{upload_id}/confirm   (S3 has no callback - you MUST call confirm to finalize) \n\nThe URL includes authentication and expires after presigned_url_expiration seconds. S3 returns an ETag header on success - pass it to confirm for integrity validation. NOTE: This will be null if is_duplicate=true (duplicate found, no upload needed)."},"presigned_url_expiration":{"type":"integer","title":"Presigned Url Expiration","description":"How long the presigned URL is valid, in seconds","examples":[3600]},"s3_key":{"type":"string","title":"S3 Key","description":"Full S3 object key where the file will be stored. Format: {internal_id}/{namespace_id}/api_buckets_uploads_create/{upload_id}/{filename}. Used internally for verification and object creation.","examples":["int_xyz/ns_abc/api_buckets_uploads_create/upl_123/video.mp4"]},"status":{"$ref":"#/components/schemas/TaskStatusEnum","description":"Current upload status. After creation, always PENDING. Possible statuses: PENDING → IN_PROGRESS → PROCESSING → COMPLETED/FAILED/CANCELED","examples":["PENDING"]},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","description":"Custom metadata for tracking"},"create_object_on_confirm":{"type":"boolean","title":"Create Object On Confirm","description":"Whether bucket object will be auto-created on confirmation"},"object_metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Object Metadata","description":"Metadata for the bucket object (if create_object_on_confirm=true)"},"blob_property":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Blob Property","description":"Property name for the blob in bucket object"},"blob_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Blob Type","description":"Type of blob (IMAGE, VIDEO, etc.)"},"file_hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"File Hash","description":"SHA256 hash of the file content. Set during confirmation from S3 metadata or provided in request. Used for duplicate detection.","examples":["e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"]},"skip_duplicates":{"type":"boolean","title":"Skip Duplicates","description":"Whether duplicate detection was enabled for this upload","default":true},"is_duplicate":{"type":"boolean","title":"Is Duplicate","description":"Whether this upload was identified as a duplicate of an existing file. If true:   - duplicate_of_upload_id contains the original upload   - presigned_url will be null (no upload needed)   - You can use the original upload's S3 object. This saves bandwidth and storage costs.","default":false},"duplicate_of_upload_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Duplicate Of Upload Id","description":"If skip_duplicates=true and duplicate found, this is the original upload_id. The response will reference the existing upload instead of creating a new one.","examples":["upl_original123"]},"skipped_unique_key":{"type":"boolean","title":"Skipped Unique Key","description":"Whether this upload was skipped because the unique key already exists in the bucket. If true:   - existing_object_id contains the ID of the existing object   - presigned_url will be null (no upload needed)   - No S3 upload is required This saves bandwidth and prevents duplicate objects.","default":false},"existing_object_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Existing Object Id","description":"If skipped_unique_key=true, this is the object_id of the existing object that has the same unique key values. The upload was skipped to prevent duplicates.","examples":["obj_abc123xyz789"]},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message","description":"Human-readable message about the upload. When status is FAILED, the reason it failed (for example it was not confirmed before expires_at, or its confirmation did not finish). Also provided when is_duplicate=true or other special conditions. Example: 'File already exists with the same content hash. No upload needed - returning existing upload.'"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"When this upload record was created (ISO 8601 format)","examples":["2024-01-15T10:30:00Z"]},"expires_at":{"type":"string","format":"date-time","title":"Expires At","description":"When the presigned URL expires (ISO 8601 format). After this time:   - The presigned URL cannot be used   - Upload status will be marked as FAILED if not completed   - The upload record will be auto-deleted 30 days later (MongoDB TTL)","examples":["2024-01-15T11:30:00Z"]},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"When the upload was completed and verified (ISO 8601 format)","examples":["2024-01-15T10:35:00Z"]},"verified_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Verified At","description":"When S3 object existence was verified (ISO 8601 format)","examples":["2024-01-15T10:35:00Z"]},"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag","description":"S3 ETag from the uploaded object (set during confirmation)","examples":["d41d8cd98f00b204e9800998ecf8427e"]},"object_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Object Id","description":"Created bucket object ID (if create_object_on_confirm was true)","examples":["obj_a1b2c3d4e5f6"]},"task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id","description":"Task ID for async confirmation (if processed asynchronously)","examples":["task_abc123"]}},"type":"object","required":["upload_id","bucket_id","filename","content_type","presigned_url_expiration","s3_key","status","create_object_on_confirm","created_at","expires_at"],"title":"UploadResponse","description":"Response containing presigned URL and upload tracking information.\n\nThis response includes everything needed to:\n1. Upload your file to S3 using the presigned_url\n2. Track the upload status using upload_id\n3. Confirm the upload using the confirmation endpoint\n\nThe presigned_url is time-limited and specific to this upload.\nAfter uploading to S3, call POST /v1/buckets/{bucket_id}/uploads/{upload_id}/confirm.","examples":[{"blob_property":"video","blob_type":"VIDEO","bucket_id":"bkt_prod_videos","content_type":"video/mp4","create_object_on_confirm":true,"created_at":"2024-01-15T10:30:00Z","description":"New upload ready for S3 - object will be created on confirm (DEFAULT)","expires_at":"2024-01-15T11:30:00Z","file_size_bytes":52428800,"filename":"product_demo.mp4","is_duplicate":false,"object_metadata":{"category":"tutorials"},"presigned_url":"https://s3.amazonaws.com/bucket/key?X-Amz-Signature=...","presigned_url_expiration":3600,"s3_key":"int_xyz/ns_abc/api_buckets_uploads_create/upl_abc123xyz789/product_demo.mp4","skip_duplicates":true,"status":"PENDING","upload_id":"upl_abc123xyz789"},{"bucket_id":"bkt_prod_videos","completed_at":"2024-01-10T08:25:00Z","content_type":"video/mp4","created_at":"2024-01-10T08:20:00Z","description":"Duplicate detected - no upload needed, existing object returned","duplicate_of_upload_id":"upl_original456","file_hash":"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855","file_size_bytes":52428800,"filename":"product_demo.mp4","is_duplicate":true,"message":"File already exists with the same content hash. No upload needed - returning existing upload.","object_id":"obj_existing789","s3_key":"int_xyz/ns_abc/api_buckets_uploads_create/upl_original456/product_demo.mp4","status":"COMPLETED","upload_id":"upl_original456"},{"bucket_id":"bkt_media","content_type":"video/mp4","create_object_on_confirm":false,"created_at":"2024-01-15T10:30:00Z","description":"ADVANCED: Manual object creation (create_object_on_confirm=false)","expires_at":"2024-01-15T11:30:00Z","filename":"video.mp4","note":"Only use when combining multiple uploads into one object","presigned_url":"https://s3.amazonaws.com/bucket/key?X-Amz-Signature=...","presigned_url_expiration":3600,"s3_key":"int_xyz/ns_abc/api_buckets_uploads_create/upl_manual789/video.mp4","status":"PENDING","upload_id":"upl_manual789","workflow":["1. User uploads file to presigned_url","2. POST /uploads/upl_manual789/confirm (verifies upload, no object created)","3. POST /buckets/{id}/objects with upload_id reference:","   {blobs: [{property: 'video', upload_id: 'upl_manual789'}]}"]}]},"UploadUrlRequest":{"properties":{"filename":{"type":"string","title":"Filename","description":"Zip filename (e.g. 'my-app-v2.zip')"},"content_type":{"type":"string","title":"Content Type","default":"application/zip"}},"type":"object","required":["filename"],"title":"UploadUrlRequest"},"UploadUrlResponse":{"properties":{"upload_url":{"type":"string","title":"Upload Url","description":"Presigned S3 PUT URL"},"bundle_s3_key":{"type":"string","title":"Bundle S3 Key","description":"S3 key to pass back in DeployRequest"},"expires_in":{"type":"integer","title":"Expires In","description":"URL expiry in seconds","default":3600}},"type":"object","required":["upload_url","bundle_s3_key"],"title":"UploadUrlResponse"},"UpsertOptions":{"properties":{"write_token":{"type":"boolean","title":"Write Token","description":"Return a WriteToken for read-your-writes consistency.","default":false},"idempotency_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Idempotency Key","description":"Deduplication key. A repeated call with the same key and an identical body returns the original cached response; the same key with a different body returns 409 Conflict."}},"type":"object","title":"UpsertOptions","description":"Options controlling the upsert behavior."},"UsageBreakdownResponse":{"properties":{"billing_month":{"type":"string","title":"Billing Month","description":"Billing month (YYYY-MM)","examples":["2025-12"]},"total_credits":{"type":"integer","title":"Total Credits","description":"Total credits consumed","examples":[23450]},"total_cost_usd":{"type":"number","title":"Total Cost Usd","description":"Total cost in USD","examples":[23.45]},"by_operation":{"additionalProperties":{"type":"integer"},"type":"object","title":"By Operation","description":"Credits consumed by operation type","examples":[{"batch":2450,"extractor":15000,"search":1000,"upload":5000}]},"by_extractor":{"additionalProperties":{"type":"integer"},"type":"object","title":"By Extractor","description":"Credits consumed by extractor","examples":[{"multimodal_extractor":10000,"text_extractor":5000}]},"by_namespace":{"additionalProperties":{"type":"integer"},"type":"object","title":"By Namespace","description":"Credits consumed by namespace (chargeback / cost-allocation for multi-namespace orgs). Keyed by namespace_id; excludes namespace-less consumption. Empty for older usage recorded before per-namespace attribution.","examples":[{"ns_clientA":18000,"ns_clientB":5450}]},"by_retriever":{"additionalProperties":{"type":"integer"},"type":"object","title":"By Retriever","description":"Credits consumed by retriever (per-product query-cost attribution for chargeback). Keyed by retriever_id (resource_type='retriever' charges: queries, enrichment). Empty when no retriever-attributed usage.","examples":[{"ret_search_prod":4200,"ret_support_bot":900}]},"by_resource_kind":{"additionalProperties":{"type":"number"},"type":"object","title":"By Resource Kind","description":"Credits consumed by the kind of resource charged: extractor_run, retriever, mvs, upload, storage, inference or other. Read from the daily per-resource cost rollup, so it covers the days that rollup has run; empty when it has no rows for the month.","examples":[{"extractor_run":15000,"mvs":2350,"retriever":5100}]},"by_storage_class":{"additionalProperties":{"type":"number"},"type":"object","title":"By Storage Class","description":"Average stored data per storage class over the billing month, in GB-months (each day's GB summed, divided by the days in the month). Keyed by the bucket's class name, lowercased (standard, nearline, coldline, archive on GCS; standard, standard_ia, glacier and so on on S3). Empty when no storage was measured for the month.","examples":[{"nearline":40.0,"standard":12.5}]},"pending_credits":{"type":"number","title":"Pending Credits","description":"Unflushed sub-credit usage accrued but not yet committed to by_operation. Micro-priced per-op usage (e.g. MVS writes/queries at ~0.001 credit each) accumulates here and rolls into by_operation in whole credits as it crosses 1 — so real activity is visible immediately, before a whole credit accrues.","default":0.0,"examples":[0.014]},"pending_by_operation":{"additionalProperties":{"type":"number"},"type":"object","title":"Pending By Operation","description":"Unflushed fractional credits by operation type.","examples":[{"mvs_query":0.004,"mvs_write":0.01}]},"period_start":{"type":"string","format":"date-time","title":"Period Start","description":"Start of billing period"},"period_end":{"type":"string","format":"date-time","title":"Period End","description":"End of billing period"}},"type":"object","required":["billing_month","total_credits","total_cost_usd","by_operation","by_extractor","period_start","period_end"],"title":"UsageBreakdownResponse","description":"Response with detailed usage breakdown."},"UsageMetric":{"properties":{"time_bucket":{"type":"string","format":"date-time","title":"Time Bucket","description":"Time bucket timestamp"},"storage_gb_hours":{"type":"number","title":"Storage Gb Hours","description":"Storage GB-hours"},"upload_operations":{"type":"integer","title":"Upload Operations","description":"Upload operation count"},"sync_operations":{"type":"integer","title":"Sync Operations","description":"Sync operation count"},"total_credits":{"type":"integer","title":"Total Credits","description":"Total credits consumed"},"estimated_cost_usd":{"type":"number","title":"Estimated Cost Usd","description":"Estimated cost in USD"}},"type":"object","required":["time_bucket","storage_gb_hours","upload_operations","sync_operations","total_credits","estimated_cost_usd"],"title":"UsageMetric","description":"Usage and cost metrics for a time bucket."},"UsageStatistics":{"properties":{"total_queries":{"type":"integer","title":"Total Queries","description":"Total number of queries executed","default":0},"queries_last_24h":{"type":"integer","title":"Queries Last 24H","description":"Number of queries in the last 24 hours","default":0},"avg_latency_ms":{"type":"number","title":"Avg Latency Ms","description":"Average latency in milliseconds","default":0.0},"error_rate":{"type":"number","maximum":1.0,"minimum":0.0,"title":"Error Rate","description":"Error rate as a fraction (0.0 - 1.0)","default":0.0},"last_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Error","description":"Most recent error message for debugging"},"cache_hit_rate":{"anyOf":[{"type":"number","maximum":1.0,"minimum":0.0},{"type":"null"}],"title":"Cache Hit Rate","description":"Cache hit rate if caching is enabled (0.0 - 1.0)"}},"type":"object","title":"UsageStatistics","description":"Usage statistics for a retriever."},"UserCreateRequest":{"properties":{"email":{"type":"string","format":"email","title":"Email","description":"Unique email address within the organization."},"user_name":{"type":"string","maxLength":100,"minLength":2,"title":"User Name","description":"Display name shown in dashboards and audit trails."},"avatar_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Avatar Url","description":"Profile picture URL (e.g., from PropelAuth picture_url property)."},"role":{"$ref":"#/components/schemas/UserRole","description":"Default role within the organization if omitted.","default":"member"},"status":{"$ref":"#/components/schemas/UserStatus","description":"Initial lifecycle status. Use 'pending' for invited users who haven't accepted yet.","default":"active"},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Custom key/value metadata stored with the user record."}},"type":"object","required":["email","user_name"],"title":"UserCreateRequest","description":"Payload for creating an organization user.","examples":[{"email":"alice@example.com","role":"member","user_name":"Alice Smith"},{"email":"bob@example.com","metadata":{"department":"Engineering"},"role":"admin","user_name":"Bob Johnson"}]},"UserRole":{"type":"string","enum":["admin","member","viewer"],"title":"UserRole","description":"High-level organization role applied to users.\n\nRoles define the baseline permissions a user has within an organization:\n\n- ADMIN: Full administrative access including user management, billing,\n  and organization settings. Can create/modify/delete all resources.\n- MEMBER: Standard user access. Can create and manage their own resources\n  (namespaces, collections, clusters) but cannot manage other users or\n  organization-level settings.\n- VIEWER: Read-only access. Can view resources and execute retrievers but\n  cannot create, modify, or delete any resources."},"UserStatus":{"type":"string","enum":["active","suspended","pending"],"title":"UserStatus","description":"Lifecycle state of an organization user.\n\nStatus values control whether a user can authenticate and access resources:\n\n- ACTIVE: User is fully operational and can authenticate with their API keys.\n- SUSPENDED: User access is disabled. Setting this status revokes every API\n  key the user owns, and no new key can be created for them while suspended.\n  Account data is preserved. An admin can reactivate the user, who then\n  creates new keys: the revoked keys stay revoked.\n- PENDING: User invitation has been created but not yet accepted. User cannot\n  authenticate until they complete the onboarding flow."},"UserUpdateRequest":{"properties":{"user_name":{"anyOf":[{"type":"string","maxLength":100,"minLength":2},{"type":"null"}],"title":"User Name","description":"Updated display name."},"avatar_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Avatar Url","description":"Updated profile image URL (e.g., custom avatar to override Gravatar)."},"role":{"anyOf":[{"$ref":"#/components/schemas/UserRole"},{"type":"null"}],"description":"Updated organization role."},"status":{"anyOf":[{"$ref":"#/components/schemas/UserStatus"},{"type":"null"}],"description":"Lifecycle status update (active, suspended, pending). Any status other than active revokes every API key the user owns. Setting active again does not restore them: the user creates new keys."},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Replaces metadata with the provided dictionary when set."}},"type":"object","title":"UserUpdateRequest","description":"Partial update payload for a user."},"UuidIndexParams":{"properties":{"type":{"type":"string","title":"Type","default":"uuid"},"is_tenant":{"type":"boolean","title":"Is Tenant","default":false}},"type":"object","title":"UuidIndexParams","description":"Configuration for UUID index."},"ValidateMigrationRequest":{"properties":{"config":{"$ref":"#/components/schemas/MigrationConfig","description":"Migration configuration"}},"type":"object","required":["config"],"title":"ValidateMigrationRequest","description":"Request to validate a migration configuration without creating it."},"ValidateMigrationResponse":{"properties":{"validation_result":{"$ref":"#/components/schemas/ValidationResult","description":"Validation result"},"dependency_graph":{"anyOf":[{"$ref":"#/components/schemas/DependencyGraph"},{"type":"null"}],"description":"Dependency graph if validation passed"},"message":{"type":"string","title":"Message","description":"Human-readable message"}},"type":"object","required":["validation_result","message"],"title":"ValidateMigrationResponse","description":"Response for migration validation.","example":{"message":"Configuration is valid with 1 warning","validation_result":{"errors":[],"estimated_duration_seconds":1800,"estimated_resources":{"collection":5,"taxonomy":2},"valid":true,"warnings":[{"error_code":"RE_EXTRACT_COST_WARNING","message":"RE_EXTRACT migration will reprocess all documents and incur processing costs","severity":"warning"}]}}},"ValidateResult":{"properties":{"valid":{"type":"boolean","title":"Valid","description":"Whether the manifest is valid"},"resources":{"additionalProperties":{"type":"integer"},"type":"object","title":"Resources","description":"Count of each resource type"},"missing_secrets":{"items":{"type":"string"},"type":"array","title":"Missing Secrets","description":"Secret names referenced but not configured"},"errors":{"items":{"type":"string"},"type":"array","title":"Errors","description":"Validation errors"},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings","description":"Validation warnings"},"parameters":{"items":{"$ref":"#/components/schemas/ManifestParameterSpec"},"type":"array","title":"Parameters","description":"The parameters the manifest declares, returned whether or not values were supplied, so a form can collect them before apply"}},"type":"object","required":["valid"],"title":"ValidateResult","description":"Result of validating a manifest.","examples":[{"errors":[],"missing_secrets":[],"resources":{"buckets":2,"collections":1,"namespaces":1,"retrievers":1},"valid":true,"warnings":[]}]},"ValidationError":{"properties":{"error_code":{"type":"string","title":"Error Code","description":"Error code"},"message":{"type":"string","title":"Message","description":"Human-readable error message"},"resource_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Id","description":"Related resource ID"},"resource_type":{"anyOf":[{"$ref":"#/components/schemas/shared__namespaces__migrations__models__ResourceType"},{"type":"null"}],"description":"Resource type"},"severity":{"type":"string","title":"Severity","description":"Severity: error or warning","default":"error"}},"type":"object","required":["error_code","message"],"title":"ValidationError","description":"Validation error for pre-flight checks."},"ValidationResult":{"properties":{"valid":{"type":"boolean","title":"Valid","description":"Whether migration can proceed"},"errors":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Errors","description":"Validation errors"},"warnings":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Warnings","description":"Validation warnings"},"estimated_resources":{"additionalProperties":{"type":"integer"},"propertyNames":{"$ref":"#/components/schemas/shared__namespaces__migrations__models__ResourceType"},"type":"object","title":"Estimated Resources","description":"Estimated resource counts"},"estimated_duration_seconds":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Estimated Duration Seconds","description":"Estimated migration duration"}},"type":"object","required":["valid"],"title":"ValidationResult","description":"Result of pre-flight validation."},"VectorBackendUsageResponse":{"properties":{"vector_backend":{"type":"string","title":"Vector Backend","description":"Active vector backend for this tenant","examples":["mvs"]},"billing_month":{"type":"string","title":"Billing Month","description":"Billing month (YYYY-MM)","examples":["2026-05"]},"namespace_count":{"type":"integer","title":"Namespace Count","description":"Number of namespaces billed"},"vectors_stored":{"type":"integer","title":"Vectors Stored","description":"Total vectors stored across all namespaces"},"storage_bytes":{"type":"integer","title":"Storage Bytes","description":"Total storage bytes"},"queries":{"type":"integer","title":"Queries","description":"Total search queries in billing period"},"writes":{"type":"integer","title":"Writes","description":"Total writes in billing period"},"cost_breakdown":{"$ref":"#/components/schemas/VectorUsageBreakdown","description":"Detailed cost breakdown"},"total_credits":{"type":"integer","title":"Total Credits","description":"Total credits for vector backend usage"},"total_cost_usd":{"type":"number","title":"Total Cost Usd","description":"Total cost in USD"}},"type":"object","required":["vector_backend","billing_month","namespace_count","vectors_stored","storage_bytes","queries","writes","cost_breakdown","total_credits","total_cost_usd"],"title":"VectorBackendUsageResponse","description":"Response with vector backend usage details."},"VectorBasedConfig-Input":{"properties":{"feature_uri":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Feature Uri","description":"DEPRECATED: Use feature_uris instead. Canonical feature URI for the vector embedding to cluster. Format: 'mixpeek://{extractor}@{version}/{output}'. For multi-feature clustering, use feature_uris (plural) instead.","examples":["mixpeek://multimodal_extractor@v1/vertex_multimodal_embedding","mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1"]},"feature_uris":{"anyOf":[{"items":{"type":"string"},"type":"array","minItems":1},{"type":"null"}],"title":"Feature Uris","description":"RECOMMENDED. List of feature URIs to cluster. Format: 'mixpeek://{extractor}@{version}/{output}'. For single-feature clustering, provide a list with one element. For multi-feature clustering, provide multiple feature URIs. Each feature must exist in all input collections.","examples":[["mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1"],["mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1","mixpeek://image_extractor@v1/embedding"]]},"feature_extractor_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Feature Extractor Name","description":"Internal field populated from feature_uri. Do not set manually."},"version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Version","description":"Internal field populated from feature_uri. Do not set manually."},"output_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Output Name","description":"Internal field populated from feature_uri. Do not set manually."},"clustering_method":{"$ref":"#/components/schemas/ClusteringAlgorithm","description":"Clustering algorithm to use"},"sample_size":{"anyOf":[{"type":"integer","maximum":1000000.0},{"type":"null"}],"title":"Sample Size","description":"Number of samples to use for clustering. If not set, defaults are applied per algorithm to prevent out-of-memory: HDBSCAN/DBSCAN/OPTICS: 50,000 (O(N²) memory), Spectral/Agglomerative: 50,000, KMeans/GaussianMixture/MeanShift: 100,000. KMeans/GMM hard max: 1,000,000; O(N²) algorithms: 100,000."},"kmeans_parameters":{"anyOf":[{"$ref":"#/components/schemas/KMeansParams"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Kmeans Parameters","description":"Parameters for K-means clustering (deprecated, use algorithm_params)"},"dbscan_parameters":{"anyOf":[{"$ref":"#/components/schemas/DBSCANParams"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Dbscan Parameters","description":"Parameters for DBSCAN clustering (deprecated, use algorithm_params)"},"hdbscan_parameters":{"anyOf":[{"$ref":"#/components/schemas/HDBSCANParams"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Hdbscan Parameters","description":"Parameters for HDBSCAN clustering (deprecated, use algorithm_params)"},"algorithm_params":{"anyOf":[{"$ref":"#/components/schemas/KMeansParams"},{"$ref":"#/components/schemas/DBSCANParams"},{"$ref":"#/components/schemas/HDBSCANParams"},{"$ref":"#/components/schemas/AgglomerativeParams"},{"$ref":"#/components/schemas/SpectralParams"},{"$ref":"#/components/schemas/GaussianMixtureParams"},{"$ref":"#/components/schemas/MeanShiftParams"},{"$ref":"#/components/schemas/OPTICSParams"},{"$ref":"#/components/schemas/LeidenParams"},{"$ref":"#/components/schemas/EVoCParams"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Algorithm Params","description":"Algorithm-specific parameters"},"multi_feature_strategy":{"type":"string","enum":["concatenate","independent","weighted"],"title":"Multi Feature Strategy","description":"Strategy for handling multiple feature vectors:\n- concatenate: Combine embeddings into one vector, single clustering\n- independent: Run separate clustering per feature\n- weighted: Learn optimal feature weights","default":"concatenate"},"normalize_features":{"type":"boolean","title":"Normalize Features","description":"Apply L2 normalization to each feature block before concatenation. Prevents feature dominance when combining different modalities. Only applies when multi_feature_strategy='concatenate'.","default":true},"feature_weights":{"anyOf":[{"additionalProperties":{"type":"number"},"type":"object"},{"type":"null"}],"title":"Feature Weights","description":"Optional per-feature weights (0.0-1.0) for concatenation strategy. Keys are feature URIs, values are weights. Example: {'mixpeek://text@v1/emb': 0.7, 'mixpeek://image@v1/emb': 0.3}. Defaults to equal weights (1.0) if not specified. Only applies when multi_feature_strategy='concatenate'. If multi_feature_strategy='weighted' and this is None, weights are learned automatically using weight_learning_config.","examples":[{"mixpeek://image_extractor@v1/embedding":0.3,"mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1":0.7}]},"weight_learning_config":{"anyOf":[{"$ref":"#/components/schemas/WeightLearningConfig"},{"type":"null"}],"description":"Configuration for automatic feature weight learning. Only used when multi_feature_strategy='weighted' and feature_weights is None. If feature_weights is provided, manual weights are used instead of learning. If this is None when learning is needed, default WeightLearningConfig is used.","examples":[{"max_iterations":20,"method":"bayesian","metric":"silhouette","sample_size":5000},{"max_iterations":5,"method":"grid_search","metric":"silhouette"}]},"output_strategy":{"type":"string","enum":["single","per_feature"],"title":"Output Strategy","description":"Output collection creation strategy:\n- single: Create one collection with all feature vectors\n- per_feature: Create separate collections for each feature (for hierarchical taxonomies)","default":"single"},"effective_feature_method":{"type":"string","enum":["mean","median","medoid"],"title":"Effective Feature Method","description":"Method for calculating cluster centroids:\n- mean: Average of all vectors in cluster\n- median: Median vector (robust to outliers)\n- medoid: Actual cluster member closest to centroid","default":"mean"},"enrich_source":{"type":"boolean","title":"Enrich Source","description":"Whether to enrich source documents with cluster_id","default":false},"face_cluster_merge":{"anyOf":[{"$ref":"#/components/schemas/FaceClusterMergeConfig"},{"type":"null"}],"description":"Optional post-HDBSCAN agglomerative merge pass for face identity clusters. HDBSCAN over ArcFace 512d face embeddings tends to over-split the same person across pose/lighting variants. When provided with enabled=true, two clusters merge if their centroid cosine meets the threshold AND one of the spatial signals (bbox IoU on overlapping frames, scene-id Jaccard) clears its threshold. Leave null (default) for non-face clusterings — existing behavior is preserved."},"preprocessing_steps":{"anyOf":[{"items":{"oneOf":[{"$ref":"#/components/schemas/TSNEParams"},{"$ref":"#/components/schemas/UMAPParams"},{"$ref":"#/components/schemas/WhiteningParams"},{"$ref":"#/components/schemas/NoReduction"}],"discriminator":{"propertyName":"method","mapping":{"none":"#/components/schemas/NoReduction","tsne":"#/components/schemas/TSNEParams","umap":"#/components/schemas/UMAPParams","whitening":"#/components/schemas/WhiteningParams"}}},"type":"array"},{"type":"null"}],"title":"Preprocessing Steps","description":"Ordered list of preprocessing steps applied before clustering. Steps execute in order. Common patterns:\n- [whitening, umap]: Decorrelate then reduce — best for high-dimensional embeddings\n- [umap]: UMAP pre-reduction only (defaults: 50D, cosine, n_neighbors=30)\n- [whitening]: Whitening only — improves density-based clustering without dimension reduction\n\nIf set, overrides any default dimensionality reduction.","examples":[[{"method":"whitening","regularization":1e-05},{"method":"umap","min_dist":0.0,"n_components":50,"n_neighbors":30}],[{"method":"umap","n_components":50}]]},"hierarchical":{"type":"boolean","title":"Hierarchical","description":"Enable recursive sub-clustering. After initial clustering, each cluster with enough members is sub-divided using UMAP+HDBSCAN recursively. Produces hierarchical cluster IDs (e.g., cl_0_sub_1_sub_0).","default":false},"max_hierarchy_depth":{"type":"integer","maximum":5.0,"minimum":1.0,"title":"Max Hierarchy Depth","description":"Maximum recursion depth for hierarchical sub-clustering.","default":3},"vis_n_components":{"type":"integer","enum":[2,3],"title":"Vis N Components","description":"Number of dimensions for visualization coordinates (2 or 3). When 3, the z coordinate is populated for depth/size-based rendering. Stored on the cluster and used as the default for all executions.","default":2},"layout_stability":{"anyOf":[{"type":"string","enum":["none","transform","align"]},{"type":"null"}],"title":"Layout Stability","description":"How the visualization layout behaves across re-executions. 'align' (the default when unset): re-fit the projection as usual, then register the new layout onto the previous run's coordinates with a least-squares similarity transform computed over shared documents — the map keeps its shape and orientation, so users don't lose their bearings. 'transform': additionally reuse the previous run's saved projection reducer when compatible (same features/dimensionality), so existing documents stay pixel-stable and new documents land in the established frame; falls back to 'align', then to a raw layout. 'none': independent re-layout every run (pre- behavior). Pure post-processing of coordinates — cluster assignments are never affected. The execution record reports what was actually applied in layout_stability_applied."}},"type":"object","required":["clustering_method"],"title":"VectorBasedConfig","description":"Configuration for vector-based clustering.\n\nUse canonical feature URIs to specify which vector embeddings to cluster.\nFeature URIs follow the format: mixpeek://{extractor}@{version}/{output}\n\nSupports both single and multi-feature clustering:\n- Single feature: Provide one feature_uri for standard clustering\n- Multi-feature: Provide multiple feature_uris for hybrid clustering\n\nExamples:\n    Single feature:\n    {\n        \"feature_uri\": \"mixpeek://multimodal_extractor@v1/vertex_multimodal_embedding\",\n        \"clustering_method\": \"hdbscan\",\n        \"sample_size\": 1000\n    }\n\n    Multi-feature:\n    {\n        \"feature_uris\": [\n            \"mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1\",\n            \"mixpeek://image_extractor@v1/embedding\"\n        ],\n        \"clustering_method\": \"hdbscan\",\n        \"multi_feature_strategy\": \"concatenate\"\n    }","examples":[{"algorithm_params":{"min_cluster_size":10,"min_samples":5},"clustering_method":"hdbscan","description":"HDBSCAN clustering with multimodal embeddings","feature_uri":"mixpeek://multimodal_extractor@v1/vertex_multimodal_embedding","sample_size":1000},{"clustering_method":"hdbscan","description":"Face-identity clustering with post-HDBSCAN merge","face_cluster_merge":{"bbox_iou_threshold":0.4,"centroid_cosine_threshold":0.55,"enabled":true,"scene_jaccard_threshold":0.3},"feature_uris":["mixpeek://face_identity_extractor@v1/face_embedding"]},{"algorithm_params":{"n_clusters":10},"clustering_method":"kmeans","description":"K-means clustering with text embeddings","feature_uri":"mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1"},{"algorithm_params":{"eps":0.5,"min_samples":5},"clustering_method":"dbscan","description":"DBSCAN clustering with CLIP image embeddings","feature_uri":"mixpeek://clip@v1/image_embedding"}]},"VectorBasedConfig-Output":{"properties":{"feature_uri":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Feature Uri","description":"DEPRECATED: Use feature_uris instead. Canonical feature URI for the vector embedding to cluster. Format: 'mixpeek://{extractor}@{version}/{output}'. For multi-feature clustering, use feature_uris (plural) instead.","examples":["mixpeek://multimodal_extractor@v1/vertex_multimodal_embedding","mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1"]},"feature_uris":{"anyOf":[{"items":{"type":"string"},"type":"array","minItems":1},{"type":"null"}],"title":"Feature Uris","description":"RECOMMENDED. List of feature URIs to cluster. Format: 'mixpeek://{extractor}@{version}/{output}'. For single-feature clustering, provide a list with one element. For multi-feature clustering, provide multiple feature URIs. Each feature must exist in all input collections.","examples":[["mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1"],["mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1","mixpeek://image_extractor@v1/embedding"]]},"clustering_method":{"$ref":"#/components/schemas/ClusteringAlgorithm","description":"Clustering algorithm to use"},"sample_size":{"anyOf":[{"type":"integer","maximum":1000000.0},{"type":"null"}],"title":"Sample Size","description":"Number of samples to use for clustering. If not set, defaults are applied per algorithm to prevent out-of-memory: HDBSCAN/DBSCAN/OPTICS: 50,000 (O(N²) memory), Spectral/Agglomerative: 50,000, KMeans/GaussianMixture/MeanShift: 100,000. KMeans/GMM hard max: 1,000,000; O(N²) algorithms: 100,000."},"kmeans_parameters":{"anyOf":[{"$ref":"#/components/schemas/KMeansParams"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Kmeans Parameters","description":"Parameters for K-means clustering (deprecated, use algorithm_params)"},"dbscan_parameters":{"anyOf":[{"$ref":"#/components/schemas/DBSCANParams"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Dbscan Parameters","description":"Parameters for DBSCAN clustering (deprecated, use algorithm_params)"},"hdbscan_parameters":{"anyOf":[{"$ref":"#/components/schemas/HDBSCANParams"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Hdbscan Parameters","description":"Parameters for HDBSCAN clustering (deprecated, use algorithm_params)"},"algorithm_params":{"anyOf":[{"$ref":"#/components/schemas/KMeansParams"},{"$ref":"#/components/schemas/DBSCANParams"},{"$ref":"#/components/schemas/HDBSCANParams"},{"$ref":"#/components/schemas/AgglomerativeParams"},{"$ref":"#/components/schemas/SpectralParams"},{"$ref":"#/components/schemas/GaussianMixtureParams"},{"$ref":"#/components/schemas/MeanShiftParams"},{"$ref":"#/components/schemas/OPTICSParams"},{"$ref":"#/components/schemas/LeidenParams"},{"$ref":"#/components/schemas/EVoCParams"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Algorithm Params","description":"Algorithm-specific parameters"},"multi_feature_strategy":{"type":"string","enum":["concatenate","independent","weighted"],"title":"Multi Feature Strategy","description":"Strategy for handling multiple feature vectors:\n- concatenate: Combine embeddings into one vector, single clustering\n- independent: Run separate clustering per feature\n- weighted: Learn optimal feature weights","default":"concatenate"},"normalize_features":{"type":"boolean","title":"Normalize Features","description":"Apply L2 normalization to each feature block before concatenation. Prevents feature dominance when combining different modalities. Only applies when multi_feature_strategy='concatenate'.","default":true},"feature_weights":{"anyOf":[{"additionalProperties":{"type":"number"},"type":"object"},{"type":"null"}],"title":"Feature Weights","description":"Optional per-feature weights (0.0-1.0) for concatenation strategy. Keys are feature URIs, values are weights. Example: {'mixpeek://text@v1/emb': 0.7, 'mixpeek://image@v1/emb': 0.3}. Defaults to equal weights (1.0) if not specified. Only applies when multi_feature_strategy='concatenate'. If multi_feature_strategy='weighted' and this is None, weights are learned automatically using weight_learning_config.","examples":[{"mixpeek://image_extractor@v1/embedding":0.3,"mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1":0.7}]},"weight_learning_config":{"anyOf":[{"$ref":"#/components/schemas/WeightLearningConfig"},{"type":"null"}],"description":"Configuration for automatic feature weight learning. Only used when multi_feature_strategy='weighted' and feature_weights is None. If feature_weights is provided, manual weights are used instead of learning. If this is None when learning is needed, default WeightLearningConfig is used.","examples":[{"max_iterations":20,"method":"bayesian","metric":"silhouette","sample_size":5000},{"max_iterations":5,"method":"grid_search","metric":"silhouette"}]},"output_strategy":{"type":"string","enum":["single","per_feature"],"title":"Output Strategy","description":"Output collection creation strategy:\n- single: Create one collection with all feature vectors\n- per_feature: Create separate collections for each feature (for hierarchical taxonomies)","default":"single"},"effective_feature_method":{"type":"string","enum":["mean","median","medoid"],"title":"Effective Feature Method","description":"Method for calculating cluster centroids:\n- mean: Average of all vectors in cluster\n- median: Median vector (robust to outliers)\n- medoid: Actual cluster member closest to centroid","default":"mean"},"enrich_source":{"type":"boolean","title":"Enrich Source","description":"Whether to enrich source documents with cluster_id","default":false},"face_cluster_merge":{"anyOf":[{"$ref":"#/components/schemas/FaceClusterMergeConfig"},{"type":"null"}],"description":"Optional post-HDBSCAN agglomerative merge pass for face identity clusters. HDBSCAN over ArcFace 512d face embeddings tends to over-split the same person across pose/lighting variants. When provided with enabled=true, two clusters merge if their centroid cosine meets the threshold AND one of the spatial signals (bbox IoU on overlapping frames, scene-id Jaccard) clears its threshold. Leave null (default) for non-face clusterings — existing behavior is preserved."},"preprocessing_steps":{"anyOf":[{"items":{"oneOf":[{"$ref":"#/components/schemas/TSNEParams"},{"$ref":"#/components/schemas/UMAPParams"},{"$ref":"#/components/schemas/WhiteningParams"},{"$ref":"#/components/schemas/NoReduction"}],"discriminator":{"propertyName":"method","mapping":{"none":"#/components/schemas/NoReduction","tsne":"#/components/schemas/TSNEParams","umap":"#/components/schemas/UMAPParams","whitening":"#/components/schemas/WhiteningParams"}}},"type":"array"},{"type":"null"}],"title":"Preprocessing Steps","description":"Ordered list of preprocessing steps applied before clustering. Steps execute in order. Common patterns:\n- [whitening, umap]: Decorrelate then reduce — best for high-dimensional embeddings\n- [umap]: UMAP pre-reduction only (defaults: 50D, cosine, n_neighbors=30)\n- [whitening]: Whitening only — improves density-based clustering without dimension reduction\n\nIf set, overrides any default dimensionality reduction.","examples":[[{"method":"whitening","regularization":1e-05},{"method":"umap","min_dist":0.0,"n_components":50,"n_neighbors":30}],[{"method":"umap","n_components":50}]]},"hierarchical":{"type":"boolean","title":"Hierarchical","description":"Enable recursive sub-clustering. After initial clustering, each cluster with enough members is sub-divided using UMAP+HDBSCAN recursively. Produces hierarchical cluster IDs (e.g., cl_0_sub_1_sub_0).","default":false},"max_hierarchy_depth":{"type":"integer","maximum":5.0,"minimum":1.0,"title":"Max Hierarchy Depth","description":"Maximum recursion depth for hierarchical sub-clustering.","default":3},"vis_n_components":{"type":"integer","enum":[2,3],"title":"Vis N Components","description":"Number of dimensions for visualization coordinates (2 or 3). When 3, the z coordinate is populated for depth/size-based rendering. Stored on the cluster and used as the default for all executions.","default":2},"layout_stability":{"anyOf":[{"type":"string","enum":["none","transform","align"]},{"type":"null"}],"title":"Layout Stability","description":"How the visualization layout behaves across re-executions. 'align' (the default when unset): re-fit the projection as usual, then register the new layout onto the previous run's coordinates with a least-squares similarity transform computed over shared documents — the map keeps its shape and orientation, so users don't lose their bearings. 'transform': additionally reuse the previous run's saved projection reducer when compatible (same features/dimensionality), so existing documents stay pixel-stable and new documents land in the established frame; falls back to 'align', then to a raw layout. 'none': independent re-layout every run (pre- behavior). Pure post-processing of coordinates — cluster assignments are never affected. The execution record reports what was actually applied in layout_stability_applied."}},"type":"object","required":["clustering_method"],"title":"VectorBasedConfig","description":"Configuration for vector-based clustering.\n\nUse canonical feature URIs to specify which vector embeddings to cluster.\nFeature URIs follow the format: mixpeek://{extractor}@{version}/{output}\n\nSupports both single and multi-feature clustering:\n- Single feature: Provide one feature_uri for standard clustering\n- Multi-feature: Provide multiple feature_uris for hybrid clustering\n\nExamples:\n    Single feature:\n    {\n        \"feature_uri\": \"mixpeek://multimodal_extractor@v1/vertex_multimodal_embedding\",\n        \"clustering_method\": \"hdbscan\",\n        \"sample_size\": 1000\n    }\n\n    Multi-feature:\n    {\n        \"feature_uris\": [\n            \"mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1\",\n            \"mixpeek://image_extractor@v1/embedding\"\n        ],\n        \"clustering_method\": \"hdbscan\",\n        \"multi_feature_strategy\": \"concatenate\"\n    }","examples":[{"algorithm_params":{"min_cluster_size":10,"min_samples":5},"clustering_method":"hdbscan","description":"HDBSCAN clustering with multimodal embeddings","feature_uri":"mixpeek://multimodal_extractor@v1/vertex_multimodal_embedding","sample_size":1000},{"clustering_method":"hdbscan","description":"Face-identity clustering with post-HDBSCAN merge","face_cluster_merge":{"bbox_iou_threshold":0.4,"centroid_cosine_threshold":0.55,"enabled":true,"scene_jaccard_threshold":0.3},"feature_uris":["mixpeek://face_identity_extractor@v1/face_embedding"]},{"algorithm_params":{"n_clusters":10},"clustering_method":"kmeans","description":"K-means clustering with text embeddings","feature_uri":"mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1"},{"algorithm_params":{"eps":0.5,"min_samples":5},"clustering_method":"dbscan","description":"DBSCAN clustering with CLIP image embeddings","feature_uri":"mixpeek://clip@v1/image_embedding"}]},"VectorConfigSpec":{"properties":{"name":{"type":"string","title":"Name","description":"Name of the vector index","example":"clip"},"dimension":{"type":"integer","minimum":1.0,"title":"Dimension","description":"Vector dimension","example":768},"metric":{"type":"string","title":"Metric","description":"Distance metric: cosine, euclidean, or dot_product","default":"cosine","example":"cosine"}},"type":"object","required":["name","dimension"],"title":"VectorConfigSpec","description":"Per-vector configuration for standalone namespaces (BYO vectors)."},"VectorConfigSpecModel":{"properties":{"name":{"type":"string","title":"Name","description":"Vector index name (e.g. 'text-embedding')"},"dimension":{"type":"integer","minimum":1.0,"title":"Dimension","description":"Vector dimension"},"metric":{"type":"string","title":"Metric","description":"Distance metric: cosine, euclidean, or dot_product","default":"cosine"}},"type":"object","required":["name","dimension"],"title":"VectorConfigSpecModel","description":"Per-vector configuration within a standalone namespace."},"VectorDataType":{"type":"string","enum":["float32","uint8"],"title":"VectorDataType","description":"Vector data type."},"VectorFieldSpec":{"properties":{"field":{"type":"string","minLength":1,"title":"Field","description":"Key in each row that holds the vector, as a list of numbers. A row without this key, or with a vector of the wrong length, is reported as a failed row and the other rows are still written.","examples":["embedding"]},"name":{"type":"string","title":"Name","description":"Name of the vector index the vector is stored under. Use this name in a feature_search stage to search the rows with a raw query vector. Letters, digits and underscores, starting with a letter, at most 64 characters, and unique within vector_fields.","examples":["text_embedding"]},"dimensions":{"type":"integer","maximum":65536.0,"minimum":1.0,"title":"Dimensions","description":"Length of every vector in this field.","examples":[384,768,1536]},"distance":{"type":"string","enum":["cosine","dot","euclidean"],"title":"Distance","description":"Distance metric for the index. Use the metric the vectors were trained for.","default":"cosine"}},"type":"object","required":["field","name","dimensions"],"title":"VectorFieldSpec","description":"One precomputed vector carried on each row of a JSONL or Parquet object."},"VectorFrontier":{"properties":{"capture_mode":{"type":"string","title":"Capture Mode","description":"'scroll_bracketed': vectors were exported by a scroll while writes continued, so the export lies between shards_start and shards_end and matches no single commit. 'not_captured': this snapshot exported no vectors.","default":"scroll_bracketed"},"shards_start":{"additionalProperties":{"$ref":"#/components/schemas/ShardFrontier"},"type":"object","title":"Shards Start","description":"Per-shard frontier read before the export"},"shards_end":{"additionalProperties":{"$ref":"#/components/schemas/ShardFrontier"},"type":"object","title":"Shards End","description":"Per-shard frontier read after the export"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"}},"type":"object","title":"VectorFrontier"},"VectorIndex":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"OPTIONAL. Named vector identifier. If not provided, auto-derived from inference_service_id using the same conversion as inference_name (org/model -> org__model with hyphens as underscores). This enables cross-extractor compatibility: extractors using the same model will share the same named vector in the vector store, allowing direct vector search across collections without fusion logic.","examples":["intfloat__multilingual_e5_large_instruct","google__siglip_base_patch16_224","jinaai__jina_embeddings_v2_base_code"]},"description":{"type":"string","minLength":10,"title":"Description","description":"REQUIRED. Human-readable description of what this vector index represents. Explain the content type, use cases, and search characteristics. Shown in API documentation and collection metadata. Be specific about what embeddings are stored here.","examples":["Dense vector embedding for text content using E5-Large model","Video segment embeddings for semantic visual search","Sparse keyword expansion embeddings for explainable search"]},"dimensions":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Dimensions","description":"Number of vector dimensions. REQUIRED for DENSE vectors (e.g., 1024 for E5-Large, 1408 for multimodal). NOT REQUIRED for SPARSE vectors (dimensions determined dynamically). Must match the output dimensions of the inference service. Cannot be changed after index creation without recreating the collection.","examples":[1024,1408,768,512]},"type":{"$ref":"#/components/schemas/VectorType","description":"REQUIRED. Vector storage format type. Determines how vectors are stored and searched in the vector store. Use DENSE for traditional embeddings (most common), SPARSE for keyword-based models like SPLADE, MULTI_DENSE for late-interaction models like ColBERT. Must match the output format of your inference service.","examples":["dense","sparse","multi_dense"]},"distance":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Distance","description":"Distance metric for similarity search. OPTIONAL - defaults to 'cosine' (normalized dot product). Options: 'cosine' (most common, normalized), 'dot' (raw dot product), 'euclidean' (L2 distance), 'manhattan' (L1 distance). Cosine recommended for most embeddings as it's scale-invariant. Must match the metric your model was trained with.","default":"cosine","examples":["cosine","dot","euclidean"]},"datatype":{"anyOf":[{"$ref":"#/components/schemas/VectorDataType"},{"type":"null"}],"description":"Data type for storing vector values. OPTIONAL - defaults to FLOAT32 (standard precision). Use FLOAT32 for general use (4 bytes per dimension). Use FLOAT16 to save 50% storage with minimal quality loss. Use UINT8 for maximum compression (quantization, ~2% quality loss). Lower precision = smaller storage + faster search, slightly lower accuracy.","default":"float32","examples":["float32","float16","uint8"]},"on_disk":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"On Disk","description":"OPTIONAL. If true, vectors stored on disk instead of RAM. Defaults to true for memory efficiency. Set to false for faster search with higher memory usage. Trade-off: on_disk=true saves ~95% RAM but ~10x slower search. Recommended to keep default (true) unless RAM is abundant and low latency critical."},"supported_inputs":{"anyOf":[{"items":{"$ref":"#/components/schemas/BucketSchemaFieldType"},"type":"array"},{"type":"null"}],"title":"Supported Inputs","description":"OPTIONAL. List of bucket schema field types this vector can process. Validates that input fields are compatible with this index. Examples: TEXT and STRING for text embeddings, VIDEO and IMAGE for multimodal embeddings, DOCUMENT for PDF extractors. Used for validation during collection creation.","examples":[["text","string"],["video","image"],["document"]]},"inference_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inference Name","description":"DEPRECATED: Use inference_service_id instead. Identifier of the inference service to generate embeddings. Must reference a valid inference service registered in the system. Examples: 'multilingual_e5_large_instruct_v1' for text, 'vertex_multimodal_embedding' for video, 'laion_clip_vit_l_14_v1' for images. This determines which model creates the vectors during ingestion. Cannot be changed after collection creation.","examples":["multilingual_e5_large_instruct_v1","vertex_multimodal_embedding","laion_clip_vit_l_14_v1","openai_text_embedding_3_small"]},"inference_service_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inference Service Id","description":"RECOMMENDED. Service ID in org/name format (e.g., 'intfloat/e5-large'). When set, dimensions and distance are automatically derived from the registry. This is the canonical identifier for cross-plugin compatibility. Plugins using the same service_id can search across each other's vectors. Takes precedence over inference_name when both are set.","examples":["intfloat/e5-large","google/vertex-multimodal","google/siglip","jinaai/jina-code-v2"]},"purpose":{"anyOf":[{"$ref":"#/components/schemas/VectorPurpose"},{"type":"null"}],"description":"RECOMMENDED. Semantic purpose of this vector index. Enables pipelines to look up vector configs by purpose (text, code, image) without needing to know the specific inference_service_id. This provides automatic configuration - the pipeline just says 'give me the text vector' and gets the correct column name. If not specified, pipeline must use inference_service_id lookup.","examples":["text","code","image","multimodal"]},"vector_name_override":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vector Name Override","description":"OPTIONAL. Override for Named vector identifier. When set, this value is used as the vector name instead of auto-deriving from inference_service_id. This enables multiple vectors from the same embedding model with different storage names. The inference_service_id is still used for cross-extractor compatibility checking, but storage uses this custom name. Use case: A single extractor producing N vectors (e.g., title_embedding, body_embedding) using the same model but needing separate storage.","examples":["title_embedding","body_embedding","summary_embedding"]},"supports_multi_query":{"type":"boolean","title":"Supports Multi Query","description":"Whether this vector index supports multi-content queries at retrieval time. When True, the feature_search stage accepts input_mode='multi_content' — a list of URLs and/or text strings that are embedded together in one API call to produce a single query vector. Only set for extractors whose underlying model natively supports multi-file input (e.g., gemini_multifile_extractor using Gemini Embedding 2).","default":false}},"type":"object","required":["description","type"],"title":"VectorIndex","description":"Configuration for a single vector index in the vector store.\n\nDefines the fully-qualified vector index including storage name, dimensions,\ndistance metric, and inference service. This is the actual index that gets\ncreated in the vector store and used for vector similarity search.\n\nKey Concepts:\n    - The `name` field is the FULL qualified name used as the vector store collection name\n    - Format: {extractor}_{version}_{output} (e.g., \"text_extractor_v1_embedding\")\n    - This ensures namespace isolation between extractors and versions\n    - Different from VectorIndexDefinition.name which is the short user-facing name\n\nUse Cases:\n    - Define vector storage configuration for feature extractors\n    - Specify inference service and model parameters\n    - Configure distance metrics for similarity search\n    - Set storage optimization (on-disk for large vectors)\n\nRequirements:\n    - name: REQUIRED - Must be unique across all extractors in namespace\n    - description: REQUIRED - Explain what this vector represents\n    - dimensions: REQUIRED for DENSE vectors, OPTIONAL for SPARSE\n    - type: REQUIRED - Must match VectorType enum\n    - inference_name: REQUIRED - Must reference a valid inference service","examples":[{"datatype":"float32","description":"Dense vector embedding for text content using E5-Large multilingual model. Optimized for semantic search across 100+ languages.","dimensions":1024,"distance":"cosine","inference_name":"multilingual_e5_large_instruct_v1","name":"text_extractor_v1_embedding","supported_inputs":["text","string"],"type":"dense"},{"datatype":"float32","description":"Dense vector embeddings for video segments using Google's multimodal model. Supports visual semantic search.","dimensions":1408,"distance":"cosine","inference_name":"vertex_multimodal_embedding","name":"multimodal_extractor_v1_video_embedding","supported_inputs":["video","image"],"type":"dense"},{"datatype":"float32","description":"Dense vector embeddings for images using SigLIP model. Supports visual semantic search.","dimensions":768,"distance":"cosine","inference_name":"siglip_base_v1","name":"image_extractor_v1_embedding","supported_inputs":["image"],"type":"dense"},{"description":"Title embedding using E5-Large - same model as body but stored separately.","inference_service_id":"intfloat/multilingual-e5-large-instruct","type":"dense","vector_name_override":"title_embedding"},{"description":"Body embedding using E5-Large - same model as title but stored separately.","inference_service_id":"intfloat/multilingual-e5-large-instruct","type":"dense","vector_name_override":"body_embedding"}]},"VectorIndexDefinition":{"properties":{"feature_uri":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Feature Uri","description":"Full feature URI for this vector index. Format: mixpeek://{extractor}@{version}/{output_name}. Populated at collection creation time. Use this URI in retriever feature_filter stages.","examples":["mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1","mixpeek://multimodal_extractor@v1/vertex_multimodal_embedding"]},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name","description":"OPTIONAL. Human-friendly label for this feature output (e.g. 'face' for insightface__arcface, 'text embedding' for an e5 index). Presentation-layer vocabulary shared by Studio, docs and pricing — the technical `name` stays the URI-addressable identity and MUST still be shown/available wherever this label is used."},"name":{"type":"string","minLength":1,"title":"Name","description":"REQUIRED. Short user-facing output name used in feature URIs. This is NOT the vector store collection name - it's the clean identifier for this output. Format: Simple snake_case name (e.g., 'embedding', 'video_embedding', 'sparse_embedding'). Used in feature URIs: mixpeek://{extractor}@{version}/{THIS_NAME}. Must be unique within this extractor's outputs.","examples":["embedding","video_embedding","transcription_embedding","sparse_embedding"]},"description":{"type":"string","minLength":10,"title":"Description","description":"REQUIRED. Human-readable description of this vector output. Explain what content this output embeds and when to use it. Appears in API documentation and helps users choose the right feature URI. Be specific about the embedding type and use cases.","examples":["Vector index for video segment embeddings","Dense text embeddings for semantic search","Sparse keyword embeddings for explainable retrieval"]},"type":{"type":"string","enum":["single","multi"],"title":"Type","description":"REQUIRED. Index type - 'single' or 'multi'. 'single': One vector per document (most common). Use for standard embeddings. 'multi': Multiple named vectors per document (rare). Use for hybrid/ensemble. Determines whether 'index' field contains VectorIndex or MultiVectorIndex.","examples":["single","multi"]},"index":{"anyOf":[{"$ref":"#/components/schemas/VectorIndex"},{"$ref":"#/components/schemas/MultiVectorIndex"}],"title":"Index Configuration","description":"REQUIRED. Nested index configuration. VectorIndex if type='single' (most common case). MultiVectorIndex if type='multi' (rare, for hybrid search). Contains the full storage configuration including vector store collection name, dimensions, distance metric, and inference service."}},"type":"object","required":["name","description","type","index"],"title":"VectorIndexDefinition","description":"Complete vector index definition that can be either single or multi-vector.\n\nThis is the USER-FACING representation that appears in feature extractor definitions\nand API responses. It wraps a VectorIndex (or MultiVectorIndex) and adds metadata.\n\nKey Concepts - Two-Name System:\n    - VectorIndexDefinition.name: SHORT user-facing name (e.g., \"embedding\")\n      Used in feature URIs: mixpeek://text_extractor@v1/multilingual_e5_large_instruct_v1\n                                                        ^^^^^^^^^^\n\n    - VectorIndex.name: FULL storage name (e.g., \"text_extractor_v1_embedding\")\n      Used as the vector store collection name for namespace isolation\n\nThis two-level naming allows clean URIs while preventing storage collisions.\n\nUse Cases:\n    - Define extractor outputs in feature extractor definitions\n    - Expose available vector indexes in collection metadata\n    - Enable feature URI resolution (short name → full storage name)\n\nRequirements:\n    - name: REQUIRED - Short output name for feature URIs\n    - description: REQUIRED - Explain what this output produces\n    - type: REQUIRED - \"single\" (most common) or \"multi\" (rare)\n    - index: REQUIRED - Nested VectorIndex or MultiVectorIndex\n    - feature_uri: OPTIONAL - Populated at collection creation time","examples":[{"description":"Vector index for text embeddings using E5-Large model.","index":{"datatype":"float32","description":"Dense vector embedding for text content","dimensions":1024,"distance":"cosine","inference_name":"multilingual_e5_large_instruct_v1","name":"text_extractor_v1_embedding","supported_inputs":["text","string"],"type":"dense"},"name":"embedding","type":"single"},{"description":"Vector index for video segment embeddings using multimodal model.","index":{"datatype":"float32","description":"Dense vector embeddings for video segments","dimensions":1408,"distance":"cosine","inference_name":"vertex_multimodal_embedding","name":"multimodal_extractor_v1_video_embedding","supported_inputs":["video","image"],"type":"dense"},"name":"video_embedding","type":"single"},{"description":"Hybrid dense + sparse embeddings for enhanced retrieval.","index":{"description":"Combined dense and sparse embeddings","name":"hybrid_extractor_v1_multi","vectors":{"dense":{"description":"Dense semantic embedding","dimensions":1024,"distance":"cosine","inference_name":"multilingual_e5_large_instruct_v1","name":"hybrid_v1_dense","type":"dense"},"sparse":{"description":"Sparse keyword embedding","distance":"dot","inference_name":"splade_plus_plus_v1","name":"hybrid_v1_sparse","type":"sparse"}}},"name":"hybrid_embedding","type":"multi"}]},"VectorJoin":{"properties":{"array":{"type":"string","title":"Array","description":"Export path of the vector array (e.g. 'embeddings')."},"key":{"type":"string","title":"Key","description":"Field both the element and the vector row share (e.g. 'scene_index')."},"index":{"type":"string","title":"Index","description":"Target vector index name to store the decoded vector under."},"vector_field":{"type":"string","title":"Vector Field","description":"Field on the vector row holding the encoded vector.","default":"vector_b64"}},"type":"object","required":["array","key","index"],"title":"VectorJoin","description":"How a separate vector array aligns to the exploded elements."},"VectorMappingModel":{"properties":{"existing_index":{"type":"string","title":"Existing Index","description":"Name of existing vector index"},"inference_service":{"type":"string","title":"Inference Service","description":"Inference service to bind (e.g. 'openai_text_3_large')"}},"type":"object","required":["existing_index","inference_service"],"title":"VectorMappingModel"},"VectorPurpose":{"type":"string","enum":["text","code","image","multimodal","video","audio","sparse"],"title":"VectorPurpose","description":"Semantic purpose of a vector index.\n\nUsed by pipelines to look up vector configs by purpose without\nneeding to know the specific inference_service_id."},"VectorType":{"type":"string","enum":["dense","sparse","multi_dense"],"title":"VectorType","description":"Vector types supported by the Mixpeek system.\n\nDefines the storage format and structure of embeddings in the vector store.\n\nValues:\n    DENSE: Traditional float array embeddings (e.g., [0.1, 0.2, 0.3]).\n           Most common format. Used by: text_extractor, multimodal_extractor, image_extractor.\n           Storage: ~4KB per 1024-dim vector. Fast cosine/dot similarity search.\n\n    SPARSE: Index-value pairs for sparse embeddings (e.g., SPLADE, BM25).\n            Only stores non-zero dimensions. Format: {indices: [1,5,9], values: [0.8,0.6,0.4]}.\n            Storage: ~20KB. Keyword-based semantic search.\n\n    MULTI_DENSE: List of dense vectors for late interaction models (e.g., ColBERT).\n                 Each document has multiple embeddings. Format: [[0.1,0.2], [0.3,0.4], ...].\n                 Storage: ~500KB. High-precision retrieval.\n\nExamples:\n    - DENSE for general semantic search (text_extractor, multimodal_extractor)\n    - SPARSE for keyword expansion and explainability\n    - MULTI_DENSE for maximum precision retrieval"},"VectorUsageBreakdown":{"properties":{"backend":{"type":"string","title":"Backend","description":"Vector backend serving the tenant (mvs)","examples":["mvs"]},"vector_storage_usd":{"type":"number","title":"Vector Storage Usd","description":"Raw cost for vector storage"},"data_storage_usd":{"type":"number","title":"Data Storage Usd","description":"Raw cost for data storage (GCS/S3)"},"query_usd":{"type":"number","title":"Query Usd","description":"Raw cost for search queries"},"write_usd":{"type":"number","title":"Write Usd","description":"Raw cost for writes/upserts"},"total_usd":{"type":"number","title":"Total Usd","description":"Total cost after overhead and margin"},"total_credits":{"type":"integer","title":"Total Credits","description":"Total credits for vector backend usage"}},"type":"object","required":["backend","vector_storage_usd","data_storage_usd","query_usd","write_usd","total_usd","total_credits"],"title":"VectorUsageBreakdown","description":"Cost breakdown for vector backend usage."},"VerifyPasswordRequest":{"properties":{"password":{"type":"string","minLength":1,"title":"Password","description":"The password to verify against the retriever's password"}},"type":"object","required":["password"],"title":"VerifyPasswordRequest","description":"Request to verify password for a password-protected retriever."},"VerifyPasswordResponse":{"properties":{"valid":{"type":"boolean","title":"Valid","description":"Whether the provided password is valid"},"public_api_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Public Api Key","description":"DEPRECATED: API keys are no longer required. After password verification, call the execute endpoint directly."}},"type":"object","required":["valid"],"title":"VerifyPasswordResponse","description":"Response from password verification."},"VerifyUploadRequest":{"properties":{"bundle_s3_key":{"type":"string","title":"Bundle S3 Key","description":"S3 key returned by /deploy/upload-url — the object you just PUT to."}},"type":"object","required":["bundle_s3_key"],"title":"VerifyUploadRequest"},"VerifyUploadResponse":{"properties":{"bundle_s3_key":{"type":"string","title":"Bundle S3 Key","description":"S3 key that was verified"},"exists":{"type":"boolean","title":"Exists","description":"True if the object exists in S3"},"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag","description":"S3 ETag of the uploaded object (MD5 for single-part uploads)."},"size_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Size Bytes","description":"Size of the uploaded object in bytes."},"last_modified":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Modified","description":"Last-modified timestamp (ISO 8601)."}},"type":"object","required":["bundle_s3_key","exists"],"title":"VerifyUploadResponse","description":"Confirms a presigned-URL upload landed in S3.\n\nS3 presigned PUTs return an empty body — the ETag is only in response\nheaders, which many clients can't surface (CORS restrictions, browser\nDevTools gotchas). This endpoint does a server-side HEAD on the bundle\nand returns the object metadata so clients can verify their upload\nsucceeded."},"VersionDetailResponse":{"properties":{"version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Version"},"s3_version_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"S3 Version Id"},"asset_prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Asset Prefix"},"asset_manifest":{"anyOf":[{"additionalProperties":{"additionalProperties":true,"type":"object"},"type":"object"},{"type":"null"}],"title":"Asset Manifest"},"deployed_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Deployed By"},"deployed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Deployed At"},"environment":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Environment"},"build_duration_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Build Duration Ms"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message"},"source_files":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Source Files"},"git_commit_sha":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Commit Sha","description":"Git commit SHA"},"git_commit_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Commit Message","description":"Git commit message"},"git_author":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Author","description":"Git commit author"},"is_active":{"additionalProperties":{"type":"boolean"},"type":"object","title":"Is Active","description":"Which environments this version is currently deployed to"}},"type":"object","title":"VersionDetailResponse","description":"Full detail for a single version."},"VersionDiffResponse":{"properties":{"app_id":{"type":"string","title":"App Id"},"from_version":{"type":"integer","title":"From Version"},"to_version":{"type":"integer","title":"To Version"},"files":{"items":{"$ref":"#/components/schemas/FileDiff"},"type":"array","title":"Files"},"summary":{"additionalProperties":{"type":"integer"},"type":"object","title":"Summary","description":"Counts: added, removed, modified, unchanged"},"source_diff":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Source Diff","description":"Map of file path → unified diff string (only if both versions have source_files)"}},"type":"object","required":["app_id","from_version","to_version"],"title":"VersionDiffResponse","description":"Diff between two versions — file-level and optionally source-level."},"VersionListResponse":{"properties":{"versions":{"items":{},"type":"array","title":"Versions"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["versions","total"],"title":"VersionListResponse"},"VersionRecord":{"properties":{"version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Version"},"s3_version_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"S3 Version Id","description":"S3 object VersionId for instant rollback"},"asset_prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Asset Prefix","description":"S3 asset prefix for this version"},"asset_manifest":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Asset Manifest","description":"Map of relative path → {s3_key, hash, size}"},"asset_manifest_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Asset Manifest Url","description":"S3 URL of the asset manifest for this version"},"deployed_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Deployed By"},"deployed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Deployed At"},"environment":{"type":"string","title":"Environment","default":"production"},"build_duration_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Build Duration Ms"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message"},"source_files":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Source Files","description":"Map of relative path → file content for source-level version diffs"},"git_commit_sha":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Commit Sha","description":"Git commit SHA that triggered this deploy"},"git_commit_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Commit Message","description":"Git commit message"},"git_author":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Author","description":"Git commit author (name <email>)"}},"type":"object","title":"VersionRecord","description":"A single entry in the App version history."},"VideoResponse":{"properties":{"video_id":{"type":"string","title":"Video Id"},"organization_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Id"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"source_type":{"$ref":"#/components/schemas/SupportVideoSource"},"storage_uri":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Storage Uri"},"external_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Url"},"playback_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Playback Url"},"thumbnail_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Thumbnail Url"},"duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Seconds"},"mime_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mime Type"},"chapters":{"items":{"$ref":"#/components/schemas/SupportVideoChapter"},"type":"array","title":"Chapters"},"analysis_status":{"$ref":"#/components/schemas/SupportVideoAnalysisStatus","default":"pending"},"analysis_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Analysis Error"},"created_by":{"anyOf":[{"$ref":"#/components/schemas/SupportActor"},{"type":"null"}]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["video_id","title","source_type"],"title":"VideoResponse"},"VideoUploadUrlRequest":{"properties":{"filename":{"type":"string","title":"Filename"},"mime_type":{"type":"string","title":"Mime Type","default":"video/mp4"},"organization_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Id"}},"type":"object","required":["filename"],"title":"VideoUploadUrlRequest"},"VideoUploadUrlResponse":{"properties":{"upload_url":{"type":"string","title":"Upload Url"},"storage_uri":{"type":"string","title":"Storage Uri"},"resource_id":{"type":"string","title":"Resource Id"},"expires_in":{"type":"integer","title":"Expires In"}},"type":"object","required":["upload_url","storage_uri","resource_id","expires_in"],"title":"VideoUploadUrlResponse"},"VisibilityReason":{"properties":{"searchable":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Searchable","description":"True when the source object's vectors are present in MVS (the document is retrievable), False when confirmed absent (the unsearchable class), None when it could not be determined."},"reason":{"type":"string","title":"Reason","description":"Human-readable explanation of the searchable verdict."},"source_object_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Object Id","description":"The _internal.lineage.source_object_id the presence check was keyed on. None when the document carries no such id to check."}},"type":"object","required":["reason"],"title":"VisibilityReason","description":"Whether this document's vectors are present in MVS, and why."},"VitalsSummary":{"properties":{"metric_name":{"type":"string","title":"Metric Name"},"p50":{"type":"number","title":"P50"},"p75":{"type":"number","title":"P75"},"p95":{"type":"number","title":"P95"},"sample_count":{"type":"integer","title":"Sample Count"}},"type":"object","required":["metric_name","p50","p75","p95","sample_count"],"title":"VitalsSummary"},"WebScraperExtractorParams":{"properties":{"extractor_type":{"type":"string","const":"web_scraper","title":"Extractor Type","description":"Discriminator field for parameter type identification.","default":"web_scraper"},"max_depth":{"type":"integer","maximum":10.0,"minimum":0.0,"title":"Max Depth","description":"Maximum link depth to crawl. 0=seed page only, 1=seed+direct links, etc. Default: 2. Max: 10.","default":2},"max_pages":{"type":"integer","maximum":500.0,"minimum":1.0,"title":"Max Pages","description":"Maximum pages to crawl. Default: 50. Max: 500.","default":50},"crawl_timeout":{"type":"integer","maximum":3600.0,"minimum":10.0,"title":"Crawl Timeout","description":"Maximum total time for crawling in seconds. Default: 300 (5 minutes). Increase for large sites with many pages. Max: 3600 (1 hour).","default":300},"crawl_mode":{"$ref":"#/components/schemas/CrawlMode","description":"Crawl strategy. DETERMINISTIC: BFS all links (predictable). SEMANTIC: LLM-guided, prioritizes relevant pages (requires crawl_goal).","default":"deterministic"},"crawl_goal":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Crawl Goal","description":"Goal for semantic crawling. Only used when crawl_mode=SEMANTIC. Example: 'Find all S3 API documentation and examples'"},"render_strategy":{"$ref":"#/components/schemas/RenderStrategy","description":"How to render pages. AUTO (default): tries static, falls back to JS. STATIC: fast HTTP fetch. JAVASCRIPT: Playwright browser for SPAs.","default":"auto"},"include_patterns":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Include Patterns","description":"Regex patterns for URLs to include. Example: ['/docs/', '/api/']"},"exclude_patterns":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Exclude Patterns","description":"Regex patterns for URLs to exclude. Example: ['/blog/', '\\.pdf$']"},"chunk_strategy":{"$ref":"#/components/schemas/ChunkStrategy","description":"How to split page content. NONE: one chunk per page. SENTENCES/PARAGRAPHS: semantic boundaries. WORDS/CHARACTERS: fixed size chunks.","default":"none"},"chunk_size":{"type":"integer","maximum":10000.0,"minimum":1.0,"title":"Chunk Size","description":"Target size for each chunk (in units of chunk_strategy).","default":500},"chunk_overlap":{"type":"integer","maximum":5000.0,"minimum":0.0,"title":"Chunk Overlap","description":"Overlap between chunks to preserve context.","default":50},"document_id_strategy":{"$ref":"#/components/schemas/DocumentIdStrategy","description":"How to generate document IDs. URL (default): stable across re-crawls. POSITION: order-based. CONTENT: deduplicates identical content.","default":"url"},"generate_text_embeddings":{"type":"boolean","title":"Generate Text Embeddings","description":"Generate E5 embeddings for text content.","default":true},"generate_code_embeddings":{"type":"boolean","title":"Generate Code Embeddings","description":"Generate Jina code embeddings for code blocks.","default":true},"generate_image_embeddings":{"type":"boolean","title":"Generate Image Embeddings","description":"Generate SigLIP embeddings for images/figures.","default":true},"generate_structure_embeddings":{"type":"boolean","title":"Generate Structure Embeddings","description":"Generate DINOv2 visual structure embeddings for layout comparison.","default":true},"response_shape":{"anyOf":[{"type":"string"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Response Shape","description":"Optional structured extraction schema. Natural language or JSON schema. Example: 'Extract API version, deprecated methods, and example code'"},"llm_provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Llm Provider","description":"LLM provider for structured extraction: openai, google, anthropic"},"llm_model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Llm Model","description":"LLM model for structured extraction."},"llm_api_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Llm Api Key","description":"API key for LLM operations (BYOK - Bring Your Own Key). Supports:\n- Direct key: 'sk-proj-abc123...'\n- Secret reference: '{{SECRET.openai_api_key}}'\n\nWhen using secret reference, the key is loaded from your organization's secrets vault at runtime. Store secrets via POST /v1/organizations/secrets.\n\nIf not provided, uses Mixpeek's default API keys."},"max_retries":{"type":"integer","maximum":10.0,"minimum":0.0,"title":"Max Retries","description":"Maximum retry attempts for failed HTTP requests. Uses exponential backoff with jitter. Default: 3.","default":3},"retry_base_delay":{"type":"number","maximum":30.0,"minimum":0.1,"title":"Retry Base Delay","description":"Base delay in seconds for retry backoff. Actual delay = base * 2^attempt + jitter. Default: 1.0.","default":1.0},"retry_max_delay":{"type":"number","maximum":300.0,"minimum":1.0,"title":"Retry Max Delay","description":"Maximum delay in seconds between retries. Default: 30.","default":30.0},"respect_retry_after":{"type":"boolean","title":"Respect Retry After","description":"Respect Retry-After header from 429/503 responses. If False, uses exponential backoff instead. Default: True.","default":true},"proxies":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Proxies","description":"List of proxy URLs for rotation. Supports formats: 'http://host:port', 'http://user:pass@host:port', 'socks5://host:port'. Proxies rotate on errors or every N requests."},"rotate_proxy_on_error":{"type":"boolean","title":"Rotate Proxy On Error","description":"Rotate to next proxy when request fails. Default: True.","default":true},"rotate_proxy_every_n_requests":{"type":"integer","maximum":1000.0,"minimum":0.0,"title":"Rotate Proxy Every N Requests","description":"Rotate proxy every N requests (0 = disabled). Useful for avoiding IP-based rate limits. Default: 0 (disabled).","default":0},"captcha_service_provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Captcha Service Provider","description":"Captcha solving service provider: '2captcha', 'anti-captcha', 'capsolver'. If not set, captcha pages are skipped gracefully."},"captcha_service_api_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Captcha Service Api Key","description":"API key for captcha solving service. Supports secret reference: '{{SECRET.captcha_api_key}}'. Required if captcha_service_provider is set."},"detect_captcha":{"type":"boolean","title":"Detect Captcha","description":"Detect captcha challenges (Cloudflare, reCAPTCHA, hCaptcha). If detected and no solver configured, page is skipped. Default: True.","default":true},"persist_cookies":{"type":"boolean","title":"Persist Cookies","description":"Persist cookies across requests within a crawl session. Useful for sites requiring authentication. Default: True.","default":true},"custom_headers":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Custom Headers","description":"Custom HTTP headers to include in all requests. Example: {'Authorization': 'Bearer token', 'X-Custom': 'value'}"},"youtube_mode":{"type":"string","enum":["auto","off","force"],"title":"Youtube Mode","description":"YouTube channel fast path. 'auto' (default): detect YouTube channel URLs and hand off to yt-dlp; other URLs run normal BFS. 'off': never hand off. 'force': treat every URL as a YouTube channel (useful for explicit channel buckets).","default":"auto"},"youtube_max_videos":{"type":"integer","maximum":5000.0,"minimum":1.0,"title":"Youtube Max Videos","description":"Max videos to pull per channel enumeration. Default: 50.","default":50},"youtube_backfill_months":{"type":"integer","maximum":60.0,"minimum":1.0,"title":"Youtube Backfill Months","description":"Skip videos older than this many months. Default: 6.","default":6},"youtube_show_filter":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Youtube Show Filter","description":"Optional case-insensitive regex applied to video titles. Used when a channel hosts multiple shows and you only want one."},"youtube_download_videos":{"type":"boolean","title":"Youtube Download Videos","description":"If true (default), download each video file so downstream processors can read it from the `video_path` field. If false, only metadata + captions are emitted.","default":true},"youtube_format_ladder":{"type":"string","title":"Youtube Format Ladder","description":"yt-dlp format selector. Defaults to a muxed-first ladder that avoids breaking on YouTube's DASH n-challenge when the current EJS signature solver is stale. See BUILD_LOG.md in the greenroom folder for the rationale.","default":"b[height<=720]/bv*[height<=720]+ba/best"},"youtube_cookies_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Youtube Cookies Path","description":"Optional path to a Netscape cookies file. Required for age-gated or members-only content."},"youtube_request_sleep":{"type":"number","maximum":30.0,"minimum":0.0,"title":"Youtube Request Sleep","description":"Seconds to sleep between yt-dlp requests. Default: 1.0.","default":1.0},"delay_between_requests":{"type":"number","maximum":60.0,"minimum":0.0,"title":"Delay Between Requests","description":"Delay in seconds between consecutive requests. Useful for polite crawling and avoiding rate limits. Default: 0 (no delay).","default":0.0}},"type":"object","title":"WebScraperExtractorParams","description":"Parameters for the web scraper extractor.\n\nThe web scraper extractor crawls websites and extracts content with three types\nof embeddings for comprehensive multimodal search:\n\n**Embedding Types:**\n- Text (E5-Large): 1024D embeddings for page content\n- Code (Jina Code): 768D embeddings for code blocks\n- Images (SigLIP): 768D semantic embeddings for figures/screenshots\n- Images (DINOv2): 768D structure embeddings for visual layout comparison\n\n**Crawl Modes:**\n- DETERMINISTIC: BFS following all links (default, predictable)\n- SEMANTIC: LLM-guided, prioritizes pages matching crawl_goal\n\n**Rendering Strategies:**\n- AUTO: Tries static, falls back to JS if content too short (default)\n- STATIC: Fast HTTP fetch, works for most sites\n- JAVASCRIPT: Playwright browser for SPAs (React/Vue/Angular)\n\n**Use Cases:**\n- Documentation freshness: Crawl docs, compare against course content\n- Job board ingestion: Extract job listings with structured data\n- Knowledge base building: Convert websites to searchable collections\n- Code example indexing: Find API usage patterns across docs","examples":[{"chunk_size":3,"chunk_strategy":"paragraphs","description":"Documentation site crawl","extractor_type":"web_scraper","max_depth":3,"max_pages":100},{"description":"Job board extraction","extractor_type":"web_scraper","max_depth":1,"max_pages":50,"render_strategy":"auto","response_shape":"Extract job title, department, location, and requirements"},{"crawl_goal":"Find all S3 upload examples and API documentation","crawl_mode":"semantic","description":"Semantic crawl for API docs","extractor_type":"web_scraper","generate_code_embeddings":true,"max_pages":200},{"delay_between_requests":0.5,"description":"Large-scale catalogue with resilience","extractor_type":"web_scraper","max_depth":5,"max_pages":10000,"max_retries":5,"respect_retry_after":true},{"description":"Protected site with proxy rotation","extractor_type":"web_scraper","max_pages":5000,"persist_cookies":true,"proxies":["http://proxy1.example.com:8080","http://proxy2.example.com:8080"],"rotate_proxy_every_n_requests":50,"rotate_proxy_on_error":true}]},"Webhook-Input":{"properties":{"webhook_id":{"type":"string","pattern":"^wh_[a-fA-F0-9]{16}$","title":"Webhook Id","description":"Unique identifier for the webhook. Auto-generated with 'wh_' prefix followed by secure random token. Format: wh_{16-character hex}. Used for API operations and event tracking.","examples":["wh_abc123def4567890","wh_1234567890abcdef"]},"webhook_name":{"type":"string","maxLength":200,"minLength":1,"title":"Webhook Name","description":"REQUIRED. Human-readable name for the webhook. Displayed in dashboards, logs, and notification metadata. Should describe the webhook's purpose or destination. Format: 1-200 characters.","examples":["Slack Engineering Alerts","External System Integration","Audit Trail Logger","Production Monitoring"]},"internal_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Internal Id","description":"Organization internal identifier for multi-tenancy scoping. All webhook operations are scoped to this organization. Excluded from API responses for security. Format: int_{24-character secure token}."},"event_types":{"items":{"$ref":"#/components/schemas/WebhookEventType"},"type":"array","minItems":1,"title":"Event Types","description":"REQUIRED. List of event types that trigger this webhook. When any of these events occur, notifications are sent to all channels. Must contain at least one event type. Common patterns: - ['object.created', 'object.updated'] for object lifecycle tracking - ['cluster.execution.completed', 'cluster.execution.failed'] for job monitoring - ['*'] for all events (use cautiously, high volume)","examples":[["object.created","object.updated","object.deleted"],["cluster.execution.completed","cluster.execution.failed"],["collection.documents.written"]]},"resource_types":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Resource Types","description":"OPTIONAL. Deliver only events whose resource_type is one of these, for example ['retriever', 'taxonomy']. Applies to every event type: for resource.executed and resource.execution_failed the resource_type is the primitive that ran (it travels in the payload); for the per-kind types it is the first segment of the event type. Omitted or empty: no resource_type filter.","examples":[["retriever"],["taxonomy","cluster"]]},"channels":{"items":{"$ref":"#/components/schemas/WebhookChannel-Input"},"type":"array","minItems":1,"title":"Channels","description":"REQUIRED. List of notification channels for event delivery. When an event occurs, notifications are sent to ALL configured channels. Must contain at least one channel. Multiple channels provide redundancy and multi-audience delivery. Example: Send to both Slack (team) and email (manager) for critical events."},"is_active":{"type":"boolean","title":"Is Active","description":"Whether the webhook is currently active and should send notifications. True: Events trigger notifications to channels. False: Webhook is paused, no notifications sent but config preserved. Use to temporarily disable webhooks without losing configuration. Default: True","default":true},"delivery_health":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Delivery Health","description":"Read-only delivery state written by the dispatcher: consecutive_failures, first_failure_at, last_failure_at and last_failure_cause for the current run of failed deliveries, and paused_at and paused_reason when the run paused the webhook (is_active false). Re-enable with an update setting is_active true, which clears it."},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"UTC timestamp when the webhook was created. Auto-generated at creation time. Immutable after creation. Format: ISO 8601 datetime."},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"UTC timestamp of the most recent webhook update. Updated automatically when event_types, channels, or is_active changes. Tracks configuration modifications. Format: ISO 8601 datetime."}},"type":"object","required":["webhook_name","event_types","channels"],"title":"Webhook","description":"Configured webhook subscription for organization event notifications.\n\nWebhooks enable real-time notifications when events occur in the system.\nEach webhook subscribes to specific event types and delivers notifications\nvia one or more configured channels (Slack, email, HTTP).\n\nWebhook Lifecycle:\n    1. Created with event_types and channels configured\n    2. is_active=True enables notification delivery\n    3. Events matching event_types trigger notifications to all channels\n    4. is_active=False temporarily pauses notifications without deletion\n    5. Webhook can be updated to add/remove event types or channels\n    6. Permanent deletion removes the webhook configuration\n\nUse Cases:\n    - Integrate Mixpeek events with external systems via HTTP webhooks\n    - Notify teams in Slack when ingestion jobs complete\n    - Send email alerts when critical failures occur\n    - Trigger automated workflows based on state changes\n    - Maintain audit trails by forwarding events to SIEM systems\n\nBest Practices:\n    - Subscribe only to events you need (reduces noise)\n    - Use descriptive webhook_name for identification\n    - Configure multiple channels for critical events (redundancy)\n    - Set is_active=False to temporarily disable without losing config\n    - Monitor webhook delivery failures via last_error tracking","examples":[{"channels":[{"channel":"slack","configs":{"channel":"#alerts","webhook_url":"https://hooks.slack.com/services/T000/B000/XXXX"}}],"created_at":"2025-01-01T00:00:00Z","description":"Slack notifications for object lifecycle","event_types":["object.created","object.updated","object.deleted"],"is_active":true,"updated_at":"2025-01-01T00:00:00Z","webhook_id":"wh_abc123def4567890","webhook_name":"Engineering Slack Alerts"},{"channels":[{"channel":"slack","configs":{"channel":"#alerts","webhook_url":"https://hooks.slack.com/services/T000/B000/XXXX"}},{"channel":"email","configs":{"subject_template":"CRITICAL: {event_type}","to_addresses":["oncall@example.com"]}}],"created_at":"2025-01-01T00:00:00Z","description":"Multi-channel alerts for cluster failures","event_types":["cluster.execution.failed","trigger.execution.failed"],"is_active":true,"updated_at":"2025-01-15T10:30:00Z","webhook_id":"wh_a1b2c3d4e5f60789","webhook_name":"Production Monitoring"},{"channels":[{"channel":"webhook","configs":{"headers":{"Authorization":"Bearer secret123"},"url":"https://siem.company.com/webhooks/mixpeek"}}],"created_at":"2025-01-01T00:00:00Z","description":"External system integration via HTTP webhook","event_types":["object.created","object.updated","object.deleted","collection.created","collection.deleted"],"is_active":true,"updated_at":"2025-01-01T00:00:00Z","webhook_id":"wh_0123456789abcdef","webhook_name":"SIEM Audit Trail"}]},"Webhook-Output":{"properties":{"webhook_id":{"type":"string","pattern":"^wh_[a-fA-F0-9]{16}$","title":"Webhook Id","description":"Unique identifier for the webhook. Auto-generated with 'wh_' prefix followed by secure random token. Format: wh_{16-character hex}. Used for API operations and event tracking.","examples":["wh_abc123def4567890","wh_1234567890abcdef"]},"webhook_name":{"type":"string","maxLength":200,"minLength":1,"title":"Webhook Name","description":"REQUIRED. Human-readable name for the webhook. Displayed in dashboards, logs, and notification metadata. Should describe the webhook's purpose or destination. Format: 1-200 characters.","examples":["Slack Engineering Alerts","External System Integration","Audit Trail Logger","Production Monitoring"]},"event_types":{"items":{"$ref":"#/components/schemas/WebhookEventType"},"type":"array","minItems":1,"title":"Event Types","description":"REQUIRED. List of event types that trigger this webhook. When any of these events occur, notifications are sent to all channels. Must contain at least one event type. Common patterns: - ['object.created', 'object.updated'] for object lifecycle tracking - ['cluster.execution.completed', 'cluster.execution.failed'] for job monitoring - ['*'] for all events (use cautiously, high volume)","examples":[["object.created","object.updated","object.deleted"],["cluster.execution.completed","cluster.execution.failed"],["collection.documents.written"]]},"resource_types":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Resource Types","description":"OPTIONAL. Deliver only events whose resource_type is one of these, for example ['retriever', 'taxonomy']. Applies to every event type: for resource.executed and resource.execution_failed the resource_type is the primitive that ran (it travels in the payload); for the per-kind types it is the first segment of the event type. Omitted or empty: no resource_type filter.","examples":[["retriever"],["taxonomy","cluster"]]},"channels":{"items":{"$ref":"#/components/schemas/WebhookChannel-Output"},"type":"array","minItems":1,"title":"Channels","description":"REQUIRED. List of notification channels for event delivery. When an event occurs, notifications are sent to ALL configured channels. Must contain at least one channel. Multiple channels provide redundancy and multi-audience delivery. Example: Send to both Slack (team) and email (manager) for critical events."},"is_active":{"type":"boolean","title":"Is Active","description":"Whether the webhook is currently active and should send notifications. True: Events trigger notifications to channels. False: Webhook is paused, no notifications sent but config preserved. Use to temporarily disable webhooks without losing configuration. Default: True","default":true},"delivery_health":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Delivery Health","description":"Read-only delivery state written by the dispatcher: consecutive_failures, first_failure_at, last_failure_at and last_failure_cause for the current run of failed deliveries, and paused_at and paused_reason when the run paused the webhook (is_active false). Re-enable with an update setting is_active true, which clears it."},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"UTC timestamp when the webhook was created. Auto-generated at creation time. Immutable after creation. Format: ISO 8601 datetime."},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"UTC timestamp of the most recent webhook update. Updated automatically when event_types, channels, or is_active changes. Tracks configuration modifications. Format: ISO 8601 datetime."}},"type":"object","required":["webhook_name","event_types","channels"],"title":"Webhook","description":"Configured webhook subscription for organization event notifications.\n\nWebhooks enable real-time notifications when events occur in the system.\nEach webhook subscribes to specific event types and delivers notifications\nvia one or more configured channels (Slack, email, HTTP).\n\nWebhook Lifecycle:\n    1. Created with event_types and channels configured\n    2. is_active=True enables notification delivery\n    3. Events matching event_types trigger notifications to all channels\n    4. is_active=False temporarily pauses notifications without deletion\n    5. Webhook can be updated to add/remove event types or channels\n    6. Permanent deletion removes the webhook configuration\n\nUse Cases:\n    - Integrate Mixpeek events with external systems via HTTP webhooks\n    - Notify teams in Slack when ingestion jobs complete\n    - Send email alerts when critical failures occur\n    - Trigger automated workflows based on state changes\n    - Maintain audit trails by forwarding events to SIEM systems\n\nBest Practices:\n    - Subscribe only to events you need (reduces noise)\n    - Use descriptive webhook_name for identification\n    - Configure multiple channels for critical events (redundancy)\n    - Set is_active=False to temporarily disable without losing config\n    - Monitor webhook delivery failures via last_error tracking","examples":[{"channels":[{"channel":"slack","configs":{"channel":"#alerts","webhook_url":"https://hooks.slack.com/services/T000/B000/XXXX"}}],"created_at":"2025-01-01T00:00:00Z","description":"Slack notifications for object lifecycle","event_types":["object.created","object.updated","object.deleted"],"is_active":true,"updated_at":"2025-01-01T00:00:00Z","webhook_id":"wh_abc123def4567890","webhook_name":"Engineering Slack Alerts"},{"channels":[{"channel":"slack","configs":{"channel":"#alerts","webhook_url":"https://hooks.slack.com/services/T000/B000/XXXX"}},{"channel":"email","configs":{"subject_template":"CRITICAL: {event_type}","to_addresses":["oncall@example.com"]}}],"created_at":"2025-01-01T00:00:00Z","description":"Multi-channel alerts for cluster failures","event_types":["cluster.execution.failed","trigger.execution.failed"],"is_active":true,"updated_at":"2025-01-15T10:30:00Z","webhook_id":"wh_a1b2c3d4e5f60789","webhook_name":"Production Monitoring"},{"channels":[{"channel":"webhook","configs":{"headers":{"Authorization":"Bearer secret123"},"url":"https://siem.company.com/webhooks/mixpeek"}}],"created_at":"2025-01-01T00:00:00Z","description":"External system integration via HTTP webhook","event_types":["object.created","object.updated","object.deleted","collection.created","collection.deleted"],"is_active":true,"updated_at":"2025-01-01T00:00:00Z","webhook_id":"wh_0123456789abcdef","webhook_name":"SIEM Audit Trail"}]},"WebhookChannel-Input":{"properties":{"channel":{"$ref":"#/components/schemas/NotificationChannel","description":"REQUIRED. The notification channel type for delivery. Determines which delivery mechanism is used (email, Slack, webhook). Must match the type of the configs field."},"configs":{"anyOf":[{"$ref":"#/components/schemas/EmailConfig-Input"},{"$ref":"#/components/schemas/SlackConfig"},{"$ref":"#/components/schemas/WebhookConfig"}],"title":"Configs","description":"REQUIRED. Channel-specific configuration for notification delivery. Type depends on the channel field: - EmailConfig for EMAIL channel (recipients, subject template, etc.) - SlackConfig for SLACK channel (incoming webhook URL, optional channel and username) - WebhookConfig for WEBHOOK channel (URL, headers, auth). See respective config models for detailed field requirements."}},"type":"object","required":["channel","configs"],"title":"WebhookChannel","description":"Notification channel configuration for webhook delivery.\n\nDefines how and where webhook event notifications should be delivered.\nEach webhook can have multiple channels configured for redundancy or\ndifferent notification audiences.\n\nSupported Channels:\n    - EMAIL: Send notifications via email to specified recipients\n    - SLACK: Post messages to Slack channels or direct messages\n    - WEBHOOK: HTTP POST to external endpoints (standard webhooks)\n\nUse Cases:\n    - Route critical alerts to Slack and email simultaneously\n    - Send audit trail events to external webhook endpoints\n    - Notify team members via email for object lifecycle events\n    - Post cluster completion status to Slack channels\n\nRequirements:\n    - Channel type must match the config type (discriminated union)\n    - Each config must have valid credentials/endpoints configured\n    - Channel configs are validated at webhook creation time","examples":[{"channel":"slack","configs":{"channel":"#alerts","webhook_url":"https://hooks.slack.com/services/T000/B000/XXXX"},"description":"Slack notification channel"},{"channel":"email","configs":{"subject_template":"Mixpeek Alert: {event_type}","to_addresses":["team@example.com","admin@example.com"]},"description":"Email notification channel"},{"channel":"webhook","configs":{"headers":{"Authorization":"Bearer token123"},"url":"https://api.example.com/webhooks/mixpeek"},"description":"HTTP webhook channel"}]},"WebhookChannel-Output":{"properties":{"channel":{"$ref":"#/components/schemas/NotificationChannel","description":"REQUIRED. The notification channel type for delivery. Determines which delivery mechanism is used (email, Slack, webhook). Must match the type of the configs field."},"configs":{"anyOf":[{"$ref":"#/components/schemas/shared__notifications__vendors__email__models__EmailConfig"},{"$ref":"#/components/schemas/SlackConfig"},{"$ref":"#/components/schemas/WebhookConfig"}],"title":"Configs","description":"REQUIRED. Channel-specific configuration for notification delivery. Type depends on the channel field: - EmailConfig for EMAIL channel (recipients, subject template, etc.) - SlackConfig for SLACK channel (incoming webhook URL, optional channel and username) - WebhookConfig for WEBHOOK channel (URL, headers, auth). See respective config models for detailed field requirements."}},"type":"object","required":["channel","configs"],"title":"WebhookChannel","description":"Notification channel configuration for webhook delivery.\n\nDefines how and where webhook event notifications should be delivered.\nEach webhook can have multiple channels configured for redundancy or\ndifferent notification audiences.\n\nSupported Channels:\n    - EMAIL: Send notifications via email to specified recipients\n    - SLACK: Post messages to Slack channels or direct messages\n    - WEBHOOK: HTTP POST to external endpoints (standard webhooks)\n\nUse Cases:\n    - Route critical alerts to Slack and email simultaneously\n    - Send audit trail events to external webhook endpoints\n    - Notify team members via email for object lifecycle events\n    - Post cluster completion status to Slack channels\n\nRequirements:\n    - Channel type must match the config type (discriminated union)\n    - Each config must have valid credentials/endpoints configured\n    - Channel configs are validated at webhook creation time","examples":[{"channel":"slack","configs":{"channel":"#alerts","webhook_url":"https://hooks.slack.com/services/T000/B000/XXXX"},"description":"Slack notification channel"},{"channel":"email","configs":{"subject_template":"Mixpeek Alert: {event_type}","to_addresses":["team@example.com","admin@example.com"]},"description":"Email notification channel"},{"channel":"webhook","configs":{"headers":{"Authorization":"Bearer token123"},"url":"https://api.example.com/webhooks/mixpeek"},"description":"HTTP webhook channel"}]},"WebhookConfig":{"properties":{"url":{"type":"string","title":"Url","description":"The URL to which the webhook will be sent."},"headers":{"additionalProperties":{"type":"string"},"type":"object","title":"Headers","description":"Custom headers to include in the webhook request."},"payload_template":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Payload Template","description":"A Jinja2 template for the JSON payload."},"timeout":{"type":"number","title":"Timeout","description":"Request timeout in seconds.","default":10.0},"signing_secret":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Signing Secret","description":"NOT REQUIRED. A secret shared with the receiver. When set, every delivery carries X-Mixpeek-Signature: t=<unix seconds>,v1=<hex HMAC-SHA256 of '<t>.' plus the raw request body, keyed by this secret>. The receiver recomputes it to verify the delivery came from Mixpeek and rejects an old t to stop replays. Stored encrypted and never returned: reads show 'redacted'. Send 'redacted' (or omit the field) on an update to keep it, or an empty string to remove it."}},"type":"object","required":["url"],"title":"WebhookConfig","description":"Configuration for webhook notifications."},"WebhookEventType":{"type":"string","enum":["object.created","objects.created.batch","object.updated","object.deleted","document.created","document.updated","document.deleted","documents.updated.batch","documents.deleted.batch","collection.created","collection.updated","collection.deleted","collection.documents.written","collection.documents.batch_completed","cluster.created","cluster.updated","cluster.deleted","cluster.execution.started","cluster.execution.completed","cluster.execution.failed","trigger.created","trigger.updated","trigger.deleted","trigger.paused","trigger.resumed","trigger.fired","trigger.execution.completed","trigger.execution.failed","taxonomy.created","taxonomy.updated","taxonomy.deleted","alert.created","alert.updated","alert.deleted","alert.triggered","alert.execution.completed","alert.execution.failed","annotation.created","annotation.updated","annotation.deleted","resource.executed","resource.execution_failed","manifest.apply.resource_state"],"title":"WebhookEventType","description":"Webhook event types for real-time notifications.\n\nThese events are emitted when significant state changes occur in the system.\nWebhooks subscribe to specific event types and receive notifications via\nconfigured channels (email, Slack, HTTP webhooks).\n\nEvent Naming Convention:\n    {resource}.{action}[.{sub-resource}[.{sub-action}]]\n\nExamples:\n    - object.created: New object ingested\n    - collection.documents.written: Documents indexed\n    - cluster.execution.completed: Cluster job finished\n\nCache Invalidation Annotations:\n    Each event type includes a comment indicating recommended cache invalidation scope:\n    - [KEY] = Invalidate specific document/object keys\n    - [COLLECTION] = Invalidate collection-level cache\n    - [NAMESPACE] = Invalidate namespace-level cache\n\nEvent Categories:\n    - Object Lifecycle: Events for individual objects (create, update, delete)\n    - Collection Lifecycle: Events for collections (create, update, delete, documents written)\n    - Cluster Lifecycle: Events for clusters (create, update, delete, execution status)\n    - Trigger Lifecycle: Events for cluster triggers (create, update, fire, execution status)\n    - Taxonomy Lifecycle: Events for taxonomies (create, update, delete)\n\nUse Cases:\n    - Real-time sync with external systems\n    - Audit trail and compliance logging\n    - Automated workflows triggered by state changes\n    - Cache invalidation for distributed systems\n    - Notifications to team members via Slack/email"},"WeightLearningConfig":{"properties":{"method":{"type":"string","enum":["grid_search","bayesian"],"title":"Method","description":"Weight learning method:\n- bayesian: Gaussian process optimization (recommended, scales to 5+ features)\n- grid_search: Exhaustive search (limited to 2-3 features, simpler but slower)","default":"bayesian","examples":["bayesian","grid_search"]},"max_iterations":{"type":"integer","maximum":100.0,"minimum":5.0,"title":"Max Iterations","description":"Maximum optimization iterations:\n- grid_search: Number of values to try per feature (total: max_iterations^n_features)\n- bayesian: Number of weight combinations to evaluate\nRecommended: 20 for bayesian, 5 for grid_search","default":20,"examples":[20,50]},"metric":{"type":"string","enum":["silhouette","davies_bouldin","calinski_harabasz"],"title":"Metric","description":"Clustering quality metric to optimize:\n- silhouette: Measures how similar points are to their cluster vs other clusters (range: [-1, 1], higher is better)\n- davies_bouldin: Ratio of within-cluster to between-cluster distances (range: [0, ∞], lower is better)\n- calinski_harabasz: Ratio of between-cluster to within-cluster variance (range: [0, ∞], higher is better)\nRecommended: silhouette (most general-purpose)","default":"silhouette","examples":["silhouette","davies_bouldin","calinski_harabasz"]},"sample_size":{"anyOf":[{"type":"integer","minimum":100.0},{"type":"null"}],"title":"Sample Size","description":"Optional: Learn weights on a random sample (speeds up large datasets).\nIf provided and dataset has more documents, weights are learned on sample_size random documents, then applied to full dataset.\nRecommended: 5000 for datasets >10k documents","examples":[5000,10000]},"random_state":{"type":"integer","title":"Random State","description":"Random seed for reproducibility of weight learning","default":42,"examples":[42]}},"type":"object","title":"WeightLearningConfig","description":"Configuration for automatic feature weight learning in multi-feature clustering.\n\nWhen multi_feature_strategy='weighted' and feature_weights is not provided,\nthis configuration controls how optimal weights are automatically learned.\n\nThe system tries different weight combinations and picks the one that\nproduces the best clustering quality (measured by silhouette score, etc.).\n\nExamples:\n    Bayesian optimization (recommended):\n    {\n        \"method\": \"bayesian\",\n        \"max_iterations\": 20,\n        \"metric\": \"silhouette\",\n        \"sample_size\": 5000\n    }\n\n    Grid search (exhaustive, limited to 2-3 features):\n    {\n        \"method\": \"grid_search\",\n        \"max_iterations\": 5,\n        \"metric\": \"silhouette\"\n    }","examples":[{"max_iterations":20,"method":"bayesian","metric":"silhouette","random_state":42,"sample_size":5000},{"max_iterations":5,"method":"grid_search","metric":"silhouette","random_state":42}]},"WhiteningParams":{"properties":{"method":{"type":"string","const":"whitening","title":"Method","default":"whitening"},"regularization":{"type":"number","minimum":0.0,"title":"Regularization","description":"Eigenvalue floor to prevent division by near-zero values.","default":1e-05}},"type":"object","title":"WhiteningParams"},"WorkloadIdentityProvider":{"properties":{"name":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9][A-Za-z0-9_.-]*$","title":"Name","description":"Unique name within the organization, e.g. 'vercel-prod'."},"issuer":{"type":"string","minLength":1,"title":"Issuer","description":"Exact value of the token's 'iss' claim. Vercel: 'https://oidc.vercel.com/<team_slug>' (team issuer mode) or 'https://oidc.vercel.com' (global mode). GitHub Actions: 'https://token.actions.githubusercontent.com'."},"jwks_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Jwks Url","description":"URL of the issuer's JSON Web Key Set. When omitted, Mixpeek reads 'jwks_uri' from the issuer's '/.well-known/openid-configuration'."},"audience":{"items":{"type":"string"},"type":"array","minItems":1,"title":"Audience","description":"Accepted values of the token's 'aud' claim. Vercel's default is 'https://vercel.com/<team_slug>'; for GitHub Actions use the audience you request with core.getIDToken(audience)."},"algorithms":{"items":{"type":"string","enum":["RS256","RS384","RS512","ES256","ES384","PS256"]},"type":"array","minItems":1,"title":"Algorithms","description":"Signature algorithms accepted. Only asymmetric algorithms."},"claim_conditions":{"additionalProperties":{"items":{"type":"string"},"type":"array"},"type":"object","minProperties":1,"title":"Claim Conditions","description":"Claims the token must carry, each mapped to its allowed values. Every listed claim must match one of its values. A value ending in '*' matches by prefix, e.g. 'repo:acme/api:*'. At least one claim other than iss, aud, exp, iat, nbf and jti is required, so a provider never trusts every workload an issuer signs for.","examples":[{"environment":["production"],"project_id":["prj_123"]},{"ref":["refs/heads/main"],"repository":["acme/api"]}]},"permissions":{"items":{"$ref":"#/components/schemas/Permission"},"type":"array","minItems":1,"title":"Permissions","description":"Permissions of the keys this provider mints: read, write and delete. Admin is not available through workload identity."},"token_ttl_seconds":{"type":"integer","maximum":3600.0,"minimum":300.0,"title":"Token Ttl Seconds","description":"Lifetime of each minted key, 300 to 3600 seconds.","default":900},"enabled":{"type":"boolean","title":"Enabled","description":"When false, the exchange refuses this provider's tokens.","default":true},"provider_id":{"type":"string","title":"Provider Id","description":"Identifier the workload sends to the token exchange. Assigned by Mixpeek; keep it when you update the list so existing workloads keep working."},"created_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By","description":"User who configured the provider. Minted keys belong to this user and stop being issued if the user is suspended or removed. Set by Mixpeek."},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"When the provider was added. Set by Mixpeek."}},"additionalProperties":false,"type":"object","required":["name","issuer","audience","claim_conditions"],"title":"WorkloadIdentityProvider","description":"An external OIDC issuer whose workload tokens can be exchanged for a key.\n\nExample for a Vercel project (team issuer mode)::\n\n    {\n      \"name\": \"vercel-prod\",\n      \"issuer\": \"https://oidc.vercel.com/acme\",\n      \"audience\": [\"https://vercel.com/acme\"],\n      \"claim_conditions\": {\n        \"project_id\": [\"prj_123\"],\n        \"environment\": [\"production\"]\n      },\n      \"permissions\": [\"read\"]\n    }"},"WorkloadIdentityProviderInput":{"properties":{"name":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9][A-Za-z0-9_.-]*$","title":"Name","description":"Unique name within the organization, e.g. 'vercel-prod'."},"issuer":{"type":"string","minLength":1,"title":"Issuer","description":"Exact value of the token's 'iss' claim. Vercel: 'https://oidc.vercel.com/<team_slug>' (team issuer mode) or 'https://oidc.vercel.com' (global mode). GitHub Actions: 'https://token.actions.githubusercontent.com'."},"jwks_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Jwks Url","description":"URL of the issuer's JSON Web Key Set. When omitted, Mixpeek reads 'jwks_uri' from the issuer's '/.well-known/openid-configuration'."},"audience":{"items":{"type":"string"},"type":"array","minItems":1,"title":"Audience","description":"Accepted values of the token's 'aud' claim. Vercel's default is 'https://vercel.com/<team_slug>'; for GitHub Actions use the audience you request with core.getIDToken(audience)."},"algorithms":{"items":{"type":"string","enum":["RS256","RS384","RS512","ES256","ES384","PS256"]},"type":"array","minItems":1,"title":"Algorithms","description":"Signature algorithms accepted. Only asymmetric algorithms."},"claim_conditions":{"additionalProperties":{"items":{"type":"string"},"type":"array"},"type":"object","minProperties":1,"title":"Claim Conditions","description":"Claims the token must carry, each mapped to its allowed values. Every listed claim must match one of its values. A value ending in '*' matches by prefix, e.g. 'repo:acme/api:*'. At least one claim other than iss, aud, exp, iat, nbf and jti is required, so a provider never trusts every workload an issuer signs for.","examples":[{"environment":["production"],"project_id":["prj_123"]},{"ref":["refs/heads/main"],"repository":["acme/api"]}]},"permissions":{"items":{"$ref":"#/components/schemas/Permission"},"type":"array","minItems":1,"title":"Permissions","description":"Permissions of the keys this provider mints: read, write and delete. Admin is not available through workload identity."},"token_ttl_seconds":{"type":"integer","maximum":3600.0,"minimum":300.0,"title":"Token Ttl Seconds","description":"Lifetime of each minted key, 300 to 3600 seconds.","default":900},"enabled":{"type":"boolean","title":"Enabled","description":"When false, the exchange refuses this provider's tokens.","default":true},"provider_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider Id","description":"Existing provider's identifier; omit for a new provider."}},"additionalProperties":false,"type":"object","required":["name","issuer","audience","claim_conditions"],"title":"WorkloadIdentityProviderInput","description":"A provider as sent in ``PATCH /v1/organizations``.\n\nOmit ``provider_id`` for a new provider; send it back unchanged to keep an\nexisting provider's identifier. ``created_by`` and ``created_at`` are set\nby Mixpeek."},"WriteBackFieldMapping":{"properties":{"source_field":{"type":"string","title":"Source Field","description":"Field path in retriever result (dot notation supported)","examples":["ai_safety_insight.text","category","score"]},"target_field":{"type":"string","title":"Target Field","description":"Field name to write on the document","examples":["_enrichment_category","safety_score","related_items"]},"mode":{"type":"string","enum":["first","all_as_array","concat"],"title":"Mode","description":"How to aggregate values from multiple results. 'first': top result only. 'all_as_array': collect into list. 'concat': join strings with ', '.","default":"first"},"type":{"anyOf":[{"type":"string","enum":["string","number","integer","boolean"]},{"type":"null"}],"title":"Type","description":"OPTIONAL. The type a retriever_transform collection declares for target_field in its output schema. Leave it unset for a string. Set 'number' or 'integer' for a time or a position, so a filter or sort on the field compares numbers. Retriever enrichments ignore it.","examples":["number","integer"]}},"type":"object","required":["source_field","target_field"],"title":"WriteBackFieldMapping","description":"Maps a field from retriever results back to the document.\n\nControls how retriever result fields are written to the source document.\n\nAttributes:\n    source_field: Field path in retriever result (dot notation for nested fields)\n    target_field: Field name to write on the document\n    mode: How to aggregate values across multiple results:\n        - \"first\": Write value from first result only (default)\n        - \"all_as_array\": Collect values from all results into a list\n        - \"concat\": Concatenate string values with \", \" separator"},"WriteConsistency":{"properties":{"retriever_visible":{"type":"string","title":"Retriever Visible","description":"Visibility model: 'eventual' (BYOV direct upsert — indexed within seconds) or 'after_processing' (managed ingestion — visible after a collection batch processes the object)."},"recommended_header":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recommended Header","description":"Header to send on retriever execute for read-your-writes (BYOV). Set only when a write_token was actually issued; null when no token was minted."},"write_token_available":{"type":"boolean","title":"Write Token Available","description":"Whether a write_token was issued for read-your-writes.","default":false},"expected_visible_within_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Expected Visible Within Ms","description":"Typical upper bound for visibility (BYOV indexing). Null when visibility depends on asynchronous processing (managed ingestion)."},"poll":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Poll","description":"How to poll for visibility when it depends on async processing: {endpoint, field, ready_when}."},"next_actions":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Next Actions","description":"Actionable next steps to reach retriever visibility."}},"type":"object","required":["retriever_visible"],"title":"WriteConsistency","description":"How and when a write becomes visible to retriever reads."},"api__analytics__buckets__models__TimeRange":{"properties":{"start":{"type":"string","format":"date-time","title":"Start","description":"Start of time range"},"end":{"type":"string","format":"date-time","title":"End","description":"End of time range"}},"type":"object","required":["start","end"],"title":"TimeRange","description":"Time range for analytics queries."},"api__analytics__clusters__models__FailureAnalysisResponse":{"properties":{"cluster_id":{"type":"string","title":"Cluster Id"},"time_range":{"$ref":"#/components/schemas/api__analytics__clusters__models__TimeRange"},"failures":{"items":{"$ref":"#/components/schemas/FailureMetric"},"type":"array","title":"Failures"},"total_failures":{"type":"integer","title":"Total Failures"}},"type":"object","required":["cluster_id","time_range","failures","total_failures"],"title":"FailureAnalysisResponse","description":"Cluster failure analysis response."},"api__analytics__clusters__models__TimeRange":{"properties":{"start":{"type":"string","format":"date-time","title":"Start"},"end":{"type":"string","format":"date-time","title":"End"}},"type":"object","required":["start","end"],"title":"TimeRange","description":"Time range for analytics queries."},"api__analytics__collections__models__FailureAnalysisResponse":{"properties":{"collection_id":{"type":"string","title":"Collection Id"},"time_range":{"$ref":"#/components/schemas/api__analytics__collections__models__TimeRange"},"error_distribution":{"items":{"$ref":"#/components/schemas/ErrorMetrics"},"type":"array","title":"Error Distribution"},"total_errors":{"type":"integer","title":"Total Errors"}},"type":"object","required":["collection_id","time_range","error_distribution","total_errors"],"title":"FailureAnalysisResponse","description":"Failure analysis response."},"api__analytics__collections__models__TimeRange":{"properties":{"start":{"type":"string","format":"date-time","title":"Start"},"end":{"type":"string","format":"date-time","title":"End"}},"type":"object","required":["start","end"],"title":"TimeRange","description":"Time range for analytics queries."},"api__analytics__models__TimeRange":{"properties":{"start":{"type":"string","format":"date-time","title":"Start","description":"Start time (UTC)"},"end":{"type":"string","format":"date-time","title":"End","description":"End time (UTC)"}},"type":"object","required":["start","end"],"title":"TimeRange","description":"Time range for analytics queries."},"api__analytics__taxonomies__models__TimeRange":{"properties":{"start":{"type":"string","format":"date-time","title":"Start"},"end":{"type":"string","format":"date-time","title":"End"}},"type":"object","required":["start","end"],"title":"TimeRange","description":"Time range for analytics queries."},"shared__clusters__triggers__models__CreateTriggerRequest":{"properties":{"cluster_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cluster Id","description":"OPTIONAL. Reference to existing cluster definition. If provided, execution_config is inherited from the cluster. Either cluster_id OR execution_config must be provided.","examples":["cluster_abc123",null]},"execution_config":{"anyOf":[{"$ref":"#/components/schemas/TriggerExecutionConfig"},{"type":"null"}],"description":"OPTIONAL. Clustering configuration for this trigger. Specifies collections and algorithm to use when trigger fires. Required if cluster_id is not provided."},"trigger_type":{"$ref":"#/components/schemas/shared__clusters__triggers__models__TriggerType","description":"REQUIRED. Type of trigger to create. Determines which schedule_config fields are required. Options: 'cron', 'interval', 'event', 'conditional'."},"schedule_config":{"additionalProperties":true,"type":"object","title":"Schedule Config","description":"REQUIRED. Type-specific schedule configuration. Contents depend on trigger_type. See trigger type examples above for required fields."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"OPTIONAL. Human-readable description of what this trigger does. Helpful for identifying triggers in dashboards.","examples":["Daily clustering at 2am UTC","Re-cluster after 100 documents","Maintain fresh clusters hourly"]},"status":{"$ref":"#/components/schemas/shared__clusters__triggers__models__TriggerStatus","description":"OPTIONAL. Initial status of trigger. Defaults to 'active' (enabled). Can be set to 'paused' to create disabled trigger.","default":"active"}},"type":"object","required":["trigger_type","schedule_config"],"title":"CreateTriggerRequest","description":"Request to create a new cluster trigger.\n\nCreates an automated trigger that executes clustering based on schedules, events, or conditions.\n\nRequirements:\n    - trigger_type: REQUIRED - Determines which schedule_config fields are needed\n    - schedule_config: REQUIRED - Configuration specific to trigger_type\n    - execution_config OR cluster_id: REQUIRED - Either provide config directly or reference existing cluster\n\nTrigger Types and schedule_config:\n    - **cron**: Requires {\"cron_expression\": str, \"timezone\": str}\n    - **interval**: Requires {\"interval_seconds\": int, \"start_immediately\": bool}\n    - **event**: Requires {\"event_type\": str, \"event_threshold\": int, \"collection_id\": str, \"cooldown_seconds\": int}\n    - **conditional**: Requires {\"condition_type\": str, \"threshold\": float, \"metric\": str, \"check_interval_seconds\": int}\n\nUse Cases:\n    - Scheduled maintenance: Use cron or interval triggers\n    - Reactive clustering: Use event triggers to cluster when data changes\n    - Intelligent clustering: Use conditional triggers based on metrics\n\nExamples:\n    Cron trigger (daily at 2am UTC):\n        {\n            \"trigger_type\": \"cron\",\n            \"schedule_config\": {\n                \"cron_expression\": \"0 2 * * *\",\n                \"timezone\": \"UTC\"\n            },\n            \"execution_config\": {\n                \"collection_ids\": [\"col_abc123\"],\n                \"config\": {\n                    \"algorithm\": \"kmeans\",\n                    \"n_clusters\": 5\n                }\n            },\n            \"description\": \"Daily clustering at 2am\"\n        }\n\n    Interval trigger (every 6 hours):\n        {\n            \"trigger_type\": \"interval\",\n            \"schedule_config\": {\n                \"interval_seconds\": 21600,\n                \"start_immediately\": false\n            },\n            \"execution_config\": {\n                \"collection_ids\": [\"col_products\"],\n                \"config\": {\n                    \"algorithm\": \"hdbscan\",\n                    \"min_cluster_size\": 10\n                }\n            },\n            \"description\": \"Cluster every 6 hours\"\n        }\n\n    Event trigger (after 100 documents added):\n        {\n            \"trigger_type\": \"event\",\n            \"schedule_config\": {\n                \"event_type\": \"documents_added\",\n                \"event_threshold\": 100,\n                \"collection_id\": \"col_abc123\",\n                \"cooldown_seconds\": 300\n            },\n            \"execution_config\": {\n                \"collection_ids\": [\"col_abc123\"],\n                \"config\": {\n                    \"algorithm\": \"kmeans\",\n                    \"n_clusters\": 3\n                }\n            },\n            \"description\": \"Cluster after 100 new documents\"\n        }\n\n    Conditional trigger (when drift exceeds 30%):\n        {\n            \"trigger_type\": \"conditional\",\n            \"schedule_config\": {\n                \"condition_type\": \"drift\",\n                \"threshold\": 0.3,\n                \"metric\": \"cosine_drift\",\n                \"check_interval_seconds\": 3600\n            },\n            \"execution_config\": {\n                \"collection_ids\": [\"col_abc123\"],\n                \"config\": {\n                    \"algorithm\": \"hdbscan\",\n                    \"min_cluster_size\": 5\n                }\n            },\n            \"description\": \"Re-cluster when drift > 30%\"\n        }\n\n    Using existing cluster definition:\n        {\n            \"trigger_type\": \"interval\",\n            \"schedule_config\": {\n                \"interval_seconds\": 3600,\n                \"start_immediately\": true\n            },\n            \"cluster_id\": \"cluster_xyz789\",\n            \"description\": \"Hourly clustering using cluster_xyz789\"\n        }","examples":[{"description":"Daily clustering at 2am UTC","execution_config":{"collection_ids":["col_abc123"],"config":{"algorithm":"kmeans","min_cluster_size":2,"n_clusters":5}},"schedule_config":{"cron_expression":"0 2 * * *","timezone":"UTC"},"trigger_type":"cron"},{"description":"Cluster every 6 hours","execution_config":{"collection_ids":["col_products"],"config":{"algorithm":"hdbscan","min_cluster_size":10,"min_samples":5}},"schedule_config":{"interval_seconds":21600,"start_immediately":false},"trigger_type":"interval"},{"description":"Cluster after 100 new documents","execution_config":{"collection_ids":["col_abc123"],"config":{"algorithm":"kmeans","n_clusters":3}},"schedule_config":{"collection_id":"col_abc123","cooldown_seconds":300,"event_threshold":100,"event_type":"documents_added"},"trigger_type":"event"},{"description":"Re-cluster when drift > 30%","execution_config":{"collection_ids":["col_abc123"],"config":{"algorithm":"hdbscan","min_cluster_size":5}},"schedule_config":{"check_interval_seconds":3600,"condition_type":"drift","metric":"cosine_drift","threshold":0.3},"trigger_type":"conditional"},{"cluster_id":"cluster_xyz789","description":"Hourly clustering using cluster_xyz789","schedule_config":{"interval_seconds":3600,"start_immediately":true},"trigger_type":"interval"}]},"shared__clusters__triggers__models__ListTriggersRequest":{"properties":{"cluster_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cluster Id","description":"Filter by cluster ID"},"trigger_type":{"anyOf":[{"$ref":"#/components/schemas/shared__clusters__triggers__models__TriggerType"},{"type":"null"}],"description":"Filter by trigger type"},"status":{"anyOf":[{"$ref":"#/components/schemas/shared__clusters__triggers__models__TriggerStatus"},{"type":"null"}],"description":"Filter by status"},"offset":{"type":"integer","minimum":0.0,"title":"Offset","description":"Pagination offset","default":0},"limit":{"type":"integer","maximum":1000.0,"minimum":1.0,"title":"Limit","description":"Results per page","default":50},"sort_by":{"type":"string","title":"Sort By","description":"Field to sort by","default":"created_at"},"direction":{"type":"string","title":"Direction","description":"Sort direction (asc/desc)","default":"desc"}},"type":"object","title":"ListTriggersRequest","description":"Request to list triggers with filters and pagination."},"shared__clusters__triggers__models__ListTriggersResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/shared__clusters__triggers__models__TriggerModel"},"type":"array","title":"Results","description":"List of triggers"},"total":{"type":"integer","title":"Total","description":"Total number of triggers"},"offset":{"type":"integer","title":"Offset","description":"Current offset"},"limit":{"type":"integer","title":"Limit","description":"Current limit"}},"type":"object","required":["results","total","offset","limit"],"title":"ListTriggersResponse","description":"Response for list triggers request."},"shared__clusters__triggers__models__TriggerHistoryResponse":{"properties":{"trigger_id":{"type":"string","title":"Trigger Id","description":"Trigger ID"},"executions":{"items":{"$ref":"#/components/schemas/TriggerExecutionHistoryItem"},"type":"array","title":"Executions","description":"Execution history"},"total":{"type":"integer","title":"Total","description":"Total executions"},"offset":{"type":"integer","title":"Offset","description":"Current offset"},"limit":{"type":"integer","title":"Limit","description":"Current limit"}},"type":"object","required":["trigger_id","executions","total","offset","limit"],"title":"TriggerHistoryResponse","description":"Response for trigger execution history."},"shared__clusters__triggers__models__TriggerModel":{"properties":{"trigger_id":{"type":"string","title":"Trigger Id","description":"Unique trigger ID"},"cluster_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cluster Id","description":"Optional link to cluster definition"},"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace ID"},"internal_id":{"type":"string","title":"Internal Id","description":"Organization internal ID"},"execution_config":{"$ref":"#/components/schemas/TriggerExecutionConfig","description":"Configuration for cluster execution"},"trigger_type":{"$ref":"#/components/schemas/shared__clusters__triggers__models__TriggerType","description":"Type of trigger"},"schedule_config":{"additionalProperties":true,"type":"object","title":"Schedule Config","description":"Type-specific schedule configuration"},"status":{"$ref":"#/components/schemas/shared__clusters__triggers__models__TriggerStatus","description":"Current status","default":"active"},"last_triggered_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Triggered At","description":"Last time trigger fired"},"last_execution_job_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Execution Job Id","description":"Job ID of last execution"},"next_scheduled_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Next Scheduled At","description":"Next scheduled execution time"},"execution_count":{"type":"integer","title":"Execution Count","description":"Total executions","default":0},"consecutive_failures":{"type":"integer","title":"Consecutive Failures","description":"Consecutive execution failures","default":0},"last_execution_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Execution Status","description":"Status of last execution"},"last_execution_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Execution Error","description":"Error from last execution"},"event_counter":{"type":"integer","title":"Event Counter","description":"Current event count since last trigger","default":0},"last_cooldown_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Cooldown At","description":"Last time cooldown was applied"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"},"created_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By","description":"User who created trigger"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Trigger description"}},"type":"object","required":["namespace_id","internal_id","execution_config","trigger_type","schedule_config"],"title":"TriggerModel","description":"Model for cluster trigger."},"shared__clusters__triggers__models__TriggerStatus":{"type":"string","enum":["active","paused","disabled","failed"],"title":"TriggerStatus","description":"Status of a cluster trigger."},"shared__clusters__triggers__models__TriggerType":{"type":"string","enum":["cron","interval","event","conditional"],"title":"TriggerType","description":"Type of trigger for automated cluster execution.\n\nSupported trigger types:\n- **cron**: Schedule-based execution using cron expressions (e.g., daily at 2am)\n- **interval**: Fixed-interval execution (e.g., every 6 hours)\n- **event**: Event-driven execution (e.g., after 100 documents added)\n- **conditional**: Condition-based execution (e.g., when drift exceeds threshold)"},"shared__clusters__triggers__models__UpdateTriggerRequest":{"properties":{"schedule_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Schedule Config","description":"Updated schedule configuration"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Updated description"},"status":{"anyOf":[{"$ref":"#/components/schemas/shared__clusters__triggers__models__TriggerStatus"},{"type":"null"}],"description":"Updated status"}},"type":"object","title":"UpdateTriggerRequest","description":"Request to update an existing trigger."},"shared__collection__features__extractors__models__FeatureExtractorConfig-Input":{"properties":{"feature_extractor_name":{"type":"string","title":"Feature Extractor Name","description":"Name of the feature extractor"},"version":{"type":"string","title":"Version","description":"Version of the feature extractor (e.g., 'v1', 'v2')"},"params":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Params","description":"Optional extractor parameters that affect vector index configuration. Parameters set here are locked at namespace creation and determine vector dimensions in the vector store. Collections using this extractor must use compatible params. Example: {'model': 'siglip_base'}"},"parameters":{"anyOf":[{"$ref":"#/components/schemas/AudioFingerprintExtractorParams"},{"$ref":"#/components/schemas/ColbertExtractorParams"},{"$ref":"#/components/schemas/ColqwenExtractorParams"},{"$ref":"#/components/schemas/DocumentGraphExtractorParams"},{"$ref":"#/components/schemas/FaceIdentityExtractorParams"},{"$ref":"#/components/schemas/GeminiMultifileExtractorParams"},{"$ref":"#/components/schemas/ImageExtractorParams"},{"$ref":"#/components/schemas/MultimodalExtractorParams"},{"$ref":"#/components/schemas/PassthroughExtractorParams"},{"$ref":"#/components/schemas/ScrollingTextExtractorParams"},{"$ref":"#/components/schemas/TextExtractorParams"},{"$ref":"#/components/schemas/TranscodingExtractorParams"},{"$ref":"#/components/schemas/UniversalExtractorParams"},{"$ref":"#/components/schemas/WebScraperExtractorParams"},{"$ref":"#/components/schemas/CustomPluginParams"},{"type":"null"}],"title":"Parameters","description":"Parameters for the feature extractor. Each extractor type has specific parameters. See the schema for your chosen extractor (e.g., MultimodalExtractorParams for multimodal_extractor).","examples":[{"split_method":"time","time_split_interval":10},{"chunk_size":512,"split_by":"sentences"}]},"input_mappings":{"anyOf":[{"additionalProperties":{"anyOf":[{"type":"string"},{"items":{"type":"string"},"type":"array"}]},"type":"object"},{"items":{"$ref":"#/components/schemas/InputMapping"},"type":"array"}],"title":"Input Mappings","description":"Mapping from extractor input names to source field paths. Tells the extractor which source fields to process. Single value: {'image': 'thumbnail_url'} maps one blob field to one extractor input. Array value: {'files': ['image', 'spec_pdf', 'description']} maps multiple blob fields to a single extractor input as a list — used by multi-file extractors like gemini_multifile_extractor that embed all blobs of an object into one embedding.","examples":[{"image":"product_image","text":"title"},{"video":"video_url"},{"text":"content"},{"files":["hero_image","spec_sheet","description"]}]},"field_passthrough":{"items":{"$ref":"#/components/schemas/FieldPassthrough"},"type":"array","title":"Field Passthrough","description":"NOT REQUIRED. List of specific fields to pass through from source to output documents. These fields are included alongside extractor-computed features (embeddings, detections, etc.). Empty list = only extractor outputs in documents (default behavior). With entries = specified fields + extractor outputs in documents. \n\nHow It Works:\n1. During processing, fields are extracted from source object/document\n2. They appear in output documents at the root level\n3. Field filtering happens automatically (only listed fields included)\n4. Use target_path to rename fields for cleaner schemas\n\nCommon Use Cases:\n- Preserve identifiers: campaign_id, product_sku, order_id\n- Keep metadata: category, tags, author, created_at\n- Enable filtering: department, status, priority, region\n- Maintain context: title, description, source_url\n\nBehavior:\n- Works with include_all_source_fields=False (default): ONLY these fields included\n- Works with include_all_source_fields=True: These configs used for renaming/defaults\n- Fields must exist in source bucket_schema or upstream collection output_schema\n- Missing optional fields are omitted (unless default provided)\n- Missing required fields cause processing errors\n\nOutput Schema:\noutput_schema = field_passthrough fields + extractor output fields\nExample: ['title', 'category', 'text_extractor_v1_embedding']","examples":[[{"required":true,"source_path":"title"},{"required":true,"source_path":"campaign_id"}],[{"default":"uncategorized","source_path":"category"},{"source_path":"metadata.author","target_path":"author"}]]},"include_all_source_fields":{"type":"boolean","title":"Include All Source Fields","description":"NOT REQUIRED. Whether to include ALL fields from source object/document in output. Default: False (only field_passthrough fields included). \n\nWhen False (RECOMMENDED):\n- Only fields listed in field_passthrough are included in output\n- Creates clean, predictable output schemas\n- Prevents data leakage of unwanted fields\n- Output = field_passthrough fields + extractor outputs\n\nWhen True (USE WITH CAUTION):\n- ALL source fields are included in output documents\n- field_passthrough still used for renaming/defaults/requirements\n- Can result in large documents if source has many fields\n- Can leak sensitive or unnecessary data\n- Output = all source fields + extractor outputs\n\nUse True When:\n- You want to preserve complete source data\n- Source has limited, well-defined fields\n- Downstream processing needs all context\n\nUse False When (MOST CASES):\n- You want clean, controlled output schemas\n- Source has many fields you don't need\n- You want explicit field selection\n- You're concerned about document size\n\nExamples:\nFalse: source={a,b,c,d} + passthrough=[a,b] → output={a,b,embedding}\nTrue:  source={a,b,c,d} + passthrough=[a→x] → output={x,b,c,d,embedding}","default":false}},"additionalProperties":false,"type":"object","required":["feature_extractor_name","version"],"title":"FeatureExtractorConfig","description":"Configuration for a feature extractor with field passthrough support.\n\nA feature extractor processes source data (from buckets or collections) and\nproduces features (embeddings, extracted text, detected objects, etc.).\n\nWith field passthrough, you can also include selected source fields in the\noutput documents alongside the computed features.\n\nCore Concepts:\n    1. **Feature Extraction**: Extractors compute features from input data\n       (e.g., text → embeddings, image → detections, video → scenes)\n    2. **Field Passthrough**: Selectively preserve source fields in output\n       (e.g., title, category, campaign_id from source → output documents)\n    3. **Output Schema**: Combination of passed-through fields + extractor outputs\n       (e.g., {title, category, text_embedding} all in one document)\n\nHow Field Passthrough Works:\n    1. Define which source fields to include via field_passthrough list\n    2. During processing, these fields are extracted from source\n    3. They appear in output documents at root level\n    4. Combine with extractor outputs for complete documents\n    5. Use target_path to rename fields for cleaner schemas\n\nField Selection Modes:\n    - **Explicit** (field_passthrough + include_all=False):\n      Only listed fields pass through. Clean, controlled output.\n      Example: passthrough=[title, category] → output has ONLY title, category, embedding\n\n    - **Inclusive** (include_all=True):\n      All source fields pass through, field_passthrough for renaming.\n      Example: source has 10 fields → output has all 10 + embedding\n\n    - **None** (no field_passthrough):\n      Only extractor outputs in documents.\n      Example: → output has ONLY embedding (no source fields)\n\nUse Cases:\n    - **Preserve Identifiers**: Keep campaign_id, product_sku, order_id for tracking\n    - **Enable Filtering**: Pass category, status, department for query filters\n    - **Maintain Context**: Include title, description for display\n    - **Track Metadata**: Preserve author, created_at, source for lineage\n    - **Business Logic**: Keep priority, region, type for application logic\n\nCommon Patterns:\n    1. **Minimal Passthrough** (recommended):\n       field_passthrough=[{\"source_path\": \"id\"}], include_all=False\n       → Clean output, only ID + extractor features\n\n    2. **Metadata Preservation**:\n       field_passthrough=[\n           {\"source_path\": \"title\"},\n           {\"source_path\": \"category\"},\n           {\"source_path\": \"created_at\"}\n       ]\n       → Document has context for display and filtering\n\n    3. **Field Renaming**:\n       field_passthrough=[\n           {\"source_path\": \"doc_title\", \"target_path\": \"title\"},\n           {\"source_path\": \"metadata.author\", \"target_path\": \"author\"}\n       ]\n       → Cleaner output schema with flattened fields\n\n    4. **Required Fields**:\n       field_passthrough=[\n           {\"source_path\": \"campaign_id\", \"required\": True},\n           {\"source_path\": \"priority\", \"default\": 0}\n       ]\n       → Ensures critical fields always present\n\nRequirements:\n    - feature_extractor_name: REQUIRED - name of the extractor\n    - version: REQUIRED - extractor version (e.g., \"v1\")\n    - parameters: NOT REQUIRED - extractor-specific config (model, thresholds, etc.)\n    - input_mappings: NOT REQUIRED - maps extractor inputs to source fields\n    - field_passthrough: NOT REQUIRED - which source fields to preserve (default: none)\n    - include_all_source_fields: NOT REQUIRED - preserve all fields (default: false)","examples":[{"description":"Text extractor with field passthrough","feature_extractor_name":"text_extractor","field_passthrough":[{"required":true,"source_path":"title"},{"source_path":"author"}],"input_mappings":{"text":"content"},"parameters":{"model":"text-embedding-3-small"},"version":"v1"},{"description":"Video extractor with campaign metadata","feature_extractor_name":"multimodal_extractor","field_passthrough":[{"source_path":"campaign_id"},{"source_path":"duration_seconds"}],"input_mappings":{"video":"video_url"},"parameters":{"fps":1},"version":"v1"},{"description":"Image extractor with all source fields","feature_extractor_name":"image_extractor","include_all_source_fields":true,"input_mappings":{"image":"product_image"},"parameters":{"model":"clip-vit-base-patch32"},"version":"v1"},{"description":"Text extractor with field renaming","feature_extractor_name":"text_extractor","field_passthrough":[{"source_path":"metadata.author","target_path":"author"},{"source_path":"metadata.created_at","target_path":"created_at"}],"input_mappings":{"text":"content"},"version":"v1"}]},"shared__collection__features__extractors__models__FeatureExtractorConfig-Output":{"properties":{"feature_extractor_name":{"type":"string","title":"Feature Extractor Name","description":"Name of the feature extractor"},"version":{"type":"string","title":"Version","description":"Version of the feature extractor (e.g., 'v1', 'v2')"},"params":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Params","description":"Optional extractor parameters that affect vector index configuration. Parameters set here are locked at namespace creation and determine vector dimensions in the vector store. Collections using this extractor must use compatible params. Example: {'model': 'siglip_base'}"},"parameters":{"anyOf":[{"$ref":"#/components/schemas/AudioFingerprintExtractorParams"},{"$ref":"#/components/schemas/ColbertExtractorParams"},{"$ref":"#/components/schemas/ColqwenExtractorParams"},{"$ref":"#/components/schemas/DocumentGraphExtractorParams"},{"$ref":"#/components/schemas/FaceIdentityExtractorParams"},{"$ref":"#/components/schemas/GeminiMultifileExtractorParams"},{"$ref":"#/components/schemas/ImageExtractorParams"},{"$ref":"#/components/schemas/MultimodalExtractorParams"},{"$ref":"#/components/schemas/PassthroughExtractorParams"},{"$ref":"#/components/schemas/ScrollingTextExtractorParams"},{"$ref":"#/components/schemas/TextExtractorParams"},{"$ref":"#/components/schemas/TranscodingExtractorParams"},{"$ref":"#/components/schemas/UniversalExtractorParams"},{"$ref":"#/components/schemas/WebScraperExtractorParams"},{"$ref":"#/components/schemas/CustomPluginParams"},{"type":"null"}],"title":"Parameters","description":"Parameters for the feature extractor. Each extractor type has specific parameters. See the schema for your chosen extractor (e.g., MultimodalExtractorParams for multimodal_extractor).","examples":[{"split_method":"time","time_split_interval":10},{"chunk_size":512,"split_by":"sentences"}]},"input_mappings":{"anyOf":[{"additionalProperties":{"anyOf":[{"type":"string"},{"items":{"type":"string"},"type":"array"}]},"type":"object"},{"items":{"$ref":"#/components/schemas/InputMapping"},"type":"array"}],"title":"Input Mappings","description":"Mapping from extractor input names to source field paths. Tells the extractor which source fields to process. Single value: {'image': 'thumbnail_url'} maps one blob field to one extractor input. Array value: {'files': ['image', 'spec_pdf', 'description']} maps multiple blob fields to a single extractor input as a list — used by multi-file extractors like gemini_multifile_extractor that embed all blobs of an object into one embedding.","examples":[{"image":"product_image","text":"title"},{"video":"video_url"},{"text":"content"},{"files":["hero_image","spec_sheet","description"]}]},"field_passthrough":{"items":{"$ref":"#/components/schemas/FieldPassthrough"},"type":"array","title":"Field Passthrough","description":"NOT REQUIRED. List of specific fields to pass through from source to output documents. These fields are included alongside extractor-computed features (embeddings, detections, etc.). Empty list = only extractor outputs in documents (default behavior). With entries = specified fields + extractor outputs in documents. \n\nHow It Works:\n1. During processing, fields are extracted from source object/document\n2. They appear in output documents at the root level\n3. Field filtering happens automatically (only listed fields included)\n4. Use target_path to rename fields for cleaner schemas\n\nCommon Use Cases:\n- Preserve identifiers: campaign_id, product_sku, order_id\n- Keep metadata: category, tags, author, created_at\n- Enable filtering: department, status, priority, region\n- Maintain context: title, description, source_url\n\nBehavior:\n- Works with include_all_source_fields=False (default): ONLY these fields included\n- Works with include_all_source_fields=True: These configs used for renaming/defaults\n- Fields must exist in source bucket_schema or upstream collection output_schema\n- Missing optional fields are omitted (unless default provided)\n- Missing required fields cause processing errors\n\nOutput Schema:\noutput_schema = field_passthrough fields + extractor output fields\nExample: ['title', 'category', 'text_extractor_v1_embedding']","examples":[[{"required":true,"source_path":"title"},{"required":true,"source_path":"campaign_id"}],[{"default":"uncategorized","source_path":"category"},{"source_path":"metadata.author","target_path":"author"}]]},"include_all_source_fields":{"type":"boolean","title":"Include All Source Fields","description":"NOT REQUIRED. Whether to include ALL fields from source object/document in output. Default: False (only field_passthrough fields included). \n\nWhen False (RECOMMENDED):\n- Only fields listed in field_passthrough are included in output\n- Creates clean, predictable output schemas\n- Prevents data leakage of unwanted fields\n- Output = field_passthrough fields + extractor outputs\n\nWhen True (USE WITH CAUTION):\n- ALL source fields are included in output documents\n- field_passthrough still used for renaming/defaults/requirements\n- Can result in large documents if source has many fields\n- Can leak sensitive or unnecessary data\n- Output = all source fields + extractor outputs\n\nUse True When:\n- You want to preserve complete source data\n- Source has limited, well-defined fields\n- Downstream processing needs all context\n\nUse False When (MOST CASES):\n- You want clean, controlled output schemas\n- Source has many fields you don't need\n- You want explicit field selection\n- You're concerned about document size\n\nExamples:\nFalse: source={a,b,c,d} + passthrough=[a,b] → output={a,b,embedding}\nTrue:  source={a,b,c,d} + passthrough=[a→x] → output={x,b,c,d,embedding}","default":false},"feature_extractor_id":{"type":"string","title":"Feature Extractor Id","description":"Construct unique identifier for the feature extractor instance (name + version).","readOnly":true}},"additionalProperties":false,"type":"object","required":["feature_extractor_name","version","feature_extractor_id"],"title":"FeatureExtractorConfig","description":"Configuration for a feature extractor with field passthrough support.\n\nA feature extractor processes source data (from buckets or collections) and\nproduces features (embeddings, extracted text, detected objects, etc.).\n\nWith field passthrough, you can also include selected source fields in the\noutput documents alongside the computed features.\n\nCore Concepts:\n    1. **Feature Extraction**: Extractors compute features from input data\n       (e.g., text → embeddings, image → detections, video → scenes)\n    2. **Field Passthrough**: Selectively preserve source fields in output\n       (e.g., title, category, campaign_id from source → output documents)\n    3. **Output Schema**: Combination of passed-through fields + extractor outputs\n       (e.g., {title, category, text_embedding} all in one document)\n\nHow Field Passthrough Works:\n    1. Define which source fields to include via field_passthrough list\n    2. During processing, these fields are extracted from source\n    3. They appear in output documents at root level\n    4. Combine with extractor outputs for complete documents\n    5. Use target_path to rename fields for cleaner schemas\n\nField Selection Modes:\n    - **Explicit** (field_passthrough + include_all=False):\n      Only listed fields pass through. Clean, controlled output.\n      Example: passthrough=[title, category] → output has ONLY title, category, embedding\n\n    - **Inclusive** (include_all=True):\n      All source fields pass through, field_passthrough for renaming.\n      Example: source has 10 fields → output has all 10 + embedding\n\n    - **None** (no field_passthrough):\n      Only extractor outputs in documents.\n      Example: → output has ONLY embedding (no source fields)\n\nUse Cases:\n    - **Preserve Identifiers**: Keep campaign_id, product_sku, order_id for tracking\n    - **Enable Filtering**: Pass category, status, department for query filters\n    - **Maintain Context**: Include title, description for display\n    - **Track Metadata**: Preserve author, created_at, source for lineage\n    - **Business Logic**: Keep priority, region, type for application logic\n\nCommon Patterns:\n    1. **Minimal Passthrough** (recommended):\n       field_passthrough=[{\"source_path\": \"id\"}], include_all=False\n       → Clean output, only ID + extractor features\n\n    2. **Metadata Preservation**:\n       field_passthrough=[\n           {\"source_path\": \"title\"},\n           {\"source_path\": \"category\"},\n           {\"source_path\": \"created_at\"}\n       ]\n       → Document has context for display and filtering\n\n    3. **Field Renaming**:\n       field_passthrough=[\n           {\"source_path\": \"doc_title\", \"target_path\": \"title\"},\n           {\"source_path\": \"metadata.author\", \"target_path\": \"author\"}\n       ]\n       → Cleaner output schema with flattened fields\n\n    4. **Required Fields**:\n       field_passthrough=[\n           {\"source_path\": \"campaign_id\", \"required\": True},\n           {\"source_path\": \"priority\", \"default\": 0}\n       ]\n       → Ensures critical fields always present\n\nRequirements:\n    - feature_extractor_name: REQUIRED - name of the extractor\n    - version: REQUIRED - extractor version (e.g., \"v1\")\n    - parameters: NOT REQUIRED - extractor-specific config (model, thresholds, etc.)\n    - input_mappings: NOT REQUIRED - maps extractor inputs to source fields\n    - field_passthrough: NOT REQUIRED - which source fields to preserve (default: none)\n    - include_all_source_fields: NOT REQUIRED - preserve all fields (default: false)","examples":[{"description":"Text extractor with field passthrough","feature_extractor_name":"text_extractor","field_passthrough":[{"required":true,"source_path":"title"},{"source_path":"author"}],"input_mappings":{"text":"content"},"parameters":{"model":"text-embedding-3-small"},"version":"v1"},{"description":"Video extractor with campaign metadata","feature_extractor_name":"multimodal_extractor","field_passthrough":[{"source_path":"campaign_id"},{"source_path":"duration_seconds"}],"input_mappings":{"video":"video_url"},"parameters":{"fps":1},"version":"v1"},{"description":"Image extractor with all source fields","feature_extractor_name":"image_extractor","include_all_source_fields":true,"input_mappings":{"image":"product_image"},"parameters":{"model":"clip-vit-base-patch32"},"version":"v1"},{"description":"Text extractor with field renaming","feature_extractor_name":"text_extractor","field_passthrough":[{"source_path":"metadata.author","target_path":"author"},{"source_path":"metadata.created_at","target_path":"created_at"}],"input_mappings":{"text":"content"},"version":"v1"}]},"shared__namespaces__migrations__models__FeatureExtractorConfig":{"properties":{"feature_extractor_name":{"type":"string","title":"Feature Extractor Name","description":"Name of the extractor"},"version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Version","description":"Version to use"},"parameters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Parameters","description":"Extractor parameters"}},"type":"object","required":["feature_extractor_name"],"title":"FeatureExtractorConfig","description":"Configuration for a feature extractor in migration."},"shared__namespaces__migrations__models__ResourceType":{"type":"string","enum":["bucket","collection","taxonomy","cluster","retriever"],"title":"ResourceType","description":"Types of resources that can be migrated."},"shared__notifications__vendors__email__models__EmailConfig":{"properties":{"to_addresses":{"items":{"type":"string"},"type":"array","title":"To Addresses","description":"Email addresses to send to"},"subject_template":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject Template","description":"Template for email subject"},"body_template":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body Template","description":"Template for email body"},"content_type":{"$ref":"#/components/schemas/NotificationContentType","description":"Format of the email body","default":"html"},"cc_addresses":{"items":{"type":"string"},"type":"array","title":"Cc Addresses","description":"CC addresses"},"bcc_addresses":{"items":{"type":"string"},"type":"array","title":"Bcc Addresses","description":"BCC addresses"}},"type":"object","required":["to_addresses"],"title":"EmailConfig","description":"Configuration for email notifications."},"shared__organizations__connections__provider_configs__EmailConfig":{"properties":{"provider_type":{"type":"string","const":"email","title":"Provider Type","default":"email"},"credentials":{"$ref":"#/components/schemas/EmailCredentials","description":"Webhook signing credentials (auto-generated if omitted)."},"inbound_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inbound Address","description":"System-assigned inbound email address. Auto-provisioned on connection creation. Read-only."},"allowed_senders":{"items":{"type":"string"},"type":"array","title":"Allowed Senders","description":"Sender allowlist. Emails from senders not matching this list are rejected. Supports exact addresses (user@company.com) and domain wildcards (*@company.com). Empty list = accept all senders."},"store_raw_eml":{"type":"boolean","title":"Store Raw Eml","description":"Store the raw .eml file as an additional blob for chain of custody.","default":true}},"type":"object","title":"EmailConfig","description":"Inbound email connector configuration (push-based).\n\nCustomers receive a dedicated inbound email address per connection.\nEmails forwarded to that address are parsed (MIME), attachments are\nextracted as blobs, and the whole message becomes a bucket object.\n\nAuthentication:\n    - Inbound webhook verified via HMAC-SHA256 signing secret\n\nRequirements:\n    - External inbound email service (SES Inbound / Postmark / CloudMailin)\n      configured to POST parsed emails to the webhook URL\n\nUse Cases:\n    - Compliance document intake (legal, healthcare)\n    - Customer support email ingestion\n    - Secure document forwarding pipelines\n    - Media collection via email attachments","examples":[{"allowed_senders":["*@lawfirm.com","paralegal@partner.com"],"credentials":{"type":"webhook_secret","webhook_secret":""},"description":"Legal document intake inbox","provider_type":"email","store_raw_eml":true}]},"shared__organizations__enums__ResourceType":{"type":"string","enum":["organization","user","api_key","namespace","collection","document","bucket","retriever","cluster","taxonomy","storage_connection","alert","annotation","secret","webhook"],"title":"ResourceType","description":"Resource surfaces supported by scoped API keys and audit events.\n\nThese resource types can be used in:\n- API key scopes to restrict access to specific resources\n- Audit logs to identify what type of resource was affected\n- Permission systems to grant/deny access to resource categories\n\nResource hierarchy:\n    ORGANIZATION -> USER, API_KEY, STORAGE_CONNECTION\n    NAMESPACE -> COLLECTION, BUCKET, RETRIEVER, CLUSTER, TAXONOMY\n\nResource types:\n    - ORGANIZATION: Top-level tenant entity\n    - USER: Organization member with authentication credentials\n    - API_KEY: Authentication token for programmatic access\n    - NAMESPACE: Isolated environment for data and compute resources\n    - COLLECTION: Vector database collection for searchable documents\n    - DOCUMENT: A single searchable document within a collection\n    - BUCKET: Object storage container for raw files\n    - RETRIEVER: Configured search/retrieval pipeline\n    - CLUSTER: Ray compute cluster for distributed processing\n    - TAXONOMY: Hierarchical classification system for documents\n    - STORAGE_CONNECTION: External storage provider integration"},"shared__retrievers__benchmarks__models__TimeRange":{"properties":{"start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start","description":"Start of time range (inclusive)."},"end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End","description":"End of time range (inclusive)."}},"type":"object","title":"TimeRange","description":"Time range filter for session queries."},"shared__triggers__models__CreateTriggerRequest":{"properties":{"action_type":{"$ref":"#/components/schemas/TriggerActionType","description":"Type of action to execute"},"action_config":{"additionalProperties":true,"type":"object","title":"Action Config","description":"Action-specific configuration"},"trigger_type":{"$ref":"#/components/schemas/shared__triggers__models__TriggerType","description":"Type of schedule"},"schedule_config":{"additionalProperties":true,"type":"object","title":"Schedule Config","description":"Schedule-specific configuration"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Human-readable trigger name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Human-readable description"},"status":{"$ref":"#/components/schemas/shared__triggers__models__TriggerStatus","description":"Initial status (active or paused)","default":"active"}},"type":"object","required":["action_type","action_config","trigger_type","schedule_config"],"title":"CreateTriggerRequest","description":"Request to create a new trigger.\n\nExamples:\n    Cluster trigger (cron):\n        {\n            \"action_type\": \"cluster\",\n            \"action_config\": {\"cluster_id\": \"clust_abc123\"},\n            \"trigger_type\": \"cron\",\n            \"schedule_config\": {\"cron_expression\": \"0 2 * * *\", \"timezone\": \"UTC\"},\n            \"description\": \"Daily clustering at 2am\"\n        }\n\n    Taxonomy trigger (interval):\n        {\n            \"action_type\": \"taxonomy_enrichment\",\n            \"action_config\": {\"taxonomy_id\": \"tax_products\", \"collection_id\": \"col_inv\"},\n            \"trigger_type\": \"interval\",\n            \"schedule_config\": {\"interval_seconds\": 21600},\n            \"description\": \"Re-enrich every 6 hours\"\n        }","examples":[{"action_config":{"cluster_id":"clust_abc123"},"action_type":"cluster","description":"Daily clustering at 2am","schedule_config":{"cron_expression":"0 2 * * *","timezone":"UTC"},"trigger_type":"cron"},{"action_config":{"cluster_id":"clust_abc123","filters":{"status":"active"},"output_collection_ids":["col_daily_clusters"]},"action_type":"cluster","description":"Daily clustering of active items with output override","schedule_config":{"cron_expression":"0 2 * * *","timezone":"UTC"},"trigger_type":"cron"},{"action_config":{"collection_id":"col_inventory","taxonomy_id":"tax_products"},"action_type":"taxonomy_enrichment","description":"Re-enrich products every 6 hours (in-place)","schedule_config":{"interval_seconds":21600,"start_immediately":false},"trigger_type":"interval"},{"action_config":{"collection_id":"col_inventory","incremental":true,"taxonomy_id":"tax_products"},"action_type":"taxonomy_enrichment","description":"Hourly incremental enrichment (only new docs)","schedule_config":{"interval_seconds":3600},"trigger_type":"interval"},{"action_config":{"batch_size":500,"collection_id":"col_inventory","incremental":true,"parallelism":8,"target_collection_id":"col_enriched","taxonomy_id":"tax_products"},"action_type":"taxonomy_enrichment","description":"Nightly incremental enrichment to target collection","schedule_config":{"cron_expression":"0 3 * * *","timezone":"UTC"},"trigger_type":"cron"}]},"shared__triggers__models__ListTriggersRequest":{"properties":{"action_type":{"anyOf":[{"$ref":"#/components/schemas/TriggerActionType"},{"type":"null"}],"description":"Filter by action type"},"trigger_type":{"anyOf":[{"$ref":"#/components/schemas/shared__triggers__models__TriggerType"},{"type":"null"}],"description":"Filter by trigger type"},"status":{"anyOf":[{"$ref":"#/components/schemas/shared__triggers__models__TriggerStatus"},{"type":"null"}],"description":"Filter by status"},"resource_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Id","description":"Filter by resource ID (cluster_id or taxonomy_id)"},"offset":{"type":"integer","minimum":0.0,"title":"Offset","description":"Pagination offset","default":0},"limit":{"type":"integer","maximum":1000.0,"minimum":1.0,"title":"Limit","description":"Results per page","default":50},"sort_by":{"type":"string","title":"Sort By","description":"Field to sort by","default":"created_at"},"direction":{"type":"string","title":"Direction","description":"Sort direction (asc/desc)","default":"desc"}},"type":"object","title":"ListTriggersRequest","description":"Request to list triggers with filters."},"shared__triggers__models__ListTriggersResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/shared__triggers__models__TriggerModel"},"type":"array","title":"Results","description":"List of triggers"},"total":{"type":"integer","title":"Total","description":"Total number of triggers"},"offset":{"type":"integer","title":"Offset","description":"Current offset"},"limit":{"type":"integer","title":"Limit","description":"Current limit"}},"type":"object","required":["results","total","offset","limit"],"title":"ListTriggersResponse","description":"Response for list triggers request."},"shared__triggers__models__TriggerHistoryResponse":{"properties":{"trigger_id":{"type":"string","title":"Trigger Id","description":"Trigger ID"},"executions":{"items":{"$ref":"#/components/schemas/TriggerExecutionHistory"},"type":"array","title":"Executions","description":"Execution history"},"total":{"type":"integer","title":"Total","description":"Total executions"},"offset":{"type":"integer","title":"Offset","description":"Current offset"},"limit":{"type":"integer","title":"Limit","description":"Current limit"}},"type":"object","required":["trigger_id","executions","total","offset","limit"],"title":"TriggerHistoryResponse","description":"Response for trigger execution history."},"shared__triggers__models__TriggerModel":{"properties":{"trigger_id":{"type":"string","title":"Trigger Id","description":"Unique trigger identifier"},"namespace_id":{"type":"string","title":"Namespace Id","description":"Namespace ID"},"internal_id":{"type":"string","title":"Internal Id","description":"Organization internal ID"},"action_type":{"$ref":"#/components/schemas/TriggerActionType","description":"Type of action to execute"},"action_config":{"additionalProperties":true,"type":"object","title":"Action Config","description":"Action-specific configuration"},"trigger_type":{"$ref":"#/components/schemas/shared__triggers__models__TriggerType","description":"Type of schedule"},"schedule_config":{"additionalProperties":true,"type":"object","title":"Schedule Config","description":"Schedule-specific configuration"},"status":{"$ref":"#/components/schemas/shared__triggers__models__TriggerStatus","description":"Current trigger status","default":"active"},"last_triggered_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Triggered At","description":"Last time trigger fired"},"last_execution_task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Execution Task Id","description":"Task ID of last execution"},"next_scheduled_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Next Scheduled At","description":"Next scheduled execution time"},"execution_count":{"type":"integer","title":"Execution Count","description":"Total successful executions","default":0},"consecutive_failures":{"type":"integer","title":"Consecutive Failures","description":"Consecutive failures","default":0},"last_execution_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Execution Status","description":"Status of last execution"},"last_execution_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Execution Error","description":"Error from last execution (if failed)"},"event_counter":{"type":"integer","title":"Event Counter","description":"Current event count since last trigger","default":0},"last_cooldown_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Cooldown At","description":"Last time cooldown was applied"},"baseline_snapshot":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Baseline Snapshot","description":"Baseline snapshot for drift measurement (captured after successful execution)"},"last_drift_measurement":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Last Drift Measurement","description":"Result of most recent drift measurement check"},"last_volume_measurement":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Last Volume Measurement","description":"Result of most recent volume (document count) condition check"},"last_condition_check_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Condition Check At","description":"When condition was last evaluated"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Human-readable trigger name (surfaced in list/get responses)"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Human-readable description"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"},"created_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By","description":"User who created trigger"},"is_overdue":{"type":"boolean","title":"Is Overdue","description":"Whether this trigger is active, scheduled by next_scheduled_at\n(cron, interval, or conditional), and that time has already passed.\n\nnext_scheduled_at is naive (implicitly UTC) right after creation --\n_calculate_next_cron (shared/triggers/utils.py) strips tzinfo before\nreturning -- and aware once round-tripped through Mongo (tz_aware=True\non both providers). Compare on the naive side so both cases work.","readOnly":true}},"type":"object","required":["namespace_id","internal_id","action_type","action_config","trigger_type","schedule_config","is_overdue"],"title":"TriggerModel","description":"Unified trigger model for all action types.\n\nA trigger defines:\n1. **What** to execute (action_type + action_config)\n2. **When** to execute (trigger_type + schedule_config)\n3. **State** tracking (execution count, failures, next scheduled time)"},"shared__triggers__models__TriggerStatus":{"type":"string","enum":["active","paused","disabled","failed"],"title":"TriggerStatus","description":"Status of a trigger."},"shared__triggers__models__TriggerType":{"type":"string","enum":["cron","interval","event","conditional"],"title":"TriggerType","description":"Type of trigger schedule.\n\nSupported trigger types:\n- **cron**: Schedule-based execution using cron expressions\n- **interval**: Fixed-interval execution\n- **event**: Event-driven execution\n- **conditional**: Condition-based execution"},"shared__triggers__models__UpdateTriggerRequest":{"properties":{"schedule_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Schedule Config","description":"Updated schedule configuration"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Updated trigger name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Updated description"},"status":{"anyOf":[{"$ref":"#/components/schemas/shared__triggers__models__TriggerStatus"},{"type":"null"}],"description":"Updated status"}},"additionalProperties":false,"type":"object","title":"UpdateTriggerRequest","description":"Request to update an existing trigger.\n\nOnly provided fields will be updated. Unknown fields are refused\n(extra=\"forbid\"): this endpoint cannot update action_config, and a body\ncarrying it used to 200 while changing nothing, so the caller read\nsuccess and moved on. A field the endpoint cannot act on is an error,\nnot a no-op."},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError","description":"Not sent by this API: a 422 answers with ErrorResponse, whose error.details.validation_errors lists each failing field. Kept so existing SDK imports of this type still resolve."}},"securitySchemes":{"BearerAuth":{"type":"http","scheme":"bearer","description":"Mixpeek API key, sent as `Authorization: Bearer mxp_sk_...`. Create one in Studio under Settings → API Keys, or with an admin key via `POST /v1/organizations/users/{user_email}/api-keys`. A missing, malformed, unknown, revoked, inactive or expired key returns 401; a key without the permission, scope or plan an operation needs returns 403."},"NamespaceHeader":{"type":"apiKey","in":"header","name":"X-Namespace","description":"Namespace id (`ns_...`), not the namespace name. This scopes the request rather than authenticating it, and it is required on every operation marked `x-mixpeek-namespace-scoped`."}}},"security":[{"BearerAuth":[]}]}