Sign inGet started

Cancel Number Subscription

"Cancel Number Subscription" API endpoint is deprecated, we suggest you to use . APIs to cancel the subscription. You can use numberId as endpointId parameter and use main as a subscription name to achieve identical behavior.
POST
/workspaces/{workspaceId}/numbers/{numberId}/cancel-subscription
Cancel Number Subscription
Corps de la réponse
type
string
The type of the number.
Possible values: local, national, tollfree, mobile, shortcode
capabilities
object
The capabilities of the number.
Afficher les attributs enfants
capabilities.sms
object
obligatoire
Afficher les attributs enfants
capabilities.sms.inbound
boolean
obligatoire
Whether the number supports inbound use cases.
capabilities.sms.outbound
boolean
obligatoire
Whether the number supports outbound use cases.
capabilities.voice
object
obligatoire
Afficher les attributs enfants
capabilities.voice.inbound
boolean
obligatoire
Whether the number supports inbound use cases.
capabilities.voice.outbound
boolean
obligatoire
Whether the number supports outbound use cases.
capabilities.mms
object
obligatoire
Afficher les attributs enfants
capabilities.mms.inbound
boolean
obligatoire
Whether the number supports inbound use cases.
capabilities.mms.outbound
boolean
obligatoire
Whether the number supports outbound use cases.
capabilities.fax
object
obligatoire
Afficher les attributs enfants
capabilities.fax.inbound
boolean
obligatoire
Whether the number supports inbound use cases.
capabilities.fax.outbound
boolean
obligatoire
Whether the number supports outbound use cases.
capabilities.whatsapp
object
Afficher les attributs enfants
capabilities.whatsapp.inbound
boolean
obligatoire
Whether the number supports inbound use cases.
capabilities.whatsapp.outbound
boolean
obligatoire
Whether the number supports outbound use cases.
number
string
The phone number in E.164 format.
country
string
monthlyRecurringPrice
object
Money combines an amount of money with its currency.
Afficher les attributs enfants
monthlyRecurringPrice.currencyCode
string
obligatoire
Currency as ISO 4217 code (three digits). An example would be EUR for Euro.
Possible values: EUR, USD, GBP, AUD, SGD, IDR, INR, MXN
monthlyRecurringPrice.amount
integer
obligatoire
monthlyRecurringPrice.exponent
integer
obligatoire
Usually a negative number to specify the exponent for decimal precision. e.g., 1540 * (10^-2) = 15.4
complianceRequirements
array of object
Afficher les attributs enfants
complianceRequirements.name
string
obligatoire
complianceRequirements.type
string
obligatoire
Possible values: kycForm, useCase, whatsappVerification
complianceRequirements.scope
string
obligatoire
Possible values: number-activation, sms-outbound, whatsapp
complianceRequirements.selector
object
Afficher les attributs enfants
complianceRequirements.selector.scope
string
obligatoire
complianceRequirements.selector.numberType
string
obligatoire
The type of the number.
Possible values: local, national, tollfree, mobile, shortcode
complianceRequirements.selector.countryCode
string
obligatoire
The country code in ISO 3166-1 alpha-2 format.
complianceRequirements.inventoryId
string
id
string
obligatoire
The ID of the number.
status
string
obligatoire
The status of the number.
Possible values: active, inactive
subscription
object
Describes status of Number Subscription
Afficher les attributs enfants
subscription.status
string
The status of the accounting subscription. It can be none, active, canceling, canceled, or planned.
Possible values: none, active, inactive, canceling, canceled, planned
subscription.subscribedAt
string
Timestamp (UTC) when the subscription became active.
subscription.updatedAt
string
Timestamp (UTC) when the subscription was last updated.
subscription.cancelledAt
string
Timestamp (UTC) when the subscription was cancelled.
endpointSubscription
object
Afficher les attributs enfants
endpointSubscription.id
string
obligatoire
The subscription unique identifier.
endpointSubscription.correlationId
string
obligatoire
The correlation links the subscription to its number. Hence, the correlationId is the numberId.
endpointSubscription.status
string
obligatoire
The status of the accounting subscription. It can be none, active, canceling, canceled, or planned.
Possible values: none, active, inactive, canceling, canceled, planned
endpointSubscription.subscribedAt
string
The date and time when the subscription was created.
endpointSubscription.updatedAt
string
endpointSubscription.canceledAt
string
The date and time when the subscription was canceled.
endpointSubscription.startAt
string
The date and time when the subscription should start.
endpointSubscription.endAt
string
The date and time when the subscription should end.
configurations
object
Afficher les attributs enfants
configurations.voice
object
Afficher les attributs enfants
configurations.voice.inbound
object
Afficher les attributs enfants
configurations.voice.inbound.connectorId
string
configurations.voice.inbound.connectorTemplateId
string
configurations.voice.inbound.connectorTemplateRef
string
configurations.voice.outbound
object
Afficher les attributs enfants
configurations.voice.outbound.connectorId
string
configurations.voice.outbound.connectorTemplateId
string
configurations.voice.outbound.connectorTemplateRef
string
configurations.sms
object
Afficher les attributs enfants
configurations.sms.inbound
object
Afficher les attributs enfants
configurations.sms.inbound.connectorId
string
configurations.sms.inbound.connectorTemplateId
string
configurations.sms.inbound.connectorTemplateRef
string
configurations.sms.outbound
object
Afficher les attributs enfants
configurations.sms.outbound.connectorId
string
configurations.sms.outbound.connectorTemplateId
string
configurations.sms.outbound.connectorTemplateRef
string
configurations.mms
object
Afficher les attributs enfants
configurations.mms.inbound
object
Afficher les attributs enfants
configurations.mms.inbound.connectorId
string
configurations.mms.inbound.connectorTemplateId
string
configurations.mms.inbound.connectorTemplateRef
string
configurations.mms.outbound
object
Afficher les attributs enfants
configurations.mms.outbound.connectorId
string
configurations.mms.outbound.connectorTemplateId
string
configurations.mms.outbound.connectorTemplateRef
string
configurations.fax
object
Afficher les attributs enfants
configurations.fax.inbound
object
Afficher les attributs enfants
configurations.fax.inbound.connectorId
string
configurations.fax.inbound.connectorTemplateId
string
configurations.fax.inbound.connectorTemplateRef
string
configurations.fax.outbound
object
Afficher les attributs enfants
configurations.fax.outbound.connectorId
string
configurations.fax.outbound.connectorTemplateId
string
configurations.fax.outbound.connectorTemplateRef
string
configurations.whatsapp
object
Afficher les attributs enfants
configurations.whatsapp.connectorId
string
configurations.whatsapp.connectorTemplateId
string
configurations.whatsapp.connectorTemplateRef
string
createdAt
string
obligatoire
Timestamp (UTC) when the number was created.
updatedAt
string
obligatoire
Timestamp (UTC) when the number was last updated.
activatedAt
string
Timestamp (UTC) of the last time the number was activated.
deactivatedAt
string
Timestamp (UTC) of the last time the number was deactivated.
deactivatesAt
string
Timestamp (UTC) when the number will be deactivated.
requirements
array of object
Afficher les attributs enfants
requirements.requirement
object
obligatoire
Compliance requirement for a number. It may be a KYC form, use case, or WhatsApp verification. In some cases, a destination may require multiple compliance requirements to be satisfied to be able to send traffic.
Afficher les attributs enfants
requirements.requirement.name
string
obligatoire
requirements.requirement.type
string
obligatoire
Possible values: kycForm, useCase, whatsappVerification
requirements.requirement.scope
string
obligatoire
Possible values: number-activation, sms-outbound, whatsapp
requirements.requirement.selector
object
Afficher les attributs enfants
requirements.requirement.selector.scope
string
obligatoire
requirements.requirement.selector.numberType
string
obligatoire
The type of the number.
Possible values: local, national, tollfree, mobile, shortcode
requirements.requirement.selector.countryCode
string
obligatoire
The country code in ISO 3166-1 alpha-2 format.
requirements.requirement.inventoryId
string
requirements.status
string
obligatoire
Possible values: ok, pending, not-valid, not-found, error, no-reference
requirements.reference
string
obligatoire
requirements.notOkSince
string
Timestamp (UTC) when the number didn't meet the requirement.
endpoint
object
A representation of an endpoint. It contains details such as the capabilities, dependencies, and more.
Afficher les attributs enfants
endpoint.id
string
obligatoire
The ID of the endpoint.
endpoint.type
string
obligatoire
The type of the endpoint. It can be a long code number, short code number, alpha number, ip pool, or rcs google agent.
Possible values: long-code-number, short-code-number, alpha-number, ip-pool, rcs-google-agent
endpoint.instanceId
string
obligatoire
The unique identifier of the instance.
endpoint.name
string
obligatoire
The name of the endpoint. For some cases it will be the number in international format as string.
endpoint.capabilities
array of object
obligatoire
Afficher les attributs enfants
endpoint.capabilities.name
string
obligatoire
Possible values: sms
endpoint.capabilities.inbound
object
Afficher les attributs enfants
endpoint.capabilities.inbound.status
string
obligatoire
Possible values: active, inactive, available, unavailable
endpoint.capabilities.inbound.issues
array of string
endpoint.capabilities.outbound
object
Afficher les attributs enfants
endpoint.capabilities.outbound.status
string
obligatoire
Possible values: active, inactive, available, unavailable
endpoint.capabilities.outbound.destinationStatuses
object
Afficher les attributs enfants
endpoint.capabilities.outbound.destinationStatuses.active
number
endpoint.capabilities.outbound.destinationStatuses.inactive
number
endpoint.capabilities.outbound.destinationStatuses.available
number
endpoint.capabilities.outbound.destinationStatuses.unavailable
number
endpoint.capabilities.outbound.supportsDestinations
boolean
Whether the number supports destinations
endpoint.capabilities.outbound.issues
array of string
endpoint.dependencies
array of object
The dependencies of the endpoint. It shows the connectors that the endpoint is connected to.
Afficher les attributs enfants
endpoint.dependencies.type
string
Possible values: connector
endpoint.dependencies.connectorId
string
obligatoire
endpoint.dependencies.connectorTemplateRef
string
obligatoire
endpoint.dependencies.capabilities
array of string
endpoint.issues
array of string
endpoint.provisioningStatus
string
obligatoire
Possible values: provisioned, provisioning, deprovisioned, deprovisioning
endpoint.whatsApp
object
WhatsApp pre-verification details for this endpoint, if applicable. Only present for long code numbers from WhatsApp-capable providers.
Afficher les attributs enfants
endpoint.whatsApp.whatsAppId
string
endpoint.whatsApp.status
string
WhatsApp number status
Possible values: unknown, already-exists, installed, verified, not-verified, expired
endpoint.whatsApp.stage
string
endpoint.whatsApp.attempt
integer
endpoint.whatsApp.nextAttemptAt
string
endpoint.whatsApp.verificationExpiresAt
string
endpoint.whatsApp.requestedCodeAt
string
endpoint.whatsApp.createdAt
string
endpoint.whatsApp.updatedAt
string
endpoint.createdAt
string
obligatoire
endpoint.updatedAt
string
obligatoire
whatsApp
object
WhatsApp number pre-verification details.
Afficher les attributs enfants
whatsApp.whatsAppId
string
whatsApp.status
string
WhatsApp number status
Possible values: unknown, already-exists, installed, verified, not-verified, expired
whatsApp.stage
string
whatsApp.attempt
integer
whatsApp.nextAttemptAt
string
whatsApp.verificationExpiresAt
string
whatsApp.requestedCodeAt
string
whatsApp.createdAt
string
whatsApp.updatedAt
string
Exemple de code
curl -X POST 'https://api.bird.com/workspaces/{workspaceId}/numbers/{numberId}/cancel-subscription' \
  -H 'Authorization: AccessKey YOUR_ACCESS_KEY'