Searching for Events
Learn to search for and filter events using Ticketmaster's Discovery API.
We'll cover the following...
Event search
The purpose of the Discovery API is—as the name implies—to discover events, venues, attractions, and so on. We can use the events endpoint of the Discovery API to search for and filter events based on different criteria.
The URL for this endpoint is:
https://app.ticketmaster.com/discovery/v2/events
Request parameters
We can provide multiple optional parameters to filter the search results. A few of these parameters and their uses are mentioned below. You can visit this lesson to see the complete list.
Parameter | Type | Category | Description |
| string | optional | If provided, the search results are filtered by the event ID. |
| string | optional | This is a keyword on which the search is performed. |
| string | optional | If provided, the search results are filtered by the attraction ID. |
| string | optional | If provided, the search results are filtered by the venue ID. |
| string | optional | If provided, the search results are filtered to return events with a start date after this date. |
| string | optional | If provided, the search results are filtered to return events with a start date before this date. |
| number | optional | This is the number of results to be returned per page. The default value is |
| number | optional | This is the page of search results to be returned. The default value is |
| string | optional | This is the sorting order of the search results. Allowable values are, |
| array[string] | optional | If provided, the search results are filtered by classification ID, that is, the ID of any segment, genre, subgenre, type, or subtype. Negative filtering is supported with this format: |
Let's try making an actual call to this endpoint, first with no search parameters. Later we'll make a call with a few of the optional parameters, such as size
and id
.
The code below makes a call to the events ...