Skip to main content
WEBHOOK
Fires when a phone number is imported into Surge from an external provider, such as through porting or hosting. The event includes the number’s ID, E.164 format, type, and any campaign attachment details available at import time. Imported numbers are not necessarily ready for production messaging yet. If a campaign is associated with the number, check data.campaign.attachment_status. When attachment completes, Surge fires phone_number.attached_to_campaign instead.

Common use case

Use phone_number.imported to update your own records when a ported or hosted number becomes available in Surge, for example, to notify a customer that their import finished or to start tracking campaign attachment for that number.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
account_id
string
required

The ID of the account in which this event occurred

data
object
required

The data associated with the event

timestamp
string<date-time>
required

The timestamp when this event occurred, in ISO8601 format

type
string
required

The type of the event. Always phone_number.imported for this event.

Allowed value: "phone_number.imported"

Response

200

Return a 200 status to indicate that the data was received successfully