Microsoft SharePoint · Arazzo Workflow
SharePoint Search for a Document and Download It
Version 1.0.0
Run a search query, take the top hit's path, and fetch the document bytes.
View Spec
View on GitHub
CollaborationDocument-ManagementEnterprise Content ManagementIntranetMicrosoftArazzoWorkflows
Provider
Workflows
search-and-download
Search SharePoint content and download the highest ranked matching document.
Executes a keyword search restricted to a handful of properties, captures the top result's path, and downloads that file.
1
runSearch
Execute the search query. selectproperties is pinned to a fixed, ordered set so the returned cell positions are stable: cell 0 is Title, cell 1 is Path, cell 2 is FileType, cell 3 is LastModifiedTime. Change that list and the pointers in this step's outputs must change with it.
2
downloadTopResult
Download the top ranked document using the Path cell from the search result. Search returns Path as an absolute URL, so a caller running this against a live tenant should reduce it to the server-relative form this operation expects.
Source API Descriptions
openapi
Arazzo Workflow Specification
Work with this as data
Every workflow here is available over the APIs.io API and to AI agents over MCP.