How microsoftgraph/msgraph-training-python works
Project type and purpose
• This repository is a set of Python sample applications demonstrating how to call Microsoft Graph from Python.
• It contains two independent console-style samples:
a. Delegated user authentication sample under user-auth/
b. App-only (daemon) authentication sample under app-auth/
• Each sample authenticates against Azure AD, acquires an access token, and uses the Microsoft Graph SDK to call Graph endpoints in Microsoft 365.
File structure
• Top‐level:
• .github/, CI workflows, codelinting.
• README.md, license, security, code of conduct.
• app-auth/ – App-only auth sample
• user-auth/ – Delegated user auth sample
• app-auth/graphapponlytutorial/ and user-auth/graphtutorial/ each contain:
• config.cfg – holds tenant/app/client-ID settings
• main.py – orchestrates auth and Graph calls
• graph.py – contains wrapper functions for Graph API operations
• requirements*.txt, pylintrc for lint/deps
• PowerShell scripts to register Azure AD app.
README for additional insights
• Describes running two distinct samples.
• Points to Microsoft Graph tutorials for detailed steps.
• No built-in database or UI: pure Python console app + external Graph service.