Skip to main content

Matimo provider — Bruno API testing tools (collections, requests, imports, reports)

Project description

matimo-bruno

Bruno CLI tools for Matimo — Enable AI agents to autonomously manage, execute, and validate API test collections.

📦 Installation

pip install matimo-bruno

🚀 Quick Start

Python

from matimo import Matimo

matimo = await Matimo.init()

# List all collections in workspace
collections = await matimo.execute('bruno_list_collections', {
    'workspace_path': './collections'
})

# Get collection metadata before running
info = await matimo.execute('bruno_get_collection_info', {
    'collection_path': './collections/payment-api'
})

# Run entire collection
result = await matimo.execute('bruno_run_collection', {
    'collection_path': './collections/payment-api',
    'environment': 'staging',
    'report_path': './reports/staging-results.json'
})

# Run single request for debugging
response = await matimo.execute('bruno_run_request', {
    'collection_path': './collections/auth',
    'request_name': 'Login',
    'environment': 'staging'
})

# Bootstrap from OpenAPI spec
imported = await matimo.execute('bruno_import_openapi', {
    'spec_source': 'https://api.example.com/openapi.json',
    'output_directory': './collections',
    'collection_name': 'Generated API Tests'
})

# Create new collection
created = await matimo.execute('bruno_create_collection', {
    'collection_path': './collections/new-service',
    'collection_name': 'New Service Tests'
})

📋 Available Tools

1. bruno_run_collection

Execute a Bruno API collection with configurable environments, data files, and reporting.

Parameters:

  • collection_path (required) — Path to collection file or directory
  • environment — Environment name (dev, staging, prod)
  • env_file — Path to environment file override
  • data_file — CSV/JSON data file for data-driven testing
  • iteration_count — Number of iterations to run
  • delay_ms — Delay between requests
  • tags — Comma-separated tags (run requests with ALL tags)
  • exclude_tags — Comma-separated tags (skip requests with ANY tags)
  • tests_only — Run only requests with tests/assertions
  • bail_on_failure — Stop on first failure
  • parallel — Run requests in parallel
  • sandbox_mode — JavaScript execution mode ('safe' or 'developer')
  • report_format — Report format (json, junit, html)
  • report_path — Path to write report file

Returns: Collection execution results, summary, and report path

2. bruno_run_request

Execute a single request for targeted debugging and validation.

Parameters:

  • collection_path (required) — Collection directory
  • request_name (required) — Request name to execute
  • environment — Environment name override
  • env_file — Environment file override
  • sandbox_mode — JavaScript execution mode

Returns: Request/response details and assertion results

3. bruno_list_collections

Discover all collections in a workspace.

Parameters:

  • workspace_path (required) — Workspace directory
  • filter — Filter by collection name (substring)

Returns: Array of collection metadata

4. bruno_get_collection_info

Introspect collection structure before execution.

Parameters:

  • collection_path (required) — Collection path

Returns: Collection structure, requests, environments, variables

5. bruno_import_openapi

Bootstrap a collection from OpenAPI 3.0 specification.

Parameters:

  • spec_source (required) — Path or URL to OpenAPI spec
  • output_directory (required) — Where to create collection
  • collection_name — Collection name
  • collection_format — 'bru' or 'opencollection'
  • group_by — Group by 'tags' or 'path'
  • insecure — Skip TLS verification

Returns: Collection path and metadata

6. bruno_create_collection

Create a new empty collection scaffold.

Parameters:

  • collection_path (required) — Collection creation path
  • collection_name (required) — Collection name

Returns: Creation status and path

🔄 Agent Workflows

Autonomous Test Execution

Agent discovers spec → import_openapi → set environment → run_collection → parse results

Multi-Environment Validation

list_collections → for each environment: set_env + run_collection → compare results

Targeted Debugging

get_collection_info → run_request (single endpoint) → analyze response

Data-Driven Testing

run_collection with CSV file → multiple iterations → aggregate metrics

🔐 Authentication

Tools use environment variables for credentials. Bruno CLI manages environment setup — tools wrap CLI execution.

📖 Prerequisites

  • Bruno CLI installed globally: pnpm install -g @usebruno/cli
  • Python 3.11+
  • Bruno collections in .bru format or OpenAPI specs

🤝 Integration

Works with:

  • LangChain — Convert to StructuredTool
  • CrewAI — Convert to BaseTool
  • MCP — Expose via JSON-RPC to Claude / other MCP clients
  • Native — Direct SDK usage

📝 License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

matimo_bruno-0.1.0.tar.gz (16.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

matimo_bruno-0.1.0-py3-none-any.whl (19.9 kB view details)

Uploaded Python 3

File details

Details for the file matimo_bruno-0.1.0.tar.gz.

File metadata

  • Download URL: matimo_bruno-0.1.0.tar.gz
  • Upload date:
  • Size: 16.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for matimo_bruno-0.1.0.tar.gz
Algorithm Hash digest
SHA256 690fa3ba92d6216d8f7a71121b9f54e3ad849fa9eeb9ccab1ab1e67ac4254581
MD5 ae3fad331e6db7f15ff21c03fa4828f1
BLAKE2b-256 da7af9e8b5666ab5ee1b4f9e649a47e1ade9c721b706ce97d25ab4d17b0061fa

See more details on using hashes here.

File details

Details for the file matimo_bruno-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: matimo_bruno-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 19.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for matimo_bruno-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 c4c36848e5bf8a012c84bc11878a246692c4cf3ea2d0224942006c06fe2e89ee
MD5 cd5382131a207f9b01e1e69bb1db8f00
BLAKE2b-256 4e1d5816757228a1737583bc5fe4fa10b1c7df3142bc44f0617774d85b69fc9d

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page