{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/hoplix-com/json-schema/hoplix-com-campaign-input-schema.json",
  "title": "CampaignInput",
  "x-generated": "2026-11-05",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/_original/hoplix-com-v1-openapi.json#/components/schemas/CampaignInput",
  "type": "object",
  "required": [
    "name",
    "product-code",
    "product-color",
    "product-price"
  ],
  "properties": {
    "name": {
      "type": "string"
    },
    "description": {
      "type": "string"
    },
    "url": {
      "type": "string",
      "description": "Slug of the public page; letters, digits and hyphens, must be unused"
    },
    "private": {
      "type": "string",
      "description": "y = private campaign, n = public",
      "enum": [
        "y",
        "n"
      ]
    },
    "oneshot": {
      "type": "string",
      "description": "on = deleted 90 days after creation"
    },
    "campaign-duration": {
      "type": "string",
      "description": "End date yyyy-mm-dd hh:ii:ss, or 0 for no end"
    },
    "front": {
      "type": "string",
      "description": "URL of the front design (PNG or JPG)"
    },
    "back": {
      "type": "string",
      "description": "URL of the back design"
    },
    "insidelabel": {
      "type": "string",
      "description": "URL of the inside label design"
    },
    "currency": {
      "type": "string",
      "enum": [
        "EUR"
      ]
    },
    "product-code": {
      "type": "string",
      "description": "Main product"
    },
    "product-color": {
      "type": "string",
      "description": "Comma-separated colors of the main product"
    },
    "product-price": {
      "type": "string",
      "description": "Selling price, greater than the base cost"
    },
    "additional-product": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "product-code": {
            "type": "string"
          },
          "product-color": {
            "type": "string"
          },
          "product-price": {
            "type": "string"
          }
        }
      }
    }
  }
}