Spy just a range of extensions

Home » Asterisk Users » Spy just a range of extensions
Asterisk Users 2 Comments

Alejandro,

I am using here the ExtenSpy() function, and it works very well.

I just change my dialout context to:



exten => _XXXXXXX,n,Set(SPYGROUP=callcenter)

And made a change to the callcenter context of the agents:

[monitoramento_callcenter]
exten => 88,1,Authenticate(12345|a|5)
exten => 88,n,ExtenSpy(,g(callcenter))
exten => 88,n,Hangup

The trick is on the SPYGROUP definition.

Best regards.

2 thoughts on - Spy just a range of extensions

  • Hi Alejandro,

    if you use 1.6.2.X look at e(ext) option

    With this option you can spy only the extensions you define, separate with :
    delimiter.

    Example:

    exten -> Chanspy,1,(all,e(9000:9001:9002:9002)

    I don’t test this option but I think work.

    Regards

  • Dear Bakko, I use this lines in order to listen and whisper:

    [custom-spy]
    ; Listen
    exten => _*84.,1,Set(SPY=${EXTEN:3})
    exten => _*84.,n,NoOp(spy an agent: ${SPY})
    exten => _*84.,n,ChanSpy(Agent/${SPY},q)
    exten => _*84.,n,Hangup

    ; Whisper
    exten => _*85.,1,Set(SPY=${EXTEN:3})
    exten => _*85.,n,NoOp(whisper an agent: ${SPY})
    exten => _*85.,n,ChanSpy(Agent/${SPY},w)
    exten => _*85.,n,Hangup

    Where do I have to add the e(ext) option here ???

    Thanks a lot again !!!

    2011/8/22 bakko