Skip to main content

Zoom API client for Python using server to server tokens

Project description

Zoom Python client

Python tests pre-commit CodeQL codecov

⚠️ WIP: This project is a WIP and therefore may contain bugs. Use it at your own risk and keep this in mind if you decide to use it in production environments.

Zoom API Python client with support for Server to Server Oauth tokens

Usage

Defining your env variables

Define the following variables in your env or your .env file:

  • ZOOM_ACCOUNT_ID
  • ZOOM_CLIENT_ID
  • ZOOM_CLIENT_SECRET

Initialize the ZoomApiClient from environment variables

from src.zoom_python_client.zoom_api_client import ZoomApiClient

zoom_client = ZoomApiClient.init_from_env()

Initialize the ZoomApiClient from .env

from src.zoom_python_client.zoom_api_client import ZoomApiClient

zoom_client = ZoomApiClient.init_from_dotenv()

Initialize the ZoomApiClient manually

from src.zoom_python_client.zoom_api_client import ZoomApiClient

zoom_client = ZoomApiClient(
        account_id="<YOUR ACCOUNT ID>",
        client_id="<YOUR CLIENT ID>",
        client_secret="<YOUR CLIENT SECRET>")

Use the file system to store the access token instead of environment

There are some cases where you might want to store the access token in the file system in order to share its value with other elements of the application (Ex. different pods on a Kubernetes/Openshift application).

You can define the path where the token will be stored, passing the use_path variable to the constructor:

from src.zoom_python_client.zoom_api_client import ZoomApiClient

zoom_client = ZoomApiClient(
        account_id="<YOUR ACCOUNT ID>",
        client_id="<YOUR CLIENT ID>",
        client_secret="<YOUR CLIENT SECRET>",
        use_path="/path/to/token/folder")

How to make API calls

MEETING_ID = "12345"
USER_ID = "abcdfgh"

result = zoom_client.users.get_user(USER_ID)
print(result)

result = zoom_client.meetings.get_meeting(MEETING_ID)
print(result)

Optional: How to configure the logging

from zoom_python_client.zoom_api_client import ZoomApiClient

setup_logs(log_level=logging.DEBUG)

Available endpoints

users:

  1. get user details
  2. get user meetings

meetings:

  1. get meeting details
  2. get meeting token

meeting live streams:

  1. get meeting live stream
  2. update live stream
  3. update livestream status

webinars:

  1. get webinar details

webinar live streams:

  1. get webinar live stream
  2. update webinar live stream
  3. update webinar livestream status

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

zoom_python_client-0.0.6.tar.gz (20.1 kB view details)

Uploaded Source

Built Distribution

zoom_python_client-0.0.6-py3-none-any.whl (24.9 kB view details)

Uploaded Python 3

File details

Details for the file zoom_python_client-0.0.6.tar.gz.

File metadata

  • Download URL: zoom_python_client-0.0.6.tar.gz
  • Upload date:
  • Size: 20.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.5.1 CPython/3.11.0 Linux/5.15.0-1037-azure

File hashes

Hashes for zoom_python_client-0.0.6.tar.gz
Algorithm Hash digest
SHA256 9d71a8eb0b119861d0048a69331e4a8d8a302bddb058ecdd2a494f909ea4625b
MD5 af40c9163af361fcdcc7d6253087f842
BLAKE2b-256 4ef4ec9919bb9f106be8592343aa07e35c7d34239aa697ffd5310ecab5a94b48

See more details on using hashes here.

File details

Details for the file zoom_python_client-0.0.6-py3-none-any.whl.

File metadata

  • Download URL: zoom_python_client-0.0.6-py3-none-any.whl
  • Upload date:
  • Size: 24.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.5.1 CPython/3.11.0 Linux/5.15.0-1037-azure

File hashes

Hashes for zoom_python_client-0.0.6-py3-none-any.whl
Algorithm Hash digest
SHA256 281aceb0d3b616ce252c805ef0b2c7fa7e01185d43b8fa8cf1eb56af3ac105c5
MD5 50cdaf26e105ee07837cd254c29e630f
BLAKE2b-256 f9605bf8731da6760a3264b1707e8378185494dc9adb058a295a0e1843a687cc

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page