Skip to main content



Sharing SharePoint online site and file with external users using CSOM

With lots if questions and requirements moving around, I thought of making a post about sharing a SharePoint online document / file with external user.

Good news is Microsoft has released APIs for both CSOM ( and REST to share an OBJECT (Could be web or document) with external users. Instead of I writing much I will let my code talk much for me :)

This blog post is concentrated around sharing object using CSOM. I will later publish a blog about how to share files using REST APIs for MS and other platform users. Till then sorry for non MS platforms!

You must first enable external sharing to your site collection from your office 365 SharePoint Admin Console. Follow this article to do so;

Lets get started
Take reference to latest SharePoint client libra…

Latest Posts

Downloading multiple files as a ZIP from SharePoint document library

Calling Office 365 graph API from PHP - App based authentication

Sharepoint 2010 Sandbox solutions


Web services issues in MOSS 2007

Create MOSS 2007 workflow with Infopath 2007 in VS 2008