microsoft-graph-comms-samples icon indicating copy to clipboard operation
microsoft-graph-comms-samples copied to clipboard

Do not receive notification when invitee rejects an invite to a call

Open bfany365 opened this issue 1 year ago • 2 comments

Describe the issue When inviting a user to an already established call, I do not receive respected event when he/she rejects the call, despite that I see it in logs.

Code Snippet

_endpoint.TeamsClient.OnNotificationProcessed += (r) => {
                switch (r.Notification.ChangeType) {
                    case ChangeType.Deleted:
                        var extracted = r.Notification.ExtractResouceData();
                        break;
                    default:
                        break;
                }
            };

 var operation = await (_botCall).Participants.InviteAsync(
                new List<InvitationParticipantInfo>() {
                    new InvitationParticipantInfo() {
                        Identity = usertocall,
                    }
                },
                cancellationToken
            );

Expected behavior Should get the following data when I use "extracted " from above code:

GraphLogger::PalBabakBot - {
  "value": [
    {
      "changeType": "Deleted",
      "resourceUrl": "/communications/calls/09005280-1a9b-4920-b36a-41120f8d11c9/operations/496ecbca-26fa-45c1-937e-08fd1aed1e4f",
      "resource": "/app/calls/09005280-1a9b-4920-b36a-41120f8d11c9/operations/496ecbca-26fa-45c1-937e-08fd1aed1e4f",
      "resourceData": {
        "@odata.type": "#microsoft.graph.inviteParticipantsOperation",
        "participants": [
          {
            "@odata.type": "#microsoft.graph.invitationParticipantInfo",
            "identity": {
              "@odata.type": "#microsoft.graph.identitySet",
              "user": {
                "@odata.type": "#microsoft.graph.identity",
                "tenantId": "293c78bf-b98b-4505-a3aa-2f330db99522",
                "displayName": "sip:[email protected]",
                "id": "96bb95f4-7a20-446a-bea5-04541b2001a7"
              }
            },
            "participantId": "58935b36-232d-44fe-b545-e0250249e339"
          }
        ],
        "clientContext": "c2056953-fda3-4d35-8083-1ba6a43b251f",
        "resultInfo": {
          "@odata.type": "#microsoft.graph.resultInfo",
          "code": 603,
          "message": "addParticipants failed for participant 8:orgid:96bb95f4-7a20-446a-bea5-04541b2001a7. Underlying reason: Decline. DiagCode: 603#0.@",
          "subcode": 0
        },
        "status": 3,
        "id": "496ecbca-26fa-45c1-937e-08fd1aed1e4f"
      }
    }
  ]
}

Graph SDK: Azure.Identity:1.12.0 Microsoft.Graph:5.38.0 Microsoft.Graph.Communications.Calls:1.2.0.10563 Microsoft.Graph.Communications.Client:1.2.0.10563 Microsoft.Graph.Communications.Common:1.2.0.10563 Microsoft.Graph.Communications.Core:1.2.0.10563 Microsoft.Graph.Core:3.1.3 Microsoft.IdentityModel.Clients.ActiveDirectory:3.19.8 Microsoft.IdentityModel.Protocols.OpenIdConnect:6.7.1

Logs

2024-12-18 11:02:57,978 [17] GraphLogger::PalBabakBot - No queue or registered callbacks for Deleted: /communications/calls/09005280-1a9b-4920-b36a-41120f8d11c9/operations/496ecbca-26fa-45c1-937e-08fd1aed1e4f

2024-12-18 11:04:02,010 [17] GraphLogger::PalBabakBot - { "value": [ { "changeType": "Deleted", "resourceUrl": "/communications/calls/09005280-1a9b-4920-b36a-41120f8d11c9/operations/496ecbca-26fa-45c1-937e-08fd1aed1e4f", "resource": "/app/calls/09005280-1a9b-4920-b36a-41120f8d11c9/operations/496ecbca-26fa-45c1-937e-08fd1aed1e4f", "resourceData": { "@odata.type": "#microsoft.graph.inviteParticipantsOperation", "participants": [ { "@odata.type": "#microsoft.graph.invitationParticipantInfo", "identity": { "@odata.type": "#microsoft.graph.identitySet", "user": { "@odata.type": "#microsoft.graph.identity", "tenantId": "293c78bf-b98b-4505-a3aa-2f330db99522", "displayName": "sip:[email protected]", "id": "96bb95f4-7a20-446a-bea5-04541b2001a7" } }, "participantId": "58935b36-232d-44fe-b545-e0250249e339" } ], "clientContext": "c2056953-fda3-4d35-8083-1ba6a43b251f", "resultInfo": { "@odata.type": "#microsoft.graph.resultInfo", "code": 603, "message": "addParticipants failed for participant 8:orgid:96bb95f4-7a20-446a-bea5-04541b2001a7. Underlying reason: Decline. DiagCode: 603#0.@", "subcode": 0 }, "status": 3, "id": "496ecbca-26fa-45c1-937e-08fd1aed1e4f" } } ] }

bfany365 avatar Dec 18 '24 11:12 bfany365

Ok, this post explains it very well

https://bfakhriloo.wordpress.com/2024/12/31/how-to-find-out-invite-rejection-for-teams-call/

bfany365 avatar Jan 06 '25 14:01 bfany365

I have the same issue. Using your solution doesn't work for me.

saadalienghouse avatar Jan 16 '25 12:01 saadalienghouse