0.2.0
Keepalive command.
A 'Ping' action will elicit a 'Pong' response. Used to keep the
manager connection open.
0.9.0
Control Event Flow.
If all events should be sent.
If no events should be sent.
To select which flags events should have to be sent.
Enable/Disable sending of events to this manager client.
0.2.0
Logoff Manager.
Logoff the current manager session.
[Login]
0.2.0
Login Manager.
ActionID for this transaction. Will be returned.
Username to login with as specified in manager.conf.
Authorization type. Valid values are:
Plain text secret. (default)
MD5 hashed secret.
Plain text secret to login with as specified in manager.conf.
Key to use with MD5 authentication. To create the key, you must
initialize a new MD5 hash, call the Challenge AMI action,
update the hash with the response, then update the hash with the secret as specified
in manager.conf. The key value must be the final result of the hash
as a 32 character lower-case hex string without any "0x" prepended.
See the description for an example of creating a key in Python.
Login Manager.
import hashlib
m = hashlib.md5()
m.update(response_from_challenge)
m.update(your_secret)
key = m.hexdigest()
## '031edd7d41651593c5fe5c006fa5752b'
[Challenge]
[Logoff]
0.4.0
Generate Challenge for MD5 Auth.
Digest algorithm to use in the challenge. Valid values are:
Generate a challenge for MD5 authentication.
0.2.0
Hangup channel.
The exact channel name to be hungup, or to use a regular expression, set this parameter to: /regex/
Example exact channel: SIP/provider-0000012a
Example regular expression: /^SIP/provider-.*$/
Numeric hangup cause.
Hangup a channel.
0.2.0
List channel status.
The name of the channel to query for status.
Comma , separated list of variable to include.
If set to "true", the Status event will include all channel variables for
the requested channel(s).
Will return the status information of each channel along with the
value for the specified channel variables.
18.26.0
20.11.0
21.6.0
22.1.0
Raised in response to a Status command.
Type of channel
Dialed number identifier
Absolute lifetime of the channel
Identifier of the bridge the channel is in, may be empty if not in one
Application currently executing on the channel
Data given to the currently executing channel
Media formats the connected party is willing to send or receive
Media formats that frames from the channel are received in
Translation path for media received in native formats
Media formats that frames to the channel are accepted in
Translation path for media sent to the connected party
Configured call group on the channel
Configured pickup group on the channel
Number of seconds the channel has been active
[Status]
18.26.0
20.11.0
21.6.0
22.1.0
Raised in response to a Status command.
Number of Status events returned
[Status]
1.0.0
Sets a channel variable or function value.
Channel to set variable for.
Variable name, function or expression.
Variable or function value.
This command can be used to set the value of channel variables or dialplan
functions.
If a channel name is not provided then the variable is considered global.
[Getvar]
1.0.0
Gets a channel variable or function value.
Channel to read variable from.
Variable name, function or expression.
Get the value of a channel variable or function return.
If a channel name is not provided then the variable is considered global.
[Setvar]
1.4.0
Retrieve configuration.
Configuration filename (e.g. foo.conf).
Category in configuration file.
A comma separated list of
name_regex=value_regex
expressions which will cause only categories whose variables match all expressions
to be considered. The special variable name TEMPLATES
can be used to control whether templates are included. Passing
include as the value will include templates
along with normal categories. Passing
restrict as the value will restrict the operation to
ONLY templates. Not specifying a TEMPLATES expression
results in the default behavior which is to not include templates.
This action will dump the contents of a configuration
file by category and contents or optionally by specified category only.
In the case where a category name is non-unique, a filter may be specified
to match only categories with matching variable values.
[GetConfigJSON]
[UpdateConfig]
[CreateConfig]
[ListCategories]
1.6.0
Retrieve configuration (JSON format).
Configuration filename (e.g. foo.conf).
Category in configuration file.
This action will dump the contents of a configuration file by category
and contents in JSON format or optionally by specified category only.
This only makes sense to be used using rawman over the HTTP interface.
In the case where a category name is non-unique, a filter may be specified
to match only categories with matching variable values.
[GetConfig]
[UpdateConfig]
[CreateConfig]
[ListCategories]
1.4.0
Update basic configuration.
Configuration filename to read (e.g. foo.conf).
Configuration filename to write (e.g. foo.conf)
Whether or not a reload should take place (or name of specific module).
Whether the effective category contents should be preserved on template change. Default is true (pre 13.2 behavior).
Action to take.
0's represent 6 digit number beginning with 000000.
Category to operate on.
Variable to work on.
Value to work on.
Extra match required to match line.
Line in category to operate on (used with delete and insert actions).
A comma separated list of action-specific options.
One or more of the following...
Allow duplicate category names.
This category is a template.
Templates from which to inherit.
The following actions share the same options...
catfilter is most useful when a file
contains multiple categories with the same name and you wish to
operate on specific ones instead of all of them.
This action will modify, create, or delete configuration elements
in Asterisk configuration files.
[GetConfig]
[GetConfigJSON]
[CreateConfig]
[ListCategories]
1.6.0
Creates an empty file in the configuration directory.
The configuration filename to create (e.g. foo.conf).
This action will create an empty file in the configuration
directory. This action is intended to be used before an UpdateConfig
action.
[GetConfig]
[GetConfigJSON]
[UpdateConfig]
[ListCategories]
1.6.0
List categories in configuration file.
Configuration filename (e.g. foo.conf).
This action will dump the categories in a given file.
[GetConfig]
[GetConfigJSON]
[UpdateConfig]
[CreateConfig]
0.2.0
Redirect (transfer) a call.
Channel to redirect.
Second call leg to transfer (optional).
Extension to transfer to.
Extension to transfer extrachannel to (optional).
Context to transfer to.
Context to transfer extrachannel to (optional).
Priority to transfer to.
Priority to transfer extrachannel to (optional).
Redirect (transfer) a call.
[BlindTransfer]
1.6.1.0
Attended transfer.
Transferer's channel.
Extension to transfer to.
Context to transfer to.
Attended transfer.
[AttendedTransfer]
15.1.0
14.7.0
13.18.0
Cancel an attended transfer.
The transferer channel.
Cancel an attended transfer. Note, this uses the configured cancel attended transfer
feature option (atxferabort) to cancel the transfer. If not available this action will fail.
[AttendedTransfer]
0.2.0
Originate a call.
Channel name to call.
Extension to use (requires Context and
Priority)
Context to use (requires Exten and
Priority)
Priority to use (requires Exten and
Context)
Application to execute.
Data to use (requires Application).
How long to wait for call to be answered (in ms.).
Caller ID to be set on the outgoing channel.
Channel variable to set, multiple Variable: headers are allowed.
Account code.
Set to true to force call bridge on early media..
Set to true for fast origination.
Comma-separated list of codecs to use for this call.
Channel UniqueId to be set on the channel.
Channel UniqueId to be set on the second local channel.
PreDialGoSub Context,Extension,Priority to set options/headers needed before start the outgoing extension
Generates an outgoing call to a
Extension/Context/Priority
or Application/Data
[OriginateResponse]
18.26.0
20.11.0
21.6.0
22.1.0
Raised in response to an Originate command.
[Originate]
0.3.0
Execute Asterisk CLI Command.
Asterisk CLI command to run.
Run a CLI command.
0.4.0
Check Extension Status.
Extension to check state on.
Context for extension.
Report the extension state for given extension. If the extension has a hint,
will use devicestate to check the status of the device connected to the extension.
Will return an Extension Status message. The response will include
the hint for the extension and the status.
[ExtensionStatus]
11.0.0
Check Presence State
Presence Provider to check the state of
Report the presence state for the given presence provider.
Will return a Presence State message. The response will include the
presence state and, if set, a presence subtype and custom message.
[PresenceStatus]
0.5.0
Set absolute timeout.
Channel name to hangup.
Maximum duration of the call (sec).
Hangup a channel after a certain time. Acknowledges set time with
Timeout Set message.
0.4.0
Check mailbox.
Full mailbox ID mailbox@vm-context.
Checks a voicemail account for status.
Returns whether there are messages waiting.
Message: Mailbox Status.
Mailbox: mailboxid.
Waiting: 0 if messages waiting, 1
if no messages waiting.
[MailboxCount]
0.5.0
Check Mailbox Message Count.
Full mailbox ID mailbox@vm-context.
Checks a voicemail account for new messages.
Returns number of urgent, new and old messages.
Message: Mailbox Message Count
Mailbox: mailboxid
UrgentMessages: count
NewMessages: count
OldMessages: count
[MailboxStatus]
1.0.0
List available manager commands.
Returns the action name and synopsis for every action that
is available to the user.
1.6.0
Sends a text message to channel. A content type can be optionally specified. If not set
it is set to an empty string allowing a custom handler to default it as it sees fit.
Channel to send message to.
Message to send.
The type of content in the message
Sends A Text Message to a channel while in a call.
[SendText]
1.4.0
Send an arbitrary event.
Event string to send.
Content1.
ContentN.
Send an event to manager sessions.
[UserEvent]
[UserEvent]
1.4.0
Wait for an event to occur.
Maximum time (in seconds) to wait for events, -1 means forever.
This action will elicit a Success response. Whenever
a manager event is queued. Once WaitEvent has been called on an HTTP manager
session, events will be generated and queued.
1.6.0
Show PBX core settings (version etc).
Query for Core PBX settings.
1.6.0
Show PBX core status variables.
Query for Core PBX status.
1.6.0
Send a reload event.
Name of the module to reload.
Send a reload event.
[ModuleLoad]
18.26.0
20.11.0
21.6.0
22.1.0
Raised in response to a CoreShowChannels command.
Identifier of the bridge the channel is in, may be empty if not in one
Application currently executing on the channel
Data given to the currently executing application
The amount of time the channel has existed
[CoreShowChannels]
[CoreShowChannelsComplete]
18.26.0
20.11.0
21.6.0
22.1.0
Raised at the end of the CoreShowChannel list produced by the CoreShowChannels command.
Conveys the status of the command response list
The total number of list items produced
[CoreShowChannels]
[CoreShowChannel]
1.6.0
List currently active channels.
List currently defined channels and some information about them.
18.26.0
20.11.0
21.6.0
22.1.0
Raised at the end of the CoreShowChannelMap list produced by the CoreShowChannelMap command.
Conveys the status of the command response list
The total number of list items produced
20.4.0
18.19.0
List all channels connected to the specified channel.
The channel to get the mapping for. Requires a channel name.
List all channels currently connected to the specified channel. This can be any channel, including
Local channels, and Local channels will be followed through to their other half.
13.0.0
Reload and rotate the Asterisk logger.
Reload and rotate the logger. Analogous to the CLI command 'logger rotate'.
1.6.0
Module management.
Asterisk module name (including .so extension) or subsystem identifier:
The operation to be done on module. Subsystem identifiers may only
be reloaded.
Completely unload and load again a specified module.
If no module is specified for a reload loadtype,
all modules are reloaded.
For refresh operations, attempt to recursively
unload any other modules that are dependent on this module, if that would
allow it to successfully unload, and load them again afterwards.
Loads, unloads or reloads an Asterisk module in a running system.
[Reload]
[ModuleCheck]
1.6.0
Check if module is loaded.
Asterisk module name (not including extension).
Checks if Asterisk module is loaded. Will return Success/Failure.
An empty Version header is also returned (which doesn't contain
the module revision number).
[ModuleLoad]
1.8.0
Generate an Advice of Charge message on a channel.
Channel name to generate the AOC message on.
This value is required unless ChannelPrefix is given.
Partial channel prefix. By using this option one can match the beginning part
of a channel name without having to put the entire name in. For example
if a channel name is SIP/snom-00000001 and this value is set to SIP/snom, then
that channel matches and the message will be sent. Note however that only
the first matched channel has the message sent on it.
Defines what type of AOC message to create, AOC-S, AOC-D or AOC-E
Defines what kind of charge this message represents for AOC-D and AOC-E.
This represents the amount of units charged. The ETSI AOC standard specifies that
this value along with the optional UnitType value are entries in a list. To accommodate this
these values take an index value starting at 0 which can be used to generate this list of
unit entries. For example, If two unit entries were required this could be achieved by setting the
parameter UnitAmount(0)=1234 and UnitAmount(1)=5678. Note that UnitAmount at index 0 is
required when ChargeType=Unit, all other entries in the list are optional.
Defines the type of unit. ETSI AOC standard specifies this as an integer
value between 1 and 16, but this value is left open to accept any positive
integer. Like the UnitAmount parameter, this value represents a list entry
and has an index parameter that starts at 0.
Specifies the currency's name. Note that this value is truncated after 10 characters.
Specifies the charge unit amount as a positive integer.
This value is required when ChargeType==Currency (AOC-D or AOC-E) or
RateType==Duration/Flat/Volume (AOC-S).
Specifies the currency multiplier.
This value is required when CurrencyAmount is given.
Defines what kind of AOC-D total is represented.
Represents a billing ID associated with an AOC-D or AOC-E message. Note
that only the first 3 items of the enum are valid AOC-D billing IDs
Charging association identifier. This is optional for AOC-E and can be
set to any value between -32768 and 32767
Represents the charging association party number. This value is optional
for AOC-E.
Integer representing the charging plan associated with the ChargingAssociationNumber.
The value is bits 7 through 1 of the Q.931 octet containing the type-of-number and
numbering-plan-identification fields.
Defines what part of the call is charged in AOC-S. Usually this is set to
BasicCommunication, which refers to the time after the call is answered, but establishment
(CallAttempt) or successful establishment (CallSetup) of a call can also be used.
Other options are available, but these generally do not carry enough information to actually
calculate the price of a call.
It is possible to have multiple ChargedItem entries for a single call -- for example to
charge for both the establishment of the call and the actual call. In this case, each
ChargedItem is described by a ChargedItem: header and all other headers that follow it up to
the next ChargedItem: header.
Defines how an AOC-S ChargedItem is charged.
The Duration option is only available when ChargedItem==BasicCommunication.
Specifies a positive integer which is the amount of time is paid for by one
CurrencyAmount.
This value is required when RateType==Duration.
Specifies the time multiplier.
This value is required when Time is given.
Specifies a positive integer which is the size of the charged time increments.
This value is optional when RateType==Duration and ChargingType==StepFunction.
Specifies the granularity time multiplier.
This value is required when Granularity is given.
Specifies whether the charge increases continuously with time or in increments of
Time or, if provided, Granularity.
This value is required when RateType==Duration.
Specifies the quantity of which one unit is paid for by one CurrencyAmount.
This value is required when RateType==Volume.
Specifies the charging code, which can be set to a value between 1 and 10.
This value is required when ChargedItem==SpecialArrangement or RateType==SpecialCode.
Generates an AOC-S, AOC-D or AOC-E message on a channel.
[AOC-S]
[AOC-D]
[AOC-E]
11.0.0
Checks attributes of manager accounts
Login name, specified in manager.conf
The manager account attribute to return
The number of sessions for this AMI account
Currently, the only supported parameter is "sessions" which will return the current number of
active sessions for this AMI account.
10.0.0
Dynamically add filters for the current manager session.
Add a filter.
Advanced match criteria. If not specified, the Filter
parameter is assumed to be a regular expression and will be matched against
the entire event payload.
Syntax: [name(<event_name>)][,header(<header_name>)][,<match_method>]
One of each of the following may be specified separated by commas.
Instead of prefixing the Filter with ! to exclude matching events,
specify action(exclude). Although the default is include
if action isn't specified, adding action(include)
will help with readability.
Only events with name event_name will be included.
Only events containing a header with a name of header_name
will be included and the Filter parameter (if supplied) will only be
matched against the value of the header.
Specifies how the Filter parameter
is to be applied to the results of applying any
name(<event_name>) and/or
header(<header_name>) parameters
above.
One of the following:
The Filter parameter contains a regular expression
which will be matched against the result. (default)
The Filter parameter contains a string which must
exactly match the entire result.
The Filter parameter contains a string which must
match the beginning of the result.
The Filter parameter contains a string which must
match the end of the result.
The Filter parameter contains a string
which will be searched for in the result.
The Filter parameter is ignored.
The match expression to be applied to the event.
See the manager.conf.sample file in the configs/samples
directory of the Asterisk source tree for more information.
See the manager.conf.sample file in the configs/samples
directory of the Asterisk source tree for a full description
and examples.
The filters added are only used for the current session.
Once the connection is closed the filters are removed.
This command requires the system permission because
this command can be used to create filters that may bypass
filters defined in manager.conf
12.0.0
Blind transfer channel(s) to the given destination
Redirect all channels currently bridged to the specified channel to the specified destination.
[Redirect]
[BlindTransfer]
18.26.0
20.11.0
21.6.0
22.1.0
Raised when a hint changes due to a device state change.
Name of the extension.
Context that owns the extension.
Hint set for the extension
Numerical value of the extension status. Extension
status is determined by the combined device state of all items
contained in the hint.
The extension was removed from the dialplan.
The extension's hint was removed from the dialplan.
Idle - Related device(s) are in an idle
state.
InUse - Related device(s) are in active
calls but may take more calls.
Busy - Related device(s) are in active
calls and may not take any more calls.
Unavailable - Related device(s) are
not reachable.
Ringing - Related device(s) are
currently ringing.
InUse&Ringing - Related device(s)
are currently ringing and in active calls.
Hold - Related device(s) are
currently on hold.
InUse&Hold - Related device(s)
are currently on hold and in active calls.
Text representation of Status.
Status does not match any of the above values.
[ExtensionState]
18.26.0
20.11.0
21.6.0
22.1.0
Raised when a hint changes due to a presence state change.
[PresenceState]