verify credentials.json url not returning any data

robert_madden
@robert_madden Robert Madden

url = "http://api.twitter.com/1/account/verify_credentials.json";
TwitterUser user = Json.Deserialise(oAuth.oAuthWebRequest(oAuthTwitter.Method.GET, url, String.Empty));

It was working before Twitter went down on Thursday.
any ideas?

The xml alternative is working:
url = "http://twitter.com/account/verify_credentials.xml";
xml = oAuth.oAuthWebRequest(oAuthTwitter.Method.GET, url, String.Empty);
apiResponse.InnerHtml = Server.HtmlEncode(xml);

How do you extract the user id from the xml and send it to a string?
i.e convert xml to string

1 week 1 day ago

Replies

episod
@episod Taylor Singletary

Is there an error you're getting in response? Have you tried making the request outside of your library code directly? Are you doing any kind of error handling?

Avoid any URLs without the subdomain "api" in them when making API requests. They will not work as you may expect.

1 week 1 day ago
robert_madden
@robert_madden Robert Madden

I found the problem. I had a few lines commented out in Json.cs

I commented it out because this namespace is not being recognised becuase its not compatible with .Net2
using System.Runtime.Serialization.Json;
//The type or namespace Json does not exist in the namespace System.Runtime.Serialization

The xml alternative
url = "http://twitter.com/account/verify_credentials.xml";
xml = oAuth.oAuthWebRequest(oAuthTwitter.Method.GET, url, String.Empty);
apiResponse.InnerHtml = Server.HtmlEncode(xml);

How do you extract the user id from the xml and send it to a string?
i.e convert xml to string

5 days 13 hours ago