invalid grant when refreshing token.

45 views
Skip to first unread message

Oak Nguyen

unread,
May 8, 2017, 10:39:32 PM5/8/17
to AdWords API Forum
I've read all the other threads of people getting invalid grant when trying to refresh their token but none of the resolution have helped me. The odd behavior here is that we have many other oauth tokens that are working seamlessly but this issue seems to only be happening with just one token. They'll come into our web app to oauth and we'd get the access and refresh token. Everything works fine until we try to refresh the token which then throws the invalid grant response. We've asked the client to reauth again and the same flow would happen. The initial reauth works okay until we refresh and the error throws again.

I've tried to debug the issues regarding this post https://groups.google.com/forum/#!topic/adwords-api/3CY3FUBuy7E, but none of those applies to us. We've talked with the client and we can see that there are only 2 outstanding tokens and ours is not revoked. If there's any insight that you guys can give, it'll be much appreciated. This is quite infuriating in that this is happening to only one of our clients out of the couple hundred we have.  Thanks for the help in advance.

-Oak

P.S We're using the .Net library. 

Peter Oliquino

unread,
May 8, 2017, 11:57:52 PM5/8/17
to AdWords API Forum
Hi Oak,

Access tokens are refreshed automatically when you use any of the AdWords API client libraries. What is manually generated is the refresh token. This said, could you retry and regenerate only your refresh token (by following this guide) and use any of the example codes in the .NET library to check whether the "invalid_grant" issue persists? If you still encounter the issue, could you provide the SOAP request and response and reply to me via Reply privately to author so I can further investigate?

Thanks and regards,
Peter
AdWords API Team
Reply all
Reply to author
Forward
0 new messages