Legend

Forum

Unread topics or posts

Topic

Unread posts

Locked

Announcement

Forums > Developers

Get XML



AuthorMessage
rodrigomjuarez

Posted: Nov 09, 2010
Score: 0



Hi

How can I get an xml result when I trying to get a token
I'm using visual studio 2010 with csharp

The following code returns a JSON result

var requestUrl = "http://api.toodledo.com/2/account/token.php?userid={0};appid={1};vers=0;device=testing;sig={2}";
requestUrl = string.Format(requestUrl, Userid, Appid, ExpectedMd5);

var req = (HttpWebRequest)WebRequest.Create(requestUrl);
req.Method = "GET";
req.ContentType = "text/xml; encoding='utf-8'";

Thanks in advance
Toodledo

Administrator
Posted: Nov 09, 2010
Score: 1



You can pass f=xml to any API call to get XML instead of JSON. I'll make sure this is more clear in the docs.

http://api.toodledo.com/2/account/token.php?f=xml;userid={0};appid={1};vers=0;device=testing;sig={2}


To participate in these forums, you must be signed in.



Toodledo Forums > Developers

Contact Us | Blog | API | Help | Forums Privacy | Terms | Copyright © 2006-2012