私はこのコードを持っています:
val voice = new Voice("<un>", "<pw>")
voice.login()
// The ID isn't specced well in the source code, not sure what it needs to be
voice.sendSMS("<number>", "hello", "343434")
ブラウザでこのエラーがスローされます (Play 2.0):
Server returned HTTP response code: 500 for URL: https://www.google.com/voice/b/0/sms/send/]
スタックトレースは次のとおりです。
[info] play - Application started (Dev)
[info] application - index:
https://www.google.com/accounts/ClientLogin - OK
Logged in to Google - Auth token received
https://www.google.com/voice/b/0/settings/tab/phones - OK
https://www.google.com/voice/b/0 - OK
Successfully Received rnr_se.
smsdata: id=hello&phoneNumber=XXXXXXXX&conversationId=343434&text=hello&_rnr_se=XXXXXXXXXXXXXXX
[error] application -
! @6an08o8h8 - Internal server error, for request [GET /smsTest] ->
play.core.ActionInvoker$$anonfun$receive$1$$anon$1: Execution exception [[IOException: Server returned HTTP response code: 500 for URL: https://www.google.com/voice/b/0/sms/send/]]
at play.core.ActionInvoker$$anonfun$receive$1.apply(Invoker.scala:134) [play_2.9.1.jar:2.0.1]
at play.core.ActionInvoker$$anonfun$receive$1.apply(Invoker.scala:115) [play_2.9.1.jar:2.0.1]
at akka.actor.Actor$class.apply(Actor.scala:311) [akka-actor.jar:2.0.1]
at play.core.ActionInvoker.apply(Invoker.scala:113) [play_2.9.1.jar:2.0.1]
at akka.actor.ActorCell.invoke(ActorCell.scala:619) [akka-actor.jar:2.0.1]
at akka.dispatch.Mailbox.processMailbox(Mailbox.scala:196) [akka-actor.jar:2.0.1]
Caused by: java.io.IOException: Server returned HTTP response code: 500 for URL: https://www.google.com/voice/b/0/sms/send/
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1436) ~[na:1.6.0_31]
at sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:234) ~[na:1.6]
at com.techventus.server.voice.Voice.sendSMS(Voice.java:1669) ~[google-voice-java-1.14.jar:na]
at controllers.Application$$anonfun$smsTest$1.apply(Application.scala:47) ~[classes/:na]
at controllers.Application$$anonfun$smsTest$1.apply(Application.scala:45) ~[classes/:na]
at play.api.mvc.Action$$anon$1.apply(Action.scala:170) ~[play_2.9.1.jar:2.0.1]
[info] Compiling 1 Scala source to /Users/franklovecchio/Desktop/dev/applications-voip/target/scala-2.9.1/classes...
最新の jarを使用しています。
現在、SMSを送信できる人はいますか?