---
title: "Assign Phone Number"
method: PATCH
path: "/restapi/v2/accounts/{accountId}/phone-numbers/{phoneNumberId}"
tags: ["Phone Numbers"]
---

# Assign Phone Number

`PATCH /restapi/v2/accounts/{accountId}/phone-numbers/{phoneNumberId}`

Assigns or reassigns a phone number as a company or extension number.

Assign scenarios supported:
- from Inventory to a company number;
- from Inventory to an extension number.

Reassign scenarios supported:
- from an extension to another extension;
- from an extension to a company number;
- from a company number to an extension.

## Path parameters

- `accountId` string, required
- `phoneNumberId` string, required — Internal unique identifier of a phone number

## Request body

- AssignPhoneNumberRequest
  - `type` 'VoiceFax' | 'VoiceOnly' | 'FaxOnly', nullable — Type of phone number
  - `usageType` 'MainCompanyNumber' | 'CompanyNumber' | 'DirectNumber' | 'PhoneLine', required — Target usage type of phone number (only listed values are supported)
  - `extension` object
    - `id` string, required — Internal identifier of an extension
  - `costCenterId` string

## Response `200`

Successful response

- AccountPhoneNumberInfo
  - `id` string, required — Internal unique identifier of a phone number
  - `phoneNumber` string, required — Phone number in e.164 format (with '+' prefix)
  - `type` 'VoiceFax' | 'VoiceOnly' | 'FaxOnly', nullable — Type of phone number
  - `tollType` 'Toll' | 'TollFree', required — Indicates if a number is toll or toll-free
  - `usageType` 'MainCompanyNumber' | 'DirectNumber' | 'Inventory' | 'InventoryPartnerBusinessMobileNumber' | 'PartnerBusinessMobileNumber' | 'AdditionalCompanyNumber' | 'CompanyNumber' | 'PhoneLine' | 'CompanyFaxNumber' | 'ForwardedNumber' | 'ForwardedCompanyNumber' | 'ContactCenterNumber' | 'ConferencingNumber' | 'MeetingsNumber' | 'BusinessMobileNumber' | 'ELIN', required — Usage type of phone number
  - `byocNumber` boolean
  - `status` 'Normal' | 'Pending' | 'PortedIn' | 'Temporary' | 'Unknown', required — Status of a phone number. If the value is 'Normal', the phone number is ready to be used. Otherwise, it is an external number not yet ported to RingCentral
  - `extension` object — Reference to the extension this number is assigned to. Omitted for company numbers
    - `id` string, required — Unique identifier of extension
    - `extensionNumber` string — Short number of an extension. Actual max length depends on system length limit for extension.

## Other responses

- `400` — General response with **HTTP 400 "Bad request"** status.<br> Reasons: unparsable request, path, query or body parameters are invalid. The error description may contain reference to particular parameter(s) which haven't passed the validation.
- `403` — General response with **HTTP 403 "Forbidden"** status.<br> Reasons: the requested operation is forbidden because of certain resource state, lack of permissions, feature unavailability, etc.
- `404` — General response with **HTTP 404 "Not found"** status.<br> Reasons: the entity with given ID (typically specified in a path parameter), is not found or inaccessible
- `429` — General response with **HTTP 429 "Too many requests"** status.<br> Reasons: certain rate limit is exceeded.
- `500` — General response with **HTTP 500 "Internal Server Error"** status.<br> Reasons: general server-side error.
- `503` — General response with **HTTP 503 "Service not available"** status.<br> Reasons: server cannot process the request because of being overloaded, misconfiguration or other issues.

---

[API](https://skmtc.net/ringcentral/apis/ringcentral-api.md) · [All operations](https://skmtc.net/ringcentral/apis/ringcentral-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/ringcentral/ringcentral-api/versions/8d602198ec97/schema)
