{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/nice/json-schema/nice-get-custom-card-response-schema.json",
  "title": "GetCustomCardResponse",
  "description": "The custom cards stored for an interaction.",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/nice-realtimeinsights-openapi.yml#/components/schemas/GetCustomCardResponse",
  "required": [
    "cards",
    "timestamp"
  ],
  "type": "object",
  "properties": {
    "timestamp": {
      "type": "string",
      "description": "Server timestamp of the response (UTC).",
      "format": "date-time"
    },
    "cards": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "$ref": "#/$defs/CustomCardDataItem"
      },
      "description": "The custom cards associated with the interaction."
    }
  },
  "additionalProperties": false,
  "$defs": {
    "CustomCardDataItem": {
      "required": [
        "text",
        "type",
        "uid"
      ],
      "type": "object",
      "properties": {
        "timestamp": {
          "type": "string",
          "description": "Timestamp when the card was created or last updated (UTC).",
          "format": "date-time"
        },
        "uid": {
          "type": [
            "string",
            "null"
          ],
          "description": "Unique identifier of the card."
        },
        "type": {
          "type": [
            "string",
            "null"
          ],
          "description": "Card type discriminator."
        },
        "title": {
          "type": [
            "string",
            "null"
          ],
          "description": "Card title shown to the agent."
        },
        "text": {
          "type": [
            "string",
            "null"
          ],
          "description": "Card body text."
        },
        "links": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "$ref": "#/$defs/CustomCardLinkData"
          },
          "description": "Links displayed on the card."
        },
        "images": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "$ref": "#/$defs/CustomCardImageData"
          },
          "description": "Images displayed on the card."
        },
        "icon": {
          "type": [
            "string",
            "null"
          ],
          "description": "Icon identifier or URL shown on the card."
        },
        "backgroundColor": {
          "type": [
            "string",
            "null"
          ],
          "description": "Background color of the card, as a hex color code."
        },
        "actions": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "type": "string"
          },
          "description": "Action identifiers available on the card."
        }
      },
      "additionalProperties": false,
      "description": "A stored custom card and its content."
    },
    "CustomCardImageData": {
      "required": [
        "url"
      ],
      "type": "object",
      "properties": {
        "title": {
          "type": [
            "string",
            "null"
          ],
          "description": "Image title or alt text."
        },
        "url": {
          "type": [
            "string",
            "null"
          ],
          "description": "Full-size image URL."
        },
        "thumbUrl": {
          "type": [
            "string",
            "null"
          ],
          "description": "Thumbnail image URL."
        }
      },
      "additionalProperties": false,
      "description": "An image stored on a custom card."
    },
    "CustomCardLinkData": {
      "required": [
        "title",
        "url"
      ],
      "type": "object",
      "properties": {
        "title": {
          "type": [
            "string",
            "null"
          ],
          "description": "Display text for the link."
        },
        "url": {
          "type": [
            "string",
            "null"
          ],
          "description": "Target URL of the link."
        }
      },
      "additionalProperties": false,
      "description": "A hyperlink stored on a custom card."
    }
  }
}