Cisco Support Community
Showing results for 
Search instead for 
Did you mean: 
New Member

CLI commands in TCL IVR

Is it possible to run CLI commands with a TCL IVR script? For now I want to be able to change a parameter that I pass through to a current IVR script, but as I'm thinking about it, it might be cool to have a TCL IVR script authenticate me and allow me to change a connection type.

"Press one for T1 connection, Press 2 for VPN"

and then have it run config commands based on what option I pick. (Sorry guys, just imagining the possibilities out loud...)

I tried executing the "exec" and "ios_config" commands, but that didn't work.

Anybody have an idea on how I can get it them to run?


Re: CLI commands in TCL IVR

I have no experience with TCL but does the language description mention a way to execute cli commands? If there is no specific command/function to do that, then I'd consider it impossible.

I know that router XML (the limited XML API for Callmanager Express) has a command to execute cli commands, but it is limited to a small number of cli commands (and your example would already be too much).

Re: CLI commands in TCL IVR

Hey there,

If you enter the tcl shell on a router, you'd be able to put in these commands:-


r5(tcl)#foreach i {



+>(tcl)#} { puts [ exec "ping $i" ] }

This would then put "ping" and then "ping" on the command line

Hope that helps!


** Please rate all posts **

Hall of Fame Super Gold

Re: CLI commands in TCL IVR


TCL/IVR has no support whatsoever for executing CLI commands.

Because I've this need, I'm writing a module that has an IOS TCL (the one related to EEM) http server that listens to requests from a TCL/IVR client and execute command on its behalf.

I'm not done yet with this, but is definitely on my list of to-do things. I will update here once progress is made.

New Member

Re: CLI commands in TCL IVR

Awesome! Please be sure to let me know on how you got it to work. I wish I could help but I'm very new to scripting on the router side.

Hope to hear from you.


CreatePlease to create content