Need help with scanapi?
Click the “chat” button below for chat support from the developer who created it, or find similar developers for support.

About the developer

344 Stars 43 Forks MIT License 434 Commits 30 Opened issues


Automated Integration Testing and Live Documentation for your API

Services available


Need anything else?

Contributors list

CircleCI Codecov PyPI version Join the community on Spectrum

A library for your API that provides:

  • Automated Integration Testing
  • Automated Live Documentation

Given an API specification, written in YAML/JSON format, ScanAPI hits the specified endpoints, runs the test cases, and generates a detailed report of this execution - which can also be used as the API documentation itself.

With almost no Python knowledge, the user can define endpoints to be hit, the expected behavior for each response and will receive a full real-time diagnostic report of the API!



How to install

$ pip install scanapi

Basic Usage

You will need to write the API's specification and save it as a YAML or JSON file. For example:

  - name: scanapi-demo # The API's name of your API
    path: # The API's base url
      - name: list_all_devs # The name of the first request
        path: devs/ # The path of the first request
        method: get # The HTTP method of the first request
          - name: status_code_is_200 # The name of the first test for this request
            assert: ${{ response.status_code == 200 }} # The assertion

And run the scanapi command

$ scanapi run 

Then, the lib will hit the specified endpoints and generate a

file with the report results.

An overview screenshot of the report. A screenshot of the report showing the request details. A screenshot of the report showing the response and test details


The full documentation is available at


You can find complete examples at scanapi/examples!

This tutorial helps you to create integration tests for your REST API using ScanAPI

Watch the video


Collaboration is super welcome! We prepared the Newcomers Guide to help you in the first steps. Every little bit of help counts! Feel free to create new GitHub issues and interact here.

Let's build it together 🚀

We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.