skills/e2e-bruno/SKILL.md
End-to-end API testing with Bruno HTTP client: collection organization, environment variables, test scripts, and CI integration. Trigger: When creating E2E API tests, organizing Bruno collections, or setting up API test automation.
npx skillsauth add 333-333-333/agents e2e-brunoInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Bruno is open-source, Git-friendly (plain text files), and runs collections from CLI. No cloud sync needed — collections live in the repo under version control.
Collections follow the service structure. One directory per service, one file per endpoint:
tests/e2e/
bruno.json # Bruno workspace config
environments/
local.bru # localhost URLs, test tokens
development.bru # dev environment URLs
staging.bru # staging environment URLs
notification/
health.bru # GET /health
send-email.bru # POST /api/v1/notifications/send (email)
send-sms.bru # POST /api/v1/notifications/send (sms)
send-push.bru # POST /api/v1/notifications/send (push)
send-invalid-channel.bru # POST with invalid channel (expect 400)
send-missing-content.bru # POST with missing content (expect 400)
auth/
register.bru
login.bru
logout.bru
gateway/
health.bru
proxy-auth.bru
proxy-notifications.bru
Every .bru file follows this structure:
See assets/example-success.bru for a success path test.
See assets/example-error.bru for an error path test.
See assets/example-chained.bru for a chained request that uses a previous response.
Environments define variables per deployment target. Each .bru uses {{variable}} placeholders.
See assets/environment-local.bru for local environment config.
Bruno supports JavaScript test scripts in tests blocks. Key patterns:
| Pattern | What it verifies |
|---------|-----------------|
| Status code | res.getStatus() === 200 |
| Response body field | res.getBody().data.id !== undefined |
| Response body type | typeof res.getBody().data.status === 'string' |
| Error envelope | res.getBody().error.code === 'VALIDATION_ERROR' |
| Set variable | bru.setVar('notificationId', res.getBody().data.id) |
| Chain requests | Use {{notificationId}} in subsequent requests |
Bruno CLI runs collections headlessly. The pattern for CI:
See assets/ci-bruno.yml for GitHub Actions integration.
Testing a single endpoint happy path?
→ One .bru file with status + body assertions
Testing an error path (400, 422, 401)?
→ Separate .bru file named with error scenario
Testing a flow (register → login → use token)?
→ Chained .bru files with bru.setVar/getVar
Need to run in CI?
→ Use bru run with --env flag
| File | Description |
|------|-------------|
| assets/example-success.bru | Success path test with body assertions |
| assets/example-error.bru | Error path test with error envelope validation |
| assets/example-chained.bru | Chained request using variables from previous response |
| assets/environment-local.bru | Local environment with localhost URLs |
| assets/ci-bruno.yml | GitHub Actions step for running Bruno in CI |
| assets/bruno.json | Bruno workspace config file |
npm install -g @usebruno/cli # Install Bruno CLI
bru run tests/e2e/notification --env local # Run notification E2E tests
bru run tests/e2e --env local # Run ALL E2E tests
testing
Review Flutter components and screens for UX/UI compliance. Trigger: When user invokes /ux-review command or requests UX audit.
development
TypeScript strict patterns and best practices. Trigger: When implementing or refactoring TypeScript in .ts/.tsx (types, interfaces, generics, const maps, type guards, removing any, tightening unknown).
testing
Testing philosophy and strategy for every feature: test pyramid, mandatory levels per change type, completion checklist, and skill delegation. Trigger: When planning tests for a feature, reviewing test coverage, defining acceptance criteria, or asking what tests a change needs.
development
Terraform security practices: sensitive variables, secret management, state protection, .gitignore patterns, and CI/CD credential handling. Trigger: When handling secrets in Terraform, configuring state backends, reviewing .gitignore for Terraform, or setting up CI/CD pipelines for infrastructure.