Unread topics or posts


Unread posts



Forums > Developers

Adding Tasks with Ref & Errors


Posted: Feb 16, 2013
Score: 0


I seem to have found a potential bug with the add tasks API with regards to the "ref" parameter and an error condition.

The docs say that this parameter is alphanumeric (http://api.toodledo.com/2/tasks/index.php) however this is what I see returned if an error happens:

Post: tasks=[{"ref":"123","note":"hi"}]
Response: [{"errorCode":5,"errorDesc":"No title","ref":"123"}]
This is correct.

However if I use a letter in the reference, I get 0 back in the echoed ref parameter:
Post: tasks=[{"ref":"abc","note":"hi"}]
Response: [{"errorCode":5,"errorDesc":"No title","ref":0}]

Note that however if there is no error, i.e if I did add a title, then the references comes back fine:
Post: tasks=[{"ref":"abc","note":"hi","title":"the title"}]
Response: [{"id":"80749485","title":"the title","modified":1361029585,"completed":0,"ref":"abc"}]

Since I am using guids for references which have alphanumeric characters, it means it is difficult to map back any errors to the appropriate task.


Toodledo Admin
Posted: Feb 18, 2013
Score: 0

Thanks for reporting this bug. I have identified the place where the alphanumeric string is incorrectly getting forced to be a numeric string when an error is being reported. I will get this fixed.

Posted: Feb 20, 2013
Score: 0

Thanks, if you could let me know once it's done that will be great (so that I can switch back to guids etc).

Toodledo Admin
Posted: Feb 20, 2013
Score: 0

It is fixed
You cannot reply yet

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

Toodledo Forums > Developers

Contact Us | Blog | API | Jobs | Press | Documentation | Forums Privacy | Terms | Copyright © 2004-2014