irmEncryptFailedToFindProtector error response when download file

howard tseng 1 Reputation point
2022-10-06T07:18:04.5+00:00

Hi,
I try to download a file by api

   GET /items/{item-id}/content  

and I get the error code like this

   {"error":{"code":"resourceModified","innerError":{"code":"irmEncryptFailedToFindProtector"},"message":"The resource has changed since the caller last read it; usually an eTag mismatch"}}  

It seems like the error on server side. What is the root cause of this error?

Furthermore, I'm wondering if there is any query option to bypass this error and force download?
Or, do you have recommanded way to handle this kind of error ?

Thank you.

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

2 answers

Sort by: Most helpful
  1. Srinivasa Rao Darna 6,696 Reputation points Microsoft Vendor
    2022-11-01T06:29:51.393+00:00

    Hi @howard tseng ,

    Error message The resource has changed since the caller last read it; usually an eTag mismatch suggests, it appears the file has been modified from the time you have requested file or item attributes.

    Can you try including request headers if-none-match: {eTag} refer to driveitem-get-content.

    Hope this helps.
    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    0 comments No comments

  2. howard tseng 1 Reputation point
    2022-11-22T01:49:53.313+00:00

    But I did not add the if-nono-match: {etag} header in the request, the file content supposed to be downloaded without eTag mismatch error
    Looking forward to your reply, thanks

    0 comments No comments