> ## Documentation Index
> Fetch the complete documentation index at: https://docs.hybridbox.io/llms.txt
> Use this file to discover all available pages before exploring further.

# 招待を作成

> アカウント招待を作成

<script src="/locale-bridge.js" />


## OpenAPI

````yaml /openapi.ja.json POST /v1/public/accounts/{account_id}/auth/invitations
openapi: 3.1.0
info:
  title: Code API (Public)
  version: 1.0.0
servers:
  - url: https://api.hybridbox.io
security: []
paths:
  /v1/public/accounts/{account_id}/auth/invitations:
    post:
      tags:
        - public-accounts
        - public-account-auth
      summary: アカウント招待を作成
      description: アカウントスコープの招待を作成します。
      operationId: >-
        create_public_account_invitation_v1_public_accounts__account_id__auth_invitations_post
      parameters:
        - in: path
          name: account_id
          required: true
          schema:
            format: uuid
            title: Account Id
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/InviteRequest'
        required: true
      responses:
        '201':
          content:
            application/json:
              schema:
                anyOf:
                  - $ref: '#/components/schemas/InviteResponse'
                  - $ref: '#/components/schemas/MaterializedInvitationAccessResponse'
                title: >-
                  Response Create Public Account Invitation V1 Public Accounts 
                  Account Id  Auth Invitations Post
          description: ''
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
          description: 検証エラー
      security:
        - PublicBearerAuth: []
components:
  schemas:
    InviteRequest:
      description: 新しいユーザー招待を作成するためのリクエスト スキーマ。
      properties:
        assignments:
          items:
            $ref: '#/components/schemas/InvitationAssignmentRequest'
          minItems: 1
          title: 割り当て
          type: array
        email:
          description: 対象メールアドレス
          title: メール
          type: string
        locale:
          anyOf:
            - type: string
            - type: 'null'
          description: トランザクション招待メール用の任意ロケール
          title: ロケール
        note:
          anyOf:
            - type: string
            - type: 'null'
          title: メモ
      required:
        - email
        - assignments
      title: Inviteリクエスト
      type: object
    InviteResponse:
      properties:
        accepted_at:
          anyOf:
            - format: date-time
              type: string
            - type: 'null'
          title: 承諾日時
        accepted_subject_id:
          anyOf:
            - type: string
            - type: 'null'
          title: 承諾サブジェクト ID
        assignments:
          items:
            $ref: '#/components/schemas/InvitationAssignmentResponse'
          title: 割り当て
          type: array
        created_at:
          anyOf:
            - format: date-time
              type: string
            - type: 'null'
          title: 作成日時
        email:
          title: メール
          type: string
        expires_at:
          anyOf:
            - format: date-time
              type: string
            - type: 'null'
          title: 有効期限日時
        id:
          format: uuid
          title: ID
          type: string
        note:
          anyOf:
            - type: string
            - type: 'null'
          title: メモ
        permission_context:
          $ref: '#/components/schemas/PermissionInspectabilitySnapshot'
        status:
          title: ステータス
          type: string
      required:
        - id
        - email
        - status
        - assignments
        - permission_context
      title: InviteResponse
      type: object
    MaterializedInvitationAccessResponse:
      properties:
        accepted_subject_id:
          title: 承諾サブジェクト ID
          type: string
        assignment_count:
          title: 割り当て数
          type: integer
        email:
          title: メール
          type: string
        grant_count:
          title: 付与数
          type: integer
        group_membership_count:
          title: グループメンバーシップ数
          type: integer
        mode:
          default: materialized
          title: モード
          type: string
        permission_context:
          $ref: '#/components/schemas/PermissionInspectabilitySnapshot'
        role_assignment_count:
          title: 役割の割り当て数
          type: integer
        status:
          default: accepted
          title: ステータス
          type: string
      required:
        - email
        - accepted_subject_id
        - assignment_count
        - group_membership_count
        - grant_count
        - role_assignment_count
        - permission_context
      title: Materialized招待Accessレスポンス
      type: object
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          title: 詳細
          type: array
      title: HTTPValidationエラー
      type: object
    InvitationAssignmentRequest:
      description: 招待内の単一の権限割り当てのスキーマ。
      properties:
        capability_key:
          anyOf:
            - type: string
            - type: 'null'
          title: ケイパビリティキー
        grant_kind:
          anyOf:
            - $ref: '#/components/schemas/GrantKind'
            - type: 'null'
        group_id:
          anyOf:
            - type: string
            - type: 'null'
          title: グループ ID
        resource_id:
          anyOf:
            - format: uuid
              type: string
            - type: 'null'
          title: リソース ID
        resource_type:
          anyOf:
            - $ref: '#/components/schemas/ResourceType'
            - type: 'null'
        role_key:
          anyOf:
            - type: string
            - type: 'null'
          title: 役割キー
      title: 招待割り当てリクエスト
      type: object
    InvitationAssignmentResponse:
      description: 招待応答内の単一の権限割り当てのスキーマ。
      properties:
        assignment_kind:
          title: 割り当ての種類
          type: string
        capability_key:
          anyOf:
            - type: string
            - type: 'null'
          title: ケイパビリティキー
        grant_kind:
          anyOf:
            - type: string
            - type: 'null'
          title: 付与の種類
        group_id:
          anyOf:
            - type: string
            - type: 'null'
          title: グループ ID
        id:
          anyOf:
            - format: uuid
              type: string
            - type: 'null'
          title: ID
        position:
          title: 位置
          type: integer
        resource_id:
          anyOf:
            - format: uuid
              type: string
            - type: 'null'
          title: リソース ID
        resource_type:
          anyOf:
            - type: string
            - type: 'null'
          title: リソースタイプ
        role_key:
          anyOf:
            - type: string
            - type: 'null'
          title: 役割キー
      required:
        - assignment_kind
        - position
      title: 招待割り当てレスポンス
      type: object
    PermissionInspectabilitySnapshot:
      description: ユーザー、グループ、および招待状の管理のための共有検査可能性スナップショット。
      properties:
        assigned_bundle_keys:
          items:
            type: string
          title: 割り当て済みバンドルキー
          type: array
        direct_capability_keys:
          items:
            type: string
          title: 直接ケイパビリティキー
          type: array
        owner_assignments:
          items:
            $ref: '#/components/schemas/OwnerAssignmentSnapshot'
          title: 所有者割り当て
          type: array
        resolved_capability_keys:
          items:
            type: string
          title: 解決済みケイパビリティキー
          type: array
        status:
          default: active
          title: ステータス
          type: string
        subject_id:
          default: ''
          title: サブジェクト ID
          type: string
        subject_type:
          default: unknown
          title: サブジェクトタイプ
          type: string
      title: 権限InspectabilitySnapshot
      type: object
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          title: 場所
          type: array
        msg:
          title: メッセージ
          type: string
        type:
          title: エラータイプ
          type: string
      required:
        - loc
        - msg
        - type
      title: Validationエラー
      type: object
    GrantKind:
      description: 認可付与の種類。
      enum:
        - capability
        - account_owner
        - super_admin
      title: GrantKind
      type: string
    ResourceType:
      description: 認可リソースおよびスコープタイプ。
      enum:
        - client
        - account
        - workspace
        - domain
        - dns_record
        - mailbox
        - redirect
        - forwarding
        - credential
        - tenant
        - route
        - proxy
      title: リソースType
      type: string
    OwnerAssignmentSnapshot:
      description: アカウント所有者の関係を示すスキーマ。
      properties:
        account_id:
          format: uuid
          title: アカウントID
          type: string
      required:
        - account_id
      title: Owner割り当てSnapshot
      type: object
  securitySchemes:
    PublicBearerAuth:
      bearerFormat: JWT or Hybridbox Service account token
      description: >-
        Public API bearer credential sent as `Authorization: Bearer <token>`.
        Use either an OAuth access token or a Hybridbox Service account token.
      scheme: bearer
      type: http

````