Warm tip: This article is reproduced from serverfault.com, please click

D365FO import AAD users using API

发布于 2021-05-18 10:55:12

I'm trying to find a way to import Azure AD users to Dynamics 365 Finance & Operations (D365FO).

It is possible to get all system users using this endpoint (like using Postman):

/data/SystemUsers

However, not sure how the new user could be imported from Azure AD. If I go to D365FO UI I can do this using System administration -> Users -> Import users and there is an option to add users from AAD. Is there a way to do the same using API? Looking through the web was not very helpful so far.

Questioner
Oleksii
Viewed
0
Oleksii 2021-06-11 20:59:23

So here is the answer if someone is looking for the same - it is not possible.

If you work with SystemUsers using API - you can only select D365FO users. At the same time there is 'AccountType' attribute which tells D365 F&O what account type is it.

It can be Claims User, Claims Group, AD User or AD Group. Types starting with 'Claims' are pointing to Azure objects while AD are pointing to AD.

So when you create a new user and selecr 'ClaimsUser' as account type - D365F&O would know that this is Azure user and would do mapping. That sounds a bit 'magical', however this is how it works.