extension-authoring

extension-authoring is a skill for Claude Code, Codex from HaseebKhalid1507/SynapsCLI. It costs 34 tokens per session (1,609 once invoked), scanned A, original, Apache-2.0.

A step-by-step guide for building a SynapsCLI extension, a separate program that communicates with the SynapsCLI command-line tool.

In plain words
What is it for?
It helps create extensions with tools that the model can call and hooks that react to events such as a tool call.
Why use it?
It explains the required manifest, communication format, permissions, installation, and testing so an extension can be connected correctly.

Skill for Claude CodeCodex

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

Good fit It helps create extensions with tools that the model can call and hooks that react to events such as a tool call.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/haseebkhalid1507/synapscli/extension-authoring
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 HaseebKhalid1507/SynapsCLI --skill extension-authoring
Clone the repo
git clone --depth 1 https://github.com/HaseebKhalid1507/SynapsCLI

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 extension-authoring

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

Your own site · 80×15
<a href="https://agentmods.dev/skills/haseebkhalid1507/synapscli/extension-authoring"><img src="https://agentmods.dev/badge/skills/haseebkhalid1507/synapscli/extension-authoring.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 34 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,609 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 1 finding, up to medium

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • medium Rogue Agent · line 30
    Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.
    Fix: Remove any persistence mechanisms (cron jobs, startup scripts, state files). Skills should not maintain state across sessions without explicit user consent.
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.00034 $0.01609
Opus 5.5 $0.00014 $0.00644
Sonnet 5.5 $0.00007 $0.00322
Haiku 4.5 $0.00003 $0.00161

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

Security

Grade A, and why

extension-authoring scanned grade A with 1 finding 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 1mo 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.

Runs shell commandslowCapability

Expected in a hook, worth knowing in a rule or an instructions file.

proc = subprocess.Popen(["python3", "main.py"],
.synaps-cli/skills/extension-authoring/SKILL.md · 240 lines

How it starts

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

Build a SynapsCLI Extension

Source of truth: {baseDir}/../../../docs/extensions/tutorial.md Read that file for the complete worked example. This skill is a structured summary + checklist you can keep in context while authoring.


What you are building

A separate process SynapsCLI spawns and talks to over stdin/stdout using JSON-RPC 2.0 with Content-Length framing. The runtime calls methods on you; you only respond. Any language works — Python 3 (no deps) is the tutorial language.

Two capabilities:

  • Tool — callable by the model (tools.register permission required).
  • Hook — reacts to lifecycle events, optionally blocks/modifies them (hook.* permission required per hook type).

Step 1 — Manifest (plugin.json)

Create .synaps-plugin/plugin.json in your extension root:

{
  "name": "hello-ext",
  "version": "0.1.0",
  "description": "Hello-world extension",
  "extension": {
    "entry_point": "python3 main.py",
    "extension_protocol_version": 1,
    "permissions": [
      "tools.register",
      "hooks.before_tool_call"
    ]
  }
}

Key fields:

  • entry_point — shell command to start your process (resolved from plugin root).
  • extension_protocol_version — must be 1.
  • permissions — declare every capability you use; undeclared calls are rejected.

Step 2 — Framing helpers

Every message is a Content-Length: N\r\n\r\n header followed by N bytes of JSON. Write helpers once:

import sys, json

def send(obj):
    body = json.dumps(obj).encode()
    sys.stdout.buffer.write(b"Content-Length: " + str(len(body)).encode() + b"\r\n\r\n" + body)
    sys.stdout.buffer.flush()

def recv():
    header = b""
    while not header.endswith(b"\r\n\r\n"):
        header += sys.stdin.buffer.read(1)
    n = int(header.split(b"Content-Length:")[1].strip().split()[0])
    return json.loads(sys.stdin.buffer.read(n))

Step 3 — Handshake (initialize)

The runtime sends initialize first. You must respond with your capabilities:

Read the full file on GitHub · 240 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. 1mo ago First seen · 240 lines · 34 tokens per session scan A 61f39a30e4ed

Subscribe to this mod's changes

extension-authoring is a skill published in the GitHub repository HaseebKhalid1507/SynapsCLI (51 stars, last pushed today), licensed Apache-2.0. It adds 34 tokens to every session and 1,609 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 1 finding (runs shell commands). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.