Skip to content

Commit 3b592f6

Browse files
vinzensgtjoseph
authored andcommitted
feat: ARI transfer handling - configuration improvements
also: there is no automatically generated NOTIFY
1 parent 5599bb3 commit 3b592f6

File tree

1 file changed

+33
-1
lines changed
  • docs/Configuration/Interfaces/Asterisk-REST-Interface-ARI/Introduction-to-ARI-Transfer-Handling

1 file changed

+33
-1
lines changed

docs/Configuration/Interfaces/Asterisk-REST-Interface-ARI/Introduction-to-ARI-Transfer-Handling/index.md

Lines changed: 33 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,31 @@ In SIP there is a method called `REFER`. This method, if triggered by the user,
2020

2121
Asterisk handles the REFER without any config changes by itself. To have ARI handle the transfer you need to change a setting so the ARI events are generated. If done, the `channelTransferEvent` will be generated in case a `REFER` is received. The `channelTransferEvent` contains the information about the transfer. The `channelTransferEvent` is generated for both, blind and attended transfer.
2222

23+
24+
### Configuration
25+
26+
To enable ARI transfer handling, set [PJSIP_TRANSFER_HANDLING()=ari-only](https://docs.asterisk.org/Latest_API/API_Documentation/Dialplan_Functions/PJSIP_TRANSFER_HANDLING/).
27+
28+
• Endpoint configuration:
29+
30+
```
31+
set_var=PJSIP_TRANSFER_HANDLING()=ari-only
32+
```
33+
34+
All channels from this endpoint will inherit the setting.
35+
36+
• Dialplan:
37+
38+
```
39+
same => n,Set(PJSIP_TRANSFER_HANDLING()=ari-only)
40+
```
41+
42+
Apply before sending the channel to a Stasis application.
43+
44+
• ARI-created channels:
45+
46+
Set the variable at channel creation. See the [ARI REST documentation](https://docs.asterisk.org/Latest_API/API_Documentation/Asterisk_REST_Interface/Channels_REST_API/#create) for details.
47+
2348
### Information within the `channelTransferEvent`
2449

2550
#### Attended transfer
@@ -61,7 +86,14 @@ Where the channel marked with the "X" might be placed on hold, or not.
6186
### Actions after the event is received
6287

6388
#### Attended transfer
64-
The ARI application MUST take some action in order to handle the REFER. The Asterisk will not do anything by itself. The first thing to do when received an SIP REFER is acknowledge it. This is done by the Asterisk, as well as the first `NOTIFY` telling the telephone an `100 Trying` SIP frag. After that, the telephon waits for a `Notify` containing a SIP frag with `200 OK`. This has to be sent by the ARI application manually.
89+
The ARI application MUST take action in order to handle a SIP REFER. Asterisk does not handle the transfer automatically.
90+
91+
When a REFER is received, Asterisk will acknowledge it with a `202 Accepted`. After that, it is the responsibility of the ARI application to send the required NOTIFY messages to the transferrer. This includes:
92+
93+
* An initial NOTIFY with a SIP frag of `100 Trying`
94+
* Subsequent NOTIFY messages with updated status, such as a SIP frag of `200 OK` once the transfer is complete, or an appropriate error if the transfer fails
95+
96+
If the ARI application does not send these NOTIFY messages, the transferrer will never receive progress or completion information for the transfer.
6597

6698
Actions that should be taken by the ARI application in the scenario described in call schema 1:
6799

0 commit comments

Comments
 (0)