The KKBOX Open API zh-TW Developer Hub

Welcome to the KKBOX Open API zh-TW developer hub. You'll find comprehensive guides and documentation to help you start working with KKBOX Open API zh-TW as quickly as possible, as well as support if you get stuck. Let's jump right in!

Get Started    

歌曲

Suggest Edits

/tracks/{track_id}

透過 {track_id} 取得該歌曲的資訊

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/tracks/track_id
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/tracks/4kxvr3wPWkaL9_y3o_?territory=TW' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/tracks/4kxvr3wPWkaL9_y3o_?territory=TW")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/tracks/4kxvr3wPWkaL9_y3o_?territory=TW",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/tracks/4kxvr3wPWkaL9_y3o_?territory=TW", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/tracks/4kxvr3wPWkaL9_y3o_?territory=TW",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/tracks/4kxvr3wPWkaL9_y3o_?territory=TW"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "id": "4kxvr3wPWkaL9_y3o_",
  "name": "島嶼天光",
  "duration": 260493,
  "url": "https://event.kkbox.com/content/song/4kxvr3wPWkaL9_y3o_",
  "track_number": 1,
  "explicitness": false,
  "available_territories": [
    "TW",
    "HK",
    "SG",
    "MY",
    "JP"
  ],
  "album": {
    "id": "WpTPGzNLeutVFHcFq6",
    "name": "島嶼天光",
    "url": "https://event.kkbox.com/content/album/WpTPGzNLeutVFHcFq6",
    "explicitness": false,
    "available_territories": [
      "TW",
      "HK",
      "SG",
      "MY",
      "JP"
    ],
    "release_date": "2014-03-28",
    "images": [
      {
        "height": 160,
        "width": 160,
        "url": "https://i.kfs.io/album/tw/3693943,0v1/fit/160x160.jpg"
      },
      {
        "height": 500,
        "width": 500,
        "url": "https://i.kfs.io/album/tw/3693943,0v1/fit/500x500.jpg"
      },
      {
        "height": 1000,
        "width": 1000,
        "url": "https://i.kfs.io/album/tw/3693943,0v1/fit/1000x1000.jpg"
      }
    ],
    "artist": {
      "id": "8q3_xzjl89Yakn_7GB",
      "name": "滅火器 (Fire EX.)",
      "url": "https://event.kkbox.com/content/artist/8q3_xzjl89Yakn_7GB",
      "images": [
        {
          "height": 160,
          "width": 160,
          "url": "https://i.kfs.io/artist/global/26407,0v3/fit/160x160.jpg"
        },
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/artist/global/26407,0v3/fit/300x300.jpg"
        }
      ]
    }
  }
}
HTTP/1.1 400 Bad Request
Content-Type: application/json

{
    "error": {
        "code": 0,
        "message": "Invalid Territory"
    }
}
{
  "error": {
    "message": "Invalid Authentication",
    "code": 0
  }
}

Path Params

track_id
string
required

歌曲 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

 

專輯

Suggest Edits

/albums/{album_id}

透過 {album_id} 取得該專輯的資訊

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/albums/album_id
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/albums/KmRKnW5qmUrTnGRuxF?territory=TW' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/albums/KmRKnW5qmUrTnGRuxF?territory=TW")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/albums/KmRKnW5qmUrTnGRuxF?territory=TW",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/albums/KmRKnW5qmUrTnGRuxF?territory=TW", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/albums/KmRKnW5qmUrTnGRuxF?territory=TW",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/albums/KmRKnW5qmUrTnGRuxF?territory=TW"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "id": "WpTPGzNLeutVFHcFq6",
  "name": "島嶼天光",
  "url": "https://event.kkbox.com/content/album/WpTPGzNLeutVFHcFq6",
  "explicitness": false,
  "available_territories": [
    "TW",
    "HK",
    "SG",
    "MY",
    "JP"
  ],
  "release_date": "2014-03-28",
  "images": [
    {
      "height": 160,
      "width": 160,
      "url": "https://i.kfs.io/album/tw/3693943,0v1/fit/160x160.jpg"
    },
    {
      "height": 500,
      "width": 500,
      "url": "https://i.kfs.io/album/tw/3693943,0v1/fit/500x500.jpg"
    },
    {
      "height": 1000,
      "width": 1000,
      "url": "https://i.kfs.io/album/tw/3693943,0v1/fit/1000x1000.jpg"
    }
  ],
  "artist": {
    "id": "8q3_xzjl89Yakn_7GB",
    "name": "滅火器 (Fire EX.)",
    "url": "https://event.kkbox.com/content/artist/8q3_xzjl89Yakn_7GB",
    "images": [
      {
        "height": 160,
        "width": 160,
        "url": "https://i.kfs.io/artist/global/26407,0v3/fit/160x160.jpg"
      },
      {
        "height": 300,
        "width": 300,
        "url": "https://i.kfs.io/artist/global/26407,0v3/fit/300x300.jpg"
      }
    ]
  }
}

Path Params

album_id
string
required

專輯 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

 
Suggest Edits

/albums/{album_id}/tracks

透過 {album_id} 取得該專輯中的歌曲列表

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/albums/album_id/tracks
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/albums/KmRKnW5qmUrTnGRuxF/tracks?territory=TW&offset=0&limit=500' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/albums/KmRKnW5qmUrTnGRuxF/tracks?territory=TW&offset=0&limit=500")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/albums/KmRKnW5qmUrTnGRuxF/tracks?territory=TW&offset=0&limit=500",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/albums/KmRKnW5qmUrTnGRuxF/tracks?territory=TW&offset=0&limit=500", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/albums/KmRKnW5qmUrTnGRuxF/tracks?territory=TW&offset=0&limit=500",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/albums/KmRKnW5qmUrTnGRuxF/tracks?territory=TW&offset=0&limit=500"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "4nUHbb0o3TYuoaINx9",
      "name": "Introduction",
      "duration": 18575,
      "url": "https://event.kkbox.com/content/song/4nUHbb0o3TYuoaINx9",
      "track_number": 1,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY"
      ]
    },
    {
      "id": "L_o2Utm5_NyBo6oNMY",
      "name": "Genesis 01",
      "duration": 292850,
      "url": "https://event.kkbox.com/content/song/L_o2Utm5_NyBo6oNMY",
      "track_number": 2,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY"
      ]
    },
    {
      "id": "DYPE2v_bri5YQ2b-7p",
      "name": "Genesis 02",
      "duration": 210466,
      "url": "https://event.kkbox.com/content/song/DYPE2v_bri5YQ2b-7p",
      "track_number": 3,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY"
      ]
    },
    {
      "id": "KrDrOTRn6Il0Ayj3p0",
      "name": "Genesis 03",
      "duration": 256906,
      "url": "https://event.kkbox.com/content/song/KrDrOTRn6Il0Ayj3p0",
      "track_number": 4,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY"
      ]
    },
    {
      "id": "LaAGS6sZzEPTjmAAFH",
      "name": "Genesis 04",
      "duration": 251240,
      "url": "https://event.kkbox.com/content/song/LaAGS6sZzEPTjmAAFH",
      "track_number": 5,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY"
      ]
    }
  ],
  "paging": {
    "offset": 0,
    "limit": 5,
    "previous": null,
    "next": "https://api.kkbox.com/v1.1/albums/0qXVlEZgW0hFnj-Db2/tracks?limit=5&offset=5"
  },
  "summary": {
    "total": 1190
  }
}

Path Params

album_id
string
required

專輯 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

limit
int32

每頁返回的結果數量,最多不能超過 500

offset
int32

跳過頁數

 
 

透過歌手 id 取得照片、專輯、熱門歌曲、相關歌手等實用資料

Suggest Edits

/artists/{artist_id}

透過 {artist_id} 取得該藝人的資訊

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/artists/artist_id
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/artists/foo?territory=foo' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/artists/foo?territory=foo")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/artists/foo?territory=foo",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/artists/foo?territory=foo", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/artists/foo?territory=foo",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/artists/foo?territory=foo"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "id": "8q3_xzjl89Yakn_7GB",
  "name": "滅火器 (Fire EX.)",
  "url": "https://event.kkbox.com/content/artist/8q3_xzjl89Yakn_7GB",
  "images": [
    {
      "height": 160,
      "width": 160,
      "url": "https://i.kfs.io/artist/global/26407,0v3/fit/160x160.jpg"
    },
    {
      "height": 300,
      "width": 300,
      "url": "https://i.kfs.io/artist/global/26407,0v3/fit/300x300.jpg"
    }
  ]
}

Path Params

artist_id
string
required

藝人 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

 
Suggest Edits

/artists/{artist_id}/albums

透過 {artist_id} 取得該藝人的專輯列表

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/artists/artist_id/albums
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/artists/Cnv_K6i5Ft4y41SxLy/albums?territory=TW&offset=0&limit=500' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/artists/Cnv_K6i5Ft4y41SxLy/albums?territory=TW&offset=0&limit=500")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/artists/Cnv_K6i5Ft4y41SxLy/albums?territory=TW&offset=0&limit=500",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/artists/Cnv_K6i5Ft4y41SxLy/albums?territory=TW&offset=0&limit=500", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/artists/Cnv_K6i5Ft4y41SxLy/albums?territory=TW&offset=0&limit=500",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/artists/Cnv_K6i5Ft4y41SxLy/albums?territory=TW&offset=0&limit=500"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "OrZNXB5eLG7iPlkRfm",
      "name": "The Art of The Ballad([魔岩Ja22大師名曲系列]德斯特戈登)",
      "url": "https://event.kkbox.com/content/album/OrZNXB5eLG7iPlkRfm",
      "explicitness": false,
      "available_territories": [],
      "images": [
        {
          "height": 160,
          "width": 160,
          "url": "https://i.kfs.io/album/tw/32394,0v1/fit/160x160.jpg"
        },
        {
          "height": 500,
          "width": 500,
          "url": "https://i.kfs.io/album/tw/32394,0v1/fit/500x500.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/album/tw/32394,0v1/fit/1000x1000.jpg"
        }
      ],
      "artist": {
        "id": "CluDKLYxr1GFQqLSZt",
        "name": "Dexter Gordon",
        "url": "https://event.kkbox.com/content/artist/CluDKLYxr1GFQqLSZt",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/artist/global/4547,0v486/fit/160x160.jpg"
          },
          {
            "height": 300,
            "width": 300,
            "url": "https://i.kfs.io/artist/global/4547,0v486/fit/300x300.jpg"
          }
        ]
      }
    },
    {
      "id": "4mPUAQFE2kVG4kRaM8",
      "name": "Sophisticated Giant(才藝巨人)",
      "url": "https://event.kkbox.com/content/album/4mPUAQFE2kVG4kRaM8",
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY"
      ],
      "release_date": "1997-08-26",
      "images": [
        {
          "height": 160,
          "width": 160,
          "url": "https://i.kfs.io/album/tw/57735,0v1/fit/160x160.jpg"
        },
        {
          "height": 500,
          "width": 500,
          "url": "https://i.kfs.io/album/tw/57735,0v1/fit/500x500.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/album/tw/57735,0v1/fit/1000x1000.jpg"
        }
      ],
      "artist": {
        "id": "CluDKLYxr1GFQqLSZt",
        "name": "Dexter Gordon",
        "url": "https://event.kkbox.com/content/artist/CluDKLYxr1GFQqLSZt",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/artist/global/4547,0v486/fit/160x160.jpg"
          },
          {
            "height": 300,
            "width": 300,
            "url": "https://i.kfs.io/artist/global/4547,0v486/fit/300x300.jpg"
          }
        ]
      }
    },
    {
      "id": "SmNmkWuygNqlRZcqBS",
      "name": "The Classic Blue Note Recordings",
      "url": "https://event.kkbox.com/content/album/SmNmkWuygNqlRZcqBS",
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY",
        "JP"
      ],
      "release_date": "2003-01-06",
      "images": [
        {
          "height": 160,
          "width": 160,
          "url": "https://i.kfs.io/album/tw/59423,0v1/fit/160x160.jpg"
        },
        {
          "height": 500,
          "width": 500,
          "url": "https://i.kfs.io/album/tw/59423,0v1/fit/500x500.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/album/tw/59423,0v1/fit/1000x1000.jpg"
        }
      ],
      "artist": {
        "id": "CluDKLYxr1GFQqLSZt",
        "name": "Dexter Gordon",
        "url": "https://event.kkbox.com/content/artist/CluDKLYxr1GFQqLSZt",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/artist/global/4547,0v486/fit/160x160.jpg"
          },
          {
            "height": 300,
            "width": 300,
            "url": "https://i.kfs.io/artist/global/4547,0v486/fit/300x300.jpg"
          }
        ]
      }
    },
    {
      "id": "Ksh_HHNedkIB-GLKVK",
      "name": "Go!",
      "url": "https://event.kkbox.com/content/album/Ksh_HHNedkIB-GLKVK",
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY",
        "JP"
      ],
      "release_date": "1999-03-11",
      "images": [
        {
          "height": 160,
          "width": 160,
          "url": "https://i.kfs.io/album/tw/60368,0v1/fit/160x160.jpg"
        },
        {
          "height": 500,
          "width": 500,
          "url": "https://i.kfs.io/album/tw/60368,0v1/fit/500x500.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/album/tw/60368,0v1/fit/1000x1000.jpg"
        }
      ],
      "artist": {
        "id": "CluDKLYxr1GFQqLSZt",
        "name": "Dexter Gordon",
        "url": "https://event.kkbox.com/content/artist/CluDKLYxr1GFQqLSZt",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/artist/global/4547,0v486/fit/160x160.jpg"
          },
          {
            "height": 300,
            "width": 300,
            "url": "https://i.kfs.io/artist/global/4547,0v486/fit/300x300.jpg"
          }
        ]
      }
    },
    {
      "id": "T_jtz6mb5SlJ8gh7IE",
      "name": "Gettin' Around",
      "url": "https://event.kkbox.com/content/album/T_jtz6mb5SlJ8gh7IE",
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY",
        "JP"
      ],
      "release_date": "2006-02-08",
      "images": [
        {
          "height": 160,
          "width": 160,
          "url": "https://i.kfs.io/album/tw/66353,0v1/fit/160x160.jpg"
        },
        {
          "height": 500,
          "width": 500,
          "url": "https://i.kfs.io/album/tw/66353,0v1/fit/500x500.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/album/tw/66353,0v1/fit/1000x1000.jpg"
        }
      ],
      "artist": {
        "id": "CluDKLYxr1GFQqLSZt",
        "name": "Dexter Gordon",
        "url": "https://event.kkbox.com/content/artist/CluDKLYxr1GFQqLSZt",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/artist/global/4547,0v486/fit/160x160.jpg"
          },
          {
            "height": 300,
            "width": 300,
            "url": "https://i.kfs.io/artist/global/4547,0v486/fit/300x300.jpg"
          }
        ]
      }
    }
  ],
  "paging": {
    "offset": 0,
    "limit": 5,
    "previous": null,
    "next": "https://api.kkbox.com/v1.1/artists/CluDKLYxr1GFQqLSZt/albums?limit=5&offset=5"
  },
  "summary": {
    "total": 653
  }
}

Path Params

artist_id
string
required

藝人 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

limit
string

每頁返回的結果數量,最多不能超過 500

offset
string

跳過頁數

 
Suggest Edits

/artists/{artist_id}/top-tracks

透過 {artist_id} 取得該藝人最熱門的歌曲列表

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/artists/artist_id/top-tracks
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/artists/Cnv_K6i5Ft4y41SxLy/top-tracks?territory=TW&offset=0&limit=500' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/artists/Cnv_K6i5Ft4y41SxLy/top-tracks?territory=TW&offset=0&limit=500")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/artists/Cnv_K6i5Ft4y41SxLy/top-tracks?territory=TW&offset=0&limit=500",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/artists/Cnv_K6i5Ft4y41SxLy/top-tracks?territory=TW&offset=0&limit=500", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/artists/Cnv_K6i5Ft4y41SxLy/top-tracks?territory=TW&offset=0&limit=500",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/artists/Cnv_K6i5Ft4y41SxLy/top-tracks?territory=TW&offset=0&limit=500"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "GkXWQm7-nSw3SIIfzC",
      "name": "The Christmas Song",
      "duration": 317974,
      "url": "https://event.kkbox.com/content/song/GkXWQm7-nSw3SIIfzC",
      "track_number": 5,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY",
        "JP"
      ],
      "album": {
        "id": "-ru5tAbZ1XBjJ3ykFj",
        "name": "The Panther",
        "url": "https://event.kkbox.com/content/album/-ru5tAbZ1XBjJ3ykFj",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "release_date": "2006-09-03",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/tw/101813,0v1/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/tw/101813,0v1/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/tw/101813,0v1/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "CluDKLYxr1GFQqLSZt",
          "name": "Dexter Gordon",
          "url": "https://event.kkbox.com/content/artist/CluDKLYxr1GFQqLSZt",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/global/4547,0v486/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/global/4547,0v486/fit/300x300.jpg"
            }
          ]
        }
      }
    },
    {
      "id": "CmLfKO1VtBWGrlXXF6",
      "name": "Manha De Carnaval",
      "duration": 504848,
      "url": "https://event.kkbox.com/content/song/CmLfKO1VtBWGrlXXF6",
      "track_number": 1,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY",
        "JP"
      ],
      "album": {
        "id": "L_fVA94eYWLlTm3XVk",
        "name": "Gettin' Around",
        "url": "https://event.kkbox.com/content/album/L_fVA94eYWLlTm3XVk",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "release_date": "1987-06-17",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/tw/89716,0v1/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/tw/89716,0v1/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/tw/89716,0v1/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "CluDKLYxr1GFQqLSZt",
          "name": "Dexter Gordon",
          "url": "https://event.kkbox.com/content/artist/CluDKLYxr1GFQqLSZt",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/global/4547,0v486/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/global/4547,0v486/fit/300x300.jpg"
            }
          ]
        }
      }
    },
    {
      "id": "GkwkUu7-nSw3RcCqE9",
      "name": "Cheese Cake",
      "duration": 321689,
      "url": "https://event.kkbox.com/content/song/GkwkUu7-nSw3RcCqE9",
      "track_number": 2,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY",
        "JP"
      ],
      "album": {
        "id": "Ksh_HHNedkIB-GLKVK",
        "name": "Go!",
        "url": "https://event.kkbox.com/content/album/Ksh_HHNedkIB-GLKVK",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "release_date": "1999-03-11",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/tw/60368,0v1/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/tw/60368,0v1/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/tw/60368,0v1/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "CluDKLYxr1GFQqLSZt",
          "name": "Dexter Gordon",
          "url": "https://event.kkbox.com/content/artist/CluDKLYxr1GFQqLSZt",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/global/4547,0v486/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/global/4547,0v486/fit/300x300.jpg"
            }
          ]
        }
      }
    },
    {
      "id": "8tFVSAfjsnPsEuBX1B",
      "name": "For Sentimental Reasons",
      "duration": 410157,
      "url": "https://event.kkbox.com/content/song/8tFVSAfjsnPsEuBX1B",
      "track_number": 1,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY",
        "JP"
      ],
      "album": {
        "id": "Cmmy884WAc3pyXTYea",
        "name": "The Art Of The Ballad",
        "url": "https://event.kkbox.com/content/album/Cmmy884WAc3pyXTYea",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "release_date": "2008-04-14",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/tw/103820,0v1/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/tw/103820,0v1/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/tw/103820,0v1/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "CluDKLYxr1GFQqLSZt",
          "name": "Dexter Gordon",
          "url": "https://event.kkbox.com/content/artist/CluDKLYxr1GFQqLSZt",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/global/4547,0v486/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/global/4547,0v486/fit/300x300.jpg"
            }
          ]
        }
      }
    },
    {
      "id": "1ZNLS-68mUN-7imS6g",
      "name": "Where Are You",
      "duration": 393392,
      "url": "https://event.kkbox.com/content/song/1ZNLS-68mUN-7imS6g",
      "track_number": 1,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY",
        "JP"
      ],
      "album": {
        "id": "Ksh_HHNedkIB-GLKVK",
        "name": "Go!",
        "url": "https://event.kkbox.com/content/album/Ksh_HHNedkIB-GLKVK",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "release_date": "1999-03-11",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/tw/60368,0v1/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/tw/60368,0v1/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/tw/60368,0v1/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "CluDKLYxr1GFQqLSZt",
          "name": "Dexter Gordon",
          "url": "https://event.kkbox.com/content/artist/CluDKLYxr1GFQqLSZt",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/global/4547,0v486/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/global/4547,0v486/fit/300x300.jpg"
            }
          ]
        }
      }
    }
  ],
  "paging": {
    "offset": 0,
    "limit": 5,
    "previous": null,
    "next": "https://api.kkbox.com/v1.1/artists/CluDKLYxr1GFQqLSZt/top-tracks?limit=5&offset=5"
  },
  "summary": {
    "total": 30
  }
}

Path Params

artist_id
string
required

藝人 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

limit
string

每頁返回的結果數量,最多不能超過 500

offset
int32

跳過頁數

 
Suggest Edits

/artists/{artist_id}/related-artists

透過 {artist_id} 取得與該藝人關連性高的藝人列表

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/artists/artist_id/related-artists
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/artists/8q3_xzjl89Yakn_7GB/related-artists?territory=TW&offset=0&limit=500' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/artists/8q3_xzjl89Yakn_7GB/related-artists?territory=TW&offset=0&limit=500")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/artists/8q3_xzjl89Yakn_7GB/related-artists?territory=TW&offset=0&limit=500",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/artists/8q3_xzjl89Yakn_7GB/related-artists?territory=TW&offset=0&limit=500", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/artists/8q3_xzjl89Yakn_7GB/related-artists?territory=TW&offset=0&limit=500",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/artists/8q3_xzjl89Yakn_7GB/related-artists?territory=TW&offset=0&limit=500"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "Wpilq65t_aFRE8uo74",
      "name": "John Lennon",
      "url": "https://event.kkbox.com/content/artist/Wpilq65t_aFRE8uo74",
      "images": [
        {
          "height": 160,
          "width": 160,
          "url": "https://i.kfs.io/artist/global/3276,0v3/fit/160x160.jpg"
        },
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/artist/global/3276,0v3/fit/300x300.jpg"
        }
      ]
    },
    {
      "id": "WsepDmTku7eU2wtwQc",
      "name": "Paul McCartney",
      "url": "https://event.kkbox.com/content/artist/WsepDmTku7eU2wtwQc",
      "images": [
        {
          "height": 160,
          "width": 160,
          "url": "https://i.kfs.io/artist/global/3189,0v1/fit/160x160.jpg"
        },
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/artist/global/3189,0v1/fit/300x300.jpg"
        }
      ]
    },
    {
      "id": "GnBlYTRjnXAaTtkR1H",
      "name": "George Harrison",
      "url": "https://event.kkbox.com/content/artist/GnBlYTRjnXAaTtkR1H",
      "images": [
        {
          "height": 160,
          "width": 160,
          "url": "https://i.kfs.io/artist/global/3426,0v19/fit/160x160.jpg"
        },
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/artist/global/3426,0v19/fit/300x300.jpg"
        }
      ]
    },
    {
      "id": "HY0Pxt2oa-MNW8J9cR",
      "name": "Ringo Starr",
      "url": "https://event.kkbox.com/content/artist/HY0Pxt2oa-MNW8J9cR",
      "images": [
        {
          "height": 160,
          "width": 160,
          "url": "https://i.kfs.io/artist/global/27901,0v18/fit/160x160.jpg"
        },
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/artist/global/27901,0v18/fit/300x300.jpg"
        }
      ]
    }
  ],
  "paging": {
    "offset": 0,
    "limit": 20,
    "previous": null,
    "next": null
  },
  "summary": {
    "total": 4
  }
}

Path Params

artist_id
string
required

藝人 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

limit
int32

每頁返回的結果數量,最多不能超過 20

offset
int32

跳過頁數

 
Suggest Edits

Shared Playlists

 

來自 KKBOX 用戶公開分享的個人歌單。可透過 /search type 指定 playlist 搜尋到。

Suggest Edits

/shared-playlists/{playlist_id}

透過 {playlist_id} 取得該分享歌單的資訊

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/shared-playlists/playlist_id
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/shared-playlists/4nUZM-TY2aVxZ2xaA-?territory=TW' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/shared-playlists/4nUZM-TY2aVxZ2xaA-?territory=TW")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/shared-playlists/4nUZM-TY2aVxZ2xaA-?territory=TW",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/shared-playlists/4nUZM-TY2aVxZ2xaA-?territory=TW", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/shared-playlists/4nUZM-TY2aVxZ2xaA-?territory=TW",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/shared-playlists/4nUZM-TY2aVxZ2xaA-?territory=TW"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "tracks": {
    "data": [
      {
        "id": "SsJItLYfDXYxalPgtU",
        "name": "這個世界",
        "duration": 240195,
        "url": "https://event.kkbox.com/content/song/SsJItLYfDXYxalPgtU",
        "track_number": 12,
        "explicitness": false,
        "available_territories": [
          "TW"
        ],
        "album": {
          "id": "CnWnDaRF4d6Z3EgCnv",
          "name": "這個世界 (This World)",
          "url": "https://event.kkbox.com/content/album/CnWnDaRF4d6Z3EgCnv",
          "explicitness": false,
          "available_territories": [
            "TW"
          ],
          "release_date": "2016-10-12",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/global/19151099,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/global/19151099,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/global/19151099,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "-lm_2ldXI0rBCMeriC",
            "name": "蔡藍欽",
            "url": "https://event.kkbox.com/content/artist/-lm_2ldXI0rBCMeriC",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/4979,0v1/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/4979,0v1/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "-kQ0G1lzMveSbRJI1h",
        "name": "這個世界",
        "duration": 268956,
        "url": "https://event.kkbox.com/content/song/-kQ0G1lzMveSbRJI1h",
        "track_number": 25,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "album": {
          "id": "KqoKCbzKOnJP4qBEAZ",
          "name": "當我們混在一起 2005 演唱會 Live 全記錄",
          "url": "https://event.kkbox.com/content/album/KqoKCbzKOnJP4qBEAZ",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY",
            "JP"
          ],
          "release_date": "2005-05-27",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/54709,0v3/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/54709,0v3/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/54709,0v3/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "9XN-7yg5vg3gYnCdsM",
            "name": "五月天 (Mayday)",
            "url": "https://event.kkbox.com/content/artist/9XN-7yg5vg3gYnCdsM",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/6651,0v9/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/6651,0v9/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "0oVpLhDXhv4OSjm_fJ",
        "name": "這個世界",
        "duration": 234370,
        "url": "https://event.kkbox.com/content/song/0oVpLhDXhv4OSjm_fJ",
        "track_number": 6,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "album": {
          "id": "__v-2rnU8IHVqOOmz9",
          "name": "黃鶯鶯搖籃曲",
          "url": "https://event.kkbox.com/content/album/__v-2rnU8IHVqOOmz9",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY",
            "JP"
          ],
          "release_date": "2012-07-02",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/352143,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/352143,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/352143,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "GsuNkAHedyFlIFnpAU",
            "name": "黃鶯鶯 (Tracy Huang)",
            "url": "https://event.kkbox.com/content/artist/GsuNkAHedyFlIFnpAU",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/363,0v1/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/363,0v1/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "Gl5PVJTpylVNEdjV83",
        "name": "這個世界",
        "duration": 182961,
        "url": "https://event.kkbox.com/content/song/Gl5PVJTpylVNEdjV83",
        "track_number": 3,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK"
        ],
        "album": {
          "id": "Grvf3dwZSVBLbO_3uD",
          "name": "夏樹的期待-黃建為音樂故事EP",
          "url": "https://event.kkbox.com/content/album/Grvf3dwZSVBLbO_3uD",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK"
          ],
          "release_date": "2007-07-30",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/93750,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/93750,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/93750,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "9ajzwD_q8L4InP_8Yu",
            "name": "黃建為",
            "url": "https://event.kkbox.com/content/artist/9ajzwD_q8L4InP_8Yu",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/21756,0v4/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/21756,0v4/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "-oiIln1-e7WVLDU48L",
        "name": "這個世界",
        "duration": 220682,
        "url": "https://event.kkbox.com/content/song/-oiIln1-e7WVLDU48L",
        "track_number": 25,
        "explicitness": false,
        "available_territories": [
          "TW",
          "JP"
        ],
        "album": {
          "id": "8s0yeK6TI8uiqdCcmx",
          "name": "永恆金曲 影音典藏精選 (Ultimate Jeff Chang)",
          "url": "https://event.kkbox.com/content/album/8s0yeK6TI8uiqdCcmx",
          "explicitness": false,
          "available_territories": [
            "TW",
            "JP"
          ],
          "release_date": "2014-07-04",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/4247039,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/4247039,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/4247039,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "LZ5XE3V1w4lbhvgqpN",
            "name": "張信哲 (Jeff Chang)",
            "url": "https://event.kkbox.com/content/artist/LZ5XE3V1w4lbhvgqpN",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/1935,0v20/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/1935,0v20/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "WlQ7AW7hHya3DJrUwR",
        "name": "這個世界",
        "duration": 260702,
        "url": "https://event.kkbox.com/content/song/WlQ7AW7hHya3DJrUwR",
        "track_number": 5,
        "explicitness": false,
        "available_territories": [
          "TW",
          "SG",
          "MY",
          "JP"
        ],
        "album": {
          "id": "Gm5YZ7Pkte5pDqOAym",
          "name": "砂礫",
          "url": "https://event.kkbox.com/content/album/Gm5YZ7Pkte5pDqOAym",
          "explicitness": false,
          "available_territories": [
            "TW",
            "SG",
            "MY",
            "JP"
          ],
          "release_date": "2015-06-30",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/global/6869119,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/global/6869119,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/global/6869119,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "9__gCzeJGTMFK-hL_h",
            "name": "陳永龍",
            "url": "https://event.kkbox.com/content/artist/9__gCzeJGTMFK-hL_h",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/49691,0v3/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/49691,0v3/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "Gky6sg7-nSw3QDG0D6",
        "name": "這個世界",
        "duration": 217663,
        "url": "https://event.kkbox.com/content/song/Gky6sg7-nSw3QDG0D6",
        "track_number": 6,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY"
        ],
        "album": {
          "id": "0t2OsmRsK_vh-iXotN",
          "name": "眼球先生的這個世界",
          "url": "https://event.kkbox.com/content/album/0t2OsmRsK_vh-iXotN",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY"
          ],
          "release_date": "2010-01-06",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/140451,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/140451,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/140451,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "8qfqtzjl89YamthC8L",
            "name": "眼球先生",
            "url": "https://event.kkbox.com/content/artist/8qfqtzjl89YamthC8L",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/12422,0v1/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/12422,0v1/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "4lfJzlnq9Z5EbF9AI3",
        "name": "這個世界",
        "duration": 228437,
        "url": "https://event.kkbox.com/content/song/4lfJzlnq9Z5EbF9AI3",
        "track_number": 2,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY"
        ],
        "album": {
          "id": "0t2OsmRsK_vh-iXotN",
          "name": "眼球先生的這個世界",
          "url": "https://event.kkbox.com/content/album/0t2OsmRsK_vh-iXotN",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY"
          ],
          "release_date": "2010-01-06",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/140451,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/140451,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/140451,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "8qfqtzjl89YamthC8L",
            "name": "眼球先生",
            "url": "https://event.kkbox.com/content/artist/8qfqtzjl89YamthC8L",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/12422,0v1/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/12422,0v1/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "OtNNztzt3DzwZYikO6",
        "name": "這個世界",
        "duration": 291968,
        "url": "https://event.kkbox.com/content/song/OtNNztzt3DzwZYikO6",
        "track_number": 8,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "album": {
          "id": "8kUKk3p-GTiCJGjksr",
          "name": "音樂家庭2 -美麗的假期",
          "url": "https://event.kkbox.com/content/album/8kUKk3p-GTiCJGjksr",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY",
            "JP"
          ],
          "release_date": "1999-00-00",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/26943,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/26943,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/26943,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "4quBLsuwBSuh2uptkv",
            "name": "孫建平",
            "url": "https://event.kkbox.com/content/artist/4quBLsuwBSuh2uptkv",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/5896,0v1/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/5896,0v1/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "SpdWAa8c1sYnoczBUa",
        "name": "這個世界 (This World)",
        "duration": 228205,
        "url": "https://event.kkbox.com/content/song/SpdWAa8c1sYnoczBUa",
        "track_number": 2,
        "explicitness": false,
        "available_territories": [
          "TW"
        ],
        "album": {
          "id": "XXT7zI5qEjhjDAVmn0",
          "name": "許一個願望 Make A Wish",
          "url": "https://event.kkbox.com/content/album/XXT7zI5qEjhjDAVmn0",
          "explicitness": false,
          "available_territories": [
            "TW"
          ],
          "release_date": "2012-03-09",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/322125,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/322125,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/322125,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "L_mqUUz6gunFMEq5a0",
            "name": "賈靜雯",
            "url": "https://event.kkbox.com/content/artist/L_mqUUz6gunFMEq5a0",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/203187,0v1/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/203187,0v1/fit/300x300.jpg"
              }
            ]
          }
        }
      }
    ],
    "paging": {
      "offset": 0,
      "limit": 100,
      "previous": null,
      "next": null
    },
    "summary": {
      "total": 10
    }
  },
  "id": "4nUZM-TY2aVxZ2xaA-",
  "title": "各種版本的「這個世界」",
  "description": "原來曾經有這麼多人重唱過「你的世界」",
  "url": "https://event.kkbox.com/content/playlist/4nUZM-TY2aVxZ2xaA-",
  "images": [
    {
      "height": 300,
      "width": 300,
      "url": "https://i.kfs.io/playlist/global/39885447v1/cropresize/300x300.jpg"
    },
    {
      "height": 600,
      "width": 600,
      "url": "https://i.kfs.io/playlist/global/39885447v1/cropresize/600x600.jpg"
    },
    {
      "height": 1000,
      "width": 1000,
      "url": "https://i.kfs.io/playlist/global/39885447v1/cropresize/1000x1000.jpg"
    }
  ],
  "updated_at": "2016-10-18T08:15:09+00:00",
  "owner": {
    "id": "CoiM4s7qXvCTQBLstX",
    "name": "澳門首家線上賭場"
  }
}

Path Params

playlist_id
string
required

歌單 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

 
Suggest Edits

/shared-playlists/{playlist_id}/tracks

透過 {playlist_id} 取得該分享歌單的歌曲列表

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/shared-playlists/playlist_id/tracks
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/shared-playlists/4nUZM-TY2aVxZ2xaA-/tracks?territory=TW&offset=0&limit=500' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/shared-playlists/4nUZM-TY2aVxZ2xaA-/tracks?territory=TW&offset=0&limit=500")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/shared-playlists/4nUZM-TY2aVxZ2xaA-/tracks?territory=TW&offset=0&limit=500",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/shared-playlists/4nUZM-TY2aVxZ2xaA-/tracks?territory=TW&offset=0&limit=500", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/shared-playlists/4nUZM-TY2aVxZ2xaA-/tracks?territory=TW&offset=0&limit=500",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/shared-playlists/4nUZM-TY2aVxZ2xaA-/tracks?territory=TW&offset=0&limit=500"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "LZkCyJWMMFHaj-TO7m",
      "name": "Not Afraid Anymore",
      "duration": 226719,
      "url": "https://event.kkbox.com/content/song/LZkCyJWMMFHaj-TO7m",
      "track_number": 1,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY",
        "JP"
      ],
      "album": {
        "id": "8mr11p1liKnsnDhqEF",
        "name": "Not Afraid Anymore",
        "url": "https://event.kkbox.com/content/album/8mr11p1liKnsnDhqEF",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "release_date": "2017-01-13",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/global/21818054,0v1/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/global/21818054,0v1/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/global/21818054,0v1/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "PZgYvhZg4cM7vAA2DW",
          "name": "Halsey",
          "url": "https://event.kkbox.com/content/artist/PZgYvhZg4cM7vAA2DW",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/global/3338232,0v8/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/global/3338232,0v8/fit/300x300.jpg"
            }
          ]
        }
      }
    },
    {
      "id": "OseG-8qU8UtszwJlXm",
      "name": "開門關門",
      "duration": 208979,
      "url": "https://event.kkbox.com/content/song/OseG-8qU8UtszwJlXm",
      "track_number": 10,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY",
        "JP"
      ],
      "album": {
        "id": "4lGaKhRh6lesfP_pvT",
        "name": "52Hz, I Love You",
        "url": "https://event.kkbox.com/content/album/4lGaKhRh6lesfP_pvT",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "release_date": "2017-01-26",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/global/22034915,0v1/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/global/22034915,0v1/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/global/22034915,0v1/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "LY5scHimqDphGqy41I",
          "name": "Various Artists",
          "url": "https://event.kkbox.com/content/artist/LY5scHimqDphGqy41I",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/tw/noimg/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/tw/noimg/fit/300x300.jpg"
            }
          ]
        }
      }
    },
    {
      "id": "Kl8bTlB4BZNACUxeAi",
      "name": "Beauty and the Beast",
      "duration": 227927,
      "url": "https://event.kkbox.com/content/song/Kl8bTlB4BZNACUxeAi",
      "track_number": 1,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY"
      ],
      "album": {
        "id": "Gn-oN41HPEfODw75Ah",
        "name": "Beauty and the Beast",
        "url": "https://event.kkbox.com/content/album/Gn-oN41HPEfODw75Ah",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY"
        ],
        "release_date": "2017-02-03",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/global/22396256,2v1/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/global/22396256,2v1/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/global/22396256,2v1/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "L_yJ1jz6gunFPJ02QF",
          "name": "Ariana Grande, John Legend",
          "url": "https://event.kkbox.com/content/artist/L_yJ1jz6gunFPJ02QF",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/global/7610849,0v3/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/global/7610849,0v3/fit/300x300.jpg"
            }
          ]
        }
      }
    }
  ],
  "paging": {
    "offset": 0,
    "limit": 3,
    "previous": null,
    "next": "https://api.kkbox.com/v1.1/shared-playlists/-meJqWeQgu9_xxSLSy/tracks?limit=3&offset=3"
  },
  "summary": {
    "total": 102
  }
}

Path Params

playlist_id
string
required

歌單 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

limit
int32

每頁返回的結果數量,最多不能超過 500

offset
int32

跳過頁數

 
Suggest Edits

/featured-playlists

取得最新主題歌單列表

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/featured-playlists
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/featured-playlists?territory=TW&offset=0&limit=500' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/featured-playlists?territory=TW&offset=0&limit=500")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/featured-playlists?territory=TW&offset=0&limit=500",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/featured-playlists?territory=TW&offset=0&limit=500", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/featured-playlists?territory=TW&offset=0&limit=500",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/featured-playlists?territory=TW&offset=0&limit=500"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "Wt95My35CqR9hB_FW1",
      "title": "一起複習少女時代的十年輝煌時刻!",
      "description": "2007年8月,少女時代以同名專輯於韓國出道,可人的少女形象深入人心,十年來靠著努力與實力獲得人氣,也在樂壇創造不少紀錄,膾炙人口的歌曲更是不計其數。",
      "url": "https://event.kkbox.com/content/playlist/Wt95My35CqR9hB_FW1",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist/global/11264817v2/cropresize/300x300.jpg"
        },
        {
          "height": 600,
          "width": 600,
          "url": "https://i.kfs.io/playlist/global/11264817v2/cropresize/600x600.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/playlist/global/11264817v2/cropresize/1000x1000.jpg"
        }
      ],
      "updated_at": "2017-08-01T03:59:31+00:00",
      "owner": {
        "id": "D-gh_8TEudW64tRSCs",
        "name": "KKBOX 韓語小編"
      }
    },
    {
      "id": "1Z8QkKMuPcQzOZPBHh",
      "title": "歐爸男神愛吃Subway!熱門韓劇OST",
      "description": "鬼怪.太陽的後裔.K2.信號.被告人~最夯韓劇歐爸都享受著Subway的美味餐點~快來Subway享用鬼怪餐!",
      "url": "https://event.kkbox.com/content/playlist/1Z8QkKMuPcQzOZPBHh",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist/global/59724778v3/cropresize/300x300.jpg"
        },
        {
          "height": 600,
          "width": 600,
          "url": "https://i.kfs.io/playlist/global/59724778v3/cropresize/600x600.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/playlist/global/59724778v3/cropresize/1000x1000.jpg"
        }
      ],
      "updated_at": "2017-08-01T02:13:38+00:00",
      "owner": {
        "id": "4sr2MkSmWI-OwNsrJc",
        "name": "布萊德船長"
      }
    },
    {
      "id": "-meJqWeQgu9_xxSLSy",
      "title": "電影原聲帶爆雷推薦 (更至最新8/1)",
      "description": "聽原聲帶不用擠,「爆雷推薦 」一次全都給你!每月更新台灣地區上映過的院線片原聲帶。你可以慢慢聽、分批聽、一首首聽。",
      "url": "https://event.kkbox.com/content/playlist/-meJqWeQgu9_xxSLSy",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist/global/39934041v14/cropresize/300x300.jpg"
        },
        {
          "height": 600,
          "width": 600,
          "url": "https://i.kfs.io/playlist/global/39934041v14/cropresize/600x600.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/playlist/global/39934041v14/cropresize/1000x1000.jpg"
        }
      ],
      "updated_at": "2017-07-31T08:44:51+00:00",
      "owner": {
        "id": "4nZOCDKORLgbsSWpDb",
        "name": "祖崇"
      }
    },
    {
      "id": "GoLEPA3yeHNvhKYh0W",
      "title": "Boom-bap嘻哈首席製作人DJ Premier",
      "description": "他,就代表Boom-bap。",
      "url": "https://event.kkbox.com/content/playlist/GoLEPA3yeHNvhKYh0W",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist/global/59745018v1/cropresize/300x300.jpg"
        },
        {
          "height": 600,
          "width": 600,
          "url": "https://i.kfs.io/playlist/global/59745018v1/cropresize/600x600.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/playlist/global/59745018v1/cropresize/1000x1000.jpg"
        }
      ],
      "updated_at": "2017-08-01T03:35:59+00:00",
      "owner": {
        "id": "DX-43tMGDz4i_e-lnW",
        "name": "老莫"
      }
    },
    {
      "id": "-kFVLp4ANZlr6BhTgL",
      "title": "這些男歌手都出現在酷娃恰莉的新MV《Boys》",
      "description": "酷娃恰莉日前釋出新歌《Boys》的MV,出演的男明星一字排開,數量與顏值都非常的驚人,其中不乏長相與實力兼具的音樂人,Mark Ronson、Charlie Puth、Diplo等人在MV裡面都有性感演出!",
      "url": "https://event.kkbox.com/content/playlist/-kFVLp4ANZlr6BhTgL",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist/global/59744688v2/cropresize/300x300.jpg"
        },
        {
          "height": 600,
          "width": 600,
          "url": "https://i.kfs.io/playlist/global/59744688v2/cropresize/600x600.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/playlist/global/59744688v2/cropresize/1000x1000.jpg"
        }
      ],
      "updated_at": "2017-08-01T03:49:52+00:00",
      "owner": {
        "id": "5XIttVqe0foATcIFMp",
        "name": "KKBOX 西洋小編"
      }
    }
  ],
  "paging": {
    "offset": 0,
    "limit": 5,
    "previous": null,
    "next": "https://api.kkbox.com/v1.1/featured-playlists?limit=5&territory=TW&offset=5"
  },
  "summary": {
    "total": 30
  }
}

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

 
Suggest Edits

/featured-playlists/{playlist_id}

透過 {playlist_id} 取得該主題歌單的資訊

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/featured-playlists/playlist_id
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/featured-playlists/Wt95My35CqR9hB_FW1?territory=TW' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/featured-playlists/Wt95My35CqR9hB_FW1?territory=TW")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/featured-playlists/Wt95My35CqR9hB_FW1?territory=TW",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/featured-playlists/Wt95My35CqR9hB_FW1?territory=TW", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/featured-playlists/Wt95My35CqR9hB_FW1?territory=TW",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/featured-playlists/Wt95My35CqR9hB_FW1?territory=TW"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "tracks": {
    "data": [
      {
        "id": "SsJItLYfDXYxalPgtU",
        "name": "這個世界",
        "duration": 240195,
        "url": "https://event.kkbox.com/content/song/SsJItLYfDXYxalPgtU",
        "track_number": 12,
        "explicitness": false,
        "available_territories": [
          "TW"
        ],
        "album": {
          "id": "CnWnDaRF4d6Z3EgCnv",
          "name": "這個世界 (This World)",
          "url": "https://event.kkbox.com/content/album/CnWnDaRF4d6Z3EgCnv",
          "explicitness": false,
          "available_territories": [
            "TW"
          ],
          "release_date": "2016-10-12",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/global/19151099,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/global/19151099,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/global/19151099,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "-lm_2ldXI0rBCMeriC",
            "name": "蔡藍欽",
            "url": "https://event.kkbox.com/content/artist/-lm_2ldXI0rBCMeriC",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/4979,0v1/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/4979,0v1/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "-kQ0G1lzMveSbRJI1h",
        "name": "這個世界",
        "duration": 268956,
        "url": "https://event.kkbox.com/content/song/-kQ0G1lzMveSbRJI1h",
        "track_number": 25,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "album": {
          "id": "KqoKCbzKOnJP4qBEAZ",
          "name": "當我們混在一起 2005 演唱會 Live 全記錄",
          "url": "https://event.kkbox.com/content/album/KqoKCbzKOnJP4qBEAZ",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY",
            "JP"
          ],
          "release_date": "2005-05-27",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/54709,0v3/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/54709,0v3/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/54709,0v3/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "9XN-7yg5vg3gYnCdsM",
            "name": "五月天 (Mayday)",
            "url": "https://event.kkbox.com/content/artist/9XN-7yg5vg3gYnCdsM",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/6651,0v9/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/6651,0v9/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "0oVpLhDXhv4OSjm_fJ",
        "name": "這個世界",
        "duration": 234370,
        "url": "https://event.kkbox.com/content/song/0oVpLhDXhv4OSjm_fJ",
        "track_number": 6,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "album": {
          "id": "__v-2rnU8IHVqOOmz9",
          "name": "黃鶯鶯搖籃曲",
          "url": "https://event.kkbox.com/content/album/__v-2rnU8IHVqOOmz9",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY",
            "JP"
          ],
          "release_date": "2012-07-02",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/352143,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/352143,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/352143,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "GsuNkAHedyFlIFnpAU",
            "name": "黃鶯鶯 (Tracy Huang)",
            "url": "https://event.kkbox.com/content/artist/GsuNkAHedyFlIFnpAU",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/363,0v1/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/363,0v1/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "Gl5PVJTpylVNEdjV83",
        "name": "這個世界",
        "duration": 182961,
        "url": "https://event.kkbox.com/content/song/Gl5PVJTpylVNEdjV83",
        "track_number": 3,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK"
        ],
        "album": {
          "id": "Grvf3dwZSVBLbO_3uD",
          "name": "夏樹的期待-黃建為音樂故事EP",
          "url": "https://event.kkbox.com/content/album/Grvf3dwZSVBLbO_3uD",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK"
          ],
          "release_date": "2007-07-30",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/93750,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/93750,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/93750,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "9ajzwD_q8L4InP_8Yu",
            "name": "黃建為",
            "url": "https://event.kkbox.com/content/artist/9ajzwD_q8L4InP_8Yu",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/21756,0v4/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/21756,0v4/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "-oiIln1-e7WVLDU48L",
        "name": "這個世界",
        "duration": 220682,
        "url": "https://event.kkbox.com/content/song/-oiIln1-e7WVLDU48L",
        "track_number": 25,
        "explicitness": false,
        "available_territories": [
          "TW",
          "JP"
        ],
        "album": {
          "id": "8s0yeK6TI8uiqdCcmx",
          "name": "永恆金曲 影音典藏精選 (Ultimate Jeff Chang)",
          "url": "https://event.kkbox.com/content/album/8s0yeK6TI8uiqdCcmx",
          "explicitness": false,
          "available_territories": [
            "TW",
            "JP"
          ],
          "release_date": "2014-07-04",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/4247039,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/4247039,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/4247039,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "LZ5XE3V1w4lbhvgqpN",
            "name": "張信哲 (Jeff Chang)",
            "url": "https://event.kkbox.com/content/artist/LZ5XE3V1w4lbhvgqpN",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/1935,0v20/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/1935,0v20/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "WlQ7AW7hHya3DJrUwR",
        "name": "這個世界",
        "duration": 260702,
        "url": "https://event.kkbox.com/content/song/WlQ7AW7hHya3DJrUwR",
        "track_number": 5,
        "explicitness": false,
        "available_territories": [
          "TW",
          "SG",
          "MY",
          "JP"
        ],
        "album": {
          "id": "Gm5YZ7Pkte5pDqOAym",
          "name": "砂礫",
          "url": "https://event.kkbox.com/content/album/Gm5YZ7Pkte5pDqOAym",
          "explicitness": false,
          "available_territories": [
            "TW",
            "SG",
            "MY",
            "JP"
          ],
          "release_date": "2015-06-30",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/global/6869119,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/global/6869119,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/global/6869119,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "9__gCzeJGTMFK-hL_h",
            "name": "陳永龍",
            "url": "https://event.kkbox.com/content/artist/9__gCzeJGTMFK-hL_h",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/49691,0v3/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/49691,0v3/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "Gky6sg7-nSw3QDG0D6",
        "name": "這個世界",
        "duration": 217663,
        "url": "https://event.kkbox.com/content/song/Gky6sg7-nSw3QDG0D6",
        "track_number": 6,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY"
        ],
        "album": {
          "id": "0t2OsmRsK_vh-iXotN",
          "name": "眼球先生的這個世界",
          "url": "https://event.kkbox.com/content/album/0t2OsmRsK_vh-iXotN",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY"
          ],
          "release_date": "2010-01-06",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/140451,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/140451,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/140451,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "8qfqtzjl89YamthC8L",
            "name": "眼球先生",
            "url": "https://event.kkbox.com/content/artist/8qfqtzjl89YamthC8L",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/12422,0v1/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/12422,0v1/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "4lfJzlnq9Z5EbF9AI3",
        "name": "這個世界",
        "duration": 228437,
        "url": "https://event.kkbox.com/content/song/4lfJzlnq9Z5EbF9AI3",
        "track_number": 2,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY"
        ],
        "album": {
          "id": "0t2OsmRsK_vh-iXotN",
          "name": "眼球先生的這個世界",
          "url": "https://event.kkbox.com/content/album/0t2OsmRsK_vh-iXotN",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY"
          ],
          "release_date": "2010-01-06",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/140451,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/140451,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/140451,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "8qfqtzjl89YamthC8L",
            "name": "眼球先生",
            "url": "https://event.kkbox.com/content/artist/8qfqtzjl89YamthC8L",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/12422,0v1/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/12422,0v1/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "OtNNztzt3DzwZYikO6",
        "name": "這個世界",
        "duration": 291968,
        "url": "https://event.kkbox.com/content/song/OtNNztzt3DzwZYikO6",
        "track_number": 8,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "album": {
          "id": "8kUKk3p-GTiCJGjksr",
          "name": "音樂家庭2 -美麗的假期",
          "url": "https://event.kkbox.com/content/album/8kUKk3p-GTiCJGjksr",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY",
            "JP"
          ],
          "release_date": "1999-00-00",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/26943,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/26943,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/26943,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "4quBLsuwBSuh2uptkv",
            "name": "孫建平",
            "url": "https://event.kkbox.com/content/artist/4quBLsuwBSuh2uptkv",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/5896,0v1/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/5896,0v1/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "SpdWAa8c1sYnoczBUa",
        "name": "這個世界 (This World)",
        "duration": 228205,
        "url": "https://event.kkbox.com/content/song/SpdWAa8c1sYnoczBUa",
        "track_number": 2,
        "explicitness": false,
        "available_territories": [
          "TW"
        ],
        "album": {
          "id": "XXT7zI5qEjhjDAVmn0",
          "name": "許一個願望 Make A Wish",
          "url": "https://event.kkbox.com/content/album/XXT7zI5qEjhjDAVmn0",
          "explicitness": false,
          "available_territories": [
            "TW"
          ],
          "release_date": "2012-03-09",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/322125,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/322125,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/322125,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "L_mqUUz6gunFMEq5a0",
            "name": "賈靜雯",
            "url": "https://event.kkbox.com/content/artist/L_mqUUz6gunFMEq5a0",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/203187,0v1/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/203187,0v1/fit/300x300.jpg"
              }
            ]
          }
        }
      }
    ],
    "paging": {
      "offset": 0,
      "limit": 100,
      "previous": null,
      "next": null
    },
    "summary": {
      "total": 10
    }
  },
  "id": "4nUZM-TY2aVxZ2xaA-",
  "title": "各種版本的「這個世界」",
  "description": "原來曾經有這麼多人重唱過「你的世界」",
  "url": "https://event.kkbox.com/content/playlist/4nUZM-TY2aVxZ2xaA-",
  "images": [
    {
      "height": 300,
      "width": 300,
      "url": "https://i.kfs.io/playlist/global/39885447v1/cropresize/300x300.jpg"
    },
    {
      "height": 600,
      "width": 600,
      "url": "https://i.kfs.io/playlist/global/39885447v1/cropresize/600x600.jpg"
    },
    {
      "height": 1000,
      "width": 1000,
      "url": "https://i.kfs.io/playlist/global/39885447v1/cropresize/1000x1000.jpg"
    }
  ],
  "updated_at": "2016-10-18T08:15:09+00:00",
  "owner": {
    "id": "CoiM4s7qXvCTQBLstX",
    "name": "澳門首家線上賭場"
  }
}

Path Params

playlist_id
string
required

歌單 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

 
Suggest Edits

/featured-playlists/{playlist_id}/tracks

透過 {playlist_id} 取得該主題歌單的歌曲列表

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/featured-playlists/playlist_id/tracks
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/featured-playlists/Wt95My35CqR9hB_FW1/tracks?territory=TW&offset=0&limit=500' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/featured-playlists/Wt95My35CqR9hB_FW1/tracks?territory=TW&offset=0&limit=500")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/featured-playlists/Wt95My35CqR9hB_FW1/tracks?territory=TW&offset=0&limit=500",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/featured-playlists/Wt95My35CqR9hB_FW1/tracks?territory=TW&offset=0&limit=500", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/featured-playlists/Wt95My35CqR9hB_FW1/tracks?territory=TW&offset=0&limit=500",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/featured-playlists/Wt95My35CqR9hB_FW1/tracks?territory=TW&offset=0&limit=500"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "LZkCyJWMMFHaj-TO7m",
      "name": "Not Afraid Anymore",
      "duration": 226719,
      "url": "https://event.kkbox.com/content/song/LZkCyJWMMFHaj-TO7m",
      "track_number": 1,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY",
        "JP"
      ],
      "album": {
        "id": "8mr11p1liKnsnDhqEF",
        "name": "Not Afraid Anymore",
        "url": "https://event.kkbox.com/content/album/8mr11p1liKnsnDhqEF",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "release_date": "2017-01-13",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/global/21818054,0v1/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/global/21818054,0v1/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/global/21818054,0v1/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "PZgYvhZg4cM7vAA2DW",
          "name": "Halsey",
          "url": "https://event.kkbox.com/content/artist/PZgYvhZg4cM7vAA2DW",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/global/3338232,0v8/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/global/3338232,0v8/fit/300x300.jpg"
            }
          ]
        }
      }
    },
    {
      "id": "OseG-8qU8UtszwJlXm",
      "name": "開門關門",
      "duration": 208979,
      "url": "https://event.kkbox.com/content/song/OseG-8qU8UtszwJlXm",
      "track_number": 10,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY",
        "JP"
      ],
      "album": {
        "id": "4lGaKhRh6lesfP_pvT",
        "name": "52Hz, I Love You",
        "url": "https://event.kkbox.com/content/album/4lGaKhRh6lesfP_pvT",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "release_date": "2017-01-26",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/global/22034915,0v1/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/global/22034915,0v1/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/global/22034915,0v1/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "LY5scHimqDphGqy41I",
          "name": "Various Artists",
          "url": "https://event.kkbox.com/content/artist/LY5scHimqDphGqy41I",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/tw/noimg/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/tw/noimg/fit/300x300.jpg"
            }
          ]
        }
      }
    },
    {
      "id": "Kl8bTlB4BZNACUxeAi",
      "name": "Beauty and the Beast",
      "duration": 227927,
      "url": "https://event.kkbox.com/content/song/Kl8bTlB4BZNACUxeAi",
      "track_number": 1,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY"
      ],
      "album": {
        "id": "Gn-oN41HPEfODw75Ah",
        "name": "Beauty and the Beast",
        "url": "https://event.kkbox.com/content/album/Gn-oN41HPEfODw75Ah",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY"
        ],
        "release_date": "2017-02-03",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/global/22396256,2v1/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/global/22396256,2v1/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/global/22396256,2v1/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "L_yJ1jz6gunFPJ02QF",
          "name": "Ariana Grande, John Legend",
          "url": "https://event.kkbox.com/content/artist/L_yJ1jz6gunFPJ02QF",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/global/7610849,0v3/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/global/7610849,0v3/fit/300x300.jpg"
            }
          ]
        }
      }
    }
  ],
  "paging": {
    "offset": 0,
    "limit": 3,
    "previous": null,
    "next": "https://api.kkbox.com/v1.1/shared-playlists/-meJqWeQgu9_xxSLSy/tracks?limit=3&offset=3"
  },
  "summary": {
    "total": 102
  }
}

Path Params

playlist_id
string
required

歌單 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

limit
int32

每頁返回的結果數量,最多不能超過 100

offset
int32

跳過頁數

 
Suggest Edits

/featured-playlist-categories

取得主題歌單類別列表

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/featured-playlist-categories
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/featured-playlist-categories?territory=TW&offset=0&limit=500' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/featured-playlist-categories?territory=TW&offset=0&limit=500")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/featured-playlist-categories?territory=TW&offset=0&limit=500",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/featured-playlist-categories?territory=TW&offset=0&limit=500", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/featured-playlist-categories?territory=TW&offset=0&limit=500",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/featured-playlist-categories?territory=TW&offset=0&limit=500"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "LXUR688EBKRRZydAWb",
      "title": "焦點",
      "images": [
        {
          "height": 150,
          "width": 150,
          "url": "https://i.kfs.io/playlist_folder/global/352v1/cropresize/150x150.jpg"
        },
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist_folder/global/352v1/cropresize/300x300.jpg"
        }
      ]
    },
    {
      "id": "CrBHGk1J1KEsQlPLoz",
      "title": "話題時事",
      "images": [
        {
          "height": 150,
          "width": 150,
          "url": "https://i.kfs.io/playlist_folder/global/77v2/cropresize/150x150.jpg"
        },
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist_folder/global/77v2/cropresize/300x300.jpg"
        }
      ]
    },
    {
      "id": "8kRhaF8gmylBe88AE-",
      "title": "名人推薦",
      "images": [
        {
          "height": 150,
          "width": 150,
          "url": "https://i.kfs.io/playlist_folder/global/410v2/cropresize/150x150.jpg"
        },
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist_folder/global/410v2/cropresize/300x300.jpg"
        }
      ]
    },
    {
      "id": "5YFHwM5RA3GVbGWU-M",
      "title": "HBL",
      "images": [
        {
          "height": 150,
          "width": 150,
          "url": "https://i.kfs.io/playlist_folder/global/608v1/cropresize/150x150.jpg"
        },
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist_folder/global/608v1/cropresize/300x300.jpg"
        }
      ]
    },
    {
      "id": "9-K8y7beYC7DNljcyr",
      "title": "冬",
      "images": [
        {
          "height": 150,
          "width": 150,
          "url": "https://i.kfs.io/playlist_folder/global/548v1/cropresize/150x150.jpg"
        },
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist_folder/global/548v1/cropresize/300x300.jpg"
        }
      ]
    },
    {
      "id": "4qpEIldRGLYN-iSyDF",
      "title": "來開趴",
      "images": [
        {
          "height": 150,
          "width": 150,
          "url": "https://i.kfs.io/playlist_folder/global/99v1/cropresize/150x150.jpg"
        },
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist_folder/global/99v1/cropresize/300x300.jpg"
        }
      ]
    },
    {
      "id": "5YEn4M5RA3GVZdptVp",
      "title": "關於愛",
      "images": [
        {
          "height": 150,
          "width": 150,
          "url": "https://i.kfs.io/playlist_folder/global/102v1/cropresize/150x150.jpg"
        },
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist_folder/global/102v1/cropresize/300x300.jpg"
        }
      ]
    },
    {
      "id": "SqXRoyi-cul2vtG-Fu",
      "title": "KTV",
      "images": [
        {
          "height": 150,
          "width": 150,
          "url": "https://i.kfs.io/playlist_folder/global/497v2/cropresize/150x150.jpg"
        },
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist_folder/global/497v2/cropresize/300x300.jpg"
        }
      ]
    },
    {
      "id": "TZBSLGMMXPEQ40YmL6",
      "title": "放輕鬆",
      "images": [
        {
          "height": 150,
          "width": 150,
          "url": "https://i.kfs.io/playlist_folder/global/101v1/cropresize/150x150.jpg"
        },
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist_folder/global/101v1/cropresize/300x300.jpg"
        }
      ]
    },
    {
      "id": "1-1auKDQWQusWq7eda",
      "title": "愛運動",
      "images": [
        {
          "height": 150,
          "width": 150,
          "url": "https://i.kfs.io/playlist_folder/global/97v1/cropresize/150x150.jpg"
        },
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist_folder/global/97v1/cropresize/300x300.jpg"
        }
      ]
    }
  ],
  "paging": {
    "offset": 0,
    "limit": 10,
    "previous": null,
    "next": "https://api.kkbox.com/v1.1/featured-playlist-categories?limit=10&offset=10"
  },
  "summary": {
    "total": 17
  }
}

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

limit
int32

每頁返回的結果數量,最多不能超過 500

offset
int32

跳過頁數

 
Suggest Edits

/featured-playlist-categories/{category_id}

透過 {category_id} 取得該主題類別的資訊

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/featured-playlist-categories/category_id
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/featured-playlist-categories/LXUR688EBKRRZydAWb?territory=TW' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/featured-playlist-categories/LXUR688EBKRRZydAWb?territory=TW")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/featured-playlist-categories/LXUR688EBKRRZydAWb?territory=TW",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/featured-playlist-categories/LXUR688EBKRRZydAWb?territory=TW", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/featured-playlist-categories/LXUR688EBKRRZydAWb?territory=TW",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/featured-playlist-categories/LXUR688EBKRRZydAWb?territory=TW"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "id": "9XQKD8BJx595ESs_rb",
  "title": "時光機",
  "images": [
    {
      "height": 150,
      "width": 150,
      "url": "https://i.kfs.io/playlist_folder/global/93v1/cropresize/150x150.jpg"
    },
    {
      "height": 300,
      "width": 300,
      "url": "https://i.kfs.io/playlist_folder/global/93v1/cropresize/300x300.jpg"
    }
  ],
  "playlists": {
    "data": [
      {
        "id": "Wt95My35CqR9hB_FW1",
        "title": "一起複習少女時代的十年輝煌時刻!",
        "description": "2007年8月,少女時代以同名專輯於韓國出道,可人的少女形象深入人心,十年來靠著努力與實力獲得人氣,也在樂壇創造不少紀錄,膾炙人口的歌曲更是不計其數。",
        "url": "https://event.kkbox.com/content/playlist/Wt95My35CqR9hB_FW1",
        "images": [
          {
            "height": 300,
            "width": 300,
            "url": "https://i.kfs.io/playlist/global/11264817v2/cropresize/300x300.jpg"
          },
          {
            "height": 600,
            "width": 600,
            "url": "https://i.kfs.io/playlist/global/11264817v2/cropresize/600x600.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/playlist/global/11264817v2/cropresize/1000x1000.jpg"
          }
        ],
        "updated_at": "2017-08-01T03:59:31+00:00",
        "owner": {
          "id": "D-gh_8TEudW64tRSCs",
          "name": "KKBOX 韓語小編"
        }
      },
      {
        "id": "SqeQcqEW219sLIODRZ",
        "title": "美聲天后 孫燕姿 生日快樂!",
        "description": "來自新加坡的 Stefanie 在台出道,發行十二張專輯,也締造了無數華語金曲。",
        "url": "https://event.kkbox.com/content/playlist/SqeQcqEW219sLIODRZ",
        "images": [
          {
            "height": 300,
            "width": 300,
            "url": "https://i.kfs.io/playlist/global/33159760v2/cropresize/300x300.jpg"
          },
          {
            "height": 600,
            "width": 600,
            "url": "https://i.kfs.io/playlist/global/33159760v2/cropresize/600x600.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/playlist/global/33159760v2/cropresize/1000x1000.jpg"
          }
        ],
        "updated_at": "2017-07-23T04:56:51+00:00",
        "owner": {
          "id": "Os-z4yYPRlzOAkzZm3",
          "name": "KKBOX 華語小編"
        }
      },
      {
        "id": "H_Ls8oVhX-E8N6AvjZ",
        "title": "2000s 八年級生的CD player",
        "description": "好、懷念、啊!\r\n這些旋律是不是隨便放,整個感覺都來了~\r\n想當年還要用CD播放器的日子\r\n每一張專輯都有好好收藏、都是珍貴的回憶",
        "url": "https://event.kkbox.com/content/playlist/H_Ls8oVhX-E8N6AvjZ",
        "images": [
          {
            "height": 300,
            "width": 300,
            "url": "https://i.kfs.io/playlist/global/59588458v1/cropresize/300x300.jpg"
          },
          {
            "height": 600,
            "width": 600,
            "url": "https://i.kfs.io/playlist/global/59588458v1/cropresize/600x600.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/playlist/global/59588458v1/cropresize/1000x1000.jpg"
          }
        ],
        "updated_at": "2017-07-05T01:51:35+00:00",
        "owner": {
          "id": "OqKuWe-j7l2Qvo5gH0",
          "name": "輔大之聲_LaylaLee"
        }
      },
      {
        "id": "8mJjba8bdzM74QtEI3",
        "title": "很愛很愛你的青春戀曲",
        "description": "走訪鄉間小路,回憶你我走過的木棉道,轉身別過那熟悉的康橋。美麗台北河畔,響起無數飛揚的旋律,那些年的奔放、青春印記及新不了情,是你我心中沒唱完的歌、沒說出的話、沒有結果的故事......在時代中一路傳唱的戀曲,今夏在河畔,別把悲傷留給自己,我們一起大聲說LOVE\r\n\r\n7/22(六)時值節令大暑之日,\r\n台北河岸音樂季持續熱鬧滾滾,\r\n就讓台北廣播電台所特別製播的特別演出,\r\n幫您沁涼消暑、也幫您的愛情加溫。\r\n\r\n詳情請上 台北旅遊網,或搜尋 台北河岸音樂季",
        "url": "https://event.kkbox.com/content/playlist/8mJjba8bdzM74QtEI3",
        "images": [
          {
            "height": 300,
            "width": 300,
            "url": "https://i.kfs.io/playlist/global/59639713v2/cropresize/300x300.jpg"
          },
          {
            "height": 600,
            "width": 600,
            "url": "https://i.kfs.io/playlist/global/59639713v2/cropresize/600x600.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/playlist/global/59639713v2/cropresize/1000x1000.jpg"
          }
        ],
        "updated_at": "2017-07-18T05:58:40+00:00",
        "owner": {
          "id": "OlNcKO0tJ2-GOgz_64",
          "name": "台北河岸音樂季-青春舞曲"
        }
      },
      {
        "id": "9-GKQ_UoL47LJYUDey",
        "title": "這些歌都20歲了!1997年陪伴我們的華語金曲",
        "description": "",
        "url": "https://event.kkbox.com/content/playlist/9-GKQ_UoL47LJYUDey",
        "images": [
          {
            "height": 300,
            "width": 300,
            "url": "https://i.kfs.io/playlist/global/47199909v1/cropresize/300x300.jpg"
          },
          {
            "height": 600,
            "width": 600,
            "url": "https://i.kfs.io/playlist/global/47199909v1/cropresize/600x600.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/playlist/global/47199909v1/cropresize/1000x1000.jpg"
          }
        ],
        "updated_at": "2017-02-06T02:55:23+00:00",
        "owner": {
          "id": "OkTRqkjXUSh5lYyROH",
          "name": "編輯室 - 阿斯巴甜"
        }
      }
    ],
    "paging": {
      "offset": 0,
      "limit": 100,
      "previous": null,
      "next": "https://api.kkbox.com/v1.1/featured-playlist-categories/9XQKD8BJx595ESs_rb/playlists?territory=TW&offset=100&limit=100"
    },
    "summary": {
      "total": 339
    }
  }
}

Path Params

category_id
string
required

類別 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

 
Suggest Edits

/featured-playlist-categories/{category_id}/playlists

透過 {category_id} 取得該主題類別的歌單列表

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/featured-playlist-categories/category_id/playlists
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/featured-playlist-categories/LXUR688EBKRRZydAWb/playlists?territory=TW&offset=0&limit=100' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/featured-playlist-categories/LXUR688EBKRRZydAWb/playlists?territory=TW&offset=0&limit=100")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/featured-playlist-categories/LXUR688EBKRRZydAWb/playlists?territory=TW&offset=0&limit=100",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/featured-playlist-categories/LXUR688EBKRRZydAWb/playlists?territory=TW&offset=0&limit=100", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/featured-playlist-categories/LXUR688EBKRRZydAWb/playlists?territory=TW&offset=0&limit=100",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/featured-playlist-categories/LXUR688EBKRRZydAWb/playlists?territory=TW&offset=0&limit=100"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "Wt95My35CqR9hB_FW1",
      "title": "一起複習少女時代的十年輝煌時刻!",
      "description": "2007年8月,少女時代以同名專輯於韓國出道,可人的少女形象深入人心,十年來靠著努力與實力獲得人氣,也在樂壇創造不少紀錄,膾炙人口的歌曲更是不計其數。",
      "url": "https://event.kkbox.com/content/playlist/Wt95My35CqR9hB_FW1",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist/global/11264817v2/cropresize/300x300.jpg"
        },
        {
          "height": 600,
          "width": 600,
          "url": "https://i.kfs.io/playlist/global/11264817v2/cropresize/600x600.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/playlist/global/11264817v2/cropresize/1000x1000.jpg"
        }
      ],
      "updated_at": "2017-08-01T03:59:31+00:00",
      "owner": {
        "id": "D-gh_8TEudW64tRSCs",
        "name": "KKBOX 韓語小編"
      }
    },
    {
      "id": "SqeQcqEW219sLIODRZ",
      "title": "美聲天后 孫燕姿 生日快樂!",
      "description": "來自新加坡的 Stefanie 在台出道,發行十二張專輯,也締造了無數華語金曲。",
      "url": "https://event.kkbox.com/content/playlist/SqeQcqEW219sLIODRZ",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist/global/33159760v2/cropresize/300x300.jpg"
        },
        {
          "height": 600,
          "width": 600,
          "url": "https://i.kfs.io/playlist/global/33159760v2/cropresize/600x600.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/playlist/global/33159760v2/cropresize/1000x1000.jpg"
        }
      ],
      "updated_at": "2017-07-23T04:56:51+00:00",
      "owner": {
        "id": "Os-z4yYPRlzOAkzZm3",
        "name": "KKBOX 華語小編"
      }
    },
    {
      "id": "H_Ls8oVhX-E8N6AvjZ",
      "title": "2000s 八年級生的CD player",
      "description": "好、懷念、啊!\r\n這些旋律是不是隨便放,整個感覺都來了~\r\n想當年還要用CD播放器的日子\r\n每一張專輯都有好好收藏、都是珍貴的回憶",
      "url": "https://event.kkbox.com/content/playlist/H_Ls8oVhX-E8N6AvjZ",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist/global/59588458v1/cropresize/300x300.jpg"
        },
        {
          "height": 600,
          "width": 600,
          "url": "https://i.kfs.io/playlist/global/59588458v1/cropresize/600x600.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/playlist/global/59588458v1/cropresize/1000x1000.jpg"
        }
      ],
      "updated_at": "2017-07-05T01:51:35+00:00",
      "owner": {
        "id": "OqKuWe-j7l2Qvo5gH0",
        "name": "輔大之聲_LaylaLee"
      }
    },
    {
      "id": "8mJjba8bdzM74QtEI3",
      "title": "很愛很愛你的青春戀曲",
      "description": "走訪鄉間小路,回憶你我走過的木棉道,轉身別過那熟悉的康橋。美麗台北河畔,響起無數飛揚的旋律,那些年的奔放、青春印記及新不了情,是你我心中沒唱完的歌、沒說出的話、沒有結果的故事......在時代中一路傳唱的戀曲,今夏在河畔,別把悲傷留給自己,我們一起大聲說LOVE\r\n\r\n7/22(六)時值節令大暑之日,\r\n台北河岸音樂季持續熱鬧滾滾,\r\n就讓台北廣播電台所特別製播的特別演出,\r\n幫您沁涼消暑、也幫您的愛情加溫。\r\n\r\n詳情請上 台北旅遊網,或搜尋 台北河岸音樂季",
      "url": "https://event.kkbox.com/content/playlist/8mJjba8bdzM74QtEI3",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist/global/59639713v2/cropresize/300x300.jpg"
        },
        {
          "height": 600,
          "width": 600,
          "url": "https://i.kfs.io/playlist/global/59639713v2/cropresize/600x600.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/playlist/global/59639713v2/cropresize/1000x1000.jpg"
        }
      ],
      "updated_at": "2017-07-18T05:58:40+00:00",
      "owner": {
        "id": "OlNcKO0tJ2-GOgz_64",
        "name": "台北河岸音樂季-青春舞曲"
      }
    },
    {
      "id": "9-GKQ_UoL47LJYUDey",
      "title": "這些歌都20歲了!1997年陪伴我們的華語金曲",
      "description": "",
      "url": "https://event.kkbox.com/content/playlist/9-GKQ_UoL47LJYUDey",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist/global/47199909v1/cropresize/300x300.jpg"
        },
        {
          "height": 600,
          "width": 600,
          "url": "https://i.kfs.io/playlist/global/47199909v1/cropresize/600x600.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/playlist/global/47199909v1/cropresize/1000x1000.jpg"
        }
      ],
      "updated_at": "2017-02-06T02:55:23+00:00",
      "owner": {
        "id": "OkTRqkjXUSh5lYyROH",
        "name": "編輯室 - 阿斯巴甜"
      }
    }
  ],
  "paging": {
    "offset": 0,
    "limit": 5,
    "previous": null,
    "next": "https://api.kkbox.com/v1.1/featured-playlist-categories/9XQKD8BJx595ESs_rb/playlists?limit=5&territory=TW&offset=5"
  },
  "summary": {
    "total": 339
  }
}

Path Params

category_id
string
required

類別 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

limit
int32

每頁返回的結果數量,最多不能超過 100

offset
int32

跳過頁數

 
Suggest Edits

Mood Stations

 

情境電台,各電台的歌單內容,每次回傳的結果是隨機的

Suggest Edits

/mood-stations

取得情境電台列表

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/mood-stations
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/mood-stations?territory=TW&offset=0&limit=500' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/mood-stations?territory=TW&offset=0&limit=500")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/mood-stations?territory=TW&offset=0&limit=500",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/mood-stations?territory=TW&offset=0&limit=500", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/mood-stations?territory=TW&offset=0&limit=500",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/mood-stations?territory=TW&offset=0&limit=500"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "StGZp2ToWq92diPHS7",
      "name": "Work Out",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://a.kfs.io/banner/theme-channel/grey_center/channel_616.png"
        }
      ]
    },
    {
      "id": "CqKi7kny7nlTW42w5M",
      "name": "Party Animal",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://a.kfs.io/banner/theme-channel/grey_center/channel_617.png"
        }
      ]
    },
    {
      "id": "CmJ_Y5mRTWygkTXsYl",
      "name": "Relaxing",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://a.kfs.io/banner/theme-channel/grey_center/channel_618.png"
        }
      ]
    },
    {
      "id": "TZZ4fMCHdJNYqHEf-p",
      "name": "Working Time",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://a.kfs.io/banner/theme-channel/grey_center/channel_619.png"
        }
      ]
    },
    {
      "id": "4tmrBI125HMtMlO9OF",
      "name": "Romantic",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://a.kfs.io/banner/theme-channel/grey_center/channel_620.png"
        }
      ]
    },
    {
      "id": "8oxjHzAAeM8PU8KCw5",
      "name": "Vacation",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://a.kfs.io/banner/theme-channel/grey_center/channel_621.png"
        }
      ]
    },
    {
      "id": "HXvnvb5yEReQJAiNMB",
      "name": "Chill Out",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://a.kfs.io/banner/theme-channel/grey_center/channel_622.png"
        }
      ]
    },
    {
      "id": "9anYIPKMtg7NqGbiy4",
      "name": "Tipsy Night",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://a.kfs.io/banner/theme-channel/grey_center/channel_623.png"
        }
      ]
    },
    {
      "id": "-msVbZnpWLE4CpWBJo",
      "name": "Acoustic Pop",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://a.kfs.io/banner/theme-channel/grey_center/channel_624.png"
        }
      ]
    },
    {
      "id": "OkN0EhmweNQdIEGkor",
      "name": "Hardcore",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://a.kfs.io/banner/theme-channel/grey_center/channel_625.png"
        }
      ]
    }
  ],
  "paging": {
    "offset": 0,
    "limit": 50,
    "previous": null,
    "next": null
  },
  "summary": {
    "total": 10
  }
}

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

 
Suggest Edits

/mood-stations/{station_id}

透過 {station_id} 取得該情境電台的資訊

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/mood-stations/station_id
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/mood-stations/StGZp2ToWq92diPHS7?territory=TW' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/mood-stations/StGZp2ToWq92diPHS7?territory=TW")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/mood-stations/StGZp2ToWq92diPHS7?territory=TW",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/mood-stations/StGZp2ToWq92diPHS7?territory=TW", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/mood-stations/StGZp2ToWq92diPHS7?territory=TW",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/mood-stations/StGZp2ToWq92diPHS7?territory=TW"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "id": "-msVbZnpWLE4CpWBJo",
  "name": "Acoustic Pop",
  "tracks": {
    "data": [
      {
        "id": "GnZOtsn2JNIVKHkJPx",
        "name": "Imagination",
        "duration": 217710,
        "url": "https://event.kkbox.com/content/song/GnZOtsn2JNIVKHkJPx",
        "track_number": 14,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "album": {
          "id": "SmCGV2uygNqlRbPeU8",
          "name": "Handwritten",
          "url": "https://event.kkbox.com/content/album/SmCGV2uygNqlRbPeU8",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY",
            "JP"
          ],
          "release_date": "2015-04-14",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/global/6349857,1v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/global/6349857,1v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/global/6349857,1v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "Sk0i41HwT10-nYR1xg",
            "name": "Shawn Mendes",
            "url": "https://event.kkbox.com/content/artist/Sk0i41HwT10-nYR1xg",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/2302317,0v3/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/2302317,0v3/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "OrLsshVVf78HVJmb7j",
        "name": "Ye Bbo Seo Geu Rae",
        "duration": 186305,
        "url": "https://event.kkbox.com/content/song/OrLsshVVf78HVJmb7j",
        "track_number": 1,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY"
        ],
        "album": {
          "id": "SoOuon0tFOcHe5Ev1b",
          "name": "young",
          "url": "https://event.kkbox.com/content/album/SoOuon0tFOcHe5Ev1b",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY"
          ],
          "release_date": "2015-06-26",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/global/6862412,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/global/6862412,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/global/6862412,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "8sPjQQl8zbMOnRLac4",
            "name": "Standing egg",
            "url": "https://event.kkbox.com/content/artist/8sPjQQl8zbMOnRLac4",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/415564,0v2/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/415564,0v2/fit/300x300.jpg"
              }
            ]
          }
        }
      }
    ],
    "paging": {
      "offset": 0,
      "limit": 100,
      "previous": null,
      "next": null
    },
    "summary": {
      "total": 100
    }
  }
}

Path Params

station_id
string
required

電台 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

 
Suggest Edits

Genre Stations

 

曲風電台,各電台的歌單內容,每次回傳的結果是隨機的

Suggest Edits

/genre-stations

取得曲風電台列表

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/genre-stations
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/genre-stations?territory=TW&offset=0&limit=500' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/genre-stations?territory=TW&offset=0&limit=500")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/genre-stations?territory=TW&offset=0&limit=500",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/genre-stations?territory=TW&offset=0&limit=500", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/genre-stations?territory=TW&offset=0&limit=500",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/genre-stations?territory=TW&offset=0&limit=500"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "TYq3EHFTl-1EOvJM5Y",
      "category": "Mandarin",
      "name": "Mandarin New Release"
    },
    {
      "id": "SrGnPsRNdLGo2-QD4_",
      "category": "Mandarin",
      "name": "Mandopop Male"
    },
    {
      "id": "KmH_kXscZ40s9YgvHo",
      "category": "Mandarin",
      "name": "Mandopop Female"
    },
    {
      "id": "WoqzVWL-LKrtawiYGT",
      "category": "Mandarin",
      "name": "Mandopop Group"
    },
    {
      "id": "DZFgBL_02ygfJq12I0",
      "category": "Mandarin",
      "name": "Mandopop Duet"
    },
    {
      "id": "Wmm-aBHQWjQ0swnWFc",
      "category": "Mandarin",
      "name": "Mandopop Idol"
    },
    {
      "id": "CrUb2t-gr2k6sxUxH5",
      "category": "Mandarin",
      "name": "Love Song"
    },
    {
      "id": "OlKxmKz5tfab39jlx_",
      "category": "Mandarin",
      "name": "Karaoke Hits"
    },
    {
      "id": "LaN6zM2q9ZeLxC790i",
      "category": "Mandarin",
      "name": "Golden Melody Award Winner"
    },
    {
      "id": "Wmn-aBHQWjQ0vtJ5mX",
      "category": "Mandarin",
      "name": "Mandarin Film & TV Songs"
    }
  ],
  "paging": {
    "offset": 0,
    "limit": 10,
    "previous": null,
    "next": "https://api.kkbox.com/v1.1/genre-stations?limit=10&territory=TW&offset=10"
  },
  "summary": {
    "total": 188
  }
}

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

 
Suggest Edits

/genre-stations/{station_id}

透過 {station_id} 取得該曲風電台的資訊

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/genre-stations/station_id
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/genre-stations/TYq3EHFTl-1EOvJM5Y?territory=TW' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/genre-stations/TYq3EHFTl-1EOvJM5Y?territory=TW")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/genre-stations/TYq3EHFTl-1EOvJM5Y?territory=TW",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/genre-stations/TYq3EHFTl-1EOvJM5Y?territory=TW", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/genre-stations/TYq3EHFTl-1EOvJM5Y?territory=TW",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/genre-stations/TYq3EHFTl-1EOvJM5Y?territory=TW"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "category": "Hokkien",
  "id": "9ax4APKMtg7NqOqhNp",
  "name": "Classic Hokkien Duet",
  "tracks": {
    "data": [
      {
        "album": {
          "artist": {
            "id": "_aEHylB6qG5HcOtPdp",
            "images": [
              {
                "height": 160,
                "url": "https://i.kfs.io/artist/global/6065,0v3/fit/160x160.jpg",
                "width": 160
              },
              {
                "height": 300,
                "url": "https://i.kfs.io/artist/global/6065,0v3/fit/300x300.jpg",
                "width": 300
              }
            ],
            "name": "蔡秋鳳",
            "url": "https://event.kkbox.com/content/artist/_aEHylB6qG5HcOtPdp"
          },
          "available_territories": [
            "TW"
          ],
          "explicitness": false,
          "id": "LZ3HkIgu2Z7b0X2hk2",
          "images": [
            {
              "height": 160,
              "url": "https://i.kfs.io/album/tw/319698,0v3/fit/160x160.jpg",
              "width": 160
            },
            {
              "height": 500,
              "url": "https://i.kfs.io/album/tw/319698,0v3/fit/500x500.jpg",
              "width": 500
            },
            {
              "height": 1000,
              "url": "https://i.kfs.io/album/tw/319698,0v3/fit/1000x1000.jpg",
              "width": 1000
            }
          ],
          "name": "問韓信",
          "release_date": "2011-12-16",
          "url": "https://event.kkbox.com/content/album/LZ3HkIgu2Z7b0X2hk2"
        },
        "available_territories": [
          "TW"
        ],
        "duration": 286302,
        "explicitness": false,
        "id": "GoaqbjSgV7_OdENewN",
        "name": "終點站",
        "track_number": 4,
        "url": "https://event.kkbox.com/content/song/GoaqbjSgV7_OdENewN"
      },
      {
        "album": {
          "artist": {
            "id": "KtmWH9Jnpx6uiVKtBP",
            "images": [
              {
                "height": 160,
                "url": "https://i.kfs.io/artist/global/8191,0v2/fit/160x160.jpg",
                "width": 160
              },
              {
                "height": 300,
                "url": "https://i.kfs.io/artist/global/8191,0v2/fit/300x300.jpg",
                "width": 300
              }
            ],
            "name": "陳淑萍",
            "url": "https://event.kkbox.com/content/artist/KtmWH9Jnpx6uiVKtBP"
          },
          "available_territories": [
            "TW"
          ],
          "explicitness": false,
          "id": "Gpemn2zjWop22LAy8-",
          "images": [
            {
              "height": 160,
              "url": "https://i.kfs.io/album/tw/5447736,0v1/fit/160x160.jpg",
              "width": 160
            },
            {
              "height": 500,
              "url": "https://i.kfs.io/album/tw/5447736,0v1/fit/500x500.jpg",
              "width": 500
            },
            {
              "height": 1000,
              "url": "https://i.kfs.io/album/tw/5447736,0v1/fit/1000x1000.jpg",
              "width": 1000
            }
          ],
          "name": "阮的幸福",
          "release_date": "2014-11-26",
          "url": "https://event.kkbox.com/content/album/Gpemn2zjWop22LAy8-"
        },
        "available_territories": [
          "TW"
        ],
        "duration": 330292,
        "explicitness": false,
        "id": "0pQjOwJVMinpX1LTtN",
        "name": "情緣路",
        "track_number": 2,
        "url": "https://event.kkbox.com/content/song/0pQjOwJVMinpX1LTtN"
      }
    ],
    "paging": {
      "offset": 0,
      "limit": 100,
      "previous": null,
      "next": null
    },
    "summary": {
      "total": 100
    }
  }
}

Path Params

station_id
string
required

電台 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

 
Suggest Edits

New Release Categories

 

各類別的最新發行歌單

Suggest Edits

/new-release-categories

取得最新發行類別列表

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/new-release-categories
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/new-release-categories?territory=TW&offset=0&limit=500' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/new-release-categories?territory=TW&offset=0&limit=500")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/new-release-categories?territory=TW&offset=0&limit=500",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/new-release-categories?territory=TW&offset=0&limit=500", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/new-release-categories?territory=TW&offset=0&limit=500",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/new-release-categories?territory=TW&offset=0&limit=500"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "KrdH2LdyUKS8z2aoxX",
      "title": "綜合"
    },
    {
      "id": "Cng5IUIQhxb8w1cbsz",
      "title": "華語"
    },
    {
      "id": "CkgxHJdAgNrEruEDza",
      "title": "西洋"
    },
    {
      "id": "4pVhRTE2XjCwnJfQRn",
      "title": "韓語"
    },
    {
      "id": "-nap5A1iST1A6Ny3ze",
      "title": "日語"
    },
    {
      "id": "1ZQwmFTaLE4p7BG-Ua",
      "title": "台語"
    },
    {
      "id": "GtN6qomUYBvqtWeRP8",
      "title": "粵語"
    },
    {
      "id": "HaGEkt7m7GQpGZOizF",
      "title": "原聲帶"
    },
    {
      "id": "8oroiyJSZINEq8f7Nc",
      "title": "電子"
    },
    {
      "id": "0oiRsbGpPKxymZD1Lg",
      "title": "嘻哈"
    },
    {
      "id": "XZjUObcyRqcInHd62v",
      "title": "R&B"
    },
    {
      "id": "KsOPYl5NAnG7rpnWpe",
      "title": "搖滾"
    },
    {
      "id": "Ksfvcl5NAnG7pjDuca",
      "title": "另類/獨立"
    },
    {
      "id": "Cod1x4lH1l7Y1dhuy4",
      "title": "靈魂樂"
    },
    {
      "id": "LX484KR5HnYUt4luvG",
      "title": "鄉村"
    },
    {
      "id": "0nyjA5B6Bj-8DkdXVI",
      "title": "雷鬼"
    },
    {
      "id": "0pGAIGDf5SqYh_SyHr",
      "title": "藍調歌曲"
    },
    {
      "id": "5YLZUQJX6npjoGcFdr",
      "title": "有聲書/相聲"
    }
  ],
  "paging": {
    "offset": 0,
    "limit": 50,
    "previous": null,
    "next": null
  },
  "summary": {
    "total": 18
  }
}

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

limit
string

每頁返回的結果數量,最多不能超過 500

offset
int32

跳過頁數

 
Suggest Edits

/new-release-categories/{category_id}

透過 {category_id} 取得該最新發行類別的資訊

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/new-release-categories/category_id
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/new-release-categories/KrdH2LdyUKS8z2aoxX?territory=TW' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/new-release-categories/KrdH2LdyUKS8z2aoxX?territory=TW")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/new-release-categories/KrdH2LdyUKS8z2aoxX?territory=TW",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/new-release-categories/KrdH2LdyUKS8z2aoxX?territory=TW", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/new-release-categories/KrdH2LdyUKS8z2aoxX?territory=TW",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/new-release-categories/KrdH2LdyUKS8z2aoxX?territory=TW"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "id": "1ZQwmFTaLE4p7BG-Ua",
  "title": "台語",
  "albums": {
    "data": [
      {
        "id": "Gr1u9_wJSVBLZejbWF",
        "name": "愛的燈火",
        "url": "https://event.kkbox.com/content/album/Gr1u9_wJSVBLZejbWF",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY"
        ],
        "release_date": "2017-07-26",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/global/27491421,0v2/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/global/27491421,0v2/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/global/27491421,0v2/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "KldNiwYxd1n-AYVOv6",
          "name": "朱海君",
          "url": "https://event.kkbox.com/content/artist/KldNiwYxd1n-AYVOv6",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/global/204079,0v2/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/global/204079,0v2/fit/300x300.jpg"
            }
          ]
        }
      },
      {
        "id": "DXIU0WMPYpMkhCH-JZ",
        "name": "風鈴聲",
        "url": "https://event.kkbox.com/content/album/DXIU0WMPYpMkhCH-JZ",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY"
        ],
        "release_date": "2017-07-26",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/global/27491368,0v2/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/global/27491368,0v2/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/global/27491368,0v2/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "Ooavzj87hVggf7e9_r",
          "name": "謝宜君",
          "url": "https://event.kkbox.com/content/artist/Ooavzj87hVggf7e9_r",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/global/3322678,0v1/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/global/3322678,0v1/fit/300x300.jpg"
            }
          ]
        }
      },
      {
        "id": "Cm3Iqi4GAc3pyrBbxi",
        "name": "原來的幸福",
        "url": "https://event.kkbox.com/content/album/Cm3Iqi4GAc3pyrBbxi",
        "explicitness": false,
        "available_territories": [
          "TW"
        ],
        "release_date": "2017-07-25",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/global/27209931,0v1/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/global/27209931,0v1/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/global/27209931,0v1/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "Csh6Hdo952obVOW_ln",
          "name": "郭婷筠",
          "url": "https://event.kkbox.com/content/artist/Csh6Hdo952obVOW_ln",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/global/463121,0v2/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/global/463121,0v2/fit/300x300.jpg"
            }
          ]
        }
      },
      {
        "id": "SpfOM00KS-4BcZmZ23",
        "name": "美麗的約束",
        "url": "https://event.kkbox.com/content/album/SpfOM00KS-4BcZmZ23",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "release_date": "2017-07-15",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/global/27099794,0v1/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/global/27099794,0v1/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/global/27099794,0v1/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "OkS2D9NM0d0gqt2jMx",
          "name": "黃巧嫻",
          "url": "https://event.kkbox.com/content/artist/OkS2D9NM0d0gqt2jMx",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/global/10159,0v2/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/global/10159,0v2/fit/300x300.jpg"
            }
          ]
        }
      },
      {
        "id": "Omnth0goP4HnC7XuNI",
        "name": "真心真愛",
        "url": "https://event.kkbox.com/content/album/Omnth0goP4HnC7XuNI",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "release_date": "2017-07-14",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/global/27055150,0v1/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/global/27055150,0v1/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/global/27055150,0v1/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "KmEo49GPD7TqVz7i-y",
          "name": "王中平",
          "url": "https://event.kkbox.com/content/artist/KmEo49GPD7TqVz7i-y",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/global/10065,0v2/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/global/10065,0v2/fit/300x300.jpg"
            }
          ]
        }
      }
    ],
    "paging": {
      "offset": 0,
      "limit": 5,
      "previous": null,
      "next": "https://api.kkbox.com/v1.1/new-release-categories/1ZQwmFTaLE4p7BG-Ua/albums?territory=TW&offset=5&limit=5"
    },
    "summary": {
      "total": 1000
    }
  }
}

Path Params

category_id
string
required

類別 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

 
Suggest Edits

/new-release-categories/{category_id}/albums

透過 {category_id} 取得該最新發行類別的專輯列表

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/new-release-categories/category_id/albums
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/new-release-categories/KrdH2LdyUKS8z2aoxX/albums?territory=TW&offset=0&limit=500' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/new-release-categories/KrdH2LdyUKS8z2aoxX/albums?territory=TW&offset=0&limit=500")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/new-release-categories/KrdH2LdyUKS8z2aoxX/albums?territory=TW&offset=0&limit=500",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/new-release-categories/KrdH2LdyUKS8z2aoxX/albums?territory=TW&offset=0&limit=500", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/new-release-categories/KrdH2LdyUKS8z2aoxX/albums?territory=TW&offset=0&limit=500",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/new-release-categories/KrdH2LdyUKS8z2aoxX/albums?territory=TW&offset=0&limit=500"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "Gr1u9_wJSVBLZejbWF",
      "name": "愛的燈火",
      "url": "https://event.kkbox.com/content/album/Gr1u9_wJSVBLZejbWF",
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY"
      ],
      "release_date": "2017-07-26",
      "images": [
        {
          "height": 160,
          "width": 160,
          "url": "https://i.kfs.io/album/global/27491421,0v2/fit/160x160.jpg"
        },
        {
          "height": 500,
          "width": 500,
          "url": "https://i.kfs.io/album/global/27491421,0v2/fit/500x500.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/album/global/27491421,0v2/fit/1000x1000.jpg"
        }
      ],
      "artist": {
        "id": "KldNiwYxd1n-AYVOv6",
        "name": "朱海君",
        "url": "https://event.kkbox.com/content/artist/KldNiwYxd1n-AYVOv6",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/artist/global/204079,0v2/fit/160x160.jpg"
          },
          {
            "height": 300,
            "width": 300,
            "url": "https://i.kfs.io/artist/global/204079,0v2/fit/300x300.jpg"
          }
        ]
      }
    },
    {
      "id": "DXIU0WMPYpMkhCH-JZ",
      "name": "風鈴聲",
      "url": "https://event.kkbox.com/content/album/DXIU0WMPYpMkhCH-JZ",
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY"
      ],
      "release_date": "2017-07-26",
      "images": [
        {
          "height": 160,
          "width": 160,
          "url": "https://i.kfs.io/album/global/27491368,0v2/fit/160x160.jpg"
        },
        {
          "height": 500,
          "width": 500,
          "url": "https://i.kfs.io/album/global/27491368,0v2/fit/500x500.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/album/global/27491368,0v2/fit/1000x1000.jpg"
        }
      ],
      "artist": {
        "id": "Ooavzj87hVggf7e9_r",
        "name": "謝宜君",
        "url": "https://event.kkbox.com/content/artist/Ooavzj87hVggf7e9_r",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/artist/global/3322678,0v1/fit/160x160.jpg"
          },
          {
            "height": 300,
            "width": 300,
            "url": "https://i.kfs.io/artist/global/3322678,0v1/fit/300x300.jpg"
          }
        ]
      }
    },
    {
      "id": "Cm3Iqi4GAc3pyrBbxi",
      "name": "原來的幸福",
      "url": "https://event.kkbox.com/content/album/Cm3Iqi4GAc3pyrBbxi",
      "explicitness": false,
      "available_territories": [
        "TW"
      ],
      "release_date": "2017-07-25",
      "images": [
        {
          "height": 160,
          "width": 160,
          "url": "https://i.kfs.io/album/global/27209931,0v1/fit/160x160.jpg"
        },
        {
          "height": 500,
          "width": 500,
          "url": "https://i.kfs.io/album/global/27209931,0v1/fit/500x500.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/album/global/27209931,0v1/fit/1000x1000.jpg"
        }
      ],
      "artist": {
        "id": "Csh6Hdo952obVOW_ln",
        "name": "郭婷筠",
        "url": "https://event.kkbox.com/content/artist/Csh6Hdo952obVOW_ln",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/artist/global/463121,0v2/fit/160x160.jpg"
          },
          {
            "height": 300,
            "width": 300,
            "url": "https://i.kfs.io/artist/global/463121,0v2/fit/300x300.jpg"
          }
        ]
      }
    },
    {
      "id": "SpfOM00KS-4BcZmZ23",
      "name": "美麗的約束",
      "url": "https://event.kkbox.com/content/album/SpfOM00KS-4BcZmZ23",
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY",
        "JP"
      ],
      "release_date": "2017-07-15",
      "images": [
        {
          "height": 160,
          "width": 160,
          "url": "https://i.kfs.io/album/global/27099794,0v1/fit/160x160.jpg"
        },
        {
          "height": 500,
          "width": 500,
          "url": "https://i.kfs.io/album/global/27099794,0v1/fit/500x500.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/album/global/27099794,0v1/fit/1000x1000.jpg"
        }
      ],
      "artist": {
        "id": "OkS2D9NM0d0gqt2jMx",
        "name": "黃巧嫻",
        "url": "https://event.kkbox.com/content/artist/OkS2D9NM0d0gqt2jMx",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/artist/global/10159,0v2/fit/160x160.jpg"
          },
          {
            "height": 300,
            "width": 300,
            "url": "https://i.kfs.io/artist/global/10159,0v2/fit/300x300.jpg"
          }
        ]
      }
    },
    {
      "id": "Omnth0goP4HnC7XuNI",
      "name": "真心真愛",
      "url": "https://event.kkbox.com/content/album/Omnth0goP4HnC7XuNI",
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY",
        "JP"
      ],
      "release_date": "2017-07-14",
      "images": [
        {
          "height": 160,
          "width": 160,
          "url": "https://i.kfs.io/album/global/27055150,0v1/fit/160x160.jpg"
        },
        {
          "height": 500,
          "width": 500,
          "url": "https://i.kfs.io/album/global/27055150,0v1/fit/500x500.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/album/global/27055150,0v1/fit/1000x1000.jpg"
        }
      ],
      "artist": {
        "id": "KmEo49GPD7TqVz7i-y",
        "name": "王中平",
        "url": "https://event.kkbox.com/content/artist/KmEo49GPD7TqVz7i-y",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/artist/global/10065,0v2/fit/160x160.jpg"
          },
          {
            "height": 300,
            "width": 300,
            "url": "https://i.kfs.io/artist/global/10065,0v2/fit/300x300.jpg"
          }
        ]
      }
    }
  ],
  "paging": {
    "offset": 0,
    "limit": 5,
    "previous": null,
    "next": "https://api.kkbox.com/v1.1/new-release-categories/1ZQwmFTaLE4p7BG-Ua/albums?limit=5&territory=TW&offset=5"
  },
  "summary": {
    "total": 1000
  }
}

Path Params

category_id
string
required

類別 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

limit
int32

每頁返回的結果數量,最多不能超過 500

offset
int32

跳過頁數

 
Suggest Edits

/search

透過關鍵字、指定類別,取得想要的資訊

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/search
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/search?q=Mayday&type=track&territory=TW&offset=0&limit=50' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/search?q=Mayday&type=track&territory=TW&offset=0&limit=50")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/search?q=Mayday&type=track&territory=TW&offset=0&limit=50",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/search?q=Mayday&type=track&territory=TW&offset=0&limit=50", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/search?q=Mayday&type=track&territory=TW&offset=0&limit=50",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/search?q=Mayday&type=track&territory=TW&offset=0&limit=50"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "artists": {
    "data": [
      {
        "id": "GmHEVs8n1D6m6pz6zC",
        "name": "盧芸 (Rita)",
        "url": "https://event.kkbox.com/content/artist/GmHEVs8n1D6m6pz6zC",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/artist/global/6721287,0v2/fit/160x160.jpg"
          },
          {
            "height": 300,
            "width": 300,
            "url": "https://i.kfs.io/artist/global/6721287,0v2/fit/300x300.jpg"
          }
        ]
      }
    ],
    "paging": {
      "offset": 0,
      "limit": 15,
      "previous": null,
      "next": null
    },
    "summary": {
      "total": 1
    }
  },
  "tracks": {
    "data": [
      {
        "id": "Pac1gYzqWKr81wzSsi",
        "name": "天空下",
        "duration": 210755,
        "url": "https://event.kkbox.com/content/song/Pac1gYzqWKr81wzSsi",
        "track_number": 1,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "album": {
          "id": "_-5I-tcxQDQcUrHUwo",
          "name": "天空下 (Under the Same Sky)",
          "url": "https://event.kkbox.com/content/album/_-5I-tcxQDQcUrHUwo",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY",
            "JP"
          ],
          "release_date": "2016-10-17",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/global/19185225,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/global/19185225,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/global/19185225,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "GmHEVs8n1D6m6pz6zC",
            "name": "盧芸 (Rita)",
            "url": "https://event.kkbox.com/content/artist/GmHEVs8n1D6m6pz6zC",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/6721287,0v2/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/6721287,0v2/fit/300x300.jpg"
              }
            ]
          }
        }
      }
    ],
    "paging": {
      "offset": 0,
      "limit": 15,
      "previous": null,
      "next": null
    },
    "summary": {
      "total": 1
    }
  },
  "paging": {
    "offset": 0,
    "limit": 15,
    "previous": null,
    "next": null
  },
  "summary": {
    "total": 1
  }
}

Query Params

q
string
required

搜索關鍵字,必須使用 URL 編碼

type
string

搜尋結果類型,可以是 track、album、artist、playlist。未填的話預設為搜尋全部類型

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

limit
int32

每頁返回的結果數量,最多不能超過 50

offset
int32

跳過頁數

 
Suggest Edits

New Hits Playlists

 

最新熱門歌單

Suggest Edits

/new-hits-playlists

取得最新熱門歌單列表

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/new-hits-playlists
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/new-hits-playlists?territory=TW&offset=0&limit=10' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/new-hits-playlists?territory=TW&offset=0&limit=10")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/new-hits-playlists?territory=TW&offset=0&limit=10",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/new-hits-playlists?territory=TW&offset=0&limit=10", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/new-hits-playlists?territory=TW&offset=0&limit=10",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/new-hits-playlists?territory=TW&offset=0&limit=10"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "DZrC8m29ciOFY2JAm3",
      "title": "華語新曲速報 (每週三六更新)",
      "description": "",
      "url": "https://event.kkbox.com/content/playlist/DZrC8m29ciOFY2JAm3",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist/global/26541395v33/cropresize/300x300.jpg"
        },
        {
          "height": 600,
          "width": 600,
          "url": "https://i.kfs.io/playlist/global/26541395v33/cropresize/600x600.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/playlist/global/26541395v33/cropresize/1000x1000.jpg"
        }
      ],
      "updated_at": "2017-08-01T04:13:38+00:00",
      "owner": {
        "id": "Os-z4yYPRlzOAkzZm3",
        "name": "KKBOX 華語小編"
      }
    },
    {
      "id": "DZni8m29ciOFbRxTJq",
      "title": "西洋新曲速報  (每週五更新)",
      "description": "TW西洋新曲主打",
      "url": "https://event.kkbox.com/content/playlist/DZni8m29ciOFbRxTJq",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist/global/26541409v17/cropresize/300x300.jpg"
        },
        {
          "height": 600,
          "width": 600,
          "url": "https://i.kfs.io/playlist/global/26541409v17/cropresize/600x600.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/playlist/global/26541409v17/cropresize/1000x1000.jpg"
        }
      ],
      "updated_at": "2017-08-01T02:19:51+00:00",
      "owner": {
        "id": "5XIttVqe0foATcIFMp",
        "name": "KKBOX 西洋小編"
      }
    },
    {
      "id": "1_pCwOnj-qZsGU3rTJ",
      "title": "日語新曲速報(每週日更新)",
      "description": "TW日語新曲主打",
      "url": "https://event.kkbox.com/content/playlist/1_pCwOnj-qZsGU3rTJ",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist/global/26541410v16/cropresize/300x300.jpg"
        },
        {
          "height": 600,
          "width": 600,
          "url": "https://i.kfs.io/playlist/global/26541410v16/cropresize/600x600.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/playlist/global/26541410v16/cropresize/1000x1000.jpg"
        }
      ],
      "updated_at": "2017-08-01T03:38:22+00:00",
      "owner": {
        "id": "Ooerjv5-p-TJsFGLg5",
        "name": "KKBOX 日語小編"
      }
    },
    {
      "id": "0kM_Sp_Ezou3BMGK-n",
      "title": "韓語新曲速報 (每週一更新)",
      "description": "TW韓語新曲主打",
      "url": "https://event.kkbox.com/content/playlist/0kM_Sp_Ezou3BMGK-n",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist/global/26541412v18/cropresize/300x300.jpg"
        },
        {
          "height": 600,
          "width": 600,
          "url": "https://i.kfs.io/playlist/global/26541412v18/cropresize/600x600.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/playlist/global/26541412v18/cropresize/1000x1000.jpg"
        }
      ],
      "updated_at": "2017-08-01T02:44:17+00:00",
      "owner": {
        "id": "D-gh_8TEudW64tRSCs",
        "name": "KKBOX 韓語小編"
      }
    }
  ],
  "paging": {
    "offset": 0,
    "limit": 5,
    "previous": null,
    "next": null
  },
  "summary": {
    "total": 4
  }
}

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

 
Suggest Edits

/new-hits-playlists/{playlist_id}

透過 {playlist_id} 取得該最新熱門歌單的資訊

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/new-hits-playlists/playlist_id
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/new-hits-playlists/DZrC8m29ciOFY2JAm3?territory=TW' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/new-hits-playlists/DZrC8m29ciOFY2JAm3?territory=TW")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/new-hits-playlists/DZrC8m29ciOFY2JAm3?territory=TW",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/new-hits-playlists/DZrC8m29ciOFY2JAm3?territory=TW", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/new-hits-playlists/DZrC8m29ciOFY2JAm3?territory=TW",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/new-hits-playlists/DZrC8m29ciOFY2JAm3?territory=TW"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "tracks": {
    "data": [
      {
        "id": "Wk-z5ZBpPowcmYlS0E",
        "name": "明天的秘密 (Tomorrow Will Be A Secret)",
        "duration": 258624,
        "url": "https://event.kkbox.com/content/song/Wk-z5ZBpPowcmYlS0E",
        "track_number": 1,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "album": {
          "id": "Os-3-rAoqcVQaVhpkn",
          "name": "明天的秘密",
          "url": "https://event.kkbox.com/content/album/Os-3-rAoqcVQaVhpkn",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY",
            "JP"
          ],
          "release_date": "2017-07-31",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/global/27683214,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/global/27683214,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/global/27683214,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "CmUb4SnT1F5sNiD_9N",
            "name": "蕭亞軒 (Elva Hsiao)",
            "url": "https://event.kkbox.com/content/artist/CmUb4SnT1F5sNiD_9N",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/1729,0v4/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/1729,0v4/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "8pj_f7fb2c2enQ0Epb",
        "name": "心之焰",
        "duration": 148271,
        "url": "https://event.kkbox.com/content/song/8pj_f7fb2c2enQ0Epb",
        "track_number": 1,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "album": {
          "id": "CowV7V6O1JHrxk7T4f",
          "name": "心之焰",
          "url": "https://event.kkbox.com/content/album/CowV7V6O1JHrxk7T4f",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY",
            "JP"
          ],
          "release_date": "2017-07-28",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/global/27561016,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/global/27561016,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/global/27561016,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "WsiS7mTku7eU0Z8S7R",
            "name": "G.E.M.鄧紫棋",
            "url": "https://event.kkbox.com/content/artist/WsiS7mTku7eU0Z8S7R",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/45702,0v5/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/45702,0v5/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "4nwP4FwI3TYuonfKXu",
        "name": "愛正在發生 (Love Is Happening)",
        "duration": 232489,
        "url": "https://event.kkbox.com/content/song/4nwP4FwI3TYuonfKXu",
        "track_number": 1,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "album": {
          "id": "Kmw7Gp56mUrTne5Wtp",
          "name": "愛正在發生 (Love Is Happening)",
          "url": "https://event.kkbox.com/content/album/Kmw7Gp56mUrTne5Wtp",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY",
            "JP"
          ],
          "release_date": "2017-07-31",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/global/27681911,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/global/27681911,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/global/27681911,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "KmRHQyGPD7TqUyb0Vt",
            "name": "邱勝翊(王子)",
            "url": "https://event.kkbox.com/content/artist/KmRHQyGPD7TqUyb0Vt",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/tw/noimg/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/tw/noimg/fit/300x300.jpg"
              }
            ]
          }
        }
      }
    ],
    "paging": {
      "offset": 0,
      "limit": 100,
      "previous": null,
      "next": null
    },
    "summary": {
      "total": 43
    }
  },
  "id": "DZrC8m29ciOFY2JAm3",
  "title": "華語新曲速報 (每週三六更新)",
  "description": "",
  "url": "https://event.kkbox.com/content/playlist/DZrC8m29ciOFY2JAm3",
  "images": [
    {
      "height": 300,
      "width": 300,
      "url": "https://i.kfs.io/playlist/global/26541395v33/cropresize/300x300.jpg"
    },
    {
      "height": 600,
      "width": 600,
      "url": "https://i.kfs.io/playlist/global/26541395v33/cropresize/600x600.jpg"
    },
    {
      "height": 1000,
      "width": 1000,
      "url": "https://i.kfs.io/playlist/global/26541395v33/cropresize/1000x1000.jpg"
    }
  ],
  "updated_at": "2017-08-01T04:13:38+00:00",
  "owner": {
    "id": "Os-z4yYPRlzOAkzZm3",
    "name": "KKBOX 華語小編"
  }
}

Path Params

playlist_id
string
required

歌單 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

 
Suggest Edits

/new-hits-playlists/{playlist_id}/tracks

透過 {playlist_id} 取得該最新熱門歌單的歌曲列表

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/new-hits-playlists/playlist_id/tracks
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/new-hits-playlists/DZrC8m29ciOFY2JAm3/tracks?territory=TW&offset=42&limit=500' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/new-hits-playlists/DZrC8m29ciOFY2JAm3/tracks?territory=TW&offset=42&limit=500")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/new-hits-playlists/DZrC8m29ciOFY2JAm3/tracks?territory=TW&offset=42&limit=500",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/new-hits-playlists/DZrC8m29ciOFY2JAm3/tracks?territory=TW&offset=42&limit=500", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/new-hits-playlists/DZrC8m29ciOFY2JAm3/tracks?territory=TW&offset=42&limit=500",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/new-hits-playlists/DZrC8m29ciOFY2JAm3/tracks?territory=TW&offset=42&limit=500"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "LZkCyJWMMFHaj-TO7m",
      "name": "Not Afraid Anymore",
      "duration": 226719,
      "url": "https://event.kkbox.com/content/song/LZkCyJWMMFHaj-TO7m",
      "track_number": 1,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY",
        "JP"
      ],
      "album": {
        "id": "8mr11p1liKnsnDhqEF",
        "name": "Not Afraid Anymore",
        "url": "https://event.kkbox.com/content/album/8mr11p1liKnsnDhqEF",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "release_date": "2017-01-13",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/global/21818054,0v1/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/global/21818054,0v1/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/global/21818054,0v1/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "PZgYvhZg4cM7vAA2DW",
          "name": "Halsey",
          "url": "https://event.kkbox.com/content/artist/PZgYvhZg4cM7vAA2DW",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/global/3338232,0v8/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/global/3338232,0v8/fit/300x300.jpg"
            }
          ]
        }
      }
    },
    {
      "id": "OseG-8qU8UtszwJlXm",
      "name": "開門關門",
      "duration": 208979,
      "url": "https://event.kkbox.com/content/song/OseG-8qU8UtszwJlXm",
      "track_number": 10,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY",
        "JP"
      ],
      "album": {
        "id": "4lGaKhRh6lesfP_pvT",
        "name": "52Hz, I Love You",
        "url": "https://event.kkbox.com/content/album/4lGaKhRh6lesfP_pvT",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "release_date": "2017-01-26",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/global/22034915,0v1/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/global/22034915,0v1/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/global/22034915,0v1/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "LY5scHimqDphGqy41I",
          "name": "Various Artists",
          "url": "https://event.kkbox.com/content/artist/LY5scHimqDphGqy41I",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/tw/noimg/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/tw/noimg/fit/300x300.jpg"
            }
          ]
        }
      }
    },
    {
      "id": "Kl8bTlB4BZNACUxeAi",
      "name": "Beauty and the Beast",
      "duration": 227927,
      "url": "https://event.kkbox.com/content/song/Kl8bTlB4BZNACUxeAi",
      "track_number": 1,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY"
      ],
      "album": {
        "id": "Gn-oN41HPEfODw75Ah",
        "name": "Beauty and the Beast",
        "url": "https://event.kkbox.com/content/album/Gn-oN41HPEfODw75Ah",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY"
        ],
        "release_date": "2017-02-03",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/global/22396256,2v1/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/global/22396256,2v1/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/global/22396256,2v1/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "L_yJ1jz6gunFPJ02QF",
          "name": "Ariana Grande, John Legend",
          "url": "https://event.kkbox.com/content/artist/L_yJ1jz6gunFPJ02QF",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/global/7610849,0v3/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/global/7610849,0v3/fit/300x300.jpg"
            }
          ]
        }
      }
    }
  ],
  "paging": {
    "offset": 0,
    "limit": 3,
    "previous": null,
    "next": "https://api.kkbox.com/v1.1/shared-playlists/-meJqWeQgu9_xxSLSy/tracks?limit=3&offset=3"
  },
  "summary": {
    "total": 102
  }
}

Path Params

playlist_id
string
required

歌單 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

limit
int32

每頁返回的結果數量,最多不能超過 500

offset
int32

跳過頁數

 

歌曲排行榜

Suggest Edits

/charts

取得歌曲排行榜列表

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/charts
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/charts?territory=TW' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/charts?territory=TW")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/charts?territory=TW",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/charts?territory=TW", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/charts?territory=TW",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/charts?territory=TW"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "0kTVCy_kzou3AdOsAc",
      "title": "華語人氣日榜 Top 100",
      "description": "華語人氣日榜 Top 100",
      "url": "https://event.kkbox.com/content/playlist/0kTVCy_kzou3AdOsAc",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist/global/59726106v1/cropresize/300x300.jpg"
        },
        {
          "height": 600,
          "width": 600,
          "url": "https://i.kfs.io/playlist/global/59726106v1/cropresize/600x600.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/playlist/global/59726106v1/cropresize/1000x1000.jpg"
        }
      ],
      "updated_at": "2017-07-26T19:48:02+00:00",
      "owner": {
        "id": "T-YMdq3gnf6AVbuqgt",
        "name": "KKBOX"
      }
    },
    {
      "id": "Gminyp3RoIXuK79FWR",
      "title": "西洋人氣日榜 Top 100",
      "description": "西洋人氣日榜 Top 100",
      "url": "https://event.kkbox.com/content/playlist/Gminyp3RoIXuK79FWR",
      "images": [
        {
          "height": 300,
          "width": 300,
          "url": "https://i.kfs.io/playlist/global/59726113v1/cropresize/300x300.jpg"
        },
        {
          "height": 600,
          "width": 600,
          "url": "https://i.kfs.io/playlist/global/59726113v1/cropresize/600x600.jpg"
        },
        {
          "height": 1000,
          "width": 1000,
          "url": "https://i.kfs.io/playlist/global/59726113v1/cropresize/1000x1000.jpg"
        }
      ],
      "updated_at": "2017-07-26T19:48:04+00:00",
      "owner": {
        "id": "T-YMdq3gnf6AVbuqgt",
        "name": "KKBOX"
      }
    }
  ],
  "paging": {
    "offset": 0,
    "limit": 5,
    "previous": null,
    "next": null
  },
  "summary": {
    "total": 30
  }
}

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

 
Suggest Edits

/charts/{playlist_id}

透過 {playlist_id} 取得該排行榜的資訊

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/charts/playlist_id
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/charts/4nUZM-TY2aVxZ2xaA-?territory=TW' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/charts/4nUZM-TY2aVxZ2xaA-?territory=TW")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/charts/4nUZM-TY2aVxZ2xaA-?territory=TW",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/charts/4nUZM-TY2aVxZ2xaA-?territory=TW", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/charts/4nUZM-TY2aVxZ2xaA-?territory=TW",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/charts/4nUZM-TY2aVxZ2xaA-?territory=TW"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "tracks": {
    "data": [
      {
        "id": "SsJItLYfDXYxalPgtU",
        "name": "這個世界",
        "duration": 240195,
        "url": "https://event.kkbox.com/content/song/SsJItLYfDXYxalPgtU",
        "track_number": 12,
        "explicitness": false,
        "available_territories": [
          "TW"
        ],
        "album": {
          "id": "CnWnDaRF4d6Z3EgCnv",
          "name": "這個世界 (This World)",
          "url": "https://event.kkbox.com/content/album/CnWnDaRF4d6Z3EgCnv",
          "explicitness": false,
          "available_territories": [
            "TW"
          ],
          "release_date": "2016-10-12",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/global/19151099,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/global/19151099,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/global/19151099,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "-lm_2ldXI0rBCMeriC",
            "name": "蔡藍欽",
            "url": "https://event.kkbox.com/content/artist/-lm_2ldXI0rBCMeriC",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/4979,0v1/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/4979,0v1/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "-kQ0G1lzMveSbRJI1h",
        "name": "這個世界",
        "duration": 268956,
        "url": "https://event.kkbox.com/content/song/-kQ0G1lzMveSbRJI1h",
        "track_number": 25,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "album": {
          "id": "KqoKCbzKOnJP4qBEAZ",
          "name": "當我們混在一起 2005 演唱會 Live 全記錄",
          "url": "https://event.kkbox.com/content/album/KqoKCbzKOnJP4qBEAZ",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY",
            "JP"
          ],
          "release_date": "2005-05-27",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/54709,0v3/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/54709,0v3/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/54709,0v3/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "9XN-7yg5vg3gYnCdsM",
            "name": "五月天 (Mayday)",
            "url": "https://event.kkbox.com/content/artist/9XN-7yg5vg3gYnCdsM",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/6651,0v9/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/6651,0v9/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "0oVpLhDXhv4OSjm_fJ",
        "name": "這個世界",
        "duration": 234370,
        "url": "https://event.kkbox.com/content/song/0oVpLhDXhv4OSjm_fJ",
        "track_number": 6,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "album": {
          "id": "__v-2rnU8IHVqOOmz9",
          "name": "黃鶯鶯搖籃曲",
          "url": "https://event.kkbox.com/content/album/__v-2rnU8IHVqOOmz9",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY",
            "JP"
          ],
          "release_date": "2012-07-02",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/352143,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/352143,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/352143,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "GsuNkAHedyFlIFnpAU",
            "name": "黃鶯鶯 (Tracy Huang)",
            "url": "https://event.kkbox.com/content/artist/GsuNkAHedyFlIFnpAU",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/363,0v1/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/363,0v1/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "Gl5PVJTpylVNEdjV83",
        "name": "這個世界",
        "duration": 182961,
        "url": "https://event.kkbox.com/content/song/Gl5PVJTpylVNEdjV83",
        "track_number": 3,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK"
        ],
        "album": {
          "id": "Grvf3dwZSVBLbO_3uD",
          "name": "夏樹的期待-黃建為音樂故事EP",
          "url": "https://event.kkbox.com/content/album/Grvf3dwZSVBLbO_3uD",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK"
          ],
          "release_date": "2007-07-30",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/93750,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/93750,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/93750,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "9ajzwD_q8L4InP_8Yu",
            "name": "黃建為",
            "url": "https://event.kkbox.com/content/artist/9ajzwD_q8L4InP_8Yu",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/21756,0v4/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/21756,0v4/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "-oiIln1-e7WVLDU48L",
        "name": "這個世界",
        "duration": 220682,
        "url": "https://event.kkbox.com/content/song/-oiIln1-e7WVLDU48L",
        "track_number": 25,
        "explicitness": false,
        "available_territories": [
          "TW",
          "JP"
        ],
        "album": {
          "id": "8s0yeK6TI8uiqdCcmx",
          "name": "永恆金曲 影音典藏精選 (Ultimate Jeff Chang)",
          "url": "https://event.kkbox.com/content/album/8s0yeK6TI8uiqdCcmx",
          "explicitness": false,
          "available_territories": [
            "TW",
            "JP"
          ],
          "release_date": "2014-07-04",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/4247039,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/4247039,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/4247039,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "LZ5XE3V1w4lbhvgqpN",
            "name": "張信哲 (Jeff Chang)",
            "url": "https://event.kkbox.com/content/artist/LZ5XE3V1w4lbhvgqpN",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/1935,0v20/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/1935,0v20/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "WlQ7AW7hHya3DJrUwR",
        "name": "這個世界",
        "duration": 260702,
        "url": "https://event.kkbox.com/content/song/WlQ7AW7hHya3DJrUwR",
        "track_number": 5,
        "explicitness": false,
        "available_territories": [
          "TW",
          "SG",
          "MY",
          "JP"
        ],
        "album": {
          "id": "Gm5YZ7Pkte5pDqOAym",
          "name": "砂礫",
          "url": "https://event.kkbox.com/content/album/Gm5YZ7Pkte5pDqOAym",
          "explicitness": false,
          "available_territories": [
            "TW",
            "SG",
            "MY",
            "JP"
          ],
          "release_date": "2015-06-30",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/global/6869119,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/global/6869119,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/global/6869119,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "9__gCzeJGTMFK-hL_h",
            "name": "陳永龍",
            "url": "https://event.kkbox.com/content/artist/9__gCzeJGTMFK-hL_h",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/49691,0v3/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/49691,0v3/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "Gky6sg7-nSw3QDG0D6",
        "name": "這個世界",
        "duration": 217663,
        "url": "https://event.kkbox.com/content/song/Gky6sg7-nSw3QDG0D6",
        "track_number": 6,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY"
        ],
        "album": {
          "id": "0t2OsmRsK_vh-iXotN",
          "name": "眼球先生的這個世界",
          "url": "https://event.kkbox.com/content/album/0t2OsmRsK_vh-iXotN",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY"
          ],
          "release_date": "2010-01-06",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/140451,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/140451,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/140451,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "8qfqtzjl89YamthC8L",
            "name": "眼球先生",
            "url": "https://event.kkbox.com/content/artist/8qfqtzjl89YamthC8L",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/12422,0v1/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/12422,0v1/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "4lfJzlnq9Z5EbF9AI3",
        "name": "這個世界",
        "duration": 228437,
        "url": "https://event.kkbox.com/content/song/4lfJzlnq9Z5EbF9AI3",
        "track_number": 2,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY"
        ],
        "album": {
          "id": "0t2OsmRsK_vh-iXotN",
          "name": "眼球先生的這個世界",
          "url": "https://event.kkbox.com/content/album/0t2OsmRsK_vh-iXotN",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY"
          ],
          "release_date": "2010-01-06",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/140451,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/140451,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/140451,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "8qfqtzjl89YamthC8L",
            "name": "眼球先生",
            "url": "https://event.kkbox.com/content/artist/8qfqtzjl89YamthC8L",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/12422,0v1/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/12422,0v1/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "OtNNztzt3DzwZYikO6",
        "name": "這個世界",
        "duration": 291968,
        "url": "https://event.kkbox.com/content/song/OtNNztzt3DzwZYikO6",
        "track_number": 8,
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "album": {
          "id": "8kUKk3p-GTiCJGjksr",
          "name": "音樂家庭2 -美麗的假期",
          "url": "https://event.kkbox.com/content/album/8kUKk3p-GTiCJGjksr",
          "explicitness": false,
          "available_territories": [
            "TW",
            "HK",
            "SG",
            "MY",
            "JP"
          ],
          "release_date": "1999-00-00",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/26943,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/26943,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/26943,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "4quBLsuwBSuh2uptkv",
            "name": "孫建平",
            "url": "https://event.kkbox.com/content/artist/4quBLsuwBSuh2uptkv",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/5896,0v1/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/5896,0v1/fit/300x300.jpg"
              }
            ]
          }
        }
      },
      {
        "id": "SpdWAa8c1sYnoczBUa",
        "name": "這個世界 (This World)",
        "duration": 228205,
        "url": "https://event.kkbox.com/content/song/SpdWAa8c1sYnoczBUa",
        "track_number": 2,
        "explicitness": false,
        "available_territories": [
          "TW"
        ],
        "album": {
          "id": "XXT7zI5qEjhjDAVmn0",
          "name": "許一個願望 Make A Wish",
          "url": "https://event.kkbox.com/content/album/XXT7zI5qEjhjDAVmn0",
          "explicitness": false,
          "available_territories": [
            "TW"
          ],
          "release_date": "2012-03-09",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/album/tw/322125,0v1/fit/160x160.jpg"
            },
            {
              "height": 500,
              "width": 500,
              "url": "https://i.kfs.io/album/tw/322125,0v1/fit/500x500.jpg"
            },
            {
              "height": 1000,
              "width": 1000,
              "url": "https://i.kfs.io/album/tw/322125,0v1/fit/1000x1000.jpg"
            }
          ],
          "artist": {
            "id": "L_mqUUz6gunFMEq5a0",
            "name": "賈靜雯",
            "url": "https://event.kkbox.com/content/artist/L_mqUUz6gunFMEq5a0",
            "images": [
              {
                "height": 160,
                "width": 160,
                "url": "https://i.kfs.io/artist/global/203187,0v1/fit/160x160.jpg"
              },
              {
                "height": 300,
                "width": 300,
                "url": "https://i.kfs.io/artist/global/203187,0v1/fit/300x300.jpg"
              }
            ]
          }
        }
      }
    ],
    "paging": {
      "offset": 0,
      "limit": 100,
      "previous": null,
      "next": null
    },
    "summary": {
      "total": 10
    }
  },
  "id": "4nUZM-TY2aVxZ2xaA-",
  "title": "各種版本的「這個世界」",
  "description": "原來曾經有這麼多人重唱過「你的世界」",
  "url": "https://event.kkbox.com/content/playlist/4nUZM-TY2aVxZ2xaA-",
  "images": [
    {
      "height": 300,
      "width": 300,
      "url": "https://i.kfs.io/playlist/global/39885447v1/cropresize/300x300.jpg"
    },
    {
      "height": 600,
      "width": 600,
      "url": "https://i.kfs.io/playlist/global/39885447v1/cropresize/600x600.jpg"
    },
    {
      "height": 1000,
      "width": 1000,
      "url": "https://i.kfs.io/playlist/global/39885447v1/cropresize/1000x1000.jpg"
    }
  ],
  "updated_at": "2016-10-18T08:15:09+00:00",
  "owner": {
    "id": "CoiM4s7qXvCTQBLstX",
    "name": "澳門首家線上賭場"
  }
}

Path Params

playlist_id
string
required

歌單 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

 
Suggest Edits

/charts/{playlist_id}/tracks

透過 {playlist_id} 取得該排行榜的歌曲列表

 

OAuth2 Auth

Bearer
 Authentication is required for this endpoint.
gethttps://api.kkbox.com/v1.1/charts/playlist_id/tracks
curl --request GET \
  --url 'https://api.kkbox.com/v1.1/charts/-meJqWeQgu9_xxSLSy-/tracks?territory=TW&offset=0&limit=500' \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR ACCESS TOKEN HERE'
require 'uri'
require 'net/http'

url = URI("https://api.kkbox.com/v1.1/charts/-meJqWeQgu9_xxSLSy-/tracks?territory=TW&offset=0&limit=500")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["accept"] = 'application/json'
request["authorization"] = 'Bearer YOUR ACCESS TOKEN HERE'

response = http.request(request)
puts response.read_body
var http = require("https");

var options = {
  "method": "GET",
  "hostname": "api.kkbox.com",
  "port": null,
  "path": "/v1.1/charts/-meJqWeQgu9_xxSLSy-/tracks?territory=TW&offset=0&limit=500",
  "headers": {
    "accept": "application/json",
    "authorization": "Bearer YOUR ACCESS TOKEN HERE"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
import http.client

conn = http.client.HTTPSConnection("api.kkbox.com")

headers = {
    'accept': "application/json",
    'authorization': "Bearer YOUR ACCESS TOKEN HERE"
    }

conn.request("GET", "/v1.1/charts/-meJqWeQgu9_xxSLSy-/tracks?territory=TW&offset=0&limit=500", headers=headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.kkbox.com/v1.1/charts/-meJqWeQgu9_xxSLSy-/tracks?territory=TW&offset=0&limit=500",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "accept: application/json",
    "authorization: Bearer YOUR ACCESS TOKEN HERE"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
    "fmt"
    "net/http"
    "io/ioutil"
)

func main() {

    url := "https://api.kkbox.com/v1.1/charts/-meJqWeQgu9_xxSLSy-/tracks?territory=TW&offset=0&limit=500"

    req, _ := http.NewRequest("GET", url, nil)

    req.Header.Add("accept", "application/json")
    req.Header.Add("authorization", "Bearer YOUR ACCESS TOKEN HERE")

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()
    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(res)
    fmt.Println(string(body))

}
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "LZkCyJWMMFHaj-TO7m",
      "name": "Not Afraid Anymore",
      "duration": 226719,
      "url": "https://event.kkbox.com/content/song/LZkCyJWMMFHaj-TO7m",
      "track_number": 1,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY",
        "JP"
      ],
      "album": {
        "id": "8mr11p1liKnsnDhqEF",
        "name": "Not Afraid Anymore",
        "url": "https://event.kkbox.com/content/album/8mr11p1liKnsnDhqEF",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "release_date": "2017-01-13",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/global/21818054,0v1/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/global/21818054,0v1/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/global/21818054,0v1/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "PZgYvhZg4cM7vAA2DW",
          "name": "Halsey",
          "url": "https://event.kkbox.com/content/artist/PZgYvhZg4cM7vAA2DW",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/global/3338232,0v8/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/global/3338232,0v8/fit/300x300.jpg"
            }
          ]
        }
      }
    },
    {
      "id": "OseG-8qU8UtszwJlXm",
      "name": "開門關門",
      "duration": 208979,
      "url": "https://event.kkbox.com/content/song/OseG-8qU8UtszwJlXm",
      "track_number": 10,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY",
        "JP"
      ],
      "album": {
        "id": "4lGaKhRh6lesfP_pvT",
        "name": "52Hz, I Love You",
        "url": "https://event.kkbox.com/content/album/4lGaKhRh6lesfP_pvT",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY",
          "JP"
        ],
        "release_date": "2017-01-26",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/global/22034915,0v1/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/global/22034915,0v1/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/global/22034915,0v1/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "LY5scHimqDphGqy41I",
          "name": "Various Artists",
          "url": "https://event.kkbox.com/content/artist/LY5scHimqDphGqy41I",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/tw/noimg/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/tw/noimg/fit/300x300.jpg"
            }
          ]
        }
      }
    },
    {
      "id": "Kl8bTlB4BZNACUxeAi",
      "name": "Beauty and the Beast",
      "duration": 227927,
      "url": "https://event.kkbox.com/content/song/Kl8bTlB4BZNACUxeAi",
      "track_number": 1,
      "explicitness": false,
      "available_territories": [
        "TW",
        "HK",
        "SG",
        "MY"
      ],
      "album": {
        "id": "Gn-oN41HPEfODw75Ah",
        "name": "Beauty and the Beast",
        "url": "https://event.kkbox.com/content/album/Gn-oN41HPEfODw75Ah",
        "explicitness": false,
        "available_territories": [
          "TW",
          "HK",
          "SG",
          "MY"
        ],
        "release_date": "2017-02-03",
        "images": [
          {
            "height": 160,
            "width": 160,
            "url": "https://i.kfs.io/album/global/22396256,2v1/fit/160x160.jpg"
          },
          {
            "height": 500,
            "width": 500,
            "url": "https://i.kfs.io/album/global/22396256,2v1/fit/500x500.jpg"
          },
          {
            "height": 1000,
            "width": 1000,
            "url": "https://i.kfs.io/album/global/22396256,2v1/fit/1000x1000.jpg"
          }
        ],
        "artist": {
          "id": "L_yJ1jz6gunFPJ02QF",
          "name": "Ariana Grande, John Legend",
          "url": "https://event.kkbox.com/content/artist/L_yJ1jz6gunFPJ02QF",
          "images": [
            {
              "height": 160,
              "width": 160,
              "url": "https://i.kfs.io/artist/global/7610849,0v3/fit/160x160.jpg"
            },
            {
              "height": 300,
              "width": 300,
              "url": "https://i.kfs.io/artist/global/7610849,0v3/fit/300x300.jpg"
            }
          ]
        }
      }
    }
  ],
  "paging": {
    "offset": 0,
    "limit": 3,
    "previous": null,
    "next": "https://api.kkbox.com/v1.1/shared-playlists/-meJqWeQgu9_xxSLSy/tracks?limit=3&offset=3"
  },
  "summary": {
    "total": 102
  }
}

Path Params

playlist_id
string
required

歌單 id

Query Params

territory
string
required

地區參數,可以使用的有: TW, HK, SG, MY, JP

limit
int32

每頁返回的結果數量,最多不能超過 500

offset
int32

跳過頁數