Akka.NET Best Practices
Aaronontheweb/dotnet-skills
Guidance for Akka.NET actor systems covering EventStream versus DistributedPubSub, supervision, Props versus DependencyResolver, work distribution and testable cluster code.
Error handling strategy for .NET 10 applications. An agent skill from codewithmukesh/dotnet-claude-kit.
$ npx skills add codewithmukesh/dotnet-claude-kit --skill error-handling -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install codewithmukesh/dotnet-claude-kit error-handling --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/codewithmukesh/dotnet-claude-kit.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/error-handling .claude/skills/error-handling && rm -rf skills-srcUse ~/.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/
Install the "error-handling" agent skill from https://github.com/codewithmukesh/dotnet-claude-kit/tree/main/skills/error-handling into .claude/skills/error-handling/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "error-handling", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/codewithmukesh/dotnet-claude-kit/tree/main/skills/error-handlingType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add codewithmukesh/dotnet-claude-kit --skill error-handling -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install codewithmukesh/dotnet-claude-kit error-handling --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/codewithmukesh/dotnet-claude-kit.git skills-src && mkdir -p .agents/skills && cp -r skills-src/skills/error-handling .agents/skills/error-handling && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "error-handling" agent skill from https://github.com/codewithmukesh/dotnet-claude-kit/tree/main/skills/error-handling into .agents/skills/error-handling/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "error-handling", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add codewithmukesh/dotnet-claude-kit --skill error-handling -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install codewithmukesh/dotnet-claude-kit error-handling --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/codewithmukesh/dotnet-claude-kit.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/skills/error-handling .cursor/skills/error-handling && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "error-handling" agent skill from https://github.com/codewithmukesh/dotnet-claude-kit/tree/main/skills/error-handling into .cursor/skills/error-handling/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "error-handling", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/codewithmukesh/dotnet-claude-kit.git --path skills/error-handling--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add codewithmukesh/dotnet-claude-kit --skill error-handling -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install codewithmukesh/dotnet-claude-kit error-handling --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/codewithmukesh/dotnet-claude-kit.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/skills/error-handling .gemini/skills/error-handling && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "error-handling" agent skill from https://github.com/codewithmukesh/dotnet-claude-kit/tree/main/skills/error-handling into .gemini/skills/error-handling/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "error-handling", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install codewithmukesh/dotnet-claude-kit error-handlingInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add codewithmukesh/dotnet-claude-kit --skill error-handling -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/codewithmukesh/dotnet-claude-kit.git skills-src && mkdir -p .github/skills && cp -r skills-src/skills/error-handling .github/skills/error-handling && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "error-handling" agent skill from https://github.com/codewithmukesh/dotnet-claude-kit/tree/main/skills/error-handling into .github/skills/error-handling/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "error-handling", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add codewithmukesh/dotnet-claude-kit --skill error-handling -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install codewithmukesh/dotnet-claude-kit error-handling --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/codewithmukesh/dotnet-claude-kit.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/skills/error-handling .opencode/skills/error-handling && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "error-handling" agent skill from https://github.com/codewithmukesh/dotnet-claude-kit/tree/main/skills/error-handling into .opencode/skills/error-handling/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "error-handling", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
error-handlingError handling strategy for .NET 10 applications. An agent skill from codewithmukesh/dotnet-claude-kit.
Error Handling is an agent skill from codewithmukesh/dotnet-claude-kit. Error handling strategy for .NET 10 applications. Covers the Result pattern, ProblemDetails (RFC 9457), global exception handling, FluentValidation, and structured error responses. Load this skill when implementing error handling, validation, or designing API error contracts, or when the user mentions "error handling", "Result pattern", "ProblemDetails", "exception", "validation", "FluentValidation", "error response", "global exception handler", or "RFC 9457".
Its SKILL.md is about 2.1k 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 Development, covering Error handling. It works with .NET. The repository describes itself as: Make Claude Code a .NET 10 Expert. The licence is MIT.
4 steps, taken from the first numbered list in SKILL.md.
Read from SKILL.md and the folder at commit 2330089. It shows what the files ask for, not the result of running them.
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.
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.
Hosts in commands or code, which the agent is likely to contact:
tools.ietf.orgFrom URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Error Handling loads about 2.1k tokens when it runs. Until then it costs about 120 tokens; SKILL.md has 230 words of instructions outside code blocks.
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.
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.
The full file from codewithmukesh/dotnet-claude-kit at commit 2330089, republished under its MIT licence (© codewithmukesh). 230 words, ~2,068 tokens.
.claude/skills/error-handling/SKILL.md (or your agent's skills folder).type, title, status, detail, and optionally errors.A simple, generic result type that carries either a value or errors.
public class Result
{
public bool IsSuccess { get; }
public bool IsFailure => !IsSuccess;
public List<string> Errors { get; }
protected Result(bool isSuccess, List<string>? errors = null)
{
IsSuccess = isSuccess;
Errors = errors ?? [];
}
public static Result Success() => new(true);
public static Result Failure(params string[] errors) => new(false, [..errors]);
public static Result<T> Success<T>(T value) => new(value);
public static Result<T> Failure<T>(params string[] errors) => new(errors);
}
public class Result<T> : Result
{
public T Value { get; }
internal Result(T value) : base(true) => Value = value;
internal Result(IEnumerable<string> errors) : base(false, [..errors]) => Value = default!;
}public static class ResultExtensions
{
public static IResult ToProblemDetails(this Result result, int statusCode = 400)
{
return TypedResults.Problem(
title: "One or more errors occurred",
statusCode: statusCode,
extensions: new Dictionary<string, object?>
{
["errors"] = result.Errors
});
}
}
// Usage in endpoint
group.MapPost("/", async (CreateOrder.Command command, ISender sender, CancellationToken ct) =>
{
var result = await sender.Send(command, ct);
return result.IsSuccess
? TypedResults.Created($"/api/orders/{result.Value.Id}", result.Value)
: result.ToProblemDetails();
});Catches unexpected exceptions and converts them to ProblemDetails. For the modern IExceptionHandler approach (preferred), see knowledge/common-infrastructure.md. The inline lambda below works for simple cases:
// Program.cs
app.UseExceptionHandler(errorApp =>
{
errorApp.Run(async context =>
{
var exception = context.Features.Get<IExceptionHandlerFeature>()?.Error;
var logger = context.RequestServices.GetRequiredService<ILogger<Program>>();
logger.LogError(exception, "Unhandled exception for {Method} {Path}",
context.Request.Method, context.Request.Path);
var problem = new ProblemDetails
{
Title = "An unexpected error occurred",
Status = StatusCodes.Status500InternalServerError,
Type = "https://tools.ietf.org/html/rfc9110#section-15.6.1"
};
// Don't leak details in production
if (context.RequestServices.GetRequiredService<IHostEnvironment>().IsDevelopment())
{
problem.Detail = exception?.Message;
}
context.Response.StatusCode = problem.Status.Value;
await context.Response.WriteAsJsonAsync(problem);
});
});// Validator
public class CreateOrderValidator : AbstractValidator<CreateOrderRequest>
{
public CreateOrderValidator()
{
RuleFor(x => x.CustomerId)
.NotEmpty().WithMessage("Customer ID is required");
RuleFor(x => x.Items)
.NotEmpty().WithMessage("At least one item is required");
RuleForEach(x => x.Items).ChildRules(item =>
{
item.RuleFor(x => x.ProductId).NotEmpty();
item.RuleFor(x => x.Quantity).GreaterThan(0);
});
}
}
// Generic validation filter
public class ValidationFilter<TRequest> : IEndpointFilter
{
public async ValueTask<object?> InvokeAsync(
EndpointFilterInvocationContext context,
EndpointFilterDelegate next)
{
var validator = context.HttpContext.RequestServices.GetService<IValidator<TRequest>>();
if (validator is null)
return await next(context);
var request = context.Arguments.OfType<TRequest>().FirstOrDefault();
if (request is null)
return await next(context);
var result = await validator.ValidateAsync(request);
if (!result.IsValid)
{
return TypedResults.ValidationProblem(result.ToDictionary());
}
return await next(context);
}
}
// Registration
group.MapPost("/", CreateOrder)
.AddEndpointFilter<ValidationFilter<CreateOrderRequest>>();For richer error handling, use typed error enums or error objects.
public abstract record Error(string Code, string Message);
public record NotFoundError(string Entity, object Id)
: Error("not_found", $"{Entity} with ID {Id} was not found");
public record ValidationError(string Field, string Message)
: Error("validation", Message);
public record ConflictError(string Message)
: Error("conflict", Message);
// Map to HTTP status codes
public static IResult ToHttpResult(this Error error) => error switch
{
NotFoundError => TypedResults.Problem(title: error.Message, statusCode: 404),
ValidationError => TypedResults.Problem(title: error.Message, statusCode: 400),
ConflictError => TypedResults.Problem(title: error.Message, statusCode: 409),
_ => TypedResults.Problem(title: error.Message, statusCode: 500)
};// BAD — exceptions for expected outcomes
public Order GetOrder(Guid id)
{
var order = db.Orders.Find(id)
?? throw new NotFoundException($"Order {id} not found");
return order;
}
// GOOD — Result pattern
public Result<Order> GetOrder(Guid id)
{
var order = db.Orders.Find(id);
return order is not null
? Result.Success(order)
: Result.Failure<Order>($"Order {id} not found");
}// BAD — inconsistent error format
return Results.BadRequest("Something went wrong");
return Results.BadRequest(new { error = "Invalid input" });
// GOOD — always ProblemDetails
return TypedResults.Problem(title: "Invalid input", statusCode: 400);
return TypedResults.ValidationProblem(validationResult.ToDictionary());// BAD — silently swallowing
try { await ProcessOrder(order); }
catch (Exception) { /* ignore */ }
// GOOD — log and handle appropriately
try { await ProcessOrder(order); }
catch (PaymentException ex)
{
logger.LogWarning(ex, "Payment failed for order {OrderId}", order.Id);
return Result.Failure<Order>("Payment processing failed");
}| Scenario | Recommendation |
|---|---|
| Expected business failure | Result pattern |
| Input validation | FluentValidation with endpoint filter |
| Unexpected crash | Global exception handler → ProblemDetails |
| API error format | RFC 9457 ProblemDetails — always |
| Validation in handler | Return Result.Failure, don't throw |
| External service failure | Catch specific exception, return Result.Failure |
| Logging errors | Structured logging with correlation ID |
© codewithmukesh, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in skills/error-handling of codewithmukesh/dotnet-claude-kit.
Open the folder on GitHubat commit 2330089
We found 4 copies of this SKILL.md (exact, near-identical or edited) in other folders, from 1 other GitHub owner. This page covers the copy in codewithmukesh/dotnet-claude-kit, which our catalogue first saw on October 7, 2026.
Error Handling 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.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Error Handling this skillcodewithmukesh/dotnet-claude-kit | 751 | 1 repos | ~2.1k | Automated safety check: Pass | MIT | |
| Akka.NET Best PracticesAaronontheweb/dotnet-skills | 1.2k | 1 repos | ~3.3k | Automated safety check: Pass | MIT | |
| Project Workflow Analysis Blueprint Generatorgithub/awesome-copilot | 40k | 1 repos | ~2.7k | Automated safety check: Pass | MIT | |
| Dotnet Webapidotnet/skills | 5.6k | 2 repos | ~5.5k | Automated safety check: Pass | MIT | |
| Error HandlingNethereum/Nethereum | 2.3k | — | ~1.1k | Automated safety check: Pass | MIT | |
| Mole Bug Patternstw93/Mole | 69k | — | ~2k | Automated safety check: Pass | GPL-3.0 |
Aaronontheweb/dotnet-skills
Guidance for Akka.NET actor systems covering EventStream versus DistributedPubSub, supervision, Props versus DependencyResolver, work distribution and testable cluster code.
github/awesome-copilot
Comprehensive technology-agnostic prompt generator for documenting end-to-end application workflows.
dotnet/skills
Guides creation and modification of ASP.NET Core Web API endpoints with correct HTTP semantics, OpenAPI metadata, and error handling.
Nethereum/Nethereum
Handle smart contract reverts and decode custom error types using Nethereum (.NET).
tw93/Mole
A catalog of recurring bug shapes in the Mole Mac cleaner, used to review safety-sensitive diffs for deletion safety, unbounded commands, shell traps and weak tests.
CherryHQ/cherry-studio-app
A skill your agent uses when implementing or debugging ANY network request, API call, or data fetching.
codewithmukesh/dotnet-claude-kit
API versioning strategies for ASP.NET Core. An agent skill from codewithmukesh/dotnet-claude-kit.
codewithmukesh/dotnet-claude-kit
Architecture-aware feature scaffolding for .NET 10 projects.
codewithmukesh/dotnet-claude-kit
Architecture selection advisor for .NET applications. An agent skill from codewithmukesh/dotnet-claude-kit.
codewithmukesh/dotnet-claude-kit
.NET Aspire for cloud-native orchestration. An agent skill from codewithmukesh/dotnet-claude-kit.
codewithmukesh/dotnet-claude-kit
Authentication and authorization for ASP.NET Core. An agent skill from codewithmukesh/dotnet-claude-kit.
codewithmukesh/dotnet-claude-kit
Caching strategies for .NET 10 applications. An agent skill from codewithmukesh/dotnet-claude-kit.
Works with
Categories
Error handling strategy for .NET 10 applications. An agent skill from codewithmukesh/dotnet-claude-kit. Error Handling is an agent skill from codewithmukesh/dotnet-claude-kit.NET 10 applications.
Error Handling fits situations like: mentions error handling; fluentValidation; global exception handler.
Run `npx skills add codewithmukesh/dotnet-claude-kit --skill error-handling -a claude-code`. Or copy the skill folder (skills/error-handling in codewithmukesh/dotnet-claude-kit) into .claude/skills/error-handling in your project. Claude Code loads it when a task matches its description.
Run `npx skills add codewithmukesh/dotnet-claude-kit --skill error-handling -a codex`. Or copy the skill folder (skills/error-handling in codewithmukesh/dotnet-claude-kit) into .agents/skills/error-handling in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add codewithmukesh/dotnet-claude-kit --skill error-handling -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/error-handling, .gemini/skills/error-handling, .github/skills/error-handling and .opencode/skills/error-handling in your project.
SKILL.md names no scripts, command-line tools or credentials: Error Handling is instructions for the agent only.
SKILL.md names 1 domain. In commands or code: tools.ietf.org; the agent is likely to contact it when it follows the instructions. This is read from the text; nothing was executed.
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.
Error Handling is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 2.1k tokens (SKILL.md is roughly 8.3k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Error Handling: Akka.NET Best Practices (Aaronontheweb/dotnet-skills, 1.2k stars), Project Workflow Analysis Blueprint Generator (github/awesome-copilot, 40k stars), Dotnet Webapi (dotnet/skills, 5.6k stars) and Error Handling (Nethereum/Nethereum, 2.3k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
codewithmukesh (a GitHub organization) maintains it in codewithmukesh/dotnet-claude-kit, which has 751 GitHub stars. The repository holds 47 skills in this directory. The repository was last updated on August 7, 2026.
Source: codewithmukesh/dotnet-claude-kit on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.