IronTelemetry

IronTelemetry SDK for Python

Error monitoring and crash reporting for Python applications

PyPI version Python versions License: MIT

WebsiteDocumentationPython GuideGit

--- **IronTelemetry** helps you capture exceptions, track user journeys, and get actionable insights to fix issues faster. Built for developers who want simple, powerful error monitoring without the complexity. ## Features - **Exception Capture** - Automatically capture and report exceptions with full stack traces - **Journey Tracking** - Understand what users did before an error occurred - **Breadcrumbs** - Add context with custom breadcrumbs and metadata - **Framework Support** - Built-in integrations for Django, Flask, FastAPI - **Async Support** - Full async/await support - **Type Hints** - Complete type annotations for IDE support - **Offline Queue** - Events are queued when offline and sent when connectivity returns ## Installation ```bash pip install irontelemetry ``` ## Quick Start ### Initialize the SDK ```python import irontelemetry irontelemetry.init("https://pk_live_xxx@irontelemetry.com") ``` ### Capture Exceptions ```python try: do_something() except Exception as e: irontelemetry.capture_exception(e) raise ``` ### Track User Journeys ```python with irontelemetry.start_journey("Checkout Flow"): irontelemetry.set_user("user-123", "user@example.com") with irontelemetry.start_step("Validate Cart", "business"): validate_cart() with irontelemetry.start_step("Process Payment", "business"): process_payment() with irontelemetry.start_step("Send Confirmation", "notification"): send_confirmation_email() ``` ### Add Breadcrumbs ```python from irontelemetry import add_breadcrumb, BreadcrumbCategory add_breadcrumb("User clicked checkout button", BreadcrumbCategory.UI) add_breadcrumb("Payment API called", BreadcrumbCategory.HTTP) ``` ## Framework Integrations ### Django ```python # settings.py INSTALLED_APPS = [ 'irontelemetry.django', # ... ] IRONTELEMETRY_DSN = "https://pk_live_xxx@irontelemetry.com" ``` ### Flask ```python from flask import Flask from irontelemetry.flask import IronTelemetry app = Flask(__name__) IronTelemetry(app, dsn="https://pk_live_xxx@irontelemetry.com") ``` ### FastAPI ```python from fastapi import FastAPI from irontelemetry.fastapi import IronTelemetryMiddleware app = FastAPI() app.add_middleware(IronTelemetryMiddleware, dsn="https://pk_live_xxx@irontelemetry.com") ``` ## Configuration ```python from irontelemetry import TelemetryOptions, init init(TelemetryOptions( dsn="https://pk_live_xxx@irontelemetry.com", environment="production", app_version="1.2.3", sample_rate=1.0, debug=False, before_send=lambda event: event if "expected" not in (event.message or "") else None, )) ``` ## Documentation For complete documentation, visit [irontelemetry.com/docs](https://irontelemetry.com/docs). ## Other SDKs | Platform | Package | |----------|---------| | JavaScript/TypeScript | [@ironservices/telemetry](https://git.marketally.com/ironservices/irontelemetry-js) | | .NET | [IronTelemetry.Client](https://git.marketally.com/ironservices/irontelemetry-dotnet) | | Go | [irontelemetry-go](https://git.marketally.com/ironservices/irontelemetry-go) | | Java | [irontelemetry-java](https://git.marketally.com/ironservices/irontelemetry-java) | | Rust | [irontelemetry](https://git.marketally.com/ironservices/irontelemetry-rust) | ## Support - **Documentation**: [irontelemetry.com/docs](https://irontelemetry.com/docs) - **Email**: dev@ironservices.io - **Issues**: [git.marketally.com/ironservices/irontelemetry-python/issues](https://git.marketally.com/ironservices/irontelemetry-python/issues) ## License MIT License - see [LICENSE](LICENSE) for details.