Create Rate Plan API
Create a rate plan for a room type. The created rate plan is returned with 201 Created.
Authorizations
user-api-keystringRequired
API key for programmatic access, sent in the user-api-key header.
Body
Request body accepted when creating a rate plan.
Responses
201
201 Created response wrapping a resource body.
application/json
JSON:API document wrapping a single resource.
400
The request body could not be parsed as JSON.
application/json
401
Authentication credentials are missing or invalid.
application/json
422
The request has missing or invalid arguments; details lists the messages per argument.
application/json
post/rate_plans
POST /api/v1/rate_plans HTTP/1.1
Host: app.channex.io
user-api-key: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 1112
{
"rate_plan": {
"parent_rate_plan_id": null,
"currency": "GBP",
"meal_type": "none",
"tax_set_id": "4adfa81f-af0a-4b39-834f-1336ab065c08",
"cancellation_policy_id": "5b2c9d1e-3f4a-4b5c-8d6e-7f8a9b0c1d2e",
"ui_read_only": false,
"meta": {
"pms_code": "BAR"
},
"auto_rate_settings": null,
"inherit_rate": false,
"inherit_closed_to_arrival": false,
"inherit_closed_to_departure": false,
"inherit_stop_sell": false,
"inherit_min_stay_arrival": false,
"inherit_min_stay_through": false,
"inherit_max_stay": false,
"inherit_max_availability": false,
"inherit_availability_offset": false,
"children_fee": "0.00",
"infant_fee": "0.00",
"max_stay": [
0,
0,
0,
0,
0,
0,
0
],
"min_stay_arrival": [
1,
1,
1,
1,
1,
1,
1
],
"min_stay_through": [
1,
1,
1,
1,
1,
1,
1
],
"closed_to_arrival": [
false,
false,
false,
false,
false,
false,
false
],
"closed_to_departure": [
false,
false,
false,
false,
false,
false,
false
],
"stop_sell": [
false,
false,
false,
false,
false,
false,
false
],
"title": "Best Available Rate",
"property_id": "716305c4-561a-4561-a187-7f5b8aeb5920",
"room_type_id": "994d1375-dbbd-4072-8724-b2ab32ce781b",
"sell_mode": "per_room",
"rate_mode": "manual",
"options": [
{
"occupancy": 3,
"is_primary": true,
"rate": "100.00"
}
]
}
}{
"data": {
"type": "rate_plan",
"id": "4b7b3c1e-2a3f-4c8d-9e1a-5f6b7c8d9e0f",
"attributes": {
"currency": "GBP",
"meal_type": "none",
"tax_set_id": "4adfa81f-af0a-4b39-834f-1336ab065c08",
"cancellation_policy_id": "5b2c9d1e-3f4a-4b5c-8d6e-7f8a9b0c1d2e",
"ui_read_only": false,
"meta": {
"pms_code": "BAR"
},
"auto_rate_settings": null,
"inherit_rate": false,
"inherit_closed_to_arrival": false,
"inherit_closed_to_departure": false,
"inherit_stop_sell": false,
"inherit_min_stay_arrival": false,
"inherit_min_stay_through": false,
"inherit_max_stay": false,
"inherit_max_availability": false,
"inherit_availability_offset": false,
"children_fee": "0.00",
"infant_fee": "0.00",
"max_stay": [
0,
0,
0,
0,
0,
0,
0
],
"min_stay_arrival": [
1,
1,
1,
1,
1,
1,
1
],
"min_stay_through": [
1,
1,
1,
1,
1,
1,
1
],
"closed_to_arrival": [
false,
false,
false,
false,
false,
false,
false
],
"closed_to_departure": [
false,
false,
false,
false,
false,
false,
false
],
"stop_sell": [
false,
false,
false,
false,
false,
false,
false
],
"id": "4b7b3c1e-2a3f-4c8d-9e1a-5f6b7c8d9e0f",
"title": "Best Available Rate",
"sell_mode": "per_room",
"rate_mode": "manual",
"options": [
{
"inherit_rate": false,
"inherit_closed_to_arrival": false,
"inherit_closed_to_departure": false,
"inherit_stop_sell": false,
"inherit_min_stay_arrival": false,
"inherit_min_stay_through": false,
"inherit_max_stay": false,
"inherit_max_availability": false,
"inherit_availability_offset": false,
"rate_category_id": null,
"id": "4b7b3c1e-2a3f-4c8d-9e1a-5f6b7c8d9e0f",
"occupancy": 3,
"is_primary": true,
"rate": "100.00",
"derived_option": null
}
]
},
"relationships": {
"room_type": {
"data": {
"id": "994d1375-dbbd-4072-8724-b2ab32ce781b",
"type": "room_type"
}
},
"property": {
"data": {
"id": "716305c4-561a-4561-a187-7f5b8aeb5920",
"type": "property"
}
}
}
}
}Last updated