Skip to content

Integrate

Command line interface

Use the EHQ CLI for local scripts, operations runbooks, and CI. It reads the same API contract and honors the same scopes.

Install the preview

The CLI requires Node.js 20 or newer. Public npm installation is not available yet. Request a verified preview archive through Endurance HQ support, then install the file you received. The example below uses version 0.1.0; use your archive's actual filename.

npm install --global --ignore-scripts ./endurancehq-cli-0.1.0.tgz
ehq --version
ehq operations

These two verification commands need no credential and do not change EHQ data. You can use the remote MCP connection or REST API without installing the CLI.

Authenticate and make a read-only request

Create a key with schedule:read in Account Connections or Organization Connections for the event-list request below. Check the authentication guide for access requirements. Paste the key into the interactive prompt, not a command argument or chat.

ehq auth set-key
ehq events list

For automation, supply EHQ_API_KEY through your secret manager. EHQ_API_URL can override the API origin; do not append /v1. A key's scopes and current account permissions both apply.

Common commands

Replace the example IDs with records you can access. Create and update commands change data; team invite sends an invitation. Inspect the generated API reference for each command's required scope.

ehq tasks list --organization org_123
ehq tasks create --organization org_123 --title "Confirm timing crew"
ehq tasks get EHQ-184
ehq tasks update EHQ-184 --status in_progress
ehq team list --event evt_123
ehq team invite --scope event --event evt_123 --email crew@example.com --areas participants,volunteers
ehq webhooks list --organization org_123

Troubleshooting

  • An npm 404 for @endurancehq/cli means the public package is not available. Install the supplied archive instead.
  • If ehq is not found, check your Node installation and global npm bin directory on PATH. Use a user-owned Node installation rather than sudo.
  • An authentication or permission error is separate from installation. Check that the key is active, the account has API access, and the operation's scope and record permissions are granted.
  • Use ehq auth logout to remove a locally saved key. Revoke a compromised key in Endurance HQ as well.