Packages

Add an option to a package item choice

Adds a new PackageItemChoiceOption to the parent PackageItemChoice. The body sets the offering the option points at and any price uplift; the option is appended to the choice's existing list.

Requires the SETTINGS_MANAGE permission on the package's site.

post/shop/packages/{packageId}/item-choices/{itemChoiceId}/options

Request body

idstring required

Identifier of the offering this option points at — an AppointmentType, SessionType or retail Product, depending on item_type. The guest sees the offering's name and image when picking this option in the storefront.

item_typestring required

The type of item this option represents.

price_changeinteger nullable required

A currency amount that this option would increase the package price by.

Example request

{
  "id": "5dcb47800000000000000026",
  "item_type": "appointment",
  "offering": {
    "id": "5e932c0901d210625e3a8766",
    "categories": [
      {
        "id": "5e932c0901d210625e3a8766",
        "name": "Massage"
      }
    ],
    "currency": "gbp",
    "description": "Choose from classic, deep tissue and Swedish massage",
    "discounted_price_from": 4500,
    "duration": 30,
    "durations": [
      30
    ],
    "has_availability": true,
    "image": {
      "file_name": "super-cool-photo.jpg",
      "mime_type": "image/jpeg",
      "original_url": "https://example.com/media/super-cool-photo.jpg",
      "size": 84256,
      "url": "https://example.com/media/super-cool-photo-thumbnail@2x.jpg"
    },
    "max_guests": 2,
    "min_guests": 2,
    "name": "60 minute massage",
    "price_from": 5000,
    "price_to": 6500,
    "type": "appointment"
  },
  "price_change": 2000
}

Response

A single PackageItemChoiceOption.

Example response

{
  "data": {
    "id": "5dcb47800000000000000026",
    "item_type": "appointment",
    "offering": {
      "id": "5e932c0901d210625e3a8766",
      "categories": [
        {
          "id": "5e932c0901d210625e3a8766",
          "name": "Massage"
        }
      ],
      "currency": "gbp",
      "description": "Choose from classic, deep tissue and Swedish massage",
      "discounted_price_from": 4500,
      "duration": 30,
      "durations": [
        30
      ],
      "has_availability": true,
      "image": {
        "file_name": "super-cool-photo.jpg",
        "mime_type": "image/jpeg",
        "original_url": "https://example.com/media/super-cool-photo.jpg",
        "size": 84256,
        "url": "https://example.com/media/super-cool-photo-thumbnail@2x.jpg"
      },
      "max_guests": 2,
      "min_guests": 2,
      "name": "60 minute massage",
      "price_from": 5000,
      "price_to": 6500,
      "type": "appointment"
    },
    "price_change": 2000
  }
}

Changes

No recorded changes to this endpoint across all 1 revision of this API.