curl 'https://api.datawake.ai/v1/youtube/playlist?playlist_id=PLP32wGpgzmIlInfgKVFfCwVsxgGqZNIiS' \
-H 'x-api-key: YOUR_API_KEY' \
-H 'Accept: application/json'
const response = await fetch("https://api.datawake.ai/v1/youtube/playlist?playlist_id=PLP32wGpgzmIlInfgKVFfCwVsxgGqZNIiS", {
method: "GET",
headers: {
'x-api-key': 'YOUR_API_KEY',
'Accept': 'application/json',
},
});
const data = await response.json();
console.log(data);
import requests
response = requests.request(
"GET",
"https://api.datawake.ai/v1/youtube/playlist?playlist_id=PLP32wGpgzmIlInfgKVFfCwVsxgGqZNIiS",
headers={
"x-api-key": "YOUR_API_KEY",
"Accept": "application/json",
},
)
print(response.json())
$ch = curl_init();
curl_setopt_array($ch, [
CURLOPT_URL => "https://api.datawake.ai/v1/youtube/playlist?playlist_id=PLP32wGpgzmIlInfgKVFfCwVsxgGqZNIiS",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
'x-api-key: YOUR_API_KEY',
'Accept: application/json',
],
]);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
client := &http.Client{}
req, err := http.NewRequest("GET", "https://api.datawake.ai/v1/youtube/playlist?playlist_id=PLP32wGpgzmIlInfgKVFfCwVsxgGqZNIiS", nil)
if err != nil {
panic(err)
}
req.Header.Set("x-api-key", "YOUR_API_KEY")
req.Header.Set("Accept", "application/json")
resp, err := client.Do(req)
if err != nil {
panic(err)
}
defer resp.Body.Close()
body, _ := io.ReadAll(resp.Body)
fmt.Println(string(body))
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.datawake.ai/v1/youtube/playlist?playlist_id=PLP32wGpgzmIlInfgKVFfCwVsxgGqZNIiS"))
.header("x-api-key", "YOUR_API_KEY")
.header("Accept", "application/json")
.method("GET", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse<String> response = HttpClient.newHttpClient()
.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());