Skip to content

Booking Metrics

POST
/api/analytics/booking/grid
curl --request POST \
--url https://api.wink.travel/api/analytics/booking/grid \
--header 'Content-Type: application/json' \
--header 'Wink-Version: 2.0' \
--data '{ "skip": 0, "take": 30, "sort": "", "filter": "", "group": "" }'

Show paginated analytics.

Wink-Version
string
default: 2.0.0
Allowed values: 2.0
Media type application/json
object
skip

Number of records to be skipped by the pager.

integer format: int32
0
Example
0
take

Number of records to take.

integer format: int32
default: 30 >= 1 <= 180
Example
10
sort

Descriptors used for sorting result set.

Array<object>
""
object
dir

Descriptors used for sorting result set

string
""
Allowed values: asc desc
Example
asc
field

Data set field to sort on

string
""
Example
hotel.name
filter

Descriptors used for filtering result set

object
logic

Whether to filter inclusively or exclusively

string
""
Allowed values: and or
Example
and
filters

Descriptors used for filtering the result set

Array<object>
""
object
field
required

Field name to filter on

string
"" >= 1 characters
Example
hotel.name
operator
required

Filter operator to use on field

string
""
Allowed values: neq eq contains doesnotcontain isnull isnotnull isempty isnotempty startswith endswith gte lte gt lt in nin
Example
startsWith
value

Value to filter dataset against

""
Example
Happy Res
ignoreCase

Make filter comparison case insensitive. Default: Case sensitive

boolean
Example
true
group

Descriptors to group result sets by.

Array<object>
""
object
field

Field to group data set on

string
""
Example
createdDate
dir

Group sort direction

string
""
Allowed values: asc desc
Example
asc
aggregates

Primitive aggregate data points

Array<object>
""
object
field

Field to run aggregate function on

string
""
Example
hotel.bookings
aggregate

Aggregate function

string
""
Allowed values: count sum average min max
Example
count

OK

Media type application/json
object
totalPages
integer format: int32
totalElements
integer format: int64
size
integer format: int32
content
Array<object>
object
identifier

Unique line chart identifier

string format: uuid
""
title

The configuration options for the chart title

object
text
string
legend

The configuration options for the chart legend.

object
data
Array<string>
series

The configuration of the chart series. The series type is determined by the value of the type field. If a type value is missing, the chart renders the type that is specified in seriesDefaults. Some options accept functions as arguments. These arguments are evaluated for each point which is supplied as a parameter. If no value is returned, the chart uses the theme or seriesDefaults values.

Array<object>
""
object
name

The name of the Chart series which is visible in the legend.

string
""
data

The array of data items which represent the series data.

You can set it to:

  • Array of numbers. Supported when the series.type option is set to area, bar, column, donut, pie, line, or waterfall. The Bubble series need arrays of three values—X value, Y value, and Size value—for example, [1, 1, 10]. The Scatter and ScatterLine series need arrays of two values—X value and Y value. The OHLC and Candlestick series need arrays of four values—open, high, low, and close. The RangeBar and RangeArea series need arrays of two values—the from and to value.
Array<number>
""
xAxis
Category axis

The configuration options of the category axis.

object
data

The category names. The Chart creates a category for every item of the array.

Array<string>
""
xaxis
object
data

The category names. The Chart creates a category for every item of the array.

Array<string>
""
number
integer format: int32
numberOfElements
integer format: int32
sort
object
empty
boolean
unsorted
boolean
sorted
boolean
first
boolean
last
boolean
pageable
object
offset
integer format: int64
sort
object
empty
boolean
unsorted
boolean
sorted
boolean
pageSize
integer format: int32
paged
boolean
pageNumber
integer format: int32
unpaged
boolean
empty
boolean
Example
{
"content": [
{
"identifier": "",
"title": "",
"legend": "",
"series": "",
"xAxis": "",
"xaxis": {
"data": ""
}
}
]
}

Bad Request

object
type
string format: uri
title
string
status
integer format: int32
detail
string
instance
string format: uri
properties
object
key
additional properties
Example generated
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"instance": "https://example.com",
"properties": {
"additionalProperty": "example"
}
}

Unauthorized

Media type */*
object
type
string format: uri
title
string
status
integer format: int32
detail
string
instance
string format: uri
properties
object
key
additional properties

Forbidden

Media type */*
object
type
string format: uri
title
string
status
integer format: int32
detail
string
instance
string format: uri
properties
object
key
additional properties

Internal Server Error

object
Example generated
{}