Integrate promptman with your AI applications using the Model Context Protocol (MCP) server or REST API. Manage, version, and deploy your prompts programmatically.
To use the promptman API, you'll need an API key. Sign up for a free account to get started.
Create Free AccountPromptman exposes a standard MCP server that allows AI agents (like Claude Desktop or Claude Code) to discover, fetch, and manage your prompts dynamically as tools.
https://api.promptman.dev/mcp{
"mcpServers": {
"promptman": {
"command": "npx",
"args": [
"mcp-remote",
"https://api.promptman.dev/mcp",
"--header",
"X-API-Key:YOUR_API_KEY"
]
}
}
}Add this to claude_desktop_config.json (Claude Desktop) or ~/.claude/settings.json (Claude Code). Replace YOUR_API_KEY with your API key from the dashboard.
Returns a list of all prompts in your workspace. Can optionally filter by a specific app.
| Argument | Type | Description | Required |
|---|---|---|---|
| appSlug | string | Filter prompts by app slug | No |
Retrieves a specific prompt by its slug. Optionally specify a stage to get the version pinned to that deployment stage. Without a stage, returns the latest draft.
| Argument | Type | Description | Required |
|---|---|---|---|
| promptSlug | string | The slug of the prompt to retrieve | Yes |
| stage | string | Stage name (e.g., 'dev', 'prod') to get the pinned version | No |
Returns a list of all applications in your workspace.
No arguments required.
Returns the version history of a specific prompt, ordered by most recent first.
| Argument | Type | Description | Required |
|---|---|---|---|
| promptSlug | string | The slug of the prompt | Yes |
| limit | number | Maximum number of versions to return (default: 20) | No |
Creates a new prompt in the specified application.
| Argument | Type | Description | Required |
|---|---|---|---|
| appSlug | string | The slug of the app to create the prompt in | Yes |
| content | string | The content/text of the prompt | Yes |
| title | string | The title of the prompt (max 200 characters) | No |
| variableDescriptions | object | Descriptions for template variables (see Variables Schema below) | No |
Updates an existing prompt's title and/or content. Does not create a new version by default.
| Argument | Type | Description | Required |
|---|---|---|---|
| promptSlug | string | The slug of the prompt to update | Yes |
| title | string | The new title of the prompt | Yes |
| content | string | The new content/text of the prompt | Yes |
| variableDescriptions | object | Descriptions for template variables (see Variables Schema below) | No |
| createVersion | boolean | Whether to create a new version (default: false) | No |
Permanently deletes a prompt and all its versions. This action cannot be undone.
| Argument | Type | Description | Required |
|---|---|---|---|
| promptSlug | string | The slug of the prompt to delete | Yes |
Returns a list of all agents in your workspace. Can optionally filter by a specific app.
| Argument | Type | Description | Required |
|---|---|---|---|
| appSlug | string | Filter agents by app slug | No |
Retrieves all documents for an agent. Optionally specify a stage to get the versions pinned to that deployment stage. Without a stage, returns the latest drafts.
| Argument | Type | Description | Required |
|---|---|---|---|
| agentSlug | string | The slug of the agent to retrieve | Yes |
| stage | string | Stage name (e.g., 'dev', 'prod') to get the pinned versions | No |
Creates a new agent in the specified application.
| Argument | Type | Description | Required |
|---|---|---|---|
| appSlug | string | The slug of the app to create the agent in | Yes |
| name | string | The name of the agent (max 200 characters) | Yes |
| description | string | A description of the agent | No |
Updates an existing agent's name and/or description.
| Argument | Type | Description | Required |
|---|---|---|---|
| agentSlug | string | The slug of the agent to update | Yes |
| name | string | The new name of the agent | No |
| description | string | The new description of the agent | No |
Permanently deletes an agent and all its documents and versions. This action cannot be undone.
| Argument | Type | Description | Required |
|---|---|---|---|
| agentSlug | string | The slug of the agent to delete | Yes |
Retrieves a specific document from an agent by its document key. Optionally specify a stage to get the pinned version.
| Argument | Type | Description | Required |
|---|---|---|---|
| agentSlug | string | The slug of the agent | Yes |
| documentKey | string | The document key (e.g., 'SOUL.md', 'AGENTS.md') | Yes |
| stage | string | Stage name to get the pinned version | No |
Creates a new document in an agent. Documents are identified by their key (e.g., 'SOUL.md', 'AGENTS.md').
| Argument | Type | Description | Required |
|---|---|---|---|
| agentSlug | string | The slug of the agent | Yes |
| documentKey | string | The document key (e.g., 'SOUL.md') | Yes |
| content | string | The content of the document | Yes |
Updates an existing agent document's content. Does not create a new version by default.
| Argument | Type | Description | Required |
|---|---|---|---|
| agentSlug | string | The slug of the agent | Yes |
| documentKey | string | The document key | Yes |
| content | string | The new content of the document | Yes |
| createVersion | boolean | Whether to create a new version (default: false) | No |
| message | string | Version message (required when createVersion is true, max 200 characters) | No |
Permanently deletes a document from an agent, including all its versions. This action cannot be undone.
| Argument | Type | Description | Required |
|---|---|---|---|
| agentSlug | string | The slug of the agent | Yes |
| documentKey | string | The document key to delete | Yes |
Returns the version history of a specific agent document, ordered by most recent first.
| Argument | Type | Description | Required |
|---|---|---|---|
| agentSlug | string | The slug of the agent | Yes |
| documentKey | string | The document key | Yes |
| limit | number | Maximum number of versions to return (default: 20) | No |
Use the REST API to fetch prompts directly in your applications. Perfect for server-side integrations and custom workflows.
https://api.promptman.devAll API requests require an API key passed in the X-API-Key header.
curl -H "X-API-Key: YOUR_API_KEY" \
https://api.promptman.dev/prompt/welcome-emailRetrieve a prompt by its slug. Returns the latest draft version by default.
| Parameter | Location | Description | Required |
|---|---|---|---|
| slug | path | The slug of the prompt | Yes |
| app | query | App slug to validate the prompt belongs to this app | No |
| stage | query | Stage name to get the pinned version (e.g., 'dev', 'prod') | No |
{
"title": "Welcome Email",
"content": "Hello {{username}}, welcome to {{company}}!",
"variables": {
"username": { "required": true, "type": "string", "description": "..." },
"company": { "required": true, "type": "string", "description": "..." }
},
"version": 3
}Retrieve all documents for an agent by its slug. Returns the latest drafts by default.
| Parameter | Location | Description | Required |
|---|---|---|---|
| slug | path | The slug of the agent | Yes |
| app | query | App slug to validate the agent belongs to this app | No |
| stage | query | Stage name to get the pinned versions (e.g., 'dev', 'prod') | No |
{
"name": "My Agent",
"description": "Agent description",
"documents": {
"SOUL.md": "# Soul\nYou are...",
"AGENTS.md": "# Agents\n..."
}
}Prompts can contain template variables using the {{variableName}} syntax. When creating or updating prompts, you can provide descriptions for these variables.
The variableDescriptions parameter accepts a simple object mapping variable names to their descriptions:
{
"username": "The user's display name",
"email": "User's email address",
"company": "The company or organization name"
}When retrieving prompts, the API returns a structured variables object with additional metadata for each variable:
{
"username": {
"required": true,
"type": "string",
"description": "The user's display name"
},
"email": {
"required": true,
"type": "string",
"description": "User's email address"
}
}Variable extraction
Variables are automatically extracted from the prompt content by scanning for {{variableName}} patterns. Variable names are normalized to lowercase. Only variables that appear in the content will be included in the response.