horse-minimal-api

horse-minimal-api is a skill for Claude Code, Codex from HashLoad/horse. It costs 26 tokens per session (607 once invoked), scanned A, original, MIT.

A guide to building small HTTP services with Horse, a Delphi web framework. It shows how to define routes, middleware, and JSON responses directly in one program file.

In plain words
What is it for?
Creating simple endpoints such as health checks, greeting routes, and JSON status responses in Delphi.
Why use it?
It reduces the setup and boilerplate needed for a focused service, mock API, or quick prototype.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Creating simple endpoints such as health checks, greeting routes, and JSON status responses in Delphi.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/hashload/horse/horse-minimal-api
About the project

Horse is a lightweight web framework for Delphi and Lazarus programs, providing tools for building HTTP servers and APIs. It is for developers who need routing, request handling, middleware, streaming, WebSockets, and related server features in those languages. Its catalogue skills support working with the framework.

HashLoad/horse · 1,385 stars · on GitHub

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 HashLoad/horse --skill horse-minimal-api
Clone the repo
git clone --depth 1 https://github.com/HashLoad/horse

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 horse-minimal-api

README.md
[![agentmods](https://agentmods.dev/badge/skills/hashload/horse/horse-minimal-api/github.svg)](https://agentmods.dev/skills/hashload/horse/horse-minimal-api)
Your own site
<a href="https://agentmods.dev/skills/hashload/horse/horse-minimal-api"><img src="https://agentmods.dev/badge/skills/hashload/horse/horse-minimal-api/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for horse-minimal-api

Your own site · 80×15
<a href="https://agentmods.dev/skills/hashload/horse/horse-minimal-api"><img src="https://agentmods.dev/badge/skills/hashload/horse/horse-minimal-api.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 26 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 607 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. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
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.00026 $0.00607
Opus 5.5 $0.00010 $0.00243
Sonnet 5.5 $0.00005 $0.00121
Haiku 4.5 $0.00003 $0.00061

Measured 3mo ago against content hash 5afe0bfad4cb, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

horse-minimal-api 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 3mo 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.

doc/skills/horse-minimal-api/SKILL.md · 76 lines

How it starts

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

Horse Minimal API

For focused microservices, mock APIs, or rapid prototyping, you can leverage Horse's lightweight routing and configuration DSL to build complete HTTP services in a single file with minimal boilerplate.


1. Single-File Bootstrap Design (Delphi)

A Minimal API structures all route registrations, basic logic, and middleware imports directly within the main .dpr bootstrap file using inline anonymous procedures:

program MinimalAPI;

{$APPTYPE CONSOLE}

uses
  System.SysUtils,
  System.JSON,
  Horse,
  Horse.Jhonson;

begin
  // 1. Fluent Middleware Configuration
  THorse.Use(Jhonson);

  // 2. Inline Route Mappings
  THorse.Get('/ping',
    procedure(Req: THorseRequest; Res: THorseResponse)
    begin
      Res.Send('pong');
    end);

  THorse.Get('/hello/:name',
    procedure(Req: THorseRequest; Res: THorseResponse)
    begin
      Res.Send('Hello, ' + Req.Params.Field('name').AsString + '!');
    end);

  // 3. Fast JSON response
  THorse.Get('/status',
    procedure(Req: THorseRequest; Res: THorseResponse)
    var
      LStatus: TJSONObject;
    begin
      LStatus := TJSONObject.Create(TJSONPair.Create('status', 'online'));
      Res.Send(LStatus); // Johnson takes ownership
    end);

  // 4. Port Listening
  THorse.Listen(9000);
end.

2. Best Practices for Minimal APIs

Although Minimal APIs promote rapid development, follow these principles to avoid "spaghetti code":

  1. Extract Complex Handlers: If a route handler exceeds 25 lines of code or requires database calls, do not write it inline. Extract it to a local unit procedure.
  2. Use Radix Router: Opt-in to THorse.UseRadixRouter; to ensure maximum matching speed if your API contains path parameters.
  3. Keep it Focused: A Minimal API should serve a single responsibility (Microservice). If you need to manage multiple domains (e.g. Users, Products, Invoices) in the same project, migrate to modular controllers.

3. When to Transition to MVC Architecture

Transition from a Minimal API to a structured MVC/Modular architecture when:

Read the full file on GitHub · 76 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. 3mo ago First seen · 76 lines · 26 tokens per session scan A 5afe0bfad4cb

Subscribe to this mod's changes

horse-minimal-api is a skill published in the GitHub repository HashLoad/horse (1,385 stars, last pushed 20d ago), licensed MIT. It adds 26 tokens to every session and 607 once invoked, about $0.0001 per session on Opus 5.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

horse-minimal-api compared with skills from other repositories

horse-minimal-api next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
horse-minimal-apiHashLoad/horseSkill1.4k20d agoMITA26Claude Code, Codex
api-design-patternsaAAaqwq/AGI-Super-TeamSkill1214d agoMITA29Claude Code
api-design-patternsbobmatnyc/claude-mpmSkill1603mo agononeA29Claude Code
api-design-patternsbobmatnyc/claude-mpm-skillsSkill794mo agoMITA29Claude Code
fastapifastapi/fastapiSkill105k6d agoMITA57Claude Code, Codex
api-integration-architectsickn33/agentic-awesome-skillsSkill51kyesterdayMITA33Claude Code
dmrwemake-services/django-modern-restSkill1.6ktodayMITA80Claude Code, Codex