> ## Documentation Index
> Fetch the complete documentation index at: https://docs.tetherai.ca/llms.txt
> Use this file to discover all available pages before exploring further.

# Update prompt version metadata

> Updates editable metadata fields (displayVersion, title, description) on a prompt version. Passing an explicit null clears the field; at least one field must be supplied.



## OpenAPI

````yaml /api-reference/openapi.yaml patch /api/prompts/{promptId}/versions/{versionId}
openapi: 3.0.3
info:
  title: Tether Relay and Tether API
  version: 1.0.0
  description: >-
    Route-derived OpenAPI contract generated from tether-relay backend sources.
    Regenerate with scripts/sync-openapi-from-backend.mjs.
servers:
  - url: https://your-instance.example.com
    description: Production
  - url: http://localhost:2212
    description: Local API service
security: []
tags:
  - name: AI
  - name: Applications
  - name: Approval
  - name: Auth
  - name: Automations
  - name: Calls
  - name: Campaigns
  - name: Contact Analytics
  - name: Contact Metrics
  - name: Contact Notes
  - name: Contacts
  - name: Conversation Monitor
  - name: Conversations
  - name: Departments
  - name: Email
  - name: Escalation Dashboard
  - name: Event Logs
  - name: Google Sheets
  - name: Marketplace
  - name: Messages
  - name: Notification Sounds
  - name: Notifications
  - name: Org Snapshots
  - name: Organizations
  - name: Outreach
  - name: Outreach Metrics
  - name: Outreach Sources
  - name: Pipelines
  - name: Processes
  - name: Prompts
  - name: Reminders
  - name: Sms
  - name: Templates
  - name: Traces
  - name: Training
  - name: Upload
  - name: User Snapshots
  - name: Users
  - name: Vertical
  - name: Webchats
  - name: Webhook
paths:
  /api/prompts/{promptId}/versions/{versionId}:
    patch:
      tags:
        - Prompts
      summary: Update prompt version metadata
      description: >-
        Updates editable metadata fields (displayVersion, title, description) on
        a prompt version. Passing an explicit null clears the field; at least
        one field must be supplied.
      operationId: patch_prompts_version_metadata
      parameters:
        - in: path
          name: promptId
          required: true
          schema:
            type: string
        - in: path
          name: versionId
          required: true
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PromptVersionMetadataUpdateRequest'
      responses:
        '200':
          description: Prompt version updated successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PromptVersionUpdateResponse'
        '400':
          description: Invalid version id or no fields to update
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PromptErrorResponse'
        '403':
          description: Prompt not found or not accessible by user
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PromptErrorResponse'
        '404':
          description: Version not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PromptErrorResponse'
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PromptErrorResponse'
      security:
        - bearerAuth: []
components:
  schemas:
    PromptVersionMetadataUpdateRequest:
      type: object
      properties:
        displayVersion:
          type: string
          nullable: true
          description: >-
            Human label shown in the version dropdown (e.g. `v1.4`); pass null
            to clear.
        title:
          type: string
          nullable: true
          description: Short label shown on the version timeline entry; pass null to clear.
        description:
          type: string
          nullable: true
          description: >-
            Longer description shown on the version timeline entry; pass null to
            clear.
      additionalProperties: true
      example:
        displayVersion: v1.5
        title: Tone tweak
        description: Softened opening line based on feedback.
    PromptVersionUpdateResponse:
      type: object
      description: Returned by `PATCH /api/prompts/{promptId}/versions/{versionId}`.
      properties:
        message:
          type: string
        version:
          $ref: '#/components/schemas/PromptVersionSummary'
      required:
        - message
        - version
      additionalProperties: true
      example:
        message: Prompt version updated successfully
        version:
          _id: 64d2f9c5e8a1d4e001a0b1d8
          version: 5
          label: Pre-launch checkpoint (renamed)
          displayVersion: v1.4
          title: Pre-launch — final
          description: Renamed during launch retro.
          source: manual_save
          createdAt: '2026-04-25T10:14:00.000Z'
    PromptErrorResponse:
      type: object
      description: Generic error envelope returned by Prompt endpoints.
      properties:
        error:
          type: string
        details:
          type: string
      required:
        - error
      additionalProperties: true
      example:
        error: Prompt not found
        details: No prompt with id 5f7b1c2e8a1d4e0012c3b4a5 belongs to this user.
    PromptVersionSummary:
      type: object
      properties:
        _id:
          type: string
        version:
          type: integer
        label:
          type: string
          nullable: true
        displayVersion:
          type: string
          nullable: true
        title:
          type: string
          nullable: true
        description:
          type: string
          nullable: true
        source:
          type: string
          enum:
            - manual_save
            - ai_apply
            - checkpoint
        createdAt:
          type: string
          format: date-time
        matchesCurrentPrompt:
          type: boolean
        preview:
          type: string
      additionalProperties: true
      example:
        _id: 65f9b1c2e8a1d4e001a0b1c3
        version: 4
        label: Friendlier tone
        displayVersion: v1.3
        title: Tone update
        description: Softened the opening line.
        source: manual_save
        createdAt: '2026-04-22T10:14:00.000Z'
        matchesCurrentPrompt: true
        preview: <prompt><role>Leasing assistant</role>...
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````