API reference

Phone numbers

Provision and manage Canadian phone numbers.

get/v1/phone-numbers/area-codes

List provinces and their active area codes

Requires phone_numbers:r.

Responses

  • 200Provinces with their active area codes.
    FieldTypeDescription
    data[]requiredobject[]
    provincerequiredstring
    countryrequiredstring
    area_codesrequiredstring[]
  • 401Missing, invalid, revoked or expired API key.The standard error body.
  • 402The account has no balance, or a LIVE key was used before the first top-up.The standard error body.
  • 403The API key lacks the permission this operation requires, or the account is suspended or closed.The standard error body.
  • 429Rate limit reached: 100 requests per second per account, or a route-specific limit (Retry-After set where one applies).The standard error body.
  • 500Unexpected server error.The standard error body.

Example

const { data, error } = await honkio.phoneNumbers.areaCodes()
if (error) throw new Error(error.message)
console.log(data.data)
get/v1/phone-numbers

List account's provisioned phone numbers

Permissionphone_numbers:rNode.js SDKhonkio.phoneNumbers.list()

Requires phone_numbers:r.

Responses

  • 200The account's numbers, excluding released ones, newest first. Not paginated.
    FieldTypeDescription
    data[]requiredobject[]
    idrequiredstring
    phone_numberrequiredstring

    E.164

    area_coderequiredstring
    regionrequiredstring

    Province or territory, when the area code maps to one.

    • Can be null
    capabilitiesrequiredstring[]
    statusrequiredstring
    • One of: ACTIVE | SUSPENDED | RELEASING | RELEASED
    monthly_cost_centsrequiredinteger

    Recurring rent in CAD cents.

    provisioned_atrequiredstring
    • Format: date-time
    released_atrequiredstring
    • Format: date-time
    • Can be null
    number_typerequiredstring

    Toll-free numbers (833, 844, 855, 866, 877, 888) need an approved toll-free verification before they can send SMS.

    • One of: local | toll_free
    toll_free_verificationrequiredobject

    The newest toll-free verification application for this number, cancelled ones aside. Null for a local number or a toll-free number never applied for.

    • Can be null
    idrequiredstring

    tfv_…

    statusrequiredstring

    The number sends SMS once this is APPROVED.

    • One of: DRAFT | AWAITING_PAYMENT | IN_REVIEW | CHANGES_REQUESTED | SUBMITTED | APPROVED | REJECTED | DECLINED
  • 401Missing, invalid, revoked or expired API key.The standard error body.
  • 402The account has no balance, or a LIVE key was used before the first top-up.The standard error body.
  • 403The API key lacks the permission this operation requires, or the account is suspended or closed.The standard error body.
  • 429Rate limit reached: 100 requests per second per account, or a route-specific limit (Retry-After set where one applies).The standard error body.
  • 500Unexpected server error.The standard error body.

Example

const { data, error } = await honkio.phoneNumbers.list()
if (error) throw new Error(error.message)
for (const n of data.data) console.log(n.phone_number, n.status)
post/v1/phone-numbers

Provision (purchase) a phone number

Provisions a number and debits its first month's rent plus a one-time activation fee, as one purchase (see GET /v1/pricing for both amounts; the activation fee is the same on every tier and is not refunded on release). A balance that cannot cover the total returns 402 INSUFFICIENT_BALANCE, and rent owed on a number released while suspended returns 402 RENT_OWED, before anything is charged or ordered. Accounts are capped on how many phone numbers they may hold at once (counting ACTIVE and SUSPENDED), a per-account limit that falls back to a platform-wide default staff can change at runtime; exceeding it returns 403 NUMBER_LIMIT_REACHED with the limit and current usage in details. Request a higher allowance from the dashboard. May also return 409 PURCHASE_IN_PROGRESS when another purchase for this account is already in flight: this is transient, unlike the terminal 409 CONFLICT returned when the number is already owned; retry PURCHASE_IN_PROGRESS after a short delay rather than treating it as a failed purchase.

Requires phone_numbers:w.

Request body

FieldTypeDescription
phone_numberrequiredstring

E.164 number to provision (from available search)

Responses

  • 201The provisioned number.
    FieldTypeDescription
    idrequiredstring
    phone_numberrequiredstring

    E.164

    area_coderequiredstring
    regionrequiredstring

    Province or territory, when the area code maps to one.

    • Can be null
    capabilitiesrequiredstring[]
    statusrequiredstring
    • One of: ACTIVE | SUSPENDED | RELEASING | RELEASED
    monthly_cost_centsrequiredinteger

    Recurring rent in CAD cents.

    provisioned_atrequiredstring
    • Format: date-time
    released_atrequiredstring
    • Format: date-time
    • Can be null
    number_typerequiredstring

    Toll-free numbers (833, 844, 855, 866, 877, 888) need an approved toll-free verification before they can send SMS.

    • One of: local | toll_free
    toll_free_verificationrequiredobject

    The newest toll-free verification application for this number, cancelled ones aside. Null for a local number or a toll-free number never applied for.

    • Can be null
    idrequiredstring

    tfv_…

    statusrequiredstring

    The number sends SMS once this is APPROVED.

    • One of: DRAFT | AWAITING_PAYMENT | IN_REVIEW | CHANGES_REQUESTED | SUBMITTED | APPROVED | REJECTED | DECLINED
  • 401Missing, invalid, revoked or expired API key.The standard error body.
  • 402INSUFFICIENT_BALANCE: the balance cannot cover the first month and the activation fee. RENT_OWED: rent is owed on a number released while suspended; top up to pay it first. Nothing was charged or ordered.The standard error body.
  • 403NUMBER_LIMIT_REACHED (details carries limit and used), LIVE_KEY_REQUIRED (test keys cannot provision), or ACCOUNT_NOT_VERIFIED (the account has not verified an owner mobile number).The standard error body.
  • 409CONFLICT (the number is already owned), PURCHASE_IN_PROGRESS (another purchase for this account is in flight; retry shortly), or COMPED_TOLL_FREE (toll-free numbers are not available on this account).The standard error body.
  • 422NON_CANADIAN_NUMBER or VALIDATION_ERROR.The standard error body.
  • 429Rate limit reached: 100 requests per second per account, or a route-specific limit (Retry-After set where one applies).The standard error body.
  • 500INTERNAL_ERROR: the charge failed for a reason other than balance.The standard error body.
  • 501TOLLFREE_800_COMING_SOON: 1-800 numbers are not offered yet.The standard error body.
  • 502PROVISIONING_FAILED: the carrier did not provision the number. The charge is refunded.The standard error body.

Example

const { data: number, error } = await honkio.phoneNumbers.provision({ phoneNumber: '+1416XXXXXXX' })
if (error) throw new Error(error.message)
console.log(number.id, number.status)
get/v1/phone-numbers/{id}

Get a phone number by ID

Permissionphone_numbers:rNode.js SDKhonkio.phoneNumbers.get()

Requires phone_numbers:r.

Parameters

ParameterTypeDescription
idrequiredpathstring

Responses

  • 200The number, released ones included.
    FieldTypeDescription
    idrequiredstring
    phone_numberrequiredstring

    E.164

    area_coderequiredstring
    regionrequiredstring

    Province or territory, when the area code maps to one.

    • Can be null
    capabilitiesrequiredstring[]
    statusrequiredstring
    • One of: ACTIVE | SUSPENDED | RELEASING | RELEASED
    monthly_cost_centsrequiredinteger

    Recurring rent in CAD cents.

    provisioned_atrequiredstring
    • Format: date-time
    released_atrequiredstring
    • Format: date-time
    • Can be null
    number_typerequiredstring

    Toll-free numbers (833, 844, 855, 866, 877, 888) need an approved toll-free verification before they can send SMS.

    • One of: local | toll_free
    toll_free_verificationrequiredobject

    The newest toll-free verification application for this number, cancelled ones aside. Null for a local number or a toll-free number never applied for.

    • Can be null
    idrequiredstring

    tfv_…

    statusrequiredstring

    The number sends SMS once this is APPROVED.

    • One of: DRAFT | AWAITING_PAYMENT | IN_REVIEW | CHANGES_REQUESTED | SUBMITTED | APPROVED | REJECTED | DECLINED
  • 401Missing, invalid, revoked or expired API key.The standard error body.
  • 402The account has no balance, or a LIVE key was used before the first top-up.The standard error body.
  • 403The API key lacks the permission this operation requires, or the account is suspended or closed.The standard error body.
  • 404NOT_FOUND: no such resource on this account.The standard error body.
  • 429Rate limit reached: 100 requests per second per account, or a route-specific limit (Retry-After set where one applies).The standard error body.
  • 500Unexpected server error.The standard error body.

Example

const { data, error } = await honkio.phoneNumbers.get('NUMBER_ID')
if (error) throw new Error(error.message)
console.log(data.phone_number, data.status)
delete/v1/phone-numbers/{id}

Release (cancel) a phone number

Releases the number at the carrier and answers 204, also when the carrier had already let it go. If the carrier does not accept the release, answers 502 RELEASE_FAILED and the number stays yours, unchanged; try again. Releasing a SUSPENDED number leaves one month of its rent owed (rent_owed_cents on the account): until a top-up pays it, paid sends and number purchases are refused with 402 RENT_OWED.

Requires phone_numbers:d.

Parameters

ParameterTypeDescription
idrequiredpathstring

Responses

  • 204Released, or already released at the carrier.
  • 401Missing, invalid, revoked or expired API key.The standard error body.
  • 402The account has no balance, or a LIVE key was used before the first top-up.The standard error body.
  • 403LIVE_KEY_REQUIRED: test keys cannot reach live resources here. Also FORBIDDEN when the key lacks the permission this operation requires, or the account is suspended or closed.The standard error body.
  • 404NOT_FOUND: no such number on this account, or it is already released.The standard error body.
  • 429Rate limit reached: 100 requests per second per account, or a route-specific limit (Retry-After set where one applies).The standard error body.
  • 500Unexpected server error.The standard error body.
  • 502RELEASE_FAILED: the carrier did not accept the release. The number stays yours, unchanged; try again.The standard error body.

Example

const { error } = await honkio.phoneNumbers.release('NUMBER_ID')
if (error) throw new Error(error.message)
get/v1/phone-numbers/allowance-requests

List your phone number allowance requests

Permissionphone_numbers:r

Requires phone_numbers:r.

Responses

  • 200The account's allowance requests, newest first.
    FieldTypeDescription
    data[]requiredobject[]
    idrequiredstring
    requested_limitrequiredinteger

    Total numbers asked for, not an increment.

    limit_at_requestrequiredinteger
    held_at_requestrequiredinteger
    reasonrequiredstring
    statusrequiredstring
    • One of: PENDING | APPROVED | DENIED
    granted_limitrequiredinteger
    • Can be null
    staff_noterequiredstring
    • Can be null
    decided_atrequiredstring
    • Format: date-time
    • Can be null
    created_atrequiredstring
    • Format: date-time
  • 401Missing, invalid, revoked or expired API key.The standard error body.
  • 402The account has no balance, or a LIVE key was used before the first top-up.The standard error body.
  • 403The API key lacks the permission this operation requires, or the account is suspended or closed.The standard error body.
  • 429Rate limit reached: 100 requests per second per account, or a route-specific limit (Retry-After set where one applies).The standard error body.
  • 500Unexpected server error.The standard error body.

Example

cURL
curl https://api.honkio.ca/v1/phone-numbers/allowance-requests \
  -H "Authorization: Bearer mk_live_YOUR_KEY"
post/v1/phone-numbers/allowance-requests

Request a higher phone number allowance

Permissionphone_numbers:w

Needs a verified business (BUSINESS_VERIFICATION_REQUIRED until then; see /v1/business-verification). Files a request for HonkIO staff to review. Only one request may be pending at a time. Approval raises the account limit; you are emailed when that happens.

Requires phone_numbers:w.

Request body

FieldTypeDescription
requested_limitrequiredinteger

Total numbers you want to be able to hold (not an increment)

  • Minimum: 2
  • Maximum: 100
reasonrequiredstring

What you need them for. Staff decide on this.

  • At least 10 characters
  • At most 1000 characters

Responses

  • 201The request, pending review.
    FieldTypeDescription
    idrequiredstring
    requested_limitrequiredinteger

    Total numbers asked for, not an increment.

    limit_at_requestrequiredinteger
    held_at_requestrequiredinteger
    reasonrequiredstring
    statusrequiredstring
    • One of: PENDING | APPROVED | DENIED
    granted_limitrequiredinteger
    • Can be null
    staff_noterequiredstring
    • Can be null
    decided_atrequiredstring
    • Format: date-time
    • Can be null
    created_atrequiredstring
    • Format: date-time
  • 401Missing, invalid, revoked or expired API key.The standard error body.
  • 402The account has no balance, or a LIVE key was used before the first top-up.The standard error body.
  • 403BUSINESS_VERIFICATION_REQUIRED: verify your business first (PUT /v1/business-verification, then submit it). Also LIVE_KEY_REQUIRED for a test key, or FORBIDDEN when the key lacks the permission this operation requires.The standard error body.
  • 409ALLOWANCE_REQUEST_PENDING: a request is already pending.The standard error body.
  • 422VALIDATION_ERROR, or INVALID_ALLOWANCE_REQUEST when requested_limit is not above the current limit.The standard error body.
  • 429RATE_LIMITED: 3 requests per day per account.The standard error body.
  • 500Unexpected server error.The standard error body.

Example

cURL
curl -X POST https://api.honkio.ca/v1/phone-numbers/allowance-requests \
  -H "Authorization: Bearer mk_live_YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "requested_limit": 2,
    "reason": "..."
  }'
get/v1/toll-free-verifications/options

List toll-free verification options

The values an application's use_case, monthly_volume, entity_type and business_address.province take, each with an English and French label, and the verification fee.

Requires phone_numbers:r.

Responses

  • 200The option lists and the fee.
    FieldTypeDescription
    use_cases[]requiredobject[]
    valuerequiredstring
    label_enrequiredstring
    label_frrequiredstring
    monthly_volumes[]requiredobject[]
    valuerequiredstring
    label_enrequiredstring
    label_frrequiredstring
    entity_types[]requiredobject[]
    valuerequiredstring
    label_enrequiredstring
    label_frrequiredstring
    provinces[]requiredobject[]
    valuerequiredstring
    label_enrequiredstring
    label_frrequiredstring
    fee_centsrequiredinteger

    The verification fee, in cents CAD, charged once per application.

  • 401Missing, invalid, revoked or expired API key.The standard error body.
  • 402The account has no balance, or a LIVE key was used before the first top-up.The standard error body.
  • 403The API key lacks the permission this operation requires, or the account is suspended or closed.The standard error body.
  • 429Rate limit reached: 100 requests per second per account, or a route-specific limit (Retry-After set where one applies).The standard error body.
  • 500Unexpected server error.The standard error body.

Example

const { data: options, error } = await honkio.tollFreeVerifications.options()
if (error) throw new Error(error.message)
for (const u of options.use_cases) console.log(u.value, u.label_en)
console.log(options.fee_cents)
get/v1/toll-free-verifications

List toll-free verification applications

The account's applications, newest first, cancelled ones included. Not paginated.

Requires phone_numbers:r.

Parameters

ParameterTypeDescription
statusquerystring

Only applications in this status.

  • One of: DRAFT | AWAITING_PAYMENT | IN_REVIEW | CHANGES_REQUESTED | SUBMITTED | APPROVED | REJECTED | DECLINED | CANCELLED

Responses

  • 200The account's applications, newest first.
    FieldTypeDescription
    data[]requiredobject[]
    idrequiredstring
    statusrequiredstring

    DRAFT, then AWAITING_PAYMENT, IN_REVIEW (HonkIO staff), SUBMITTED (with the carrier) and APPROVED. CHANGES_REQUESTED and REJECTED (by the carrier) can be edited and submitted again, and a REJECTED one can be withdrawn (CANCELLED); DECLINED (by HonkIO) and CANCELLED are final.

    • One of: DRAFT | AWAITING_PAYMENT | IN_REVIEW | CHANGES_REQUESTED | SUBMITTED | APPROVED | REJECTED | DECLINED | CANCELLED
    phone_numbers[]requiredobject[]
    idrequiredstring
    phone_numberrequiredstring
    applicationrequiredobject

    The application as stored: every field, with the business number, postal code and phone normalized.

    business_namerequiredstring
    doing_business_asrequiredstring
    • Can be null
    entity_typerequiredstring
    • One of: SOLE_PROPRIETOR | PRIVATE_PROFIT | PUBLIC_PROFIT | NON_PROFIT | GOVERNMENT
    business_registration_numberrequiredstring
    business_addressrequiredobject
    line1requiredstring
    cityrequiredstring
    provincerequiredstring
    postal_coderequiredstring
    contactrequiredobject
    first_namerequiredstring
    last_namerequiredstring
    emailrequiredstring
    phonerequiredstring
    websiterequiredstring
    use_caserequiredstring
    • One of: 2FA | App Notifications | Appointments | Auctions | Auto Repair Services | Bank Transfers | Billing | Booking Confirmations | Business Updates | COVID-19 Alerts | Career Training | Chatbot | Conversational / Alerts | Courier Services & Deliveries | Emergency Alerts | Events & Planning | Financial Services | Fraud Alerts | Fundraising | General Marketing | General School Updates | HR / Staffing | Healthcare Alerts | Housing Community Updates | Insurance Services | Job Dispatch | Legal Services | Mixed | Motivational Reminders | Notary Notifications | Order Notifications | Political | Public Works | Real Estate Services | Religious Services | Repair and Diagnostics Alerts | Rewards Program | Surveys | System Alerts | Voting Reminders | Waitlist Alerts | Webinar Reminders | Workshop Alerts
    use_case_summaryrequiredstring
    sample_messagesrequiredstring[]
    opt_in_workflowrequiredstring
    opt_in_image_urlsrequiredstring[]
    opt_in_confirmation_messagerequiredstring
    help_messagerequiredstring
    privacy_policy_urlrequiredstring
    terms_urlrequiredstring
    • Can be null
    monthly_volumerequiredstring
    • One of: 10 | 100 | 1,000 | 10,000 | 100,000 | 250,000 | 500,000 | 750,000 | 1,000,000 | 5,000,000 | 10,000,000+
    age_gatedrequiredboolean
    additional_informationrequiredstring
    • Can be null
    fee_centsrequiredinteger

    The verification fee for this application, in cents CAD.

    payment_urlrequiredstring

    While AWAITING_PAYMENT: the dashboard page where the fee is paid. Null otherwise.

    • Can be null
    paid_atrequiredstring
    • Format: date-time
    • Can be null
    refunded_atrequiredstring
    • Format: date-time
    • Can be null
    reviewer_noterequiredstring

    What HonkIO staff asked to change, or why they declined the application.

    • Can be null
    carrier_statusrequiredstring

    Where the carrier's review stands once it has the application: pending, action_needed (the carrier asked HonkIO a question; nothing for you to do yet), approved or rejected. Null before it is submitted.

    • One of: pending | action_needed | approved | rejected
    • Can be null
    carrier_rejection_reasonrequiredstring

    Why the carrier rejected the application, when it did.

    • Can be null
    submitted_atrequiredstring
    • Format: date-time
    • Can be null
    decided_atrequiredstring

    When the carrier approved or rejected it.

    • Format: date-time
    • Can be null
    created_atrequiredstring
    • Format: date-time
    updated_atrequiredstring
    • Format: date-time
  • 401Missing, invalid, revoked or expired API key.The standard error body.
  • 402The account has no balance, or a LIVE key was used before the first top-up.The standard error body.
  • 403The API key lacks the permission this operation requires, or the account is suspended or closed.The standard error body.
  • 429Rate limit reached: 100 requests per second per account, or a route-specific limit (Retry-After set where one applies).The standard error body.
  • 500Unexpected server error.The standard error body.

Example

const { data, error } = await honkio.tollFreeVerifications.list({ status: 'CHANGES_REQUESTED' })
if (error) throw new Error(error.message)
for (const v of data.data) console.log(v.id, v.reviewer_note)
post/v1/toll-free-verifications

Create a toll-free verification application

Toll-free numbers can send SMS only once verified. This creates a DRAFT application for up to 5 of your toll-free numbers; submit it to pay the verification fee and send it for review. Live keys only.

Requires phone_numbers:w.

Request body

The numbers to verify and the application for them.

FieldTypeDescription
phone_number_idsrequiredstring[]

The ids of 1 to 5 of your toll-free numbers (GET /v1/phone-numbers). A number can be on only one open application.

applicationrequiredobject

The application. Every field is checked when you create it.

business_namerequiredstring

The legal name of the business, as registered with the Canada Revenue Agency.

  • At least 1 characters
  • At most 255 characters
doing_business_asstring

The name the business trades under, when it differs from the legal name.

  • At most 255 characters
  • Can be null
entity_typerequiredstring

The kind of organization. GET /v1/toll-free-verifications/options lists the values with labels.

  • One of: SOLE_PROPRIETOR | PRIVATE_PROFIT | PUBLIC_PROFIT | NON_PROFIT | GOVERNMENT
business_registration_numberrequiredstring

The CRA business number: 9 digits, optionally followed by a program account such as RC0001. Spaces and hyphens are ignored.

  • At most 40 characters
business_registration_typestring

Optional. Always CRA: only Canadian businesses can apply.

  • One of: CRA
business_registration_countrystring

Optional. Always CA.

  • One of: CA
business_addressrequiredobject

The registered address of the business, in Canada.

line1requiredstring
  • At least 1 characters
  • At most 255 characters
cityrequiredstring
  • At least 1 characters
  • At most 100 characters
provincerequiredstring

Two-letter province or territory code.

  • One of: AB | BC | MB | NB | NL | NS | NT | NU | ON | PE | QC | SK | YT
postal_coderequiredstring

Canadian postal code, e.g. K1A 0B1.

  • At most 10 characters
contactrequiredobject

The person the carrier and HonkIO staff can contact about this application.

first_namerequiredstring
  • At least 1 characters
  • At most 100 characters
last_namerequiredstring
  • At least 1 characters
  • At most 100 characters
emailrequiredstring
  • Format: email
  • At most 254 characters
phonerequiredstring

A North American phone number, e.g. +14165550100.

  • At most 32 characters
websiterequiredstring

The business website (https). Reviewers check that it matches the business.

  • At most 2048 characters
use_caserequiredstring

What the messages are for. GET /v1/toll-free-verifications/options lists the values with labels.

  • One of: 2FA | App Notifications | Appointments | Auctions | Auto Repair Services | Bank Transfers | Billing | Booking Confirmations | Business Updates | COVID-19 Alerts | Career Training | Chatbot | Conversational / Alerts | Courier Services & Deliveries | Emergency Alerts | Events & Planning | Financial Services | Fraud Alerts | Fundraising | General Marketing | General School Updates | HR / Staffing | Healthcare Alerts | Housing Community Updates | Insurance Services | Job Dispatch | Legal Services | Mixed | Motivational Reminders | Notary Notifications | Order Notifications | Political | Public Works | Real Estate Services | Religious Services | Repair and Diagnostics Alerts | Rewards Program | Surveys | System Alerts | Voting Reminders | Waitlist Alerts | Webinar Reminders | Workshop Alerts
use_case_summaryrequiredstring

A few sentences on what you send, to whom, and why they expect it.

  • At least 10 characters
  • At most 2000 characters
sample_messagesrequiredstring[]

1 to 5 messages exactly as you will send them, at most 1000 characters together. At least one must tell the recipient how to opt out (STOP, or ARRET in French).

opt_in_workflowrequiredstring

How recipients agree to receive your messages: where, how, and what they are told.

  • At least 10 characters
  • At most 2000 characters
opt_in_image_urlsrequiredstring[]

1 to 5 https links to screenshots or photos of the opt-in (a web form, a paper form, a checkout box). The carrier requires at least one.

opt_in_confirmation_messagerequiredstring

The message a recipient gets right after opting in.

  • At least 1 characters
  • At most 1000 characters
help_messagerequiredstring

The reply to HELP: who you are and how to reach you.

  • At least 1 characters
  • At most 1000 characters
privacy_policy_urlrequiredstring

Your privacy policy (https).

  • At most 2048 characters
terms_urlstring

Your terms of service (https), if you have them.

  • At most 2048 characters
  • Can be null
monthly_volumerequiredstring

The number of messages you expect to send a month. GET /v1/toll-free-verifications/options lists the values with labels.

  • One of: 10 | 100 | 1,000 | 10,000 | 100,000 | 250,000 | 500,000 | 750,000 | 1,000,000 | 5,000,000 | 10,000,000+
age_gatedboolean

True when the messages are about age-restricted products such as alcohol or cannabis.

additional_informationstring

Anything else the reviewers should know.

  • At most 2000 characters
  • Can be null

Responses

  • 201The application, in DRAFT.
    FieldTypeDescription
    idrequiredstring
    statusrequiredstring

    DRAFT, then AWAITING_PAYMENT, IN_REVIEW (HonkIO staff), SUBMITTED (with the carrier) and APPROVED. CHANGES_REQUESTED and REJECTED (by the carrier) can be edited and submitted again, and a REJECTED one can be withdrawn (CANCELLED); DECLINED (by HonkIO) and CANCELLED are final.

    • One of: DRAFT | AWAITING_PAYMENT | IN_REVIEW | CHANGES_REQUESTED | SUBMITTED | APPROVED | REJECTED | DECLINED | CANCELLED
    phone_numbers[]requiredobject[]
    idrequiredstring
    phone_numberrequiredstring
    applicationrequiredobject

    The application as stored: every field, with the business number, postal code and phone normalized.

    business_namerequiredstring
    doing_business_asrequiredstring
    • Can be null
    entity_typerequiredstring
    • One of: SOLE_PROPRIETOR | PRIVATE_PROFIT | PUBLIC_PROFIT | NON_PROFIT | GOVERNMENT
    business_registration_numberrequiredstring
    business_addressrequiredobject
    line1requiredstring
    cityrequiredstring
    provincerequiredstring
    postal_coderequiredstring
    contactrequiredobject
    first_namerequiredstring
    last_namerequiredstring
    emailrequiredstring
    phonerequiredstring
    websiterequiredstring
    use_caserequiredstring
    • One of: 2FA | App Notifications | Appointments | Auctions | Auto Repair Services | Bank Transfers | Billing | Booking Confirmations | Business Updates | COVID-19 Alerts | Career Training | Chatbot | Conversational / Alerts | Courier Services & Deliveries | Emergency Alerts | Events & Planning | Financial Services | Fraud Alerts | Fundraising | General Marketing | General School Updates | HR / Staffing | Healthcare Alerts | Housing Community Updates | Insurance Services | Job Dispatch | Legal Services | Mixed | Motivational Reminders | Notary Notifications | Order Notifications | Political | Public Works | Real Estate Services | Religious Services | Repair and Diagnostics Alerts | Rewards Program | Surveys | System Alerts | Voting Reminders | Waitlist Alerts | Webinar Reminders | Workshop Alerts
    use_case_summaryrequiredstring
    sample_messagesrequiredstring[]
    opt_in_workflowrequiredstring
    opt_in_image_urlsrequiredstring[]
    opt_in_confirmation_messagerequiredstring
    help_messagerequiredstring
    privacy_policy_urlrequiredstring
    terms_urlrequiredstring
    • Can be null
    monthly_volumerequiredstring
    • One of: 10 | 100 | 1,000 | 10,000 | 100,000 | 250,000 | 500,000 | 750,000 | 1,000,000 | 5,000,000 | 10,000,000+
    age_gatedrequiredboolean
    additional_informationrequiredstring
    • Can be null
    fee_centsrequiredinteger

    The verification fee for this application, in cents CAD.

    payment_urlrequiredstring

    While AWAITING_PAYMENT: the dashboard page where the fee is paid. Null otherwise.

    • Can be null
    paid_atrequiredstring
    • Format: date-time
    • Can be null
    refunded_atrequiredstring
    • Format: date-time
    • Can be null
    reviewer_noterequiredstring

    What HonkIO staff asked to change, or why they declined the application.

    • Can be null
    carrier_statusrequiredstring

    Where the carrier's review stands once it has the application: pending, action_needed (the carrier asked HonkIO a question; nothing for you to do yet), approved or rejected. Null before it is submitted.

    • One of: pending | action_needed | approved | rejected
    • Can be null
    carrier_rejection_reasonrequiredstring

    Why the carrier rejected the application, when it did.

    • Can be null
    submitted_atrequiredstring
    • Format: date-time
    • Can be null
    decided_atrequiredstring

    When the carrier approved or rejected it.

    • Format: date-time
    • Can be null
    created_atrequiredstring
    • Format: date-time
    updated_atrequiredstring
    • Format: date-time
  • 401Missing, invalid, revoked or expired API key.The standard error body.
  • 402The account has no balance, or a LIVE key was used before the first top-up.The standard error body.
  • 403The API key lacks the permission this operation requires, or the account is suspended or closed.The standard error body.
  • 409NUMBER_IN_OPEN_VERIFICATION: a number is already on another open application (details.phone_number_id).The standard error body.
  • 422VALIDATION_ERROR (details names the fields), NOT_A_TOLL_FREE_NUMBER (a number is not one of your toll-free numbers; details.phone_number_id), or LIVE_MODE_REQUIRED for a test key.The standard error body.
  • 429RATE_LIMITED: 10 new applications per day per account.The standard error body.
  • 500Unexpected server error.The standard error body.

Example

const { data: application, error } = await honkio.tollFreeVerifications.create({
  phoneNumberIds: ['NUMBER_ID'], // your toll-free numbers, 1 to 5
  application: {
    businessName: 'Acme Clinics Inc.',
    entityType: 'PRIVATE_PROFIT',
    businessRegistrationNumber: '123456789RC0001',
    businessAddress: { line1: '100 King St W', city: 'Toronto', province: 'ON', postalCode: 'M5X 1A9' },
    contact: { firstName: 'Ada', lastName: 'Lovelace', email: 'ada@acme.ca', phone: '+1416XXXXXXX' },
    website: 'https://acme.ca',
    useCase: 'Appointments',
    useCaseSummary: 'Appointment reminders for our patients.',
    sampleMessages: ['Acme Clinics: your appointment is tomorrow at 2 pm. Reply STOP to opt out.'],
    optInWorkflow: 'Patients tick an unchecked SMS box on the booking form.',
    optInImageUrls: ['https://acme.ca/img/booking-form-sms-box.png'],
    optInConfirmationMessage: 'Acme Clinics: you are subscribed to appointment texts. Reply STOP to opt out.',
    helpMessage: 'Acme Clinics: visit acme.ca/help. Reply STOP to opt out.',
    privacyPolicyUrl: 'https://acme.ca/privacy',
    monthlyVolume: '10,000',
  },
})
if (error) throw new Error(`${error.name}: ${error.message}`)
console.log(application.id, application.status) // 'DRAFT'
get/v1/toll-free-verifications/{id}

Get a toll-free verification application

The application, its numbers, its status and, when staff asked for changes or declined it, their note.

Requires phone_numbers:r.

Parameters

ParameterTypeDescription
idrequiredpathstring

Responses

  • 200The application.
    FieldTypeDescription
    idrequiredstring
    statusrequiredstring

    DRAFT, then AWAITING_PAYMENT, IN_REVIEW (HonkIO staff), SUBMITTED (with the carrier) and APPROVED. CHANGES_REQUESTED and REJECTED (by the carrier) can be edited and submitted again, and a REJECTED one can be withdrawn (CANCELLED); DECLINED (by HonkIO) and CANCELLED are final.

    • One of: DRAFT | AWAITING_PAYMENT | IN_REVIEW | CHANGES_REQUESTED | SUBMITTED | APPROVED | REJECTED | DECLINED | CANCELLED
    phone_numbers[]requiredobject[]
    idrequiredstring
    phone_numberrequiredstring
    applicationrequiredobject

    The application as stored: every field, with the business number, postal code and phone normalized.

    business_namerequiredstring
    doing_business_asrequiredstring
    • Can be null
    entity_typerequiredstring
    • One of: SOLE_PROPRIETOR | PRIVATE_PROFIT | PUBLIC_PROFIT | NON_PROFIT | GOVERNMENT
    business_registration_numberrequiredstring
    business_addressrequiredobject
    line1requiredstring
    cityrequiredstring
    provincerequiredstring
    postal_coderequiredstring
    contactrequiredobject
    first_namerequiredstring
    last_namerequiredstring
    emailrequiredstring
    phonerequiredstring
    websiterequiredstring
    use_caserequiredstring
    • One of: 2FA | App Notifications | Appointments | Auctions | Auto Repair Services | Bank Transfers | Billing | Booking Confirmations | Business Updates | COVID-19 Alerts | Career Training | Chatbot | Conversational / Alerts | Courier Services & Deliveries | Emergency Alerts | Events & Planning | Financial Services | Fraud Alerts | Fundraising | General Marketing | General School Updates | HR / Staffing | Healthcare Alerts | Housing Community Updates | Insurance Services | Job Dispatch | Legal Services | Mixed | Motivational Reminders | Notary Notifications | Order Notifications | Political | Public Works | Real Estate Services | Religious Services | Repair and Diagnostics Alerts | Rewards Program | Surveys | System Alerts | Voting Reminders | Waitlist Alerts | Webinar Reminders | Workshop Alerts
    use_case_summaryrequiredstring
    sample_messagesrequiredstring[]
    opt_in_workflowrequiredstring
    opt_in_image_urlsrequiredstring[]
    opt_in_confirmation_messagerequiredstring
    help_messagerequiredstring
    privacy_policy_urlrequiredstring
    terms_urlrequiredstring
    • Can be null
    monthly_volumerequiredstring
    • One of: 10 | 100 | 1,000 | 10,000 | 100,000 | 250,000 | 500,000 | 750,000 | 1,000,000 | 5,000,000 | 10,000,000+
    age_gatedrequiredboolean
    additional_informationrequiredstring
    • Can be null
    fee_centsrequiredinteger

    The verification fee for this application, in cents CAD.

    payment_urlrequiredstring

    While AWAITING_PAYMENT: the dashboard page where the fee is paid. Null otherwise.

    • Can be null
    paid_atrequiredstring
    • Format: date-time
    • Can be null
    refunded_atrequiredstring
    • Format: date-time
    • Can be null
    reviewer_noterequiredstring

    What HonkIO staff asked to change, or why they declined the application.

    • Can be null
    carrier_statusrequiredstring

    Where the carrier's review stands once it has the application: pending, action_needed (the carrier asked HonkIO a question; nothing for you to do yet), approved or rejected. Null before it is submitted.

    • One of: pending | action_needed | approved | rejected
    • Can be null
    carrier_rejection_reasonrequiredstring

    Why the carrier rejected the application, when it did.

    • Can be null
    submitted_atrequiredstring
    • Format: date-time
    • Can be null
    decided_atrequiredstring

    When the carrier approved or rejected it.

    • Format: date-time
    • Can be null
    created_atrequiredstring
    • Format: date-time
    updated_atrequiredstring
    • Format: date-time
  • 401Missing, invalid, revoked or expired API key.The standard error body.
  • 402The account has no balance, or a LIVE key was used before the first top-up.The standard error body.
  • 403The API key lacks the permission this operation requires, or the account is suspended or closed.The standard error body.
  • 404NOT_FOUND: no such resource on this account.The standard error body.
  • 429Rate limit reached: 100 requests per second per account, or a route-specific limit (Retry-After set where one applies).The standard error body.
  • 500Unexpected server error.The standard error body.

Example

const { data, error } = await honkio.tollFreeVerifications.get('VERIFICATION_ID')
if (error) throw new Error(error.message)
console.log(data.status, data.reviewer_note, data.carrier_rejection_reason)
patch/v1/toll-free-verifications/{id}

Update a toll-free verification application

Edits an application in DRAFT, CHANGES_REQUESTED or REJECTED. Its status does not change: submit it again when you are done. Live keys only.

Requires phone_numbers:m.

Parameters

ParameterTypeDescription
idrequiredpathstring

Request body

The fields to change. Application fields you send replace the stored ones (an address or contact is replaced whole); the result must still be a complete, valid application.

FieldTypeDescription
phone_number_idsstring[]

Replaces the numbers on the application: 1 to 5 of your toll-free numbers.

applicationobject

Any of the application's fields.

business_namestring
  • At least 1 characters
  • At most 255 characters
doing_business_asstring
  • At most 255 characters
  • Can be null
entity_typestring
  • One of: SOLE_PROPRIETOR | PRIVATE_PROFIT | PUBLIC_PROFIT | NON_PROFIT | GOVERNMENT
business_registration_numberstring
  • At most 40 characters
business_registration_typestring
  • One of: CRA
business_registration_countrystring
  • One of: CA
business_addressobject
line1requiredstring
  • At least 1 characters
  • At most 255 characters
cityrequiredstring
  • At least 1 characters
  • At most 100 characters
provincerequiredstring
  • One of: AB | BC | MB | NB | NL | NS | NT | NU | ON | PE | QC | SK | YT
postal_coderequiredstring
  • At most 10 characters
contactobject
first_namerequiredstring
  • At least 1 characters
  • At most 100 characters
last_namerequiredstring
  • At least 1 characters
  • At most 100 characters
emailrequiredstring
  • Format: email
  • At most 254 characters
phonerequiredstring
  • At most 32 characters
websitestring
  • At most 2048 characters
use_casestring
  • One of: 2FA | App Notifications | Appointments | Auctions | Auto Repair Services | Bank Transfers | Billing | Booking Confirmations | Business Updates | COVID-19 Alerts | Career Training | Chatbot | Conversational / Alerts | Courier Services & Deliveries | Emergency Alerts | Events & Planning | Financial Services | Fraud Alerts | Fundraising | General Marketing | General School Updates | HR / Staffing | Healthcare Alerts | Housing Community Updates | Insurance Services | Job Dispatch | Legal Services | Mixed | Motivational Reminders | Notary Notifications | Order Notifications | Political | Public Works | Real Estate Services | Religious Services | Repair and Diagnostics Alerts | Rewards Program | Surveys | System Alerts | Voting Reminders | Waitlist Alerts | Webinar Reminders | Workshop Alerts
use_case_summarystring
  • At least 10 characters
  • At most 2000 characters
sample_messagesstring[]
opt_in_workflowstring
  • At least 10 characters
  • At most 2000 characters
opt_in_image_urlsstring[]
opt_in_confirmation_messagestring
  • At least 1 characters
  • At most 1000 characters
help_messagestring
  • At least 1 characters
  • At most 1000 characters
privacy_policy_urlstring
  • At most 2048 characters
terms_urlstring
  • At most 2048 characters
  • Can be null
monthly_volumestring
  • One of: 10 | 100 | 1,000 | 10,000 | 100,000 | 250,000 | 500,000 | 750,000 | 1,000,000 | 5,000,000 | 10,000,000+
age_gatedboolean
additional_informationstring
  • At most 2000 characters
  • Can be null

Responses

  • 200The edited application.
    FieldTypeDescription
    idrequiredstring
    statusrequiredstring

    DRAFT, then AWAITING_PAYMENT, IN_REVIEW (HonkIO staff), SUBMITTED (with the carrier) and APPROVED. CHANGES_REQUESTED and REJECTED (by the carrier) can be edited and submitted again, and a REJECTED one can be withdrawn (CANCELLED); DECLINED (by HonkIO) and CANCELLED are final.

    • One of: DRAFT | AWAITING_PAYMENT | IN_REVIEW | CHANGES_REQUESTED | SUBMITTED | APPROVED | REJECTED | DECLINED | CANCELLED
    phone_numbers[]requiredobject[]
    idrequiredstring
    phone_numberrequiredstring
    applicationrequiredobject

    The application as stored: every field, with the business number, postal code and phone normalized.

    business_namerequiredstring
    doing_business_asrequiredstring
    • Can be null
    entity_typerequiredstring
    • One of: SOLE_PROPRIETOR | PRIVATE_PROFIT | PUBLIC_PROFIT | NON_PROFIT | GOVERNMENT
    business_registration_numberrequiredstring
    business_addressrequiredobject
    line1requiredstring
    cityrequiredstring
    provincerequiredstring
    postal_coderequiredstring
    contactrequiredobject
    first_namerequiredstring
    last_namerequiredstring
    emailrequiredstring
    phonerequiredstring
    websiterequiredstring
    use_caserequiredstring
    • One of: 2FA | App Notifications | Appointments | Auctions | Auto Repair Services | Bank Transfers | Billing | Booking Confirmations | Business Updates | COVID-19 Alerts | Career Training | Chatbot | Conversational / Alerts | Courier Services & Deliveries | Emergency Alerts | Events & Planning | Financial Services | Fraud Alerts | Fundraising | General Marketing | General School Updates | HR / Staffing | Healthcare Alerts | Housing Community Updates | Insurance Services | Job Dispatch | Legal Services | Mixed | Motivational Reminders | Notary Notifications | Order Notifications | Political | Public Works | Real Estate Services | Religious Services | Repair and Diagnostics Alerts | Rewards Program | Surveys | System Alerts | Voting Reminders | Waitlist Alerts | Webinar Reminders | Workshop Alerts
    use_case_summaryrequiredstring
    sample_messagesrequiredstring[]
    opt_in_workflowrequiredstring
    opt_in_image_urlsrequiredstring[]
    opt_in_confirmation_messagerequiredstring
    help_messagerequiredstring
    privacy_policy_urlrequiredstring
    terms_urlrequiredstring
    • Can be null
    monthly_volumerequiredstring
    • One of: 10 | 100 | 1,000 | 10,000 | 100,000 | 250,000 | 500,000 | 750,000 | 1,000,000 | 5,000,000 | 10,000,000+
    age_gatedrequiredboolean
    additional_informationrequiredstring
    • Can be null
    fee_centsrequiredinteger

    The verification fee for this application, in cents CAD.

    payment_urlrequiredstring

    While AWAITING_PAYMENT: the dashboard page where the fee is paid. Null otherwise.

    • Can be null
    paid_atrequiredstring
    • Format: date-time
    • Can be null
    refunded_atrequiredstring
    • Format: date-time
    • Can be null
    reviewer_noterequiredstring

    What HonkIO staff asked to change, or why they declined the application.

    • Can be null
    carrier_statusrequiredstring

    Where the carrier's review stands once it has the application: pending, action_needed (the carrier asked HonkIO a question; nothing for you to do yet), approved or rejected. Null before it is submitted.

    • One of: pending | action_needed | approved | rejected
    • Can be null
    carrier_rejection_reasonrequiredstring

    Why the carrier rejected the application, when it did.

    • Can be null
    submitted_atrequiredstring
    • Format: date-time
    • Can be null
    decided_atrequiredstring

    When the carrier approved or rejected it.

    • Format: date-time
    • Can be null
    created_atrequiredstring
    • Format: date-time
    updated_atrequiredstring
    • Format: date-time
  • 401Missing, invalid, revoked or expired API key.The standard error body.
  • 402The account has no balance, or a LIVE key was used before the first top-up.The standard error body.
  • 403The API key lacks the permission this operation requires, or the account is suspended or closed.The standard error body.
  • 404NOT_FOUND: no such resource on this account.The standard error body.
  • 409VERIFICATION_NOT_EDITABLE (not in DRAFT, CHANGES_REQUESTED or REJECTED) or NUMBER_IN_OPEN_VERIFICATION.The standard error body.
  • 422VALIDATION_ERROR, NOT_A_TOLL_FREE_NUMBER, or LIVE_MODE_REQUIRED for a test key.The standard error body.
  • 429Rate limit reached: 100 requests per second per account, or a route-specific limit (Retry-After set where one applies).The standard error body.
  • 500Unexpected server error.The standard error body.

Example

const { error } = await honkio.tollFreeVerifications.update('VERIFICATION_ID', {
  application: { optInImageUrls: ['https://acme.ca/img/booking-form-v2.png'] },
})
if (error) throw new Error(error.message)
delete/v1/toll-free-verifications/{id}

Cancel or withdraw a toll-free verification application

Cancels an application in DRAFT or AWAITING_PAYMENT, or withdraws one the carrier REJECTED, and frees its numbers for another application. A withdrawn application's fee is not refunded; an application in review or with the carrier cannot be cancelled. Once the payment page has been opened, cancel from the dashboard instead (VERIFICATION_NOT_EDITABLE, reason checkout_started), so the open payment can be closed first. Live keys only.

Requires phone_numbers:d.

Parameters

ParameterTypeDescription
idrequiredpathstring

Responses

  • 204Cancelled.
  • 401Missing, invalid, revoked or expired API key.The standard error body.
  • 402The account has no balance, or a LIVE key was used before the first top-up.The standard error body.
  • 403The API key lacks the permission this operation requires, or the account is suspended or closed.The standard error body.
  • 404NOT_FOUND: no such resource on this account.The standard error body.
  • 409VERIFICATION_NOT_EDITABLE: only DRAFT and AWAITING_PAYMENT applications can be cancelled.The standard error body.
  • 422LIVE_MODE_REQUIRED for a test key.The standard error body.
  • 429Rate limit reached: 100 requests per second per account, or a route-specific limit (Retry-After set where one applies).The standard error body.
  • 500Unexpected server error.The standard error body.

Example

const { error } = await honkio.tollFreeVerifications.cancel('VERIFICATION_ID')
if (error) throw new Error(error.message)
post/v1/toll-free-verifications/{id}/submit

Submit a toll-free verification application

From DRAFT: moves the application to AWAITING_PAYMENT and returns payment_url, the dashboard page where the verification fee is paid; once paid it goes to HonkIO staff for review. From CHANGES_REQUESTED or REJECTED: sends the edited application back for review, at no charge. Live keys only (LIVE_MODE_REQUIRED). Needs a verified business with a CRA business number on its profile (BUSINESS_VERIFICATION_REQUIRED, or BUSINESS_NUMBER_REQUIRED when the business as HonkIO verified it has none; see verified_details on /v1/business-verification).

Requires phone_numbers:w.

Parameters

ParameterTypeDescription
idrequiredpathstring

Responses

  • 200The application, AWAITING_PAYMENT with payment_url, or back IN_REVIEW.
    FieldTypeDescription
    idrequiredstring
    statusrequiredstring

    DRAFT, then AWAITING_PAYMENT, IN_REVIEW (HonkIO staff), SUBMITTED (with the carrier) and APPROVED. CHANGES_REQUESTED and REJECTED (by the carrier) can be edited and submitted again, and a REJECTED one can be withdrawn (CANCELLED); DECLINED (by HonkIO) and CANCELLED are final.

    • One of: DRAFT | AWAITING_PAYMENT | IN_REVIEW | CHANGES_REQUESTED | SUBMITTED | APPROVED | REJECTED | DECLINED | CANCELLED
    phone_numbers[]requiredobject[]
    idrequiredstring
    phone_numberrequiredstring
    applicationrequiredobject

    The application as stored: every field, with the business number, postal code and phone normalized.

    business_namerequiredstring
    doing_business_asrequiredstring
    • Can be null
    entity_typerequiredstring
    • One of: SOLE_PROPRIETOR | PRIVATE_PROFIT | PUBLIC_PROFIT | NON_PROFIT | GOVERNMENT
    business_registration_numberrequiredstring
    business_addressrequiredobject
    line1requiredstring
    cityrequiredstring
    provincerequiredstring
    postal_coderequiredstring
    contactrequiredobject
    first_namerequiredstring
    last_namerequiredstring
    emailrequiredstring
    phonerequiredstring
    websiterequiredstring
    use_caserequiredstring
    • One of: 2FA | App Notifications | Appointments | Auctions | Auto Repair Services | Bank Transfers | Billing | Booking Confirmations | Business Updates | COVID-19 Alerts | Career Training | Chatbot | Conversational / Alerts | Courier Services & Deliveries | Emergency Alerts | Events & Planning | Financial Services | Fraud Alerts | Fundraising | General Marketing | General School Updates | HR / Staffing | Healthcare Alerts | Housing Community Updates | Insurance Services | Job Dispatch | Legal Services | Mixed | Motivational Reminders | Notary Notifications | Order Notifications | Political | Public Works | Real Estate Services | Religious Services | Repair and Diagnostics Alerts | Rewards Program | Surveys | System Alerts | Voting Reminders | Waitlist Alerts | Webinar Reminders | Workshop Alerts
    use_case_summaryrequiredstring
    sample_messagesrequiredstring[]
    opt_in_workflowrequiredstring
    opt_in_image_urlsrequiredstring[]
    opt_in_confirmation_messagerequiredstring
    help_messagerequiredstring
    privacy_policy_urlrequiredstring
    terms_urlrequiredstring
    • Can be null
    monthly_volumerequiredstring
    • One of: 10 | 100 | 1,000 | 10,000 | 100,000 | 250,000 | 500,000 | 750,000 | 1,000,000 | 5,000,000 | 10,000,000+
    age_gatedrequiredboolean
    additional_informationrequiredstring
    • Can be null
    fee_centsrequiredinteger

    The verification fee for this application, in cents CAD.

    payment_urlrequiredstring

    While AWAITING_PAYMENT: the dashboard page where the fee is paid. Null otherwise.

    • Can be null
    paid_atrequiredstring
    • Format: date-time
    • Can be null
    refunded_atrequiredstring
    • Format: date-time
    • Can be null
    reviewer_noterequiredstring

    What HonkIO staff asked to change, or why they declined the application.

    • Can be null
    carrier_statusrequiredstring

    Where the carrier's review stands once it has the application: pending, action_needed (the carrier asked HonkIO a question; nothing for you to do yet), approved or rejected. Null before it is submitted.

    • One of: pending | action_needed | approved | rejected
    • Can be null
    carrier_rejection_reasonrequiredstring

    Why the carrier rejected the application, when it did.

    • Can be null
    submitted_atrequiredstring
    • Format: date-time
    • Can be null
    decided_atrequiredstring

    When the carrier approved or rejected it.

    • Format: date-time
    • Can be null
    created_atrequiredstring
    • Format: date-time
    updated_atrequiredstring
    • Format: date-time
  • 401Missing, invalid, revoked or expired API key.The standard error body.
  • 402The account has no balance, or a LIVE key was used before the first top-up.The standard error body.
  • 403BUSINESS_VERIFICATION_REQUIRED (verify your business first) or BUSINESS_NUMBER_REQUIRED (your verified business profile has no CRA business number, which toll-free verification needs).The standard error body.
  • 404NOT_FOUND: no such resource on this account.The standard error body.
  • 409VERIFICATION_NOT_EDITABLE: only DRAFT, CHANGES_REQUESTED and REJECTED applications can be submitted. COMPED_TOLL_FREE: toll-free numbers are not available on this account.The standard error body.
  • 422LIVE_MODE_REQUIRED for a test key, or NOT_A_TOLL_FREE_NUMBER when a number was released since.The standard error body.
  • 429Rate limit reached: 100 requests per second per account, or a route-specific limit (Retry-After set where one applies).The standard error body.
  • 500Unexpected server error.The standard error body.

Example

const { data, error } = await honkio.tollFreeVerifications.submit('VERIFICATION_ID')
if (error) throw new Error(error.message)
console.log(data.status, data.payment_url) // a draft: 'AWAITING_PAYMENT' and where to pay the fee