For the complete documentation index, see llms.txt. This page is also available as Markdown.

Update Rate Plan API

Update a rate plan

put
/rate_plans/{id}

Update a rate plan by its identifier. Attributes absent from the request are left unchanged. The updated rate plan is returned.

Authorizations
user-api-keystringRequired

API key for programmatic access, sent in the user-api-key header.

Path parameters
idstring Β· uuidRequiredExample: 716305c4-561a-4561-a187-7f5b8aeb5920
Body

Request body accepted when updating a rate plan.

Responses
200

The request has succeeded.

application/json

JSON:API document wrapping a single resource.

put/rate_plans/{id}
PUT /api/v1/rate_plans/{id} HTTP/1.1
Host: app.channex.io
user-api-key: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 1137

{
  "rate_plan": {
    "title": "Best Available Rate",
    "sell_mode": "per_room",
    "rate_mode": "manual",
    "currency": "USD",
    "meal_type": "none",
    "tax_set_id": "716305c4-561a-4561-a187-7f5b8aeb5920",
    "cancellation_policy_id": "716305c4-561a-4561-a187-7f5b8aeb5920",
    "ui_read_only": true,
    "meta": {},
    "inherit_rate": true,
    "inherit_closed_to_arrival": true,
    "inherit_closed_to_departure": true,
    "inherit_stop_sell": true,
    "inherit_min_stay_arrival": true,
    "inherit_min_stay_through": true,
    "inherit_max_stay": true,
    "inherit_max_availability": true,
    "inherit_availability_offset": true,
    "property_id": "716305c4-561a-4561-a187-7f5b8aeb5920",
    "room_type_id": "716305c4-561a-4561-a187-7f5b8aeb5920",
    "parent_rate_plan_id": "716305c4-561a-4561-a187-7f5b8aeb5920",
    "options": [
      {
        "occupancy": 3,
        "is_primary": true,
        "derived_option": {
          "rate": [
            [
              "increase_by_percent",
              "5.00"
            ],
            [
              "increase_by_amount",
              "12.00"
            ]
          ]
        },
        "rate": "100.00"
      }
    ],
    "auto_rate_settings": {
      "increase_mode": "$",
      "decrease_mode": "$",
      "increase_value": "10.00",
      "decrease_value": "5.00"
    },
    "children_fee": "0.00",
    "infant_fee": "0.00",
    "max_stay": 1,
    "min_stay_arrival": 1,
    "min_stay_through": 1,
    "closed_to_arrival": true,
    "closed_to_departure": true,
    "stop_sell": true
  }
}
{
  "data": {
    "type": "rate_plan",
    "id": "716305c4-561a-4561-a187-7f5b8aeb5920",
    "attributes": {
      "id": "bab451e7-9ab1-4cc4-aa16-107bf7bbabb2",
      "title": "Best Available Rate",
      "sell_mode": "per_room",
      "rate_mode": "manual",
      "currency": "USD",
      "meal_type": "none",
      "tax_set_id": "716305c4-561a-4561-a187-7f5b8aeb5920",
      "cancellation_policy_id": "716305c4-561a-4561-a187-7f5b8aeb5920",
      "ui_read_only": true,
      "meta": {},
      "inherit_rate": true,
      "inherit_closed_to_arrival": true,
      "inherit_closed_to_departure": true,
      "inherit_stop_sell": true,
      "inherit_min_stay_arrival": true,
      "inherit_min_stay_through": true,
      "inherit_max_stay": true,
      "inherit_max_availability": true,
      "inherit_availability_offset": true,
      "options": [
        {
          "id": "716305c4-561a-4561-a187-7f5b8aeb5920",
          "occupancy": 3,
          "is_primary": true,
          "inherit_rate": true,
          "inherit_closed_to_arrival": true,
          "inherit_closed_to_departure": true,
          "inherit_stop_sell": true,
          "inherit_min_stay_arrival": true,
          "inherit_min_stay_through": true,
          "inherit_max_stay": true,
          "inherit_max_availability": true,
          "inherit_availability_offset": true,
          "derived_option": {
            "rate": [
              [
                "increase_by_percent",
                "5.00"
              ],
              [
                "increase_by_amount",
                "12.00"
              ]
            ]
          },
          "rate_category_id": "716305c4-561a-4561-a187-7f5b8aeb5920",
          "rate": "100.00"
        }
      ],
      "auto_rate_settings": {
        "increase_mode": "$",
        "decrease_mode": "$",
        "increase_value": "10.00",
        "decrease_value": "5.00"
      },
      "children_fee": "0.00",
      "infant_fee": "0.00",
      "max_stay": [
        1
      ],
      "min_stay_arrival": [
        1
      ],
      "min_stay_through": [
        1
      ],
      "closed_to_arrival": [
        true
      ],
      "closed_to_departure": [
        true
      ],
      "stop_sell": [
        true
      ]
    },
    "relationships": {
      "room_type": {
        "data": {
          "id": "716305c4-561a-4561-a187-7f5b8aeb5920",
          "type": "room_type"
        }
      },
      "property": {
        "data": {
          "id": "716305c4-561a-4561-a187-7f5b8aeb5920",
          "type": "property"
        }
      },
      "tax_set": {
        "data": {
          "id": "716305c4-561a-4561-a187-7f5b8aeb5920",
          "type": "tax_set",
          "attributes": {
            "id": "716305c4-561a-4561-a187-7f5b8aeb5920",
            "title": "text"
          }
        }
      },
      "parent_rate_plan": {
        "data": {
          "id": "716305c4-561a-4561-a187-7f5b8aeb5920",
          "type": "rate_plan"
        }
      },
      "channel": {
        "data": {
          "id": "716305c4-561a-4561-a187-7f5b8aeb5920",
          "type": "channel"
        }
      }
    }
  }
}

Last updated