api-testing-bruno

Runs end-to-end API tests with Bruno CLI against a locally running backend service.

Updated Aug 22, 2026
One-click install
npx skills add https://github.com/balajirags/aifsd-kit --skill api-testing-bruno-balajirags
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: api-testing-bruno
Source: https://github.com/balajirags/aifsd-kit/tree/main/docs/skills/api-testing-bruno
Command: npx skills add https://github.com/balajirags/aifsd-kit --skill api-testing-bruno-balajirags

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires @usebruno/cli.

What problem does it solve? After implementing or modifying API endpoints, developers need a fast way to validate the deployed HTTP contract end-to-end without writing heavy integration test suites. This Skill provides a repeatable workflow for authoring and executing Bruno CLI test collections against a locally running backend as a post-implementation smoke and E2E validation step. ## Core Features & Use Cases - Bruno Collection Authoring: Create .bru request files with assertions and test blocks covering happy paths, validation errors, not-found, and conflict scenarios. - CLI Test Execution: Run entire collections, single module folders, or individual request files with bru run against a configurable local environment. - Full Workflow Integration: Start the Spring Boot app, wait on the health endpoint, run tests, interpret failures (max 3 attempts), and shut the app down cleanly. - Use Case: After adding a new /api/v1/locations endpoint, generate Bruno requests for create, validation-error, and duplicate cases, then run bru run api-tests/locations/ --env local to verify the live API contract. ## Quick Start Run the Bruno API tests for the endpoints I just changed by starting the app, executing bru run against the api-tests collection with the local environment, and reporting any failures.

Frequently Asked Questions about api-testing-bruno

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I run Bruno API tests from the command line?

Run Bruno tests with the CLI command `bru run api-tests/ --env local` to execute the whole collection. You can also target a single module folder like `bru run api-tests/locations/ --env local` or one `.bru` request file directly.

How to write API test assertions in Bruno .bru files?

Add an `assert` block for simple checks like `res.status: eq 201`, and a `tests` block with JavaScript for complex assertions on response body fields. Each `.bru` file holds one request with its meta, HTTP method, body, and assertions.

When should I use Bruno instead of JUnit or Testcontainers?

Use Bruno for E2E validation of the deployed API contract through the real HTTP stack. Use JUnit with Mockito for unit tests and Testcontainers with WebTestClient for integration tests requiring database assertions; Bruno complements rather than replaces them.

Can Bruno be used for load testing APIs?

No, Bruno is not a load testing tool. It is designed for functional API testing and smoke validation of request/response contracts, not for generating concurrent load or measuring performance under stress.

Why do my Bruno CLI tests fail against the local backend?

Failures usually mean the app is not running or not ready, the baseUrl in the local environment file is wrong, or assertions mismatch actual responses. Poll the health endpoint before running, and distinguish production bugs from test bugs before re-running, with a maximum of 3 attempts.