Quantcast
Channel: VOIP-info.org Wiki Changes
Viewing all articles
Browse latest Browse all 5767

Asterisk cmd PauseQueueMember

$
0
0
Update: in Asterisk 1.4 it has the following details (i.e. you can use an interface rather than an agent):

Synopsis

Pauses a queue member

Description

PauseQueueMember([queuename]|interface[|options]):
In Asterisk 1.8:
PauseQueueMember([queuename],interface,[options],[reason]):
Pauses (blocks calls for) a queue member. The given interface will be paused in the given queue. This prevents any calls from being sent from the queue to the interface until it is unpaused with UnpauseQueueMember or the manager interface. If no queuename is given, the interface is paused in every queue it is a member of. If the interface is not in the named queue, or if no queue is given and the interface is not in any queue, it will jump to priority n+101, if it exists and the appropriate options are set. The application will fail if the interface is not found and no extension to jump to exists.
In Asterisk 1.8 the reason will be logged in the data column of the queue_log.

The option string may contain zero or more of the following characters:
'j' — jump to +101 priority when appropriate.
This application sets the following channel variable upon completion: PQMSTATUS
The status of the attempt to pause a queue member as a text string, one of PAUSED | NOTFOUND

Example:

PauseQueueMember(|SIP/3000)



Synopsis


Pauses a queue member

Description

PauseQueueMember([queuename]|agent[|options]):

Pauses an agent on a queue, i.e. the agent will not receive calls but s/he is still a member of the queue.

If no queue is given, agent is paused on all queues.

The option string may contain zero or more of the following characters:
  • j - jump to priority n+101 if the agent is not a member of the queue

Example

PauseQueueMember(|Agent/101)

Pauses Agent/101 on all queues s/he is a member of.

In extensions.conf:
exten => *11ZXXX,1,PauseQueueMember(|Agent/${EXTEN:3});

If *111001 is dialed, Agent/1001 will be paused on all queues s/he is a member of.


An example macro for pausing the extension that is calling in with a feature code:


[macro-agent-pause]

exten => s,1,Answer
exten => s,1,Wait(1)
exten => s,n,Macro(user-callerid,SKIPTTL,)
exten => s,n,Set(CALLBACKNUM=${AMPUSER})
exten => s,n,PauseQueueMember(|Local/${CALLBACKNUM}@from-internal/n)
exten => s,n,System( echo "${EPOCH}|${UNIQUEID}|NONE|Agent/${CALLBACKNUM}|AGENTPAUSED|-" >> /var/log/asterisk/queue_log )
exten => s,n,UserEvent(RefreshQueue)
exten => s,n,Wait(1)
exten => s,n,Playback(extension)
exten => s,n,SayDigits(${CALLBACKNUM})
exten => s,n,Playback(dictate/paused)
exten => s,n,Wait(1)
exten => s,n,Hangup

; end of [macro-agent-pause]


See also


Viewing all articles
Browse latest Browse all 5767

Trending Articles