HCC Docs

Twilio and numbers

Real calls run on your own Twilio account. Twilio bills you directly for minutes and numbers. You don't need any of this in test mode.

Only owners and admins can connect an account.

Connect your account

  1. In the dashboard, open Settings, then Telephony.
  2. Choose Connect your own account, then Connect Twilio.
  3. Enter your Account SID and Auth Token, both from Twilio's console. It has to be the Auth Token, not an API key.
  4. Press Connect.

Import your numbers

Press Import numbers, pick the ones you want and press Import. Buy any new numbers in Twilio's console first.

Importing points each number's voice and status webhooks at HCC, and we remember what they were. Removing a number or disconnecting the account puts them back. The number itself is never deleted from Twilio.

Choose what a number does

A number can runSet it with
A call flownumbers on the flow and hcc deploy --live, or hcc.numbers.update
Your own call webhookNumbers, Edit webhook. The signing secret is shown once
A fallback agentNumbers, Fallback agent. It answers when your code can't

To declare it in code:

export const inbound = defineCallFlow(
  'inbound',
  { numbers: [env('SALES_NUMBER')] }, // live calls to this number run this flow
  function* (c) {
    yield* c.say('Thanks for calling.');
    yield* c.hangup();
  },
);

Pointing a number at a flow needs the numbers:write Scope, which only a key an owner or admin makes can have. See Call flows for how deploys handle it.

Plans

Connecting Twilio and importing numbers need no plan. Placing live outbound calls does. See your plan on Settings, Billing.