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

# Bulk Invite Users (legacy)

> Invite several people to your organization in one request, without workspaces.

> [!WARNING]
>
> **Legacy endpoint.** `/api/v1/invitations/bulk-invite/` predates workspaces. It keeps working for existing integrations, but it cannot place an invitee in a workspace. New integrations should use [Bulk Invite Users](https://docs.nekt.com/platform-api/invitations/organization/bulk-invite.md), which takes the same request with the role named `organization_role` and accepts `workspaces`.

Each entry in `invitations` takes the same fields as the [legacy single invite](https://docs.nekt.com/platform-api/invitations/legacy/invite.md). The batch is all-or-nothing, and the response (`message`, `invited`, `resent`) is the same as [Bulk Invite Users](https://docs.nekt.com/platform-api/invitations/organization/bulk-invite.md).


## OpenAPI

````yaml POST /api/v1/invitations/bulk-invite/
openapi: 3.0.3
info:
  title: Nekt API
  version: v1
  description: Nekt API Documentation
  contact:
    email: support@nekt.ai
servers:
  - url: https://api.nekt.ai
security: []
paths:
  /api/v1/invitations/bulk-invite/:
    post:
      tags:
        - v1
      description: >-
        Invite several people at once.


        Each entry behaves exactly like a single `POST /api/v1/invitations/`: an
        address with no

        outstanding invitation is invited, and one that already has an
        invitation gets it re-sent,

        with a role change if the role differs. Only `email` is required; `role`
        defaults to

        `member`.


        ALL-OR-NOTHING, by way of `ATOMIC_REQUESTS` and DRF's `set_rollback()`:
        one entry that

        fails -- an address that already belongs to a member, a role above the
        caller's own --

        undoes the whole batch. The alternative, applying some entries and
        reporting the rest as

        errors, makes a retry ambiguous: the caller cannot tell a
        duplicate-invite from a first

        attempt, and re-sending the batch would mail everyone who did succeed a
        second time.


        Emails are sent on commit rather than inline, so a batch that rolls back
        sends none. That

        is the one half of this a transaction cannot take back.
      operationId: v1_invitations_bulk_invite_create
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BulkInvitationInput'
          application/x-www-form-urlencoded:
            schema:
              $ref: '#/components/schemas/BulkInvitationInput'
          multipart/form-data:
            schema:
              $ref: '#/components/schemas/BulkInvitationInput'
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BulkInvitationResponse'
          description: ''
      security:
        - ApiKeyAuth: []
components:
  schemas:
    BulkInvitationInput:
      type: object
      properties:
        invitations:
          type: array
          items:
            $ref: '#/components/schemas/Invitation'
          description: The people to invite.
      required:
        - invitations
    BulkInvitationResponse:
      type: object
      description: What a bulk invite did, split by what happened to each address.
      properties:
        message:
          type: string
          description: Human-readable summary of what the bulk invite did.
        invited:
          type: array
          items:
            type: string
            format: email
          description: Addresses that had no outstanding invitation and now do.
        resent:
          type: array
          items:
            type: string
            format: email
          description: Addresses whose outstanding invitation was re-sent.
      required:
        - invited
        - message
        - resent
    Invitation:
      type: object
      properties:
        id:
          type: string
          format: uuid
          readOnly: true
        first_name:
          type: string
          maxLength: 150
        last_name:
          type: string
          maxLength: 150
        email:
          type: string
          format: email
          title: Email address
          maxLength: 254
        role:
          allOf:
            - $ref: '#/components/schemas/OrganizationRoleEnum'
          default: member
          description: >-
            Defaults to `member`. You cannot invite somebody to a role above
            your own, and on the Free plan only owners can be invited.


            * `owner` - Owner

            * `admin` - Admin

            * `member` - Member
        functional_area:
          nullable: true
          oneOf:
            - $ref: '#/components/schemas/FunctionalAreaEnum'
            - $ref: '#/components/schemas/BlankEnum'
            - $ref: '#/components/schemas/NullEnum'
        other_functional_area:
          type: string
          nullable: true
          maxLength: 128
        sent_at:
          type: string
          format: date-time
          readOnly: true
        expires_at:
          type: string
          format: date-time
          readOnly: true
        accepted_at:
          type: string
          format: date-time
          readOnly: true
          nullable: true
        revoked_at:
          type: string
          format: date-time
          readOnly: true
          nullable: true
        created_at:
          type: string
          format: date-time
          readOnly: true
        created_by:
          allOf:
            - $ref: '#/components/schemas/OrganizationUser'
          readOnly: true
      required:
        - accepted_at
        - created_at
        - created_by
        - email
        - expires_at
        - id
        - revoked_at
        - sent_at
    OrganizationRoleEnum:
      enum:
        - owner
        - admin
        - member
      type: string
      description: |-
        * `owner` - Owner
        * `admin` - Admin
        * `member` - Member
    FunctionalAreaEnum:
      enum:
        - data_analytics
        - sales
        - customer_support
        - operations
        - marketing
        - finance
        - product_development
        - growth
        - executive_leadership
        - other
      type: string
      description: |-
        * `data_analytics` - Data & Analytics
        * `sales` - Sales
        * `customer_support` - Customer Support
        * `operations` - Operations
        * `marketing` - Marketing
        * `finance` - Finance
        * `product_development` - Product Development
        * `growth` - Growth
        * `executive_leadership` - Executive Leadership
        * `other` - Other
    BlankEnum:
      enum:
        - ''
    NullEnum:
      enum:
        - null
    OrganizationUser:
      type: object
      properties:
        id:
          type: integer
          readOnly: true
        first_name:
          type: string
          readOnly: true
        last_name:
          type: string
          readOnly: true
        email:
          type: string
          format: email
          readOnly: true
          title: Email address
        picture:
          type: string
          format: uri
          readOnly: true
          nullable: true
        role:
          type: string
          readOnly: true
        functional_area:
          readOnly: true
          nullable: true
          oneOf:
            - $ref: '#/components/schemas/FunctionalAreaEnum'
            - $ref: '#/components/schemas/NullEnum'
        other_functional_area:
          type: string
          readOnly: true
          nullable: true
        date_joined:
          type: string
          format: date-time
          readOnly: true
        last_login:
          type: string
          format: date-time
          readOnly: true
          nullable: true
        is_active:
          type: boolean
          readOnly: true
          default: false
        is_pending:
          type: boolean
          readOnly: true
          default: false
        joined_at:
          type: string
          format: date-time
          readOnly: true
          description: When the user joined the organization; null while they are pending.
        workspace_is_active:
          type: boolean
          nullable: true
          readOnly: true
          description: >-
            Whether the person can act in the requester's workspace: active in
            the organization AND in that workspace (spec rule 15); false when
            they are not a member of it. Populated on the organization's user
            list; null where this serializer is nested.
      required:
        - date_joined
        - email
        - first_name
        - functional_area
        - id
        - is_active
        - is_pending
        - joined_at
        - last_login
        - last_name
        - other_functional_area
        - picture
        - role
        - workspace_is_active
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: 'API Key authentication. Format: ''x-api-key: api_key'''

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.