Skip to content
Judgment Labs
Esc
↑↓navigate↵open⌘Jpreview

Requests Tracing

Trace Requests HTTP calls with Judgment.

Requests tracing uses the standard OpenTelemetry Requests instrumentation and routes outbound HTTP spans through Judgment.

uv add judgeval requests opentelemetry-instrumentation-requests
pip install judgeval requests opentelemetry-instrumentation-requests
from judgeval import Tracer
from opentelemetry.instrumentation.requests import RequestsInstrumentor

Tracer.init(project_name="requests_app")
Tracer.registerOTELInstrumentation(RequestsInstrumentor())

requests.get("https://example.com")
Tracer.force_flush()

Was this page helpful?