Skip to main content
Glama

create_prompt_version

Create a new version of a prompt template, specifying model, provider, and messages. Optionally creates the template if it does not exist.

Instructions

Create a new version of a prompt template. This is a write operation. Always confirm with the user before calling — describe which prompt template will be modified, the model and provider, and whether a new template will be created.

If the template doesn't exist and create_if_not_exists is True, the template will be created automatically.

Note: Deployment is not supported via MCP at this time to reduce risk of unintentional changes. Use the Freeplay UI to deploy versions to environments.

Args: project_id: The Freeplay project ID (required) template_name: Name of the prompt template (required) prompt_messages: JSON string of template messages array, e.g. '[{"role": "system", "content": "You are helpful."}]' (required) model: The model name, e.g. "gpt-4", "claude-3-opus" (required) provider: The provider name, e.g. "openai", "anthropic" (required) version_name: Optional name for this version version_description: Optional description for this version llm_parameters: Optional LLM parameters object, e.g. {"temperature": 0.7, "max_tokens": 1000} tool_schema: Optional tool definitions array for function calling output_schema: Optional output schema for structured outputs create_if_not_exists: If true, creates the template if it doesn't exist (default: true)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modelYes
providerYes
project_idYes
tool_schemaNo
version_nameNo
output_schemaNo
template_nameYes
llm_parametersNo
prompt_messagesYes
version_descriptionNo
create_if_not_existsNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

No annotations are provided, so the description fully discloses behavior: it is a write operation requiring user confirmation. It explains the automatic creation behavior when create_if_not_exists is true. It does not detail versioning mechanics (e.g., numbering), but the overall behavior is clear.

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

Conciseness4/5

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

The description is well-structured: starts with a clear purpose statement, followed by usage guidance, then a parameter block. It is relatively long but every part adds value. Minor redundancy could be trimmed (e.g., the parameter list repeats schema info), but it remains efficient for its complexity.

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?

Given 11 parameters (5 required), an output schema exists, and no annotations, the description covers all key aspects: purpose, required confirmation, automatic template creation, deployment limitation, and parameter details. It could mention default values (e.g., create_if_not_exists defaults to true) but these are in the schema. Overall, it is complete for an agent to invoke correctly.

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

Parameters4/5

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

Input schema description coverage is 0%, so the description must compensate. It does so by listing all parameters with examples (e.g., prompt_messages JSON format, model examples like 'gpt-4', provider examples like 'openai'). Optional parameters like llm_parameters and tool_schema are explained. Some parameter types (e.g., tool_schema as array of objects) could be more precise, but the examples help.

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 clearly states the core action: 'Create a new version of a prompt template.' It specifies it is a write operation. None of the sibling tools (e.g., get_prompt_version, list_prompt_templates) perform creation, so it is distinct.

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?

Explicitly instructs the agent to 'Always confirm with the user before calling' and to describe which template, model, provider, and whether a new template will be created. Also warns that 'Deployment is not supported via MCP' and directs to the Freeplay UI, guiding when not to use the tool.

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/freeplayai/freeplay-mcp'

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