> For the complete documentation index, see [llms.txt](https://docs.didforsale.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.didforsale.com/sip-trunking/sip-trunking/freepbx-trunk-configuration/freepbx-pjsip-configuration/ip-based.md).

# IP-based

Configure FreePBX PJSIP Trunking with IP based interconnection with DIDForSale. This configuration has been tested on FreePBX Version 14.0.5.2 'VoIP Server'

**CREATE** **TRUNKS** **FOR** **INBOUND**

**Step** **1**: Login to your freepbx admin interface, go to Connectivity>Trunks and select the option Add SIP (chan\_pjsip) Trunk&#x20;

![](https://4161683604-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LUHjv4EwOoqWXb2by8A%2F-LWI3RO-GWHZsuzMJzEp%2F-LWI3ZiuaOvtlUQASNrs%2Fpjsip.png?alt=media\&token=7725523a-39f1-4a04-a0d0-af541918169d)

**Step** **2**: Give a name for the trunk as didforsale\_1 and add the trunk Parameter as shown in below img.

![](https://4161683604-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LUHjv4EwOoqWXb2by8A%2F-LWI65pquVQFnDypYJyQ%2F-LWI6OAbIFgeDhDoscVh%2Fpjin_1.png?alt=media\&token=b98269fe-56d4-42ef-a13f-04d466054cea)

**STEP 3**:Click on the PJSIP settings and enter the IP 66.209.76.70 in front of SIP SERVER and SIP Server Port as 5060, then click on submit as shown in the figure below:

<figure><img src="https://4161683604-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LUHjv4EwOoqWXb2by8A%2Fuploads%2FmhkFgwK2wu5MfhMSKmCq%2Fimage.png?alt=media&amp;token=ab22cb1c-fea7-4110-aa0f-ad9b57e956fa" alt=""><figcaption></figcaption></figure>

**Step 4**: Create a second trunk for inbound with trunk name as didforsale\_2 and add the trunk Parameters as shown

![](https://4161683604-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LUHjv4EwOoqWXb2by8A%2F-LWI65pquVQFnDypYJyQ%2F-LWI6XZY-BBHItKBZd0r%2Fojin_2.png?alt=media\&token=c3fc9d4e-c7cc-4304-b397-45b63f1cde5a)

**STEP 5**: Click on the PJSIP settings and enter the second IP **66.209.76.72** in front of SIP SERVER, and then click on submit as shown below:

<figure><img src="https://4161683604-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LUHjv4EwOoqWXb2by8A%2Fuploads%2FmnuGcMVQaVzgBgqAgaqm%2Fimage.png?alt=media&amp;token=a77377d3-cff7-41cd-96f1-1c3b397bd9e4" alt=""><figcaption></figcaption></figure>

#### Routing Inbound Routes

**Step** **6**: For routing your inbound calls coming to your DID number, click on inbound routes and configure the DID with prefix 1. Toll-free numbers need to be configured without 1. Say your DID is 6014932412, then you will configure the DID with 16014932412 in the inbound routes.

Here is the image for inbound setups

![](https://4161683604-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LUHjv4EwOoqWXb2by8A%2F-LWHZNqhRVXEkCrS3Drk%2F-LWHZz6mcNdyjd2S9EAg%2FInboundROute.png?alt=media\&token=e23af115-239d-4296-b9e3-155bfb9ec735)
