new-entity

new-entity is a skill for Claude Code, Codex from fpindej/netrock. It costs 10 tokens per session (516 once invoked), scanned A, original, MIT.

A code-generation helper for adding a backend entity to a .NET application that uses Entity Framework Core, a tool for mapping code objects to database tables. It creates the entity, database mapping, errors, and migration from the surrounding code.

In plain words
What is it for?
Use it when adding a new backend entity, its properties or enums, EF Core database configuration, error messages, and a database migration.
Why use it?
It removes the repetitive work of wiring a new data object into both the application and database while following the project's conventions. It asks questions only when the entity's purpose or key properties are unclear.

Skill for Claude CodeCodex

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.

agentmods
npx agentmods add skills/fpindej/netrock/new-entity
Any agent
npx skills add fpindej/netrock --skill new-entity
Clone the repo
git clone --depth 1 https://github.com/fpindej/netrock

Made for: Claude Code, Codex.

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 new-entity

README.md
[![agentmods](https://agentmods.dev/badge/skills/fpindej/netrock/new-entity.svg)](https://agentmods.dev/skills/fpindej/netrock/new-entity)
Your own site
<a href="https://agentmods.dev/skills/fpindej/netrock/new-entity"><img src="https://agentmods.dev/badge/skills/fpindej/netrock/new-entity.svg" alt="Measured on agentmods" height="20"></a>
Per session 10 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 516 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00010 $0.00516
Opus 5 $0.00005 $0.00258
Sonnet 5 $0.00002 $0.00103
Haiku 4.5 $0.00001 $0.00052

Measured 4d ago against content hash 2b4a876ce1a4, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

new-entity 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 4d 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.

.claude/skills/new-entity/SKILL.md · 53 lines

How it starts

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

Creates a new backend entity with EF Core configuration and migration.

Infers entity name, properties, feature name, and enum values from context. Asks only if the entity's purpose or key properties are genuinely ambiguous.

Templates

Use these as starting points - fill in the specifics from context:

Conventions

  • Boolean properties: Use Is* prefix in C# (e.g. IsUsed, IsInvalidated) per .NET convention, but map to prefix-free DB column names via HasColumnName (e.g. Used, Invalidated) to keep the schema clean.

Steps

Domain:

  1. Create src/backend/MyProject.Domain/Entities/{Entity}.cs:
    • Extend BaseEntity, private setters, protected parameterless ctor, public ctor with Id = Guid.NewGuid()
  2. If enums: create alongside entity with explicit integer values
  3. Add Error entries (snake_case code + message) to src/backend/MyProject.Shared/ErrorMessages.cs

Infrastructure:

  1. Create EF config Infrastructure/Features/{Feature}/Configurations/{Entity}Configuration.cs:
    • Extend BaseEntityConfiguration<T>, mark internal, .HasComment() on enum columns
    • For boolean properties: map with .HasColumnName("PrefixFree") to keep DB schema clean
  2. Add DbSet<{Entity}> to Infrastructure/Persistence/MyProjectDbContext.cs
  3. Run migration:
    dotnet ef migrations add Add{Entity} \
      --project src/backend/MyProject.Infrastructure \
      --startup-project src/backend/MyProject.WebApi \
      --output-dir Persistence/Migrations
    

Dockerfile:

  1. If a new project was added that WebApi references, add its .csproj COPY line to the Dockerfile restore layer - otherwise dotnet restore fails in Docker builds.

Verify and commit:

  1. dotnet build src/backend/MyProject.slnx - fix errors, loop until green
  2. Commit: feat({feature}): add {Entity} entity and EF configuration

This skill stops at Infrastructure. Use /new-endpoint to add service, controller, and API surface.

Read the full file on GitHub · 53 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. 4d ago First seen · 53 lines · 10 tokens per session scan A 2b4a876ce1a4

Subscribe to this mod's changes

new-entity is a skill published in the GitHub repository fpindej/netrock (231 stars, last pushed 5d ago), licensed MIT. It adds 10 tokens to every session and 516 once invoked, about $0.0001 per session on Opus 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.