api-mirror

api-mirror is a skill for Claude Code, Codex from cyanheads/mcp-ts-core. It costs 68 tokens per session (2,654 once invoked), scanned A, a copy of api-mirror, Apache-2.0.

A local mirror for a large or slow upstream dataset, such as research papers, stored in SQLite, a small embedded database, with optional full-text search.

In plain words
What is it for?
Use it to ingest, sync, search, and query bulk datasets locally in Node or Bun applications where persistent SQLite storage is available.
Why use it?
It avoids repeatedly paging through a live API for every request and can refresh a local copy over time.

Skill for Claude CodeCodex

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

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is ./scripts/.

Good fit Use it to ingest, sync, search, and query bulk datasets locally in Node or Bun applications where persistent SQLite storage is available.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/cyanheads/mcp-ts-core
agentmods
npx agentmods add skills/cyanheads/mcp-ts-core/api-mirror

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 api-mirror

README.md
[![agentmods](https://agentmods.dev/badge/skills/cyanheads/mcp-ts-core/api-mirror/github.svg)](https://agentmods.dev/skills/cyanheads/mcp-ts-core/api-mirror)
Your own site
<a href="https://agentmods.dev/skills/cyanheads/mcp-ts-core/api-mirror"><img src="https://agentmods.dev/badge/skills/cyanheads/mcp-ts-core/api-mirror/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 api-mirror

Your own site · 80×15
<a href="https://agentmods.dev/skills/cyanheads/mcp-ts-core/api-mirror"><img src="https://agentmods.dev/badge/skills/cyanheads/mcp-ts-core/api-mirror.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 68 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,654 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 100% copy Near-identical to another mod 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.00068 $0.02654
Opus 5.5 $0.00027 $0.01062
Sonnet 5.5 $0.00014 $0.00531
Haiku 4.5 $0.00007 $0.00265

Measured 6d ago against content hash 295ccb236d75, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

api-mirror 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 6d 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.

Origin

This is a copy

100% identical to api-mirror — 0 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

framework-skills/api-mirror/SKILL.md · 140 lines

How it starts

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

Context

The MirrorService owns the source-agnostic half of a local mirror — the embedded store, the sync-state machine, the runner — so a server supplies only the two parts that are irreducibly per-source: the ingester (a sync generator) and the schema. It targets the embedded-SQLite tier (~10⁴–10⁷ rows). Node/Bun only: bun:sqlite is built-in on Bun, better-sqlite3 is an optional peer dependency on Node; the store is unavailable on Workers (no SQLite, no persistent filesystem).

Import from @cyanheads/mcp-ts-core/mirror.

The shape

import { defineMirror, sqliteMirrorStore } from '@cyanheads/mcp-ts-core/mirror';

const papers = defineMirror({
  name: 'arxiv-papers',
  store: sqliteMirrorStore({
    path: config.mirrorPath,
    table: 'papers',                                 // primary table; FTS index is `papers_fts`
    primaryKey: 'id',
    columns: { id: 'TEXT', title: 'TEXT', authors: 'TEXT', abstract: 'TEXT', updated: 'TEXT' },
    fts: ['title', 'authors', 'abstract'],          // opt-in FTS5 external-content index
    indexes: [{ columns: ['updated'] }],
  }),
  // The ingester — the one part that is always server-specific.
  async *sync({ mode, cursor, checkpoint, signal }) {
    for await (const page of harvestPages({ resumeFrom: cursor, since: checkpoint, signal })) {
      yield {
        records: page.rows,             // objects keyed by declared column
        tombstones: page.deletedIds,    // primary-key values to delete
        cursor: page.token,             // volatile resume position (see below)
        checkpoint: page.maxStamp,      // durable high-water mark (see below)
      };
    }
  },
});

await papers.runSync({ mode: 'init', signal: AbortSignal.timeout(3_600_000) }); // full; resumes on interrupt
await papers.runSync({ mode: 'refresh' });                                       // incremental
const { rows, total } = await papers.query({ match: 'transformers', limit: 10, offset: 0 });
const status = await papers.status();   // { status, ready, checkpoint, total, ... }

Read the full file on GitHub · 140 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. 6d ago Changed · +1 lines 295ccb236d75
  2. 25d ago Changed · +2 lines 9f413113d4e8
  3. 27d ago Changed · +1 lines 09bc52651965
  4. 1mo ago Changed · +1 lines 5a774600bbe3
  5. 1mo ago Changed · +2 lines c798117ba567
  6. 2mo ago First seen · 133 lines · 68 tokens per session scan A 89b98aefc722

Subscribe to this mod's changes

api-mirror is a skill published in the GitHub repository cyanheads/mcp-ts-core (153 stars, last pushed 5d ago), licensed Apache-2.0. It adds 68 tokens to every session and 2,654 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. It is 100% identical to api-mirror, differing in 0 lines, and is treated as a copy.

Related

Other skills, from other repositories

openclaw-database-toolkit

Database operations MCP server with 5 tools for D1, PostgreSQL, and MongoDB. Use when: (1) 'query my D1 database' or 'run this SQL', (2) 'insert these records' or 'add rows to table', (3) 'update records where X' or 'bulk update', (4) 'show me the table schema' or 'what columns exist', (5) 'migrate this schema' or…

yedanyagamiai-cmd/openclaw-mcp-servers · 128 tokens

ssh-manager

How to use the MCP SSH Manager core tools (sshlistservers, sshexecute, sshupload, sshdownload, sshsync) without breaking a server: server names, the remote shell, time limits and long commands, file transfer pitfalls, security modes, host keys. Use it whenever a task runs a command or moves a file on a remote machine…

bvisible/mcp-ssh-manager · 79 tokens

servicenow-cmdb

Auditing the CMDB as a data model: CI class hierarchy, raw relationships, CMDB health scorecards, data quality (duplicates, orphans, staleness, missing fields) and CSDM 5 conformance. Use when the user mentions CMDB health, CMDB audit, data quality, duplicates, orphaned or stale CIs, CI classes, relationships in…

jschuller/mcp-server-servicenow · 110 tokens

build-sql-transformation

Create or change a Snowflake or BigQuery SQL transformation in Keboola. Use when the user wants to turn a query into a saved transformation, build a new table from existing Keboola tables, or edit the SQL of an existing transformation.

keboola/mcp-server · 54 tokens

exploring-tables

Exploring any ServiceNow table: schema, field types, sample records, relationships, data patterns, a record's history (work notes, comments, field changes), and what touches a table or field (business rules, client scripts, UI policies, ACLs, script includes). Use when the user mentions tables, schemas, fields, data…

jschuller/mcp-server-servicenow · 134 tokens

explore-project-data

Explore a Keboola project's data. Use when the user asks what data they have in Keboola, which buckets or tables exist, what a table contains, or wants a read-only SQL answer from their Keboola tables.

keboola/mcp-server · 49 tokens