-
Notifications
You must be signed in to change notification settings - Fork 16
2.5.1 Recherche globale
Vincent Séguin edited this page Jun 26, 2015
·
1 revision
Permet de rechercher dans la base de données d'itunes les films et saisons de séries télévisées en un seul appel.
Token d'authentification nécessaire
Paramètres obligatoires
q
est le paramètre de recherche dans l'URL.
Par exemple pour rechercher pour saw
l'URL sera /search?q=saw
.
Paramètres facultatifs
limit
donne le nombre de résultats maximums voulu. (Valeur par défault de 10)
Par exemple pour rechercher pour saw
et obtenir maximum 20 résultats l'URL sera /search?q=saw&limit=20
.
La requête doit être URL encodée (Comment URL encoder en JavaScript)
{
"resultCount": 10,
"results": [
{
"wrapperType": "track",
"kind": "feature-movie",
"trackId": 265727087,
"artistName": "James Wan",
"trackName": "Saw",
"trackCensoredName": "Saw",
"trackViewUrl": "https://itunes.apple.com/us/movie/saw/id265727087?uo=4",
"previewUrl": "http://a978.v.phobos.apple.com/us/r1000/097/Video/a6/aa/f2/mzm.jszrvyyu..640x360.h264lc.D2.p.m4v",
"artworkUrl30": "http://is5.mzstatic.com/image/pf/us/r30/Music/af/37/e2/dj.fsfobjrm.30x30-50.jpg",
"artworkUrl60": "http://is2.mzstatic.com/image/pf/us/r30/Music/af/37/e2/dj.fsfobjrm.60x60-50.jpg",
"artworkUrl100": "http://is2.mzstatic.com/image/pf/us/r30/Music/af/37/e2/dj.fsfobjrm.100x100-75.jpg",
"collectionPrice": 9.99,
"trackPrice": 9.99,
"trackRentalPrice": 2.99,
"collectionHdPrice": 12.99,
"trackHdPrice": 12.99,
"trackHdRentalPrice": 3.99,
"releaseDate": "2004-10-29T07:00:00Z",
"collectionExplicitness": "notExplicit",
"trackExplicitness": "notExplicit",
"trackTimeMillis": 6187486,
"country": "USA",
"currency": "USD",
"primaryGenreName": "Horror",
"contentAdvisoryRating": "R",
"longDescription": "Would you die to live? That's what two men, Adam (Leigh Whannell) and Gordon (Cary Elwes), have to ask themselves when they're paired up in a deadly situation. Abducted by a serial killer, they're trapped up in a prison constructed with such ingenuity that they may not be able to escape before their captor decides it's time to dismantle their bodies in his signature way. Attempting to break free may kill them, but staying definitely will.",
"radioStationUrl": "https://itunes.apple.com/station/idra.265727087"
},{...
}]
}