{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/compteam-io/json-schema/compteam-io-offering-update-schema.json",
  "title": "OfferingUpdate",
  "x-generated": "2026-11-04",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/compteam-io-openapi.yml#/components/schemas/OfferingUpdate",
  "properties": {
    "discipline": {
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "bjj",
            "luta_livre",
            "taekwondo",
            "karate",
            "muay_thai",
            "sambo",
            "kickboxing",
            "judo",
            "aikido",
            "mma"
          ]
        },
        {
          "type": "null"
        }
      ],
      "title": "Discipline"
    },
    "title": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Title"
    },
    "description": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Description"
    },
    "price_amount": {
      "anyOf": [
        {
          "type": "number"
        },
        {
          "type": "null"
        }
      ],
      "title": "Price Amount"
    },
    "currency": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Currency"
    },
    "stripe_price_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Stripe Price Id"
    },
    "purchase_order_item_id": {
      "anyOf": [
        {
          "type": "string",
          "format": "uuid"
        },
        {
          "type": "null"
        }
      ],
      "title": "Purchase Order Item Id"
    },
    "scheduled_at": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Scheduled At"
    },
    "duration_min": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Duration Min"
    },
    "sessions": {
      "anyOf": [
        {
          "items": {
            "$ref": "#/$defs/OfferingSession"
          },
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Sessions"
    },
    "location_id": {
      "anyOf": [
        {
          "type": "string",
          "format": "uuid"
        },
        {
          "type": "null"
        }
      ],
      "title": "Location Id"
    },
    "location_text": {
      "anyOf": [
        {
          "type": "string",
          "maxLength": 500
        },
        {
          "type": "null"
        }
      ],
      "title": "Location Text"
    },
    "capacity": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Capacity"
    },
    "is_active": {
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "null"
        }
      ],
      "title": "Is Active"
    },
    "rrule": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Rrule"
    },
    "dtstart_date": {
      "anyOf": [
        {
          "type": "string",
          "format": "date"
        },
        {
          "type": "null"
        }
      ],
      "title": "Dtstart Date"
    },
    "until_date": {
      "anyOf": [
        {
          "type": "string",
          "format": "date"
        },
        {
          "type": "null"
        }
      ],
      "title": "Until Date"
    },
    "start_time": {
      "anyOf": [
        {
          "type": "string",
          "format": "time"
        },
        {
          "type": "null"
        }
      ],
      "title": "Start Time"
    },
    "is_organization_wide": {
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "null"
        }
      ],
      "title": "Is Organization Wide"
    },
    "visitor_billing_mode": {
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "home_branch_invoice",
            "host_branch_invoice"
          ]
        },
        {
          "type": "null"
        }
      ],
      "title": "Visitor Billing Mode"
    },
    "host_invoice_payment_method": {
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "manual",
            "stripe"
          ]
        },
        {
          "type": "null"
        }
      ],
      "title": "Host Invoice Payment Method"
    },
    "home_branch_commission_pct": {
      "anyOf": [
        {
          "type": "number",
          "maximum": 100.0,
          "minimum": 0.0
        },
        {
          "type": "null"
        }
      ],
      "title": "Home Branch Commission Pct"
    }
  },
  "type": "object",
  "$defs": {
    "OfferingSession": {
      "properties": {
        "scheduled_at": {
          "type": "string",
          "format": "date-time",
          "title": "Scheduled At"
        },
        "duration_min": {
          "type": "integer",
          "exclusiveMinimum": 0.0,
          "title": "Duration Min"
        }
      },
      "type": "object",
      "required": [
        "scheduled_at",
        "duration_min"
      ],
      "title": "OfferingSession"
    }
  }
}