add-email-template

add-email-template is a skill for Claude Code from fpindej/netrock. It costs 10 tokens per session (610 once invoked), scanned A, original, MIT.

A recipe for adding transactional email templates, such as order confirmations, with HTML, plain text, and subject-line files. It uses Fluid, a template language that fills placeholders such as an order number with application data.

In plain words
What is it for?
Use it when adding a new automated email template and connecting its application values to the message body, subject, and optional plain-text version.
Why use it?
It gives the email system the data model and file structure needed to render consistent messages. This avoids putting email content directly into application code.

Skill for Claude Code

Written for Claude Code: user-invocable in frontmatter.

Good fit Use it when adding a new automated email template and connecting its…

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/fpindej/netrock/add-email-template
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.

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

Made for: Claude Code.

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 add-email-template

README.md
[![agentmods](https://agentmods.dev/badge/skills/fpindej/netrock/add-email-template.svg)](https://agentmods.dev/skills/fpindej/netrock/add-email-template)
Your own site
<a href="https://agentmods.dev/skills/fpindej/netrock/add-email-template"><img src="https://agentmods.dev/badge/skills/fpindej/netrock/add-email-template.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 610 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00010 $0.00610
Opus 5 $0.00005 $0.00305
Sonnet 5 $0.00002 $0.00122
Haiku 4.5 $0.00001 $0.00061

Measured 7d ago against content hash 3b973d765962, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

add-email-template 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 7d 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/add-email-template/SKILL.md · 61 lines

How it starts

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

Adds a transactional email template using Fluid (Liquid).

Each email has a 3-file pattern plus a model record.

Steps

1. Create the model record in src/backend/MyProject.Application/Features/Email/Models/EmailTemplateModels.cs:

/// <summary>
/// Model for the order-confirmation template. Exposed as <c>order_number</c> and <c>total</c> in Liquid.
/// </summary>
public record OrderConfirmationModel(string OrderNumber, string Total);

Properties auto-map to snake_case Liquid variables (OrderNumber -> order_number).

2. Create 3 template files in src/backend/MyProject.Infrastructure/Features/Email/Templates/:

  • order-confirmation.liquid - HTML body fragment (injected into _base.liquid via {{ body | raw }}):
    <h2 style="margin: 0 0 20px 0; font-size: 22px; font-weight: 700; color: #333333;">Order Confirmed</h2>
    <p style="margin: 0 0 16px 0;">Your order <strong>{{ order_number }}</strong> totaling {{ total }} has been confirmed.</p>
    
  • order-confirmation.subject.liquid - Subject line (plain text, no HTML)
  • order-confirmation.text.liquid - Plain text body (optional but recommended)

All marked as EmbeddedResource (verify .csproj has <EmbeddedResource Include="Features\Email\Templates\*.liquid" />).

3. Register the model type in FluidEmailTemplateRenderer.CreateOptions():

options.MemberAccessStrategy.Register<OrderConfirmationModel>();

4. Use in a service:

await templatedEmailSender.SendSafeAsync("order-confirmation",
    new OrderConfirmationModel(order.Number, order.FormattedTotal),
    customer.Email, cancellationToken);

5. Add tests in FluidEmailTemplateRendererTests.cs - test subject rendering, HTML variable injection, and plain text variant.

6. Verify: dotnet test src/backend/MyProject.slnx -c Release

Conventions

  • Template names: kebab-case (order-confirmation, not orderConfirmation)
  • HTML templates: inline styles (email clients ignore <style> blocks in fragments)
  • _base.liquid provides the wrapper (header with {{ app_name }}, card, footer) - fragments provide inner content only
  • HTML body: HtmlEncoder.Default (XSS-safe). Subject/plain text: unencoded
  • Subject: static text or config-sourced variables only - never raw user input
  • {{ app_name }} is automatically available from EmailOptions.FromName

Read the full file on GitHub · 61 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. 7d ago First seen · 61 lines · 10 tokens per session scan A 3b973d765962

Subscribe to this mod's changes

add-email-template is a skill published in the GitHub repository fpindej/netrock (231 stars, last pushed 6d ago), licensed MIT. It adds 10 tokens to every session and 610 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.