-
Notifications
You must be signed in to change notification settings - Fork 39
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to obtain a user ID and OAuth access token in Dialogflow #11
Comments
Just to confirm, the first snippet does work as expected? |
Yes, this works:
And this doesn't work: Should it not return consistent results? |
Check out the Google Sign In sample in Java but specifically here:
I'm closing this out but if you're still facing issues let us know. |
@sarahdwyer I saw that, but it doesn't address the issue I'm experiencing |
Did you set up Account Linking for your project? If so, what configuration did you choose (Google Sign-In, OAuth, etc.)? |
We did via OAuth's Authorization code flow |
@slkasisto if you added OAuth, then user info needs to come from your authentication/authorization provider. The access token you get back from |
That is understood, however it was not populating. |
While I posted a comment on it here I still think there's an issue here as described in https://stackoverflow.com/questions/54871395/how-to-obtain-a-user-id-and-oauth-access-token-in-dialogflow.
Why should I be doing some coding acrobatics to get to
accessToken
, for example:while the more straightforward methods advertised via the API don't work (always returning
null
):Ditto for other fields, i.e.
userId
,sessionId
,isSigninGranted
, etc.Or, am I missing something?
The text was updated successfully, but these errors were encountered: