Adding subdomain to OAuth valid redirect urls

1,127 views
Skip to first unread message

assaf

unread,
Oct 25, 2015, 12:07:28 PM10/25/15
to AdWords API Forum, Assaf - Easyleads, di...@easyleads.com
Hi,

We have a developer token with enabled Adwords API. Recently we decided to allow customers to authorize using the OAuth protocol. It's working fine when in the redirect_uri we specify is http://ourdomain.com or http://localhost, but fails on http://app.ourdomain.com

400. That’s an error.

Error: redirect_uri_mismatch

A native application: xxx

You can email the developer of this application at: yyy

Request Details

That’s all we know.

As far as we understand this uri (subdomain) should be authorized somewhere in the Developers Console, but we don't see this option. Just for test purposes we created a new Client of type Web Application and it indeed has a section called Authorized redirect URIs, but it's missing in the our original Client which is of type Other.


How can we solve this while preserving all the permissions we have in the original client? Should we migrate it from Other to Web application?

Thanks

Josh Radcliff (AdWords API Team)

unread,
Oct 26, 2015, 1:54:05 PM10/26/15
to AdWords API Forum, as...@easyleads.com, di...@easyleads.com
Hi,

The flow you described sounds like a Web application flow to me, rather than an Other/Native application flow. The Web flow will allow you to enter multiple redirect URIs, as you noted.

I'd recommend switching over to the Web application client ID and secret, then adding all required redirect URIs to that application.

Cheers,
Josh, AdWords API Team

assaf

unread,
Oct 28, 2015, 9:51:44 AM10/28/15
to AdWords API Forum, as...@easyleads.com, di...@easyleads.com
Thanks, we did it and seems to work. I thought that adding a new client will require to pass the approval process for developer token again.
Reply all
Reply to author
Forward
0 new messages