PLEASE HELPME
I am trying to delete a file with event trigger when creating a file in sharepoint, the file should be deleted if it is rejected, but I get access denied, i go it this:
{
"statusCode": 403,
"headers": {
"Cache-Control": "no-store, no-cache",
"Pragma": "no-cache",
"Set-Cookie": "ARRAffinity=18ffbb6bc42e6a8947719b4904cdb240a479c70cd565ecfce265809dd3032f9a;Path=/;HttpOnly;Secure;Domain=sharepointonline-cus.azconn-cus-001.p.azurewebsites.net,ARRAffinitySameSite=18ffbb6bc42e6a8947719b4904cdb240a479c70cd565ecfce265809dd3032f9a;Path=/;HttpOnly;SameSite=None;Secure;Domain=sharepointonline-cus.azconn-cus-001.p.azurewebsites.net",
"Strict-Transport-Security": "max-age=31536000; includeSubDomains",
"x-ms-request-id": "ab6b42a1-508e-5000-fd8d-809f8211d243;ab6b42a1-3092-5000-fd8d-8fff8f28a2d8",
"X-Content-Type-Options": "nosniff",
"X-Frame-Options": "DENY",
"Timing-Allow-Origin": "*",
"x-ms-apihub-cached-response": "true",
"x-ms-apihub-obo": "false",
"Date": "Fri, 02 Aug 2024 19:25:27 GMT",
"Content-Length": "707",
"Content-Type": "application/json",
"Expires": "-1"
},
"body": {
"status": 403,
"message": "Acceso denegado.\r\nclientRequestId: 314862d3-7c67-4a95-8909-603f6ad9e6b4\r\nserviceRequestId: ab6b42a1-508e-5000-fd8d-809f8211d243;ab6b42a1-3092-5000-fd8d-8fff8f28a2d8",
"source": "https://bucaramangagovco.sharepoint.com/sites/portal-calidad-salud-ambiente/_api/web/GetFileByServerRelativePath(decodedUrl=@p)/Recycle?@p='%2fsites%2fportal-calidad-salud-ambiente%2fhttps%3a%2f%2fbucaramangagovco.sharepoint.com%2fsites%2fportal-calidad-salud-ambiente%2fAPROBACIONES%2fFICHAS-TECNICAS%2fFORMATO+DE+FICHA+T%C3%89CNICA+ACTIVIDADES+SSAB+(2).xlsx%3fd%3dw51883885a8e0452d99bd36839f0bd632'",
"errors": [
"-2147024891",
"System.UnauthorizedAccessException"
]
}
}
I must say that I am the owner of the flow connection but the one who approves is another person who is within the domain
this is the data entrance
{
"host": {
"connectionReferenceName": "shared_sharepointonline",
"operationId": "DeleteFile"
},
"parameters": {
"dataset": "https://bucaramangagovco.sharepoint.com/sites/portal-calidad-salud-ambiente",
"id": "https%3A%2F%2Fbucaramangagovco.sharepoint.com%2Fsites%2Fportal-calidad-salud-ambiente%2FAPROBACIONES%2FFICHAS-TECNICAS%2FFORMATO%2520DE%2520FICHA%2520T%25C3%2589CNICA%2520ACTIVIDADES%2520SSAB%2520%282%29.xlsx%3Fd%3Dw1c7814a63e5145fb8bdfa16ec4f2fc5b"
}
}