admin管理员组文章数量:1312782
I am using the DownloadAttachment
action on the SharePoint Connector with the following default configuration:
{
"RemoteFile": "/sites/xyz/Shared Documents/General/sharepoint-file.txt",
"HasBytes": false
}
From the logs, I can see that the generated URL for the request is correct:
[11123|Q-Id] [HTTP|Req: 11490] GET (@v)/$value?@v='%2Fsites%2Fxyz%2FShared%20Documents%2FGeneral%2Fsharepoint-files.txt'
The request also successfully goes through, as seen in the logs:
[11123|Q-Id] [HTTP|Res: 11490] HTTP/1.1 200 OK, 3129 Bytes Transferred
The number of bytes matches the file size, and I can download the file manually using the URL in a browser. However, the integration fails to fetch the file, and no Content
field is set in the response. The output of connectorOutputPayload()
is:
[
{
"Success": "False"
}
]
I expected connectorOutputPayload()
to return the Content
field with the file data, but it does not. There are no errors in the logs either.
What I Have Tried:
- Verified that the file exists and is accessible via the generated URL.
- Confirmed that the request completes successfully with a
200 OK
response and the correct byte count. - Checked the browser download, which works fine.
- Ensured that no additional permissions are required.
Questions:
- Why is the
Content
field missing fromconnectorOutputPayload()
? - Is there any additional configuration needed to properly retrieve the file content?
- Could
HasBytes: false
be affecting the response?
Any insights would be greatly appreciated!
I am using the DownloadAttachment
action on the SharePoint Connector with the following default configuration:
{
"RemoteFile": "/sites/xyz/Shared Documents/General/sharepoint-file.txt",
"HasBytes": false
}
From the logs, I can see that the generated URL for the request is correct:
[11123|Q-Id] [HTTP|Req: 11490] GET https://mydomain.sharepoint/sites/xyz/_api/web/GetFileByServerRelativeUrl(@v)/$value?@v='%2Fsites%2Fxyz%2FShared%20Documents%2FGeneral%2Fsharepoint-files.txt'
The request also successfully goes through, as seen in the logs:
[11123|Q-Id] [HTTP|Res: 11490] HTTP/1.1 200 OK, 3129 Bytes Transferred
The number of bytes matches the file size, and I can download the file manually using the URL in a browser. However, the integration fails to fetch the file, and no Content
field is set in the response. The output of connectorOutputPayload()
is:
[
{
"Success": "False"
}
]
I expected connectorOutputPayload()
to return the Content
field with the file data, but it does not. There are no errors in the logs either.
What I Have Tried:
- Verified that the file exists and is accessible via the generated URL.
- Confirmed that the request completes successfully with a
200 OK
response and the correct byte count. - Checked the browser download, which works fine.
- Ensured that no additional permissions are required.
Questions:
- Why is the
Content
field missing fromconnectorOutputPayload()
? - Is there any additional configuration needed to properly retrieve the file content?
- Could
HasBytes: false
be affecting the response?
Any insights would be greatly appreciated!
Share Improve this question edited Feb 1 at 8:00 Daniyal Khan 155 bronze badges asked Jan 31 at 20:04 KrisrettiwtKrisrettiwt 173 bronze badges1 Answer
Reset to default 0Though text files are not generally considered binary files, you can still try to set the HasBytes:false
into HasBytes:true
to instruct the connector that it should treat the response as binary data and return it in the Content field, encoded as base64.z. Otherwise, you can eliminate the HasBytes:false as stated in to this example of downloading an attachment:
{
"RemoteFile": "/sites/xyz/Shared Documents/General/sharepoint-file.txt"
}
版权声明:本文标题:google cloud platform - SharePoint Connector `DownloadAttachment` Action Not Returning Content - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1741896282a2403593.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论