Skip to content
This repository has been archived by the owner on May 28, 2024. It is now read-only.

Can't find user access token in requests to fulfilment webhooks #431

Open
philipstratford opened this issue Mar 23, 2022 · 1 comment
Open

Comments

@philipstratford
Copy link

philipstratford commented Mar 23, 2022

As per this issue, even after completing the account linking OAuth flow and seemingly successfully linking the user's Google account to their account in my own authentication system, I can't find the user's access token in requests coming from Conversational Actions to my fulfilment webhooks.

I'm testing with the simulator in the Actions Console so I'm able to view the body of the incoming requests. I'm assuming that my account has been successfully linked because I'm able to unlink it:
google1

However, the user property of the request does not contain any property named accessToken:
google2

Note also that in that second screenshot the user.accountLinkingStatus is "LINKED", cementing my belief that the accounts were linked successfully.

There is that params.bearerToken property which briefly got me excited, but its value doesn't match any tokens issued by my OAuth server. Since I can't find this property documented anywhere I don't know if it's supposed to contain the access token produced by my OAuth server, but whether it should or shouldn't, it doesn't!

Does the absence of an accessToken property indicate that something has gone wrong with my account linking process? If so, how might I go about figuring out what, since by all appearances it has worked? Or, should I be looking elsewhere for the access token?

@dominik-meissner
Copy link

Hi Philip,

the authorization property is in the header (not as you suspect in the body).
I made the same mistake before :-)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants