Skip to content
Skills Library
DevOps & cloud · Building & coding

observability

/observability

This skill should be used when the user asks about "observability", "logging", "metrics", "tracing", "monitoring", "structured logging", "log format", "log levels", "distributed tracing", "OpenTelemetry", "health checks", or needs guidance on implementing observability and monitoring requirements.

Licence
MIT
Last repository change
06.07.2026

Assessment and security

100/ 100Class: good
Format25 / 25
Frontmatter with name and description, valid name, description up to 1,024 characters, name matching the folder.
Discoverability25 / 25
Description explains when to use the skill, has a reasonable length and uses third person.
Content35 / 35
At least 150 words and at most 500 lines, headings, step lists, examples or code.
Hygiene15 / 15
No placeholders such as TODO, no Windows paths, with a licence.
Riskno signals detected in the scan
Files in this package
1
Scripts
0
HTML comments
0
URLs in SKILL.md
2
Deprecation

No signals detected. Repository changed on 06.07.2026, without references to retired models or APIs.

Licence

MIT, open: use and modify while retaining author attribution.

What it does and when to use it

This skill should be used when the user asks about "observability", "logging", "metrics", "tracing", "monitoring", "structured logging", "log format", "log levels", "distributed tracing", "OpenTelemetry", "health checks", or needs guidance on implementing observability and monitoring requirements.

Triggers from the description

observabilityloggingmetricstracingmonitoringstructured logginglog formatlog levels
Original author description

This skill should be used when the user asks about "observability", "logging", "metrics", "tracing", "monitoring", "structured logging", "log format", "log levels", "distributed tracing", "OpenTelemetry", "health checks", or needs guidance on implementing observability and monitoring requirements.

How it works

  1. Tooling
  2. Logging Requirements
  3. Metrics Requirements
  4. Distributed Tracing
  5. Health Checks
  6. Alerting
  7. Implementation Checklist
  8. Compliance Verification
  9. Language-Specific Logging
  10. Additional Resources
Original SKILL.md headings · 302 lines, 986 words
SKILL.md preview
---
name: observability
description: This skill should be used when the user asks about "observability", "logging", "metrics", "tracing", "monitoring", "structured logging", "log format", "log levels", "distributed tracing", "OpenTelemetry", "health checks", or needs guidance on implementing observability and monitoring requirements.
version: 1.0.0
---

# Observability Standards

Guidance for implementing observability requirements including logging, metrics, tracing, and monitoring configuration.

## Tooling

> **Available Tools**: If using Claude Code, the `agents:sre-engineer` agent specializes in observability setup and SLO management. The `agents:devops-engineer` agent can help configure monitoring infrastructure.

## Logging Requirements

### Structured Logging (MUST)

All logging MUST use structured format (JSON preferred):

```json
{
  "timestamp": "2024-01-15T10:30:00.000Z",
  "level": "info",
  "message": "Request processed",
  "service": "api-gateway",
  "trace_id": "abc123",
  "span_id": "def456",
  "duration_ms": 45,
  "status_code": 200
}
```

### Log Levels (MUST)

Use consistent log levels with defined semantics:

| Level | Purpose                    | When to Use                       |
| ----- | -------------------------- | --------------------------------- |
| ERROR | Errors requiring attention | Failures, exceptions              |
| WARN  | Potential issues           | Degraded performance, retries     |
| INFO  | Significant events         | Request completion, state changes |
| DEBUG | Detailed information       | Development, troubleshooting      |
| TRACE | Very detailed tracing      | Deep debugging                    |

### Required Log Fields (MUST)

All log entries MUST include:

| Field       | Description                   |
| ----------- | ----------------------------- |
| `timestamp` | ISO 8601 format with timezone |
| `level`     | Log severity level            |
| `message`   | Human-readable description    |
| `service`   | Service/application name      |

### Recommended Log Fields (SHOULD)

Log entries SHOULD include when applicable:

| Field         | Description                        |
| ------------- | ---------------------------------- |
| `trace_id`    | Distributed trace identifier       |
| `span_id`     | Span identifier                    |
| `user_id`     | User identifier (if authenticated) |
| `request_id`  | Request correlation ID             |
| `duration_ms` | Operation duration                 |

### Sensitive Data (MUST NOT)

Logs MUST NOT contain:

- Passwords or secrets
- API keys or tokens
- Personal identifiable information (PII)
- Credit card numbers
- Session tokens

## Metrics Requirements

### Metric Types (MUST)

Implement appropriate metric types:

| Type      | Purpose               | Examples                    |
| --------- | --------------------- | --------------------------- |
| Counter   | Cumulative values     | Request count, errors       |
| Gauge     | Current values        | Queue size, connections     |
| Histogram | Value distributions   | Response time, payload size |
| Summary   | Quantile calculations | P50, P95, P99 latencies     |

### Required Metrics (MUST)

Services MUST expose:

| Metric                     | Type      | Description                       |
| -------------------------- | --------- | --------------------------------- |
| `requests_total`           | Counter   | Total requests by endpoint/status |
| `request_duration_seconds` | Histogram | Request latency                   |
| `errors_total`             | Counter   | Error count by type               |
| `active_connections`       | Gauge     | Current connections               |

### Metric Naming (MUST)

Follow naming conventions:

```
# Format: <namespace>_<name>_<unit>
http_requests_total
http_request_duration_seconds
db_connections_active
cache_hits_total
```

### Metric Labels (SHOULD)

Use consistent label naming:

| Label        | Description          |
| ------------ | -------------------- |
| `service`    | Service name         |
| `endpoint`   | API endpoint         |
| `method`     | HTTP method          |
| `status`     | Response status      |
| `error_type` | Error classification |

## Distributed Tracing

### Tracing Implementation (SHOULD)

Implement distributed tracing using OpenTelemetry:

```yaml
# OpenTelemetry configuration
exporters:
  otlp:
    endpoint: "collector:4317"

service:
  pipelines:
    traces:
      receivers: [otlp]
      processors: [batch]
      exporters: [otlp]
```

### Trace Context (MUST)

When tracing is implemented, propagate context:

| Header         | Standard            |
| -------------- | ------------------- |
| `traceparent`  | W3C Trace Context   |
| `tracestate`   | W3C Trace Context   |
| `X-Request-ID` | Request correlation |

### Span Requirements (SHOULD)

Spans SHOULD include:

- Operation name
- Start/end timestamps
- Status (OK, ERROR)
- Relevant attributes
- Error details (if applicable)

## Health Checks

### Health Endpoints (MUST)

Services MUST expose health endpoints:

| Endpoint        | Purpose         | Response              |
| --------------- | --------------- | --------------------- |
| `/health`       | Basic health    | 200 OK or 503         |
| `/health/live`  | Liveness probe  | 200 if running        |
| `/health/ready` | Readiness probe | 200 if ready to serve |

### Health Response Format (MUST)

```json
{
  "status": "healthy",
  "checks": {
    "database": {
      "status": "healthy",
      "latency_ms": 5
    },
    "cache": {
      "status": "healthy",
      "latency_ms": 1
    }
  },
  "version": "1.2.3",
  "uptime_seconds": 3600
}
```

### Dependency Checks (SHOULD)

Health checks SHOULD verify:

- Database connectivity
- Cache availability
- External service reachability
- Disk space adequacy
- Memory availability

## Alerting

### Alert Configuration (MUST)

Define alerts for critical conditions:

| Condition        | Severity | Response          |
| ---------------- | -------- | ----------------- |
| Service down     | Critical | Immediate page    |
| Error rate > 5%  | High     | Page within 5 min |
| Latency P95 > 1s | Medium   | Notify team       |
| Disk > 80%       | Warning  | Create ticket     |

### Alert Requirements (MUST)

Alerts MUST include:

- Clear description of condition
- Severity level
- Runbook link
- Affected service/component

## Implementation Checklist

- [ ] Configure structured logging
- [ ] Define log level policies
- [ ] Implement required metrics
- [ ] Set up health endpoints
- [ ] Configure distributed tracing (if applicable)
- [ ] Define alerting rules
- [ ] Create runbooks for alerts
- [ ] Verify sensitive data exclusion

## Compliance Verification

```bash
# Verify structured log output
app_command 2>&1 | jq .

# Check health endpoint
curl -s http://localhost:8080/health | jq .

# Verify metrics endpoint
curl -s http://localhost:8080/metrics | grep -E "^(http_|app_)"

# Check for sensitive data in logs
grep -r -i "password\|secret\|token" logs/ | wc -l
# Should be 0
```

## Language-Specific Logging

### Rust (tracing)

```rust
use tracing::{info, instrument};

#[instrument]
fn process_request(id: &str) {
    info!(request_id = %id, "Processing request");
}
```

### TypeScript (pino)

```typescript
import pino from "pino";

const logger = pino({
  level: "info",
  formatters: {
    level: (label) => ({ level: label }),
  },
});

logger.info({ requestId, duration }, "Request processed");
```

### Python (structlog)

```python
import structlog

logger = structlog.get_logger()
logger.info("request_processed", request_id=request_id, duration=duration)
```

## Additional Resources

### Reference Files

- **`references/logging-config.md`** - Logging configuration guide
- **`references/metrics-guide.md`** - Metrics implementation patterns

### Examples

- **`examples/otel-config.yaml`** - OpenTelemetry configuration
- **`examples/alerting-rules.yaml`** - Prometheus alerting rules

Versions

RepositoryScoreLicence
This page · zircote-plugins/sdlc-quality100MIT
maragudk/fabrik100MIT
matteocodogno/wellforge100MIT
iuliandita/skills100MIT
ctxpipe-ai/ctxpipe100MIT
rjmurillo/ai-agents100MIT
rjmurillo/ai-agents100MIT
wrongstack/wrongstack100MIT
nvidia/ai-factory-operations-agent100Apache-2.0

Database snapshot: 13.11.2026 · package version 80f8338cb080 (SHA-256 digest of the entire package)

Downloads in the last 30 days: 1 · ranking

Report a problem with this skill: harmful content, incorrect descriptions or an author’s removal request.

Similar skills

  • 90FastAPI Observability
    This skill should be used when the user asks to "add logging", "implement metrics", "add tracing", "configure Prometheus", "setup OpenTelemetry", "add health checks", "monitor API", or mentions observability, APM, monitoring, structured logging, distributed tracing, or Grafana.…
  • 100go-observability
    Structured logging, distributed tracing, metrics, and health checks for Go services. Covers slog, OpenTelemetry, Prometheus, and observability best practices. Use when: "add logging", "structured logs", "add tracing", "OpenTelemetry", "add metrics", "Prometheus",…
  • 100python-observability
    Python observability patterns including structured logging, metrics, and distributed tracing. Use when adding logging, implementing metrics collection, setting up tracing, or debugging production systems.
  • 100python-observability
    Python observability patterns including structured logging, metrics, and distributed tracing. Use when adding logging, implementing metrics collection, setting up tracing, or debugging production systems.
  • 95agent-observability
    Observability with OpenTelemetry, metrics, and logging. Use for monitoring agents and LLM calls.
  • 100python-observability-ops
    Observability patterns for Python applications. Triggers on: logging, metrics, tracing, opentelemetry, prometheus, observability, monitoring, structlog, correlation id.

Feedback and reports

Your message goes to Bartosz Sokoliński. An email address is needed only for a reply. See the privacy policy.