APIShed

A modular HTTP API server. Each module owns its own versioned route prefix.

The math LLMs get wrong — as a deterministic API and MCP server.

Checksums, date arithmetic, exact character counts, token counts — a language model guesses at these instead of computing them. apished runs the actual algorithm and gives you a real answer, over plain HTTP or as MCP tools an agent can call directly. That also makes it useful on edge devices and IoT boards: an agent running somewhere it can't spin up a Python interpreter or install a package still gets exact computation, one HTTP call away.

88% → 16%

GPT-4's accuracy on timezone questions vs. date-difference questions, on the "Test of Time" benchmark.

Date math, done right — /v1/datemath

"2 r's"

The canonical LLM answer to "how many r's in strawberry" — tokenization groups letters into tokens, so the model never actually counts.

Character counts you can trust — /v1/text

Plausible, wrong

Ask an LLM for a SHA-256 hash and it will confidently invent a real-looking hex string instead of computing one.

Real checksums, not guesses — /v1/hash

Rules

MCP

POST/mcp

Every module below, exposed as 52 MCP tools over Streamable HTTP for MCP clients like Claude Desktop, Claude Code, Cursor, and ChatGPT — same logic as the REST endpoints, no duplication. See /mcp-setup for the full tool list and client-by-client setup instructions.

Modules

Every module's routes, grouped below. For the full interactive reference — request/response schemas, try-it-out — see /docs (openapi.json).

checksum README →

Validates Luhn, ISBN, EAN/UPC, IBAN, EU VAT, and SWIFT/BIC checksums and formats.

POST/luhn — POST/isbn — POST/ean — POST/iban — POST/vateu — POST/swiftbic —
color README →

Converts hex/RGB/HSL/HSV colors and computes WCAG 2.1 contrast ratio.

POST/convert — POST/contrast —

Parses, validates, and converts CSV to/from JSON — no type guessing.

POST/parse — POST/validate — POST/stats — POST/to_json — POST/from_json —
datemath README →

Calendar date arithmetic — differences, business days, age, day-of-week, add/subtract.

POST/diff — POST/businessdays — POST/leapyear — POST/age — POST/dayofweek — POST/add —
datetime README →

Returns the actual current date/time in a given format and IANA timezone.

GET/now —
encode README →

Encodes/decodes text as ROT13, base64, base64url, base32, hex, uuencode, URL, or HTML entities.

POST/encode — POST/decode —
hash README →

Computes MD5/SHA1/SHA256/SHA512/CRC32 digests and HMAC, with optional base64/hex input.

POST/digest — POST/hmac —
idvalidate README →

Validates Polish PESEL, NIP, and REGON checksums — PESEL also decodes birth date and sex.

POST/pesel — POST/nip — POST/regon —
network README →

IPv4/IPv6 CIDR info, containment, and overlap checks.

POST/cidr/info — POST/cidr/contains — POST/cidr/overlaps —
pipe README →

Chains other operations together in one request, in-process, so an agent skips a round-trip per step.

POST/run —
random README →

Generates cryptographically random integers in a range, using crypto/rand.

POST/int —
regex README →

Regex extract, replace, and split, on Go's RE2-based (backtracking-safe) engine.

POST/extract — POST/replace — POST/split —
rpncalc README →

Evaluates Reverse Polish Notation expressions — arithmetic, trig, logs, bitwise ops, and constants.

POST/rpn —
text README →

Character/word counting, reversal, palindrome checks, indexing, and sorting — Unicode-safe.

POST/count — POST/wordcount — POST/reverse — POST/palindrome — POST/charat — POST/sort — POST/stats —
tokens README →

Counts tokens under OpenAI-compatible (tiktoken) encodings, by model or encoding name.

POST/count —
units README →

Converts data size (SI/IEC) and temperature, as exact decimal strings.

POST/convert/datasize — POST/convert/temperature —
uuid README →

Validates, parses, and generates UUIDs.

POST/validate — POST/generate —
validate README →

Regex matching, email/URL format checks, and JSON Schema validation.

POST/regex — POST/email — POST/url — POST/jsonschema —