atproto-lexicon

atproto-lexicon is a skill for Claude Code from ngerakines/atproto-skills. It costs 720 tokens per session (3,527 once invoked), scanned A, original, MIT.

A set of rules for defining AT Protocol data records and remote methods in JSON, with guides for Rust, TypeScript, and Go.

In plain words
What is it for?
Use it to write or check lexicon documents, record types, XRPC methods, identifiers, references, and related AT Protocol rules.
Why use it?
It helps clients and servers agree on the same data shapes and method names, reducing invalid records and mismatched requests.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the atproto-skills plugin — 7 skills shipped together

Good fit Use it to write or check lexicon documents, record types, XRPC methods, identifiers, references, and related AT Protocol rules.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/ngerakines/atproto-skills/atproto-lexicon
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 ngerakines/atproto-skills --skill atproto-lexicon
Clone the repo
git clone --depth 1 https://github.com/ngerakines/atproto-skills

Made for: Claude Code.

Or install atproto-skills, the plugin that ships this one along with the rest of its 7 skills.

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 atproto-lexicon

README.md
[![agentmods](https://agentmods.dev/badge/skills/ngerakines/atproto-skills/atproto-lexicon/github.svg)](https://agentmods.dev/skills/ngerakines/atproto-skills/atproto-lexicon)
Your own site
<a href="https://agentmods.dev/skills/ngerakines/atproto-skills/atproto-lexicon"><img src="https://agentmods.dev/badge/skills/ngerakines/atproto-skills/atproto-lexicon/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 atproto-lexicon

Your own site · 80×15
<a href="https://agentmods.dev/skills/ngerakines/atproto-skills/atproto-lexicon"><img src="https://agentmods.dev/badge/skills/ngerakines/atproto-skills/atproto-lexicon.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 720 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,527 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.00720 $0.03527
Opus 5 $0.00360 $0.01764
Sonnet 5 $0.00144 $0.00705
Haiku 4.5 $0.00072 $0.00353

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

Security

Grade A, and why

atproto-lexicon 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 12d 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.

skills/atproto-lexicon/SKILL.md · 144 lines

How it starts

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

AT Protocol Lexicon + XRPC + Records

An AT Protocol lexicon is a JSON document that declares the shape of one record type or one XRPC method. Every record's $type, every XRPC path, and every ref between them ties back to an NSID. The lexicon is the protocol's type system; validation against it is the contract between clients, servers, and the repository layer.

This skill routes to per-language guides for Rust, TypeScript, and Go, sitting on top of a language-neutral spec in shared/.

Defaults

  • Lexicon doc{lexicon: 1, id: <nsid>, revision?, defs: {...}}. Primary types (record, query, procedure, subscription) live under main. Secondary types can use any name.
  • NSID — reversed-DNS authority + name segment. ASCII only, 317 bytes max, name segment allows no hyphens. See shared/nsid.md.
  • $type — required on every record. Bare NSID implies #main. Used for union dispatch. Missing $type = invalid record.
  • AT-URIs in records — DIDs strongly preferred over handles for the authority. Query strings forbidden. See shared/at-uri.md.
  • strongRef{uri, cid} where cid is a plain string, not a cid-link. Common bug source.
  • Blob refs (modern){$type:"blob", ref:{$link:<cid>}, mimeType, size}. Legacy {cid, mimeType} only accepted with an opt-in lenient flag.
  • XRPC wire/xrpc/<nsid> path. GET for queries, POST for procedures, WebSocket for subscriptions. Errors as {error, message}. Subscription frames are two concatenated DAG-CBOR objects per WS binary message.
  • Validation — strict by default on write, lenient on read. ALLOW_LEGACY_BLOB and ALLOW_LENIENT_DATETIME are the typical lenient opt-ins.

Full normative rules: shared/lexicon-spec.md, shared/nsid.md, shared/at-uri.md, shared/record-model.md, shared/xrpc-wire.md, shared/backward-compat.md. Fixtures: shared/test-vectors.md. Cross-language differences: shared/divergence-matrix.md.

Language detection

Before generating or reviewing any lexicon / XRPC / record code, determine the target language from project files or the file being edited:

Read the full file on GitHub · 144 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. 12d ago First seen · 144 lines · 720 tokens per session scan A f5f5ba4e7b81

Subscribe to this mod's changes

atproto-lexicon is a skill published in the GitHub repository ngerakines/atproto-skills (50 stars, last pushed 4mo ago), licensed MIT. It adds 720 tokens to every session and 3,527 once invoked, about $0.0036 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

afrexai-api-architect

Design, build, test, document, and secure production-grade APIs. Covers the full lifecycle from schema design through deployment, monitoring, and versioning. Use when designing new APIs, reviewing existing ones, generating OpenAPI specs, building test suites, or debugging production issues.

LeoYeAI/openclaw-master-skills · 61 tokens

litellm

Operate, configure, secure, and troubleshoot the LiteLLM AI gateway (proxy) and Python SDK: run the proxy (litellm --config), route to 100+ providers through one OpenAI-compatible API, configure model lists and routing/reliability, virtual keys, teams, budgets, rate limits, caching, guardrails, observability, and…

magnus919/agent-skills · 173 tokens

email

Send and diagnose transactional email through Twilio SendGrid from a terminal or agent: send messages, check deliverability (bounces and spam reports), and verify Signed Event Webhook signatures (ECDSA P-256) — with a bundled email-cli script that is read-only by default and gates every send behind a --dry-run/--yes…

magnus919/agent-skills · 135 tokens

supabase

Use this skill when developing applications with Supabase, running the Supabase CLI, designing migrations and RLS policies, testing database behavior, generating client types, deploying the official self-hosted Docker stack, or administering its Postgres, Auth, Storage, Realtime, Functions, API gateway, backups…

magnus919/agent-skills · 94 tokens

vercel-eve

Build, develop, deploy, self-host, secure, and troubleshoot durable backend AI agents with Vercel Eve. Use when creating an Eve agent, adding tools, skills, subagents, channels, schedules, sandboxing, durable sessions, observability, or deploying Eve on Vercel or a Node host. Do not use for the separate Vercel AI SDK…

magnus919/agent-skills · 99 tokens

agentmail

API-first email platform designed for AI agents. Create and manage dedicated email inboxes, send and receive emails programmatically, and handle email-based workflows with webhooks and real-time events. Use when you need to set up agent email identity, send emails from agents, handle incoming email workflows, or…

LeoYeAI/openclaw-master-skills · 73 tokens