# Trying to create a meeting through the API but I get "Invalid JSON error message"

**URL:** <https://devforum.zoom.us/t/trying-to-create-a-meeting-through-the-api-but-i-get-invalid-json-error-message/14467>\
**Category:** API and Webhooks\
**Created:** [April 22, 2020, 6:01pm UTC](https://devforum.zoom.us/t/trying-to-create-a-meeting-through-the-api-but-i-get-invalid-json-error-message/14467 "2020-04-22T18:01:49Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![yperez](https://avatars.discourse-cdn.com/v4/letter/y/8e7dd6/32.png) [@yperez](https://devforum.zoom.us/u/yperez)\
**Post date:** [April 22, 2020, 6:01pm UTC](https://devforum.zoom.us/t/trying-to-create-a-meeting-through-the-api-but-i-get-invalid-json-error-message/14467/1 "2020-04-22T18:01:49Z")

</div>

**Description**  
I am running a test in [https://marketplace.zoom.us/docs/api-reference/zoom-api/meetings/meetingcreate](https://marketplace.zoom.us/docs/api-reference/zoom-api/meetings/meetingcreate) to create meetings through API but i keep getting the error below. Any assistance will be highly appreciated.

**Error**  
{  
“code”: 300,  
“message”: “Request Body should be a valid JSON object.”  
}

**Which Endpoint/s?**  
[https://api.zoom.us/v2/users/{userId}/meetings](https://api.zoom.us/v2/users/%7BuserId%7D/meetings)

**How To Reproduce (If applicable)**  
This is the body of the request.

```json
{
  "topic": "Value",
  "type": 1,
  "start_time": "04/22/2020 02:30 PM",
  "duration": 60,
  "timezone": "America/New_York",
  "password": "834073",
  "agenda": "Nothing to show",
  "recurrence": {
    "type": 1,
    "repeat_interval": "integer",
    "weekly_days": "string",
    "monthly_day": "integer",
    "monthly_week": "integer",
    "monthly_week_day": "integer",
    "end_times": "integer",
    "end_date_time": "string [date-time]"
  },
  "settings": {
    "host_video": true,
    "participant_video": true,
    "cn_meeting": true,
    "in_meeting": true,
    "join_before_host": false,
    "mute_upon_entry": false,
    "watermark": false,
    "use_pmi": false,
    "approval_type": 1,
    "registration_type": 1,
    "audio": "Both",
    "auto_recording": "off",
    "enforce_login": false,
    "enforce_login_domains": "off",
    "alternative_hosts": "none",
    "global_dial_in_countries": [
      {
        "city": "New York",
        "country": "US",
        "country_name": "US",
        "number": "+1 1000200200",
        "type": "toll"
      },
      {
        "city": "San Jose",
        "country": "US",
        "country_name": "US",
        "number": "+1 6699006833",
        "type": "toll"
      },
      {
        "city": "San Jose",
        "country": "US",
        "country_name": "US",
        "number": "+1 408000000",
        "type": "toll"
      }
    ],
    "registrants_email_notification": true
  }
}

```

---

<div class="post-metadata">

**Author:** ![yperez](https://avatars.discourse-cdn.com/v4/letter/y/8e7dd6/32.png) [@yperez](https://devforum.zoom.us/u/yperez)\
**Post date:** [April 22, 2020, 9:56pm UTC](https://devforum.zoom.us/t/trying-to-create-a-meeting-through-the-api-but-i-get-invalid-json-error-message/14467/2 "2020-04-22T21:56:18Z")

</div>

Resolved, error is in the global\_dial\_in\_countries. It should be in the following format  
“global\_dial\_in\_countries”: [  
“US”  
]

---

<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:** [April 23, 2020, 5:42pm UTC](https://devforum.zoom.us/t/trying-to-create-a-meeting-through-the-api-but-i-get-invalid-json-error-message/14467/3 "2020-04-23T17:42:02Z")

</div>

Happy to hear you figured out the issue! 🙂

Please also make sure you are passing the start\_time in the correct format:

`YYYY-MM-DDTHH:MM:SSZ`

And using correct values for the `recurrence` object.

Thanks,  
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, 8:54pm UTC](https://devforum.zoom.us/t/trying-to-create-a-meeting-through-the-api-but-i-get-invalid-json-error-message/14467/4 "2020-08-21T20:54:43Z")

</div>

Closed on August 21, 2020, 8:54pm UTC


