/
04. Comprehensive Search

04. Comprehensive Search

Every site should have a comprehensive search available on most every page including possibly making it the main feature of the homepage. Once a visitor is has selected an event for which to view tickets and throughout the purchase process it probably makes sense to not show the search and instead use that space for useful elements.

It is suggested that this main search performs a search across Performers, Venues, and Events.

 

 

Comprehensive Search can be done via two different endpoints and you should experiment with both and decide which you prefer based on the experience you choose to present to the user.

/searches/suggestions

The /searches/suggestion endpoint was created to be used in an auto-suggest type of selector.

 

/searches/suggestion via cURL
curl -i \ -X GET \ -H "X-Signature: IKE8qY1xcCqHKoJFOC+Ett/Xpy5pzkXdCRQh5YflTCs=" \ -H "X-Token: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" \ --url 'https://api.ticketevolution.com/v9/searches/suggestions?entities=events,performers,venues&fuzzy=true&limit=6&q=diamondbacks'

 

 

/searches/suggestion using ticketevolution-php
$response = $client->listSearchSuggestions([ 'entities' => 'events,performers,venues', 'fuzzy' => true, 'limit' => 6, 'q' => 'diamondbacks', ]));

 

 

 

 

/searches/suggestion JSON results
{ "total_entries": 3, "suggestions": { "events": [{ "id": 1073656, "type": "events", "name": "Arizona Diamondbacks at San Francisco Giants", "slug": null, "location": "San Francisco, CA", "company": null, "venue_name": "AT&T Park", "occurs_at": "2017-08-05T18:05:00Z" }, { "id": 1073663, "type": "events", "name": "Arizona Diamondbacks at San Francisco Giants", "slug": null, "location": "San Francisco, CA", "company": null, "venue_name": "AT&T Park", "occurs_at": "2017-09-16T18:05:00Z" }, { "id": 1073718, "type": "events", "name": "Arizona Diamondbacks at San Francisco Giants", "slug": null, "location": "San Francisco, CA", "company": null, "venue_name": "AT&T Park", "occurs_at": "2017-09-17T13:05:00Z" }, { "id": 1073688, "type": "events", "name": "Arizona Diamondbacks at San Francisco Giants", "slug": null, "location": "San Francisco, CA", "company": null, "venue_name": "AT&T Park", "occurs_at": "2017-08-04T19:15:00Z" }, { "id": 1073709, "type": "events", "name": "Arizona Diamondbacks at San Francisco Giants", "slug": null, "location": "San Francisco, CA", "company": null, "venue_name": "AT&T Park", "occurs_at": "2017-08-06T13:05:00Z" }, { "id": 1073695, "type": "events", "name": "Arizona Diamondbacks at San Francisco Giants", "slug": null, "location": "San Francisco, CA", "company": null, "venue_name": "AT&T Park", "occurs_at": "2017-09-15T19:15:00Z" }, { "id": 1073465, "type": "events", "name": "Arizona Diamondbacks at Los Angeles Dodgers", "slug": null, "location": "Los Angeles, CA", "company": null, "venue_name": "Dodger Stadium", "occurs_at": "2017-07-04T18:10:00Z" }, { "id": 1073457, "type": "events", "name": "Arizona Diamondbacks at Los Angeles Dodgers", "slug": null, "location": "Los Angeles, CA", "company": null, "venue_name": "Dodger Stadium", "occurs_at": "2017-09-05T19:10:00Z" }, { "id": 1073470, "type": "events", "name": "Arizona Diamondbacks at Los Angeles Dodgers", "slug": null, "location": "Los Angeles, CA", "company": null, "venue_name": "Dodger Stadium", "occurs_at": "2017-07-06T19:10:00Z" }, { "id": 1073502, "type": "events", "name": "Arizona Diamondbacks at Los Angeles Dodgers", "slug": null, "location": "Los Angeles, CA", "company": null, "venue_name": "Dodger Stadium", "occurs_at": "2017-07-05T19:10:00Z" }, { "id": 1073481, "type": "events", "name": "Arizona Diamondbacks at Los Angeles Dodgers", "slug": null, "location": "Los Angeles, CA", "company": null, "venue_name": "Dodger Stadium", "occurs_at": "2017-09-04T17:10:00Z" }, { "id": 1073415, "type": "events", "name": "Arizona Diamondbacks at Kansas City Royals", "slug": null, "location": "Kansas City, MO",