Sorry if I'm repeating a question previously asked, but here goes.
Moving to Azure AD from on premise has created a challenge since we've completely disconnected our Jamf and AD. Legacy user IDs that were read in the past (ex, Rich Trouton's script here) have become no longer as useful. Now I'm trying to get creative and read the email account actively using Outlook. Has anyone come across a readable key that can be read by defaults (or something else?) that contains the email account being used within Outlook? I can run
defaults read com.microsoft.office OfficeActivationEmailAddress
But there is always the risk that the user who activated Office is not the user using Outlook for email. Generally we should be using the same credential to activate and then use Outlook, but people could slip through.