Authentication
repsapi uses bearer API keys. Create an account to generate one, then send it in the Authorization header on every request.
Your API key
Keys look like rk_live_…. Grab one from your project menu after you create an account. Treat it like a password — never ship it to the browser.
Making an authenticated request
terminal
curl "https://repsapi.com/v1/tracking?num=YT2530998211074512" \
-H "Authorization: Bearer rk_live_3f9a8c2b71d04e6f9a12"Prefer a query param? Every endpoint also accepts ?key=YOUR_KEY instead of the header — handy for quick tests, but keep keys server-side in production.
With the SDK
The SDK reads the key from the constructor (or the REPS_KEY env var).
index.ts
import { Reps } from "@repsapi/sdk";
const reps = new Reps(process.env.REPS_KEY);Good to know
- Keys are scoped to a single project.
- Rotate a key anytime — the old one stops working immediately.
- Server-side only. For browser apps, proxy requests through your backend.