# Zoom Phone WebSocket events format

**URL:** <https://devforum.zoom.us/t/zoom-phone-websocket-events-format/92115>\
**Category:** Phone\
**Created:** [July 20, 2023, 7:49am UTC](https://devforum.zoom.us/t/zoom-phone-websocket-events-format/92115 "2023-07-20T07:49:07Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![ZPForum](https://avatars.discourse-cdn.com/v4/letter/z/94ad74/32.png) [@ZPForum](https://devforum.zoom.us/u/ZPForum)\
**Post date:** [July 20, 2023, 7:49am UTC](https://devforum.zoom.us/t/zoom-phone-websocket-events-format/92115/1 "2023-07-20T07:49:07Z")

</div>

Hi !

I subscribed for Zoom Phone events on top of WebSocket connection via a Server-to-Server OAuth app, however I don’t find the format description of the events to be received. Is this already supported ? Is it possible to receive real time events of a phone call on a WebSocket connection ?

Thanks.

---

<div class="post-metadata">

**Author:** ![gianni.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/gianni.zoom/32/32523_2.png) [@gianni.zoom](https://devforum.zoom.us/u/gianni.zoom)\
**Post date:** [July 24, 2023, 9:23pm UTC](https://devforum.zoom.us/t/zoom-phone-websocket-events-format/92115/2 "2023-07-24T21:23:02Z")

</div>

Hi @ZPForum ,

What do you mean by this please? Are you saying you aren’t receiving any of the phone related [WebSockets](https://developers.zoom.us/docs/api/rest/websockets/)?

> [@ZPForum](#):
>
> however I don’t find the format description of the events to be received.

---

<div class="post-metadata">

**Author:** ![ZPForum](https://avatars.discourse-cdn.com/v4/letter/z/94ad74/32.png) [@ZPForum](https://devforum.zoom.us/u/ZPForum)\
**Post date:** [July 28, 2023, 6:31am UTC](https://devforum.zoom.us/t/zoom-phone-websocket-events-format/92115/4 "2023-07-28T06:31:32Z")

</div>

Yes, my question was basically where the format description can be found however I can receive the events on WebSocket connection.  
Do you plan to add the description ?

Thanks.

---

<div class="post-metadata">

**Author:** ![gianni.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/gianni.zoom/32/32523_2.png) [@gianni.zoom](https://devforum.zoom.us/u/gianni.zoom)\
**Post date:** [July 28, 2023, 7:01pm UTC](https://devforum.zoom.us/t/zoom-phone-websocket-events-format/92115/5 "2023-07-28T19:01:20Z")

</div>

Hi @ZPForum ,

> [@ZPForum](#):
>
> Yes, my question was basically where the format description can be found however I can receive the events on WebSocket connection. Do you plan to add the description?

Based on [the docs](https://developers.zoom.us/docs/api/rest/websockets/), the WebSocket response payload should be the corresponding Webhook events. This is what I have seen with Meeting and Account events through a bit of testing, but will double check what the behavior is. Can you please provide screenshots and show us how to reproduce?

@ojus.zoom , can you please confirm if the WebSocket payloads for corresponding API Webhook events should be the same? Thanks 🙂

---

<div class="post-metadata">

**Author:** ![ZPForum](https://avatars.discourse-cdn.com/v4/letter/z/94ad74/32.png) [@ZPForum](https://devforum.zoom.us/u/ZPForum)\
**Post date:** [August 1, 2023, 11:26am UTC](https://devforum.zoom.us/t/zoom-phone-websocket-events-format/92115/6 "2023-08-01T11:26:13Z")

</div>

This is the WebSocket message format of e.g. “callee\_ended” event:  
{  
“module”: “message”,  
“content”: {  
“event”: “phone.callee\_ended”,  
“payload”: {  
“account\_id”: “Gzsh7rfYSyi433TvpEaNcw”,  
“object”: {  
“call\_id”: “7258584963242796608”,  
“caller”: {  
“extension\_type”: “user”,  
“extension\_number”: 847,  
“phone\_number”: “847”,  
“device\_type”: “Windows\_Client(5.14.11.17466)”,  
“connection\_type”: “voip”  
},

However in the Webhook API description the example for the same event is:  
{  
“event”: “phone.callee\_ended”,  
“payload”: {  
“account\_id”: “TQTvjT52Tmi\_wrhASNNOEw”,  
“object”: {  
“call\_id”: “6998252113337041462”,  
“channel\_id”: “b21dee06-ddaa-4578-ab90-1dd6e50ea4ba”,  
“caller”: {  
“phone\_number”: “+12092592844”,  
“connection\_type”: “voip”  
},  
So the events format are not the same.

Thanks.

---

<div class="post-metadata">

**Author:** ![gianni.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/gianni.zoom/32/32523_2.png) [@gianni.zoom](https://devforum.zoom.us/u/gianni.zoom)\
**Post date:** [August 2, 2023, 3:57pm UTC](https://devforum.zoom.us/t/zoom-phone-websocket-events-format/92115/7 "2023-08-02T15:57:55Z")

</div>

Hi @ZPForum ,

Okay, I’m checking internally on this. Thanks for your patience here.

---

<div class="post-metadata">

**Author:** ![gianni.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/gianni.zoom/32/32523_2.png) [@gianni.zoom](https://devforum.zoom.us/u/gianni.zoom)\
**Post date:** [August 2, 2023, 4:28pm UTC](https://devforum.zoom.us/t/zoom-phone-websocket-events-format/92115/8 "2023-08-02T16:28:57Z")

</div>

Hi @ZPForum ,

I confirmed that the payloads should be the same. There just may be a discrepancy in the documentation itself. Did you test this event for BOTH WebSocket and Webhook? If so, did they yield the same payload?

---

<div class="post-metadata">

**Author:** ![ZPForum](https://avatars.discourse-cdn.com/v4/letter/z/94ad74/32.png) [@ZPForum](https://devforum.zoom.us/u/ZPForum)\
**Post date:** [August 3, 2023, 9:38am UTC](https://devforum.zoom.us/t/zoom-phone-websocket-events-format/92115/9 "2023-08-03T09:38:15Z")

</div>

No, I don’t use Webhook. I use WebSocket connection for event handling, I get the Webhook event format from the API description.

Thanks.

---

<div class="post-metadata">

**Author:** ![gianni.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/gianni.zoom/32/32523_2.png) [@gianni.zoom](https://devforum.zoom.us/u/gianni.zoom)\
**Post date:** [August 3, 2023, 4:41pm UTC](https://devforum.zoom.us/t/zoom-phone-websocket-events-format/92115/10 "2023-08-03T16:41:37Z")

</div>

Hi @ZPForum ,

Okay, well the response bodies should be the same, so I’ll make a request to the docs team to update (DEVELOPERS-4099). Thanks so much!
