Admin MCP tools

The admin MCP is a stateless Streamable-HTTP JSON-RPC endpoint at POST https://api.mozaik-dev.com/mcp (no sessions, no SSE — every POST is answered with JSON). Auth is a bearer mzk_ token only; the store is derived from the token — a store/storeId argument in tool input is refused as a validation error. Every tool call is synthesized into an ordinary HTTP request and replayed through the same router the admin panel uses, so auth, scope gates and the proposal divert are byte-identical to the public API.

initialize negotiates the protocol (2026-07-28 with legacy auto-detect) and enforces the client floor: a clientInfo that identifies as our CLI/Dev MCP below 0.1.0 is refused with -32001 client_too_old and the exact upgrade command (npm i -g @mozaik/cli@0.1.0). Third-party MCP clients are never refused for lacking a version.

Tool names are the registry's dotted ids verbatim — one tool per command, one per catalog route with a non-owner policy (commands.run/commands.list are omitted: commands are 1:1 tools already). The list below is buildToolList() with the full admin scope; a real token sees the scope-filtered subset. Resources: mzk://store, mzk://proposal/current, mzk://draft, mzk://sections-meta, mzk://docs/{path}.

Developer view (Geliştirici token — executes directly)

toolkindpolicysummary
catalog.category.archivecommandproposeArchive a category (products keep their assignment; hidden from active lists).
catalog.category.createcommandproposeCreate a category (flat compliance taxonomy; taksitCap = BDDK installment cap).
catalog.category.updatecommandproposeUpdate a category's name, installment cap, or position.
catalog.collection.archivecommandproposeArchive a collection — its page 404s; product memberships are kept.
catalog.collection.createcommandproposeCreate a collection (handle derived from title when omitted).
catalog.collection.setProductscommandproposeWholesale-replace a collection's product list (order = array order = manual sort).
catalog.collection.updatecommandproposePatch collection fields.
catalog.digital.codes.addcommandproposeAdd e-pin codes to a pooled digital product (sealed at rest; duplicates skipped).
catalog.digital.codes.voidcommandproposeVoid unused pool codes (oldest first) — they can never be allocated; nothing is deleted.
catalog.media.commitcommandproposeCommit a staged upload into the media library (variants generated async).
catalog.media.deletecommandproposePermanently delete an UNUSED media file (refused while referenced by catalog, live design, or the draft).
catalog.price.setcommandproposeSet the price (kuruş) of a product (prd_) or variant (var_). compareAt only on products; null clears it. Variant price null = inherit product price.
catalog.product.archivecommandproposeArchive a product — removed from the storefront, history kept.
catalog.product.createcommandproposeCreate a product. price/compareAt in kuruş; stock null = untracked; handle derived from title when omitted.
catalog.product.setDigitalcommandproposeSet a product's digital/shipping posture: requiresShipping, delivered digital content, withdrawal exception.
catalog.product.setMediacommandproposeWholesale-replace a product's media list (order = array order; alt is per-usage).
catalog.product.setVariantscommandproposeWholesale-replace a product's variant STRUCTURE (order = array order). Existing variants update title/sku only; initial price/stock allowed solely for new variants.
catalog.product.updatecommandproposePatch product fields. Price and stock are NOT here — use catalog.price.set / catalog.stock.set.
catalog.stock.adjustcommandproposeAdjust stock by a ± delta (receiving, stocktake, connector sync). Fails on untracked items; expectedStock = compare-and-set.
catalog.stock.setcommandproposeSet stock of a product (prd_) or variant (var_). null = untracked (always available).
customer.anonymizecommandproposeAnonymize a customer row (KVKK request) — order snapshots stay under the statutory retention.
customer.identity.unlinkcommandproposeClear a Mozaik ID pointer from this store's customers (revoke/erasure healing).
extension.configurecommandproposeSet an extension's configuration (validated against its schema). Does not enable it.
extension.disablecommandproposeDisable an extension. Its payment method / hooks / panels stop immediately.
extension.enablecommandproposeEnable an installed extension. Requires its secrets set and config valid.
extension.hook.deactivatecommandproposeDeactivate (or reactivate) an extension's hooks without disabling the extension.
extension.installcommandproposeInstall an extension for this store (disabled until configured + enabled). Grants the manifest's scopes.
extension.uninstallcommandproposeUninstall a disabled extension. Config is archived in the audit row; secrets and data are kept.
extension.upgradecommandproposeUpgrade an installed extension to the platform's current manifest version.
metafield.definition.createcommandproposeDefine a typed custom field on products, variants, collections, or the store.
metafield.definition.deletecommandproposeDelete a metafield definition AND every value stored under it.
metafield.definition.updatecommandproposeUpdate a metafield definition's label, description, or validations (type/key are immutable).
metafield.setcommandproposeSet a metafield value on a product, variant, collection, or the store.
metafield.unsetcommandproposeRemove a metafield value.
order.cancelcommandproposeCancel an unpaid order (pending_cod/awaiting_transfer) — restocks lines.
order.cod.collectcommandproposeRecord that the carrier's COD cash for a shipped/delivered order reached the merchant — order becomes paid.
order.note.addcommandproposeAppend a merchant note to an order's timeline.
order.return.approvecommandproposeApprove a return — issues the instructions the shopper sees (snapshotted as evidence).
order.return.receivecommandproposeRecord the returned goods arriving — per-line condition; saleable lines restock (ledgered).
order.return.rejectcommandproposeReject a return with a stated reason (the shopper mail carries the THH/consumer-court recourse).
order.shipcommandproposeCreate a shipment for an order's shippable lines (a cargo extension or a manual carrier) — writes the VUK 509 forward fields.
order.shipment.cancelcommandproposeCancel a shipment before carrier handoff completes — resets the order to unfulfilled when nothing else is active.
order.shipment.trackcommandproposeRecord a carrier state transition (webhook/poll/manual) and aggregate the order's fulfillment status.
order.transfer.confirmcommandproposeConfirm a bank-transfer payment arrived — order becomes paid; digital content is released.
proposal.submitcommanddirectSubmit an open proposal for the store owner's review (the owner is mailed a link). The proposalId comes from your first recorded mutation's response — or proposals.list.
proposal.withdrawcommanddirectWithdraw a proposal that has not been applied.
settings.checkout.updatecommandproposeUpdate checkout legal settings: delivery estimate, return-cargo carrier/cost disclosure.
settings.flag.setcommandproposeSet or clear a store readiness flag (ETBİS beyanı, rehber kartları).
settings.identity.updatecommandproposeSet the legal merchant identity (6563 m.3) — complete rows only; rendered live in the footer.
settings.store.updatecommandproposeUpdate store settings (display name). Projected to KV tenant records.
store.syncKvcommanddirectRe-project store state (t:, l:, live b:, g:) from Postgres to KV; bumps generation once.
audit.listroutereadRecent audit rows for the store (optionally by entity).
cargo.carriers.listroutereadPlatform carrier reference table (codes, labels, tracking availability).
catalog.categories.listroutereadList categories.
catalog.collections.getroutereadGet one collection with members.
catalog.collections.listroutereadList collections.
catalog.products.getroutereadGet one product with variants, media and stock.
catalog.products.listroutereadList products (keyset cursor, filters).
catalog.stockMovements.listroutereadStock ledger rows for a product or variant.
design.draft.deleterouteworkspaceDiscard the draft (expectedRev).
design.draft.getroutereadRead the draft bundle (rev, hash, body, preview link).
design.draft.putrouteworkspaceReplace the draft bundle under optimistic concurrency (expectedRev).
design.draftFromTemplaterouteworkspaceInstantiate a starter template as the draft.
design.previewUrl.getroutereadSigned preview link: ?hash= freezes a snapshot, ?workspace= follows that workspace's current draft (the dev-loop link).
design.templates.listroutereadStarter template cards.
design.version.getroutereadFull body of a published version.
design.versions.listroutereadPublished version ledger (seq, hash, label, live marker).
ext.cargo.senderrouteproposeCreate the sender address at the cargo provider and store its id in the extension config.
extensions.listroutereadInstalled + available extensions with config, secrets state and manifest UI hints (owner-only).
extensions.ops.getroutereadThe extension's agent contract with LIVE readiness: every op, what it needs (secrets/config/enabled), and exactly what blocks it right now. Secrets appear as keys only.
media.listroutereadList media objects.
media.uploadrouteworkspaceStage a binary upload (raw body); commit with catalog.media.commit.
meta.getroutereadPlatform build identity and compatibility fingerprint (buildId, registryHash, minCli).
metafields.definitions.listroutereadMetafield definitions (owner-only).
orders.belge.getroutereadFetch a legal document snapshot of an order.
orders.cargo.bookrouteproposeAccept a carrier offer, create the label and ship the order.
orders.cargo.offersroutequoteCreate a provider quote for the order and return carrier offers (no store mutation).
orders.cargo.shiprouteproposeShip with the merchant's own carrier (manual tracking).
orders.cod.collectrouteproposeMark a cash-on-delivery order as collected.
orders.getroutereadGet one order with lines, payment, shipments, returns, timeline.
orders.listroutereadList orders.
orders.note.addrouteproposeAdd a merchant note to the order timeline.
orders.refundrouteproposeRefund part or all of a captured payment through the original PSP extension.
orders.shipment.cancelrouteproposeCancel a shipment before pickup.
orders.shipment.labelroutequoteFetch the shipping label URL from the provider.
orders.shipment.trackrouteproposeRecord a shipment status transition by hand.
orders.shipment.updaterouteproposePoll the provider and apply the current tracking status.
proposals.getroutereadOne proposal with its items, recorded previews and (for design items) a preview link.
proposals.listroutereadList proposals; agent tokens see only their own.
returns.approverouteproposeApprove a return request with shipping instructions; mails the shopper.
returns.getroutereadGet one return request.
returns.listroutereadList return requests.
returns.rejectrouteproposeReject a return request with a reason; mails the shopper.
routes.listroutereadList typed routes with JSON Schemas (the twin of commands.list).
scopes.listroutereadScope registry: TR labels, sensitivity and who may hold each scope (any token / developer tokens / sessions only).
sections.meta.getroutereadSection catalog with props/blocks JSON Schemas and placement rules.
store.checkoutSettings.getroutereadCheckout settings (owner-only).
store.health.getroutereadStore readiness checklist (draft/live, identity, flags).
store.identity.getroutereadLegal identity block (owner-only).
tokens.whoamiroutereadDescribe the calling credential: store, kind, scopes, expiry, workspace — what an agent should call first.
validate.bundleroutequoteValidate a store bundle (schema + referential integrity) without saving anything. Media readiness is checked at draft save, which is the enforcement point.
validate.commandroutequoteValidate a command payload against its registered schema without running it (no preview, no mutation).
validate.manifestroutequoteValidate an extension manifest against zExtensionManifest, including the agent-contract rules.
workspaces.adoptrouteworkspaceCopy a workspace draft into the builder's main draft under optimistic concurrency (never a merge).
workspaces.listroutereadList draft workspaces: the builder's main draft plus every agent/developer workspace with its draft rev and sandbox state.

Agent view (Ajan token — propose tools are recorded, not applied)

The same names; propose tools answer PROPOSED (not applied) and record the call into the token's open proposal for the owner to review.

toolkindpolicyproposal-recordedsummary
catalog.category.archivecommandproposeArchive a category (products keep their assignment; hidden from active lists).
catalog.category.createcommandproposeCreate a category (flat compliance taxonomy; taksitCap = BDDK installment cap).
catalog.category.updatecommandproposeUpdate a category's name, installment cap, or position.
catalog.collection.archivecommandproposeArchive a collection — its page 404s; product memberships are kept.
catalog.collection.createcommandproposeCreate a collection (handle derived from title when omitted).
catalog.collection.setProductscommandproposeWholesale-replace a collection's product list (order = array order = manual sort).
catalog.collection.updatecommandproposePatch collection fields.
catalog.digital.codes.addcommandproposeAdd e-pin codes to a pooled digital product (sealed at rest; duplicates skipped).
catalog.digital.codes.voidcommandproposeVoid unused pool codes (oldest first) — they can never be allocated; nothing is deleted.
catalog.media.commitcommandproposeCommit a staged upload into the media library (variants generated async).
catalog.media.deletecommandproposePermanently delete an UNUSED media file (refused while referenced by catalog, live design, or the draft).
catalog.price.setcommandproposeSet the price (kuruş) of a product (prd_) or variant (var_). compareAt only on products; null clears it. Variant price null = inherit product price.
catalog.product.archivecommandproposeArchive a product — removed from the storefront, history kept.
catalog.product.createcommandproposeCreate a product. price/compareAt in kuruş; stock null = untracked; handle derived from title when omitted.
catalog.product.setDigitalcommandproposeSet a product's digital/shipping posture: requiresShipping, delivered digital content, withdrawal exception.
catalog.product.setMediacommandproposeWholesale-replace a product's media list (order = array order; alt is per-usage).
catalog.product.setVariantscommandproposeWholesale-replace a product's variant STRUCTURE (order = array order). Existing variants update title/sku only; initial price/stock allowed solely for new variants.
catalog.product.updatecommandproposePatch product fields. Price and stock are NOT here — use catalog.price.set / catalog.stock.set.
catalog.stock.adjustcommandproposeAdjust stock by a ± delta (receiving, stocktake, connector sync). Fails on untracked items; expectedStock = compare-and-set.
catalog.stock.setcommandproposeSet stock of a product (prd_) or variant (var_). null = untracked (always available).
customer.anonymizecommandproposeAnonymize a customer row (KVKK request) — order snapshots stay under the statutory retention.
customer.identity.unlinkcommandproposeClear a Mozaik ID pointer from this store's customers (revoke/erasure healing).
extension.configurecommandproposeSet an extension's configuration (validated against its schema). Does not enable it.
extension.disablecommandproposeDisable an extension. Its payment method / hooks / panels stop immediately.
extension.enablecommandproposeEnable an installed extension. Requires its secrets set and config valid.
extension.hook.deactivatecommandproposeDeactivate (or reactivate) an extension's hooks without disabling the extension.
extension.installcommandproposeInstall an extension for this store (disabled until configured + enabled). Grants the manifest's scopes.
extension.uninstallcommandproposeUninstall a disabled extension. Config is archived in the audit row; secrets and data are kept.
extension.upgradecommandproposeUpgrade an installed extension to the platform's current manifest version.
metafield.definition.createcommandproposeDefine a typed custom field on products, variants, collections, or the store.
metafield.definition.deletecommandproposeDelete a metafield definition AND every value stored under it.
metafield.definition.updatecommandproposeUpdate a metafield definition's label, description, or validations (type/key are immutable).
metafield.setcommandproposeSet a metafield value on a product, variant, collection, or the store.
metafield.unsetcommandproposeRemove a metafield value.
order.cancelcommandproposeCancel an unpaid order (pending_cod/awaiting_transfer) — restocks lines.
order.cod.collectcommandproposeRecord that the carrier's COD cash for a shipped/delivered order reached the merchant — order becomes paid.
order.note.addcommandproposeAppend a merchant note to an order's timeline.
order.return.approvecommandproposeApprove a return — issues the instructions the shopper sees (snapshotted as evidence).
order.return.receivecommandproposeRecord the returned goods arriving — per-line condition; saleable lines restock (ledgered).
order.return.rejectcommandproposeReject a return with a stated reason (the shopper mail carries the THH/consumer-court recourse).
order.shipcommandproposeCreate a shipment for an order's shippable lines (a cargo extension or a manual carrier) — writes the VUK 509 forward fields.
order.shipment.cancelcommandproposeCancel a shipment before carrier handoff completes — resets the order to unfulfilled when nothing else is active.
order.shipment.trackcommandproposeRecord a carrier state transition (webhook/poll/manual) and aggregate the order's fulfillment status.
order.transfer.confirmcommandproposeConfirm a bank-transfer payment arrived — order becomes paid; digital content is released.
proposal.submitcommanddirectSubmit an open proposal for the store owner's review (the owner is mailed a link). The proposalId comes from your first recorded mutation's response — or proposals.list.
proposal.withdrawcommanddirectWithdraw a proposal that has not been applied.
settings.checkout.updatecommandproposeUpdate checkout legal settings: delivery estimate, return-cargo carrier/cost disclosure.
settings.flag.setcommandproposeSet or clear a store readiness flag (ETBİS beyanı, rehber kartları).
settings.identity.updatecommandproposeSet the legal merchant identity (6563 m.3) — complete rows only; rendered live in the footer.
settings.store.updatecommandproposeUpdate store settings (display name). Projected to KV tenant records.
store.syncKvcommanddirectRe-project store state (t:, l:, live b:, g:) from Postgres to KV; bumps generation once.
audit.listroutereadRecent audit rows for the store (optionally by entity).
cargo.carriers.listroutereadPlatform carrier reference table (codes, labels, tracking availability).
catalog.categories.listroutereadList categories.
catalog.collections.getroutereadGet one collection with members.
catalog.collections.listroutereadList collections.
catalog.products.getroutereadGet one product with variants, media and stock.
catalog.products.listroutereadList products (keyset cursor, filters).
catalog.stockMovements.listroutereadStock ledger rows for a product or variant.
design.draft.deleterouteworkspaceDiscard the draft (expectedRev).
design.draft.getroutereadRead the draft bundle (rev, hash, body, preview link).
design.draft.putrouteworkspaceReplace the draft bundle under optimistic concurrency (expectedRev).
design.draftFromTemplaterouteworkspaceInstantiate a starter template as the draft.
design.previewUrl.getroutereadSigned preview link: ?hash= freezes a snapshot, ?workspace= follows that workspace's current draft (the dev-loop link).
design.templates.listroutereadStarter template cards.
design.version.getroutereadFull body of a published version.
design.versions.listroutereadPublished version ledger (seq, hash, label, live marker).
ext.cargo.senderrouteproposeCreate the sender address at the cargo provider and store its id in the extension config.
extensions.listroutereadInstalled + available extensions with config, secrets state and manifest UI hints (owner-only).
extensions.ops.getroutereadThe extension's agent contract with LIVE readiness: every op, what it needs (secrets/config/enabled), and exactly what blocks it right now. Secrets appear as keys only.
media.listroutereadList media objects.
media.uploadrouteworkspaceStage a binary upload (raw body); commit with catalog.media.commit.
meta.getroutereadPlatform build identity and compatibility fingerprint (buildId, registryHash, minCli).
metafields.definitions.listroutereadMetafield definitions (owner-only).
orders.belge.getroutereadFetch a legal document snapshot of an order.
orders.cargo.bookrouteproposeAccept a carrier offer, create the label and ship the order.
orders.cargo.offersroutequoteCreate a provider quote for the order and return carrier offers (no store mutation).
orders.cargo.shiprouteproposeShip with the merchant's own carrier (manual tracking).
orders.cod.collectrouteproposeMark a cash-on-delivery order as collected.
orders.getroutereadGet one order with lines, payment, shipments, returns, timeline.
orders.listroutereadList orders.
orders.note.addrouteproposeAdd a merchant note to the order timeline.
orders.refundrouteproposeRefund part or all of a captured payment through the original PSP extension.
orders.shipment.cancelrouteproposeCancel a shipment before pickup.
orders.shipment.labelroutequoteFetch the shipping label URL from the provider.
orders.shipment.trackrouteproposeRecord a shipment status transition by hand.
orders.shipment.updaterouteproposePoll the provider and apply the current tracking status.
proposals.getroutereadOne proposal with its items, recorded previews and (for design items) a preview link.
proposals.listroutereadList proposals; agent tokens see only their own.
returns.approverouteproposeApprove a return request with shipping instructions; mails the shopper.
returns.getroutereadGet one return request.
returns.listroutereadList return requests.
returns.rejectrouteproposeReject a return request with a reason; mails the shopper.
routes.listroutereadList typed routes with JSON Schemas (the twin of commands.list).
scopes.listroutereadScope registry: TR labels, sensitivity and who may hold each scope (any token / developer tokens / sessions only).
sections.meta.getroutereadSection catalog with props/blocks JSON Schemas and placement rules.
store.checkoutSettings.getroutereadCheckout settings (owner-only).
store.health.getroutereadStore readiness checklist (draft/live, identity, flags).
store.identity.getroutereadLegal identity block (owner-only).
tokens.whoamiroutereadDescribe the calling credential: store, kind, scopes, expiry, workspace — what an agent should call first.
validate.bundleroutequoteValidate a store bundle (schema + referential integrity) without saving anything. Media readiness is checked at draft save, which is the enforcement point.
validate.commandroutequoteValidate a command payload against its registered schema without running it (no preview, no mutation).
validate.manifestroutequoteValidate an extension manifest against zExtensionManifest, including the agent-contract rules.
workspaces.adoptrouteworkspaceCopy a workspace draft into the builder's main draft under optimistic concurrency (never a merge).
workspaces.listroutereadList draft workspaces: the builder's main draft plus every agent/developer workspace with its draft rev and sandbox state.
Generated from the live platform registries at build time — reference pages cannot go stale. Markdown variant: /reference/mcp-tools.md