{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/asapp3/json-schema/asapp3-conversation-schema.json",
  "title": "Conversation",
  "description": "Represents a conversation between an agent and a customer.",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/asapp3-conversations-api-openapi.yml#/components/schemas/Conversation",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "The unique identifier for the conversation within the ASAPP system."
    },
    "externalId": {
      "type": "string",
      "description": "The unique identifier for the conversation in your external chat or voice system."
    },
    "agent": {
      "type": "object",
      "description": "Information about the agent participating in the conversation.",
      "properties": {
        "externalId": {
          "type": "string",
          "description": "The unique identifier for the agent in your external system."
        },
        "name": {
          "type": "string",
          "description": "The display name of the agent."
        }
      },
      "required": [
        "externalId"
      ]
    },
    "customer": {
      "type": "object",
      "description": "Information about the customer participating in the conversation.",
      "properties": {
        "externalId": {
          "type": "string",
          "description": "The unique identifier for the customer in your external system."
        },
        "name": {
          "type": "string",
          "description": "The display name of the customer."
        }
      },
      "required": [
        "externalId"
      ]
    },
    "metadata": {
      "type": "object",
      "additionalProperties": {
        "type": "string"
      },
      "description": "Additional key-value pairs to store custom metadata about the conversation. Use this for filtering or categorization purposes."
    }
  },
  "required": [
    "externalId",
    "customer"
  ]
}