Forum Discussion
Daniel_Karpiski
Apr 04, 2024Copper Contributor
Incomplete json result from graph api after an error cuts in
Hello there,
I have a really strange error from graphapi.
When I query messages from one specific account I reach a point when there is an error. It would all be fine, if not the fact that this error breaks the entire output.
This error appears out of nowhere, it cuts into the regular json response, it breaks the entire format, the json response is not closed in any way.
Here is the end of the response
...,"recurrence":null,
"previousLocation":null,
"previousStartDateTime":null,
"previousEndDateTime":null}{"error":{
"code":"ErrorItemNotFound",
"message":"The specified object was not found in the store., The Active Directory user wasn't found."}}
As you can see there isn't even a coma when this error cuts in.
This is a first time this happened to me, and I've querried quite a few accounts till now, so I don't think this is common.
I'm using a simple query like that
f"/users('{user}')/messages?$filter=createdDateTime gt {startTime:%Y-%m-%dT%H:%M:%SZ}&$orderby=createdDateTime"
And after that loop through the rest of the results using @odata.nextLink
To me it seems like a bugged response object, but maybe there is a way to prevent/escape that somehow.
1 Reply
Sort By
- Best open a support case and report this.