Back to skills
SKILL.md
Openclaw Logfire
ASecurityPydantic Logfire observability — OTEL GenAI traces, tool call spans, token metrics, distributed tracing
- 14 stars
- 0 votes
- 0 copies
- 3 views
- Added September 7, 2026
Works with
Security analysis
100/100Pro scans all 19 files and shows the line behind each finding
npx -y skills add modbender/skill-library-mcp --skill openclaw-logfire --agent claude-codeAre you the author of Openclaw Logfire?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/modbender-openclaw-logfire)---
name: openclaw-logfire
description: Pydantic Logfire observability — OTEL GenAI traces, tool call spans, token metrics, distributed tracing
version: 0.1.2
homepage: https://github.com/Ultrathink-Solutions/openclaw-logfire
metadata:
openclaw:
primaryEnv: LOGFIRE_TOKEN
requires:
env:
- LOGFIRE_TOKEN
---
# OpenClaw Logfire Plugin
Pydantic [Logfire](https://pydantic.dev/logfire) observability plugin for OpenClaw. Traces the full agent lifecycle with [OTEL GenAI semantic conventions](https://opentelemetry.io/docs/specs/semconv/gen-ai/) — tool calls, token usage, errors, and optional distributed tracing across services.
## Install
```bash
openclaw plugins install @ultrathink-solutions/openclaw-logfire
```
Set your Logfire write token:
```bash
export LOGFIRE_TOKEN="your-token"
```
Add to `openclaw.json`:
```json
{
"plugins": {
"entries": {
"openclaw-logfire": {
"enabled": true,
"config": {}
}
}
}
}
```
Restart OpenClaw. Traces appear in your Logfire dashboard.
## What It Traces
Every agent invocation produces a span tree:
```
invoke_agent chief-of-staff (root span)
|-- execute_tool Read (file read)
|-- execute_tool exec (shell command)
|-- execute_tool Write (file write)
```
Spans follow OTEL GenAI semantic conventions: `gen_ai.agent.name`, `gen_ai.tool.name`, `gen_ai.usage.input_tokens`, `gen_ai.usage.output_tokens`, etc.
## Metrics
- `gen_ai.client.token.usage` — token count histogram (input/output)
- `gen_ai.client.operation.duration` — agent invocation latency
## Key Configuration
| Setting | Default | Description |
|---------|---------|-------------|
| `environment` | `development` | Deployment environment label |
| `serviceName` | `openclaw-agent` | OTEL service name |
| `providerName` | — | GenAI provider (e.g. `anthropic`) |
| `captureToolInput` | `true` | Record tool arguments |
| `redactSecrets` | `true` | Strip API keys and JWTs |
| `distributedTracing.enabled` | `false` | W3C traceparent propagation |
## Security & Privacy
- **Secret redaction** (on by default): Strips API keys, platform tokens, JWTs, and credentials from recorded tool arguments before export
- **Tool output** is not captured by default (`captureToolOutput: false`)
- **Message content** is not captured by default (`captureMessageContent: false`)
- **Data destination**: Traces are exported via OTLP HTTP to Pydantic Logfire (US or EU region). No other external endpoints are contacted.
- **No local persistence**: All data is streamed to Logfire; nothing is written to disk
## External Endpoints
| URL | Data Sent |
|-----|-----------|
| `https://logfire-api.pydantic.dev` (US) | OTLP traces + metrics |
| `https://logfire-api-eu.pydantic.dev` (EU) | OTLP traces + metrics |
By using this plugin, trace and metric data is sent to Pydantic Logfire. Only install if you trust this destination.
## Links
- [GitHub](https://github.com/Ultrathink-Solutions/openclaw-logfire)
- [npm](https://www.npmjs.com/package/@ultrathink-solutions/openclaw-logfire)
- [Logfire](https://pydantic.dev/logfire)
- [Blog: We Put OpenClaw Into Production](https://ultrathinksolutions.com/the-signal/openclaw-to-production/)
Files in this skill
- CHANGELOG.md
- CONTRIBUTING.md
- README.md
- SKILL.md
- docs/worktracking/2025-12-04-logfire-pubsub-observability-plan.md
- docs/worktracking/2026-02-12-openclaw-chief-of-staff-deployment.md
- docs/worktracking/2026-02-14-openclaw-ops-os-redesign.md
- eslint.config.js
- openclaw.plugin.json
- package.json
- src/config.test.ts
- src/config.ts
- src/context/propagation.ts
- src/context/span-store.test.ts
- src/context/span-store.ts
- src/events/inference-details.ts
- src/hooks/agent-end.ts
- src/hooks/before-agent-start.ts
- src/hooks/before-tool-call.ts
Attribution
Comments
Loading comments…