team-telnyx / telnyx-java

Java SDK for the Telnyx API
10 stars 20 forks source link

Expected a string but was BEGIN_OBJECT at line 9 column 14 path $.data.from #1

Closed Izimbergenov closed 4 years ago

Izimbergenov commented 4 years ago

Screenshot_1

I wrote code from sample. But got: com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected a string but was BEGIN_OBJECT at line 9 column 14 path $.data.from at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$Adapter.read(ReflectiveTypeAdapterFactory.java:226) at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$1.read(ReflectiveTypeAdapterFactory.java:131) at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$Adapter.read(ReflectiveTypeAdapterFactory.java:222) at com.google.gson.Gson.fromJson(Gson.java:932) at com.google.gson.Gson.fromJson(Gson.java:897) at com.google.gson.Gson.fromJson(Gson.java:846) at io.swagger.client.JSON.deserialize(JSON.java:134) at io.swagger.client.ApiClient.deserialize(ApiClient.java:710) at io.swagger.client.ApiClient.handleResponse(ApiClient.java:913) at io.swagger.client.ApiClient.execute(ApiClient.java:840) at io.swagger.client.api.MessagesApi.createMessageWithHttpInfo(MessagesApi.java:266) at io.swagger.client.api.MessagesApi.createMessage(MessagesApi.java:252)

Anyway sms was delivered

Izimbergenov commented 4 years ago

Now works