Playlists

This section of the API handles retrieval of playlist data. All requests must be authenticated as covered in the introduction.

smp.playlists.get

This method is used to get a specific playlist based on a unique ID. The following URL will get the playlist with the ID 154822.

http://playlists.net/api/v2?method=smp.playlists.get&id=154822

It will return an array of results similar to the following.

{
    "status":"ok",
    "playlist":{
        "id":"154822",
        "title":"Pauls Old Skool House Vol1",
        "playcount":"60",
        "created":"2013-01-09 11:10:24",
        "created_formatted":"09\/01\/2013",
        "uri":"http:\/\/playlists.net\/pauls-old-skool-house-vol1",
        "description":"Zone, Wigan Pier, Bowlers, Angels 1990's Classic piano house music.",
        "description_featured":"Zone, Wigan Pier, Bowlers, Angels 1990's Classic piano house music.",
        "playlist_uri":"spotify:user:seoidiot:playlist:4gqJbnlZvOh7mNnxrWDORB",
        "slug":"pauls-old-skool-house-vol1",
        "total_tracks":"59",
        "duration":"",
        "duration_formatted":"",
        "image":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154822.png",
        "image_l":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154822.png",
        "image_m":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-medium\/154822.png",
        "image_s":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-small\/154822.png"
    }
}

PHP SDK

require_once "ShareMyPlaylists.php";

$public = "{your_public_key}";
$private = "{your_private_key}";

$smp = new ShareMyPlaylists_Api($public, $private);

$parameters = array(
	"id" => 154822
);

$get_playlist = $smp->api("playlists.get", $parameters);

$playlist = $get_playlist["playlist"];

if( !empty($playlist) )
{
	print "<a class=\"image\" href=\"\"><img src=\"".$playlist["image_l"]."\" /></a>";
}

smp.playlists.get.pins

This method is used to get a specific playlist's pins based on a unique ID. The following URL will get the playlist with the ID 154822 pins.

http://playlists.net/api/v2?method=smp.playlists.get.pins&id=154822

It will return an array of results similar to the following.

Field
playlist_id The ID of the playlist you want to return pins from.
page The page of data you want to return.
per_page The number of pins you want to return per page.
{
    "status":"ok",
    "playlist":{
        "id":"154822",
        "title":"Pauls Old Skool House Vol1",
        "playcount":"60",
        "created":"2013-01-09 11:10:24",
        "created_formatted":"09\/01\/2013",
        "uri":"http:\/\/playlists.net\/pauls-old-skool-house-vol1",
        "description":"Zone, Wigan Pier, Bowlers, Angels 1990's Classic piano house music.",
        "description_featured":"Zone, Wigan Pier, Bowlers, Angels 1990's Classic piano house music.",
        "playlist_uri":"spotify:user:seoidiot:playlist:4gqJbnlZvOh7mNnxrWDORB",
        "slug":"pauls-old-skool-house-vol1",
        "total_tracks":"59",
        "duration":"",
        "duration_formatted":"",
        "image":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154822.png",
        "image_l":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154822.png",
        "image_m":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-medium\/154822.png",
        "image_s":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-small\/154822.png"
        "pins":[
            {
                "id":"2",
                "location_lat":"54.916191",
                "location_long":"-1.377371",
                "location_name":"Fitness 2000",
                "location_address":"",
                "foursquare_id":"4d21d1475acaa35d4420d335",
                "date_time":"2013-08-08 00:39:20",
            },
            {
                "id":"3",
                "location_lat":"54.916191",
                "location_long":"-1.377371",
                "location_name":"Fitness 2000",
                "location_address":"",
                "foursquare_id":"4d21d1475acaa35d4420d335",
                "date_time":"2013-08-08 00:19:20"
            }
		]
    }
}

PHP SDK

require_once "ShareMyPlaylists.php";

$public = "{your_public_key}";
$private = "{your_private_key}";

$smp = new ShareMyPlaylists_Api($public, $private);

$parameters = array(
	"id" => 154822
);

$get_playlist = $smp->api("playlists.get", $parameters);

$playlist = $get_playlist["playlist"];

if( !empty($playlist) )
{
	print "<a class=\"image\" href=\"\"><img src=\"".$playlist["image_l"]."\" /></a>";
}

smp.playlists.getList

The following URL will get the 15 most recently submitted featured playlists.

http://playlists.net/api/v2?method=smp.playlists.getList&page=1&per_page=15&arguments[is_featured]=1

It will return an array of results similar to the following.

{
    "status":"ok",
    "playlists":[
        {
            "id":"154822",
            "title":"Pauls Old Skool House Vol1",
            "playcount":"60",
            "created":"2013-01-09 11:10:24",
            "created_formatted":"09\/01\/2013",
            "uri":"http:\/\/playlists.net\/pauls-old-skool-house-vol1",
            "description":"Zone, Wigan Pier, Bowlers, Angels 1990's Classic piano house music.",
            "description_featured":"Zone, Wigan Pier, Bowlers, Angels 1990's Classic piano house music.",
            "playlist_uri":"spotify:user:seoidiot:playlist:4gqJbnlZvOh7mNnxrWDORB",
            "slug":"pauls-old-skool-house-vol1",
            "total_tracks":"59",
            "duration":"",
            "duration_formatted":"",
            "image":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154822.png",
            "image_l":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154822.png",
            "image_m":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-medium\/154822.png",
            "image_s":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-small\/154822.png"
        },
        {
            "id":"154784",
            "title":"Could be Bond",
            "playcount":"176",
            "created":"2013-01-09 01:14:06",
            "created_formatted":"09\/01\/2013",
            "uri":"http:\/\/playlists.net\/could-be-bond",
            "description":"Here's a collection of songs that sound like they could have been made for a Bond film (and, in fact, some of these songs were actually submitted for consideration for the films). A list that is sure to create as much debate as the Sean versus Roger versus Daniel row.",
            "description_featured":"Here's a collection of songs that sound like they could have been made for a Bond film (and, in fact, some of these songs were actually submitted for consideration for the films).",
            "playlist_uri":"spotify:user:hoxsd:playlist:0Ocg2A05Z0kUtBvWl8OUzG",
            "slug":"could-be-bond",
            "total_tracks":"109",
            "duration":"",
            "duration_formatted":"",
            "image":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154784.jpg",
            "image_l":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154784.jpg",
            "image_m":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-medium\/154784.jpg",
            "image_s":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-small\/154784.jpg"
        }
    ],
    "page":6,
    "per_page":"5",
    "total_records":1155
}

PHP SDK

require_once "ShareMyPlaylists.php";

$public = "{your_public_key}";
$private = "{your_private_key}";

$smp = new ShareMyPlaylists_Api($public, $private);

$parameters = array(
	"page" => 1,
	"per_page" => 15,
	"arguments" => array("is_featured" => 1 )
);

$get_list = $smp->api("playlists.getList", $parameters);

$playlists = $get_list["playlists"];

foreach( $playlists as $playlist )
{
	print "<a class=\"image\" href=\"\"><img src=\"".$playlist["image_l"]."\" /></a><br />";
}

smp.playlists.getRecommended

The following URL will get playlists that are similar to the playlists with the ID 154822.

http://playlists.net/api/v2?method=smp.playlists.getRecommended&id=154822

It will return an array of results similar to the following.

{
    "status":"ok",
    "playlists":[
        {
            "id":"154822",
            "title":"Pauls Old Skool House Vol1",
            "playcount":"60",
            "created":"2013-01-09 11:10:24",
            "created_formatted":"09\/01\/2013",
            "uri":"http:\/\/playlists.net\/pauls-old-skool-house-vol1",
            "description":"Zone, Wigan Pier, Bowlers, Angels 1990's Classic piano house music.",
            "description_featured":"Zone, Wigan Pier, Bowlers, Angels 1990's Classic piano house music.",
            "playlist_uri":"spotify:user:seoidiot:playlist:4gqJbnlZvOh7mNnxrWDORB",
            "slug":"pauls-old-skool-house-vol1",
            "total_tracks":"59",
            "duration":"",
            "duration_formatted":"",
            "image":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154822.png",
            "image_l":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154822.png",
            "image_m":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-medium\/154822.png",
            "image_s":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-small\/154822.png"
        },
        {
            "id":"154784",
            "title":"Could be Bond",
            "playcount":"176",
            "created":"2013-01-09 01:14:06",
            "created_formatted":"09\/01\/2013",
            "uri":"http:\/\/playlists.net\/could-be-bond",
            "description":"Here's a collection of songs that sound like they could have been made for a Bond film (and, in fact, some of these songs were actually submitted for consideration for the films). A list that is sure to create as much debate as the Sean versus Roger versus Daniel row.",
            "description_featured":"Here's a collection of songs that sound like they could have been made for a Bond film (and, in fact, some of these songs were actually submitted for consideration for the films).",
            "playlist_uri":"spotify:user:hoxsd:playlist:0Ocg2A05Z0kUtBvWl8OUzG",
            "slug":"could-be-bond",
            "total_tracks":"109",
            "duration":"",
            "duration_formatted":"",
            "image":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154784.jpg",
            "image_l":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154784.jpg",
            "image_m":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-medium\/154784.jpg",
            "image_s":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-small\/154784.jpg"
        }
    ]
}

PHP SDK

require_once "ShareMyPlaylists.php";

$public = "{your_public_key}";
$private = "{your_private_key}";

$smp = new ShareMyPlaylists_Api($public, $private);

$parameters = array(
	"page" => 1,
	"per_page" => 15,
	"arguments" => array("is_featured" => 1 )
);

$get_list = $smp->api("playlists.getRecommended", $parameters);

$playlists = $get_list["playlists"];

foreach( $playlists as $playlist )
{
	print "<a class=\"image\" href=\"\"><img src=\"".$playlist["image_l"]."\" /></a><br />";
}

smp.playlists.getByLocation

This method is used to get a list of playlists based on the the given location.

http://playlists.net/api/v2?method=smp.playlists.getByLocation&location_lat=54.916191&location_long=-1.377371

Field
location_lat Latitude of the specified location.
location_long Longitude of the specified location.
location_address Address of the specified location.
distance The distance, in kilometers, from the address or lat / long specified.

It will return an array of results similar to the following.

{
    "status":"ok",
    "playlists":[
    {
        "id":"104757",
        "title":"Pop Mix",
        "playcount":"35",
        "created":"2012-02-19 16:03:16",
        "created_formatted":"19\/02\/2012",
        "uri":"http:\/\/playlists.net\/pop-mix",
        "description":"",
        "description_featured":"",
        "playlist_uri":"spotify:user:12967587:playlist:0hUSGqAE42pukgF5fm4Ln1",
        "slug":"pop-mix",
        "total_tracks":"2986",
        "duration":"743457",
        "duration_formatted":"2 weeks, 8 hours",
        "image":"https:\/\/s3.amazonaws.com\/smpv2-genres-artwork_image-large\/17.png",
        "image_l":"https:\/\/s3.amazonaws.com\/smpv2-genres-artwork_image-large\/17.png",
        "image_m":"https:\/\/s3.amazonaws.com\/smpv2-genres-artwork_image-medium\/17.png",
        "image_s":"https:\/\/s3.amazonaws.com\/smpv2-genres-artwork_image-small\/17.png",
        "author":{
            "id":"127367",
            "uri":"http:\/\/playlists.net\/members\/jessica-ransom",
            "display_name":"Jessica Ransom",
            "profile_image":"https:\/\/s3.amazonaws.com\/smpv2-users-profile_image-large\/default\/soundtrack.jpg",
            "profile_image_l":"https:\/\/s3.amazonaws.com\/smpv2-users-profile_image-large\/default\/soundtrack.jpg",
            "profile_image_m":"https:\/\/s3.amazonaws.com\/smpv2-users-profile_image-medium\/default\/soundtrack.jpg",
            "profile_image_s":"https:\/\/s3.amazonaws.com\/smpv2-users-profile_image-small\/default\/soundtrack.jpg"
        },
        "genre":{
            "id":"17",
            "name":"Pop",
            "slug":"pop",
            "uri":"http:\/\/playlists.net\/playlists\/pop",
            "image":"https:\/\/s3.amazonaws.com\/smpv2-genres-image-large\/17.png",
            "image_l":"https:\/\/s3.amazonaws.com\/smpv2-genres-image-large\/17.png",
            "image_m":"https:\/\/s3.amazonaws.com\/smpv2-genres-image-medium\/17.png",
            "image_s":"https:\/\/s3.amazonaws.com\/smpv2-genres-image-small\/17.png"
        }
    }
}

PHP SDK

require_once "ShareMyPlaylists.php";

$public = "{your_public_key}";
$private = "{your_private_key}";

$smp = new ShareMyPlaylists_Api($public, $private);

$parameters = array(
	"distance" => 50,
	"location_lat" => 54.916191,
	"location_long" => -1.377371,
);

$get_playlists = $smp->api("playlists.getByLocation", $parameters);

$playlists = $get_list["playlists"];

foreach( $playlists as $playlist )
{
	print "<a class=\"image\" href=\"\"><img src=\"".$playlist["image_l"]."\" /></a><br />";
}
require_once "ShareMyPlaylists.php";

$public = "{your_public_key}";
$private = "{your_private_key}";

$smp = new ShareMyPlaylists_Api($public, $private);

$parameters = array(
	"distance" => 50,
	"location_address" => "36 Roker Avenue Sunderland, Tyne and Wear SR6 0HX",
);

$get_playlists = $smp->api("playlists.getByLocation", $parameters);

$playlists = $get_list["playlists"];

foreach( $playlists as $playlist )
{
	print "<a class=\"image\" href=\"\"><img src=\"".$playlist["image_l"]."\" /></a><br />";
}

smp.playlists.getByArtists

This method is used to get a list of playlists based on the array of artists supplied. Playlists are returned that contain tracks by those artists as well as additional meta data about those artists such as an image and description. The following URL will return playlists containing tracks by "Kanye West" & "Eminem".

http://playlists.net/api/v2?method=smp.playlists.getByArtists&artists[]=Kanye West&artists[]=Eminem

It will return an array of results similar to the following.

{
    "status":"ok",
    "artists":[
        {
            "id":"343",
            "image":
            "https:\/\/s3.amazonaws.com\/smpv2-artists-image-large\/343.jpg",
            "image_l":"https:\/\/s3.amazonaws.com\/smpv2-artists-image-large\/343.jpg",
            "image_m":"https:\/\/s3.amazonaws.com\/smpv2-artists-image-medium\/343.jpg",
            "image_s":"https:\/\/s3.amazonaws.com\/smpv2-artists-image-small\/343.jpg",
            "name":"Kanye West",
            "summary":"Kanye Omari West (born June 8, 1977 in Atlanta, Georgia) is a Grammy award winning rapper, producer, author, designer and singer. He began making beats and rapping in the early 90s in Chicago, IL, United States when he formed the rap group Go Getters with Chicago natives GLC and Really Doe. He later gained nationwide popularity in New York when he began producing tracks for artists such as Jay-Z, Twista, Mase, Talib Kweli and Alicia Keys. In 2004 (after being pushed aside by many record companies who felt he wasn't a marketable hip hop artist), he managed to release his debut solo album, The College Dropout on Roc-a-Fella Records.",
            "summary_formatted":"Kanye Omari West (born June 8, 1977 in Atlanta, Georgia) is a Grammy award winning rapper, producer, author, designer and singer. He began making beats and rapping in the early 90s in Chicago, IL, United States when he formed the rap group Go Getters with Chicago natives GLC and Really Doe. He later gained nationwide popularity in New York when he began producing tracks for artists such as Jay-Z, Twista, Mase, Talib Kweli and Alicia Keys. In 2004 (after being pushed aside by many record companies who felt he wasn't a marketable hip hop artist), he managed to release his debut solo album, The College Dropout on Roc-a-Fella Records.",
            "spotify_uri":"spotify:artist:5K4W6rqBFWDnAN6FQUkS6x",
            "uri":"http:\/\/playlists.net\/artists\/Kanye West"
        },
        {
            "id":"285",
            "image":"https:\/\/s3.amazonaws.com\/smpv2-artists-image-large\/285.jpg",
            "image_l":"https:\/\/s3.amazonaws.com\/smpv2-artists-image-large\/285.jpg",
            "image_m":"https:\/\/s3.amazonaws.com\/smpv2-artists-image-medium\/285.jpg",
            "image_s":"https:\/\/s3.amazonaws.com\/smpv2-artists-image-small\/285.jpg",
            "name":"Eminem",
            "summary":"Marshall Bruce Mathers III (born October 17, 1972),  better known by his stage name Eminem\/Slim Shady is an American rapper and record producer. Eminem learned his trade while growing up in Detroit, United States, and quickly gained popularity in 1999 with his major-label album, The Slim Shady LP, which won a Grammy Award for Best Rap Album. The following album, The Marshall Mathers LP, became the fastest-selling solo album in the United States history. The Marshall Mathers LP and his third album, The Eminem Show, also won Grammy Awards, making Eminem the first artist to win Best Rap Album for three consecutive LPs.",
            "summary_formatted":"Marshall Bruce Mathers III (born October 17, 1972),  better known by his stage name Eminem\/Slim Shady is an American rapper and record producer. Eminem learned his trade while growing up in Detroit, United States, and quickly gained popularity in 1999 with his major-label album, The Slim Shady LP, which won a Grammy Award for Best Rap Album. The following album, The Marshall Mathers LP, became the fastest-selling solo album in the United States history. The Marshall Mathers LP and his third album, The Eminem Show, also won Grammy Awards, making Eminem the first artist to win Best Rap Album for three consecutive LPs.",
            "spotify_uri":"spotify:artist:7dGJo4pcD2V6oG8kP0tJRR",
            "uri":"http:\/\/playlists.net\/artists\/Eminem"
        }
    ],
    "playlists":[
    {
        "id":"104757",
        "title":"Pop Mix",
        "playcount":"35",
        "created":"2012-02-19 16:03:16",
        "created_formatted":"19\/02\/2012",
        "uri":"http:\/\/playlists.net\/pop-mix",
        "description":"",
        "description_featured":"",
        "playlist_uri":"spotify:user:12967587:playlist:0hUSGqAE42pukgF5fm4Ln1",
        "slug":"pop-mix",
        "total_tracks":"2986",
        "duration":"743457",
        "duration_formatted":"2 weeks, 8 hours",
        "image":"https:\/\/s3.amazonaws.com\/smpv2-genres-artwork_image-large\/17.png",
        "image_l":"https:\/\/s3.amazonaws.com\/smpv2-genres-artwork_image-large\/17.png",
        "image_m":"https:\/\/s3.amazonaws.com\/smpv2-genres-artwork_image-medium\/17.png",
        "image_s":"https:\/\/s3.amazonaws.com\/smpv2-genres-artwork_image-small\/17.png",
        "author":{
            "id":"127367",
            "uri":"http:\/\/playlists.net\/members\/jessica-ransom",
            "display_name":"Jessica Ransom",
            "profile_image":"https:\/\/s3.amazonaws.com\/smpv2-users-profile_image-large\/default\/soundtrack.jpg",
            "profile_image_l":"https:\/\/s3.amazonaws.com\/smpv2-users-profile_image-large\/default\/soundtrack.jpg",
            "profile_image_m":"https:\/\/s3.amazonaws.com\/smpv2-users-profile_image-medium\/default\/soundtrack.jpg",
            "profile_image_s":"https:\/\/s3.amazonaws.com\/smpv2-users-profile_image-small\/default\/soundtrack.jpg"
        },
        "genre":{
            "id":"17",
            "name":"Pop",
            "slug":"pop",
            "uri":"http:\/\/playlists.net\/playlists\/pop",
            "image":"https:\/\/s3.amazonaws.com\/smpv2-genres-image-large\/17.png",
            "image_l":"https:\/\/s3.amazonaws.com\/smpv2-genres-image-large\/17.png",
            "image_m":"https:\/\/s3.amazonaws.com\/smpv2-genres-image-medium\/17.png",
            "image_s":"https:\/\/s3.amazonaws.com\/smpv2-genres-image-small\/17.png"
        }
    }
}

PHP SDK

require_once "ShareMyPlaylists.php";

$public = "{your_public_key}";
$private = "{your_private_key}";

$smp = new ShareMyPlaylists_Api($public, $private);

$parameters = array(
	"artists" => array("Eminem", "Kanye West")
);

$get_playlists = $smp->api("playlists.getByArtists", $parameters);

$playlists = $get_list["playlists"];
$artists = $get_list["artists"];

foreach( $artists as $artists )
{
	print $artists["name"]."<br />";
}

print "<br /><br />";

foreach( $playlists as $playlist )
{
	print "<a class=\"image\" href=\"\"><img src=\"".$playlist["image_l"]."\" /></a><br />";
}

smp.playlists.getChart

This method gets the last week's top 50 most listened to playlists on Playlists.net.

http://playlists.net/api/v2?method=smp.playlists.getChart

It will return an array of results similar to the following.

{
    "playlists":[
        {
            "id":"154822",
            "title":"Pauls Old Skool House Vol1",
            "playcount":"60",
            "created":"2013-01-09 11:10:24",
            "created_formatted":"09\/01\/2013",
            "uri":"http:\/\/playlists.net\/pauls-old-skool-house-vol1",
            "description":"Zone, Wigan Pier, Bowlers, Angels 1990's Classic piano house music.",
            "description_featured":"Zone, Wigan Pier, Bowlers, Angels 1990's Classic piano house music.",
            "playlist_uri":"spotify:user:seoidiot:playlist:4gqJbnlZvOh7mNnxrWDORB",
            "slug":"pauls-old-skool-house-vol1",
            "total_tracks":"59",
            "duration":"",
            "duration_formatted":"",
            "image":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154822.png",
            "image_l":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154822.png",
            "image_m":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-medium\/154822.png",
            "image_s":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-small\/154822.png"
        },
        {
            "id":"154784",
            "title":"Could be Bond",
            "playcount":"176",
            "created":"2013-01-09 01:14:06",
            "created_formatted":"09\/01\/2013",
            "uri":"http:\/\/playlists.net\/could-be-bond",
            "description":"Here's a collection of songs that sound like they could have been made for a Bond film (and, in fact, some of these songs were actually submitted for consideration for the films). A list that is sure to create as much debate as the Sean versus Roger versus Daniel row.",
            "description_featured":"Here's a collection of songs that sound like they could have been made for a Bond film (and, in fact, some of these songs were actually submitted for consideration for the films).",
            "playlist_uri":"spotify:user:hoxsd:playlist:0Ocg2A05Z0kUtBvWl8OUzG",
            "slug":"could-be-bond",
            "total_tracks":"109",
            "duration":"",
            "duration_formatted":"",
            "image":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154784.jpg",
            "image_l":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154784.jpg",
            "image_m":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-medium\/154784.jpg",
            "image_s":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-small\/154784.jpg"
        }
    ],
    "page":1,
    "per_page":"2",
    "total_records":11473
}

PHP SDK

require_once "ShareMyPlaylists.php";

$public = "{your_public_key}";
$private = "{your_private_key}";

$smp = new ShareMyPlaylists_Api($public, $private);

$parameters = array();

$get_list = $smp->api("playlists.getChart", $parameters);

$playlists = $get_list["playlists"];

foreach( $playlists as $playlist )
{
	print "<a class=\"image\" href=\"\"><img src=\"".$playlist["image_l"]."\" /></a><br />";
}

smp.playlists.submit

This method pushes a playlist to the Playlists.net service.

http://playlists.net/api/v2?method=smp.playlists.submit&author_id=97989&title=Pauls Old Skool House Vol1&genre_id=14&description=Zone, Wigan Pier, Bowlers, Angels 1990's Classic piano house music.&spotify_uri=spotify:user:seoidiot:playlist:4gqJbnlZvOh7mNnxrWDORB

You can also submit the additional paramaters location_lat, location_long & location_name in order to tie that playlist to a location.

An object containting your submitted playlist's data will be returned.

Field
title The title for this playlist.
description The description for this playlist.
image_data The raw data of the image for this playlist.
spotify_uri The Spotify URI for this playlist, for instance; spotify:user:seoidiot:playlist:4gqJbnlZvOh7mNnxrWDORB.
genre_id The ID of the genre for this playlist.
author_id The ID of the author of this playlist.
{
    "playlist":{
        "id":"154822",
        "title":"Pauls Old Skool House Vol1",
        "playcount":"60",
        "created":"2013-01-09 11:10:24",
        "created_formatted":"09\/01\/2013",
        "uri":"http:\/\/playlists.net\/pauls-old-skool-house-vol1",
        "description":"Zone, Wigan Pier, Bowlers, Angels 1990's Classic piano house music.",
        "description_featured":"Zone, Wigan Pier, Bowlers, Angels 1990's Classic piano house music.",
        "playlist_uri":"spotify:user:seoidiot:playlist:4gqJbnlZvOh7mNnxrWDORB",
        "slug":"pauls-old-skool-house-vol1",
        "total_tracks":"59",
        "duration":"",
        "duration_formatted":"",
        "image":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154822.png",
        "image_l":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154822.png",
        "image_m":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-medium\/154822.png",
        "image_s":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-small\/154822.png"
    }
}

PHP SDK

require_once "ShareMyPlaylists.php";

$public = "{your_public_key}";
$private = "{your_private_key}";

$smp = new ShareMyPlaylists_Api($public, $private);

$parameters = array(
	"author_id": 97989,
	"title": "Pauls Old Skool House Vol1",
	"genre_id": 14,
	"description": "Zone, Wigan Pier, Bowlers, Angels 1990's Classic piano house music.",
	"spotify_uri": "spotify:user:seoidiot:playlist:4gqJbnlZvOh7mNnxrWDORB"
);

$get_list = $smp->api("playlists.submit", $parameters);

$playlist = $get_list["playlist"];

print "<a class=\"image\" href=\"\"><img src=\"".$playlist["image_l"]."\" /></a>";

smp.playlists.getSimilar

This method returns playlists that are similar in content to the Spotify URI provided. Additionally it also returns additional meta data on the most popular artists in the playlist provided.

http://playlists.net/api/v2?method=smp.playlists.getSimilar&spotify_uri=spotify:user:mattlowden:playlist:5IElIECviY9K6PcrPX4KuA

It will return an array of results similar to the following.

{
    "playlists":[
        {
            "id":"154822",
            "title":"Pauls Old Skool House Vol1",
            "playcount":"60",
            "created":"2013-01-09 11:10:24",
            "created_formatted":"09\/01\/2013",
            "uri":"http:\/\/playlists.net\/pauls-old-skool-house-vol1",
            "description":"Zone, Wigan Pier, Bowlers, Angels 1990's Classic piano house music.",
            "description_featured":"Zone, Wigan Pier, Bowlers, Angels 1990's Classic piano house music.",
            "playlist_uri":"spotify:user:seoidiot:playlist:4gqJbnlZvOh7mNnxrWDORB",
            "slug":"pauls-old-skool-house-vol1",
            "total_tracks":"59",
            "duration":"",
            "duration_formatted":"",
            "image":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154822.png",
            "image_l":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154822.png",
            "image_m":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-medium\/154822.png",
            "image_s":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-small\/154822.png"
        },
        {
            "id":"154784",
            "title":"Could be Bond",
            "playcount":"176",
            "created":"2013-01-09 01:14:06",
            "created_formatted":"09\/01\/2013",
            "uri":"http:\/\/playlists.net\/could-be-bond",
            "description":"Here's a collection of songs that sound like they could have been made for a Bond film (and, in fact, some of these songs were actually submitted for consideration for the films). A list that is sure to create as much debate as the Sean versus Roger versus Daniel row.",
            "description_featured":"Here's a collection of songs that sound like they could have been made for a Bond film (and, in fact, some of these songs were actually submitted for consideration for the films).",
            "playlist_uri":"spotify:user:hoxsd:playlist:0Ocg2A05Z0kUtBvWl8OUzG",
            "slug":"could-be-bond",
            "total_tracks":"109",
            "duration":"",
            "duration_formatted":"",
            "image":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154784.jpg",
            "image_l":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154784.jpg",
            "image_m":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-medium\/154784.jpg",
            "image_s":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-small\/154784.jpg"
        }
    ],
    "artists":[
        {
            "id":"1255",
            "image":"https:\/\/s3.amazonaws.com\/smpv2-artists-image-large\/1255.jpg",
            "image_l":"https:\/\/s3.amazonaws.com\/smpv2-artists-image-large\/1255.jpg",
            "image_m":"https:\/\/s3.amazonaws.com\/smpv2-artists-image-medium\/1255.jpg",
            "image_s":"https:\/\/s3.amazonaws.com\/smpv2-artists-image-small\/1255.jpg",
            "name":"\"Weird Al\" Yankovic",
            "summary":"Alfred Matthew \"Weird Al\" Yankovic (born October 23, 1959 in Downey, California) is an American singer-songwriter, music producer, actor, comedian, satirist, accordian player and kazooist. Yankovic is known in particular for his humorous songs that make light of popular culture and that often parody specific songs by contemporary musical acts. Since his first-aired song parody in 1976, he has sold more than 12 million albums--more than any other comedy act in history--recorded more than 150 parody and original songs, and has performed more than 1,000 live shows.His works have earned him three Grammy Awards among nine nominations, four gold records, and six platinum records in the United States. Yankovic's first top ten Billboard album (Straight Outta Lynwood) and single (\"White & Nerdy\") were both released in 2006, nearly three decades into his career.",
            "summary_formatted":"Alfred Matthew \"Weird Al\" Yankovic (born October 23, 1959 in Downey, California) is an American singer-songwriter, music producer, actor, comedian, satirist, accordian player and kazooist. Yankovic is known in particular for his humorous songs that make light of popular culture and that often parody specific songs by contemporary musical acts. Since his first-aired song parody in 1976, he has sold more than 12 million albums--more than any other comedy act in history--recorded more than 150 parody and original songs, and has performed more than 1,000 live shows.His works have earned him three Grammy Awards among nine nominations, four gold records, and six platinum records in the United States. Yankovic's first top ten Billboard album (Straight Outta Lynwood) and single (\"White & Nerdy\") were both released in 2006, nearly three decades into his career.",
            "spotify_uri":"spotify:artist:1bDWGdIC2hardyt55nlQgG",
            "uri":"http:\/\/playlists.net\/artists\/\"Weird Al\" Yankovic"
        } ,
        {
            "id":"12799",
            "image":"https:\/\/s3.amazonaws.com\/smpv2-artists-image-large\/12799.jpg",
            "image_l":"https:\/\/s3.amazonaws.com\/smpv2-artists-image-large\/12799.jpg",
            "image_m":"https:\/\/s3.amazonaws.com\/smpv2-artists-image-medium\/12799.jpg",
            "image_s":"https:\/\/s3.amazonaws.com\/smpv2-artists-image-small\/12799.jpg",
            "name":"'Til Tuesday",
            "summary":"After The break up of The Young Snakes, 'Til Tuesday,an American new wave band, was formed in Boston in 1982. Its original lineup was bassist\/vocalist Aimee Mann, guitarist\/vocalist Robert Holmes, keyboardist Joey Pesce, and drummer Michael Hausman. The group first gained fame six months after its formation when it won radio station WBCN's battle of the bands competition in 1983. Their original composition \"Love In A Vacuum\" (credited to all members of the group) received a fair amount of airplay on the station, and the group was eventually signed to Epic Records.",
            "summary_formatted":"After The break up of The Young Snakes, 'Til Tuesday,an American new wave band, was formed in Boston in 1982. Its original lineup was bassist\/vocalist Aimee Mann, guitarist\/vocalist Robert Holmes, keyboardist Joey Pesce, and drummer Michael Hausman. The group first gained fame six months after its formation when it won radio station WBCN's battle of the bands competition in 1983. Their original composition \"Love In A Vacuum\" (credited to all members of the group) received a fair amount of airplay on the station, and the group was eventually signed to Epic Records.",
            "spotify_uri":"spotify:artist:1L0y9srZMyh9XUnYGv37IP",
            "uri":"http:\/\/playlists.net\/artists\/'Til Tuesday"
        }
    ],
}

PHP SDK

require_once "ShareMyPlaylists.php";

$public = "{your_public_key}";
$private = "{your_private_key}";

$smp = new ShareMyPlaylists_Api($public, $private);

$parameters = array(
	"spotify_uri" => "spotify:user:mattlowden:playlist:5IElIECviY9K6PcrPX4KuA"
);

$get_list = $smp->api("playlists.getSimilar", $parameters);

$playlists = $get_list["playlists"];

foreach( $playlists as $playlist )
{
	print "<a class=\"image\" href=\"\"><img src=\"".$playlist["image_l"]."\" /></a><br />";
}

smp.playlists.play

This method should be used to indicate that a playlist, specified by the playlists's ID, has been played by the currently authenticated user.

http://playlists.net/api/v2?method=smp.playlists.play&id=154822

Field
id The ID of the playlist the authenticated user is playing.

It will return an array of results similar to the following.

{
    "playlist": {
            "id":"154822",
            "title":"Pauls Old Skool House Vol1",
            "playcount":"60",
            "created":"2013-01-09 11:10:24",
            "created_formatted":"09\/01\/2013",
            "uri":"http:\/\/playlists.net\/pauls-old-skool-house-vol1",
            "description":"Zone, Wigan Pier, Bowlers, Angels 1990's Classic piano house music.",
            "description_featured":"Zone, Wigan Pier, Bowlers, Angels 1990's Classic piano house music.",
            "playlist_uri":"spotify:user:seoidiot:playlist:4gqJbnlZvOh7mNnxrWDORB",
            "slug":"pauls-old-skool-house-vol1",
            "total_tracks":"59",
            "duration":"",
            "duration_formatted":"",
            "image":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154822.png",
            "image_l":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154822.png",
            "image_m":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-medium\/154822.png",
            "image_s":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-small\/154822.png"
    }
}

PHP SDK

require_once "ShareMyPlaylists.php";

$public = "{your_public_key}";
$private = "{your_private_key}";

$smp = new ShareMyPlaylists_Api($public, $private);

$parameters = array(
	"id" => 154822
);

$get_list = $smp->api("playlists.play", $parameters);

smp.playlists.pin

This method should be used to pin a playlist to particular location, for instance a user may wish to associate a running playlist with a local gymnasium.

http://playlists.net/api/v2?method=smp.playlists.pin&playlist_id=154822&user_id=130000&location_lat=54.916191&location_long=-1.377371&location_name=Fitness%202000&foursquare_id=4d21d1475acaa35d4420d335

Field
playlist_id The ID of the playlist the authenticated user is pinning.
user_id The ID of the authenticated user.
location_lat Latitude of the user's location.
location_long Longitude of the user's location.
location_name Name of the user's location.
foursquare_id Foursquare ID of the user's location.
location_address Address of of the user's location.

It will return an array of results similar to the following.

{
    "playlist": {
            "id":"154822",
            "title":"Pauls Old Skool House Vol1",
            "playcount":"60",
            "created":"2013-01-09 11:10:24",
            "created_formatted":"09\/01\/2013",
            "uri":"http:\/\/playlists.net\/pauls-old-skool-house-vol1",
            "description":"Zone, Wigan Pier, Bowlers, Angels 1990's Classic piano house music.",
            "description_featured":"Zone, Wigan Pier, Bowlers, Angels 1990's Classic piano house music.",
            "playlist_uri":"spotify:user:seoidiot:playlist:4gqJbnlZvOh7mNnxrWDORB",
            "slug":"pauls-old-skool-house-vol1",
            "total_tracks":"59",
            "duration":"",
            "duration_formatted":"",
            "image":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154822.png",
            "image_l":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-large\/154822.png",
            "image_m":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-medium\/154822.png",
            "image_s":"https:\/\/s3.amazonaws.com\/smpv2-playlists-image-small\/154822.png"
    }
}

PHP SDK

require_once "ShareMyPlaylists.php";

$public = "{your_public_key}";
$private = "{your_private_key}";

$smp = new ShareMyPlaylists_Api($public, $private);

$parameters = array(
	"playlist_id" => 154822,
	"location_lat" => 54.916191,
	"location_long" => -1.377371,
	"location_name" => "Fitness 2000",
	"foursquare_id" => "4d21d1475acaa35d4420d335"
);

$get_list = $smp->api("playlists.pin", $parameters);

$playlists = $get_list["playlists"];

foreach( $playlists as $playlist )
{
	print "<a class=\"image\" href=\"\"><img src=\"".$playlist["image_l"]."\" /></a><br />";
}