Internal Server Error Graph Api CalendarView

Munna Kumar 1 Reputation point
2021-09-09T13:07:40.637+00:00

0

When i check with postman is working fine.

https://graph.microsoft.com/v1.0/me/events?$filter=iscancelled eq false and isorganizer ne false and (locations/Any(s:s/displayname eq 'abcd') )

When i want to get same result with Microsoft.Graph API using c#. Then giving an error.

            var queryOptions = new List<QueryOption>()
            {
                new QueryOption("startDateTime", from.ConvertDateTimeToUtc(timeZone.WinTimeZone).ConvertDateTimeToUtcIso8601String()),
                new QueryOption("endDateTime", to.ConvertDateTimeToUtc(timeZone.WinTimeZone).ConvertDateTimeToUtcIso8601String()),
            };var filtering="iscancelled eq false and isorganizer ne false and (locations/Any(s:s/displayname eq 'abcd') )";graphServiceClient.Users["emailaddress"].CalendarView .Request(queryOptions) .Filter(filtertring) .GetAsync();

'Error
{"error":{"code":"ErrorInternalServerError","message":"An internal server error occurred. The operation failed."}}'

Code: ErrorInternalServerError
Message: An internal server error occurred. The operation failed.
ClientRequestId: a945d124-53f0-4466-9cb2-2ce903e8a61d

When i removed the location from the filter it works.

var filtering="iscancelled eq false and isorganizer ne false";

graphServiceClient.Users["emailaddress"].CalendarView .Request(queryOptions) .Filter(filtertring) .GetAsync();

Microsoft Graph
Microsoft Graph
A Microsoft programmability model that exposes REST APIs and client libraries to access data on Microsoft 365 services.
10,576 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Maggie Rain 161 Reputation points
    2021-09-13T13:06:26.417+00:00

    When I run a similar query, the response is an empty list, not the internal error you are experiencing.

    Please share the request Id and the time stamp so that I can look into the logs, to find out more about the error you are experiencing.

    0 comments No comments