it
 

Differences from Musiclist2ApiParameters:18 (red) to Musiclist2ApiParameters:19 (green)

You can rollbackto Musiclist2ApiParameters:18
**jamendo.get2** : [[Musiclist2Api|Home]] | [[Musiclist2ApiTutorial|Crash course]] | [[Musiclist2ApiUsefulQueries|Useful queries]] | [[Musiclist2ApiFormats|Formats]] | [[Musiclist2ApiParameters|Parameters]] | [[Musiclist2ApiFields|Fields]] | [[Musiclist2ApiOrders|Orders]] | [[Musiclist2ApiJoins|Joins]]

== Parameters reference ==

This is a reference of all available parameters in our [[Musiclist2Api|jamendo.get2 API]]

There are 3 types of parameters :
* **Global parameters** : like "n=20" or "order=random", they affect to the entire query.
* **Unit parameters** : like "album_id=116", they are linked to a specific unit. Check the available [[Musiclist2ApiFields|Units/Fields reference]]
* **Format parameters** : like "json_callback=MyJsonCallback", they are linked to a specific format.

=== Global parameters ===

|=Parameter name|=Default value|=Description|=Examples|
|**n**|20|Number of items you want to fetch| [[http://api.jamendo.com/get2/image/album/jsonpretty/?n=100|Fetch 100 album images]] |
|**pn**|1|Page number for pagination. Starts at 1.| [[http://api.jamendo.com/get2/id+name+url/album/jsonpretty/?order=rating_desc&n=10&pn=1|Most popular albums, 1-10]]\\[[http://api.jamendo.com/get2/id+name+url/album/jsonpretty/?order=rating_desc&n=10&pn=2|Most popular albums, 11-20]]\\[[http://api.jamendo.com/get2/id+name+url/album/jsonpretty/?order=rating_desc&n=10&pn=3|Most popular albums, 21-30]]
|**order**| unordered |How to order the results. See our [[Musiclist2ApiOrders|Order reference]]| |
|**nshuffle**| 0 | If >0, actually fetch **nshuffle** results, and return **n** of them picked randomly. | [[http://api.jamendo.com/get2/id+name+url/album/jsonpretty/?order=rating_desc&n=10&nshuffle=50|Pick 10 of the 50 most popular albums]]

=== Unit parameters ===

==== Common to most units ====
|=Parameter name|=Description|=Examples|
|**id**|Numeric ID of the item. All items on Jamendo have one. You can fetch several IDs in the same query with **id=1+2+3+5**| |
|**idexclude**|Numeric IDs you want to exclude from the results| |
|**idfrom**\\**idto**|Numeric ID range. **idfrom** <= (results) < **idto**| |
|**datefrom**\\**dateto**|Date range. Use YYYY-MM-DD format for now. We will implement ISO dates soon| |


==== artist ====
|=Parameter name|=Description|=Examples|
|**artist_idstr**| String id of the artist | http://www.jamendo.com/get2/id/artist/plain?idstr=both|
|**artist_name**| Name of the artist (the real band name)\\//Be careful, name is not unique, 2 bands can have the same.// | http://www.jamendo.com/get2/id/artist/plain?name=Echo+Lali|
|**artist_mbid**| Numeric id of the artist on MusicBrainz | http://www.jamendo.com/get2/idstr/artist/plain?mbid=263632
|**artist_mbgid**| String id of the artist on MusicBrainz | http://www.jamendo.com/get2/idstr/artist/plain?mbgid=0781a3f3-645c-45d1-a84f-76b4e4decf6d
|**artist_hasalbums**| Fetch only the artists that have albums published on Jamendo | http://www.jamendo.com/get2/idstr/artist/plain?hasalbums=1
|**artist_hasmbid**| Fetch only the artists that have a MusicBrainz ID | http://www.jamendo.com/get2/idstr/artist/plain?hasmbid=1
|**artist_firstletter**| Search artists by their first letter | http://www.jamendo.com/get2/idstr/artist/plain?firstletter=a http://www.jamendo.com/get2/idstr/artist/plain?firstletter=zhttp://www.jamendo.com/get2/idstr/artist/plain?firstletter=a\n http://www.jamendo.com/get2/idstr/artist/plain?firstletter=z\n http://www.jamendo.com/get2/idstr/artist/plain?firstletter=0-9


==== album ====
|=Parameter name|=Description|=Examples|
|**album_mbid**| Numeric id of the album on MusicBrainz | http://www.jamendo.com/get2/name/album/plain?mbid=375887
|**album_mbgid**| String id of the album on MusicBrainz | http://www.jamendo.com/get2/name/album/plain?mbgid=602ede40-fcbc-4142-94b5-f72204bba21f

|=User|||
|**user_idstr**| String id (username/login) of the user | http://www.jamendo.com/get2/id/user/plain?idstr=pierrotsmnrd
|**user_hasavatar**| Fetch only the users that have an avatar | http://www.jamendo.com/get2/idstr/user/plain?hasavatar=1

=== Format parameters ===

|=json|