File tree Expand file tree Collapse file tree 1 file changed +4
-8
lines changed Expand file tree Collapse file tree 1 file changed +4
-8
lines changed Original file line number Diff line number Diff line change @@ -26,28 +26,24 @@ To call Microsoft Graph, your app must acquire an access token from the Microsof
2626### 3. Import modules
2727
2828``` python
29- from azure.identity import ClientSecretCredential
29+ from azure.identity import InteractiveBrowserCredential
3030from msgraph.core import GraphClient
3131```
3232
3333### 4. Configure a Credential Object
3434
3535``` python
36- # Using ClientSecretCredential for demonstration purposes.
36+ # Using InteractiveBrowserCredential for demonstration purposes.
3737# There are many other options for getting an access token. See the following for more information.
3838# https://pypi.org/project/azure-identity/
3939
40- credential = ClientSecretCredential(
41- tenant_id = ' xxxxxxxxxxx' ,
42- client_id = ' xxxxxxxxxxx' ,
43- client_secret = ' xxxxxxxxx'
44- )
40+ browser_credential = InteractiveBrowserCredential(client_id = ' YOUR_CLIENT_ID' )
4541```
4642
4743### 5. Pass the credential object to the GraphClient constructor.
4844
4945``` python
50- client = GraphClient(credential = credential )
46+ client = GraphClient(credential = browser_credential )
5147```
5248
5349### 6. Make a requests to the graph using the client
You can’t perform that action at this time.
0 commit comments