This contains random examples of code snippets for Microsoft Fabric. Particulary stuff we couldn't find documented. All of these examples can use various auth methods such as Managed Identity, Visual Studio and VS Code.
Example of using Azure.Identity with SqlClient to authenticate to a Fabric SQL EndPoint.
Example of using Azure.Identity with HttpClient to authenticate to a Fabric Pipeline and execute it. This interacts with the api the same way the web client would when requesting a pipeline execution.
Example of using Azure.Identity with HttpClient to copy a Blob across the OneLake. This is a basic example of a rest call to copy a file on a onelake.
Example of using Azure.Identity with HttpClient to authenticate to a Fabric Capcity and Suspend it. This is the same management api as used in a web browser. Will fail if capacity is already paused
Example of using Azure.Identity with HttpClient to authenticate to a Fabric Capcity and Resume it. This is the same management api as used in a web browser. Will fail if capacity is already running.
Example of using Python API to refresh PowerBI datasets within workspaces.
Sample Fabric Notebooks and builtin python class to Integrate Sharepoint and Fabric using Graph API.
Monitoring script for Fabric DW to show requests, sessions and blocking. This has moved to https://github.com/ProdataSQL/FabricWhoIsActive
Sample Notebook to connect to a Fabric SqlEndPoint using AAD Token from a Notebook with Python