我能够使用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)})