{"openapi":"3.1.0","info":{"title":"Signal Telecom Suite — Platform APIs","description":"Tenant management, Audit, Notifications, Analytics, Reporting, AI/ML, FAQ","version":"0.1.0"},"paths":{"/api/v1/tenant/catalog/vendors":{"get":{"tags":["Tenant / Sandbox"],"summary":"List Vendor Catalog","description":"All vendors Signal Telecom Suite supports.","operationId":"list_vendor_catalog_api_v1_tenant_catalog_vendors_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Response List Vendor Catalog Api V1 Tenant Catalog Vendors Get"}}}}}}},"/api/v1/tenant/catalog/modules":{"get":{"tags":["Tenant / Sandbox"],"summary":"List Module Catalog","description":"All modules in Signal Telecom Suite.\n\nEach row contains everything a partner / integration engineer needs to\nactually call into the module: what it does (`description`, `purpose`),\nwhich OAuth scopes a token needs (`auth_scopes`), which Swagger group\nholds the live API (`swagger_group` -> /docs/{group}/docs), and which\nintegration-guide section explains the flow (`guide_anchor`). The\nfrontend derives endpoint counts from /openapi.json directly so this\nendpoint stays free of vertical-package imports.","operationId":"list_module_catalog_api_v1_tenant_catalog_modules_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Response List Module Catalog Api V1 Tenant Catalog Modules Get"}}}}}}},"/api/v1/tenant/by-slug/{slug}":{"get":{"tags":["Tenant / Sandbox"],"summary":"Get Tenant By Slug","description":"Public resolver: slug → minimal tenant info (id + name). Used by the\nPlayground UI to discover the demo tenant's id without hardcoding it.\nReturns 404 if no tenant matches. No sensitive fields exposed.","operationId":"get_tenant_by_slug_api_v1_tenant_by_slug__slug__get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Tenant By Slug Api V1 Tenant By Slug  Slug  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenant/catalog/orchestrators":{"get":{"tags":["Tenant / Sandbox"],"summary":"List Orchestrator Catalog","description":"External workflow orchestrators / ETL tools / partner ERPs the platform\nintegrates with for invoicing and batch jobs. Returned as a flat list for\nthe public /integrations page.","operationId":"list_orchestrator_catalog_api_v1_tenant_catalog_orchestrators_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Response List Orchestrator Catalog Api V1 Tenant Catalog Orchestrators Get"}}}}}}},"/api/v1/tenant/catalog/countries":{"get":{"tags":["Tenant / Sandbox"],"summary":"List Countries","description":"All countries Signal Telecom Suite supports.","operationId":"list_countries_api_v1_tenant_catalog_countries_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Response List Countries Api V1 Tenant Catalog Countries Get"}}}}}}},"/api/v1/tenant/catalog/gateways":{"get":{"tags":["Tenant / Sandbox"],"summary":"List Gateway Catalog","description":"All gateway providers the platform supports (SMS + payment).\n\nOptional filter: ?gateway_type=sms or ?gateway_type=payment","operationId":"list_gateway_catalog_api_v1_tenant_catalog_gateways_get","parameters":[{"name":"gateway_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gateway Type"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","additionalProperties":true},"title":"Response List Gateway Catalog Api V1 Tenant Catalog Gateways Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenant/catalog/enums":{"get":{"tags":["Tenant / Sandbox"],"summary":"List Enums","description":"All enum values the frontend needs — single request, no hardcoding.","operationId":"list_enums_api_v1_tenant_catalog_enums_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response List Enums Api V1 Tenant Catalog Enums Get"}}}}}}},"/api/v1/tenant/catalog/currencies":{"get":{"tags":["Tenant / Sandbox"],"summary":"List Currencies","description":"All supported currencies with formatting rules.","operationId":"list_currencies_api_v1_tenant_catalog_currencies_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Response List Currencies Api V1 Tenant Catalog Currencies Get"}}}}}}},"/api/v1/tenant/login":{"post":{"tags":["Tenant / Sandbox"],"summary":"Tenant Login","description":"Authenticate tenant and return config.","operationId":"tenant_login_api_v1_tenant_login_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TenantLogin"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Tenant Login Api V1 Tenant Login Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenant/register":{"post":{"tags":["Tenant / Sandbox"],"summary":"Register Tenant","description":"Register a new tenant (used by Signal AI Labs to onboard customers).","operationId":"register_tenant_api_v1_tenant_register_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TenantCreate"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TenantResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenant/config/{tenant_id}":{"patch":{"tags":["Tenant / Sandbox"],"summary":"Update Tenant Config","description":"Update tenant's enabled vendors, modules, countries (P0 Admin).","operationId":"update_tenant_config_api_v1_tenant_config__tenant_id__patch","parameters":[{"name":"tenant_id","in":"path","required":true,"schema":{"type":"integer","title":"Tenant Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TenantConfigUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Update Tenant Config Api V1 Tenant Config  Tenant Id  Patch"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenant/{tenant_id}":{"get":{"tags":["Tenant / Sandbox"],"summary":"Get Tenant","operationId":"get_tenant_api_v1_tenant__tenant_id__get","parameters":[{"name":"tenant_id","in":"path","required":true,"schema":{"type":"integer","title":"Tenant Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TenantResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenant/users":{"post":{"tags":["Tenant / Sandbox"],"summary":"Create User","description":"Create a user within a tenant (called by tenant admin).","operationId":"create_user_api_v1_tenant_users_post","parameters":[{"name":"x-tenant-id","in":"header","required":false,"schema":{"type":"integer","default":0,"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenant/users/{tenant_id_param}":{"get":{"tags":["Tenant / Sandbox"],"summary":"List Users","description":"List all users for a tenant.","operationId":"list_users_api_v1_tenant_users__tenant_id_param__get","parameters":[{"name":"tenant_id_param","in":"path","required":true,"schema":{"type":"integer","title":"Tenant Id Param"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/UserResponse"},"title":"Response List Users Api V1 Tenant Users  Tenant Id Param  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenant/users/login":{"post":{"tags":["Tenant / Sandbox"],"summary":"User Login","description":"Authenticate a tenant user and return JWT token.","operationId":"user_login_api_v1_tenant_users_login_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserLogin"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response User Login Api V1 Tenant Users Login Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenant/users/{user_id}/reset-password":{"post":{"tags":["Tenant / Sandbox"],"summary":"Reset User Password","description":"Reset a tenant user's password.","operationId":"reset_user_password_api_v1_tenant_users__user_id__reset_password_post","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"integer","title":"User Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Reset User Password Api V1 Tenant Users  User Id  Reset Password Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenant/users/{user_id}":{"patch":{"tags":["Tenant / Sandbox"],"summary":"Update User","description":"Update a tenant user's name or role.","operationId":"update_user_api_v1_tenant_users__user_id__patch","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"integer","title":"User Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenant/users/{user_id}/deactivate":{"patch":{"tags":["Tenant / Sandbox"],"summary":"Deactivate User","description":"Deactivate a tenant user.","operationId":"deactivate_user_api_v1_tenant_users__user_id__deactivate_patch","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"integer","title":"User Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Deactivate User Api V1 Tenant Users  User Id  Deactivate Patch"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenant/enterprise-users":{"post":{"tags":["Tenant / Sandbox"],"summary":"Create Enterprise User","description":"Create a user for an enterprise customer.\n\nCalled by operator P0 (to create the first enterprise admin)\nor by an enterprise admin (to create their team).","operationId":"create_enterprise_user_api_v1_tenant_enterprise_users_post","parameters":[{"name":"x-tenant-id","in":"header","required":false,"schema":{"type":"integer","default":0,"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnterpriseUserCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnterpriseUserResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenant/enterprise-users/{customer_id}":{"get":{"tags":["Tenant / Sandbox"],"summary":"List Enterprise Users","description":"List all users for an enterprise customer.","operationId":"list_enterprise_users_api_v1_tenant_enterprise_users__customer_id__get","parameters":[{"name":"customer_id","in":"path","required":true,"schema":{"type":"string","title":"Customer Id"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"type":"integer","default":0,"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/EnterpriseUserResponse"},"title":"Response List Enterprise Users Api V1 Tenant Enterprise Users  Customer Id  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenant/enterprise-users/login":{"post":{"tags":["Tenant / Sandbox"],"summary":"Enterprise User Login","description":"Authenticate an enterprise customer user and return JWT.","operationId":"enterprise_user_login_api_v1_tenant_enterprise_users_login_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserLogin"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Enterprise User Login Api V1 Tenant Enterprise Users Login Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenant/enterprise-users/{user_id}":{"patch":{"tags":["Tenant / Sandbox"],"summary":"Update Enterprise User","description":"Update an enterprise user's name, role, or department.","operationId":"update_enterprise_user_api_v1_tenant_enterprise_users__user_id__patch","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"integer","title":"User Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Update Enterprise User Api V1 Tenant Enterprise Users  User Id  Patch"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenant/enterprise-users/{user_id}/deactivate":{"patch":{"tags":["Tenant / Sandbox"],"summary":"Deactivate Enterprise User","description":"Deactivate an enterprise user.","operationId":"deactivate_enterprise_user_api_v1_tenant_enterprise_users__user_id__deactivate_patch","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"integer","title":"User Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Deactivate Enterprise User Api V1 Tenant Enterprise Users  User Id  Deactivate Patch"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenant/enterprise-users/{user_id}/reset-password":{"post":{"tags":["Tenant / Sandbox"],"summary":"Reset Enterprise Password","description":"Reset an enterprise user's password.","operationId":"reset_enterprise_password_api_v1_tenant_enterprise_users__user_id__reset_password_post","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"integer","title":"User Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Reset Enterprise Password Api V1 Tenant Enterprise Users  User Id  Reset Password Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenant/gateway-configs/{tenant_id}":{"get":{"tags":["Tenant / Sandbox"],"summary":"List Gateway Configs","description":"List all gateway configs for a tenant (credentials redacted).","operationId":"list_gateway_configs_api_v1_tenant_gateway_configs__tenant_id__get","parameters":[{"name":"tenant_id","in":"path","required":true,"schema":{"type":"integer","title":"Tenant Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","additionalProperties":true},"title":"Response List Gateway Configs Api V1 Tenant Gateway Configs  Tenant Id  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Tenant / Sandbox"],"summary":"Upsert Gateway Config","description":"Create or update a gateway config for a tenant.\n\nuse_platform=true: tenant uses Signal AI Labs' account (billed via SaaS).\nuse_platform=false: tenant provides their own provider + config credentials.","operationId":"upsert_gateway_config_api_v1_tenant_gateway_configs__tenant_id__put","parameters":[{"name":"tenant_id","in":"path","required":true,"schema":{"type":"integer","title":"Tenant Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GatewayConfigCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Upsert Gateway Config Api V1 Tenant Gateway Configs  Tenant Id  Put"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenant/gateway-configs/{tenant_id}/{gateway_type}":{"delete":{"tags":["Tenant / Sandbox"],"summary":"Delete Gateway Config","description":"Remove a tenant's gateway config (reverts to platform default).","operationId":"delete_gateway_config_api_v1_tenant_gateway_configs__tenant_id___gateway_type__delete","parameters":[{"name":"tenant_id","in":"path","required":true,"schema":{"type":"integer","title":"Tenant Id"}},{"name":"gateway_type","in":"path","required":true,"schema":{"type":"string","title":"Gateway Type"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Delete Gateway Config Api V1 Tenant Gateway Configs  Tenant Id   Gateway Type  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/audit":{"get":{"tags":["SIG-AUD — Audit Trail"],"summary":"List Audit Entries","description":"List audit entries with flexible filters and pagination.","operationId":"list_audit_entries_api_v1_audit_get","parameters":[{"name":"actor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Actor"}},{"name":"actor_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Actor Type"}},{"name":"action","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Action"}},{"name":"entity_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Type"}},{"name":"entity_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Id"}},{"name":"module","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Module"}},{"name":"severity","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Severity"}},{"name":"date_from","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Date From"}},{"name":"date_to","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Date To"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Page Size"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuditListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["SIG-AUD — Audit Trail"],"summary":"Create Audit Entry","description":"Manually log an audit entry (for external integrations).","operationId":"create_audit_entry_api_v1_audit_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuditEntryCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuditEntryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/audit/entity/{entity_type}/{entity_id}":{"get":{"tags":["SIG-AUD — Audit Trail"],"summary":"Get Entity History","description":"All audit entries for a specific entity.","operationId":"get_entity_history_api_v1_audit_entity__entity_type___entity_id__get","parameters":[{"name":"entity_type","in":"path","required":true,"schema":{"type":"string","title":"Entity Type"}},{"name":"entity_id","in":"path","required":true,"schema":{"type":"string","title":"Entity Id"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Page Size"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuditListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/audit/actor/{actor}":{"get":{"tags":["SIG-AUD — Audit Trail"],"summary":"Get Actor History","description":"All actions performed by a specific actor.","operationId":"get_actor_history_api_v1_audit_actor__actor__get","parameters":[{"name":"actor","in":"path","required":true,"schema":{"type":"string","title":"Actor"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Page Size"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuditListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/audit/stats":{"get":{"tags":["SIG-AUD — Audit Trail"],"summary":"Get Audit Stats","description":"Aggregate action counts for a time period.","operationId":"get_audit_stats_api_v1_audit_stats_get","parameters":[{"name":"date_from","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Date From"}},{"name":"date_to","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Date To"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuditStatsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/notifications/templates":{"post":{"tags":["SIG-NTF — Notifications"],"summary":"Create Template","operationId":"create_template_api_v1_notifications_templates_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TemplateCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TemplateResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["SIG-NTF — Notifications"],"summary":"List Templates","operationId":"list_templates_api_v1_notifications_templates_get","parameters":[{"name":"channel","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Channel"}},{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"}},{"name":"is_active","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Page Size"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TemplateListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/notifications/templates/{template_id}":{"get":{"tags":["SIG-NTF — Notifications"],"summary":"Get Template","operationId":"get_template_api_v1_notifications_templates__template_id__get","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"integer","title":"Template Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TemplateResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["SIG-NTF — Notifications"],"summary":"Update Template","operationId":"update_template_api_v1_notifications_templates__template_id__patch","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"integer","title":"Template Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TemplateUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TemplateResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/notifications/send":{"post":{"tags":["SIG-NTF — Notifications"],"summary":"Send Notification","operationId":"send_notification_api_v1_notifications_send_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendNotificationRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/notifications/send-bulk":{"post":{"tags":["SIG-NTF — Notifications"],"summary":"Send Bulk","operationId":"send_bulk_api_v1_notifications_send_bulk_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkSendRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkSendResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/notifications/history":{"get":{"tags":["SIG-NTF — Notifications"],"summary":"Notification History","operationId":"notification_history_api_v1_notifications_history_get","parameters":[{"name":"customer_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Customer Id"}},{"name":"channel","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Channel"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Page Size"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/notifications/{notification_id}":{"get":{"tags":["SIG-NTF — Notifications"],"summary":"Get Notification","operationId":"get_notification_api_v1_notifications__notification_id__get","parameters":[{"name":"notification_id","in":"path","required":true,"schema":{"type":"integer","title":"Notification Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/notifications/retry-failed":{"post":{"tags":["SIG-NTF — Notifications"],"summary":"Retry Failed","operationId":"retry_failed_api_v1_notifications_retry_failed_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/notifications/{notification_id}/delivered":{"post":{"tags":["SIG-NTF — Notifications"],"summary":"Mark Delivered","operationId":"mark_delivered_api_v1_notifications__notification_id__delivered_post","parameters":[{"name":"notification_id","in":"path","required":true,"schema":{"type":"integer","title":"Notification Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarkDeliveredRequest","default":{}}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/notifications/{notification_id}/failed":{"post":{"tags":["SIG-NTF — Notifications"],"summary":"Mark Failed","operationId":"mark_failed_api_v1_notifications__notification_id__failed_post","parameters":[{"name":"notification_id","in":"path","required":true,"schema":{"type":"integer","title":"Notification Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarkFailedRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/notifications/preferences/{customer_id}":{"get":{"tags":["SIG-NTF — Notifications"],"summary":"Get Preferences","operationId":"get_preferences_api_v1_notifications_preferences__customer_id__get","parameters":[{"name":"customer_id","in":"path","required":true,"schema":{"type":"string","title":"Customer Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreferenceListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["SIG-NTF — Notifications"],"summary":"Update Preferences","operationId":"update_preferences_api_v1_notifications_preferences__customer_id__put","parameters":[{"name":"customer_id","in":"path","required":true,"schema":{"type":"string","title":"Customer Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreferenceBulkUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreferenceListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/analytics/metrics":{"post":{"tags":["SIG-ANL — Analytics & Dashboards"],"summary":"Record Metric","description":"Record (upsert) a metric value.  Automatically snapshots the previous value.","operationId":"record_metric_api_v1_analytics_metrics_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MetricCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MetricWithTrend"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["SIG-ANL — Analytics & Dashboards"],"summary":"List Metrics","description":"List all metrics for the tenant with optional filters.","operationId":"list_metrics_api_v1_analytics_metrics_get","parameters":[{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/MetricCategory"},{"type":"null"}],"title":"Category"}},{"name":"period","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/MetricPeriod"},{"type":"null"}],"title":"Period"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Page Size"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MetricListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/analytics/metrics/{metric_name}":{"get":{"tags":["SIG-ANL — Analytics & Dashboards"],"summary":"Get Metric","description":"Get current value and trend for a single metric.","operationId":"get_metric_api_v1_analytics_metrics__metric_name__get","parameters":[{"name":"metric_name","in":"path","required":true,"schema":{"type":"string","title":"Metric Name"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MetricWithTrend"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["SIG-ANL — Analytics & Dashboards"],"summary":"Update Metric","description":"Update the value of an existing metric (records new snapshot).","operationId":"update_metric_api_v1_analytics_metrics__metric_name__put","parameters":[{"name":"metric_name","in":"path","required":true,"schema":{"type":"string","title":"Metric Name"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MetricUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MetricWithTrend"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/analytics/metrics/{metric_name}/history":{"get":{"tags":["SIG-ANL — Analytics & Dashboards"],"summary":"Get Metric History","description":"Return time-series snapshots for a specific metric.","operationId":"get_metric_history_api_v1_analytics_metrics__metric_name__history_get","parameters":[{"name":"metric_name","in":"path","required":true,"schema":{"type":"string","title":"Metric Name"}},{"name":"date_from","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Date From"}},{"name":"date_to","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Date To"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"default":100,"title":"Limit"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MetricHistoryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/analytics/trends":{"get":{"tags":["SIG-ANL — Analytics & Dashboards"],"summary":"Calculate Trends","description":"Compare current vs previous values for all metrics.  Returns trend data.","operationId":"calculate_trends_api_v1_analytics_trends_get","parameters":[{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/MetricCategory"},{"type":"null"}],"title":"Category"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","additionalProperties":true},"title":"Response Calculate Trends Api V1 Analytics Trends Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/analytics/dashboards":{"post":{"tags":["SIG-ANL — Analytics & Dashboards"],"summary":"Create Dashboard","description":"Create a new dashboard.","operationId":"create_dashboard_api_v1_analytics_dashboards_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DashboardCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DashboardResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["SIG-ANL — Analytics & Dashboards"],"summary":"List Dashboards","description":"List all dashboards for the tenant.","operationId":"list_dashboards_api_v1_analytics_dashboards_get","parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Page Size"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DashboardListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/analytics/dashboards/{slug}":{"get":{"tags":["SIG-ANL — Analytics & Dashboards"],"summary":"Get Dashboard","description":"Fetch a single dashboard by slug.","operationId":"get_dashboard_api_v1_analytics_dashboards__slug__get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DashboardResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/analytics/dashboards/{dashboard_id}":{"put":{"tags":["SIG-ANL — Analytics & Dashboards"],"summary":"Update Dashboard","description":"Update an existing dashboard.","operationId":"update_dashboard_api_v1_analytics_dashboards__dashboard_id__put","parameters":[{"name":"dashboard_id","in":"path","required":true,"schema":{"type":"integer","title":"Dashboard Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DashboardUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DashboardResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["SIG-ANL — Analytics & Dashboards"],"summary":"Delete Dashboard","description":"Delete a dashboard.","operationId":"delete_dashboard_api_v1_analytics_dashboards__dashboard_id__delete","parameters":[{"name":"dashboard_id","in":"path","required":true,"schema":{"type":"integer","title":"Dashboard Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/analytics/dashboards/{slug}/data":{"get":{"tags":["SIG-ANL — Analytics & Dashboards"],"summary":"Get Dashboard Data","description":"Resolve a dashboard layout into actual metric data for rendering.","operationId":"get_dashboard_data_api_v1_analytics_dashboards__slug__data_get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DashboardDataResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/analytics/kpis":{"get":{"tags":["SIG-ANL — Analytics & Dashboards"],"summary":"Compute Kpis","description":"Compute cross-vertical KPIs from recorded metrics.","operationId":"compute_kpis_api_v1_analytics_kpis_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/KPIResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/analytics/export":{"get":{"tags":["SIG-ANL — Analytics & Dashboards"],"summary":"Export Metrics","description":"Export metrics and snapshot history as CSV or JSON for BI tools.","operationId":"export_metrics_api_v1_analytics_export_get","parameters":[{"name":"format","in":"query","required":false,"schema":{"$ref":"#/components/schemas/ExportFormat","default":"json"}},{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/MetricCategory"},{"type":"null"}],"title":"Category"}},{"name":"metric_names","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Comma-separated metric names","title":"Metric Names"},"description":"Comma-separated metric names"},{"name":"date_from","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Date From"}},{"name":"date_to","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Date To"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/reports/definitions":{"post":{"tags":["SIG-RPT — Reporting & BI"],"summary":"Create Report Definition","description":"Create a new report definition.","operationId":"create_report_definition_api_v1_reports_definitions_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportDefinitionCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportDefinitionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["SIG-RPT — Reporting & BI"],"summary":"List Report Definitions","description":"List report definitions with optional filters.","operationId":"list_report_definitions_api_v1_reports_definitions_get","parameters":[{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"}},{"name":"is_active","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Page Size"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportDefinitionListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/reports/definitions/{report_id}":{"get":{"tags":["SIG-RPT — Reporting & BI"],"summary":"Get Report Definition","description":"Get a report definition by ID.","operationId":"get_report_definition_api_v1_reports_definitions__report_id__get","parameters":[{"name":"report_id","in":"path","required":true,"schema":{"type":"integer","title":"Report Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportDefinitionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["SIG-RPT — Reporting & BI"],"summary":"Update Report Definition","description":"Update a report definition.","operationId":"update_report_definition_api_v1_reports_definitions__report_id__patch","parameters":[{"name":"report_id","in":"path","required":true,"schema":{"type":"integer","title":"Report Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportDefinitionUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportDefinitionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["SIG-RPT — Reporting & BI"],"summary":"Delete Report Definition","description":"Delete a report definition and all its runs.","operationId":"delete_report_definition_api_v1_reports_definitions__report_id__delete","parameters":[{"name":"report_id","in":"path","required":true,"schema":{"type":"integer","title":"Report Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/reports/definitions/{report_id}/run":{"post":{"tags":["SIG-RPT — Reporting & BI"],"summary":"Run Report","description":"Execute a report on-demand and return the run record.","operationId":"run_report_api_v1_reports_definitions__report_id__run_post","parameters":[{"name":"report_id","in":"path","required":true,"schema":{"type":"integer","title":"Report Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/RunReportRequest"},{"type":"null"}],"title":"Body"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportRunResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/reports/definitions/{report_id}/runs":{"get":{"tags":["SIG-RPT — Reporting & BI"],"summary":"List Report Runs","description":"List execution history for a report.","operationId":"list_report_runs_api_v1_reports_definitions__report_id__runs_get","parameters":[{"name":"report_id","in":"path","required":true,"schema":{"type":"integer","title":"Report Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Page Size"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportRunListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/reports/runs/{run_id}":{"get":{"tags":["SIG-RPT — Reporting & BI"],"summary":"Get Report Run","description":"Get details of a specific report run.","operationId":"get_report_run_api_v1_reports_runs__run_id__get","parameters":[{"name":"run_id","in":"path","required":true,"schema":{"type":"integer","title":"Run Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportRunResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/reports/definitions/{report_id}/schedule":{"post":{"tags":["SIG-RPT — Reporting & BI"],"summary":"Schedule Report","description":"Set or update the schedule for a report.","operationId":"schedule_report_api_v1_reports_definitions__report_id__schedule_post","parameters":[{"name":"report_id","in":"path","required":true,"schema":{"type":"integer","title":"Report Id"}},{"name":"cron_expression","in":"query","required":true,"schema":{"type":"string","description":"Cron expression, e.g. \"0 6 1 * *\"","title":"Cron Expression"},"description":"Cron expression, e.g. \"0 6 1 * *\""},{"name":"recipients","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"JSON array of emails","title":"Recipients"},"description":"JSON array of emails"},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportDefinitionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/reports/predefined/{report_name}":{"get":{"tags":["SIG-RPT — Reporting & BI"],"summary":"Run Predefined Report","description":"Execute a predefined (canned) report by name.","operationId":"run_predefined_report_api_v1_reports_predefined__report_name__get","parameters":[{"name":"report_name","in":"path","required":true,"schema":{"$ref":"#/components/schemas/PredefinedReport"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PredefinedReportResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/reports/bi-connections":{"post":{"tags":["SIG-RPT — Reporting & BI"],"summary":"Create Bi Connection","description":"Register a new BI tool connection.","operationId":"create_bi_connection_api_v1_reports_bi_connections_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BIConnectionCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BIConnectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["SIG-RPT — Reporting & BI"],"summary":"List Bi Connections","description":"List BI connections with optional filters.","operationId":"list_bi_connections_api_v1_reports_bi_connections_get","parameters":[{"name":"platform","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Platform"}},{"name":"is_active","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Page Size"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BIConnectionListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/reports/bi-connections/{connection_id}":{"get":{"tags":["SIG-RPT — Reporting & BI"],"summary":"Get Bi Connection","description":"Get a BI connection by ID.","operationId":"get_bi_connection_api_v1_reports_bi_connections__connection_id__get","parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"integer","title":"Connection Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BIConnectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["SIG-RPT — Reporting & BI"],"summary":"Update Bi Connection","description":"Update a BI connection.","operationId":"update_bi_connection_api_v1_reports_bi_connections__connection_id__patch","parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"integer","title":"Connection Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BIConnectionUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BIConnectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["SIG-RPT — Reporting & BI"],"summary":"Delete Bi Connection","description":"Delete a BI connection.","operationId":"delete_bi_connection_api_v1_reports_bi_connections__connection_id__delete","parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"integer","title":"Connection Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/reports/bi-connections/{connection_id}/embed":{"get":{"tags":["SIG-RPT — Reporting & BI"],"summary":"Get Embed Config","description":"Get the resolved embed configuration for a BI connection.\n\nReturns the embed URL and platform-specific parameters needed\nby the frontend to render an embedded dashboard.","operationId":"get_embed_config_api_v1_reports_bi_connections__connection_id__embed_get","parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"integer","title":"Connection Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmbedConfigResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/reports/bi-connections/export":{"post":{"tags":["SIG-RPT — Reporting & BI"],"summary":"Export Data For Bi","description":"Export raw data tables as CSV/JSON for BI tool import.\n\nOnly whitelisted tables are allowed.  Results are tenant-scoped\nand optionally filtered by date range.","operationId":"export_data_for_bi_api_v1_reports_bi_connections_export_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DataExportRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/DataExportResponse"},"title":"Response Export Data For Bi Api V1 Reports Bi Connections Export Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/ai/models":{"post":{"tags":["SIG-AI — AI & Intelligence"],"summary":"Create Model","description":"Create a new AI/ML model definition.","operationId":"create_model_api_v1_ai_models_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PredictionModelCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PredictionModelResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["SIG-AI — AI & Intelligence"],"summary":"List Models","description":"List AI/ML models with optional filters.","operationId":"list_models_api_v1_ai_models_get","parameters":[{"name":"model_type","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/ModelType"},{"type":"null"}],"title":"Model Type"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/ModelStatus"},{"type":"null"}],"title":"Status"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Page Size"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PredictionModelListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/ai/models/{model_id}":{"get":{"tags":["SIG-AI — AI & Intelligence"],"summary":"Get Model","description":"Get a single AI/ML model by ID.","operationId":"get_model_api_v1_ai_models__model_id__get","parameters":[{"name":"model_id","in":"path","required":true,"schema":{"type":"integer","title":"Model Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PredictionModelResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["SIG-AI — AI & Intelligence"],"summary":"Update Model","description":"Update an existing AI/ML model.","operationId":"update_model_api_v1_ai_models__model_id__put","parameters":[{"name":"model_id","in":"path","required":true,"schema":{"type":"integer","title":"Model Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PredictionModelUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PredictionModelResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["SIG-AI — AI & Intelligence"],"summary":"Delete Model","description":"Delete an AI/ML model and all its predictions.","operationId":"delete_model_api_v1_ai_models__model_id__delete","parameters":[{"name":"model_id","in":"path","required":true,"schema":{"type":"integer","title":"Model Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/ai/predict/churn":{"post":{"tags":["SIG-AI — AI & Intelligence"],"summary":"Predict Churn","description":"Predict churn risk for a customer using heuristic scoring.","operationId":"predict_churn_api_v1_ai_predict_churn_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChurnPredictionRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PredictionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/ai/predict/anomalies":{"post":{"tags":["SIG-AI — AI & Intelligence"],"summary":"Detect Anomalies","description":"Detect anomalies using z-score analysis for the given entity type.","operationId":"detect_anomalies_api_v1_ai_predict_anomalies_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnomalyDetectionRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/PredictionResponse"},"title":"Response Detect Anomalies Api V1 Ai Predict Anomalies Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/ai/predict/demand":{"post":{"tags":["SIG-AI — AI & Intelligence"],"summary":"Forecast Demand","description":"Forecast demand using simple moving average.","operationId":"forecast_demand_api_v1_ai_predict_demand_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemandForecastRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PredictionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/ai/predict/recommendations":{"post":{"tags":["SIG-AI — AI & Intelligence"],"summary":"Generate Recommendations","description":"Generate rule-based recommendations for a customer.","operationId":"generate_recommendations_api_v1_ai_predict_recommendations_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecommendationRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/PredictionResponse"},"title":"Response Generate Recommendations Api V1 Ai Predict Recommendations Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/ai/predict/batch":{"post":{"tags":["SIG-AI — AI & Intelligence"],"summary":"Run Batch Predictions","description":"Run predictions for a batch of entities.","operationId":"run_batch_predictions_api_v1_ai_predict_batch_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchPredictionRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchPredictionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/ai/predictions":{"get":{"tags":["SIG-AI — AI & Intelligence"],"summary":"List Predictions","description":"List prediction results with optional filters.","operationId":"list_predictions_api_v1_ai_predictions_get","parameters":[{"name":"model_id","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Model Id"}},{"name":"entity_type","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/TargetEntity"},{"type":"null"}],"title":"Entity Type"}},{"name":"entity_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Id"}},{"name":"prediction_type","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/PredictionType"},{"type":"null"}],"title":"Prediction Type"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Page Size"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PredictionListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/ai/insights/generate":{"post":{"tags":["SIG-AI — AI & Intelligence"],"summary":"Generate Insights","description":"Scan data and generate actionable insights.","operationId":"generate_insights_api_v1_ai_insights_generate_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/InsightResponse"},"title":"Response Generate Insights Api V1 Ai Insights Generate Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/ai/insights":{"get":{"tags":["SIG-AI — AI & Intelligence"],"summary":"List Insights","description":"List insights with optional filters.","operationId":"list_insights_api_v1_ai_insights_get","parameters":[{"name":"insight_type","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/InsightType"},{"type":"null"}],"title":"Insight Type"}},{"name":"severity","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/sigcore__core__ai__schemas__Severity"},{"type":"null"}],"title":"Severity"}},{"name":"is_read","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Read"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Page Size"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InsightListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/ai/insights/mark-read":{"post":{"tags":["SIG-AI — AI & Intelligence"],"summary":"Mark Insights Read","description":"Mark one or more insights as read.","operationId":"mark_insights_read_api_v1_ai_insights_mark_read_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InsightMarkRead"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Mark Insights Read Api V1 Ai Insights Mark Read Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/ai/insights/mark-actioned":{"post":{"tags":["SIG-AI — AI & Intelligence"],"summary":"Mark Insights Actioned","description":"Mark one or more insights as actioned (also marks as read).","operationId":"mark_insights_actioned_api_v1_ai_insights_mark_actioned_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InsightMarkActioned"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Mark Insights Actioned Api V1 Ai Insights Mark Actioned Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/ai/chat":{"post":{"tags":["SIG-AI — AI & Intelligence"],"summary":"Ai Chat","description":"AI-powered chat assistant — answers billing, usage, plan, and account queries.","operationId":"ai_chat_api_v1_ai_chat_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChatRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChatResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/platform-faq":{"get":{"tags":["SIG-FAQ — Knowledge Base"],"summary":"List Platform Faqs","description":"List platform FAQ entries. Searchable by keyword and filterable by category.","operationId":"list_platform_faqs_api_v1_platform_faq_get","parameters":[{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"}},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/FaqResponse"},"title":"Response List Platform Faqs Api V1 Platform Faq Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["SIG-FAQ — Knowledge Base"],"summary":"Create Platform Faq","description":"Create a platform FAQ entry (Signal AI Labs admin).","operationId":"create_platform_faq_api_v1_platform_faq_post","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FaqCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FaqResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/platform-faq/categories":{"get":{"tags":["SIG-FAQ — Knowledge Base"],"summary":"Platform Faq Categories","description":"List platform FAQ categories with counts.","operationId":"platform_faq_categories_api_v1_platform_faq_categories_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/FaqCategoryCount"},"type":"array","title":"Response Platform Faq Categories Api V1 Platform Faq Categories Get"}}}}}}},"/api/v1/platform-faq/{faq_id}":{"get":{"tags":["SIG-FAQ — Knowledge Base"],"summary":"Get Platform Faq","operationId":"get_platform_faq_api_v1_platform_faq__faq_id__get","parameters":[{"name":"faq_id","in":"path","required":true,"schema":{"type":"integer","title":"Faq Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FaqResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["SIG-FAQ — Knowledge Base"],"summary":"Update Platform Faq","operationId":"update_platform_faq_api_v1_platform_faq__faq_id__patch","parameters":[{"name":"faq_id","in":"path","required":true,"schema":{"type":"integer","title":"Faq Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FaqUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FaqResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["SIG-FAQ — Knowledge Base"],"summary":"Delete Platform Faq","operationId":"delete_platform_faq_api_v1_platform_faq__faq_id__delete","parameters":[{"name":"faq_id","in":"path","required":true,"schema":{"type":"integer","title":"Faq Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Delete Platform Faq Api V1 Platform Faq  Faq Id  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/faq":{"get":{"tags":["SIG-FAQ — Knowledge Base"],"summary":"List Tenant Faqs","description":"List tenant FAQ entries. Searchable and filterable.","operationId":"list_tenant_faqs_api_v1_faq_get","parameters":[{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"}},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/FaqResponse"},"title":"Response List Tenant Faqs Api V1 Faq Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["SIG-FAQ — Knowledge Base"],"summary":"Create Tenant Faq","description":"Create a tenant FAQ entry (operator admin).","operationId":"create_tenant_faq_api_v1_faq_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FaqCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FaqResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/faq/categories":{"get":{"tags":["SIG-FAQ — Knowledge Base"],"summary":"Tenant Faq Categories","description":"List tenant FAQ categories with counts.","operationId":"tenant_faq_categories_api_v1_faq_categories_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/FaqCategoryCount"},"title":"Response Tenant Faq Categories Api V1 Faq Categories Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/faq/{faq_id}":{"get":{"tags":["SIG-FAQ — Knowledge Base"],"summary":"Get Tenant Faq","operationId":"get_tenant_faq_api_v1_faq__faq_id__get","parameters":[{"name":"faq_id","in":"path","required":true,"schema":{"type":"integer","title":"Faq Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FaqResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["SIG-FAQ — Knowledge Base"],"summary":"Update Tenant Faq","operationId":"update_tenant_faq_api_v1_faq__faq_id__patch","parameters":[{"name":"faq_id","in":"path","required":true,"schema":{"type":"integer","title":"Faq Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FaqUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FaqResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["SIG-FAQ — Knowledge Base"],"summary":"Delete Tenant Faq","operationId":"delete_tenant_faq_api_v1_faq__faq_id__delete","parameters":[{"name":"faq_id","in":"path","required":true,"schema":{"type":"integer","title":"Faq Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-tenant-id","in":"header","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"X-Tenant-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Delete Tenant Faq Api V1 Faq  Faq Id  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"ActionCount":{"properties":{"action":{"type":"string","title":"Action"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["action","count"],"title":"ActionCount"},"ActorType":{"type":"string","enum":["user","system","api","webhook"],"title":"ActorType"},"AnomalyDetectionRequest":{"properties":{"entity_type":{"$ref":"#/components/schemas/TargetEntity","default":"device","examples":["device"]}},"type":"object","title":"AnomalyDetectionRequest"},"AuditEntryCreate":{"properties":{"actor":{"type":"string","maxLength":200,"title":"Actor"},"actor_type":{"$ref":"#/components/schemas/ActorType","default":"user"},"action":{"type":"string","maxLength":100,"title":"Action"},"entity_type":{"type":"string","maxLength":50,"title":"Entity Type"},"entity_id":{"type":"string","maxLength":100,"title":"Entity Id"},"module":{"type":"string","maxLength":20,"title":"Module"},"changes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Changes","description":"JSON diff of what changed"},"ip_address":{"anyOf":[{"type":"string","maxLength":45},{"type":"null"}],"title":"Ip Address"},"user_agent":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"User Agent"},"request_id":{"anyOf":[{"type":"string","maxLength":36},{"type":"null"}],"title":"Request Id"},"severity":{"$ref":"#/components/schemas/sigcore__core__audit__schemas__Severity","default":"info"}},"type":"object","required":["actor","action","entity_type","entity_id","module"],"title":"AuditEntryCreate"},"AuditEntryResponse":{"properties":{"id":{"type":"integer","title":"Id"},"tenant_id":{"type":"integer","title":"Tenant Id"},"timestamp":{"type":"string","format":"date-time","title":"Timestamp"},"actor":{"type":"string","title":"Actor"},"actor_type":{"type":"string","title":"Actor Type"},"action":{"type":"string","title":"Action"},"entity_type":{"type":"string","title":"Entity Type"},"entity_id":{"type":"string","title":"Entity Id"},"module":{"type":"string","title":"Module"},"changes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Changes"},"ip_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ip Address"},"user_agent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Agent"},"request_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Request Id"},"severity":{"type":"string","title":"Severity"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","tenant_id","timestamp","actor","actor_type","action","entity_type","entity_id","module","changes","ip_address","user_agent","request_id","severity","created_at"],"title":"AuditEntryResponse"},"AuditListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/AuditEntryResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"page_size":{"type":"integer","title":"Page Size"}},"type":"object","required":["items","total","page","page_size"],"title":"AuditListResponse"},"AuditStatsResponse":{"properties":{"counts":{"items":{"$ref":"#/components/schemas/ActionCount"},"type":"array","title":"Counts"},"total":{"type":"integer","title":"Total"},"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"}},"type":"object","required":["counts","total"],"title":"AuditStatsResponse"},"BIConnectionCreate":{"properties":{"name":{"type":"string","maxLength":100,"title":"Name"},"platform":{"$ref":"#/components/schemas/BIPlatform"},"connection_type":{"$ref":"#/components/schemas/ConnectionType"},"config":{"type":"string","title":"Config","description":"JSON with platform-specific config. PowerBI: {\"workspace_id\": \"...\", \"report_id\": \"...\", \"embed_url\": \"...\"}. Tableau: {\"server\": \"...\", \"site\": \"...\", \"workbook\": \"...\"}. Metabase: {\"url\": \"...\", \"dashboard_id\": 42}"},"is_active":{"type":"boolean","title":"Is Active","default":true}},"type":"object","required":["name","platform","connection_type","config"],"title":"BIConnectionCreate"},"BIConnectionListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/BIConnectionResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"page_size":{"type":"integer","title":"Page Size"}},"type":"object","required":["items","total","page","page_size"],"title":"BIConnectionListResponse"},"BIConnectionResponse":{"properties":{"id":{"type":"integer","title":"Id"},"tenant_id":{"type":"integer","title":"Tenant Id"},"name":{"type":"string","title":"Name"},"platform":{"type":"string","title":"Platform"},"connection_type":{"type":"string","title":"Connection Type"},"config":{"type":"string","title":"Config"},"is_active":{"type":"boolean","title":"Is Active"},"last_synced_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Synced At"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","tenant_id","name","platform","connection_type","config","is_active","last_synced_at","created_at"],"title":"BIConnectionResponse"},"BIConnectionUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Name"},"platform":{"anyOf":[{"$ref":"#/components/schemas/BIPlatform"},{"type":"null"}]},"connection_type":{"anyOf":[{"$ref":"#/components/schemas/ConnectionType"},{"type":"null"}]},"config":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Config"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"BIConnectionUpdate"},"BIPlatform":{"type":"string","enum":["powerbi","tableau","metabase","grafana","superset","custom"],"title":"BIPlatform"},"BatchPredictionRequest":{"properties":{"entity_type":{"$ref":"#/components/schemas/TargetEntity"},"entity_ids":{"items":{"type":"string"},"type":"array","maxItems":100,"minItems":1,"title":"Entity Ids"},"prediction_type":{"$ref":"#/components/schemas/PredictionType"}},"type":"object","required":["entity_type","entity_ids","prediction_type"],"title":"BatchPredictionRequest"},"BatchPredictionResponse":{"properties":{"predictions":{"items":{"$ref":"#/components/schemas/PredictionResponse"},"type":"array","title":"Predictions"},"total":{"type":"integer","title":"Total"},"errors":{"items":{"type":"string"},"type":"array","title":"Errors"}},"type":"object","required":["predictions","total"],"title":"BatchPredictionResponse"},"BulkSendRequest":{"properties":{"template_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Template Id"},"channel":{"$ref":"#/components/schemas/Channel"},"recipients":{"items":{"type":"string"},"type":"array","maxItems":1000,"minItems":1,"title":"Recipients"},"subject":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Subject"},"body":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}],"title":"Body"},"priority":{"$ref":"#/components/schemas/Priority","default":"normal"},"variables":{"additionalProperties":{"type":"string"},"type":"object","title":"Variables"},"reference_type":{"anyOf":[{"$ref":"#/components/schemas/ReferenceType"},{"type":"null"}]},"reference_id":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}],"title":"Reference Id"}},"type":"object","required":["channel","recipients"],"title":"BulkSendRequest"},"BulkSendResponse":{"properties":{"queued":{"type":"integer","title":"Queued"},"notifications":{"items":{"$ref":"#/components/schemas/NotificationResponse"},"type":"array","title":"Notifications"}},"type":"object","required":["queued","notifications"],"title":"BulkSendResponse"},"Category":{"type":"string","enum":["billing","provisioning","support","marketing","system","security"],"title":"Category"},"Channel":{"type":"string","enum":["sms","email","push","ussd","webhook"],"title":"Channel"},"ChatRequest":{"properties":{"customer_id":{"anyOf":[{"type":"string","maxLength":36},{"type":"null"}],"title":"Customer Id"},"message":{"type":"string","maxLength":2000,"minLength":1,"title":"Message"}},"type":"object","required":["message"],"title":"ChatRequest"},"ChatResponse":{"properties":{"reply":{"type":"string","title":"Reply"},"intent":{"type":"string","title":"Intent"},"suggestions":{"items":{"type":"string"},"type":"array","title":"Suggestions","default":[]}},"type":"object","required":["reply","intent"],"title":"ChatResponse"},"ChurnPredictionRequest":{"properties":{"customer_id":{"type":"string","maxLength":100,"title":"Customer Id","examples":["cust-001"]}},"type":"object","required":["customer_id"],"title":"ChurnPredictionRequest"},"ConnectionType":{"type":"string","enum":["embed","api","jdbc","odbc"],"title":"ConnectionType"},"DashboardCreate":{"properties":{"name":{"type":"string","maxLength":100,"title":"Name"},"slug":{"type":"string","maxLength":50,"pattern":"^[a-z0-9][a-z0-9_-]*$","title":"Slug"},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description"},"layout":{"type":"string","title":"Layout","description":"JSON array of widget definitions","default":"[]"},"is_default":{"type":"boolean","title":"Is Default","default":false},"created_by":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Created By"}},"type":"object","required":["name","slug"],"title":"DashboardCreate"},"DashboardDataResponse":{"properties":{"dashboard_id":{"type":"integer","title":"Dashboard Id"},"dashboard_name":{"type":"string","title":"Dashboard Name"},"widgets":{"items":{"$ref":"#/components/schemas/WidgetData"},"type":"array","title":"Widgets"}},"type":"object","required":["dashboard_id","dashboard_name","widgets"],"title":"DashboardDataResponse"},"DashboardListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/DashboardResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"page_size":{"type":"integer","title":"Page Size"}},"type":"object","required":["items","total","page","page_size"],"title":"DashboardListResponse"},"DashboardResponse":{"properties":{"id":{"type":"integer","title":"Id"},"tenant_id":{"type":"integer","title":"Tenant Id"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"layout":{"type":"string","title":"Layout"},"is_default":{"type":"boolean","title":"Is Default"},"created_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","tenant_id","name","slug","description","layout","is_default","created_by","created_at","updated_at"],"title":"DashboardResponse"},"DashboardUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description"},"layout":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Layout","description":"JSON array of widget definitions"},"is_default":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Default"}},"type":"object","title":"DashboardUpdate"},"DataExportRequest":{"properties":{"tables":{"items":{"type":"string"},"type":"array","minItems":1,"title":"Tables","description":"Table names to export, e.g. ['invoices', 'payments']"},"format":{"$ref":"#/components/schemas/OutputFormat","default":"csv"},"date_from":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Date From"},"date_to":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Date To"}},"type":"object","required":["tables"],"title":"DataExportRequest","description":"Request to export raw data tables for BI tool import."},"DataExportResponse":{"properties":{"table":{"type":"string","title":"Table"},"row_count":{"type":"integer","title":"Row Count"},"file_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"File Reference"},"data":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Data","description":"Inline data (small exports)"}},"type":"object","required":["table","row_count"],"title":"DataExportResponse"},"DemandForecastRequest":{"properties":{"target_id":{"type":"string","maxLength":100,"title":"Target Id","description":"Commodity ID or plan ID to forecast demand for","examples":["plan-basic-100"]}},"type":"object","required":["target_id"],"title":"DemandForecastRequest"},"EmbedConfigResponse":{"properties":{"connection_id":{"type":"integer","title":"Connection Id"},"platform":{"type":"string","title":"Platform"},"embed_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Embed Url"},"config":{"additionalProperties":true,"type":"object","title":"Config"},"is_active":{"type":"boolean","title":"Is Active"}},"type":"object","required":["connection_id","platform","config","is_active"],"title":"EmbedConfigResponse","description":"Resolved embed configuration for a BI connection."},"EnterpriseUserCreate":{"properties":{"customer_id":{"type":"string","maxLength":36,"title":"Customer Id"},"email":{"type":"string","title":"Email"},"password":{"type":"string","title":"Password"},"name":{"type":"string","title":"Name"},"role":{"type":"string","title":"Role","default":"viewer"},"department":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Department"},"can_manage_sims":{"type":"boolean","title":"Can Manage Sims","default":false},"can_view_billing":{"type":"boolean","title":"Can View Billing","default":true},"can_create_users":{"type":"boolean","title":"Can Create Users","default":false}},"type":"object","required":["customer_id","email","password","name"],"title":"EnterpriseUserCreate"},"EnterpriseUserResponse":{"properties":{"id":{"type":"integer","title":"Id"},"tenant_id":{"type":"integer","title":"Tenant Id"},"customer_id":{"type":"string","title":"Customer Id"},"email":{"type":"string","title":"Email"},"name":{"type":"string","title":"Name"},"role":{"type":"string","title":"Role"},"department":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Department"},"can_manage_sims":{"type":"boolean","title":"Can Manage Sims"},"can_view_billing":{"type":"boolean","title":"Can View Billing"},"can_create_users":{"type":"boolean","title":"Can Create Users"},"is_active":{"type":"boolean","title":"Is Active"},"created_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","tenant_id","customer_id","email","name","role","department","can_manage_sims","can_view_billing","can_create_users","is_active","created_by","created_at"],"title":"EnterpriseUserResponse"},"ExportFormat":{"type":"string","enum":["csv","json"],"title":"ExportFormat"},"FaqCategoryCount":{"properties":{"category":{"type":"string","title":"Category"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["category","count"],"title":"FaqCategoryCount"},"FaqCreate":{"properties":{"category":{"type":"string","title":"Category"},"question":{"type":"string","title":"Question"},"answer":{"type":"string","title":"Answer"},"tags":{"type":"string","title":"Tags","default":""},"sort_order":{"type":"integer","title":"Sort Order","default":0},"is_published":{"type":"boolean","title":"Is Published","default":true}},"type":"object","required":["category","question","answer"],"title":"FaqCreate"},"FaqResponse":{"properties":{"id":{"type":"integer","title":"Id"},"category":{"type":"string","title":"Category"},"question":{"type":"string","title":"Question"},"answer":{"type":"string","title":"Answer"},"tags":{"type":"string","title":"Tags"},"sort_order":{"type":"integer","title":"Sort Order"},"is_published":{"type":"boolean","title":"Is Published"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","category","question","answer","tags","sort_order","is_published","created_at","updated_at"],"title":"FaqResponse"},"FaqUpdate":{"properties":{"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"question":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Question"},"answer":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Answer"},"tags":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tags"},"sort_order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Sort Order"},"is_published":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Published"}},"type":"object","title":"FaqUpdate"},"GatewayConfigCreate":{"properties":{"gateway_type":{"type":"string","title":"Gateway Type"},"use_platform":{"type":"boolean","title":"Use Platform","default":true},"provider":{"type":"string","title":"Provider","default":""},"config":{"additionalProperties":true,"type":"object","title":"Config","default":{}}},"type":"object","required":["gateway_type"],"title":"GatewayConfigCreate"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"InsightListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/InsightResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"page_size":{"type":"integer","title":"Page Size"}},"type":"object","required":["items","total","page","page_size"],"title":"InsightListResponse"},"InsightMarkActioned":{"properties":{"insight_ids":{"items":{"type":"integer"},"type":"array","minItems":1,"title":"Insight Ids"}},"type":"object","required":["insight_ids"],"title":"InsightMarkActioned"},"InsightMarkRead":{"properties":{"insight_ids":{"items":{"type":"integer"},"type":"array","minItems":1,"title":"Insight Ids"}},"type":"object","required":["insight_ids"],"title":"InsightMarkRead"},"InsightResponse":{"properties":{"id":{"type":"integer","title":"Id"},"tenant_id":{"type":"integer","title":"Tenant Id"},"insight_type":{"type":"string","title":"Insight Type"},"title":{"type":"string","title":"Title"},"description":{"type":"string","title":"Description"},"severity":{"type":"string","title":"Severity"},"entity_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Type"},"entity_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Id"},"data":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Data"},"is_read":{"type":"boolean","title":"Is Read"},"is_actioned":{"type":"boolean","title":"Is Actioned"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","tenant_id","insight_type","title","description","severity","entity_type","entity_id","data","is_read","is_actioned","created_at"],"title":"InsightResponse"},"InsightType":{"type":"string","enum":["trend","anomaly","recommendation","alert","forecast"],"title":"InsightType"},"KPIResponse":{"properties":{"total_customers":{"type":"integer","title":"Total Customers","default":0},"new_customers_this_month":{"type":"integer","title":"New Customers This Month","default":0},"active_subscriptions":{"type":"integer","title":"Active Subscriptions","default":0},"churn_rate":{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$","title":"Churn Rate","default":"0.0000"},"monthly_revenue":{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$","title":"Monthly Revenue","default":"0.0000"},"outstanding_invoices":{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$","title":"Outstanding Invoices","default":"0.0000"},"computed_at":{"type":"string","format":"date-time","title":"Computed At"}},"type":"object","required":["computed_at"],"title":"KPIResponse"},"MarkDeliveredRequest":{"properties":{"provider_message_id":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Provider Message Id"}},"type":"object","title":"MarkDeliveredRequest"},"MarkFailedRequest":{"properties":{"failure_reason":{"type":"string","maxLength":500,"title":"Failure Reason"}},"type":"object","required":["failure_reason"],"title":"MarkFailedRequest"},"MetricCategory":{"type":"string","enum":["customers","revenue","operations","network","marketplace"],"title":"MetricCategory"},"MetricCreate":{"properties":{"name":{"type":"string","maxLength":100,"title":"Name","examples":["total_customers"]},"category":{"$ref":"#/components/schemas/MetricCategory"},"value":{"anyOf":[{"type":"number"},{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*(?:\\d{0,11}|(?=[\\d.]{1,16}0*$)\\d{0,11}\\.\\d{0,4}0*$)"}],"title":"Value"},"previous_value":{"anyOf":[{"type":"number"},{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*(?:\\d{0,11}|(?=[\\d.]{1,16}0*$)\\d{0,11}\\.\\d{0,4}0*$)"},{"type":"null"}],"title":"Previous Value"},"unit":{"$ref":"#/components/schemas/MetricUnit"},"currency":{"anyOf":[{"type":"string","maxLength":3},{"type":"null"}],"title":"Currency","examples":["USD"]},"period":{"$ref":"#/components/schemas/MetricPeriod"}},"type":"object","required":["name","category","value","unit","period"],"title":"MetricCreate"},"MetricHistoryResponse":{"properties":{"metric_name":{"type":"string","title":"Metric Name"},"snapshots":{"items":{"$ref":"#/components/schemas/SnapshotResponse"},"type":"array","title":"Snapshots"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["metric_name","snapshots","total"],"title":"MetricHistoryResponse"},"MetricListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/MetricWithTrend"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"page_size":{"type":"integer","title":"Page Size"}},"type":"object","required":["items","total","page","page_size"],"title":"MetricListResponse"},"MetricPeriod":{"type":"string","enum":["realtime","daily","weekly","monthly","quarterly","annual"],"title":"MetricPeriod"},"MetricUnit":{"type":"string","enum":["count","currency","percent","bytes","minutes"],"title":"MetricUnit"},"MetricUpdate":{"properties":{"value":{"anyOf":[{"type":"number"},{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*(?:\\d{0,11}|(?=[\\d.]{1,16}0*$)\\d{0,11}\\.\\d{0,4}0*$)"}],"title":"Value"},"currency":{"anyOf":[{"type":"string","maxLength":3},{"type":"null"}],"title":"Currency"},"period":{"anyOf":[{"$ref":"#/components/schemas/MetricPeriod"},{"type":"null"}]}},"type":"object","required":["value"],"title":"MetricUpdate"},"MetricWithTrend":{"properties":{"id":{"type":"integer","title":"Id"},"tenant_id":{"type":"integer","title":"Tenant Id"},"name":{"type":"string","title":"Name"},"category":{"type":"string","title":"Category"},"value":{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$","title":"Value"},"previous_value":{"anyOf":[{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$"},{"type":"null"}],"title":"Previous Value"},"unit":{"type":"string","title":"Unit"},"currency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Currency"},"period":{"type":"string","title":"Period"},"recorded_at":{"type":"string","format":"date-time","title":"Recorded At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"trend_percent":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Trend Percent","description":"Percentage change vs previous value"},"trend_direction":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trend Direction","description":"up, down, or flat"}},"type":"object","required":["id","tenant_id","name","category","value","previous_value","unit","currency","period","recorded_at","created_at"],"title":"MetricWithTrend"},"ModelStatus":{"type":"string","enum":["draft","training","active","deprecated"],"title":"ModelStatus"},"ModelType":{"type":"string","enum":["churn_prediction","demand_forecast","anomaly_detection","recommendation","classification","regression"],"title":"ModelType"},"NotificationListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/NotificationResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"page_size":{"type":"integer","title":"Page Size"}},"type":"object","required":["items","total","page","page_size"],"title":"NotificationListResponse"},"NotificationResponse":{"properties":{"id":{"type":"integer","title":"Id"},"tenant_id":{"type":"integer","title":"Tenant Id"},"customer_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Customer Id"},"template_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Template Id"},"channel":{"type":"string","title":"Channel"},"recipient":{"type":"string","title":"Recipient"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"body":{"type":"string","title":"Body"},"status":{"type":"string","title":"Status"},"priority":{"type":"string","title":"Priority"},"sent_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Sent At"},"delivered_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Delivered At"},"failed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Failed At"},"failure_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Failure Reason"},"retry_count":{"type":"integer","title":"Retry Count"},"max_retries":{"type":"integer","title":"Max Retries"},"reference_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Type"},"reference_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Id"},"provider_message_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider Message Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","tenant_id","customer_id","template_id","channel","recipient","subject","body","status","priority","sent_at","delivered_at","failed_at","failure_reason","retry_count","max_retries","reference_type","reference_id","provider_message_id","created_at"],"title":"NotificationResponse"},"OutputFormat":{"type":"string","enum":["json","csv","pdf","xlsx"],"title":"OutputFormat"},"PredefinedReport":{"type":"string","enum":["monthly_revenue_by_customer","outstanding_invoices","subscription_summary","usage_summary","payment_summary","collection_aging","tax_summary"],"title":"PredefinedReport"},"PredefinedReportResponse":{"properties":{"report_name":{"type":"string","title":"Report Name"},"generated_at":{"type":"string","format":"date-time","title":"Generated At"},"row_count":{"type":"integer","title":"Row Count"},"data":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Data"}},"type":"object","required":["report_name","generated_at","row_count","data"],"title":"PredefinedReportResponse"},"PredictionListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/PredictionResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"page_size":{"type":"integer","title":"Page Size"}},"type":"object","required":["items","total","page","page_size"],"title":"PredictionListResponse"},"PredictionModelCreate":{"properties":{"name":{"type":"string","maxLength":100,"title":"Name","examples":["churn_predictor"]},"model_type":{"$ref":"#/components/schemas/ModelType"},"target_entity":{"$ref":"#/components/schemas/TargetEntity"},"status":{"$ref":"#/components/schemas/ModelStatus","default":"draft"},"config":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Config","description":"JSON model configuration (thresholds, features, parameters)","examples":["{\"threshold\": 0.7, \"features\": [\"days_since_payment\", \"ticket_count\"]}"]},"accuracy":{"anyOf":[{"type":"number"},{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*(?:\\d{0,3}|(?=[\\d.]{1,6}0*$)\\d{0,3}\\.\\d{0,2}0*$)"},{"type":"null"}],"title":"Accuracy"},"training_data_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Training Data Count"}},"type":"object","required":["name","model_type","target_entity"],"title":"PredictionModelCreate"},"PredictionModelListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/PredictionModelResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"page_size":{"type":"integer","title":"Page Size"}},"type":"object","required":["items","total","page","page_size"],"title":"PredictionModelListResponse"},"PredictionModelResponse":{"properties":{"id":{"type":"integer","title":"Id"},"tenant_id":{"type":"integer","title":"Tenant Id"},"name":{"type":"string","title":"Name"},"model_type":{"type":"string","title":"Model Type"},"target_entity":{"type":"string","title":"Target Entity"},"status":{"type":"string","title":"Status"},"config":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Config"},"accuracy":{"anyOf":[{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$"},{"type":"null"}],"title":"Accuracy"},"last_trained_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Trained At"},"training_data_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Training Data Count"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","tenant_id","name","model_type","target_entity","status","config","accuracy","last_trained_at","training_data_count","created_at","updated_at"],"title":"PredictionModelResponse"},"PredictionModelUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Name"},"model_type":{"anyOf":[{"$ref":"#/components/schemas/ModelType"},{"type":"null"}]},"target_entity":{"anyOf":[{"$ref":"#/components/schemas/TargetEntity"},{"type":"null"}]},"status":{"anyOf":[{"$ref":"#/components/schemas/ModelStatus"},{"type":"null"}]},"config":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Config"},"accuracy":{"anyOf":[{"type":"number"},{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*(?:\\d{0,3}|(?=[\\d.]{1,6}0*$)\\d{0,3}\\.\\d{0,2}0*$)"},{"type":"null"}],"title":"Accuracy"},"training_data_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Training Data Count"}},"type":"object","title":"PredictionModelUpdate"},"PredictionResponse":{"properties":{"id":{"type":"integer","title":"Id"},"tenant_id":{"type":"integer","title":"Tenant Id"},"model_id":{"type":"integer","title":"Model Id"},"entity_type":{"type":"string","title":"Entity Type"},"entity_id":{"type":"string","title":"Entity Id"},"prediction_type":{"type":"string","title":"Prediction Type"},"score":{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$","title":"Score"},"label":{"type":"string","title":"Label"},"confidence":{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$","title":"Confidence"},"explanation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Explanation"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","tenant_id","model_id","entity_type","entity_id","prediction_type","score","label","confidence","explanation","expires_at","created_at"],"title":"PredictionResponse"},"PredictionType":{"type":"string","enum":["churn_risk","demand_level","anomaly_score","recommendation","forecast"],"title":"PredictionType"},"PreferenceBulkUpdate":{"properties":{"preferences":{"items":{"$ref":"#/components/schemas/PreferenceUpdate"},"type":"array","minItems":1,"title":"Preferences"}},"type":"object","required":["preferences"],"title":"PreferenceBulkUpdate"},"PreferenceChannel":{"type":"string","enum":["sms","email","push"],"title":"PreferenceChannel","description":"Channels that support customer opt-in/out preferences."},"PreferenceListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/PreferenceResponse"},"type":"array","title":"Items"}},"type":"object","required":["items"],"title":"PreferenceListResponse"},"PreferenceResponse":{"properties":{"id":{"type":"integer","title":"Id"},"tenant_id":{"type":"integer","title":"Tenant Id"},"customer_id":{"type":"string","title":"Customer Id"},"channel":{"type":"string","title":"Channel"},"enabled":{"type":"boolean","title":"Enabled"}},"type":"object","required":["id","tenant_id","customer_id","channel","enabled"],"title":"PreferenceResponse"},"PreferenceUpdate":{"properties":{"channel":{"$ref":"#/components/schemas/PreferenceChannel"},"enabled":{"type":"boolean","title":"Enabled"}},"type":"object","required":["channel","enabled"],"title":"PreferenceUpdate"},"Priority":{"type":"string","enum":["low","normal","high","critical"],"title":"Priority"},"QueryType":{"type":"string","enum":["sql","aggregation","predefined"],"title":"QueryType"},"RecommendationRequest":{"properties":{"customer_id":{"type":"string","maxLength":100,"title":"Customer Id","examples":["cust-001"]}},"type":"object","required":["customer_id"],"title":"RecommendationRequest"},"ReferenceType":{"type":"string","enum":["invoice","payment","ticket","subscription","system"],"title":"ReferenceType"},"ReportCategory":{"type":"string","enum":["financial","operational","regulatory","custom"],"title":"ReportCategory"},"ReportDefinitionCreate":{"properties":{"name":{"type":"string","maxLength":200,"title":"Name"},"slug":{"type":"string","maxLength":50,"title":"Slug"},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description"},"category":{"$ref":"#/components/schemas/ReportCategory"},"query_type":{"$ref":"#/components/schemas/QueryType"},"query_config":{"type":"string","title":"Query Config","description":"JSON defining data extraction. Aggregation: {\"source\": \"invoices\", \"filters\": {...}, \"group_by\": \"...\", \"aggregate\": \"sum:total_amount\", \"date_range\": \"this_month\"}. Predefined: {\"report\": \"monthly_revenue_by_customer\"}. SQL (admin): {\"sql\": \"SELECT ...\"}"},"output_format":{"$ref":"#/components/schemas/OutputFormat","default":"json"},"schedule":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Schedule","description":"Cron expression, e.g. \"0 6 1 * *\" (1st of month at 6 AM)"},"recipients":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipients","description":"JSON array of email addresses, e.g. [\"a@b.com\"]"},"is_active":{"type":"boolean","title":"Is Active","default":true},"created_by":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Created By"}},"type":"object","required":["name","slug","category","query_type","query_config"],"title":"ReportDefinitionCreate"},"ReportDefinitionListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ReportDefinitionResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"page_size":{"type":"integer","title":"Page Size"}},"type":"object","required":["items","total","page","page_size"],"title":"ReportDefinitionListResponse"},"ReportDefinitionResponse":{"properties":{"id":{"type":"integer","title":"Id"},"tenant_id":{"type":"integer","title":"Tenant Id"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"category":{"type":"string","title":"Category"},"query_type":{"type":"string","title":"Query Type"},"query_config":{"type":"string","title":"Query Config"},"output_format":{"type":"string","title":"Output Format"},"schedule":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Schedule"},"recipients":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipients"},"is_active":{"type":"boolean","title":"Is Active"},"last_run_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Run At"},"created_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","tenant_id","name","slug","description","category","query_type","query_config","output_format","schedule","recipients","is_active","last_run_at","created_by","created_at","updated_at"],"title":"ReportDefinitionResponse"},"ReportDefinitionUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Name"},"slug":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Slug"},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description"},"category":{"anyOf":[{"$ref":"#/components/schemas/ReportCategory"},{"type":"null"}]},"query_type":{"anyOf":[{"$ref":"#/components/schemas/QueryType"},{"type":"null"}]},"query_config":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Query Config"},"output_format":{"anyOf":[{"$ref":"#/components/schemas/OutputFormat"},{"type":"null"}]},"schedule":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Schedule"},"recipients":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipients"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"ReportDefinitionUpdate"},"ReportRunListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ReportRunResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"page_size":{"type":"integer","title":"Page Size"}},"type":"object","required":["items","total","page","page_size"],"title":"ReportRunListResponse"},"ReportRunResponse":{"properties":{"id":{"type":"integer","title":"Id"},"tenant_id":{"type":"integer","title":"Tenant Id"},"report_id":{"type":"integer","title":"Report Id"},"run_number":{"type":"integer","title":"Run Number"},"status":{"type":"string","title":"Status"},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"},"row_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Row Count"},"file_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"File Reference"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message"},"parameters":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parameters"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","tenant_id","report_id","run_number","status","started_at","completed_at","row_count","file_reference","error_message","parameters","created_at"],"title":"ReportRunResponse"},"RunReportRequest":{"properties":{"parameters":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parameters","description":"Optional JSON of runtime parameters to override query_config defaults"},"output_format":{"anyOf":[{"$ref":"#/components/schemas/OutputFormat"},{"type":"null"}],"description":"Override the report's default output format for this run"}},"type":"object","title":"RunReportRequest","description":"Parameters for an on-demand report execution."},"SendNotificationRequest":{"properties":{"customer_id":{"anyOf":[{"type":"string","maxLength":36},{"type":"null"}],"title":"Customer Id"},"template_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Template Id"},"channel":{"$ref":"#/components/schemas/Channel"},"recipient":{"type":"string","maxLength":300,"title":"Recipient"},"subject":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Subject"},"body":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}],"title":"Body"},"priority":{"$ref":"#/components/schemas/Priority","default":"normal"},"variables":{"additionalProperties":{"type":"string"},"type":"object","title":"Variables"},"reference_type":{"anyOf":[{"$ref":"#/components/schemas/ReferenceType"},{"type":"null"}]},"reference_id":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}],"title":"Reference Id"}},"type":"object","required":["channel","recipient"],"title":"SendNotificationRequest"},"SnapshotResponse":{"properties":{"id":{"type":"integer","title":"Id"},"tenant_id":{"type":"integer","title":"Tenant Id"},"metric_name":{"type":"string","title":"Metric Name"},"value":{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$","title":"Value"},"period":{"type":"string","title":"Period"},"snapshot_date":{"type":"string","format":"date-time","title":"Snapshot Date"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","tenant_id","metric_name","value","period","snapshot_date","created_at"],"title":"SnapshotResponse"},"TargetEntity":{"type":"string","enum":["customer","subscription","device","listing","transaction"],"title":"TargetEntity"},"TemplateCreate":{"properties":{"name":{"type":"string","maxLength":200,"title":"Name"},"slug":{"type":"string","maxLength":200,"title":"Slug"},"channel":{"$ref":"#/components/schemas/Channel"},"subject":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Subject"},"body":{"type":"string","minLength":1,"title":"Body"},"language":{"type":"string","maxLength":5,"title":"Language","default":"en"},"category":{"$ref":"#/components/schemas/Category"},"is_active":{"type":"boolean","title":"Is Active","default":true}},"type":"object","required":["name","slug","channel","body","category"],"title":"TemplateCreate"},"TemplateListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/TemplateResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"page_size":{"type":"integer","title":"Page Size"}},"type":"object","required":["items","total","page","page_size"],"title":"TemplateListResponse"},"TemplateResponse":{"properties":{"id":{"type":"integer","title":"Id"},"tenant_id":{"type":"integer","title":"Tenant Id"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"channel":{"type":"string","title":"Channel"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"body":{"type":"string","title":"Body"},"language":{"type":"string","title":"Language"},"category":{"type":"string","title":"Category"},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","tenant_id","name","slug","channel","subject","body","language","category","is_active","created_at"],"title":"TemplateResponse"},"TemplateUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Name"},"slug":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Slug"},"channel":{"anyOf":[{"$ref":"#/components/schemas/Channel"},{"type":"null"}]},"subject":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Subject"},"body":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}],"title":"Body"},"language":{"anyOf":[{"type":"string","maxLength":5},{"type":"null"}],"title":"Language"},"category":{"anyOf":[{"$ref":"#/components/schemas/Category"},{"type":"null"}]},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"TemplateUpdate"},"TenantConfigUpdate":{"properties":{"vendors_enabled":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Vendors Enabled"},"modules_enabled":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Modules Enabled"},"countries":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Countries"},"customer_id_prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Customer Id Prefix"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"billing_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Billing Email"},"tax_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tax Id"},"bank_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bank Name"},"bank_account":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bank Account"},"invoice_footer":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Invoice Footer"},"invoice_terms":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Invoice Terms"}},"type":"object","title":"TenantConfigUpdate"},"TenantCreate":{"properties":{"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"email":{"type":"string","title":"Email"},"password":{"type":"string","title":"Password"},"country_primary":{"type":"string","title":"Country Primary","default":"RW"},"countries":{"type":"string","title":"Countries","default":"RW"},"customer_id_prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Customer Id Prefix"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"billing_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Billing Email"},"tax_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tax Id"},"bank_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bank Name"},"bank_account":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bank Account"},"invoice_footer":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Invoice Footer"},"invoice_terms":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Invoice Terms"}},"type":"object","required":["name","slug","email","password"],"title":"TenantCreate"},"TenantLogin":{"properties":{"email":{"type":"string","title":"Email"},"password":{"type":"string","title":"Password"}},"type":"object","required":["email","password"],"title":"TenantLogin"},"TenantResponse":{"properties":{"id":{"type":"integer","title":"Id"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"email":{"type":"string","title":"Email"},"country_primary":{"type":"string","title":"Country Primary"},"countries":{"type":"string","title":"Countries"},"vendors_enabled":{"type":"string","title":"Vendors Enabled"},"modules_enabled":{"type":"string","title":"Modules Enabled"},"is_active":{"type":"boolean","title":"Is Active"}},"type":"object","required":["id","name","slug","email","country_primary","countries","vendors_enabled","modules_enabled","is_active"],"title":"TenantResponse"},"UserCreate":{"properties":{"email":{"type":"string","title":"Email"},"password":{"type":"string","title":"Password"},"name":{"type":"string","title":"Name"},"role":{"type":"string","title":"Role","default":"P6"}},"type":"object","required":["email","password","name"],"title":"UserCreate"},"UserLogin":{"properties":{"email":{"type":"string","title":"Email"},"password":{"type":"string","title":"Password"}},"type":"object","required":["email","password"],"title":"UserLogin"},"UserResponse":{"properties":{"id":{"type":"integer","title":"Id"},"tenant_id":{"type":"integer","title":"Tenant Id"},"email":{"type":"string","title":"Email"},"name":{"type":"string","title":"Name"},"role":{"type":"string","title":"Role"},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","tenant_id","email","name","role","is_active","created_at"],"title":"UserResponse"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"},"WidgetData":{"properties":{"widget":{"type":"string","title":"Widget"},"metric":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Metric"},"metrics":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Metrics"},"data":{"anyOf":[{"additionalProperties":true,"type":"object"},{"items":{},"type":"array"},{"type":"null"}],"title":"Data"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"}},"type":"object","required":["widget"],"title":"WidgetData"},"sigcore__core__ai__schemas__Severity":{"type":"string","enum":["info","warning","critical"],"title":"Severity"},"sigcore__core__audit__schemas__Severity":{"type":"string","enum":["info","warning","error","critical"],"title":"Severity"}}},"servers":[{"url":"/docs/platform"}]}