{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/upsellguru/json-schema/upsellguru-basic-extra-type-schema.json",
  "title": "BasicExtraType",
  "x-generated": "2026-11-17",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/upsellguru-openapi.yml#/components/schemas/BasicExtraType",
  "type": "object",
  "properties": {
    "status": {
      "$ref": "#/$defs/ExtraTypeStatus"
    },
    "code": {
      "type": "string"
    },
    "pmsTransactionCode": {
      "type": "string"
    },
    "otherPmsCodes": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "billingRule": {
      "$ref": "#/$defs/ExtraTypeBillingRule"
    },
    "salesType": {
      "$ref": "#/$defs/ExtraTypeSalesType"
    },
    "category": {
      "$ref": "#/$defs/ExtraTypeCategory"
    },
    "names": {
      "$ref": "#/$defs/LocalizedStringsMap"
    },
    "descriptions": {
      "$ref": "#/$defs/LocalizedStringsMap"
    },
    "position": {
      "type": "integer"
    },
    "price": {
      "$ref": "#/$defs/Money"
    },
    "strikePrice": {
      "$ref": "#/$defs/Money"
    },
    "taxes": {
      "$ref": "#/$defs/Money"
    },
    "serviceFee": {
      "$ref": "#/$defs/Money"
    },
    "pointOfSale": {
      "$ref": "#/$defs/ExtraTypePointOfSale"
    },
    "cutOffDays": {
      "type": "integer"
    },
    "cutOffHour": {
      "type": "integer",
      "minimum": 0,
      "maximum": 23
    },
    "excludedDates": {
      "type": "array",
      "items": {
        "format": "date"
      }
    },
    "availableDates": {
      "type": "array",
      "items": {
        "format": "date"
      }
    },
    "losFrom": {
      "type": "integer"
    },
    "losTo": {
      "type": "integer"
    },
    "excludedRatePlans": {
      "type": "array",
      "items": {
        "format": "string"
      }
    },
    "allowedRatePlans": {
      "type": "array",
      "items": {
        "format": "string"
      }
    },
    "excludedMarketSegments": {
      "type": "array",
      "items": {
        "format": "string"
      }
    },
    "allowedMarketSegments": {
      "type": "array",
      "items": {
        "format": "string"
      }
    },
    "excludedReservationSources": {
      "type": "array",
      "items": {
        "format": "string"
      }
    },
    "allowedReservationSources": {
      "type": "array",
      "items": {
        "format": "string"
      }
    },
    "excludedMembershipLevels": {
      "type": "array",
      "items": {
        "format": "string"
      }
    },
    "allowedMembershipLevels": {
      "type": "array",
      "items": {
        "format": "string"
      }
    },
    "offeredDays": {
      "$ref": "#/$defs/ExtraTypeOfferedDays"
    },
    "offeredDaysType": {
      "$ref": "#/$defs/ExtraTypeOfferedDaysType"
    },
    "dayTimeConfirmation": {
      "$ref": "#/$defs/ExtraTypeDayTimeConfirmation"
    },
    "dayTimeConfirmationSchedule": {
      "$ref": "#/$defs/ExtraTypeDayTimeConfirmationSchedule"
    },
    "customQuestion": {
      "type": "string"
    },
    "isPurchasingMultipleVariationsAllowed": {
      "type": "boolean"
    }
  },
  "$defs": {
    "ExtraTypeBillingRule": {
      "type": "string",
      "enum": [
        "PERSON",
        "DAY_PERSON",
        "DAY",
        "UNIT",
        "RESERVATION"
      ]
    },
    "ExtraTypeCategory": {
      "type": "string",
      "enum": [
        "F_AND_B",
        "F_AND_B_BREAKFAST",
        "F_AND_B_DINNER",
        "EXTENDED_STAY",
        "EXTENDED_STAY_ECI",
        "EXTENDED_STAY_LCO",
        "SPA",
        "ACTIVITIES",
        "TRANSPORTATION",
        "ROOM_AMENITIES",
        "PACKAGES",
        "CLUB_BENEFITS",
        "LOYALTY"
      ]
    },
    "ExtraTypeDayTimeConfirmation": {
      "type": "string",
      "enum": [
        "NOT_REQUIRED",
        "ANY_TIME",
        "SPECIFIC_HOURS"
      ]
    },
    "ExtraTypeDayTimeConfirmationSchedule": {
      "type": "object",
      "properties": {
        "hoursFrom": {
          "type": "integer"
        },
        "hoursTo": {
          "type": "integer"
        },
        "minutesFrom": {
          "type": "integer"
        },
        "minutesTo": {
          "type": "integer"
        }
      }
    },
    "ExtraTypeOfferedDays": {
      "type": "object",
      "properties": {
        "mon": {
          "type": "boolean"
        },
        "tue": {
          "type": "boolean"
        },
        "wed": {
          "type": "boolean"
        },
        "thu": {
          "type": "boolean"
        },
        "fri": {
          "type": "boolean"
        },
        "sat": {
          "type": "boolean"
        },
        "sun": {
          "type": "boolean"
        }
      }
    },
    "ExtraTypeOfferedDaysType": {
      "type": "string",
      "enum": [
        "CHECKIN",
        "STAY",
        "CHECKOUT"
      ]
    },
    "ExtraTypePointOfSale": {
      "type": "string",
      "enum": [
        "ALL",
        "PRESTAY_ONLY",
        "INHOUSE_ONLY"
      ]
    },
    "ExtraTypeSalesType": {
      "type": "string",
      "enum": [
        "INSTANT_CONFIRMATION",
        "BIDDING",
        "ON_REQUEST"
      ]
    },
    "ExtraTypeStatus": {
      "type": "string",
      "description": "This enum describes all possible status an extra type can be in UpsellGuru",
      "enum": [
        "ONLINE",
        "OFFLINE",
        "DELETED"
      ]
    },
    "LocalizedStringsMap": {
      "type": "object",
      "additionalProperties": {
        "type": "string"
      }
    },
    "Money": {
      "type": "object",
      "properties": {
        "amount": {
          "type": "number",
          "format": "float"
        },
        "currency": {
          "type": "string"
        }
      },
      "required": [
        "amount",
        "currency"
      ]
    }
  }
}