You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 674d8a1
Browse filesBrowse the repository at this point in the historyBrowse files
feat: identify every gitops API request with a User-Agent
Only `npm run sim` and `npm run check` identified themselves. Setup,
pull, push, apply, promote, cleanup, rollback, call and audit sent Node's
default `node` User-Agent, about a sixth of all api.vapi.ai traffic, so
gitops usage beyond simulations couldn't be counted.
- src/user-agent.ts: `vapi-gitops-<command>/<version>`, plus ` (ci)`
when CI or GITHUB_ACTIONS is set. The command is the npm script that
started the process (so `npm run apply` labels the pull and push it
runs as apply, and a promotion's applies as promote), else the entry
script's name. sim and check keep their fixed labels, which analytics
already counts simulation runs by.
- Every fetch to the Vapi API sends it. tests/user-agent-coverage.test.ts
fails on a fetch without it and checks api.ts against a local server.
- cleanup-safety and new-file-gate tests sent about a dozen requests to
the real api.vapi.ai per `npm test` (fake key, 401s), which the new
User-Agent made visible in the request logs, and which would have
counted every fork's CI run as usage. They now point at a dead local
address.
- how-it-works.md says what the API sees; AGENTS.md says every request
sends the header.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
0 commit comments