> For the complete documentation index, see [llms.txt](https://prosbcdocs.telcobridges.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://prosbcdocs.telcobridges.com/tmedia-documentation/use-cases/process-redirection-to-other-sip-endpoints.md).

# Process redirection to other SIP endpoints

#### ***Applies to version(s): v2.8 and above***

In this scenario, the incoming call is sent to a SIP redirect server, which returns a 3xx message and a new call is sent to the SIP contacts received.

![Redirect to SIP](https://docs.telcobridges.com/w/images/7/72/Redirect_to_SIP.png)

This is the call flow of such a scenario. A 302 Moved temporarily is returned from the SIP redirect server and new calls are made to the SIP endpoints.

![SIP Redirect callflow process v2](https://docs.telcobridges.com/w/images/b/be/SIP_Redirect_callflow_process_v2.png)

| Configure Routing Scripts                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      | Configure NAP                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               | Configure NAP Colums                                                                                                                                                                                                                                                                                                                          | Configure Routes                                                                                                                                                                                                                                                                                                                 |
| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| [Configure Routing scripts](https://github.com/telcobridges-main/tmedia-wiki/tree/main/tmedia/configuration/web-portal-2-9-call-routes-settings/README.md#routing-script) \***Routing Scripts** -> Import Script File \*\***File**-> [redirect\_routing\_rb](https://docs.telcobridges.com/w/images/a/a0/Redirect_routing_rb.zip) \*\***ScriptType**-> Customer \*\***Load on startup** -> unchecked \***Routing Scripts** -> Select Main Script \*\*At start of script: \*\*\*require 'redirect\_routing' \*\*In the main class: \*\*\*include RedirectQuery \*\*\*before\_filter :method => :redirect\_query | [Configure NAP](https://github.com/telcobridges-main/tmedia-wiki/tree/main/tmedia/configuration/allocating-a-sip-network-access-point-nap/README.md) \***NAP** -> Create New NAP \*\***Name**-> NAP\_REDIRECT\_SERVER\_A \*\***Proxy address**-> x.x.x.x (IP of SIP redirect server) You can add more SIP redirect server as needed \***NAP** -> Create New NAP \*\***Name**-> SIP\_NAP\_ANY \*\***Proxy address**-> NONE This will allow calls to be redirected to any IPs using this SIP transport Server | In NAP Columns, set the following: \***NAP Columns** -> Create New Nap Column \*\***Name** -> server\_type \*\***Type Attributes** -> NORMAL\|REDIRECT \*\***Default** -> NORMAL Select REDIRECT for each NAP that is a SIP Redirect server and you can prioritize with group (lowest value is highest priority) and weight (to load balance) | When you [Configure Routes](https://github.com/telcobridges-main/tmedia-wiki/tree/main/tmedia/configuration/web-portal-2-9-call-routes-settings/README.md#static-route), set the following: \***Routes** -> Create New Static Route \*\***Name** -> To\_SIP\_Endpoints \*\***NAP** -> any \*\***Remapped\_NAP** -> SIP\_NAP\_ANY |

These settings are set by default, but may be verified if some changes were made in the default configuration: SIP -> Header Parameters -> Use legacy redirection mode \[unchecked] ( old naming convention was: Allow Recurse) Profiles -> Edit Reason Cause Mapping -> 302 Moved temporarily-> Route retry action -> Process Call Routing gateway -> use Script -> default\_routing\_script

### Files used for routing scripts

[Redirect to SIP files](https://docs.telcobridges.com/w/images/a/a0/Redirect_routing_rb.zip)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://prosbcdocs.telcobridges.com/tmedia-documentation/use-cases/process-redirection-to-other-sip-endpoints.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
