sip:refer verb is used to transfer a call and disconnect it.
This verb sends a REFER message to the carrier (SIP trunk) or SIP phone. For the transfer to be successful, the carrier or SIP phone needs to support the REFER message. Once the sip:refer is successfully completed, the call will be transferred and disconnected from Voice Gateway.
Configuration
The full set of configuration parameters:| Parameters | Description | Required |
|---|---|---|
| referTo | A SIP URI or a phone number/user identifier. | Yes |
| referredBy | A SIP URI or a phone number/user identifier. If the value is not provided, it will default to the identity of the party being transferred. | No |
| actionHook | A webhook to receive an HTTP POST when the call was completed. Default is refer | No |
| eventHook | A webhook to receive an HTTP POST when NOTIFY messages of follow-on call status are received. | No |
| headers | Additional SIP headers to include in the response. | No |
sip:refer verb completes when one of the following conditions is met:
- A failure response is received to the
REFER. - A
202 Acceptedresponse is received in response to theREFER, and aNOTIFYof the follow-on call status with a final call status is received. - The
sip:referhas an action hook that will provide details of the final result, as well as an event hook that is called for everyNOTIFYreceived after a successfulREFER.
actionHook
The actionHook webhook contains the following additional parameters:| Parameter | Description |
|---|---|
| referStatus | The SIP status response to the REFER request. |
| final_referred_call_status | The parameter indicates the final SIP status of the subsequent call to the transferee. This parameter is provided only when the REFER is accepted and NOTIFY requests are received from the remote party. |
| eventHook.event | Transfer status. |
| eventHook.call_status | Contains a SIP status received in a NOTIFY after a successful REFER. |