Logfire and any opentelemetry compatible tracing library works out of the box with Portkey.

All you need to do is set the following environment variables in your application:

OTEL_EXPORTER_OTLP_ENDPOINT = "https://api.portkey.com/v1/logs/otel"
OTEL_EXPORTER_OTLP_HEADERS = "x-portkey-api-key={YOUR_PORTKEY_API_KEY}"