Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -24,5 +24,20 @@ authorization_request_url = client_instance.get_authorization_request_url(SCOPES
|
|
24 |
st.write('Connecting to MSGraph with url:' + authorization_request_url)
|
25 |
webbrowser.open(authorization_request_url, new=True)
|
26 |
|
|
|
27 |
|
28 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
24 |
st.write('Connecting to MSGraph with url:' + authorization_request_url)
|
25 |
webbrowser.open(authorization_request_url, new=True)
|
26 |
|
27 |
+
authorization_code = '' #Get from url of webbrowser response - this is contingent on the URL set in MS Graph API Authentication section
|
28 |
|
29 |
|
30 |
+
access_token_id = access_token['access_token']
|
31 |
+
headers = {'Authorization': 'Bearer ' + access_token_id}
|
32 |
+
|
33 |
+
endpoint = base_url + 'me'
|
34 |
+
response = requests.get()
|
35 |
+
|
36 |
+
# URLs used in this sample app to demonstrate MS Graph in Python
|
37 |
+
# https://portal.azure.com/#view/Microsoft_AAD_RegisteredApps/ApplicationMenuBlade/~/Authentication/appId/d36c689d-3c61-4be6-a230-c09fc54cf80d/objectId/ece93996-1d7c-4b39-abc5-de51487073ed/isMSAApp~/false/defaultBlade/Overview/appSignInAudience/AzureADandPersonalMicrosoftAccount/servicePrincipalCreated~/true
|
38 |
+
# https://developer.microsoft.com/en-us/graph/graph-explorer
|
39 |
+
# https://chatgpt.com/c/67065b64-e2a8-800d-8b64-69cfe7aaed7f
|
40 |
+
# https://www.google.com/search?q=msal+pypi&oq=msal+pypi&gs_lcrp=EgZjaHJvbWUyBggAEEUYOTIICAEQABgWGB4yCAgCEAAYFhgeMg0IAxAAGIYDGIAEGIoFMg0IBBAAGIYDGIAEGIoFMg0IBRAAGIYDGIAEGIoFMgoIBhAAGIAEGKIEMgoIBxAAGIAEGKIEMgoICBAAGIAEGKIE0gEIMTk2NGowajeoAgCwAgA&sourceid=chrome&ie=UTF-8
|
41 |
+
# https://www.youtube.com/watch?v=1Jyd7SA-0kI&list=PLHgX2IExbFot3M2dudQEbTVEk9ikRJ2h5&t=972s
|
42 |
+
# https://huggingface.co/spaces/awacke1/MSGraphAPI
|
43 |
+
|