Agent skill

Logging

by Resgrid in Resgrid/Core

Observability for .NET 10 applications. An agent skill from Resgrid/Core.

Apache-2.0Auto-check passedDevOps & Cloud

Install Logging

skills CLI
$ npx skills add Resgrid/Core --skill logging -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install Resgrid/Core logging --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/Resgrid/Core.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.forge/skills/logging .claude/skills/logging && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
logging
GitHub stars
229
Token cost
~1.4k tokens
SKILL.md length
188 words
Files
1
Skills in repo
13
Repo updated
First seen
Licence
Apache-2.0

At a glance

Observability for .NET 10 applications. An agent skill from Resgrid/Core.

  • Works in 4 steps: Structured logging with Serilog — Every… → OpenTelemetry for distributed tracing —… → Health checks for operational readiness… → …
  • Mentions Serilog
  • SKILL.md covers Core Principles, Patterns, Anti-patterns and Decision Guide
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Logging is an agent skill from Resgrid/Core. Observability for .NET 10 applications. Covers Serilog structured logging, OpenTelemetry traces and metrics, health checks, and correlation IDs. Load this skill when setting up logging, tracing, metrics, or health monitoring, or when the user mentions "Serilog", "logging", "structured log", "OpenTelemetry", "traces", "metrics", "health check", "correlation ID", "observability", "telemetry", "log enrichment", or "ILogger".

Its SKILL.md is about 1.4k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in DevOps & Cloud, covering Observability. It works with OpenTelemetry and .NET. The repository describes itself as: The Open Source Computer Aided Dispatch (CAD), Personnel, Shift Management, Automatic Vehicle Location (AVL) and Emergency Management Platform that powers Resgrid.com. The licence is Apache-2.0.

When your agent uses it

  • Mentions Serilog
  • Tasks that involve Observability

Example prompts

  • “Serilog”
  • “logging”
  • “structured log”
  • “/logging”

Workflow steps

4 steps, taken from the first numbered list in SKILL.md.

  1. Structured logging with Serilog — Every log entry is a structured event with named properties, not a formatted string. This enables…
  2. OpenTelemetry for distributed tracing — Traces connect requests across services. Metrics track system health over time.
  3. Health checks for operational readiness — Every service exposes /health endpoints for load balancers and orchestrators.
  4. Correlation IDs for request tracing — Every request gets a unique ID that flows through all log entries and downstream service calls.

What it can do on your machine

Read from SKILL.md and the folder at commit 65103d9. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are csharp).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Logging loads about 1.4k tokens when it runs. Until then it costs about 108 tokens; SKILL.md has 188 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~108
When it runs · the whole SKILL.md, loaded when a task matches
~1.4k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from Resgrid/Core at commit 65103d9, republished under its Apache-2.0 licence (© Resgrid). 188 words, ~1,404 tokens.

Download SKILL.mdSave it as .claude/skills/logging/SKILL.md (or your agent's skills folder).
name
logging
description
Observability for .NET 10 applications. Covers Serilog structured logging, OpenTelemetry traces and metrics, health checks, and correlation IDs. Load this skill when setting up logging, tracing, metrics, or health monitoring, or when the user mentions "Serilog", "logging", "structured log", "OpenTelemetry", "traces", "metrics", "health check", "correlation ID", "observability", "telemetry", "log enrichment", or "ILogger".

Logging & Observability

Core Principles

  1. Structured logging with Serilog — Every log entry is a structured event with named properties, not a formatted string. This enables searching, filtering, and alerting.
  2. OpenTelemetry for distributed tracing — Traces connect requests across services. Metrics track system health over time.
  3. Health checks for operational readiness — Every service exposes /health endpoints for load balancers and orchestrators.
  4. Correlation IDs for request tracing — Every request gets a unique ID that flows through all log entries and downstream service calls.

Patterns

Serilog Setup
csharp
// Program.cs
builder.Host.UseSerilog((context, loggerConfig) =>
{
    loggerConfig
        .ReadFrom.Configuration(context.Configuration)
        .Enrich.FromLogContext()
        .Enrich.WithMachineName()
        .Enrich.WithProperty("Application", "MyApp.Api")
        .WriteTo.Console(outputTemplate:
            "[{Timestamp:HH:mm:ss} {Level:u3}] {Message:lj} {Properties:j}{NewLine}{Exception}")
        .WriteTo.Seq(context.Configuration["Seq:Url"] ?? "http://localhost:5341");
});

// After building the app
app.UseSerilogRequestLogging(options =>
{
    options.EnrichDiagnosticContext = (diagnosticContext, httpContext) =>
    {
        diagnosticContext.Set("UserId",
            httpContext.User.FindFirstValue(ClaimTypes.NameIdentifier) ?? "anonymous");
    };
});
Structured Logging (Correct Usage)
csharp
// GOOD — structured logging with message template
logger.LogInformation("Processing order {OrderId} for customer {CustomerId}",
    orderId, customerId);

// GOOD — include relevant context
logger.LogWarning("Payment failed for order {OrderId}. Attempt {Attempt} of {MaxAttempts}",
    orderId, attempt, maxAttempts);

// GOOD — log exceptions with structured data
logger.LogError(exception, "Failed to process order {OrderId}", orderId);
Correlation IDs
csharp
// Middleware to set correlation ID
public class CorrelationIdMiddleware(RequestDelegate next)
{
    private const string CorrelationIdHeader = "X-Correlation-Id";

    public async Task InvokeAsync(HttpContext context)
    {
        var correlationId = context.Request.Headers[CorrelationIdHeader].FirstOrDefault()
            ?? Guid.NewGuid().ToString();

        context.Items["CorrelationId"] = correlationId;
        context.Response.Headers[CorrelationIdHeader] = correlationId;

        using (LogContext.PushProperty("CorrelationId", correlationId))
        {
            await next(context);
        }
    }
}

// Program.cs
app.UseMiddleware<CorrelationIdMiddleware>();
OpenTelemetry Integration

For full OpenTelemetry setup (metrics, tracing, OTLP export), see the opentelemetry skill. The logging skill focuses on structured logging with Serilog. OpenTelemetry handles the export pipeline.

Health Checks
csharp
// Program.cs
builder.Services.AddHealthChecks()
    .AddNpgSql(builder.Configuration.GetConnectionString("Default")!,
        name: "database", tags: ["ready"])
    .AddRedis(builder.Configuration.GetConnectionString("Redis")!,
        name: "redis", tags: ["ready"])
    .AddRabbitMQ(builder.Configuration.GetConnectionString("RabbitMq")!,
        name: "rabbitmq", tags: ["ready"]);

// Map endpoints
app.MapHealthChecks("/health/live", new HealthCheckOptions
{
    Predicate = _ => false // No dependency checks — just "am I running?"
});

app.MapHealthChecks("/health/ready", new HealthCheckOptions
{
    Predicate = check => check.Tags.Contains("ready")
});

Anti-patterns

Don't Use String Interpolation in Log Messages
csharp
// BAD — allocates string even if level is disabled, breaks structured logging
logger.LogInformation($"Order {orderId} created for {customerId}");

// GOOD — message template with named parameters
logger.LogInformation("Order {OrderId} created for {CustomerId}", orderId, customerId);
Don't Log Sensitive Data
csharp
// BAD — logging credentials
logger.LogInformation("User logged in: {Email} with password {Password}", email, password);

// GOOD — never log secrets, passwords, tokens, or PII
logger.LogInformation("User logged in: {Email}", email);
Don't Skip Health Check Tags
csharp
// BAD — all checks run for liveness AND readiness
app.MapHealthChecks("/health");

// GOOD — separate liveness (am I running?) from readiness (can I serve traffic?)
app.MapHealthChecks("/health/live", new() { Predicate = _ => false });
app.MapHealthChecks("/health/ready", new() { Predicate = c => c.Tags.Contains("ready") });

Decision Guide

ScenarioRecommendation
Application loggingSerilog with structured logging
Distributed tracingOpenTelemetry with OTLP exporter
Custom business metricsIMeterFactory + counters/histograms
Request tracingCorrelation ID middleware
Container health/health/live and /health/ready endpoints
Log storageSeq (development), Elastic/Grafana (production)
Log levelsDebug in dev, Information in staging, Warning in production

© Resgrid, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .forge/skills/logging of Resgrid/Core.

Open the folder on GitHubat commit 65103d9

Compare with similar skills

Logging next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Logging compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Logging this skillResgrid/Core229—~1.4kAutomated safety check: PassApache-2.0
Aspire Service DefaultsAaronontheweb/dotnet-skills1.2k1 repos~2.6kAutomated safety check: PassMIT
Otel Instrumentationatherio-danp/cde-dotnetcc109—~1.3kAutomated safety check: NotesNone
Dotnet Devopsnovotnyllc/dotnet-artisan233—~1.1kAutomated safety check: PassMIT
Opentelemetrycodewithmukesh/dotnet-claude-kit7511 repos~2.3kAutomated safety check: PassMIT
Serilogcodewithmukesh/dotnet-claude-kit7511 repos~2.4kAutomated safety check: PassMIT

Similar skills

  • Aspire Service Defaults

    Aaronontheweb/dotnet-skills

    Sets up a shared ServiceDefaults project for .NET Aspire apps that centralizes OpenTelemetry, health checks, HTTP resilience and service discovery for every service.

    1.2k GitHub starsUsed in 1 repo~2.6k tokens
    DevOps & CloudAuto-check passed
  • Otel Instrumentation

    atherio-danp/cde-dotnetcc

    Add or change OpenTelemetry tracing, metrics, and structured logging in the .NET API (apps/api) — OTLP exporter setup, custom ActivitySource spans, IMeterFactory metrics, log/trace correlation.

    109 GitHub stars~1.3k tokensUpdated 2 mo ago
    DevOps & CloudAuto-check: notes
  • Dotnet Devops

    novotnyllc/dotnet-artisan

    Configures .NET CI/CD pipelines (GitHub Actions with setup-dotnet, NuGet cache, reusable workflows; Azure DevOps with DotNetCoreCLI, templates, multi-stage), containerization (multi-stage…

    233 GitHub stars~1.1k tokensUpdated today
    DevOps & CloudAuto-check passed
  • Opentelemetry

    codewithmukesh/dotnet-claude-kit

    OpenTelemetry observability for .NET 10 applications. An agent skill from codewithmukesh/dotnet-claude-kit.

    751 GitHub starsUsed in 1 repo~2.3k tokens
    DevOps & CloudAuto-check passed
  • Serilog

    codewithmukesh/dotnet-claude-kit

    Structured logging with Serilog for .NET 10 applications. An agent skill from codewithmukesh/dotnet-claude-kit.

    751 GitHub starsUsed in 1 repo~2.4k tokens
    DevOps & CloudAuto-check passed
  • Logging

    codewithmukesh/dotnet-claude-kit

    Observability overview and glue for .NET 10: how the pieces fit together, plus the cross-cutting parts owned here — ASP.NET health check endpoints (/health), correlation IDs, and log-level strategy.

    751 GitHub stars~1.6k tokensUpdated 2 mo ago
    DevOps & CloudAuto-check passed

More from Resgrid/Core

All 13 skills in this repo
  • 80 20 Review

    Resgrid/Core

    Focus code review effort on the 20% of code that causes 80% of issues.

    229 GitHub stars~2.8k tokensUpdated today
    Auto-check passed
  • Autonomous Loops

    Resgrid/Core

    Autonomous iteration loops for .NET development: build-fix, test-fix, refactor, and scaffold loops.

    229 GitHub stars~3.6k tokensUpdated today
    Auto-check passed
  • Learning Log

    Resgrid/Core

    Auto-document insights and discoveries during development sessions.

    229 GitHub stars~2.2k tokensUpdated today
    Auto-check passed
  • Model Selection

    Resgrid/Core

    Strategic Codex model selection for .NET development workflows.

    229 GitHub stars~2k tokensUpdated today
    Auto-check passed
  • Model Selection

    Resgrid/Core

    Strategic Claude model selection for .NET development workflows.

    229 GitHub stars~2k tokensUpdated today
    Auto-check passed
  • Session Management

    Resgrid/Core

    End-to-end session lifecycle management for .NET projects. An agent skill from Resgrid/Core.

    229 GitHub stars~3.4k tokensUpdated today
    Auto-check passed

Categories

Questions about Logging

What does Logging do?

Observability for .NET 10 applications. An agent skill from Resgrid/Core. Logging is an agent skill from Resgrid/Core.NET 10 applications.

When should I use Logging?

Logging fits situations like: mentions Serilog; tasks that involve Observability.

How do I install Logging in Claude Code?

Run `npx skills add Resgrid/Core --skill logging -a claude-code`. Or copy the skill folder (.forge/skills/logging in Resgrid/Core) into .claude/skills/logging in your project. Claude Code loads it when a task matches its description.

How do I install Logging in Codex?

Run `npx skills add Resgrid/Core --skill logging -a codex`. Or copy the skill folder (.forge/skills/logging in Resgrid/Core) into .agents/skills/logging in your project. Codex loads it when a task matches its description.

Can I use Logging in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add Resgrid/Core --skill logging -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/logging, .gemini/skills/logging, .github/skills/logging and .opencode/skills/logging in your project.

What does Logging need to run?

SKILL.md names no scripts, command-line tools or credentials: Logging is instructions for the agent only.

Does Logging access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Logging safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Logging use?

Logging is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Logging use?

About 1.4k tokens (SKILL.md is roughly 5.6k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Logging?

Skills that share tags, products or a category with Logging: Aspire Service Defaults (Aaronontheweb/dotnet-skills, 1.2k stars), Otel Instrumentation (atherio-danp/cde-dotnetcc, 109 stars), Dotnet Devops (novotnyllc/dotnet-artisan, 233 stars) and Opentelemetry (codewithmukesh/dotnet-claude-kit, 751 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Logging?

Resgrid (a GitHub organization) maintains it in Resgrid/Core, which has 229 GitHub stars. The repository holds 13 skills in this directory. The repository was last updated on October 8, 2026.

Source: Resgrid/Core on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.