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

# Update training data

> The API does not accept `metadata` in requests.




## OpenAPI

````yaml /api-reference/openapi.json put /training-data/{id}
openapi: 3.1.0
info:
  title: Weav API
  version: 1.0.0
  description: |
    Public API for Weav workspace integrations.
    Base URL is versioned under /v1 and requires bearer token authentication.
    Token abilities are enforced:
    - `external-api:read` for read endpoints
    - `external-api:write` for write endpoints
    - `external-api:write` also grants read access
servers:
  - url: https://api.weav.com/v1
    description: Production
security:
  - bearerAuth: []
tags:
  - name: Agents
  - name: Companies
  - name: Conversations
  - name: Customers
  - name: Messages
  - name: Training Data
  - name: Webhooks
paths:
  /training-data/{id}:
    put:
      tags:
        - Training Data
      summary: Update training data
      description: |
        The API does not accept `metadata` in requests.
      operationId: updateTrainingData
      parameters:
        - $ref: '#/components/parameters/idPath'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TrainingDataUpdateRequest'
      responses:
        '200':
          description: Training data updated
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TrainingData'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
        '422':
          $ref: '#/components/responses/ValidationError'
components:
  parameters:
    idPath:
      name: id
      in: path
      required: true
      schema:
        type: string
        format: uuid
  schemas:
    TrainingDataUpdateRequest:
      type: object
      properties:
        title:
          type: string
          maxLength: 255
        description:
          type: string
          nullable: true
        agent_ids:
          type: array
          items:
            type: string
            format: uuid
          nullable: true
    TrainingData:
      type: object
      properties:
        id:
          type: string
          format: uuid
        type:
          type: string
          enum:
            - text
            - url
            - file
            - video
            - qa
        source:
          type: string
          nullable: true
        title:
          type: string
          nullable: true
        description:
          type: string
          nullable: true
        slug:
          type: string
          nullable: true
        is_processed:
          type: boolean
        status:
          type: string
          enum:
            - queued
            - processing
            - completed
            - failed
          nullable: true
        training_folder_id:
          type: string
          format: uuid
          nullable: true
        created_at:
          type: string
          format: date-time
          nullable: true
        updated_at:
          type: string
          format: date-time
          nullable: true
    Error:
      type: object
      properties:
        error:
          type: string
          example: Error message
        code:
          type: string
          nullable: true
          example: UNAUTHENTICATED
        errors:
          type: object
          additionalProperties: true
          nullable: true
    ValidationError:
      type: object
      properties:
        message:
          type: string
          example: The given data was invalid.
        errors:
          type: object
          additionalProperties:
            type: array
            items:
              type: string
  responses:
    Unauthorized:
      description: Unauthorized
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    NotFound:
      description: Resource not found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    ValidationError:
      description: Validation error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ValidationError'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API Token
      description: |
        Workspace API token.
        Include abilities `external-api:read` and/or `external-api:write`.

````