Search for media assets
GET /mediaAssets
This call is used to search for (multiple) media assets that match the query parameters specified in the URL. Unlike the GET call to retrieve the details of a single media asset, this call will not return the full set of data for the media assets matching the query. Instead, it will return a limited set of metadata for each media asset.
To get more details for one of the returned media assets, the GET /mediaAsset/ call can be used.
Deleted media assets (stored in WHATS'ON as historical media assets) are not returned in this call.
Request
GET /mam/v1/mediaAssets?filter={filterParams)&offset={number}&limit={number}&sort={fieldToSort}
GET /mediaAssets?filter=eq(status,Ready for broadcast);eq(preferred,true)&offset=0&limit=50
[
{
"mediaAssetId": "MA123",
"contentId": "PG123",
"label": "MA123-PG123/V1",
"status": "Ready for broadcast",
"frameRate": "25fps",
"kind": "ANTENNE",
"preferred": true
},
{
"mediaAssetId": "MA456",
"contentId": "PG456",
"label": "MA123-PG456/V1",
"status": "Ready for broadcast",
"frameRate": "25fps",
"kind": "MASTER",
"preferred": true
}
]
The call does not require a body. Instead, a query string must be added to the URL, which can contain several parameters. The filter parameter is used to filter results based on predefined search criteria. The other parameters are used for sizing and sorting of the returned set of results.
Filter
Possible search parameters for WHATS'ON to execute the search:
labelstatuskindpreferredvideoMediaLabel: With this parameter you can search for media assets where the video component has a media with a specific labelaudioMediaLabel: With this parameter you can search for media assets where the audio component has a media with a specific labelsubtitlingMediaLabel: With this parameter you can search for media assets where the subtitling component has a media with a specific labelcontentIdscheduledDatechannelsourceMediaAssetId
| Search operators | Description | WHATS'ON operator |
|---|---|---|
| eq(property,value) | equal to | = |
| ne(property,value) | not equal to | <> |
| gt(property,value) | greater than | > |
| ge(property,value) | greater than or equal to | >= |
| lt(property,value) | less than | < |
| le(property,value) | less than or equal to | <= |
| null(property) | null | () |
| notNull(property) | not null | (*) |
| between(property,(value1,value2)) | between 2 values | 1..10 |
| in(property,(value1,value2,...)) | in one of x values | 1,2,3 |
Filter example: eq(title,Ben-Hur)
Other parameters
offset: number of returned entries omitted. E.g. Offset = 50 will not return the first 50 entries.limit: number of entries returned.sort: the fields used for sorting the resulting list. Add - for inverse sorting.
It is a best practice to use the offset and limit to prevent performance issues.