I HAVE A DREAM Command Line Utilities for FreePBX + Drag-and-Drop GUI

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,168
Reaction score
5,199
Since no one else has volunteered, we are beginning the painful process of creating BASH command line utilities to add extensions, trunks, outbound routes, inbound routes, and perhaps other components such as IVRs, call forwarding, etc. to PBX in a Flash and Incredible PBX. See also our earlier work with Phone Genie for other features we plan to incorporate. Should work fine with other FreePBX 2.11-compatible distros , but I'm not testing them!

This will be a slow process as time permits. It's even slower because it requires reverse-engineering numerous pieces of FreePBX code to get things to work with and remain compatible with FreePBX 2.11. As (more) time permits, we will rework the basic components to work with FreePBX 12 as well, but the initial releases HAVE NOT BEEN TESTED AND PROBABLY WILL NOT WORK with FreePBX 12!

If there are other components anyone desperately needs or wants, post a note about what is desired and why. It will then be prioritized on the Wish List. If others wish to contribute GPL2 code, please feel free to jump in.



The long-range objective is to get these command-line utilities built and then hire some off-shore programmers to write a drag-and-drop GUI (see proof-of-concept video) similar to what's available with Anveo, RingRoost, and pbxww.com. See this thread for some examples. See jsPlumb documentation used for proof-of-concept video here. The GUI would hook into these command-line utilities to put the pieces together while remaining compatible with FreePBX. No promises whether it will be GPL2 code or commercial. Kinda depends on the development cost.

 

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,168
Reaction score
5,199
Add SIP Extension with NO Voicemail

Syntax: add-extension-no-vm ext-num ext-pw

License: GPL2

Version: 0.002
 

Attachments

  • add-extension-no-vm.tar.gz
    1.3 KB · Views: 50

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,168
Reaction score
5,199
Add SIP Extension with Voicemail

Syntax: add-extension-vm ext-num ext-pw vm-pw

License: GPL2

Version: 0.002
 

Attachments

  • add-extension-vm.tar.gz
    1.5 KB · Views: 32

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,168
Reaction score
5,199
Call Forwarding

Forward Calls Syntax: call-forward ext-num fwd-num

Cancel Forwarding Syntax: call-forward ext-num cancel/disable/delete

License: GPL2

Version: 0.002
 

Attachments

  • call-forward.tar.gz
    484 bytes · Views: 24

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,168
Reaction score
5,199
Create Sample Trunks

Create Sample Trunks Syntax: create-sample-trunks now

License: GPL2

Version: 0.002

This script should be especially helpful (now) to those installing Incredible PBX for CentOS or Incredible PBX for Ubuntu 14. It creates and then disables the Baker's Dozen Trunks that were included in earlier builds of Incredible PBX 11 for PBX in a Flash servers. Just add your credentials and enable the desired trunks using FreePBX (for now).

Strongly recommend that this only be run on virgin installs until more testing is done. Unless you have 70+ existing trunks, running this script shouldn't step on any of them.:taz:
Vitelity
AxVoice
CallCentric
DIDforSale
FlowRoute
Future-Nine
IPkall
Les.net
LocalPhone
Teliax
VoIP.ms
VoipMyWay
VoipStreet
 

Attachments

  • create-sample-trunks.tar.gz
    2.5 KB · Views: 73

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,168
Reaction score
5,199
Create Vestalink SIP Trunk

Create Syntax: create-vestalink-trunk enabled/disabled acct-number acct-password acct-did

License: GPL2

Version: 0.002
 

Attachments

  • create-vestalink-trunk.tar.gz
    950 bytes · Views: 25

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,168
Reaction score
5,199
List Devices & Extensions

Syntax: list-devices

License: GPL2

Version: 0.002

BzgMi4zIUAAi5s3.jpg:large
 

Attachments

  • list-devices.tar.gz
    365 bytes · Views: 43

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,168
Reaction score
5,199
List Trunks

Syntax: list-trunks

License: GPL2

Version: 0.002

BzgCVrBIcAAWgLl.jpg:large
 

Attachments

  • list-trunks.tar.gz
    387 bytes · Views: 31

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,168
Reaction score
5,199
List Inbound Routes

Syntax: list-inbound-routes

License: GPL2

Version: 0.002

One of the real shortcomings of FreePBX is that there's no way to quickly identify which Trunk is associated with the DID specified in an Inbound Route. Usually, but not always, the DID matching that of the Inbound Route is tacked onto the end of the Trunk's Registration String. But this only applies to registered Trunks. Thus, it is prudent to name Inbound Routes in a way that identifies the Trunk to which each is associated.

Example below shows a Default Inbound Route with a destination of the IVR sample shown here.

BzgM27eIUAAvwLG.jpg:large
 

Attachments

  • list-inbound-routes.tar.gz
    392 bytes · Views: 30

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,168
Reaction score
5,199
List Outbound Routes

Syntax: list-outbound-routes

License: GPL2

Version: 0.002

If you enjoy hairy MySQL queries with 4-table joins, this Bud's for you! In FreePBX parlance, this example shows two Outbound Routes (in seq order as shown in column 1). The first Outbound Route has two Routes specified in its Trunk Sequence (which are displayed in priority order based upon column 6 seq entries). All sequences start with 0. None of the trunks have Outbound CallerID set. Since all of the specified trunks have their disabled flag set on, outbound calls will go nowhere. This is a great troubleshooting tool for outbound call issues. :smartass:

BzgmYFqCYAIugrb.jpg:large
 

Attachments

  • list-outbound-routes.tar.gz
    512 bytes · Views: 39

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,168
Reaction score
5,199
List Users

Syntax: list-users

License: GPL2

Version: 0.002

BzgCDmPIEAA53X8.jpg:large
 

Attachments

  • list-users.tar.gz
    381 bytes · Views: 30

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,168
Reaction score
5,199
List Custom Destinations

Syntax: list-custom-destinations

License: GPL2

Version: 0.002

BzgNSlECAAAZM32.jpg:large
 

Attachments

  • list-custom-destinations.tar.gz
    389 bytes · Views: 27

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,168
Reaction score
5,199
List Misc Destinations

Syntax: list-misc-destinations

License: GPL2

Version: 0.002

BzgALjoCAAAkynI.jpg:large
 

Attachments

  • list-misc-destinations.tar.gz
    376 bytes · Views: 30

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,168
Reaction score
5,199
List Ring Groups

Syntax: list-ring-groups

License: GPL2

Version: 0.002

BzgNlEsCEAEq_Kv.jpg:large
 

Attachments

  • list-ring-groups.tar.gz
    401 bytes · Views: 27

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,168
Reaction score
5,199
List Call Forwarding

Syntax: list-call-forwarding

License: GPL2

Version: 0.002

BzgOJtgIUAAVhFx.jpg:large
 

Attachments

  • list-call-forwarding.tar.gz
    293 bytes · Views: 26

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,168
Reaction score
5,199
List IVRs

Syntax: list-ivrs

License: GPL2

Version: 0.002
BzgBCFnCIAAJWIK.jpg:large
 

Attachments

  • list-ivrs.tar.gz
    419 bytes · Views: 27

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,168
Reaction score
5,199
Here's the Po' Folks one-minute demo of how we envision the drag-and-drop GUI working with the GPL2 components in this thread to generate code for your existing Incredible PBX server.

You would first click on each of the components to create and/or select extensions and trunks for inbound and outbound routes as well as a destination for failed calls and voicemail. This isn't shown in the video. Then you would use drag-and-drop connectors to interconnect the desired components in the way you want them to work (see video demo). Then the software would generate the necessary code to populate the requested setup to your existing Incredible PBX server for operation with Asterisk 11 and FreePBX 2.11.

 

matthew

Guru
Joined
May 22, 2013
Messages
83
Reaction score
26
These are great. Thanks Ward. :)

I have a lot of inbound routes, so I modified your script slightly to show the name of the route and sort by it. This works a little better for me in my own situation.

Code:
mysql -u $DBUSER -p$DBPASS asterisk -e "select description,cidnum,extension,destination from incoming order by description"
 

matthew

Guru
Joined
May 22, 2013
Messages
83
Reaction score
26
I was inspired by this thread, so thought I'd whip up a quick script to do something like it on the cli. There's probably a million ways it could be improved.

show_active_calls
Code:
#!/bin/bash -
echo "A Party          B Party"
asterisk -rx "core show channels concise"|awk -F ! '$6 == "Dial" { print $8"\t"$7 }'|sed -e 's/\t.*\//\t/g' -e 's/,.*$//g'
 

Members online

No members online now.

Forum statistics

Threads
25,780
Messages
167,506
Members
19,199
Latest member
leocipriano
Get 3CX - Absolutely Free!

Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.
Top