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

# Accept

> The endpoint to accept an invitation, by token, for either a user that exists already
or a user that is signing up concurrently with accepting the invitation.

See examples stated for each case: existing user or new user. New users must send sign-up data
or else a 400 response will be returned.

The expiry date and status of invitation are validated before acceptance.



## OpenAPI

````yaml api-reference/openapi.yaml post /api/v1/organization-invitations/accept/
openapi: 3.0.3
info:
  title: API v1 Public
  version: 1.4.2
  description: >+


    Apex API functions and available endpoints.


    To authenticate, use the `Token` value from the `auth/login` endpoint in the
    Authorize dialog.

  license:
    name: Proprietary to Emotive Technologies Inc.
servers:
  - url: https://api.main.apexscore.ai
security: []
paths:
  /api/v1/organization-invitations/accept/:
    post:
      tags:
        - Organization Invitations
      summary: Accept
      description: >-
        The endpoint to accept an invitation, by token, for either a user that
        exists already

        or a user that is signing up concurrently with accepting the invitation.


        See examples stated for each case: existing user or new user. New users
        must send sign-up data

        or else a 400 response will be returned.


        The expiry date and status of invitation are validated before
        acceptance.
      operationId: organization_invitations_accept_create
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/InlineOrganizationInvitationAcceptRequest'
            examples:
              ForANewUser(signsUpANewUser):
                value:
                  token: e8e912b6-ba9b-4c3a-bb4f-d04bdc370843
                  user:
                    password: pwd
                    confirm_password: pwd
                    first_name: Fname
                    last_name: Lname
                summary: For a new user (signs up a new user)
              ForAnExistingUser:
                value:
                  token: e8e912b6-ba9b-4c3a-bb4f-d04bdc370843
                summary: For an existing user
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/InlineOrganizationInvitationAccept200Response
          description: ''
        '400':
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/InlineOrganizationInvitationAccept400Response
          description: ''
        '404':
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/InlineOrganizationInvitationAccept404Response
          description: ''
      security:
        - tokenAuth: []
        - {}
components:
  schemas:
    InlineOrganizationInvitationAcceptRequest:
      type: object
      properties:
        token:
          type: string
          format: uuid
      required:
        - token
    InlineOrganizationInvitationAccept200Response:
      type: object
      properties:
        status:
          type: string
          default: accepted
    InlineOrganizationInvitationAccept400Response:
      type: object
      properties:
        detail:
          type: string
          default: >-
            A user with the invited email does not exist in the system. To
            create a user, please pass user data with the request.
    InlineOrganizationInvitationAccept404Response:
      type: object
      properties:
        error:
          type: string
          default: Your invitation could not be found or has expired.
  securitySchemes:
    tokenAuth:
      type: http
      scheme: bearer

````