web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Automate - AI Builder
Under review by Community Managers

Under review

Thank you for your post! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Get Sharepoint File and Generate the Link

Posted on by

Hi Masters, 

 

I would like to create a function to have our bot in copilot studio that can-

 

- We type keyword of file like web search

- Bot index the keyword and search the file in Sharepoint 

- Generate the link to view

 

The following are 2 scratch path I am making at half stage which I don't know how to continue, as you see in attachment.

It will be great I could learn and be advised how to compete this work.

 

 

Option #1
 

1. Run a flow from Copilot - (Test Successfully)


  • Add an input

  • Text

  • Keyword


  •  

2. Sharepoint: Get Files (Property Only) - (Test Successfully)


  • Filter Query: concat('substringof(''', triggerOutputs()?['body/Keyword'], ''', FileLeafRef)')

  • Order by: FileLeafRef

  • Include Nested Items: Yes


  •  

3. Data Operation: Select - (Test Successfully)


  • From: Sharepoint- Get Files (Property Only)- body/value

  • Map: FileName- item()['{FilenameWithExtension}']

  • Map: IsFolder- item()['IsFolder']


  •  

4. Data Operation: Filter Array - (Test Successfully)


  • From: Data Operation- Select- Output

  • Filter Query: item().IsFolder - is equal to - false


  •  

5. Data Operation: Compose - (Test Successfully)


  • input: json(string(body('Filter_array')))


  •  

6. Respond to Copilot- (Test Failed)


  • File: Data Operation- Compose- Outputs
 
 
Option #2
 

1. Run a flow from Copilot - (Test Successfully)

 

  • Add an input
  • Text
  • Keyword
 
2. Initialized variable
 
  • Name: FileLinks
  • Type: String
  • Value: Respond to Copilot- Keyword
 
3. Sharepoint: Get Files (Property Only)
 
  • Filter Query: substringof('variables('variable')',FileLeafRef)

 

 
The above is what I couldn't will get it done. It will be great if someone gimme a hand. 
Thank you so much in advance!
Screenshot 2024-0...
Screenshot 2024-0...

Your file is currently under scan for potential threats. Please wait while we review it for any viruses or malicious content.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 245 Super User 2025 Season 2

#2
Expiscornovus Profile Picture

Expiscornovus 207 Most Valuable Professional

#3
trice602 Profile Picture

trice602 185 Super User 2025 Season 2

Last 30 days Overall leaderboard

Featured topics