[SOLVED] Missing AgentCalled event

Hy everyone!

I have a little problem with Asterisk Agent Events.

I set the required parameters in the Asterisk to get AgentCalled, AgentComplete …etc events on AMI but the AgentLogin is arrived only.

Asterisk 11.2.1

queues.conf

[general]
...
eventwhencalled=yes

manager.conf

[general]
...
read=system,call,log,verbose,command,agent,user,originate,agi
write=system,call,log,verbose,command,agent,user,originate,agi

What did I wrong? What have to set to get AgentCalled event?

Thank you.

Solved!

The eventwhencalled=yes option has to be in the used queue section and not the general section.

…but it’s interensting to asterisk give AgentLogin and AgentLogoff events if the aforementioned option is in the general section.

AgentLogin and Logoff relate to agents, and are handled by chan_agent.c. AgentCalled isn’t really about agents, it is really about queue members, and is handled by app_queue.c.