# Connect Cloud Voice to a TE100 Gateway

Pairing Cloud Voice with a TE100 digital gateway lets you bring an E1/T1/PRI circuit into your hosted phone system. E1/T1/PRI (Primary Rate Interface) lines are digital trunk lines that carry many concurrent voice channels over a single physical circuit, and the TE100 gateway is the box that converts that circuit into VoIP.

You build the link from two matching SIP trunks. SIP (Session Initiation Protocol) is the signalling that sets up and tears down VoIP calls. On Cloud Voice you create an account trunk that accepts a registration, and on the gateway you create a register trunk that signs in to it. Once both sides agree, the single E1/T1/PRI line on the gateway behaves as an extended trunk on Cloud Voice.

:::note
The two trunk types describe direction. An account trunk on Cloud Voice acts like the server: it holds a username and password and waits for the far end to log in. The register trunk on the gateway acts like the client: it uses that same username and password to log in to Cloud Voice.
:::

## Requirements

Your Cloud Voice system must run firmware version 84.10.0.30 or later.

## Step 1. Create a SIP account trunk on Cloud Voice

Start on the phone system by defining the account trunk that the gateway will register against.

1. Sign in to the Cloud Voice management portal and go to **Extension and Trunk > Trunk**, then click **Add**.
2. Fill in the trunk settings.

   ![Cloud Voice account trunk configured to accept a registration from the TE100 gateway](/images/pbx/sip-account-trunk-connect-to-te100-pce.png)

   - **Name**: A label that is easy to recognize, such as `Connect-to-TE100-Gateway`.
   - **Trunk Status**: Select **Enabled**.
   - **Select ITSP Template**: Select **General**. ITSP (Internet Telephony Service Provider) templates preload provider-specific settings; **General** applies no provider-specific tweaks, which is what you want for a direct gateway link.
   - **Trunk Type**: Select **Account Trunk**.
   - **Transport**: Select **UDP**. UDP (User Datagram Protocol) is the network transport SIP will use; you must select the same transport on the gateway in Step 2.
   - **Username**: Set a username for the trunk, for example `6700`.
   - **Password**: Set the password that goes with the username.
   - **Use User Name as Account Trunk's Authentication Name**: Turn this on so the trunk's username is also used as its authentication name.

   :::note
   The username doubles as the trunk number, so choose a value you can identify later.
   :::

   :::tip
   Write down the username and password now. You re-enter both on the gateway in Step 2, and they must match exactly.
   :::

3. Click **Save**, then **Apply**.

## Step 2. Create a SIP register trunk on the TE100 gateway

On the gateway, add a register trunk that signs in to the account trunk you just created.

1. Sign in to the gateway's web interface and go to **Gateway > VoIP Settings > VoIP Trunk**, then click **Add VoIP Trunk**.
2. Configure the trunk in the window that opens.

   
   ![Cloud Voice, TE100 gateway register trunk pointed at the Cloud Voice domain and SIP port](/images/pbx/te-service-provider-trunk-connect-to-ce.png)

   - **Trunk Type**: Select **Trunk**.
   - **Provider Name**: A label that is easy to recognize.
   - **Hostname/IP**: Enter your Cloud Voice domain name followed by the SIP port. This example uses `pbx.example.com` and the default SIP port `5060`.
   - **Domain**: Enter your Cloud Voice domain name, `pbx.example.com` in this example.
   - **User Name**: Enter the username from the account trunk in Step 1, `6700` in this example.
   - **Authorization Name**: Enter the same username, `6700` in this example.
   - **Password**: Enter the password from the account trunk in Step 1.

   :::caution
   The username, authorization name, and password on the gateway must exactly match the username and password you set on the Cloud Voice account trunk in Step 1, and the transport (UDP) and SIP port (5060) must match on both ends. If any of these differ, the gateway cannot register and no calls will pass over the trunk.
   :::

3. Click **Save**, then **Apply Changes**.

## Result

With both trunks in place, confirm the registration on each device.

- In the Cloud Voice portal (**Extension and Trunk > Trunk**), the trunk shows a connected status icon ![Trunk connected](/images/pbx/trunk-ok.png).

  ![Cloud Voice trunk list showing the TE100 account trunk as connected](/images/pbx/sip-register-trunk-connect-to-te100-status-ce.png)

- On the gateway (**Status > System Status > IP Trunk Status**), the trunk status reads **Registered**.

  
  ![Cloud Voice, TE100 gateway IP trunk status showing the trunk as Registered](/images/pbx/te-ce-trunk-status.png)

Cloud Voice is now connected to the TE100 gateway, and the gateway's single E1/T1/PRI line is available as an extended trunk on your phone system.

## What to do next

- To place outbound calls over the extended E1/T1/PRI trunk, see [Make Outbound Calls through the Extended E1/T1/PRI Trunk](/pbx/integrations/cloud-voice-te/make-outbound-calls-through-the-extended-e1-t1-pri-trunk/).
- To take inbound calls over the extended E1/T1/PRI trunk, see [Receive Inbound Calls through the Extended E1/T1/PRI Trunk](/pbx/integrations/cloud-voice-te/receive-inbound-calls-through-the-extended-e1-t1-pri-trunk/).
