{"openapi":"3.1.0","info":{"title":"AIR API","version":"0.1.0","description":"HTTP API for AI Responsibly (AIR): manage organizations, domains, projects, risk-assessment documents, and assessments. Integrators authenticate with org-scoped bearer API keys (service accounts); portal users use browser sessions. Interactive reference: https://api.air.thalus.ai/docs."},"paths":{"/":{"get":{"tags":["AIR System"],"operationId":"info","parameters":[],"security":[],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string"},"status":{"type":"string"},"docs":{"type":"string"},"openapi":{"type":"string"}},"required":["name","status","docs","openapi"],"additionalProperties":false}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}}},"description":"Returns the API name, process health, and relative paths to `/docs` and `/openapi.json`. Does not require authentication.","summary":"Get API metadata"}},"/health":{"get":{"tags":["AIR System"],"operationId":"health","parameters":[],"security":[],"responses":{"204":{"description":"<No Content>"},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}}},"description":"Returns 204 No Content when the API process is running. Does not require authentication.","summary":"Liveness check"}},"/users":{"get":{"tags":["AIR Users"],"operationId":"users.list","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"pid":{"type":"string","allOf":[{"pattern":"^usr_[1-9A-HJ-NP-Za-km-z]{16}$","description":"User public id (`usr_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"principalId":{"type":"string","allOf":[{"pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$","format":"uuid"}]},"email":{"type":"string","allOf":[{"minLength":1},{"pattern":"^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$"}]},"name":{"type":"string","allOf":[{"minLength":1}]},"isStaff":{"type":"boolean"},"emailVerifiedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["pid","principalId","email","name","isStaff","emailVerifiedAt","createdAt","updatedAt"],"additionalProperties":false}}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_UnauthorizedError"}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Returns users visible to the caller. Requires a human user session actor; service-account API keys receive 403.","summary":"List users"}},"/users/{pid}":{"get":{"tags":["AIR Users"],"operationId":"users.getByPid","parameters":[{"name":"pid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^usr_[1-9A-HJ-NP-Za-km-z]{16}$","description":"User public id (`usr_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"pid":{"type":"string","allOf":[{"pattern":"^usr_[1-9A-HJ-NP-Za-km-z]{16}$","description":"User public id (`usr_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"principalId":{"type":"string","allOf":[{"pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$","format":"uuid"}]},"email":{"type":"string","allOf":[{"minLength":1},{"pattern":"^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$"}]},"name":{"type":"string","allOf":[{"minLength":1}]},"isStaff":{"type":"boolean"},"emailVerifiedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["pid","principalId","email","name","isStaff","emailVerifiedAt","createdAt","updatedAt"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_UnauthorizedError"}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Returns a single user by public id. Requires a human user session; returns 404 when the pid is unknown or not visible.","summary":"Get user by pid"}},"/account/profile":{"patch":{"tags":["AIR Account"],"operationId":"account.updateProfile","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"}},"required":["success"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Updates the signed-in user display name. Requires a human user session; service-account API keys receive 403.","summary":"Update account profile","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"anyOf":[{"type":"string","allOf":[{"minLength":1}]},{"type":"null"}]}},"additionalProperties":false}}},"required":true}}},"/account/email/request-change":{"post":{"tags":["AIR Account"],"operationId":"account.requestEmailChange","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"}},"required":["success"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"409":{"description":"air/EmailAlreadyInUseError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_EmailAlreadyInUseError"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"429":{"description":"air/RateLimitedError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_RateLimitedError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Starts a confirmed email-change flow by sending a one-time code to the current mailbox. Returns 409 when the target email is already in use.","summary":"Request email change verification","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"newEmail":{"type":"string","allOf":[{"minLength":1},{"pattern":"^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$"}]}},"required":["newEmail"],"additionalProperties":false}}},"required":true}}},"/account/email/verify-change":{"post":{"tags":["AIR Account"],"operationId":"account.verifyEmailChange","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"}},"required":["success"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"409":{"description":"air/EmailAlreadyInUseError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_EmailAlreadyInUseError"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"429":{"description":"air/RateLimitedError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_RateLimitedError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Completes the email-change flow with the code from `requestEmailChange`. Updates credentials and invalidates existing sessions, forcing re-login.","summary":"Verify email change","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","allOf":[{"minLength":6},{"maxLength":6}]}},"required":["code"],"additionalProperties":false}}},"required":true}}},"/account/password":{"post":{"tags":["AIR Account"],"operationId":"account.changePassword","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"}},"required":["success"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Sets or rotates the signed-in user password. OTP-only invited users may set a first password without supplying a current password.","summary":"Change account password","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"currentPassword":{"anyOf":[{"type":"string","allOf":[{"minLength":1}]},{"type":"null"}]},"newPassword":{"type":"string","allOf":[{"minLength":8}]}},"required":["newPassword"],"additionalProperties":false}}},"required":true}}},"/memberships":{"get":{"tags":["AIR Memberships"],"operationId":"memberships.list","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"memberPid":{"type":"string","allOf":[{"pattern":"^mem_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"scopePid":{"type":"string","allOf":[{"pattern":"^scp_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"scopeKind":{"type":"string","enum":["org","domain","project"]},"principalPid":{"type":"string","allOf":[{"pattern":"^prn_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"userPid":{"type":"string","allOf":[{"pattern":"^usr_[1-9A-HJ-NP-Za-km-z]{16}$","description":"User public id (`usr_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"email":{"type":"string"},"name":{"type":"string"},"role":{"type":"string","enum":["owner","admin","member","viewer","service_account"]},"joinedAt":{"type":"string"}},"required":["memberPid","scopePid","scopeKind","principalPid","userPid","email","name","role","joinedAt"],"additionalProperties":false}}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Returns all memberships for the caller's current org. Requires a user actor; service-account API keys are rejected with 403.","summary":"List org members"}},"/memberships/domains/{domainPid}":{"get":{"tags":["AIR Memberships"],"operationId":"memberships.listByDomain","parameters":[{"name":"domainPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"memberPid":{"type":"string","allOf":[{"pattern":"^mem_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"scopePid":{"type":"string","allOf":[{"pattern":"^scp_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"scopeKind":{"type":"string","enum":["org","domain","project"]},"principalPid":{"type":"string","allOf":[{"pattern":"^prn_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"userPid":{"type":"string","allOf":[{"pattern":"^usr_[1-9A-HJ-NP-Za-km-z]{16}$","description":"User public id (`usr_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"email":{"type":"string"},"name":{"type":"string"},"role":{"type":"string","enum":["owner","admin","member","viewer","service_account"]},"joinedAt":{"type":"string"}},"required":["memberPid","scopePid","scopeKind","principalPid","userPid","email","name","role","joinedAt"],"additionalProperties":false}}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Returns memberships for the given `domainPid`. Requires a user actor with read access to the domain; returns 404 when the domain is unknown or not visible to the caller.","summary":"List domain members"}},"/memberships/projects/{projectPid}":{"get":{"tags":["AIR Memberships"],"operationId":"memberships.listByProject","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"memberPid":{"type":"string","allOf":[{"pattern":"^mem_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"scopePid":{"type":"string","allOf":[{"pattern":"^scp_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"scopeKind":{"type":"string","enum":["org","domain","project"]},"principalPid":{"type":"string","allOf":[{"pattern":"^prn_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"userPid":{"type":"string","allOf":[{"pattern":"^usr_[1-9A-HJ-NP-Za-km-z]{16}$","description":"User public id (`usr_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"email":{"type":"string"},"name":{"type":"string"},"role":{"type":"string","enum":["owner","admin","member","viewer","service_account"]},"joinedAt":{"type":"string"}},"required":["memberPid","scopePid","scopeKind","principalPid","userPid","email","name","role","joinedAt"],"additionalProperties":false}}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Returns memberships for the given `projectPid`. Requires a user actor with read access to the project; returns 404 when the project is unknown or not visible to the caller.","summary":"List project members"}},"/memberships/invite":{"post":{"tags":["AIR Memberships"],"operationId":"memberships.invite","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"}},"required":["success"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError | air/SeatLimitExceededError | air/BillingInactiveError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_ForbiddenError"},{"$ref":"#/components/schemas/air_SeatLimitExceededError"},{"$ref":"#/components/schemas/air_BillingInactiveError"}]}}}},"422":{"description":"air/InviteFailedError | air/SchemaValidationError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_InviteFailedError"},{"$ref":"#/components/schemas/air_SchemaValidationError"}]}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Adds a user to the caller's org by email, provisioning user and principal records when needed. Dispatches an org-invite email; the invitee signs in via email OTP. Requires a trusted browser origin, org owner/admin role, and an active billing seat. Returns 422 `already_member` when the email is already in this org (the only client-visible invite failure — unknown emails are provisioned silently). Returns 403 when seat limits or billing block the invite.","summary":"Invite member by email","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"email":{"type":"string","allOf":[{"minLength":1},{"pattern":"^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$"}]},"name":{"type":"string","allOf":[{"minLength":1}]},"role":{"anyOf":[{"type":"string","enum":["owner","admin","member","viewer","service_account"]},{"type":"null"}]}},"required":["email","name"],"additionalProperties":false}}},"required":true}}},"/memberships/access/{scopeKind}/{scopePid}":{"get":{"tags":["AIR Memberships"],"operationId":"memberships.scopeAccess","parameters":[{"name":"scopeKind","in":"path","schema":{"type":"string","enum":["org","domain","project"]},"required":true},{"name":"scopePid","in":"path","schema":{"anyOf":[{"type":"string","allOf":[{"pattern":"^org_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Organization public id (`org_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"canManage":{"type":"boolean"},"canContribute":{"type":"boolean"},"effectiveRole":{"anyOf":[{"type":"string","enum":["owner","admin","member","viewer","service_account"]},{"type":"null"}]}},"required":["canManage","canContribute","effectiveRole"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Returns whether the caller can manage or contribute in the given `scopeKind`/`scopePid`, plus their effective management role when present. Requires a user actor; returns 404 when the scope is unknown or not visible.","summary":"Get caller access for a scope"}},"/memberships/{scopeKind}/{scopePid}/members":{"post":{"tags":["AIR Memberships"],"operationId":"memberships.addScopeMember","parameters":[{"name":"scopeKind","in":"path","schema":{"type":"string","enum":["domain","project"]},"required":true},{"name":"scopePid","in":"path","schema":{"anyOf":[{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"memberPid":{"type":"string","allOf":[{"pattern":"^mem_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"scopePid":{"type":"string","allOf":[{"pattern":"^scp_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"scopeKind":{"type":"string","enum":["org","domain","project"]},"principalPid":{"type":"string","allOf":[{"pattern":"^prn_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"userPid":{"type":"string","allOf":[{"pattern":"^usr_[1-9A-HJ-NP-Za-km-z]{16}$","description":"User public id (`usr_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"email":{"type":"string"},"name":{"type":"string"},"role":{"type":"string","enum":["owner","admin","member","viewer","service_account"]},"joinedAt":{"type":"string"}},"required":["memberPid","scopePid","scopeKind","principalPid","userPid","email","name","role","joinedAt"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/MembershipMutationError | air/SchemaValidationError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_MembershipMutationError"},{"$ref":"#/components/schemas/air_SchemaValidationError"}]}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Grants an existing org member access to a `domain` or `project` sub-scope via `principalPid` and `role`. Org membership is created only through `invite`. Requires a trusted origin and owner/admin of the scope (or an ancestor). Returns 422 when the principal is not an org member, is already in the scope, is a service account, or the mutation would remove the last owner.","summary":"Add existing member to domain or project","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"principalPid":{"type":"string","allOf":[{"pattern":"^prn_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"role":{"type":"string","enum":["owner","admin","member","viewer","service_account"]}},"required":["principalPid","role"],"additionalProperties":false}}},"required":true}}},"/memberships/{scopeKind}/{scopePid}/members/{memberPid}":{"patch":{"tags":["AIR Memberships"],"operationId":"memberships.updateScopeMemberRole","parameters":[{"name":"scopeKind","in":"path","schema":{"type":"string","enum":["org","domain","project"]},"required":true},{"name":"scopePid","in":"path","schema":{"anyOf":[{"type":"string","allOf":[{"pattern":"^org_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Organization public id (`org_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]}]},"required":true},{"name":"memberPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^mem_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"}},"required":["success"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/MembershipMutationError | air/SchemaValidationError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_MembershipMutationError"},{"$ref":"#/components/schemas/air_SchemaValidationError"}]}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Changes the `role` of `memberPid` within the path scope. Requires a trusted origin and scope owner/admin; admins cannot grant, modify, or remove owner-level membership. Returns 404 when the membership is not in the scope; returns 422 on owner-ceiling or last-owner violations.","summary":"Update member role in scope","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"role":{"type":"string","enum":["owner","admin","member","viewer","service_account"]}},"required":["role"],"additionalProperties":false}}},"required":true}},"delete":{"tags":["AIR Memberships"],"operationId":"memberships.removeScopeMember","parameters":[{"name":"scopeKind","in":"path","schema":{"type":"string","enum":["org","domain","project"]},"required":true},{"name":"scopePid","in":"path","schema":{"anyOf":[{"type":"string","allOf":[{"pattern":"^org_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Organization public id (`org_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]}]},"required":true},{"name":"memberPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^mem_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"}},"required":["success"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/MembershipMutationError | air/SchemaValidationError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_MembershipMutationError"},{"$ref":"#/components/schemas/air_SchemaValidationError"}]}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Revokes `memberPid` from the path scope. Requires a trusted origin and scope owner/admin; admins cannot remove owners. Returns 404 when the membership is not in the scope; returns 422 when removing the last owner.","summary":"Remove member from scope"}},"/memberships/{scopeKind}/{scopePid}/members/{memberPid}/reinvite":{"post":{"tags":["AIR Memberships"],"operationId":"memberships.reinviteScopeMember","parameters":[{"name":"scopeKind","in":"path","schema":{"type":"string","enum":["org","domain","project"]},"required":true},{"name":"scopePid","in":"path","schema":{"anyOf":[{"type":"string","allOf":[{"pattern":"^org_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Organization public id (`org_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]}]},"required":true},{"name":"memberPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^mem_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"}},"required":["success"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Re-dispatches the org-invite email for `memberPid` bound to the path scope (prevents cross-scope invite by pid). Requires a trusted origin and scope owner/admin. Returns 404 when the member is not in the scope.","summary":"Resend invite email to scope member"}},"/memberships/{scopeKind}/{scopePid}/members/{memberPid}/email":{"patch":{"tags":["AIR Memberships"],"operationId":"memberships.changeScopeMemberEmail","parameters":[{"name":"scopeKind","in":"path","schema":{"type":"string","enum":["org","domain","project"]},"required":true},{"name":"scopePid","in":"path","schema":{"anyOf":[{"type":"string","allOf":[{"pattern":"^org_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Organization public id (`org_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]}]},"required":true},{"name":"memberPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^mem_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"}},"required":["success"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"409":{"description":"air/EmailAlreadyInUseError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_EmailAlreadyInUseError"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Updates the login email for `memberPid` in the path scope, cascading to credentials and forcing re-login. Requires a trusted origin and scope owner/admin; admins cannot change an owner's email. Returns 409 when the new email is already in use; returns 404 when the member is not in the scope.","summary":"Change member login email","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"email":{"type":"string","allOf":[{"minLength":1},{"pattern":"^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$"}]}},"required":["email"],"additionalProperties":false}}},"required":true}}},"/domains/{domainPid}/service-accounts":{"get":{"tags":["AIR Service Accounts"],"operationId":"service-accounts.list","parameters":[{"name":"domainPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"pid":{"type":"string","allOf":[{"pattern":"^svc_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Service account public id (`svc_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"name":{"type":"string","allOf":[{"minLength":1}]},"description":{"anyOf":[{"type":"string","allOf":[{"minLength":1}]},{"type":"null"}]},"createdAt":{"type":"string"}},"required":["pid","name","description","createdAt"],"additionalProperties":false}}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Lists machine principals in the caller domain. Requires domain owner or admin role; members receive 403.","summary":"List service accounts"},"post":{"tags":["AIR Service Accounts"],"operationId":"service-accounts.create","parameters":[{"name":"domainPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"pid":{"type":"string","allOf":[{"pattern":"^svc_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Service account public id (`svc_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"name":{"type":"string","allOf":[{"minLength":1}]},"description":{"anyOf":[{"type":"string","allOf":[{"minLength":1}]},{"type":"null"}]},"createdAt":{"type":"string"}},"required":["pid","name","description","createdAt"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Creates a service account for API integrations in the caller domain. Requires domain owner or admin role.","summary":"Create service account","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","allOf":[{"minLength":1}]},"description":{"anyOf":[{"anyOf":[{"type":"string","allOf":[{"minLength":1}]},{"type":"null"}]},{"type":"null"}]}},"required":["name"],"additionalProperties":false}}},"required":true}}},"/domains/{domainPid}/service-accounts/{serviceAccountPid}/keys":{"get":{"tags":["AIR Service Accounts"],"operationId":"service-accounts.listKeys","parameters":[{"name":"domainPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"serviceAccountPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^svc_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Service account public id (`svc_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"pid":{"type":"string","allOf":[{"pattern":"^ak_[1-9A-HJ-NP-Za-km-z]{16}$","description":"API key public id (`ak_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"name":{"type":"string","allOf":[{"minLength":1}]},"keyPrefix":{"type":"string","allOf":[{"minLength":1}]},"canCopy":{"type":"boolean"},"scopes":{"type":"array","items":{"type":"string","enum":["projects:read","projects:write","assessments:read","assessments:write","domains:read","domains:write","portfolio:read","search:read","integrations:full"],"description":"Integrator permission for this API key (`resource:action`). Write scopes imply read on the same resource; `integrations:full` grants all integrator scopes."}},"expiresAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"disabledAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"revokedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"lastUsedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"createdAt":{"type":"string"}},"required":["pid","name","keyPrefix","canCopy","scopes","expiresAt","disabledAt","revokedAt","lastUsedAt","createdAt"],"additionalProperties":false}}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Returns masked key metadata (pid, prefix, scopes, timestamps). Never includes raw secrets or hashes. Returns 404 for foreign service-account pids.","summary":"List API keys for a service account"},"post":{"tags":["AIR Service Accounts"],"operationId":"service-accounts.createKey","parameters":[{"name":"domainPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"serviceAccountPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^svc_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Service account public id (`svc_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Newly minted API key with the full bearer token.","content":{"application/json":{"schema":{"type":"object","properties":{"key":{"type":"object","properties":{"pid":{"type":"string","allOf":[{"pattern":"^ak_[1-9A-HJ-NP-Za-km-z]{16}$","description":"API key public id (`ak_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"name":{"type":"string","allOf":[{"minLength":1}]},"keyPrefix":{"type":"string","allOf":[{"minLength":1}]},"canCopy":{"type":"boolean"},"scopes":{"type":"array","items":{"type":"string","enum":["projects:read","projects:write","assessments:read","assessments:write","domains:read","domains:write","portfolio:read","search:read","integrations:full"],"description":"Integrator permission for this API key (`resource:action`). Write scopes imply read on the same resource; `integrations:full` grants all integrator scopes."}},"expiresAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"disabledAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"revokedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"lastUsedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"createdAt":{"type":"string"}},"required":["pid","name","keyPrefix","canCopy","scopes","expiresAt","disabledAt","revokedAt","lastUsedAt","createdAt"],"additionalProperties":false},"rawKey":{"type":"string","allOf":[{"pattern":"^air_[A-Za-z0-9_-]+\\.(ak_[1-9A-HJ-NP-Za-km-z]{16})\\.[A-Za-z0-9_-]{32,}$"}]}},"required":["key","rawKey"],"additionalProperties":false,"description":"Newly minted API key with the full bearer token."}}}},"400":{"description":"BadRequest","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_BadRequest"}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Mints a bearer API key scoped to this domain. Requires a non-empty `scopes` array.","summary":"Create API key","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","allOf":[{"minLength":1}]},"scopes":{"type":"array","items":{"type":"string","enum":["projects:read","projects:write","assessments:read","assessments:write","domains:read","domains:write","portfolio:read","search:read","integrations:full"],"description":"Integrator permission for this API key (`resource:action`). Write scopes imply read on the same resource; `integrations:full` grants all integrator scopes."}},"expiresAt":{"anyOf":[{"anyOf":[{"type":"string"},{"type":"null"}]},{"type":"null"}]}},"required":["name","scopes"],"additionalProperties":false}}},"required":true}}},"/domains/{domainPid}/service-accounts/{serviceAccountPid}/keys/{keyPid}/raw":{"get":{"tags":["AIR Service Accounts"],"operationId":"service-accounts.revealKey","parameters":[{"name":"domainPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"serviceAccountPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^svc_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Service account public id (`svc_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"keyPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^ak_[1-9A-HJ-NP-Za-km-z]{16}$","description":"API key public id (`ak_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Full bearer token for an active API key. Requires domain manager access.","content":{"application/json":{"schema":{"type":"object","properties":{"rawKey":{"type":"string","allOf":[{"pattern":"^air_[A-Za-z0-9_-]+\\.(ak_[1-9A-HJ-NP-Za-km-z]{16})\\.[A-Za-z0-9_-]{32,}$"}]}},"required":["rawKey"],"additionalProperties":false,"description":"Full bearer token for an active API key. Requires domain manager access."}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Returns the full bearer token for an active API key. Requires domain owner or admin role.","summary":"Reveal API key"}},"/domains/{domainPid}/service-accounts/{serviceAccountPid}/keys/{keyPid}/revoke":{"post":{"tags":["AIR Service Accounts"],"operationId":"service-accounts.revokeKey","parameters":[{"name":"domainPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"serviceAccountPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^svc_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Service account public id (`svc_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"keyPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^ak_[1-9A-HJ-NP-Za-km-z]{16}$","description":"API key public id (`ak_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"pid":{"type":"string","allOf":[{"pattern":"^ak_[1-9A-HJ-NP-Za-km-z]{16}$","description":"API key public id (`ak_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"name":{"type":"string","allOf":[{"minLength":1}]},"keyPrefix":{"type":"string","allOf":[{"minLength":1}]},"canCopy":{"type":"boolean"},"scopes":{"type":"array","items":{"type":"string","enum":["projects:read","projects:write","assessments:read","assessments:write","domains:read","domains:write","portfolio:read","search:read","integrations:full"],"description":"Integrator permission for this API key (`resource:action`). Write scopes imply read on the same resource; `integrations:full` grants all integrator scopes."}},"expiresAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"disabledAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"revokedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"lastUsedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"createdAt":{"type":"string"}},"required":["pid","name","keyPrefix","canCopy","scopes","expiresAt","disabledAt","revokedAt","lastUsedAt","createdAt"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Revokes a key immediately; subsequent bearer requests with that key return 401. Returns 404 for foreign pids.","summary":"Revoke API key"}},"/orgs/{orgSlug}":{"get":{"tags":["AIR Orgs"],"operationId":"orgs.findBySlug","parameters":[{"name":"orgSlug","in":"path","schema":{"type":"string","allOf":[{"minLength":1}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Organization summary returned by org lookups.","content":{"application/json":{"schema":{"type":"object","properties":{"pid":{"type":"string","allOf":[{"pattern":"^org_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Organization public id (`org_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"name":{"type":"string","allOf":[{"minLength":1}]},"slug":{"type":"string","allOf":[{"minLength":1}]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["pid","name","slug","createdAt","updatedAt"],"additionalProperties":false,"description":"Organization summary returned by org lookups."}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Returns the org summary for a URL slug. Requires membership in the org; returns 404 rather than 403 when the slug exists but is not visible to the caller.","summary":"Find org by slug"}},"/orgs/{orgSlug}/portfolio":{"get":{"tags":["AIR Portfolio"],"operationId":"portfolio.orgPortfolio","parameters":[{"name":"orgSlug","in":"path","schema":{"type":"string","allOf":[{"minLength":1}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"orgPid":{"type":"string","allOf":[{"pattern":"^org_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Organization public id (`org_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"orgSlug":{"type":"string","allOf":[{"minLength":1}]},"orgName":{"type":"string"},"refreshedAt":{"type":"string"},"summary":{"type":"object","properties":{"totalProjects":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"assessedProjects":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"unassessedProjects":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"activeAssessments":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"riskStates":{"type":"object","properties":{"outstanding":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"managed":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"potential":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"cannotEvaluate":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"total":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["outstanding","managed","potential","cannotEvaluate","total"],"additionalProperties":false},"controlsSuggested":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"controlCoverageRate":{"anyOf":[{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},{"type":"null"}]}},"required":["totalProjects","assessedProjects","unassessedProjects","activeAssessments","riskStates","controlsSuggested","controlCoverageRate"],"additionalProperties":false},"riskDistribution":{"type":"object","properties":{"outstanding":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"managed":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"potential":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"cannotEvaluate":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"total":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["outstanding","managed","potential","cannotEvaluate","total"],"additionalProperties":false},"lifecycleMatrix":{"type":"array","items":{"type":"object","properties":{"stage":{"type":"string","enum":["Plan","Build","Validate","Run"]},"state":{"type":"string","enum":["outstanding","managed","potential","cannotEvaluate"]},"projectCount":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["stage","state","projectCount"],"additionalProperties":false}},"lifecycleStages":{"type":"array","items":{"type":"object","properties":{"stage":{"type":"string","enum":["Plan","Build","Validate","Run"]},"projectsAtStage":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"outstandingRiskCount":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"managedRiskCount":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"coverageRate":{"anyOf":[{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},{"type":"null"}]}},"required":["stage","projectsAtStage","outstandingRiskCount","managedRiskCount","coverageRate"],"additionalProperties":false}},"euAiActTiers":{"type":"array","items":{"type":"object","properties":{"tier":{"type":"string","enum":["UNACCEPTABLE","HIGH","LIMITED","MINIMAL","UNCLASSIFIED","NA"]},"projectCount":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"portfolioPct":{"anyOf":[{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},{"type":"null"}]},"assessedCount":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"assessedPct":{"anyOf":[{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},{"type":"null"}]},"naBreakdown":{"anyOf":[{"type":"object","properties":{"unassessedProjects":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"indeterminateTierProjects":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["unassessedProjects","indeterminateTierProjects"],"additionalProperties":false},{"type":"null"}]}},"required":["tier","projectCount","portfolioPct","assessedCount","assessedPct"],"additionalProperties":false}},"topThemes":{"type":"array","items":{"type":"object","properties":{"rank":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"themeId":{"type":"string"},"themeName":{"type":"string"},"projectCount":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"prevalencePct":{"anyOf":[{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},{"type":"null"}]},"severityRatio":{"anyOf":[{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},{"type":"null"}]}},"required":["rank","themeId","themeName","projectCount","prevalencePct","severityRatio"],"additionalProperties":false}},"topControls":{"type":"array","items":{"type":"object","properties":{"rank":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"controlId":{"type":"string"},"controlName":{"type":"string"},"projectCount":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"suggestionRatePct":{"anyOf":[{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},{"type":"null"}]}},"required":["rank","controlId","controlName","projectCount","suggestionRatePct"],"additionalProperties":false}},"edgeCases":{"type":"object","properties":{"noCompletedAssessments":{"type":"boolean"},"allCannotEvaluate":{"type":"boolean"},"hasUnassessedProjects":{"type":"boolean"},"insufficientDataForTrends":{"type":"boolean"}},"required":["noCompletedAssessments","allCannotEvaluate","hasUnassessedProjects","insufficientDataForTrends"],"additionalProperties":false},"unassessedProjects":{"type":"array","items":{"type":"object","properties":{"projectPid":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"projectSlug":{"type":"string","allOf":[{"minLength":1}]},"projectName":{"type":"string"},"domainPid":{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"domainSlug":{"type":"string","allOf":[{"minLength":1}]},"domainName":{"type":"string"}},"required":["projectPid","projectSlug","projectName","domainPid","domainSlug","domainName"],"additionalProperties":false}},"riskHeatmap":{"type":"array","items":{"type":"object","properties":{"entityPid":{"type":"string"},"entitySlug":{"type":"string","allOf":[{"minLength":1}]},"entityName":{"type":"string"},"riskCounts":{"type":"object","properties":{"outstanding":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"managed":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"potential":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"cannotEvaluate":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["outstanding","managed","potential","cannotEvaluate"],"additionalProperties":false}},"required":["entityPid","entitySlug","entityName","riskCounts"],"additionalProperties":false}},"topDomains":{"type":"array","items":{"type":"object","properties":{"domainPid":{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"domainSlug":{"type":"string","allOf":[{"minLength":1}]},"domainName":{"type":"string"},"tierSummary":{"type":"string"},"tierDistribution":{"type":"array","items":{"type":"object","properties":{"tier":{"type":"string","enum":["UNACCEPTABLE","HIGH","LIMITED","MINIMAL","UNCLASSIFIED","NA"]},"count":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["tier","count"],"additionalProperties":false}},"lastAssessedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"riskCounts":{"type":"object","properties":{"outstanding":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"managed":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"potential":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"cannotEvaluate":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["outstanding","managed","potential","cannotEvaluate"],"additionalProperties":false},"controlCoverageRate":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["domainPid","domainSlug","domainName","tierSummary","tierDistribution","lastAssessedAt","riskCounts","controlCoverageRate"],"additionalProperties":false}},"bottomDomains":{"type":"array","items":{"type":"object","properties":{"domainPid":{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"domainSlug":{"type":"string","allOf":[{"minLength":1}]},"domainName":{"type":"string"},"tierSummary":{"type":"string"},"tierDistribution":{"type":"array","items":{"type":"object","properties":{"tier":{"type":"string","enum":["UNACCEPTABLE","HIGH","LIMITED","MINIMAL","UNCLASSIFIED","NA"]},"count":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["tier","count"],"additionalProperties":false}},"lastAssessedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"riskCounts":{"type":"object","properties":{"outstanding":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"managed":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"potential":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"cannotEvaluate":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["outstanding","managed","potential","cannotEvaluate"],"additionalProperties":false},"controlCoverageRate":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["domainPid","domainSlug","domainName","tierSummary","tierDistribution","lastAssessedAt","riskCounts","controlCoverageRate"],"additionalProperties":false}},"unrankedDomainCount":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["orgPid","orgSlug","orgName","refreshedAt","summary","riskDistribution","lifecycleMatrix","lifecycleStages","euAiActTiers","topThemes","topControls","edgeCases","unassessedProjects","riskHeatmap","topDomains","bottomDomains","unrankedDomainCount"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Returns portfolio-level risk and project summaries for the org identified by `orgSlug`. Requires access to the org; returns 404 when the slug is unknown or not visible to the caller.","summary":"Get org portfolio dashboard"}},"/orgs/{orgSlug}/domains/{domainSlug}/portfolio":{"get":{"tags":["AIR Portfolio"],"operationId":"portfolio.domainPortfolio","parameters":[{"name":"orgSlug","in":"path","schema":{"type":"string","allOf":[{"minLength":1}]},"required":true},{"name":"domainSlug","in":"path","schema":{"type":"string","allOf":[{"minLength":1}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"orgPid":{"type":"string","allOf":[{"pattern":"^org_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Organization public id (`org_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"orgSlug":{"type":"string","allOf":[{"minLength":1}]},"domainPid":{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"domainSlug":{"type":"string","allOf":[{"minLength":1}]},"domainName":{"type":"string"},"refreshedAt":{"type":"string"},"summary":{"type":"object","properties":{"totalProjects":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"assessedProjects":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"unassessedProjects":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"activeAssessments":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"riskStates":{"type":"object","properties":{"outstanding":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"managed":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"potential":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"cannotEvaluate":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"total":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["outstanding","managed","potential","cannotEvaluate","total"],"additionalProperties":false},"controlsSuggested":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"controlCoverageRate":{"anyOf":[{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},{"type":"null"}]}},"required":["totalProjects","assessedProjects","unassessedProjects","activeAssessments","riskStates","controlsSuggested","controlCoverageRate"],"additionalProperties":false},"riskDistribution":{"type":"object","properties":{"outstanding":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"managed":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"potential":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"cannotEvaluate":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"total":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["outstanding","managed","potential","cannotEvaluate","total"],"additionalProperties":false},"lifecycleMatrix":{"type":"array","items":{"type":"object","properties":{"stage":{"type":"string","enum":["Plan","Build","Validate","Run"]},"state":{"type":"string","enum":["outstanding","managed","potential","cannotEvaluate"]},"projectCount":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["stage","state","projectCount"],"additionalProperties":false}},"lifecycleStages":{"type":"array","items":{"type":"object","properties":{"stage":{"type":"string","enum":["Plan","Build","Validate","Run"]},"projectsAtStage":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"outstandingRiskCount":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"managedRiskCount":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"coverageRate":{"anyOf":[{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},{"type":"null"}]}},"required":["stage","projectsAtStage","outstandingRiskCount","managedRiskCount","coverageRate"],"additionalProperties":false}},"euAiActTiers":{"type":"array","items":{"type":"object","properties":{"tier":{"type":"string","enum":["UNACCEPTABLE","HIGH","LIMITED","MINIMAL","UNCLASSIFIED","NA"]},"projectCount":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"portfolioPct":{"anyOf":[{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},{"type":"null"}]},"assessedCount":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"assessedPct":{"anyOf":[{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},{"type":"null"}]},"naBreakdown":{"anyOf":[{"type":"object","properties":{"unassessedProjects":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"indeterminateTierProjects":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["unassessedProjects","indeterminateTierProjects"],"additionalProperties":false},{"type":"null"}]}},"required":["tier","projectCount","portfolioPct","assessedCount","assessedPct"],"additionalProperties":false}},"topThemes":{"type":"array","items":{"type":"object","properties":{"rank":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"themeId":{"type":"string"},"themeName":{"type":"string"},"projectCount":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"prevalencePct":{"anyOf":[{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},{"type":"null"}]},"severityRatio":{"anyOf":[{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},{"type":"null"}]}},"required":["rank","themeId","themeName","projectCount","prevalencePct","severityRatio"],"additionalProperties":false}},"topControls":{"type":"array","items":{"type":"object","properties":{"rank":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"controlId":{"type":"string"},"controlName":{"type":"string"},"projectCount":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"suggestionRatePct":{"anyOf":[{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},{"type":"null"}]}},"required":["rank","controlId","controlName","projectCount","suggestionRatePct"],"additionalProperties":false}},"edgeCases":{"type":"object","properties":{"noCompletedAssessments":{"type":"boolean"},"allCannotEvaluate":{"type":"boolean"},"hasUnassessedProjects":{"type":"boolean"},"insufficientDataForTrends":{"type":"boolean"}},"required":["noCompletedAssessments","allCannotEvaluate","hasUnassessedProjects","insufficientDataForTrends"],"additionalProperties":false},"unassessedProjects":{"type":"array","items":{"type":"object","properties":{"projectPid":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"projectSlug":{"type":"string","allOf":[{"minLength":1}]},"projectName":{"type":"string"},"domainPid":{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"domainSlug":{"type":"string","allOf":[{"minLength":1}]},"domainName":{"type":"string"}},"required":["projectPid","projectSlug","projectName","domainPid","domainSlug","domainName"],"additionalProperties":false}},"topProjects":{"type":"array","items":{"type":"object","properties":{"projectPid":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"projectSlug":{"type":"string","allOf":[{"minLength":1}]},"projectName":{"type":"string"},"activeAssessmentPid":{"type":"string","allOf":[{"pattern":"^pasm_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"euAiActTier":{"type":"string","enum":["UNACCEPTABLE","HIGH","LIMITED","MINIMAL","UNCLASSIFIED","NA"]},"lastAssessedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"riskCounts":{"type":"object","properties":{"outstanding":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"managed":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"potential":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"cannotEvaluate":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["outstanding","managed","potential","cannotEvaluate"],"additionalProperties":false},"controlCoverageRate":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["projectPid","projectSlug","projectName","activeAssessmentPid","euAiActTier","lastAssessedAt","riskCounts","controlCoverageRate"],"additionalProperties":false}},"bottomProjects":{"type":"array","items":{"type":"object","properties":{"projectPid":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"projectSlug":{"type":"string","allOf":[{"minLength":1}]},"projectName":{"type":"string"},"activeAssessmentPid":{"type":"string","allOf":[{"pattern":"^pasm_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"euAiActTier":{"type":"string","enum":["UNACCEPTABLE","HIGH","LIMITED","MINIMAL","UNCLASSIFIED","NA"]},"lastAssessedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"riskCounts":{"type":"object","properties":{"outstanding":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"managed":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"potential":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"cannotEvaluate":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["outstanding","managed","potential","cannotEvaluate"],"additionalProperties":false},"controlCoverageRate":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["projectPid","projectSlug","projectName","activeAssessmentPid","euAiActTier","lastAssessedAt","riskCounts","controlCoverageRate"],"additionalProperties":false}},"unrankedProjectCount":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["orgPid","orgSlug","domainPid","domainSlug","domainName","refreshedAt","summary","riskDistribution","lifecycleMatrix","lifecycleStages","euAiActTiers","topThemes","topControls","edgeCases","unassessedProjects","topProjects","bottomProjects","unrankedProjectCount"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Returns portfolio summaries scoped to a domain within an org. Requires access to the domain; returns 404 when either slug is unknown or not visible to the caller.","summary":"Get domain portfolio dashboard"}},"/domains":{"get":{"tags":["AIR Domains"],"operationId":"domains.list","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"pid":{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"name":{"type":"string","allOf":[{"minLength":1}]},"slug":{"type":"string","allOf":[{"minLength":1}]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["pid","name","slug","createdAt","updatedAt"],"additionalProperties":false}}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Returns all domains for the caller's current organization. Requires a user actor.","summary":"List domains in current org"},"post":{"tags":["AIR Domains"],"operationId":"domains.create","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"pid":{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"name":{"type":"string","allOf":[{"minLength":1}]},"slug":{"type":"string","allOf":[{"minLength":1}]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["pid","name","slug","createdAt","updatedAt"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_Conflict"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Creates a domain in the caller's current organization with `name` and `slug`. Requires org owner/admin. Returns 409 when the slug conflicts with an existing domain.","summary":"Create domain in current org","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","allOf":[{"minLength":1}]},"slug":{"type":"string","allOf":[{"minLength":1}]}},"required":["name","slug"],"additionalProperties":false}}},"required":true}}},"/domains/{domainPid}/projects":{"get":{"tags":["AIR Domains"],"operationId":"domains.listProjects","parameters":[{"name":"domainPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"search","in":"query","schema":{"anyOf":[{"type":"string"},{"type":"null"}]},"required":false},{"name":"sortBy","in":"query","schema":{"anyOf":[{"type":"string","enum":["pid","name","createdAt","updatedAt"]},{"type":"null"}]},"required":false},{"name":"sortDirection","in":"query","schema":{"anyOf":[{"type":"string","enum":["asc","desc"]},{"type":"null"}]},"required":false},{"name":"page","in":"query","schema":{"anyOf":[{"type":"string"},{"type":"null"}]},"required":false},{"name":"pageSize","in":"query","schema":{"anyOf":[{"type":"string"},{"type":"null"}]},"required":false}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","properties":{"pid":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"name":{"type":"string","allOf":[{"minLength":1}]},"slug":{"type":"string","allOf":[{"minLength":1}]},"description":{"anyOf":[{"type":"string"},{"type":"null"}]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"},"latestAssessmentStatus":{"anyOf":[{"type":"string","enum":["draft","queued","running","completed","failed"]},{"type":"null"}]},"assessmentCount":{"type":"integer"}},"required":["pid","name","slug","description","createdAt","updatedAt","latestAssessmentStatus","assessmentCount"],"additionalProperties":false}},"page":{"type":"integer"},"pageSize":{"type":"integer"},"total":{"type":"integer"},"totalPages":{"type":"integer"}},"required":["items","page","pageSize","total","totalPages"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Returns a paginated page of projects within `domainPid`, with optional `search`, `sortBy`, and `sortDirection`. Requires a user actor; returns 404 when the domain is unknown or not visible to the caller.","summary":"List projects in a domain"},"post":{"tags":["AIR Domains"],"operationId":"domains.createProject","parameters":[{"name":"domainPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"pid":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"name":{"type":"string","allOf":[{"minLength":1}]},"slug":{"type":"string","allOf":[{"minLength":1}]},"description":{"anyOf":[{"type":"string"},{"type":"null"}]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["pid","name","slug","description","createdAt","updatedAt"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError | air/ProjectLimitExceededError | air/BillingInactiveError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_ForbiddenError"},{"$ref":"#/components/schemas/air_ProjectLimitExceededError"},{"$ref":"#/components/schemas/air_BillingInactiveError"}]}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_Conflict"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Creates a project under `domainPid` with `name`, `slug`, and optional `description`. Requires domain contributor access and an active billing subscription within project limits. Returns 403 when billing is inactive or the org project limit is exceeded; returns 409 when the slug conflicts.","summary":"Create project in domain","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","allOf":[{"minLength":1}]},"slug":{"type":"string","allOf":[{"minLength":1}]},"description":{"anyOf":[{"anyOf":[{"type":"string"},{"type":"null"}]},{"type":"null"}]}},"required":["name","slug"],"additionalProperties":false}}},"required":true}}},"/domains/lookup/{orgSlug}/{domainSlug}":{"get":{"tags":["AIR Domains"],"operationId":"domains.lookupBySlug","parameters":[{"name":"orgSlug","in":"path","schema":{"type":"string","allOf":[{"minLength":1}]},"required":true},{"name":"domainSlug","in":"path","schema":{"type":"string","allOf":[{"minLength":1}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"pid":{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"name":{"type":"string","allOf":[{"minLength":1}]},"slug":{"type":"string","allOf":[{"minLength":1}]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["pid","name","slug","createdAt","updatedAt"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Returns the domain summary for the given `orgSlug` and `domainSlug`. Requires a user actor; returns 404 when either slug is unknown or not visible to the caller.","summary":"Find domain by org and domain slugs"}},"/domains/{domainPid}":{"delete":{"tags":["AIR Domains"],"operationId":"domains.delete","parameters":[{"name":"domainPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"<No Content>"},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Permanently deletes `domainPid` when it belongs to the caller's current org. Requires org owner/admin. Returns 404 when the domain is unknown, foreign, or not visible.","summary":"Delete domain"}},"/domains/{domainPid}/projects/{projectPid}":{"delete":{"tags":["AIR Domains"],"operationId":"domains.deleteProject","parameters":[{"name":"domainPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"<No Content>"},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Permanently deletes `projectPid` when it belongs to `domainPid`. Requires domain owner/admin. Returns 404 when the domain or project is unknown, the project is not in the domain, or not visible to the caller.","summary":"Delete project from domain"}},"/projects/{projectPid}/documents":{"get":{"tags":["AIR Projects"],"operationId":"projects.listDocuments","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"includeArchived","in":"query","schema":{"anyOf":[{"type":"string","enum":["true","false"]},{"type":"null"}]},"required":false}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","allOf":[{"pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$","format":"uuid"}]},"pid":{"type":"string","allOf":[{"pattern":"^psrc_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"projectId":{"type":"string","allOf":[{"pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$","format":"uuid"}]},"kind":{"type":"string","enum":["document","github_repo","databricks_workspace","sagemaker_account"],"description":"Kind of project source. `document` is an uploaded file processed by extraction; connector kinds are driven by integration workflows."},"name":{"type":"string","allOf":[{"minLength":1}]},"status":{"type":"string","enum":["connected","degraded","disconnected","error","processing"]},"lastSyncedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"lastError":{"anyOf":[{"type":"string"},{"type":"null"}]},"archivedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"progress":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"currentStage":{"anyOf":[{"type":"string"},{"type":"null"}]},"createdByPrincipalId":{"anyOf":[{"type":"string","allOf":[{"pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$","format":"uuid"}]},{"type":"null"}]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","pid","projectId","kind","name","status","lastSyncedAt","lastError","archivedAt","progress","currentStage","createdByPrincipalId","createdAt","updatedAt"],"additionalProperties":false}}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Returns document sources (`kind === 'document'`) for the project. Pass `includeArchived: true` to include archived sources. Requires project access; returns 404 when `projectPid` is unknown or not visible.","summary":"List project documents"}},"/projects/{projectPid}/artifacts":{"get":{"tags":["AIR Projects"],"operationId":"projects.listArtifacts","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"includeArchived","in":"query","schema":{"anyOf":[{"type":"string","enum":["true","false"]},{"type":"null"}]},"required":false}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"artifactPid":{"type":"string","allOf":[{"pattern":"^artf_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"sourcePid":{"anyOf":[{"type":"string","allOf":[{"pattern":"^psrc_[1-9A-HJ-NP-Za-km-z]{16}$"}]},{"type":"null"}]},"sourceKind":{"anyOf":[{"type":"string","enum":["document","github_repo","databricks_workspace","sagemaker_account"],"description":"Kind of project source. `document` is an uploaded file processed by extraction; connector kinds are driven by integration workflows."},{"type":"null"}]},"kind":{"type":"string","enum":["document","source_file","notebook","structured_snapshot"]},"name":{"type":"string"},"description":{"anyOf":[{"type":"string"},{"type":"null"}]},"mediaPid":{"anyOf":[{"type":"string","allOf":[{"pattern":"^med_[1-9A-HJ-NP-Za-km-z]{16}$"}]},{"type":"null"}]},"filename":{"anyOf":[{"type":"string"},{"type":"null"}]},"contentType":{"anyOf":[{"type":"string"},{"type":"null"}]},"sizeBytes":{"anyOf":[{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},{"type":"null"}]},"externalUri":{"anyOf":[{"type":"string"},{"type":"null"}]},"fingerprint":{"anyOf":[{"type":"string"},{"type":"null"}]},"fetchedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"archivedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"createdAt":{"type":"string"}},"required":["artifactPid","sourcePid","sourceKind","kind","name","description","mediaPid","filename","contentType","sizeBytes","externalUri","fingerprint","fetchedAt","archivedAt","createdAt"],"additionalProperties":false}}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Returns document-derived artifacts for the project. Includes archived artifacts when `includeArchived` is true. Requires project access; returns 404 when `projectPid` is unknown or not visible.","summary":"List project document artifacts"}},"/projects/{projectPid}/artifacts/{artifactPid}":{"get":{"tags":["AIR Projects"],"operationId":"projects.getArtifact","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"artifactPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^artf_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"artifactPid":{"type":"string","allOf":[{"pattern":"^artf_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"sourcePid":{"anyOf":[{"type":"string","allOf":[{"pattern":"^psrc_[1-9A-HJ-NP-Za-km-z]{16}$"}]},{"type":"null"}]},"sourceKind":{"anyOf":[{"type":"string","enum":["document","github_repo","databricks_workspace","sagemaker_account"],"description":"Kind of project source. `document` is an uploaded file processed by extraction; connector kinds are driven by integration workflows."},{"type":"null"}]},"kind":{"type":"string","enum":["document","source_file","notebook","structured_snapshot"]},"name":{"type":"string"},"description":{"anyOf":[{"type":"string"},{"type":"null"}]},"mediaPid":{"anyOf":[{"type":"string","allOf":[{"pattern":"^med_[1-9A-HJ-NP-Za-km-z]{16}$"}]},{"type":"null"}]},"filename":{"anyOf":[{"type":"string"},{"type":"null"}]},"contentType":{"anyOf":[{"type":"string"},{"type":"null"}]},"sizeBytes":{"anyOf":[{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},{"type":"null"}]},"externalUri":{"anyOf":[{"type":"string"},{"type":"null"}]},"fingerprint":{"anyOf":[{"type":"string"},{"type":"null"}]},"fetchedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"archivedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"},"hasText":{"type":"boolean"}},"required":["artifactPid","sourcePid","sourceKind","kind","name","description","mediaPid","filename","contentType","sizeBytes","externalUri","fingerprint","fetchedAt","archivedAt","createdAt","updatedAt","hasText"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Returns full artifact metadata for `artifactPid` scoped to `projectPid`. Requires project access; returns 404 when the project or artifact is unknown or not visible.","summary":"Get artifact details"},"delete":{"tags":["AIR Projects"],"operationId":"projects.deleteArtifact","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"artifactPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^artf_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"<No Content>"},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_Conflict"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Permanently deletes the artifact row and cleans up its extracted-text media. Returns 409 when the artifact is cited by any assessment — cited evidence may only be archived via `archiveArtifact`, never destroyed. Requires project access; returns 404 when the project or artifact is unknown or not visible.","summary":"Hard-delete artifact"}},"/projects/{projectPid}/artifacts/{artifactPid}/text":{"get":{"tags":["AIR Projects"],"operationId":"projects.getArtifactText","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"artifactPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^artf_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"text":{"type":"string"},"contentType":{"type":"string"},"byteSize":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"truncated":{"type":"boolean"}},"required":["text","contentType","byteSize","truncated"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Returns the artifact's extracted text, truncated to the preview byte limit when stored in media. Requires project access; returns 404 when the project, artifact, or backing media is unknown or not visible.","summary":"Get artifact extracted text"}},"/projects/{projectPid}/sources":{"get":{"tags":["AIR Projects"],"operationId":"projects.listSources","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"kind","in":"query","schema":{"anyOf":[{"type":"string","enum":["document","github_repo","databricks_workspace","sagemaker_account"],"description":"Kind of project source. `document` is an uploaded file processed by extraction; connector kinds are driven by integration workflows."},{"type":"null"}]},"required":false}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/air_ProjectSource"}}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Returns all sources for the project. Filters by `kind` when the query parameter is set. Requires project access; returns 404 when `projectPid` is unknown or not visible.","summary":"List project sources"},"post":{"tags":["AIR Projects"],"operationId":"projects.createSource","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"sourcePid":{"type":"string","allOf":[{"pattern":"^psrc_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"workflowPid":{"type":"string","allOf":[{"pattern":"^wfr_[1-9A-HJ-NP-Za-km-z]{16}$"}]}},"required":["sourcePid","workflowPid"],"additionalProperties":false}}}},"400":{"description":"BadRequest","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_BadRequest"}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Creates a connector-backed source (`github_repo`, `databricks_workspace`) for the project: validates `config` and `credentials` against the connector schemas, encrypts the credentials into the secrets store, then dispatches `IngestSourceWorkflow` to pull artifacts. Returns 400 when the kind has no registered connector or the config/credentials do not match its schema. Requires project access.","summary":"Connect a source integration","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"kind":{"type":"string","enum":["document","github_repo","databricks_workspace","sagemaker_account"],"description":"Kind of project source. `document` is an uploaded file processed by extraction; connector kinds are driven by integration workflows."},"name":{"type":"string","allOf":[{"minLength":1}]},"config":{},"credentials":{}},"required":["kind","name","config","credentials"],"additionalProperties":false}}},"required":true}}},"/projects/lookup/{orgSlug}/{domainSlug}/{projectSlug}":{"get":{"tags":["AIR Projects"],"operationId":"projects.lookupBySlug","parameters":[{"name":"orgSlug","in":"path","schema":{"type":"string","allOf":[{"minLength":1}]},"required":true},{"name":"domainSlug","in":"path","schema":{"type":"string","allOf":[{"minLength":1}]},"required":true},{"name":"projectSlug","in":"path","schema":{"type":"string","allOf":[{"minLength":1}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"pid":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"name":{"type":"string","allOf":[{"minLength":1}]},"slug":{"type":"string","allOf":[{"minLength":1}]},"description":{"anyOf":[{"type":"string"},{"type":"null"}]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["pid","name","slug","description","createdAt","updatedAt"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Resolves a project by `orgSlug`, `domainSlug`, and `projectSlug` and returns its summary. Requires access to the org; returns 404 when any slug in the chain is unknown or not visible to the caller.","summary":"Look up project by slugs"}},"/projects/{projectPid}/documents/upload-init":{"post":{"tags":["AIR Projects"],"operationId":"projects.initUpload","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"uploadUrl":{"type":"string"},"s3Key":{"type":"string"}},"required":["uploadUrl","s3Key"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Returns a presigned PUT `uploadUrl` and `s3Key` for uploading the original bytes directly to object storage. Caller must PUT the file to `uploadUrl`, then call `upload-complete` with the same `s3Key`. Requires project access; returns 404 when `projectPid` is unknown or not visible.","summary":"Start presigned document upload","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"filename":{"type":"string"},"contentType":{"type":"string"}},"required":["filename","contentType"],"additionalProperties":false}}},"required":true}}},"/projects/{projectPid}/documents/upload-complete":{"post":{"tags":["AIR Projects"],"operationId":"projects.completeUpload","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"sourcePid":{"type":"string","allOf":[{"pattern":"^psrc_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"workflowPid":{"type":"string","allOf":[{"pattern":"^wfr_[1-9A-HJ-NP-Za-km-z]{16}$"}]}},"required":["sourcePid","workflowPid"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Finalizes a presigned upload after bytes are in storage: creates the media row and document source, then dispatches `ExtractDocumentArtifactsWorkflow`. Returns `sourcePid` and `workflowPid` for lifecycle tracking. Requires project access; returns 404 when `projectPid` is unknown or not visible.","summary":"Complete presigned document upload","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"s3Key":{"type":"string"},"filename":{"type":"string"},"contentType":{"type":"string"}},"required":["s3Key","filename","contentType"],"additionalProperties":false}}},"required":true}}},"/projects/{projectPid}/documents/{sourcePid}/download":{"get":{"tags":["AIR Projects"],"operationId":"projects.getDocumentDownloadUrl","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"sourcePid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^psrc_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"downloadUrl":{"type":"string"},"filename":{"type":"string"}},"required":["downloadUrl","filename"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Returns a time-limited `downloadUrl` and `filename` for the document's original blob. Requires project access; returns 404 when the source, project, or original media is unknown or not visible.","summary":"Get presigned document download URL"}},"/projects/{projectPid}/documents/{sourcePid}":{"delete":{"tags":["AIR Projects"],"operationId":"projects.deleteDocument","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"sourcePid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^psrc_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"<No Content>"},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Hard-deletes the document source. Derived artifacts are archived (preserved as assessment evidence), not destroyed — there is no assessment-usage conflict on this route. Requires project access; returns 404 when the source or project is unknown or not visible.","summary":"Delete document source"}},"/projects/{projectPid}/artifacts/{artifactPid}/archive":{"post":{"tags":["AIR Projects"],"operationId":"projects.archiveArtifact","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"artifactPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^artf_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"<No Content>"},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Archives `artifactPid` within `projectPid`, preserving it as assessment evidence without deleting the row. Requires project access; returns 404 when the project or artifact is unknown or not visible.","summary":"Archive artifact"}},"/projects/{projectPid}/documents/{sourcePid}/archive":{"post":{"tags":["AIR Projects"],"operationId":"projects.archiveDocument","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"sourcePid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^psrc_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"<No Content>"},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Archives the document source without deleting it. Archived sources are omitted from default list calls unless `includeArchived` is true. Requires project access; returns 404 when the source or project is unknown or not visible.","summary":"Archive document source"}},"/projects/{projectPid}/documents/{sourcePid}/unarchive":{"post":{"tags":["AIR Projects"],"operationId":"projects.unarchiveDocument","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"sourcePid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^psrc_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"<No Content>"},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Restores an archived document source to active status. Requires project access; returns 404 when the source or project is unknown or not visible.","summary":"Unarchive document source"}},"/projects/{projectPid}/documents/{sourcePid}/regenerate":{"post":{"tags":["AIR Projects"],"operationId":"projects.regenerateDocument","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"sourcePid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^psrc_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"sourcePid":{"type":"string","allOf":[{"pattern":"^psrc_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"workflowPid":{"type":"string","allOf":[{"pattern":"^wfr_[1-9A-HJ-NP-Za-km-z]{16}$"}]}},"required":["sourcePid","workflowPid"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_Conflict"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Re-reads the stored original blob, re-parses, and idempotently replaces the artifact and chunks by dispatching `ExtractDocumentArtifactsWorkflow`. Returns `sourcePid` and `workflowPid` so the caller can resubscribe to lifecycle events. Returns 409 when the source is already `processing` or still has an active (non-archived) artifact. Requires project access; returns 404 when the source or project is unknown or not visible.","summary":"Re-run document extraction"}},"/projects/{projectPid}/sources/{sourcePid}/sync":{"post":{"tags":["AIR Projects"],"operationId":"projects.syncSource","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true},{"name":"sourcePid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^psrc_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"sourcePid":{"type":"string","allOf":[{"pattern":"^psrc_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"workflowPid":{"type":"string","allOf":[{"pattern":"^wfr_[1-9A-HJ-NP-Za-km-z]{16}$"}]}},"required":["sourcePid","workflowPid"],"additionalProperties":false}}}},"400":{"description":"BadRequest","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_BadRequest"}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_Conflict"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Re-runs ingestion for an existing connector source. Unchanged remote content is skipped via fingerprint dedup; new or changed content produces fresh artifacts. Returns 409 while a sync is already `processing`, 400 for sources without a registered connector (e.g. `document`). Requires project access.","summary":"Re-sync a connector source"}},"/projects/{projectPid}/sources/test-connection":{"post":{"tags":["AIR Projects"],"operationId":"projects.testSourceConnection","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"string","enum":["connected","degraded","disconnected","error"]},"message":{"anyOf":[{"type":"string"},{"type":"null"}]},"checkedAt":{"type":"string"}},"required":["status","message","checkedAt"],"additionalProperties":false}}}},"400":{"description":"BadRequest","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_BadRequest"}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Validates `config`/`credentials` against the connector schemas and performs a live connection check against the remote system without persisting anything. Returns the health status so the UI can confirm a token works before saving. Returns 400 when the kind has no registered connector or the shapes are invalid.","summary":"Test connector credentials","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"kind":{"type":"string","enum":["document","github_repo","databricks_workspace","sagemaker_account"],"description":"Kind of project source. `document` is an uploaded file processed by extraction; connector kinds are driven by integration workflows."},"config":{},"credentials":{}},"required":["kind","config","credentials"],"additionalProperties":false}}},"required":true}}},"/assessments/projects/{projectPid}":{"post":{"tags":["AIR Assessments"],"operationId":"assessments.startForProject","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true}],"security":[{"bearer":[]}],"responses":{"202":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"assessmentPid":{"type":"string","allOf":[{"pattern":"^pasm_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"workflowRunId":{"type":"string"}},"required":["assessmentPid","workflowRunId"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"402":{"description":"air/InsufficientCreditsError | air/TrialExpiredError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_InsufficientCreditsError"},{"$ref":"#/components/schemas/air_TrialExpiredError"}]}}}},"403":{"description":"air/ForbiddenError | air/BillingInactiveError | air/SeatLimitExceededError | air/FeatureNotAvailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_ForbiddenError"},{"$ref":"#/components/schemas/air_BillingInactiveError"},{"$ref":"#/components/schemas/air_SeatLimitExceededError"},{"$ref":"#/components/schemas/air_FeatureNotAvailableError"}]}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Creates a project assessment, locks org credits for the run, and dispatches `RiskAssessmentWorkflow`. Requires project contributor scope and a billable org (`assertCanRunAssessment`). Returns 202 with `assessmentPid` and `workflowRunId`. May return 402 or 403 billing errors when credits are insufficient, the trial has expired, or billing is inactive.","summary":"Start assessment for project","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string"},"artifactPids":{"type":"array","items":{"type":"string","allOf":[{"pattern":"^artf_[1-9A-HJ-NP-Za-km-z]{16}$"}]}}},"required":["name","artifactPids"],"additionalProperties":false}}},"required":true}},"get":{"tags":["AIR Assessments"],"operationId":"assessments.listByProject","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"pid":{"type":"string","allOf":[{"pattern":"^pasm_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"name":{"type":"string","allOf":[{"minLength":1}]},"status":{"type":"string","enum":["draft","queued","running","completed","failed"]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"},"startedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"completedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"failedAt":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["pid","name","status","createdAt","updatedAt","startedAt","completedAt","failedAt"],"additionalProperties":false}}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Lists assessment summaries for a project. Requires project reader scope. Omits assessments the caller's org cannot access under report-history billing rules. Returns 404 when the project is unknown or not visible.","summary":"List project assessments"}},"/assessments/projects/{projectPid}/drafts":{"post":{"tags":["AIR Assessments"],"operationId":"assessments.createDraftForProject","parameters":[{"name":"projectPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^prj_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Project public id (`prj_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"required":true}],"security":[{"bearer":[]}],"responses":{"201":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"assessmentPid":{"type":"string","allOf":[{"pattern":"^pasm_[1-9A-HJ-NP-Za-km-z]{16}$"}]}},"required":["assessmentPid"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Creates an assessment row without starting the risk pipeline. Requires project contributor scope. When `artifactPids` are provided, stores them as draft selection on the assessment. Auto-generates a display name when `name` is empty. Returns 201 with `assessmentPid`.","summary":"Create assessment draft","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string"},"artifactPids":{"type":"array","items":{"type":"string","allOf":[{"pattern":"^artf_[1-9A-HJ-NP-Za-km-z]{16}$"}]}}},"required":["name","artifactPids"],"additionalProperties":false}}},"required":true}}},"/assessments/{assessmentPid}":{"get":{"tags":["AIR Assessments"],"operationId":"assessments.getByPid","parameters":[{"name":"assessmentPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^pasm_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"pid":{"type":"string","allOf":[{"pattern":"^pasm_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"name":{"type":"string","allOf":[{"minLength":1}]},"status":{"type":"string","enum":["draft","queued","running","completed","failed"]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"},"workflowRunId":{"anyOf":[{"type":"string"},{"type":"null"}]},"reportAvailable":{"type":"boolean"}},"required":["pid","name","status","createdAt","updatedAt","workflowRunId","reportAvailable"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"402":{"description":"air/InsufficientCreditsError | air/TrialExpiredError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_InsufficientCreditsError"},{"$ref":"#/components/schemas/air_TrialExpiredError"}]}}}},"403":{"description":"air/ForbiddenError | air/BillingInactiveError | air/SeatLimitExceededError | air/FeatureNotAvailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_ForbiddenError"},{"$ref":"#/components/schemas/air_BillingInactiveError"},{"$ref":"#/components/schemas/air_SeatLimitExceededError"},{"$ref":"#/components/schemas/air_FeatureNotAvailableError"}]}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Returns assessment metadata including `workflowRunId` and whether a report is available. Requires project reader scope and report-history billing access for the assessment. Returns 404 when the assessment is unknown or not visible; may return 403 when billing or feature gates block access.","summary":"Get assessment details"}},"/assessments/{assessmentPid}/report":{"get":{"tags":["AIR Assessments"],"operationId":"assessments.getReport","parameters":[{"name":"assessmentPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^pasm_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"assessmentPid":{"type":"string","allOf":[{"pattern":"^pasm_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"projectName":{"type":"string"},"projectOverview":{"type":"string"},"systemProfile":{"anyOf":[{"type":"object","properties":{"systemName":{"type":"string"},"purpose":{"type":"string"},"useCaseDomain":{"type":"string"},"modelsUsed":{"type":"array","items":{"type":"string"}},"dataSources":{"type":"array","items":{"type":"string"}},"deploymentContext":{"type":"string"},"stakeholdersMentioned":{"type":"array","items":{"type":"string"}},"lifecycleStageIndicators":{"type":"array","items":{"type":"string"}},"thirdPartyDependencies":{"type":"array","items":{"type":"string"}},"modalities":{"type":"array","items":{"type":"string","enum":["predictive","generative","computer_vision","ranking","autonomous","rule_based","hybrid"]}},"jurisdictions":{"type":"array","items":{"type":"string","enum":["EU","UK","US_federal","US_HIPAA","US_FINRA","internal_only"]}},"blastRadius":{"type":"string","enum":["low","medium","high","critical"]},"inputNeeded":{"type":"array","items":{"type":"string","enum":["modalities","jurisdictions","blastRadius"]}}},"required":["systemName","purpose","useCaseDomain","modelsUsed","dataSources","deploymentContext","stakeholdersMentioned","lifecycleStageIndicators","thirdPartyDependencies","modalities","jurisdictions","blastRadius","inputNeeded"],"additionalProperties":false},{"type":"null"}]},"quality":{"type":"object","properties":{"sourceCount":{"type":"integer"},"evidenceChunkCount":{"type":"integer"},"citedEvidenceChunkCount":{"type":"integer"},"inputNeeded":{"type":"array","items":{"type":"string","enum":["modalities","jurisdictions","blastRadius"]}},"providerFailures":{"type":"array","items":{"type":"object","properties":{"stage":{"type":"string"},"reason":{"type":"string"}},"required":["stage","reason"],"additionalProperties":false}},"lowConfidenceRiskCount":{"type":"integer"}},"required":["sourceCount","evidenceChunkCount","citedEvidenceChunkCount","inputNeeded","providerFailures","lowConfidenceRiskCount"],"additionalProperties":false},"controlEvidence":{"type":"array","items":{"type":"object","properties":{"riskId":{"type":"string"},"controlId":{"type":"string"},"status":{"type":"string","enum":["implemented","partially_evidenced","missing_implementation","missing_evidence","not_assessed","input_needed"]},"evidenceChunkIds":{"type":"array","items":{"type":"string"}},"evidenceRequired":{"type":"array","items":{"type":"string"}},"closeCriteria":{"type":"array","items":{"type":"string"}},"findings":{"type":"string"},"actionNeeded":{"type":"string"}},"required":["riskId","controlId","status","evidenceChunkIds","evidenceRequired","closeCriteria","findings","actionNeeded"],"additionalProperties":false}},"overview":{"type":"object","properties":{"totalRisks":{"type":"integer"},"requiredControls":{"type":"integer"},"implementedControls":{"type":"integer"},"missingControls":{"type":"integer"}},"required":["totalRisks","requiredControls","implementedControls","missingControls"],"additionalProperties":false},"riskRegister":{"type":"array","items":{"type":"object","properties":{"riskId":{"type":"string"},"riskTitle":{"type":"string"},"riskStatement":{"type":"string"},"themeName":{"type":"string"},"familyName":{"type":"string"},"themeId":{"type":"string"},"themeState":{"type":"string","enum":["triggered","potential_risk","not_triggered","cannot_evaluate"]},"evidenceChunkIds":{"type":"array","items":{"type":"string"}},"confidence":{"type":"string","enum":["low","medium","high"]},"signalHighlights":{"type":"array","items":{"type":"object","properties":{"signalText":{"type":"string"},"controlId":{"anyOf":[{"type":"string"},{"type":"null"}]},"presentStatus":{"type":"string","enum":["present","absent","missing","unclear"]},"signalKind":{"type":"string","enum":["risk","control"]},"evidenceChunkIds":{"type":"array","items":{"type":"string"}},"rationale":{"type":"string"}},"required":["signalText","presentStatus","signalKind","evidenceChunkIds","rationale"],"additionalProperties":false}},"lifecycleStages":{"type":"array","items":{"type":"string","enum":["Plan","Build","Validate","Run"]}},"affectedStakeholders":{"type":"array","items":{"type":"string","enum":["customer","employee","patient","citizen","regulator","third_party","environment"]}},"likelihood":{"anyOf":[{"type":"string","enum":["low","medium","high"]},{"type":"null"}]},"severity":{"anyOf":[{"type":"string","enum":["low","medium","high"]},{"type":"null"}]},"likelihoodRationale":{"type":"string"},"severityRationale":{"type":"string"},"inherentSeverity":{"anyOf":[{"type":"integer"},{"type":"null"}]}},"required":["riskId","riskTitle","riskStatement","themeName","familyName","themeId","themeState","evidenceChunkIds","confidence","signalHighlights","lifecycleStages","affectedStakeholders","likelihoodRationale","severityRationale"],"additionalProperties":false}},"watchlist":{"type":"array","items":{"type":"object","properties":{"themeId":{"type":"string"},"themeName":{"type":"string"},"familyName":{"type":"string"},"riskTitle":{"type":"string"},"riskStatement":{"type":"string"},"confidence":{"type":"string","enum":["low","medium","high"]},"evidenceChunkIds":{"type":"array","items":{"type":"string"}},"signalHighlights":{"type":"array","items":{"type":"object","properties":{"signalText":{"type":"string"},"controlId":{"anyOf":[{"type":"string"},{"type":"null"}]},"presentStatus":{"type":"string","enum":["present","absent","missing","unclear"]},"signalKind":{"type":"string","enum":["risk","control"]},"evidenceChunkIds":{"type":"array","items":{"type":"string"}},"rationale":{"type":"string"}},"required":["signalText","presentStatus","signalKind","evidenceChunkIds","rationale"],"additionalProperties":false}}},"required":["themeId","themeName","familyName","riskTitle","riskStatement","confidence","evidenceChunkIds","signalHighlights"],"additionalProperties":false}},"clearedThemes":{"type":"array","items":{"type":"object","properties":{"themeId":{"type":"string"},"themeName":{"type":"string"},"familyName":{"type":"string"},"riskTitle":{"type":"string"},"riskStatement":{"type":"string"},"confidence":{"type":"string","enum":["low","medium","high"]},"evidenceChunkIds":{"type":"array","items":{"type":"string"}},"signalHighlights":{"type":"array","items":{"type":"object","properties":{"signalText":{"type":"string"},"controlId":{"anyOf":[{"type":"string"},{"type":"null"}]},"presentStatus":{"type":"string","enum":["present","absent","missing","unclear"]},"signalKind":{"type":"string","enum":["risk","control"]},"evidenceChunkIds":{"type":"array","items":{"type":"string"}},"rationale":{"type":"string"}},"required":["signalText","presentStatus","signalKind","evidenceChunkIds","rationale"],"additionalProperties":false}}},"required":["themeId","themeName","familyName","riskTitle","riskStatement","confidence","evidenceChunkIds","signalHighlights"],"additionalProperties":false}},"cannotEvaluateThemes":{"type":"array","items":{"type":"object","properties":{"themeId":{"type":"string"},"themeName":{"type":"string"},"familyName":{"type":"string"},"riskTitle":{"type":"string"},"riskStatement":{"type":"string"},"confidence":{"type":"string","enum":["low","medium","high"]},"evidenceChunkIds":{"type":"array","items":{"type":"string"}},"signalHighlights":{"type":"array","items":{"type":"object","properties":{"signalText":{"type":"string"},"controlId":{"anyOf":[{"type":"string"},{"type":"null"}]},"presentStatus":{"type":"string","enum":["present","absent","missing","unclear"]},"signalKind":{"type":"string","enum":["risk","control"]},"evidenceChunkIds":{"type":"array","items":{"type":"string"}},"rationale":{"type":"string"}},"required":["signalText","presentStatus","signalKind","evidenceChunkIds","rationale"],"additionalProperties":false}}},"required":["themeId","themeName","familyName","riskTitle","riskStatement","confidence","evidenceChunkIds","signalHighlights"],"additionalProperties":false}},"controlMatrix":{"type":"array","items":{"type":"object","properties":{"riskId":{"type":"string"},"themeId":{"type":"string"},"controlId":{"type":"string"},"controlTitle":{"type":"string"},"controlDescription":{"type":"string"},"linkageType":{"type":"string","enum":["PRIMARY","SECONDARY"]},"outcomeStatus":{"type":"string","enum":["REQUIRED","SUPPORTING","NOT_APPLICABLE","DEFERRED"]},"assignmentSource":{"type":"string"},"suppressionApplied":{"type":"boolean"},"rulesFired":{"type":"array","items":{"type":"string"}},"suppressionRationale":{"anyOf":[{"type":"string"},{"type":"null"}]},"promotionRationale":{"anyOf":[{"type":"string"},{"type":"null"}]},"inputNeeded":{"type":"array","items":{"type":"string"}}},"required":["riskId","themeId","controlId","controlTitle","controlDescription","linkageType","outcomeStatus","assignmentSource","suppressionApplied","rulesFired","suppressionRationale","promotionRationale","inputNeeded"],"additionalProperties":false}},"overlays":{"type":"array","items":{"type":"object","properties":{"riskId":{"type":"string"},"themeId":{"type":"string"},"controlId":{"type":"string"},"outcomeStatus":{"type":"string","enum":["REQUIRED","SUPPORTING","NOT_APPLICABLE","DEFERRED"]},"mappingSource":{"type":"string","enum":["PRIMARY","SECONDARY_PROMOTED","SECONDARY_SUPPORTING"]},"present":{"type":"string","enum":["yes","no","unclear"]},"operating":{"type":"string","enum":["yes","no","unclear"]},"relevantToRisk":{"type":"string","enum":["yes","no","unclear"]},"controlEvidenceStatus":{"type":"string","enum":["Implemented","Partially_evidenced","Missing"]},"creditWeight":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"evidenceChunkIds":{"type":"array","items":{"type":"string"}},"findings":{"type":"string"},"actionNeeded":{"type":"string"}},"required":["riskId","themeId","controlId","outcomeStatus","mappingSource","present","operating","relevantToRisk","controlEvidenceStatus","creditWeight","evidenceChunkIds","findings","actionNeeded"],"additionalProperties":false}},"positions":{"type":"array","items":{"type":"object","properties":{"riskId":{"type":"string"},"treatmentGap":{"type":"array","items":{"type":"string"}}},"required":["riskId","treatmentGap"],"additionalProperties":false}},"lensViews":{"type":"object","properties":{"iso42001":{"type":"array","items":{"type":"object","properties":{"riskId":{"type":"string"},"clauseId":{"type":"string"},"annexKind":{"type":"string","enum":["A","B"]},"clauseTitle":{"type":"string"},"clauseText":{"type":"string"},"controlId":{"type":"string"},"controlTitle":{"type":"string"},"mappingNotes":{"anyOf":[{"type":"string"},{"type":"null"}]},"outcomeStatus":{"type":"string","enum":["REQUIRED","SUPPORTING","NOT_APPLICABLE","DEFERRED"]}},"required":["riskId","clauseId","annexKind","clauseTitle","clauseText","controlId","controlTitle","mappingNotes","outcomeStatus"],"additionalProperties":false}},"euAiAct":{"type":"array","items":{"type":"object","properties":{"riskId":{"type":"string"},"controlId":{"type":"string"},"controlTitle":{"type":"string"},"obligationId":{"type":"string"},"obligationTitle":{"type":"string"},"obligationText":{"type":"string"},"obligationNature":{"type":"string","enum":["mandatory","conditional","recommended","transparency_only"]},"satisfactionStrength":{"type":"string","enum":["full","partial","addressed"]},"tier":{"type":"string"},"tierName":{"type":"string"}},"required":["riskId","controlId","controlTitle","obligationId","obligationTitle","obligationText","obligationNature","satisfactionStrength","tier","tierName"],"additionalProperties":false}},"nistAiRmf":{"type":"array","items":{"type":"object","properties":{"riskId":{"type":"string"},"controlId":{"type":"string"},"controlTitle":{"type":"string"},"nistSubcategory":{"type":"string"},"nistFunction":{"type":"string"},"nistDescription":{"type":"string"},"outcomeStatus":{"type":"string","enum":["REQUIRED","SUPPORTING","NOT_APPLICABLE","DEFERRED"]}},"required":["riskId","controlId","controlTitle","nistSubcategory","nistFunction","nistDescription","outcomeStatus"],"additionalProperties":false}}},"required":["iso42001","euAiAct","nistAiRmf"],"additionalProperties":false},"euAiActTier":{"type":"object","properties":{"available":{"type":"boolean"},"tier":{"anyOf":[{"type":"object","properties":{"value":{"type":"string","enum":["UNACCEPTABLE","HIGH","LIMITED","MINIMAL","NA"]},"displayName":{"type":"string"},"description":{"type":"string"}},"required":["value","displayName","description"],"additionalProperties":false},{"type":"null"}]},"criteria":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"},"categoryId":{"type":"string","enum":["UNACCEPTABLE","HIGH","LIMITED"]},"criteriaStatus":{"type":"string","enum":["triggered","not_triggered","cannot_evaluate"]},"triggerFacts":{"type":"array","items":{"type":"string"}},"missingFacts":{"type":"array","items":{"type":"string"}},"mitigatingFacts":{"type":"array","items":{"type":"string"}},"rawAssessment":{"type":"object"}},"required":["id","name","description","categoryId","criteriaStatus","triggerFacts","missingFacts","mitigatingFacts","rawAssessment"],"additionalProperties":false}},"rawAssessment":{"type":"object","properties":{"unacceptableRiskResults":{"type":"object","additionalProperties":{"type":"object"}},"highRiskResults":{"type":"object","additionalProperties":{"type":"object"}},"limitedRiskResults":{"type":"object","additionalProperties":{"type":"object"}}},"required":["unacceptableRiskResults","highRiskResults","limitedRiskResults"],"additionalProperties":false},"tierRationale":{"anyOf":[{"type":"object","properties":{"text":{"type":"string"},"articlePageUrl":{"type":"string"},"methodVersion":{"type":"string"}},"required":["text","articlePageUrl","methodVersion"],"additionalProperties":false},{"type":"null"}]}},"required":["available","tier","criteria","rawAssessment","tierRationale"],"additionalProperties":false},"euAiActFacts":{"type":"object","properties":{"available":{"type":"boolean"},"facts":{"type":"array","items":{"type":"object","properties":{"factPath":{"type":"string"},"title":{"type":"string"},"value":{},"evidenceChunkIds":{"type":"array","items":{"type":"string"}},"excerpts":{"type":"array","items":{"type":"string"}}},"required":["factPath","title","value","evidenceChunkIds","excerpts"],"additionalProperties":false}}},"required":["available","facts"],"additionalProperties":false},"evidenceAppendix":{"type":"array","items":{"type":"object","properties":{"chunkId":{"type":"string"},"sourceId":{"anyOf":[{"type":"string","allOf":[{"pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$","format":"uuid"}]},{"type":"null"}]},"artifactId":{"anyOf":[{"type":"string","allOf":[{"pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$","format":"uuid"}]},{"type":"null"}]},"page":{"anyOf":[{"type":"integer"},{"type":"null"}]},"sectionPath":{"anyOf":[{"type":"string"},{"type":"null"}]},"text":{"type":"string"}},"required":["chunkId","sourceId","artifactId","page","sectionPath","text"],"additionalProperties":false}},"inputArtifacts":{"type":"array","items":{"type":"object","properties":{"artifactId":{"anyOf":[{"type":"string","allOf":[{"pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$","format":"uuid"}]},{"type":"null"}]},"artifactPid":{"type":"string","allOf":[{"pattern":"^artf_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"artifactName":{"type":"string"},"artifactKind":{"type":"string","enum":["document","source_file","notebook","structured_snapshot"]},"sourcePid":{"anyOf":[{"type":"string","allOf":[{"pattern":"^psrc_[1-9A-HJ-NP-Za-km-z]{16}$"}]},{"type":"null"}]},"sourceName":{"anyOf":[{"type":"string"},{"type":"null"}]},"sourceKind":{"anyOf":[{"type":"string","enum":["document","github_repo","databricks_workspace","sagemaker_account"],"description":"Kind of project source. `document` is an uploaded file processed by extraction; connector kinds are driven by integration workflows."},{"type":"null"}]},"filename":{"anyOf":[{"type":"string"},{"type":"null"}]},"contentType":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["artifactId","artifactPid","artifactName","artifactKind","sourcePid","sourceName","sourceKind","filename","contentType"],"additionalProperties":false}}},"required":["assessmentPid","projectName","projectOverview","quality","controlEvidence","overview","riskRegister","watchlist","clearedThemes","cannotEvaluateThemes","controlMatrix","overlays","positions","lensViews","euAiActTier","euAiActFacts","evidenceAppendix","inputArtifacts"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"402":{"description":"air/InsufficientCreditsError | air/TrialExpiredError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_InsufficientCreditsError"},{"$ref":"#/components/schemas/air_TrialExpiredError"}]}}}},"403":{"description":"air/ForbiddenError | air/BillingInactiveError | air/SeatLimitExceededError | air/FeatureNotAvailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_ForbiddenError"},{"$ref":"#/components/schemas/air_BillingInactiveError"},{"$ref":"#/components/schemas/air_SeatLimitExceededError"},{"$ref":"#/components/schemas/air_FeatureNotAvailableError"}]}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Renders the structured risk report for a completed (or partially completed) assessment. Requires project reader scope and report-history billing access. Returns 404 when the assessment is unknown, not visible, or has no renderable report.","summary":"Get assessment report"}},"/assessments/{assessmentPid}/stages":{"get":{"tags":["AIR Assessments"],"operationId":"assessments.listStages","parameters":[{"name":"assessmentPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^pasm_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"stageName":{"type":"string"},"status":{"type":"string","enum":["pending","running","completed","failed","skipped"]},"startedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"completedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"errorMessage":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["stageName","status","startedAt","completedAt","errorMessage"],"additionalProperties":false}}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"402":{"description":"air/InsufficientCreditsError | air/TrialExpiredError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_InsufficientCreditsError"},{"$ref":"#/components/schemas/air_TrialExpiredError"}]}}}},"403":{"description":"air/ForbiddenError | air/BillingInactiveError | air/SeatLimitExceededError | air/FeatureNotAvailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_ForbiddenError"},{"$ref":"#/components/schemas/air_BillingInactiveError"},{"$ref":"#/components/schemas/air_SeatLimitExceededError"},{"$ref":"#/components/schemas/air_FeatureNotAvailableError"}]}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Returns per-stage checkpoint logs (`stageName`, `status`, timestamps, `errorMessage`) for an assessment run. Requires project reader scope and report-history billing access. Returns 404 when the assessment is unknown or not visible.","summary":"List assessment stage logs"}},"/assessments/{assessmentPid}/input-artifacts":{"get":{"tags":["AIR Assessments"],"operationId":"assessments.listInputArtifacts","parameters":[{"name":"assessmentPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^pasm_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"artifactId":{"anyOf":[{"type":"string","allOf":[{"pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$","format":"uuid"}]},{"type":"null"}]},"artifactPid":{"type":"string","allOf":[{"pattern":"^artf_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"artifactName":{"type":"string"},"artifactKind":{"type":"string","enum":["document","source_file","notebook","structured_snapshot"]},"sourcePid":{"anyOf":[{"type":"string","allOf":[{"pattern":"^psrc_[1-9A-HJ-NP-Za-km-z]{16}$"}]},{"type":"null"}]},"sourceName":{"anyOf":[{"type":"string"},{"type":"null"}]},"sourceKind":{"anyOf":[{"type":"string","enum":["document","github_repo","databricks_workspace","sagemaker_account"],"description":"Kind of project source. `document` is an uploaded file processed by extraction; connector kinds are driven by integration workflows."},{"type":"null"}]},"filename":{"anyOf":[{"type":"string"},{"type":"null"}]},"contentType":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["artifactId","artifactPid","artifactName","artifactKind","sourcePid","sourceName","sourceKind","filename","contentType"],"additionalProperties":false}}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Lists artifacts that were used as inputs when the assessment report was generated. Requires project reader scope on the assessment's project. Returns 404 when the assessment or its artifacts are unknown or not visible.","summary":"List assessment input artifacts"}},"/assessments/{assessmentPid}/retry":{"post":{"tags":["AIR Assessments"],"operationId":"assessments.retry","parameters":[{"name":"assessmentPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^pasm_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"202":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"assessmentPid":{"type":"string","allOf":[{"pattern":"^pasm_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"workflowRunId":{"type":"string"},"resumedFromStage":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["assessmentPid","workflowRunId","resumedFromStage"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"402":{"description":"air/InsufficientCreditsError | air/TrialExpiredError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_InsufficientCreditsError"},{"$ref":"#/components/schemas/air_TrialExpiredError"}]}}}},"403":{"description":"air/ForbiddenError | air/BillingInactiveError | air/SeatLimitExceededError | air/FeatureNotAvailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_ForbiddenError"},{"$ref":"#/components/schemas/air_BillingInactiveError"},{"$ref":"#/components/schemas/air_SeatLimitExceededError"},{"$ref":"#/components/schemas/air_FeatureNotAvailableError"}]}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_Conflict"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Re-queues a failed assessment by dispatching a new `RiskAssessmentWorkflow` with `resume: true` from the last completed stage, locks credits again, and returns 202 with `workflowRunId` and optional `resumedFromStage`. Requires project contributor scope and a billable org. Returns 409 when status is not `failed` (including `completed`, `queued`, or `running`); returns 404 when the assessment or prior workflow input is missing.","summary":"Retry failed assessment"}},"/assessments/{assessmentPid}/terminate":{"post":{"tags":["AIR Assessments"],"operationId":"assessments.terminate","parameters":[{"name":"assessmentPid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^pasm_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"assessmentPid":{"type":"string","allOf":[{"pattern":"^pasm_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"workflowRunId":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["assessmentPid","workflowRunId"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_Conflict"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_AuthUnavailableError"},{"$ref":"#/components/schemas/air_AuthUnavailableError"}]}}}}},"description":"Marks a queued or running assessment as failed, fails in-flight stage checkpoints, interrupts the linked workflow run when active, and releases locked credits. Requires project contributor scope. Returns 409 when the assessment is not terminatable (not `queued`/`running` and no running stages). Returns 404 when the assessment is unknown or not visible.","summary":"Terminate running assessment"}},"/search":{"post":{"tags":["AIR Search"],"operationId":"search.search","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"searchKey":{"type":"string"},"entityId":{"type":"string","allOf":[{"pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$","format":"uuid"}]},"pid":{"type":"string"},"slug":{"type":"string"},"name":{"type":"string"},"entityKind":{"type":"string","enum":["org","domain","project"]},"orgId":{"anyOf":[{"type":"string","allOf":[{"pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$","format":"uuid"}]},{"type":"null"}]},"domainId":{"anyOf":[{"type":"string","allOf":[{"pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$","format":"uuid"}]},{"type":"null"}]},"orgPid":{"anyOf":[{"type":"string","allOf":[{"pattern":"^org_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Organization public id (`org_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},{"type":"null"}]},"domainPid":{"anyOf":[{"type":"string","allOf":[{"pattern":"^dom_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Domain public id (`dom_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},{"type":"null"}]},"orgSlug":{"anyOf":[{"type":"string"},{"type":"null"}]},"domainSlug":{"anyOf":[{"type":"string"},{"type":"null"}]},"score":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["searchKey","entityId","pid","slug","name","entityKind","orgId","domainId","orgPid","domainPid","orgSlug","domainSlug","score"],"additionalProperties":false}}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/air_UnauthorizedError"},{"$ref":"#/components/schemas/air_UnauthorizedError"}]}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Full-text search across organizations, domains, and projects the caller can access. Results are membership-scoped.","summary":"Search org resources","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"q":{"type":"string","description":"Free-text query matched against names in visible scopes."},"kind":{"anyOf":[{"type":"string","enum":["org","domain","project"],"description":"Restrict results to one entity kind. Omit to search orgs, domains, and projects."},{"type":"null"}]},"limit":{"anyOf":[{"type":"integer","allOf":[{"description":"Maximum number of hits to return."}]},{"type":"null"}]},"boostOrgId":{"anyOf":[{"type":"string","allOf":[{"pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$","format":"uuid"}]},{"type":"null"}]}},"required":["q"],"additionalProperties":false,"examples":[{"q":"payments","kind":"project","limit":10}]}}},"required":true}}},"/workflows/{workflowName}/start":{"post":{"tags":["AIR Workflows"],"operationId":"workflows.startWorkflow","parameters":[{"name":"workflowName","in":"path","schema":{"type":"string","allOf":[{"minLength":1}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"pid":{"type":"string","allOf":[{"pattern":"^wfr_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"status":{"anyOf":[{"type":"string","enum":["accepted"]}]}},"required":["pid","status"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_UnauthorizedError"}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Dispatches a registered workflow. `payload` is validated against the workflow registry schema. Requires a human user session actor.","summary":"Start workflow by name","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"requestedBy":{"type":"string","allOf":[{"minLength":1}]},"payload":{}},"required":["requestedBy","payload"],"additionalProperties":false}}},"required":true}}},"/workflows/{pid}":{"get":{"tags":["AIR Workflows"],"operationId":"workflows.getWorkflow","parameters":[{"name":"pid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^wfr_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"pid":{"type":"string","allOf":[{"pattern":"^wfr_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"workflowName":{"type":"string","allOf":[{"minLength":1}]},"status":{"type":"string","enum":["accepted","running","suspended","interrupted","completed","failed"]},"currentStep":{"anyOf":[{"type":"string"},{"type":"null"}]},"output":{"anyOf":[{},{"type":"null"}]},"lastErrorTag":{"anyOf":[{"type":"string"},{"type":"null"}]},"lastErrorMessage":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["pid","workflowName","status","currentStep","output","lastErrorTag","lastErrorMessage"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_UnauthorizedError"}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Returns lifecycle state for a workflow run pid. Requires a human user session; returns 404 when unknown.","summary":"Get workflow run status"}},"/workflows/{pid}/interrupt":{"post":{"tags":["AIR Workflows"],"operationId":"workflows.interruptWorkflow","parameters":[{"name":"pid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^wfr_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"pid":{"type":"string","allOf":[{"pattern":"^wfr_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"workflowName":{"type":"string","allOf":[{"minLength":1}]},"status":{"type":"string","enum":["accepted","running","suspended","interrupted","completed","failed"]},"currentStep":{"anyOf":[{"type":"string"},{"type":"null"}]},"output":{"anyOf":[{},{"type":"null"}]},"lastErrorTag":{"anyOf":[{"type":"string"},{"type":"null"}]},"lastErrorMessage":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["pid","workflowName","status","currentStep","output","lastErrorTag","lastErrorMessage"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_UnauthorizedError"}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Requests interruption of an in-flight workflow run. Requires a human user session.","summary":"Interrupt workflow run"}},"/workflows/{pid}/resume":{"post":{"tags":["AIR Workflows"],"operationId":"workflows.resumeWorkflow","parameters":[{"name":"pid","in":"path","schema":{"type":"string","allOf":[{"pattern":"^wfr_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"required":true}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"pid":{"type":"string","allOf":[{"pattern":"^wfr_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"workflowName":{"type":"string","allOf":[{"minLength":1}]},"status":{"type":"string","enum":["accepted","running","suspended","interrupted","completed","failed"]},"currentStep":{"anyOf":[{"type":"string"},{"type":"null"}]},"output":{"anyOf":[{},{"type":"null"}]},"lastErrorTag":{"anyOf":[{"type":"string"},{"type":"null"}]},"lastErrorMessage":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["pid","workflowName","status","currentStep","output","lastErrorTag","lastErrorMessage"],"additionalProperties":false}}}},"401":{"description":"air/UnauthorizedError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_UnauthorizedError"}}}},"403":{"description":"air/ForbiddenError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_ForbiddenError"}}}},"404":{"description":"NotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/effect_HttpApiError_NotFound"}}}},"422":{"description":"air/SchemaValidationError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_SchemaValidationError"}}}},"503":{"description":"air/AuthUnavailableError","content":{"application/json":{"schema":{"$ref":"#/components/schemas/air_AuthUnavailableError"}}}}},"description":"Resumes a paused or interrupted workflow run. Requires a human user session.","summary":"Resume workflow run"}}},"components":{"schemas":{"air_SchemaValidationError":{"type":"object","properties":{"_tag":{"type":"string","enum":["air/SchemaValidationError"]},"message":{"type":"string"}},"required":["_tag","message"],"additionalProperties":false},"air_ForbiddenError":{"type":"object","properties":{"_tag":{"type":"string","enum":["air/ForbiddenError"]},"message":{"type":"string"}},"required":["_tag","message"],"additionalProperties":false},"air_UnauthorizedError":{"type":"object","properties":{"_tag":{"type":"string","enum":["air/UnauthorizedError"]},"message":{"type":"string"}},"required":["_tag","message"],"additionalProperties":false},"air_AuthUnavailableError":{"type":"object","properties":{"_tag":{"type":"string","enum":["air/AuthUnavailableError"]},"message":{"type":"string"}},"required":["_tag","message"],"additionalProperties":false},"effect_HttpApiError_NotFound":{"type":"object","properties":{"_tag":{"type":"string","enum":["NotFound"]}},"required":["_tag"],"additionalProperties":false},"air_EmailAlreadyInUseError":{"type":"object","properties":{"_tag":{"type":"string","enum":["air/EmailAlreadyInUseError"]},"email":{"type":"string","allOf":[{"minLength":1}]}},"required":["_tag","email"],"additionalProperties":false},"air_RateLimitedError":{"type":"object","properties":{"_tag":{"type":"string","enum":["air/RateLimitedError"]},"message":{"type":"string"},"retryAfter":{"anyOf":[{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},{"type":"null"}]}},"required":["_tag","message"],"additionalProperties":false},"air_SeatLimitExceededError":{"type":"object","properties":{"_tag":{"type":"string","enum":["air/SeatLimitExceededError"]},"orgPid":{"type":"string","allOf":[{"pattern":"^org_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Organization public id (`org_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"active":{"type":"integer"},"limit":{"type":"integer"}},"required":["_tag","orgPid","active","limit"],"additionalProperties":false},"air_BillingInactiveError":{"type":"object","properties":{"_tag":{"type":"string","enum":["air/BillingInactiveError"]},"orgPid":{"type":"string","allOf":[{"pattern":"^org_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Organization public id (`org_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"status":{"type":"string"}},"required":["_tag","orgPid","status"],"additionalProperties":false},"air_InviteFailedError":{"type":"object","properties":{"_tag":{"type":"string","enum":["air/InviteFailedError"]},"reason":{"anyOf":[{"type":"string","enum":["already_member"]}]},"message":{"type":"string"}},"required":["_tag","reason","message"],"additionalProperties":false},"air_MembershipMutationError":{"type":"object","properties":{"_tag":{"type":"string","enum":["air/MembershipMutationError"]},"reason":{"type":"string","enum":["last_owner","service_account","not_org_member","already_member"]},"message":{"type":"string"}},"required":["_tag","reason","message"],"additionalProperties":false},"effect_HttpApiError_BadRequest":{"type":"object","properties":{"_tag":{"type":"string","enum":["BadRequest"]}},"required":["_tag"],"additionalProperties":false},"effect_HttpApiError_Conflict":{"type":"object","properties":{"_tag":{"type":"string","enum":["Conflict"]}},"required":["_tag"],"additionalProperties":false},"air_ProjectLimitExceededError":{"type":"object","properties":{"_tag":{"type":"string","enum":["air/ProjectLimitExceededError"]},"orgPid":{"type":"string","allOf":[{"pattern":"^org_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Organization public id (`org_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"active":{"type":"integer"},"limit":{"type":"integer"}},"required":["_tag","orgPid","active","limit"],"additionalProperties":false},"air_ProjectSource":{"type":"object","properties":{"id":{"type":"string","allOf":[{"pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$","format":"uuid"}]},"pid":{"type":"string","allOf":[{"pattern":"^psrc_[1-9A-HJ-NP-Za-km-z]{16}$"}]},"projectId":{"type":"string","allOf":[{"pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$","format":"uuid"}]},"kind":{"type":"string","enum":["document","github_repo","databricks_workspace","sagemaker_account"],"description":"Kind of project source. `document` is an uploaded file processed by extraction; connector kinds are driven by integration workflows."},"name":{"type":"string","allOf":[{"minLength":1}]},"config":{},"credentialsRef":{"anyOf":[{},{"type":"null"}]},"status":{"type":"string","enum":["connected","degraded","disconnected","error","processing"]},"lastSyncedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"lastError":{"anyOf":[{"type":"string"},{"type":"null"}]},"archivedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"progress":{"anyOf":[{"anyOf":[{"type":"number"},{"type":"string","enum":["NaN"]},{"type":"string","enum":["Infinity"]},{"type":"string","enum":["-Infinity"]}]},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"currentStage":{"anyOf":[{"type":"string"},{"type":"null"}]},"createdByPrincipalId":{"anyOf":[{"type":"string","allOf":[{"pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$","format":"uuid"}]},{"type":"null"}]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","pid","projectId","kind","name","config","credentialsRef","status","lastSyncedAt","lastError","archivedAt","progress","currentStage","createdByPrincipalId","createdAt","updatedAt"],"additionalProperties":false},"air_FeatureNotAvailableError":{"type":"object","properties":{"_tag":{"type":"string","enum":["air/FeatureNotAvailableError"]},"orgPid":{"type":"string","allOf":[{"pattern":"^org_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Organization public id (`org_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"feature":{"type":"string","enum":["pdf_export","report_history","multi_framework"]},"plan":{"type":"string","enum":["trial","starter","team","enterprise","internal"]}},"required":["_tag","orgPid","feature","plan"],"additionalProperties":false},"air_InsufficientCreditsError":{"type":"object","properties":{"_tag":{"type":"string","enum":["air/InsufficientCreditsError"]},"orgPid":{"type":"string","allOf":[{"pattern":"^org_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Organization public id (`org_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]},"available":{"type":"integer"},"required":{"type":"integer"}},"required":["_tag","orgPid","available","required"],"additionalProperties":false},"air_TrialExpiredError":{"type":"object","properties":{"_tag":{"type":"string","enum":["air/TrialExpiredError"]},"orgPid":{"type":"string","allOf":[{"pattern":"^org_[1-9A-HJ-NP-Za-km-z]{16}$","description":"Organization public id (`org_` prefix). Opaque public identifier: a type prefix, underscore, and 16-character Crockford base32 suffix. Treat as an opaque string — do not parse or construct."}]}},"required":["_tag","orgPid"],"additionalProperties":false}},"securitySchemes":{"bearer":{"type":"http","scheme":"Bearer"}}},"security":[],"tags":[{"name":"AIR System","description":"Unauthenticated health and metadata endpoints for load balancers and integrators."},{"name":"AIR Users","description":"AIR user management endpoints. Requires a human user session actor."},{"name":"AIR Account","description":"Self-service account management for the signed-in user: update display name, change or set a password, and change email. Changing email is a confirmed two-step flow — request a one-time code (sent to the *current* email to prove mailbox control, which works for OTP-only users) then verify it; the change cascades to credentials and invalidates existing sessions (forces re-login). OTP-only invited users may set a first password without supplying a current password."},{"name":"AIR Memberships","description":"List members of the current org and invite new ones by email. Invites pre-create user + principal records when needed; the invitee logs in via email OTP — no password setup is required because the platform is invite-only. Owner/admin of a scope (or any ancestor up to the org root) may add existing members to sub-scopes, change roles, remove members, re-send invites, and change member emails."},{"name":"AIR Service Accounts","description":"Machine credentials for a domain. Domain owners/admins create service accounts and mint bearer API keys for them. Active keys can be copied again via `revealKey`. Revoked keys fail authentication immediately."},{"name":"AIR Orgs","description":"Organization lookups by slug."},{"name":"AIR Portfolio","description":"Read-only portfolio dashboards aggregating project and assessment posture for an org or domain."},{"name":"AIR Domains","description":"List domains for the current organization and projects within a domain."},{"name":"AIR Projects","description":"Per-project document uploads via presigned object storage (`upload-init` → PUT to returned URL → `upload-complete`) so bytes never cross the API process."},{"name":"AIR Assessments","description":"Create, list, inspect, and control risk assessments on a project. Starting or retrying an assessment dispatches `RiskAssessmentWorkflow` and consumes org credits."},{"name":"AIR Search","description":"Search AIR organizations, domains, and projects by name."},{"name":"AIR Workflows","description":"AIR workflow management endpoints. Start any registered workflow by name. Requires a human user session actor."}],"servers":[{"url":"https://api.air.thalus.ai","description":"Deployed API server"}]}