Forum Discussion
Dragan_Krstic
May 21, 2024Copper Contributor
Identifier(s) in API calls to load mail folders and mails from folders
Hi all.
I am trying to load user folders with call to list user folders , and later emails for given folder with call to list emails in given folder .
In both calls common part is:
GET /users/{id | userPrincipalName}...
On Azure portal userPrincipalName parameter is editable:
Is it a must to use Object ID (below) for accessing user and so forth ?
For my use case it would be of great benefit to use User principal name , but what happens if someone changes it ?
Thanks in advance,
Dragan
- You can use UPN in some (not all) calls, but it's best to stick to the objectID indeed.
2 Replies
Sort By
- You can use UPN in some (not all) calls, but it's best to stick to the objectID indeed.
- Dragan_KrsticCopper ContributorI need only the following two:
GET /users/{id | userPrincipalName}/mailFolders/?includeHiddenFolders=true
and
GET /users/{id | userPrincipalName}/mailFolders/{id}/messages
Any idea on how can I check this deeper?