Skip token errors on Grpah API - microsoft-graph-api

Hello I am getting several skip token errors when running a full import on the graph API.
here is the error
The following one looks like expiration of skiptoken. Graph connector uses skip token in different cases. I would communicate with Graph API team to understand if this is correct behavior for the API.
Message: Error during http call. HttpStatusCode: BadRequest;
url: https://graph.microsoft.com:443/v1.0/groups/5802115b-ef14-4572-bec1-9a4747e5bcfb/members/?$select=id&$skiptoken=X%2744537074090001000000000000000010000000D6203A9D758C6F4B887B307BA3302EB5000000000000000000000017312E322E3834302E3131333535362E312E342E323333310000000000000157F232736047814E848C20B3547FF5E8%27;
Response: {
"error": {
"code": "Directory_ExpiredPageToken",
"message": "The specified page token value has expired and can no longer be included in your request.",
"innerError": {
"request-id": "1489b123-f94c-4531-82d1-d4b76331e3eb",
"date": "2017-11-27T18:59:23"
}
}
}
Message: Error during http call. HttpStatusCode: Unauthorized;
"code": "Authentication_MissingOrMalformed",
"message": "Access Token missing or malformed.",
The application has full control over all objects so it should not get an error with permissions issues

Related

"Unknown Error" in Microsoft Graph API Get Staff Availability in MS Bookings

When trying to make a request to the graph API endpoint for getting staff availability info on MS Bookings I keep receiving the below error which returns status code 500. I had followed the guide here and also decoded my access token and verified I had the right permissions.
{
"error": {
"code": "UnknownError",
"message": "",
"innerError": {
"date": "2022-07-25T08:21:46",
"request-id": "aa302590-9a6e-47a4-a5ac-51a12ef5e72e",
"client-request-id": "aa302590-9a6e-47a4-a5ac-51a12ef5e72e"
}
}
}
I also encountered the same error in graph explorer.
Well this seemed to work for me when I changed the timeZone value on the request payload from my local time zone to 'UTC'. So my request payload was changed as below
However same error persists on graph explorer - guessing its because application permissions are not currently supported on graph explorer

Issue while accessing data from Graph API

When accessing data using https://graph.microsoft.com/beta/teams/{id}, it is failing with 400 bad request without any error details. {id} is the value received from the response of https://graph.microsoft.com/beta/groups.
Following response is returned.
{
"error": {
"code": "AuthenticationError",
"message": "Error authenticating with resource",
"innerError": {
"date": "2021-10-15T15:01:43",
"request-id": "1d82fe40-5186-46fc-9fb7-c16341eb1ffb",
"client-request-id": "29c9e68d-bfd8-6f53-65c4-c49a82581a76"
}
}
}
We tried using MS graph SDK as well as graph explorer. All the consent are given for the end point.
What could be the reason for the error?

SharePoint returns General Exception: An unspecified error has occurred

We create a Team with Power Automate using the Graph API from an HTTP Action:
We are calling the following URI using application permissions.
https://graph.microsoft.com/v1.0/groups('8c250cdd-1f21-405d-b45f-f95cf248e9d8')/sites('root')/webUrl
But the result is an HTTP 500:
{
"error": {
"code": "generalException",
"message": "An unspecified error has occurred.",
"innerError": {
"request-id": "0649718d-057d-4c4c-9fec-986c158376ee",
"date": "2019-12-02T09:11:10"
}
}
}
Calling the same URL in Graph Explorer works as expected.
The solution is to use a custom connector instead of an HTTP action.

OneDrive /me Error: InvalidAuthenticationToken

I am using the Code flow ... with scope of "onedrive.readonly onedrive.appfolder"
I get the code, then the token, and when I try to get the information about the user:
https://graph.microsoft.com/v1.0/me
In java I set the following headers to the request:
uc.setRequestProperty("Content-Type", "application/json");
uc.setRequestProperty("Authorization", String.format("Bearer %s", mSessionInfo.BearerToken));
I get the error:
{ "error": {
"code": "InvalidAuthenticationToken",
"message": "CompactToken parsing failed with error code: 8004920A",
"innerError": {
"request-id": "b8959569-efd0-4575-947e-c8835f8fef93",
"date": "2018-08-29T15:46:53"
} } }
What does this error mean ? How to proceed ?
The response actually indicates that the access token was not successfully generated or passed to the graph endpoint. Microsoft Graph couldn't parse it as a JWT token and thus attempted to process it as a Microsoft Account/Live Id compact token, which also failed. Please check the response that you got from the call to login.microsoftonline.com and that the token passed to graph.microsoft.com is a valid JWT token.

sendMail returns ResourceNotFound

I'm trying to send an email message using the Microsoft Graph REST API. My application is a service/daemon application where I am sending email on a user's behalf.
I am successfully able to obtain a token and obtain the user object such that I have the user's id, but when I try to use the sendMail API (POST /users/{user id}/sendMail) I receive the following error response:
{
"error": {
"code": "ResourceNotFound",
"message": "Resource could not be discovered.",
"innerError": {
"request-id": "a911ead2-840d-4bfe-9a77-bc5000c1b749",
"date": "2017-01-03T13:33:24"
}
}
}
I also tried to first create the message as a draft using POST /users/{user id}/messages but that also returns the exact same error. My application permissions include both Mail.ReadWrite and Mail.Send.

Resources