refresh_token call always responds with 404

35 views
Skip to first unread message

Ayush Goel

unread,
Nov 16, 2014, 7:15:04 AM11/16/14
to checkv...@googlegroups.com
When I do a POST request to 

https://checkvist.com/auth/refresh_token.json with parameters [old_token: `my_token`] I always get a 404 response with "old_token parameter is not valid" as response string. 

Response:

URL: https://checkvist.com/auth/refresh_token.json

status code: 404, headers {

    "Cache-Control" = "no-cache";

    Connection = "keep-alive";

    "Content-Type" = "application/json; charset=utf-8";

    Date = "Sun, 16 Nov 2014 12:11:39 GMT";

    Server = "nginx/1.2.3";

    "Set-Cookie" = "_cv_session=BAh7B0kiD3Nlc3Npb25faWQGOgZFVEkiJTcyNzEyN2I5MzcwNjE0Nzg3ZmJkYTJjNDNiYWZlMmE4BjsAVEkiDHVzZXJfaWQGOwBGaQMHHwE%3D--a51a75085dde28ae8867351f7f5b83ea3c3b7c98; path=/; expires=Sun, 16-Nov-2014 13:11:39 GMT; HttpOnly";

    Status = "404 Not Found";

    "Transfer-Encoding" = Identity;

    "X-Rack-Cache" = "invalidate, pass";

    "X-Request-Id" = aabf154b0954f784d126767801333b89;

    "X-Runtime" = "0.012647";

    "X-UA-Compatible" = "IE=Edge,chrome=1";

} }


Reply back if you need any more details..

KIR

unread,
Nov 16, 2014, 12:28:27 PM11/16/14
to checkv...@googlegroups.com
Hello,

   I've just checked - refresh_token works correctly for me. Did you get the 'my_token' from the login.json call? 
   You should get the initial token with login.json, and you can refresh the obtained token using refresh_token call.

   Please note, that the refresh_token call works only once with given single old_token, so if you refreshed token correctly, the old_token expires and won't work anymore. 

   Hope this helps,
   KIR

Ayush Goel

unread,
Nov 19, 2014, 1:48:41 AM11/19/14
to checkv...@googlegroups.com
Thanks KIR,

I checked with curl and found the call to be working correctly! This helped me get to the bug I had in parsing the response token from login call. Everything Fixed! Thank! :)

--
Regards,
Ayush
Reply all
Reply to author
Forward
0 new messages