# \[ZoomRooms\] Schedule meeting callback returns a bad formatted payload

**URL:** <https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151>\
**Category:** API and Webhooks\
**Created:** [October 4, 2019, 7:38pm UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151 "2019-10-04T19:38:27Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![addison](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/addison/32/2034_2.png) [@addison](https://devforum.zoom.us/u/addison)\
**Post date:** [October 4, 2019, 7:38pm UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/1 "2019-10-04T19:38:27Z")

</div>

**Description/Error**  
I’m trying to schedule a meeting in a Zoom Room using the API, but the request that hits the callback endpoint has the payload in a wrong format, instead of a JSON, I’m receiving request\_id=60cc5021-dae4-4eb8-959e-a2811b2115f9&meeting\_number=

**Which Endpoint/s?**  
Schedule, from Zoom Rooms API

**How To Reproduce (If applicable)**  
Steps to reproduce the behavior:

1. URL: POST [https://api.zoom.us/v2/rooms/{roomId}/meetings](https://api.zoom.us/v2/rooms/%7BroomId%7D/meetings)  
Body: { jsonrpc: ‘2.0’,  
method: ‘schedule’,  
params:  
{ callback\_url: ‘[http://ac081f69.ngrok.io/api/v1/webhooks/zoomRooms?id=123123123](http://ac081f69.ngrok.io/api/v1/webhooks/zoomRooms?id=123123123)’,  
meeting\_info:  
{ topic: ‘Testing User’s booking.’,  
start\_time: ‘2019-10-06T21:15:00Z’,  
duration: 15 } } }  
Header: JWT token
2. Wait for callback
3. Callback body has a string instead of a JSON

---

<div class="post-metadata">

**Author:** ![tommy](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/tommy/32/72769_2.png) [@tommy](https://devforum.zoom.us/u/tommy)\
**Post date:** [October 5, 2019, 12:20am UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/2 "2019-10-05T00:20:17Z")

</div>

Hey @addison,

We are coming out with new Zoom Room APIs soon. That endpoint unfortunatly is not REST and will not return JSON.

You can use our [GET /rooms](https://marketplace.zoom.us/docs/api-reference/zoom-api/rooms/listzoomrooms) to get rooms in a JSON response.

[Be sure to track our releases here for the Zoom Rooms API update.](https://marketplace.zoom.us/docs/changelog)

Thanks,  
Tommy

---

<div class="post-metadata">

**Author:** ![addison](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/addison/32/2034_2.png) [@addison](https://devforum.zoom.us/u/addison)\
**Post date:** [October 5, 2019, 12:11pm UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/3 "2019-10-05T12:11:22Z")

</div>

Hi!

Is there any ETA for the new API?  
What I need is to get the scheduled meeting’s info, to give our customers the join URL, is there any other way to get it?

Thanks!

---

<div class="post-metadata">

**Author:** ![tommy](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/tommy/32/72769_2.png) [@tommy](https://devforum.zoom.us/u/tommy)\
**Post date:** [October 7, 2019, 3:24pm UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/4 "2019-10-07T15:24:49Z")

</div>

Hey @addison,

Have you tried specifying the JSON response instead of the XML response to POST `https://api.zoom.us/v2/rooms/{roomId}/meetings`?

Can you send me the string you get back?

Thanks,  
Tommy

---

<div class="post-metadata">

**Author:** ![addison](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/addison/32/2034_2.png) [@addison](https://devforum.zoom.us/u/addison)\
**Post date:** [October 7, 2019, 3:57pm UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/5 "2019-10-07T15:57:55Z")

</div>

So you’re saying I shouldn’t use these endpoints at all, right? [https://marketplace.zoom.us/docs/guides/zoom-rooms/zoom-rooms-api](https://marketplace.zoom.us/docs/guides/zoom-rooms/zoom-rooms-api)

> [@tommy](#):
>
> Can you send me the string you get back?

So instead of getting {“request\_id”: 123, “meeting\_number”:"1234567890″}, I get something like “request\_id=123&meeting\_number=”. I can make a workaround to parse it before it gets to the express middleware, but I’d rather have an official solution for this 🙂

---

<div class="post-metadata">

**Author:** ![tommy](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/tommy/32/72769_2.png) [@tommy](https://devforum.zoom.us/u/tommy)\
**Post date:** [October 7, 2019, 7:57pm UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/6 "2019-10-07T19:57:25Z")

</div>

Hey @addison,

Those endpoints will be updated soon with new ones.

Have you tried setting a `"Accept": "application/json"` header?

By default the [Zoom Room](https://marketplace.zoom.us/docs/guides/zoom-rooms/zoom-rooms-api) endpoints return an [XML string](https://marketplace.zoom.us/docs/api-reference/zoom-api).

> <https://stackoverflow.com/questions/43209924/rest-api-use-the-accept-application-json-http-header>

Thanks,  
Tommy

---

<div class="post-metadata">

**Author:** ![addison](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/addison/32/2034_2.png) [@addison](https://devforum.zoom.us/u/addison)\
**Post date:** [October 7, 2019, 8:00pm UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/7 "2019-10-07T20:00:27Z")

</div>

> [@tommy](#):
>
> Have you tried setting a `"Accept": "application/json"` header?

I’ve set the `jsonrpc: '2.0'` field, but I can’t send headers for the callback\_url in `POST https://api.zoom.us/v2/rooms/${roomId}/meetings`. Or can I?

---

<div class="post-metadata">

**Author:** ![tommy](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/tommy/32/72769_2.png) [@tommy](https://devforum.zoom.us/u/tommy)\
**Post date:** [October 7, 2019, 8:51pm UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/8 "2019-10-07T20:51:36Z")

</div>

Hey @addison In your initial post request, in your headers try setting:

```json
{
   "Accept": "application/json"
}

```

Let me know if you get JSON back instead of the string.

Thanks,  
Tommy

---

<div class="post-metadata">

**Author:** ![addison](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/addison/32/2034_2.png) [@addison](https://devforum.zoom.us/u/addison)\
**Post date:** [October 7, 2019, 9:25pm UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/9 "2019-10-07T21:25:54Z")

</div>

It has the same effect, sending the Accept header in the same way I send the Authorization does not change the outcome of the request fired from your side

---

<div class="post-metadata">

**Author:** ![tommy](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/tommy/32/72769_2.png) [@tommy](https://devforum.zoom.us/u/tommy)\
**Post date:** [October 7, 2019, 9:50pm UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/10 "2019-10-07T21:50:43Z")

</div>

Thanks for letting me know @addison.

My best suggestion is to wait for the [updated Zoom Rooms APIs](https://marketplace.zoom.us/docs/guides/getting-started/stay-up-to-date/changelog), and use the [work around](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/5) you suggest above.

Thanks,  
Tommy

---

<div class="post-metadata">

**Author:** ![addison](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/addison/32/2034_2.png) [@addison](https://devforum.zoom.us/u/addison)\
**Post date:** [October 8, 2019, 1:14pm UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/11 "2019-10-08T13:14:02Z")

</div>

Ok, thanks!!

> [@tommy](#):
>
> My best suggestion is to wait for the [updated Zoom Rooms APIs](https://marketplace.zoom.us/docs/guides/getting-started/stay-up-to-date/changelog)

Is there an ETA for this?

---

<div class="post-metadata">

**Author:** ![addison](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/addison/32/2034_2.png) [@addison](https://devforum.zoom.us/u/addison)\
**Post date:** [October 8, 2019, 1:17pm UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/12 "2019-10-08T13:17:07Z")

</div>

Also, I’ve just tried the workaround, and it won’t work because I still get the answer like `request_id=123&meeting_number=` hehe

---

<div class="post-metadata">

**Author:** ![tommy](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/tommy/32/72769_2.png) [@tommy](https://devforum.zoom.us/u/tommy)\
**Post date:** [October 8, 2019, 7:05pm UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/13 "2019-10-08T19:05:26Z")

</div>

Hey @addison,

As a work around I would suggest using [GET /rooms](https://marketplace.zoom.us/docs/api-reference/zoom-api/rooms/listzoomrooms) which can return up to 300 rooms at a time, and can be filtered by status.

Then you can filter through the list to get the specific room you want.

Thanks,  
Tommy

---

<div class="post-metadata">

**Author:** ![addison](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/addison/32/2034_2.png) [@addison](https://devforum.zoom.us/u/addison)\
**Post date:** [October 8, 2019, 9:08pm UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/14 "2019-10-08T21:08:31Z")

</div>

Mmm I think that’s not going to work, because what I need is the meeting I’ve just scheduled, which is not sent on the GET /rooms response

---

<div class="post-metadata">

**Author:** ![tommy](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/tommy/32/72769_2.png) [@tommy](https://devforum.zoom.us/u/tommy)\
**Post date:** [October 8, 2019, 9:56pm UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/15 "2019-10-08T21:56:00Z")

</div>

Hey @addison,

Have you tried using the Meeting Created Webhook?

> **[Meeting Created - Meeting Events - Webhook Reference - API Reference](https://marketplace.zoom.us/docs/api-reference/webhook-reference/meeting-events/meeting-created)**
>
> Meeting Created
> 
> 
> 
> Zoom offers multiple methods for users to schedule new meetings. Users can create meetings manually from the Zoom Client or from the ...

This will send a payload automatically to your application after the meeting is created.

Thanks,  
Tommy

---

<div class="post-metadata">

**Author:** ![addison](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/addison/32/2034_2.png) [@addison](https://devforum.zoom.us/u/addison)\
**Post date:** [October 9, 2019, 3:18pm UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/16 "2019-10-09T15:18:43Z")

</div>

Ok, that one worked!!

Now I have a different issue… I see the `meeting.created` event, and then immediately I receive a `meeting.deleted`, so I can’t join any of the meetings I create. Do you want me to create a new ticket for this? Or can we solve it right here?

---

<div class="post-metadata">

**Author:** ![tommy](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/tommy/32/72769_2.png) [@tommy](https://devforum.zoom.us/u/tommy)\
**Post date:** [October 9, 2019, 4:46pm UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/17 "2019-10-09T16:46:29Z")

</div>

@addison Awesome!

Yes please create a new topic for that 🙂

Thanks,  
Tommy

---

<div class="post-metadata">

**Author:** ![addison](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/addison/32/2034_2.png) [@addison](https://devforum.zoom.us/u/addison)\
**Post date:** [October 9, 2019, 4:50pm UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/18 "2019-10-09T16:50:38Z")

</div>

Ok, thank you so much for your help and patience!!

---

<div class="post-metadata">

**Author:** ![tommy](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/tommy/32/72769_2.png) [@tommy](https://devforum.zoom.us/u/tommy)\
**Post date:** [October 9, 2019, 4:59pm UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/19 "2019-10-09T16:59:45Z")

</div>

You are so welcome 🙂

-Tommy

---

<div class="post-metadata">

**Author:** ![DeveloperBot](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/developerbot/32/12632_2.png) [@DeveloperBot](https://devforum.zoom.us/u/DeveloperBot)\
**Post date:** [August 21, 2020, 6:44pm UTC](https://devforum.zoom.us/t/zoomrooms-schedule-meeting-callback-returns-a-bad-formatted-payload/6151/20 "2020-08-21T18:44:19Z")

</div>

Closed on August 21, 2020, 6:44pm UTC


