Overview
Bruno is an Electron-based desktop application built with React. It uses a monorepo structure managed by npm workspaces, with multiple specialized packages working together.Bruno is offline-only by design. All data is stored locally on your filesystem, with no cloud sync. This ensures your API collections remain private and under your control.
Technology Stack
Frontend
React 19
Modern React with hooks and functional components
Redux Toolkit
State management with @reduxjs/toolkit
Styled Components
CSS-in-JS for component styling
Tailwind CSS
Utility-first CSS for layout
Build Tools
- Rsbuild: Fast build tool for React (development and production)
- Electron Builder: Package and build desktop apps
- Babel: JavaScript transpilation
- Jest: Testing framework
- Playwright: End-to-end testing
Key Libraries
- UI Components
- HTTP & Networking
- Data Processing
- Developer Tools
- CodeMirror 5: Code editors for requests/responses
- Tabler Icons: Icon library
- Tippy.js: Tooltips and popovers
- React DnD: Drag and drop functionality
- Formik + Yup: Form handling and validation
Monorepo Structure
Bruno uses npm workspaces to manage 15+ packages:Core Packages
bruno-app
bruno-app
The React FrontendMain UI application built with React 19 and Rsbuild. Handles:
- Request/response interface
- Collection management
- Code editors (CodeMirror)
- Authentication flows
- Environment variables
- Testing and assertions
- React 19.0.0
- Redux Toolkit for state
- Styled Components + Tailwind CSS
- CodeMirror for code editing
- GraphiQL for GraphQL
bruno-electron
bruno-electron
The Electron Main ProcessManages the desktop application shell and native integrations:
- Window management
- File system access via IPC
- Native menus and dialogs
- Auto-updates
- Terminal integration (@lydell/node-pty)
- Electron 37.6.1
- Chokidar for file watching
- Electron Store for settings
bruno-cli
bruno-cli
Command-Line InterfaceRun Bruno collections from the command line:
- Execute collections programmatically
- CI/CD integration
- Automated testing
- Environment variable support
@usebruno/clibruno-lang
bruno-lang
Bru Language ParserParser for Bruno’s
.bru file format:- Plain text markup language
- Git-friendly format
- Request/response definitions
- Metadata and assertions
bruno-requests
bruno-requests
HTTP Request EngineCore request handling logic:
- HTTP/HTTPS requests
- Authentication (Bearer, Basic, OAuth2, AWS Signature)
- Proxy support
- SSL/TLS configuration
- Request/response interceptors
bruno-converters
bruno-converters
Import/Export ConvertersConvert between different API client formats:
- Postman collections
- Insomnia collections
- OpenAPI/Swagger
- HAR files
bruno-filestore
bruno-filestore
File System ManagementHandles collection storage:
- Read/write
.brufiles - Collection organization
- File system watching
- Workspace management
bruno-common
bruno-common
Shared UtilitiesCommon code shared across packages:
- Utility functions
- Constants
- Type definitions
- Shared logic
bruno-schema
bruno-schema
Schema DefinitionsDefines the structure of Bruno collections:
- Request schema
- Collection schema
- Environment schema
- Validation rules
Data Flow
File Storage Format
Bruno uses its own.bru file format:
Example Request
The
.bru format is designed to be:- Human-readable: Easy to understand and edit
- Git-friendly: Produces clean diffs
- Plain text: No binary formats
Build Process
Development Build
- Package builds: TypeScript packages compile to JavaScript
- React app: Rsbuild starts dev server with hot reload
- Electron: Launches with DevTools enabled
- File watching: Chokidar monitors collection changes
Production Build
- Build packages: All TypeScript packages compile
- Bundle React app: Rsbuild creates optimized production bundle
- Package Electron: electron-builder creates installers
- Platform-specific: Separate builds for Mac, Windows, Linux
Testing Architecture
- Unit Tests
- E2E Tests
- Integration Tests
Jest for unit testing:
- Package-level tests
- Utility function tests
- Parser tests
- Schema validation tests
Authentication Architecture
Supported authentication methods:- Basic Auth: Username/password
- Bearer Token: JWT and API tokens
- OAuth 2.0: Full OAuth flow
- AWS Signature v4: AWS API authentication
- API Key: Custom header/query auth
- Digest Auth: RFC 2617 digest authentication
- NTLM: Windows authentication
Key Design Principles
Offline-First
No cloud dependencies, all data stays local
Git-Friendly
Plain text format for easy version control
Privacy-Focused
Your data never leaves your machine
Open Source
Transparent, auditable codebase
Performance Optimizations
- Code splitting: Dynamic imports for large features
- Virtualization: Large lists use react-virtuoso
- Memoization: React.memo and useMemo for expensive renders
- Worker threads: Heavy processing offloaded where possible
- Lazy loading: Components loaded on demand
Next Steps
Now that you understand Bruno’s architecture:- Review the coding standards
- Set up your development environment
- Start contributing to specific packages