{"openapi":"3.1.0","info":{"title":"Esy API","description":"Workflow engine API for esy.com","version":"0.1.0"},"paths":{"/v1/auth/register":{"post":{"tags":["auth"],"summary":"Register","operationId":"post_v1_auth_register","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RegisterRequest"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/auth/login":{"post":{"tags":["auth"],"summary":"Login","operationId":"post_v1_auth_login","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LoginRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/auth/refresh":{"post":{"tags":["auth"],"summary":"Refresh","operationId":"post_v1_auth_refresh","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenResponse"}}}}}}},"/v1/auth/logout":{"post":{"tags":["auth"],"summary":"Logout","operationId":"post_v1_auth_logout","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/v1/api-keys":{"get":{"tags":["api-keys"],"summary":"List Api Keys","operationId":"get_v1_api-keys","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiKeyListResponse"}}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["api-keys"],"summary":"Create Api Key","operationId":"post_v1_api-keys","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateApiKeyRequest"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreatedApiKeyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/api-keys/{key_id}":{"delete":{"tags":["api-keys"],"summary":"Revoke Api Key","operationId":"delete_v1_api-keys_key_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"key_id","in":"path","required":true,"schema":{"type":"string","title":"Key Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiKeyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/users/me":{"get":{"tags":["users"],"summary":"Get Me","operationId":"get_v1_users_me","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserResponse"}}}}},"security":[{"HTTPBearer":[]}]},"delete":{"tags":["users"],"summary":"Delete Me","description":"Ask for this account to be deleted.\n\nNote what this does NOT do: sign you out, or destroy anything. A human\nreviews the request, which can take days, and locking someone out for that\nwhole time would punish them for asking. What does happen immediately is the\npart that should not wait — bank connections revoked at the institution,\nAPI keys killed.\n\nReturns the user so the client can show the pending state without a second\nround trip. Idempotent — asking twice returns the request already in the\nqueue rather than filing a second one.","operationId":"delete_v1_users_me","requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/AccountDeletionRequest"},{"type":"null"}],"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"}}}}},"security":[{"HTTPBearer":[]}]},"patch":{"tags":["users"],"summary":"Update Me","operationId":"patch_v1_users_me","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserUpdateRequest"}}},"required":true},"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"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/users/me/restore":{"post":{"tags":["users"],"summary":"Restore Me","description":"Withdraw a deletion request that has not been reviewed yet.\n\nOnly works while the request is still waiting. Once an operator has approved\nit the purge is scheduled and taking it back is their call — an approval\nthat anyone can overturn is not a review.\n\nBank connections do NOT come back either way: they were revoked at the\ninstitution and cannot be un-revoked from here. You re-link, which is honest\nabout what happened rather than pretending the connection survived.","operationId":"post_v1_users_me_restore","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserResponse"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/workspaces":{"get":{"tags":["workspaces"],"summary":"List Workspaces","operationId":"get_v1_workspaces","security":[{"HTTPBearer":[]}],"parameters":[{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkspaceListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["workspaces"],"summary":"Create Workspace","operationId":"post_v1_workspaces","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkspaceCreateRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkspaceResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/workspaces/{workspace_id}":{"get":{"tags":["workspaces"],"summary":"Get Workspace","operationId":"get_v1_workspaces_workspace_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspace_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Workspace Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkspaceResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/workspaces/{workspace_id}/projects":{"get":{"tags":["workspaces"],"summary":"List Projects","operationId":"get_v1_workspaces_workspace_id_projects","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspace_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Workspace Id"}},{"name":"includeArchived","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Includearchived"}},{"name":"clientId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"A client id, or 'none' for the organization's own brands","title":"Clientid"},"description":"A client id, or 'none' for the organization's own brands"},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["workspaces"],"summary":"Create Project","operationId":"post_v1_workspaces_workspace_id_projects","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspace_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Workspace Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectCreateRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/workspaces/{workspace_id}/projects/{project_id}":{"patch":{"tags":["workspaces"],"summary":"Update Project","operationId":"patch_v1_workspaces_workspace_id_projects_project_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspace_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Workspace Id"}},{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["workspaces"],"summary":"Delete Project","description":"Hard delete. Runs/artifacts that referenced the project fall back to org-level\n(project_id is ON DELETE SET NULL). Prefer PATCH archived=true to preserve\nattribution; delete is for projects created in error.","operationId":"delete_v1_workspaces_workspace_id_projects_project_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspace_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Workspace Id"}},{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["workspaces"],"summary":"Get Project","operationId":"get_v1_workspaces_workspace_id_projects_project_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspace_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Workspace Id"}},{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/brands":{"post":{"tags":["brands"],"summary":"Create Brand","description":"A brand = a project (kind='brand') + its profile row, born together.","operationId":"post_v1_brands","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandCreateRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["brands"],"summary":"List Brands","operationId":"get_v1_brands","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Workspaceid"}},{"name":"includeArchived","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Includearchived"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/brands/{project_id}":{"get":{"tags":["brands"],"summary":"Get Brand","operationId":"get_v1_brands_project_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["brands"],"summary":"Patch Brand","description":"Edit the working copy. Never touches snapshots — publish does that.","operationId":"patch_v1_brands_project_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandProfilePatch"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/brands/{project_id}/import":{"post":{"tags":["brands"],"summary":"Import Brand","description":"Launch compose-brand-profile for this brand. The run produces a\nPROPOSAL artifact; nothing lands on the profile until /profile/confirm.\nOne active import per brand (409) — idempotency for double-clicks.","operationId":"post_v1_brands_project_id_import","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandImportRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/brands/{project_id}/profile/confirm":{"post":{"tags":["brands"],"summary":"Confirm Profile","description":"A human accepts a proposal into the working copy — the propose→confirm\ncontract: nothing an import run wrote is live until someone said so.","operationId":"post_v1_brands_project_id_profile_confirm","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProfileConfirmRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/brands/{project_id}/profile/publish":{"post":{"tags":["brands"],"summary":"Publish Profile","description":"Snapshot the working copy into an immutable knowledge artifact and\npoint current_snapshot_id at it. Idempotent: an unchanged profile returns\nthe standing snapshot instead of minting a twin (content-hash compare).\n\nAlso the ONE moment the brand's font is captured: the first family in\nvisual.fonts is resolved against the Google Fonts catalog, stored in R2,\nand recorded on the snapshot — renders read the pinned asset, never the\nnetwork. A font failure logs and moves on; it never blocks a publish.","operationId":"post_v1_brands_project_id_profile_publish","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SnapshotResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/campaigns":{"post":{"tags":["campaigns"],"summary":"Create Campaign","description":"Create a campaign under a brand, pinning the brand's CURRENT published\nsnapshot. A brand that has never published has no context to pin — 422\nwith the action that fixes it, not a mystery.","operationId":"post_v1_campaigns","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignCreateRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["campaigns"],"summary":"List Campaigns","operationId":"get_v1_campaigns","security":[{"HTTPBearer":[]}],"parameters":[{"name":"projectId","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Projectid"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"includeArchived","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Includearchived"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/campaigns/{campaign_id}":{"get":{"tags":["campaigns"],"summary":"Get Campaign","operationId":"get_v1_campaigns_campaign_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"string","title":"Campaign Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["campaigns"],"summary":"Patch Campaign","description":"Brief edits are a DRAFT-only right: once a campaign is submitted or\nproducing, the brief is what the work answers to — changing it under a\nrunning production would orphan the outputs' provenance. 409 names the\nstate.","operationId":"patch_v1_campaigns_campaign_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"string","title":"Campaign Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignPatchRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/campaigns/{campaign_id}/submit":{"post":{"tags":["campaigns"],"summary":"Submit Campaign","description":"Managed mode's handoff: the brief becomes a Task in the operator's\nqueue plus an Inbox doorbell. Idempotent — resubmitting a submitted\ncampaign returns it unchanged (double-clicks, retried requests).","operationId":"post_v1_campaigns_campaign_id_submit","security":[{"HTTPBearer":[]}],"parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"string","title":"Campaign Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/campaigns/{campaign_id}/request":{"get":{"tags":["campaigns"],"summary":"Managed Request Status","description":"The customer-safe projection of the managed request: five states in\nMake's words, plus any operator notes addressed to this campaign.","operationId":"get_v1_campaigns_campaign_id_request","security":[{"HTTPBearer":[]}],"parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"string","title":"Campaign Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ManagedRequestStatus"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/campaigns/{campaign_id}/archive":{"post":{"tags":["campaigns"],"summary":"Archive Campaign","description":"Soft archive, project-style: hidden from default lists, provenance\nkept. Idempotent.","operationId":"post_v1_campaigns_campaign_id_archive","security":[{"HTTPBearer":[]}],"parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"string","title":"Campaign Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/productions":{"post":{"tags":["productions"],"summary":"Create Production","operationId":"post_v1_productions","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductionCreateRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["productions"],"summary":"List Productions","operationId":"get_v1_productions","security":[{"HTTPBearer":[]}],"parameters":[{"name":"campaignId","in":"query","required":true,"schema":{"type":"string","title":"Campaignid"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductionListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/productions/{production_id}/start":{"post":{"tags":["productions"],"summary":"Start","description":"Launch the planning wave. The budget gate inside run creation can 402\nhere — before any provider spend. Only a draft starts (409 otherwise), so\na double-click cannot mint a second planning run.","operationId":"post_v1_productions_production_id_start","security":[{"HTTPBearer":[]}],"parameters":[{"name":"production_id","in":"path","required":true,"schema":{"type":"string","title":"Production Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/productions/{production_id}":{"get":{"tags":["productions"],"summary":"Get Production","operationId":"get_v1_productions_production_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"production_id","in":"path","required":true,"schema":{"type":"string","title":"Production Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/productions/{production_id}/cancel":{"post":{"tags":["productions"],"summary":"Cancel Production","description":"Cancel the production and every non-terminal run it owns (the same\nstamp-and-let-the-engine-unwind mechanics as run cancel: the DB status IS\nthe signal; in-flight steps notice at their next boundary). Idempotent —\ncancelling a terminal production returns it unchanged.","operationId":"post_v1_productions_production_id_cancel","security":[{"HTTPBearer":[]}],"parameters":[{"name":"production_id","in":"path","required":true,"schema":{"type":"string","title":"Production Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/productions/{production_id}/events":{"get":{"tags":["productions"],"summary":"Stream Production Events","operationId":"get_v1_productions_production_id_events","parameters":[{"name":"production_id","in":"path","required":true,"schema":{"type":"string","title":"Production Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/productions/{production_id}/revisions":{"post":{"tags":["productions"],"summary":"Create Production Revision","description":"Executes a request_changes (or rejected/failed) decision: a fresh run\nof the same deliverable, attached under the original's role. The finished\nartifact is stamped as the next version of the one it supersedes.","operationId":"post_v1_productions_production_id_revisions","security":[{"HTTPBearer":[]}],"parameters":[{"name":"production_id","in":"path","required":true,"schema":{"type":"string","title":"Production Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RevisionRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/workflows":{"get":{"tags":["workflows"],"summary":"List Workflows","operationId":"get_v1_workflows","security":[{"HTTPBearer":[]}],"parameters":[{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}},{"name":"visibility","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"null"}],"title":"Visibility"}},{"name":"includeDeprecated","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Includedeprecated"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkflowListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["workflows"],"summary":"Create Workflow","operationId":"post_v1_workflows","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkflowCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkflowResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/workflows/{workflow_id}":{"get":{"tags":["workflows"],"summary":"Get Workflow","operationId":"get_v1_workflows_workflow_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workflow_id","in":"path","required":true,"schema":{"type":"string","title":"Workflow Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkflowResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["workflows"],"summary":"Update Workflow","operationId":"patch_v1_workflows_workflow_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workflow_id","in":"path","required":true,"schema":{"type":"string","title":"Workflow Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkflowUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkflowResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/workflows/estimate":{"post":{"tags":["workflows"],"summary":"Estimate Workflow Cost","description":"Dry-run cost estimate for a draft template. Powers the Factory\ncost-analysis panel and is reused by the budget pre-check. subWorkflow steps\nresolve their child template's cost from the DB.","operationId":"post_v1_workflows_estimate","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EstimateRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CostEstimateResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/workflows/dry-run":{"post":{"tags":["workflows"],"summary":"Dry Run Workflow Template","description":"Resolve + validate a draft template against a sample intake without any\nprovider call. Surfaces resolved prompts, unresolved/forward `{path}`\nreferences, sub-workflow resolution, and the cost estimate — the publish-time\nsafety net behind the Factory \"Test\" button.","operationId":"post_v1_workflows_dry-run","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DryRunRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__dry_run__DryRunResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/workflows/{workflow_id}/versions":{"get":{"tags":["workflows"],"summary":"List Workflow Versions","description":"Immutable version history for a template, newest first. The version the\n`canonical_version_id` pointer targets is flagged `isCanonical`.","operationId":"get_v1_workflows_workflow_id_versions","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workflow_id","in":"path","required":true,"schema":{"type":"string","title":"Workflow Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkflowVersionListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/catalog/workflows":{"get":{"tags":["catalog"],"summary":"Get Catalog Workflows","description":"List the public platform workflow templates. The publish ladder's top rung\n(``visibility == \"public\"``) is the single inclusion rule; ``owner_id IS NULL``\nis kept as defense-in-depth so only system-owned templates can ever be public,\nand internal/draft templates never leak onto the marketing site.","operationId":"get_v1_catalog_workflows","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CatalogResponse"}}}}}}},"/v1/catalog/workflows/{workflow_id}":{"get":{"tags":["catalog"],"summary":"Get Catalog Workflow Contract","description":"The public contract of one template — the payload behind\nesy.com/workflows/<id>/contract. Same inclusion rule as the list\n(public + system-owned), EXCEPT deprecated templates are served here\nwith their supersededById so retired public URLs can redirect instead\nof 404ing.","operationId":"get_v1_catalog_workflows_workflow_id","parameters":[{"name":"workflow_id","in":"path","required":true,"schema":{"type":"string","title":"Workflow Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CatalogContract"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/models":{"get":{"tags":["models"],"summary":"Get Models","operationId":"get_v1_models","security":[{"HTTPBearer":[]}],"parameters":[{"name":"capability","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by capability: text | image | video | tool","title":"Capability"},"description":"Filter by capability: text | image | video | tool"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ModelListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/tools":{"get":{"tags":["tools"],"summary":"Get Tools","description":"List executable workflow tools with their typed contracts for Factory.","operationId":"get_v1_tools","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ToolListResponse"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/ai/completions":{"post":{"tags":["ai"],"summary":"Create Completion","operationId":"post_v1_ai_completions","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompletionRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/copilot/factory/turns":{"post":{"tags":["copilot"],"summary":"Create Factory Turn","operationId":"post_v1_copilot_factory_turns","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CopilotTurnRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/runs/events":{"get":{"tags":["runs"],"summary":"Stream Runs Firehose","operationId":"get_v1_runs_events","parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/runs/{run_id}/events":{"get":{"tags":["runs"],"summary":"Stream Run Events","operationId":"get_v1_runs_run_id_events","parameters":[{"name":"run_id","in":"path","required":true,"schema":{"type":"string","title":"Run Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/runs":{"get":{"tags":["runs"],"summary":"List Runs","operationId":"get_v1_runs","security":[{"HTTPBearer":[]}],"parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"parentOrderId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parentorderid"}},{"name":"workerId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Workerid"}},{"name":"includeArchived","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Includearchived"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["runs"],"summary":"Create Run","operationId":"post_v1_runs","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateRunRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/runs/{run_id}":{"get":{"tags":["runs"],"summary":"Get Run","operationId":"get_v1_runs_run_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"run_id","in":"path","required":true,"schema":{"type":"string","title":"Run Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/runs/{run_id}/cancel":{"post":{"tags":["runs"],"summary":"Cancel Run","description":"Cancel a run (and its non-terminal sub-workflow children).\n\nThe DB status IS the cancel signal: this stamps ``cancelled`` terminally,\nand the engine re-reads status at every step boundary and aborts — an\nin-flight step finishes within its timeout budget and is discarded. A run\nwith no live executor (orphaned ``running``) is finalized here directly.\nIdempotent: cancelling an already-terminal run returns it unchanged.","operationId":"post_v1_runs_run_id_cancel","security":[{"HTTPBearer":[]}],"parameters":[{"name":"run_id","in":"path","required":true,"schema":{"type":"string","title":"Run Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/runs/{run_id}/finalize":{"post":{"tags":["runs"],"summary":"Finalize Run","description":"Finalize a limbo run whose steps all completed but whose finalization\nnever ran (a process death between the last step and the paperwork — the\n2026-08-01 deploy stranded 42 such runs). The work is already paid for:\nre-execution replays every completed step from its snapshot (engine\nsnapshot-resume), so finalizing costs zero new provider calls.\n\nEligible: a non-completed run whose snapshot shows EVERY step completed\nwith recorded outputs. Cancelled runs are eligible — cancelling a limbo\nrun was the operator flailing at a stuck UI, and finalize is the operator\nexplicitly asking for the finished work back.","operationId":"post_v1_runs_run_id_finalize","security":[{"HTTPBearer":[]}],"parameters":[{"name":"run_id","in":"path","required":true,"schema":{"type":"string","title":"Run Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/runs/{run_id}/archive":{"post":{"tags":["runs"],"summary":"Archive Run","description":"Clear a terminal run from lists. Archive, never delete: the run keeps\nits cost ledger, frozen spec, and artifacts, and can be listed back with\nincludeArchived=true. Terminal-only (clearing active work would hide a\nlive executor); cascades to the run's terminal children so the whole\nsub-workflow tree clears together. Idempotent.","operationId":"post_v1_runs_run_id_archive","security":[{"HTTPBearer":[]}],"parameters":[{"name":"run_id","in":"path","required":true,"schema":{"type":"string","title":"Run Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/runs/{run_id}/project":{"patch":{"tags":["runs"],"summary":"Reassign Run Project","description":"Move a run to a different project (or to org-level when projectId is null).\n\nReassignment is within the run's existing workspace only. Because costs.py\nbuckets by Run.project_id at query time, changing it here re-buckets the run's\nwhole cost ledger automatically; we additionally cascade the new project onto\nthe run's artifact(s) and any sub-workflow child runs (and their artifacts) so\nproject-scoped views stay consistent.","operationId":"patch_v1_runs_run_id_project","security":[{"HTTPBearer":[]}],"parameters":[{"name":"run_id","in":"path","required":true,"schema":{"type":"string","title":"Run Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReassignRunProjectRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/orders":{"post":{"tags":["orders"],"summary":"Create Order","operationId":"post_v1_orders","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerationOrderCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerationOrderResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["orders"],"summary":"List Orders","operationId":"get_v1_orders","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"planArtifactId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Planartifactid"}},{"name":"collectionId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Collectionid"}},{"name":"hasCollection","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Hascollection"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerationOrderListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/orders/{order_id}/start":{"post":{"tags":["orders"],"summary":"Start Order","description":"Kick off execution of a `planned` order. Re-checks the budget against the\nwhole-order estimate, flips the order to `running` (committed so it's immediately\nvisible), then hands the planned children to the bounded order executor.","operationId":"post_v1_orders_order_id_start","security":[{"HTTPBearer":[]}],"parameters":[{"name":"order_id","in":"path","required":true,"schema":{"type":"string","title":"Order Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerationOrderResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/orders/{order_id}/cancel":{"post":{"tags":["orders"],"summary":"Cancel Order","description":"Cancel a `planned` or `running` order.\n\nPlanned: nothing has executed, so cancellation is pure bookkeeping — the\norder and every still-planned child flip to `cancelled` (terminal, $0).\n\nRunning (incident 2026-07-07 follow-up — a stalled order had no manual\nstop): still-planned children flip to `cancelled` and the executor's\nstatus guard refuses them even if they're already queued behind the\nconcurrency semaphore; in-flight children finish (their artifacts still\nland in review) or get reaped. The order goes `cancelled` immediately and\nstays there — late child completions update counts, never status.","operationId":"post_v1_orders_order_id_cancel","security":[{"HTTPBearer":[]}],"parameters":[{"name":"order_id","in":"path","required":true,"schema":{"type":"string","title":"Order Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerationOrderResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/orders/{order_id}/retry-failed":{"post":{"tags":["orders"],"summary":"Retry Failed Children","description":"Re-run an order's failed children as new sibling runs under the SAME\norder (issue #198) — lineage, dedupe keys, and cost roll-ups stay coherent,\nno client-side top-up scripts. Optional per-child intake patches cover the\n#197 shape (a corrected textPolicy). Idempotent per attempt via the ``:rN``\nsibling convention; the order returns to ``running`` and re-finalizes\nthrough the normal executor, so the completeness verdict re-evaluates.","operationId":"post_v1_orders_order_id_retry-failed","security":[{"HTTPBearer":[]}],"parameters":[{"name":"order_id","in":"path","required":true,"schema":{"type":"string","title":"Order Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderRetryFailedRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderRetryFailedResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/orders/backfill-covers":{"post":{"tags":["orders"],"summary":"Backfill Pack Covers","description":"Make covers for finished packs that have none.\n\nA pack with no cover cannot publish, and nothing goes back for it: a shift\nonly touches the orders it creates, and the publish sweep refuses to spend\non its own initiative. This is the authorized exception — an operator\nsaying \"yes, spend up to this much on covers.\"\n\nIt creates the runs and returns immediately. It publishes nothing: the\nexisting sweep notices each pack now qualifies and ships it on its normal\npass, under the same guards as everything else.","operationId":"post_v1_orders_backfill-covers","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CoverBackfillRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CoverBackfillResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/orders/{order_id}/accept-gap":{"post":{"tags":["orders"],"summary":"Accept Order Gap","description":"Settle a short order deliberately: 23 of 25 is what this pack is.\n\nWithout this an order that will never reach its target sits in `attention`\nforever, and the only way to close it is to edit `target_count` down —\nwhich erases the fact that 25 were intended and makes the shortfall\nunauditable. So the count is left alone and the decision is recorded beside\nit: who accepted it, when, why, and exactly which members were dropped.\n\nThe gaps stay `failed`. Nothing is rewritten to look like it succeeded.","operationId":"post_v1_orders_order_id_accept-gap","security":[{"HTTPBearer":[]}],"parameters":[{"name":"order_id","in":"path","required":true,"schema":{"type":"string","title":"Order Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderAcceptGapRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerationOrderResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/orders/{order_id}":{"get":{"tags":["orders"],"summary":"Get Order","operationId":"get_v1_orders_order_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"order_id","in":"path","required":true,"schema":{"type":"string","title":"Order Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerationOrderResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/orders/{order_id}/publish-pack":{"post":{"tags":["orders"],"summary":"Publish Pack","operationId":"post_v1_orders_order_id_publish-pack","security":[{"HTTPBearer":[]}],"parameters":[{"name":"order_id","in":"path","required":true,"schema":{"type":"string","title":"Order Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__generation_order__PackPublishRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackPublishResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/orders/{order_id}/unpublish-pack":{"post":{"tags":["orders"],"summary":"Unpublish Pack","operationId":"post_v1_orders_order_id_unpublish-pack","security":[{"HTTPBearer":[]}],"parameters":[{"name":"order_id","in":"path","required":true,"schema":{"type":"string","title":"Order Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackPublishResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/collections":{"get":{"tags":["collections"],"summary":"List Collections","operationId":"get_v1_collections","security":[{"HTTPBearer":[]}],"parameters":[{"name":"kind","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Kind"}},{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"updatedAfter","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updatedafter"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/packs":{"get":{"tags":["collections"],"summary":"List Packs","operationId":"get_v1_packs","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"format","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Format"}},{"name":"clientRef","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Clientref"}},{"name":"updatedAfter","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updatedafter"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["collections"],"summary":"Create Pack","description":"Create a pack.\n\nCreating twice with the same `clientRef` returns the pack that already\nexists, answering 200 instead of 201 — a client that charged a customer and\nthen lost the response can simply ask again.","operationId":"post_v1_packs","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/packs/{pack_id}":{"get":{"tags":["collections"],"summary":"Get Pack","operationId":"get_v1_packs_pack_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"pack_id","in":"path","required":true,"schema":{"type":"string","title":"Pack Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["collections"],"summary":"Update Pack","operationId":"patch_v1_packs_pack_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"pack_id","in":"path","required":true,"schema":{"type":"string","title":"Pack Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/packs/{pack_id}/items":{"patch":{"tags":["collections"],"summary":"Patch Pack Items","description":"Add, edit, remove, restore and reorder pieces in one change, under one\netag — a board full of edits is one decision, not five races.","operationId":"patch_v1_packs_pack_id_items","security":[{"HTTPBearer":[]}],"parameters":[{"name":"pack_id","in":"path","required":true,"schema":{"type":"string","title":"Pack Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackItemsPatch"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/packs:import":{"post":{"tags":["collections"],"summary":"Import Pack","description":"Write down orders that already ran as a pack.\n\nNothing is redrawn: the plan says what the pack was meant to contain, the\norders say what was actually drawn, and the result becomes a pack whose\npieces have ids from here on. Importing the same work twice returns the\npack that already exists, answering 200 instead of 201.","operationId":"post_v1_packs:import","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackImport"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/packs/{pack_id}:render":{"post":{"tags":["collections"],"summary":"Render Pack","description":"Draw the pack's pieces, or the ones named.\n\nEsy compiles each piece's prompt from the pack's own rules, places the\nwork, and tags every job with the piece it is for — so the finished picture\nlands on that piece however many times the pack is edited meanwhile.","operationId":"post_v1_packs_pack_id:render","security":[{"HTTPBearer":[]}],"parameters":[{"name":"pack_id","in":"path","required":true,"schema":{"type":"string","title":"Pack Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackRenderRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackRenderResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/packs/{pack_id}:makeCover":{"post":{"tags":["collections"],"summary":"Make Pack Cover","description":"Compose the pack's cover from the pieces it actually contains.","operationId":"post_v1_packs_pack_id:makeCover","security":[{"HTTPBearer":[]}],"parameters":[{"name":"pack_id","in":"path","required":true,"schema":{"type":"string","title":"Pack Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackRenderRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackRenderResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/packs/{pack_id}:makeSheet":{"post":{"tags":["collections"],"summary":"Make Pack Sheet","description":"Draw the whole set as one grid — a preview of a pack nobody has bought\nyet. A cell is a preview, never a deliverable.","operationId":"post_v1_packs_pack_id:makeSheet","security":[{"HTTPBearer":[]}],"parameters":[{"name":"pack_id","in":"path","required":true,"schema":{"type":"string","title":"Pack Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackRenderRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackRenderResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/packs/{pack_id}:exportPrint":{"post":{"tags":["collections"],"summary":"Export Pack Print","description":"Make print-size masters of the accepted pieces, from the pictures that\nwere accepted rather than by drawing them again.","operationId":"post_v1_packs_pack_id:exportPrint","security":[{"HTTPBearer":[]}],"parameters":[{"name":"pack_id","in":"path","required":true,"schema":{"type":"string","title":"Pack Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackRenderRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackRenderResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/packs/{pack_id}:publish":{"post":{"tags":["collections"],"summary":"Publish Pack","description":"Send the whole pack to its outlet.\n\nBuilt from the pieces that were accepted, wherever they were drawn — which\nis the difference from publishing one order, whose children are only the\nwork that order did.","operationId":"post_v1_packs_pack_id:publish","security":[{"HTTPBearer":[]}],"parameters":[{"name":"pack_id","in":"path","required":true,"schema":{"type":"string","title":"Pack Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__collection__PackPublishRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackDeliveryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/packs/{pack_id}:unpublish":{"post":{"tags":["collections"],"summary":"Unpublish Pack","description":"Take the pack down, and record that on the pack — so every screen stops\nsaying it is live.","operationId":"post_v1_packs_pack_id:unpublish","security":[{"HTTPBearer":[]}],"parameters":[{"name":"pack_id","in":"path","required":true,"schema":{"type":"string","title":"Pack Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__collection__PackPublishRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackDeliveryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/packs/{pack_id}/items/{item_id}:accept":{"post":{"tags":["collections"],"summary":"Accept Piece","description":"Keep this piece. That decision is what finishes it.","operationId":"post_v1_packs_pack_id_items_item_id:accept","security":[{"HTTPBearer":[]}],"parameters":[{"name":"pack_id","in":"path","required":true,"schema":{"type":"string","title":"Pack Id"}},{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackDecisionRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/packs/{pack_id}/items/{item_id}:reject":{"post":{"tags":["collections"],"summary":"Reject Piece","description":"Turn this piece down. It goes back to waiting to be drawn, and the pack\nstops showing the picture that was turned down.","operationId":"post_v1_packs_pack_id_items_item_id:reject","security":[{"HTTPBearer":[]}],"parameters":[{"name":"pack_id","in":"path","required":true,"schema":{"type":"string","title":"Pack Id"}},{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackDecisionRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/sites":{"get":{"tags":["web pages"],"summary":"List Sites","operationId":"get_v1_sites","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"updatedAfter","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updatedafter"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SiteListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["web pages"],"summary":"Create Site","description":"Create a site for a project, with its header and footer waiting to be\nmade. A retry with the same requestId returns the first answer.","operationId":"post_v1_sites","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SiteCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SiteResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/sites/{site_id}:gatherFacts":{"post":{"tags":["web pages"],"summary":"Gather Facts","description":"Build or refresh the site's business facts (build-business-facts) from\nwhat the client supplies, their website and their Business Profile page.","operationId":"post_v1_sites_site_id:gatherFacts","security":[{"HTTPBearer":[]}],"parameters":[{"name":"site_id","in":"path","required":true,"schema":{"type":"string","title":"Site Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GatherFactsRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActionStarted"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/sites/{site_id}:makeFrame":{"post":{"tags":["web pages"],"summary":"Make Frame","description":"Make the site's design brief, header and footer (generate-site-frame).\n409 until the site has its facts.","operationId":"post_v1_sites_site_id:makeFrame","security":[{"HTTPBearer":[]}],"parameters":[{"name":"site_id","in":"path","required":true,"schema":{"type":"string","title":"Site Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MakeFrameRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActionStarted"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/sites/{site_id}":{"get":{"tags":["web pages"],"summary":"Get Site","operationId":"get_v1_sites_site_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"site_id","in":"path","required":true,"schema":{"type":"string","title":"Site Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SiteResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/pages":{"get":{"tags":["web pages"],"summary":"List Pages","description":"A site's pages, or a project's, or a workspace's.","operationId":"get_v1_pages","security":[{"HTTPBearer":[]}],"parameters":[{"name":"siteId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Siteid"}},{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"format","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Format"}},{"name":"updatedAfter","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updatedafter"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["web pages"],"summary":"Create Page","description":"Create a page: its site, its genre, the search it should win, and how\nvisitors arrive. Nothing is written yet; :plan makes the sections.","operationId":"post_v1_pages","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/pages/{page_id}:plan":{"post":{"tags":["web pages"],"summary":"Plan Page","description":"Plan the page's sections (plan-web-page). When the plan passes the\nframework and the facts, its sections appear in order; when it doesn't,\nthe page goes to attention with the missing facts noted.","operationId":"post_v1_pages_page_id:plan","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page_id","in":"path","required":true,"schema":{"type":"string","title":"Page Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActionRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActionStarted"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/pages/{page_id}:write":{"post":{"tags":["web pages"],"summary":"Write Page","description":"Write every section with no kept version, in parallel, one job each.\nThe page builds on its own once they have all settled.","operationId":"post_v1_pages_page_id:write","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page_id","in":"path","required":true,"schema":{"type":"string","title":"Page Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActionRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActionStarted"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/pages/{page_id}:build":{"post":{"tags":["web pages"],"summary":"Build Page","description":"Assemble and check the page from its kept sections (build-web-page).\n409 while any section has no kept version.","operationId":"post_v1_pages_page_id:build","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page_id","in":"path","required":true,"schema":{"type":"string","title":"Page Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActionRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActionStarted"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/pages/{page_id}/sections/{section_id}:tryMore":{"post":{"tags":["web pages"],"summary":"Try More","description":"Three new versions of this section in three approaches, checked and\nranked. None is kept until someone keeps one (:accept). 409 while locked.","operationId":"post_v1_pages_page_id_sections_section_id:tryMore","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page_id","in":"path","required":true,"schema":{"type":"string","title":"Page Id"}},{"name":"section_id","in":"path","required":true,"schema":{"type":"string","title":"Section Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TryMoreRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TryMoreResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/pages/{page_id}/sections/{section_id}":{"patch":{"tags":["web pages"],"summary":"Edit Section","description":"A person's own edit of the section's words: a new version, marked as\nedited by them and kept at once. The page then needs building again.","operationId":"patch_v1_pages_page_id_sections_section_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page_id","in":"path","required":true,"schema":{"type":"string","title":"Page Id"}},{"name":"section_id","in":"path","required":true,"schema":{"type":"string","title":"Section Id"}},{"name":"if-match","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"If-Match"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SectionEditRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/pages/{page_id}/sections/{section_id}/versions":{"get":{"tags":["web pages"],"summary":"Section Versions","description":"Every version of the section, newest first: each draft, Try 3 more\n(ranked within its batch) and hand edit, with what judged it.","operationId":"get_v1_pages_page_id_sections_section_id_versions","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page_id","in":"path","required":true,"schema":{"type":"string","title":"Page Id"}},{"name":"section_id","in":"path","required":true,"schema":{"type":"string","title":"Section Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SectionVersionsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/pages/{page_id}/sections/{section_id}:lock":{"post":{"tags":["web pages"],"summary":"Lock Section","description":"Protect this section from Try 3 more and rewrites.","operationId":"post_v1_pages_page_id_sections_section_id:lock","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page_id","in":"path","required":true,"schema":{"type":"string","title":"Page Id"}},{"name":"section_id","in":"path","required":true,"schema":{"type":"string","title":"Section Id"}},{"name":"if-match","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"If-Match"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SectionActionRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/pages/{page_id}/sections/{section_id}:unlock":{"post":{"tags":["web pages"],"summary":"Unlock Section","description":"Let this section be rewritten again; it goes back to where it was.","operationId":"post_v1_pages_page_id_sections_section_id:unlock","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page_id","in":"path","required":true,"schema":{"type":"string","title":"Page Id"}},{"name":"section_id","in":"path","required":true,"schema":{"type":"string","title":"Section Id"}},{"name":"if-match","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"If-Match"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SectionActionRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/pages/{page_id}/sections/{section_id}:accept":{"post":{"tags":["web pages"],"summary":"Accept Section","description":"Keep this version of the section, or Restore an older one.","operationId":"post_v1_pages_page_id_sections_section_id:accept","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page_id","in":"path","required":true,"schema":{"type":"string","title":"Page Id"}},{"name":"section_id","in":"path","required":true,"schema":{"type":"string","title":"Section Id"}},{"name":"if-match","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"If-Match"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SectionAcceptRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/pages/{page_id}":{"get":{"tags":["web pages"],"summary":"Get Page","operationId":"get_v1_pages_page_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page_id","in":"path","required":true,"schema":{"type":"string","title":"Page Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["web pages"],"summary":"Update Page","description":"Rename the page, or change the search it should win.","operationId":"patch_v1_pages_page_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page_id","in":"path","required":true,"schema":{"type":"string","title":"Page Id"}},{"name":"if-match","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"If-Match"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/experiments/case-sets":{"post":{"tags":["experiments"],"summary":"Create Case Set","operationId":"post_v1_experiments_case-sets","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CaseSetCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CaseSetResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["experiments"],"summary":"List Case Sets","operationId":"get_v1_experiments_case-sets","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CaseSetListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/experiments/case-sets/{case_set_id}":{"get":{"tags":["experiments"],"summary":"Get Case Set","operationId":"get_v1_experiments_case-sets_case_set_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"case_set_id","in":"path","required":true,"schema":{"type":"string","title":"Case Set Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CaseSetResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/experiments/case-sets/{case_set_id}/versions":{"post":{"tags":["experiments"],"summary":"Create Case Set Version","operationId":"post_v1_experiments_case-sets_case_set_id_versions","security":[{"HTTPBearer":[]}],"parameters":[{"name":"case_set_id","in":"path","required":true,"schema":{"type":"string","title":"Case Set Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CaseSetVersionCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CaseSetVersionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/experiments/case-sets/{case_set_id}/versions/{version}":{"get":{"tags":["experiments"],"summary":"Get Case Set Version","operationId":"get_v1_experiments_case-sets_case_set_id_versions_version","security":[{"HTTPBearer":[]}],"parameters":[{"name":"case_set_id","in":"path","required":true,"schema":{"type":"string","title":"Case Set Id"}},{"name":"version","in":"path","required":true,"schema":{"type":"integer","title":"Version"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CaseSetVersionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/experiments/scorers":{"get":{"tags":["experiments"],"summary":"List Scorers","operationId":"get_v1_experiments_scorers","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/experiments":{"post":{"tags":["experiments"],"summary":"Create Experiment","operationId":"post_v1_experiments","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExperimentCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExperimentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["experiments"],"summary":"List Experiments","operationId":"get_v1_experiments","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"kind","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Kind"}},{"name":"templatesOnly","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Templatesonly"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExperimentListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/experiments/{experiment_id}":{"get":{"tags":["experiments"],"summary":"Get Experiment","operationId":"get_v1_experiments_experiment_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"experiment_id","in":"path","required":true,"schema":{"type":"string","title":"Experiment Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExperimentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["experiments"],"summary":"Update Experiment","operationId":"patch_v1_experiments_experiment_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"experiment_id","in":"path","required":true,"schema":{"type":"string","title":"Experiment Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExperimentUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExperimentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/experiments/{experiment_id}/arms":{"post":{"tags":["experiments"],"summary":"Add Arm","operationId":"post_v1_experiments_experiment_id_arms","security":[{"HTTPBearer":[]}],"parameters":[{"name":"experiment_id","in":"path","required":true,"schema":{"type":"string","title":"Experiment Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ArmCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExperimentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/experiments/{experiment_id}/arms/{arm_key}":{"delete":{"tags":["experiments"],"summary":"Delete Arm","operationId":"delete_v1_experiments_experiment_id_arms_arm_key","security":[{"HTTPBearer":[]}],"parameters":[{"name":"experiment_id","in":"path","required":true,"schema":{"type":"string","title":"Experiment Id"}},{"name":"arm_key","in":"path","required":true,"schema":{"type":"string","title":"Arm Key"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExperimentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/experiments/{experiment_id}/freeze":{"post":{"tags":["experiments"],"summary":"Freeze Experiment","operationId":"post_v1_experiments_experiment_id_freeze","security":[{"HTTPBearer":[]}],"parameters":[{"name":"experiment_id","in":"path","required":true,"schema":{"type":"string","title":"Experiment Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExperimentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/experiments/{experiment_id}/dry-run":{"post":{"tags":["experiments"],"summary":"Dry Run Experiment","operationId":"post_v1_experiments_experiment_id_dry-run","security":[{"HTTPBearer":[]}],"parameters":[{"name":"experiment_id","in":"path","required":true,"schema":{"type":"string","title":"Experiment Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__experiment__DryRunResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/experiments/{experiment_id}/run":{"post":{"tags":["experiments"],"summary":"Run Experiment","operationId":"post_v1_experiments_experiment_id_run","security":[{"HTTPBearer":[]}],"parameters":[{"name":"experiment_id","in":"path","required":true,"schema":{"type":"string","title":"Experiment Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExperimentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/experiments/{experiment_id}/cancel":{"post":{"tags":["experiments"],"summary":"Cancel Experiment","operationId":"post_v1_experiments_experiment_id_cancel","security":[{"HTTPBearer":[]}],"parameters":[{"name":"experiment_id","in":"path","required":true,"schema":{"type":"string","title":"Experiment Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExperimentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/experiments/{experiment_id}/trials":{"get":{"tags":["experiments"],"summary":"List Trials","operationId":"get_v1_experiments_experiment_id_trials","security":[{"HTTPBearer":[]}],"parameters":[{"name":"experiment_id","in":"path","required":true,"schema":{"type":"string","title":"Experiment Id"}},{"name":"armKey","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Armkey"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"default":200,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TrialListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/experiments/{experiment_id}/scores":{"get":{"tags":["experiments"],"summary":"Get Scores","operationId":"get_v1_experiments_experiment_id_scores","security":[{"HTTPBearer":[]}],"parameters":[{"name":"experiment_id","in":"path","required":true,"schema":{"type":"string","title":"Experiment Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScoresResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/experiments/{experiment_id}/rescore":{"post":{"tags":["experiments"],"summary":"Rescore Experiment","operationId":"post_v1_experiments_experiment_id_rescore","security":[{"HTTPBearer":[]}],"parameters":[{"name":"experiment_id","in":"path","required":true,"schema":{"type":"string","title":"Experiment Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RescoreRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RescoreResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/experiments/{experiment_id}/report":{"get":{"tags":["experiments"],"summary":"Get Report","operationId":"get_v1_experiments_experiment_id_report","security":[{"HTTPBearer":[]}],"parameters":[{"name":"experiment_id","in":"path","required":true,"schema":{"type":"string","title":"Experiment Id"}},{"name":"format","in":"query","required":false,"schema":{"type":"string","default":"json","title":"Format"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["experiments"],"summary":"Refile Report","operationId":"post_v1_experiments_experiment_id_report","security":[{"HTTPBearer":[]}],"parameters":[{"name":"experiment_id","in":"path","required":true,"schema":{"type":"string","title":"Experiment Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/queue/count":{"get":{"tags":["queue"],"summary":"Queue Count","description":"Just the pending total — for the side-rail badge and the Overview card,\nwhich showed the number but fetched the whole ~52KB queue to read it. A plain\nCOUNT(*) instead of hydrating + serializing every pending row (perf 2026-07-10).","operationId":"get_v1_queue_count","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"templateId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Templateid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReviewQueueCountResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/queue":{"get":{"tags":["queue"],"summary":"List Queue","description":"List pending human decisions: the caller's runs sitting in ``review``.\n\nThe queue is a read-model — a pending item is a run awaiting its gate, not a\nstored row. Resolving a run (POST /{run_id}/decision) moves it out of ``review``\nso it leaves the queue.","operationId":"get_v1_queue","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"templateId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Templateid"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReviewQueueResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/queue/{run_id}/decision":{"post":{"tags":["queue"],"summary":"Decide","description":"Resolve a run's review gate: record the decision and transition state.\n\napprove -> artifact ``approved``, run ``completed``.\nreject  -> artifact ``rejected``, run ``rejected``.\n\nWrites a ``ReviewDecision`` provenance row (who/when/what/why) keyed by the gate.\nIdempotency: a run not in ``review`` is a 409 — it has already been resolved.","operationId":"post_v1_queue_run_id_decision","security":[{"HTTPBearer":[]}],"parameters":[{"name":"run_id","in":"path","required":true,"schema":{"type":"string","title":"Run Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReviewDecisionRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReviewDecisionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/queue/decisions":{"post":{"tags":["queue"],"summary":"Decide Bulk","description":"Bulk review: the same decide() per item, in order, no cross-item\nrollback — approving nine good outputs is never hostage to one 409. Each\nresult row carries its own status (201 or the error detail).","operationId":"post_v1_queue_decisions","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkDecisionRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkDecisionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/costs":{"get":{"tags":["costs"],"summary":"Cost Summary","description":"Roll up the provider cost ledger by a single dimension.\n\nAggregation happens in SQL (GROUP BY + SUM), so the database returns one row per\nbucket — a handful — instead of every ledger row in scope. The previous version\npulled the whole window's ledger (~100k rows, ~35 MB) into the API process on\nevery call and summed it in Python; with the dashboard refetching this on each\nrun event, one batch day moved >100 GiB out of Neon (2026-08-31 egress alert).","operationId":"get_v1_costs","security":[{"HTTPBearer":[]}],"parameters":[{"name":"groupBy","in":"query","required":false,"schema":{"type":"string","default":"provider","title":"Groupby"}},{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"workflowId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Workflowid"}},{"name":"provider","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"periodGranularity","in":"query","required":false,"schema":{"type":"string","default":"month","title":"Periodgranularity"}},{"name":"from","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"From"}},{"name":"to","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"To"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CostSummaryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/briefs":{"get":{"tags":["briefs"],"summary":"List Briefs","description":"Past briefs, newest first, so a client can show a row of days that\nunfold in place. Default 14, at most 60 a page.","operationId":"get_v1_briefs","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Workspaceid"}},{"name":"period","in":"query","required":false,"schema":{"enum":["daily","weekly"],"type":"string","default":"daily","title":"Period"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":60,"minimum":1,"default":14,"title":"Limit"}},{"name":"pageToken","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pagetoken"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BriefPage"}}}},"400":{"description":"Bad pageToken"},"403":{"description":"Not a member"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["briefs"],"summary":"Compose Brief","description":"Compose a brief now. At most one per workspace per clock hour: a second\nrequest in the same hour returns that hour's brief instead of spending\nanother model call.","operationId":"post_v1_briefs","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BriefCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__planning__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/briefs/latest":{"get":{"tags":["briefs"],"summary":"Latest Brief","description":"The most recent brief of this period filed for the caller in this workspace; 404 when none yet.","operationId":"get_v1_briefs_latest","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Workspaceid"}},{"name":"period","in":"query","required":false,"schema":{"enum":["daily","weekly"],"type":"string","default":"daily","title":"Period"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__planning__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/letter-styles":{"get":{"tags":["letter-styles"],"summary":"List Platform Styles","description":"The platform styles any workspace can choose by key. The first is the default.","operationId":"get_v1_letter-styles","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/LetterStyleSpec"},"type":"array","title":"Response Get V1 Letter-Styles"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/workspaces/{workspace_id}/letter-style":{"get":{"tags":["letter-styles"],"summary":"Get Letter Style","description":"The style this workspace's letters use now, and its etag. A workspace\nthat never chose has the default, at etag \"0\".","operationId":"get_v1_workspaces_workspace_id_letter-style","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspace_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Workspace Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LetterStyleResponse"}}}},"403":{"description":"Not a member, or (on PUT) not an owner or admin"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["letter-styles"],"summary":"Put Letter Style","description":"Choose a platform style (`{\"key\": \"classic\"}`), save a custom spec\n(`{\"spec\": {...}}`), or go back to the default (`{\"key\": \"edition\"}`).","operationId":"put_v1_workspaces_workspace_id_letter-style","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspace_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Workspace Id"}},{"name":"If-Match","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"If-Match"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LetterStylePut"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LetterStyleResponse"}}}},"403":{"description":"Not a member, or (on PUT) not an owner or admin"},"409":{"description":"Stale etag; the body carries the current style and etag"},"422":{"description":"Invalid spec, unknown key, or both/neither of key and spec"},"428":{"description":"No etag was sent"}}}},"/v1/clients/{client_id}":{"get":{"tags":["clients"],"summary":"Get Client","operationId":"get_v1_clients_client_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["clients"],"summary":"Update Client","description":"Change a client. Permission is checked before the etag, so a member\nlearns nothing about the current version (RFC 9110 §13.2).","operationId":"patch_v1_clients_client_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}},{"name":"If-Match","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"If-Match"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientResponse"}}}},"409":{"description":"Stale etag"},"428":{"description":"No etag was sent"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["clients"],"summary":"Archive Client","description":"Archive, never delete: the client's projects, history and payments stay.","operationId":"delete_v1_clients_client_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/clients/{client_id}/events":{"get":{"tags":["clients"],"summary":"Client Events","description":"Every status change, newest first.","operationId":"get_v1_clients_client_id_events","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/StatusEventResponse"},"title":"Response Get V1 Clients Client Id Events"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/clients/{client_id}/contacts":{"get":{"tags":["clients"],"summary":"List Contacts","operationId":"get_v1_clients_client_id_contacts","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ContactResponse"},"title":"Response Get V1 Clients Client Id Contacts"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["clients"],"summary":"Add Contact","operationId":"post_v1_clients_client_id_contacts","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ContactCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ContactResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/clients/{client_id}/contacts/{contact_id}":{"patch":{"tags":["clients"],"summary":"Update Contact","operationId":"patch_v1_clients_client_id_contacts_contact_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}},{"name":"contact_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Contact Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ContactUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ContactResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["clients"],"summary":"Remove Contact","description":"Removed outright: a contact is personal data. The client's history keeps ids, not details.","operationId":"delete_v1_clients_client_id_contacts_contact_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}},{"name":"contact_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Contact Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/workspaces/{workspace_id}/clients":{"get":{"tags":["clients"],"summary":"List Clients","description":"The organization's clients, by name, with this month's roll-ups.","operationId":"get_v1_workspaces_workspace_id_clients","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspace_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Workspace Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string","pattern":"^(lead|active|paused|past)$"},{"type":"null"}],"title":"Status"}},{"name":"includeArchived","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Includearchived"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["clients"],"summary":"Create Client","description":"Add a client. A retry with the same requestId returns the first answer.","operationId":"post_v1_workspaces_workspace_id_clients","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspace_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Workspace Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/characters":{"get":{"tags":["characters"],"summary":"List Characters","description":"A workspace's characters, or one project's. Needs membership.","operationId":"get_v1_characters","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"includeArchived","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Includearchived"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CharacterListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["characters"],"summary":"Create Character","description":"Add a character to a project. A retry with the same requestId returns the first answer.","operationId":"post_v1_characters","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CharacterCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CharacterResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/characters/{character_id}":{"get":{"tags":["characters"],"summary":"Get Character","operationId":"get_v1_characters_character_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"character_id","in":"path","required":true,"schema":{"type":"string","title":"Character Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CharacterResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["characters"],"summary":"Update Character","description":"Rename, or edit the persona draft. Versions are untouched until frozen.","operationId":"patch_v1_characters_character_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"character_id","in":"path","required":true,"schema":{"type":"string","title":"Character Id"}},{"name":"if-match","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"If-Match"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CharacterUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CharacterResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["characters"],"summary":"Archive Character","description":"Archive: no new work features it; everything it made stays.","operationId":"delete_v1_characters_character_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"character_id","in":"path","required":true,"schema":{"type":"string","title":"Character Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/characters/{character_id}/references":{"post":{"tags":["characters"],"summary":"Add Reference","description":"Add a picture (or voice sample) to the draft, by artifact id.","operationId":"post_v1_characters_character_id_references","security":[{"HTTPBearer":[]}],"parameters":[{"name":"character_id","in":"path","required":true,"schema":{"type":"string","title":"Character Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReferenceCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CharacterResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/characters/{character_id}/references/{item_id}":{"delete":{"tags":["characters"],"summary":"Remove Reference","description":"Soft-remove (API-005): frozen versions still name it by id.","operationId":"delete_v1_characters_character_id_references_item_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"character_id","in":"path","required":true,"schema":{"type":"string","title":"Character Id"}},{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CharacterResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/characters/{character_id}/versions":{"get":{"tags":["characters"],"summary":"List Versions","operationId":"get_v1_characters_character_id_versions","security":[{"HTTPBearer":[]}],"parameters":[{"name":"character_id","in":"path","required":true,"schema":{"type":"string","title":"Character Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/VersionResponse"},"title":"Response Get V1 Characters Character Id Versions"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["characters"],"summary":"Freeze Version","description":"Freeze the draft (references + persona) as the next version.\n\nA likeness character names the person it depicts, and keeps naming the\nsame person: a different face is a different character.","operationId":"post_v1_characters_character_id_versions","security":[{"HTTPBearer":[]}],"parameters":[{"name":"character_id","in":"path","required":true,"schema":{"type":"string","title":"Character Id"}},{"name":"if-match","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"If-Match"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VersionCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VersionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/characters/{character_id}/versions/{number}:retire":{"post":{"tags":["characters"],"summary":"Retire Version","description":"No new work on this version; what it made stays valid.","operationId":"post_v1_characters_character_id_versions_number:retire","security":[{"HTTPBearer":[]}],"parameters":[{"name":"character_id","in":"path","required":true,"schema":{"type":"string","title":"Character Id"}},{"name":"number","in":"path","required":true,"schema":{"type":"integer","title":"Number"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VersionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/characters/{character_id}:check":{"post":{"tags":["characters"],"summary":"Check Character","description":"The gate, for a planned use: can this avatar appear here, and if not, why.","operationId":"post_v1_characters_character_id:check","security":[{"HTTPBearer":[]}],"parameters":[{"name":"character_id","in":"path","required":true,"schema":{"type":"string","title":"Character Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CheckRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CheckResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/characters/{character_id}/versions/{number}/bindings":{"post":{"tags":["characters"],"summary":"Add Binding","description":"Record a provider's copy of a version and the provider's consent status.","operationId":"post_v1_characters_character_id_versions_number_bindings","security":[{"HTTPBearer":[]}],"parameters":[{"name":"character_id","in":"path","required":true,"schema":{"type":"string","title":"Character Id"}},{"name":"number","in":"path","required":true,"schema":{"type":"integer","title":"Number"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BindingCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BindingResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/workspaces/{workspace_id}/subjects":{"get":{"tags":["characters"],"summary":"List Subjects","operationId":"get_v1_workspaces_workspace_id_subjects","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspace_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Workspace Id"}},{"name":"includeErased","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Includeerased"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubjectListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["characters"],"summary":"Create Subject","description":"Add a person who will be depicted. The caller attests they are an adult\nand not a political candidate or official; the database refuses otherwise.","operationId":"post_v1_workspaces_workspace_id_subjects","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspace_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Workspace Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubjectCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubjectResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/subjects/{subject_id}":{"get":{"tags":["characters"],"summary":"Get Subject","operationId":"get_v1_subjects_subject_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"subject_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Subject Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubjectResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["characters"],"summary":"Update Subject","operationId":"patch_v1_subjects_subject_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"subject_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Subject Id"}},{"name":"if-match","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"If-Match"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubjectUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubjectResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/subjects/{subject_id}:erase":{"post":{"tags":["characters"],"summary":"Erase Subject","description":"Erase a person: blank what identifies them, revoke every consent, retire\nevery version that depicts them. The consent records stay as the proof\nthat past work was permitted.","operationId":"post_v1_subjects_subject_id:erase","security":[{"HTTPBearer":[]}],"parameters":[{"name":"subject_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Subject Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubjectResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/subjects/{subject_id}/consents":{"post":{"tags":["characters"],"summary":"Record Consent","description":"Record a consent as pending. Nothing can use it until it is activated.","operationId":"post_v1_subjects_subject_id_consents","security":[{"HTTPBearer":[]}],"parameters":[{"name":"subject_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Subject Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConsentCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConsentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/likeness-consents/{consent_id}:activate":{"post":{"tags":["characters"],"summary":"Activate Consent","operationId":"post_v1_likeness-consents_consent_id:activate","security":[{"HTTPBearer":[]}],"parameters":[{"name":"consent_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Consent Id"}},{"name":"if-match","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"If-Match"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConsentAction"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConsentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/likeness-consents/{consent_id}:suspend":{"post":{"tags":["characters"],"summary":"Suspend Consent","operationId":"post_v1_likeness-consents_consent_id:suspend","security":[{"HTTPBearer":[]}],"parameters":[{"name":"consent_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Consent Id"}},{"name":"if-match","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"If-Match"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConsentAction"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConsentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/likeness-consents/{consent_id}:resume":{"post":{"tags":["characters"],"summary":"Resume Consent","operationId":"post_v1_likeness-consents_consent_id:resume","security":[{"HTTPBearer":[]}],"parameters":[{"name":"consent_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Consent Id"}},{"name":"if-match","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"If-Match"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConsentAction"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConsentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/likeness-consents/{consent_id}:revoke":{"post":{"tags":["characters"],"summary":"Revoke Consent","operationId":"post_v1_likeness-consents_consent_id:revoke","security":[{"HTTPBearer":[]}],"parameters":[{"name":"consent_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Consent Id"}},{"name":"if-match","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"If-Match"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConsentAction"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConsentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/likeness-consents/{consent_id}/events":{"get":{"tags":["characters"],"summary":"Consent Events","operationId":"get_v1_likeness-consents_consent_id_events","security":[{"HTTPBearer":[]}],"parameters":[{"name":"consent_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Consent Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ConsentEventResponse"},"title":"Response Get V1 Likeness-Consents Consent Id Events"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/character-bindings/{binding_id}":{"patch":{"tags":["characters"],"summary":"Update Binding","operationId":"patch_v1_character-bindings_binding_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"binding_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Binding Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BindingUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BindingResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/mfa/status":{"get":{"tags":["mfa"],"summary":"Mfa Status","operationId":"get_v1_mfa_status","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MfaStatusResponse"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/mfa/passkeys":{"get":{"tags":["mfa"],"summary":"List Passkeys","operationId":"get_v1_mfa_passkeys","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasskeyListResponse"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/mfa/passkeys/{passkey_id}":{"delete":{"tags":["mfa"],"summary":"Delete Passkey","operationId":"delete_v1_mfa_passkeys_passkey_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"passkey_id","in":"path","required":true,"schema":{"title":"Passkey Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/mfa/registration/options":{"post":{"tags":["mfa"],"summary":"Registration Options","operationId":"post_v1_mfa_registration_options","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RegistrationOptionsResponse"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/mfa/registration/verify":{"post":{"tags":["mfa"],"summary":"Registration Verify","operationId":"post_v1_mfa_registration_verify","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RegistrationVerifyRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MfaStatusResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/mfa/authentication/options":{"post":{"tags":["mfa"],"summary":"Authentication Options","operationId":"post_v1_mfa_authentication_options","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthenticationOptionsResponse"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/mfa/authentication/verify":{"post":{"tags":["mfa"],"summary":"Authentication Verify","operationId":"post_v1_mfa_authentication_verify","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthenticationVerifyRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MfaVerifyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/mfa/recovery-codes/generate":{"post":{"tags":["mfa"],"summary":"Generate Recovery Codes","operationId":"post_v1_mfa_recovery-codes_generate","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecoveryCodesResponse"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/mfa/recovery/verify":{"post":{"tags":["mfa"],"summary":"Recovery Verify","operationId":"post_v1_mfa_recovery_verify","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecoveryCodeVerifyRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MfaVerifyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/financial-connections":{"get":{"tags":["finance"],"summary":"List Financial Connections","operationId":"get_v1_financial-connections","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Workspaceid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FinancialConnectionListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/financial-connections/stripe/connect-url":{"post":{"tags":["finance"],"summary":"Stripe Connect Url","operationId":"post_v1_financial-connections_stripe_connect-url","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectUrlResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/financial-connections/stripe/connect-account":{"post":{"tags":["finance"],"summary":"Stripe Connect Account","description":"Map one of the Stripe Organization's accounts to a project and backfill it.\n\nOne read-only org key (`sk_org_…`) is stored once per workspace; each project gets\na mapping row to its `acct_…`. Revenue is read with the org key scoped to that\naccount via `Stripe-Context`, then attributed entirely to the project. Pass\n`secretKey` to set/replace the org key, or omit it to reuse the saved one.","operationId":"post_v1_financial-connections_stripe_connect-account","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StripeConnectAccountRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectUrlResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/financial-connections/plaid/link-token":{"post":{"tags":["finance"],"summary":"Plaid Link Token","operationId":"post_v1_financial-connections_plaid_link-token","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectUrlResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/financial-connections/plaid/{connection_id}/update-link-token":{"post":{"tags":["finance"],"summary":"Plaid Update Link Token","description":"Create Link update mode for exactly one existing Plaid Item.","operationId":"post_v1_financial-connections_plaid_connection_id_update-link-token","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectUrlResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/financial-connections/plaid/{connection_id}/complete-update":{"post":{"tags":["finance"],"summary":"Plaid Complete Update","description":"Confirm Link success by syncing and clearing the Item repair state.","operationId":"post_v1_financial-connections_plaid_connection_id_complete-update","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FinancialConnectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/financial-connections/plaid/exchange-token":{"post":{"tags":["finance"],"summary":"Plaid Exchange Token","description":"Exchange a Plaid public_token for an access token, store it encrypted, sync.","operationId":"post_v1_financial-connections_plaid_exchange-token","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlaidExchangeRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectUrlResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/financial-connections/{connection_id}":{"delete":{"tags":["finance"],"summary":"Revoke Financial Connection","operationId":"delete_v1_financial-connections_connection_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/revenue":{"get":{"tags":["finance"],"summary":"Revenue Summary","operationId":"get_v1_revenue","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"groupBy","in":"query","required":false,"schema":{"type":"string","default":"kind","title":"Groupby"}},{"name":"periodGranularity","in":"query","required":false,"schema":{"type":"string","default":"month","title":"Periodgranularity"}},{"name":"from","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"From"}},{"name":"to","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"To"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RevenueSummaryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/revenue/products":{"get":{"tags":["finance"],"summary":"Revenue Products","description":"Per-product sales breakdown from Stripe Checkout line items.\n\nAnswers: what sold, its list/market value, units, gross revenue, Stripe fees,\nand net (revenue − fees). Grouped by product (falling back to price, then the\nline description) so even ad-hoc `price_data` purchases get a row.","operationId":"get_v1_revenue_products","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"from","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"From"}},{"name":"to","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"To"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductBreakdownResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/banking/accounts":{"get":{"tags":["finance"],"summary":"Banking Accounts","operationId":"get_v1_banking_accounts","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Workspaceid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BankAccountListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/banking/accounts/{account_id}":{"get":{"tags":["finance"],"summary":"Banking Account Detail","description":"One account plus its recent balance history (movement-only snapshots).","operationId":"get_v1_banking_accounts_account_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Account Id"}},{"name":"snapshotLimit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":30,"title":"Snapshotlimit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BankAccountDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/banking/transactions":{"get":{"tags":["finance"],"summary":"Banking Transactions","description":"The transaction explorer's read: filter, search, sort, and page.\n\nAlso returns spending/deposit totals for the WHOLE filtered set, not just\nthe page — \"what do these 340 rows add up to\" is the question a filter is\nusually asked in service of, and a per-page sum would answer a different one.","operationId":"get_v1_banking_transactions","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"accountId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Accountid"}},{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"}},{"name":"merchant","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Merchant"}},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Q"}},{"name":"from","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"From"}},{"name":"to","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"To"}},{"name":"minAmountCents","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Minamountcents"}},{"name":"maxAmountCents","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Maxamountcents"}},{"name":"direction","in":"query","required":false,"schema":{"anyOf":[{"type":"string","pattern":"^(in|out)$"},{"type":"null"}],"title":"Direction"}},{"name":"pending","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Pending"}},{"name":"includeRemoved","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Includeremoved"}},{"name":"sort","in":"query","required":false,"schema":{"type":"string","pattern":"^(date|amount|merchant)$","default":"date","title":"Sort"}},{"name":"order","in":"query","required":false,"schema":{"type":"string","pattern":"^(asc|desc)$","default":"desc","title":"Order"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BankTransactionListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/banking/transactions/{transaction_id}":{"get":{"tags":["finance"],"summary":"Banking Transaction Detail","description":"Full stored contract for one transaction, pending/posted/removed included.\n\nRemoved rows stay readable (status=\"removed\", removed_at set) so a client\nholding a stale id sees the provider's deletion instead of a phantom 404.","operationId":"get_v1_banking_transactions_transaction_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"transaction_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Transaction Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BankTransactionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/banking/summary":{"get":{"tags":["finance"],"summary":"Banking Summary","operationId":"get_v1_banking_summary","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"groupBy","in":"query","required":false,"schema":{"type":"string","default":"category","title":"Groupby"}},{"name":"periodGranularity","in":"query","required":false,"schema":{"type":"string","default":"month","title":"Periodgranularity"}},{"name":"from","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"From"}},{"name":"to","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"To"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BankingSummaryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/banking/sync":{"post":{"tags":["finance"],"summary":"Banking Sync","description":"On-demand pull of all active Plaid connections for the workspace.\n\nUseful where Plaid webhooks can't reach back (local/dev) and as a manual\nrefresh. Production also syncs via the SYNC_UPDATES_AVAILABLE webhook.","operationId":"post_v1_banking_sync","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BankingSyncResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/banking/balances/refresh":{"post":{"tags":["finance"],"summary":"Banking Balance Refresh","description":"Request current balances without turning routine sync into paid calls.","operationId":"post_v1_banking_balances_refresh","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlaidConnectionRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BalanceRefreshResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/investments/accounts":{"get":{"tags":["finance"],"summary":"Investment Accounts","operationId":"get_v1_investments_accounts","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Workspaceid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvestmentAccountListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/investments/transactions":{"get":{"tags":["finance"],"summary":"Investment Transactions","operationId":"get_v1_investments_transactions","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Workspaceid"}},{"name":"accountId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Accountid"}},{"name":"from","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"From"}},{"name":"to","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"To"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvestmentTransactionListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/income-attribution-rules":{"get":{"tags":["finance"],"summary":"List Attribution Rules","operationId":"get_v1_income-attribution-rules","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Workspaceid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AttributionRuleListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["finance"],"summary":"Create Attribution Rule","operationId":"post_v1_income-attribution-rules","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AttributionRuleCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AttributionRuleResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/income-attribution-rules/{rule_id}":{"delete":{"tags":["finance"],"summary":"Delete Attribution Rule","operationId":"delete_v1_income-attribution-rules_rule_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"rule_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Rule Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/income-attribution-rules/apply":{"post":{"tags":["finance"],"summary":"Apply Attribution Rules","operationId":"post_v1_income-attribution-rules_apply","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AttributionApplyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/finance/overview":{"get":{"tags":["finance"],"summary":"Finance Overview","description":"The banking home screen in one read: cash vs. cards, latest activity,\nsync freshness, and connections that need the user's attention.","operationId":"get_v1_finance_overview","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Workspaceid"}},{"name":"transactionLimit","in":"query","required":false,"schema":{"type":"integer","maximum":50,"minimum":1,"default":10,"title":"Transactionlimit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FinanceOverviewResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/finance/digest":{"get":{"tags":["finance"],"summary":"Finance Daily Digest","operationId":"get_v1_finance_digest","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Workspaceid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FinanceReportResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/finance/report":{"get":{"tags":["finance"],"summary":"Finance Weekly Report","operationId":"get_v1_finance_report","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Workspaceid"}},{"name":"period","in":"query","required":false,"schema":{"type":"string","default":"weekly","title":"Period"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FinanceReportResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/finance/runway":{"get":{"tags":["finance"],"summary":"Finance Runway Summary","description":"How many months of cash are left, and the date they run out.\n\nAlso returns what was deliberately left out of the burn (internal transfers,\ncredit-card activity) so the figure can be reconciled against statements\nrather than taken on trust — and, per workspace, each side's own burn and\nrunway, with the money between the owner and the business in `ownerFlows`.","operationId":"get_v1_finance_runway","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FinanceRunwayResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/finance/cashflow-series":{"get":{"tags":["finance"],"summary":"Finance Cashflow Series","description":"Monthly cash in, cash out, and closing balance — same exclusions as runway.","operationId":"get_v1_finance_cashflow-series","security":[{"HTTPBearer":[]}],"parameters":[{"name":"months","in":"query","required":false,"schema":{"type":"integer","maximum":36,"minimum":1,"default":12,"title":"Months"}},{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"side","in":"query","required":false,"schema":{"enum":["combined","organization","personal"],"type":"string","default":"combined","title":"Side"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CashflowSeriesResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/finance/recurring":{"get":{"tags":["finance"],"summary":"Finance Recurring","description":"Charges arriving on a monthly rhythm, and when each is next expected.","operationId":"get_v1_finance_recurring","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"side","in":"query","required":false,"schema":{"enum":["combined","organization","personal"],"type":"string","default":"combined","title":"Side"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecurringResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/finance/obligations":{"get":{"tags":["finance"],"summary":"Finance Obligations","description":"Every card's balance, statement, minimum, and due date — soonest first.","operationId":"get_v1_finance_obligations","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"side","in":"query","required":false,"schema":{"enum":["combined","organization","personal"],"type":"string","default":"combined","title":"Side"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ObligationsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/workspaces/{workspace_id}/runway-preferences":{"get":{"tags":["finance"],"summary":"Get Runway Preferences","operationId":"get_v1_workspaces_workspace_id_runway-preferences","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspace_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Workspace Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunwayPreferencesResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["finance"],"summary":"Put Runway Preferences","operationId":"put_v1_workspaces_workspace_id_runway-preferences","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspace_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Workspace Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunwayPreferencesUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunwayPreferencesResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/finance/alert-preferences":{"get":{"tags":["finance"],"summary":"Get Finance Alert Preferences","description":"Stored thresholds, or the code-level defaults when none were saved.","operationId":"get_v1_finance_alert-preferences","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Workspaceid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FinanceAlertPreferencesResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["finance"],"summary":"Update Finance Alert Preferences","description":"Partial update; the row is created from defaults on first save.","operationId":"put_v1_finance_alert-preferences","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FinanceAlertPreferencesUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FinanceAlertPreferencesResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/webhooks/stripe":{"post":{"tags":["finance"],"summary":"Stripe Webhook","description":"Stripe webhook receiver. Verifies the signature, then ingests charges/payouts.\n\nReturns 503 until a webhook secret is configured so retries are harmless and no\nunverified payload is ingested. For v1 (single self-owned account via restricted\nkey), the event is attributed to the workspace's one active Stripe connection.","operationId":"post_v1_webhooks_stripe","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/v1/webhooks/plaid":{"post":{"tags":["finance"],"summary":"Plaid Webhook","description":"Verify provider authenticity, then route one Item event by Plaid item_id.","operationId":"post_v1_webhooks_plaid","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/v1/budgets":{"get":{"tags":["budgets"],"summary":"List Budgets","operationId":"get_v1_budgets","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"workflowId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Workflowid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BudgetListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["budgets"],"summary":"Create Budget","operationId":"post_v1_budgets","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BudgetCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BudgetResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/budgets/{budget_id}":{"get":{"tags":["budgets"],"summary":"Get Budget","operationId":"get_v1_budgets_budget_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"budget_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Budget Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BudgetResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["budgets"],"summary":"Update Budget","operationId":"patch_v1_budgets_budget_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"budget_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Budget Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BudgetUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BudgetResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["budgets"],"summary":"Delete Budget","operationId":"delete_v1_budgets_budget_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"budget_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Budget Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/budgets/{budget_id}/refusals":{"get":{"tags":["budgets"],"summary":"List Budget Refusals","description":"The drill-down behind refusalsThisWindow: every attempt this budget\nrefused, newest first — what was turned away, when, and the economics at\nthe moment of refusal.","operationId":"get_v1_budgets_budget_id_refusals","security":[{"HTTPBearer":[]}],"parameters":[{"name":"budget_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Budget Id"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BudgetRefusalListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/artifacts/{artifact_id}":{"delete":{"tags":["artifacts"],"summary":"Retract Artifact","description":"Retract an artifact: it disappears from listings, its provenance stays.\n\nIdempotent — retracting an already-retracted artifact is a 204, not a 404,\nso a client retrying a dropped response does not get a false error.","operationId":"delete_v1_artifacts_artifact_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"artifact_id","in":"path","required":true,"schema":{"type":"string","title":"Artifact Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["artifacts"],"summary":"Get Artifact","operationId":"get_v1_artifacts_artifact_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"artifact_id","in":"path","required":true,"schema":{"type":"string","title":"Artifact Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ArtifactResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/artifacts/counts":{"get":{"tags":["artifacts"],"summary":"Count Artifacts Over Time","description":"Artifacts filed per period, for a production trend.\n\nReturns only periods that HAVE artifacts — the caller fills gaps with real\nzeros. Emitting a row per empty day would make the response size a function\nof how long you have been idle.","operationId":"get_v1_artifacts_counts","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"string","format":"uuid"}},{"type":"null"}],"title":"Projectid"}},{"name":"class","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"null"}],"title":"Class"}},{"name":"artifactType","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"null"}],"title":"Artifacttype"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"null"}],"title":"Status"}},{"name":"templateId","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"null"}],"title":"Templateid"}},{"name":"workerId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Workerid"}},{"name":"createdAfter","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Createdafter"}},{"name":"createdBefore","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Createdbefore"}},{"name":"periodGranularity","in":"query","required":false,"schema":{"enum":["day","week","month"],"type":"string","default":"day","title":"Periodgranularity"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ArtifactCountsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/artifacts":{"get":{"tags":["artifacts"],"summary":"List Artifacts","operationId":"get_v1_artifacts","security":[{"HTTPBearer":[]}],"parameters":[{"name":"run_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Run Id"}},{"name":"runId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Runid"}},{"name":"includeStage","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Includestage"}},{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"string","format":"uuid"}},{"type":"null"}],"title":"Projectid"}},{"name":"type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Type"}},{"name":"class","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"null"}],"title":"Class"}},{"name":"artifactType","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"null"}],"title":"Artifacttype"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"null"}],"title":"Status"}},{"name":"templateId","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"null"}],"title":"Templateid"}},{"name":"createdAfter","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Createdafter"}},{"name":"createdBefore","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Createdbefore"}},{"name":"live","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Live"}},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Q"}},{"name":"sort","in":"query","required":false,"schema":{"enum":["createdDesc","createdAsc","titleAsc"],"type":"string","default":"createdDesc","title":"Sort"}},{"name":"facets","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Facets"}},{"name":"workerId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Workerid"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ArtifactListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/artifacts/{artifact_id}/family":{"get":{"tags":["artifacts"],"summary":"Get Pack Family","description":"Everything a pack plan spawned, in one payload (operator mandate\n2026-07-31: \"if i click the planned report it should be connected to all\nof its associates\"). Resolution: plan → orders that declared it\n(``GenerationOrder.plan_artifact_id``) → their children's produced\nartifacts → each order's QA report. Ad-hoc orders and pre-link packs\nsimply return an empty family — the graph only knows declared edges.","operationId":"get_v1_artifacts_artifact_id_family","security":[{"HTTPBearer":[]}],"parameters":[{"name":"artifact_id","in":"path","required":true,"schema":{"type":"string","title":"Artifact Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackFamilyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/artifacts/{artifact_id}/comments":{"post":{"tags":["artifacts"],"summary":"Create Comment","operationId":"post_v1_artifacts_artifact_id_comments","security":[{"HTTPBearer":[]}],"parameters":[{"name":"artifact_id","in":"path","required":true,"schema":{"type":"string","title":"Artifact Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CommentCreateRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CommentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["artifacts"],"summary":"List Comments","operationId":"get_v1_artifacts_artifact_id_comments","security":[{"HTTPBearer":[]}],"parameters":[{"name":"artifact_id","in":"path","required":true,"schema":{"type":"string","title":"Artifact Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CommentListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/context/upload":{"post":{"tags":["context"],"summary":"Upload Context File","description":"Accept a data/text file as a source record: raw bytes to R2 (the\nLibrary), structure sniffed into content (columns, rowCount, preview) so\nthe shelf can render it and workflows can consume it by reference.","operationId":"post_v1_context_upload","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_post_v1_context_upload"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ArtifactResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/context":{"get":{"tags":["context"],"summary":"List Context","description":"The shelf lens: every artifact that is a context record — uploaded,\nauthored, or a run-produced brief that claimed a context_type.","operationId":"get_v1_context","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Type"}},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Q"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ArtifactListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/context/profile":{"get":{"tags":["context"],"summary":"Get Profile","operationId":"get_v1_context_profile","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Workspaceid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ArtifactResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["context"],"summary":"Upsert Profile","description":"The one authored record about the workspace itself (org facts: when it\nwas formed, legal name, brands, mission — or personal facts). One per\nworkspace; a PUT replaces content rather than versioning.","operationId":"put_v1_context_profile","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProfileUpsertRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ArtifactResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/story-heroes":{"post":{"tags":["story-heroes"],"summary":"Register Story Hero","description":"Register one rigged hero GLB for a series: validate, store the bytes\ncontent-addressed in R2, and create the `story-hero-model` artifact the\nplanner (`heroModel` intake) and the manifest bind by id.","operationId":"post_v1_story-heroes","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_post_v1_story-heroes"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ArtifactResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["story-heroes"],"summary":"List Story Heroes","description":"The newest registered hero per series (optionally one series). A\nre-registration supersedes the prior one for planning; older artifacts\nstay for provenance of books already built on them.","operationId":"get_v1_story-heroes","security":[{"HTTPBearer":[]}],"parameters":[{"name":"seriesId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Seriesid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ArtifactResponse"},"title":"Response Get V1 Story-Heroes"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/story-trinkets":{"post":{"tags":["story-trinkets"],"summary":"Register Story Trinket","description":"Register one hand-made trinket GLB for a series: validate, store the\nbytes content-addressed in R2, and create the `story-trinket-model`\nartifact the manifest builder lists under nook.trinkets.","operationId":"post_v1_story-trinkets","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_post_v1_story-trinkets"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ArtifactResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["story-trinkets"],"summary":"List Story Trinkets","description":"The newest registered trinket per (series, subject), optionally one\nseries. A re-upload of the same subject supersedes; older artifacts stay\nfor the provenance of books already built on them.","operationId":"get_v1_story-trinkets","security":[{"HTTPBearer":[]}],"parameters":[{"name":"seriesId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Seriesid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ArtifactResponse"},"title":"Response Get V1 Story-Trinkets"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/artifacts/{artifact_id}/publish-story-book":{"post":{"tags":["story-books"],"summary":"Publish Story Book","operationId":"post_v1_artifacts_artifact_id_publish-story-book","security":[{"HTTPBearer":[]}],"parameters":[{"name":"artifact_id","in":"path","required":true,"schema":{"type":"string","title":"Artifact Id"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/StoryBookPublishRequest"},{"type":"null"}],"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StoryBookPublishResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/story-books/{slug}/manifest":{"get":{"tags":["story-books"],"summary":"Read Story Book Manifest","description":"The published manifest by slug — public, short-cached. Newest\npublished manifest wins when a book was rebuilt and republished.","operationId":"get_v1_story-books_slug_manifest","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/specs":{"get":{"tags":["specs"],"summary":"List Specs","operationId":"get_v1_specs","security":[{"HTTPBearer":[]}],"parameters":[{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SpecListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/specs/{spec_id}":{"get":{"tags":["specs"],"summary":"Get Spec","operationId":"get_v1_specs_spec_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"spec_id","in":"path","required":true,"schema":{"type":"string","title":"Spec Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SpecResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/insights":{"post":{"tags":["insights"],"summary":"Create Insight","operationId":"post_v1_insights","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InsightRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InsightResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents/{document_id}/agent/threads":{"get":{"tags":["document-agent"],"summary":"List Threads","operationId":"get_v1_documents_document_id_agent_threads","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ThreadListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["document-agent"],"summary":"Create Thread","operationId":"post_v1_documents_document_id_agent_threads","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ThreadCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ThreadResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents/{document_id}/agent/threads/{thread_id}":{"patch":{"tags":["document-agent"],"summary":"Rename Thread","operationId":"patch_v1_documents_document_id_agent_threads_thread_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}},{"name":"thread_id","in":"path","required":true,"schema":{"type":"string","title":"Thread Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ThreadUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ThreadResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["document-agent"],"summary":"Delete Thread","operationId":"delete_v1_documents_document_id_agent_threads_thread_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}},{"name":"thread_id","in":"path","required":true,"schema":{"type":"string","title":"Thread Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents/{document_id}/agent/threads/{thread_id}/messages":{"get":{"tags":["document-agent"],"summary":"List Messages","operationId":"get_v1_documents_document_id_agent_threads_thread_id_messages","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}},{"name":"thread_id","in":"path","required":true,"schema":{"type":"string","title":"Thread Id"}},{"name":"beforeSequence","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Beforesequence"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MessagePage"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents/{document_id}/agent/messages/{message_id}/cancel":{"post":{"tags":["document-agent"],"summary":"Cancel Message","description":"Explicit stop. The streaming generator's finalizer preserves whatever\npartial content was checkpointed; this only settles the terminal status.","operationId":"post_v1_documents_document_id_agent_messages_message_id_cancel","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}},{"name":"message_id","in":"path","required":true,"schema":{"type":"string","title":"Message Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__document_agent__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents/{document_id}/agent/messages/{message_id}/applications":{"post":{"tags":["document-agent"],"summary":"Record Application","description":"Record an explicit apply. The client flushes autosave, applies the\nTipTap transaction locally, then records the event — so the revision\nsnapshot taken here reflects the pre-application document.","operationId":"post_v1_documents_document_id_agent_messages_message_id_applications","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}},{"name":"message_id","in":"path","required":true,"schema":{"type":"string","title":"Message Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApplicationCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApplicationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents/{document_id}/revisions/{revision_id}":{"get":{"tags":["document-agent"],"summary":"Get Revision","operationId":"get_v1_documents_document_id_revisions_revision_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}},{"name":"revision_id","in":"path","required":true,"schema":{"type":"string","title":"Revision Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RevisionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents/{document_id}/agent/threads/{thread_id}/turns":{"post":{"tags":["document-agent"],"summary":"Create Turn","operationId":"post_v1_documents_document_id_agent_threads_thread_id_turns","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}},{"name":"thread_id","in":"path","required":true,"schema":{"type":"string","title":"Thread Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgentTurnRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents/{document_id}/outline":{"get":{"tags":["document-outline"],"summary":"Get Outline","operationId":"get_v1_documents_document_id_outline","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutlineResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents/{document_id}/outline/blocks":{"post":{"tags":["document-outline"],"summary":"Create Block","operationId":"post_v1_documents_document_id_outline_blocks","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutlineBlockCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutlineResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents/{document_id}/outline/blocks/{block_id}":{"patch":{"tags":["document-outline"],"summary":"Update Block","operationId":"patch_v1_documents_document_id_outline_blocks_block_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}},{"name":"block_id","in":"path","required":true,"schema":{"type":"string","title":"Block Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutlineBlockUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutlineBlockResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["document-outline"],"summary":"Delete Block","operationId":"delete_v1_documents_document_id_outline_blocks_block_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}},{"name":"block_id","in":"path","required":true,"schema":{"type":"string","title":"Block Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutlineResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents/{document_id}/outline/reorder":{"post":{"tags":["document-outline"],"summary":"Reorder Blocks","description":"Complete new ordering: every existing block exactly once. Re-parenting\nis allowed (parentId change); descendants follow their parent.","operationId":"post_v1_documents_document_id_outline_reorder","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutlineReorder"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutlineResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents/{document_id}/outline/import":{"post":{"tags":["document-outline"],"summary":"Import Headings","description":"Import manuscript headings as blocks. Level 1-2 headings become roots;\nlevel-3 headings nest under the preceding level-2 block.","operationId":"post_v1_documents_document_id_outline_import","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutlineImportRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutlineResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents/{document_id}/outline/propose":{"post":{"tags":["document-outline"],"summary":"Propose Outline","operationId":"post_v1_documents_document_id_outline_propose","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutlineProposalRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutlineProposalResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents/{document_id}/outline/accept":{"post":{"tags":["document-outline"],"summary":"Accept Proposal","description":"Materialize approved proposed blocks into the outline — the explicit\ngate between AI proposal and durable structure.","operationId":"post_v1_documents_document_id_outline_accept","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutlineAcceptRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutlineResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents":{"get":{"tags":["documents"],"summary":"List Documents","operationId":"get_v1_documents","security":[{"HTTPBearer":[]}],"parameters":[{"name":"kind","in":"query","required":false,"schema":{"anyOf":[{"type":"string","pattern":"^(essay|article)$"},{"type":"null"}],"title":"Kind"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string","pattern":"^(draft|published)$"},{"type":"null"}],"title":"Status"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["documents"],"summary":"Create Document","operationId":"post_v1_documents","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents/{document_id}":{"get":{"tags":["documents"],"summary":"Get Document","operationId":"get_v1_documents_document_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["documents"],"summary":"Update Document","operationId":"patch_v1_documents_document_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["documents"],"summary":"Delete Document","operationId":"delete_v1_documents_document_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents/{document_id}/publish":{"post":{"tags":["documents"],"summary":"Publish Document","operationId":"post_v1_documents_document_id_publish","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents/{document_id}/unpublish":{"post":{"tags":["documents"],"summary":"Unpublish Document","operationId":"post_v1_documents_document_id_unpublish","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents/{document_id}/newsletter/draft":{"post":{"tags":["documents"],"summary":"Create Newsletter Draft","description":"Turn this article into a Beehiiv DRAFT (never a send — Phase 1 is\ndraft-first; the user reviews and sends inside Beehiiv).\n\nFlow: resolve the document's publication and its Beehiiv connection →\ntransform the article to email-safe HTML (video degrades to a poster\nlinking to the publication's own site) → create the draft → record\nprovenance on the document. Opt-in per article: nothing here runs on\nordinary publish.","operationId":"post_v1_documents_document_id_newsletter_draft","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NewsletterDraftRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NewsletterDraftResult"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents/{document_id}/youtube/upload":{"post":{"tags":["documents"],"summary":"Upload To Youtube","description":"Publish this document's Mux video to the author's connected YouTube channel.\n\nBrokered so Compose never touches a Google token: resolve the connection,\nrefresh it if expired, then stream the Mux MP4 rendition into YouTube's\nresumable upload. Records a social_upload either way. Default privacy is\nunlisted (the author flips to public in YouTube Studio).","operationId":"post_v1_documents_document_id_youtube_upload","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VideoUploadRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VideoUploadResult"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/documents/{document_id}/youtube/uploads":{"get":{"tags":["documents"],"summary":"List Youtube Uploads","description":"This document's YouTube publish history (newest first) — lets Compose show\nthe published/watch state across reloads instead of only in-session.","operationId":"get_v1_documents_document_id_youtube_uploads","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SocialUploadListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/publications/public/{slug}/articles":{"get":{"tags":["publications"],"summary":"List Publication Articles","operationId":"get_v1_publications_public_slug_articles","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicArticleListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/publications/public/{slug}/articles/{article_slug}":{"get":{"tags":["publications"],"summary":"Get Publication Article","operationId":"get_v1_publications_public_slug_articles_article_slug","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"article_slug","in":"path","required":true,"schema":{"type":"string","title":"Article Slug"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicArticle"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/publications/public/{slug}/categories":{"get":{"tags":["publications"],"summary":"List Publication Categories Public","operationId":"get_v1_publications_public_slug_categories","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicationCategoryListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/publications":{"get":{"tags":["publications"],"summary":"List Publications","operationId":"get_v1_publications","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicationListResponse"}}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["publications"],"summary":"Create Publication","operationId":"post_v1_publications","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicationCreate"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicationWithSecretResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/publications/{publication_id}":{"get":{"tags":["publications"],"summary":"Get Publication","operationId":"get_v1_publications_publication_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"publication_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Publication Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["publications"],"summary":"Update Publication","operationId":"patch_v1_publications_publication_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"publication_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Publication Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicationUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["publications"],"summary":"Delete Publication","operationId":"delete_v1_publications_publication_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"publication_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Publication Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/publications/{publication_id}/secret/rotate":{"post":{"tags":["publications"],"summary":"Rotate Secret","operationId":"post_v1_publications_publication_id_secret_rotate","security":[{"HTTPBearer":[]}],"parameters":[{"name":"publication_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Publication Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicationWithSecretResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/publications/{publication_id}/verify":{"post":{"tags":["publications"],"summary":"Verify Connection","operationId":"post_v1_publications_publication_id_verify","security":[{"HTTPBearer":[]}],"parameters":[{"name":"publication_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Publication Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VerifyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/publications/{publication_id}/newsletter":{"post":{"tags":["publications"],"summary":"Connect Newsletter","description":"Bind (or re-bind) this publication's Beehiiv channel. The API key is\nencrypted at rest; the response exposes only that a key is set.","operationId":"post_v1_publications_publication_id_newsletter","security":[{"HTTPBearer":[]}],"parameters":[{"name":"publication_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Publication Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NewsletterConnect"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["publications"],"summary":"Disconnect Newsletter","description":"Turn the email channel off. The web destination is untouched.","operationId":"delete_v1_publications_publication_id_newsletter","security":[{"HTTPBearer":[]}],"parameters":[{"name":"publication_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Publication Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/publications/{publication_id}/newsletter/verify":{"post":{"tags":["publications"],"summary":"Verify Newsletter","description":"Live round-trip to Beehiiv so the user confirms the key + publication id\nactually resolve — the Connect panel's \"Verify\" for the email channel.","operationId":"post_v1_publications_publication_id_newsletter_verify","security":[{"HTTPBearer":[]}],"parameters":[{"name":"publication_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Publication Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NewsletterVerifyResult"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/publications/{publication_id}/categories":{"get":{"tags":["publications"],"summary":"List Categories","operationId":"get_v1_publications_publication_id_categories","security":[{"HTTPBearer":[]}],"parameters":[{"name":"publication_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Publication Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicationCategoryListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["publications"],"summary":"Create Category","operationId":"post_v1_publications_publication_id_categories","security":[{"HTTPBearer":[]}],"parameters":[{"name":"publication_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Publication Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicationCategoryCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicationCategoryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/publications/{publication_id}/categories/reorder":{"post":{"tags":["publications"],"summary":"Reorder Categories","operationId":"post_v1_publications_publication_id_categories_reorder","security":[{"HTTPBearer":[]}],"parameters":[{"name":"publication_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Publication Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CategoryReorder"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicationCategoryListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/publications/{publication_id}/categories/{category_id}":{"patch":{"tags":["publications"],"summary":"Update Category","operationId":"patch_v1_publications_publication_id_categories_category_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"publication_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Publication Id"}},{"name":"category_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Category Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicationCategoryUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicationCategoryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["publications"],"summary":"Delete Category","operationId":"delete_v1_publications_publication_id_categories_category_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"publication_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Publication Id"}},{"name":"category_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Category Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/authors":{"get":{"tags":["authors"],"summary":"List Authors","operationId":"get_v1_authors","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthorListResponse"}}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["authors"],"summary":"Create Author","operationId":"post_v1_authors","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthorCreate"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthorResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/authors/{author_id}":{"patch":{"tags":["authors"],"summary":"Update Author","operationId":"patch_v1_authors_author_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"author_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Author Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthorUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthorResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["authors"],"summary":"Delete Author","operationId":"delete_v1_authors_author_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"author_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Author Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/social/connections":{"get":{"tags":["social"],"summary":"List Connections","operationId":"get_v1_social_connections","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SocialConnectionListResponse"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/social/{provider}/connect":{"get":{"tags":["social"],"summary":"Connect","description":"Return the provider's OAuth consent URL for the browser to open. State\nembeds the caller so the (cookieless) callback can attribute the tokens.","operationId":"get_v1_social_provider_connect","security":[{"HTTPBearer":[]}],"parameters":[{"name":"provider","in":"path","required":true,"schema":{"type":"string","title":"Provider"}},{"name":"returnTo","in":"query","required":false,"schema":{"type":"string","default":"","title":"Returnto"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SocialAuthUrlResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/social/{provider}/callback":{"get":{"tags":["social"],"summary":"Callback","description":"Google redirects here after consent. Verify state, exchange the code, store\nthe encrypted tokens, and bounce the browser back to Compose.","operationId":"get_v1_social_provider_callback","parameters":[{"name":"provider","in":"path","required":true,"schema":{"type":"string","title":"Provider"}},{"name":"code","in":"query","required":false,"schema":{"type":"string","default":"","title":"Code"}},{"name":"state","in":"query","required":false,"schema":{"type":"string","default":"","title":"State"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/social/{provider}":{"delete":{"tags":["social"],"summary":"Disconnect","operationId":"delete_v1_social_provider","security":[{"HTTPBearer":[]}],"parameters":[{"name":"provider","in":"path","required":true,"schema":{"type":"string","title":"Provider"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/outlets":{"get":{"tags":["outlets"],"summary":"List Outlets","operationId":"get_v1_outlets","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutletListResponse"}}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["outlets"],"summary":"Create Outlet","operationId":"post_v1_outlets","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutletCreate"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutletWithSecretResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/outlets/items/by-artifact/{artifact_id}":{"get":{"tags":["outlets"],"summary":"Items For Artifact","description":"Everywhere one artifact is filed — the app's Publishing card reads\nthis to render Live-on / Unpublish controls.","operationId":"get_v1_outlets_items_by-artifact_artifact_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"artifact_id","in":"path","required":true,"schema":{"type":"string","title":"Artifact Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutletItemListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/outlets/{outlet_id}":{"get":{"tags":["outlets"],"summary":"Get Outlet","operationId":"get_v1_outlets_outlet_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"outlet_id","in":"path","required":true,"schema":{"type":"string","title":"Outlet Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutletResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["outlets"],"summary":"Update Outlet","operationId":"patch_v1_outlets_outlet_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"outlet_id","in":"path","required":true,"schema":{"type":"string","title":"Outlet Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutletUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutletResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/outlets/{outlet_id}/secret/rotate":{"post":{"tags":["outlets"],"summary":"Rotate Secret","operationId":"post_v1_outlets_outlet_id_secret_rotate","security":[{"HTTPBearer":[]}],"parameters":[{"name":"outlet_id","in":"path","required":true,"schema":{"type":"string","title":"Outlet Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutletWithSecretResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/outlets/{outlet_id}/verify":{"post":{"tags":["outlets"],"summary":"Verify Outlet","operationId":"post_v1_outlets_outlet_id_verify","security":[{"HTTPBearer":[]}],"parameters":[{"name":"outlet_id","in":"path","required":true,"schema":{"type":"string","title":"Outlet Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutletVerifyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/outlets/{outlet_id}/items/publish":{"post":{"tags":["outlets"],"summary":"Publish Items","operationId":"post_v1_outlets_outlet_id_items_publish","security":[{"HTTPBearer":[]}],"parameters":[{"name":"outlet_id","in":"path","required":true,"schema":{"type":"string","title":"Outlet Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutletItemsAct"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutletItemsActResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/outlets/{outlet_id}/items/unpublish":{"post":{"tags":["outlets"],"summary":"Unpublish Items","operationId":"post_v1_outlets_outlet_id_items_unpublish","security":[{"HTTPBearer":[]}],"parameters":[{"name":"outlet_id","in":"path","required":true,"schema":{"type":"string","title":"Outlet Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutletItemsAct"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutletItemsActResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/outlets/{outlet_id}/items":{"get":{"tags":["outlets"],"summary":"List Items","description":"The consumer feed: items + the artifact data an ingest needs to build\na page. Defaults to published items, newest publish first.","operationId":"get_v1_outlets_outlet_id_items","security":[{"HTTPBearer":[]}],"parameters":[{"name":"outlet_id","in":"path","required":true,"schema":{"type":"string","title":"Outlet Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"default":"published","title":"Status"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutletItemListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/media/uploads":{"post":{"tags":["media"],"summary":"Create Upload","operationId":"post_v1_media_uploads","responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MuxUploadResponse"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/media/uploads/{upload_id}":{"get":{"tags":["media"],"summary":"Get Upload Status","operationId":"get_v1_media_uploads_upload_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"upload_id","in":"path","required":true,"schema":{"type":"string","title":"Upload Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MuxUploadStatusResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/media/assets":{"get":{"tags":["media"],"summary":"List Assets","operationId":"get_v1_media_assets","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MediaAssetListResponse"}}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["media"],"summary":"Create Asset","operationId":"post_v1_media_assets","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MediaAssetCreate"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MediaAssetResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/media/images":{"post":{"tags":["media"],"summary":"Upload Image","description":"Accept an image from the editor, store it in R2, return a durable asset.\n\nUnlike video (brokered to Mux), image bytes transit this API and land in\nESY-owned R2. Static raster formats are transcoded to WebP; animated GIFs\nare passed through untouched so motion survives. Storage is scoped by the\npublication when one is supplied and owned by the caller; otherwise it\nlands in the owner-scoped bucket. The result registers in the shared media\nlibrary and comes back as a public URL.","operationId":"post_v1_media_images","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_post_v1_media_images"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MediaAssetResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/goals":{"get":{"tags":["planning"],"summary":"List Goals","operationId":"get_v1_goals","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"horizon","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Horizon"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"assigneeWorkerId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assigneeworkerid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GoalListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["planning"],"summary":"Create Goal","operationId":"post_v1_goals","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GoalCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GoalResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/goals/{goal_id}":{"get":{"tags":["planning"],"summary":"Get Goal","operationId":"get_v1_goals_goal_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"goal_id","in":"path","required":true,"schema":{"type":"string","title":"Goal Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GoalResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["planning"],"summary":"Update Goal","operationId":"patch_v1_goals_goal_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"goal_id","in":"path","required":true,"schema":{"type":"string","title":"Goal Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GoalUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GoalResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["planning"],"summary":"Delete Goal","operationId":"delete_v1_goals_goal_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"goal_id","in":"path","required":true,"schema":{"type":"string","title":"Goal Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/tasks":{"get":{"tags":["planning"],"summary":"List Tasks","operationId":"get_v1_tasks","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"goalId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Goalid"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"assigneeWorkerId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assigneeworkerid"}},{"name":"dateFrom","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Datefrom"}},{"name":"dateTo","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Dateto"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["planning"],"summary":"Create Task","operationId":"post_v1_tasks","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/tasks/{task_id}":{"get":{"tags":["planning"],"summary":"Get Task","operationId":"get_v1_tasks_task_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["planning"],"summary":"Update Task","operationId":"patch_v1_tasks_task_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["planning"],"summary":"Delete Task","operationId":"delete_v1_tasks_task_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/messages":{"get":{"tags":["planning"],"summary":"List Messages","operationId":"get_v1_messages","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"projectId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},{"name":"kind","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Kind"}},{"name":"unread","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Unread"}},{"name":"archived","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Archived"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MessageListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["planning"],"summary":"Send Message","operationId":"post_v1_messages","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MessageCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__planning__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/messages/unread-count":{"get":{"tags":["planning"],"summary":"Unread Count","operationId":"get_v1_messages_unread-count","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnreadCountResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/messages/{message_id}":{"get":{"tags":["planning"],"summary":"Get Message","operationId":"get_v1_messages_message_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"message_id","in":"path","required":true,"schema":{"type":"string","title":"Message Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__planning__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["planning"],"summary":"Update Message","operationId":"patch_v1_messages_message_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"message_id","in":"path","required":true,"schema":{"type":"string","title":"Message Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MessageUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__planning__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/category-presets":{"get":{"tags":["planning"],"summary":"List Presets","operationId":"get_v1_category-presets","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CategoryPresetListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["planning"],"summary":"Create Preset","operationId":"post_v1_category-presets","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CategoryPresetCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CategoryPresetResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/category-presets/{preset_id}":{"get":{"tags":["planning"],"summary":"Get Preset","operationId":"get_v1_category-presets_preset_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"preset_id","in":"path","required":true,"schema":{"type":"string","title":"Preset Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CategoryPresetResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["planning"],"summary":"Update Preset","operationId":"patch_v1_category-presets_preset_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"preset_id","in":"path","required":true,"schema":{"type":"string","title":"Preset Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CategoryPresetUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CategoryPresetResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["planning"],"summary":"Delete Preset","operationId":"delete_v1_category-presets_preset_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"preset_id","in":"path","required":true,"schema":{"type":"string","title":"Preset Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/prompts/resolve":{"get":{"tags":["prompts"],"summary":"Resolve","description":"What a run would use right now. The same call the engine makes, exposed\nso an operator can answer \"which text is `live` actually pointing at?\"\nwithout reading the database.","operationId":"get_v1_prompts_resolve","security":[{"HTTPBearer":[]}],"parameters":[{"name":"itemId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Itemid"}},{"name":"slug","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug"}},{"name":"alias","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"default":"live","title":"Alias"}},{"name":"version","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Version"}},{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResolvedRef"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/prompts":{"get":{"tags":["prompts"],"summary":"List Items","description":"List items. Metadata only by default.\n\n`?include=live` attaches the version each item's `live` alias points at,\npayload and all. Without it a caller that needs the CONTENT of every item —\na category picker showing which labels a set holds, a prompt list showing a\npreview — has to fetch each item separately, which is a request per row for\ndata one join already has.","operationId":"get_v1_prompts","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Q"}},{"name":"includeArchived","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Includearchived"}},{"name":"include","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"`live` attaches each item's live version, payload included.","title":"Include"},"description":"`live` attaches each item's live version, payload included."},{"name":"purpose","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: instructions | fragment (prompts)","title":"Purpose"},"description":"Facet filter: instructions | fragment (prompts)"},{"name":"product","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: product slug","title":"Product"},"description":"Facet filter: product slug"},{"name":"stage","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: research | style | manifest | …","title":"Stage"},"description":"Facet filter: research | style | manifest | …"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["prompts"],"summary":"Create Item","description":"Create the item and publish v1 together. An item with no version is a\nresource nothing can reference, so it is never a state worth persisting.","operationId":"post_v1_prompts","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/prompts/{item_id}":{"get":{"tags":["prompts"],"summary":"Get Item","operationId":"get_v1_prompts_item_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["prompts"],"summary":"Update Item","description":"Identity only — name, description, archived. Content is never patched;\nit is published (see POST /versions), which is what keeps every byte any run\never used still readable.","operationId":"patch_v1_prompts_item_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/prompts/{item_id}/versions":{"post":{"tags":["prompts"],"summary":"Create Version","description":"Publish. Nothing that runs changes unless `promoteTo` is set, and that\npath takes the same admin check as an explicit promote.","operationId":"post_v1_prompts_item_id_versions","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryVersionCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/prompts/{item_id}/aliases":{"post":{"tags":["prompts"],"summary":"Set Alias","description":"Promote — point an alias at a version. Recorded in library_alias_moves\nwhether or not the permission check ever rejects anyone.","operationId":"post_v1_prompts_item_id_aliases","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AliasMove"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/prompts/{item_id}/moves":{"get":{"tags":["prompts"],"summary":"List Moves","description":"Who moved what, when. Readable by any member — an audit trail only one\nperson can read is a diary.","operationId":"get_v1_prompts_item_id_moves","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AliasMoveListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/classifiers/resolve":{"get":{"tags":["classifiers"],"summary":"Resolve","description":"What a run would use right now. The same call the engine makes, exposed\nso an operator can answer \"which text is `live` actually pointing at?\"\nwithout reading the database.","operationId":"get_v1_classifiers_resolve","security":[{"HTTPBearer":[]}],"parameters":[{"name":"itemId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Itemid"}},{"name":"slug","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug"}},{"name":"alias","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"default":"live","title":"Alias"}},{"name":"version","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Version"}},{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResolvedRef"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/classifiers":{"get":{"tags":["classifiers"],"summary":"List Items","description":"List items. Metadata only by default.\n\n`?include=live` attaches the version each item's `live` alias points at,\npayload and all. Without it a caller that needs the CONTENT of every item —\na category picker showing which labels a set holds, a prompt list showing a\npreview — has to fetch each item separately, which is a request per row for\ndata one join already has.","operationId":"get_v1_classifiers","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Q"}},{"name":"includeArchived","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Includearchived"}},{"name":"include","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"`live` attaches each item's live version, payload included.","title":"Include"},"description":"`live` attaches each item's live version, payload included."},{"name":"purpose","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: instructions | fragment (prompts)","title":"Purpose"},"description":"Facet filter: instructions | fragment (prompts)"},{"name":"product","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: product slug","title":"Product"},"description":"Facet filter: product slug"},{"name":"stage","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: research | style | manifest | …","title":"Stage"},"description":"Facet filter: research | style | manifest | …"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["classifiers"],"summary":"Create Item","description":"Create the item and publish v1 together. An item with no version is a\nresource nothing can reference, so it is never a state worth persisting.","operationId":"post_v1_classifiers","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/classifiers/{item_id}":{"get":{"tags":["classifiers"],"summary":"Get Item","operationId":"get_v1_classifiers_item_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["classifiers"],"summary":"Update Item","description":"Identity only — name, description, archived. Content is never patched;\nit is published (see POST /versions), which is what keeps every byte any run\never used still readable.","operationId":"patch_v1_classifiers_item_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/classifiers/{item_id}/versions":{"post":{"tags":["classifiers"],"summary":"Create Version","description":"Publish. Nothing that runs changes unless `promoteTo` is set, and that\npath takes the same admin check as an explicit promote.","operationId":"post_v1_classifiers_item_id_versions","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryVersionCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/classifiers/{item_id}/aliases":{"post":{"tags":["classifiers"],"summary":"Set Alias","description":"Promote — point an alias at a version. Recorded in library_alias_moves\nwhether or not the permission check ever rejects anyone.","operationId":"post_v1_classifiers_item_id_aliases","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AliasMove"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/classifiers/{item_id}/moves":{"get":{"tags":["classifiers"],"summary":"List Moves","description":"Who moved what, when. Readable by any member — an audit trail only one\nperson can read is a diary.","operationId":"get_v1_classifiers_item_id_moves","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AliasMoveListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/standards/resolve":{"get":{"tags":["standards"],"summary":"Resolve","description":"What a run would use right now. The same call the engine makes, exposed\nso an operator can answer \"which text is `live` actually pointing at?\"\nwithout reading the database.","operationId":"get_v1_standards_resolve","security":[{"HTTPBearer":[]}],"parameters":[{"name":"itemId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Itemid"}},{"name":"slug","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug"}},{"name":"alias","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"default":"live","title":"Alias"}},{"name":"version","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Version"}},{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResolvedRef"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/standards":{"get":{"tags":["standards"],"summary":"List Items","description":"List items. Metadata only by default.\n\n`?include=live` attaches the version each item's `live` alias points at,\npayload and all. Without it a caller that needs the CONTENT of every item —\na category picker showing which labels a set holds, a prompt list showing a\npreview — has to fetch each item separately, which is a request per row for\ndata one join already has.","operationId":"get_v1_standards","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Q"}},{"name":"includeArchived","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Includearchived"}},{"name":"include","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"`live` attaches each item's live version, payload included.","title":"Include"},"description":"`live` attaches each item's live version, payload included."},{"name":"purpose","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: instructions | fragment (prompts)","title":"Purpose"},"description":"Facet filter: instructions | fragment (prompts)"},{"name":"product","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: product slug","title":"Product"},"description":"Facet filter: product slug"},{"name":"stage","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: research | style | manifest | …","title":"Stage"},"description":"Facet filter: research | style | manifest | …"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["standards"],"summary":"Create Item","description":"Create the item and publish v1 together. An item with no version is a\nresource nothing can reference, so it is never a state worth persisting.","operationId":"post_v1_standards","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/standards/{item_id}":{"get":{"tags":["standards"],"summary":"Get Item","operationId":"get_v1_standards_item_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["standards"],"summary":"Update Item","description":"Identity only — name, description, archived. Content is never patched;\nit is published (see POST /versions), which is what keeps every byte any run\never used still readable.","operationId":"patch_v1_standards_item_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/standards/{item_id}/versions":{"post":{"tags":["standards"],"summary":"Create Version","description":"Publish. Nothing that runs changes unless `promoteTo` is set, and that\npath takes the same admin check as an explicit promote.","operationId":"post_v1_standards_item_id_versions","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryVersionCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/standards/{item_id}/aliases":{"post":{"tags":["standards"],"summary":"Set Alias","description":"Promote — point an alias at a version. Recorded in library_alias_moves\nwhether or not the permission check ever rejects anyone.","operationId":"post_v1_standards_item_id_aliases","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AliasMove"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/standards/{item_id}/moves":{"get":{"tags":["standards"],"summary":"List Moves","description":"Who moved what, when. Readable by any member — an audit trail only one\nperson can read is a diary.","operationId":"get_v1_standards_item_id_moves","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AliasMoveListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/directions/resolve":{"get":{"tags":["directions"],"summary":"Resolve","description":"What a run would use right now. The same call the engine makes, exposed\nso an operator can answer \"which text is `live` actually pointing at?\"\nwithout reading the database.","operationId":"get_v1_directions_resolve","security":[{"HTTPBearer":[]}],"parameters":[{"name":"itemId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Itemid"}},{"name":"slug","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug"}},{"name":"alias","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"default":"live","title":"Alias"}},{"name":"version","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Version"}},{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResolvedRef"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/directions":{"get":{"tags":["directions"],"summary":"List Items","description":"List items. Metadata only by default.\n\n`?include=live` attaches the version each item's `live` alias points at,\npayload and all. Without it a caller that needs the CONTENT of every item —\na category picker showing which labels a set holds, a prompt list showing a\npreview — has to fetch each item separately, which is a request per row for\ndata one join already has.","operationId":"get_v1_directions","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Q"}},{"name":"includeArchived","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Includearchived"}},{"name":"include","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"`live` attaches each item's live version, payload included.","title":"Include"},"description":"`live` attaches each item's live version, payload included."},{"name":"purpose","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: instructions | fragment (prompts)","title":"Purpose"},"description":"Facet filter: instructions | fragment (prompts)"},{"name":"product","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: product slug","title":"Product"},"description":"Facet filter: product slug"},{"name":"stage","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: research | style | manifest | …","title":"Stage"},"description":"Facet filter: research | style | manifest | …"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["directions"],"summary":"Create Item","description":"Create the item and publish v1 together. An item with no version is a\nresource nothing can reference, so it is never a state worth persisting.","operationId":"post_v1_directions","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/directions/{item_id}":{"get":{"tags":["directions"],"summary":"Get Item","operationId":"get_v1_directions_item_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["directions"],"summary":"Update Item","description":"Identity only — name, description, archived. Content is never patched;\nit is published (see POST /versions), which is what keeps every byte any run\never used still readable.","operationId":"patch_v1_directions_item_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/directions/{item_id}/versions":{"post":{"tags":["directions"],"summary":"Create Version","description":"Publish. Nothing that runs changes unless `promoteTo` is set, and that\npath takes the same admin check as an explicit promote.","operationId":"post_v1_directions_item_id_versions","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryVersionCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/directions/{item_id}/aliases":{"post":{"tags":["directions"],"summary":"Set Alias","description":"Promote — point an alias at a version. Recorded in library_alias_moves\nwhether or not the permission check ever rejects anyone.","operationId":"post_v1_directions_item_id_aliases","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AliasMove"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/directions/{item_id}/moves":{"get":{"tags":["directions"],"summary":"List Moves","description":"Who moved what, when. Readable by any member — an audit trail only one\nperson can read is a diary.","operationId":"get_v1_directions_item_id_moves","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AliasMoveListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/axes/resolve":{"get":{"tags":["axes"],"summary":"Resolve","description":"What a run would use right now. The same call the engine makes, exposed\nso an operator can answer \"which text is `live` actually pointing at?\"\nwithout reading the database.","operationId":"get_v1_axes_resolve","security":[{"HTTPBearer":[]}],"parameters":[{"name":"itemId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Itemid"}},{"name":"slug","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug"}},{"name":"alias","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"default":"live","title":"Alias"}},{"name":"version","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Version"}},{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResolvedRef"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/axes":{"get":{"tags":["axes"],"summary":"List Items","description":"List items. Metadata only by default.\n\n`?include=live` attaches the version each item's `live` alias points at,\npayload and all. Without it a caller that needs the CONTENT of every item —\na category picker showing which labels a set holds, a prompt list showing a\npreview — has to fetch each item separately, which is a request per row for\ndata one join already has.","operationId":"get_v1_axes","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Q"}},{"name":"includeArchived","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Includearchived"}},{"name":"include","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"`live` attaches each item's live version, payload included.","title":"Include"},"description":"`live` attaches each item's live version, payload included."},{"name":"purpose","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: instructions | fragment (prompts)","title":"Purpose"},"description":"Facet filter: instructions | fragment (prompts)"},{"name":"product","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: product slug","title":"Product"},"description":"Facet filter: product slug"},{"name":"stage","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: research | style | manifest | …","title":"Stage"},"description":"Facet filter: research | style | manifest | …"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["axes"],"summary":"Create Item","description":"Create the item and publish v1 together. An item with no version is a\nresource nothing can reference, so it is never a state worth persisting.","operationId":"post_v1_axes","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/axes/{item_id}":{"get":{"tags":["axes"],"summary":"Get Item","operationId":"get_v1_axes_item_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["axes"],"summary":"Update Item","description":"Identity only — name, description, archived. Content is never patched;\nit is published (see POST /versions), which is what keeps every byte any run\never used still readable.","operationId":"patch_v1_axes_item_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/axes/{item_id}/versions":{"post":{"tags":["axes"],"summary":"Create Version","description":"Publish. Nothing that runs changes unless `promoteTo` is set, and that\npath takes the same admin check as an explicit promote.","operationId":"post_v1_axes_item_id_versions","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryVersionCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/axes/{item_id}/aliases":{"post":{"tags":["axes"],"summary":"Set Alias","description":"Promote — point an alias at a version. Recorded in library_alias_moves\nwhether or not the permission check ever rejects anyone.","operationId":"post_v1_axes_item_id_aliases","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AliasMove"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/axes/{item_id}/moves":{"get":{"tags":["axes"],"summary":"List Moves","description":"Who moved what, when. Readable by any member — an audit trail only one\nperson can read is a diary.","operationId":"get_v1_axes_item_id_moves","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AliasMoveListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/style-kits/resolve":{"get":{"tags":["style kits"],"summary":"Resolve","description":"What a run would use right now. The same call the engine makes, exposed\nso an operator can answer \"which text is `live` actually pointing at?\"\nwithout reading the database.","operationId":"get_v1_style-kits_resolve","security":[{"HTTPBearer":[]}],"parameters":[{"name":"itemId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Itemid"}},{"name":"slug","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug"}},{"name":"alias","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"default":"live","title":"Alias"}},{"name":"version","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Version"}},{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResolvedRef"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/style-kits":{"get":{"tags":["style kits"],"summary":"List Items","description":"List items. Metadata only by default.\n\n`?include=live` attaches the version each item's `live` alias points at,\npayload and all. Without it a caller that needs the CONTENT of every item —\na category picker showing which labels a set holds, a prompt list showing a\npreview — has to fetch each item separately, which is a request per row for\ndata one join already has.","operationId":"get_v1_style-kits","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Q"}},{"name":"includeArchived","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Includearchived"}},{"name":"include","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"`live` attaches each item's live version, payload included.","title":"Include"},"description":"`live` attaches each item's live version, payload included."},{"name":"purpose","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: instructions | fragment (prompts)","title":"Purpose"},"description":"Facet filter: instructions | fragment (prompts)"},{"name":"product","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: product slug","title":"Product"},"description":"Facet filter: product slug"},{"name":"stage","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: research | style | manifest | …","title":"Stage"},"description":"Facet filter: research | style | manifest | …"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["style kits"],"summary":"Create Item","description":"Create the item and publish v1 together. An item with no version is a\nresource nothing can reference, so it is never a state worth persisting.","operationId":"post_v1_style-kits","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/style-kits/{item_id}":{"get":{"tags":["style kits"],"summary":"Get Item","operationId":"get_v1_style-kits_item_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["style kits"],"summary":"Update Item","description":"Identity only — name, description, archived. Content is never patched;\nit is published (see POST /versions), which is what keeps every byte any run\never used still readable.","operationId":"patch_v1_style-kits_item_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/style-kits/{item_id}/versions":{"post":{"tags":["style kits"],"summary":"Create Version","description":"Publish. Nothing that runs changes unless `promoteTo` is set, and that\npath takes the same admin check as an explicit promote.","operationId":"post_v1_style-kits_item_id_versions","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryVersionCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/style-kits/{item_id}/aliases":{"post":{"tags":["style kits"],"summary":"Set Alias","description":"Promote — point an alias at a version. Recorded in library_alias_moves\nwhether or not the permission check ever rejects anyone.","operationId":"post_v1_style-kits_item_id_aliases","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AliasMove"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/style-kits/{item_id}/moves":{"get":{"tags":["style kits"],"summary":"List Moves","description":"Who moved what, when. Readable by any member — an audit trail only one\nperson can read is a diary.","operationId":"get_v1_style-kits_item_id_moves","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AliasMoveListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/sources/resolve":{"get":{"tags":["sources"],"summary":"Resolve","description":"What a run would use right now. The same call the engine makes, exposed\nso an operator can answer \"which text is `live` actually pointing at?\"\nwithout reading the database.","operationId":"get_v1_sources_resolve","security":[{"HTTPBearer":[]}],"parameters":[{"name":"itemId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Itemid"}},{"name":"slug","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug"}},{"name":"alias","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"default":"live","title":"Alias"}},{"name":"version","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Version"}},{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResolvedRef"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/sources":{"get":{"tags":["sources"],"summary":"List Items","description":"List items. Metadata only by default.\n\n`?include=live` attaches the version each item's `live` alias points at,\npayload and all. Without it a caller that needs the CONTENT of every item —\na category picker showing which labels a set holds, a prompt list showing a\npreview — has to fetch each item separately, which is a request per row for\ndata one join already has.","operationId":"get_v1_sources","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Q"}},{"name":"includeArchived","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Includearchived"}},{"name":"include","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"`live` attaches each item's live version, payload included.","title":"Include"},"description":"`live` attaches each item's live version, payload included."},{"name":"purpose","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: instructions | fragment (prompts)","title":"Purpose"},"description":"Facet filter: instructions | fragment (prompts)"},{"name":"product","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: product slug","title":"Product"},"description":"Facet filter: product slug"},{"name":"stage","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: research | style | manifest | …","title":"Stage"},"description":"Facet filter: research | style | manifest | …"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["sources"],"summary":"Create Item","description":"Create the item and publish v1 together. An item with no version is a\nresource nothing can reference, so it is never a state worth persisting.","operationId":"post_v1_sources","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/sources/{item_id}":{"get":{"tags":["sources"],"summary":"Get Item","operationId":"get_v1_sources_item_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["sources"],"summary":"Update Item","description":"Identity only — name, description, archived. Content is never patched;\nit is published (see POST /versions), which is what keeps every byte any run\never used still readable.","operationId":"patch_v1_sources_item_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/sources/{item_id}/versions":{"post":{"tags":["sources"],"summary":"Create Version","description":"Publish. Nothing that runs changes unless `promoteTo` is set, and that\npath takes the same admin check as an explicit promote.","operationId":"post_v1_sources_item_id_versions","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryVersionCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/sources/{item_id}/aliases":{"post":{"tags":["sources"],"summary":"Set Alias","description":"Promote — point an alias at a version. Recorded in library_alias_moves\nwhether or not the permission check ever rejects anyone.","operationId":"post_v1_sources_item_id_aliases","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AliasMove"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/sources/{item_id}/moves":{"get":{"tags":["sources"],"summary":"List Moves","description":"Who moved what, when. Readable by any member — an audit trail only one\nperson can read is a diary.","operationId":"get_v1_sources_item_id_moves","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AliasMoveListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/source-policies/resolve":{"get":{"tags":["sources"],"summary":"Resolve","description":"What a run would use right now. The same call the engine makes, exposed\nso an operator can answer \"which text is `live` actually pointing at?\"\nwithout reading the database.","operationId":"get_v1_source-policies_resolve","security":[{"HTTPBearer":[]}],"parameters":[{"name":"itemId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Itemid"}},{"name":"slug","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug"}},{"name":"alias","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"default":"live","title":"Alias"}},{"name":"version","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Version"}},{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResolvedRef"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/source-policies":{"get":{"tags":["sources"],"summary":"List Items","description":"List items. Metadata only by default.\n\n`?include=live` attaches the version each item's `live` alias points at,\npayload and all. Without it a caller that needs the CONTENT of every item —\na category picker showing which labels a set holds, a prompt list showing a\npreview — has to fetch each item separately, which is a request per row for\ndata one join already has.","operationId":"get_v1_source-policies","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Q"}},{"name":"includeArchived","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Includearchived"}},{"name":"include","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"`live` attaches each item's live version, payload included.","title":"Include"},"description":"`live` attaches each item's live version, payload included."},{"name":"purpose","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: instructions | fragment (prompts)","title":"Purpose"},"description":"Facet filter: instructions | fragment (prompts)"},{"name":"product","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: product slug","title":"Product"},"description":"Facet filter: product slug"},{"name":"stage","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Facet filter: research | style | manifest | …","title":"Stage"},"description":"Facet filter: research | style | manifest | …"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["sources"],"summary":"Create Item","description":"Create the item and publish v1 together. An item with no version is a\nresource nothing can reference, so it is never a state worth persisting.","operationId":"post_v1_source-policies","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/source-policies/{item_id}":{"get":{"tags":["sources"],"summary":"Get Item","operationId":"get_v1_source-policies_item_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["sources"],"summary":"Update Item","description":"Identity only — name, description, archived. Content is never patched;\nit is published (see POST /versions), which is what keeps every byte any run\never used still readable.","operationId":"patch_v1_source-policies_item_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/source-policies/{item_id}/versions":{"post":{"tags":["sources"],"summary":"Create Version","description":"Publish. Nothing that runs changes unless `promoteTo` is set, and that\npath takes the same admin check as an explicit promote.","operationId":"post_v1_source-policies_item_id_versions","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryVersionCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/source-policies/{item_id}/aliases":{"post":{"tags":["sources"],"summary":"Set Alias","description":"Promote — point an alias at a version. Recorded in library_alias_moves\nwhether or not the permission check ever rejects anyone.","operationId":"post_v1_source-policies_item_id_aliases","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AliasMove"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LibraryItemDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/source-policies/{item_id}/moves":{"get":{"tags":["sources"],"summary":"List Moves","description":"Who moved what, when. Readable by any member — an audit trail only one\nperson can read is a diary.","operationId":"get_v1_source-policies_item_id_moves","security":[{"HTTPBearer":[]}],"parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","title":"Item Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AliasMoveListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/teams":{"get":{"tags":["autonomy"],"summary":"List Teams","operationId":"get_v1_teams","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["autonomy"],"summary":"Create Team","operationId":"post_v1_teams","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/teams/{team_id}":{"get":{"tags":["autonomy"],"summary":"Get Team","operationId":"get_v1_teams_team_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"team_id","in":"path","required":true,"schema":{"type":"string","title":"Team Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["autonomy"],"summary":"Update Team","operationId":"patch_v1_teams_team_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"team_id","in":"path","required":true,"schema":{"type":"string","title":"Team Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["autonomy"],"summary":"Delete Team","operationId":"delete_v1_teams_team_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"team_id","in":"path","required":true,"schema":{"type":"string","title":"Team Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/workers":{"get":{"tags":["autonomy"],"summary":"List Workers","operationId":"get_v1_workers","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkerListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["autonomy"],"summary":"Create Worker","operationId":"post_v1_workers","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkerCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkerResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/workers/{worker_id}":{"get":{"tags":["autonomy"],"summary":"Get Worker","operationId":"get_v1_workers_worker_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"worker_id","in":"path","required":true,"schema":{"type":"string","title":"Worker Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkerResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["autonomy"],"summary":"Update Worker","operationId":"patch_v1_workers_worker_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"worker_id","in":"path","required":true,"schema":{"type":"string","title":"Worker Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkerUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkerResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/workers/{worker_id}/run":{"post":{"tags":["autonomy"],"summary":"Run Worker Now","description":"Manual trigger: start a shift now. Fire-and-return — the shift runs in\nthe background; watch it via /shifts, the SSE shift.* events, and the\nworker's report in the Inbox.","operationId":"post_v1_workers_worker_id_run","security":[{"HTTPBearer":[]}],"parameters":[{"name":"worker_id","in":"path","required":true,"schema":{"type":"string","title":"Worker Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShiftListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/workers/{worker_id}/shifts/{shift_id}/end":{"post":{"tags":["autonomy"],"summary":"End Worker Shift","description":"Manually end a running shift NOW (2026-07-07: a shift stalled on a\nhung order had no stop button). Cancels the shift's non-terminal orders\n(planned children flip to cancelled; in-flight children finish and still\nland in review), then settles:\n\n- live shift (this process is driving it): its task sees the end request\n  at the next checkpoint and runs the normal close-out — publish, goal\n  credit, report — within ~one poll tick. The response still reads\n  `running` until then; watch the shift.* events.\n- orphaned shift (its process died): settled immediately via the\n  recovery path; the response is terminal.","operationId":"post_v1_workers_worker_id_shifts_shift_id_end","security":[{"HTTPBearer":[]}],"parameters":[{"name":"worker_id","in":"path","required":true,"schema":{"type":"string","title":"Worker Id"}},{"name":"shift_id","in":"path","required":true,"schema":{"type":"string","title":"Shift Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShiftResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/workers/{worker_id}/shifts/{shift_id}":{"get":{"tags":["autonomy"],"summary":"Get Worker Shift","description":"One shift, deep-linkable — the live shift page's primary read.\n\n``?include=linked`` resolves the shift's linked orders/goals/tasks/\nmessages server-side (four IN queries, bounded by the links caps) —\nJSON:API compound-document style, opt-in so the plain response stays\nbyte-identical. Replaces the client's per-id fan-out that made the live\nshift page cost 8-12 round trips per refresh.","operationId":"get_v1_workers_worker_id_shifts_shift_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"worker_id","in":"path","required":true,"schema":{"type":"string","title":"Worker Id"}},{"name":"shift_id","in":"path","required":true,"schema":{"type":"string","title":"Shift Id"}},{"name":"include","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Include"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShiftResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/workers/{worker_id}/shifts":{"get":{"tags":["autonomy"],"summary":"List Worker Shifts","operationId":"get_v1_workers_worker_id_shifts","security":[{"HTTPBearer":[]}],"parameters":[{"name":"worker_id","in":"path","required":true,"schema":{"type":"string","title":"Worker Id"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShiftListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/schedules":{"get":{"tags":["autonomy"],"summary":"List Schedules","operationId":"get_v1_schedules","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workspaceId","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},{"name":"workerId","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Workerid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScheduleListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["autonomy"],"summary":"Create Schedule","operationId":"post_v1_schedules","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScheduleCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScheduleResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/schedules/{schedule_id}":{"get":{"tags":["autonomy"],"summary":"Get Schedule","operationId":"get_v1_schedules_schedule_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"schedule_id","in":"path","required":true,"schema":{"type":"string","title":"Schedule Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScheduleResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["autonomy"],"summary":"Update Schedule","operationId":"patch_v1_schedules_schedule_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"schedule_id","in":"path","required":true,"schema":{"type":"string","title":"Schedule Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScheduleUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScheduleResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["autonomy"],"summary":"Delete Schedule","operationId":"delete_v1_schedules_schedule_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"schedule_id","in":"path","required":true,"schema":{"type":"string","title":"Schedule Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/admin/users":{"get":{"tags":["admin"],"summary":"List Users","description":"Everyone on the platform, newest first.\n\nPaginated and filtered in SQL rather than in the browser. A list that loads\neverything and filters client-side is fine at a thousand rows and a cliff\nafter — and this is the page you reach for when something is wrong, which is\nexactly when it will be biggest.","operationId":"get_v1_admin_users","security":[{"HTTPBearer":[]}],"parameters":[{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Match against email or name","title":"Q"},"description":"Match against email or name"},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"pageSize","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Pagesize"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminUserList"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/admin/users/{user_id}":{"get":{"tags":["admin"],"summary":"Get User","description":"One person, in full — and read-only.\n\n`is_sole_member` on each workspace is the number an operator actually needs\nbefore approving a deletion: it is exactly the set that would be destroyed,\nas opposed to the organizations that would merely lose a member.","operationId":"get_v1_admin_users_user_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminUserDetail"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/admin/deletion-requests":{"get":{"tags":["admin"],"summary":"List Deletion Requests","description":"The queue. Open requests first, most urgent at the top.\n\nSorted by `respond_by` rather than by arrival: the one that matters is the\none closest to the promise, and those are not always the same request.","operationId":"get_v1_admin_deletion-requests","security":[{"HTTPBearer":[]}],"parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeletionQueue"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/admin/deletion-requests/{deletion_id}":{"get":{"tags":["admin"],"summary":"Get Deletion Request","operationId":"get_v1_admin_deletion-requests_deletion_id","security":[{"HTTPBearer":[]}],"parameters":[{"name":"deletion_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Deletion Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeletionRequestRow"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/admin/deletion-requests/{deletion_id}/approve":{"post":{"tags":["admin"],"summary":"Approve Deletion Request","description":"Approve: schedule the purge and lock the account.\n\nNothing is destroyed at this instant — the sweep does that when the\ncooling-off window expires, which is what makes `undo` possible.","operationId":"post_v1_admin_deletion-requests_deletion_id_approve","security":[{"HTTPBearer":[]}],"parameters":[{"name":"deletion_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Deletion Id"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ApproveBody"},{"type":"null"}],"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeletionRequestRow"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/admin/deletion-requests/{deletion_id}/undo":{"post":{"tags":["admin"],"summary":"Undo Deletion Approval","description":"Take an approval back. Only possible before the sweep has acted.","operationId":"post_v1_admin_deletion-requests_deletion_id_undo","security":[{"HTTPBearer":[]}],"parameters":[{"name":"deletion_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Deletion Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeletionRequestRow"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/admin/deletion-requests/{deletion_id}/decline":{"post":{"tags":["admin"],"summary":"Decline Deletion Request","description":"Refuse the request, with a reason the account holder is shown.\n\nRefusing an erasure request is a serious thing to do and usually only\ndefensible when another legal duty outweighs it. The reason is mandatory\nbecause \"declined\" with no explanation is the worst possible answer.","operationId":"post_v1_admin_deletion-requests_deletion_id_decline","security":[{"HTTPBearer":[]}],"parameters":[{"name":"deletion_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Deletion Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeclineBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeletionRequestRow"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/admin/overview":{"get":{"tags":["admin"],"summary":"Get Overview","description":"The dashboard tiles. Cheap counts only — this page loads on every visit.","operationId":"get_v1_admin_overview","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminOverview"}}}}},"security":[{"HTTPBearer":[]}]}},"/health":{"get":{"summary":"Health Check","description":"Liveness, plus whether the background loops are actually running.\n\n`{\"status\": \"ok\"}` was true and useless on 2026-08-07: the API answered in\n130 ms while the worker had been dead for nine hours. HTTP health says\nnothing about the tier that does the work — they are different processes.\n\n`loops` reports the last heartbeat per loop out of shared Redis, so this\nanswers from either tier. `status` stays \"ok\" when a loop is stale: a\nstopped sweep is not a reason to fail a load-balancer probe and take the\nsite down. `loopsStale` names exactly what is not running.","operationId":"get_health","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}}},"components":{"schemas":{"AccountDeletionRequest":{"properties":{"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"}},"type":"object","title":"AccountDeletionRequest","description":"Optional context the account holder can attach when asking to leave.\n\nOptional on purpose. Requiring someone to justify leaving before you let\nthem is a dark pattern; asking is fine, insisting is not."},"ActionRequest":{"properties":{"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag"},"requestId":{"anyOf":[{"type":"string","maxLength":64,"minLength":8},{"type":"null"}],"title":"Requestid"}},"type":"object","title":"ActionRequest","description":"Any action with no inputs of its own: :plan, :write, :build."},"ActionStarted":{"properties":{"orderId":{"type":"string","title":"Orderid"},"orderIds":{"items":{"type":"string"},"type":"array","title":"Orderids"},"runIds":{"items":{"type":"string"},"type":"array","title":"Runids"},"itemIds":{"items":{"type":"string"},"type":"array","title":"Itemids","default":[]},"attemptIds":{"items":{"type":"string"},"type":"array","title":"Attemptids","default":[]},"budgetCapUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Budgetcapusd"},"estimatedCostUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Estimatedcostusd"},"etag":{"type":"string","title":"Etag"}},"type":"object","required":["orderId","orderIds","runIds","etag"],"title":"ActionStarted","description":"What an action started: the order, its runs, the members it covers,\nan attempt per member, and the budget cap set (the templates' per-run\ncaps, summed)."},"AdInput":{"properties":{"keyword":{"type":"string","title":"Keyword"},"offer":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Offer"}},"type":"object","required":["keyword"],"title":"AdInput"},"AdminOverview":{"properties":{"userCount":{"type":"integer","title":"Usercount"},"workspaceCount":{"type":"integer","title":"Workspacecount"},"openDeletionCount":{"type":"integer","title":"Opendeletioncount"},"overdueDeletionCount":{"type":"integer","title":"Overduedeletioncount"},"runCount30D":{"type":"integer","title":"Runcount30D"},"artifactCount30D":{"type":"integer","title":"Artifactcount30D"}},"type":"object","required":["userCount","workspaceCount","openDeletionCount","overdueDeletionCount","runCount30D","artifactCount30D"],"title":"AdminOverview","description":"The dashboard's numbers. Each one links to the page that explains it."},"AdminUserDetail":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"email":{"type":"string","title":"Email"},"name":{"type":"string","title":"Name"},"role":{"type":"string","title":"Role"},"isActive":{"type":"boolean","title":"Isactive"},"workspaceCount":{"type":"integer","title":"Workspacecount"},"runCount":{"type":"integer","title":"Runcount"},"lastRunAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastrunat"},"deletionStatus":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Deletionstatus"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"artifactCount":{"type":"integer","title":"Artifactcount"},"apiKeyCount":{"type":"integer","title":"Apikeycount"},"passkeyCount":{"type":"integer","title":"Passkeycount"},"workspaces":{"items":{"$ref":"#/components/schemas/AdminWorkspaceSummary"},"type":"array","title":"Workspaces"},"connections":{"items":{"type":"string"},"type":"array","title":"Connections"},"deletionId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Deletionid"}},"type":"object","required":["id","email","name","role","isActive","workspaceCount","runCount","createdAt","artifactCount","apiKeyCount","passkeyCount","workspaces","connections"],"title":"AdminUserDetail"},"AdminUserList":{"properties":{"items":{"items":{"$ref":"#/components/schemas/AdminUserSummary"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"pageSize":{"type":"integer","title":"Pagesize"}},"type":"object","required":["items","total","page","pageSize"],"title":"AdminUserList"},"AdminUserSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"email":{"type":"string","title":"Email"},"name":{"type":"string","title":"Name"},"role":{"type":"string","title":"Role"},"isActive":{"type":"boolean","title":"Isactive"},"workspaceCount":{"type":"integer","title":"Workspacecount"},"runCount":{"type":"integer","title":"Runcount"},"lastRunAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastrunat"},"deletionStatus":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Deletionstatus"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"}},"type":"object","required":["id","email","name","role","isActive","workspaceCount","runCount","createdAt"],"title":"AdminUserSummary"},"AdminWorkspaceSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"kind":{"type":"string","title":"Kind"},"role":{"type":"string","title":"Role"},"isSoleMember":{"type":"boolean","title":"Issolemember"}},"type":"object","required":["id","name","slug","kind","role","isSoleMember"],"title":"AdminWorkspaceSummary"},"AgentContextSnapshot":{"properties":{"scope":{"type":"string","enum":["none","selection","section","document","block"],"title":"Scope","default":"section"},"documentTitle":{"type":"string","maxLength":500,"title":"Documenttitle","default":""},"documentText":{"type":"string","maxLength":60000,"title":"Documenttext","default":""},"selection":{"anyOf":[{"$ref":"#/components/schemas/AgentSelection"},{"type":"null"}]},"blockId":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Blockid"},"blockHeading":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}],"title":"Blockheading"}},"type":"object","title":"AgentContextSnapshot","description":"Bounded live-editor context captured at send time. The server treats\nall of it as user-supplied context (never as system instructions)."},"AgentSelection":{"properties":{"text":{"type":"string","maxLength":20000,"minLength":1,"title":"Text"},"fromPos":{"type":"integer","minimum":0.0,"title":"Frompos"},"toPos":{"type":"integer","minimum":0.0,"title":"Topos"}},"type":"object","required":["text","fromPos","toPos"],"title":"AgentSelection","description":"The user's live selection. Positions are ProseMirror offsets and are\nsession-local — Replace is only valid while the captured range still holds\nthe exact original text in the same editor session."},"AgentTurnRequest":{"properties":{"content":{"type":"string","maxLength":8000,"minLength":1,"title":"Content"},"action":{"type":"string","maxLength":40,"title":"Action","default":"ask"},"model":{"type":"string","maxLength":120,"title":"Model","description":"Registry model id"},"context":{"$ref":"#/components/schemas/AgentContextSnapshot"}},"type":"object","required":["content","model"],"title":"AgentTurnRequest","description":"One user turn. POST /threads/{threadId}/turns streams the reply."},"AiMessage":{"properties":{"role":{"type":"string","enum":["user","assistant"],"title":"Role"},"content":{"type":"string","minLength":1,"title":"Content"}},"type":"object","required":["role","content"],"title":"AiMessage"},"AiRequestMetadata":{"properties":{"client":{"anyOf":[{"type":"string","maxLength":40},{"type":"null"}],"title":"Client"},"purpose":{"anyOf":[{"type":"string","maxLength":80},{"type":"null"}],"title":"Purpose"}},"type":"object","title":"AiRequestMetadata","description":"Caller attribution for the usage log. `client` identifies the surface\n(\"compose\", \"app\", \"clip-art\"); `purpose` is a free-form feature tag\n(\"continue\", \"improve\", \"screenplay-draft\")."},"AliasMove":{"properties":{"alias":{"type":"string","maxLength":60,"title":"Alias","default":"live"},"version":{"type":"integer","minimum":1.0,"title":"Version"},"note":{"type":"string","title":"Note","default":""}},"type":"object","required":["version"],"title":"AliasMove"},"AliasMoveListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/AliasMoveResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"AliasMoveListResponse"},"AliasMoveResponse":{"properties":{"id":{"type":"string","title":"Id"},"itemId":{"type":"string","title":"Itemid"},"alias":{"type":"string","title":"Alias"},"fromVersion":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Fromversion"},"toVersion":{"type":"integer","title":"Toversion"},"note":{"type":"string","title":"Note"},"movedByUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Movedbyuserid"},"movedAt":{"type":"string","format":"date-time","title":"Movedat"}},"type":"object","required":["id","itemId","alias","toVersion","note","movedAt"],"title":"AliasMoveResponse","description":"One line of the promote history."},"AnalysisPlan":{"properties":{"paired":{"type":"boolean","title":"Paired","default":true},"bootstrapSamples":{"type":"integer","maximum":20000.0,"minimum":200.0,"title":"Bootstrapsamples","default":2000},"correction":{"type":"string","enum":["holm","none"],"title":"Correction","default":"holm"},"alpha":{"type":"number","exclusiveMaximum":1.0,"exclusiveMinimum":0.0,"title":"Alpha","default":0.05},"includeHoldout":{"type":"boolean","title":"Includeholdout","default":false},"scorerVersions":{"additionalProperties":{"type":"string"},"type":"object","title":"Scorerversions"},"thresholdGrid":{"anyOf":[{"items":{"type":"number"},"type":"array"},{"type":"null"}],"title":"Thresholdgrid"}},"type":"object","title":"AnalysisPlan"},"ApiKeyListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ApiKeyResponse"},"type":"array","title":"Items"}},"type":"object","required":["items"],"title":"ApiKeyListResponse"},"ApiKeyResponse":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"keyPrefix":{"type":"string","title":"Keyprefix"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"lastUsedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastusedat"},"revokedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Revokedat"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"}},"type":"object","required":["id","name","keyPrefix","workspaceId","lastUsedAt","revokedAt","createdAt"],"title":"ApiKeyResponse"},"ApplicationCreate":{"properties":{"idempotencyKey":{"type":"string","maxLength":64,"minLength":8,"title":"Idempotencykey"},"mode":{"type":"string","enum":["insert","append","replace"],"title":"Mode"},"targetFrom":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Targetfrom"},"targetTo":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Targetto"},"replacedChars":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Replacedchars"}},"type":"object","required":["idempotencyKey","mode"],"title":"ApplicationCreate","description":"Records that the user explicitly applied an assistant message to the\ndocument. The client applies the TipTap transaction first, then records\nthe event; the idempotency key makes retries safe."},"ApplicationResponse":{"properties":{"id":{"type":"string","title":"Id"},"messageId":{"type":"string","title":"Messageid"},"mode":{"type":"string","enum":["insert","append","replace"],"title":"Mode"},"revisionId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Revisionid"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"}},"type":"object","required":["id","messageId","mode","createdAt"],"title":"ApplicationResponse"},"ApproveBody":{"properties":{"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"}},"type":"object","title":"ApproveBody"},"ArmCreate":{"properties":{"key":{"type":"string","maxLength":40,"minLength":1,"title":"Key"},"label":{"type":"string","title":"Label","default":""},"workflowId":{"type":"string","title":"Workflowid"},"intakeOverrides":{"additionalProperties":true,"type":"object","title":"Intakeoverrides"},"providerOverrides":{"additionalProperties":{"type":"string"},"type":"object","title":"Provideroverrides"},"isBaseline":{"type":"boolean","title":"Isbaseline","default":false}},"type":"object","required":["key","workflowId"],"title":"ArmCreate"},"ArmResponse":{"properties":{"id":{"type":"string","title":"Id"},"key":{"type":"string","title":"Key"},"label":{"type":"string","title":"Label"},"workflowId":{"type":"string","title":"Workflowid"},"workflowVersionId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Workflowversionid"},"intakeOverrides":{"additionalProperties":true,"type":"object","title":"Intakeoverrides"},"providerOverrides":{"additionalProperties":{"type":"string"},"type":"object","title":"Provideroverrides"},"stepPatches":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Steppatches"},"isBaseline":{"type":"boolean","title":"Isbaseline"},"position":{"type":"integer","title":"Position"}},"type":"object","required":["id","key","label","workflowId","workflowVersionId","intakeOverrides","providerOverrides","stepPatches","isBaseline","position"],"title":"ArmResponse"},"ArtifactCountBucket":{"properties":{"period":{"type":"string","format":"date-time","title":"Period"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["period","count"],"title":"ArtifactCountBucket","description":"Artifacts filed in one period."},"ArtifactCountsResponse":{"properties":{"granularity":{"type":"string","title":"Granularity"},"buckets":{"items":{"$ref":"#/components/schemas/ArtifactCountBucket"},"type":"array","title":"Buckets"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["granularity","buckets","total"],"title":"ArtifactCountsResponse","description":"Production over time. Only periods that HAVE artifacts are returned —\nemitting a row per empty day would make the response size a function of how\nlong you have been idle. Callers fill gaps with real zeros, so a quiet\nSunday draws as zero rather than as a straight line through missing data."},"ArtifactListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ArtifactSummary"},"type":"array","title":"Items"},"facets":{"anyOf":[{"additionalProperties":{"additionalProperties":{"type":"integer"},"type":"object"},"type":"object"},{"type":"null"}],"title":"Facets"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"ArtifactListResponse"},"ArtifactResponse":{"properties":{"id":{"type":"string","title":"Id"},"runId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Runid"},"templateId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Templateid"},"templateName":{"type":"string","title":"Templatename"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"title":{"type":"string","title":"Title"},"subtitle":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subtitle"},"status":{"type":"string","title":"Status"},"content":{"additionalProperties":true,"type":"object","title":"Content"},"qa":{"additionalProperties":true,"type":"object","title":"Qa"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata"},"costLedger":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Costledger"},"version":{"type":"integer","title":"Version"},"parentVersionId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parentversionid"},"versionNote":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Versionnote"},"specId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specid"},"specVersionHash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specversionhash"},"source":{"type":"string","title":"Source","default":"run"},"contextType":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contexttype"},"stageStepId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stagestepid"},"artifactClass":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifactclass"},"artifactType":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifacttype"},"live":{"type":"boolean","title":"Live","default":false},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","templateName","title","status","content","qa","metadata","version","createdAt","updatedAt"],"title":"ArtifactResponse"},"ArtifactSummary":{"properties":{"id":{"type":"string","title":"Id"},"runId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Runid"},"templateId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Templateid"},"templateName":{"type":"string","title":"Templatename"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"title":{"type":"string","title":"Title"},"subtitle":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subtitle"},"status":{"type":"string","title":"Status"},"content":{"additionalProperties":true,"type":"object","title":"Content"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata"},"version":{"type":"integer","title":"Version"},"parentVersionId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parentversionid"},"versionNote":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Versionnote"},"specId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specid"},"specVersionHash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specversionhash"},"source":{"type":"string","title":"Source","default":"run"},"contextType":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contexttype"},"stageStepId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stagestepid"},"artifactClass":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifactclass"},"artifactType":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifacttype"},"live":{"type":"boolean","title":"Live","default":false},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","templateName","title","status","content","metadata","version","createdAt","updatedAt"],"title":"ArtifactSummary","description":"Slim list contract (perf 2026-07-10). List endpoints return this instead\nof the full ArtifactResponse: it drops ``qa`` (the grid never reads it) and\nthe ``cost_ledger`` array (each row carries a ``raw_provider_payload``). The\ngrid derives class and cost from ``metadata.runtimeProfile``, so both stay;\n``content`` stays because the thumbnail reads ``content.url``. The detail\nendpoint still returns the full ArtifactResponse with qa + ledger."},"AttemptSummary":{"properties":{"id":{"type":"string","title":"Id"},"orderId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Orderid"},"runId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Runid"},"status":{"type":"string","title":"Status"},"failure":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Failure"},"costUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Costusd"}},"type":"object","required":["id","status"],"title":"AttemptSummary"},"AttributionApplyResponse":{"properties":{"rowsUpdated":{"type":"integer","title":"Rowsupdated"}},"type":"object","required":["rowsUpdated"],"title":"AttributionApplyResponse"},"AttributionRuleCreate":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"provider":{"type":"string","enum":["stripe","plaid"],"title":"Provider"},"matchType":{"type":"string","enum":["product","product_type","customer","merchant","category","account"],"title":"Matchtype"},"matchValue":{"type":"string","title":"Matchvalue"},"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label"}},"type":"object","required":["workspaceId","provider","matchType","matchValue"],"title":"AttributionRuleCreate"},"AttributionRuleListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/AttributionRuleResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"AttributionRuleListResponse"},"AttributionRuleResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"provider":{"type":"string","title":"Provider"},"matchType":{"type":"string","title":"Matchtype"},"matchValue":{"type":"string","title":"Matchvalue"},"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label"},"confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Confidence"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","workspaceId","provider","matchType","matchValue","createdAt","updatedAt"],"title":"AttributionRuleResponse"},"AuthenticationOptionsResponse":{"properties":{"options":{"additionalProperties":true,"type":"object","title":"Options"},"hasPasskeys":{"type":"boolean","title":"Haspasskeys","default":true}},"type":"object","required":["options"],"title":"AuthenticationOptionsResponse"},"AuthenticationVerifyRequest":{"properties":{"credential":{"additionalProperties":true,"type":"object","title":"Credential"}},"type":"object","required":["credential"],"title":"AuthenticationVerifyRequest"},"AuthorCreate":{"properties":{"name":{"type":"string","title":"Name","default":""},"role":{"type":"string","title":"Role","default":""},"avatarUrl":{"type":"string","title":"Avatarurl","default":""}},"type":"object","title":"AuthorCreate"},"AuthorListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/AuthorResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"AuthorListResponse"},"AuthorRef":{"properties":{"name":{"type":"string","title":"Name","default":""},"role":{"type":"string","title":"Role","default":""},"avatar":{"type":"string","title":"Avatar","default":""}},"type":"object","title":"AuthorRef"},"AuthorResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"role":{"type":"string","title":"Role"},"avatarUrl":{"type":"string","title":"Avatarurl"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","name","role","avatarUrl","createdAt","updatedAt"],"title":"AuthorResponse"},"AuthorUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"},"avatarUrl":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Avatarurl"}},"type":"object","title":"AuthorUpdate"},"BalanceRefreshResponse":{"properties":{"connectionsRefreshed":{"type":"integer","title":"Connectionsrefreshed"},"accounts":{"type":"integer","title":"Accounts"},"cooldownSkipped":{"type":"integer","title":"Cooldownskipped"},"cooldownSeconds":{"type":"integer","title":"Cooldownseconds"}},"type":"object","required":["connectionsRefreshed","accounts","cooldownSkipped","cooldownSeconds"],"title":"BalanceRefreshResponse"},"BalanceSnapshotResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"accountId":{"type":"string","format":"uuid","title":"Accountid"},"currentBalanceCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Currentbalancecents"},"availableBalanceCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Availablebalancecents"},"creditLimitCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Creditlimitcents"},"currency":{"type":"string","title":"Currency"},"asOf":{"type":"string","format":"date-time","title":"Asof"}},"type":"object","required":["id","accountId","currency","asOf"],"title":"BalanceSnapshotResponse"},"BankAccountDetailResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"connectionId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Connectionid"},"provider":{"type":"string","title":"Provider"},"providerAccountId":{"type":"string","title":"Provideraccountid"},"institutionName":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Institutionname"},"name":{"type":"string","title":"Name"},"officialName":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Officialname"},"mask":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mask"},"type":{"type":"string","title":"Type"},"subtype":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subtype"},"currentBalanceCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Currentbalancecents"},"availableBalanceCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Availablebalancecents"},"creditLimitCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Creditlimitcents"},"currency":{"type":"string","title":"Currency"},"isBusiness":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Isbusiness"},"lastSyncedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastsyncedat"},"statementBalanceCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Statementbalancecents"},"minimumPaymentCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Minimumpaymentcents"},"lastPaymentAmountCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Lastpaymentamountcents"},"purchaseAprBps":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Purchaseaprbps"},"nextPaymentDueAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Nextpaymentdueat"},"lastPaymentAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastpaymentat"},"lastStatementAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Laststatementat"},"liabilitiesSyncedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Liabilitiessyncedat"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"},"snapshots":{"items":{"$ref":"#/components/schemas/BalanceSnapshotResponse"},"type":"array","title":"Snapshots","default":[]}},"type":"object","required":["id","workspaceId","provider","providerAccountId","name","type","currency","createdAt","updatedAt"],"title":"BankAccountDetailResponse"},"BankAccountListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/BankAccountResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"BankAccountListResponse"},"BankAccountResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"connectionId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Connectionid"},"provider":{"type":"string","title":"Provider"},"providerAccountId":{"type":"string","title":"Provideraccountid"},"institutionName":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Institutionname"},"name":{"type":"string","title":"Name"},"officialName":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Officialname"},"mask":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mask"},"type":{"type":"string","title":"Type"},"subtype":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subtype"},"currentBalanceCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Currentbalancecents"},"availableBalanceCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Availablebalancecents"},"creditLimitCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Creditlimitcents"},"currency":{"type":"string","title":"Currency"},"isBusiness":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Isbusiness"},"lastSyncedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastsyncedat"},"statementBalanceCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Statementbalancecents"},"minimumPaymentCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Minimumpaymentcents"},"lastPaymentAmountCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Lastpaymentamountcents"},"purchaseAprBps":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Purchaseaprbps"},"nextPaymentDueAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Nextpaymentdueat"},"lastPaymentAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastpaymentat"},"lastStatementAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Laststatementat"},"liabilitiesSyncedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Liabilitiessyncedat"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","workspaceId","provider","providerAccountId","name","type","currency","createdAt","updatedAt"],"title":"BankAccountResponse"},"BankTransactionListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/BankTransactionResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"offset":{"type":"integer","title":"Offset"},"limit":{"type":"integer","title":"Limit"},"spendingCents":{"type":"integer","title":"Spendingcents","default":0},"depositCents":{"type":"integer","title":"Depositcents","default":0},"netCashflowCents":{"type":"integer","title":"Netcashflowcents","default":0}},"type":"object","required":["items","total","offset","limit"],"title":"BankTransactionListResponse"},"BankTransactionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"accountId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Accountid"},"connectionId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Connectionid"},"provider":{"type":"string","title":"Provider"},"providerTransactionId":{"type":"string","title":"Providertransactionid"},"pendingTransactionId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pendingtransactionid"},"amountCents":{"type":"integer","title":"Amountcents"},"currency":{"type":"string","title":"Currency"},"merchantName":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Merchantname"},"counterparty":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Counterparty"},"categoryPrimary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Categoryprimary"},"categoryDetailed":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Categorydetailed"},"paymentChannel":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Paymentchannel"},"status":{"type":"string","title":"Status"},"pending":{"type":"boolean","title":"Pending"},"authorizedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Authorizedat"},"occurredAt":{"type":"string","format":"date-time","title":"Occurredat"},"removedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Removedat"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","workspaceId","provider","providerTransactionId","amountCents","currency","status","pending","occurredAt","createdAt","updatedAt"],"title":"BankTransactionResponse"},"BankingSummaryResponse":{"properties":{"groupBy":{"type":"string","title":"Groupby"},"currency":{"type":"string","title":"Currency","default":"USD"},"spendingCents":{"type":"integer","title":"Spendingcents"},"depositCents":{"type":"integer","title":"Depositcents"},"netCashflowCents":{"type":"integer","title":"Netcashflowcents"},"entryCount":{"type":"integer","title":"Entrycount"},"buckets":{"items":{"$ref":"#/components/schemas/FinanceBucket"},"type":"array","title":"Buckets"}},"type":"object","required":["groupBy","spendingCents","depositCents","netCashflowCents","entryCount","buckets"],"title":"BankingSummaryResponse"},"BankingSyncResponse":{"properties":{"connectionsSynced":{"type":"integer","title":"Connectionssynced"},"accounts":{"type":"integer","title":"Accounts"},"upserted":{"type":"integer","title":"Upserted"},"removed":{"type":"integer","title":"Removed"}},"type":"object","required":["connectionsSynced","accounts","upserted","removed"],"title":"BankingSyncResponse"},"BillingTerms":{"properties":{"version":{"type":"integer","const":1,"title":"Version","default":1},"model":{"type":"string","enum":["retainer","per_job","hourly","none"],"title":"Model","default":"none"},"amountCents":{"anyOf":[{"type":"integer","maximum":10000000000.0,"minimum":0.0},{"type":"null"}],"title":"Amountcents"},"currency":{"type":"string","pattern":"^[a-z]{3}$","title":"Currency","default":"usd"},"period":{"anyOf":[{"type":"string","enum":["month","quarter","year"]},{"type":"null"}],"title":"Period"},"scope":{"items":{"$ref":"#/components/schemas/ScopeLine"},"type":"array","maxItems":50,"title":"Scope"},"startsOn":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Startson"},"renewsOn":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Renewson"}},"type":"object","title":"BillingTerms"},"BindingCreate":{"properties":{"provider":{"type":"string","pattern":"^[a-z0-9_-]{2,40}$","title":"Provider"},"assetKind":{"type":"string","enum":["likeness","voice"],"title":"Assetkind"},"providerAssetId":{"type":"string","maxLength":200,"minLength":1,"title":"Providerassetid"},"providerConsentStatus":{"type":"string","enum":["not_required","pending","accepted","rejected"],"title":"Providerconsentstatus"},"providerConsentRef":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Providerconsentref"}},"type":"object","required":["provider","assetKind","providerAssetId","providerConsentStatus"],"title":"BindingCreate"},"BindingResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"versionId":{"type":"string","format":"uuid","title":"Versionid"},"provider":{"type":"string","title":"Provider"},"assetKind":{"type":"string","title":"Assetkind"},"providerAssetId":{"type":"string","title":"Providerassetid"},"providerConsentStatus":{"type":"string","enum":["not_required","pending","accepted","rejected"],"title":"Providerconsentstatus"},"providerConsentRef":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Providerconsentref"},"disabledAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Disabledat"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"}},"type":"object","required":["id","versionId","provider","assetKind","providerAssetId","providerConsentStatus","createdAt"],"title":"BindingResponse"},"BindingUpdate":{"properties":{"providerConsentStatus":{"anyOf":[{"type":"string","enum":["not_required","pending","accepted","rejected"]},{"type":"null"}],"title":"Providerconsentstatus"},"providerConsentRef":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Providerconsentref"},"disabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Disabled"}},"type":"object","title":"BindingUpdate"},"BlockPlacement":{"properties":{"id":{"type":"string","maxLength":100,"title":"Id"},"parentId":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Parentid"}},"type":"object","required":["id"],"title":"BlockPlacement"},"Body_post_v1_context_upload":{"properties":{"file":{"type":"string","contentMediaType":"application/octet-stream","title":"File"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary"},"tags":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tags"}},"type":"object","required":["file"],"title":"Body_post_v1_context_upload"},"Body_post_v1_media_images":{"properties":{"file":{"type":"string","contentMediaType":"application/octet-stream","title":"File"},"publicationId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publicationid"}},"type":"object","required":["file"],"title":"Body_post_v1_media_images"},"Body_post_v1_story-heroes":{"properties":{"glb":{"type":"string","contentMediaType":"application/octet-stream","title":"Glb"},"seriesId":{"type":"string","title":"Seriesid"},"clips":{"type":"string","title":"Clips","default":""},"shapeKeys":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Shapekeys"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},"type":"object","required":["glb","seriesId"],"title":"Body_post_v1_story-heroes"},"Body_post_v1_story-trinkets":{"properties":{"glb":{"type":"string","contentMediaType":"application/octet-stream","title":"Glb"},"seriesId":{"type":"string","title":"Seriesid"},"subject":{"type":"string","title":"Subject"},"earnedBy":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Earnedby"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},"type":"object","required":["glb","seriesId","subject"],"title":"Body_post_v1_story-trinkets"},"BrandCreateRequest":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"websiteUrl":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Websiteurl"}},"type":"object","required":["workspaceId","name"],"title":"BrandCreateRequest"},"BrandImportRequest":{"properties":{"websiteUrl":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Websiteurl"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"}},"type":"object","title":"BrandImportRequest"},"BrandListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/BrandResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"BrandListResponse"},"BrandProfilePatch":{"properties":{"businessName":{"anyOf":[{"type":"string","maxLength":120},{"type":"null"}],"title":"Businessname"},"websiteUrl":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Websiteurl"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"audiences":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Audiences"},"products":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Products"},"tone":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tone"},"visual":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Visual"},"claims":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Claims"}},"type":"object","title":"BrandProfilePatch","description":"PATCH body — every field optional; only sent fields change."},"BrandProfileResponse":{"properties":{"businessName":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Businessname"},"websiteUrl":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Websiteurl"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"audiences":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Audiences"},"products":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Products"},"tone":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tone"},"visual":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Visual"},"claims":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Claims"},"source":{"type":"string","title":"Source"},"currentSnapshotId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Currentsnapshotid"},"updatedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updatedat"}},"type":"object","required":["source"],"title":"BrandProfileResponse"},"BrandResponse":{"properties":{"projectId":{"type":"string","format":"uuid","title":"Projectid"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"slug":{"type":"string","title":"Slug"},"name":{"type":"string","title":"Name"},"archivedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Archivedat"},"profile":{"$ref":"#/components/schemas/BrandProfileResponse"},"createdAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Createdat"}},"type":"object","required":["projectId","workspaceId","slug","name","profile"],"title":"BrandResponse"},"BriefCreate":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"period":{"type":"string","enum":["daily","weekly"],"title":"Period","default":"daily"}},"type":"object","required":["workspaceId"],"title":"BriefCreate"},"BriefPage":{"properties":{"items":{"items":{"$ref":"#/components/schemas/app__schemas__planning__MessageResponse"},"type":"array","title":"Items"},"nextPageToken":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Nextpagetoken"}},"type":"object","required":["items"],"title":"BriefPage"},"BriefPeriod":{"properties":{"sendAtLocal":{"anyOf":[{"type":"string","maxLength":9},{"type":"null"}],"title":"Sendatlocal"},"covers":{"type":"string","enum":["previous_day","previous_week","since_last"],"title":"Covers","default":"since_last"},"headline":{"type":"string","enum":["day","answers","greeting"],"title":"Headline","default":"greeting"},"sections":{"items":{"$ref":"#/components/schemas/BriefSection"},"type":"array","maxItems":10,"minItems":1,"title":"Sections"}},"type":"object","required":["sections"],"title":"BriefPeriod"},"BriefSection":{"properties":{"key":{"type":"string","enum":["lead","numbers","wants_an_answer","by_client","money_in","everything_else","made","later","for_you","spend"],"title":"Key"},"title":{"anyOf":[{"type":"string","maxLength":80,"minLength":1},{"type":"null"}],"title":"Title"}},"type":"object","required":["key"],"title":"BriefSection"},"BudgetCreate":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"workflowId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Workflowid"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"limitUsd":{"type":"number","minimum":0.0,"title":"Limitusd"},"period":{"type":"string","enum":["total","daily","weekly","monthly"],"title":"Period","default":"monthly"},"perRunCapUsd":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Perruncapusd"},"enforcementMode":{"type":"string","enum":["hard_stop","allow_overage","allow_one_more","track_only"],"title":"Enforcementmode","default":"hard_stop"},"overageUsd":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Overageusd"}},"type":"object","required":["workspaceId","limitUsd"],"title":"BudgetCreate"},"BudgetListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/BudgetResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"BudgetListResponse"},"BudgetRefusalListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/BudgetRefusalResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"BudgetRefusalListResponse"},"BudgetRefusalResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"budgetId":{"type":"string","format":"uuid","title":"Budgetid"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"workflowId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Workflowid"},"source":{"type":"string","title":"Source"},"reason":{"type":"string","title":"Reason"},"runEstimateUsd":{"type":"number","title":"Runestimateusd"},"spendUsd":{"type":"number","title":"Spendusd"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"}},"type":"object","required":["id","budgetId","source","reason","runEstimateUsd","spendUsd","createdAt"],"title":"BudgetRefusalResponse"},"BudgetResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"workflowId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Workflowid"},"scope":{"type":"string","title":"Scope"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"limitUsd":{"type":"number","title":"Limitusd"},"period":{"type":"string","title":"Period"},"perRunCapUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Perruncapusd"},"enforcementMode":{"type":"string","title":"Enforcementmode"},"overageUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Overageusd"},"currency":{"type":"string","title":"Currency"},"refusalsThisWindow":{"type":"integer","title":"Refusalsthiswindow","default":0},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","workspaceId","scope","limitUsd","period","enforcementMode","currency","createdAt","updatedAt"],"title":"BudgetResponse"},"BudgetUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"limitUsd":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Limitusd"},"period":{"anyOf":[{"type":"string","enum":["total","daily","weekly","monthly"]},{"type":"null"}],"title":"Period"},"perRunCapUsd":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Perruncapusd"},"enforcementMode":{"anyOf":[{"type":"string","enum":["hard_stop","allow_overage","allow_one_more","track_only"]},{"type":"null"}],"title":"Enforcementmode"},"overageUsd":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Overageusd"}},"type":"object","title":"BudgetUpdate"},"BulkDecisionItem":{"properties":{"runId":{"type":"string","title":"Runid"},"decision":{"type":"string","enum":["approve","reject","request_changes"],"title":"Decision"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"patch":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Patch"},"gateId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gateid"}},"type":"object","required":["runId","decision"],"title":"BulkDecisionItem"},"BulkDecisionRequest":{"properties":{"decisions":{"items":{"$ref":"#/components/schemas/BulkDecisionItem"},"type":"array","title":"Decisions"}},"type":"object","required":["decisions"],"title":"BulkDecisionRequest"},"BulkDecisionResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/BulkDecisionResult"},"type":"array","title":"Results"}},"type":"object","required":["results"],"title":"BulkDecisionResponse"},"BulkDecisionResult":{"properties":{"runId":{"type":"string","title":"Runid"},"statusCode":{"type":"integer","title":"Statuscode"},"decision":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Decision"},"error":{"anyOf":[{},{"type":"null"}],"title":"Error"}},"type":"object","required":["runId","statusCode"],"title":"BulkDecisionResult","description":"Per-item outcome — bulk never rolls back across items; each row says\nwhat happened to ITS run (201 shape on success, the error detail on\nfailure)."},"CampaignBrief":{"properties":{"offer":{"type":"string","minLength":1,"title":"Offer"},"goal":{"type":"string","enum":["launch","promote","refresh_creative","grow_organic","other"],"title":"Goal","default":"promote"},"audience":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Audience"},"channels":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Channels"},"constraints":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Constraints"},"timeframe":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timeframe"}},"type":"object","required":["offer"],"title":"CampaignBrief","description":"The AMA-shaped brief (docs/make/11 §2). Outcomes only — never\nmechanisms: what's marketed, to whom, toward what goal, on which\nchannels."},"CampaignCreateRequest":{"properties":{"projectId":{"type":"string","format":"uuid","title":"Projectid"},"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"brief":{"$ref":"#/components/schemas/CampaignBrief"},"fulfillmentMode":{"type":"string","enum":["self_serve","managed"],"title":"Fulfillmentmode","default":"self_serve"}},"type":"object","required":["projectId","name","brief"],"title":"CampaignCreateRequest"},"CampaignListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/CampaignResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"CampaignListResponse"},"CampaignPatchRequest":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Name"},"brief":{"anyOf":[{"$ref":"#/components/schemas/CampaignBrief"},{"type":"null"}]}},"type":"object","title":"CampaignPatchRequest"},"CampaignResponse":{"properties":{"id":{"type":"string","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"type":"string","format":"uuid","title":"Projectid"},"name":{"type":"string","title":"Name"},"brief":{"additionalProperties":true,"type":"object","title":"Brief"},"fulfillmentMode":{"type":"string","title":"Fulfillmentmode"},"status":{"type":"string","title":"Status"},"brandSnapshotId":{"type":"string","title":"Brandsnapshotid"},"strategyArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Strategyartifactid"},"archivedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Archivedat"},"createdAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Createdat"},"updatedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updatedat"}},"type":"object","required":["id","workspaceId","projectId","name","brief","fulfillmentMode","status","brandSnapshotId"],"title":"CampaignResponse"},"CardObligation":{"properties":{"accountId":{"type":"string","format":"uuid","title":"Accountid"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"name":{"type":"string","title":"Name"},"institutionName":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Institutionname"},"mask":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mask"},"currentBalanceCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Currentbalancecents"},"creditLimitCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Creditlimitcents"},"utilizationBps":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Utilizationbps"},"statementBalanceCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Statementbalancecents"},"minimumPaymentCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Minimumpaymentcents"},"nextPaymentDueAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Nextpaymentdueat"},"daysUntilDue":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Daysuntildue"},"purchaseAprBps":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Purchaseaprbps"},"liabilitiesSyncedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Liabilitiessyncedat"}},"type":"object","required":["accountId","workspaceId","name"],"title":"CardObligation","description":"What one card demands, and when. Every term may be null (no coverage)."},"CaseItem":{"properties":{"caseId":{"type":"string","maxLength":100,"minLength":1,"title":"Caseid"},"intake":{"additionalProperties":true,"type":"object","title":"Intake"},"tags":{"additionalProperties":true,"type":"object","title":"Tags"},"holdout":{"type":"boolean","title":"Holdout","default":false},"source":{"additionalProperties":true,"type":"object","title":"Source"}},"type":"object","required":["caseId","intake"],"title":"CaseItem"},"CaseSetCreate":{"properties":{"name":{"type":"string","maxLength":200,"minLength":1,"title":"Name"},"description":{"type":"string","title":"Description","default":""},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"cases":{"items":{"$ref":"#/components/schemas/CaseItem"},"type":"array","title":"Cases"},"note":{"type":"string","title":"Note","default":""}},"type":"object","required":["name"],"title":"CaseSetCreate"},"CaseSetListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/CaseSetResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"CaseSetListResponse"},"CaseSetResponse":{"properties":{"id":{"type":"string","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"latestVersion":{"type":"integer","title":"Latestversion"},"latestVersionId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Latestversionid"},"caseCount":{"type":"integer","title":"Casecount","default":0},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","workspaceId","projectId","name","description","latestVersion","createdAt","updatedAt"],"title":"CaseSetResponse"},"CaseSetVersionCreate":{"properties":{"cases":{"items":{"$ref":"#/components/schemas/CaseItem"},"type":"array","title":"Cases"},"note":{"type":"string","title":"Note","default":""}},"type":"object","required":["cases"],"title":"CaseSetVersionCreate"},"CaseSetVersionResponse":{"properties":{"id":{"type":"string","title":"Id"},"caseSetId":{"type":"string","title":"Casesetid"},"version":{"type":"integer","title":"Version"},"contentHash":{"type":"string","title":"Contenthash"},"cases":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Cases"},"note":{"type":"string","title":"Note"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"}},"type":"object","required":["id","caseSetId","version","contentHash","cases","note","createdAt"],"title":"CaseSetVersionResponse"},"CashflowMonth":{"properties":{"period":{"type":"string","title":"Period"},"cashInCents":{"type":"integer","title":"Cashincents"},"cashOutCents":{"type":"integer","title":"Cashoutcents"},"netCents":{"type":"integer","title":"Netcents"},"closingBalanceCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Closingbalancecents"}},"type":"object","required":["period","cashInCents","cashOutCents","netCents"],"title":"CashflowMonth"},"CashflowSeriesResponse":{"properties":{"asOf":{"type":"string","format":"date-time","title":"Asof"},"currency":{"type":"string","title":"Currency","default":"USD"},"months":{"items":{"$ref":"#/components/schemas/CashflowMonth"},"type":"array","title":"Months"}},"type":"object","required":["asOf","months"],"title":"CashflowSeriesResponse"},"CatalogContract":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"shortDescription":{"type":"string","title":"Shortdescription"},"artifactClass":{"type":"string","title":"Artifactclass"},"outputType":{"type":"string","title":"Outputtype"},"status":{"type":"string","title":"Status"},"supersededById":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supersededbyid"},"version":{"type":"string","title":"Version"},"stages":{"items":{"$ref":"#/components/schemas/WorkflowStageSchema"},"type":"array","title":"Stages"},"intakeSchema":{"additionalProperties":true,"type":"object","title":"Intakeschema"},"runtimeSteps":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Runtimesteps"},"gates":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Gates"},"artifactSchema":{"additionalProperties":true,"type":"object","title":"Artifactschema"},"providers":{"additionalProperties":{"type":"string"},"type":"object","title":"Providers"},"budgetPolicy":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Budgetpolicy"},"versions":{"items":{"$ref":"#/components/schemas/CatalogVersionEntry"},"type":"array","title":"Versions"},"updatedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updatedat"}},"type":"object","required":["id","name","description","shortDescription","artifactClass","outputType","status","version","stages"],"title":"CatalogContract","description":"The public contract of one workflow template (plan:\ndocs/plans/2026-07-21-public-workflow-docs.md) — what\nesy.com/workflows/<id>/contract renders.\n\nWhitelist serialization, redaction by construction: a redacted property\nappears with the literal value \"redacted\" — the key's existence is public,\nits value is not (per-step system/promptTemplate/maxTokens; provider model\nbindings behind their role names; the budget policy). Deprecated templates\nARE served here (with supersededById) so retired public URLs can redirect;\nonly the list excludes them."},"CatalogEntry":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"shortDescription":{"type":"string","title":"Shortdescription"},"artifactClass":{"type":"string","title":"Artifactclass"},"outputType":{"type":"string","title":"Outputtype"},"depth":{"type":"string","title":"Depth"},"estimatedRuntime":{"type":"string","title":"Estimatedruntime"},"includesQa":{"type":"boolean","title":"Includesqa"},"stages":{"items":{"$ref":"#/components/schemas/WorkflowStageSchema"},"type":"array","title":"Stages"},"whatYouProvide":{"items":{"type":"string"},"type":"array","title":"Whatyouprovide"},"whatYouGet":{"items":{"type":"string"},"type":"array","title":"Whatyouget"},"qaChecks":{"items":{"type":"string"},"type":"array","title":"Qachecks"},"intakeSchema":{"additionalProperties":true,"type":"object","title":"Intakeschema"},"version":{"type":"string","title":"Version"},"cadence":{"type":"string","title":"Cadence"},"updatedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updatedat"}},"type":"object","required":["id","name","description","shortDescription","artifactClass","outputType","depth","estimatedRuntime","includesQa","stages","whatYouProvide","whatYouGet","qaChecks","version","cadence"],"title":"CatalogEntry","description":"A published Workflow Template as shown on the public catalog. Carries only\npresentation-safe fields — no prompts, providers, budget internals, or the raw\nruntime step graph. ``stages`` is the curated, display-only pipeline summary\n(name + one-line description + step count), so the marketing site can render\nthe workflow's shape without leaking the runtime definition.\n\n``intake_schema`` is also exposed: it's the operator-input contract (the fields\na user fills in to launch a run), which is presentation-safe — it describes\n*inputs*, not the runtime step graph — and lets consumers (the app's runner)\nrender a generic intake form straight from the published definition."},"CatalogResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/CatalogEntry"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"generatedAt":{"type":"string","format":"date-time","title":"Generatedat"}},"type":"object","required":["items","total","generatedAt"],"title":"CatalogResponse"},"CatalogVersionEntry":{"properties":{"version":{"type":"string","title":"Version"},"revision":{"type":"integer","title":"Revision"},"contentHash":{"type":"string","title":"Contenthash"},"createdAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Createdat"}},"type":"object","required":["version","revision","contentHash"],"title":"CatalogVersionEntry","description":"One immutable published version — public lineage metadata only, never\nthe definition snapshot."},"CategoryPresetCreate":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"name":{"type":"string","maxLength":120,"minLength":1,"title":"Name"},"description":{"type":"string","title":"Description","default":""},"categories":{"items":{"type":"string"},"type":"array","minItems":1,"title":"Categories"}},"type":"object","required":["workspaceId","name","categories"],"title":"CategoryPresetCreate"},"CategoryPresetListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/CategoryPresetResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"CategoryPresetListResponse"},"CategoryPresetResponse":{"properties":{"id":{"type":"string","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"categories":{"items":{"type":"string"},"type":"array","title":"Categories"},"createdByUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Createdbyuserid"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","workspaceId","name","description","categories","createdAt","updatedAt"],"title":"CategoryPresetResponse"},"CategoryPresetUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":120,"minLength":1},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"categories":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Categories"}},"type":"object","title":"CategoryPresetUpdate"},"CategoryRef":{"properties":{"id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Id"},"slug":{"type":"string","title":"Slug"},"label":{"type":"string","title":"Label","default":""}},"type":"object","required":["slug"],"title":"CategoryRef"},"CategoryReorder":{"properties":{"order":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Order"}},"type":"object","title":"CategoryReorder"},"CharacterConsentState":{"properties":{"state":{"type":"string","enum":["not_needed","active","missing","suspended","revoked","expired","pending","erased"],"title":"State"},"endsOn":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Endson"}},"type":"object","required":["state"],"title":"CharacterConsentState","description":"What a member may know: whether the character can be used today, and\nuntil when. The terms themselves are for owners and admins."},"CharacterCreate":{"properties":{"projectId":{"type":"string","format":"uuid","title":"Projectid"},"name":{"type":"string","maxLength":300,"minLength":1,"title":"Name"},"format":{"type":"string","enum":["synthetic","likeness"],"title":"Format"},"persona":{"anyOf":[{"$ref":"#/components/schemas/Persona"},{"type":"null"}]},"clientRef":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Clientref"},"requestId":{"anyOf":[{"type":"string","maxLength":64,"minLength":8},{"type":"null"}],"title":"Requestid"}},"type":"object","required":["projectId","name","format"],"title":"CharacterCreate"},"CharacterListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/CharacterResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"CharacterListResponse"},"CharacterResponse":{"properties":{"id":{"type":"string","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"type":"string","format":"uuid","title":"Projectid"},"name":{"type":"string","title":"Name"},"format":{"type":"string","enum":["synthetic","likeness"],"title":"Format"},"status":{"type":"string","title":"Status"},"persona":{"additionalProperties":true,"type":"object","title":"Persona"},"references":{"items":{"$ref":"#/components/schemas/ReferenceResponse"},"type":"array","title":"References"},"latestVersion":{"anyOf":[{"$ref":"#/components/schemas/VersionResponse"},{"type":"null"}]},"versionCount":{"type":"integer","title":"Versioncount","default":0},"subjectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Subjectid"},"consent":{"anyOf":[{"$ref":"#/components/schemas/CharacterConsentState"},{"type":"null"}]},"clientRef":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Clientref"},"etag":{"type":"string","title":"Etag"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","workspaceId","projectId","name","format","status","persona","etag","createdAt","updatedAt"],"title":"CharacterResponse"},"CharacterUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":300,"minLength":1},{"type":"null"}],"title":"Name"},"persona":{"anyOf":[{"$ref":"#/components/schemas/Persona"},{"type":"null"}]},"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag"}},"type":"object","title":"CharacterUpdate"},"CheckRequest":{"properties":{"media":{"items":{"type":"string","enum":["image","video","audio"]},"type":"array","minItems":1,"title":"Media"},"use":{"anyOf":[{"type":"string","enum":["organic","ads"]},{"type":"null"}],"title":"Use"},"channel":{"anyOf":[{"type":"string","pattern":"^[a-z0-9][a-z0-9_-]{0,39}$"},{"type":"null"}],"title":"Channel"},"territory":{"anyOf":[{"type":"string","pattern":"^[A-Z]{2}$"},{"type":"null"}],"title":"Territory"},"advertiser":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Advertiser"},"provider":{"anyOf":[{"type":"string","pattern":"^[a-z0-9_-]{2,40}$"},{"type":"null"}],"title":"Provider"},"on":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"On"},"version":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Version"}},"type":"object","title":"CheckRequest","description":"A planned use. Only media is required; the more you say, the more the\ngate can check against the consent's scope."},"CheckResponse":{"properties":{"ok":{"type":"boolean","title":"Ok"},"version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Version"},"reasons":{"items":{"type":"string"},"type":"array","title":"Reasons"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message"},"consentIds":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Consentids"},"disclosure":{"anyOf":[{"$ref":"#/components/schemas/Disclosure"},{"type":"null"}]}},"type":"object","required":["ok"],"title":"CheckResponse"},"ClientCreate":{"properties":{"name":{"type":"string","maxLength":200,"minLength":1,"title":"Name"},"slug":{"anyOf":[{"type":"string","maxLength":120},{"type":"null"}],"title":"Slug"},"status":{"type":"string","enum":["lead","active","paused","past"],"title":"Status","default":"active"},"billing":{"anyOf":[{"$ref":"#/components/schemas/BillingTerms"},{"type":"null"}]},"stripeCustomerId":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Stripecustomerid"},"notes":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}],"title":"Notes"},"requestId":{"anyOf":[{"type":"string","maxLength":64,"minLength":8},{"type":"null"}],"title":"Requestid"}},"type":"object","required":["name"],"title":"ClientCreate"},"ClientListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ClientResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"ClientListResponse"},"ClientProjectRef":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"slug":{"type":"string","title":"Slug"},"name":{"type":"string","title":"Name"}},"type":"object","required":["id","slug","name"],"title":"ClientProjectRef"},"ClientResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"status":{"type":"string","enum":["lead","active","paused","past"],"title":"Status"},"billing":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Billing"},"renewsOn":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Renewson"},"stripeCustomerId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stripecustomerid"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"etag":{"type":"string","title":"Etag"},"projects":{"items":{"$ref":"#/components/schemas/ClientProjectRef"},"type":"array","title":"Projects"},"rollup":{"anyOf":[{"$ref":"#/components/schemas/ClientRollup"},{"type":"null"}]},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"},"archivedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Archivedat"}},"type":"object","required":["id","workspaceId","name","slug","status","etag","createdAt","updatedAt"],"title":"ClientResponse"},"ClientRollup":{"properties":{"periodStart":{"type":"string","format":"date","title":"Periodstart"},"costUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Costusd"},"waitingOnYou":{"type":"integer","title":"Waitingonyou","default":0},"made":{"type":"integer","title":"Made","default":0},"expectedFeeCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Expectedfeecents"}},"type":"object","required":["periodStart"],"title":"ClientRollup","description":"This period's figures, computed through the client's projects. Money\nfields are null for members who aren't owners or admins."},"ClientUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":200,"minLength":1},{"type":"null"}],"title":"Name"},"slug":{"anyOf":[{"type":"string","maxLength":120},{"type":"null"}],"title":"Slug"},"status":{"anyOf":[{"type":"string","enum":["lead","active","paused","past"]},{"type":"null"}],"title":"Status"},"statusNote":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Statusnote"},"billing":{"anyOf":[{"$ref":"#/components/schemas/BillingTerms"},{"type":"null"}]},"clearBilling":{"type":"boolean","title":"Clearbilling","default":false},"stripeCustomerId":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Stripecustomerid"},"notes":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}],"title":"Notes"},"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag"}},"type":"object","title":"ClientUpdate","description":"PATCH semantics: only what is sent changes. The etag comes in the body\nor If-Match (API-003)."},"CollectionCost":{"properties":{"spendUsd":{"type":"number","title":"Spendusd","default":0.0}},"type":"object","title":"CollectionCost","description":"What every attempt at every member has cost so far, across all orders."},"CollectionListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/CollectionSummary"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"CollectionListResponse"},"CollectionProgress":{"properties":{"planned":{"type":"integer","title":"Planned","default":0},"pending":{"type":"integer","title":"Pending","default":0},"working":{"type":"integer","title":"Working","default":0},"review":{"type":"integer","title":"Review","default":0},"accepted":{"type":"integer","title":"Accepted","default":0},"failed":{"type":"integer","title":"Failed","default":0},"locked":{"type":"integer","title":"Locked","default":0},"removed":{"type":"integer","title":"Removed","default":0}},"type":"object","title":"CollectionProgress","description":"Member counts by status. `planned` is every member not removed."},"CollectionSummary":{"properties":{"id":{"type":"string","title":"Id"},"kind":{"type":"string","title":"Kind"},"format":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Format"},"status":{"type":"string","title":"Status"},"title":{"type":"string","title":"Title"},"etag":{"type":"string","title":"Etag"},"clientRef":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Clientref"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"sourceArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sourceartifactid"},"coverArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Coverartifactid"},"renditions":{"additionalProperties":true,"type":"object","title":"Renditions","default":{}},"delivery":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Delivery"},"progress":{"$ref":"#/components/schemas/CollectionProgress"},"cost":{"$ref":"#/components/schemas/CollectionCost"},"preview":{"items":{"$ref":"#/components/schemas/PreviewPiece"},"type":"array","title":"Preview","default":[]},"annotations":{"additionalProperties":true,"type":"object","title":"Annotations","default":{}},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","kind","status","title","etag","progress","cost","createdAt","updatedAt"],"title":"CollectionSummary"},"CommentCreateRequest":{"properties":{"body":{"type":"string","maxLength":4000,"minLength":1,"title":"Body"}},"type":"object","required":["body"],"title":"CommentCreateRequest"},"CommentListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/CommentResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"CommentListResponse"},"CommentResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"artifactId":{"type":"string","title":"Artifactid"},"authorUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Authoruserid"},"body":{"type":"string","title":"Body"},"createdAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Createdat"}},"type":"object","required":["id","artifactId","body"],"title":"CommentResponse"},"CompletenessPolicy":{"properties":{"mode":{"type":"string","enum":["all","threshold"],"title":"Mode"},"minSucceededRatio":{"anyOf":[{"type":"number","maximum":1.0,"exclusiveMinimum":0.0},{"type":"null"}],"title":"Minsucceededratio"}},"type":"object","required":["mode"],"title":"CompletenessPolicy","description":"What \"done\" means for this order (issue #198). `all`: completed only if\nevery child succeeds/holds. `threshold`: completed at minSucceededRatio of\ntarget, else the terminal state is `attention`."},"CompletionRequest":{"properties":{"model":{"type":"string","title":"Model","description":"Registry model id, e.g. 'anthropic/claude-sonnet-4-6'"},"messages":{"items":{"$ref":"#/components/schemas/AiMessage"},"type":"array","minItems":1,"title":"Messages"},"system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"System"},"stream":{"type":"boolean","title":"Stream","default":true},"maxOutputTokens":{"type":"integer","maximum":64000.0,"minimum":1.0,"title":"Maxoutputtokens","default":4096},"temperature":{"anyOf":[{"type":"number","maximum":2.0,"minimum":0.0},{"type":"null"}],"title":"Temperature"},"metadata":{"anyOf":[{"$ref":"#/components/schemas/AiRequestMetadata"},{"type":"null"}]}},"type":"object","required":["model","messages"],"title":"CompletionRequest"},"ConnectRequest":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"}},"type":"object","required":["workspaceId"],"title":"ConnectRequest"},"ConnectUrlResponse":{"properties":{"provider":{"type":"string","enum":["stripe","plaid"],"title":"Provider"},"status":{"type":"string","enum":["not_configured","ready"],"title":"Status"},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url"},"linkToken":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linktoken"},"message":{"type":"string","title":"Message"}},"type":"object","required":["provider","status","message"],"title":"ConnectUrlResponse"},"ConsentAction":{"properties":{"note":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Note"},"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag"}},"type":"object","title":"ConsentAction"},"ConsentCreate":{"properties":{"grantor":{"type":"string","enum":["self","representative"],"title":"Grantor"},"representation":{"type":"string","enum":["none","counsel","union"],"title":"Representation","default":"none"},"coversLikeness":{"type":"boolean","title":"Coverslikeness"},"coversVoice":{"type":"boolean","title":"Coversvoice"},"scope":{"$ref":"#/components/schemas/ConsentScope"},"trainingPermitted":{"type":"boolean","title":"Trainingpermitted","default":false},"startsOn":{"type":"string","format":"date","title":"Startson"},"endsOn":{"type":"string","format":"date","title":"Endson"},"compensationNote":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Compensationnote"},"evidenceKind":{"type":"string","enum":["signed_document","recorded_statement","provider_verified"],"title":"Evidencekind"},"evidenceArtifactId":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Evidenceartifactid"},"evidenceSha256":{"type":"string","pattern":"^[0-9a-f]{64}$","title":"Evidencesha256"},"retainAssetsUntil":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Retainassetsuntil"},"requestId":{"anyOf":[{"type":"string","maxLength":64,"minLength":8},{"type":"null"}],"title":"Requestid"}},"type":"object","required":["grantor","coversLikeness","coversVoice","scope","startsOn","endsOn","evidenceKind","evidenceSha256"],"title":"ConsentCreate"},"ConsentEventResponse":{"properties":{"event":{"type":"string","title":"Event"},"actorUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Actoruserid"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"at":{"type":"string","format":"date-time","title":"At"}},"type":"object","required":["event","at"],"title":"ConsentEventResponse"},"ConsentResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"subjectId":{"type":"string","format":"uuid","title":"Subjectid"},"status":{"type":"string","enum":["pending","active","suspended","revoked"],"title":"Status"},"usableToday":{"type":"boolean","title":"Usabletoday"},"grantor":{"type":"string","title":"Grantor"},"representation":{"type":"string","title":"Representation"},"coversLikeness":{"type":"boolean","title":"Coverslikeness"},"coversVoice":{"type":"boolean","title":"Coversvoice"},"scope":{"additionalProperties":true,"type":"object","title":"Scope"},"trainingPermitted":{"type":"boolean","title":"Trainingpermitted"},"startsOn":{"type":"string","format":"date","title":"Startson"},"endsOn":{"type":"string","format":"date","title":"Endson"},"compensationNote":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Compensationnote"},"evidenceKind":{"type":"string","title":"Evidencekind"},"evidenceArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Evidenceartifactid"},"evidenceSha256":{"type":"string","title":"Evidencesha256"},"retainAssetsUntil":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Retainassetsuntil"},"activatedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Activatedat"},"revokedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Revokedat"},"revokedReason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Revokedreason"},"etag":{"type":"string","title":"Etag"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"}},"type":"object","required":["id","subjectId","status","usableToday","grantor","representation","coversLikeness","coversVoice","scope","trainingPermitted","startsOn","endsOn","evidenceKind","evidenceSha256","etag","createdAt"],"title":"ConsentResponse"},"ConsentScope":{"properties":{"version":{"type":"integer","const":1,"title":"Version","default":1},"uses":{"items":{"type":"string","enum":["organic","ads"]},"type":"array","minItems":1,"title":"Uses"},"media":{"items":{"type":"string","enum":["image","video","audio"]},"type":"array","minItems":1,"title":"Media"},"channels":{"items":{"type":"string"},"type":"array","maxItems":30,"minItems":1,"title":"Channels"},"territories":{"items":{"type":"string"},"type":"array","maxItems":60,"minItems":1,"title":"Territories"},"advertisers":{"items":{"type":"string"},"type":"array","maxItems":30,"title":"Advertisers"},"productLines":{"items":{"type":"string"},"type":"array","maxItems":30,"title":"Productlines"}},"type":"object","required":["uses","media","channels","territories"],"title":"ConsentScope","description":"What the person agreed to: a \"reasonably specific description of the\nintended uses\" (CA Labor Code §927, NY GOB §5-302), structured so the gate\ncan check every run against it. Anything outside it needs a new consent."},"ContactCreate":{"properties":{"name":{"type":"string","maxLength":200,"minLength":1,"title":"Name"},"email":{"anyOf":[{"type":"string","maxLength":320,"pattern":"^[^@\\s]+@[^@\\s]+$"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string","maxLength":40},{"type":"null"}],"title":"Phone"},"role":{"anyOf":[{"type":"string","maxLength":120},{"type":"null"}],"title":"Role"},"approves":{"type":"boolean","title":"Approves","default":false}},"type":"object","required":["name"],"title":"ContactCreate"},"ContactResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"clientId":{"type":"string","format":"uuid","title":"Clientid"},"name":{"type":"string","title":"Name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"},"approves":{"type":"boolean","title":"Approves"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","clientId","name","approves","createdAt","updatedAt"],"title":"ContactResponse"},"ContactUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":200,"minLength":1},{"type":"null"}],"title":"Name"},"email":{"anyOf":[{"type":"string","maxLength":320,"pattern":"^[^@\\s]+@[^@\\s]+$"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string","maxLength":40},{"type":"null"}],"title":"Phone"},"role":{"anyOf":[{"type":"string","maxLength":120},{"type":"null"}],"title":"Role"},"approves":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Approves"}},"type":"object","title":"ContactUpdate"},"CopilotMessage":{"properties":{"role":{"type":"string","enum":["user","assistant"],"title":"Role"},"content":{"type":"string","maxLength":20000,"title":"Content"}},"type":"object","required":["role","content"],"title":"CopilotMessage"},"CopilotTurnRequest":{"properties":{"messages":{"items":{"$ref":"#/components/schemas/CopilotMessage"},"type":"array","maxItems":60,"minItems":1,"title":"Messages"},"draft":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Draft"},"focus":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Focus"},"runId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Runid"}},"type":"object","required":["messages"],"title":"CopilotTurnRequest","description":"One stateless turn. `draft` is the Factory build page's in-progress\ntemplate (same dict shape the dry-run/estimate endpoints take); `focus`\nis the currently-selected node (e.g. \"step-3\"); `run_id` points the\nconversation at a specific run (usually a failed one)."},"CopyCta":{"properties":{"label":{"type":"string","maxLength":200,"title":"Label","default":""},"action":{"type":"string","title":"Action","default":"call"},"backupLabel":{"type":"string","maxLength":200,"title":"Backuplabel","default":""}},"type":"object","title":"CopyCta"},"CopyItem":{"properties":{"title":{"type":"string","maxLength":500,"title":"Title","default":""},"text":{"type":"string","maxLength":4000,"title":"Text","default":""}},"type":"object","title":"CopyItem"},"CostBucket":{"properties":{"key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Key"},"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label"},"estimatedUsd":{"type":"number","title":"Estimatedusd"},"actualUsd":{"type":"number","title":"Actualusd"},"spendUsd":{"type":"number","title":"Spendusd"},"entryCount":{"type":"integer","title":"Entrycount"}},"type":"object","required":["estimatedUsd","actualUsd","spendUsd","entryCount"],"title":"CostBucket","description":"One aggregation group (e.g. a provider, a workflow, or a time period)."},"CostEstimateResponse":{"properties":{"estimatedCost":{"$ref":"#/components/schemas/CostRange"},"estimatedTokens":{"$ref":"#/components/schemas/TokenRange"},"breakdown":{"items":{"$ref":"#/components/schemas/StepCostBreakdown"},"type":"array","title":"Breakdown"},"pricingVersion":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pricingversion"},"highCost":{"type":"boolean","title":"Highcost","default":false},"thresholdUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Thresholdusd"}},"type":"object","required":["estimatedCost","estimatedTokens","breakdown"],"title":"CostEstimateResponse"},"CostRange":{"properties":{"min":{"type":"number","title":"Min"},"typical":{"type":"number","title":"Typical"},"max":{"type":"number","title":"Max"},"currency":{"type":"string","title":"Currency","default":"USD"}},"type":"object","required":["min","typical","max"],"title":"CostRange"},"CostSummaryResponse":{"properties":{"groupBy":{"type":"string","title":"Groupby"},"currency":{"type":"string","title":"Currency","default":"USD"},"estimatedUsd":{"type":"number","title":"Estimatedusd"},"actualUsd":{"type":"number","title":"Actualusd"},"spendUsd":{"type":"number","title":"Spendusd"},"entryCount":{"type":"integer","title":"Entrycount"},"buckets":{"items":{"$ref":"#/components/schemas/CostBucket"},"type":"array","title":"Buckets"}},"type":"object","required":["groupBy","estimatedUsd","actualUsd","spendUsd","entryCount","buckets"],"title":"CostSummaryResponse"},"CoverBackfillRequest":{"properties":{"limit":{"type":"integer","maximum":500.0,"minimum":1.0,"title":"Limit"},"maxSpendUsd":{"type":"number","maximum":100.0,"exclusiveMinimum":0.0,"title":"Maxspendusd"}},"type":"object","required":["limit","maxSpendUsd"],"title":"CoverBackfillRequest","description":"POST /v1/orders/backfill-covers — make covers for finished packs that\nhave none, so the publish sweep can ship them.\n\nBoth bounds are required and neither has a generous default: this spends\nmoney, and a batch job that spends by default is a batch job that spends\nby accident."},"CoverBackfillResponse":{"properties":{"started":{"type":"integer","title":"Started"},"orderIds":{"items":{"type":"string"},"type":"array","title":"Orderids"},"estimatedSpendUsd":{"type":"number","title":"Estimatedspendusd"},"skipped":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Skipped"}},"type":"object","required":["started","orderIds","estimatedSpendUsd","skipped"],"title":"CoverBackfillResponse"},"CreateApiKeyRequest":{"properties":{"name":{"type":"string","title":"Name"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"}},"type":"object","required":["name"],"title":"CreateApiKeyRequest"},"CreateRunRequest":{"properties":{"templateId":{"type":"string","title":"Templateid"},"intake":{"additionalProperties":true,"type":"object","title":"Intake"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"providers":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Providers"}},"type":"object","required":["templateId","intake"],"title":"CreateRunRequest"},"CreatedApiKeyResponse":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"keyPrefix":{"type":"string","title":"Keyprefix"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"lastUsedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastusedat"},"revokedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Revokedat"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"secret":{"type":"string","title":"Secret"}},"type":"object","required":["id","name","keyPrefix","workspaceId","lastUsedAt","revokedAt","createdAt","secret"],"title":"CreatedApiKeyResponse","description":"Mint response — the only time the secret is ever returned."},"CurrentArtifact":{"properties":{"artifactId":{"type":"string","title":"Artifactid"},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url"},"runId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Runid"}},"type":"object","required":["artifactId"],"title":"CurrentArtifact"},"DeclineBody":{"properties":{"reason":{"type":"string","title":"Reason"}},"type":"object","required":["reason"],"title":"DeclineBody"},"DeletionQueue":{"properties":{"items":{"items":{"$ref":"#/components/schemas/DeletionRequestRow"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"openCount":{"type":"integer","title":"Opencount"},"overdueCount":{"type":"integer","title":"Overduecount"}},"type":"object","required":["items","total","openCount","overdueCount"],"title":"DeletionQueue"},"DeletionRequestRow":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"userId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Userid"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"status":{"type":"string","title":"Status"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"},"requestedAt":{"type":"string","format":"date-time","title":"Requestedat"},"respondBy":{"type":"string","format":"date-time","title":"Respondby"},"daysRemaining":{"type":"integer","title":"Daysremaining"},"approvedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Approvedat"},"effectiveAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Effectiveat"},"declinedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Declinedat"},"declineReason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Declinereason"},"adminNote":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Adminnote"},"completedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completedat"},"reviewedByEmail":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reviewedbyemail"},"purgedCounts":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Purgedcounts"}},"type":"object","required":["id","userId","email","status","reason","requestedAt","respondBy","daysRemaining"],"title":"DeletionRequestRow"},"DerivedFrom":{"properties":{"briefArtifactId":{"type":"string","title":"Briefartifactid"},"segmentKey":{"type":"string","title":"Segmentkey"}},"type":"object","required":["briefArtifactId","segmentKey"],"title":"DerivedFrom","description":"Demand provenance (docs/CONTEXT.md): the demand-brief segment a\ngoal/specialty/produces was seeded from. Provenance only — deliberately no\nFK; the shift executor resolves the segment from the latest ready brief."},"Disclosure":{"properties":{"aiGenerated":{"type":"boolean","title":"Aigenerated","default":true},"depicts":{"type":"string","enum":["synthetic","likeness"],"title":"Depicts"},"syntheticPerformer":{"type":"boolean","title":"Syntheticperformer"},"label":{"type":"string","title":"Label"}},"type":"object","required":["depicts","syntheticPerformer","label"],"title":"Disclosure"},"DocumentCreate":{"properties":{"kind":{"type":"string","enum":["essay","article"],"title":"Kind","default":"essay"},"title":{"type":"string","title":"Title","default":""},"contentJson":{"additionalProperties":true,"type":"object","title":"Contentjson"}},"type":"object","title":"DocumentCreate"},"DocumentListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/DocumentResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"DocumentListResponse"},"DocumentResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"publicationId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Publicationid"},"kind":{"type":"string","title":"Kind"},"status":{"type":"string","title":"Status"},"title":{"type":"string","title":"Title"},"slug":{"type":"string","title":"Slug"},"description":{"type":"string","title":"Description"},"category":{"type":"string","title":"Category"},"categoryLabel":{"type":"string","title":"Categorylabel"},"muxPlaybackId":{"type":"string","title":"Muxplaybackid"},"durationSeconds":{"type":"integer","title":"Durationseconds"},"thumbnailUrl":{"type":"string","title":"Thumbnailurl"},"templateSlug":{"type":"string","title":"Templateslug"},"stages":{"items":{},"type":"array","title":"Stages"},"tags":{"items":{},"type":"array","title":"Tags"},"relatedSlugs":{"items":{},"type":"array","title":"Relatedslugs"},"contentJson":{"additionalProperties":true,"type":"object","title":"Contentjson"},"contentMarkdown":{"type":"string","title":"Contentmarkdown"},"excerpt":{"type":"string","title":"Excerpt"},"wordCount":{"type":"integer","title":"Wordcount"},"citationCount":{"type":"integer","title":"Citationcount"},"publishedAt":{"type":"string","title":"Publishedat"},"firstPublishedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Firstpublishedat"},"newsletterStatus":{"type":"string","title":"Newsletterstatus","default":""},"newsletterBeehiivPostId":{"type":"string","title":"Newsletterbeehiivpostid","default":""},"newsletterDraftedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Newsletterdraftedat"},"newsletterSubject":{"type":"string","title":"Newslettersubject","default":""},"newsletterPreviewText":{"type":"string","title":"Newsletterpreviewtext","default":""},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"},"categoryIds":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Categoryids"},"author":{"additionalProperties":true,"type":"object","title":"Author"}},"type":"object","required":["id","kind","status","title","slug","description","category","categoryLabel","muxPlaybackId","durationSeconds","thumbnailUrl","templateSlug","stages","tags","relatedSlugs","contentJson","contentMarkdown","excerpt","wordCount","citationCount","publishedAt","createdAt","updatedAt"],"title":"DocumentResponse"},"DocumentUpdate":{"properties":{"publicationId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Publicationid"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"categoryLabel":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Categorylabel"},"muxPlaybackId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Muxplaybackid"},"durationSeconds":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Durationseconds"},"thumbnailUrl":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Thumbnailurl"},"templateSlug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Templateslug"},"stages":{"anyOf":[{"items":{"$ref":"#/components/schemas/StageItem"},"type":"array"},{"type":"null"}],"title":"Stages"},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags"},"relatedSlugs":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Relatedslugs"},"contentJson":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Contentjson"},"contentMarkdown":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contentmarkdown"},"excerpt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Excerpt"},"wordCount":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Wordcount"},"citationCount":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Citationcount"},"publishedAt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publishedat"},"categoryIds":{"anyOf":[{"items":{"type":"string","format":"uuid"},"type":"array"},{"type":"null"}],"title":"Categoryids"},"author":{"anyOf":[{"$ref":"#/components/schemas/AuthorRef"},{"type":"null"}]}},"type":"object","title":"DocumentUpdate"},"DryRunRef":{"properties":{"path":{"type":"string","title":"Path"},"kind":{"type":"string","title":"Kind"},"status":{"type":"string","title":"Status"},"detail":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Detail"}},"type":"object","required":["path","kind","status"],"title":"DryRunRef","description":"One `{dotted.path}` (or path-valued field) referenced by a step, with whether\nit resolves against the sample intake / upstream step graph."},"DryRunRequest":{"properties":{"runtimeSteps":{"items":{},"type":"array","title":"Runtimesteps"},"providers":{"additionalProperties":{"type":"string"},"type":"object","title":"Providers"},"intakeSchema":{"additionalProperties":true,"type":"object","title":"Intakeschema"},"intake":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Intake"},"thresholdUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Thresholdusd"}},"type":"object","title":"DryRunRequest","description":"A draft (possibly-unsaved) template to resolve and validate without spending.\n\nMirrors the /estimate body so the Factory can test the current draft before it\nis published. `intake` is an optional sample; when omitted a sample is\nsynthesized from `intake_schema` so reference resolution can run."},"DryRunStep":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"kind":{"type":"string","title":"Kind"},"resolvedSystem":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resolvedsystem"},"resolvedPrompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resolvedprompt"},"references":{"items":{"$ref":"#/components/schemas/DryRunRef"},"type":"array","title":"References"},"subWorkflow":{"anyOf":[{"$ref":"#/components/schemas/DryRunSub"},{"type":"null"}]},"errors":{"items":{"type":"string"},"type":"array","title":"Errors"},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings"}},"type":"object","required":["id","name","kind"],"title":"DryRunStep"},"DryRunSub":{"properties":{"templateId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Templateid"},"resolved":{"type":"boolean","title":"Resolved","default":false},"mappings":{"items":{"$ref":"#/components/schemas/DryRunSubMapping"},"type":"array","title":"Mappings"}},"type":"object","title":"DryRunSub"},"DryRunSubMapping":{"properties":{"childField":{"type":"string","title":"Childfield"},"sourcePath":{"type":"string","title":"Sourcepath"},"status":{"type":"string","title":"Status"}},"type":"object","required":["childField","sourcePath","status"],"title":"DryRunSubMapping"},"EstimateRequest":{"properties":{"runtimeSteps":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Runtimesteps","default":[]},"providers":{"additionalProperties":{"type":"string"},"type":"object","title":"Providers","default":{}},"thresholdUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Thresholdusd"}},"type":"object","title":"EstimateRequest","description":"A draft workflow definition to price. The Factory sends its in-progress\nruntime steps + provider bindings; the estimator resolves each step's model\nagainst the registry."},"ExperimentCreate":{"properties":{"name":{"type":"string","maxLength":200,"minLength":1,"title":"Name"},"kind":{"type":"string","enum":["ab","benchmark","canary"],"title":"Kind","default":"ab"},"hypothesis":{"type":"string","title":"Hypothesis","default":""},"primaryMetric":{"$ref":"#/components/schemas/MetricRef"},"guardrailMetrics":{"items":{"$ref":"#/components/schemas/MetricRef"},"type":"array","title":"Guardrailmetrics"},"analysisPlan":{"$ref":"#/components/schemas/AnalysisPlan"},"repeats":{"type":"integer","maximum":10.0,"minimum":1.0,"title":"Repeats","default":1},"budgetLimitUsd":{"anyOf":[{"type":"number","exclusiveMinimum":0.0},{"type":"null"}],"title":"Budgetlimitusd"},"budgetEnforcementMode":{"type":"string","enum":["hard_stop","allow_overage","track_only"],"title":"Budgetenforcementmode","default":"hard_stop"},"concurrency":{"type":"integer","maximum":16.0,"minimum":1.0,"title":"Concurrency","default":4},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"caseSetVersionId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Casesetversionid"},"caseSetId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Casesetid"},"arms":{"items":{"$ref":"#/components/schemas/ArmCreate"},"type":"array","title":"Arms"}},"type":"object","required":["name","primaryMetric"],"title":"ExperimentCreate"},"ExperimentListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ExperimentResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"ExperimentListResponse"},"ExperimentResponse":{"properties":{"id":{"type":"string","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"createdByUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Createdbyuserid"},"name":{"type":"string","title":"Name"},"kind":{"type":"string","title":"Kind"},"status":{"type":"string","title":"Status"},"hypothesis":{"type":"string","title":"Hypothesis"},"primaryMetric":{"additionalProperties":true,"type":"object","title":"Primarymetric"},"guardrailMetrics":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Guardrailmetrics"},"analysisPlan":{"additionalProperties":true,"type":"object","title":"Analysisplan"},"repeats":{"type":"integer","title":"Repeats"},"baselineArmKey":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Baselinearmkey"},"caseSetVersionId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Casesetversionid"},"designHash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Designhash"},"frozenAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Frozenat"},"budgetLimitUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Budgetlimitusd"},"budgetEnforcementMode":{"type":"string","title":"Budgetenforcementmode"},"estimatedCostUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Estimatedcostusd"},"actualCostUsd":{"type":"number","title":"Actualcostusd"},"concurrency":{"type":"integer","title":"Concurrency"},"counts":{"additionalProperties":{"type":"integer"},"type":"object","title":"Counts"},"reportArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reportartifactid"},"decisionArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Decisionartifactid"},"templateOfId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Templateofid"},"scheduleId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scheduleid"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"startedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Startedat"},"completedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completedat"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"},"arms":{"items":{"$ref":"#/components/schemas/ArmResponse"},"type":"array","title":"Arms"}},"type":"object","required":["id","workspaceId","projectId","createdByUserId","name","kind","status","hypothesis","primaryMetric","guardrailMetrics","analysisPlan","repeats","baselineArmKey","caseSetVersionId","designHash","frozenAt","budgetLimitUsd","budgetEnforcementMode","estimatedCostUsd","actualCostUsd","concurrency","counts","reportArtifactId","decisionArtifactId","templateOfId","scheduleId","error","startedAt","completedAt","createdAt","updatedAt"],"title":"ExperimentResponse"},"ExperimentUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"hypothesis":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hypothesis"},"primaryMetric":{"anyOf":[{"$ref":"#/components/schemas/MetricRef"},{"type":"null"}]},"guardrailMetrics":{"anyOf":[{"items":{"$ref":"#/components/schemas/MetricRef"},"type":"array"},{"type":"null"}],"title":"Guardrailmetrics"},"analysisPlan":{"anyOf":[{"$ref":"#/components/schemas/AnalysisPlan"},{"type":"null"}]},"repeats":{"anyOf":[{"type":"integer","maximum":10.0,"minimum":1.0},{"type":"null"}],"title":"Repeats"},"budgetLimitUsd":{"anyOf":[{"type":"number","exclusiveMinimum":0.0},{"type":"null"}],"title":"Budgetlimitusd"},"budgetEnforcementMode":{"anyOf":[{"type":"string","enum":["hard_stop","allow_overage","track_only"]},{"type":"null"}],"title":"Budgetenforcementmode"},"concurrency":{"anyOf":[{"type":"integer","maximum":16.0,"minimum":1.0},{"type":"null"}],"title":"Concurrency"},"caseSetVersionId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Casesetversionid"},"caseSetId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Casesetid"}},"type":"object","title":"ExperimentUpdate","description":"Draft-only edits to the design; after freeze only the name survives."},"FailureExplanationResponse":{"properties":{"title":{"type":"string","title":"Title"},"explanation":{"type":"string","title":"Explanation"},"likelyFixes":{"items":{"type":"string"},"type":"array","title":"Likelyfixes"},"owner":{"type":"string","title":"Owner"}},"type":"object","required":["title","explanation","owner"],"title":"FailureExplanationResponse","description":"Plain-language reading of a failure code (app/services/failure_registry.py).\nAdditive: null whenever the code is unknown to the registry — clients keep\nrendering the raw error either way."},"FinanceAlertPreferencesResponse":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"largeTransactionCents":{"type":"integer","title":"Largetransactioncents"},"materialBalanceChangeCents":{"type":"integer","title":"Materialbalancechangecents"},"newMerchantAlerts":{"type":"boolean","title":"Newmerchantalerts"},"creditUtilizationAlertBps":{"type":"integer","title":"Creditutilizationalertbps"},"categorySpikeBps":{"type":"integer","title":"Categoryspikebps"},"categorySpikeMinCents":{"type":"integer","title":"Categoryspikemincents"},"staleConnectionHours":{"type":"integer","title":"Staleconnectionhours"},"negativeCashflowWindowDays":{"type":"integer","title":"Negativecashflowwindowdays"},"digestEnabled":{"type":"boolean","title":"Digestenabled"},"digestHourLocal":{"type":"integer","title":"Digesthourlocal"},"digestTimezone":{"type":"string","title":"Digesttimezone"}},"type":"object","required":["workspaceId","largeTransactionCents","materialBalanceChangeCents","newMerchantAlerts","creditUtilizationAlertBps","categorySpikeBps","categorySpikeMinCents","staleConnectionHours","negativeCashflowWindowDays","digestEnabled","digestHourLocal","digestTimezone"],"title":"FinanceAlertPreferencesResponse"},"FinanceAlertPreferencesUpdate":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"largeTransactionCents":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Largetransactioncents"},"materialBalanceChangeCents":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Materialbalancechangecents"},"newMerchantAlerts":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Newmerchantalerts"},"creditUtilizationAlertBps":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Creditutilizationalertbps"},"categorySpikeBps":{"anyOf":[{"type":"integer","minimum":10000.0},{"type":"null"}],"title":"Categoryspikebps"},"categorySpikeMinCents":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Categoryspikemincents"},"staleConnectionHours":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Staleconnectionhours"},"negativeCashflowWindowDays":{"anyOf":[{"type":"integer","maximum":90.0,"minimum":1.0},{"type":"null"}],"title":"Negativecashflowwindowdays"},"digestEnabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Digestenabled"},"digestHourLocal":{"anyOf":[{"type":"integer","maximum":23.0,"minimum":0.0},{"type":"null"}],"title":"Digesthourlocal"},"digestTimezone":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Digesttimezone"}},"type":"object","required":["workspaceId"],"title":"FinanceAlertPreferencesUpdate","description":"Partial update; omitted fields keep their stored (or default) values."},"FinanceBucket":{"properties":{"key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Key"},"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label"},"grossAmountCents":{"type":"integer","title":"Grossamountcents","default":0},"feeAmountCents":{"type":"integer","title":"Feeamountcents","default":0},"netAmountCents":{"type":"integer","title":"Netamountcents","default":0},"spendingCents":{"type":"integer","title":"Spendingcents","default":0},"depositCents":{"type":"integer","title":"Depositcents","default":0},"entryCount":{"type":"integer","title":"Entrycount"}},"type":"object","required":["entryCount"],"title":"FinanceBucket"},"FinanceOverviewAccount":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"connectionId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Connectionid"},"name":{"type":"string","title":"Name"},"institutionName":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Institutionname"},"mask":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mask"},"type":{"type":"string","title":"Type"},"subtype":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subtype"},"currentBalanceCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Currentbalancecents"},"availableBalanceCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Availablebalancecents"},"creditLimitCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Creditlimitcents"},"currency":{"type":"string","title":"Currency"},"lastSyncedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastsyncedat"},"statementBalanceCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Statementbalancecents"},"minimumPaymentCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Minimumpaymentcents"},"nextPaymentDueAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Nextpaymentdueat"},"purchaseAprBps":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Purchaseaprbps"}},"type":"object","required":["id","name","type","currency"],"title":"FinanceOverviewAccount"},"FinanceOverviewConnection":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"provider":{"type":"string","title":"Provider"},"institutionName":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Institutionname"},"status":{"type":"string","title":"Status"},"healthStatus":{"type":"string","title":"Healthstatus"},"userActionRequired":{"type":"boolean","title":"Useractionrequired"},"userActionReason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Useractionreason"},"lastSyncedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastsyncedat"},"lastSyncFailedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastsyncfailedat"}},"type":"object","required":["id","provider","status","healthStatus","userActionRequired"],"title":"FinanceOverviewConnection","description":"A connection surfaced because it needs a look — never carries secrets."},"FinanceOverviewResponse":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"asOf":{"type":"string","format":"date-time","title":"Asof"},"currency":{"type":"string","title":"Currency","default":"USD"},"cashCurrentCents":{"type":"integer","title":"Cashcurrentcents"},"cashAvailableCents":{"type":"integer","title":"Cashavailablecents"},"cardBalanceCents":{"type":"integer","title":"Cardbalancecents"},"cardLimitCents":{"type":"integer","title":"Cardlimitcents"},"cardUtilizationBps":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Cardutilizationbps"},"cashAccounts":{"items":{"$ref":"#/components/schemas/FinanceOverviewAccount"},"type":"array","title":"Cashaccounts"},"creditAccounts":{"items":{"$ref":"#/components/schemas/FinanceOverviewAccount"},"type":"array","title":"Creditaccounts"},"recentTransactions":{"items":{"$ref":"#/components/schemas/BankTransactionResponse"},"type":"array","title":"Recenttransactions"},"lastSuccessfulSyncAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastsuccessfulsyncat"},"connectionsNeedingAttention":{"items":{"$ref":"#/components/schemas/FinanceOverviewConnection"},"type":"array","title":"Connectionsneedingattention"}},"type":"object","required":["workspaceId","asOf","cashCurrentCents","cashAvailableCents","cardBalanceCents","cardLimitCents","cashAccounts","creditAccounts","recentTransactions","connectionsNeedingAttention"],"title":"FinanceOverviewResponse"},"FinanceReportLine":{"properties":{"label":{"type":"string","title":"Label"},"amountCents":{"type":"integer","title":"Amountcents"},"entryCount":{"type":"integer","title":"Entrycount","default":0}},"type":"object","required":["label","amountCents"],"title":"FinanceReportLine"},"FinanceReportResponse":{"properties":{"workspaceKind":{"type":"string","title":"Workspacekind"},"period":{"type":"string","title":"Period"},"from":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"From"},"to":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"To"},"revenueCents":{"type":"integer","title":"Revenuecents","default":0},"revenueFeeCents":{"type":"integer","title":"Revenuefeecents","default":0},"esySpendCents":{"type":"integer","title":"Esyspendcents","default":0},"marginCents":{"type":"integer","title":"Margincents","default":0},"bankSpendingCents":{"type":"integer","title":"Bankspendingcents","default":0},"bankDepositCents":{"type":"integer","title":"Bankdepositcents","default":0},"netCashflowCents":{"type":"integer","title":"Netcashflowcents","default":0},"transactionCount":{"type":"integer","title":"Transactioncount","default":0},"topSpending":{"items":{"$ref":"#/components/schemas/FinanceReportLine"},"type":"array","title":"Topspending","default":[]},"largestTransactions":{"items":{"$ref":"#/components/schemas/FinanceReportLine"},"type":"array","title":"Largesttransactions","default":[]}},"type":"object","required":["workspaceKind","period"],"title":"FinanceReportResponse"},"FinanceRunwayResponse":{"properties":{"asOf":{"type":"string","format":"date-time","title":"Asof"},"currency":{"type":"string","title":"Currency","default":"USD"},"cashCents":{"type":"integer","title":"Cashcents"},"cashAvailableCents":{"type":"integer","title":"Cashavailablecents"},"cashByWorkspace":{"items":{"$ref":"#/components/schemas/RunwayWorkspaceCash"},"type":"array","title":"Cashbyworkspace"},"cardBalanceCents":{"type":"integer","title":"Cardbalancecents"},"cardLimitCents":{"type":"integer","title":"Cardlimitcents"},"netBurnCentsPerMonth":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Netburncentspermonth"},"burnWindows":{"items":{"$ref":"#/components/schemas/RunwayBurnWindow"},"type":"array","title":"Burnwindows"},"runwayMonths":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Runwaymonths"},"runwayMonthsLow":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Runwaymonthslow"},"runwayMonthsHigh":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Runwaymonthshigh"},"zeroCashDate":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Zerocashdate"},"monthlyCommittedCents":{"type":"integer","title":"Monthlycommittedcents"},"stripeNetCents":{"type":"integer","title":"Stripenetcents"},"excludedTransferCents":{"type":"integer","title":"Excludedtransfercents"},"excludedTransferPairs":{"type":"integer","title":"Excludedtransferpairs"},"excludedCardActivityCents":{"type":"integer","title":"Excludedcardactivitycents"},"observedDays":{"type":"integer","title":"Observeddays"},"countedTransactionCount":{"type":"integer","title":"Countedtransactioncount"},"includePersonal":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Includepersonal"},"ownerFlows":{"anyOf":[{"$ref":"#/components/schemas/OwnerFlows"},{"type":"null"}]}},"type":"object","required":["asOf","cashCents","cashAvailableCents","cashByWorkspace","cardBalanceCents","cardLimitCents","burnWindows","monthlyCommittedCents","stripeNetCents","excludedTransferCents","excludedTransferPairs","excludedCardActivityCents","observedDays","countedTransactionCount"],"title":"FinanceRunwayResponse","description":"The headline number, plus everything needed to check it by hand.\n\nNulls are load-bearing: `runway_months` is null when burn is unmeasurable\n(too little history) AND when the accounts are net positive, because\n\"infinite\" is a sentence, not a figure. Never render a null as 0."},"FinancialConnectionListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/FinancialConnectionResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"FinancialConnectionListResponse"},"FinancialConnectionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"provider":{"type":"string","title":"Provider"},"externalAccountId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Externalaccountid"},"institutionName":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Institutionname"},"environment":{"type":"string","title":"Environment"},"scopes":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Scopes"},"products":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Products"},"status":{"type":"string","title":"Status"},"lastSyncedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastsyncedat"},"healthStatus":{"type":"string","title":"Healthstatus"},"userActionRequired":{"type":"boolean","title":"Useractionrequired"},"userActionReason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Useractionreason"},"lastWebhookAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastwebhookat"},"lastSyncFailedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastsyncfailedat"},"lastBalanceRefreshedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastbalancerefreshedat"},"connectedByUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Connectedbyuserid"},"connectedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Connectedat"},"revokedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Revokedat"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","workspaceId","provider","environment","status","healthStatus","userActionRequired","createdAt","updatedAt"],"title":"FinancialConnectionResponse"},"GatherFactsRequest":{"properties":{"businessName":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}],"title":"Businessname"},"phone":{"anyOf":[{"type":"string","maxLength":40},{"type":"null"}],"title":"Phone"},"websiteUrl":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Websiteurl"},"serviceArea":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Servicearea"},"services":{"items":{"type":"string"},"type":"array","maxItems":50,"title":"Services"},"licences":{"items":{"type":"string"},"type":"array","maxItems":20,"title":"Licences"},"prices":{"items":{"type":"string"},"type":"array","maxItems":50,"title":"Prices"},"photoUrls":{"items":{"type":"string"},"type":"array","maxItems":50,"title":"Photourls"},"reviews":{"items":{"$ref":"#/components/schemas/ReviewInput"},"type":"array","maxItems":50,"title":"Reviews"},"businessProfileUrl":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Businessprofileurl"},"address":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Address"},"hours":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Hours"},"details":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Details"},"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag"},"requestId":{"anyOf":[{"type":"string","maxLength":64,"minLength":8},{"type":"null"}],"title":"Requestid"}},"type":"object","title":"GatherFactsRequest","description":"What the client supplies about their business, in their own words.\nEverything is optional: the website and Business Profile fill in what\nthey can, and whatever stays missing comes back as questions."},"GenerationOrderCreate":{"properties":{"workflowId":{"type":"string","title":"Workflowid"},"workflowVersion":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Workflowversion"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"intakeBase":{"additionalProperties":true,"type":"object","title":"Intakebase"},"variationSpec":{"$ref":"#/components/schemas/VariationSpec"},"targetCount":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Targetcount"},"executionMode":{"type":"string","enum":["standard","batch"],"title":"Executionmode","default":"standard"},"budgetLimitUsd":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Budgetlimitusd"},"budgetEnforcementMode":{"anyOf":[{"type":"string","enum":["hard_stop","allow_overage","allow_one_more","track_only"]},{"type":"null"}],"title":"Budgetenforcementmode"},"completenessPolicy":{"anyOf":[{"$ref":"#/components/schemas/CompletenessPolicy"},{"type":"null"}]},"retryPolicy":{"anyOf":[{"$ref":"#/components/schemas/RetryPolicy"},{"type":"null"}]},"providerOverrides":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Provideroverrides"},"planArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Planartifactid"},"coverArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Coverartifactid"}},"type":"object","required":["workflowId","variationSpec"],"title":"GenerationOrderCreate"},"GenerationOrderListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/GenerationOrderResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"GenerationOrderListResponse"},"GenerationOrderResponse":{"properties":{"id":{"type":"string","title":"Id"},"workflowId":{"type":"string","title":"Workflowid"},"workflowVersion":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Workflowversion"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"intakeBase":{"additionalProperties":true,"type":"object","title":"Intakebase"},"variationSpec":{"additionalProperties":true,"type":"object","title":"Variationspec"},"targetCount":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Targetcount"},"publishOffer":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publishoffer"},"executionMode":{"type":"string","title":"Executionmode"},"status":{"type":"string","title":"Status"},"counts":{"additionalProperties":true,"type":"object","title":"Counts"},"budgetLimitUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Budgetlimitusd"},"budgetEnforcementMode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Budgetenforcementmode"},"currency":{"type":"string","title":"Currency"},"estimatedCostUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Estimatedcostusd"},"actualCostUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Actualcostusd"},"completenessPolicy":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Completenesspolicy"},"completeness":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Completeness"},"retryPolicy":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Retrypolicy"},"retries":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Retries"},"requestRepairs":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Requestrepairs"},"batchState":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Batchstate"},"coverRunId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Coverrunid"},"delivery":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Delivery"},"acceptedGap":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Acceptedgap"},"planArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Planartifactid"},"coverArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Coverartifactid"},"collectionId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Collectionid"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","workflowId","intakeBase","variationSpec","executionMode","status","counts","currency","createdAt","updatedAt"],"title":"GenerationOrderResponse"},"GoalCreate":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"title":{"type":"string","maxLength":255,"minLength":1,"title":"Title"},"description":{"type":"string","title":"Description","default":""},"horizon":{"type":"string","enum":["vision","year","quarter","month","week"],"title":"Horizon","default":"quarter"},"startsOn":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Startson"},"endsOn":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Endson"},"assigneeWorkerId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assigneeworkerid"},"target":{"anyOf":[{"$ref":"#/components/schemas/GoalTarget"},{"type":"null"}]},"derivedFrom":{"anyOf":[{"$ref":"#/components/schemas/DerivedFrom"},{"type":"null"}]},"position":{"type":"integer","title":"Position","default":0}},"type":"object","required":["workspaceId","title"],"title":"GoalCreate"},"GoalListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/GoalResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"GoalListResponse"},"GoalResponse":{"properties":{"id":{"type":"string","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"userId":{"type":"string","format":"uuid","title":"Userid"},"title":{"type":"string","title":"Title"},"description":{"type":"string","title":"Description"},"horizon":{"type":"string","title":"Horizon"},"startsOn":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Startson"},"endsOn":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Endson"},"status":{"type":"string","title":"Status"},"assigneeWorkerId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assigneeworkerid"},"target":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Target"},"derivedFrom":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Derivedfrom"},"progressCount":{"type":"integer","title":"Progresscount","default":0},"progressUpdatedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Progressupdatedat"},"achievedBy":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Achievedby"},"activity":{"items":{},"type":"array","title":"Activity"},"position":{"type":"integer","title":"Position"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","workspaceId","userId","title","description","horizon","status","position","createdAt","updatedAt"],"title":"GoalResponse"},"GoalTarget":{"properties":{"count":{"type":"integer","minimum":1.0,"title":"Count"},"categories":{"items":{"type":"string"},"type":"array","minItems":1,"title":"Categories"},"templateId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Templateid"}},"type":"object","required":["count","categories"],"title":"GoalTarget","description":"The measurable definition of done: N catalog artifacts in these\ncategories (optionally narrowed to one template). Required on goals\nassigned to a worker — a worker never holds an outcome nobody can verify."},"GoalUpdate":{"properties":{"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"title":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"horizon":{"anyOf":[{"type":"string","enum":["vision","year","quarter","month","week"]},{"type":"null"}],"title":"Horizon"},"startsOn":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Startson"},"endsOn":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Endson"},"status":{"anyOf":[{"type":"string","enum":["active","achieved","dropped","deferred"]},{"type":"null"}],"title":"Status"},"assigneeWorkerId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assigneeworkerid"},"target":{"anyOf":[{"$ref":"#/components/schemas/GoalTarget"},{"type":"null"}]},"derivedFrom":{"anyOf":[{"$ref":"#/components/schemas/DerivedFrom"},{"type":"null"}]},"position":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Position"}},"type":"object","title":"GoalUpdate"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"InsightRequest":{"properties":{"content_type":{"type":"string","pattern":"^(essay|report|article)$","title":"Content Type","default":"essay"},"slug":{"type":"string","maxLength":255,"minLength":1,"title":"Slug"},"selected_text":{"type":"string","maxLength":1000,"minLength":10,"title":"Selected Text"},"surrounding_context":{"type":"string","maxLength":3000,"minLength":20,"title":"Surrounding Context"},"section_title":{"type":"string","maxLength":500,"title":"Section Title","default":""},"title":{"type":"string","maxLength":500,"minLength":1,"title":"Title"},"category":{"type":"string","maxLength":100,"minLength":1,"title":"Category"},"depth":{"type":"string","pattern":"^(standard|deep)$","title":"Depth","default":"standard"}},"type":"object","required":["slug","selected_text","surrounding_context","title","category"],"title":"InsightRequest"},"InsightResponse":{"properties":{"insight":{"type":"string","title":"Insight"},"source":{"type":"string","title":"Source"},"canGoDeeper":{"type":"boolean","title":"Cangodeeper"}},"type":"object","required":["insight","source","canGoDeeper"],"title":"InsightResponse"},"InvestmentAccountListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/InvestmentAccountResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"InvestmentAccountListResponse"},"InvestmentAccountResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"connectionId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Connectionid"},"provider":{"type":"string","title":"Provider"},"providerAccountId":{"type":"string","title":"Provideraccountid"},"institutionName":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Institutionname"},"name":{"type":"string","title":"Name"},"mask":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mask"},"type":{"type":"string","title":"Type"},"subtype":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subtype"},"currentBalanceCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Currentbalancecents"},"availableBalanceCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Availablebalancecents"},"currency":{"type":"string","title":"Currency"},"lastSyncedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastsyncedat"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","workspaceId","provider","providerAccountId","name","type","currency","createdAt","updatedAt"],"title":"InvestmentAccountResponse"},"InvestmentTransactionListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/InvestmentTransactionResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"offset":{"type":"integer","title":"Offset"},"limit":{"type":"integer","title":"Limit"}},"type":"object","required":["items","total","offset","limit"],"title":"InvestmentTransactionListResponse"},"InvestmentTransactionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"accountId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Accountid"},"connectionId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Connectionid"},"provider":{"type":"string","title":"Provider"},"providerTransactionId":{"type":"string","title":"Providertransactionid"},"amountCents":{"type":"integer","title":"Amountcents"},"feesCents":{"type":"integer","title":"Feescents"},"currency":{"type":"string","title":"Currency"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Type"},"subtype":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subtype"},"occurredAt":{"type":"string","format":"date-time","title":"Occurredat"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","workspaceId","provider","providerTransactionId","amountCents","feesCents","currency","occurredAt","createdAt","updatedAt"],"title":"InvestmentTransactionResponse"},"LetterStylePut":{"properties":{"key":{"anyOf":[{"type":"string","maxLength":40},{"type":"null"}],"title":"Key"},"spec":{"anyOf":[{"$ref":"#/components/schemas/LetterStyleSpec"},{"type":"null"}]},"etag":{"anyOf":[{"type":"string","maxLength":40},{"type":"null"}],"title":"Etag"}},"type":"object","title":"LetterStylePut","description":"Choose a platform style by `key`, or save a custom `spec`. Exactly one.\nGoing back to the default is choosing it: `{\"key\": \"edition\"}`. The etag\nmay come here or in `If-Match`; output fields sent back are ignored."},"LetterStyleResponse":{"properties":{"workspaceId":{"type":"string","title":"Workspaceid"},"source":{"type":"string","enum":["default","platform","custom"],"title":"Source"},"style":{"$ref":"#/components/schemas/LetterStyleSpec"},"etag":{"type":"string","title":"Etag"}},"type":"object","required":["workspaceId","source","style","etag"],"title":"LetterStyleResponse","description":"A workspace's resolved style. `source` says where it came from:\n`default` (no choice made), `platform` (a chosen platform style), or\n`custom` (a spec saved for this workspace)."},"LetterStyleSpec":{"properties":{"version":{"type":"integer","const":1,"title":"Version","default":1},"key":{"type":"string","maxLength":40,"minLength":1,"pattern":"^[a-z0-9][a-z0-9-]*$","title":"Key"},"name":{"type":"string","maxLength":80,"minLength":1,"title":"Name"},"voice":{"$ref":"#/components/schemas/Voice"},"subject":{"$ref":"#/components/schemas/Subject"},"summary":{"$ref":"#/components/schemas/Summary"},"letters":{"additionalProperties":{"items":{"type":"string","enum":["summary","prose","asks","facts","checks","gallery","callout"]},"type":"array"},"propertyNames":{"enum":["shift_report","escalation"]},"type":"object","title":"Letters"},"briefs":{"additionalProperties":{"$ref":"#/components/schemas/BriefPeriod"},"propertyNames":{"enum":["daily","weekly"]},"type":"object","title":"Briefs"}},"type":"object","required":["key","name"],"title":"LetterStyleSpec"},"LibraryAliasResponse":{"properties":{"name":{"type":"string","title":"Name"},"version":{"type":"integer","title":"Version"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["name","version","updatedAt"],"title":"LibraryAliasResponse"},"LibraryItemCreate":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"name":{"type":"string","maxLength":160,"minLength":1,"title":"Name"},"slug":{"anyOf":[{"type":"string","maxLength":160},{"type":"null"}],"title":"Slug"},"description":{"type":"string","title":"Description","default":""},"payload":{"additionalProperties":true,"type":"object","title":"Payload"},"notes":{"type":"string","title":"Notes","default":""},"facets":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Facets"}},"type":"object","required":["workspaceId","name","payload"],"title":"LibraryItemCreate"},"LibraryItemDetailResponse":{"properties":{"id":{"type":"string","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"kind":{"type":"string","title":"Kind"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"description":{"type":"string","title":"Description"},"facets":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Facets"},"archivedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Archivedat"},"createdByUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Createdbyuserid"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"},"latestVersion":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Latestversion"},"aliases":{"items":{"$ref":"#/components/schemas/LibraryAliasResponse"},"type":"array","title":"Aliases","default":[]},"live":{"anyOf":[{"$ref":"#/components/schemas/LibraryVersionResponse"},{"type":"null"}]},"versions":{"items":{"$ref":"#/components/schemas/LibraryVersionResponse"},"type":"array","title":"Versions","default":[]}},"type":"object","required":["id","workspaceId","kind","name","slug","description","createdAt","updatedAt"],"title":"LibraryItemDetailResponse"},"LibraryItemListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/LibraryItemResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"LibraryItemListResponse"},"LibraryItemResponse":{"properties":{"id":{"type":"string","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"kind":{"type":"string","title":"Kind"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"description":{"type":"string","title":"Description"},"facets":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Facets"},"archivedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Archivedat"},"createdByUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Createdbyuserid"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"},"latestVersion":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Latestversion"},"aliases":{"items":{"$ref":"#/components/schemas/LibraryAliasResponse"},"type":"array","title":"Aliases","default":[]},"live":{"anyOf":[{"$ref":"#/components/schemas/LibraryVersionResponse"},{"type":"null"}]}},"type":"object","required":["id","workspaceId","kind","name","slug","description","createdAt","updatedAt"],"title":"LibraryItemResponse"},"LibraryItemUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":160,"minLength":1},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived"},"facets":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Facets"}},"type":"object","title":"LibraryItemUpdate","description":"Identity only. Content changes publish a version; they never patch.\nFacets are identity: setting them never mints a version."},"LibraryVersionCreate":{"properties":{"payload":{"additionalProperties":true,"type":"object","title":"Payload"},"notes":{"type":"string","title":"Notes","default":""},"promoteTo":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}],"title":"Promoteto"}},"type":"object","required":["payload"],"title":"LibraryVersionCreate"},"LibraryVersionResponse":{"properties":{"id":{"type":"string","title":"Id"},"itemId":{"type":"string","title":"Itemid"},"version":{"type":"integer","title":"Version"},"payload":{"additionalProperties":true,"type":"object","title":"Payload"},"notes":{"type":"string","title":"Notes"},"createdByUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Createdbyuserid"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"aliases":{"items":{"type":"string"},"type":"array","title":"Aliases","default":[]}},"type":"object","required":["id","itemId","version","payload","notes","createdAt"],"title":"LibraryVersionResponse"},"LoginRequest":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"password":{"type":"string","title":"Password"}},"type":"object","required":["email","password"],"title":"LoginRequest"},"MakeFrameRequest":{"properties":{"brandColor":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}],"title":"Brandcolor"},"style":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}],"title":"Style"},"logoUrl":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Logourl"},"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag"},"requestId":{"anyOf":[{"type":"string","maxLength":64,"minLength":8},{"type":"null"}],"title":"Requestid"}},"type":"object","title":"MakeFrameRequest","description":"How the site should look, when the owner has a view."},"ManagedRequestStatus":{"properties":{"status":{"type":"string","enum":["not_submitted","submitted","in_review","accepted","declined"],"title":"Status"},"submittedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Submittedat"},"notes":{"items":{"type":"string"},"type":"array","title":"Notes","default":[]}},"type":"object","required":["status"],"title":"ManagedRequestStatus","description":"The customer-safe view of a managed request — a projection of the\nlinked planning-plane task, in Make's vocabulary, never the operator's."},"MediaAssetCreate":{"properties":{"muxPlaybackId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Muxplaybackid"},"durationSeconds":{"type":"integer","title":"Durationseconds","default":0},"aspectRatio":{"type":"string","title":"Aspectratio","default":""},"artifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifactid"},"title":{"type":"string","title":"Title","default":""}},"type":"object","title":"MediaAssetCreate","description":"Finalize an upload (ready_* fields from the poll response) or import an\nartifact (artifact_id). Exactly one source per request."},"MediaAssetListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/MediaAssetResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"MediaAssetListResponse"},"MediaAssetResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"kind":{"type":"string","title":"Kind"},"provider":{"type":"string","title":"Provider"},"source":{"type":"string","title":"Source"},"artifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifactid"},"title":{"type":"string","title":"Title"},"muxPlaybackId":{"type":"string","title":"Muxplaybackid"},"url":{"type":"string","title":"Url"},"mimeType":{"type":"string","title":"Mimetype"},"durationSeconds":{"type":"integer","title":"Durationseconds"},"aspectRatio":{"type":"string","title":"Aspectratio"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"}},"type":"object","required":["id","kind","provider","source","title","muxPlaybackId","url","mimeType","durationSeconds","aspectRatio","createdAt"],"title":"MediaAssetResponse"},"MessageCreate":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"kind":{"type":"string","enum":["alert","report","message"],"title":"Kind","default":"message"},"subject":{"type":"string","maxLength":500,"minLength":1,"title":"Subject"},"body":{"type":"string","title":"Body","default":""},"technicalDetail":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Technicaldetail"},"links":{"additionalProperties":true,"type":"object","title":"Links"},"content":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Content"}},"type":"object","required":["workspaceId","subject"],"title":"MessageCreate"},"MessageListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/app__schemas__planning__MessageResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"MessageListResponse"},"MessagePage":{"properties":{"items":{"items":{"$ref":"#/components/schemas/app__schemas__document_agent__MessageResponse"},"type":"array","title":"Items"},"hasMore":{"type":"boolean","title":"Hasmore"},"nextBeforeSequence":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Nextbeforesequence"}},"type":"object","required":["items","hasMore"],"title":"MessagePage","description":"Sequence-cursor page, ascending. `nextBeforeSequence` fetches older."},"MessageUpdate":{"properties":{"read":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Read"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived"}},"type":"object","title":"MessageUpdate","description":"Inbox state transitions only — a message's content is immutable."},"MetricRef":{"properties":{"scorer":{"type":"string","title":"Scorer"},"key":{"type":"string","title":"Key"},"direction":{"type":"string","enum":["higher","lower"],"title":"Direction","default":"higher"},"threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Threshold"},"maxDegradation":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Maxdegradation"}},"type":"object","required":["scorer","key"],"title":"MetricRef","description":"Which number decides. ``scorer`` names a registered scorer, ``key`` one\nof its metric keys; ``threshold`` is where a pass-rate is read."},"MfaStatusResponse":{"properties":{"enabled":{"type":"boolean","title":"Enabled"},"passkeyCount":{"type":"integer","title":"Passkeycount"},"recoveryCodesRemaining":{"type":"integer","title":"Recoverycodesremaining"}},"type":"object","required":["enabled","passkeyCount","recoveryCodesRemaining"],"title":"MfaStatusResponse"},"MfaVerifyResponse":{"properties":{"verified":{"type":"boolean","title":"Verified"},"mfaToken":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mfatoken"}},"type":"object","required":["verified"],"title":"MfaVerifyResponse"},"ModelEntry":{"properties":{"id":{"type":"string","title":"Id"},"provider":{"type":"string","title":"Provider"},"modelId":{"type":"string","title":"Modelid"},"displayName":{"type":"string","title":"Displayname"},"capability":{"type":"string","title":"Capability"},"pricing":{"$ref":"#/components/schemas/ModelPricing"},"contextWindow":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Contextwindow"},"status":{"type":"string","title":"Status","default":"active"},"pricingVersion":{"type":"string","title":"Pricingversion"},"sourceUrl":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sourceurl"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"cacheMode":{"type":"string","enum":["none","openai_implicit","anthropic_auto","gemini_implicit"],"title":"Cachemode","default":"none"},"supportsStructuredOutput":{"type":"boolean","title":"Supportsstructuredoutput","default":false},"supportsNativeTransparency":{"type":"boolean","title":"Supportsnativetransparency","default":false}},"type":"object","required":["id","provider","modelId","displayName","capability","pricing","pricingVersion"],"title":"ModelEntry","description":"A selectable model in the registry. Single source of truth for the\nFactory model picker and for cost estimation."},"ModelListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ModelEntry"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"ModelListResponse"},"ModelPricing":{"properties":{"inputPerMtokUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Inputpermtokusd"},"outputPerMtokUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Outputpermtokusd"},"cacheReadPerMtokUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cachereadpermtokusd"},"cacheWritePerMtokUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cachewritepermtokusd"},"perImageUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Perimageusd"},"perImageByAspectUsd":{"anyOf":[{"additionalProperties":{"type":"number"},"type":"object"},{"type":"null"}],"title":"Perimagebyaspectusd"},"perImageByQualityAspectUsd":{"anyOf":[{"additionalProperties":{"additionalProperties":{"type":"number"},"type":"object"},"type":"object"},{"type":"null"}],"title":"Perimagebyqualityaspectusd"},"perSecondUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Persecondusd"},"per1KTokensUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Per1Ktokensusd"},"tokenFps":{"type":"integer","title":"Tokenfps","default":24},"videoInputMultiplier":{"type":"number","title":"Videoinputmultiplier","default":0.6},"perRequestUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Perrequestusd"},"per1KCharsUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Per1Kcharsusd"}},"type":"object","title":"ModelPricing"},"MuxUploadResponse":{"properties":{"uploadId":{"type":"string","title":"Uploadid"},"uploadUrl":{"type":"string","title":"Uploadurl"}},"type":"object","required":["uploadId","uploadUrl"],"title":"MuxUploadResponse"},"MuxUploadStatusResponse":{"properties":{"status":{"type":"string","title":"Status"},"playbackId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Playbackid"},"durationSeconds":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Durationseconds"},"aspectRatio":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Aspectratio"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"}},"type":"object","required":["status"],"title":"MuxUploadStatusResponse"},"NewsletterConnect":{"properties":{"beehiivPublicationId":{"type":"string","title":"Beehiivpublicationid"},"beehiivApiKey":{"type":"string","title":"Beehiivapikey"}},"type":"object","required":["beehiivPublicationId","beehiivApiKey"],"title":"NewsletterConnect"},"NewsletterDraftRequest":{"properties":{"subject":{"type":"string","title":"Subject","default":""},"previewText":{"type":"string","title":"Previewtext","default":""}},"type":"object","title":"NewsletterDraftRequest"},"NewsletterDraftResult":{"properties":{"status":{"type":"string","title":"Status"},"beehiivPostId":{"type":"string","title":"Beehiivpostid"},"draftedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Draftedat"},"reviewUrl":{"type":"string","title":"Reviewurl","default":"https://app.beehiiv.com/posts"}},"type":"object","required":["status","beehiivPostId"],"title":"NewsletterDraftResult"},"NewsletterVerifyResult":{"properties":{"status":{"type":"string","title":"Status"},"detail":{"type":"string","title":"Detail","default":""},"publicationName":{"type":"string","title":"Publicationname","default":""}},"type":"object","required":["status"],"title":"NewsletterVerifyResult"},"ObligationsResponse":{"properties":{"asOf":{"type":"string","format":"date-time","title":"Asof"},"currency":{"type":"string","title":"Currency","default":"USD"},"totalCardBalanceCents":{"type":"integer","title":"Totalcardbalancecents"},"totalStatementBalanceCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Totalstatementbalancecents"},"totalMinimumPaymentCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Totalminimumpaymentcents"},"cardsWithTerms":{"type":"integer","title":"Cardswithterms"},"cardsTotal":{"type":"integer","title":"Cardstotal"},"items":{"items":{"$ref":"#/components/schemas/CardObligation"},"type":"array","title":"Items"}},"type":"object","required":["asOf","totalCardBalanceCents","cardsWithTerms","cardsTotal","items"],"title":"ObligationsResponse"},"OrderAcceptGapRequest":{"properties":{"reason":{"type":"string","maxLength":500,"minLength":1,"title":"Reason"}},"type":"object","required":["reason"],"title":"OrderAcceptGapRequest","description":"POST /v1/orders/{id}/accept-gap — settle a short order deliberately."},"OrderRefillSkipped":{"properties":{"runId":{"type":"string","title":"Runid"},"reason":{"type":"string","title":"Reason"}},"type":"object","required":["runId","reason"],"title":"OrderRefillSkipped","description":"A gap this refill deliberately did not re-run, and why."},"OrderRetryChild":{"properties":{"runId":{"type":"string","title":"Runid"},"patch":{"additionalProperties":true,"type":"object","title":"Patch"}},"type":"object","required":["runId"],"title":"OrderRetryChild"},"OrderRetryFailedRequest":{"properties":{"children":{"anyOf":[{"items":{"$ref":"#/components/schemas/OrderRetryChild"},"type":"array"},{"type":"null"}],"title":"Children"},"all":{"type":"boolean","title":"All","default":false},"includeDeterministic":{"type":"boolean","title":"Includedeterministic","default":false}},"type":"object","title":"OrderRetryFailedRequest","description":"POST /v1/orders/{id}/retry-failed. Omit `children` (or set `all`) to\nretry every failed child; name children to retry a subset with optional\nper-child intake patches."},"OrderRetryFailedResponse":{"properties":{"runIds":{"items":{"type":"string"},"type":"array","title":"Runids"},"order":{"$ref":"#/components/schemas/GenerationOrderResponse"},"skipped":{"items":{"$ref":"#/components/schemas/OrderRefillSkipped"},"type":"array","title":"Skipped","default":[]}},"type":"object","required":["runIds","order"],"title":"OrderRetryFailedResponse"},"OutletCreate":{"properties":{"name":{"type":"string","maxLength":200,"minLength":1,"title":"Name"},"slug":{"type":"string","maxLength":120,"title":"Slug","default":""},"siteUrl":{"type":"string","title":"Siteurl","default":""},"sectionPath":{"type":"string","maxLength":200,"title":"Sectionpath","default":""},"description":{"type":"string","title":"Description","default":""},"acceptedKinds":{"items":{"type":"string"},"type":"array","title":"Acceptedkinds"},"syndicate":{"type":"boolean","title":"Syndicate","default":false},"revalidateUrl":{"type":"string","title":"Revalidateurl","default":""},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},"type":"object","required":["name"],"title":"OutletCreate"},"OutletItemArtifact":{"properties":{"id":{"type":"string","title":"Id"},"runId":{"type":"string","title":"Runid"},"templateId":{"type":"string","title":"Templateid"},"title":{"type":"string","title":"Title"},"status":{"type":"string","title":"Status"},"content":{"additionalProperties":true,"type":"object","title":"Content"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"qa":{"additionalProperties":true,"type":"object","title":"Qa"}},"type":"object","required":["id","runId","templateId","title","status","content","createdAt"],"title":"OutletItemArtifact","description":"The consumer-feed embed: what an ingest needs to build a page.\n\n`qa` is part of that. A consumer deciding whether to publish an artifact\nneeds the verdict of the checks we already ran on it — without it the\nquality system is advisory to us and invisible to them. clip.art shipped\n56 images carrying a recorded `alpha-audit: fail` because this field was\nwritten, stored, and never handed over."},"OutletItemListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/OutletItemResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"OutletItemListResponse"},"OutletItemResponse":{"properties":{"id":{"type":"string","title":"Id"},"outletId":{"type":"string","title":"Outletid"},"artifactId":{"type":"string","title":"Artifactid"},"status":{"type":"string","title":"Status"},"publishedBy":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publishedby"},"routedVia":{"type":"string","title":"Routedvia","default":""},"publishedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Publishedat"},"unpublishedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Unpublishedat"},"outletName":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outletname"},"artifact":{"anyOf":[{"$ref":"#/components/schemas/OutletItemArtifact"},{"type":"null"}]}},"type":"object","required":["id","outletId","artifactId","status"],"title":"OutletItemResponse"},"OutletItemResult":{"properties":{"artifactId":{"type":"string","title":"Artifactid"},"ok":{"type":"boolean","title":"Ok"},"problem":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Problem"}},"type":"object","required":["artifactId","ok"],"title":"OutletItemResult"},"OutletItemsAct":{"properties":{"artifactIds":{"items":{"type":"string"},"type":"array","maxItems":500,"minItems":1,"title":"Artifactids"}},"type":"object","required":["artifactIds"],"title":"OutletItemsAct","description":"Publish or unpublish a batch of artifacts in one act (one webhook)."},"OutletItemsActResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/OutletItemResult"},"type":"array","title":"Results"},"changed":{"type":"integer","title":"Changed"}},"type":"object","required":["results","changed"],"title":"OutletItemsActResponse"},"OutletListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/OutletResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"OutletListResponse"},"OutletResponse":{"properties":{"id":{"type":"string","title":"Id"},"userId":{"type":"string","format":"uuid","title":"Userid"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"siteUrl":{"type":"string","title":"Siteurl"},"sectionPath":{"type":"string","title":"Sectionpath","default":""},"description":{"type":"string","title":"Description","default":""},"acceptedKinds":{"items":{"type":"string"},"type":"array","title":"Acceptedkinds"},"syndicate":{"type":"boolean","title":"Syndicate","default":false},"revalidateUrl":{"type":"string","title":"Revalidateurl"},"hasRevalidateSecret":{"type":"boolean","title":"Hasrevalidatesecret","default":false},"lastDeliveryStatus":{"type":"string","title":"Lastdeliverystatus","default":""},"lastDeliveryAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastdeliveryat"},"lastDeliveryDetail":{"type":"string","title":"Lastdeliverydetail","default":""},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","userId","name","slug","siteUrl","acceptedKinds","revalidateUrl","createdAt","updatedAt"],"title":"OutletResponse"},"OutletUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":200,"minLength":1},{"type":"null"}],"title":"Name"},"siteUrl":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Siteurl"},"sectionPath":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Sectionpath"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"acceptedKinds":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Acceptedkinds"},"syndicate":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Syndicate"},"revalidateUrl":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Revalidateurl"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},"type":"object","title":"OutletUpdate"},"OutletVerifyResponse":{"properties":{"status":{"type":"string","title":"Status"},"detail":{"type":"string","title":"Detail","default":""}},"type":"object","required":["status"],"title":"OutletVerifyResponse"},"OutletWithSecretResponse":{"properties":{"id":{"type":"string","title":"Id"},"userId":{"type":"string","format":"uuid","title":"Userid"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"siteUrl":{"type":"string","title":"Siteurl"},"sectionPath":{"type":"string","title":"Sectionpath","default":""},"description":{"type":"string","title":"Description","default":""},"acceptedKinds":{"items":{"type":"string"},"type":"array","title":"Acceptedkinds"},"syndicate":{"type":"boolean","title":"Syndicate","default":false},"revalidateUrl":{"type":"string","title":"Revalidateurl"},"hasRevalidateSecret":{"type":"boolean","title":"Hasrevalidatesecret","default":false},"lastDeliveryStatus":{"type":"string","title":"Lastdeliverystatus","default":""},"lastDeliveryAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastdeliveryat"},"lastDeliveryDetail":{"type":"string","title":"Lastdeliverydetail","default":""},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"},"revalidateSecret":{"type":"string","title":"Revalidatesecret","default":""}},"type":"object","required":["id","userId","name","slug","siteUrl","acceptedKinds","revalidateUrl","createdAt","updatedAt"],"title":"OutletWithSecretResponse"},"OutlineAcceptRequest":{"properties":{"blocks":{"items":{"$ref":"#/components/schemas/ProposedBlock-Input"},"type":"array","maxItems":300,"minItems":1,"title":"Blocks"},"mode":{"type":"string","enum":["replace","merge"],"title":"Mode","default":"merge"}},"type":"object","required":["blocks"],"title":"OutlineAcceptRequest","description":"Explicitly accept (all or selected) proposed blocks into Structure."},"OutlineBlockCreate":{"properties":{"heading":{"type":"string","maxLength":300,"minLength":1,"title":"Heading"},"intent":{"type":"string","maxLength":2000,"title":"Intent","default":""},"targetWords":{"anyOf":[{"type":"integer","maximum":100000.0,"minimum":0.0},{"type":"null"}],"title":"Targetwords"},"parentId":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Parentid"},"position":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Position"}},"type":"object","required":["heading"],"title":"OutlineBlockCreate"},"OutlineBlockResponse":{"properties":{"id":{"type":"string","title":"Id"},"outlineId":{"type":"string","title":"Outlineid"},"parentId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parentid"},"position":{"type":"integer","title":"Position"},"heading":{"type":"string","title":"Heading"},"intent":{"type":"string","title":"Intent"},"targetWords":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Targetwords"},"state":{"type":"string","enum":["planned","drafted","inserted","stale"],"title":"State"},"headingNodeId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Headingnodeid"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","outlineId","position","heading","intent","state","createdAt","updatedAt"],"title":"OutlineBlockResponse"},"OutlineBlockUpdate":{"properties":{"heading":{"anyOf":[{"type":"string","maxLength":300,"minLength":1},{"type":"null"}],"title":"Heading"},"intent":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Intent"},"targetWords":{"anyOf":[{"type":"integer","maximum":100000.0,"minimum":0.0},{"type":"null"}],"title":"Targetwords"},"state":{"anyOf":[{"type":"string","enum":["planned","drafted","inserted","stale"]},{"type":"null"}],"title":"State"},"headingNodeId":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Headingnodeid"}},"type":"object","title":"OutlineBlockUpdate","description":"Partial update; routes apply model_dump(exclude_unset=True)."},"OutlineImportBlock":{"properties":{"heading":{"type":"string","maxLength":300,"minLength":1,"title":"Heading"},"level":{"type":"integer","maximum":3.0,"minimum":1.0,"title":"Level"},"headingNodeId":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Headingnodeid"}},"type":"object","required":["heading","level"],"title":"OutlineImportBlock","description":"One heading imported from the manuscript (Import headings flow)."},"OutlineImportRequest":{"properties":{"blocks":{"items":{"$ref":"#/components/schemas/OutlineImportBlock"},"type":"array","maxItems":300,"minItems":1,"title":"Blocks"},"mode":{"type":"string","enum":["replace","merge"],"title":"Mode","default":"merge"}},"type":"object","required":["blocks"],"title":"OutlineImportRequest"},"OutlineProposal":{"properties":{"blocks":{"items":{"$ref":"#/components/schemas/ProposedBlock-Output"},"type":"array","maxItems":40,"minItems":1,"title":"Blocks"}},"type":"object","required":["blocks"],"title":"OutlineProposal"},"OutlineProposalRequest":{"properties":{"model":{"type":"string","maxLength":120,"title":"Model"},"instruction":{"type":"string","maxLength":4000,"title":"Instruction","default":""},"documentTitle":{"type":"string","maxLength":500,"title":"Documenttitle","default":""},"documentText":{"type":"string","maxLength":60000,"title":"Documenttext","default":""},"threadId":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Threadid"}},"type":"object","required":["model"],"title":"OutlineProposalRequest"},"OutlineProposalResponse":{"properties":{"proposal":{"$ref":"#/components/schemas/OutlineProposal"},"aiRequestId":{"type":"string","title":"Airequestid"},"model":{"type":"string","title":"Model"},"messageId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Messageid"}},"type":"object","required":["proposal","aiRequestId","model"],"title":"OutlineProposalResponse"},"OutlineReorder":{"properties":{"order":{"items":{"$ref":"#/components/schemas/BlockPlacement"},"type":"array","maxItems":300,"minItems":1,"title":"Order"}},"type":"object","required":["order"],"title":"OutlineReorder","description":"Complete new ordering: every existing block exactly once, in sibling\norder. The server renumbers positions transactionally (two-phase) so\nconcurrent reorders cannot silently duplicate positions."},"OutlineResponse":{"properties":{"id":{"type":"string","title":"Id"},"documentId":{"type":"string","title":"Documentid"},"blocks":{"items":{"$ref":"#/components/schemas/OutlineBlockResponse"},"type":"array","title":"Blocks"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","documentId","blocks","createdAt","updatedAt"],"title":"OutlineResponse","description":"Flat ordered block list (parent-first, position order within siblings).\nThe client builds the tree in O(n)."},"OwnerFlowMonth":{"properties":{"period":{"type":"string","title":"Period"},"paidToOwnerCents":{"type":"integer","title":"Paidtoownercents"},"putInCents":{"type":"integer","title":"Putincents"}},"type":"object","required":["period","paidToOwnerCents","putInCents"],"title":"OwnerFlowMonth","description":"One calendar month of money between the business and its owner."},"OwnerFlows":{"properties":{"direction":{"type":"string","enum":["paying","funding","none"],"title":"Direction"},"paidToOwnerCentsPerMonth":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Paidtoownercentspermonth"},"putInCentsPerMonth":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Putincentspermonth"},"months":{"items":{"$ref":"#/components/schemas/OwnerFlowMonth"},"type":"array","title":"Months"},"putInSinceCents":{"type":"integer","title":"Putinsincecents"},"putInSince":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Putinsince"},"lastPaidAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastpaidat"}},"type":"object","required":["direction","months","putInSinceCents"],"title":"OwnerFlows","description":"Money that moved between the owner's personal accounts and the business.\n\nPresent only when the scope holds exactly one personal workspace and at\nleast one organization. `direction` reads the headline window: the business\npaying the owner, the owner funding the business, or nothing moving yet."},"PackCreate":{"properties":{"title":{"type":"string","title":"Title","default":""},"format":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Format"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"clientRef":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Clientref"},"brief":{"additionalProperties":true,"type":"object","title":"Brief","default":{}},"style":{"additionalProperties":true,"type":"object","title":"Style","default":{}},"render":{"additionalProperties":true,"type":"object","title":"Render","default":{}},"listing":{"additionalProperties":true,"type":"object","title":"Listing","default":{}},"annotations":{"additionalProperties":true,"type":"object","title":"Annotations","default":{}},"sourceArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sourceartifactid"},"items":{"items":{"$ref":"#/components/schemas/PackItemInput"},"type":"array","title":"Items","default":[]}},"type":"object","title":"PackCreate"},"PackDecisionRequest":{"properties":{"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag"}},"type":"object","title":"PackDecisionRequest"},"PackDeliveryResponse":{"properties":{"deliveryStatus":{"type":"string","title":"Deliverystatus"},"deliveryDetail":{"type":"string","title":"Deliverydetail","default":""},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url"},"itemCount":{"type":"integer","title":"Itemcount","default":0}},"type":"object","required":["deliveryStatus"],"title":"PackDeliveryResponse","description":"Where the pack got to."},"PackFamilyOrder":{"properties":{"id":{"type":"string","title":"Id"},"status":{"type":"string","title":"Status"},"counts":{"additionalProperties":true,"type":"object","title":"Counts"},"actualCostUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Actualcostusd"},"qaReportArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Qareportartifactid"},"createdAt":{"title":"Createdat"}},"type":"object","required":["id","status","counts"],"title":"PackFamilyOrder","description":"One order in a pack family: enough for a row + its QA-report link."},"PackFamilyResponse":{"properties":{"planArtifactId":{"type":"string","title":"Planartifactid"},"orders":{"items":{"$ref":"#/components/schemas/PackFamilyOrder"},"type":"array","title":"Orders"},"assets":{"items":{"$ref":"#/components/schemas/ArtifactSummary"},"type":"array","title":"Assets"},"qaReportArtifactIds":{"items":{"type":"string"},"type":"array","title":"Qareportartifactids"}},"type":"object","required":["planArtifactId","orders","assets","qaReportArtifactIds"],"title":"PackFamilyResponse","description":"Everything a plan artifact spawned (operator mandate 2026-07-31):\nplan → orders → generated asset artifacts → QA reports, one payload, so\nthe plan page can render its whole family without N client round-trips."},"PackImport":{"properties":{"orderIds":{"items":{"type":"string"},"type":"array","title":"Orderids","default":[]},"planArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Planartifactid"},"title":{"type":"string","title":"Title","default":""},"format":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Format"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"clientRef":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Clientref"},"coverArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Coverartifactid"},"annotations":{"additionalProperties":true,"type":"object","title":"Annotations","default":{}},"requestId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Requestid"}},"type":"object","title":"PackImport","description":"Write down work that already exists as a pack. Nothing is redrawn."},"PackItemEdit":{"properties":{"id":{"type":"string","title":"Id"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"elementType":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Elementtype"},"text":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Text"},"quality":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Quality"},"altText":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Alttext"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags"},"annotations":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Annotations"}},"type":"object","required":["id"],"title":"PackItemEdit","description":"A change to one existing piece. Only the fields present move; anything\nleft out keeps what it had, so two people editing different fields of the\nsame piece don't overwrite each other."},"PackItemInput":{"properties":{"title":{"type":"string","title":"Title","default":""},"subject":{"type":"string","title":"Subject"},"elementType":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Elementtype"},"text":{"additionalProperties":true,"type":"object","title":"Text","default":{}},"quality":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Quality"},"altText":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Alttext"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","default":[]},"companionOf":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Companionof"},"companionKind":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Companionkind"},"annotations":{"additionalProperties":true,"type":"object","title":"Annotations","default":{}}},"type":"object","required":["subject"],"title":"PackItemInput","description":"A piece as a client asks for it. The id is Esy's to give: a client that\nnamed its own would be holding the pack together itself again."},"PackItemResponse":{"properties":{"id":{"type":"string","title":"Id"},"position":{"type":"integer","title":"Position"},"status":{"type":"string","title":"Status"},"title":{"type":"string","title":"Title"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"elementType":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Elementtype"},"text":{"additionalProperties":true,"type":"object","title":"Text","default":{}},"quality":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Quality"},"altText":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Alttext"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","default":[]},"companionOf":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Companionof"},"companionKind":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Companionkind"},"current":{"anyOf":[{"$ref":"#/components/schemas/CurrentArtifact"},{"type":"null"}]},"renditions":{"additionalProperties":true,"type":"object","title":"Renditions","default":{}},"lastAttempt":{"anyOf":[{"$ref":"#/components/schemas/AttemptSummary"},{"type":"null"}]},"annotations":{"additionalProperties":true,"type":"object","title":"Annotations","default":{}}},"type":"object","required":["id","position","status","title"],"title":"PackItemResponse"},"PackItemsPatch":{"properties":{"etag":{"type":"string","title":"Etag"},"add":{"items":{"$ref":"#/components/schemas/PackItemInput"},"type":"array","title":"Add","default":[]},"update":{"items":{"$ref":"#/components/schemas/PackItemEdit"},"type":"array","title":"Update","default":[]},"remove":{"items":{"type":"string"},"type":"array","title":"Remove","default":[]},"restore":{"items":{"type":"string"},"type":"array","title":"Restore","default":[]},"order":{"items":{"type":"string"},"type":"array","title":"Order","default":[]}},"type":"object","required":["etag"],"title":"PackItemsPatch","description":"Every edit to the pieces in one request, so a board that adds two,\nrenames one and reorders the rest is a single change with a single etag\ninstead of five races."},"PackListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/CollectionSummary"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"PackListResponse","description":"Lists stay light: a pack card needs its cover, counts and cost, not its\nmembers. Read one pack for its items."},"PackPublishResponse":{"properties":{"esyOrderId":{"type":"string","title":"Esyorderid"},"deliveryStatus":{"type":"string","title":"Deliverystatus"},"deliveryDetail":{"type":"string","title":"Deliverydetail"},"itemCount":{"type":"integer","title":"Itemcount","default":0}},"type":"object","required":["esyOrderId","deliveryStatus","deliveryDetail"],"title":"PackPublishResponse"},"PackRenderRequest":{"properties":{"itemIds":{"items":{"type":"string"},"type":"array","title":"Itemids","default":[]},"requestId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Requestid"},"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag"}},"type":"object","title":"PackRenderRequest","description":"Draw pieces. Naming none draws every piece still waiting."},"PackRenderResponse":{"properties":{"orderIds":{"items":{"type":"string"},"type":"array","title":"Orderids"},"itemIds":{"items":{"type":"string"},"type":"array","title":"Itemids"},"attemptIds":{"items":{"type":"string"},"type":"array","title":"Attemptids"},"budgetCapUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Budgetcapusd"},"estimatedCostUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Estimatedcostusd"},"styleKit":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Stylekit"},"lanes":{"additionalProperties":true,"type":"object","title":"Lanes","default":{}}},"type":"object","required":["orderIds","itemIds","attemptIds"],"title":"PackRenderResponse","description":"What the render started, so a client can charge for exactly that — and\nrefund a failed attempt by its id, once."},"PackResponse":{"properties":{"id":{"type":"string","title":"Id"},"kind":{"type":"string","title":"Kind"},"format":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Format"},"status":{"type":"string","title":"Status"},"title":{"type":"string","title":"Title"},"etag":{"type":"string","title":"Etag"},"clientRef":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Clientref"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"sourceArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sourceartifactid"},"coverArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Coverartifactid"},"renditions":{"additionalProperties":true,"type":"object","title":"Renditions","default":{}},"delivery":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Delivery"},"progress":{"$ref":"#/components/schemas/CollectionProgress"},"cost":{"$ref":"#/components/schemas/CollectionCost"},"preview":{"items":{"$ref":"#/components/schemas/PreviewPiece"},"type":"array","title":"Preview","default":[]},"annotations":{"additionalProperties":true,"type":"object","title":"Annotations","default":{}},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"},"brief":{"additionalProperties":true,"type":"object","title":"Brief","default":{}},"style":{"additionalProperties":true,"type":"object","title":"Style","default":{}},"render":{"additionalProperties":true,"type":"object","title":"Render","default":{}},"listing":{"additionalProperties":true,"type":"object","title":"Listing","default":{}},"items":{"items":{"$ref":"#/components/schemas/PackItemResponse"},"type":"array","title":"Items","default":[]}},"type":"object","required":["id","kind","status","title","etag","progress","cost","createdAt","updatedAt"],"title":"PackResponse"},"PackUpdate":{"properties":{"etag":{"type":"string","title":"Etag"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"format":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Format"},"style":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Style"},"render":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Render"},"listing":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Listing"},"coverArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Coverartifactid"},"annotations":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Annotations"}},"type":"object","required":["etag"],"title":"PackUpdate","description":"Edit the pack itself. The etag says which version the client was looking\nat when it decided to make this change."},"PageCreate":{"properties":{"projectId":{"type":"string","format":"uuid","title":"Projectid"},"siteId":{"type":"string","title":"Siteid"},"format":{"type":"string","title":"Format"},"title":{"type":"string","maxLength":300,"minLength":1,"title":"Title"},"targetSearch":{"type":"string","title":"Targetsearch"},"traffic":{"type":"string","title":"Traffic","default":"organic"},"ad":{"anyOf":[{"$ref":"#/components/schemas/AdInput"},{"type":"null"}]},"area":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Area"},"requestId":{"anyOf":[{"type":"string","maxLength":64,"minLength":8},{"type":"null"}],"title":"Requestid"}},"type":"object","required":["projectId","siteId","format","title","targetSearch"],"title":"PageCreate","description":"A page as a client asks for it: what it is for, never how it is built.\nSections come from the plan (API-008)."},"PageListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/CollectionSummary"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"PageListResponse"},"PageResponse":{"properties":{"id":{"type":"string","title":"Id"},"kind":{"type":"string","title":"Kind"},"format":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Format"},"status":{"type":"string","title":"Status"},"title":{"type":"string","title":"Title"},"etag":{"type":"string","title":"Etag"},"clientRef":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Clientref"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"sourceArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sourceartifactid"},"coverArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Coverartifactid"},"renditions":{"additionalProperties":true,"type":"object","title":"Renditions","default":{}},"delivery":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Delivery"},"progress":{"$ref":"#/components/schemas/CollectionProgress"},"cost":{"$ref":"#/components/schemas/CollectionCost"},"preview":{"items":{"$ref":"#/components/schemas/PreviewPiece"},"type":"array","title":"Preview","default":[]},"annotations":{"additionalProperties":true,"type":"object","title":"Annotations","default":{}},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"},"siteId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Siteid"},"targetSearch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Targetsearch"},"traffic":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Traffic"},"ad":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Ad"},"area":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Area"},"readiness":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Readiness"},"frameworkVersion":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Frameworkversion"},"needsBuild":{"type":"boolean","title":"Needsbuild","default":false},"checks":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Checks"},"sections":{"items":{"$ref":"#/components/schemas/SectionResponse"},"type":"array","title":"Sections","default":[]}},"type":"object","required":["id","kind","status","title","etag","progress","cost","createdAt","updatedAt"],"title":"PageResponse"},"PageUpdate":{"properties":{"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag"},"title":{"anyOf":[{"type":"string","maxLength":300,"minLength":1},{"type":"null"}],"title":"Title"},"targetSearch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Targetsearch"}},"type":"object","title":"PageUpdate","description":"A plain edit. The etag (or If-Match) names the version it was made against."},"PasskeyListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/PasskeyResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"PasskeyListResponse"},"PasskeyResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label"},"backedUp":{"type":"boolean","title":"Backedup"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"lastUsedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastusedat"}},"type":"object","required":["id","backedUp","createdAt"],"title":"PasskeyResponse"},"Persona":{"properties":{"version":{"type":"integer","const":1,"title":"Version","default":1},"summary":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Summary"},"voiceAndTone":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Voiceandtone"},"dos":{"items":{"type":"string"},"type":"array","maxItems":30,"title":"Dos"},"donts":{"items":{"type":"string"},"type":"array","maxItems":30,"title":"Donts"},"languages":{"items":{"type":"string"},"type":"array","maxItems":20,"title":"Languages"}},"type":"object","title":"Persona","description":"Who the character is, in words a writer or a model can follow."},"PlaidConnectionRequest":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"connectionId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Connectionid"}},"type":"object","required":["workspaceId"],"title":"PlaidConnectionRequest"},"PlaidExchangeRequest":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"publicToken":{"type":"string","title":"Publictoken"},"institutionName":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Institutionname"}},"type":"object","required":["workspaceId","publicToken"],"title":"PlaidExchangeRequest"},"PreviewPiece":{"properties":{"itemId":{"type":"string","title":"Itemid"},"artifactId":{"type":"string","title":"Artifactid"},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url"}},"type":"object","required":["itemId","artifactId"],"title":"PreviewPiece","description":"One accepted piece, enough to draw a card with."},"ProductBreakdownItem":{"properties":{"productId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Productid"},"productName":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Productname"},"priceId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Priceid"},"marketValueCents":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Marketvaluecents"},"unitsSold":{"type":"integer","title":"Unitssold"},"orderCount":{"type":"integer","title":"Ordercount"},"grossAmountCents":{"type":"integer","title":"Grossamountcents"},"feeAmountCents":{"type":"integer","title":"Feeamountcents"},"netAmountCents":{"type":"integer","title":"Netamountcents"},"avgSalePriceCents":{"type":"integer","title":"Avgsalepricecents"},"currency":{"type":"string","title":"Currency","default":"USD"}},"type":"object","required":["unitsSold","orderCount","grossAmountCents","feeAmountCents","netAmountCents","avgSalePriceCents"],"title":"ProductBreakdownItem"},"ProductBreakdownResponse":{"properties":{"currency":{"type":"string","title":"Currency","default":"USD"},"unitsSold":{"type":"integer","title":"Unitssold"},"orderCount":{"type":"integer","title":"Ordercount"},"productCount":{"type":"integer","title":"Productcount"},"grossAmountCents":{"type":"integer","title":"Grossamountcents"},"feeAmountCents":{"type":"integer","title":"Feeamountcents"},"netAmountCents":{"type":"integer","title":"Netamountcents"},"items":{"items":{"$ref":"#/components/schemas/ProductBreakdownItem"},"type":"array","title":"Items"}},"type":"object","required":["unitsSold","orderCount","productCount","grossAmountCents","feeAmountCents","netAmountCents","items"],"title":"ProductBreakdownResponse"},"ProductionCreateRequest":{"properties":{"campaignId":{"type":"string","title":"Campaignid"}},"type":"object","required":["campaignId"],"title":"ProductionCreateRequest"},"ProductionItemView":{"properties":{"role":{"type":"string","title":"Role"},"angleKey":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Anglekey"},"state":{"type":"string","title":"State"},"artifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifactid"},"refId":{"type":"string","title":"Refid"}},"type":"object","required":["role","state","refId"],"title":"ProductionItemView","description":"The customer projection of one deliverable: role and angle in Make's\nvocabulary, the run's state bucketed, and the output when there is one.\nEngine nouns (template ids, providers) stay off this shape."},"ProductionListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ProductionResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"ProductionListResponse"},"ProductionResponse":{"properties":{"id":{"type":"string","title":"Id"},"campaignId":{"type":"string","title":"Campaignid"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"type":"string","format":"uuid","title":"Projectid"},"status":{"type":"string","title":"Status"},"plan":{"additionalProperties":true,"type":"object","title":"Plan"},"counts":{"additionalProperties":true,"type":"object","title":"Counts"},"errorSummary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Errorsummary"},"items":{"items":{"$ref":"#/components/schemas/ProductionItemView"},"type":"array","title":"Items","default":[]},"createdAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Createdat"},"startedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Startedat"},"completedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completedat"}},"type":"object","required":["id","campaignId","workspaceId","projectId","status","plan","counts"],"title":"ProductionResponse"},"ProfileConfirmRequest":{"properties":{"proposalArtifactId":{"type":"string","title":"Proposalartifactid"},"fields":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Fields"}},"type":"object","required":["proposalArtifactId"],"title":"ProfileConfirmRequest","description":"Accept a compose-brand-profile proposal into the editable row.\n\n``fields`` limits which proposal fields land; omitted = all of them."},"ProfileUpsertRequest":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"markdown":{"type":"string","title":"Markdown","default":""},"facts":{"additionalProperties":true,"type":"object","title":"Facts"}},"type":"object","required":["workspaceId"],"title":"ProfileUpsertRequest"},"ProjectCreateRequest":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"slug":{"anyOf":[{"type":"string","maxLength":120,"minLength":1},{"type":"null"}],"title":"Slug"},"kind":{"type":"string","maxLength":80,"minLength":1,"title":"Kind","default":"general"}},"type":"object","required":["name"],"title":"ProjectCreateRequest"},"ProjectListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ProjectResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"ProjectListResponse"},"ProjectResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"slug":{"type":"string","title":"Slug"},"name":{"type":"string","title":"Name"},"kind":{"type":"string","title":"Kind"},"clientId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Clientid"},"archivedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Archivedat"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","workspaceId","slug","name","kind","createdAt","updatedAt"],"title":"ProjectResponse"},"ProjectUpdateRequest":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Name"},"kind":{"anyOf":[{"type":"string","maxLength":80,"minLength":1},{"type":"null"}],"title":"Kind"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived"},"clientId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Clientid"}},"type":"object","title":"ProjectUpdateRequest"},"ProposedBlock-Input":{"properties":{"heading":{"type":"string","maxLength":300,"minLength":1,"title":"Heading"},"intent":{"type":"string","maxLength":2000,"title":"Intent","default":""},"targetWords":{"anyOf":[{"type":"integer","maximum":100000.0,"minimum":0.0},{"type":"null"}],"title":"Targetwords"},"children":{"items":{"$ref":"#/components/schemas/ProposedBlock-Input"},"type":"array","maxItems":20,"title":"Children"}},"type":"object","required":["heading"],"title":"ProposedBlock","description":"Server-owned proposal schema — this exact shape is compiled to each\nprovider's native structured-output format. Two levels max in v1."},"ProposedBlock-Output":{"properties":{"heading":{"type":"string","maxLength":300,"minLength":1,"title":"Heading"},"intent":{"type":"string","maxLength":2000,"title":"Intent","default":""},"targetWords":{"anyOf":[{"type":"integer","maximum":100000.0,"minimum":0.0},{"type":"null"}],"title":"Targetwords"},"children":{"items":{"$ref":"#/components/schemas/ProposedBlock-Output"},"type":"array","maxItems":20,"title":"Children"}},"type":"object","required":["heading"],"title":"ProposedBlock","description":"Server-owned proposal schema — this exact shape is compiled to each\nprovider's native structured-output format. Two levels max in v1."},"ProviderCostResponse":{"properties":{"id":{"type":"string","title":"Id"},"runId":{"type":"string","title":"Runid"},"runStepId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Runstepid"},"artifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifactid"},"provider":{"type":"string","title":"Provider"},"providerOperation":{"type":"string","title":"Provideroperation"},"providerRequestId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Providerrequestid"},"model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Model"},"pricingSource":{"type":"string","title":"Pricingsource"},"pricingVersion":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pricingversion"},"sourceUrl":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sourceurl"},"quantity":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Quantity"},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unitPriceUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Unitpriceusd"},"estimatedCostUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Estimatedcostusd"},"actualCostUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Actualcostusd"},"currency":{"type":"string","title":"Currency"},"status":{"type":"string","title":"Status"},"rawProviderPayload":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Rawproviderpayload"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"reconciledAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Reconciledat"}},"type":"object","required":["id","runId","provider","providerOperation","pricingSource","currency","status","createdAt"],"title":"ProviderCostResponse"},"PublicArticle":{"properties":{"slug":{"type":"string","title":"Slug"},"title":{"type":"string","title":"Title"},"description":{"type":"string","title":"Description"},"category":{"type":"string","title":"Category"},"categoryLabel":{"type":"string","title":"Categorylabel"},"categories":{"items":{"$ref":"#/components/schemas/CategoryRef"},"type":"array","title":"Categories"},"durationSeconds":{"type":"integer","title":"Durationseconds"},"publishedAt":{"type":"string","title":"Publishedat"},"muxPlaybackId":{"type":"string","title":"Muxplaybackid"},"thumbnailUrl":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Thumbnailurl"},"transcript":{"type":"string","title":"Transcript","default":""},"content":{"type":"string","title":"Content"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags"},"relatedSlugs":{"items":{"type":"string"},"type":"array","title":"Relatedslugs"},"templateSlug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Templateslug"},"stages":{"anyOf":[{"items":{"$ref":"#/components/schemas/StageItem"},"type":"array"},{"type":"null"}],"title":"Stages"},"kind":{"type":"string","title":"Kind","default":""},"author":{"anyOf":[{"$ref":"#/components/schemas/AuthorRef"},{"type":"null"}]}},"type":"object","required":["slug","title","description","category","categoryLabel","durationSeconds","publishedAt","muxPlaybackId","content","tags","relatedSlugs"],"title":"PublicArticle"},"PublicArticleListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/PublicArticle"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"PublicArticleListResponse"},"PublicationCategoryCreate":{"properties":{"label":{"type":"string","title":"Label","default":""},"slug":{"type":"string","title":"Slug","default":""},"description":{"type":"string","title":"Description","default":""},"position":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Position"}},"type":"object","title":"PublicationCategoryCreate"},"PublicationCategoryListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/PublicationCategoryResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"PublicationCategoryListResponse"},"PublicationCategoryResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"publicationId":{"type":"string","format":"uuid","title":"Publicationid"},"slug":{"type":"string","title":"Slug"},"label":{"type":"string","title":"Label"},"description":{"type":"string","title":"Description"},"position":{"type":"integer","title":"Position"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","publicationId","slug","label","description","position","createdAt","updatedAt"],"title":"PublicationCategoryResponse"},"PublicationCategoryUpdate":{"properties":{"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label"},"slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"position":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Position"}},"type":"object","title":"PublicationCategoryUpdate"},"PublicationCreate":{"properties":{"name":{"type":"string","title":"Name","default":""},"slug":{"type":"string","title":"Slug","default":""},"description":{"type":"string","title":"Description","default":""},"acceptedKinds":{"items":{"type":"string"},"type":"array","title":"Acceptedkinds"},"siteUrl":{"type":"string","title":"Siteurl","default":""},"sectionPath":{"type":"string","title":"Sectionpath","default":""},"revalidateUrl":{"type":"string","title":"Revalidateurl","default":""},"isPublic":{"type":"boolean","title":"Ispublic","default":false}},"type":"object","title":"PublicationCreate"},"PublicationListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/PublicationResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"PublicationListResponse"},"PublicationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"userId":{"type":"string","format":"uuid","title":"Userid"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"description":{"type":"string","title":"Description"},"acceptedKinds":{"items":{"type":"string"},"type":"array","title":"Acceptedkinds"},"siteUrl":{"type":"string","title":"Siteurl","default":""},"sectionPath":{"type":"string","title":"Sectionpath","default":""},"revalidateUrl":{"type":"string","title":"Revalidateurl","default":""},"isPublic":{"type":"boolean","title":"Ispublic","default":false},"hasRevalidateSecret":{"type":"boolean","title":"Hasrevalidatesecret","default":false},"lastDeliveryStatus":{"type":"string","title":"Lastdeliverystatus","default":""},"lastDeliveryAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastdeliveryat"},"lastDeliveryDetail":{"type":"string","title":"Lastdeliverydetail","default":""},"beehiivPublicationId":{"type":"string","title":"Beehiivpublicationid","default":""},"hasBeehiivKey":{"type":"boolean","title":"Hasbeehiivkey","default":false},"beehiivConnectedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Beehiivconnectedat"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","userId","name","slug","description","createdAt","updatedAt"],"title":"PublicationResponse"},"PublicationUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"acceptedKinds":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Acceptedkinds"},"siteUrl":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Siteurl"},"sectionPath":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sectionpath"},"revalidateUrl":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Revalidateurl"},"isPublic":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Ispublic"}},"type":"object","title":"PublicationUpdate"},"PublicationWithSecretResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"userId":{"type":"string","format":"uuid","title":"Userid"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"description":{"type":"string","title":"Description"},"acceptedKinds":{"items":{"type":"string"},"type":"array","title":"Acceptedkinds"},"siteUrl":{"type":"string","title":"Siteurl","default":""},"sectionPath":{"type":"string","title":"Sectionpath","default":""},"revalidateUrl":{"type":"string","title":"Revalidateurl","default":""},"isPublic":{"type":"boolean","title":"Ispublic","default":false},"hasRevalidateSecret":{"type":"boolean","title":"Hasrevalidatesecret","default":false},"lastDeliveryStatus":{"type":"string","title":"Lastdeliverystatus","default":""},"lastDeliveryAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastdeliveryat"},"lastDeliveryDetail":{"type":"string","title":"Lastdeliverydetail","default":""},"beehiivPublicationId":{"type":"string","title":"Beehiivpublicationid","default":""},"hasBeehiivKey":{"type":"boolean","title":"Hasbeehiivkey","default":false},"beehiivConnectedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Beehiivconnectedat"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"},"revalidateSecret":{"type":"string","title":"Revalidatesecret","default":""}},"type":"object","required":["id","userId","name","slug","description","createdAt","updatedAt"],"title":"PublicationWithSecretResponse"},"ReassignRunProjectRequest":{"properties":{"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"}},"type":"object","required":["projectId"],"title":"ReassignRunProjectRequest"},"RecoveryCodeVerifyRequest":{"properties":{"code":{"type":"string","title":"Code"}},"type":"object","required":["code"],"title":"RecoveryCodeVerifyRequest"},"RecoveryCodesResponse":{"properties":{"codes":{"items":{"type":"string"},"type":"array","title":"Codes"}},"type":"object","required":["codes"],"title":"RecoveryCodesResponse"},"RecurringCharge":{"properties":{"merchant":{"type":"string","title":"Merchant"},"amountCents":{"type":"integer","title":"Amountcents"},"cadenceDays":{"type":"integer","title":"Cadencedays"},"occurrences":{"type":"integer","title":"Occurrences"},"lastSeenOn":{"type":"string","format":"date","title":"Lastseenon"},"nextExpectedOn":{"type":"string","format":"date","title":"Nextexpectedon"},"accountIds":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Accountids"}},"type":"object","required":["merchant","amountCents","cadenceDays","occurrences","lastSeenOn","nextExpectedOn","accountIds"],"title":"RecurringCharge"},"RecurringResponse":{"properties":{"asOf":{"type":"string","format":"date-time","title":"Asof"},"currency":{"type":"string","title":"Currency","default":"USD"},"monthlyCommittedCents":{"type":"integer","title":"Monthlycommittedcents"},"items":{"items":{"$ref":"#/components/schemas/RecurringCharge"},"type":"array","title":"Items"}},"type":"object","required":["asOf","monthlyCommittedCents","items"],"title":"RecurringResponse"},"ReferenceCreate":{"properties":{"role":{"type":"string","enum":["portrait","turnaround","expression","outfit","pose","voice_sample","other"],"title":"Role"},"artifactId":{"type":"string","maxLength":100,"minLength":1,"title":"Artifactid"},"title":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}],"title":"Title"}},"type":"object","required":["role","artifactId"],"title":"ReferenceCreate"},"ReferenceResponse":{"properties":{"id":{"type":"string","title":"Id"},"role":{"type":"string","title":"Role"},"title":{"type":"string","title":"Title"},"artifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifactid"},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url"},"position":{"type":"integer","title":"Position"}},"type":"object","required":["id","role","title","position"],"title":"ReferenceResponse"},"RegisterRequest":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"password":{"type":"string","title":"Password"},"name":{"type":"string","title":"Name"},"turnstileToken":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Turnstiletoken"}},"type":"object","required":["email","password","name"],"title":"RegisterRequest"},"RegistrationOptionsResponse":{"properties":{"options":{"additionalProperties":true,"type":"object","title":"Options"}},"type":"object","required":["options"],"title":"RegistrationOptionsResponse"},"RegistrationVerifyRequest":{"properties":{"credential":{"additionalProperties":true,"type":"object","title":"Credential"},"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label"}},"type":"object","required":["credential"],"title":"RegistrationVerifyRequest"},"ReportResponse":{"properties":{"experimentId":{"type":"string","title":"Experimentid"},"artifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifactid"},"stats":{"additionalProperties":true,"type":"object","title":"Stats"}},"type":"object","required":["experimentId","artifactId","stats"],"title":"ReportResponse"},"RescoreRequest":{"properties":{"scorers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Scorers"}},"type":"object","title":"RescoreRequest"},"RescoreResponse":{"properties":{"trials":{"type":"integer","title":"Trials"},"rowsWritten":{"type":"integer","title":"Rowswritten"}},"type":"object","required":["trials","rowsWritten"],"title":"RescoreResponse"},"ResolvedRef":{"properties":{"itemId":{"type":"string","title":"Itemid"},"kind":{"type":"string","title":"Kind"},"slug":{"type":"string","title":"Slug"},"name":{"type":"string","title":"Name"},"version":{"type":"integer","title":"Version"},"alias":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Alias"},"payload":{"additionalProperties":true,"type":"object","title":"Payload"}},"type":"object","required":["itemId","kind","slug","name","version","payload"],"title":"ResolvedRef","description":"What a run records. Deliberately carries the resolved VERSION alongside\nthe alias that was followed, so provenance survives the next promote."},"RetryPolicy":{"properties":{"maxRetriesPerChild":{"type":"integer","maximum":5.0,"minimum":0.0,"title":"Maxretriesperchild","default":0}},"type":"object","title":"RetryPolicy","description":"Auto-retry contract (issue #206): the executor re-runs failed children\nas :rN siblings before finalizing, at most maxRetriesPerChild attempts per\nelement, budget-gated per round. 0/omitted = no auto retry."},"RevenueSummaryResponse":{"properties":{"groupBy":{"type":"string","title":"Groupby"},"currency":{"type":"string","title":"Currency","default":"USD"},"grossAmountCents":{"type":"integer","title":"Grossamountcents"},"feeAmountCents":{"type":"integer","title":"Feeamountcents"},"netAmountCents":{"type":"integer","title":"Netamountcents"},"entryCount":{"type":"integer","title":"Entrycount"},"buckets":{"items":{"$ref":"#/components/schemas/FinanceBucket"},"type":"array","title":"Buckets"}},"type":"object","required":["groupBy","grossAmountCents","feeAmountCents","netAmountCents","entryCount","buckets"],"title":"RevenueSummaryResponse"},"ReviewDecisionRequest":{"properties":{"decision":{"type":"string","enum":["approve","reject","request_changes"],"title":"Decision"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"gateId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gateid"},"patch":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Patch"}},"type":"object","required":["decision"],"title":"ReviewDecisionRequest"},"ReviewDecisionResponse":{"properties":{"id":{"type":"string","title":"Id"},"runId":{"type":"string","title":"Runid"},"artifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifactid"},"gateId":{"type":"string","title":"Gateid"},"gateName":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gatename"},"decision":{"type":"string","title":"Decision"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"decidedBy":{"type":"string","format":"uuid","title":"Decidedby"},"decidedAt":{"type":"string","format":"date-time","title":"Decidedat"},"patch":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Patch"},"runStatus":{"type":"string","title":"Runstatus"},"artifactStatus":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifactstatus"}},"type":"object","required":["id","runId","gateId","decision","decidedBy","decidedAt","runStatus"],"title":"ReviewDecisionResponse"},"ReviewInput":{"properties":{"text":{"type":"string","maxLength":4000,"minLength":1,"title":"Text"},"date":{"type":"string","maxLength":40,"minLength":1,"title":"Date"},"source":{"type":"string","maxLength":200,"minLength":1,"title":"Source"},"author":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Author"}},"type":"object","required":["text","date","source"],"title":"ReviewInput"},"ReviewQueueCountResponse":{"properties":{"total":{"type":"integer","title":"Total"}},"type":"object","required":["total"],"title":"ReviewQueueCountResponse","description":"Count-only contract (perf 2026-07-10): the side-rail badge and the Overview\ncard need just the pending total, not the ~52KB queue payload the full list\nreturns. Backed by a plain COUNT(*)."},"ReviewQueueItem":{"properties":{"runId":{"type":"string","title":"Runid"},"templateId":{"type":"string","title":"Templateid"},"templateName":{"type":"string","title":"Templatename"},"gateId":{"type":"string","title":"Gateid"},"gateName":{"type":"string","title":"Gatename"},"status":{"type":"string","title":"Status"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"artifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifactid"},"artifactTitle":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifacttitle"},"artifactSubtitle":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifactsubtitle"},"artifactType":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifacttype"},"artifactStatus":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifactstatus"},"qa":{"additionalProperties":true,"type":"object","title":"Qa"},"holdReason":{"type":"string","title":"Holdreason","default":"approval-gate"},"requiresOnApprove":{"items":{"type":"string"},"type":"array","title":"Requiresonapprove"},"classificationCategory":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Classificationcategory"},"imageUrl":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Imageurl"},"categoryOptions":{"items":{"type":"string"},"type":"array","title":"Categoryoptions"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"completedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completedat"}},"type":"object","required":["runId","templateId","templateName","gateId","gateName","status","createdAt"],"title":"ReviewQueueItem","description":"One pending human decision in the Queue.\n\nDerived from a run sitting in ``review``: it carries enough run + artifact context\nfor a reviewer to decide without a second fetch, plus the gate the decision resolves."},"ReviewQueueResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ReviewQueueItem"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"ReviewQueueResponse"},"RevisionRequest":{"properties":{"runId":{"type":"string","title":"Runid"}},"type":"object","required":["runId"],"title":"RevisionRequest"},"RevisionResponse":{"properties":{"id":{"type":"string","title":"Id"},"documentId":{"type":"string","title":"Documentid"},"cause":{"type":"string","title":"Cause"},"title":{"type":"string","title":"Title"},"contentJson":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Contentjson"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"}},"type":"object","required":["id","documentId","cause","title","createdAt"],"title":"RevisionResponse"},"RunListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/RunSummary"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"RunListResponse"},"RunResponse":{"properties":{"id":{"type":"string","title":"Id"},"templateId":{"type":"string","title":"Templateid"},"templateName":{"type":"string","title":"Templatename"},"status":{"type":"string","title":"Status"},"currentStepIndex":{"type":"integer","title":"Currentstepindex"},"steps":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Steps"},"intake":{"additionalProperties":true,"type":"object","title":"Intake"},"requestRepairs":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Requestrepairs"},"artifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifactid"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"parentRunId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parentrunid"},"parentStepId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parentstepid"},"parentOrderId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parentorderid"},"orderDedupeKey":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Orderdedupekey"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"errorCode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Errorcode"},"errorExplanation":{"anyOf":[{"$ref":"#/components/schemas/FailureExplanationResponse"},{"type":"null"}]},"failureDetails":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Failuredetails"},"providerOverrides":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Provideroverrides"},"createdVia":{"type":"string","title":"Createdvia","default":"session"},"workerId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Workerid"},"apiKeyId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Apikeyid"},"apiKeyName":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Apikeyname"},"clientUserAgent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Clientuseragent"},"totalTokenUsage":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Totaltokenusage"},"totalCosts":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Totalcosts"},"runSteps":{"items":{"$ref":"#/components/schemas/RunStepResponse"},"type":"array","title":"Runsteps"},"costLedger":{"items":{"$ref":"#/components/schemas/ProviderCostResponse"},"type":"array","title":"Costledger"},"specId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specid"},"specVersionHash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specversionhash"},"workflowVersion":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Workflowversion"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"queuedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Queuedat"},"startedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Startedat"},"firstArtifactAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Firstartifactat"},"completedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completedat"},"failedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Failedat"},"archivedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Archivedat"},"durationMs":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Durationms"},"queueWaitMs":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Queuewaitms"},"timeToFirstArtifactMs":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Timetofirstartifactms"},"timeToFinalArtifactMs":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Timetofinalartifactms"},"retryCount":{"type":"integer","title":"Retrycount","default":0},"attempts":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Attempts"},"reaperRequeues":{"type":"integer","title":"Reaperrequeues","default":0}},"type":"object","required":["id","templateId","templateName","status","currentStepIndex","steps","intake","createdAt"],"title":"RunResponse"},"RunStepResponse":{"properties":{"id":{"type":"string","title":"Id"},"runId":{"type":"string","title":"Runid"},"name":{"type":"string","title":"Name"},"status":{"type":"string","title":"Status"},"provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider"},"model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Model"},"startedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Startedat"},"completedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completedat"},"durationMs":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Durationms"},"costEstimatedUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Costestimatedusd"},"costActualUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Costactualusd"},"inputSummary":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Inputsummary"},"outputSummary":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Outputsummary"},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata"},"errorCode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Errorcode"},"errorMessage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Errormessage"},"errorExplanation":{"anyOf":[{"$ref":"#/components/schemas/FailureExplanationResponse"},{"type":"null"}]}},"type":"object","required":["id","runId","name","status"],"title":"RunStepResponse"},"RunSummary":{"properties":{"id":{"type":"string","title":"Id"},"templateId":{"type":"string","title":"Templateid"},"templateName":{"type":"string","title":"Templatename"},"status":{"type":"string","title":"Status"},"currentStepIndex":{"type":"integer","title":"Currentstepindex"},"stepCount":{"type":"integer","title":"Stepcount"},"intake":{"additionalProperties":true,"type":"object","title":"Intake"},"artifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifactid"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"parentRunId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parentrunid"},"parentStepId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parentstepid"},"parentOrderId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parentorderid"},"orderDedupeKey":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Orderdedupekey"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"errorCode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Errorcode"},"failureDetails":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Failuredetails"},"providerOverrides":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Provideroverrides"},"createdVia":{"type":"string","title":"Createdvia","default":"session"},"workerId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Workerid"},"apiKeyId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Apikeyid"},"apiKeyName":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Apikeyname"},"clientUserAgent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Clientuseragent"},"totalCosts":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Totalcosts"},"specId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specid"},"specVersionHash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specversionhash"},"workflowVersion":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Workflowversion"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"queuedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Queuedat"},"startedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Startedat"},"firstArtifactAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Firstartifactat"},"completedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completedat"},"failedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Failedat"},"archivedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Archivedat"},"durationMs":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Durationms"},"queueWaitMs":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Queuewaitms"},"timeToFirstArtifactMs":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Timetofirstartifactms"},"timeToFinalArtifactMs":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Timetofinalartifactms"},"retryCount":{"type":"integer","title":"Retrycount","default":0},"attempts":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Attempts"},"reaperRequeues":{"type":"integer","title":"Reaperrequeues","default":0}},"type":"object","required":["id","templateId","templateName","status","currentStepIndex","stepCount","intake","createdAt"],"title":"RunSummary","description":"Slim list contract (perf 2026-07-10). List endpoints return this instead\nof the full RunResponse: it drops the three heavy per-row arrays — the spec\n``steps`` (replaced by ``step_count``), the normalized ``run_steps``, and the\n``cost_ledger`` (each ledger row carries a ``raw_provider_payload``). Those\nturned a 50-run page into hundreds of KB the list UI never read; the detail\nendpoint still returns the full RunResponse. Keeps ``intake`` (the run name is\nderived from it) and ``total_costs`` (the denormalized spend the list shows)."},"RunwayBurnWindow":{"properties":{"months":{"type":"integer","title":"Months"},"cashInCents":{"type":"integer","title":"Cashincents"},"cashOutCents":{"type":"integer","title":"Cashoutcents"},"netBurnCentsPerMonth":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Netburncentspermonth"},"observedDays":{"type":"integer","title":"Observeddays"}},"type":"object","required":["months","cashInCents","cashOutCents","observedDays"],"title":"RunwayBurnWindow","description":"Net outflow averaged over one trailing window.\n\n`observed_days` is what the rate was actually divided by, which is shorter\nthan the window whenever history is thin. It travels with the number so a\nreader can tell a six-month average from a six-week one wearing its label."},"RunwayPreferencesResponse":{"properties":{"includePersonal":{"type":"boolean","title":"Includepersonal"},"isDefault":{"type":"boolean","title":"Isdefault"}},"type":"object","required":["includePersonal","isDefault"],"title":"RunwayPreferencesResponse","description":"Whether the caller's own personal accounts count in this agency's runway.\n\n`is_default` is true while the member has never chosen, so a client can\ntell \"you turned this on\" from \"owners start with it on\"."},"RunwayPreferencesUpdate":{"properties":{"includePersonal":{"type":"boolean","title":"Includepersonal"}},"type":"object","required":["includePersonal"],"title":"RunwayPreferencesUpdate"},"RunwayWorkspaceCash":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"name":{"type":"string","title":"Name"},"kind":{"type":"string","title":"Kind"},"cashCents":{"type":"integer","title":"Cashcents"},"cardBalanceCents":{"type":"integer","title":"Cardbalancecents"},"cashInCentsPerMonth":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Cashincentspermonth"},"cashOutCentsPerMonth":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Cashoutcentspermonth"},"netBurnCentsPerMonth":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Netburncentspermonth"},"runwayMonths":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Runwaymonths"},"observedDays":{"type":"integer","title":"Observeddays","default":0}},"type":"object","required":["workspaceId","name","kind","cashCents","cardBalanceCents"],"title":"RunwayWorkspaceCash","description":"One workspace's contribution to the pooled cash figure — and, since the\nrunway split, that workspace's own burn and runway.\n\nThe per-side figures use the headline (3-month) window and the same null\nrules as the headline. They differ from the pooled view in one way only:\nmoney moved between two workspaces in scope (the owner's pay, or what the\nowner put in) is REAL money in or out for each side, though it nets to\nnothing in the combined number."},"ScheduleCreate":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"name":{"type":"string","maxLength":120,"minLength":1,"title":"Name"},"cron":{"type":"string","maxLength":100,"minLength":9,"title":"Cron"},"enabled":{"type":"boolean","title":"Enabled","default":true},"workerId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Workerid"},"templateId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Templateid"},"intake":{"additionalProperties":true,"type":"object","title":"Intake"},"providers":{"additionalProperties":{"type":"string"},"type":"object","title":"Providers"}},"type":"object","required":["workspaceId","name","cron"],"title":"ScheduleCreate"},"ScheduleListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ScheduleResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"ScheduleListResponse"},"ScheduleResponse":{"properties":{"id":{"type":"string","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"name":{"type":"string","title":"Name"},"cron":{"type":"string","title":"Cron"},"enabled":{"type":"boolean","title":"Enabled"},"workerId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Workerid"},"templateId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Templateid"},"intake":{"additionalProperties":true,"type":"object","title":"Intake"},"providers":{"additionalProperties":true,"type":"object","title":"Providers"},"lastFiredAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastfiredat"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","workspaceId","name","cron","enabled","intake","providers","createdAt","updatedAt"],"title":"ScheduleResponse"},"ScheduleUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":120,"minLength":1},{"type":"null"}],"title":"Name"},"cron":{"anyOf":[{"type":"string","maxLength":100,"minLength":9},{"type":"null"}],"title":"Cron"},"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled"},"intake":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Intake"},"providers":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Providers"}},"type":"object","title":"ScheduleUpdate"},"ScopeLine":{"properties":{"what":{"type":"string","maxLength":120,"minLength":1,"title":"What"},"count":{"anyOf":[{"type":"integer","maximum":100000.0,"minimum":0.0},{"type":"null"}],"title":"Count"},"per":{"anyOf":[{"type":"string","enum":["month","quarter","year","job"]},{"type":"null"}],"title":"Per"}},"type":"object","required":["what"],"title":"ScopeLine","description":"One thing the fee covers, in the client's words (\"City pages\")."},"ScoreRowResponse":{"properties":{"trialId":{"type":"string","title":"Trialid"},"scorer":{"type":"string","title":"Scorer"},"scorerVersion":{"type":"string","title":"Scorerversion"},"metricKey":{"type":"string","title":"Metrickey"},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value"},"detail":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Detail"}},"type":"object","required":["trialId","scorer","scorerVersion","metricKey","value","detail"],"title":"ScoreRowResponse"},"ScoresResponse":{"properties":{"experimentId":{"type":"string","title":"Experimentid"},"scorers":{"additionalProperties":{"type":"string"},"type":"object","title":"Scorers"},"items":{"items":{"$ref":"#/components/schemas/ScoreRowResponse"},"type":"array","title":"Items"}},"type":"object","required":["experimentId","scorers","items"],"title":"ScoresResponse"},"SectionAcceptRequest":{"properties":{"attemptId":{"type":"string","title":"Attemptid"},"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag"},"requestId":{"anyOf":[{"type":"string","maxLength":64,"minLength":8},{"type":"null"}],"title":"Requestid"}},"type":"object","required":["attemptId"],"title":"SectionAcceptRequest","description":"Keep a version of the section, or Restore an older one: both are\naccepting an attempt."},"SectionActionRequest":{"properties":{"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag"},"requestId":{"anyOf":[{"type":"string","maxLength":64,"minLength":8},{"type":"null"}],"title":"Requestid"}},"type":"object","title":"SectionActionRequest"},"SectionCopy":{"properties":{"heading":{"type":"string","maxLength":500,"title":"Heading"},"lead":{"type":"string","maxLength":1000,"title":"Lead","default":""},"body":{"items":{"type":"string"},"type":"array","maxItems":30,"title":"Body"},"items":{"items":{"$ref":"#/components/schemas/CopyItem"},"type":"array","maxItems":40,"title":"Items"},"cta":{"$ref":"#/components/schemas/CopyCta"},"factsUsed":{"items":{"type":"string"},"type":"array","title":"Factsused"}},"type":"object","required":["heading"],"title":"SectionCopy","description":"A section's words, in the shape the Section Writer writes them."},"SectionEditRequest":{"properties":{"copy":{"$ref":"#/components/schemas/SectionCopy"},"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag"},"requestId":{"anyOf":[{"type":"string","maxLength":64,"minLength":8},{"type":"null"}],"title":"Requestid"}},"type":"object","required":["copy"],"title":"SectionEditRequest","description":"A person's own edit of a section's words. An edit, so it names the\nversion it was made against (API-003)."},"SectionFinding":{"properties":{"code":{"type":"string","title":"Code"},"severity":{"type":"string","title":"Severity"},"message":{"type":"string","title":"Message"}},"type":"object","required":["code","severity","message"],"title":"SectionFinding"},"SectionResponse":{"properties":{"id":{"type":"string","title":"Id"},"pageId":{"type":"string","title":"Pageid"},"position":{"type":"integer","title":"Position"},"status":{"type":"string","title":"Status"},"title":{"type":"string","title":"Title"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"},"brief":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Brief"},"approach":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Approach"},"facts":{"items":{"type":"string"},"type":"array","title":"Facts","default":[]},"headingLevel":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Headinglevel"},"currentArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Currentartifactid"},"attemptCount":{"type":"integer","title":"Attemptcount","default":0},"locked":{"type":"boolean","title":"Locked","default":false},"annotations":{"additionalProperties":true,"type":"object","title":"Annotations","default":{}},"pageEtag":{"type":"string","title":"Pageetag"}},"type":"object","required":["id","pageId","position","status","title","pageEtag"],"title":"SectionResponse"},"SectionVersion":{"properties":{"attemptId":{"type":"string","title":"Attemptid"},"status":{"type":"string","title":"Status"},"source":{"type":"string","title":"Source"},"approach":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Approach"},"artifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifactid"},"rank":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Rank"},"score":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Score"},"auditPassed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Auditpassed"},"findings":{"items":{"$ref":"#/components/schemas/SectionFinding"},"type":"array","title":"Findings","default":[]},"editedBy":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Editedby"},"createdAt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Createdat"},"isCurrent":{"type":"boolean","title":"Iscurrent","default":false}},"type":"object","required":["attemptId","status","source"],"title":"SectionVersion","description":"One version of a section: a draft, a Try 3 more, or a hand edit."},"SectionVersionsResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/SectionVersion"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"SectionVersionsResponse"},"ShiftLinked":{"properties":{"orders":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Orders"},"goals":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Goals"},"tasks":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Tasks"},"messages":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Messages"}},"type":"object","title":"ShiftLinked","description":"The shift's linked resources, resolved server-side when the caller\nasks (?include=linked) — one round trip instead of a per-id client\nfan-out (docs/PERFORMANCE.md route standard). Flat arrays, one level\ndeep, bounded by the links caps."},"ShiftListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ShiftResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"ShiftListResponse"},"ShiftResponse":{"properties":{"id":{"type":"string","title":"Id"},"workerId":{"type":"string","title":"Workerid"},"trigger":{"type":"string","title":"Trigger"},"triggerRef":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Triggerref"},"status":{"type":"string","title":"Status"},"healthy":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Healthy"},"summary":{"type":"string","title":"Summary"},"links":{"additionalProperties":true,"type":"object","title":"Links"},"totalCostUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Totalcostusd"},"startedAt":{"type":"string","format":"date-time","title":"Startedat"},"completedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completedat"},"linked":{"anyOf":[{"$ref":"#/components/schemas/ShiftLinked"},{"type":"null"}]}},"type":"object","required":["id","workerId","trigger","status","summary","links","startedAt"],"title":"ShiftResponse"},"SiteCreate":{"properties":{"projectId":{"type":"string","format":"uuid","title":"Projectid"},"title":{"type":"string","maxLength":300,"minLength":1,"title":"Title"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain"},"phoneFirst":{"type":"boolean","title":"Phonefirst","default":true},"requestId":{"anyOf":[{"type":"string","maxLength":64,"minLength":8},{"type":"null"}],"title":"Requestid"}},"type":"object","required":["projectId","title"],"title":"SiteCreate"},"SiteItemResponse":{"properties":{"id":{"type":"string","title":"Id"},"position":{"type":"integer","title":"Position"},"status":{"type":"string","title":"Status"},"title":{"type":"string","title":"Title"},"role":{"type":"string","title":"Role"},"currentArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Currentartifactid"},"attemptCount":{"type":"integer","title":"Attemptcount","default":0},"annotations":{"additionalProperties":true,"type":"object","title":"Annotations","default":{}}},"type":"object","required":["id","position","status","title","role"],"title":"SiteItemResponse","description":"The header or the footer."},"SiteListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/CollectionSummary"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"SiteListResponse"},"SiteResponse":{"properties":{"id":{"type":"string","title":"Id"},"kind":{"type":"string","title":"Kind"},"format":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Format"},"status":{"type":"string","title":"Status"},"title":{"type":"string","title":"Title"},"etag":{"type":"string","title":"Etag"},"clientRef":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Clientref"},"workspaceId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"sourceArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sourceartifactid"},"coverArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Coverartifactid"},"renditions":{"additionalProperties":true,"type":"object","title":"Renditions","default":{}},"delivery":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Delivery"},"progress":{"$ref":"#/components/schemas/CollectionProgress"},"cost":{"$ref":"#/components/schemas/CollectionCost"},"preview":{"items":{"$ref":"#/components/schemas/PreviewPiece"},"type":"array","title":"Preview","default":[]},"annotations":{"additionalProperties":true,"type":"object","title":"Annotations","default":{}},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain"},"factsArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Factsartifactid"},"designBriefArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Designbriefartifactid"},"phoneFirst":{"type":"boolean","title":"Phonefirst","default":true},"items":{"items":{"$ref":"#/components/schemas/SiteItemResponse"},"type":"array","title":"Items","default":[]}},"type":"object","required":["id","kind","status","title","etag","progress","cost","createdAt","updatedAt"],"title":"SiteResponse"},"SnapshotResponse":{"properties":{"artifactId":{"type":"string","title":"Artifactid"},"published":{"type":"boolean","title":"Published"}},"type":"object","required":["artifactId","published"],"title":"SnapshotResponse"},"SocialAuthUrlResponse":{"properties":{"authUrl":{"type":"string","title":"Authurl"}},"type":"object","required":["authUrl"],"title":"SocialAuthUrlResponse"},"SocialConnectionListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/SocialConnectionResponse"},"type":"array","title":"Items"}},"type":"object","required":["items"],"title":"SocialConnectionListResponse"},"SocialConnectionResponse":{"properties":{"provider":{"type":"string","title":"Provider"},"connected":{"type":"boolean","title":"Connected","default":true},"accountName":{"type":"string","title":"Accountname","default":""},"connectedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Connectedat"}},"type":"object","required":["provider"],"title":"SocialConnectionResponse"},"SocialUploadListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/SocialUploadResponse"},"type":"array","title":"Items"}},"type":"object","required":["items"],"title":"SocialUploadListResponse"},"SocialUploadResponse":{"properties":{"id":{"type":"string","title":"Id"},"provider":{"type":"string","title":"Provider"},"status":{"type":"string","title":"Status"},"title":{"type":"string","title":"Title"},"platformVideoId":{"type":"string","title":"Platformvideoid"},"platformUrl":{"type":"string","title":"Platformurl"},"error":{"type":"string","title":"Error"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"}},"type":"object","required":["id","provider","status","title","platformVideoId","platformUrl","error","createdAt"],"title":"SocialUploadResponse"},"SpecListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/SpecResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"SpecListResponse"},"SpecResponse":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"status":{"type":"string","title":"Status"},"visibility":{"type":"string","title":"Visibility"},"intentSchema":{"additionalProperties":true,"type":"object","title":"Intentschema"},"pipeline":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Pipeline"},"qa":{"additionalProperties":true,"type":"object","title":"Qa"},"outputs":{"additionalProperties":true,"type":"object","title":"Outputs"},"costProfile":{"additionalProperties":true,"type":"object","title":"Costprofile"},"version":{"additionalProperties":true,"type":"object","title":"Version"},"templateId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Templateid"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags"},"isEditable":{"type":"boolean","title":"Iseditable"},"isForked":{"type":"boolean","title":"Isforked"},"parentSpecId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parentspecid"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","name","description","status","visibility","intentSchema","pipeline","qa","outputs","costProfile","version","tags","isEditable","isForked","createdAt","updatedAt"],"title":"SpecResponse"},"StageItem":{"properties":{"label":{"type":"string","title":"Label","default":""},"sublabel":{"type":"string","title":"Sublabel","default":""}},"type":"object","title":"StageItem"},"StatusEventResponse":{"properties":{"fromStatus":{"anyOf":[{"type":"string","enum":["lead","active","paused","past"]},{"type":"null"}],"title":"Fromstatus"},"toStatus":{"type":"string","enum":["lead","active","paused","past"],"title":"Tostatus"},"actorUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Actoruserid"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"at":{"type":"string","format":"date-time","title":"At"}},"type":"object","required":["toStatus","at"],"title":"StatusEventResponse"},"StepCostBreakdown":{"properties":{"stepId":{"type":"string","title":"Stepid"},"stepName":{"type":"string","title":"Stepname"},"kind":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Kind"},"capability":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Capability"},"model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Model"},"costMin":{"type":"number","title":"Costmin"},"costTypical":{"type":"number","title":"Costtypical"},"costMax":{"type":"number","title":"Costmax"}},"type":"object","required":["stepId","stepName","costMin","costTypical","costMax"],"title":"StepCostBreakdown"},"StoryBookPublishRequest":{"properties":{"offer":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Offer"}},"type":"object","title":"StoryBookPublishRequest"},"StoryBookPublishResponse":{"properties":{"artifactId":{"type":"string","title":"Artifactid"},"deliveryStatus":{"type":"string","title":"Deliverystatus"},"deliveryDetail":{"type":"string","title":"Deliverydetail"},"slug":{"type":"string","title":"Slug","default":""},"pageCount":{"type":"integer","title":"Pagecount","default":0},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url"}},"type":"object","required":["artifactId","deliveryStatus","deliveryDetail"],"title":"StoryBookPublishResponse"},"StripeConnectAccountRequest":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"type":"string","format":"uuid","title":"Projectid"},"stripeAccountId":{"type":"string","title":"Stripeaccountid"},"secretKey":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Secretkey"}},"type":"object","required":["workspaceId","projectId","stripeAccountId"],"title":"StripeConnectAccountRequest"},"Subject":{"properties":{"lead":{"type":"string","enum":["outcome","plain"],"title":"Lead","default":"plain"},"maxChars":{"type":"integer","maximum":200.0,"minimum":30.0,"title":"Maxchars","default":200},"noSenderPrefix":{"type":"boolean","title":"Nosenderprefix","default":false}},"type":"object","title":"Subject"},"SubjectAttestations":{"properties":{"adult":{"type":"boolean","const":true,"title":"Adult"},"notPolitical":{"type":"boolean","const":true,"title":"Notpolitical"}},"type":"object","required":["adult","notPolitical"],"title":"SubjectAttestations","description":"What the person adding a subject confirms. Both must be true; the\ndatabase refuses anything else (ck_character_subjects_attestations)."},"SubjectCreate":{"properties":{"displayName":{"type":"string","maxLength":200,"minLength":1,"title":"Displayname"},"email":{"anyOf":[{"type":"string","maxLength":320,"pattern":"^[^@\\s]+@[^@\\s]+$"},{"type":"null"}],"title":"Email"},"publicRole":{"type":"string","enum":["private","public_figure"],"title":"Publicrole","default":"private"},"unionStatus":{"type":"string","enum":["none","sag_aftra","other_union"],"title":"Unionstatus","default":"none"},"attestations":{"$ref":"#/components/schemas/SubjectAttestations"}},"type":"object","required":["displayName","attestations"],"title":"SubjectCreate"},"SubjectListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/SubjectResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"SubjectListResponse"},"SubjectResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"displayName":{"type":"string","title":"Displayname"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"publicRole":{"type":"string","title":"Publicrole"},"unionStatus":{"type":"string","title":"Unionstatus"},"erased":{"type":"boolean","title":"Erased"},"consents":{"items":{"$ref":"#/components/schemas/ConsentResponse"},"type":"array","title":"Consents"},"etag":{"type":"string","title":"Etag"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"erasedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Erasedat"}},"type":"object","required":["id","workspaceId","displayName","publicRole","unionStatus","erased","etag","createdAt"],"title":"SubjectResponse"},"SubjectUpdate":{"properties":{"displayName":{"anyOf":[{"type":"string","maxLength":200,"minLength":1},{"type":"null"}],"title":"Displayname"},"email":{"anyOf":[{"type":"string","maxLength":320,"pattern":"^[^@\\s]+@[^@\\s]+$"},{"type":"null"}],"title":"Email"},"publicRole":{"anyOf":[{"type":"string","enum":["private","public_figure"]},{"type":"null"}],"title":"Publicrole"},"unionStatus":{"anyOf":[{"type":"string","enum":["none","sag_aftra","other_union"]},{"type":"null"}],"title":"Unionstatus"},"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag"}},"type":"object","title":"SubjectUpdate"},"Summary":{"properties":{"lines":{"items":{"type":"string","enum":["happened","needs","cost"]},"type":"array","maxItems":3,"title":"Lines"}},"type":"object","title":"Summary","description":"The three lines that open a letter, built from the record."},"TaskCreate":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"goalId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Goalid"},"title":{"type":"string","maxLength":255,"minLength":1,"title":"Title"},"description":{"type":"string","title":"Description","default":""},"status":{"type":"string","enum":["todo","in_progress","blocked","done","dropped"],"title":"Status","default":"todo"},"priority":{"type":"string","enum":["low","normal","high","urgent"],"title":"Priority","default":"normal"},"dueOn":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Dueon"},"scheduledOn":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Scheduledon"},"assigneeWorkerId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assigneeworkerid"},"links":{"additionalProperties":true,"type":"object","title":"Links"},"position":{"type":"integer","title":"Position","default":0}},"type":"object","required":["workspaceId","title"],"title":"TaskCreate"},"TaskListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/TaskResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"TaskListResponse"},"TaskResponse":{"properties":{"id":{"type":"string","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"goalId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Goalid"},"userId":{"type":"string","format":"uuid","title":"Userid"},"title":{"type":"string","title":"Title"},"description":{"type":"string","title":"Description"},"status":{"type":"string","title":"Status"},"priority":{"type":"string","title":"Priority"},"dueOn":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Dueon"},"scheduledOn":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Scheduledon"},"assigneeWorkerId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assigneeworkerid"},"links":{"additionalProperties":true,"type":"object","title":"Links"},"createdVia":{"type":"string","title":"Createdvia"},"completedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completedat"},"completionNote":{"type":"string","title":"Completionnote","default":""},"position":{"type":"integer","title":"Position"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","workspaceId","userId","title","description","status","priority","links","createdVia","position","createdAt","updatedAt"],"title":"TaskResponse"},"TaskUpdate":{"properties":{"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"goalId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Goalid"},"title":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"status":{"anyOf":[{"type":"string","enum":["todo","in_progress","blocked","done","dropped"]},{"type":"null"}],"title":"Status"},"priority":{"anyOf":[{"type":"string","enum":["low","normal","high","urgent"]},{"type":"null"}],"title":"Priority"},"dueOn":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Dueon"},"scheduledOn":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Scheduledon"},"assigneeWorkerId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assigneeworkerid"},"links":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Links"},"position":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Position"}},"type":"object","title":"TaskUpdate"},"TeamCreate":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"name":{"type":"string","maxLength":120,"minLength":1,"title":"Name"},"produces":{"type":"string","title":"Produces","default":""},"derivedFrom":{"anyOf":[{"$ref":"#/components/schemas/DerivedFrom"},{"type":"null"}]},"description":{"type":"string","title":"Description","default":""},"outletId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outletid"}},"type":"object","required":["workspaceId","name"],"title":"TeamCreate"},"TeamListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/TeamResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"TeamListResponse"},"TeamResponse":{"properties":{"id":{"type":"string","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"name":{"type":"string","title":"Name"},"produces":{"type":"string","title":"Produces","default":""},"derivedFrom":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Derivedfrom"},"description":{"type":"string","title":"Description"},"outletId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outletid"},"changeLog":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Changelog"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","workspaceId","name","description","createdAt","updatedAt"],"title":"TeamResponse"},"TeamUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":120,"minLength":1},{"type":"null"}],"title":"Name"},"produces":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Produces"},"derivedFrom":{"anyOf":[{"$ref":"#/components/schemas/DerivedFrom"},{"type":"null"}]},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"outletId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outletid"}},"type":"object","title":"TeamUpdate"},"ThreadCreate":{"properties":{"title":{"type":"string","maxLength":200,"minLength":1,"title":"Title","default":"New conversation"}},"type":"object","title":"ThreadCreate"},"ThreadListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ThreadResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"ThreadListResponse"},"ThreadResponse":{"properties":{"id":{"type":"string","title":"Id"},"documentId":{"type":"string","title":"Documentid"},"title":{"type":"string","title":"Title"},"lastMessageAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastmessageat"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","documentId","title","createdAt","updatedAt"],"title":"ThreadResponse"},"ThreadUpdate":{"properties":{"title":{"type":"string","maxLength":200,"minLength":1,"title":"Title"}},"type":"object","required":["title"],"title":"ThreadUpdate"},"TokenRange":{"properties":{"min":{"type":"integer","title":"Min"},"typical":{"type":"integer","title":"Typical"},"max":{"type":"integer","title":"Max"}},"type":"object","required":["min","typical","max"],"title":"TokenRange"},"TokenResponse":{"properties":{"accessToken":{"type":"string","title":"Accesstoken"},"refreshToken":{"type":"string","title":"Refreshtoken"},"tokenType":{"type":"string","title":"Tokentype","default":"bearer"}},"type":"object","required":["accessToken","refreshToken"],"title":"TokenResponse"},"ToolEntry":{"properties":{"id":{"type":"string","title":"Id"},"label":{"type":"string","title":"Label"},"description":{"type":"string","title":"Description"},"modelId":{"type":"string","title":"Modelid"},"unit":{"type":"string","title":"Unit"},"inputSchema":{"additionalProperties":true,"type":"object","title":"Inputschema"},"outputSchema":{"additionalProperties":true,"type":"object","title":"Outputschema"}},"type":"object","required":["id","label","description","modelId","unit","inputSchema","outputSchema"],"title":"ToolEntry","description":"Serializable registry metadata for workflow/agent tools."},"ToolListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ToolEntry"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"ToolListResponse"},"TrialListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/TrialResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"TrialListResponse"},"TrialResponse":{"properties":{"id":{"type":"string","title":"Id"},"armKey":{"type":"string","title":"Armkey"},"caseId":{"type":"string","title":"Caseid"},"repeat":{"type":"integer","title":"Repeat"},"position":{"type":"integer","title":"Position"},"runId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Runid"},"artifactIds":{"items":{"type":"string"},"type":"array","title":"Artifactids"},"status":{"type":"string","title":"Status"},"errorCode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Errorcode"},"failureDetails":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Failuredetails"},"costUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Costusd"},"durationMs":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Durationms"},"timeToFirstArtifactMs":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Timetofirstartifactms"},"settledAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Settledat"}},"type":"object","required":["id","armKey","caseId","repeat","position","runId","artifactIds","status","errorCode","failureDetails","costUsd","durationMs","timeToFirstArtifactMs","settledAt"],"title":"TrialResponse"},"TryMoreRequest":{"properties":{"approaches":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":3},{"type":"null"}],"title":"Approaches"},"note":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Note"},"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag"},"requestId":{"anyOf":[{"type":"string","maxLength":64,"minLength":8},{"type":"null"}],"title":"Requestid"}},"type":"object","title":"TryMoreRequest","description":"Three more versions of a section. Approaches default to three the\nsection isn't written in now (web_page_framework.APPROACHES)."},"TryMoreResponse":{"properties":{"id":{"type":"string","title":"Id"},"pageId":{"type":"string","title":"Pageid"},"position":{"type":"integer","title":"Position"},"status":{"type":"string","title":"Status"},"title":{"type":"string","title":"Title"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"},"brief":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Brief"},"approach":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Approach"},"facts":{"items":{"type":"string"},"type":"array","title":"Facts","default":[]},"headingLevel":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Headinglevel"},"currentArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Currentartifactid"},"attemptCount":{"type":"integer","title":"Attemptcount","default":0},"locked":{"type":"boolean","title":"Locked","default":false},"annotations":{"additionalProperties":true,"type":"object","title":"Annotations","default":{}},"pageEtag":{"type":"string","title":"Pageetag"},"orderId":{"type":"string","title":"Orderid"},"orderIds":{"items":{"type":"string"},"type":"array","title":"Orderids","default":[]},"runIds":{"items":{"type":"string"},"type":"array","title":"Runids"},"attemptIds":{"items":{"type":"string"},"type":"array","title":"Attemptids","default":[]},"budgetCapUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Budgetcapusd"},"estimatedCostUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Estimatedcostusd"},"approaches":{"items":{"type":"string"},"type":"array","title":"Approaches","default":[]}},"type":"object","required":["id","pageId","position","status","title","pageEtag","orderId","runIds"],"title":"TryMoreResponse"},"UnreadCountResponse":{"properties":{"count":{"type":"integer","title":"Count"},"messages":{"type":"integer","title":"Messages","default":0},"alerts":{"type":"integer","title":"Alerts","default":0},"payments":{"type":"integer","title":"Payments","default":0}},"type":"object","required":["count"],"title":"UnreadCountResponse","description":"Unread split by decision weight (docs/WORKERS.md §11): `messages` is\nprose written to you (report|message kinds) — the header badge number;\n`alerts` is operational (alert kind) — the subtler indicator. `payments` is\nmoney that arrived (payment kind) — good news, and deliberately kept OUT of\n`messages` so a busy sales day cannot make the decision badge look like a\npile of work. `count` stays as the total for backward compatibility."},"UserResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"email":{"type":"string","title":"Email"},"name":{"type":"string","title":"Name"},"role":{"type":"string","title":"Role"},"isActive":{"type":"boolean","title":"Isactive"},"workspaceMemberships":{"items":{"$ref":"#/components/schemas/WorkspaceMembershipResponse"},"type":"array","title":"Workspacememberships"},"mfaEnabled":{"type":"boolean","title":"Mfaenabled","default":false},"deletionRequestedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Deletionrequestedat"},"deletionApprovedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Deletionapprovedat"},"deletionEffectiveAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Deletioneffectiveat"},"deletionRespondBy":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Deletionrespondby"},"deletionDeclinedReason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Deletiondeclinedreason"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","email","name","role","isActive","createdAt","updatedAt"],"title":"UserResponse"},"UserUpdateRequest":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"}},"type":"object","title":"UserUpdateRequest"},"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"},"VariationSpec":{"properties":{"resolver":{"type":"string","enum":["list","matrix","csv"],"title":"Resolver"},"params":{"additionalProperties":true,"type":"object","title":"Params"}},"type":"object","required":["resolver"],"title":"VariationSpec","description":"How an order fans out into children. `resolver` selects the strategy; `params`\ncarries strategy-specific config (axes for matrix, rows for list, etc.)."},"VerifyResponse":{"properties":{"status":{"type":"string","title":"Status"},"detail":{"type":"string","title":"Detail","default":""},"lastDeliveryAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lastdeliveryat"}},"type":"object","required":["status"],"title":"VerifyResponse"},"VersionCreate":{"properties":{"subjectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Subjectid"},"note":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Note"},"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag"}},"type":"object","title":"VersionCreate"},"VersionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"number":{"type":"integer","title":"Number"},"depicts":{"type":"string","enum":["synthetic","likeness"],"title":"Depicts"},"subjectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Subjectid"},"references":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"References"},"persona":{"additionalProperties":true,"type":"object","title":"Persona"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"bindings":{"items":{"$ref":"#/components/schemas/BindingResponse"},"type":"array","title":"Bindings"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"retiredAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Retiredat"}},"type":"object","required":["id","number","depicts","references","persona","createdAt"],"title":"VersionResponse"},"VideoUploadRequest":{"properties":{"title":{"type":"string","title":"Title","default":""},"description":{"type":"string","title":"Description","default":""},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","default":[]},"privacy":{"type":"string","title":"Privacy","default":"unlisted"}},"type":"object","title":"VideoUploadRequest"},"VideoUploadResult":{"properties":{"status":{"type":"string","title":"Status"},"platformVideoId":{"type":"string","title":"Platformvideoid"},"platformUrl":{"type":"string","title":"Platformurl"}},"type":"object","required":["status","platformVideoId","platformUrl"],"title":"VideoUploadResult"},"Voice":{"properties":{"person":{"type":"string","enum":["first","third"],"title":"Person","default":"first"},"tone":{"type":"string","maxLength":200,"title":"Tone","default":"plainspoken, warm, first person"},"rules":{"items":{"type":"string"},"type":"array","maxItems":12,"title":"Rules"}},"type":"object","title":"Voice","description":"Rules for every word a model writes in this workspace's letters."},"WorkerCreate":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"name":{"type":"string","maxLength":120,"minLength":1,"title":"Name"},"title":{"type":"string","maxLength":120,"title":"Title","default":""},"specialty":{"type":"string","title":"Specialty","default":""},"derivedFrom":{"anyOf":[{"$ref":"#/components/schemas/DerivedFrom"},{"type":"null"}]},"job":{"additionalProperties":true,"type":"object","title":"Job"},"allowedTemplateIds":{"items":{"type":"string"},"type":"array","title":"Allowedtemplateids"},"apiKeyId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Apikeyid"},"teamId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Teamid"},"soloOutletId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Solooutletid"}},"type":"object","required":["workspaceId","name"],"title":"WorkerCreate"},"WorkerListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/WorkerResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"WorkerListResponse"},"WorkerResponse":{"properties":{"id":{"type":"string","title":"Id"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"name":{"type":"string","title":"Name"},"title":{"type":"string","title":"Title"},"specialty":{"type":"string","title":"Specialty"},"derivedFrom":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Derivedfrom"},"job":{"additionalProperties":true,"type":"object","title":"Job"},"allowedTemplateIds":{"items":{"type":"string"},"type":"array","title":"Allowedtemplateids"},"apiKeyId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Apikeyid"},"status":{"type":"string","title":"Status"},"teamId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Teamid"},"soloOutletId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Solooutletid"},"assignmentLog":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Assignmentlog"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","workspaceId","name","title","specialty","job","allowedTemplateIds","status","createdAt","updatedAt"],"title":"WorkerResponse"},"WorkerUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":120,"minLength":1},{"type":"null"}],"title":"Name"},"title":{"anyOf":[{"type":"string","maxLength":120},{"type":"null"}],"title":"Title"},"specialty":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"},"derivedFrom":{"anyOf":[{"$ref":"#/components/schemas/DerivedFrom"},{"type":"null"}]},"job":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Job"},"allowedTemplateIds":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Allowedtemplateids"},"apiKeyId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Apikeyid"},"status":{"anyOf":[{"type":"string","enum":["active","paused","retired"]},{"type":"null"}],"title":"Status"},"teamId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Teamid"},"soloOutletId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Solooutletid"}},"type":"object","title":"WorkerUpdate"},"WorkflowCreate":{"properties":{"id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description","default":""},"shortDescription":{"type":"string","title":"Shortdescription","default":""},"outputType":{"type":"string","title":"Outputtype"},"depth":{"type":"string","title":"Depth","default":"standard"},"estimatedRuntime":{"type":"string","title":"Estimatedruntime","default":"3-5 min"},"includesQa":{"type":"boolean","title":"Includesqa","default":true},"stages":{"items":{"$ref":"#/components/schemas/WorkflowStageSchema"},"type":"array","title":"Stages"},"whatYouProvide":{"items":{"type":"string"},"type":"array","title":"Whatyouprovide"},"whatYouGet":{"items":{"type":"string"},"type":"array","title":"Whatyouget"},"qaChecks":{"items":{"type":"string"},"type":"array","title":"Qachecks"},"exampleArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Exampleartifactid"},"artifactClass":{"type":"string","title":"Artifactclass","default":"research"},"schemaVersion":{"type":"string","title":"Schemaversion","default":"workflow-schema-v1"},"version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Version"},"scopeId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scopeid"},"status":{"type":"string","title":"Status","default":"active"},"supersededById":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supersededbyid"},"visibility":{"type":"string","title":"Visibility","default":"draft"},"cadence":{"type":"string","title":"Cadence","default":"On demand"},"intakeSchema":{"additionalProperties":true,"type":"object","title":"Intakeschema"},"runtimeSteps":{"items":{},"type":"array","title":"Runtimesteps"},"classifiers":{"items":{},"type":"array","title":"Classifiers"},"gates":{"items":{},"type":"array","title":"Gates"},"providers":{"additionalProperties":true,"type":"object","title":"Providers"},"budgetPolicy":{"additionalProperties":true,"type":"object","title":"Budgetpolicy"},"artifactSchema":{"additionalProperties":true,"type":"object","title":"Artifactschema"}},"type":"object","required":["name","outputType"],"title":"WorkflowCreate","description":"Author a new Workflow Template. Canonical fields drive Factory + cost;\nlegacy presentation fields back the catalog/runner view."},"WorkflowListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/WorkflowResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"WorkflowListResponse"},"WorkflowResponse":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"shortDescription":{"type":"string","title":"Shortdescription"},"outputType":{"type":"string","title":"Outputtype"},"depth":{"type":"string","title":"Depth"},"estimatedRuntime":{"type":"string","title":"Estimatedruntime"},"includesQa":{"type":"boolean","title":"Includesqa"},"stages":{"items":{"$ref":"#/components/schemas/WorkflowStageSchema"},"type":"array","title":"Stages"},"whatYouProvide":{"items":{"type":"string"},"type":"array","title":"Whatyouprovide"},"whatYouGet":{"items":{"type":"string"},"type":"array","title":"Whatyouget"},"qaChecks":{"items":{"type":"string"},"type":"array","title":"Qachecks"},"exampleArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Exampleartifactid"},"artifactClass":{"type":"string","title":"Artifactclass","default":"research"},"schemaVersion":{"type":"string","title":"Schemaversion","default":"workflow-schema-v1"},"version":{"type":"string","title":"Version","default":"2026.05.01"},"revision":{"type":"integer","title":"Revision","default":1},"canonicalVersionId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonicalversionid"},"scopeId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scopeid"},"status":{"type":"string","title":"Status","default":"active"},"supersededById":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supersededbyid"},"visibility":{"type":"string","title":"Visibility","default":"draft"},"cadence":{"type":"string","title":"Cadence","default":"On demand"},"intakeSchema":{"additionalProperties":true,"type":"object","title":"Intakeschema"},"runtimeSteps":{"items":{},"type":"array","title":"Runtimesteps"},"classifiers":{"items":{},"type":"array","title":"Classifiers"},"gates":{"items":{},"type":"array","title":"Gates"},"providers":{"additionalProperties":true,"type":"object","title":"Providers"},"budgetPolicy":{"additionalProperties":true,"type":"object","title":"Budgetpolicy"},"artifactSchema":{"additionalProperties":true,"type":"object","title":"Artifactschema"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updatedat"}},"type":"object","required":["id","name","description","shortDescription","outputType","depth","estimatedRuntime","includesQa","stages","whatYouProvide","whatYouGet","qaChecks","createdAt"],"title":"WorkflowResponse"},"WorkflowStageSchema":{"properties":{"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"stepCount":{"type":"integer","title":"Stepcount"}},"type":"object","required":["name","description","stepCount"],"title":"WorkflowStageSchema"},"WorkflowUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"shortDescription":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Shortdescription"},"outputType":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outputtype"},"depth":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Depth"},"estimatedRuntime":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Estimatedruntime"},"includesQa":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Includesqa"},"stages":{"anyOf":[{"items":{"$ref":"#/components/schemas/WorkflowStageSchema"},"type":"array"},{"type":"null"}],"title":"Stages"},"whatYouProvide":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Whatyouprovide"},"whatYouGet":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Whatyouget"},"qaChecks":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Qachecks"},"exampleArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Exampleartifactid"},"artifactClass":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifactclass"},"version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Version"},"scopeId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scopeid"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"supersededById":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supersededbyid"},"visibility":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Visibility"},"cadence":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cadence"},"intakeSchema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Intakeschema"},"runtimeSteps":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Runtimesteps"},"classifiers":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Classifiers"},"gates":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Gates"},"providers":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Providers"},"budgetPolicy":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Budgetpolicy"},"artifactSchema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Artifactschema"}},"type":"object","title":"WorkflowUpdate","description":"Partial update. Any change bumps the template revision."},"WorkflowVersionListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/WorkflowVersionResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"WorkflowVersionListResponse"},"WorkflowVersionResponse":{"properties":{"id":{"type":"string","title":"Id"},"workflowId":{"type":"string","title":"Workflowid"},"version":{"type":"string","title":"Version"},"revision":{"type":"integer","title":"Revision"},"contentHash":{"type":"string","title":"Contenthash"},"isCanonical":{"type":"boolean","title":"Iscanonical","default":false},"createdAt":{"type":"string","format":"date-time","title":"Createdat"}},"type":"object","required":["id","workflowId","version","revision","contentHash","createdAt"],"title":"WorkflowVersionResponse","description":"An immutable published version of a template (history / provenance)."},"WorkspaceCreateRequest":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"slug":{"anyOf":[{"type":"string","maxLength":120,"minLength":1},{"type":"null"}],"title":"Slug"}},"type":"object","required":["name"],"title":"WorkspaceCreateRequest"},"WorkspaceListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/WorkspaceResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"WorkspaceListResponse"},"WorkspaceMembershipResponse":{"properties":{"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"workspaceSlug":{"type":"string","title":"Workspaceslug"},"workspaceName":{"type":"string","title":"Workspacename"},"workspaceKind":{"type":"string","title":"Workspacekind"},"role":{"type":"string","title":"Role"}},"type":"object","required":["workspaceId","workspaceSlug","workspaceName","workspaceKind","role"],"title":"WorkspaceMembershipResponse"},"WorkspaceResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"slug":{"type":"string","title":"Slug"},"name":{"type":"string","title":"Name"},"kind":{"type":"string","title":"Kind"},"ownerUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Owneruserid"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","slug","name","kind","createdAt","updatedAt"],"title":"WorkspaceResponse"},"app__schemas__collection__PackPublishRequest":{"properties":{"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag"},"requestId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Requestid"}},"type":"object","title":"PackPublishRequest"},"app__schemas__document_agent__MessageResponse":{"properties":{"id":{"type":"string","title":"Id"},"threadId":{"type":"string","title":"Threadid"},"sequence":{"type":"integer","title":"Sequence"},"role":{"type":"string","enum":["user","assistant"],"title":"Role"},"kind":{"anyOf":[{"type":"string","enum":["chat","proposal"]},{"type":"null"}],"title":"Kind"},"content":{"type":"string","title":"Content"},"action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Action"},"model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Model"},"status":{"type":"string","enum":["pending","streaming","completed","cancelled","interrupted","error"],"title":"Status"},"errorCode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Errorcode"},"aiRequestId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Airequestid"},"contextScope":{"anyOf":[{"type":"string","enum":["none","selection","section","document","block"]},{"type":"null"}],"title":"Contextscope"},"contextChars":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Contextchars"},"blockId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Blockid"},"applications":{"items":{"$ref":"#/components/schemas/ApplicationResponse"},"type":"array","title":"Applications"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"},"updatedAt":{"type":"string","format":"date-time","title":"Updatedat"}},"type":"object","required":["id","threadId","sequence","role","content","status","createdAt","updatedAt"],"title":"MessageResponse"},"app__schemas__dry_run__DryRunResponse":{"properties":{"ok":{"type":"boolean","title":"Ok"},"stepCount":{"type":"integer","title":"Stepcount"},"intake":{"additionalProperties":true,"type":"object","title":"Intake"},"steps":{"items":{"$ref":"#/components/schemas/DryRunStep"},"type":"array","title":"Steps"},"errors":{"items":{"type":"string"},"type":"array","title":"Errors"},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings"},"estimate":{"anyOf":[{"$ref":"#/components/schemas/CostEstimateResponse"},{"type":"null"}]}},"type":"object","required":["ok","stepCount","intake"],"title":"DryRunResponse"},"app__schemas__experiment__DryRunResponse":{"properties":{"trials":{"type":"integer","title":"Trials"},"perArm":{"additionalProperties":{"additionalProperties":true,"type":"object"},"type":"object","title":"Perarm"},"estimatedCostUsd":{"type":"number","title":"Estimatedcostusd"},"budgetLimitUsd":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Budgetlimitusd"},"withinBudget":{"type":"boolean","title":"Withinbudget"}},"type":"object","required":["trials","perArm","estimatedCostUsd","budgetLimitUsd","withinBudget"],"title":"DryRunResponse"},"app__schemas__generation_order__PackPublishRequest":{"properties":{"planArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Planartifactid"},"coverArtifactId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Coverartifactid"}},"type":"object","title":"PackPublishRequest","description":"The publish-pack act (docs/CLIPART_PACK_ROUTING_FINDINGS.md §3). The\norder↔plan/cover link is explicit-by-request in v1 — no model link exists."},"app__schemas__planning__MessageResponse":{"properties":{"id":{"type":"string","title":"Id"},"userId":{"type":"string","format":"uuid","title":"Userid"},"workspaceId":{"type":"string","format":"uuid","title":"Workspaceid"},"projectId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Projectid"},"kind":{"type":"string","title":"Kind"},"senderType":{"type":"string","title":"Sendertype"},"senderId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Senderid"},"subject":{"type":"string","title":"Subject"},"body":{"type":"string","title":"Body"},"technicalDetail":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Technicaldetail"},"links":{"additionalProperties":true,"type":"object","title":"Links"},"content":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Content"},"createdVia":{"type":"string","title":"Createdvia"},"readAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Readat"},"archivedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Archivedat"},"createdAt":{"type":"string","format":"date-time","title":"Createdat"}},"type":"object","required":["id","userId","workspaceId","kind","senderType","subject","body","links","createdVia","createdAt"],"title":"MessageResponse"}},"securitySchemes":{"HTTPBearer":{"type":"http","scheme":"bearer"}}}}