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

# Create invitation

> Create an invitation to join the organization. Sends an email to the invitee with a link to accept.



## OpenAPI

````yaml api-docs/app-team/auth.json post /v1/auth/organizations/{id}/invitations
openapi: 3.1.1
info:
  title: Auth API
  version: 1.0.0
  description: >-
    Auth API supporting the k0rdent Enterprise authentication and authorization
    service
servers:
  - url: http://localhost:8000
    description: Local Development
security: []
paths:
  /v1/auth/organizations/{id}/invitations:
    post:
      tags:
        - Invitations
      summary: Create invitation
      description: >-
        Create an invitation to join the organization. Sends an email to the
        invitee with a link to accept.
      parameters:
        - schema:
            type: string
            minLength: 1
          required: true
          name: id
          in: path
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                email:
                  type: string
                  format: email
                role:
                  type: string
                  enum:
                    - owner
                    - admin
                    - member
                resend:
                  type: boolean
              required:
                - email
                - role
      responses:
        '201':
          description: Invitation created
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    enum:
                      - true
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                      email:
                        type: string
                        format: email
                      role:
                        type: string
                        enum:
                          - owner
                          - admin
                          - member
                      organizationId:
                        type: string
                      status:
                        type: string
                        enum:
                          - pending
                          - accepted
                          - rejected
                          - canceled
                      expiresAt:
                        type: string
                        nullable: true
                        format: date-time
                      createdAt:
                        type: string
                        nullable: true
                        format: date-time
                    required:
                      - id
                      - email
                      - role
                      - organizationId
                      - status
                      - expiresAt
                      - createdAt
                  meta:
                    type: object
                    properties:
                      requestId:
                        type: string
                      timestamp:
                        type: string
                    required:
                      - requestId
                      - timestamp
                required:
                  - success
                  - data
                  - meta
        '400':
          description: Bad Request - Validation error
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    enum:
                      - false
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      details:
                        type: object
                        additionalProperties:
                          nullable: true
                    required:
                      - code
                      - message
                  meta:
                    type: object
                    properties:
                      requestId:
                        type: string
                      timestamp:
                        type: string
                    required:
                      - requestId
                      - timestamp
                required:
                  - success
                  - error
                  - meta
        '401':
          description: Unauthorized - Authentication required
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    enum:
                      - false
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      details:
                        type: object
                        additionalProperties:
                          nullable: true
                    required:
                      - code
                      - message
                  meta:
                    type: object
                    properties:
                      requestId:
                        type: string
                      timestamp:
                        type: string
                    required:
                      - requestId
                      - timestamp
                required:
                  - success
                  - error
                  - meta
        '403':
          description: Forbidden - Insufficient permissions
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    enum:
                      - false
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      details:
                        type: object
                        additionalProperties:
                          nullable: true
                    required:
                      - code
                      - message
                  meta:
                    type: object
                    properties:
                      requestId:
                        type: string
                      timestamp:
                        type: string
                    required:
                      - requestId
                      - timestamp
                required:
                  - success
                  - error
                  - meta
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    enum:
                      - false
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      details:
                        type: object
                        additionalProperties:
                          nullable: true
                    required:
                      - code
                      - message
                  meta:
                    type: object
                    properties:
                      requestId:
                        type: string
                      timestamp:
                        type: string
                    required:
                      - requestId
                      - timestamp
                required:
                  - success
                  - error
                  - meta

````