r/GoogleAssistantDev • u/__godfather__ • Jul 17 '19
Unexpected behavior from UserId and UserVerificationStatus
So everything was working perfectly yesterday, it started today! Let me first say how was it before, if I use the Google Assistant on my Android phone, everything works and the same phone has had the same userId for the last two months that I have been working on the action. Not only the Android phone, but the simulator would also have the same userId. The Google Assistant app on iOS would also have the same userId as long as they are all under the same Gmail account.
What happened this morning? Since this morning, the same android phone keeps creating new UserIds! Why is it happening?? What has changed? Why Google the userId is so inconsistent that I can't rely on it! Even the simulator keeps creating new userIds. In fact, the simulator has become a Guest user since this morning while it used to (yesterday) be a Verified user which makes debugging the account linking impossible!
2
Jul 18 '19
[removed] — view removed comment
1
u/__godfather__ Jul 18 '19
Thanks for sharing, since my action requires account linking, I will look into
conv.user.profile.payload.suband hopefully that stays the same for all the users and requests.1
u/voxsystems Jul 18 '19
It appears to be the same in my experience. It would be a horrific failure if it <i>weren't</i> the same, as there is no other way to identify a single user.
My AoG uses payload.sub as the userId and it has given me the same ID as one gets from Google OAuth (which is also required for my AoG).
2
u/__godfather__ Jul 17 '19
To be more accurate:
The userId stays the same as long as only
Verifiedusers use the action. Verified users in this case are Android Google Assistant and iOS Assistant app under the same Gmail account.As you know,
Guestusers will always create a new userId, guest users can be Google Home users without the Voice match on. Or as of today, Guest users on the simulator!So right after any
Guestuser with the same gmail account requests something from the action, the userId will change for all theVerifiedusers to the new userId that was created by theGuestuser.