aifgrouplaos/ai-skills/wiki-publish
- community
Checking that the SKILL.md file is still in the repository.
Publish markdown to the Company wiki through Wiki.js GraphQL — bootstrap an ephemeral working copy, then create or update live pages. User-invoked only.
Install
npx vskill@latest install aifgrouplaos/ai-skills/wiki-publishSKILL.md
Company wiki publish (Wiki.js GraphQL)
Endpoint: POST $WIKI_URL/graphql Auth: Authorization: Bearer $WIKI_API_KEY — load WIKI_URL and WIKI_API_KEY from workspace .env (those two keys only; never print the key)
Leading words: preflight · working copy · index propagation · plan · APPROVE · mutate · cleanup
Mutation shapes: REFERENCE.md.
Durable store = the Company wiki. Working copies are ephemeral under $TMPDIR/wiki-publish/. Never write Wiki page markdown into a project repo (no docs/wiki-packs/).
Speak locale-absolute URLs to the user (/en/…, /th/…). GraphQL path omits the locale prefix (locale is a separate field). Never use markdown hrefs ./standards/… or ../… — Wiki.js nests those under the current page.
Step 0 — Resolve target + working copy
Completion: every target has locale, GraphQL path, working-copy path, intended title, and a create/update intent once preflight runs.
- Parse user request into wiki path(s) (
/en/standards/templates/overviewor./standards/templates/overview→ GraphQL pathstandards/templates/overview). - Locale:
/en/…→locale: "en";/th/…→locale: "th"; path has no locale prefix. - Working-copy path:
$TMPDIR/wiki-publish/<path-with-/-as-->.mdforen; same stem with.th.mdforth(e.g.projects-foo-overview.th.md). - If the working copy is missing → Step 0b (bootstrap). If present → use it as
content. - Title = first
#heading unless the user overrides. - If authoring markdown that will be published, in-body links must be locale-absolute (
/en/…or/th/…matching the page locale), not./or../. - Index propagation: when the target is a project leaf or section, expand the target set per REFERENCE.md (section index + project root for leaves; project root for sections). Use existing index working copies; if missing, pull live index page(s) first (
singleByPath, propagation-table paths only) + patch before Plan B.
Step 0b — Bootstrap (no working copy)
Completion: user has chosen a mode; Plan A is ready (no file written yet).
Offer exactly one mode per missing target:
| Mode | Source of content | |
|---|---|---|
| stub | Minimal markdown: # <title> + short placeholder body | |
| pull template | Live wiki page under standards/templates/… matching the leaf type; if missing → stub | |
| pull live | pages.singleByPath for the target path; if missing → stub |
Show Plan A:
| path | working copy | mode | title | |||
|---|---|---|---|---|---|---|
| … | $TMPDIR/… | stub \ | pull template \ | pull live | … |
Stop. Wait for exact APPROVE. Then write the working copy only. Print the file path. Stop again for human edit — do not enter Plan B until the user says they are ready or re-invokes /wiki-publish.
Step 1 — Preflight
Completion: auth OK; for each path, parents exist; create-vs-update decided.
- Load
WIKI_URLandWIKI_API_KEYfrom workspace.env— those two keys only (REFERENCE.md). If the file or either value is missing → notify the user and stop. Do not invent a host. Do not echo the key. Do notsource.env. pages.list(limit: 1)(or equivalent) — fail closed on auth errors; notify the user.- For each target:
pages.singleByPath(path, locale)→ update ifid, else create. - For create, ensure parent path exists. If missing, add parent creates to Plan B (parents first) or stop and ask.
- Prefer
curlfor HTTPS if Python SSL verify fails.
Step 2 — Plan B (wiki mutate — stop here)
Completion: user sees the plan table; no GraphQL mutations yet.
| path | id or — | action | working copy | title | ||
|---|---|---|---|---|---|---|
| … | … | create \ | update | $TMPDIR/… | … |
Live URL form: $WIKI_URL/<locale>/<path>.
Stop. Wait for exact APPROVE. yes / ok / go are not enough.
Step 3 — Mutate (only after APPROVE)
Completion: every planned row has success and singleByPath verify.
- create —
pages.createwitheditor: "markdown",isPublished: true,isPrivate: false,tags: [], body from working copy.
Do not request page.locale in the create selection set. Prefer responseResult + verify query.
- update —
pages.update(id: …)with newcontent/title; keepeditor: "markdown",isPublished: true. - When index propagation applies: mutate leaf/section first, then section index, then project root (REFERENCE.md).
- After each write:
singleByPath→ confirmid,path,title. - Report live URLs + failures.
Step 4 — Cleanup
Completion: every successfully verified working copy from this run is deleted; failures remain with path printed.
- On success (mutate + verify): delete that working copy.
- On failure or abandon: keep the file; print its path for retry.
Guards (positive form)
- Draft in the working copy; wiki publish mutate is a separate gated step.
- Create when missing; update when
idexists. - Exact
APPROVEgates Plan A (local write) and Plan B (wiki mutate). - Ephemeral working copies only — wiki is durable.
- Project leaf/section publishes expand to index propagation targets unless the user opts out.
- Index propagation: pull index paths first, exact paths only — no folder listings, no unrelated pages.
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/company/wiki-publish/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/aifgrouplaos/ai-skills/wiki-publish)