Receiving Unexpected Call Ended Publication - Media API

I am facing an issue with the CloudLink Media API endpoints when controlling a call.

When making a direct inbound call to the endpoint via DID, then answering it (Media API), I receive an ‘ended’ state event from my subscription (Notifications API). The call has not ended and remains established. What’s odd is that I also get 2x ringing events.

When I compare the two ‘ended’ events, they are identical apart from the identifying information (publication ID etc). Please see the attached events received from Mitel, they are in the order I received them.

Happy to share the full Notification API payloads privately.

Hi Andrew,

Is the endpoint a Hunt/Ring Group similar to the scenario you describe here - Unable to Answer Calls to Non-Prime Line - Media API ?

Hi Budd

No. In this instance, I am dialing an external DID to reach the endpoint directly on its prime line. I am able to answer the call, the issue is I receive two ended events which throws my app off course because it thinks the call has ended.

Andrew