{"library":"microsoftgraph-python","title":"Microsoft Graph Python SDK","description":"API wrapper for Microsoft Graph written in Python. Version 1.1.8.1 supports Python 3.7+ and provides access to Microsoft 365 APIs. This library wraps Microsoft Graph REST API with easy-to-use methods for users, groups, mail, calendar, files, and more. Release cadence is low; the official Microsoft Graph SDK is recommended for new projects.","language":"python","status":"active","last_verified":"Sat May 09","install":{"commands":["pip install microsoftgraph-python"],"cli":null},"imports":["from microsoftgraph.client import GraphServiceClient","from msal import PublicClientApplication"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"from microsoftgraph.client import GraphServiceClient\nfrom msal import PublicClientApplication\n\napp = PublicClientApplication(client_id='YOUR_CLIENT_ID', authority='https://login.microsoftonline.com/common')\nresult = app.acquire_token_interactive(scopes=['User.Read'])\nclient = GraphServiceClient(tenant_id='YOUR_TENANT_ID', client_id='YOUR_CLIENT_ID', client_secret='YOUR_CLIENT_SECRET') if 'client_secret' else None\n\n# If using device code flow\nscopes = ['User.Read']\nresult = app.acquire_token_by_device_flow(scopes)\nclient = GraphServiceClient() if result else None","lang":"python","description":"Instantiate GraphServiceClient with credentials. Note: This library requires separate handling of authentication via msal. The GraphServiceClient expects token acquisition done outside.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}