Non working some web service api methods

615 views
Skip to first unread message

Salvador García

unread,
Sep 26, 2014, 8:22:23 AM9/26/14
to wireless-s...@googlegroups.com
Hi,

-- http://www.mytaglist.com/ethLogs.asmx/GetMultiTagStatsRaw

System.InvalidOperationException: GetMultiTagStatsRaw Web Service method name is not valid.
   at System.Web.Services.Protocols.HttpServerProtocol.Initialize()
   at System.Web.Services.Protocols.ServerProtocolFactory.Create(Type type, HttpContext context, ...

-- http://www.mytaglist.com/ethLogs.asmx/GetHourlyStats

System.InvalidOperationException: GetHourlyStats Web Service method name is not valid.


--- http://mytaglist.com/ethLogShared.asmx/GetMultiTagStatsRawByUUIDs

System.InvalidOperationException: GetMultiTagStatsRawByUUIDs Web Service method name is not valid.
   at System.Web.Services.Protocols.HttpServerProtocol.Initialize()
   at System.Web.Services.Protocols.ServerProtocolFactory.Create(Type type, HttpContext context, HttpRequest request, HttpResponse response, Boolean& abortProcessing)

NON WORKING EITHER


I need this last method in order not to have to send many request, one for each of the many tags I have.

I need support with this, I'm stuck at this point.
Thank you

mytaglist.com support

unread,
Sep 27, 2014, 3:36:12 AM9/27/14
to wireless-s...@googlegroups.com
I guess none of the API is working for you.

There is something wrong generally with the way you call API.

Are you using cURL tool to call the API or some other client?  Can you share the entire HTTP request header you are sending to the server?

Salvador García

unread,
Sep 27, 2014, 7:10:56 AM9/27/14
to wireless-s...@googlegroups.com
I use Java, HttpUrlConnection class.
I've successfuly log in (get the cookie) which I return in the Cookie header of the post request. Other service methods work.

If I use a browser, the response is: Web Service method name is not valid. For the methods that work, the response is that a parameter is missing.

http://mytaglist.com/ethLogShared.asmx/GetTemperatureRawDataByUUID

System.InvalidOperationException: Missing parameter: id.
at System.Web.Services.Protocols.ValueCollectionParameterReader.Read(NameValueCollection collection)
at System.Web.Services.Protocols.HttpServerProtocol.ReadParameters() at System.Web.Services.Protocols.WebServiceHandler.CoreProcessRequest()

http://mytaglist.com/ethLogShared.asmx/GetMultiTagStatsRawByUUIDs

mytaglist.com support

unread,
Sep 27, 2014, 1:27:01 PM9/27/14
to wireless-s...@googlegroups.com
Below is an example using Java to call the API. You need AsyncHttpClient (http://loopj.com/android-async-http/)

AsyncHttpClient client = new AsyncHttpClient();
this,
MainActivity.WSROOT + "/ethLogs.asmx/GetTemperatureStats2",
new Header[] { new BasicHeader("Cookie", CookieManager.getInstance().getCookie(MainActivity.WSROOT)) },
new StringEntity(String.format("{id:%d}", slaveId)),
RequestParams.APPLICATION_JSON, new JsonHttpResponseHandler() {
@Override
public void onFailure(int statusCode, Header[] headers, Throwable throwable, JSONObject errorResponse) {
try {
MainActivity.instance.showToast(errorResponse.getString("Message"));
} catch (Exception e) {
MainActivity.instance.showToast(throwable.toString());
}
}
@Override
public void onSuccess(int statusCode, Header[] headers, JSONObject response) {
try{
JSONObject data = response.getJSONObject("d");
                                                                }.....
Reply all
Reply to author
Forward
Message has been deleted
0 new messages