▪ Saturation Series

Saturation Series API returns a time-based accommodation occupancy data series for the selected POI, grouped by a time period.
Request
Endpoint
GET
/v4/{billing_plan}/account/{account_id}/poi/{poi_id}/rates/saturation/series
Path Parameters
Name |
Description |
Type |
Examples |
*{billing_plan} |
Billing plan to be applied to the call. |
string |
licence ondemand |
*{account_id} |
Provided identifier of the account. |
string |
|
*{poi_id} |
Identifier of the POI to retrieve data for. Value obtainable either : - if {billing_plan} = licence, from $.results[*].resource.id field of List Licences Response Body - if {billing_plan} = ondemand, from $.results.pois[*].id field of any Search API Response Body. |
string |
XXeUNbmtYZTsH7UGvNfXWo |
Name |
Description |
Type |
Examples |
*x-api-key |
Provided API key {x_api_key} that allows authentication. |
string |
|
*Authorization |
Provided token {jwt_bearer} that allows authorization. |
string |
Bearer {jwt_bearer} |
Query Parameters
Name |
Description |
Type |
Examples |
*from |
Start date of timeframe. |
date |
2020-01-01 |
*to |
End date of timeframe. |
date |
2020-12-31 |
*period |
Time unit of the series. |
string |
dayweekmonth |
refundable |
Filter by offers refundability. |
boolean |
|
breakfast_included |
Filter by breakfast inclusion in offers. |
boolean |
|
lunch_included |
Filter by lunch inclusion in offers. |
boolean |
|
dinner_included |
Filter by dinner inclusion in offers. |
boolean |
|
ⓝ number_of_guests |
Filter by allowed number of guests. |
int |
|
Supported values for period
Example
curl -X GET 'https://api.datappeal.io/v4/licence/account/{account_id}/poi/HF8xjSQW4W43NGr56denSh/rates/saturation/series?from=2021-07-01&to=2021-07-31&period=week' \
-H 'x-api-key: {x_api_key}' \
-H 'Authorization: Bearer {jwt_bearer}' \
Response
Status
Status |
Description |
200 |
Saturation Series data has been successfully returned. |
Body
SeriesSaturation
Field |
Description |
Type |
series |
Saturation Series data for the requested timeframe and period. |
array[SeriesSaturationElement] |
SeriesSaturationElement
Field |
Description |
Type |
*period |
Date representing the requested period, corresponding to the first day of the period.
day : the day itself.
week : first day of the corresponding week.
month : first day of the corresponding month. |
date |
*value |
Saturation data for the corresponding period . |
Saturation |
Saturation
Field |
Description |
Type |
Examples |
*total_offers |
Total number of accommodation offers. |
int |
1106 |
*available_offers |
Number of available accommodation offers. |
int |
729 |
*saturation |
Occupancy ratio in the range [0,100] calculated by the following formula.
 |
decimal |
34.09 |
Example
{
"series": [
{
"period": "2021-07-05",
"value": {
"total_offers": 1106,
"available_offers": 729,
"saturation": 34.09
}
},
{
"period": "2021-07-12",
"value": {
"total_offers": 935,
"available_offers": 500,
"saturation": 46.52
}
},
{
"period": "2021-07-19",
"value": {
"total_offers": 1011,
"available_offers": 530,
"saturation": 47.58
}
},
{
"period": "2021-07-26",
"value": {
"total_offers": 841,
"available_offers": 485,
"saturation": 42.33
}
}
]
}