SOLVED

"Invalid cookie value" when calling REST API leads

Go to solution
Anonymous
Not applicable
I'm trying to get the lead information for the current user in a website, using this REST API: Get Multiple Leads By Filter Type

I have the right authentication token ( I am able to call other entries, i.e. /lead/{id}.json ) but whenever I call the "leads" resource with filterType=cookie&filterValues=xxxxxxxxxxxxxx I get a JSON error response with this value in the message property:
Invalid cookie value 'id:561-HYG-937&token:_mch-marketo.com-1415884534947-30230'
I have encoded the '&' inside the cookie value as %26, and it is reaching the API correctly.  The value stated in the error message matches exactly the value of my _mkto_trk cookie on the 'marketo.com' domain.

Any clue on what I may be doing wrong?
Thanks in advance
Jose
Tags (1)
1 ACCEPTED SOLUTION
Anonymous
Not applicable
For future viewers of this thread, I also updated this developer blog post with the example:
http://developers.marketo.com/blog/get-a-visitors-cookie-id-and-then-query-associated-lead-data/

View solution in original post

14 REPLIES 14