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

# Delete Phone Number

> Deletes a phone number you brought to the account: a custom VoIP number, whose SIP resources are released, or a number imported from Twilio, which stays in your Twilio account. The number is removed from the live Pearls that use it: an outbound Pearl is paused, and an inbound Pearl is paused only when this was its last number. You receive an email listing the paused Pearls. A number purchased from NLPearl cannot be deleted through the API: delete it from the platform. The `phoneNumberId` is the `id` returned by Get Phone Numbers.



## OpenAPI

````yaml delete /v2/PhoneNumber/{phoneNumberId}
openapi: 3.0.1
info:
  title: NLPearl Client API
  description: A sample API that demonstrates features in the OpenAPI specification
  version: v2
servers:
  - url: https://api.nlpearl.ai
    description: Production Environement
security:
  - bearer_auth: []
  - oauth2_client_credentials: []
tags:
  - name: Pearl
    description: >-
      Manage your Pearls, the AI agents that handle your inbound and outbound
      calls. Create and configure Pearls, retrieve their details and settings,
      run or pause them, list and bulk-export their calls, monitor calls in
      progress, get analytics, and reset a customer's conversation memory.
paths:
  /v2/PhoneNumber/{phoneNumberId}:
    delete:
      tags:
        - PhoneNumber
      summary: Delete Phone Number
      description: >-
        Deletes a phone number you brought to the account: a custom VoIP number,
        whose SIP resources are released, or a number imported from Twilio,
        which stays in your Twilio account. The number is removed from the live
        Pearls that use it: an outbound Pearl is paused, and an inbound Pearl is
        paused only when this was its last number. You receive an email listing
        the paused Pearls. A number purchased from NLPearl cannot be deleted
        through the API: delete it from the platform. The `phoneNumberId` is the
        `id` returned by Get Phone Numbers.
      parameters:
        - name: phoneNumberId
          in: path
          required: true
          schema:
            type: string
      responses:
        '200':
          description: Returns a boolean indicating if the deletion was successful.
          content:
            text/plain:
              schema:
                type: boolean
            application/json:
              schema:
                type: boolean
            text/json:
              schema:
                type: boolean
        '400':
          description: Error
          content:
            text/plain:
              schema:
                $ref: '#/components/schemas/ValidationProblemDetails'
            application/json:
              schema:
                $ref: '#/components/schemas/ValidationProblemDetails'
            text/json:
              schema:
                $ref: '#/components/schemas/ValidationProblemDetails'
components:
  schemas:
    ValidationProblemDetails:
      type: object
      properties:
        type:
          type: string
          nullable: true
        title:
          type: string
          nullable: true
        status:
          type: integer
          format: int32
          nullable: true
        detail:
          type: string
          nullable: true
        instance:
          type: string
          nullable: true
        errors:
          type: object
          additionalProperties:
            type: array
            items:
              type: string
          nullable: true
      additionalProperties: {}
  securitySchemes:
    bearer_auth:
      type: http
      description: >-
        Specify the authorization token.


        For more information, check out the [Authorization
        Guide](/api-reference/authorization).
      scheme: bearer
    oauth2_client_credentials:
      type: oauth2
      description: >-
        OAuth2 client_credentials grant. Use the Id of an OAuth API key as
        `client_id` and its one-time secret as `client_secret`.
      flows:
        clientCredentials:
          tokenUrl: /oauth/token
          scopes:
            pearls:read: List and view Pearls
            pearls:write: >-
              Create and update Pearls (settings, conversation flows, voices);
              implies pearls:read
            pearls:moderate: Run/pause Pearls and reset customer memory; implies pearls:read
            pearls:analytics: Read Pearl analytics; implies pearls:read
            pearls:leads: Manage and read outbound leads; implies pearls:read
            pearls:calls: >-
              Read calls and recordings, make and delete calls; implies
              pearls:read
            account:phone_numbers: >-
              Read account phone numbers and text channels, manage custom VoIP
              numbers, import Twilio numbers and delete phone numbers
            account:users: Read account users
            account:advanced: Manage advanced account settings (blacklist)
            account:billing: Read account information and credit balance
            account:audit_log: Read the audit log
            tts: Synthesise speech and clone voices

````

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