Hi @Hashaam Hasaan
Listing all calls by calling the GET /communications/calls
endpoint is not supported. This API endpoint also does not exist in the Graph API documentation. Only the GET /communications/calls/{id}
endpoint is currently supported.
To get the call id, you can find it after creating the call.
Note that the GET /communications/calls/{id} endpoint only supports application permissions, you need to create an application-only context using the client credentials flow.
scopes = ['https://graph.microsoft.com/.default']
# Values from app registration
tenant_id = 'YOUR_TENANT_ID'
client_id = 'YOUR_CLIENT_ID'
client_secret = 'YOUR_CLIENT_SECRET'
# azure.identity.aio
credential = ClientSecretCredential(
tenant_id=tenant_id,
client_id=client_id,
client_secret=client_secret)
graph_client = GraphServiceClient(credential, scopes)
result = await graph_client.communications.calls.by_call_id('call-id').get()
Hope this helps.
If the reply is helpful, please click Accept Answer and kindly upvote it. If you have additional questions about this answer, please click Comment.