diff --git a/reference/.agents/skills/iapl-audit/SKILL.md b/reference/.agents/skills/iapl-audit/SKILL.md index 21d0ea5..00bd783 100644 --- a/reference/.agents/skills/iapl-audit/SKILL.md +++ b/reference/.agents/skills/iapl-audit/SKILL.md @@ -76,4 +76,13 @@ names, env, admin, AGENTS.md, skills, seeds and — with `--url` / `--deep` — rolled out). Report-only for more than a few weeks with clean reports → WARNING (switch to `mode: 'enforce'`). Then open `/pl` and `/admin` in the browser: CSP lines in the console = missing sources (flags / `extra`). +- **Drafts and locales over the API** (a collection with `versions: { drafts: true }`): without a session, + `curl -s "$U/api/?draft=true&limit=100" | grep -c '"_status":"draft"'` → `0`, else ERROR: give it + `access: { read: readPublished(), readVersions: readPublished() }` (access.md). `curl -sI "$U/md/xx"` → `404` + (no stand-in locale); a 404 page assigned in System pages must be published. +- **Secrets out of queries** (as an admin, with versions on for Site integrations or a collection using + `writeOnlySecret`): `curl -s -H "Authorization: JWT $T" "$U/api/globals/site-integrations/versions?where[version.smtpPassword][exists]=true"` + answers an error with no `totalDocs`, else ERROR (the field lost `secretReadAccess`, e.g. an override replaced its + `access`). + Do not say "done" until the full audit (without `--quick`) has no errors. diff --git a/reference/.agents/skills/iapl-collection/SKILL.md b/reference/.agents/skills/iapl-collection/SKILL.md index 84e5400..98a5b87 100644 --- a/reference/.agents/skills/iapl-collection/SKILL.md +++ b/reference/.agents/skills/iapl-collection/SKILL.md @@ -46,6 +46,9 @@ Ask only when the brief leaves a business question open (e.g. "do posts have aut **No URL prefix in code** — the editor assigns the archive page in Site settings (`Archive`). The plugin handles routing, sitemap, generateStaticParams, hreflang. + **With drafts** (`versions: { drafts: true }`): `access: { read: readPublished(), readVersions: readPublished() }` + — Payload's open `read: () => true` answers `?draft=true` with the draft over REST and GraphQL. Check: + `curl -i /api//?draft=true` without a session → `404`; the same with an editor's token → the draft. 3. Entry list = a block (EntriesList) with `getEntries`; the entry page uses `resolveRoute` (type `entry`); JSON-LD per seo.md (e.g. Article). 4. **An auth collection for visitors** (`auth: true`: customers, members) only when the client requires it