Synopsis
Starts a call from the CLI and links it to an application or context.
Description
There are two ways to use this command. A call can be originated between a channel and a specific application, or between a channel and an extension in the dialplan. This is similar to call files or the manager originate action.
originate <tech/data> application <appname> [appdata]
This will originate a call between the specified channel and the given application. Arguments to the application are optional.
originate <tech/data> extension [<exten>@][<context>]
This will originate a call between the specified channel and the given extension. If no context is specified, the ‘default’ context will be used. If no extension is given, the ‘s’ extension will be used.
NOTE:
As of Asterisk 1.6 the new syntax for originating calls from the CLI is:
channel originate <tech/data> application <appname> [appdata]
channel originate <tech/data> extension [<exten>@][<context>]
Example
In extensions.conf
[greeting]]
exten => 400,1,Answer
exten => 400,n,Background("hello")
exten => 400,n,Wait(5)
exten => 400,n,HangUp()
Then in CLI:
originate Zap/1/123456 extension 400@greeting
This can be used from external scripts like this: asterisk -rx “originate zap/1/123456 extension 1@greeting”
See also
- Asterisk cmd Originate as introduced with Asterisk 1.6.2
- Asterisk auto-dial out using .call files