Part of an app I'm working on creates links to messages in GMail using their message ID:
"https://mail.google.com/mail/u/0/#search/" + encodeURIComponent(`rfc822msgid:${interaction.messageId.replace(/(^<|>$)/g, "")}`)
Simple enough.
The problem comes when a user has multiple Google accounts, and the message they're opening does not belong to the currently logged in one: The link should open a search with only one result, if the user isn't logged in to the correct account, no message is displayed.
Is there any way to specify which email address to open the message with in the URL?
Something along the lines of https://mail.google.com/mail/u/0/[email protected]#search/rfc822msgid:[email protected]