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

# Disconnect Carrier Account

> Deletes the saved key. If Yappr created the Call Control App, Yappr deletes it
from your Telnyx account too (`telnyx_connection_deleted`). Yappr never deletes
your API key: delete it in Telnyx yourself. Remove the account's numbers first.
Requires `carrier_accounts:manage`.


Deletes the saved API key. Requires `carrier_accounts:manage`.
[Remove the account's numbers](/api-reference/carrier-accounts/remove-number) first:
campaigns and agents may still use them (`409 CARRIER_ACCOUNT_HAS_NUMBERS`).

```bash theme={null}
curl -X DELETE https://api.goyappr.com/carrier-accounts/7c1e… \
  -H "Authorization: Bearer ypr_live_..."
```

```json theme={null}
{ "success": true, "id": "7c1e…", "telnyx_connection_deleted": true }
```

If Yappr created the Call Control App for you, Yappr deletes it from your Telnyx
account too and reports it in `telnyx_connection_deleted` (`null` when the app was
yours). Yappr never deletes your API key: delete it in Telnyx yourself.


## OpenAPI

````yaml DELETE /carrier-accounts/{id}
openapi: 3.1.0
info:
  title: Yappr API
  description: >
    Create and manage AI voice agents, purchase phone numbers, configure tools,
    and initiate calls — all via REST.
  version: 1.0.0
  contact:
    url: https://goyappr.com
servers:
  - url: https://api.goyappr.com
    description: Production
security:
  - apiKey: []
paths:
  /carrier-accounts/{id}:
    parameters:
      - in: path
        name: id
        required: true
        schema:
          type: string
          format: uuid
    delete:
      tags:
        - Carrier Accounts
      summary: Disconnect carrier account
      description: >
        Deletes the saved key. If Yappr created the Call Control App, Yappr
        deletes it

        from your Telnyx account too (`telnyx_connection_deleted`). Yappr never
        deletes

        your API key: delete it in Telnyx yourself. Remove the account's numbers
        first.

        Requires `carrier_accounts:manage`.
      operationId: deleteCarrierAccount
      responses:
        '200':
          description: Disconnected
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                  id:
                    type: string
                    format: uuid
                  telnyx_connection_deleted:
                    type: boolean
                    nullable: true
                    description: '`null` when Yappr did not create the app.'
        '403':
          $ref: '#/components/responses/CarrierAccountsNotEnabled'
        '404':
          description: '`CARRIER_ACCOUNT_NOT_FOUND` — not in this workspace.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '409':
          description: '`CARRIER_ACCOUNT_HAS_NUMBERS` — remove its numbers first.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  responses:
    CarrierAccountsNotEnabled:
      description: >
        `CARRIER_ACCOUNTS_NOT_ENABLED` — Yappr has switched calling out through
        your own

        Telnyx account off for this workspace. It is available in every
        workspace, so this

        is only the emergency-off answer; contact Yappr support. Every
        carrier-accounts

        route answers this while it is off (check with

        [GET /carrier-accounts/status](/api-reference/carrier-accounts/status)).
        An API key

        without the route's scope gets a 403 of its own.
      content:
        application/json:
          schema:
            allOf:
              - $ref: '#/components/schemas/Error'
              - type: object
                properties:
                  enabled:
                    type: boolean
                    example: false
          example:
            error: >-
              Calling out through your own Telnyx account is switched off for
              this workspace. Contact Yappr support.
            code: CARRIER_ACCOUNTS_NOT_ENABLED
            enabled: false
  schemas:
    Error:
      type: object
      properties:
        error:
          type: string
        code:
          type: string
  securitySchemes:
    apiKey:
      type: http
      scheme: bearer
      bearerFormat: API Key
      description: >-
        Your Yappr API key (e.g. `ypr_live_...`). Generate one in the dashboard
        under **Settings → API Keys**.

````