我能夠使用dialplan中繼消息。此命令發送消息,但我似乎無法使用fastagi(JAVA)通過fastagi發送SIP消息星號
撥號方案來運行它
exten => _X.,n,MessageSend(${ACTUALTO},${MESSAGE(from)})
FastAgi
public void service(AgiRequest ar, AgiChannel ac) throws AgiException {
System.out.println(ac.getFullVariable("${MESSAGE(body)}"));
System.out.println(ac.getFullVariable("${MESSAGE(to)}"));
System.out.println(ac.getFullVariable("${MESSAGE(from)}"));
System.out.println(ac.getFullVariable("${CUT(MESSAGE(to),@,1)}"));
//Correct values are show from above printlns
ac.exec("MessageSend(${CUT(MESSAGE(to),@,1)},${MESSAGE(from)})");
}
最後一行導致預警/var/asterisk/messages
WAR寧[2287] [C-00000000] res_agi.c:找不到應用程序(MessageSend($ {CUT(MESSAGE(到),@,1)})