{"components":{"schemas":{"api_handler.AuthZENAction":{"properties":{"name":{"example":"doc:read","type":"string"},"properties":{"additionalProperties":{},"type":"object"}},"type":"object"},"api_handler.AuthZENActionSearchResponse":{"properties":{"results":{"items":{"$ref":"#/components/schemas/api_handler.AuthZENAction"},"type":"array","uniqueItems":false}},"type":"object"},"api_handler.AuthZENConfiguration":{"properties":{"access_evaluation_endpoint":{"type":"string"},"access_evaluations_endpoint":{"type":"string"},"policy_decision_point":{"type":"string"},"search_action_endpoint":{"type":"string"},"search_resource_endpoint":{"type":"string"}},"type":"object"},"api_handler.AuthZENDecision":{"properties":{"context":{"additionalProperties":{},"description":"Context is, for a token subject, the verified principal (principal:\nsub, act, aud, scope, client_id, org_id), for the caller's own scope\ncheck.","type":"object"},"decision":{"type":"boolean"}},"type":"object"},"api_handler.AuthZENEvaluation":{"properties":{"action":{"$ref":"#/components/schemas/api_handler.AuthZENAction"},"context":{"additionalProperties":{},"description":"Context carries Pontive's extras: actor, an agent (agt_) acting for the\nuser subject, which can only narrow the decision.","type":"object"},"resource":{"$ref":"#/components/schemas/api_handler.AuthZENResource"},"subject":{"$ref":"#/components/schemas/api_handler.AuthZENSubject"}},"type":"object"},"api_handler.AuthZENEvaluationsRequest":{"properties":{"action":{"$ref":"#/components/schemas/api_handler.AuthZENAction"},"context":{"additionalProperties":{},"description":"Context carries Pontive's extras: actor, an agent (agt_) acting for the\nuser subject, which can only narrow the decision.","type":"object"},"evaluations":{"items":{"$ref":"#/components/schemas/api_handler.AuthZENEvaluation"},"type":"array","uniqueItems":false},"options":{"$ref":"#/components/schemas/api_handler.AuthZENOptions"},"resource":{"$ref":"#/components/schemas/api_handler.AuthZENResource"},"subject":{"$ref":"#/components/schemas/api_handler.AuthZENSubject"}},"type":"object"},"api_handler.AuthZENEvaluationsResponse":{"properties":{"evaluations":{"items":{"$ref":"#/components/schemas/api_handler.AuthZENDecision"},"type":"array","uniqueItems":false}},"type":"object"},"api_handler.AuthZENOptions":{"properties":{"evaluations_semantic":{"description":"EvaluationsSemantic is execute_all (the default), deny_on_first_deny or\npermit_on_first_permit.","enum":["execute_all","deny_on_first_deny","permit_on_first_permit"],"type":"string"}},"type":"object"},"api_handler.AuthZENPage":{"properties":{"limit":{"type":"integer"},"properties":{"additionalProperties":{},"type":"object"},"token":{"type":"string"}},"type":"object"},"api_handler.AuthZENPageResult":{"properties":{"count":{"type":"integer"},"next_token":{"type":"string"},"total":{"type":"integer"}},"type":"object"},"api_handler.AuthZENResource":{"properties":{"id":{"example":"res_1a2b3c4d5e6f","type":"string"},"properties":{"additionalProperties":{},"type":"object"},"type":{"example":"doc","type":"string"}},"type":"object"},"api_handler.AuthZENResourceSearchResponse":{"properties":{"page":{"$ref":"#/components/schemas/api_handler.AuthZENPageResult"},"results":{"items":{"$ref":"#/components/schemas/api_handler.AuthZENResource"},"type":"array","uniqueItems":false}},"type":"object"},"api_handler.AuthZENSearchRequest":{"properties":{"action":{"$ref":"#/components/schemas/api_handler.AuthZENAction"},"context":{"additionalProperties":{},"description":"Context carries Pontive's extras: actor; for a resource search\norganization_id, parent_id, direct_only and include_ancestors; for an\naction search actions, the action names to ask about (required for the\ncaller's own token, at most 32).","type":"object"},"page":{"$ref":"#/components/schemas/api_handler.AuthZENPage"},"resource":{"$ref":"#/components/schemas/api_handler.AuthZENResource"},"subject":{"$ref":"#/components/schemas/api_handler.AuthZENSubject"}},"type":"object"},"api_handler.AuthZENSubject":{"properties":{"id":{"example":"usr_1a2b3c4d5e6f","type":"string"},"properties":{"additionalProperties":{},"description":"Properties are accepted and not read.","type":"object"},"type":{"description":"Type is user, service_account, agent, or token (an access token of\nthis instance as the id).","enum":["user","service_account","agent","token"],"example":"user","type":"string"}},"type":"object"},"api_handler_billing.Object":{"properties":{"id":{"description":"ID is its prefixed id.","example":"cust_1a2b3c4d","type":"string"},"object":{"description":"Object names the kind: customer, invoice, contract, …","example":"customer","type":"string"}},"type":"object"},"apierr.ErrBody":{"properties":{"code":{"description":"Code is the spec's machine-readable code for this error, in snake\ncase: a domain code such as seat_limit_reached where the refusal has\none, otherwise a generic one such as permission_denied, not_found,\nconflict, invalid_request or service_unavailable.","example":"permission_denied","type":"string"},"details":{"description":"Details are per-field findings, present only on a refusal that has\nthem, e.g. a 422 invalid_theme names each invalid value by its path,\na 422 package_invalid each problem, and a 409 capability_in_use each\ncount by its name.","items":{"$ref":"#/components/schemas/apierr.ErrDetail"},"type":"array","uniqueItems":false},"doc_url":{"description":"DocURL links to documentation about this error, when available.","type":"string"},"message":{"description":"Message is a human-readable description of what went wrong.","example":"You do not have permission to do this.","type":"string"},"object":{"description":"Object is the discriminator; always \"error\".","example":"error","type":"string"},"param":{"description":"Param names the request parameter this error refers to, when applicable.","example":"email","type":"string"},"type":{"description":"Type is the error's category, set by its HTTP status: one of\nvalidation_error, authentication_error, authorization_error,\nnot_found, conflict_error, rate_limit_error, internal_error.","enum":["validation_error","authentication_error","authorization_error","not_found","conflict_error","rate_limit_error","internal_error"],"example":"authorization_error","type":"string"}},"type":"object"},"apierr.ErrDetail":{"properties":{"field":{"description":"Field is where the finding is: for a theme, its dotted path.","example":"global.light.sem-color-primary","type":"string"},"message":{"description":"Message is what is wrong there.","example":"must be a color","type":"string"}},"type":"object"},"apierr.ErrResponse":{"properties":{"error":{"$ref":"#/components/schemas/apierr.ErrBody"}},"type":"object"}},"securitySchemes":{"BearerAuth":{"description":"Access token as \"Bearer <jwt>\"","in":"header","name":"Authorization","type":"apiKey"},"X-Pontive-Instance-ID":{"description":"Instance ID for the request","in":"header","name":"x-pontive-instance-id","type":"apiKey"}}},"info":{"title":"Authorization API","version":"1.0"},"openapi":"3.2.0","paths":{"/.well-known/authzen-configuration":{"get":{"description":"The decision point's metadata (OpenID AuthZEN Authorization API 1.0, §9): its identifier and the endpoints it serves. Public.","operationId":"GetAuthZENConfiguration","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/api_handler.AuthZENConfiguration"}}},"description":"OK"}},"summary":"AuthZEN discovery","tags":["AuthZEN"],"x-pontive-document":"authz"}},"/access/v1/evaluation":{"post":{"description":"AuthZEN Access Evaluation (OpenID AuthZEN Authorization API 1.0, §6): may the subject do the action on the resource. The subject is a user (usr_), a service account (svc_), an agent (agt_), or a token — an access token of this instance as subject.id: a token acting for a user through an agent is answered for the (user, agent) pair, within its organization and while its delegation is live, and the decision's context echoes the verified principal so the caller applies its own scope check. context.actor names an agent acting for a user subject: only what both may do is allowed. A token that does not verify is refused 400 invalid_token. Inherited roles are resolved through the resource graph. Needs sys:authz:check. A check on a custom resource type bills as one authorization check. Callers: a management credential asks about any subject; any other access token of the instance only about itself, subject {\"type\": \"token\"} or its own subject by id, and is refused 403 for any other (D24, D48).","operationId":"EvaluateAccess","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/api_handler.AuthZENEvaluation","description":"subject, action, resource, context","summary":"request"}}},"description":"subject, action, resource, context","required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/api_handler.AuthZENDecision"}}},"description":"OK"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"invalid_token, actor_invalid, invalid_request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Unauthorized"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Forbidden"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Internal Server Error"}},"summary":"Evaluate access","tags":["AuthZEN"],"x-pontive-document":"authz"}},"/access/v1/evaluations":{"post":{"description":"AuthZEN Access Evaluations (OpenID AuthZEN Authorization API 1.0, §7): up to 100 questions, answered in the order asked. The request's own subject, action, resource and context are the defaults each evaluation's own keys override; with no evaluations it is a single evaluation, answered as one. options.evaluations_semantic is execute_all (the default), deny_on_first_deny (stop at the first denial) or permit_on_first_permit (stop at the first permit): the answer then ends with the evaluation that stopped it. Subjects, tokens and context.actor are named as in an evaluation. Needs sys:authz:check. Each check on a custom resource type bills as one authorization check. Callers: a management credential asks about any subject; any other access token of the instance only about itself, subject {\"type\": \"token\"} or its own subject by id, and is refused 403 for any other (D24, D48).","operationId":"EvaluateAccessBatch","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/api_handler.AuthZENEvaluationsRequest","description":"defaults, evaluations and options","summary":"request"}}},"description":"defaults, evaluations and options","required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/api_handler.AuthZENEvaluationsResponse"}}},"description":"OK"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"invalid_token, actor_invalid, invalid_request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Unauthorized"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Forbidden"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Internal Server Error"}},"summary":"Evaluate access, many questions","tags":["AuthZEN"],"x-pontive-document":"authz"}},"/access/v1/search/action":{"post":{"description":"AuthZEN Action Search (OpenID AuthZEN Authorization API 1.0, §8.6): the actions the subject may take on the resource. For a subject named by id or by an access token, identity-svc checks every permission of the resource's type on the object, as an evaluation is checked, and answers those held in key order; context.actions narrows the answer to the ones asked about, and context.actor names an agent acting for a user subject. For the caller itself — subject {\"type\": \"token\"} with no id — context.actions names the catalog permissions (sys:<resource>:<action>, at most 32) to ask about on the target instance (resource {\"type\": \"root\"}): what a client hides or disables by, never the decision. Needs sys:authz:check; the caller's own question needs nothing. Callers: a management credential asks about any subject; any other access token of the instance only about itself, subject {\"type\": \"token\"} or its own subject by id, and is refused 403 for any other (D24, D48).","operationId":"SearchActions","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/api_handler.AuthZENSearchRequest","description":"subject, resource, context","summary":"request"}}},"description":"subject, resource, context","required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/api_handler.AuthZENActionSearchResponse"}}},"description":"OK"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"invalid_token, actor_invalid, invalid_request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Unauthorized"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Forbidden"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Internal Server Error"}},"summary":"Search actions","tags":["AuthZEN"],"x-pontive-document":"authz"}},"/access/v1/search/resource":{"post":{"description":"AuthZEN Resource Search (OpenID AuthZEN Authorization API 1.0, §8.5): the resources of resource.type the subject may do action.name on, directly or by inheritance, each with its name, organization, parent and the roles held as properties. Subjects, tokens and context.actor are named as in an evaluation; a delegated subject lists what the (user, agent) pair both reach. context takes Pontive's filters: organization_id, parent_id, direct_only, include_ancestors. Pages by page.token and page.limit (1 to 100); page.next_token is \"\" on the last page. Needs sys:authz:check for a token or an actor; a subject alone needs what reading that principal does (sys:user:read, sys:sa:read or sys:agent:read). Bills as one authorization check. Callers: a management credential asks about any subject; any other access token of the instance only about itself, subject {\"type\": \"token\"} or its own subject by id, and is refused 403 for any other (D24, D48).","operationId":"SearchResources","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/api_handler.AuthZENSearchRequest","description":"subject, action, resource {type}, context, page","summary":"request"}}},"description":"subject, action, resource {type}, context, page","required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/api_handler.AuthZENResourceSearchResponse"}}},"description":"OK"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"invalid_token, delegated_permission_required, actor_invalid, invalid_request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Unauthorized"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Forbidden"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"The resource type does not exist"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Internal Server Error"}},"summary":"Search resources","tags":["AuthZEN"],"x-pontive-document":"authz"}},"/v1/entitlements/check":{"post":{"description":"billing.entitlement.v1.EntitlementService/CheckEntitlement (39-entitlements-and-controls.md, API Surface; Check, list, consume). No side effects. A denial is a 200 with allowed false and a reason (not_entitled, allowance_exhausted, balance_exhausted, access_restricted), never an error (Error Handling). value is the feature's value: true, a decimal string, or a metered feature's allowance; when the Customer is not entitled to it, false for a boolean feature and null otherwise. limit is a metered feature's state, null for other types. Only external subjects resolve until Phase 4. The RPC writes nothing and takes no idempotency key, so X-Idempotency-Key is not read.","operationId":"CheckEntitlement","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/api_handler_billing.Object"}}},"description":"An entitlement_check object: { allowed, value, reason, limit }"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Unauthorized"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"module_required: the instance's billing capability is off"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Not Found"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Unprocessable Entity"}},"security":[{"BearerAuth":[]}],"summary":"POST /v1/entitlements/check","tags":["Billing entitlements"],"x-pontive-capability":"billing","x-pontive-document":"authz"}},"/v1/entitlements/consume":{"post":{"description":"billing.entitlement.v1.EntitlementService/ConsumeEntitlement (39-entitlements-and-controls.md, API Surface; Check, list, consume). Resolves, decides as a check would and, when allowed, records the usage event, in one transaction. Idempotent on transaction_id, not on X-Idempotency-Key, which is not read: a retry of an allowed consume answers the first decision with replayed true and consumes nothing again; a denied consume records nothing and is decided again on retry (billing-svc docs/questions.md, P9). A denial is a 200 with allowed false and a reason, never an error. properties is a JSON object, kept as sent. The usage event is checked against its event type's schema as ingest checks it: with validation warn, an allowed consume lists warnings, each { code, property, expected }; with reject, one that does not fit is refused with 422 schema_mismatch and records nothing: the error's details list each violation as { field: its property, message: its code and what was expected } (billing-svc docs/questions.md, P99, P111).","operationId":"ConsumeEntitlement","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/api_handler_billing.Object"}}},"description":"An entitlement_consumption object: { allowed, value, reason, limit, event_id, replayed, warnings }"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Unauthorized"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"module_required: the instance's billing capability is off"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Not Found"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Unprocessable Entity"}},"security":[{"BearerAuth":[]}],"summary":"POST /v1/entitlements/consume","tags":["Billing entitlements"],"x-pontive-capability":"billing","x-pontive-document":"authz"}},"/v1/me/entitlements/check":{"post":{"description":"billing.entitlement.v1.MeEntitlementService/CheckMyEntitlement (39-entitlements-and-controls.md, API Surface). The body is { feature, quantity? }. Under pontive:billing:read (41-embedded-organization-management.md, section 5.1). An instance user's token must be issued for the instance's me audience, https://{auth domain}/me/, with pontive:billing:read (D31, D48). The RPC writes nothing and takes no idempotency key, so X-Idempotency-Key is not read.","operationId":"CheckMyEntitlement","parameters":[{"description":"user or organization: the subject whose Customer to act for; with subject_id","in":"query","name":"subject_type","schema":{"type":"string"}},{"description":"the subject's id, usr_ or org_; with subject_type","in":"query","name":"subject_id","schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/api_handler_billing.Object"}}},"description":"An entitlement_check object: allowed, value, reason and limit"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Unauthorized"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"module_required: the instance's billing capability is off"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Conflict"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apierr.ErrResponse"}}},"description":"Unprocessable Entity"}},"security":[{"BearerAuth":[]}],"summary":"POST /v1/me/entitlements/check","tags":["Billing for the end customer"],"x-pontive-capability":"billing","x-pontive-document":"authz"}}},"security":[{"X-Pontive-Instance-ID":[]},{"BearerAuth":[]}],"servers":[{"url":"https://authz.{region}.pontive.com","variables":{"region":{"default":"us","description":"The region your instance lives in","enum":["us","eu","au"]}}}],"tags":[{"name":"AuthZEN","x-displayName":"AuthZEN"},{"name":"Billing entitlements","x-displayName":"Billing entitlements"},{"name":"Billing for the end customer","x-displayName":"Billing for the end customer"}]}