# Telemetry

> Add production observability to a function. Wraps it in an OpenTelemetry or Sentry trace span, injects execution metadata, and proposes a concrete alert rule with threshold and severity.

- **Type:** Skill
- **Install:** `agentstack add skill-v0idos-performance-deity-telemetry`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [v0idOS](https://agentstack.voostack.com/s/v0idos)
- **Installs:** 0
- **Category:** [Developer Tools](https://agentstack.voostack.com/c/developer-tools)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [v0idOS](https://github.com/v0idOS)
- **Source:** https://github.com/v0idOS/performance-deity/tree/main/skills/telemetry
- **Website:** https://v0idos.github.io/performance-deity/

## Install

```sh
agentstack add skill-v0idos-performance-deity-telemetry
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

Execute all three phases in order.

## Phase 1 — Trace Wrap

Wrap the critical-path function in a trace span:

**OpenTelemetry:**
```js
tracer.startActiveSpan('operation.name', (span) => {
  // ... function body
  span.end();
});
```

**Sentry:**
```js
const transaction = Sentry.startTransaction({ name: 'operation.name' });
// ... function body
transaction.finish();
```

**Datadog:**
```js
tracer.trace('operation.name', () => {
  // ... function body
});
```

## Phase 2 — Attribute Injection

Inside the span, attach:
- Execution time (start and stop timer)
- Query tags: `user_id`, `tenant_id`, `endpoint`
- Input and output payload sizes in bytes

## Phase 3 — Alert Rule

Propose an alert rule with all four fields specified:

| Field | Value |
|---|---|
| Metric | (e.g. `trace.operation.duration`) |
| Threshold | (e.g. `> 200ms`) |
| Evaluation window | (e.g. `last 5 minutes`) |
| Severity | (e.g. P2 / warning) |

**Examples:**
- Datadog: `avg(last_5m):avg:trace.operation.duration{env:prod} > 0.200` → P2
- Prometheus: `histogram_quantile(0.99, rate(http_request_duration_seconds_bucket[5m])) > 0.2` → warning

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [v0idOS](https://github.com/v0idOS)
- **Source:** [v0idOS/performance-deity](https://github.com/v0idOS/performance-deity)
- **License:** MIT
- **Homepage:** https://v0idos.github.io/performance-deity/

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-v0idos-performance-deity-telemetry
- Seller: https://agentstack.voostack.com/s/v0idos
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
