I have recently started using Claude Code to handle parts of my day-to-day .NET development — generating boilerplate, reviewing pull requests, and creating task-specific "subagents" for repetitive work like code review or test generation.
So far I've experimented with:
The built-in
/agentscommand to spin up specialized subagentsManually writing agent config files for more control over behavior
Letting it auto-delegate parts of a refactor to the right subagent
I'm curious how other .NET developers are actually using AI coding agents (Claude Code, GitHub Copilot, or similar) in real projects, not just demos.
Have you set up custom agents for specific .NET tasks — EF Core migrations, unit test generation, code review, etc.?
Do you prefer one general-purpose agent, or several narrow, specialized ones?
Do you let an agent make direct code changes in a larger codebase, or do you keep it strictly to suggestions you review first?
Would love to hear what's genuinely working for people day-to-day.


Peter Mamr4 reputationPosted Nov 1, 2026, 1:57 AM EDT
Mostly for one thing: getting a change all the way to a checked result on the machine where the project actually lives, not in a sandbox.
My setup is a bit unusual: the agent doesn't run on the dev box. The box runs a small MCP agent, and whatever AI I'm talking to (Claude, ChatGPT, Codex — I switch) runs commands, edits files and uses git there. That's also why I can do it from my phone: the chat is on the phone, the build is on the PC. I built that tool (Local Commander), so take this as a builder's bias.
What it changed in how I work with agents:
I stopped trusting "done". I ask for the diff, the command it ran and the output. One deployment of mine finished fine while the chat said "cancelled" — the deploy had restarted the very component that carried the connection. Since then: check the result first, then decide whether to retry.
Direct edits: yes, but in a bounded folder with a test or a check it has to pass. Big codebase → small task, clear acceptance.
One general agent vs several specialists: I haven't measured a difference, and I'd distrust anyone who claims one without numbers. The bounded task matters more than the number of agents.
dhana ganiRank #1,083 · 1.8K reputationPosted Oct 26, 2026, 1:49 AM EDT
Hi,
For .NET development, AI coding agents like Claude Code can be useful when their tasks are clearly defined and their output is verified.
1. Where AI Agents Can Help
Unit and integration tests: Ask the agent to generate tests for an existing service. Providing a sample test file helps it follow your project's mocking and assertion conventions.
Boilerplate code: Agents can help generate repetitive MediatR handlers, DTOs, and FluentValidation rules.
EF Core migrations: Agents can help create migrations, but review the generated migration and SQL script before applying database changes. Never run database updates blindly.
2. One Agent or Multiple Agents?
For many projects, starting with one agent and a
CLAUDE.mdfile is a practical approach. Document your build and test commands, architectural rules, coding conventions, and testing framework. Add specialized agents only when there is a clear benefit.3. Direct Edits or Suggestions?
Allowing an agent to edit code on a dedicated branch can speed up development. Before accepting its changes:
Run
dotnet build.Run
dotnet formatand the relevant tests.Review the
git diffbefore creating a pull request.Check security, performance, dependency injection lifetimes, and database queries.
Passing the build does not automatically mean the code is safe or production-ready. Human review remains important.
One question for other .NET developers: How do you validate AI-generated code in your projects? Do you rely on static analysis tools in your CI/CD pipeline, AI-based code review, or both?