Sorry, this file has been deleted or moved - Teams graph api

asked 2021-03-29T06:19:17.347+00:00
Pradip Kumbhar 106 Reputation points

Hi All,

I am sending the file to the team's channel by using the team's graph API, by referring to the below document but when clicked on a file in the team's channel getting an error message as "sorry, this file has been deleted or moved."

https://learn.microsoft.com/en-us/graph/api/chatmessage-post?view=graph-rest-beta&tabs=http

Below is my code:

Endpoint:
82272-image.png

Body:
82292-image.png

Microsoft Graph Teamwork API
Microsoft Teams Development
Microsoft Teams Development
Microsoft Teams: A Microsoft customizable chat-based workspace.Development: The process of researching, productizing, and refining new or existing technologies.
1,684 questions
{count} votes

Accepted answer
  1. answered 2021-04-01T04:56:47.307+00:00
    Pradip Kumbhar 106 Reputation points

    Hi All,

    Finally, I am able to figure out the issue, there was an issue with View ID and Content URL.

    The vieweId should be documented source ID, it will be visible in browser with the label "sourcedoc".

    In the case of the root site, we need to provide /:x:/r/ in addition to the file path

    Correct URL Path:
    https://nowlabcorp.sharepoint.com/:x:/r/Shared%20Documents/report.csv


0 additional answers

Sort by: Most helpful