Skip to content

Search request

Search request

Parameter Type Description
searchText string Optional. Search for contained string by the searchable fields
searchFields string Optional. When name of fields are specified as a comma separated string (e.g. "name, description, address/name") then only the selected fields will be used for searching.
select string Optional. When name of fields are specified as a comma separated string (e.g. "name, description, @id, address") then only the selected fields will be returned.
filters string[] Optional. Odata strings for filters
currentPage int Optional. By default equal 1. Determines which page of results to return in the response. Note: see limitations below the table
resultsPerPage int Optional. By default equal 10 for regular request and 50 for pdf request. Determines how many results are in response
orderBy string Optional. Determines name of field by which result will be ordered
facets FacetRequest[] Optional. List of facets which will be in the response
scoringTags string[] Optional. List of tags which will be used for scoring (Beta) of results in the response
scoringReferencePoint string Optional. Coordinates of point in format 'Longitude,Latitude' (e.g.: 8.5172912,47.5722339) which will be used for scoring by distance

Warning

There is a limitation for currentPage parameter - the product of the currentPage and resultsPerPage parameters must not exceed 100000

Information

If resultsPerPage less than 1 then default value will be applied.

Tip

For pagination better use orderBy parameter to avoid duplicates in the result. For example order by identifier.

Custom filter properties

Parameter Type Description
datasource string[] Optional. List of datasources to filter by (with OR condition).
project string[] Optional. List of projects to filter by (with OR condition).
sourcePartner string[] Optional. List of source partners acronyms to filter by (with OR condition).
sourceId string[] Optional. List of source ids to filter by (with OR condition).
category string[] Optional. List of categories to filter by (with OR condition).
allTag string[] Optional. List of tags to filter by (with OR condition).
profileTag string[] Optional. List of profile tags to filter by (with OR condition).
campaignTag string[] Optional. List of campaign tags to filter by (with OR condition).
location string[] Optional. List of location ids to filter by (with OR condition).
award string[] Optional. List of award ids to filter by (with OR condition).
action string[] Optional. List of action to filter by (with OR condition). Possible values: OrderActionWeb, RegisterActionWeb and OrderActionDsMarket.

Facets filter properties

For filtering by facets it is necessary to use property filterPropertyName from Search facet response as a request property name. These filter properties are optional.

List of available facets filters

facet name filter property name filter value type description
address/addressLocality addressLocality string[]
address/postalCode addressPostalCode string[]
tag tag string[] List of common discover.swiss tags. Profile and Campaign tags were not included.
campaignTag campaignTag string[] List of campaign tags.
categoryTree categoryTree string[] represent category tree list. For getting full list of categories don't forget to set big enough value for count property in facet request
containedInPlace/id containedInPlace string[]
time time int[]
length length double[] Length of tour
state state string[]
rating/condition ratingСondition int[]
rating/difficulty ratingDifficulty int[]
elevation/ascent elevationAscent int[]
elevation/descent elevationDescent int[]
elevation/minAltitude elevationMinAltitude int[]
elevation/maxAltitude elevationMaxAltitude int[]
season season string[]
type type string[]
combinedType combinedType string[] represent array containing data from parentType and parentAdditionalType properties
combinedTypeTree combinedTypeTree string[] represent array containing tree data from parentType and parentAdditionalType properties
leafType leafType string[] contains additionalType or type
sourcePartner sourcePartner string[] contains list of source partner acronyms

Localization

Default value

de-CH

Language: Based on the Accept-Language header localized properties are translated. Search language is based on this header as well (e.g. for de-CH it will search only in german translations if the translation is available for this porperty.