opentelemetry-setup

opentelemetry-setup is a skill for Claude Code from StefanTheCode/dotnet-ai-toolkit. It costs 125 tokens per session (1,708 once invoked), scanned A, original, MIT.

A guide for adding OpenTelemetry to ASP.NET Core and other .NET applications. OpenTelemetry is a standard way to collect traces, measurements, and logs about running software.

In plain words
What is it for?
Use it to inspect a .NET project, add or repair tracing, metrics, and logs, and export them to systems such as Jaeger, Prometheus, an OTLP collector, or Azure Monitor.
Why use it?
It helps you see where requests spend time, how services are connected, and where failures occur, including when some monitoring is already configured.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the dotnet-ai-toolkit plugin — 49 skills shipped together

Good fit Use it to inspect a .NET project, add or repair tracing, metrics, and logs, and export them to systems such as Jaeger, Prometheus, an OTLP collector, or Azure Monitor.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/stefanthecode/dotnet-ai-toolkit/opentelemetry-setup
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add StefanTheCode/dotnet-ai-toolkit --skill opentelemetry-setup
Clone the repo
git clone --depth 1 https://github.com/StefanTheCode/dotnet-ai-toolkit

Made for: Claude Code.

Or install dotnet-ai-toolkit, the plugin that ships this one along with the rest of its 49 skills.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for opentelemetry-setup

README.md
[![agentmods](https://agentmods.dev/badge/skills/stefanthecode/dotnet-ai-toolkit/opentelemetry-setup/github.svg)](https://agentmods.dev/skills/stefanthecode/dotnet-ai-toolkit/opentelemetry-setup)
Your own site
<a href="https://agentmods.dev/skills/stefanthecode/dotnet-ai-toolkit/opentelemetry-setup"><img src="https://agentmods.dev/badge/skills/stefanthecode/dotnet-ai-toolkit/opentelemetry-setup/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for opentelemetry-setup

Your own site · 80×15
<a href="https://agentmods.dev/skills/stefanthecode/dotnet-ai-toolkit/opentelemetry-setup"><img src="https://agentmods.dev/badge/skills/stefanthecode/dotnet-ai-toolkit/opentelemetry-setup.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 125 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,708 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 1 finding, up to medium

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • medium Excessive Agency · line 12
    Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.
    Fix: Add human-in-the-loop confirmation for destructive, irreversible, or high-impact operations. Never auto-execute commands that modify files, send data, or alter system state.
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00125 $0.01708
Opus 5.5 $0.00050 $0.00683
Sonnet 5.5 $0.00025 $0.00342
Haiku 4.5 $0.00013 $0.00171

Measured 2mo ago against content hash 1cd60ba767ce, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

opentelemetry-setup scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/opentelemetry-setup/SKILL.md · 182 lines

How it starts

The opening of the file, as written. The whole thing — 182 lines — stays where its author put it; the contents beside it link to each section on GitHub.

OpenTelemetry Setup (.NET)

Wire up OpenTelemetry in an ASP.NET Core or .NET worker app — traces, metrics, and logs — exported to the backend the user wants, with sensible production defaults.

Input — point it at your project

Don't ask the user to paste Program.cs — point this at the project and inspect what's already there:

  • A project or repo root — find Program.cs / Startup.cs and any existing OTel wiring.
  • A folder or single file — if they point directly at the startup file.
  • A GitHub URL — clone first, then inspect: git clone --depth 1 <url> /tmp/repo && cd /tmp/repo

Discover the current state yourself before generating, e.g.:

find <target> -name Program.cs -o -name Startup.cs | grep -vi "/obj/\|/bin/"
grep -rn "AddOpenTelemetry\|WithTracing\|WithMetrics\|AddOtlpExporter\|UseSerilog" --include=*.cs <target>

If OTel is already partly set up (e.g. metrics but no tracing), extend it rather than starting over, and call out the specific gap. Read the .csproj to see which instrumentation packages are already referenced.

When this runs

The user wants observability in a .NET app: distributed tracing, metrics, structured logs, correlation across services, or export to a specific backend. Inspect the project first, then establish three things (ask only what you can't infer):

  1. App type — ASP.NET Core API, worker/background service, or library.
  2. Backend — OTLP collector (vendor-neutral, default), Jaeger, Prometheus + Grafana/Tempo, Azure Monitor / Application Insights, or "just console for now".
  3. .NET version — defaults assume .NET 8/9.

Workflow

  1. Confirm app type, backend, and signals wanted (traces / metrics / logs — default all three).
  2. Generate the Program.cs wiring + required NuGet packages.
  3. Add resource attributes (service name, version, environment) — non-negotiable for usable telemetry.
  4. Add the relevant instrumentation libraries (ASP.NET Core, HttpClient, EF Core, runtime).
  5. Show how to emit a custom span and a custom metric.
  6. Give the export config for the chosen backend, plus the collector/compose snippet if relevant.

Read the full file on GitHub · 182 lines

Files

What ships with it

2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2mo ago First seen · 182 lines · 125 tokens per session scan A 1cd60ba767ce

Subscribe to this mod's changes

opentelemetry-setup is a skill published in the GitHub repository StefanTheCode/dotnet-ai-toolkit (26 stars, last pushed 2mo ago), licensed MIT. It adds 125 tokens to every session and 1,708 once invoked, about $0.0005 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

opentelemetry-setup compared with skills from other repositories

opentelemetry-setup next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
opentelemetry-setupStefanTheCode/dotnet-ai-toolkitSkill262mo agoMITA125Claude Code
mem0-oss-to-platformmem0ai/mem0Skill68k2d agoApache-2.0A217Claude Code, Codex
azure-mgmt-botservice-dotnetmicrosoft/skillsSkill3.2kyesterdayMITA78Claude Code
fastapi-router-pymicrosoft/skillsSkill3.2kyesterdayMITA46Claude Code
dev-runtimelangwatch/langwatchSkill5.0kyesterdayApache-2.0A172Claude Code
api-designericrisco/rsc-harnessSkill5032d agoMITA105Claude Code, Codex
migrate-segw-to-raparc-mcp/arc-1Skill252yesterdayMITA106Claude Code