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

# Detach from gateways

> Detaches the number from its gateways. The number stays on your account. Use [Release a phone number](/api-reference/phone-numbers/release-a-phone-number) to give it up.



## OpenAPI

````yaml /api-reference/rest/openapi.yaml post /v2/sip/phone-numbers/detach
openapi: 3.1.0
info:
  title: Zero Runtime REST API
  version: '1.0'
  description: >-
    Create, configure, version and deploy agents, and wire SIP telephony to
    them.
servers:
  - url: https://api.zeroruntime.ai
security:
  - token: []
tags:
  - name: Agents
  - name: Versions
  - name: Deployment
  - name: Phone numbers
  - name: Routing rules
  - name: Calls
  - name: Batch calls
  - name: Knowledge bases
  - name: Knowledge base folders
paths:
  /v2/sip/phone-numbers/detach:
    post:
      tags:
        - Phone numbers
      summary: Detach from gateways
      description: >-
        Detaches the number from its gateways. The number stays on your account.
        Use [Release a phone
        number](/api-reference/phone-numbers/release-a-phone-number) to give it
        up.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - phoneNumber
              properties:
                phoneNumber:
                  type: string
                  example: '+14155550100'
      responses:
        '200':
          description: Detached.
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
                    example: Detached successfully
                  phoneNumber:
                    $ref: '#/components/schemas/PhoneNumber'
                  inbound:
                    type:
                      - string
                      - 'null'
                    description: The inbound gateway it left.
                  outbound:
                    type:
                      - string
                      - 'null'
                    description: The outbound gateway it left.
        '400':
          description: The number isn't attached to any gateway.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Message'
components:
  schemas:
    PhoneNumber:
      type: object
      properties:
        phoneNumberId:
          type: string
        e164:
          type: string
          example: '+14155550100'
        countryCode:
          type: string
          example: US
        provider:
          type: string
          example: other
        origin:
          type: string
          example: SIP Configured
        status:
          type: string
          example: ACTIVE
        name:
          type: string
          example: Support SIP
        createdAt:
          type: string
          format: date-time
        updatedAt:
          type: string
          format: date-time
    Message:
      type: object
      properties:
        message:
          type: string
  securitySchemes:
    token:
      type: apiKey
      in: header
      name: Authorization
      description: Your API token, sent raw (no `Bearer` prefix).
      x-default: <auth-token>

````

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