Hi,
I am using Azure Active Directory graph API to get Office365 users. GET request returns users having Office365 attributes.
For example,
{
"odata.type": "Microsoft.WindowsAzure.ActiveDirectory.User",
"objectType": "User",
"objectId": "6b447fe3-1b30-25e9-bb54-013074ce6197",
"accountEnabled": true,
"assignedLicenses": [],
"assignedPlans": [],
"city": null,
"country": null,
"department": HR,
"dirSyncEnabled": null,
"displayName": "ABC",
"facsimileTelephoneNumber": null,
"givenName": null,
"jobTitle": null,
"lastDirSyncTime": null,
"mail": null,
"mailNickname": "xyz",
"mobile": null,
"otherMails": [],
"passwordPolicies": "None",
"passwordProfile": null,
"physicalDeliveryOfficeName": null,
"postalCode": null,
"preferredLanguage": null,
"provisionedPlans": [],
"provisioningErrors": [],
"proxyAddresses": [],
"state": null,
"streetAddress": null,
"surname": null,
"telephoneNumber": null,
"usageLocation": null,
"userPrincipalName": "ABC@contoso.onmicrosoft.com"
},
This returned attribute set, which doesn't contain Exchange online attributes if user has exchange online license.
On the other hand if we use powershell to manage Exchange online, the we get many exchange online attributes
'Get-Mailbox' output will look like this,
AccountSkuId | |
Alias | |
AntispamBypassEnabled | |
Database | |
DeliverToMailboxAndForward | |
DisplayName | |
DistinguishedName |
CN=Adam,OU=contoso.onmicrosoft.com,OU=Microsoft Exchange Hosted Organizations,DC=NAMPR09AH01,DC=prod,DC=outlook,DC=com |
|
EmailAddressPolicyEnabled | |
EmailAddresses | SMTP:Adam@contoso.onmicrosoft.com |
|
ExchangeGuid | 0d223ae5-da81-1c3c-78e1-368de04e4d22 |
|
ExchangeUserAccountControl | |
ExchangeVersion | |
HiddenFromAddressListsEnabled | |
IsMailboxEnabled | |
Name | |
OrganizationalUnit | NAMPR09AH01.prod.outlook.com/Microsoft Exchange Hosted Organizations/contoso.onmicrosoft.com |
|
RecipientType | |
SamAccountName | |
UMEnabled | |
| |
So, how can i get above attributes with Azure Active Directory Graph API ? There is REST API available for managing Exchange online ( https://msdn.microsoft.com/en-us/library/office/dn776319(v=exchg.150).aspx )
but it doesn't provide interface to get above mentioned attributes. Also there is no way to add\remove distributions\role group membership.
Regards,
Sagar