Repository navigation
feat(sharepoint): new SharePoint tool plugin with OAuth, Service Principal and Each user signs in (1.0.0) - #4168
Merged
Conversation
…cipal and Each user signs in, covering n8n's operations (1.0.0)
crazywoola
approved these changes
Nov 2, 2026
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
A new Microsoft SharePoint tool plugin (
tools/sharepoint), built like the reworked Outlook (#4163), Teams (#4164), OneDrive (#4165), Excel (#4166) and To Do (#4167) plugins. It works on SharePoint lists, list items and document library files through Microsoft Graph, and covers the common list, item and file operations.The repository so far only has
sharepoint_datasource, which imports documents into knowledge bases; this plugin is for workflows and agents that read and change lists and files. The README says which to use when.Auth (same three modes as the other Microsoft plugins)
Sites.ReadWrite.All,User.Read,offline_access.Sites.ReadWrite.All, orSites.Selectedwith per-site grants. Sites are tenant resources, so no user has to be named. Validation reads the root site, because Entra issues an app token even without any Graph permission.GET /sharepoint/callback) that never holds the secret; per-user tokens Fernet-encrypted in plugin storage, keyed by a hash ofclient_id | Dify user ID; never in tool output or logs. Sign Out of SharePoint (sharepoint_sign_out).Tools (all prefixed
sharepoint_: the new Agent rejects duplicate tool names across plugins)sharepoint_search_sites,sharepoint_get_site(a site URL, even of a page or file in it, its ID, orroot)sharepoint_list_lists/sharepoint_get_list(with the columns' internal names, types, required flags and choices, so an agent can write items)sharepoint_list_items(ODatafilter, allowed on non-indexed columns; up to 5000) /sharepoint_get_itemsharepoint_create_item/sharepoint_update_item/sharepoint_delete_itemsharepoint_upsert_item: match columns → update the one match or create; more than one match is an errorsharepoint_list_filessharepoint_download_file(up to 15 MB) /sharepoint_upload_file(a file, or text saved as a file) /sharepoint_update_file(rename and/or replace content; a rename that went through before a failed upload is reported)Item fields are returned without SharePoint's system columns. Every tool returns typed output variables (
success/errorplus its fields).Safety
O'Neil→'O''Neil').Release Notes
Change Type
Screenshots / Videos
No screenshots; setup is described step by step in the README. The per-user sign-in flow is the same as in #4163–#4167 (screenshots there).
Testing
pytest). They cover: site resolution from an ID,root, a site URL and a page or file URL inside the site, refusing non-SharePoint hosts; ID encoding; every tool's output variables on success and on a Graph error (a test checks every tool in the provider is covered); item simplification and the non-indexed filter header; list columns; upsert creating vs. updating, quoting, refusing several matches and missing match values; downloads without the token; uploads into folders; update with rename and content, and a failed upload after a rename; OAuth URLs per tenant and cloud; Service Principal validation; the per-user sign-in flow and validation.Checklist