Tell your agent exactly what safe means.
These prompts work with Codex, Claude, Cursor, custom agents, and other MCP clients. Replace the angle-bracket placeholders with your project values. Begin read-only, review a preview, then authorize a draft.
A reliable prompt structure
Read-only project discovery
Confirm the connection and understand the content model before allowing any write.
Use the configured Safe Strapi MCP server. 1. List projects and content types. 2. Inspect <content-type-uid> with inspect_content_type. 3. Read its schema, components, sample records and REST contract. 4. Research its routes, controllers, services, lifecycle hooks and frontend routing. 5. Find existing entries and inspect the relevant record. Do not create, update, delete, or publish anything.
Create News in three linked languages
Inspect the News schema, resolve real assets and create translations on the same document.
Use Safe Strapi for <project-name>. Inspect the exact News UID with inspect_content_type. Research the type's API implementation and frontend language routes. Read <article-file> and prepare content for <source-locale>, <locale-two> and <locale-three>. Resolve existing media and category IDs through read tools. Preview the source entry with preview_entry_write and show the exact fields, endpoint, visibility and hashes. Apply the authorized preview with apply_entry_write. Preview each translation with action=localize on the SAME documentId, using the shared slug where language prefixes distinguish routes. Never POST separate translation records. Re-fetch all three locales, verify content, assets, links and unchanged published versions. Use API tools only; never fall back to browser/admin UI or shell writes. Do not publish.
Update settings from their actual schema
Use the singleton endpoint and review every requested field before updating.
Use Safe Strapi for <project-name>. Inspect <single-type-uid> and its API/source behavior, then get_entry without a documentId. Preview only <field-changes> with action=update and the persisted inspectionId. Enable allowEntryEditing only for this authorized task. Show the exact PUT request, before/after values, visibility and hashes. Apply the approved persisted preview, re-fetch and verify unchanged fields. If Draft & Publish is disabled, disclose immediate visibility and require explicit approval.
Upload a reviewed image through the API
Reuse existing assets or upload the exact file and verify its saved metadata.
Use Safe Strapi for <project-name>. Search list_media for an existing matching asset first. If a new file is needed, preview_media_upload for <absolute-file-path> with alternativeText=<alt-text> and caption=<caption>. Show the file hash, destination, metadata and immediate Media Library visibility. After approval, call upload_media with its exact previewId, expectedOperationHash and stable idempotencyKey. Verify the returned media ID and metadata before referencing it in an entry. Never blindly retry an unknown upload outcome.
Update copy on a safe draft
Clone a page and patch one known component without touching the source.
Use Safe Strapi for project <project-name>. Find and inspect <page-slug>. Preview a clone that changes the title field on component index <index> to: "<new-title>" Show the source hash, operation hash, proposed slug, and exact changed paths. Do not write until I approve the preview.
Insert a component from JSON
Validate supplied JSON against the live project schema, then place it precisely.
Use Safe Strapi for project <project-name>. Inspect <page-slug> and fetch the schema for <component-uid>. Validate this JSON against that schema: <json-payload> Preview a cloned draft that inserts it after component index <index>. Preserve every field on every existing component. Do not write yet.
Move, duplicate, or replace a block
Use explicit zero-based indexes so repeated component types never become ambiguous.
Inspect <page-slug> in <project-name> and show the current indexed component order. On a cloned draft only: - move component index <from-index> after index <target-index> - duplicate component index <duplicate-index> at the end - replace component index <replace-index> with <component-json> Preview the sequential result first. If any selector is ambiguous or invalid, stop and explain it.
Protect a 100+ component page
Make several targeted changes while explicitly checking that unrelated fields survive.
Inspect the complete <page-slug> page in <project-name> and capture its source hash. Preview these operations in order on a clone: 1. Patch component #50 with <changes>. 2. Move component #80 after component #10. 3. Insert <component-json> after component #25. Use explicit indexes and a stable idempotency key. After creation, re-fetch the draft, validate it, compare it with the source, and confirm that every field outside the approved changes is preserved. Re-fetch the source and prove its hash is unchanged. Never publish.
Create a review-ready campaign draft
Turn a content brief into a named draft that editors can review in Strapi.
Use Safe Strapi to create a review draft from <source-page> in <project-name>. Brief: <campaign-brief> First inspect the page and relevant component schemas. Propose the smallest set of component operations and preview them. Use clone slug <review-slug> and title suffix " (Content Review)". After I approve, create the draft, validate it, compare it with the source, and return a concise review summary. Do not publish.
Respond safely to a conflict
Never force a stale operation through after another editor or agent changes content.
Continue the Safe Strapi operation only if the current source and draft hashes match the last inspected hashes. If you receive SOURCE_CHANGED or DRAFT_CHANGED, stop, inspect again, and show what changed before proposing a new preview. If you receive WRITE_OUTCOME_UNKNOWN, do not retry the create automatically. Never reuse an idempotency key for different operations.
Edit the middle component without cloning
Use the same document draft with preserved IDs and surrounding content. Requires npm 0.3.0 and project opt-in.
Use Safe Strapi for <project-name>. Confirm preview_modify_page and modify_page are available and list_projects reports allowInPlaceEditing=true. Inspect existing page <document-id> and the schema for component index <index>. Preview only this patch with preview_modify_page: <field-changes> Preserve every other block and existing component ID. Show differences, pageHash and operationHash. Do not write until I approve. After approval, call modify_page with the exact operations, both returned hashes and a stable idempotency key. Re-inspect the same document and verify the result. Do not clone, clear fields, replace arrays or publish.
Insert between existing components
Add a component to the existing draft while keeping old blocks in their relative order.
Use Safe Strapi for <project-name> with direct draft editing explicitly enabled. Inspect existing page <document-id> and get the schema for <component-uid>. Prepare <component-json> with all schema attributes, explicit null/empty values for unused fields and no component IDs. Preview an insert after component index <index> with preview_modify_page. Do not remove or replace existing blocks. After I approve the preview, apply it with modify_page using its pageHash, operationHash and a stable idempotency key. Re-inspect and verify the inserted block and all preserved IDs. Never publish. If this feature is unavailable in the installed package, upgrade to npm 0.3.0 and restart the MCP client before continuing.
Test a remote CMS on one disposable draft
The step-by-step acceptance guide includes prompts and verified results for creation, middle/nested edits, rollback, insertion, optional copy clearing, component removal, and conflict handling. Original draft and published pages remained unchanged.
Let an AI client read this guide
Give your agent the raw guide URL and ask it to choose the safest matching workflow. The Markdown version contains tool rules, placeholders, and every prompt without page chrome.
Read https://safe-strapi-mcp.metehankasapp.workers.dev/prompts.md Choose the safest matching Safe Strapi workflow for my request. Start read-only and do not write until you show me a preview.
Discovery metadata is also available at /llms.txt.