{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/salesforce-commerce-cloud/json-schema/salesforce-commerce-cloud-promotion-result-schema.json",
  "title": "PromotionResult",
  "description": "Result document containing an array of promotions.",
  "x-generated": "2026-11-25",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/salesforce-commerce-cloud-shopper-promotions-api-openapi.yml#/components/schemas/PromotionResult",
  "required": [
    "data"
  ],
  "type": "object",
  "allOf": [
    {
      "$ref": "#/$defs/ResultBase"
    }
  ],
  "properties": {
    "data": {
      "description": "The array of promotion documents.",
      "type": "array",
      "items": {
        "$ref": "#/$defs/Promotion"
      }
    }
  },
  "additionalProperties": false,
  "$defs": {
    "Promotion": {
      "description": "Document representing a promotion.",
      "additionalProperties": {
        "title": "Additional Property Support",
        "description": "This type supports additional properties passed along with the defined properties of this API.\nTo indicate that the properties were defined and expected to be handled as additional properties, they are expected to be prefixed with a `c_`.\nThe type will reject any property that does not fit this pattern, only allowing additional properties beginning with the known prefix."
      },
      "type": "object",
      "required": [
        "id"
      ],
      "properties": {
        "calloutMsg": {
          "description": "The localized call-out message of the promotion.",
          "type": "string"
        },
        "currency": {
          "description": "The currency that a promotion can be applied to. A null value means that the promotion applies to all allowed\n currencies.",
          "type": "string"
        },
        "details": {
          "description": "The localized detailed description of the promotion.",
          "type": "string"
        },
        "endDate": {
          "description": "The end date of the promotion. This property follows the ISO8601 date time format: yyyy-MM-dd'T'HH:mmZ . The time\n zone of the date time is always UTC.",
          "type": "string",
          "format": "date-time"
        },
        "id": {
          "description": "The unique ID of the promotion.",
          "type": "string"
        },
        "image": {
          "description": "The URL to the promotion image.",
          "type": "string"
        },
        "name": {
          "description": "The localized name of the promotion.",
          "type": "string"
        },
        "startDate": {
          "description": "The start date of the promotion. This property follows the ISO8601 date time format: yyyy-MM-dd'T'HH:mmZ. The\n time zone of the date time is always UTC.",
          "type": "string",
          "format": "date-time"
        }
      }
    },
    "ResultBase": {
      "description": "Schema defining generic list result. Each response schema of a resource requiring a list response should extend this schema. \nAdditionally it needs to be defined what data is returned.",
      "type": "object",
      "required": [
        "limit",
        "total"
      ],
      "properties": {
        "limit": {
          "format": "int32",
          "description": "Maximum records to retrieve per request. The limit with its constraints (minimum, maximum, default) is defined by the request parameter `limit` of the endpoint returning this schema.",
          "type": "integer"
        },
        "total": {
          "$ref": "#/$defs/Total"
        }
      }
    },
    "Total": {
      "default": 0,
      "minimum": 0,
      "format": "int32",
      "description": "The total number of hits that match the search's criteria. This can be greater than the number of results returned as search results are pagenated.",
      "type": "integer"
    }
  }
}