agentleFS
openvigletopenviglet/shio/.claude/skills/shio-content-api/SKILL.md

shio-content-api

Skill3 starsChanged 8 days agoApache-2.0View on GitHub

Read before touching Shio's content REST API or post types. Triggers on /api/v2/object/{id}/list or /path, ShConsoleListing, ShConsolePost, /api/v2/post-unified/**, copyto/moveto, /api/v2/folder/**, /api/v2/site/**, /api/v2/import, /api/v2/staticfile/**, the trash and untrash/purge, ShFolderWriteService, ShObjectWriteService, ShAddressResolver, and /api/v2/post-type/** including rename.

The file

We split this skill into the rules it gives an agent

1 rule. About 0 are common, 0 are distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈0

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    There is no generic DELETE /api/v2/object/{id}: Delete by type.

    line 19

≈ “Common” is an estimate: at least 1 in 5 of the 364,980 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Shio content API + post types

Read docs/agents/content-api.md (console reads, unified posts, copy/move, folders, sites, exchange import, static files, the trash) and docs/agents/post-types.md (the one name-keyed post-type surface).

The facts that prevent the common wrong turns

  • There is no /api/v2/post controller — do not add one. Post CRUD is /api/v2/post-unified/** on sh_post_unified; the legacy split ShPost/ShPostDraft were deleted in the nuclear refactor.
  • There is no generic DELETE /api/v2/object/{id}. Delete by type.
  • There is one post-type API and it is keyed by name. SH117 retired the id-keyed, entity-shaped twin at /api/v2/post/type; a reference to that path is stale. Renaming is POST /api/v2/post-type/{name}/rename and nothing else — a PUT to a new name creates a second type and orphans the first while answering 200.
  • Never serialize ShFolder/ShPostUnified out of a console read. Console reads return the CDA shapes (ShConsoleListing, ShConsolePost), owned by ShConsoleNavigationMapper / ShConsolePostMapper, mapped inside a transaction because shPostType/shFolder are LAZY.
  • Both ends of a move or copy are authorized (SH201), and the write service — not the controller — owns the refusals (checkMovable / checkCopyable).
  • A friendly URL is not unique by construction (SH321). The finder returns an ordered List: a reader that must serve something takes the first; ShAddressResolver refuses with a teaching 409, because an address is what a write takes. A derived Optional over a furl fails the build — ShFurlReaderLintTest, default is the one hatch (SH323).
  • duplicate-url is locale-blind on purpose (SH323). An address carries no locale, so two posts on one URL are unaddressable whatever tells them apart. A translation needs its own URL.

Guards that already exist

ShConsoleShapeOverlapTest fails the build when a component shared between a console row and its CDA counterpart drifts. ShFolderSiteInvariantTest catches folder.getShSite(). ShRootFolderReaderLintTest refuses picking from the unordered findByShSiteAndRootFolder Set (it permits iterating).

The one rule to carry into any new read

The order and the filter are the server's. A client-side sort over a paged listing sorts one page and reads exactly like a correct answer; an unknown sort is a teaching 400, never a fallback, because a listing answered in another order returns other rows.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.