# Generated public contract; edit the source and localization catalog.
openapi: 3.1.0
jsonSchemaDialect: https://json-schema.org/draft/2020-12/schema
info:
  title: OrbitSpace Identity and access API
  version: 1.0.0
  description: Public v1 application contract for identity and access. Protocol lifecycle and capability availability are documented in the integration guides.
servers:
  - url: https://api.orbitspace.dev
security:
  - bearerAuth: []
paths:
  /api/v1/access-policies:evaluate:
    post:
      tags:
        - AccessPolicyService
      operationId: AccessPolicyService_EvaluateEffectivePermissions
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/EvaluateEffectivePermissionsRequest"
        required: true
        description: Request body for evaluate effective permissions.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/EffectivePermissions"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Evaluate effective permissions
      description: Evaluate effective permissions. Supply the fields defined in the request schema.
  /api/v1/account:
    get:
      tags:
        - AuthService
      operationId: AuthService_GetAccount
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Account"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Get account
      description: Get account.
    put:
      tags:
        - AuthService
      operationId: AuthService_UpdateAccount
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/UpdateAccountRequest"
        required: true
        description: Request body for update account.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Account"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Update account
      description: Update account. Supply the fields defined in the request schema.
  /api/v1/account/team-invitations:accept:
    post:
      tags:
        - IdentityService
      operationId: IdentityService_AcceptTeamInvitation
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/AcceptTeamInvitationRequest"
        required: true
        description: Request body for accept team invitation.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/TenantAccess"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Accept team invitation
      description: Accept team invitation. Supply the fields defined in the request schema.
  /api/v1/account:change-password:
    post:
      tags:
        - AuthService
      operationId: AuthService_ChangePassword
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/ChangePasswordRequest"
        required: true
        description: Request body for change password.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ChangePasswordResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Change password
      description: Change password. Supply the fields defined in the request schema.
  /api/v1/api-token-policy:
    get:
      tags:
        - IdentityService
      operationId: IdentityService_GetAPITokenPolicy
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/APITokenPolicy"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Get API token policy
      description: Get API token policy.
  /api/v1/api-tokens:
    get:
      tags:
        - IdentityService
      operationId: IdentityService_ListAPITokens
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ListAPITokensResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: List API tokens
      description: List API tokens.
    post:
      tags:
        - IdentityService
      operationId: IdentityService_CreateAPIToken
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/CreateAPITokenRequest"
        required: true
        description: Request body for create api token.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/CreateAPITokenResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Create API token
      description: Create API token. Supply the fields defined in the request schema.
  /api/v1/api-tokens/{id}:revoke:
    post:
      tags:
        - IdentityService
      operationId: IdentityService_RevokeAPIToken
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
          description: Identifier of the resource addressed by this schema or URL.
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/RevokeAPITokenRequest"
        required: true
        description: Request body for revoke api token.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/APIToken"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Revoke API token
      description: Revoke API token. Supply the fields defined in the request schema.
  /api/v1/audit-events:
    get:
      tags:
        - AuditService
      operationId: AuditService_ListAuditEvents
      parameters:
        - name: identity_id
          in: query
          schema:
            type: string
          description: Identity id.
        - name: action_prefix
          in: query
          schema:
            type: string
          description: Action prefix.
        - name: resource_type
          in: query
          schema:
            type: string
          description: Resource type.
        - name: resource_id
          in: query
          schema:
            type: string
          description: Resource id.
        - name: outcome
          in: query
          schema:
            type: string
          description: Outcome.
        - name: created_at_from
          in: query
          schema:
            type: string
            format: date-time
          description: Created at from.
        - name: created_at_to
          in: query
          schema:
            type: string
            format: date-time
          description: Created at to.
        - name: page_size
          in: query
          schema:
            type: integer
            format: int32
          description: Requested page size, subject to the endpoint limits.
        - name: page_token
          in: query
          schema:
            type: string
          description: Opaque pagination token returned by the previous page. Do not construct or modify it.
        - name: request_id
          in: query
          schema:
            type: string
          description: Request id.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ListAuditEventsResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: List audit events
      description: List audit events. Use the declared pagination parameters to continue through results.
  /api/v1/audit-events:export:
    get:
      tags:
        - AuditService
      operationId: AuditService_ExportAuditEvents
      parameters:
        - name: identity_id
          in: query
          schema:
            type: string
          description: Identity id.
        - name: action_prefix
          in: query
          schema:
            type: string
          description: Action prefix.
        - name: resource_type
          in: query
          schema:
            type: string
          description: Resource type.
        - name: resource_id
          in: query
          schema:
            type: string
          description: Resource id.
        - name: outcome
          in: query
          schema:
            type: string
          description: Outcome.
        - name: created_at_from
          in: query
          schema:
            type: string
            format: date-time
          description: Created at from.
        - name: created_at_to
          in: query
          schema:
            type: string
            format: date-time
          description: Created at to.
        - name: request_id
          in: query
          schema:
            type: string
          description: Request id.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ExportAuditEventsResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Export audit events
      description: Export audit events.
  /api/v1/auth/login:
    post:
      tags:
        - AuthService
      security: []
      operationId: AuthService_Login
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/LoginRequest"
        required: true
        description: Request body for log in.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/LoginResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Log in
      description: Log in. Supply the fields defined in the request schema.
  /api/v1/auth/logout:
    post:
      tags:
        - AuthService
      security: []
      operationId: AuthService_Logout
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/LogoutRequest"
        required: true
        description: Request body for log out.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/LogoutResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Log out
      description: Log out. Supply the fields defined in the request schema.
  /api/v1/auth/refresh:
    post:
      tags:
        - AuthService
      security: []
      operationId: AuthService_RefreshToken
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/RefreshTokenRequest"
        required: true
        description: Request body for refresh token.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/LoginResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Refresh token
      description: Refresh token. Supply the fields defined in the request schema.
  /api/v1/auth/sessions:
    get:
      tags:
        - AuthService
      operationId: AuthService_ListSessions
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ListSessionsResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: List sessions
      description: List sessions.
  /api/v1/auth/sessions/{id}:revoke:
    post:
      tags:
        - AuthService
      operationId: AuthService_RevokeSession
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
          description: Identifier of the resource addressed by this schema or URL.
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/RevokeSessionRequest"
        required: true
        description: Request body for revoke session.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/AuthSession"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Revoke session
      description: Revoke session. Supply the fields defined in the request schema.
  /api/v1/auth/sessions:revoke-others:
    post:
      tags:
        - AuthService
      operationId: AuthService_RevokeOtherSessions
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/RevokeOtherSessionsRequest"
        required: true
        description: Request body for revoke other sessions.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/RevokeOtherSessionsResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Revoke other sessions
      description: Revoke other sessions. Supply the fields defined in the request schema.
  /api/v1/custom-roles:
    get:
      tags:
        - AccessPolicyService
      operationId: AccessPolicyService_ListCustomRoles
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ListCustomRolesResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: List custom roles
      description: List custom roles.
    post:
      tags:
        - AccessPolicyService
      operationId: AccessPolicyService_CreateCustomRole
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/CreateCustomRoleRequest"
        required: true
        description: Request body for create custom role.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/CustomRole"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Create custom role
      description: Create custom role. Supply the fields defined in the request schema.
  /api/v1/custom-roles/{id}:
    get:
      tags:
        - AccessPolicyService
      operationId: AccessPolicyService_GetCustomRole
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
          description: Identifier of the resource addressed by this schema or URL.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/CustomRole"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Get custom role
      description: Get custom role.
    put:
      tags:
        - AccessPolicyService
      operationId: AccessPolicyService_UpdateCustomRole
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
          description: Identifier of the resource addressed by this schema or URL.
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/UpdateCustomRoleRequest"
        required: true
        description: Request body for update custom role.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/CustomRole"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Update custom role
      description: Update custom role. Supply the fields defined in the request schema.
  /api/v1/identities:
    post:
      tags:
        - IdentityService
      operationId: IdentityService_ProvisionIdentity
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/ProvisionIdentityRequest"
        required: true
        description: Request body for provision identity.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/IdentityAccess"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Provision identity
      description: Provision identity. Supply the fields defined in the request schema.
  /api/v1/identity:
    get:
      tags:
        - IdentityService
      operationId: IdentityService_GetCurrentIdentity
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/IdentityAccess"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Get current identity
      description: Get current identity.
  /api/v1/identity-providers:
    get:
      tags:
        - IdentityProviderService
      operationId: IdentityProviderService_ListIdentityProviders
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ListIdentityProvidersResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: List identity providers
      description: List identity providers.
    post:
      tags:
        - IdentityProviderService
      operationId: IdentityProviderService_CreateIdentityProvider
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/CreateIdentityProviderRequest"
        required: true
        description: Request body for create identity provider.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/IdentityProvider"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Create identity provider
      description: Create identity provider. Supply the fields defined in the request schema.
  /api/v1/identity-providers/{id}:
    get:
      tags:
        - IdentityProviderService
      operationId: IdentityProviderService_GetIdentityProvider
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
          description: Identifier of the resource addressed by this schema or URL.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/IdentityProvider"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Get identity provider
      description: Get identity provider.
    put:
      tags:
        - IdentityProviderService
      operationId: IdentityProviderService_UpdateIdentityProvider
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
          description: Identifier of the resource addressed by this schema or URL.
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/UpdateIdentityProviderRequest"
        required: true
        description: Request body for update identity provider.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/IdentityProvider"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Update identity provider
      description: Update identity provider. Supply the fields defined in the request schema.
  /api/v1/identity-providers/{id}:rotate-scim-token:
    post:
      tags:
        - IdentityProviderService
      operationId: IdentityProviderService_RotateIdentityProviderSCIMToken
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
          description: Identifier of the resource addressed by this schema or URL.
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/RotateIdentityProviderSCIMTokenRequest"
        required: true
        description: Request body for rotate identity provider scim token.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/RotateIdentityProviderSCIMTokenResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Rotate identity provider SCIM token
      description: Rotate identity provider SCIM token. Supply the fields defined in the request schema.
  /api/v1/identity-providers/{provider_id}/group-mappings:
    get:
      tags:
        - IdentityProviderService
      operationId: IdentityProviderService_ListIdentityProviderGroupMappings
      parameters:
        - name: provider_id
          in: path
          required: true
          schema:
            type: string
          description: Provider id.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ListIdentityProviderGroupMappingsResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: List identity provider group mappings
      description: List identity provider group mappings.
    post:
      tags:
        - IdentityProviderService
      operationId: IdentityProviderService_UpsertIdentityProviderGroupMapping
      parameters:
        - name: provider_id
          in: path
          required: true
          schema:
            type: string
          description: Provider id.
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/UpsertIdentityProviderGroupMappingRequest"
        required: true
        description: Request body for create or update identity provider group mapping.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/IdentityProviderGroupMapping"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Create or update identity provider group mapping
      description: Create or update identity provider group mapping. Supply the fields defined in the request schema.
  /api/v1/identity-providers/{provider_id}/group-mappings/{mapping_id}:
    delete:
      tags:
        - IdentityProviderService
      operationId: IdentityProviderService_DeleteIdentityProviderGroupMapping
      parameters:
        - name: provider_id
          in: path
          required: true
          schema:
            type: string
          description: Provider id.
        - name: mapping_id
          in: path
          required: true
          schema:
            type: string
          description: Mapping id.
      responses:
        "200":
          description: Successful response.
          content: {}
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Delete identity provider group mapping
      description: Delete identity provider group mapping.
  /api/v1/identity/members:
    get:
      tags:
        - IdentityService
      operationId: IdentityService_ListTenantMembers
      parameters:
        - name: page_size
          in: query
          schema:
            type: integer
            format: int32
          description: Requested page size, subject to the endpoint limits.
        - name: page_token
          in: query
          schema:
            type: string
          description: Opaque pagination token returned by the previous page. Do not construct or modify it.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ListTenantMembersResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: List tenant members
      description: List tenant members. Use the declared pagination parameters to continue through results.
  /api/v1/identity/members/{membership_id}:
    delete:
      tags:
        - IdentityService
      operationId: IdentityService_RemoveTenantMember
      parameters:
        - name: membership_id
          in: path
          required: true
          schema:
            type: string
          description: Membership id.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/TeamOperationResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Remove tenant member
      description: Remove tenant member.
    patch:
      tags:
        - IdentityService
      operationId: IdentityService_UpdateTenantMembership
      parameters:
        - name: membership_id
          in: path
          required: true
          schema:
            type: string
          description: Membership id.
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/UpdateTenantMembershipRequest"
        required: true
        description: Request body for update tenant membership.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/TenantMember"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Update tenant membership
      description: Update tenant membership. Supply the fields defined in the request schema.
  /api/v1/identity/preferences:
    patch:
      tags:
        - IdentityService
      operationId: IdentityService_UpdateMyPreferences
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/UpdateMyPreferencesRequest"
        required: true
        description: Request body for update my preferences.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Identity"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Update my preferences
      description: Update my preferences. Supply the fields defined in the request schema.
  /api/v1/identity/tenant-preferences:
    patch:
      tags:
        - IdentityService
      operationId: IdentityService_UpdateTenantPreferences
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/UpdateTenantPreferencesRequest"
        required: true
        description: Request body for update tenant preferences.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/TenantAccess"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Update tenant preferences
      description: Update tenant preferences. Supply the fields defined in the request schema.
  /api/v1/identity/tenants:
    get:
      tags:
        - IdentityService
      operationId: IdentityService_ListMyTenants
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ListMyTenantsResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: List my tenants
      description: List my tenants.
  /api/v1/policy-bindings:
    get:
      tags:
        - AccessPolicyService
      operationId: AccessPolicyService_ListPolicyBindings
      parameters:
        - name: scope_id
          in: query
          schema:
            type: string
          description: Scope id.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ListPolicyBindingsResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: List policy bindings
      description: List policy bindings.
    post:
      tags:
        - AccessPolicyService
      operationId: AccessPolicyService_CreatePolicyBinding
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/CreatePolicyBindingRequest"
        required: true
        description: Request body for create policy binding.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/PolicyBinding"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Create policy binding
      description: Create policy binding. Supply the fields defined in the request schema.
  /api/v1/policy-bindings/{id}:
    delete:
      tags:
        - AccessPolicyService
      operationId: AccessPolicyService_DeletePolicyBinding
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
          description: Identifier of the resource addressed by this schema or URL.
      responses:
        "200":
          description: Successful response.
          content: {}
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Delete policy binding
      description: Delete policy binding.
  /api/v1/policy-permission-catalog:
    get:
      tags:
        - AccessPolicyService
      operationId: AccessPolicyService_GetPolicyPermissionCatalog
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/PolicyPermissionCatalog"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Get policy permission catalog
      description: Get policy permission catalog.
  /api/v1/policy-scopes:
    get:
      tags:
        - AccessPolicyService
      operationId: AccessPolicyService_ListPolicyScopes
      parameters:
        - name: kind
          in: query
          schema:
            enum:
              - POLICY_SCOPE_KIND_UNSPECIFIED
              - POLICY_SCOPE_KIND_ORGANIZATION
              - POLICY_SCOPE_KIND_TEAM
              - POLICY_SCOPE_KIND_PROJECT
            type: string
            format: enum
            description: Kind.
            x-enum-descriptions:
              POLICY_SCOPE_KIND_UNSPECIFIED: unspecified
              POLICY_SCOPE_KIND_ORGANIZATION: organization
              POLICY_SCOPE_KIND_TEAM: team
              POLICY_SCOPE_KIND_PROJECT: project
          description: Kind.
        - name: parent_id
          in: query
          schema:
            type: string
          description: Parent id.
        - name: status
          in: query
          schema:
            enum:
              - POLICY_SCOPE_STATUS_UNSPECIFIED
              - POLICY_SCOPE_STATUS_ACTIVE
              - POLICY_SCOPE_STATUS_ARCHIVED
            type: string
            format: enum
            description: Status.
            x-enum-descriptions:
              POLICY_SCOPE_STATUS_UNSPECIFIED: unspecified
              POLICY_SCOPE_STATUS_ACTIVE: active
              POLICY_SCOPE_STATUS_ARCHIVED: archived
          description: Status.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ListPolicyScopesResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: List policy scopes
      description: List policy scopes.
    post:
      tags:
        - AccessPolicyService
      operationId: AccessPolicyService_CreatePolicyScope
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/CreatePolicyScopeRequest"
        required: true
        description: Request body for create policy scope.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/PolicyScope"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Create policy scope
      description: Create policy scope. Supply the fields defined in the request schema.
  /api/v1/policy-scopes/{id}:
    get:
      tags:
        - AccessPolicyService
      operationId: AccessPolicyService_GetPolicyScope
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
          description: Identifier of the resource addressed by this schema or URL.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/PolicyScope"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Get policy scope
      description: Get policy scope.
    put:
      tags:
        - AccessPolicyService
      operationId: AccessPolicyService_UpdatePolicyScope
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
          description: Identifier of the resource addressed by this schema or URL.
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/UpdatePolicyScopeRequest"
        required: true
        description: Request body for update policy scope.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/PolicyScope"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Update policy scope
      description: Update policy scope. Supply the fields defined in the request schema.
  /api/v1/policy-scopes/{team_scope_id}/members:
    get:
      tags:
        - AccessPolicyService
      operationId: AccessPolicyService_ListPolicyTeamMembers
      parameters:
        - name: team_scope_id
          in: path
          required: true
          schema:
            type: string
          description: Team scope id.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ListPolicyTeamMembersResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: List policy team members
      description: List policy team members.
  /api/v1/policy-scopes/{team_scope_id}/members/{identity_id}:
    put:
      tags:
        - AccessPolicyService
      operationId: AccessPolicyService_AddPolicyTeamMember
      parameters:
        - name: team_scope_id
          in: path
          required: true
          schema:
            type: string
          description: Team scope id.
        - name: identity_id
          in: path
          required: true
          schema:
            type: string
          description: Identity id.
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/AddPolicyTeamMemberRequest"
        required: true
        description: Request body for add policy team member.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/PolicyTeamMember"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Add policy team member
      description: Add policy team member. Supply the fields defined in the request schema.
    delete:
      tags:
        - AccessPolicyService
      operationId: AccessPolicyService_RemovePolicyTeamMember
      parameters:
        - name: team_scope_id
          in: path
          required: true
          schema:
            type: string
          description: Team scope id.
        - name: identity_id
          in: path
          required: true
          schema:
            type: string
          description: Identity id.
      responses:
        "200":
          description: Successful response.
          content: {}
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Remove policy team member
      description: Remove policy team member.
  /api/v1/service-accounts:
    post:
      tags:
        - IdentityService
      operationId: IdentityService_CreateServiceAccount
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/CreateServiceAccountRequest"
        required: true
        description: Request body for create service account.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/IdentityAccess"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Create service account
      description: Create service account. Supply the fields defined in the request schema.
  /api/v1/service-accounts/{identity_id}/api-tokens:
    get:
      tags:
        - IdentityService
      operationId: IdentityService_ListServiceAccountAPITokens
      parameters:
        - name: identity_id
          in: path
          required: true
          schema:
            type: string
          description: Identity id.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ListAPITokensResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: List service account API tokens
      description: List service account API tokens.
    post:
      tags:
        - IdentityService
      operationId: IdentityService_CreateServiceAccountAPIToken
      parameters:
        - name: identity_id
          in: path
          required: true
          schema:
            type: string
          description: Identity id.
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/CreateServiceAccountAPITokenRequest"
        required: true
        description: Request body for create service account api token.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/CreateAPITokenResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Create service account API token
      description: Create service account API token. Supply the fields defined in the request schema.
  /api/v1/service-accounts/{identity_id}/api-tokens/{token_id}:revoke:
    post:
      tags:
        - IdentityService
      operationId: IdentityService_RevokeServiceAccountAPIToken
      parameters:
        - name: identity_id
          in: path
          required: true
          schema:
            type: string
          description: Identity id.
        - name: token_id
          in: path
          required: true
          schema:
            type: string
          description: Token id.
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/RevokeServiceAccountAPITokenRequest"
        required: true
        description: Request body for revoke service account api token.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/APIToken"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Revoke service account API token
      description: Revoke service account API token. Supply the fields defined in the request schema.
  /api/v1/team:
    get:
      tags:
        - IdentityService
      operationId: IdentityService_GetTeam
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Team"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Get team
      description: Get team.
    put:
      tags:
        - IdentityService
      operationId: IdentityService_UpdateTeam
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/UpdateTeamRequest"
        required: true
        description: Request body for update team.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Team"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Update team
      description: Update team. Supply the fields defined in the request schema.
  /api/v1/team/invitations:
    get:
      tags:
        - IdentityService
      operationId: IdentityService_ListTeamInvitations
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ListTeamInvitationsResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: List team invitations
      description: List team invitations.
    post:
      tags:
        - IdentityService
      operationId: IdentityService_CreateTeamInvitation
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/CreateTeamInvitationRequest"
        required: true
        description: Request body for create team invitation.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/TeamInvitationDelivery"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Create team invitation
      description: Create team invitation. Supply the fields defined in the request schema.
  /api/v1/team/invitations/{id}:reissue:
    post:
      tags:
        - IdentityService
      operationId: IdentityService_ReissueTeamInvitation
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
          description: Identifier of the resource addressed by this schema or URL.
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/ReissueTeamInvitationRequest"
        required: true
        description: Request body for reissue team invitation.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/TeamInvitationDelivery"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Reissue team invitation
      description: Reissue team invitation. Supply the fields defined in the request schema.
  /api/v1/team/invitations/{id}:revoke:
    post:
      tags:
        - IdentityService
      operationId: IdentityService_RevokeTeamInvitation
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
          description: Identifier of the resource addressed by this schema or URL.
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/RevokeTeamInvitationRequest"
        required: true
        description: Request body for revoke team invitation.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/TeamInvitation"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Revoke team invitation
      description: Revoke team invitation. Supply the fields defined in the request schema.
  /api/v1/team:archive:
    post:
      tags:
        - IdentityService
      operationId: IdentityService_ArchiveTeam
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/ArchiveTeamRequest"
        required: true
        description: Request body for archive team.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/TeamOperationResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Archive team
      description: Archive team. Supply the fields defined in the request schema.
  /api/v1/team:leave:
    post:
      tags:
        - IdentityService
      operationId: IdentityService_LeaveTeam
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/LeaveTeamRequest"
        required: true
        description: Request body for leave team.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/TeamOperationResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Leave team
      description: Leave team. Supply the fields defined in the request schema.
  /api/v1/team:transfer-ownership:
    post:
      tags:
        - IdentityService
      operationId: IdentityService_TransferTeamOwnership
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/TransferTeamOwnershipRequest"
        required: true
        description: Request body for transfer team ownership.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/TeamOperationResponse"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Transfer team ownership
      description: Transfer team ownership. Supply the fields defined in the request schema.
  /api/v1/teams:
    post:
      tags:
        - IdentityService
      operationId: IdentityService_CreateTeam
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/CreateTeamRequest"
        required: true
        description: Request body for create team.
      responses:
        "200":
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/TenantAccess"
        default:
          description: RFC 9457 Problem Details.
          content:
            application/problem+json:
              schema:
                $ref: "#/components/schemas/ProblemDetails"
      summary: Create team
      description: Create team. Supply the fields defined in the request schema.
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
  schemas:
    APIToken:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
        identity_id:
          type: string
          description: Identity id.
        tenant_id:
          type: string
          description: Tenant identifier used with the authenticated access context. Supplying an ID does not grant access.
        name:
          type: string
          description: Name.
        scopes:
          type: array
          items:
            type: string
          description: Scopes list.
        expires_at:
          type: string
          format: date-time
          description: Expires at as an RFC 3339 timestamp.
        last_used_at:
          type: string
          format: date-time
          description: Last used at as an RFC 3339 timestamp.
        revoked_at:
          type: string
          format: date-time
          description: Revoked at as an RFC 3339 timestamp.
        created_at:
          type: string
          format: date-time
          description: Created at as an RFC 3339 timestamp.
        allowed_ip_ranges:
          type: array
          items:
            type: string
          description: Empty means unrestricted; otherwise canonical IPv4/IPv6 CIDR ranges.
      description: Api token representation.
    APITokenPolicy:
      type: object
      properties:
        default_ttl:
          pattern: ^-?(?:0|[1-9][0-9]{0,11})(?:\.[0-9]{1,9})?s$
          type: string
          description: Default ttl.
        max_ttl:
          pattern: ^-?(?:0|[1-9][0-9]{0,11})(?:\.[0-9]{1,9})?s$
          type: string
          description: Max ttl.
        allow_no_expiration:
          type: boolean
          description: Allow no expiration.
        current_client_ip:
          type: string
          description: Current client ip.
      description: Api token policy representation.
    AcceptTeamInvitationRequest:
      type: object
      properties:
        invitation_token:
          type: string
          description: Invitation token.
      description: Accept team invitation request.
    Account:
      type: object
      properties:
        identity:
          $ref: "#/components/schemas/Identity"
          description: Identity.
        has_local_password:
          type: boolean
          description: Has local password.
        current_session_id:
          type: string
          description: Current session id.
      description: Account representation.
    AddPolicyTeamMemberRequest:
      type: object
      properties:
        team_scope_id:
          type: string
          description: Team scope id.
        identity_id:
          type: string
          description: Identity id.
      description: Add policy team member request.
    ArchiveTeamRequest:
      type: object
      properties:
        confirmation_name:
          type: string
          description: Confirmation name.
      description: Archive team request.
    AuditEvent:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
        tenant_id:
          type: string
          description: Tenant identifier used with the authenticated access context. Supplying an ID does not grant access.
        identity_id:
          type: string
          description: Identity id.
        actor_kind:
          type: string
          description: Actor kind.
        action:
          type: string
          description: Action.
        resource_type:
          type: string
          description: Resource type.
        resource_id:
          type: string
          description: Resource id.
        outcome:
          type: string
          description: Outcome.
        request_id:
          type: string
          description: Request id.
        metadata_json:
          type: string
          description: Metadata json.
        created_at:
          type: string
          format: date-time
          description: Created at as an RFC 3339 timestamp.
      description: Audit event representation.
    AuthSession:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
        client_type:
          type: string
          description: Client type.
        device_name:
          type: string
          description: Device name.
        user_agent:
          type: string
          description: User agent.
        ip_address:
          type: string
          description: Ip address.
        access_expires_at:
          type: string
          format: date-time
          description: Access expires at as an RFC 3339 timestamp.
        expires_at:
          type: string
          format: date-time
          description: Expires at as an RFC 3339 timestamp.
        last_seen_at:
          type: string
          format: date-time
          description: Last seen at as an RFC 3339 timestamp.
        revoked_at:
          type: string
          format: date-time
          description: Revoked at as an RFC 3339 timestamp.
        created_at:
          type: string
          format: date-time
          description: Created at as an RFC 3339 timestamp.
        audience:
          type: string
          description: Immutable session use; a platform session cannot select a tenant.
      description: Auth session representation.
    ChangePasswordRequest:
      type: object
      properties:
        current_password:
          type: string
          description: Current password.
        new_password:
          type: string
          description: New password.
      description: Change password request.
    ChangePasswordResponse:
      type: object
      properties:
        revoked_sessions:
          type: integer
          format: int32
          description: Revoked sessions.
      description: Change password response.
    CreateAPITokenRequest:
      type: object
      properties:
        name:
          type: string
          description: Name.
        scopes:
          type: array
          items:
            type: string
          description: Scopes list.
        ttl:
          pattern: ^-?(?:0|[1-9][0-9]{0,11})(?:\.[0-9]{1,9})?s$
          type: string
          description: Choose at most one expiry field; omission uses the platform default.
        expires_at:
          type: string
          format: date-time
          description: Expires at as an RFC 3339 timestamp.
        no_expiration:
          type: boolean
          description: No expiration.
        allowed_ip_ranges:
          type: array
          items:
            type: string
          description: Allowed ip ranges list.
      description: Create API token request.
    CreateAPITokenResponse:
      type: object
      properties:
        token:
          $ref: "#/components/schemas/APIToken"
          description: Token value.
        access_token:
          type: string
          description: Access token.
      description: Create API token response.
    CreateCustomRoleRequest:
      type: object
      properties:
        slug:
          type: string
          description: Slug.
        display_name:
          type: string
          description: Display name.
        description:
          type: string
          description: Description.
        permissions:
          type: array
          items:
            type: string
          description: Permissions list.
      description: Create custom role request.
    CreateIdentityProviderRequest:
      type: object
      properties:
        slug:
          type: string
          description: Slug.
        protocol:
          enum:
            - IDENTITY_PROVIDER_PROTOCOL_UNSPECIFIED
            - IDENTITY_PROVIDER_PROTOCOL_OIDC
            - IDENTITY_PROVIDER_PROTOCOL_SAML
          type: string
          format: enum
          description: Protocol.
          x-enum-descriptions:
            IDENTITY_PROVIDER_PROTOCOL_UNSPECIFIED: unspecified
            IDENTITY_PROVIDER_PROTOCOL_OIDC: oidc
            IDENTITY_PROVIDER_PROTOCOL_SAML: saml
        config:
          $ref: "#/components/schemas/IdentityProviderConfig"
          description: Config.
      description: Create identity provider request.
    CreatePolicyBindingRequest:
      type: object
      properties:
        scope_id:
          type: string
          description: Scope id.
        subject_kind:
          enum:
            - POLICY_SUBJECT_KIND_UNSPECIFIED
            - POLICY_SUBJECT_KIND_IDENTITY
            - POLICY_SUBJECT_KIND_TEAM
          type: string
          format: enum
          description: Subject kind.
          x-enum-descriptions:
            POLICY_SUBJECT_KIND_UNSPECIFIED: unspecified
            POLICY_SUBJECT_KIND_IDENTITY: identity
            POLICY_SUBJECT_KIND_TEAM: team
        subject_id:
          type: string
          description: Subject id.
        role_id:
          type: string
          description: Role id.
      description: Create policy binding request.
    CreatePolicyScopeRequest:
      type: object
      properties:
        kind:
          enum:
            - POLICY_SCOPE_KIND_UNSPECIFIED
            - POLICY_SCOPE_KIND_ORGANIZATION
            - POLICY_SCOPE_KIND_TEAM
            - POLICY_SCOPE_KIND_PROJECT
          type: string
          format: enum
          description: Kind.
          x-enum-descriptions:
            POLICY_SCOPE_KIND_UNSPECIFIED: unspecified
            POLICY_SCOPE_KIND_ORGANIZATION: organization
            POLICY_SCOPE_KIND_TEAM: team
            POLICY_SCOPE_KIND_PROJECT: project
        parent_id:
          type: string
          description: Parent id.
        slug:
          type: string
          description: Slug.
        display_name:
          type: string
          description: Display name.
      description: Create policy scope request.
    CreateServiceAccountAPITokenRequest:
      type: object
      properties:
        identity_id:
          type: string
          description: Identity id.
        name:
          type: string
          description: Name.
        scopes:
          type: array
          items:
            type: string
          description: Scopes list.
        ttl:
          pattern: ^-?(?:0|[1-9][0-9]{0,11})(?:\.[0-9]{1,9})?s$
          type: string
          description: Same lifetime and network policy as personal API tokens.
        expires_at:
          type: string
          format: date-time
          description: Expires at as an RFC 3339 timestamp.
        no_expiration:
          type: boolean
          description: No expiration.
        allowed_ip_ranges:
          type: array
          items:
            type: string
          description: Allowed ip ranges list.
      description: Create service account API token request.
    CreateServiceAccountRequest:
      type: object
      properties:
        subject:
          type: string
          description: Subject.
        display_name:
          type: string
          description: Display name.
        email:
          type: string
          description: Email.
        role:
          enum:
            - TENANT_ROLE_UNSPECIFIED
            - TENANT_ROLE_OWNER
            - TENANT_ROLE_ADMIN
            - TENANT_ROLE_MEMBER
            - TENANT_ROLE_VIEWER
            - TENANT_ROLE_WORKER
          type: string
          format: enum
          description: Role.
          x-enum-descriptions:
            TENANT_ROLE_UNSPECIFIED: unspecified
            TENANT_ROLE_OWNER: owner
            TENANT_ROLE_ADMIN: admin
            TENANT_ROLE_MEMBER: member
            TENANT_ROLE_VIEWER: viewer
            TENANT_ROLE_WORKER: Worker
      description: Create service account request.
    CreateTeamInvitationRequest:
      type: object
      properties:
        email:
          type: string
          description: Email.
        role:
          enum:
            - TENANT_ROLE_UNSPECIFIED
            - TENANT_ROLE_OWNER
            - TENANT_ROLE_ADMIN
            - TENANT_ROLE_MEMBER
            - TENANT_ROLE_VIEWER
            - TENANT_ROLE_WORKER
          type: string
          format: enum
          description: Role.
          x-enum-descriptions:
            TENANT_ROLE_UNSPECIFIED: unspecified
            TENANT_ROLE_OWNER: owner
            TENANT_ROLE_ADMIN: admin
            TENANT_ROLE_MEMBER: member
            TENANT_ROLE_VIEWER: viewer
            TENANT_ROLE_WORKER: Worker
      description: Create team invitation request.
    CreateTeamRequest:
      type: object
      properties:
        name:
          type: string
          description: Name.
        description:
          type: string
          description: Description.
        locale:
          type: string
          description: Locale.
      description: Create team request.
    CustomRole:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
        tenant_id:
          type: string
          description: Tenant identifier used with the authenticated access context. Supplying an ID does not grant access.
        slug:
          type: string
          description: Slug.
        display_name:
          type: string
          description: Display name.
        description:
          type: string
          description: Description.
        permissions:
          type: array
          items:
            type: string
          description: Permissions list.
        status:
          enum:
            - CUSTOM_ROLE_STATUS_UNSPECIFIED
            - CUSTOM_ROLE_STATUS_ACTIVE
            - CUSTOM_ROLE_STATUS_DISABLED
          type: string
          format: enum
          description: Status.
          x-enum-descriptions:
            CUSTOM_ROLE_STATUS_UNSPECIFIED: unspecified
            CUSTOM_ROLE_STATUS_ACTIVE: active
            CUSTOM_ROLE_STATUS_DISABLED: disabled
        created_at:
          type: string
          format: date-time
          description: Created at as an RFC 3339 timestamp.
        updated_at:
          type: string
          format: date-time
          description: Updated at as an RFC 3339 timestamp.
      description: Custom role representation.
    EffectivePermissionSource:
      type: object
      properties:
        kind:
          type: string
          description: Kind.
        binding_id:
          type: string
          description: Binding id.
        scope_id:
          type: string
          description: Scope id.
        subject_id:
          type: string
          description: Subject id.
        role_id:
          type: string
          description: Role id.
        role_slug:
          type: string
          description: Role slug.
        permissions:
          type: array
          items:
            type: string
          description: Permissions list.
      description: Effective permission source representation.
    EffectivePermissions:
      type: object
      properties:
        identity_id:
          type: string
          description: Identity id.
        scope:
          $ref: "#/components/schemas/PolicyScope"
          description: Scope.
        permissions:
          type: array
          items:
            type: string
          description: Permissions list.
        sources:
          type: array
          items:
            $ref: "#/components/schemas/EffectivePermissionSource"
          description: Sources list.
        allowed:
          type: boolean
          description: Allowed.
      description: Effective permissions representation.
    EvaluateEffectivePermissionsRequest:
      type: object
      properties:
        identity_id:
          type: string
          description: Identity id.
        scope_id:
          type: string
          description: Scope id.
        permission:
          type: string
          description: Permission.
      description: Evaluate effective permissions request.
    ExportAuditEventsResponse:
      type: object
      properties:
        content_type:
          type: string
          description: Content type.
        filename:
          type: string
          description: Filename.
        sha256:
          type: string
          description: SHA-256 digest.
        event_count:
          type: integer
          format: int32
          description: Event count.
        data:
          type: string
          format: bytes
          description: Data encoded as Base64.
      description: Export audit events response.
    Identity:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
        kind:
          enum:
            - IDENTITY_KIND_UNSPECIFIED
            - IDENTITY_KIND_USER
            - IDENTITY_KIND_SERVICE
          type: string
          format: enum
          description: Kind.
          x-enum-descriptions:
            IDENTITY_KIND_UNSPECIFIED: unspecified
            IDENTITY_KIND_USER: user
            IDENTITY_KIND_SERVICE: service
        issuer:
          type: string
          description: Issuer.
        subject:
          type: string
          description: Subject.
        display_name:
          type: string
          description: Display name.
        email:
          type: string
          description: Email.
        disabled_at:
          type: string
          format: date-time
          description: Disabled at as an RFC 3339 timestamp.
        created_at:
          type: string
          format: date-time
          description: Created at as an RFC 3339 timestamp.
        updated_at:
          type: string
          format: date-time
          description: Updated at as an RFC 3339 timestamp.
        locale:
          type: string
          description: Empty inherits the active tenant, browser, then English.
        time_zone:
          type: string
          description: Time zone.
        avatar_url:
          type: string
          description: Avatar url.
      description: Identity representation.
    IdentityAccess:
      type: object
      properties:
        identity:
          $ref: "#/components/schemas/Identity"
          description: Identity.
        tenant_id:
          type: string
          description: Tenant identifier used with the authenticated access context. Supplying an ID does not grant access.
        role:
          enum:
            - TENANT_ROLE_UNSPECIFIED
            - TENANT_ROLE_OWNER
            - TENANT_ROLE_ADMIN
            - TENANT_ROLE_MEMBER
            - TENANT_ROLE_VIEWER
            - TENANT_ROLE_WORKER
          type: string
          format: enum
          description: Role.
          x-enum-descriptions:
            TENANT_ROLE_UNSPECIFIED: unspecified
            TENANT_ROLE_OWNER: owner
            TENANT_ROLE_ADMIN: admin
            TENANT_ROLE_MEMBER: member
            TENANT_ROLE_VIEWER: viewer
            TENANT_ROLE_WORKER: Worker
        scopes:
          type: array
          items:
            type: string
          description: Scopes list.
        membership:
          $ref: "#/components/schemas/TenantMembership"
          description: Membership.
        permissions:
          type: array
          items:
            type: string
          description: Permissions list.
      description: Identity access representation.
    IdentityProvider:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
        tenant_id:
          type: string
          description: Tenant identifier used with the authenticated access context. Supplying an ID does not grant access.
        slug:
          type: string
          description: Slug.
        display_name:
          type: string
          description: Display name.
        protocol:
          enum:
            - IDENTITY_PROVIDER_PROTOCOL_UNSPECIFIED
            - IDENTITY_PROVIDER_PROTOCOL_OIDC
            - IDENTITY_PROVIDER_PROTOCOL_SAML
          type: string
          format: enum
          description: Protocol.
          x-enum-descriptions:
            IDENTITY_PROVIDER_PROTOCOL_UNSPECIFIED: unspecified
            IDENTITY_PROVIDER_PROTOCOL_OIDC: oidc
            IDENTITY_PROVIDER_PROTOCOL_SAML: saml
        status:
          enum:
            - IDENTITY_PROVIDER_STATUS_UNSPECIFIED
            - IDENTITY_PROVIDER_STATUS_ACTIVE
            - IDENTITY_PROVIDER_STATUS_DISABLED
          type: string
          format: enum
          description: Status.
          x-enum-descriptions:
            IDENTITY_PROVIDER_STATUS_UNSPECIFIED: unspecified
            IDENTITY_PROVIDER_STATUS_ACTIVE: active
            IDENTITY_PROVIDER_STATUS_DISABLED: disabled
        issuer_uri:
          type: string
          description: Issuer uri.
        audience:
          type: string
          description: Audience.
        tenant_claim:
          type: string
          description: Tenant claim.
        groups_claim:
          type: string
          description: Groups claim.
        email_claim:
          type: string
          description: Email claim.
        display_name_claim:
          type: string
          description: Display name claim.
        jit_enabled:
          type: boolean
          description: Jit enabled.
        default_role:
          enum:
            - TENANT_ROLE_UNSPECIFIED
            - TENANT_ROLE_OWNER
            - TENANT_ROLE_ADMIN
            - TENANT_ROLE_MEMBER
            - TENANT_ROLE_VIEWER
            - TENANT_ROLE_WORKER
          type: string
          format: enum
          description: Default role.
          x-enum-descriptions:
            TENANT_ROLE_UNSPECIFIED: unspecified
            TENANT_ROLE_OWNER: owner
            TENANT_ROLE_ADMIN: admin
            TENANT_ROLE_MEMBER: member
            TENANT_ROLE_VIEWER: viewer
            TENANT_ROLE_WORKER: Worker
        saml_entity_id:
          type: string
          description: Saml entity id.
        saml_metadata_url:
          type: string
          description: Saml metadata url.
        saml_sp_entity_id:
          type: string
          description: Saml sp entity id.
        saml_acs_url:
          type: string
          description: SAML assertion consumer service URL.
        created_at:
          type: string
          format: date-time
          description: Created at as an RFC 3339 timestamp.
        updated_at:
          type: string
          format: date-time
          description: Updated at as an RFC 3339 timestamp.
      description: Identity provider representation.
    IdentityProviderConfig:
      type: object
      properties:
        display_name:
          type: string
          description: Display name.
        issuer_uri:
          type: string
          description: Issuer uri.
        audience:
          type: string
          description: Audience.
        tenant_claim:
          type: string
          description: Tenant claim.
        groups_claim:
          type: string
          description: Groups claim.
        email_claim:
          type: string
          description: Email claim.
        display_name_claim:
          type: string
          description: Display name claim.
        jit_enabled:
          type: boolean
          description: Jit enabled.
        default_role:
          enum:
            - TENANT_ROLE_UNSPECIFIED
            - TENANT_ROLE_OWNER
            - TENANT_ROLE_ADMIN
            - TENANT_ROLE_MEMBER
            - TENANT_ROLE_VIEWER
            - TENANT_ROLE_WORKER
          type: string
          format: enum
          description: Default role.
          x-enum-descriptions:
            TENANT_ROLE_UNSPECIFIED: unspecified
            TENANT_ROLE_OWNER: owner
            TENANT_ROLE_ADMIN: admin
            TENANT_ROLE_MEMBER: member
            TENANT_ROLE_VIEWER: viewer
            TENANT_ROLE_WORKER: Worker
        saml_entity_id:
          type: string
          description: Saml entity id.
        saml_metadata_url:
          type: string
          description: Saml metadata url.
        saml_sp_entity_id:
          type: string
          description: Saml sp entity id.
        saml_acs_url:
          type: string
          description: SAML assertion consumer service URL.
      description: Identity provider config representation.
    IdentityProviderGroupMapping:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
        tenant_id:
          type: string
          description: Tenant identifier used with the authenticated access context. Supplying an ID does not grant access.
        provider_id:
          type: string
          description: Provider id.
        external_group:
          type: string
          description: External group.
        role:
          enum:
            - TENANT_ROLE_UNSPECIFIED
            - TENANT_ROLE_OWNER
            - TENANT_ROLE_ADMIN
            - TENANT_ROLE_MEMBER
            - TENANT_ROLE_VIEWER
            - TENANT_ROLE_WORKER
          type: string
          format: enum
          description: Role.
          x-enum-descriptions:
            TENANT_ROLE_UNSPECIFIED: unspecified
            TENANT_ROLE_OWNER: owner
            TENANT_ROLE_ADMIN: admin
            TENANT_ROLE_MEMBER: member
            TENANT_ROLE_VIEWER: viewer
            TENANT_ROLE_WORKER: Worker
        created_at:
          type: string
          format: date-time
          description: Created at as an RFC 3339 timestamp.
        updated_at:
          type: string
          format: date-time
          description: Updated at as an RFC 3339 timestamp.
      description: Identity provider group mapping representation.
    LeaveTeamRequest:
      type: object
      properties: {}
      description: Leave team request.
    ListAPITokensResponse:
      type: object
      properties:
        tokens:
          type: array
          items:
            $ref: "#/components/schemas/APIToken"
          description: Tokens list.
      description: List API tokens response.
    ListAuditEventsResponse:
      type: object
      properties:
        events:
          type: array
          items:
            $ref: "#/components/schemas/AuditEvent"
          description: Events list.
        next_page_token:
          type: string
          description: Pagination token for the next page. An empty value indicates there is no next page.
      description: List audit events response.
    ListCustomRolesResponse:
      type: object
      properties:
        roles:
          type: array
          items:
            $ref: "#/components/schemas/CustomRole"
          description: Roles list.
      description: List custom roles response.
    ListIdentityProviderGroupMappingsResponse:
      type: object
      properties:
        mappings:
          type: array
          items:
            $ref: "#/components/schemas/IdentityProviderGroupMapping"
          description: Mappings list.
      description: List identity provider group mappings response.
    ListIdentityProvidersResponse:
      type: object
      properties:
        providers:
          type: array
          items:
            $ref: "#/components/schemas/IdentityProvider"
          description: Providers list.
      description: List identity providers response.
    ListMyTenantsResponse:
      type: object
      properties:
        tenants:
          type: array
          items:
            $ref: "#/components/schemas/TenantAccess"
          description: Tenants list.
      description: List my tenants response.
    ListPolicyBindingsResponse:
      type: object
      properties:
        bindings:
          type: array
          items:
            $ref: "#/components/schemas/PolicyBinding"
          description: Bindings list.
      description: List policy bindings response.
    ListPolicyScopesResponse:
      type: object
      properties:
        scopes:
          type: array
          items:
            $ref: "#/components/schemas/PolicyScope"
          description: Scopes list.
      description: List policy scopes response.
    ListPolicyTeamMembersResponse:
      type: object
      properties:
        members:
          type: array
          items:
            $ref: "#/components/schemas/PolicyTeamMember"
          description: Members list.
      description: List policy team members response.
    ListSessionsResponse:
      type: object
      properties:
        sessions:
          type: array
          items:
            $ref: "#/components/schemas/AuthSession"
          description: Sessions list.
      description: List sessions response.
    ListTeamInvitationsResponse:
      type: object
      properties:
        invitations:
          type: array
          items:
            $ref: "#/components/schemas/TeamInvitation"
          description: Invitations list.
      description: List team invitations response.
    ListTenantMembersResponse:
      type: object
      properties:
        members:
          type: array
          items:
            $ref: "#/components/schemas/TenantMember"
          description: Members list.
        next_page_token:
          type: string
          description: Pagination token for the next page. An empty value indicates there is no next page.
      description: List tenant members response.
    LoginRequest:
      type: object
      properties:
        email:
          type: string
          description: Email.
        password:
          type: string
          description: Password.
        client_type:
          type: string
          description: Client type.
        device_name:
          type: string
          description: Device name.
      description: Log in request.
    LoginResponse:
      type: object
      properties:
        access_token:
          type: string
          description: Access token.
        token_type:
          type: string
          description: Token type.
        expires_in:
          type: integer
          format: int32
          description: Expires in.
        refresh_token:
          type: string
          description: Refresh token.
        identity:
          $ref: "#/components/schemas/Identity"
          description: Identity.
      description: Log in response.
    LogoutRequest:
      type: object
      properties:
        refresh_token:
          type: string
          description: Refresh token.
      description: Log out request.
    LogoutResponse:
      type: object
      properties: {}
      description: Log out response.
    PolicyBinding:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
        tenant_id:
          type: string
          description: Tenant identifier used with the authenticated access context. Supplying an ID does not grant access.
        scope_id:
          type: string
          description: Scope id.
        subject_kind:
          enum:
            - POLICY_SUBJECT_KIND_UNSPECIFIED
            - POLICY_SUBJECT_KIND_IDENTITY
            - POLICY_SUBJECT_KIND_TEAM
          type: string
          format: enum
          description: Subject kind.
          x-enum-descriptions:
            POLICY_SUBJECT_KIND_UNSPECIFIED: unspecified
            POLICY_SUBJECT_KIND_IDENTITY: identity
            POLICY_SUBJECT_KIND_TEAM: team
        subject_id:
          type: string
          description: Subject id.
        role_id:
          type: string
          description: Role id.
        created_at:
          type: string
          format: date-time
          description: Created at as an RFC 3339 timestamp.
        updated_at:
          type: string
          format: date-time
          description: Updated at as an RFC 3339 timestamp.
      description: Policy binding representation.
    PolicyPermissionCatalog:
      type: object
      properties:
        permissions:
          type: array
          items:
            type: string
          description: Permissions list.
      description: Policy permission catalog representation.
    PolicyScope:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
        tenant_id:
          type: string
          description: Tenant identifier used with the authenticated access context. Supplying an ID does not grant access.
        kind:
          enum:
            - POLICY_SCOPE_KIND_UNSPECIFIED
            - POLICY_SCOPE_KIND_ORGANIZATION
            - POLICY_SCOPE_KIND_TEAM
            - POLICY_SCOPE_KIND_PROJECT
          type: string
          format: enum
          description: Kind.
          x-enum-descriptions:
            POLICY_SCOPE_KIND_UNSPECIFIED: unspecified
            POLICY_SCOPE_KIND_ORGANIZATION: organization
            POLICY_SCOPE_KIND_TEAM: team
            POLICY_SCOPE_KIND_PROJECT: project
        parent_id:
          type: string
          description: Parent id.
        slug:
          type: string
          description: Slug.
        display_name:
          type: string
          description: Display name.
        status:
          enum:
            - POLICY_SCOPE_STATUS_UNSPECIFIED
            - POLICY_SCOPE_STATUS_ACTIVE
            - POLICY_SCOPE_STATUS_ARCHIVED
          type: string
          format: enum
          description: Status.
          x-enum-descriptions:
            POLICY_SCOPE_STATUS_UNSPECIFIED: unspecified
            POLICY_SCOPE_STATUS_ACTIVE: active
            POLICY_SCOPE_STATUS_ARCHIVED: archived
        created_at:
          type: string
          format: date-time
          description: Created at as an RFC 3339 timestamp.
        updated_at:
          type: string
          format: date-time
          description: Updated at as an RFC 3339 timestamp.
      description: Policy scope representation.
    PolicyTeamMember:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
        tenant_id:
          type: string
          description: Tenant identifier used with the authenticated access context. Supplying an ID does not grant access.
        team_scope_id:
          type: string
          description: Team scope id.
        identity_id:
          type: string
          description: Identity id.
        created_at:
          type: string
          format: date-time
          description: Created at as an RFC 3339 timestamp.
      description: Policy team member representation.
    ProblemDetails:
      type: object
      description: RFC 9457 Problem Details with OrbitSpace correlation extensions.
      required:
        - type
        - title
        - status
        - detail
        - request_id
      properties:
        type:
          type: string
          format: uri
          description: Type.
        title:
          type: string
          description: Title.
        status:
          type: integer
          minimum: 400
          maximum: 599
          description: Status.
        detail:
          type: string
          description: Detail.
        instance:
          type: string
          format: uri-reference
          description: Instance.
        code:
          type: string
          pattern: ^[A-Z][A-Z0-9_]*$
          description: Code.
        request_id:
          type: string
          format: uuid
          description: Request id.
    ProvisionIdentityRequest:
      type: object
      properties:
        kind:
          enum:
            - IDENTITY_KIND_UNSPECIFIED
            - IDENTITY_KIND_USER
            - IDENTITY_KIND_SERVICE
          type: string
          format: enum
          description: Kind.
          x-enum-descriptions:
            IDENTITY_KIND_UNSPECIFIED: unspecified
            IDENTITY_KIND_USER: user
            IDENTITY_KIND_SERVICE: service
        issuer:
          type: string
          description: Issuer.
        subject:
          type: string
          description: Subject.
        display_name:
          type: string
          description: Display name.
        email:
          type: string
          description: Email.
        role:
          enum:
            - TENANT_ROLE_UNSPECIFIED
            - TENANT_ROLE_OWNER
            - TENANT_ROLE_ADMIN
            - TENANT_ROLE_MEMBER
            - TENANT_ROLE_VIEWER
            - TENANT_ROLE_WORKER
          type: string
          format: enum
          description: Role.
          x-enum-descriptions:
            TENANT_ROLE_UNSPECIFIED: unspecified
            TENANT_ROLE_OWNER: owner
            TENANT_ROLE_ADMIN: admin
            TENANT_ROLE_MEMBER: member
            TENANT_ROLE_VIEWER: viewer
            TENANT_ROLE_WORKER: Worker
      description: Provision identity request.
    RefreshTokenRequest:
      type: object
      properties:
        refresh_token:
          type: string
          description: Refresh token.
      description: Refresh token request.
    ReissueTeamInvitationRequest:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
      description: Reissue team invitation request.
    RevokeAPITokenRequest:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
      description: Revoke API token request.
    RevokeOtherSessionsRequest:
      type: object
      properties: {}
      description: Revoke other sessions request.
    RevokeOtherSessionsResponse:
      type: object
      properties:
        revoked_sessions:
          type: integer
          format: int32
          description: Revoked sessions.
      description: Revoke other sessions response.
    RevokeServiceAccountAPITokenRequest:
      type: object
      properties:
        identity_id:
          type: string
          description: Identity id.
        token_id:
          type: string
          description: Token id.
      description: Revoke service account API token request.
    RevokeSessionRequest:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
      description: Revoke session request.
    RevokeTeamInvitationRequest:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
      description: Revoke team invitation request.
    RotateIdentityProviderSCIMTokenRequest:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
      description: Rotate identity provider SCIM token request.
    RotateIdentityProviderSCIMTokenResponse:
      type: object
      properties:
        access_token:
          type: string
          description: Access token.
        rotated_at:
          type: string
          format: date-time
          description: Rotated at as an RFC 3339 timestamp.
      description: Rotate identity provider SCIM token response.
    Team:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
        name:
          type: string
          description: Name.
        description:
          type: string
          description: Description.
        locale:
          type: string
          description: Locale.
        created_at:
          type: string
          format: date-time
          description: Created at as an RFC 3339 timestamp.
        archived_at:
          type: string
          format: date-time
          description: Archived at as an RFC 3339 timestamp.
        role:
          enum:
            - TENANT_ROLE_UNSPECIFIED
            - TENANT_ROLE_OWNER
            - TENANT_ROLE_ADMIN
            - TENANT_ROLE_MEMBER
            - TENANT_ROLE_VIEWER
            - TENANT_ROLE_WORKER
          type: string
          format: enum
          description: Role.
          x-enum-descriptions:
            TENANT_ROLE_UNSPECIFIED: unspecified
            TENANT_ROLE_OWNER: owner
            TENANT_ROLE_ADMIN: admin
            TENANT_ROLE_MEMBER: member
            TENANT_ROLE_VIEWER: viewer
            TENANT_ROLE_WORKER: Worker
      description: Team representation.
    TeamInvitation:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
        tenant_id:
          type: string
          description: Tenant identifier used with the authenticated access context. Supplying an ID does not grant access.
        email:
          type: string
          description: Email.
        role:
          enum:
            - TENANT_ROLE_UNSPECIFIED
            - TENANT_ROLE_OWNER
            - TENANT_ROLE_ADMIN
            - TENANT_ROLE_MEMBER
            - TENANT_ROLE_VIEWER
            - TENANT_ROLE_WORKER
          type: string
          format: enum
          description: Role.
          x-enum-descriptions:
            TENANT_ROLE_UNSPECIFIED: unspecified
            TENANT_ROLE_OWNER: owner
            TENANT_ROLE_ADMIN: admin
            TENANT_ROLE_MEMBER: member
            TENANT_ROLE_VIEWER: viewer
            TENANT_ROLE_WORKER: Worker
        status:
          type: string
          description: Status.
        expires_at:
          type: string
          format: date-time
          description: Expires at as an RFC 3339 timestamp.
        accepted_at:
          type: string
          format: date-time
          description: Accepted at as an RFC 3339 timestamp.
        revoked_at:
          type: string
          format: date-time
          description: Revoked at as an RFC 3339 timestamp.
        created_at:
          type: string
          format: date-time
          description: Created at as an RFC 3339 timestamp.
      description: Team invitation representation.
    TeamInvitationDelivery:
      type: object
      properties:
        invitation:
          $ref: "#/components/schemas/TeamInvitation"
          description: Invitation.
        invitation_token:
          type: string
          description: Invitation token.
      description: Team invitation delivery representation.
    TeamOperationResponse:
      type: object
      properties: {}
      description: Team operation response representation.
    TenantAccess:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
        name:
          type: string
          description: Name.
        locale:
          type: string
          description: Empty inherits the browser locale, then English.
        role:
          enum:
            - TENANT_ROLE_UNSPECIFIED
            - TENANT_ROLE_OWNER
            - TENANT_ROLE_ADMIN
            - TENANT_ROLE_MEMBER
            - TENANT_ROLE_VIEWER
            - TENANT_ROLE_WORKER
          type: string
          format: enum
          description: Role.
          x-enum-descriptions:
            TENANT_ROLE_UNSPECIFIED: unspecified
            TENANT_ROLE_OWNER: owner
            TENANT_ROLE_ADMIN: admin
            TENANT_ROLE_MEMBER: member
            TENANT_ROLE_VIEWER: viewer
            TENANT_ROLE_WORKER: Worker
        membership_id:
          type: string
          description: Membership id.
        permissions:
          type: array
          items:
            type: string
          description: Permissions list.
      description: Tenant access representation.
    TenantMember:
      type: object
      properties:
        identity:
          $ref: "#/components/schemas/Identity"
          description: Identity.
        membership:
          $ref: "#/components/schemas/TenantMembership"
          description: Membership.
      description: Tenant member representation.
    TenantMembership:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
        tenant_id:
          type: string
          description: Tenant identifier used with the authenticated access context. Supplying an ID does not grant access.
        identity_id:
          type: string
          description: Identity id.
        role:
          enum:
            - TENANT_ROLE_UNSPECIFIED
            - TENANT_ROLE_OWNER
            - TENANT_ROLE_ADMIN
            - TENANT_ROLE_MEMBER
            - TENANT_ROLE_VIEWER
            - TENANT_ROLE_WORKER
          type: string
          format: enum
          description: Role.
          x-enum-descriptions:
            TENANT_ROLE_UNSPECIFIED: unspecified
            TENANT_ROLE_OWNER: owner
            TENANT_ROLE_ADMIN: admin
            TENANT_ROLE_MEMBER: member
            TENANT_ROLE_VIEWER: viewer
            TENANT_ROLE_WORKER: Worker
        status:
          enum:
            - MEMBERSHIP_STATUS_UNSPECIFIED
            - MEMBERSHIP_STATUS_ACTIVE
            - MEMBERSHIP_STATUS_DISABLED
          type: string
          format: enum
          description: Status.
          x-enum-descriptions:
            MEMBERSHIP_STATUS_UNSPECIFIED: unspecified
            MEMBERSHIP_STATUS_ACTIVE: active
            MEMBERSHIP_STATUS_DISABLED: disabled
        source:
          enum:
            - MEMBERSHIP_SOURCE_UNSPECIFIED
            - MEMBERSHIP_SOURCE_MANUAL
            - MEMBERSHIP_SOURCE_OIDC
            - MEMBERSHIP_SOURCE_SAML
            - MEMBERSHIP_SOURCE_SCIM
          type: string
          format: enum
          description: Source.
          x-enum-descriptions:
            MEMBERSHIP_SOURCE_UNSPECIFIED: unspecified
            MEMBERSHIP_SOURCE_MANUAL: manual
            MEMBERSHIP_SOURCE_OIDC: oidc
            MEMBERSHIP_SOURCE_SAML: saml
            MEMBERSHIP_SOURCE_SCIM: SCIM
        external_id:
          type: string
          description: External id.
        disabled_at:
          type: string
          format: date-time
          description: Disabled at as an RFC 3339 timestamp.
        created_at:
          type: string
          format: date-time
          description: Created at as an RFC 3339 timestamp.
        updated_at:
          type: string
          format: date-time
          description: Updated at as an RFC 3339 timestamp.
        provider_id:
          type: string
          description: Provider id.
        external_username:
          type: string
          description: External username.
      description: Tenant membership representation.
    TransferTeamOwnershipRequest:
      type: object
      properties:
        membership_id:
          type: string
          description: Membership id.
      description: Transfer team ownership request.
    UpdateAccountRequest:
      type: object
      properties:
        display_name:
          type: string
          description: Display name.
        avatar_url:
          type: string
          description: Avatar url.
        locale:
          type: string
          description: Locale.
        time_zone:
          type: string
          description: Time zone.
      description: Update account request.
    UpdateCustomRoleRequest:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
        display_name:
          type: string
          description: Display name.
        description:
          type: string
          description: Description.
        permissions:
          type: array
          items:
            type: string
          description: Permissions list.
        status:
          enum:
            - CUSTOM_ROLE_STATUS_UNSPECIFIED
            - CUSTOM_ROLE_STATUS_ACTIVE
            - CUSTOM_ROLE_STATUS_DISABLED
          type: string
          format: enum
          description: Status.
          x-enum-descriptions:
            CUSTOM_ROLE_STATUS_UNSPECIFIED: unspecified
            CUSTOM_ROLE_STATUS_ACTIVE: active
            CUSTOM_ROLE_STATUS_DISABLED: disabled
      description: Update custom role request.
    UpdateIdentityProviderRequest:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
        status:
          enum:
            - IDENTITY_PROVIDER_STATUS_UNSPECIFIED
            - IDENTITY_PROVIDER_STATUS_ACTIVE
            - IDENTITY_PROVIDER_STATUS_DISABLED
          type: string
          format: enum
          description: Status.
          x-enum-descriptions:
            IDENTITY_PROVIDER_STATUS_UNSPECIFIED: unspecified
            IDENTITY_PROVIDER_STATUS_ACTIVE: active
            IDENTITY_PROVIDER_STATUS_DISABLED: disabled
        config:
          $ref: "#/components/schemas/IdentityProviderConfig"
          description: Config.
      description: Update identity provider request.
    UpdateMyPreferencesRequest:
      type: object
      properties:
        locale:
          type: string
          description: Supported values are en, zh-CN, and empty to inherit.
      description: Update my preferences request.
    UpdatePolicyScopeRequest:
      type: object
      properties:
        id:
          type: string
          description: Identifier of the resource addressed by this schema or URL.
        display_name:
          type: string
          description: Display name.
        status:
          enum:
            - POLICY_SCOPE_STATUS_UNSPECIFIED
            - POLICY_SCOPE_STATUS_ACTIVE
            - POLICY_SCOPE_STATUS_ARCHIVED
          type: string
          format: enum
          description: Status.
          x-enum-descriptions:
            POLICY_SCOPE_STATUS_UNSPECIFIED: unspecified
            POLICY_SCOPE_STATUS_ACTIVE: active
            POLICY_SCOPE_STATUS_ARCHIVED: archived
      description: Update policy scope request.
    UpdateTeamRequest:
      type: object
      properties:
        name:
          type: string
          description: Name.
        description:
          type: string
          description: Description.
        locale:
          type: string
          description: Locale.
      description: Update team request.
    UpdateTenantMembershipRequest:
      type: object
      properties:
        membership_id:
          type: string
          description: Membership id.
        role:
          enum:
            - TENANT_ROLE_UNSPECIFIED
            - TENANT_ROLE_OWNER
            - TENANT_ROLE_ADMIN
            - TENANT_ROLE_MEMBER
            - TENANT_ROLE_VIEWER
            - TENANT_ROLE_WORKER
          type: string
          format: enum
          description: Role.
          x-enum-descriptions:
            TENANT_ROLE_UNSPECIFIED: unspecified
            TENANT_ROLE_OWNER: owner
            TENANT_ROLE_ADMIN: admin
            TENANT_ROLE_MEMBER: member
            TENANT_ROLE_VIEWER: viewer
            TENANT_ROLE_WORKER: Worker
        status:
          enum:
            - MEMBERSHIP_STATUS_UNSPECIFIED
            - MEMBERSHIP_STATUS_ACTIVE
            - MEMBERSHIP_STATUS_DISABLED
          type: string
          format: enum
          description: Status.
          x-enum-descriptions:
            MEMBERSHIP_STATUS_UNSPECIFIED: unspecified
            MEMBERSHIP_STATUS_ACTIVE: active
            MEMBERSHIP_STATUS_DISABLED: disabled
      description: Update tenant membership request.
    UpdateTenantPreferencesRequest:
      type: object
      properties:
        locale:
          type: string
          description: Supported values are en, zh-CN, and empty to inherit.
      description: Update tenant preferences request.
    UpsertIdentityProviderGroupMappingRequest:
      type: object
      properties:
        provider_id:
          type: string
          description: Provider id.
        external_group:
          type: string
          description: External group.
        role:
          enum:
            - TENANT_ROLE_UNSPECIFIED
            - TENANT_ROLE_OWNER
            - TENANT_ROLE_ADMIN
            - TENANT_ROLE_MEMBER
            - TENANT_ROLE_VIEWER
            - TENANT_ROLE_WORKER
          type: string
          format: enum
          description: Role.
          x-enum-descriptions:
            TENANT_ROLE_UNSPECIFIED: unspecified
            TENANT_ROLE_OWNER: owner
            TENANT_ROLE_ADMIN: admin
            TENANT_ROLE_MEMBER: member
            TENANT_ROLE_VIEWER: viewer
            TENANT_ROLE_WORKER: Worker
      description: Create or update identity provider group mapping request.
tags:
  - name: AccessPolicyService
    x-displayName: Access policies
    description: Access policies operations.
  - name: AuthService
    x-displayName: Authentication and API tokens
    description: Authentication and API tokens operations.
  - name: IdentityService
    x-displayName: Accounts and teams
    description: Accounts and teams operations.
  - name: AuditService
    x-displayName: Audit events
    description: Audit events operations.
  - name: IdentityProviderService
    x-displayName: Enterprise identity providers
    description: Enterprise identity providers operations.
