Skip to content

Latest commit

 

History

21 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

zoom-docs-cli

Export Zoom Docs pages as Markdown through Zoom Canvas APIs, without browser automation.

The CLI uses Zoom Public Client OAuth with PKCE. It opens a browser for user authorization, stores tokens locally, refreshes expired tokens, and calls the Canvas file content API.

Requirements

  • Node.js 18 or newer
  • A Zoom General App with Public Client OAuth enabled
  • Canvas/Docs export read scope:
docs:read:export

Some Zoom UI/docs may also display the scope as:

docs_export:read

Some admin-level endpoints, such as root, require additional admin Docs scopes like docs:read:file:admin.

Zoom App Setup

Create a Zoom General App in the Zoom App Marketplace.

Enable:

Use Public Client OAuth

Add this OAuth redirect URL:

http://localhost:8765/callback

Copy the app's Public Client ID.

Install

From this project directory:

npm link

Then use:

zoom-docs-cli --help

You can also run it without linking:

node ./zoom-docs-cli.js --help

Configure

This repository currently defaults to this Public Client ID:

sg8o0jnAR16nACej8DwrZQ

To configure another Zoom app:

zoom-docs-cli config set --public-client-id "YOUR_PUBLIC_CLIENT_ID"

Environment variable alternative:

export ZOOM_PUBLIC_CLIENT_ID="YOUR_PUBLIC_CLIENT_ID"

Authorize

zoom-docs-cli auth login

If no token is saved, get will automatically start the same authorization flow.

Export A Document

Use a Zoom Docs URL:

zoom-docs-cli get "https://docs.zoom.us/doc/cUD70vChRIydsC_ci1rfaw" --out doc.md

Or pass the file ID directly:

zoom-docs-cli get cUD70vChRIydsC_ci1rfaw --out doc.md

The CLI calls:

GET https://api.zoom.us/v2/docs/files/{fileId}/content

For files that are too large for direct content retrieval, it falls back to:

POST /docs/exports
GET /docs/exports/{exportId}/status

and downloads the generated Markdown export.

Commands

zoom-docs-cli config show
zoom-docs-cli token status
zoom-docs-cli auth logout
zoom-docs-cli export "https://docs.zoom.us/doc/cUD70vChRIydsC_ci1rfaw" --format markdown --wait --out doc.md
zoom-docs-cli export-status EXPORT_ID
zoom-docs-cli metadata "https://docs.zoom.us/doc/cUD70vChRIydsC_ci1rfaw"
zoom-docs-cli root me
zoom-docs-cli children "https://docs.zoom.us/doc/cUD70vChRIydsC_ci1rfaw"
zoom-docs-cli collaborators "https://docs.zoom.us/doc/cUD70vChRIydsC_ci1rfaw"
zoom-docs-cli add-collaborator FILE_ID --user-id USER_ID --role viewer
zoom-docs-cli update-collaborator FILE_ID COLLABORATOR_ID --role commenter
zoom-docs-cli remove-collaborator FILE_ID COLLABORATOR_ID
zoom-docs-cli general-access "https://docs.zoom.us/doc/cUD70vChRIydsC_ci1rfaw"
zoom-docs-cli set-general-access FILE_ID --share-scope collaborators_only
zoom-docs-cli transfer-owner FILE_ID --user-id NEW_OWNER_USER_ID --yes
zoom-docs-cli import-content --file ./draft.md --file-name "Draft from CLI"
zoom-docs-cli file-upload --file ./draft.md
zoom-docs-cli import-file --file-upload-id FILE_UPLOAD_ID --file-upload-type markdown --file-name "Imported from CLI"
zoom-docs-cli import-status IMPORT_ID
zoom-docs-cli create --file-name "Folder from CLI" --file-type folder
zoom-docs-cli rename cUD70vChRIydsC_ci1rfaw --file-name "Renamed from CLI"
zoom-docs-cli delete cUD70vChRIydsC_ci1rfaw --yes

To remove old confidential OAuth credentials from local config:

zoom-docs-cli config set --clear-confidential

Local Storage

Config and tokens are stored outside the repository:

~/.zoom-docs-cli/config.json
~/.zoom-docs-cli/token.json

Tokens are local to the user and should not be committed.

Development

npm run check

This project has no runtime npm dependencies.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages