Hi. We have a multi-tenant application in which we are building support for using the InfusionSoft API. The different customers, on our side, are differentiated by subdomain. So, we have things like
wndr.wearehearken.com
kalw.wearehearken.com
…
Would love to have kalw.wearehearken.com/oauth/callback and wndr.wearehearken.com/oauth/callback, but since we only can have a single registered redirect_uri for the oAuth flow, it seems like I need to build something like:
oauth_callback.wearehearken.com/callback
which will be redirected to after going through the “Request Permission” part of the flow for all our customers. Unfortunately, I need to be able to track which customer this was for in order to save the token for them. Help.
My initial thought is to pass a query param on the redirect_uri. So, I’d register
oauth_callback.wearehearken.com/callback
with my infusionsoft app, but when I redirect to
https://signin.infusionsoft.com/app/oauth/authorize
I would add on a query param like
https://signin.infusionsoft.com/app/oauth/authorize?orgslug=kalw
https://signin.infusionsoft.com/app/oauth/authorize?orgslug=wndr
Is there a way to have this passed back when redirecting back?
Or, is there a preferred way to do this from the InfusionSoft perspective?