Skip to content

scarowar/insomnia-run

Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace
Insomnia Run

CI CodeQL MIT License All Contributors

DocumentationGetting StartedExamples


Run your Insomnia API collections and test suites in GitHub Actions with automatic PR comment reporting.

Why Insomnia Run? Insomnia is great for designing and testing APIs locally. This action brings those same collections into your CI/CD pipeline—no separate test framework needed.

Insomnia.Run.mp4

Features

  • GitHub Actions Native: Drop-in action with simple YAML configuration
  • Automatic PR Comments: Post test results directly to pull requests
  • Markdown & JSON Reports: Human-readable and machine-readable outputs
  • Flexible Exit Codes: Control workflow failure behavior
  • Environment Support: Target different Insomnia environments per run
  • Secure Secrets: Pass credentials safely via GitHub Secrets
  • Configurable Timeouts: Handle slow APIs and large collections

Quick Start

Run a collection:

- uses: scarowar/insomnia-run@v0.1.0
  with:
    command: collection
    working-directory: .insomnia

Run a test suite:

- uses: scarowar/insomnia-run@v0.1.0
  with:
    command: test
    working-directory: .insomnia
    identifier: "My Test Suite"

Inputs

Input Required Default Description
command Yes collection or test
working-directory Yes Path to .insomnia or export file
identifier No Collection/test suite name or ID
environment No Insomnia environment to use
pr-comment No true Post results as PR comment
fail-on-error No true Fail workflow on test failures
output-format No Use json to get JSON output in addition to Markdown

View all inputs

Outputs

Output Description
markdown Generated test report in Markdown format
json-output Generated JSON report (machine-readable)
exit-code 0 for pass, 1 for fail

Documentation

Guide Description
Getting Started First run in 5 minutes
Collections Run API collections
Test Suites Run unit tests
Secrets Handle credentials
Examples Workflow snippets
Troubleshooting Common issues

License

This project is licensed under the MIT License. See the LICENSE file for details.

Contributors ✨

Thanks goes to these wonderful people (emoji key):

Sagar Shaw BITS
Sagar Shaw BITS

💻
Chase Naples
Chase Naples

💻
Radha Patel
Radha Patel

💻 📖

This project follows the all-contributors specification. Contributions of any kind welcome!

About

GitHub Action to run Insomnia collections and test suites in CI/CD pipelines with automatic PR comment reporting

Topics

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Contributors

Languages