{
  "$id": "https://example.com/ClientConsentAddedV1.json",
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "ClientConsentAddedV1",
  "description": "A domain event published when consent is recorded for a client.",
  "type": "object",
  "properties": {
    "metadata": {
      "type": "object",
      "properties": {
        "createdAtUTC": {
          "type": "string",
          "description": "The date and time when the event was created in UTC. Date should be represented in ISO 8601 format, for example 2023-09-08T12:00:00Z."
        },
        "typeName": {
          "type": "string",
          "description": "The name of the event. For example ClientConsentAddedV1."
        },
        "source": {
          "type": "string",
          "description": "The source application or service that generated the event. For example Sales API."
        },
        "version": {
          "type": "number",
          "description": "Version number for the event."
        }
      },
      "required": [
        "createdAtUTC",
        "typeName",
        "version"
      ]
    },
    "data": {
      "type": "object",
      "properties": {
        "clientId": {
          "type": "string",
          "description": "The GUID of the client whose consent has been recorded."
        },
        "termsAccepted": {
          "type": "boolean",
          "description": "Indicates that the client has accepted the applicable Terms & Conditions."
        },
        "piplConsentSensitiveData": {
          "type": "boolean",
          "description": "Indicates that the client has consented to the processing of sensitive personal information under China’s Personal Information Protection Law."
        },
        "piplConsentCrossBorderTransfer": {
          "type": "boolean",
          "description": "Indicates that the client has consented to the transfer of personal information outside China under China’s Personal Information Protection Law."
        }
      },
      "required": [
        "clientId"
      ]
    }
  }
}