Microsoft graph api 在MS Graph中查找和显示扩展属性

Microsoft graph api 在MS Graph中查找和显示扩展属性,microsoft-graph-api,microsoft-graph-sdks,Microsoft Graph Api,Microsoft Graph Sdks,此AAD powershell可轻松列出用户的扩展属性: PS C:\WINDOWS\system32> Get-AzureADUser -ObjectId 50413382@wingtiptoys.com |select -ExpandProperty ExtensionProperty Key Value ---

此AAD powershell可轻松列出用户的扩展属性:

PS C:\WINDOWS\system32> Get-AzureADUser -ObjectId 50413382@wingtiptoys.com |select -ExpandProperty ExtensionProperty

Key                                                             Value
---                                                             -----
odata.metadata                                                  https://graph.windows.net/d29b7a9b-6edb-4720-99a8-3c5c6c3eeeb0/$metadata#directoryObjects/@Element
odata.type                                                      Microsoft.DirectoryServices.User
createdDateTime
employeeId                                                      50413382
onPremisesDistinguishedName
thumbnailPhoto@odata.mediaEditLink                              directoryObjects/8cc715a1-0698-4d1a-8f49-441a84b6dbc4/Microsoft.DirectoryServices.User/thumbnailPhoto
thumbnailPhoto@odata.mediaContentType                           image/Jpeg
userIdentities                                                  []
extension_10a03227b5f146ad8a0087cf0bafd627_division             |30103611|50435526|50230396|10192257|86009851
extension_10a03227b5f146ad8a0087cf0bafd627_company              wingtiptoys Inc.
extension_10a03227b5f146ad8a0087cf0bafd627_extensionAttribute10 GF
extension_10a03227b5f146ad8a0087cf0bafd627_employeeID           50413382
extension_10a03227b5f146ad8a0087cf0bafd627_cn                   50413382
extension_10a03227b5f146ad8a0087cf0bafd627_extensionAttribute8  wingtiptoys Inc. Inc.
extension_10a03227b5f146ad8a0087cf0bafd627_extensionAttribute7  Chuck
extension_10a03227b5f146ad8a0087cf0bafd627_extensionAttribute6  US11
extension_10a03227b5f146ad8a0087cf0bafd627_extensionAttribute5  US1-Rochester, NY- Site
extension_10a03227b5f146ad8a0087cf0bafd627_extensionAttribute4  USC
extension_10a03227b5f146ad8a0087cf0bafd627_extensionAttribute2  Regular
extension_10a03227b5f146ad8a0087cf0bafd627_employeeType         ARR
我现在请求将这种显示构建到一个经过身份验证的网页中,其中包含一个先前的页面,有人可以键入该对象ID,并使用Microsoft Graph Client SDK在屏幕上查看该输出

关键问题是我不能硬编码扩展属性列表。我只需要列出该特定用户上的内容

我已经找到了如何在知道扩展属性的名称后获取其值,但是如何在不提前知道属性名称的情况下获取上面的属性列表呢?(PowerShell的
-ExpandProperty ExtensionProperty
部分)

我试图通过图形浏览器获取这些数据,但遇到了困难。我试过:

  • /v1.0/me/?$select=id&$expand=extensions
    (返回一个空的extensions元素)
  • /v1.0/me/?$select=onPremisesExtensionAttributes
    (返回部分属性(但不是全部))

您可以使用
/beta
端点获取完整的属性集。
/v1.0
端点具有应用的默认筛选器,但
/beta
端点没有

例如(使用图形浏览器):

返回:

{
    "@odata.context": "https://graph.microsoft.com/v1.0/$metadata#users/$entity",
    "businessPhones": [
        "+1 425 555 0109"
    ],
    "displayName": "Adele Vance",
    "givenName": "Adele",
    "jobTitle": "Product Marketing Manager",
    "mail": "AdeleV@M365x214355.onmicrosoft.com",
    "mobilePhone": null,
    "officeLocation": "18/2111",
    "preferredLanguage": "en-US",
    "surname": "Vance",
    "userPrincipalName": "AdeleV@M365x214355.onmicrosoft.com",
    "id": "87d349ed-44d7-43e1-9a83-5f2406dee5bd"
}
{
    "@odata.context": "https://graph.microsoft.com/beta/$metadata#users/$entity",
    "id": "87d349ed-44d7-43e1-9a83-5f2406dee5bd",
    "deletedDateTime": null,
    "accountEnabled": true,
    "ageGroup": null,
    "businessPhones": [
        "+1 425 555 0109"
    ],
    "city": "Bellevue",
    "createdDateTime": "2017-07-29T03:03:26Z",
    "companyName": null,
    "consentProvidedForMinor": null,
    "country": "United States",
    "department": "Sales & Marketing",
    "displayName": "Adele Vance",
    "employeeId": null,
    "faxNumber": null,
    "givenName": "Adele",
    "imAddresses": [
        "AdeleV@M365x214355.onmicrosoft.com"
    ],
    "isResourceAccount": null,
    "jobTitle": "Product Marketing Manager",
    "legalAgeGroupClassification": null,
    "mail": "AdeleV@M365x214355.onmicrosoft.com",
    "mailNickname": "AdeleV",
    "mobilePhone": null,
    "onPremisesDistinguishedName": null,
    "officeLocation": "18/2111",
    "onPremisesDomainName": null,
    "onPremisesImmutableId": null,
    "onPremisesLastSyncDateTime": null,
    "onPremisesSecurityIdentifier": null,
    "onPremisesSamAccountName": null,
    "onPremisesSyncEnabled": null,
    "onPremisesUserPrincipalName": null,
    "otherMails": [],
    "passwordPolicies": "DisablePasswordExpiration",
    "passwordProfile": null,
    "postalCode": "98004",
    "preferredDataLocation": null,
    "preferredLanguage": "en-US",
    "proxyAddresses": [
        "SMTP:AdeleV@M365x214355.onmicrosoft.com"
    ],
    "refreshTokensValidFromDateTime": "2017-09-12T21:08:09Z",
    "showInAddressList": null,
    "signInSessionsValidFromDateTime": "2017-09-12T21:08:09Z",
    "state": "WA",
    "streetAddress": "205 108th Ave. NE, Suite 400",
    "surname": "Vance",
    "usageLocation": "US",
    "userPrincipalName": "AdeleV@M365x214355.onmicrosoft.com",
    "externalUserState": null,
    "externalUserStateChangeDateTime": null,
    "userType": "Member",
    "extension_fe2174665583431c953114ff7268b7b3_Education_ObjectType": "teacher",
    "extension_fe2174665583431c953114ff7268b7b3_Education_TeacherNumber": "106",
    "assignedLicenses": [
        {
            "disabledPlans": [],
            "skuId": "c7df2760-2c81-4ef7-b578-5b5392b571df"
        }
    ],
    "assignedPlans": [
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "Adallom",
            "servicePlanId": "8c098270-9dd4-4350-9b30-ba4703f3b36b"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "SharePoint",
            "servicePlanId": "e95bec33-7c88-4a70-8e19-b10bd9d0c014"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "SharePoint",
            "servicePlanId": "5dbe027f-2339-4123-9542-606e4d348a72"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "exchange",
            "servicePlanId": "efb87545-963c-4e0d-99df-69c6916d9eb0"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "MicrosoftCommunicationsOnline",
            "servicePlanId": "0feaeb32-d00e-4d66-bd5a-43b5b83db82c"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "MicrosoftOffice",
            "servicePlanId": "43de0ff5-c92c-492b-9116-175376d08c38"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "YammerEnterprise",
            "servicePlanId": "7547a3fe-08ee-4ccb-b430-5077c5041653"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "RMSOnline",
            "servicePlanId": "bea4c11e-220a-4e6d-8eb8-8ea15d019f90"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "ProjectWorkManagement",
            "servicePlanId": "b737dad2-2f6c-4c65-90e3-ca563267e8b9"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "PowerBI",
            "servicePlanId": "70d33638-9c74-4d01-bfd3-562de28bd4ba"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "MicrosoftCommunicationsOnline",
            "servicePlanId": "3e26ee1f-8a5f-4d52-aee2-b81ce45c8f40"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "MicrosoftCommunicationsOnline",
            "servicePlanId": "4828c8ec-dc2e-4779-b502-87ac9ce28ab7"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "Sway",
            "servicePlanId": "a23b959c-7ce8-4e57-9140-b90eb88a9e97"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "exchange",
            "servicePlanId": "34c0d7a0-a70f-4668-9238-47f9fc208882"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "exchange",
            "servicePlanId": "9f431833-0334-42de-a7dc-70aa40db46db"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "exchange",
            "servicePlanId": "4de31727-a228-4ec3-a5bf-8e45b5ca48cc"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "TeamspaceAPI",
            "servicePlanId": "57ff2da0-773e-42df-b2af-ffb7a2317929"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "PowerAppsService",
            "servicePlanId": "9c0dab89-a30c-4117-86e7-97bda240acd2"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "ProcessSimple",
            "servicePlanId": "07699545-9485-468e-95b6-2fca3738be01"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "Deskless",
            "servicePlanId": "8c7d2df8-86f0-4902-b2ed-a0458298f3b3"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "exchange",
            "servicePlanId": "8e0c0a52-6a6c-4d40-8370-dd62790dcd70"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "MicrosoftStream",
            "servicePlanId": "6c6042f5-6f01-4d67-b8c1-eb99d36eed3e"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "OfficeForms",
            "servicePlanId": "e212cbc7-0961-4c40-9825-01117710dcb1"
        }
    ],
    "deviceKeys": [],
    "onPremisesExtensionAttributes": {
        "extensionAttribute1": null,
        "extensionAttribute2": null,
        "extensionAttribute3": null,
        "extensionAttribute4": null,
        "extensionAttribute5": null,
        "extensionAttribute6": null,
        "extensionAttribute7": null,
        "extensionAttribute8": null,
        "extensionAttribute9": null,
        "extensionAttribute10": null,
        "extensionAttribute11": null,
        "extensionAttribute12": null,
        "extensionAttribute13": null,
        "extensionAttribute14": null,
        "extensionAttribute15": null
    },
    "onPremisesProvisioningErrors": [],
    "provisionedPlans": [
        {
            "capabilityStatus": "Enabled",
            "provisioningStatus": "Success",
            "service": "MicrosoftCommunicationsOnline"
        },
        {
            "capabilityStatus": "Enabled",
            "provisioningStatus": "Success",
            "service": "MicrosoftCommunicationsOnline"
        },
        {
            "capabilityStatus": "Enabled",
            "provisioningStatus": "Success",
            "service": "SharePoint"
        },
        {
            "capabilityStatus": "Enabled",
            "provisioningStatus": "Success",
            "service": "SharePoint"
        },
        {
            "capabilityStatus": "Enabled",
            "provisioningStatus": "Success",
            "service": "MicrosoftCommunicationsOnline"
        },
        {
            "capabilityStatus": "Enabled",
            "provisioningStatus": "Success",
            "service": "exchange"
        },
        {
            "capabilityStatus": "Enabled",
            "provisioningStatus": "Success",
            "service": "exchange"
        },
        {
            "capabilityStatus": "Enabled",
            "provisioningStatus": "Success",
            "service": "exchange"
        },
        {
            "capabilityStatus": "Enabled",
            "provisioningStatus": "Success",
            "service": "exchange"
        },
        {
            "capabilityStatus": "Enabled",
            "provisioningStatus": "Success",
            "service": "exchange"
        }
    ]
}
使用测试版:

https://graph.microsoft.com/beta/users/87d349ed-44d7-43e1-9a83-5f2406dee5bd
返回:

{
    "@odata.context": "https://graph.microsoft.com/v1.0/$metadata#users/$entity",
    "businessPhones": [
        "+1 425 555 0109"
    ],
    "displayName": "Adele Vance",
    "givenName": "Adele",
    "jobTitle": "Product Marketing Manager",
    "mail": "AdeleV@M365x214355.onmicrosoft.com",
    "mobilePhone": null,
    "officeLocation": "18/2111",
    "preferredLanguage": "en-US",
    "surname": "Vance",
    "userPrincipalName": "AdeleV@M365x214355.onmicrosoft.com",
    "id": "87d349ed-44d7-43e1-9a83-5f2406dee5bd"
}
{
    "@odata.context": "https://graph.microsoft.com/beta/$metadata#users/$entity",
    "id": "87d349ed-44d7-43e1-9a83-5f2406dee5bd",
    "deletedDateTime": null,
    "accountEnabled": true,
    "ageGroup": null,
    "businessPhones": [
        "+1 425 555 0109"
    ],
    "city": "Bellevue",
    "createdDateTime": "2017-07-29T03:03:26Z",
    "companyName": null,
    "consentProvidedForMinor": null,
    "country": "United States",
    "department": "Sales & Marketing",
    "displayName": "Adele Vance",
    "employeeId": null,
    "faxNumber": null,
    "givenName": "Adele",
    "imAddresses": [
        "AdeleV@M365x214355.onmicrosoft.com"
    ],
    "isResourceAccount": null,
    "jobTitle": "Product Marketing Manager",
    "legalAgeGroupClassification": null,
    "mail": "AdeleV@M365x214355.onmicrosoft.com",
    "mailNickname": "AdeleV",
    "mobilePhone": null,
    "onPremisesDistinguishedName": null,
    "officeLocation": "18/2111",
    "onPremisesDomainName": null,
    "onPremisesImmutableId": null,
    "onPremisesLastSyncDateTime": null,
    "onPremisesSecurityIdentifier": null,
    "onPremisesSamAccountName": null,
    "onPremisesSyncEnabled": null,
    "onPremisesUserPrincipalName": null,
    "otherMails": [],
    "passwordPolicies": "DisablePasswordExpiration",
    "passwordProfile": null,
    "postalCode": "98004",
    "preferredDataLocation": null,
    "preferredLanguage": "en-US",
    "proxyAddresses": [
        "SMTP:AdeleV@M365x214355.onmicrosoft.com"
    ],
    "refreshTokensValidFromDateTime": "2017-09-12T21:08:09Z",
    "showInAddressList": null,
    "signInSessionsValidFromDateTime": "2017-09-12T21:08:09Z",
    "state": "WA",
    "streetAddress": "205 108th Ave. NE, Suite 400",
    "surname": "Vance",
    "usageLocation": "US",
    "userPrincipalName": "AdeleV@M365x214355.onmicrosoft.com",
    "externalUserState": null,
    "externalUserStateChangeDateTime": null,
    "userType": "Member",
    "extension_fe2174665583431c953114ff7268b7b3_Education_ObjectType": "teacher",
    "extension_fe2174665583431c953114ff7268b7b3_Education_TeacherNumber": "106",
    "assignedLicenses": [
        {
            "disabledPlans": [],
            "skuId": "c7df2760-2c81-4ef7-b578-5b5392b571df"
        }
    ],
    "assignedPlans": [
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "Adallom",
            "servicePlanId": "8c098270-9dd4-4350-9b30-ba4703f3b36b"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "SharePoint",
            "servicePlanId": "e95bec33-7c88-4a70-8e19-b10bd9d0c014"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "SharePoint",
            "servicePlanId": "5dbe027f-2339-4123-9542-606e4d348a72"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "exchange",
            "servicePlanId": "efb87545-963c-4e0d-99df-69c6916d9eb0"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "MicrosoftCommunicationsOnline",
            "servicePlanId": "0feaeb32-d00e-4d66-bd5a-43b5b83db82c"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "MicrosoftOffice",
            "servicePlanId": "43de0ff5-c92c-492b-9116-175376d08c38"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "YammerEnterprise",
            "servicePlanId": "7547a3fe-08ee-4ccb-b430-5077c5041653"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "RMSOnline",
            "servicePlanId": "bea4c11e-220a-4e6d-8eb8-8ea15d019f90"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "ProjectWorkManagement",
            "servicePlanId": "b737dad2-2f6c-4c65-90e3-ca563267e8b9"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "PowerBI",
            "servicePlanId": "70d33638-9c74-4d01-bfd3-562de28bd4ba"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "MicrosoftCommunicationsOnline",
            "servicePlanId": "3e26ee1f-8a5f-4d52-aee2-b81ce45c8f40"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "MicrosoftCommunicationsOnline",
            "servicePlanId": "4828c8ec-dc2e-4779-b502-87ac9ce28ab7"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "Sway",
            "servicePlanId": "a23b959c-7ce8-4e57-9140-b90eb88a9e97"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "exchange",
            "servicePlanId": "34c0d7a0-a70f-4668-9238-47f9fc208882"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "exchange",
            "servicePlanId": "9f431833-0334-42de-a7dc-70aa40db46db"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "exchange",
            "servicePlanId": "4de31727-a228-4ec3-a5bf-8e45b5ca48cc"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "TeamspaceAPI",
            "servicePlanId": "57ff2da0-773e-42df-b2af-ffb7a2317929"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "PowerAppsService",
            "servicePlanId": "9c0dab89-a30c-4117-86e7-97bda240acd2"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "ProcessSimple",
            "servicePlanId": "07699545-9485-468e-95b6-2fca3738be01"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "Deskless",
            "servicePlanId": "8c7d2df8-86f0-4902-b2ed-a0458298f3b3"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "exchange",
            "servicePlanId": "8e0c0a52-6a6c-4d40-8370-dd62790dcd70"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "MicrosoftStream",
            "servicePlanId": "6c6042f5-6f01-4d67-b8c1-eb99d36eed3e"
        },
        {
            "assignedDateTime": "2017-07-29T03:03:25Z",
            "capabilityStatus": "Enabled",
            "service": "OfficeForms",
            "servicePlanId": "e212cbc7-0961-4c40-9825-01117710dcb1"
        }
    ],
    "deviceKeys": [],
    "onPremisesExtensionAttributes": {
        "extensionAttribute1": null,
        "extensionAttribute2": null,
        "extensionAttribute3": null,
        "extensionAttribute4": null,
        "extensionAttribute5": null,
        "extensionAttribute6": null,
        "extensionAttribute7": null,
        "extensionAttribute8": null,
        "extensionAttribute9": null,
        "extensionAttribute10": null,
        "extensionAttribute11": null,
        "extensionAttribute12": null,
        "extensionAttribute13": null,
        "extensionAttribute14": null,
        "extensionAttribute15": null
    },
    "onPremisesProvisioningErrors": [],
    "provisionedPlans": [
        {
            "capabilityStatus": "Enabled",
            "provisioningStatus": "Success",
            "service": "MicrosoftCommunicationsOnline"
        },
        {
            "capabilityStatus": "Enabled",
            "provisioningStatus": "Success",
            "service": "MicrosoftCommunicationsOnline"
        },
        {
            "capabilityStatus": "Enabled",
            "provisioningStatus": "Success",
            "service": "SharePoint"
        },
        {
            "capabilityStatus": "Enabled",
            "provisioningStatus": "Success",
            "service": "SharePoint"
        },
        {
            "capabilityStatus": "Enabled",
            "provisioningStatus": "Success",
            "service": "MicrosoftCommunicationsOnline"
        },
        {
            "capabilityStatus": "Enabled",
            "provisioningStatus": "Success",
            "service": "exchange"
        },
        {
            "capabilityStatus": "Enabled",
            "provisioningStatus": "Success",
            "service": "exchange"
        },
        {
            "capabilityStatus": "Enabled",
            "provisioningStatus": "Success",
            "service": "exchange"
        },
        {
            "capabilityStatus": "Enabled",
            "provisioningStatus": "Success",
            "service": "exchange"
        },
        {
            "capabilityStatus": "Enabled",
            "provisioningStatus": "Success",
            "service": "exchange"
        }
    ]
}

请注意结果中的
扩展名FE217466583431C953114FF7268B7B3_Education_ObjectType
扩展名FE217465583431C953114FF7268B7B3_Education_TeacherNumber

此链接似乎表示在MS graph sdk中不可能。这个职位现在已经6年了。这仍然是真的吗?这非常有帮助,我可以确认GrapherXPlorer beta端点返回所有数据。。我现在需要弄清楚这一点。我可能最终只是输出JSON响应,使用Graph sdk进行原始http调用。您可以使用最近发布的客户端。您将从AdditionalData字典访问扩展
var user=wait graphClient.Users[“87d349ed-44d7-43e1-9a83-5f2406dee5bd”].Request().GetAsync()

var dictionaryWithExtension=user.AdditionalData谢谢!这太棒了!谢谢你们两个帮我回答这个问题。我一直在努力寻找文档,或者找到一条使用所有不同api和版本的前进道路。