Edit an AI prompt version in place (internal)

Add MCP server to your AI tool

Allow AI tools and LLMs to interact with the API documentation portal through MCP.

MCP server URL

https://docs.usehearsay.com/mcp

Standard setup for AI tools providing an mcp.json file

mcp.json
{
  "integrations MCP server": {
    "url": "https://docs.usehearsay.com/mcp"
  }
}

Close
PATCH /ai/admin/prompts/{purpose}/versions/{versionSlug}

Edits the system prompt, tool description or input schema, model, token limit, temperature or notes of a version without changing its versionSlug, so meant for small fixes; use a new draft for material changes. Renaming or removing top-level tool input properties returns 400; an unknown version returns 404. An unknown purpose returns 400. Super admins only.

Path parameters

  • purpose string Required

    Values are chunk_summary, period_summary, conversation_summary, case_summary, case_context_filing_extraction, relevance_gate, evidentiary_map_element, or tag_suggestion.

  • versionSlug string Required
application/json

Body Required

  • systemPrompt string
  • toolDescription string
  • toolInputSchema object

    Claude tool-use input_schema (JSON Schema). Renaming or removing top-level properties triggers 400.

  • model string

    'haiku' / 'sonnet' alias or a literal Bedrock model id

  • maxTokens number

    Minimum value is 1, maximum value is 32000.

  • temperature number

    Minimum value is 0, maximum value is 2.

  • notes string

Responses

  • 200 application/json
    Hide response attributes Show response attributes object
    • data object Required
      Hide data attributes Show data attributes object
      • _id string
      • purpose string

        Values are chunk_summary, period_summary, conversation_summary, case_summary, case_context_filing_extraction, relevance_gate, evidentiary_map_element, or tag_suggestion.

      • versionSlug string
      • systemPrompt string
      • toolName string
      • toolDescription string
      • toolInputSchema object

        JSON Schema of the tool input.

      • model string
      • maxTokens number
      • temperature number
      • isActive boolean
      • notes string
      • createdBy string | null
      • updatedBy string | null
      • createdAt string(date-time) | null
      • updatedAt string(date-time) | null
    • statusCode number Required
    • timestamp string(date-time) Required
PATCH /ai/admin/prompts/{purpose}/versions/{versionSlug}
curl \
 --request PATCH 'http://api.example.com/ai/admin/prompts/{purpose}/versions/{versionSlug}' \
 --header "Authorization: Bearer $ACCESS_TOKEN" \
 --header "Content-Type: application/json" \
 --data '{
  "systemPrompt": "string",
  "toolDescription": "string",
  "toolInputSchema": {},
  "model": "string",
  "maxTokens": 42.0,
  "temperature": 42.0,
  "notes": "string"
}'
Request examples
{
  "systemPrompt": "string",
  "toolDescription": "string",
  "toolInputSchema": {},
  "model": "string",
  "maxTokens": 42.0,
  "temperature": 42.0,
  "notes": "string"
}
Response examples (200)
{
  "data": {
    "_id": "65a1b2c3d4e5f6a7b8c9d0e1",
    "purpose": "case_summary",
    "versionSlug": "case_summary.v2",
    "systemPrompt": "string",
    "toolName": "string",
    "toolDescription": "string",
    "toolInputSchema": {},
    "model": "sonnet",
    "maxTokens": 1024,
    "temperature": 0.2,
    "isActive": true,
    "notes": "string",
    "createdBy": "65a1b2c3d4e5f6a7b8c9d0e4",
    "updatedBy": "65a1b2c3d4e5f6a7b8c9d0e4",
    "createdAt": "2026-01-15T10:15:00.000Z",
    "updatedAt": "2026-01-15T10:15:00.000Z"
  },
  "statusCode": 200,
  "timestamp": "2026-01-15T10:15:00.000Z"
}