$npx -y skills add superdesigndev/tools-registry --skill interfacesrc/treg/web/skill.md is the product skill that ships to consumers — the agent's whole interface to the registry (distinct from .claude/skills/tools-registry-context/, which maintains *these* design docs). Its frontmatter name: tools-registry + description make it loa
| 1 | # The `tools-registry` skill |
| 2 | |
| 3 | `src/treg/web/skill.md` is the **product** skill that ships to consumers — the agent's whole interface to the |
| 4 | registry (distinct from `.claude/skills/tools-registry-context/`, which maintains *these* design docs). |
| 5 | Its frontmatter `name: tools-registry` + `description` make it loadable by a coding agent. |
| 6 | |
| 7 | One skill, three personas: |
| 8 | - **consumer** — discover + call tools with no credentials locally. Teaches the agent-native |
| 9 | **URL-passthrough** first: take the real upstream URL and prefix it with `{BASE}/call/` |
| 10 | + the `X-Treg-Token` header; `treg call <tool> <path>` is the CLI shorthand. |
| 11 | - **creator** — turn a local skill into a shared tool: `treg secret add`, `treg tool add` (single-key or |
| 12 | `--bind` multi-credential), the `treg skill scaffold → push` bundle flow, and `treg oauth connect` for |
| 13 | browser-consent tokens. Documents the two OAuth modes (auto-refresh vs manual) and the four auth shapes. |
| 14 | - **admin** — inventory + monitor: `treg tool/secret/skill ls`, `treg calls`, and `treg health [--run]` |
| 15 | (with the per-tool `health_check` probe). |
| 16 | |
| 17 | **Distribution:** the file is `{BASE}`-templated and served at **`GET /skill.md`** (`skill_md` in |
| 18 | `api.py`, via `_serve_md`), and `install.sh` best-effort drops it into |
| 19 | `~/.claude/skills/tools-registry/SKILL.md` right after installing the CLI — so `curl {BASE}/install.sh | sh` |
| 20 | gives a machine both the `treg` command AND the skill that teaches an agent to use it. It restates the |
| 21 | invariants (secrets are write-only, use-without-hold, the proxy relays the upstream's truth) and links |
| 22 | `{BASE}/llms.txt` + `{BASE}/tutorial`. It mirrors the surfaces in [api.md](api.md) + [cli.md](cli.md); |
| 23 | keep the three in sync when the API/CLI change. |