Skip to main content
Glama

Create a draft theme

create_draft_theme

Clone an installed theme into an isolated draft to edit safely without affecting the live site, then preview and publish later.

Instructions

Clone an installed theme into an isolated draft copy that you can edit freely without touching the live site. Every theme edit should go through a draft: write files, preview them on a private tokenised URL, then publish_draft_theme when you are happy (which backs up the previous theme first). Omit from_theme to clone the currently active theme.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
site_idNoWhich configured WordPress site to act on. Optional — with a single site configured it is used automatically; with several, the default site is used unless you name one. Run list_sites for valid ids.
draft_nameNoHuman-readable name for the draft. Defaults to "<theme> (draft)".
from_themeNoStylesheet to clone. Defaults to the active theme.
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already indicate destructiveHint=false and readOnlyHint=false. The description adds valuable context by explaining that the operation clones into an isolated draft, reinforcing safety and non-interference with the live site. It also mentions the backup behavior of the publishing step, which helps the agent understand the overall lifecycle. Not contradictory to annotations, and provides meaningful behavior beyond what the booleans convey.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is three sentences with no redundancy. It front-loads the core purpose, then explains the workflow context, and ends with a practical parameter tip. Every sentence earns its place, and the structure guides the agent from understanding to action efficiently.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The description covers the tool's purpose, its position in the editing workflow, and the optional parameter behavior. While it does not describe the return value or response format, there is no output schema, so that gap is acceptable. For a tool with only three optional parameters and clear annotations, this is sufficiently complete for an agent to call it correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

All three parameters have detailed descriptions in the schema (100% coverage), so the baseline is 3. The description reiterates the from_theme default pattern ('Omit from_theme to clone the currently active theme'), which is already stated in the schema. It adds no new semantic detail to the parameters themselves, only reinforces the workflow. Thus it meets the baseline but does not exceed it.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb (clone) and resource (installed theme into an isolated draft copy). It clearly distinguishes this from sibling tools like publish_draft_theme and delete_draft_theme by focusing on the creation of an editable draft without affecting the live site. The purpose is unambiguous and immediately understandable.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explicitly prescribes when to use the tool: 'Every theme edit should go through a draft'. It outlines the full workflow (create draft → write files → preview → publish) and identifies publish_draft_theme as the follow-up action. It also gives a concrete tip about the from_theme parameter. This leaves no doubt about the tool's role versus alternatives.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/alokemajumder/wpxmcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server