100% Free Forever
AI-Powered Learning
Industry Expert Content
Certificates & Badges
Learn At Your Own Pace
Programming

SharePoint and OneDrive Flows

Automate document and list workflows across SharePoint libraries and OneDrive folders using Power Automate's SharePoint and OneDrive for Business connectors.

IntegrationsIntermediate9 min readJul 10, 2026
Analogies

Automating SharePoint and OneDrive with Power Automate

SharePoint and OneDrive for Business are the two most commonly automated storage systems in Power Automate because so much business content already lives there: project documents in libraries, request logs in lists, and personal working files in OneDrive. Both connectors expose triggers that fire on create, modify, or delete events, and actions that let a flow read, write, and manage metadata without a user ever opening the site. Because SharePoint lists and libraries are really just structured tables with columns, a flow can treat a list the way a script treats a database table, filtering, sorting, and updating rows programmatically.

🏏

Cricket analogy: Think of a SharePoint list like the ball-by-ball scorecard a scorer maintains during an India vs Australia Test: every delivery is a row with structured columns (bowler, runs, wicket), and Power Automate is the auto-scorer reacting the instant a new row appears.

SharePoint Triggers and List Actions

The two core SharePoint triggers are 'When an item is created' and 'When an item is created or modified'; picking the wrong one is a common source of duplicate runs, since the latter fires again on every subsequent edit, including edits the flow itself makes. Both triggers scope to a single site and a single list or library, and you can add an OData filter query (for example, Status eq 'Approved') directly on the trigger to avoid pulling every row into the flow and filtering with a Condition action afterward. Downstream, 'Get item', 'Update item', and 'Send an HTTP request to SharePoint' actions let you read or write any column, including choice, lookup, and person fields, though person and lookup fields require passing the underlying Claims value or ID rather than the display text.

🏏

Cricket analogy: Choosing 'created or modified' over 'created only' is like a third umpire reviewing every replay of a decision, not just the first appeal, which can trigger repeated reviews (flow runs) if the on-field call keeps getting revisited.

Working with Metadata and Column Types

When mapping dynamic content to SharePoint columns in an 'Update item' or 'Create item' action, choice columns expect the exact display value as a string, multi-choice columns expect a semicolon-delimited string, and lookup or person columns expect the numeric ID of the related item or user, not the visible text. Use 'Get item' or the 'Send an HTTP request to SharePoint' action with a $expand query on the REST API when you need the resolved display values for lookup and person fields.

OneDrive for Business Triggers and File Actions

OneDrive for Business offers 'When a file is created' and 'When a file is modified' triggers scoped to a folder, identified internally by a folder ID rather than a display path, which means renaming a folder in the OneDrive web UI does not break the flow since the ID stays stable. Common downstream actions include 'Copy file', 'Move file', and 'Get file content using path', and because OneDrive shares the same Graph API surface as SharePoint document libraries, the same 'Convert file' action (for example, converting a Word document to PDF) works identically in both connectors. A frequent gotcha is that OneDrive triggers only fire for files created directly by users or apps with delegated permissions matching the flow's connection; files synced from a desktop client can introduce a short delay before the trigger fires because of eventual consistency in the underlying index.

🏏

Cricket analogy: A folder ID staying stable after a rename is like a player's registration number in the BCCI database staying fixed even if their playing name changes, so historical stats keep linking correctly.

text
// OData filter query on a 'When an item is created or modified' trigger
// (entered in the trigger's 'Filter Query' advanced field)
Status eq 'Approved' and Department eq 'Finance'

// REST call to expand a lookup/person field's display value
GET _api/web/lists/getbytitle('Expense Requests')/items(42)?$select=Title,Approver/Title,Approver/EMail&$expand=Approver

SharePoint list views and 'Get items' actions default to a 5,000-item list view threshold and Power Automate's own 'Get items' action caps results at 100 rows per page unless you enable pagination and raise the 'Top Count' setting; large, unfiltered list queries against libraries with tens of thousands of items will silently truncate results or throttle the connection unless you filter server-side with an OData query.

  • 'When an item is created' avoids duplicate runs; 'created or modified' fires on every edit, including the flow's own updates, so guard it with a Condition.
  • Add OData filter queries directly on triggers and 'Get items' actions to filter server-side instead of pulling entire lists into the flow.
  • Choice columns take display-text strings, multi-choice columns take semicolon-delimited strings, and lookup/person columns require numeric IDs, not display names.
  • Use '$expand' on a 'Send an HTTP request to SharePoint' call to resolve lookup and person field display values when 'Get item' isn't enough.
  • OneDrive triggers scope to a stable folder ID, so folder renames in the UI do not break existing flows.
  • The same 'Convert file' and file actions work across both SharePoint and OneDrive because they share the underlying Microsoft Graph API.
  • Watch the 5,000-item list view threshold and 100-row default page size; enable pagination for large libraries to avoid silent truncation.

Practice what you learned

Was this page helpful?

Topics covered

#Programming#PowerAutomateStudyNotes#SharePointAndOneDriveFlows#SharePoint#OneDrive#Flows#Automating#StudyNotes#SkillVeris#ExamPrep