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

# Delete organization user

> Deletes a user in your organization.



## OpenAPI

````yaml https://telnyx-openapi-ng.s3.us-east-1.amazonaws.com/account-billing/managed-accounts.yml post /organizations/users/{id}/actions/remove
openapi: 3.1.0
info:
  title: Telnyx Managed Accounts API
  version: 2.0.0
  description: API for Managed accounts.
  contact:
    email: support@telnyx.com
servers:
  - url: https://api.telnyx.com/v2
security:
  - bearerAuth: []
paths:
  /organizations/users/{id}/actions/remove:
    post:
      tags:
        - Organization Users
      summary: Delete organization user
      description: Deletes a user in your organization.
      operationId: DeleteOrganizationUser
      parameters:
        - name: id
          in: path
          description: Organization User ID
          required: true
          schema:
            type: string
      responses:
        '200':
          $ref: '#/components/responses/OrganizationUserResponse'
        '400':
          $ref: '#/components/responses/users_BadRequestResponse'
        '401':
          $ref: '#/components/responses/UnauthenticatedResponse'
        '403':
          $ref: '#/components/responses/users_UnauthorizedResponse'
        '404':
          $ref: '#/components/responses/users_NotFoundResponse'
      x-codeSamples:
        - lang: JavaScript
          source: >-
            import Telnyx from 'telnyx';


            const client = new Telnyx({
              apiKey: process.env['TELNYX_API_KEY'], // This is the default and can be omitted
            });


            const action = await
            client.organizations.users.actions.remove('id');


            console.log(action.data);
        - lang: Python
          source: |-
            import os
            from telnyx import Telnyx

            client = Telnyx(
                api_key=os.environ.get("TELNYX_API_KEY"),  # This is the default and can be omitted
            )
            action = client.organizations.users.actions.remove(
                "id",
            )
            print(action.data)
        - lang: Go
          source: "package main\n\nimport (\n\t\"context\"\n\t\"fmt\"\n\n\t\"github.com/team-telnyx/telnyx-go\"\n\t\"github.com/team-telnyx/telnyx-go/option\"\n)\n\nfunc main() {\n\tclient := telnyx.NewClient(\n\t\toption.WithAPIKey(\"My API Key\"),\n\t)\n\taction, err := client.Organizations.Users.Actions.Remove(context.TODO(), \"id\")\n\tif err != nil {\n\t\tpanic(err.Error())\n\t}\n\tfmt.Printf(\"%+v\\n\", action.Data)\n}\n"
        - lang: Java
          source: >-
            package com.telnyx.sdk.example;


            import com.telnyx.sdk.client.TelnyxClient;

            import com.telnyx.sdk.client.okhttp.TelnyxOkHttpClient;

            import
            com.telnyx.sdk.models.organizations.users.actions.ActionRemoveParams;

            import
            com.telnyx.sdk.models.organizations.users.actions.ActionRemoveResponse;


            public final class Main {
                private Main() {}

                public static void main(String[] args) {
                    TelnyxClient client = TelnyxOkHttpClient.fromEnv();

                    ActionRemoveResponse action = client.organizations().users().actions().remove("id");
                }
            }
        - lang: Ruby
          source: |-
            require "telnyx"

            telnyx = Telnyx::Client.new(api_key: "My API Key")

            action = telnyx.organizations.users.actions.remove("id")

            puts(action)
        - lang: CLI
          source: |-
            telnyx organizations:users:actions remove \
              --api-key 'My API Key' \
              --id id
components:
  responses:
    OrganizationUserResponse:
      description: Successful response with details about an Organization User.
      content:
        application/json:
          schema:
            type: object
            title: Organization User Response
            properties:
              data:
                $ref: '#/components/schemas/OrganizationUser'
    users_BadRequestResponse:
      description: >-
        Bad request, the request was unacceptable, often due to missing a
        required parameter.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            missingParameter:
              value:
                errors:
                  - code: '10015'
                    title: Bad Request
                    detail: The request failed because it was not well-formed.
                    source:
                      pointer: /
                    meta:
                      url: https://developers.telnyx.com/docs/overview/errors/10015
    UnauthenticatedResponse:
      description: Unauthorized
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            Authentication Failed:
              value:
                errors:
                  - code: '10009'
                    title: Authentication failed
                    detail: Could not understand the provided credentials.
                    meta:
                      url: https://developers.telnyx.com/docs/overview/errors/10009
    users_UnauthorizedResponse:
      description: >-
        The user doesn't have the required permissions to perform the requested
        action.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            notAuthorized:
              value:
                errors:
                  - code: '10010'
                    title: Not authorized
                    detail: You are not authorized to access the requested resource.
                    meta:
                      url: https://developers.telnyx.com/docs/overview/errors/10010
                    source:
                      pointer: /
    users_NotFoundResponse:
      description: The requested resource doesn't exist.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            notFound:
              value:
                errors:
                  - code: '10005'
                    title: Resource not found
                    detail: The requested resource or URL could not be found.
                    meta:
                      url: https://developers.telnyx.com/docs/overview/errors/10005
                    source:
                      pointer: /
  schemas:
    OrganizationUser:
      type: object
      title: OrganizationUser
      properties:
        id:
          type: string
          description: Identifies the specific resource.
          example: 6a09cdc3-8948-47f0-aa62-74ac943d6c58
        record_type:
          type: string
          description: >-
            Identifies the type of the resource. Can be 'organization_owner' or
            'organization_sub_user'.
          example: organization_sub_user
        email:
          type: string
          format: email
          description: The email address of the user.
          example: user@example.com
        user_status:
          description: The status of the account.
          type: string
          enum:
            - enabled
            - disabled
            - blocked
          default: enabled
          example: enabled
        organization_user_bypasses_sso:
          type: boolean
          description: >-
            Indicates whether this user is allowed to bypass SSO and use
            password authentication.
          example: false
        created_at:
          type: string
          description: ISO 8601 formatted date indicating when the resource was created.
          example: '2018-02-02T22:25:27.521Z'
        last_sign_in_at:
          type:
            - string
            - 'null'
          description: >-
            ISO 8601 formatted date indicating when the resource last signed
            into the portal. Null if the user has never signed in.
          example: '2018-02-02T22:25:27.521Z'
        groups:
          type: array
          description: >-
            The groups the user belongs to. Only included when include_groups
            parameter is true.
          items:
            $ref: '#/components/schemas/UserGroupReference'
      example:
        id: 6a09cdc3-8948-47f0-aa62-74ac943d6c58
        record_type: organization_sub_user
        email: user@example.com
        user_status: enabled
        organization_user_bypasses_sso: false
        created_at: '2018-02-02T22:25:27.521Z'
        last_sign_in_at: '2018-02-02T22:25:27.521Z'
    ErrorResponse:
      type: object
      properties:
        errors:
          type: array
          items:
            type: object
            properties:
              code:
                type: string
              detail:
                type: string
              meta:
                type: object
                properties:
                  url:
                    type: string
                    format: uri
              title:
                type: string
              source:
                type: object
                properties:
                  pointer:
                    type: string
    UserGroupReference:
      type: object
      title: UserGroupReference
      description: A reference to a group that a user belongs to.
      properties:
        id:
          type: string
          description: The unique identifier of the group.
          example: 7b09cdc3-8948-47f0-aa62-74ac943d6c59
        name:
          type: string
          description: The name of the group.
          example: Engineering
      required:
        - id
        - name
      example:
        id: 7b09cdc3-8948-47f0-aa62-74ac943d6c59
        name: Engineering
  securitySchemes:
    bearerAuth:
      scheme: bearer
      type: http

````