entity-generator

A code generator for creating a C# class that represents a MikroTik router object or configuration path in the tik4net library. The generated class includes field types, access rules, documentation, and the methods needed to use it.

In plain words
What is it for?
Use it when adding support for a MikroTik API path, such as DHCP-server leases, to tik4net, especially when you need a finished entity class rather than a rough draft.
Why use it?
It removes the repetitive work of turning MikroTik’s router data and documentation into correctly structured library code. It also helps distinguish fields that can be changed from those that can only be read.

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/danikf/tik4net/entity-generator
Any agent
npx skills add danikf/tik4net --skill entity-generator
Clone the repo
git clone --depth 1 https://github.com/danikf/tik4net

Made for: Claude Code, Codex.

Per session 144 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 7,285 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.00144 $0.07285
Opus 5 $0.00072 $0.03642
Sonnet 5 $0.00029 $0.01457
Haiku 4.5 $0.00014 $0.00728

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

Security

Grade A, and why

entity-generator 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 3d 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/entity-generator/SKILL.md · 450 lines

How it starts

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

tik4net entity code generator

Goal: produce a finished, idiomatic entity class under tik4net.objects/ for a given MikroTik API path (e.g. /ip/dhcp-server/lease). This replaces the two legacy WinForms helpers — you do the same work they did, but with better sources (live router via MCP and the wiki) and you finish the code (the old tools always produced a draft that a human had to clean up).

The division of labour those tools established still holds: the router is the source of truth for what fields exist and their live values; the documentation is the source of truth for types, defaults, the read-only split and descriptions. Use both and reconcile.

The tools themselves are gone (deleted in 4.0, after this skill replaced them). Everything they knew that is still worth knowing is in this file; if you need to see how they did something, git log them under Tools/tik4net.entitygenerator/ and Tools/tik4net.entityWikiImporter/.

When to use / inputs

Trigger when the user names a MikroTik path or menu and wants a tik4net entity for it. The only required input is the API path (/ip/.../...). If the user gives a WinBox menu name instead, translate it to the API path first (lowercase, slash-separated).

Step 1 — Namespace and class name (convention)

From High-level-API-custom-entities wiki page. Class name = last two parts of the API path, camelized:

/ip/firewall/filter   → namespace tik4net.Objects.Ip.Firewall   class FirewallFilter
/interface/vlan       → namespace tik4net.Objects.Interface      class InterfaceVlan
/ip/dns               → namespace tik4net.Objects.Ip             class IpDns
  • Sub-namespace when the sub-path will hold more than one class: /ip/dnsIp.IpDns, /ip/dns/cacheIp.Dns.DnsCache.
  • Three-part names when a hypothetical sub-namespace would hold only one class: /ip/hotspot/userIp.Hotspot.HotspotUser, /ip/hotspot/user/profileIp.Hotspot.HotspotUserProfile.
  • Property names: MikroTik field → PascalCase (add-mac-cookieAddMacCookie). Camelization drops - and . and title-cases (see GeneratorHelper.Camelize).
  • Enum member names: MikroTik value → PascalCase (reply-onlyReplyOnly), value carried by [TikEnum("reply-only")].

Read the full file on GitHub · 450 lines

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. 3d ago First seen · 450 lines · 144 tokens per session scan A ec87a2a33d1d

Subscribe to this mod's changes

entity-generator is a skill published in the GitHub repository danikf/tik4net (197 stars, last pushed 3d ago), licensed Apache-2.0. It adds 144 tokens to every session and 7,285 once invoked, about $0.0007 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.

Related

Other skills, from other repositories

dpg-migration

Migration logic for Azure SDK for .NET data-plane libraries migrating from AutoRest/Swagger to TypeSpec-based generation. Uses MCP tools from the generator-agent server for automated deterministic fixes.

Azure/azure-sdk-for-net · 41 tokens

csharp-azure-spector-coverage-gaps

Discovers and implements gaps in Spector test coverage for the Azure C# HTTP client emitter. Use when asked to find missing Spector scenarios, add Spector test coverage, or implement a specific Spector spec for the Azure C# emitter. Can also compare coverage between the Azure dashboard and the Standard (TypeSpec core)…

Azure/azure-sdk-for-net · 78 tokens

mgmt-review-comment-resolution

Resolve review comments on Azure management-plane .NET SDK PRs. Handles renaming types/properties, changing property types, and other API surface adjustments by updating TypeSpec client.tsp and regenerating.

Azure/azure-sdk-for-net · 46 tokens

mpg-migration

Handles Azure SDK for .NET management-plane migrations from AutoRest/Swagger to TypeSpec; use for MPG, mgmt migration, or Azure.ResourceManager. migration requests.

Azure/azure-sdk-for-net · 39 tokens

generate-code-cs

Generate the code from typespec for C#. Parameter: C# SDK repository root location .

Azure/azure-sdk-for-net · 26 tokens

bump-mgmt-base-version

Bump the http-client-csharp base dependency version in http-client-csharp-mgmt. Updates emitter (npm) and generator (NuGet) references, rebuilds, and regenerates test projects.

Azure/azure-sdk-for-net · 47 tokens