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

# Post v2orgs members

> Add members to an organization in bulk. Provide userIds and/or emails. Known emails are added as active members; unknown emails create pending invitations with tokens.



## OpenAPI

````yaml /api-reference/swagger.yml post /v2/orgs/{orgSlug}/members
openapi: 3.0.0
info:
  version: 1.0.0
  title: Prisme.ai APIs
  description: Prisme.ai APIs specifications
  termsOfService: https://www.prisme.ai/mentions-legales
  contact:
    name: Prisme.ai Support Team
    email: support@prisme.ai
    url: https://www.prisme.ai
  license:
    name: Apache 2.0
    url: https://www.apache.org/licenses/LICENSE-2.0.html
servers:
  - url: https://api.eda.prisme.ai
  - url: http://localhost:3001
security:
  - BearerAuth: []
  - WorkspaceApiKeyAuth: []
  - BearerAuth: []
    WorkspaceApiKeyAuth: []
paths:
  /v2/orgs/{orgSlug}/members:
    post:
      tags:
        - Organizations
      description: >-
        Add members to an organization in bulk. Provide userIds and/or emails.
        Known emails are added as active members; unknown emails create pending
        invitations with tokens.
      operationId: addOrgMembers
      parameters:
        - name: orgSlug
          in: path
          required: true
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                userIds:
                  type: array
                  items:
                    type: string
                emails:
                  type: array
                  items:
                    type: string
                roleSlug:
                  type: string
      responses:
        '201':
          description: Members added
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/OrgMembership'
        '401':
          description: AuthenticationError
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AuthenticationError'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ForbiddenError'
components:
  schemas:
    OrgMembership:
      type: object
      required:
        - orgSlug
        - userId
        - status
      properties:
        id:
          type: string
        orgSlug:
          type: string
        userId:
          type: string
        roleSlug:
          type: string
        status:
          type: string
          enum:
            - active
            - invited
            - suspended
        invitedBy:
          type: string
        invitedAt:
          type: string
        inviteEmail:
          type: string
        inviteToken:
          type: string
        joinedAt:
          type: string
        joinedVia:
          type: string
          enum:
            - direct
            - invite-code
            - invite-email
            - auto-join
            - join-rule
        groups:
          type: array
          description: >-
            Org group slugs the user belongs to. Only populated on
            listOrgMembers when includeGroups=true.
          items:
            type: string
        createdBy:
          type: string
        updatedBy:
          type: string
        createdAt:
          type: string
        updatedAt:
          type: string
    AuthenticationError:
      type: object
      properties:
        error:
          type: string
          example: AuthenticationError
        message:
          type: string
          example: Unauthenticated
    ForbiddenError:
      type: object
      properties:
        error:
          type: string
          example: ForbiddenError
        message:
          type: string
          example: Forbidden
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
    WorkspaceApiKeyAuth:
      type: apiKey
      in: header
      name: x-prismeai-api-key

````