尝试通过Microsoft Graph Shema扩展筛选我的Outlook 365联系人

时间:2019-07-09 15:30:43

标签: outlook office365 microsoft-graph office365api

我试图将一个employeeId(模式扩展名)与Outlook中的联系人相关联,以便能够使用employeeId进行过滤

我设法在联系人中创建架构扩展

1
123321333
3

1
ttf
1

1
12345654333
8

结果:

https://graph.microsoft.com/v1.0/me/contacts?$filter=hines_employeeId/employeeId eq '12345'&$select=hines_employeeId

我正在使用此http呼叫来过滤联系人:

{
    "@odata.context": "https://graph.microsoft.com/v1.0/$metadata#users('a83022bc-88e8-4232-85e4-b80bab0e3f56')/contacts(hines_employeeId)",
    "value": [
        {
            "@odata.etag": "W/\"EQAAABYAAAD6J1g3drNdT4/nPVSy7JrwAAAC9CF5\"",
            "id": "AAMkADFkZDNhMDY1LWU3OWQtNDA3YS04YTI0LThmZGZkZTU4ZDdmMQBGAAAAAABQNcFh6AzrTLaCIQxPc_AhBwD6J1g3drNdT4-nPVSy7JrwAAAAAAEOAAD6J1g3drNdT4-nPVSy7JrwAAAC9iuOAAA=",
            "createdDateTime": "2019-07-09T13:31:54Z",
            "lastModifiedDateTime": "2019-07-09T13:32:44Z",
            "changeKey": "EQAAABYAAAD6J1g3drNdT4/nPVSy7JrwAAAC9CF5",
            "categories": [],
            "parentFolderId": "AQMkADFkZAAzYTA2NS1lNzlkLTQwN2EtOGEyNC04ZmRmZGU1OGQ3ZjEALgAAA1A1wWHoDOtMtoIhDE9z4CEBAPonWDd2s11Pj_c9VLLsmvAAAAIBDgAAAA==",
            "birthday": null,
            "fileAs": "",
            "displayName": "test1",
            "givenName": "test1",
            "initials": null,
            "middleName": null,
            "nickName": null,
            "surname": null,
            "title": null,
            "yomiGivenName": null,
            "yomiSurname": null,
            "yomiCompanyName": null,
            "generation": null,
            "imAddresses": [],
            "jobTitle": null,
            "companyName": null,
            "department": null,
            "officeLocation": null,
            "profession": null,
            "businessHomePage": null,
            "assistantName": null,
            "manager": null,
            "homePhones": [],
            "mobilePhone": null,
            "businessPhones": [],
            "spouseName": null,
            "personalNotes": "",
            "children": [],
            "hines_employeeId": {
                "employeeId": "12345"
            },
            "emailAddresses": [],
            "homeAddress": {},
            "businessAddress": {},
            "otherAddress": {}
        },
        {
            "@odata.etag": "W/\"EQAAABYAAAD6J1g3drNdT4/nPVSy7JrwAAAC9CF8\"",
            "id": "AAMkADFkZDNhMDY1LWU3OWQtNDA3YS04YTI0LThmZGZkZTU4ZDdmMQBGAAAAAABQNcFh6AzrTLaCIQxPc_AhBwD6J1g3drNdT4-nPVSy7JrwAAAAAAEOAAD6J1g3drNdT4-nPVSy7JrwAAAC9iuNAAA=",
            "createdDateTime": "2019-07-09T13:30:21Z",
            "lastModifiedDateTime": "2019-07-09T14:58:11Z",
            "changeKey": "EQAAABYAAAD6J1g3drNdT4/nPVSy7JrwAAAC9CF8",
            "categories": [],
            "parentFolderId": "AQMkADFkZAAzYTA2NS1lNzlkLTQwN2EtOGEyNC04ZmRmZGU1OGQ3ZjEALgAAA1A1wWHoDOtMtoIhDE9z4CEBAPonWDd2s11Pj_c9VLLsmvAAAAIBDgAAAA==",
            "birthday": null,
            "fileAs": "",
            "displayName": "test1",
            "givenName": "test1",
            "initials": null,
            "middleName": null,
            "nickName": null,
            "surname": null,
            "title": null,
            "yomiGivenName": null,
            "yomiSurname": null,
            "yomiCompanyName": null,
            "generation": null,
            "imAddresses": [],
            "jobTitle": null,
            "companyName": null,
            "department": null,
            "officeLocation": null,
            "profession": null,
            "businessHomePage": null,
            "assistantName": null,
            "manager": null,
            "homePhones": [],
            "mobilePhone": null,
            "businessPhones": [],
            "spouseName": null,
            "personalNotes": "",
            "children": [],
            "hines_employeeId": {
                "employeeId": "12"
            },
            "emailAddresses": [],
            "homeAddress": {},
            "businessAddress": {},
            "otherAddress": {}
        }
    ]
}

它给了我这个回应:

https://graph.microsoft.com/v1.0/me/contacts?$filter=hines_employeeId/employeeId eq '12345'&$select=hines_employeeId

我希望我的联系人中出现一个带有employeeId“ 12345”的联系人。

感谢您的帮助:)

0 个答案:

没有答案