Events
Event
events(query_params)
Retrieves Events that fulfil given query parameters
Parameters:
Name | Type | Description | Default |
---|---|---|---|
query_params |
EventApiEventParams
|
Query Parameters API should filter for. |
required |
Returns:
Type | Description |
---|---|
list[ReducedEvent] | None
|
List of events |
Enums & Dataclasses
EventApiEventParams
dataclass
Query Params Dataclass for Event API requests
attraction_id: str | None = None
class-attribute
Filter by attraction id
city: list[str] | None = None
class-attribute
Filter by city
classification_id: list[str] | None = None
class-attribute
Filter by classification id: id of any segment, genre, sub-genre, type, sub-type. Negative filtering is supported by using the following format '-'. Be aware that negative filters may cause decreased performance.
classification_name: list[str] | None = None
class-attribute
Filter by classification name: name of any segment, genre, sub-genre, type, sub-type. Negative filtering is supported by using the following format '-'. Be aware that negative filters may cause decreased performance.
country_code: str | None = None
class-attribute
Filter by country code
end_date_time: str | None = None
class-attribute
Filter with a start date before this date
geo_point: str | None = None
class-attribute
Filter events by geoHash
id: str | None = None
class-attribute
Filter entities by its id
include_family: bool | None = None
class-attribute
Filter by classification that are family-friendly. Defaults to yes.
keyword: str | None = None
class-attribute
Keyword to search on
locale: list[str] = field(default_factory=lambda : ['de'])
class-attribute
The locale in ISO code format. Multiple comma-separated values can be provided.
When omitting the country part of the code (e.g. only en
or fr
) then the first matching locale is used.
When using a *
it matches all locales. *
can only be used at the end (e.g. en-us,en,*
).
Defaults to ["de"]
.
page: int | None = None
class-attribute
Page number. Defaults to 0.
postal_code: str | None = None
class-attribute
Filter by postal code / zipcode
radius: int | None = None
class-attribute
Radius of the area in which we want to search for events.
size: int | None = None
class-attribute
Page size of the response. Defaults to 20.
sort: SortEnum | None = None
class-attribute
Sorting order of the search result. Allowable Values: name,asc
, name,desc
, relevance,asc
,
relevance,desc
, distance,asc
, distance,desc
, random
.
Defaults to relevance,desc
start_date_time: str | None = None
class-attribute
Filter with a start date after this date
state_code: str | None = None
class-attribute
Filter by state code
unit: UnitEnum = UnitEnum.KILOMETER
class-attribute
Unit of the radius. Defaults to km
venue_id: str | None = None
class-attribute
Filter by venue id
concat_to_query()
Concatenates all fields to a string so that query can be appended to the request url
Assumes all query fields were validated before, using validate_fields
class method.
validate_fields()
Validates fields
SortEnum
Enum of possible sort by values
DISTANCE_ASC = 'distance,asc'
class-attribute
Sorting by distance in ascending order
DISTANCE_DESC = 'distance,desc'
class-attribute
Sorting by distance in descending order
NAME_ASC = 'name,asc'
class-attribute
Sorting by name in ascending order
NAME_DESC = 'name,desc'
class-attribute
Sorting by name in descending order
RELEVANCE_ASC = 'relevance,asc'
class-attribute
Sorting by relevance in ascending order
RELEVANCE_DESC = 'relevance,desc'
class-attribute
Sorting by relevance in descending order