Forum Discussion
Failed to list all calendars for certain users with graph api
We failed to list all calendars for certain users with graph api, only 2 calendars are listed. However, when we use ews api, we can list all 7 calendars with FolderClass being IPF.Appointment. Does anyone know why this inconsistency between both apis?
graph api endpoint:
https://graph.microsoft.com/v1.0/users/8057cafb-1848-4b5d-a213-5dc40453c8f7/calendarGroups/{calendar_group_id}/calendars
ews api endpoint:
https://outlook.office365.com/EWS/Exchange.asmx
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:m="http://schemas.microsoft.com/exchange/services/2006/messages"
xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types"
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Header>
<t:RequestServerVersion Version="Exchange2013" />
<t:ExchangeImpersonation>
<t:ConnectingSID>
<t:PrincipalName>user principal name</t:PrincipalName>
</t:ConnectingSID>
</t:ExchangeImpersonation>
</soap:Header>
<soap:Body>
<m:SyncFolderHierarchy>
<m:FolderShape>
<t:BaseShape>IdOnly</t:BaseShape>
<t:AdditionalProperties>
<t:FieldURI FieldURI="folder:ParentFolderId"></t:FieldURI>
<t:FieldURI FieldURI="folder:DisplayName"></t:FieldURI>
<t:FieldURI FieldURI="folder:FolderClass"></t:FieldURI>
</t:AdditionalProperties>
</m:FolderShape>
</m:SyncFolderHierarchy>
</soap:Body>
</soap:Envelope>