Skip to main content

A debugging dashboard for FastAPI applications with real-time monitoring

Project description

FastAPI Radar 🛰️

Python Version FastAPI License: MIT

A debugging dashboard for FastAPI applications providing real-time request, database query, and exception monitoring.

Installation

pip install fastapi-radar

Or with your favorite package manager:

# Using poetry
poetry add fastapi-radar

# Using pipenv
pipenv install fastapi-radar

Note: The dashboard comes pre-built! No need to build anything - just install and use.

Quick Start

from fastapi import FastAPI
from fastapi_radar import Radar
from sqlalchemy import create_engine

app = FastAPI()
engine = create_engine("sqlite:///./app.db")

# Initialize Radar - automatically adds middleware and mounts dashboard
radar = Radar(app, db_engine=engine)
radar.create_tables()

# Your routes work unchanged
@app.get("/users")
async def get_users():
    return {"users": []}

Access your dashboard at: http://localhost:8000/\_\_radar

Features

  • 🚀 Zero Configuration - Works with any FastAPI + SQLAlchemy app
  • 📊 Request Monitoring - Complete HTTP request/response capture with timing
  • 🗃️ Database Monitoring - SQL query logging with execution times
  • 🐛 Exception Tracking - Automatic exception capture with stack traces
  • Real-time Updates - Live dashboard updates as requests happen
  • 🎨 Beautiful UI - Modern React dashboard with shadcn/ui components

Screenshots

Configuration

radar = Radar(
    app,
    db_engine=engine,
    dashboard_path="/__radar",  # Custom dashboard path
    enable_in_production=False,  # Disable in production
    capture_body=True,           # Capture request/response bodies
    capture_headers=True,        # Capture headers
    max_body_size=10000,        # Max body size to capture
)

Contributing

We welcome contributions! Please see our Contributing Guide for details.

Development Setup

For contributors who want to modify the codebase:

  1. Clone the repository:
git clone https://github.com/doganarif/fastapi-radar.git
cd fastapi-radar
  1. Install development dependencies:
pip install -e ".[dev]"
  1. (Optional) If modifying the dashboard UI:
cd fastapi_radar/dashboard
npm install
npm run dev  # For development with hot reload
# or
npm run build  # To rebuild the production bundle
  1. Run the example app:
python example_app.py

License

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

Acknowledgments

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

fastapi_radar-0.1.1.tar.gz (268.1 kB view details)

Uploaded Source

Built Distribution

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

fastapi_radar-0.1.1-py3-none-any.whl (267.6 kB view details)

Uploaded Python 3

File details

Details for the file fastapi_radar-0.1.1.tar.gz.

File metadata

  • Download URL: fastapi_radar-0.1.1.tar.gz
  • Upload date:
  • Size: 268.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.5.28

File hashes

Hashes for fastapi_radar-0.1.1.tar.gz
Algorithm Hash digest
SHA256 90420cd60cb87999c0955d61f804b346317488ff616923d91ebda563e03f0233
MD5 47096c592182a35e8a9096263f3f2a49
BLAKE2b-256 3241e9ea795fabb52d8f19d1adff6fb4d5e84ed200a148f739fda6644fe8bd64

See more details on using hashes here.

File details

Details for the file fastapi_radar-0.1.1-py3-none-any.whl.

File metadata

File hashes

Hashes for fastapi_radar-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 910f1e18ad7a43a3569bee9c434717a2f377df1d532f315d86acb55c5ff6ea44
MD5 ef00b6dfd6098a65e5ee83590e88bc98
BLAKE2b-256 23f179e82ff8042a886db809d90e01bc5ef9b9f107a3f67e7b62f71ccb629c00

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