# Retrieve an active phone number

Retrieve a specific active phone number.

Endpoint: GET /v1/projects/{projectId}/activeNumbers/{phoneNumber}
Version: 1.0.3
Security: Basic, OAuth2.0

## Security:

  - `Basic` (unknown)
    http basic

  - `OAuth2.0` (unknown)
    oauth2

## Path parameters:

  - `projectId` (string, required)
    Found on your [Sinch Customer Dashboard](https://dashboard.sinch.com/settings/project-management). Settings > Projects.

  - `phoneNumber` (string, required)
    Output only. The phone number in [E.164](https://community.sinch.com/t5/Glossary/E-164/ta-p/7537) format with leading `+`.

## Response 200:

  - `200` (unknown)
    A successful response, or an [Error](https://developers.sinch.com/docs/numbers/api-reference/error-codes/status-codes/).

## Response 200 fields (application/json):

  - `phoneNumber` (string)
    The phone number in [E.164](https://community.sinch.com/t5/Glossary/E-164/ta-p/7537) format with leading `+`. Example `+12025550134`.
    Example: +12025550134

  - `projectId` (string)
    Project ID. Your project ID can be found on your [Sinch Customer Dashboard](https://dashboard.sinch.com/settings/project-management).
    Example: 51bc3f40-f266-4ca8-8938-a1ed0ff32b9a

  - `displayName` (string)
    User supplied name for the phone number.

  - `regionCode` (string)
    ISO 3166-1 alpha-2 country code of the phone number. Example: US, GB or SE.
    Example: US

  - `type` (string)
    The number type.
    Enum: "LOCAL", "MOBILE", "TOLL_FREE"

  - `capability` (array)
    The capability of the number.
    Example: ["SMS"]

  - `money` (object)
    An object giving details on currency code and the amount charged.

  - `money.currencyCode` (string)
    The 3-letter currency code defined in [ISO 4217](https://www.iso.org/iso-4217-currency-codes.html).
    Example: USD

  - `money.amount` (string)
    The amount in decimal form.
For example `2.00`.
There are no guarantees on the precision unless documented by the message origin. The amount cannot be updated and is read-only.
    Example: 2.00

  - `paymentIntervalMonths` (integer)
    How often the recurring price is charged in months.

  - `nextChargeDate` (string)
    The date of the next charge.

  - `expireAt` (string)
    The timestamp when the subscription will expire if an expiration date has been set.

  - `smsConfiguration` (object)
    The current SMS configuration for this number.
Once the `servicePlanId` is sent, it enters scheduled provisioning.
The status of scheduled provisioning will show under a `scheduledProvisioning` object if it's still running. Once processed successfully, the `servicePlanId` sent will appear directly under the `smsConfiguration` object.

  - `smsConfiguration.servicePlanId` (string, required)
    The `servicePlanId` can be found in the [Sinch Customer Dashboard](https://dashboard.sinch.com/sms/api/rest). The service plan ID is what ties this number to the configured SMS service.

  - `smsConfiguration.campaignId` (string)
    Only for US phone numbers. This `campaignId` is required to send SMS traffic to US; click [here](https://community.sinch.com/t5/10DLC/What-is-10DLC/ta-p/7845) to read more about 10DLC A2P messaging. So, it is the current campaign ID for this number. The `campaignId` is found on your TCR platform.

  - `smsConfiguration.scheduledProvisioning` (object)
    Represents the ongoing or failed scheduled provisioning job. This field will be empty if the number was both successfully provisioned to the SMS platform and linked to the 10DLC campaign.

  - `smsConfiguration.scheduledProvisioning.servicePlanId` (string)
    The SMS service plan that the scheduled provisioning job will configure with the number.

  - `smsConfiguration.scheduledProvisioning.campaignId` (string)
    TCR campaign ID that the scheduled provisioning job will configure with the number.

  - `smsConfiguration.scheduledProvisioning.status` (string)
    The provisioning status. It will be either `WAITING`, `IN_PROGRESS` or `FAILED`. If the provisioning fails, a reason for the failure will be provided. [See a full list of provisioning error descriptions]<(https://developers.sinch.com/docs/numbers/api-reference/error-codes/provisioning-errors) and troubleshooting recommendations.
    Enum: "PROVISIONING_STATUS_UNSPECIFIED", "WAITING", "IN_PROGRESS", "FAILED"

  - `smsConfiguration.scheduledProvisioning.lastUpdatedTime` (string)
    Timestamp when the status was last updated.

  - `smsConfiguration.scheduledProvisioning.errorCodes` (array)

  - `voiceConfiguration` (object)
    The current voice configuration for this number. During scheduled provisioning, the app ID, service ID, or trunk ID value may be empty in a response if it is still processing or if it has failed. The status of scheduled provisioning will show under a `scheduledVoiceProvisioning` object if it's still running. Once processed successfully, the `appId`/`serviceId`/`trunkId` sent will appear directly under the `voiceConfiguration` object.

  - `voiceConfiguration.type` (string)
    The voice application type. Examples are RTC, EST, FAX
    Enum: "RTC", "EST", "FAX"

  - `voiceConfiguration.lastUpdatedTime` (string)
    Timestamp when the status was last updated.

  - `voiceConfiguration.scheduledVoiceProvisioning` (object)
    Represents the ongoing or failed scheduled voice provisioning job. This field will be empty if the number was successfully provisioned provisioned for voice.

  - `voiceConfiguration.scheduledVoiceProvisioning.trunkId` (string)
    The trunk ID if the type is EST. The `trunkId` can be found in your [Sinch Customer Dashboard](https://dashboard.sinch.com/trunks/your-trunks).

  - `voiceConfiguration.scheduledVoiceProvisioning.serviceId` (string)
    The service ID if the type is FAX. The `serviceId` can be found in your [Sinch Customer Dashboard](https://dashboard.sinch.com/fax/services).

  - `voiceConfiguration.appId` (string)
    Your app ID for the Voice API. The `appId` can be found in your [Sinch Customer Dashboard](https://dashboard.sinch.com/voice/apps).

  - `callbackUrl` (string)
    The callback URL to be called for a rented number's provisioning / deprovisioning operations.
    Example: https://www.your-callback-server.com/callback

## Response 400:

  - `400` (unknown)
    400 Invalid Argument error

## Response 400 fields (application/json):

  - `error` (object)

  - `error.code` (integer)
    Enum: "400"

  - `error.message` (string)

  - `error.status` (string)
    Enum: "INVALID_ARGUMENT"

  - `error.details` (array)

  - `error.details.type` (string)
    Enum: "BadRequest"

  - `error.details.fieldViolations` (array)

  - `error.details.fieldViolations.field` (string)

  - `error.details.fieldViolations.description` (string)

## Response 404:

  - `404` (unknown)
    404 Not Found error

## Response 404 fields (application/json):

  - `error` (object)

  - `error.code` (integer)
    Enum: "404"

  - `error.message` (string)

  - `error.status` (string)
    Enum: "NOT_FOUND"

  - `error.details` (array)

  - `error.details.type` (string)

  - `error.details.resourceType` (string)
    The type of the resource that was not found.

  - `error.details.resourceName` (string)
    The name of the resource that was not found.

  - `error.details.owner` (string)
    The owner of the resource that was not found.

  - `error.details.description` (string)
    A description of the error.

## Response 500:

  - `500` (unknown)
    500 Internal Server error

## Response 500 fields (application/json):

  - `error` (object)

  - `error.code` (integer)
    Enum: "500"

  - `error.message` (string)

  - `error.status` (string)
    Enum: "INTERNAL", "UNKNOWN"

  - `error.details` (array)

## Response 200 examples:

  - `Response for activing a number with both SMS and Voice configuration` (unknown)

  - `Response for activing a number with SMS configuration` (unknown)

  - `Response for activing a number with Voice configuration` (unknown)

  - `Response for activing a number with Elastic SIP Trunking configuration` (unknown)

  - `Response for activing a number with Fax configuration` (unknown)

