wiki-discovery-api

A web API for adding pages to a wiki memory service. A web API lets programs communicate with a service using network requests.

In plain words
What is it for?
Use it to retrieve templates, check proposed pages, and publish or submit Markdown pages as drafts through authenticated requests.
Why use it?
It lets automated tools submit knowledge without manual file editing, while the novelty check helps avoid duplicate pages.

Skill for Claude CodeCodex

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.

agentmods
npx agentmods add skills/rossoctl/examples/wiki-discovery-api
Any agent
npx skills add rossoctl/examples --skill wiki-discovery-api
Clone the repo
git clone --depth 1 https://github.com/rossoctl/examples

Made for: Claude Code, Codex.

Per session 0 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 923 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. Scan, not verified.
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 $0.00000 $0.00923
Opus 5 $0.00000 $0.00462
Sonnet 5 $0.00000 $0.00185
Haiku 4.5 $0.00000 $0.00092

Measured 2d ago against content hash a900022ced47, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

wiki-discovery-api 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 2d 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.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

curl -s http://localhost:8321/templates
mcp/wiki_memory_tool/skills/wiki-discovery-api/SKILL.md · 107 lines

How it starts

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

kwiki Discovery Agent (REST API)

Write new knowledge to the wiki memory service via REST API after checking novelty.

Prerequisites

The wiki service must be running on http://localhost:8321.

Authentication

Option A: GitHub OAuth Token

Authorization: Bearer <wiki-jwt-token>

Option B: SPIFFE Headers (agent-to-agent)

X-Spiffe-Id: spiffe://rossoctl.example.com/ns/topic-{topic_id}/sa/discovery-agent

Procedure

1. Get a Template (optional)

curl -s http://localhost:8321/templates
curl -s http://localhost:8321/templates/paper-summary

2. Check Novelty First

curl -s -X POST http://localhost:8321/topics/{topic_id}/check-novelty \
  -H "X-Spiffe-Id: spiffe://rossoctl.example.com/ns/topic-{topic_id}/sa/discovery-agent" \
  -H "Content-Type: application/json" \
  -d '{"title": "Page Title", "abstract": "Brief summary"}'

If "novel": false, do NOT write.

3. Write the Page

curl -s -X POST http://localhost:8321/topics/{topic_id}/pages/{path} \
  -H "X-Spiffe-Id: spiffe://rossoctl.example.com/ns/topic-{topic_id}/sa/discovery-agent" \
  -H "Content-Type: application/json" \
  -d '{"content": "---\ntags: [paper]\n---\n# Title\n\nContent...", "message": "commit message"}'

Response includes suggested_links to related pages.

4. Write as Draft

curl -s -X POST "http://localhost:8321/topics/{topic_id}/pages/{path}?draft=true" \
  -H "X-Spiffe-Id: spiffe://rossoctl.example.com/ns/topic-{topic_id}/sa/discovery-agent" \
  -H "Content-Type: application/json" \
  -d '{"content": "# Draft\n\nPending review..."}'

5. Approve/Reject Drafts (admin)

# List drafts
curl -s http://localhost:8321/topics/{topic_id}/drafts \
  -H "Authorization: Bearer <admin-jwt>"

# Approve
curl -s -X POST http://localhost:8321/topics/{topic_id}/drafts/{path}/approve \
  -H "Authorization: Bearer <admin-jwt>"

# Reject
curl -s -X POST http://localhost:8321/topics/{topic_id}/drafts/{path}/reject \
  -H "Authorization: Bearer <admin-jwt>" \
  -H "Content-Type: application/json" \
  -d '{"reason": "needs more references"}'

Read the full file on GitHub · 107 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. 2d ago First seen · 107 lines · 0 tokens per session scan A a900022ced47

Subscribe to this mod's changes

wiki-discovery-api is a skill published in the GitHub repository rossoctl/examples (11 stars, last pushed 4d ago), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 923 tokens. A static security scan graded it A with 1 finding (makes network calls). 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

importing-a-codebase

Use when the repo holds real source code but no specs: the existing-codebase branch of setting-up-a-project, normally reached via that dispatcher, directly only when the situation is unmistakable. Not for empty workspaces (starting-a-new-project) or feature work in a specced project (brainstorming).

JetBrains/thinkrail · 69 tokens

starting-a-new-project

Use when the workspace is empty — no code yet — and the user brings a raw idea: the brand-new branch of setting-up-a-project, normally reached via that dispatcher, directly only when the situation is unmistakable. Not for features in an existing project — use brainstorming instead.

JetBrains/thinkrail · 61 tokens

todos

This chat has a shared, live TODO plan — your tasks for the conversation, which the user also edits. Read this skill and reach for the todo tools whenever a request takes more than a couple of steps. It covers the plan model (group = task, items = its steps; loose items are the user's lane), how to work it: propose…

JetBrains/thinkrail · 127 tokens

writing-workflow-skills

Use when adding a new workflow skill to pi-thinkrail-workflow, changing an existing workflow skill's role, trigger, handoff, or structure, or checking a workflow skill against the workflow system's rules. Not for authoring general-purpose skills outside this package.

JetBrains/thinkrail · 60 tokens

brainstorming

Use this BEFORE any creative or feature work: building a new feature, adding functionality, changing behavior, or making a nontrivial design decision. Turns the user's request into a validated design — recorded as a spec-graph task-spec — before any implementation. Do not skip this because a change looks small.

JetBrains/thinkrail · 65 tokens

reviewing-changes

Use when a review package asks you to review a plan step's change set (todo.startReview): you are the REVIEWER, not the author. How to judge an agent-written diff, file findings with addreviewcomment, and settle with exactly one reviewverdict.

JetBrains/thinkrail · 59 tokens