Fix URL encoding in mail list endpoint
This commit is contained in:
parent
388f3256a3
commit
588c8b90a0
1 changed files with 1 additions and 1 deletions
|
|
@ -185,7 +185,7 @@ def graph_request(endpoint, method="GET", data=None, headers=None):
|
|||
|
||||
def list_mail(limit=10, folder="inbox"):
|
||||
"""List emails."""
|
||||
endpoint = f"/me/mailFolders/{folder}/messages?$top={limit}&$orderby=receivedDateTime desc"
|
||||
endpoint = f"/me/mailFolders/{folder}/messages?$top={limit}&$orderby=receivedDateTime%20desc"
|
||||
endpoint += "&$select=id,subject,from,receivedDateTime,isRead,bodyPreview"
|
||||
result = graph_request(endpoint)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue