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

# Set conversation custom metadata

> Stores a custom JSON object on a conversation, replacing any existing metadata, and returns the stored metadata.
The object is also returned as `metadata` when fetching the conversation. The serialized object may be at
most 4 KiB, and objects and arrays may be nested at most 5 levels deep.



## OpenAPI

````yaml https://app.goguava.ai/openapi.json put /v1/conversations/{call_id}/metadata
openapi: 3.1.0
info:
  title: Guava API Server
  version: guava-release-0.51.0
servers:
  - url: https://app.goguava.ai
security: []
paths:
  /v1/conversations/{call_id}/metadata:
    put:
      tags:
        - Calls
      summary: Set conversation custom metadata
      description: >-
        Stores a custom JSON object on a conversation, replacing any existing
        metadata, and returns the stored metadata.

        The object is also returned as `metadata` when fetching the
        conversation. The serialized object may be at

        most 4 KiB, and objects and arrays may be nested at most 5 levels deep.
      operationId: >-
        api_put_conversation_user_metadata_v1_conversations__call_id__metadata_put
      parameters:
        - name: call_id
          in: path
          required: true
          schema:
            type: string
            description: ID of the call to attach metadata to.
            title: Call Id
          description: ID of the call to attach metadata to.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              additionalProperties: true
              description: An arbitrary JSON object.
              title: Metadata
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UserMetadataResponse'
        '400':
          description: >-
            Metadata is nested more than 5 levels deep, or contains NaN or
            Infinity.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '401':
          description: Missing or invalid credentials.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: Conversation not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '413':
          description: Metadata exceeds 4 KiB when serialized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - APIKey: []
components:
  schemas:
    UserMetadataResponse:
      properties:
        metadata:
          additionalProperties: true
          type: object
          title: Metadata
      type: object
      required:
        - metadata
      title: UserMetadataResponse
    ErrorResponse:
      properties:
        detail:
          type: string
          title: Detail
      type: object
      required:
        - detail
      title: ErrorResponse
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    APIKey:
      type: http
      description: 'A Guava API key, sent as `Authorization: Bearer <key>`.'
      scheme: bearer

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.