Make API requests

View as Markdown

Use your API credentials to authorize requests to the Account Settings APIs, Video SDK APIs, Cobrowse SDK APIs, and AI Services.

APIs use API keys or JSON Web Tokens (JWT)  in the request header bearer token for authorization. Get your API key or JWT from Platform Studio. See get credentials for details.

Make your first API call

Here is an example to make your first API call with Video SDK.

You can authenticate in the following ways:

  • Bearer token: Authorization: Bearer TOKEN using your API Key or JWT.
  • Custom header: x-api-key: ZOOM_API_KEY using your API Key.

When you send both the x-api-key custom header and a Bearer token, the x-api-key takes precedence.

Authenticate with Bearer token

This example calls the List sessions Video SDK API endpoint. synchronous transcription endpoint for the Scribe API. Replace TOKEN with your JWT or API Key.

curl https://api.zoom.us/v2/videosdk/sessions -H "Authorization: Bearer TOKEN" -H "Content-Type: application/x-www-form-urlencoded"

You should get a response code of 200 OK and something resembling the response body below.

{
  "from": "2022-09-01",
  "to": "2022-09-02",
  "page_size": 30,
  "next_page_token": "",
  "sessions": []
}

If you haven't used Video SDK yet to create sessions, the sessions object will be blank.

Authenticate with Custom header

You can also authenticate by adding your API key to the custom x-api-key header.

curl https://api.zoom.us/v2/videosdk/sessions -H "x-api-key: ZOOM_API_KEY" -H "Content-Type: application/x-www-form-urlencoded"

Use Account Settings APIs

Use the Account Settings APIs to view and modify session and session security information about your account. See Create account for details about these settings.

See in_session and session_security objects in the following APIs for reference documentation.

For example, call Get account settings to see the data_center_regions you've enabled for sessions (replace 12345abcde with your JWT). The me keyword in this example indicates that you are getting this information for your account.

Authenticate with Bearer token

curl https://api.zoom.us/v2/accounts/me/settings -H "Authorization: Bearer TOKEN" -H "Content-Type: application/x-www-form-urlencoded"

You should get a result that includes something like the following.

...
"in_session": {
    ...
    "data_center_regions": [
        "AU",
        "CA",
        "DE",
        "IE",
        "IN",
        "LA",
        "MX",
        "NL",
        "SG",
        "TY",
        "US"
    ],
...

Note: Some options may only be available for Video SDK.

Access or modify subaccount data

Master accounts can use APIs to programmatically manage activities for subaccounts in their organization if both the owner of the master account and the owner of the subaccount agree. Work with your Zoom account representative to enable this access for the master account and each subaccount.

Prerequisites

  • Verify that the master account and the subaccount are in the same organization.
  • Verify that Zoom has enabled both of the following permissions:
    • Master account permission: Login access to the subaccount.
    • Subaccount permission: Login access from the master account.

Access subaccount data

Use the Video SDK master account APIs to access or modify subaccount data. For example, the subaccount endpoint to get a daily usage report is /videosdk/report/daily. If you are using the master account and you would like to get the daily usage report for this subaccount, use /v2/accounts/{accountId}/videosdk/report/daily.

To access subaccount data

Follow these steps to use the master's API JWT to access the account endpoints for the subaccount and access or modify subaccount data. After authentication, these steps work just as you would use the master account API endpoints in the Zoom Meetings API.

  1. Be sure that you meet the prerequisites.
  2. Use the list subaccounts endpoint to get the account ID for the subaccount.
  3. Use the master account Video SDK API JWT to generate an authorization token to access the API.
  4. Find the master API endpoint that you want to use, for example, a Video SDK master account API or an Account master API such as get account settings for in_session objects.
  5. Replace {accountId} with the account ID for the subaccount.

Subscribe to webhook events

On your account page, under Add feature, toggle Event Subscriptions to subscribe to events using webhooks.

Configure webhooks to send Cobrowse SDK events or Video SDK events to your server as HTTP POST requests. This is useful for tracking events or building out business logic. For example, when you receive a Video SDK session ended webhook, you could send an email to thank the participants for joining.