Registry / devops / speedcurve

speedcurve

JSON →
library2.0.10jsnpmunverified

Official SpeedCurve CLI and Node.js API for interacting with the SpeedCurve synthetic monitoring service. Version 2.0.10, released regularly via npm. Supports triggering deploys, monitoring deploy status, fetching synthetic test results, listing sites, and checking performance budgets. Unlike other API wrappers, this is the official package maintained by SpeedCurve, includes TypeScript definitions, and offers both CLI and programmatic API. Requires Node.js 8+ and a SpeedCurve API key.

npm install speedcurve
INSTALL
IMPORT
SIG · SPEEDCURVE
S
speedcurve
devopsjavascriptv2.0.10
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

SpeedCurve
import SpeedCurve from 'speedcurve'
const SpeedCurve = require('speedcurve')
Default export for the API client class. CommonJS require works but preferred is ESM.
default (API client)
const speedcurve = require('speedcurve')
CJS require returns the default export directly. No named exports.
Types (TypeScript)
import type { SpeedCurveOptions, DeployOptions } from 'speedcurve'
import { SpeedCurveOptions } from 'speedcurve'
Use 'import type' for type-only imports when using TypeScript to avoid runtime overhead.

Creates a SpeedCurve API client, triggers a deploy with note and detail, waits for completion, and checks budgets.

import SpeedCurve from 'speedcurve'; const api = new SpeedCurve(process.env.SPEEDCURVE_API_KEY ?? ''); async function triggerDeploy() { try { const result = await api.deploy({ note: 'v2.0.0', detail: 'Performance improvements', siteId: [1043801], wait: true, checkBudgets: true, }); console.log('Deploy ID:', result.deployId); console.log('Tests:', result.tests); } catch (err) { console.error('Deploy failed:', err.message); } } triggerDeploy();
speedcurve --version
Debug
Known issues
breakingVersion 2.x requires Node.js version 8 or higher. Node.js 6 and below are not supported.
fix
Upgrade Node.js to version 8 or later.
affects: >=2.0.0
deprecatedThe `--key` flag and `SPEEDCURVE_API_KEY` environment variable are still supported, but programmatic usage now expects the API key as a constructor argument.
fix
Pass API key as first argument to SpeedCurve constructor: new SpeedCurve('your-key').
affects: >=2.0.0
gotchaThe `deploy` method's 'site' parameter expects site IDs or names, but mixing types can cause errors. Use `siteId` for numeric IDs and `siteName` for strings.
fix
Use `siteId` (array of numbers) or `siteName` (array of strings) consistently.
affects: >=2.0.0
Errors
Common errors & fixes
speedcurve: command not found
CLI not installed globally or not in PATH
fix
Install globally: `npm install -g speedcurve` or use npx: `npx speedcurve deploy`
Error: API key is required
Missing SPEEDCURVE_API_KEY environment variable or --key flag
fix
Set env variable: `export SPEEDCURVE_API_KEY=your_key` or pass --key: `speedcurve deploy --key=your_key`
Upgrade
Version history
2.0.10latest on npm
Audit
Dependencies

No dependency data recorded yet.

Agent activity
19 hits · last 30 days
node
16
OpenAI (training)
1
Resources
speedcurve — npm install speedcurve · libregistry