Skip to content

Browse

POST
/api/managing-entity/{managingEntityIdentifier}/extranet/sales/affiliate/grid
curl --request POST \
--url https://api.wink.travel/api/managing-entity/d5b8a3c2-9e6f-4a1b-8d34-7c2e1f0a5b69/extranet/sales/affiliate/grid \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Wink-Version: 2.0' \
--data null

Return a page of affiliates with their sales metrics for the given account, filtered by the supplied grid criteria.

managingEntityIdentifier
required
string
""

Managing entity identifier (UUID)

Example
d5b8a3c2-9e6f-4a1b-8d34-7c2e1f0a5b69
Wink-Version
string
default: 2.0.0
Allowed values: 2.0

Grid state including pagination, sort and filter criteria for the affiliate sales results

Media type application/json

Pagination, sorting, filtering, and grouping state used to query a paged result set.

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>
""

Descriptor that defines the sort direction and field for ordering a result set.

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
Example
{
"dir": "asc",
"field": "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>

A single field-level filter criterion that specifies what to match and how to compare it.

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
Example
{
"field": "hotel.name",
"operator": "startsWith",
"value": "Happy Res",
"ignoreCase": true
}
Example
{
"logic": "and",
"filters": [
{
"field": "hotel.name",
"operator": "startsWith",
"value": "Happy Res",
"ignoreCase": true
}
]
}
group

Descriptors to group result sets by.

Array<object>
""

Descriptor that defines how a result set should be grouped, including sort direction and optional aggregate calculations.

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>

Descriptor that defines an aggregate function to apply to a specific field in a grouped result set.

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
Example
{
"field": "hotel.bookings",
"aggregate": "count"
}
Example
{
"field": "createdDate",
"dir": "asc",
"aggregates": [
{
"field": "hotel.bookings",
"aggregate": "count"
}
]
}
Example
{
"skip": 0,
"take": 10,
"sort": [
{
"dir": "asc",
"field": "hotel.name"
}
],
"filter": {
"logic": "and",
"filters": [
{
"field": "hotel.name",
"operator": "startsWith",
"value": "Happy Res",
"ignoreCase": true
}
]
},
"group": [
{
"field": "createdDate",
"dir": "asc",
"aggregates": [
{
"field": "hotel.bookings",
"aggregate": "count"
}
]
}
]
}

Paginated affiliates with sales metrics for the given account. Pagination metadata (total, page, size) is in the Page wrapper.

Media type application/json

Booking sales metrics for a managing entity, enriched with company profile data including location, image, and online presence.

object
ownerIdentifier

The company ID.

string format: uuid
""
type

The company type

string
""
Allowed values: TRIP_PAY FACILITATOR DIRECT APPLICATION HOTEL TRAVELIKO CORPORATE TRAVEL_AGENT INFLUENCER BLOGGER DESTINATION CHANNEL_MANAGER PROPERTY_MANAGEMENT_SYSTEM CENTRAL_RESERVATION_SYSTEM GOOGLE_HOTEL_API MANAGEMENT_COMPANY CHAIN BRAND EVENT_ORGANIZER OTHER
ownerName

The company name

string
""
urlName

The company url slug

string
"" /^[a-z0-9][a-z0-9-]*[a-z0-9]$/
continent

The company continent

string
""
country

The company country

string
""
countryGeoNameId

The company country geo name ID

string
""
city

The company city

string
""
cityGeoNameId

The company city geo name ID

string
""
ownerImageId

The company image ID

string format: uuid
""
description

Short description or bio of the managing entity.

string
""
onlinePresence
Array<object>

Online presence of account.

object
type
required

List of all active accounts that could be used for selling or seeing a company’s reach.

string
""
Allowed values: WINK WEB_SITE PERSONAL_WEB_SITE CORPORATE_WEB_SITE FACEBOOK INSTAGRAM TWITTER_X LINKEDIN TIKTOK SNAPCHAT MASTODON THREADS HIVE_SOCIAL MEWE ELLO WHATSAPP TELEGRAM SIGNAL WECHAT LINE KAKAOTALK VIBER DISCORD SKYPE FACEBOOK_MESSENGER YOUTUBE TWITCH BILIBILI VIMEO DAILYMOTION KICK UPLIVE PINTEREST BEREAL VSCO IMGUR FLICKR FIVE_HUNDRED_PX REDDIT QUORA TUMBLR PLURK MEDIUM BLUESKY MINDS STEEMIT DIASPORA WHISPER YIK_YAK TELLONYM GOOGLE GITHUB SPOTIFY UPWORK SHOPIFY AMAZON PERSONAL_EMAIL WORK_EMAIL ONLY_FANS FANSLY
identifier
required

The url, account name or phone number that identifies this user with the specified network.

string
"" >= 1 characters
audiences
Array<string>
Allowed values: EVERYONE ADVENTURE BEACH BUSINESS CULTURAL_EXPERIENCE EDUCATION FAMILY FOOD_AND_CULINARY HIKING HISTORICAL_SITES HONEYMOON LUXURY MEDICAL_TOURISM MUSIC_AND_FESTIVALS NATURE_AND_WILDLIFE PHOTOGRAPHY PILGRIMAGE RELAXATION ROAD_TRIP ROMANCE SHOPPING SKIING SOLO_TRAVEL SPORTS_EVENTS VOLUNTEERING WELLNESS_AND_SPA CITY WILDLIFE
audienceSize

The size of your audience.

integer format: int64
""
sort

How you would like to order your accounts.

integer format: int32
""
disabled

Whether to disable this entry temporarily.

boolean
annualTravelSpendInDollars

How much user or company spends on travel per year.

object
amount
required

Monetary amount value

number
""
currency
required

ISO 4217 currency code

string
"" >= 1 characters /^[A-Z]{3}$/
bookings

Total number of bookings in this metric set.

integer format: int64
""
totalPriceAmount

Total revenue from all bookings in the display currency.

number format: double
""
averageBookingAmount

Average booking value in the display currency.

number format: double
""
currencyCode

Currency code for the monetary amounts.

string
"" /^[A-Z]{3}$/
key
additional properties
""
Example
{
"ownerIdentifier": "d5b8a3c2-9e6f-4a1b-8d34-7c2e1f0a5b69",
"type": "HOTEL",
"ownerName": "The Siam Residences",
"urlName": "the-siam-residences",
"continent": "Asia",
"country": "Thailand",
"countryGeoNameId": "1605651",
"city": "Bangkok",
"cityGeoNameId": "1609350",
"ownerImageId": "3c6b1a5d-8e2f-4a0b-9c7d-6e4f0a8b2c51",
"description": "Luxury boutique hotel on the Chao Phraya River.",
"onlinePresence": [
{
"type": "INSTAGRAM",
"identifier": "@siamresidences",
"audiences": [
"TRAVEL"
],
"audienceSize": 12500,
"sort": 1,
"disabled": false
}
],
"annualTravelSpendInDollars": {
"amount": 250000,
"currency": "USD"
},
"bookings": 42,
"totalPriceAmount": 63000,
"averageBookingAmount": 1500,
"currencyCode": "USD"
}

Bad Request — missing or invalid request parameter or body

Media type application/problem+json
object
type
string format: uri
title
string
status
integer format: int32
detail
string
instance
string format: uri
properties
object
key
additional properties
key
additional properties
""
Example

Unauthorized — authentication is required or the session has expired

Media type application/problem+json
object
type
string format: uri
title
string
status
integer format: int32
detail
string
instance
string format: uri
properties
object
key
additional properties
key
additional properties
""
Example

Forbidden — authenticated but lacking the required permission or scope

Media type application/problem+json
object
type
string format: uri
title
string
status
integer format: int32
detail
string
instance
string format: uri
properties
object
key
additional properties
key
additional properties
""
Example

Not Found — the requested resource does not exist

Media type application/problem+json
object
type
string format: uri
title
string
status
integer format: int32
detail
string
instance
string format: uri
properties
object
key
additional properties
key
additional properties
""
Example

Method Not Allowed — the HTTP verb is not supported on this endpoint

Media type application/problem+json
object
type
string format: uri
title
string
status
integer format: int32
detail
string
instance
string format: uri
properties
object
key
additional properties
key
additional properties
""
Example

Unsupported Media Type — use application/json

Media type application/problem+json
object
type
string format: uri
title
string
status
integer format: int32
detail
string
instance
string format: uri
properties
object
key
additional properties
key
additional properties
""
Example

Internal Server Error — an unexpected failure occurred on the server

Media type application/problem+json
object
type
string format: uri
title
string
status
integer format: int32
detail
string
instance
string format: uri
properties
object
key
additional properties
key
additional properties
""
Example

Service Unavailable — a downstream dependency is unreachable

Media type application/problem+json
object
type
string format: uri
title
string
status
integer format: int32
detail
string
instance
string format: uri
properties
object
key
additional properties
key
additional properties
""
Example