Added following snippits about Asterisk

* A Basic Asterisk server for internal calling with IVR, curl triggers and message playback
* A Asterisk server to act as a bridge between a Bluetooth phone (as in/out bound route)
* A Node-Red Subflow to create a call between extensions using ARI
This commit is contained in:
2024-01-07 21:51:57 +01:00
parent 380353f4ea
commit 2e57050f06
41 changed files with 845 additions and 0 deletions

View File

@@ -0,0 +1,27 @@
# Asterisk sever BT bridge
Go [Here](../../Docs/Setup-Asterisk-Server.md) to read about how to set it up
**Config files that are empty**
these are just here to suppress errors
* ```acl.conf```
* ```ccss.conf```
* ```cdr.conf```
* ```cel.conf```
* ```features.conf```
* ```pjproject.conf```
* ```pjsip_wizard.conf```
**Config files for basic usage**
If a config file does not have a comment is does not require any tweaking
`*` Must be updated before first use
* ```asterisk.conf```
* ```logger.conf```
* ```modules.conf```
* ```udptl.conf```
* ```chan_mobile.conf``` Settings for bluetooth `*`
* ```extentions.conf``` Dial plan for extension
* ```indications.conf``` Settings for dial tones
* ```pjsip.conf``` Sets listening for PJSIP and defines the credentials for the extensions `*`

View File

@@ -0,0 +1 @@
; Asterisk ACL configuration

View File

@@ -0,0 +1,19 @@
; Asterisk core configuration
[directories](!)
astcachedir => /tmp
astetcdir => /etc/asterisk
astmoddir => /usr/lib/asterisk/modules
astvarlibdir => /var/lib/asterisk
astdbdir => /var/lib/asterisk
astkeydir => /var/lib/asterisk
astdatadir => /var/lib/asterisk
astagidir => /var/lib/asterisk/agi-bin
astspooldir => /var/spool/asterisk
astrundir => /var/run/asterisk
astlogdir => /var/log/asterisk
astsbindir => /usr/sbin
[options]
;verbose = 3
;debug = 3
documentation_language = en_US

View File

@@ -0,0 +1 @@
; Asterisk ccss (Call Completion Supplementary Services) configuration

View File

@@ -0,0 +1 @@
; Asterisk cdr (Call Detail Record engine) configuration

View File

@@ -0,0 +1 @@
; Asterisk CEL (Channel Event Logging) configuration

View File

@@ -0,0 +1,13 @@
; Asterisk Chan Mobile configuration
[general]
interval=30
[adapter]
id=hci0
address=<Adapter MAC> ;MAC of adapter
[phone0]
context=incoming-mobile
address=<Phone MAC> ; MAC of Phone
adapter=hci0
port=1 ;port number (from mobile search)

View File

@@ -0,0 +1,12 @@
; Asterisk exention configuration
[from-internal]
;Internal extentions (Phone,softphones or other Voip clients)
exten => 7000,1,Dial(PJSIP/${EXTEN},30)
;Outbound route
exten => _X.,1,Dial(mobile/phone0/${EXTEN})
;Inbound route
[incoming-mobile]
exten => s,1,Goto(from-internal,7000,1)

View File

@@ -0,0 +1 @@
; Asterisk Call Features (transfer, monitor/mixmonitor, etc) configuration

View File

@@ -0,0 +1,30 @@
; Asterisk indication (location specific tone indications) configuration
[general]
country=nl
[nl]
description = Netherlands
ringcadence = 1000,4000
dial = 425
busy = 425/500,0/500
ring = 425/1000,0/4000
congestion = 425/250,0/250
callwaiting = 425/500,0/9500
dialrecall = 425/500,0/50
record = 1400/500,0/15000
info = 950/330,1400/330,1800/330,0/1000
stutter = 425/500,0/50
[us]
description = United States / North America
ringcadence = 2000,4000
dial = 350+440
busy = 480+620/500,0/500
ring = 440+480/2000,0/4000
congestion = 480+620/250,0/250
callwaiting = 440/300,0/10000
dialrecall = !350+440/100,!0/100,!350+440/100,!0/100,!350+440/100,!0/100,350+440
record = 1400/500,0/15000
info = !950/330,!1400/330,!1800/330,0
stutter = !350+440/100,!0/100,!350+440/100,!0/100,!350+440/100,!0/100,!350+440/100,!0/100,!350+440/100,!0/100,!350+440/100,!0/100,350+440

View File

@@ -0,0 +1,7 @@
; Asterisk logging configuration
[general]
[logfiles]
console => notice,warning,error
messages => notice,warning,error

View File

@@ -0,0 +1,76 @@
; Asterisk Module Loader configuration file
[modules]
autoload=no
;Core
load = app_dial.so
load = pbx_config.so
load = pbx_loopback.so
load = pbx_realtime.so
load = pbx_spool.so
load = func_callerid.so
load = func_dialplan.so
load = func_dialgroup.so
load = res_ael_share.so
load = res_timing_timerfd.so
;Codecs
load = codec_alaw.so
load = codec_g722.so
load = codec_g726.so
load = codec_gsm.so
load = codec_opus_open_source.so
load = codec_resample.so
load = codec_ulaw.so
;Formats
load = format_g719.so
load = format_g726.so
load = format_gsm.so
load = format_siren14.so
load = format_siren7.so
load = format_wav.so
load = format_wav_gsm.so
load = res_format_attr_g729.so
load = res_format_attr_opus.so
load = res_format_attr_siren14.so
load = res_format_attr_siren7.so
;PJSIP
require = chan_pjsip.so
load = func_pjsip_aor.so
load = func_pjsip_endpoint.so
load = res_pjproject.so
load = res_pjsip.so
load = res_pjsip_authenticator_digest.so
load = res_pjsip_caller_id.so
load = res_pjsip_endpoint_identifier_ip.so
load = res_pjsip_endpoint_identifier_user.so
load = res_pjsip_exten_state.so
load = res_pjsip_outbound_publish.so
load = res_pjsip_outbound_registration.so
load = res_pjsip_path.so
load = res_pjsip_pubsub.so
load = res_pjsip_refer.so
load = res_pjsip_registrar.so
load = res_pjsip_sdp_rtp.so
load = res_pjsip_session.so
;RTP
load = chan_rtp.so
load = bridge_native_rtp.so
load = res_rtp_asterisk.so
load = res_rtp_multicast.so
;Bridge
load = bridge_simple.so
load = bridge_builtin_features.so
;Sorcery
load = res_sorcery_astdb.so
load = res_sorcery_config.so
load = res_sorcery_memory.so
;BT Interface
require = chan_mobile.so

View File

@@ -0,0 +1 @@
; Asterisk pjproject options

View File

@@ -0,0 +1,30 @@
; Asterisk PJSIP config
[transport-udp]
type=transport
protocol=udp
bind=0.0.0.0
;Internal VoipClient
[7000]
type=endpoint
context=from-internal
callerid=DeskPhone <7000>
disallow=all
;Some phone may reqire other codecs,
;the following are available ulaw,alaw,gsm,g726,g722,opus
allow=g722
auth=7000
aors=7000
[7000]
type=auth
auth_type=userpass
password=<Password>
username=7000
[7000]
type=aor
; if one device is connected setting '1' is okay
; when a device sometimes fails to register (like my Friz!box) try increasing it, '5' is a safe value
max_contacts=1

View File

@@ -0,0 +1 @@
; Asterisk PJSIP Wizard configuration

View File

@@ -0,0 +1,8 @@
; Asterisk udptl config
[general]
udptlstart=4000
udptlend=4999
udptlfecentries = 3
udptlfecspan = 3
use_even_ports = no

View File

@@ -0,0 +1,38 @@
# Basic asterisk sever
Go [Here](../../Docs/Setup-Asterisk-Server.md) to read about how to set it up
**Config files that are empty**
these are just here to suppress errors
* ```acl.conf```
* ```ccss.conf```
* ```cdr.conf```
* ```cel.conf```
* ```features.conf```
* ```manager.conf```
* ```pjproject.conf```
* ```pjsip_wizard.conf```
**Config files for basic usage**
If a config file does not have a comment, it does not require any tweaking
`*` Must be updated for each (new) extension
`**` Must be updated if (new) extension if a voip client needs to connect ({Soft}phone) or needs to be connected to (Homeassistant)
* ```asterisk.conf```
* ```extensions.conf``` Dial plan for extensions `*`
* ```indications.conf``` Settings for dial tones
* ```logger.conf```
* ```modules.conf``` If not all functions are used you can disable some modules
* ```pjsip.conf``` Sets listening for PJSIP and loads sub configs
* ```pjsip.extension.conf``` Defines the extension the credentials for the extensions `**`
* ```pjsip.aor.conf``` Sets maximum connections for an extension `**`
* ```pjsip.auth.conf``` Sets the credentials for the extensions`**`
* ```udptl.conf```
**Config files for use with ARI**
* ```ari.conf``` ARI basic config and credentials (Make sure to update this)
* ```http.conf``` Settings for the integrated webserver for ARI
* ```stasis.conf``` (Just here to suppress errors)

View File

@@ -0,0 +1 @@
; Asterisk ACL configuration

View File

@@ -0,0 +1,9 @@
; Asterisk ARI (Asterisk REST API) configuration
[general]
enabled = yes
[aritest]
type = user
read_only = no
password = testme
password_format = plain

View File

@@ -0,0 +1,19 @@
; Asterisk core configuration
[directories](!)
astcachedir => /tmp
astetcdir => /etc/asterisk
astmoddir => /usr/lib/asterisk/modules
astvarlibdir => /var/lib/asterisk
astdbdir => /var/lib/asterisk
astkeydir => /var/lib/asterisk
astdatadir => /var/lib/asterisk
astagidir => /var/lib/asterisk/agi-bin
astspooldir => /var/spool/asterisk
astrundir => /var/run/asterisk
astlogdir => /var/log/asterisk
astsbindir => /usr/sbin
[options]
;verbose = 3
;debug = 3
documentation_language = en_US

View File

@@ -0,0 +1 @@
; Asterisk ccss (Call Completion Supplementary Services) configuration

View File

@@ -0,0 +1 @@
; Asterisk cdr (Call Detail Record engine) configuration

View File

@@ -0,0 +1 @@
; Asterisk CEL (Channel Event Logging) configuration

View File

@@ -0,0 +1,45 @@
; Asterisk exention configuration
[from-internal]
;Play audio message and hangup if 6010 is dialed
exten = 6010,1,Answer()
same = n,Wait(2)
same = n,Playback(demo-congrats)
same = n,Hangup()
;Send http request, play audio message and hangup if 6011 is dialed
exten = 6011,1,Answer()
same = n,Wait(2)
same = n,Set(CURL_RESULT=${CURL(http://<NoderedIP>:1880/endpoint/<ENDPOINT NAME>?exten=${EXTEN})})
same = n,Playback(activated)
same = n,Hangup()
;Internal extentions (Phone,softphones or other Voip clients)
; The number at the end (,30) sets the dial time out
exten => 6000,1,Dial(PJSIP/${EXTEN},30)
;Connect to extenal the Homeassistent 'Assistent' service when 6020 is dialed
exten => 6020,1,Dial(PJSIP/HomeAssistant,10)
;IVR,
;send to ivr if 6012 is dialed
exten = 6012,1,Goto(ivr-test,s,1)
;;The following section must be at the end of the file
[ivr-test]
exten =>s,1,Answer()
same =>n,set(IVRName=TestIVR)
same => n,wait(2)
same => n,Background(basic-pbx-ivr-main)
same => n,WaitExten(10)
;;Nr 1 to 4 are vaild options
exten => _[1-4],1,Set(CURL_RESULT=${CURL(http://<NoderedIP>:1880/endpoint/<ENDPOINT NAME>?${IVRName}=${EXTEN})}
same = n,Playback(activated)
same = n,Playback(goodbye)
same = n,Hangup()
;;If option invalid
exten => i,1,Playback(pm-invalid-option)
exten => i,2,Goto(ivr-test,s,5)
;; If timed out
exten => t,1,Playback(vm-pls-try-again)
exten => t,2,Goto(ivr-test,s,5)

View File

@@ -0,0 +1 @@
; Asterisk Call Features (transfer, monitor/mixmonitor, etc) configuration

View File

@@ -0,0 +1,5 @@
; Asterisk HTTP server (for ARI, etc) configuration
[general]
enabled=yes
bindaddr=0.0.0.0
bindport=8088

View File

@@ -0,0 +1,30 @@
; Asterisk indication (location specific tone indications) configuration
[general]
country=nl
[nl]
description = Netherlands
ringcadence = 1000,4000
dial = 425
busy = 425/500,0/500
ring = 425/1000,0/4000
congestion = 425/250,0/250
callwaiting = 425/500,0/9500
dialrecall = 425/500,0/50
record = 1400/500,0/15000
info = 950/330,1400/330,1800/330,0/1000
stutter = 425/500,0/50
[us]
description = United States / North America
ringcadence = 2000,4000
dial = 350+440
busy = 480+620/500,0/500
ring = 440+480/2000,0/4000
congestion = 480+620/250,0/250
callwaiting = 440/300,0/10000
dialrecall = !350+440/100,!0/100,!350+440/100,!0/100,!350+440/100,!0/100,350+440
record = 1400/500,0/15000
info = !950/330,!1400/330,!1800/330,0
stutter = !350+440/100,!0/100,!350+440/100,!0/100,!350+440/100,!0/100,!350+440/100,!0/100,!350+440/100,!0/100,!350+440/100,!0/100,350+440

View File

@@ -0,0 +1,7 @@
; Asterisk logging configuration
[general]
[logfiles]
console => notice,warning,error
messages => notice,warning,error

View File

@@ -0,0 +1 @@
; Asterisk AMI - (Asterisk Manager Interface) configuration

View File

@@ -0,0 +1,109 @@
; Asterisk Module Loader configuration file
[modules]
autoload=no
;Core (BasicCalling)
load = app_dial.so
load = pbx_config.so
load = pbx_loopback.so
load = pbx_realtime.so
load = pbx_spool.so
load = func_callerid.so
load = func_dialplan.so
load = func_dialgroup.so
load = res_ael_share.so
load = res_timing_timerfd.so
;Codecs (BasicCalling)
load = codec_alaw.so
load = codec_g722.so
load = codec_g726.so
load = codec_gsm.so
load = codec_opus_open_source.so
load = codec_resample.so
load = codec_ulaw.so
;Formats (BasicCalling)
load = format_g719.so
load = format_g726.so
load = format_gsm.so
load = format_ogg_speex.so
load = format_siren14.so
load = format_siren7.so
load = format_wav.so
load = format_wav_gsm.so
load = res_format_attr_g729.so
load = res_format_attr_opus.so
load = res_format_attr_siren14.so
load = res_format_attr_siren7.so
;PJSIP (BasicCalling)
require = chan_pjsip.so
load = func_pjsip_aor.so
load = func_pjsip_endpoint.so
load = res_pjproject.so
load = res_pjsip.so
load = res_pjsip_authenticator_digest.so
load = res_pjsip_caller_id.so
load = res_pjsip_endpoint_identifier_ip.so
load = res_pjsip_endpoint_identifier_user.so
load = res_pjsip_exten_state.so
load = res_pjsip_outbound_publish.so
load = res_pjsip_outbound_registration.so
load = res_pjsip_path.so
load = res_pjsip_pubsub.so
load = res_pjsip_refer.so
load = res_pjsip_registrar.so
load = res_pjsip_sdp_rtp.so
load = res_pjsip_session.so
;Sorcery (Rqired by PJSIP)
load = res_sorcery_astdb.so
load = res_sorcery_config.so
load = res_sorcery_memory.so
;RTP (Reqired by BasicCalling)
load = chan_rtp.so
load = bridge_native_rtp.so
load = res_rtp_asterisk.so
load = res_rtp_multicast.so
;Bridge (Reqired by BasicCalling)
load = bridge_simple.so
load = bridge_builtin_features.so
;FilePlayback (Reqired for playing a audio message for dialplan or IVR)
load = app_controlplayback.so
load = app_playback.so
;;Make call from asterisk cli
;load = app_originate.so
;load = res_clioriginate.so
;ARI (Asterisk RESTful Interface)
load => res_ari.so
load => res_ari_applications.so
load => res_ari_asterisk.so
load => res_ari_bridges.so
load => res_ari_channels.so
load => res_ari_device_states.so
load => res_ari_endpoints.so
;load => res_ari_events.so
load => res_ari_model.so
load => res_ari_playbacks.so
load => res_ari_recordings.so
load => res_ari_sounds.so
; stasis (Reqired by ARI)
load => app_stasis.so
load => res_stasis.so
load => res_stasis_answer.so
load => res_stasis_device_state.so
load => res_stasis_playback.so
load => res_stasis_recording.so
load => res_stasis_snoop.so
;cURL (Reqired for send curl commands form dialplan)
load = func_curl.so
load = res_curl.so

View File

@@ -0,0 +1 @@
; Asterisk pjproject options

View File

@@ -0,0 +1,15 @@
; Asterisk AOR (address of record) config
;Address for extenal the Homeassistent 'Assistent' service
[HomeAssistant]
type=aor
qualify_frequency=0
contact=sip:<HomeAssistant IP>:5060
;Internal extentions (Phone,softphones or other Voip clients)
[6000]
type=aor
; if one device is connected setting '1' is okay
; when a device sometimes fails to register (like my Friz!box) try increasing it, '5' is a safe value
max_contacts=5

View File

@@ -0,0 +1,15 @@
; Asterisk PJSIP auth/credentials config
;Credentials for extenal the Homeassistent 'Assistent' service
[HomeAssistant]
type=auth
auth_type=userpass
password=
username=HA
;Internal extentions (Phone,softphones or other Voip clients)
[6000]
type=auth
auth_type=userpass
password=<PASSWORD>
username=6000

View File

@@ -0,0 +1,10 @@
; Asterisk PJSIP config
#include pjsip.extension.conf
#include pjsip.auth.conf
#include pjsip.aor.conf
[transport-udp]
type=transport
protocol=udp
bind=0.0.0.0

View File

@@ -0,0 +1,32 @@
; Asterisk PJSIP extention config
;settings Homeassistent 'Assistent' service extention
[HomeAssistant]
type=endpoint
context=from-external
disallow=all
allow=opus
aors=HA
send_connected_line=false
rtp_keepalive=0
user_eq_phone=no
trust_id_inbound=no
direct_media=no
rtp_symmetric=yes
auth=HomeAssistant
aors=HomeAssistant
;dtmf_mode=auto
;Internal extentions (Phone,softphones or other Voip clients)
[6000]
type=endpoint
context=from-internal
callerid=DeskPhone <6000>
disallow=all
;Some phone may reqire other codecs,
;the following are available ulaw,alaw,gsm,g726,g722,opus
allow=g722
auth=6000
aors=6000

View File

@@ -0,0 +1 @@
; Asterisk PJSIP Wizard configuration

View File

@@ -0,0 +1,4 @@
; Asterisk Stasis config
[threadpool]
[declined_message_types]

View File

@@ -0,0 +1,8 @@
; Asterisk udptl config
[general]
udptlstart=4000
udptlend=4999
udptlfecentries = 3
udptlfecspan = 3
use_even_ports = no

View File

@@ -0,0 +1,75 @@
# Asterisk basic sever
Features
* Calling other connected/internal phones
* Extension that plays an audio message
* Extension that sends a http request (Node-Red for example) and plays an audio message
* Extension that forwards the call the the Homeassistent 'Assistent'
* Extension with a IVR menu that will send the chosen option as a http request (Node-Red for example) and plays an audio message
## Installing Packages
**Alpine Linux**
```
apk add asterisk asterisk-curl asterisk-opus asterisk-sounds-en asterisk-sounds-moh asterisk-speex asterisk-tds
```
## Configuring
(Re)move the default asterisk config (`/etc/asterisk`).
Download the config files from here [Here](../Config-Examples/Asterisk-basic-server) and put them in the config directory `/etc/asterisk`.
Set the permissions `chown -R asterisk: /etc/asterisk`.
Edit the configuration files to suit your needs,
make sure to change the credentials, and check the module list
**Alpine Linux**
```
chown -R asterisk: /etc/asterisk
rc-update add asterisk
service asterisk start
```
# Asterisk bluetooth bridge
[Source](https://hotkey404.com/connect-your-phone-to-raspbx-via-bluetooth-with-chan_mobile/)
Features
* Bridge a mobile phone to a voip phone/pbx
## Installing Packages
**Alpine Linux**
```
apk add asterisk asterisk-opus asterisk-mobile udev bluez hidapi
```
## Configuring
(Re)move the default asterisk config (`/etc/asterisk`).
Download the config files from here [Here](../Config-Examples/Asterisk-BT_bridge) and put them in the config directory `/etc/asterisk`.
Set the permissions `chown -R asterisk: /etc/asterisk`.
Edit the credentials for your (soft)phone in `/etc/asterisk/pjsip.conf`
Pair the phone using `bluetoothctl`
Edit the phone and adapter bluethooth mac address in `/etc/asterisk/chan_mobile.conf`
(Re)start Asterisk
Connect to Asterisk CLI `asterisk -r`
Make sure the phone is discoverable/in pairing mode
In Asterisk CLI run `mobile search`
Change the port to the port from mobile scan in `/etc/asterisk/chan_mobile.conf`
Restart Asterisk
**Alpine Linux**
```
chown -R asterisk: /etc/asterisk
modprobe btusb
modprobe uhid
rc-update add asterisk
rc-update add bluetooth
service asterisk start
```
**bluetoothctl**
```
#Open the bluetoothCLI
bluetoothctl
scan on
pair <Mac Of phone>
```

4
NodeRed/Readme.md Normal file
View File

@@ -0,0 +1,4 @@
# NodeRed Snippits
## List of Flows
## List of SubFlows
* **ARI_caller** Uses the Asterisk REST API to generate a call between two extensions

View File

@@ -0,0 +1,183 @@
[
{
"id": "debed60bf171318a",
"type": "subflow",
"name": "ARI Caller",
"info": "`EndPoint` \r\nPhone/Extention that rings\r\n\r\n`Extention` \r\nPhone/Extention that gets connected after answer \r\nMost likely it will play a message ",
"category": "",
"in": [{ "x": 40, "y": 40, "wires": [{ "id": "0c497bbfbb3e3e0e" }] }],
"out": [
{ "x": 520, "y": 40, "wires": [{ "id": "0f9bb285c2559f1c", "port": 0 }] }
],
"env": [
{
"name": "",
"type": "str",
"value": "Spacer",
"ui": { "type": "none" }
},
{
"name": "",
"type": "str",
"value": "ServerSettings",
"ui": {
"icon": "font-awesome/fa-server",
"label": { "en-US": "ARI Server" },
"type": "none"
}
},
{
"name": "ariServer",
"type": "str",
"value": "192.168.2.20",
"ui": {
"label": { "en-US": "IP" },
"type": "input",
"opts": { "types": ["str"] }
}
},
{
"name": "ariPort",
"type": "num",
"value": "8088",
"ui": {
"label": { "en-US": "Port" },
"type": "input",
"opts": { "types": ["num"] }
}
},
{
"name": "",
"type": "str",
"value": "Spacer",
"ui": { "type": "none" }
},
{
"name": "",
"type": "str",
"value": "ServerCredentials",
"ui": {
"icon": "font-awesome/fa-user",
"label": { "en-US": "ARI Credentials" },
"type": "none"
}
},
{
"name": "ariUser",
"type": "str",
"value": "",
"ui": {
"label": { "en-US": "ARI User" },
"type": "input",
"opts": { "types": ["str"] }
}
},
{
"name": "ariPassword",
"type": "cred",
"ui": {
"label": { "en-US": "ARI Password" },
"type": "input",
"opts": { "types": ["cred"] }
}
},
{
"name": "",
"type": "str",
"value": "Spacer",
"ui": { "type": "none" }
},
{
"name": "",
"type": "str",
"value": "CallSettings",
"ui": {
"icon": "font-awesome/fa-phone",
"label": { "en-US": "Call Setting" },
"type": "none"
}
},
{
"name": "endpoint",
"type": "num",
"value": "",
"ui": {
"label": { "en-US": "EndPoint" },
"type": "input",
"opts": { "types": ["num"] }
}
},
{
"name": "extention",
"type": "num",
"value": "",
"ui": {
"label": { "en-US": "Extention" },
"type": "input",
"opts": { "types": ["num"] }
}
},
{
"name": "CallerID",
"type": "str",
"value": "NodeRed <0>",
"ui": { "label": { "en-US": "Caller ID" } }
}
],
"meta": { "author": "brammp <dev@bprieshof.nl>", "desc": "ARI Caller" },
"color": "#3FADB5",
"icon": "font-awesome/fa-phone"
},
{
"id": "0f9bb285c2559f1c",
"type": "http request",
"z": "debed60bf171318a",
"name": "Send ARI request",
"method": "POST",
"ret": "txt",
"paytoqs": "ignore",
"url": "",
"tls": "",
"persist": false,
"proxy": "",
"insecureHTTPParser": false,
"authType": "basic",
"senderr": false,
"headers": [
{
"keyType": "other",
"keyValue": "Content-Type",
"valueType": "other",
"valueValue": "application/x-www-form-urlencoded"
}
],
"x": 390,
"y": 40,
"wires": [[]]
},
{
"id": "0c497bbfbb3e3e0e",
"type": "function",
"z": "debed60bf171318a",
"name": "Prepair ARI request",
"func": "var call={\n url: env.get(\"ariServer\") + \":\" + env.get(\"ariPort\") + \"/ari/channels\",\n payload:{ \n 'endpoint': 'PJSIP/' + env.get(\"endpoint\"),\n 'extension': env.get(\"extention\"),\n 'context': 'from-internal',\n 'callerId': env.get(\"CallerID\")\n }\n\n};\nreturn call;\n\n\n\n\n",
"outputs": 1,
"timeout": 0,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 170,
"y": 40,
"wires": [["0f9bb285c2559f1c"]]
},
{
"id": "603f44a955e26689",
"type": "subflow:debed60bf171318a",
"z": "5b5de3f9b5eae1d7",
"name": "",
"x": 80,
"y": 60,
"wires": [[]]
}
]