POST Batch fetch basic meta data for episodes
{{baseUrl}}/episodes
HEADERS

X-ListenAPI-Key
{{apiKey}}
BODY formUrlEncoded

ids
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/episodes");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "x-listenapi-key: {{apiKey}}");
headers = curl_slist_append(headers, "content-type: application/x-www-form-urlencoded");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/episodes" {:headers {:x-listenapi-key "{{apiKey}}"
                                                               :content-type "application/x-www-form-urlencoded"}})
require "http/client"

url = "{{baseUrl}}/episodes"
headers = HTTP::Headers{
  "x-listenapi-key" => "{{apiKey}}"
  "content-type" => "application/x-www-form-urlencoded"
}

response = HTTP::Client.post url, headers: headers
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/episodes"),
    Headers =
    {
        { "x-listenapi-key", "{{apiKey}}" },
    },
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/episodes");
var request = new RestRequest("", Method.Post);
request.AddHeader("x-listenapi-key", "{{apiKey}}");
request.AddHeader("content-type", "application/x-www-form-urlencoded");
var response = client.Execute(request);
package main

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

func main() {

	url := "{{baseUrl}}/episodes"

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

	req.Header.Add("x-listenapi-key", "{{apiKey}}")
	req.Header.Add("content-type", "application/x-www-form-urlencoded")

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

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

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

}
POST /baseUrl/episodes HTTP/1.1
X-Listenapi-Key: {{apiKey}}
Content-Type: application/x-www-form-urlencoded
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/episodes")
  .setHeader("x-listenapi-key", "{{apiKey}}")
  .setHeader("content-type", "application/x-www-form-urlencoded")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/episodes"))
    .header("x-listenapi-key", "{{apiKey}}")
    .header("content-type", "application/x-www-form-urlencoded")
    .method("POST", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/episodes")
  .post(null)
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .addHeader("content-type", "application/x-www-form-urlencoded")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/episodes")
  .header("x-listenapi-key", "{{apiKey}}")
  .header("content-type", "application/x-www-form-urlencoded")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/episodes');
xhr.setRequestHeader('x-listenapi-key', '{{apiKey}}');
xhr.setRequestHeader('content-type', 'application/x-www-form-urlencoded');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'POST',
  url: '{{baseUrl}}/episodes',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  }
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/episodes';
const options = {
  method: 'POST',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  }
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/episodes',
  method: 'POST',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  }
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/episodes")
  .post(null)
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .addHeader("content-type", "application/x-www-form-urlencoded")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/episodes',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  }
};

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

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

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

req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/episodes',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  }
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/episodes');

req.headers({
  'x-listenapi-key': '{{apiKey}}',
  'content-type': 'application/x-www-form-urlencoded'
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'POST',
  url: '{{baseUrl}}/episodes',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  }
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/episodes';
const options = {
  method: 'POST',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  }
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"x-listenapi-key": @"{{apiKey}}",
                           @"content-type": @"application/x-www-form-urlencoded" };

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/episodes"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/episodes" in
let headers = Header.add_list (Header.init ()) [
  ("x-listenapi-key", "{{apiKey}}");
  ("content-type", "application/x-www-form-urlencoded");
] in

Client.call ~headers `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/episodes",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => "",
  CURLOPT_HTTPHEADER => [
    "content-type: application/x-www-form-urlencoded",
    "x-listenapi-key: {{apiKey}}"
  ],
]);

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

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/episodes', [
  'headers' => [
    'content-type' => 'application/x-www-form-urlencoded',
    'x-listenapi-key' => '{{apiKey}}',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/episodes');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}',
  'content-type' => 'application/x-www-form-urlencoded'
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/episodes');
$request->setRequestMethod('POST');
$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}',
  'content-type' => 'application/x-www-form-urlencoded'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$headers.Add("content-type", "application/x-www-form-urlencoded")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/episodes' -Method POST -Headers $headers
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$headers.Add("content-type", "application/x-www-form-urlencoded")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/episodes' -Method POST -Headers $headers
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = ""

headers = {
    'x-listenapi-key': "{{apiKey}}",
    'content-type': "application/x-www-form-urlencoded"
}

conn.request("POST", "/baseUrl/episodes", payload, headers)

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

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/episodes"

payload = ""
headers = {
    "x-listenapi-key": "{{apiKey}}",
    "content-type": "application/x-www-form-urlencoded"
}

response = requests.post(url, data=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/episodes"

payload <- ""

response <- VERB("POST", url, body = payload, add_headers('x-listenapi-key' = '{{apiKey}}'), content_type(""))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/episodes")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["x-listenapi-key"] = '{{apiKey}}'
request["content-type"] = 'application/x-www-form-urlencoded'

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/x-www-form-urlencoded'}
)

response = conn.post('/baseUrl/episodes') do |req|
  req.headers['x-listenapi-key'] = '{{apiKey}}'
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/episodes";

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("x-listenapi-key", "{{apiKey}}".parse().unwrap());
    headers.insert("content-type", "application/x-www-form-urlencoded".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/episodes \
  --header 'content-type: application/x-www-form-urlencoded' \
  --header 'x-listenapi-key: {{apiKey}}'
http POST {{baseUrl}}/episodes \
  content-type:application/x-www-form-urlencoded \
  x-listenapi-key:'{{apiKey}}'
wget --quiet \
  --method POST \
  --header 'x-listenapi-key: {{apiKey}}' \
  --header 'content-type: application/x-www-form-urlencoded' \
  --output-document \
  - {{baseUrl}}/episodes
import Foundation

let headers = [
  "x-listenapi-key": "{{apiKey}}",
  "content-type": "application/x-www-form-urlencoded"
]

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/episodes")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
POST Batch fetch basic meta data for podcasts
{{baseUrl}}/podcasts
HEADERS

X-ListenAPI-Key
{{apiKey}}
BODY formUrlEncoded

ids
rsses
itunes_ids
show_latest_episodes
next_episode_pub_date
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/podcasts");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "x-listenapi-key: {{apiKey}}");
headers = curl_slist_append(headers, "content-type: application/x-www-form-urlencoded");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/podcasts" {:headers {:x-listenapi-key "{{apiKey}}"
                                                               :content-type "application/x-www-form-urlencoded"}})
require "http/client"

url = "{{baseUrl}}/podcasts"
headers = HTTP::Headers{
  "x-listenapi-key" => "{{apiKey}}"
  "content-type" => "application/x-www-form-urlencoded"
}

response = HTTP::Client.post url, headers: headers
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/podcasts"),
    Headers =
    {
        { "x-listenapi-key", "{{apiKey}}" },
    },
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/podcasts");
var request = new RestRequest("", Method.Post);
request.AddHeader("x-listenapi-key", "{{apiKey}}");
request.AddHeader("content-type", "application/x-www-form-urlencoded");
var response = client.Execute(request);
package main

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

func main() {

	url := "{{baseUrl}}/podcasts"

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

	req.Header.Add("x-listenapi-key", "{{apiKey}}")
	req.Header.Add("content-type", "application/x-www-form-urlencoded")

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

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

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

}
POST /baseUrl/podcasts HTTP/1.1
X-Listenapi-Key: {{apiKey}}
Content-Type: application/x-www-form-urlencoded
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/podcasts")
  .setHeader("x-listenapi-key", "{{apiKey}}")
  .setHeader("content-type", "application/x-www-form-urlencoded")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/podcasts"))
    .header("x-listenapi-key", "{{apiKey}}")
    .header("content-type", "application/x-www-form-urlencoded")
    .method("POST", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/podcasts")
  .post(null)
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .addHeader("content-type", "application/x-www-form-urlencoded")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/podcasts")
  .header("x-listenapi-key", "{{apiKey}}")
  .header("content-type", "application/x-www-form-urlencoded")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/podcasts');
xhr.setRequestHeader('x-listenapi-key', '{{apiKey}}');
xhr.setRequestHeader('content-type', 'application/x-www-form-urlencoded');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'POST',
  url: '{{baseUrl}}/podcasts',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  }
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/podcasts';
const options = {
  method: 'POST',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  }
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/podcasts',
  method: 'POST',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  }
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/podcasts")
  .post(null)
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .addHeader("content-type", "application/x-www-form-urlencoded")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/podcasts',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  }
};

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

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

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

req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/podcasts',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  }
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/podcasts');

req.headers({
  'x-listenapi-key': '{{apiKey}}',
  'content-type': 'application/x-www-form-urlencoded'
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'POST',
  url: '{{baseUrl}}/podcasts',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  }
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/podcasts';
const options = {
  method: 'POST',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  }
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"x-listenapi-key": @"{{apiKey}}",
                           @"content-type": @"application/x-www-form-urlencoded" };

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/podcasts"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/podcasts" in
let headers = Header.add_list (Header.init ()) [
  ("x-listenapi-key", "{{apiKey}}");
  ("content-type", "application/x-www-form-urlencoded");
] in

Client.call ~headers `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/podcasts",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => "",
  CURLOPT_HTTPHEADER => [
    "content-type: application/x-www-form-urlencoded",
    "x-listenapi-key: {{apiKey}}"
  ],
]);

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

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/podcasts', [
  'headers' => [
    'content-type' => 'application/x-www-form-urlencoded',
    'x-listenapi-key' => '{{apiKey}}',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/podcasts');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}',
  'content-type' => 'application/x-www-form-urlencoded'
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/podcasts');
$request->setRequestMethod('POST');
$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}',
  'content-type' => 'application/x-www-form-urlencoded'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$headers.Add("content-type", "application/x-www-form-urlencoded")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/podcasts' -Method POST -Headers $headers
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$headers.Add("content-type", "application/x-www-form-urlencoded")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/podcasts' -Method POST -Headers $headers
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = ""

headers = {
    'x-listenapi-key': "{{apiKey}}",
    'content-type': "application/x-www-form-urlencoded"
}

conn.request("POST", "/baseUrl/podcasts", payload, headers)

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

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/podcasts"

payload = ""
headers = {
    "x-listenapi-key": "{{apiKey}}",
    "content-type": "application/x-www-form-urlencoded"
}

response = requests.post(url, data=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/podcasts"

payload <- ""

response <- VERB("POST", url, body = payload, add_headers('x-listenapi-key' = '{{apiKey}}'), content_type(""))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/podcasts")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["x-listenapi-key"] = '{{apiKey}}'
request["content-type"] = 'application/x-www-form-urlencoded'

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/x-www-form-urlencoded'}
)

response = conn.post('/baseUrl/podcasts') do |req|
  req.headers['x-listenapi-key'] = '{{apiKey}}'
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/podcasts";

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("x-listenapi-key", "{{apiKey}}".parse().unwrap());
    headers.insert("content-type", "application/x-www-form-urlencoded".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/podcasts \
  --header 'content-type: application/x-www-form-urlencoded' \
  --header 'x-listenapi-key: {{apiKey}}'
http POST {{baseUrl}}/podcasts \
  content-type:application/x-www-form-urlencoded \
  x-listenapi-key:'{{apiKey}}'
wget --quiet \
  --method POST \
  --header 'x-listenapi-key: {{apiKey}}' \
  --header 'content-type: application/x-www-form-urlencoded' \
  --output-document \
  - {{baseUrl}}/podcasts
import Foundation

let headers = [
  "x-listenapi-key": "{{apiKey}}",
  "content-type": "application/x-www-form-urlencoded"
]

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/podcasts")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
GET Fetch a curated list of podcasts by id
{{baseUrl}}/curated_podcasts/:id
HEADERS

X-ListenAPI-Key
{{apiKey}}
QUERY PARAMS

id
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/curated_podcasts/:id");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "x-listenapi-key: {{apiKey}}");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/curated_podcasts/:id" {:headers {:x-listenapi-key "{{apiKey}}"}})
require "http/client"

url = "{{baseUrl}}/curated_podcasts/:id"
headers = HTTP::Headers{
  "x-listenapi-key" => "{{apiKey}}"
}

response = HTTP::Client.get url, headers: headers
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/curated_podcasts/:id"),
    Headers =
    {
        { "x-listenapi-key", "{{apiKey}}" },
    },
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/curated_podcasts/:id");
var request = new RestRequest("", Method.Get);
request.AddHeader("x-listenapi-key", "{{apiKey}}");
var response = client.Execute(request);
package main

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

func main() {

	url := "{{baseUrl}}/curated_podcasts/:id"

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

	req.Header.Add("x-listenapi-key", "{{apiKey}}")

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

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

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

}
GET /baseUrl/curated_podcasts/:id HTTP/1.1
X-Listenapi-Key: {{apiKey}}
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/curated_podcasts/:id")
  .setHeader("x-listenapi-key", "{{apiKey}}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/curated_podcasts/:id"))
    .header("x-listenapi-key", "{{apiKey}}")
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/curated_podcasts/:id")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/curated_podcasts/:id")
  .header("x-listenapi-key", "{{apiKey}}")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/curated_podcasts/:id');
xhr.setRequestHeader('x-listenapi-key', '{{apiKey}}');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/curated_podcasts/:id',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/curated_podcasts/:id';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/curated_podcasts/:id',
  method: 'GET',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/curated_podcasts/:id")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/curated_podcasts/:id',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

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

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

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

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/curated_podcasts/:id',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/curated_podcasts/:id');

req.headers({
  'x-listenapi-key': '{{apiKey}}'
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/curated_podcasts/:id',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/curated_podcasts/:id';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"x-listenapi-key": @"{{apiKey}}" };

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/curated_podcasts/:id"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
[request setAllHTTPHeaderFields:headers];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/curated_podcasts/:id" in
let headers = Header.add (Header.init ()) "x-listenapi-key" "{{apiKey}}" in

Client.call ~headers `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/curated_podcasts/:id",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => [
    "x-listenapi-key: {{apiKey}}"
  ],
]);

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

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/curated_podcasts/:id', [
  'headers' => [
    'x-listenapi-key' => '{{apiKey}}',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/curated_podcasts/:id');
$request->setMethod(HTTP_METH_GET);

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/curated_podcasts/:id');
$request->setRequestMethod('GET');
$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/curated_podcasts/:id' -Method GET -Headers $headers
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/curated_podcasts/:id' -Method GET -Headers $headers
import http.client

conn = http.client.HTTPSConnection("example.com")

headers = { 'x-listenapi-key': "{{apiKey}}" }

conn.request("GET", "/baseUrl/curated_podcasts/:id", headers=headers)

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

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/curated_podcasts/:id"

headers = {"x-listenapi-key": "{{apiKey}}"}

response = requests.get(url, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/curated_podcasts/:id"

response <- VERB("GET", url, add_headers('x-listenapi-key' = '{{apiKey}}'), content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/curated_podcasts/:id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["x-listenapi-key"] = '{{apiKey}}'

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/curated_podcasts/:id') do |req|
  req.headers['x-listenapi-key'] = '{{apiKey}}'
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/curated_podcasts/:id";

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("x-listenapi-key", "{{apiKey}}".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.get(url)
        .headers(headers)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/curated_podcasts/:id \
  --header 'x-listenapi-key: {{apiKey}}'
http GET {{baseUrl}}/curated_podcasts/:id \
  x-listenapi-key:'{{apiKey}}'
wget --quiet \
  --method GET \
  --header 'x-listenapi-key: {{apiKey}}' \
  --output-document \
  - {{baseUrl}}/curated_podcasts/:id
import Foundation

let headers = ["x-listenapi-key": "{{apiKey}}"]

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/curated_podcasts/:id")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "id": "Vb017Sx3l8F",
  "description": "Commuting to work is always better when you have a great new podcast to listen to, and this year, we have discovered some of our favorite podcasts yet for readers and book-lovers. These podcasts for readers entertain us and provide no shortage of new book recommendations too.",
  "source_url": "https://parade.com/718913/ashley_johnson/7-bookish-podcasts-for-avid-readers-on-the-go/",
  "source_domain": "parade.com",
  "pub_date_ms": 1556843484301,
  "listennotes_url": "https://www.listennotes.com/curated-podcasts/7-bookish-podcasts-for-avid-readers-on-H2r-TCWai8K/",
  "title": "7 Bookish Podcasts for Avid Readers On the Go",
  "total": 25
}
GET Fetch a list of best podcasts by genre
{{baseUrl}}/best_podcasts
HEADERS

X-ListenAPI-Key
{{apiKey}}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/best_podcasts");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "x-listenapi-key: {{apiKey}}");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/best_podcasts" {:headers {:x-listenapi-key "{{apiKey}}"}})
require "http/client"

url = "{{baseUrl}}/best_podcasts"
headers = HTTP::Headers{
  "x-listenapi-key" => "{{apiKey}}"
}

response = HTTP::Client.get url, headers: headers
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/best_podcasts"),
    Headers =
    {
        { "x-listenapi-key", "{{apiKey}}" },
    },
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/best_podcasts");
var request = new RestRequest("", Method.Get);
request.AddHeader("x-listenapi-key", "{{apiKey}}");
var response = client.Execute(request);
package main

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

func main() {

	url := "{{baseUrl}}/best_podcasts"

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

	req.Header.Add("x-listenapi-key", "{{apiKey}}")

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

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

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

}
GET /baseUrl/best_podcasts HTTP/1.1
X-Listenapi-Key: {{apiKey}}
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/best_podcasts")
  .setHeader("x-listenapi-key", "{{apiKey}}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/best_podcasts"))
    .header("x-listenapi-key", "{{apiKey}}")
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/best_podcasts")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/best_podcasts")
  .header("x-listenapi-key", "{{apiKey}}")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/best_podcasts');
xhr.setRequestHeader('x-listenapi-key', '{{apiKey}}');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/best_podcasts',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/best_podcasts';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/best_podcasts',
  method: 'GET',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/best_podcasts")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/best_podcasts',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

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

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

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

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/best_podcasts',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/best_podcasts');

req.headers({
  'x-listenapi-key': '{{apiKey}}'
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/best_podcasts',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/best_podcasts';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"x-listenapi-key": @"{{apiKey}}" };

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/best_podcasts"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
[request setAllHTTPHeaderFields:headers];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/best_podcasts" in
let headers = Header.add (Header.init ()) "x-listenapi-key" "{{apiKey}}" in

Client.call ~headers `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/best_podcasts",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => [
    "x-listenapi-key: {{apiKey}}"
  ],
]);

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

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/best_podcasts', [
  'headers' => [
    'x-listenapi-key' => '{{apiKey}}',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/best_podcasts');
$request->setMethod(HTTP_METH_GET);

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/best_podcasts');
$request->setRequestMethod('GET');
$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/best_podcasts' -Method GET -Headers $headers
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/best_podcasts' -Method GET -Headers $headers
import http.client

conn = http.client.HTTPSConnection("example.com")

headers = { 'x-listenapi-key': "{{apiKey}}" }

conn.request("GET", "/baseUrl/best_podcasts", headers=headers)

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

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/best_podcasts"

headers = {"x-listenapi-key": "{{apiKey}}"}

response = requests.get(url, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/best_podcasts"

response <- VERB("GET", url, add_headers('x-listenapi-key' = '{{apiKey}}'), content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/best_podcasts")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["x-listenapi-key"] = '{{apiKey}}'

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/best_podcasts') do |req|
  req.headers['x-listenapi-key'] = '{{apiKey}}'
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/best_podcasts";

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("x-listenapi-key", "{{apiKey}}".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.get(url)
        .headers(headers)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/best_podcasts \
  --header 'x-listenapi-key: {{apiKey}}'
http GET {{baseUrl}}/best_podcasts \
  x-listenapi-key:'{{apiKey}}'
wget --quiet \
  --method GET \
  --header 'x-listenapi-key: {{apiKey}}' \
  --output-document \
  - {{baseUrl}}/best_podcasts
import Foundation

let headers = ["x-listenapi-key": "{{apiKey}}"]

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/best_podcasts")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "name": "Business News",
  "listennotes_url": "https://www.listennotes.com/best-business-news-podcasts-95/",
  "previous_page_number": 1,
  "page_number": 2,
  "has_next": true,
  "next_page_number": 3,
  "parent_id": 93,
  "id": 95,
  "total": 325
}
GET Fetch a list of podcast genres
{{baseUrl}}/genres
HEADERS

X-ListenAPI-Key
{{apiKey}}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/genres");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "x-listenapi-key: {{apiKey}}");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/genres" {:headers {:x-listenapi-key "{{apiKey}}"}})
require "http/client"

url = "{{baseUrl}}/genres"
headers = HTTP::Headers{
  "x-listenapi-key" => "{{apiKey}}"
}

response = HTTP::Client.get url, headers: headers
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/genres"),
    Headers =
    {
        { "x-listenapi-key", "{{apiKey}}" },
    },
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/genres");
var request = new RestRequest("", Method.Get);
request.AddHeader("x-listenapi-key", "{{apiKey}}");
var response = client.Execute(request);
package main

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

func main() {

	url := "{{baseUrl}}/genres"

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

	req.Header.Add("x-listenapi-key", "{{apiKey}}")

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

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

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

}
GET /baseUrl/genres HTTP/1.1
X-Listenapi-Key: {{apiKey}}
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/genres")
  .setHeader("x-listenapi-key", "{{apiKey}}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/genres"))
    .header("x-listenapi-key", "{{apiKey}}")
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/genres")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/genres")
  .header("x-listenapi-key", "{{apiKey}}")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/genres');
xhr.setRequestHeader('x-listenapi-key', '{{apiKey}}');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/genres',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/genres';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/genres',
  method: 'GET',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/genres")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/genres',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

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

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

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

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/genres',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/genres');

req.headers({
  'x-listenapi-key': '{{apiKey}}'
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/genres',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/genres';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"x-listenapi-key": @"{{apiKey}}" };

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/genres"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
[request setAllHTTPHeaderFields:headers];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/genres" in
let headers = Header.add (Header.init ()) "x-listenapi-key" "{{apiKey}}" in

Client.call ~headers `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/genres",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => [
    "x-listenapi-key: {{apiKey}}"
  ],
]);

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

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/genres', [
  'headers' => [
    'x-listenapi-key' => '{{apiKey}}',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/genres');
$request->setMethod(HTTP_METH_GET);

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/genres');
$request->setRequestMethod('GET');
$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/genres' -Method GET -Headers $headers
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/genres' -Method GET -Headers $headers
import http.client

conn = http.client.HTTPSConnection("example.com")

headers = { 'x-listenapi-key': "{{apiKey}}" }

conn.request("GET", "/baseUrl/genres", headers=headers)

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

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/genres"

headers = {"x-listenapi-key": "{{apiKey}}"}

response = requests.get(url, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/genres"

response <- VERB("GET", url, add_headers('x-listenapi-key' = '{{apiKey}}'), content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/genres")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["x-listenapi-key"] = '{{apiKey}}'

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/genres') do |req|
  req.headers['x-listenapi-key'] = '{{apiKey}}'
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/genres";

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("x-listenapi-key", "{{apiKey}}".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.get(url)
        .headers(headers)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/genres \
  --header 'x-listenapi-key: {{apiKey}}'
http GET {{baseUrl}}/genres \
  x-listenapi-key:'{{apiKey}}'
wget --quiet \
  --method GET \
  --header 'x-listenapi-key: {{apiKey}}' \
  --output-document \
  - {{baseUrl}}/genres
import Foundation

let headers = ["x-listenapi-key": "{{apiKey}}"]

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/genres")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "genres": [
    {
      "id": 140,
      "parent_id": 127,
      "name": "Web Design"
    }
  ]
}
GET Fetch a list of supported countries-regions for best podcasts
{{baseUrl}}/regions
HEADERS

X-ListenAPI-Key
{{apiKey}}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/regions");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "x-listenapi-key: {{apiKey}}");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/regions" {:headers {:x-listenapi-key "{{apiKey}}"}})
require "http/client"

url = "{{baseUrl}}/regions"
headers = HTTP::Headers{
  "x-listenapi-key" => "{{apiKey}}"
}

response = HTTP::Client.get url, headers: headers
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/regions"),
    Headers =
    {
        { "x-listenapi-key", "{{apiKey}}" },
    },
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/regions");
var request = new RestRequest("", Method.Get);
request.AddHeader("x-listenapi-key", "{{apiKey}}");
var response = client.Execute(request);
package main

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

func main() {

	url := "{{baseUrl}}/regions"

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

	req.Header.Add("x-listenapi-key", "{{apiKey}}")

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

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

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

}
GET /baseUrl/regions HTTP/1.1
X-Listenapi-Key: {{apiKey}}
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/regions")
  .setHeader("x-listenapi-key", "{{apiKey}}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/regions"))
    .header("x-listenapi-key", "{{apiKey}}")
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/regions")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/regions")
  .header("x-listenapi-key", "{{apiKey}}")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/regions');
xhr.setRequestHeader('x-listenapi-key', '{{apiKey}}');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/regions',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/regions';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/regions',
  method: 'GET',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/regions")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/regions',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

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

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

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

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/regions',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/regions');

req.headers({
  'x-listenapi-key': '{{apiKey}}'
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/regions',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/regions';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"x-listenapi-key": @"{{apiKey}}" };

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/regions"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
[request setAllHTTPHeaderFields:headers];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/regions" in
let headers = Header.add (Header.init ()) "x-listenapi-key" "{{apiKey}}" in

Client.call ~headers `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/regions",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => [
    "x-listenapi-key: {{apiKey}}"
  ],
]);

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

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/regions', [
  'headers' => [
    'x-listenapi-key' => '{{apiKey}}',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/regions');
$request->setMethod(HTTP_METH_GET);

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/regions');
$request->setRequestMethod('GET');
$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/regions' -Method GET -Headers $headers
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/regions' -Method GET -Headers $headers
import http.client

conn = http.client.HTTPSConnection("example.com")

headers = { 'x-listenapi-key': "{{apiKey}}" }

conn.request("GET", "/baseUrl/regions", headers=headers)

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

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/regions"

headers = {"x-listenapi-key": "{{apiKey}}"}

response = requests.get(url, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/regions"

response <- VERB("GET", url, add_headers('x-listenapi-key' = '{{apiKey}}'), content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/regions")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["x-listenapi-key"] = '{{apiKey}}'

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/regions') do |req|
  req.headers['x-listenapi-key'] = '{{apiKey}}'
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/regions";

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("x-listenapi-key", "{{apiKey}}".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.get(url)
        .headers(headers)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/regions \
  --header 'x-listenapi-key: {{apiKey}}'
http GET {{baseUrl}}/regions \
  x-listenapi-key:'{{apiKey}}'
wget --quiet \
  --method GET \
  --header 'x-listenapi-key: {{apiKey}}' \
  --output-document \
  - {{baseUrl}}/regions
import Foundation

let headers = ["x-listenapi-key": "{{apiKey}}"]

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/regions")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "regions": {
    "de": "Germany",
    "us": "United States",
    "au": "Australia",
    "ua": "Ukraine"
  }
}
GET Fetch a list of supported languages for podcasts
{{baseUrl}}/languages
HEADERS

X-ListenAPI-Key
{{apiKey}}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/languages");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "x-listenapi-key: {{apiKey}}");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/languages" {:headers {:x-listenapi-key "{{apiKey}}"}})
require "http/client"

url = "{{baseUrl}}/languages"
headers = HTTP::Headers{
  "x-listenapi-key" => "{{apiKey}}"
}

response = HTTP::Client.get url, headers: headers
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/languages"),
    Headers =
    {
        { "x-listenapi-key", "{{apiKey}}" },
    },
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/languages");
var request = new RestRequest("", Method.Get);
request.AddHeader("x-listenapi-key", "{{apiKey}}");
var response = client.Execute(request);
package main

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

func main() {

	url := "{{baseUrl}}/languages"

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

	req.Header.Add("x-listenapi-key", "{{apiKey}}")

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

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

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

}
GET /baseUrl/languages HTTP/1.1
X-Listenapi-Key: {{apiKey}}
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/languages")
  .setHeader("x-listenapi-key", "{{apiKey}}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/languages"))
    .header("x-listenapi-key", "{{apiKey}}")
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/languages")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/languages")
  .header("x-listenapi-key", "{{apiKey}}")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/languages');
xhr.setRequestHeader('x-listenapi-key', '{{apiKey}}');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/languages',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/languages';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/languages',
  method: 'GET',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/languages")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/languages',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

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

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

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

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/languages',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/languages');

req.headers({
  'x-listenapi-key': '{{apiKey}}'
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/languages',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/languages';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"x-listenapi-key": @"{{apiKey}}" };

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/languages"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
[request setAllHTTPHeaderFields:headers];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/languages" in
let headers = Header.add (Header.init ()) "x-listenapi-key" "{{apiKey}}" in

Client.call ~headers `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/languages",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => [
    "x-listenapi-key: {{apiKey}}"
  ],
]);

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

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/languages', [
  'headers' => [
    'x-listenapi-key' => '{{apiKey}}',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/languages');
$request->setMethod(HTTP_METH_GET);

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/languages');
$request->setRequestMethod('GET');
$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/languages' -Method GET -Headers $headers
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/languages' -Method GET -Headers $headers
import http.client

conn = http.client.HTTPSConnection("example.com")

headers = { 'x-listenapi-key': "{{apiKey}}" }

conn.request("GET", "/baseUrl/languages", headers=headers)

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

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/languages"

headers = {"x-listenapi-key": "{{apiKey}}"}

response = requests.get(url, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/languages"

response <- VERB("GET", url, add_headers('x-listenapi-key' = '{{apiKey}}'), content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/languages")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["x-listenapi-key"] = '{{apiKey}}'

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/languages') do |req|
  req.headers['x-listenapi-key'] = '{{apiKey}}'
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/languages";

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("x-listenapi-key", "{{apiKey}}".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.get(url)
        .headers(headers)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/languages \
  --header 'x-listenapi-key: {{apiKey}}'
http GET {{baseUrl}}/languages \
  x-listenapi-key:'{{apiKey}}'
wget --quiet \
  --method GET \
  --header 'x-listenapi-key: {{apiKey}}' \
  --output-document \
  - {{baseUrl}}/languages
import Foundation

let headers = ["x-listenapi-key": "{{apiKey}}"]

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/languages")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "languages": [
    "Any language",
    "Afar",
    "Abkhazian",
    "Afrikaans",
    "Akan",
    "Albanian",
    "Arabic",
    "Azerbaijani",
    "Bambara",
    "Bashkir",
    "Basque",
    "Belarusian",
    "Bulgarian",
    "Catalan",
    "Chamorro",
    "Chinese",
    "Croatian",
    "Czech",
    "Danish",
    "Dutch",
    "English",
    "Estonian",
    "Faeroese",
    "Finnish",
    "French",
    "Gaelic",
    "Galician",
    "German",
    "Greek"
  ]
}
GET Fetch a random podcast episode
{{baseUrl}}/just_listen
HEADERS

X-ListenAPI-Key
{{apiKey}}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/just_listen");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "x-listenapi-key: {{apiKey}}");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/just_listen" {:headers {:x-listenapi-key "{{apiKey}}"}})
require "http/client"

url = "{{baseUrl}}/just_listen"
headers = HTTP::Headers{
  "x-listenapi-key" => "{{apiKey}}"
}

response = HTTP::Client.get url, headers: headers
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/just_listen"),
    Headers =
    {
        { "x-listenapi-key", "{{apiKey}}" },
    },
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/just_listen");
var request = new RestRequest("", Method.Get);
request.AddHeader("x-listenapi-key", "{{apiKey}}");
var response = client.Execute(request);
package main

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

func main() {

	url := "{{baseUrl}}/just_listen"

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

	req.Header.Add("x-listenapi-key", "{{apiKey}}")

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

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

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

}
GET /baseUrl/just_listen HTTP/1.1
X-Listenapi-Key: {{apiKey}}
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/just_listen")
  .setHeader("x-listenapi-key", "{{apiKey}}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/just_listen"))
    .header("x-listenapi-key", "{{apiKey}}")
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/just_listen")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/just_listen")
  .header("x-listenapi-key", "{{apiKey}}")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/just_listen');
xhr.setRequestHeader('x-listenapi-key', '{{apiKey}}');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/just_listen',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/just_listen';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/just_listen',
  method: 'GET',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/just_listen")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/just_listen',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

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

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

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

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/just_listen',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/just_listen');

req.headers({
  'x-listenapi-key': '{{apiKey}}'
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/just_listen',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/just_listen';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"x-listenapi-key": @"{{apiKey}}" };

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/just_listen"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
[request setAllHTTPHeaderFields:headers];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/just_listen" in
let headers = Header.add (Header.init ()) "x-listenapi-key" "{{apiKey}}" in

Client.call ~headers `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/just_listen",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => [
    "x-listenapi-key: {{apiKey}}"
  ],
]);

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

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/just_listen', [
  'headers' => [
    'x-listenapi-key' => '{{apiKey}}',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/just_listen');
$request->setMethod(HTTP_METH_GET);

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/just_listen');
$request->setRequestMethod('GET');
$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/just_listen' -Method GET -Headers $headers
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/just_listen' -Method GET -Headers $headers
import http.client

conn = http.client.HTTPSConnection("example.com")

headers = { 'x-listenapi-key': "{{apiKey}}" }

conn.request("GET", "/baseUrl/just_listen", headers=headers)

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

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/just_listen"

headers = {"x-listenapi-key": "{{apiKey}}"}

response = requests.get(url, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/just_listen"

response <- VERB("GET", url, add_headers('x-listenapi-key' = '{{apiKey}}'), content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/just_listen")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["x-listenapi-key"] = '{{apiKey}}'

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/just_listen') do |req|
  req.headers['x-listenapi-key'] = '{{apiKey}}'
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/just_listen";

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("x-listenapi-key", "{{apiKey}}".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.get(url)
        .headers(headers)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/just_listen \
  --header 'x-listenapi-key: {{apiKey}}'
http GET {{baseUrl}}/just_listen \
  x-listenapi-key:'{{apiKey}}'
wget --quiet \
  --method GET \
  --header 'x-listenapi-key: {{apiKey}}' \
  --output-document \
  - {{baseUrl}}/just_listen
import Foundation

let headers = ["x-listenapi-key": "{{apiKey}}"]

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/just_listen")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "maybe_audio_invalid": false,
  "pub_date_ms": 1474873200000,
  "audio": "https://www.listennotes.com/e/p/11b34041e804491b9704d11f283c74de/",
  "listennotes_edit_url": "https://www.listennotes.com/e/11b34041e804491b9704d11f283c74de/#edit",
  "image": "https://cdn-images-1.listennotes.com/podcasts/exponent-ben-thompson-james-allworth-OaJSjb4xQv3.1400x1400.jpg",
  "thumbnail": "https://cdn-images-1.listennotes.com/podcasts/exponent-ben-thompson-james-allworth-OaJSjb4xQv3.300x300.jpg",
  "description": "

Disney chief Bob Iger shared news about Star Wars movies in 2020 and beyond, but some media outlets gave conflicting reports about it. Here's the real scoop. Punch it!

***We’re listener supported! Go to http://Patreon.com/sw7x7 to donate to the Star Wars 7x7 podcast, and you’ll get some fabulous rewards for your pledge.*** 

Check out SW7x7.com for full Star Wars 7x7 show notes and links, and to comment on any of the content of this episode! If you like what you've heard, please leave us a rating or review on iTunes or Stitcher, which will also help more people discover this Star Wars podcast.

Don't forget to join the Star Wars 7x7 fun on Facebook at Facebook.com/SW7x7, and follow the breaking news Twitter feed at Twitter.com/SW7x7Podcast. We're also on Pinterest and Instagram as \"SW7x7\" too, and we'd love to connect with you there!

\n", "title": "Celebration Recap, Jason Fry and Christian Blauvelt Interviews – SWBW #101", "explicit_content": false, "listennotes_url": "https://www.listennotes.com/e/4d82e50314174754a3b603912448e812/", "audio_length_sec": 567, "id": "4d82e50314174754a3b603912448e812", "link": "https://www.npr.org/2020/01/22/798532179/soleimanis-iran", "podcast": { "image": "https://cdn-images-1.listennotes.com/podcasts/exponent-ben-thompson-james-allworth-OaJSjb4xQv3.1400x1400.jpg", "thumbnail": "https://cdn-images-1.listennotes.com/podcasts/exponent-ben-thompson-james-allworth-OaJSjb4xQv3.300x300.jpg", "title": "Star Wars 7x7 | Star Wars News, Interviews, and More!", "listennotes_url": "https://www.listennotes.com/c/4d3fe717742d4963a85562e9f84d8c79/", "id": "4d3fe717742d4963a85562e9f84d8c79", "publisher": "Planet Broadcasting", "listen_score": 81, "listen_score_global_rank": "0.5%" } }
GET Fetch curated lists of podcasts
{{baseUrl}}/curated_podcasts
HEADERS

X-ListenAPI-Key
{{apiKey}}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/curated_podcasts");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "x-listenapi-key: {{apiKey}}");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/curated_podcasts" {:headers {:x-listenapi-key "{{apiKey}}"}})
require "http/client"

url = "{{baseUrl}}/curated_podcasts"
headers = HTTP::Headers{
  "x-listenapi-key" => "{{apiKey}}"
}

response = HTTP::Client.get url, headers: headers
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/curated_podcasts"),
    Headers =
    {
        { "x-listenapi-key", "{{apiKey}}" },
    },
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/curated_podcasts");
var request = new RestRequest("", Method.Get);
request.AddHeader("x-listenapi-key", "{{apiKey}}");
var response = client.Execute(request);
package main

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

func main() {

	url := "{{baseUrl}}/curated_podcasts"

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

	req.Header.Add("x-listenapi-key", "{{apiKey}}")

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

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

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

}
GET /baseUrl/curated_podcasts HTTP/1.1
X-Listenapi-Key: {{apiKey}}
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/curated_podcasts")
  .setHeader("x-listenapi-key", "{{apiKey}}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/curated_podcasts"))
    .header("x-listenapi-key", "{{apiKey}}")
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/curated_podcasts")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/curated_podcasts")
  .header("x-listenapi-key", "{{apiKey}}")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/curated_podcasts');
xhr.setRequestHeader('x-listenapi-key', '{{apiKey}}');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/curated_podcasts',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/curated_podcasts';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/curated_podcasts',
  method: 'GET',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/curated_podcasts")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/curated_podcasts',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

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

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

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

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/curated_podcasts',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/curated_podcasts');

req.headers({
  'x-listenapi-key': '{{apiKey}}'
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/curated_podcasts',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/curated_podcasts';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"x-listenapi-key": @"{{apiKey}}" };

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/curated_podcasts"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
[request setAllHTTPHeaderFields:headers];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/curated_podcasts" in
let headers = Header.add (Header.init ()) "x-listenapi-key" "{{apiKey}}" in

Client.call ~headers `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/curated_podcasts",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => [
    "x-listenapi-key: {{apiKey}}"
  ],
]);

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

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/curated_podcasts', [
  'headers' => [
    'x-listenapi-key' => '{{apiKey}}',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/curated_podcasts');
$request->setMethod(HTTP_METH_GET);

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/curated_podcasts');
$request->setRequestMethod('GET');
$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/curated_podcasts' -Method GET -Headers $headers
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/curated_podcasts' -Method GET -Headers $headers
import http.client

conn = http.client.HTTPSConnection("example.com")

headers = { 'x-listenapi-key': "{{apiKey}}" }

conn.request("GET", "/baseUrl/curated_podcasts", headers=headers)

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

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/curated_podcasts"

headers = {"x-listenapi-key": "{{apiKey}}"}

response = requests.get(url, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/curated_podcasts"

response <- VERB("GET", url, add_headers('x-listenapi-key' = '{{apiKey}}'), content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/curated_podcasts")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["x-listenapi-key"] = '{{apiKey}}'

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/curated_podcasts') do |req|
  req.headers['x-listenapi-key'] = '{{apiKey}}'
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/curated_podcasts";

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("x-listenapi-key", "{{apiKey}}".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.get(url)
        .headers(headers)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/curated_podcasts \
  --header 'x-listenapi-key: {{apiKey}}'
http GET {{baseUrl}}/curated_podcasts \
  x-listenapi-key:'{{apiKey}}'
wget --quiet \
  --method GET \
  --header 'x-listenapi-key: {{apiKey}}' \
  --output-document \
  - {{baseUrl}}/curated_podcasts
import Foundation

let headers = ["x-listenapi-key": "{{apiKey}}"]

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/curated_podcasts")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "has_previous": true,
  "previous_page_number": 1,
  "page_number": 2,
  "next_page_number": 3,
  "has_next": true,
  "total": 25
}
GET Fetch detailed meta data and episodes for a podcast by id
{{baseUrl}}/podcasts/:id
HEADERS

X-ListenAPI-Key
{{apiKey}}
QUERY PARAMS

id
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/podcasts/:id");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "x-listenapi-key: {{apiKey}}");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/podcasts/:id" {:headers {:x-listenapi-key "{{apiKey}}"}})
require "http/client"

url = "{{baseUrl}}/podcasts/:id"
headers = HTTP::Headers{
  "x-listenapi-key" => "{{apiKey}}"
}

response = HTTP::Client.get url, headers: headers
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/podcasts/:id"),
    Headers =
    {
        { "x-listenapi-key", "{{apiKey}}" },
    },
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/podcasts/:id");
var request = new RestRequest("", Method.Get);
request.AddHeader("x-listenapi-key", "{{apiKey}}");
var response = client.Execute(request);
package main

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

func main() {

	url := "{{baseUrl}}/podcasts/:id"

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

	req.Header.Add("x-listenapi-key", "{{apiKey}}")

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

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

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

}
GET /baseUrl/podcasts/:id HTTP/1.1
X-Listenapi-Key: {{apiKey}}
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/podcasts/:id")
  .setHeader("x-listenapi-key", "{{apiKey}}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/podcasts/:id"))
    .header("x-listenapi-key", "{{apiKey}}")
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/podcasts/:id")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/podcasts/:id")
  .header("x-listenapi-key", "{{apiKey}}")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/podcasts/:id');
xhr.setRequestHeader('x-listenapi-key', '{{apiKey}}');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/podcasts/:id',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/podcasts/:id';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/podcasts/:id',
  method: 'GET',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/podcasts/:id")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/podcasts/:id',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

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

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

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

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/podcasts/:id',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/podcasts/:id');

req.headers({
  'x-listenapi-key': '{{apiKey}}'
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/podcasts/:id',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/podcasts/:id';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"x-listenapi-key": @"{{apiKey}}" };

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/podcasts/:id"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
[request setAllHTTPHeaderFields:headers];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/podcasts/:id" in
let headers = Header.add (Header.init ()) "x-listenapi-key" "{{apiKey}}" in

Client.call ~headers `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/podcasts/:id",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => [
    "x-listenapi-key: {{apiKey}}"
  ],
]);

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

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/podcasts/:id', [
  'headers' => [
    'x-listenapi-key' => '{{apiKey}}',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/podcasts/:id');
$request->setMethod(HTTP_METH_GET);

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/podcasts/:id');
$request->setRequestMethod('GET');
$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/podcasts/:id' -Method GET -Headers $headers
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/podcasts/:id' -Method GET -Headers $headers
import http.client

conn = http.client.HTTPSConnection("example.com")

headers = { 'x-listenapi-key': "{{apiKey}}" }

conn.request("GET", "/baseUrl/podcasts/:id", headers=headers)

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

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/podcasts/:id"

headers = {"x-listenapi-key": "{{apiKey}}"}

response = requests.get(url, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/podcasts/:id"

response <- VERB("GET", url, add_headers('x-listenapi-key' = '{{apiKey}}'), content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/podcasts/:id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["x-listenapi-key"] = '{{apiKey}}'

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/podcasts/:id') do |req|
  req.headers['x-listenapi-key'] = '{{apiKey}}'
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/podcasts/:id";

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("x-listenapi-key", "{{apiKey}}".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.get(url)
        .headers(headers)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/podcasts/:id \
  --header 'x-listenapi-key: {{apiKey}}'
http GET {{baseUrl}}/podcasts/:id \
  x-listenapi-key:'{{apiKey}}'
wget --quiet \
  --method GET \
  --header 'x-listenapi-key: {{apiKey}}' \
  --output-document \
  - {{baseUrl}}/podcasts/:id
import Foundation

let headers = ["x-listenapi-key": "{{apiKey}}"]

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/podcasts/:id")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "is_claimed": true,
  "type": "episodic",
  "explicit_content": false,
  "website": "http://sw7x7.com/",
  "total_episodes": 324,
  "earliest_pub_date_ms": 1470667902000,
  "rss": "https://sw7x7.libsyn.com/rss",
  "latest_pub_date_ms": 1557499770000,
  "title": "Star Wars 7x7 | Star Wars News, Interviews, and More!",
  "language": "English",
  "description": "

The Star Wars 7x7 Podcast is Rebel-rousing fun for everyday Jedi, between 7 and 14 minutes a day, 7 days a week. Join host Allen Voivod for Star Wars news, history, interviews, trivia, and deep dives into the Star Wars story as told in movies, books, comics, games, cartoons, and more. Subscribe now for your daily dose of Star Wars joy. It's destiny unleashed!

", "email": "hello@example.com", "image": "https://cdn-images-1.listennotes.com/podcasts/exponent-ben-thompson-james-allworth-OaJSjb4xQv3.1400x1400.jpg", "thumbnail": "https://cdn-images-1.listennotes.com/podcasts/exponent-ben-thompson-james-allworth-OaJSjb4xQv3.300x300.jpg", "listennotes_url": "https://www.listennotes.com/c/4d3fe717742d4963a85562e9f84d8c79/", "id": "4d3fe717742d4963a85562e9f84d8c79", "country": "United States", "publisher": "Planet Broadcasting", "itunes_id": 896354638, "looking_for": { "cohosts": true, "cross_promotion": true, "sponsors": true, "guests": true }, "extra": { "youtube_url": "https://www.youtube.com/sw7x7", "facebook_handle": "sw7x7", "instagram_handle": "sw7x7", "twitter_handle": "SW7x7podcast", "patreon_handle": "sw7x7", "google_url": "https://play.google.com/music/listen?u=0#/ps/I7gdcrqcmvhfnhh2cyqkcg32tkq", "spotify_url": "https://open.spotify.com/show/2rQJUP9Y3HxemiW3JHt9WV" }, "genre_ids": [ 138, 86, 160, 68, 82, 100, 101 ], "next_episode_pub_date": 1470667902000, "listen_score": 81, "listen_score_global_rank": "0.5%" }
GET Fetch detailed meta data for an episode by id
{{baseUrl}}/episodes/:id
HEADERS

X-ListenAPI-Key
{{apiKey}}
QUERY PARAMS

id
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/episodes/:id");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "x-listenapi-key: {{apiKey}}");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/episodes/:id" {:headers {:x-listenapi-key "{{apiKey}}"}})
require "http/client"

url = "{{baseUrl}}/episodes/:id"
headers = HTTP::Headers{
  "x-listenapi-key" => "{{apiKey}}"
}

response = HTTP::Client.get url, headers: headers
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/episodes/:id"),
    Headers =
    {
        { "x-listenapi-key", "{{apiKey}}" },
    },
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/episodes/:id");
var request = new RestRequest("", Method.Get);
request.AddHeader("x-listenapi-key", "{{apiKey}}");
var response = client.Execute(request);
package main

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

func main() {

	url := "{{baseUrl}}/episodes/:id"

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

	req.Header.Add("x-listenapi-key", "{{apiKey}}")

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

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

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

}
GET /baseUrl/episodes/:id HTTP/1.1
X-Listenapi-Key: {{apiKey}}
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/episodes/:id")
  .setHeader("x-listenapi-key", "{{apiKey}}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/episodes/:id"))
    .header("x-listenapi-key", "{{apiKey}}")
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/episodes/:id")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/episodes/:id")
  .header("x-listenapi-key", "{{apiKey}}")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/episodes/:id');
xhr.setRequestHeader('x-listenapi-key', '{{apiKey}}');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/episodes/:id',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/episodes/:id';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/episodes/:id',
  method: 'GET',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/episodes/:id")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/episodes/:id',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

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

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

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

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/episodes/:id',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/episodes/:id');

req.headers({
  'x-listenapi-key': '{{apiKey}}'
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/episodes/:id',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/episodes/:id';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"x-listenapi-key": @"{{apiKey}}" };

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/episodes/:id"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
[request setAllHTTPHeaderFields:headers];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/episodes/:id" in
let headers = Header.add (Header.init ()) "x-listenapi-key" "{{apiKey}}" in

Client.call ~headers `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/episodes/:id",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => [
    "x-listenapi-key: {{apiKey}}"
  ],
]);

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

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/episodes/:id', [
  'headers' => [
    'x-listenapi-key' => '{{apiKey}}',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/episodes/:id');
$request->setMethod(HTTP_METH_GET);

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/episodes/:id');
$request->setRequestMethod('GET');
$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/episodes/:id' -Method GET -Headers $headers
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/episodes/:id' -Method GET -Headers $headers
import http.client

conn = http.client.HTTPSConnection("example.com")

headers = { 'x-listenapi-key': "{{apiKey}}" }

conn.request("GET", "/baseUrl/episodes/:id", headers=headers)

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

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/episodes/:id"

headers = {"x-listenapi-key": "{{apiKey}}"}

response = requests.get(url, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/episodes/:id"

response <- VERB("GET", url, add_headers('x-listenapi-key' = '{{apiKey}}'), content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/episodes/:id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["x-listenapi-key"] = '{{apiKey}}'

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/episodes/:id') do |req|
  req.headers['x-listenapi-key'] = '{{apiKey}}'
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/episodes/:id";

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("x-listenapi-key", "{{apiKey}}".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.get(url)
        .headers(headers)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/episodes/:id \
  --header 'x-listenapi-key: {{apiKey}}'
http GET {{baseUrl}}/episodes/:id \
  x-listenapi-key:'{{apiKey}}'
wget --quiet \
  --method GET \
  --header 'x-listenapi-key: {{apiKey}}' \
  --output-document \
  - {{baseUrl}}/episodes/:id
import Foundation

let headers = ["x-listenapi-key": "{{apiKey}}"]

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/episodes/:id")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "maybe_audio_invalid": false,
  "pub_date_ms": 1474873200000,
  "audio": "https://www.listennotes.com/e/p/11b34041e804491b9704d11f283c74de/",
  "listennotes_edit_url": "https://www.listennotes.com/e/11b34041e804491b9704d11f283c74de/#edit",
  "image": "https://cdn-images-1.listennotes.com/podcasts/exponent-ben-thompson-james-allworth-OaJSjb4xQv3.1400x1400.jpg",
  "thumbnail": "https://cdn-images-1.listennotes.com/podcasts/exponent-ben-thompson-james-allworth-OaJSjb4xQv3.300x300.jpg",
  "description": "

Disney chief Bob Iger shared news about Star Wars movies in 2020 and beyond, but some media outlets gave conflicting reports about it. Here's the real scoop. Punch it!

***We’re listener supported! Go to http://Patreon.com/sw7x7 to donate to the Star Wars 7x7 podcast, and you’ll get some fabulous rewards for your pledge.*** 

Check out SW7x7.com for full Star Wars 7x7 show notes and links, and to comment on any of the content of this episode! If you like what you've heard, please leave us a rating or review on iTunes or Stitcher, which will also help more people discover this Star Wars podcast.

Don't forget to join the Star Wars 7x7 fun on Facebook at Facebook.com/SW7x7, and follow the breaking news Twitter feed at Twitter.com/SW7x7Podcast. We're also on Pinterest and Instagram as \"SW7x7\" too, and we'd love to connect with you there!

\n", "title": "Celebration Recap, Jason Fry and Christian Blauvelt Interviews – SWBW #101", "explicit_content": false, "listennotes_url": "https://www.listennotes.com/e/4d82e50314174754a3b603912448e812/", "audio_length_sec": 567, "id": "4d82e50314174754a3b603912448e812", "podcast": { "is_claimed": true, "type": "episodic", "explicit_content": false, "website": "http://sw7x7.com/", "total_episodes": 324, "earliest_pub_date_ms": 1470667902000, "rss": "https://sw7x7.libsyn.com/rss", "latest_pub_date_ms": 1557499770000, "title": "Star Wars 7x7 | Star Wars News, Interviews, and More!", "language": "English", "description": "

The Star Wars 7x7 Podcast is Rebel-rousing fun for everyday Jedi, between 7 and 14 minutes a day, 7 days a week. Join host Allen Voivod for Star Wars news, history, interviews, trivia, and deep dives into the Star Wars story as told in movies, books, comics, games, cartoons, and more. Subscribe now for your daily dose of Star Wars joy. It's destiny unleashed!

", "email": "hello@example.com", "image": "https://cdn-images-1.listennotes.com/podcasts/exponent-ben-thompson-james-allworth-OaJSjb4xQv3.1400x1400.jpg", "thumbnail": "https://cdn-images-1.listennotes.com/podcasts/exponent-ben-thompson-james-allworth-OaJSjb4xQv3.300x300.jpg", "listennotes_url": "https://www.listennotes.com/c/4d3fe717742d4963a85562e9f84d8c79/", "id": "4d3fe717742d4963a85562e9f84d8c79", "country": "United States", "publisher": "Planet Broadcasting", "itunes_id": 896354638, "genre_ids": [ 138, 86, 160, 68, 82, 100, 101 ], "listen_score": 81, "listen_score_global_rank": "0.5%" }, "link": "https://www.npr.org/2020/01/22/798532179/soleimanis-iran", "transcript": "00:00:07 Welcome to this podcast...\n" }
GET Fetch recommendations for a podcast
{{baseUrl}}/podcasts/:id/recommendations
HEADERS

X-ListenAPI-Key
{{apiKey}}
QUERY PARAMS

id
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/podcasts/:id/recommendations");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "x-listenapi-key: {{apiKey}}");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/podcasts/:id/recommendations" {:headers {:x-listenapi-key "{{apiKey}}"}})
require "http/client"

url = "{{baseUrl}}/podcasts/:id/recommendations"
headers = HTTP::Headers{
  "x-listenapi-key" => "{{apiKey}}"
}

response = HTTP::Client.get url, headers: headers
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/podcasts/:id/recommendations"),
    Headers =
    {
        { "x-listenapi-key", "{{apiKey}}" },
    },
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/podcasts/:id/recommendations");
var request = new RestRequest("", Method.Get);
request.AddHeader("x-listenapi-key", "{{apiKey}}");
var response = client.Execute(request);
package main

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

func main() {

	url := "{{baseUrl}}/podcasts/:id/recommendations"

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

	req.Header.Add("x-listenapi-key", "{{apiKey}}")

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

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

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

}
GET /baseUrl/podcasts/:id/recommendations HTTP/1.1
X-Listenapi-Key: {{apiKey}}
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/podcasts/:id/recommendations")
  .setHeader("x-listenapi-key", "{{apiKey}}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/podcasts/:id/recommendations"))
    .header("x-listenapi-key", "{{apiKey}}")
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/podcasts/:id/recommendations")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/podcasts/:id/recommendations")
  .header("x-listenapi-key", "{{apiKey}}")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/podcasts/:id/recommendations');
xhr.setRequestHeader('x-listenapi-key', '{{apiKey}}');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/podcasts/:id/recommendations',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/podcasts/:id/recommendations';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/podcasts/:id/recommendations',
  method: 'GET',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/podcasts/:id/recommendations")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/podcasts/:id/recommendations',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

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

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

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

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/podcasts/:id/recommendations',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/podcasts/:id/recommendations');

req.headers({
  'x-listenapi-key': '{{apiKey}}'
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/podcasts/:id/recommendations',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/podcasts/:id/recommendations';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"x-listenapi-key": @"{{apiKey}}" };

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/podcasts/:id/recommendations"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
[request setAllHTTPHeaderFields:headers];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/podcasts/:id/recommendations" in
let headers = Header.add (Header.init ()) "x-listenapi-key" "{{apiKey}}" in

Client.call ~headers `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/podcasts/:id/recommendations",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => [
    "x-listenapi-key: {{apiKey}}"
  ],
]);

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

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/podcasts/:id/recommendations', [
  'headers' => [
    'x-listenapi-key' => '{{apiKey}}',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/podcasts/:id/recommendations');
$request->setMethod(HTTP_METH_GET);

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/podcasts/:id/recommendations');
$request->setRequestMethod('GET');
$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/podcasts/:id/recommendations' -Method GET -Headers $headers
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/podcasts/:id/recommendations' -Method GET -Headers $headers
import http.client

conn = http.client.HTTPSConnection("example.com")

headers = { 'x-listenapi-key': "{{apiKey}}" }

conn.request("GET", "/baseUrl/podcasts/:id/recommendations", headers=headers)

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

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/podcasts/:id/recommendations"

headers = {"x-listenapi-key": "{{apiKey}}"}

response = requests.get(url, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/podcasts/:id/recommendations"

response <- VERB("GET", url, add_headers('x-listenapi-key' = '{{apiKey}}'), content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/podcasts/:id/recommendations")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["x-listenapi-key"] = '{{apiKey}}'

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/podcasts/:id/recommendations') do |req|
  req.headers['x-listenapi-key'] = '{{apiKey}}'
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/podcasts/:id/recommendations";

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("x-listenapi-key", "{{apiKey}}".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.get(url)
        .headers(headers)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/podcasts/:id/recommendations \
  --header 'x-listenapi-key: {{apiKey}}'
http GET {{baseUrl}}/podcasts/:id/recommendations \
  x-listenapi-key:'{{apiKey}}'
wget --quiet \
  --method GET \
  --header 'x-listenapi-key: {{apiKey}}' \
  --output-document \
  - {{baseUrl}}/podcasts/:id/recommendations
import Foundation

let headers = ["x-listenapi-key": "{{apiKey}}"]

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/podcasts/:id/recommendations")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
GET Fetch recommendations for an episode
{{baseUrl}}/episodes/:id/recommendations
HEADERS

X-ListenAPI-Key
{{apiKey}}
QUERY PARAMS

id
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/episodes/:id/recommendations");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "x-listenapi-key: {{apiKey}}");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/episodes/:id/recommendations" {:headers {:x-listenapi-key "{{apiKey}}"}})
require "http/client"

url = "{{baseUrl}}/episodes/:id/recommendations"
headers = HTTP::Headers{
  "x-listenapi-key" => "{{apiKey}}"
}

response = HTTP::Client.get url, headers: headers
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/episodes/:id/recommendations"),
    Headers =
    {
        { "x-listenapi-key", "{{apiKey}}" },
    },
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/episodes/:id/recommendations");
var request = new RestRequest("", Method.Get);
request.AddHeader("x-listenapi-key", "{{apiKey}}");
var response = client.Execute(request);
package main

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

func main() {

	url := "{{baseUrl}}/episodes/:id/recommendations"

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

	req.Header.Add("x-listenapi-key", "{{apiKey}}")

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

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

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

}
GET /baseUrl/episodes/:id/recommendations HTTP/1.1
X-Listenapi-Key: {{apiKey}}
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/episodes/:id/recommendations")
  .setHeader("x-listenapi-key", "{{apiKey}}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/episodes/:id/recommendations"))
    .header("x-listenapi-key", "{{apiKey}}")
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/episodes/:id/recommendations")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/episodes/:id/recommendations")
  .header("x-listenapi-key", "{{apiKey}}")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/episodes/:id/recommendations');
xhr.setRequestHeader('x-listenapi-key', '{{apiKey}}');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/episodes/:id/recommendations',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/episodes/:id/recommendations';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/episodes/:id/recommendations',
  method: 'GET',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/episodes/:id/recommendations")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/episodes/:id/recommendations',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

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

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

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

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/episodes/:id/recommendations',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/episodes/:id/recommendations');

req.headers({
  'x-listenapi-key': '{{apiKey}}'
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/episodes/:id/recommendations',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/episodes/:id/recommendations';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"x-listenapi-key": @"{{apiKey}}" };

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/episodes/:id/recommendations"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
[request setAllHTTPHeaderFields:headers];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/episodes/:id/recommendations" in
let headers = Header.add (Header.init ()) "x-listenapi-key" "{{apiKey}}" in

Client.call ~headers `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/episodes/:id/recommendations",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => [
    "x-listenapi-key: {{apiKey}}"
  ],
]);

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

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/episodes/:id/recommendations', [
  'headers' => [
    'x-listenapi-key' => '{{apiKey}}',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/episodes/:id/recommendations');
$request->setMethod(HTTP_METH_GET);

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/episodes/:id/recommendations');
$request->setRequestMethod('GET');
$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/episodes/:id/recommendations' -Method GET -Headers $headers
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/episodes/:id/recommendations' -Method GET -Headers $headers
import http.client

conn = http.client.HTTPSConnection("example.com")

headers = { 'x-listenapi-key': "{{apiKey}}" }

conn.request("GET", "/baseUrl/episodes/:id/recommendations", headers=headers)

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

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/episodes/:id/recommendations"

headers = {"x-listenapi-key": "{{apiKey}}"}

response = requests.get(url, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/episodes/:id/recommendations"

response <- VERB("GET", url, add_headers('x-listenapi-key' = '{{apiKey}}'), content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/episodes/:id/recommendations")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["x-listenapi-key"] = '{{apiKey}}'

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/episodes/:id/recommendations') do |req|
  req.headers['x-listenapi-key'] = '{{apiKey}}'
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/episodes/:id/recommendations";

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("x-listenapi-key", "{{apiKey}}".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.get(url)
        .headers(headers)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/episodes/:id/recommendations \
  --header 'x-listenapi-key: {{apiKey}}'
http GET {{baseUrl}}/episodes/:id/recommendations \
  x-listenapi-key:'{{apiKey}}'
wget --quiet \
  --method GET \
  --header 'x-listenapi-key: {{apiKey}}' \
  --output-document \
  - {{baseUrl}}/episodes/:id/recommendations
import Foundation

let headers = ["x-listenapi-key": "{{apiKey}}"]

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/episodes/:id/recommendations")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
GET Fetch a list of your playlists.
{{baseUrl}}/playlists
HEADERS

X-ListenAPI-Key
{{apiKey}}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/playlists");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "x-listenapi-key: {{apiKey}}");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/playlists" {:headers {:x-listenapi-key "{{apiKey}}"}})
require "http/client"

url = "{{baseUrl}}/playlists"
headers = HTTP::Headers{
  "x-listenapi-key" => "{{apiKey}}"
}

response = HTTP::Client.get url, headers: headers
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/playlists"),
    Headers =
    {
        { "x-listenapi-key", "{{apiKey}}" },
    },
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/playlists");
var request = new RestRequest("", Method.Get);
request.AddHeader("x-listenapi-key", "{{apiKey}}");
var response = client.Execute(request);
package main

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

func main() {

	url := "{{baseUrl}}/playlists"

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

	req.Header.Add("x-listenapi-key", "{{apiKey}}")

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

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

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

}
GET /baseUrl/playlists HTTP/1.1
X-Listenapi-Key: {{apiKey}}
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/playlists")
  .setHeader("x-listenapi-key", "{{apiKey}}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/playlists"))
    .header("x-listenapi-key", "{{apiKey}}")
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/playlists")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/playlists")
  .header("x-listenapi-key", "{{apiKey}}")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/playlists');
xhr.setRequestHeader('x-listenapi-key', '{{apiKey}}');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/playlists',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/playlists';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/playlists',
  method: 'GET',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/playlists")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/playlists',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

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

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

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

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/playlists',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/playlists');

req.headers({
  'x-listenapi-key': '{{apiKey}}'
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/playlists',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/playlists';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"x-listenapi-key": @"{{apiKey}}" };

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/playlists"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
[request setAllHTTPHeaderFields:headers];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/playlists" in
let headers = Header.add (Header.init ()) "x-listenapi-key" "{{apiKey}}" in

Client.call ~headers `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/playlists",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => [
    "x-listenapi-key: {{apiKey}}"
  ],
]);

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

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/playlists', [
  'headers' => [
    'x-listenapi-key' => '{{apiKey}}',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/playlists');
$request->setMethod(HTTP_METH_GET);

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/playlists');
$request->setRequestMethod('GET');
$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/playlists' -Method GET -Headers $headers
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/playlists' -Method GET -Headers $headers
import http.client

conn = http.client.HTTPSConnection("example.com")

headers = { 'x-listenapi-key': "{{apiKey}}" }

conn.request("GET", "/baseUrl/playlists", headers=headers)

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

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/playlists"

headers = {"x-listenapi-key": "{{apiKey}}"}

response = requests.get(url, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/playlists"

response <- VERB("GET", url, add_headers('x-listenapi-key' = '{{apiKey}}'), content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/playlists")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["x-listenapi-key"] = '{{apiKey}}'

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/playlists') do |req|
  req.headers['x-listenapi-key'] = '{{apiKey}}'
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/playlists";

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("x-listenapi-key", "{{apiKey}}".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.get(url)
        .headers(headers)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/playlists \
  --header 'x-listenapi-key: {{apiKey}}'
http GET {{baseUrl}}/playlists \
  x-listenapi-key:'{{apiKey}}'
wget --quiet \
  --method GET \
  --header 'x-listenapi-key: {{apiKey}}' \
  --output-document \
  - {{baseUrl}}/playlists
import Foundation

let headers = ["x-listenapi-key": "{{apiKey}}"]

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/playlists")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "previous_page_number": 1,
  "page_number": 2,
  "has_next": true,
  "has_previous": true,
  "next_page_number": 3,
  "total": 325
}
GET Fetch a playlist's info and items (i.e., episodes or podcasts).
{{baseUrl}}/playlists/:id
HEADERS

X-ListenAPI-Key
{{apiKey}}
QUERY PARAMS

id
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/playlists/:id");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "x-listenapi-key: {{apiKey}}");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/playlists/:id" {:headers {:x-listenapi-key "{{apiKey}}"}})
require "http/client"

url = "{{baseUrl}}/playlists/:id"
headers = HTTP::Headers{
  "x-listenapi-key" => "{{apiKey}}"
}

response = HTTP::Client.get url, headers: headers
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/playlists/:id"),
    Headers =
    {
        { "x-listenapi-key", "{{apiKey}}" },
    },
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/playlists/:id");
var request = new RestRequest("", Method.Get);
request.AddHeader("x-listenapi-key", "{{apiKey}}");
var response = client.Execute(request);
package main

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

func main() {

	url := "{{baseUrl}}/playlists/:id"

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

	req.Header.Add("x-listenapi-key", "{{apiKey}}")

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

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

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

}
GET /baseUrl/playlists/:id HTTP/1.1
X-Listenapi-Key: {{apiKey}}
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/playlists/:id")
  .setHeader("x-listenapi-key", "{{apiKey}}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/playlists/:id"))
    .header("x-listenapi-key", "{{apiKey}}")
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/playlists/:id")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/playlists/:id")
  .header("x-listenapi-key", "{{apiKey}}")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/playlists/:id');
xhr.setRequestHeader('x-listenapi-key', '{{apiKey}}');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/playlists/:id',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/playlists/:id';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/playlists/:id',
  method: 'GET',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/playlists/:id")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/playlists/:id',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

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

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

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

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/playlists/:id',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/playlists/:id');

req.headers({
  'x-listenapi-key': '{{apiKey}}'
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/playlists/:id',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/playlists/:id';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"x-listenapi-key": @"{{apiKey}}" };

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/playlists/:id"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
[request setAllHTTPHeaderFields:headers];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/playlists/:id" in
let headers = Header.add (Header.init ()) "x-listenapi-key" "{{apiKey}}" in

Client.call ~headers `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/playlists/:id",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => [
    "x-listenapi-key: {{apiKey}}"
  ],
]);

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

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/playlists/:id', [
  'headers' => [
    'x-listenapi-key' => '{{apiKey}}',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/playlists/:id');
$request->setMethod(HTTP_METH_GET);

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/playlists/:id');
$request->setRequestMethod('GET');
$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/playlists/:id' -Method GET -Headers $headers
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/playlists/:id' -Method GET -Headers $headers
import http.client

conn = http.client.HTTPSConnection("example.com")

headers = { 'x-listenapi-key': "{{apiKey}}" }

conn.request("GET", "/baseUrl/playlists/:id", headers=headers)

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

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/playlists/:id"

headers = {"x-listenapi-key": "{{apiKey}}"}

response = requests.get(url, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/playlists/:id"

response <- VERB("GET", url, add_headers('x-listenapi-key' = '{{apiKey}}'), content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/playlists/:id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["x-listenapi-key"] = '{{apiKey}}'

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/playlists/:id') do |req|
  req.headers['x-listenapi-key'] = '{{apiKey}}'
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/playlists/:id";

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("x-listenapi-key", "{{apiKey}}".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.get(url)
        .headers(headers)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/playlists/:id \
  --header 'x-listenapi-key: {{apiKey}}'
http GET {{baseUrl}}/playlists/:id \
  x-listenapi-key:'{{apiKey}}'
wget --quiet \
  --method GET \
  --header 'x-listenapi-key: {{apiKey}}' \
  --output-document \
  - {{baseUrl}}/playlists/:id
import Foundation

let headers = ["x-listenapi-key": "{{apiKey}}"]

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/playlists/:id")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "id": "m1pe7z60bsw",
  "name": "My podcast playlist",
  "description": "A curated playlist of podcasts about podcasting.",
  "image": "https://cdn-images-1.listennotes.com/playlist/image/6907e8ff6b6c45df94cc059753f369cc.JPEG",
  "thumbnail": "https://d3sv2eduhewoas.cloudfront.net/playlist/image/48477deae02649d7ab9d3f1b3966af38.JPEG",
  "listennotes_url": "https://www.listennotes.com/listen/podcasts-about-podcasting-m1pe7z60bsw/?display=episode",
  "visibility": "public",
  "last_timestamp_ms": 1595641092907,
  "total": 325,
  "type": "episode_list"
}
DELETE Request to delete a podcast
{{baseUrl}}/podcasts/:id
HEADERS

X-ListenAPI-Key
{{apiKey}}
QUERY PARAMS

id
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "DELETE");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/podcasts/:id");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "x-listenapi-key: {{apiKey}}");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/delete "{{baseUrl}}/podcasts/:id" {:headers {:x-listenapi-key "{{apiKey}}"}})
require "http/client"

url = "{{baseUrl}}/podcasts/:id"
headers = HTTP::Headers{
  "x-listenapi-key" => "{{apiKey}}"
}

response = HTTP::Client.delete url, headers: headers
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Delete,
    RequestUri = new Uri("{{baseUrl}}/podcasts/:id"),
    Headers =
    {
        { "x-listenapi-key", "{{apiKey}}" },
    },
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/podcasts/:id");
var request = new RestRequest("", Method.Delete);
request.AddHeader("x-listenapi-key", "{{apiKey}}");
var response = client.Execute(request);
package main

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

func main() {

	url := "{{baseUrl}}/podcasts/:id"

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

	req.Header.Add("x-listenapi-key", "{{apiKey}}")

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

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

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

}
DELETE /baseUrl/podcasts/:id HTTP/1.1
X-Listenapi-Key: {{apiKey}}
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("DELETE", "{{baseUrl}}/podcasts/:id")
  .setHeader("x-listenapi-key", "{{apiKey}}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/podcasts/:id"))
    .header("x-listenapi-key", "{{apiKey}}")
    .method("DELETE", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/podcasts/:id")
  .delete(null)
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.delete("{{baseUrl}}/podcasts/:id")
  .header("x-listenapi-key", "{{apiKey}}")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('DELETE', '{{baseUrl}}/podcasts/:id');
xhr.setRequestHeader('x-listenapi-key', '{{apiKey}}');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'DELETE',
  url: '{{baseUrl}}/podcasts/:id',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/podcasts/:id';
const options = {method: 'DELETE', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/podcasts/:id',
  method: 'DELETE',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/podcasts/:id")
  .delete(null)
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'DELETE',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/podcasts/:id',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

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

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

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

req.end();
const request = require('request');

const options = {
  method: 'DELETE',
  url: '{{baseUrl}}/podcasts/:id',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('DELETE', '{{baseUrl}}/podcasts/:id');

req.headers({
  'x-listenapi-key': '{{apiKey}}'
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'DELETE',
  url: '{{baseUrl}}/podcasts/:id',
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/podcasts/:id';
const options = {method: 'DELETE', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"x-listenapi-key": @"{{apiKey}}" };

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/podcasts/:id"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"DELETE"];
[request setAllHTTPHeaderFields:headers];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/podcasts/:id" in
let headers = Header.add (Header.init ()) "x-listenapi-key" "{{apiKey}}" in

Client.call ~headers `DELETE uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/podcasts/:id",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "DELETE",
  CURLOPT_HTTPHEADER => [
    "x-listenapi-key: {{apiKey}}"
  ],
]);

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

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('DELETE', '{{baseUrl}}/podcasts/:id', [
  'headers' => [
    'x-listenapi-key' => '{{apiKey}}',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/podcasts/:id');
$request->setMethod(HTTP_METH_DELETE);

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/podcasts/:id');
$request->setRequestMethod('DELETE');
$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/podcasts/:id' -Method DELETE -Headers $headers
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/podcasts/:id' -Method DELETE -Headers $headers
import http.client

conn = http.client.HTTPSConnection("example.com")

headers = { 'x-listenapi-key': "{{apiKey}}" }

conn.request("DELETE", "/baseUrl/podcasts/:id", headers=headers)

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

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/podcasts/:id"

headers = {"x-listenapi-key": "{{apiKey}}"}

response = requests.delete(url, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/podcasts/:id"

response <- VERB("DELETE", url, add_headers('x-listenapi-key' = '{{apiKey}}'), content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/podcasts/:id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)
request["x-listenapi-key"] = '{{apiKey}}'

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.delete('/baseUrl/podcasts/:id') do |req|
  req.headers['x-listenapi-key'] = '{{apiKey}}'
end

puts response.status
puts response.body
use std::str::FromStr;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/podcasts/:id";

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("x-listenapi-key", "{{apiKey}}".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.request(reqwest::Method::from_str("DELETE").unwrap(), url)
        .headers(headers)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request DELETE \
  --url {{baseUrl}}/podcasts/:id \
  --header 'x-listenapi-key: {{apiKey}}'
http DELETE {{baseUrl}}/podcasts/:id \
  x-listenapi-key:'{{apiKey}}'
wget --quiet \
  --method DELETE \
  --header 'x-listenapi-key: {{apiKey}}' \
  --output-document \
  - {{baseUrl}}/podcasts/:id
import Foundation

let headers = ["x-listenapi-key": "{{apiKey}}"]

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/podcasts/:id")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "DELETE"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "status": "deleted"
}
POST Submit a podcast to Listen Notes database
{{baseUrl}}/podcasts/submit
HEADERS

X-ListenAPI-Key
{{apiKey}}
BODY formUrlEncoded

rss
email
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/podcasts/submit");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "x-listenapi-key: {{apiKey}}");
headers = curl_slist_append(headers, "content-type: application/x-www-form-urlencoded");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "rss=&email=");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/podcasts/submit" {:headers {:x-listenapi-key "{{apiKey}}"}
                                                            :form-params {:rss ""
                                                                          :email ""}})
require "http/client"

url = "{{baseUrl}}/podcasts/submit"
headers = HTTP::Headers{
  "x-listenapi-key" => "{{apiKey}}"
  "content-type" => "application/x-www-form-urlencoded"
}
reqBody = "rss=&email="

response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/podcasts/submit"),
    Headers =
    {
        { "x-listenapi-key", "{{apiKey}}" },
    },
    Content = new FormUrlEncodedContent(new Dictionary
    {
        { "rss", "" },
        { "email", "" },
    }),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/podcasts/submit");
var request = new RestRequest("", Method.Post);
request.AddHeader("x-listenapi-key", "{{apiKey}}");
request.AddHeader("content-type", "application/x-www-form-urlencoded");
request.AddParameter("application/x-www-form-urlencoded", "rss=&email=", ParameterType.RequestBody);
var response = client.Execute(request);
package main

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

func main() {

	url := "{{baseUrl}}/podcasts/submit"

	payload := strings.NewReader("rss=&email=")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("x-listenapi-key", "{{apiKey}}")
	req.Header.Add("content-type", "application/x-www-form-urlencoded")

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

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

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

}
POST /baseUrl/podcasts/submit HTTP/1.1
X-Listenapi-Key: {{apiKey}}
Content-Type: application/x-www-form-urlencoded
Host: example.com
Content-Length: 11

rss=&email=
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/podcasts/submit")
  .setHeader("x-listenapi-key", "{{apiKey}}")
  .setHeader("content-type", "application/x-www-form-urlencoded")
  .setBody("rss=&email=")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/podcasts/submit"))
    .header("x-listenapi-key", "{{apiKey}}")
    .header("content-type", "application/x-www-form-urlencoded")
    .method("POST", HttpRequest.BodyPublishers.ofString("rss=&email="))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/x-www-form-urlencoded");
RequestBody body = RequestBody.create(mediaType, "rss=&email=");
Request request = new Request.Builder()
  .url("{{baseUrl}}/podcasts/submit")
  .post(body)
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .addHeader("content-type", "application/x-www-form-urlencoded")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/podcasts/submit")
  .header("x-listenapi-key", "{{apiKey}}")
  .header("content-type", "application/x-www-form-urlencoded")
  .body("rss=&email=")
  .asString();
const data = 'rss=&email=';

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/podcasts/submit');
xhr.setRequestHeader('x-listenapi-key', '{{apiKey}}');
xhr.setRequestHeader('content-type', 'application/x-www-form-urlencoded');

xhr.send(data);
import axios from 'axios';

const encodedParams = new URLSearchParams();
encodedParams.set('rss', '');
encodedParams.set('email', '');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/podcasts/submit',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  },
  data: encodedParams,
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/podcasts/submit';
const options = {
  method: 'POST',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  },
  body: new URLSearchParams({rss: '', email: ''})
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/podcasts/submit',
  method: 'POST',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  },
  data: {
    rss: '',
    email: ''
  }
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/x-www-form-urlencoded")
val body = RequestBody.create(mediaType, "rss=&email=")
val request = Request.Builder()
  .url("{{baseUrl}}/podcasts/submit")
  .post(body)
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .addHeader("content-type", "application/x-www-form-urlencoded")
  .build()

val response = client.newCall(request).execute()
const qs = require('querystring');
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/podcasts/submit',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  }
};

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

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

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

req.write(qs.stringify({rss: '', email: ''}));
req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/podcasts/submit',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  },
  form: {rss: '', email: ''}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/podcasts/submit');

req.headers({
  'x-listenapi-key': '{{apiKey}}',
  'content-type': 'application/x-www-form-urlencoded'
});

req.form({
  rss: '',
  email: ''
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;
const { URLSearchParams } = require('url');

const encodedParams = new URLSearchParams();
encodedParams.set('rss', '');
encodedParams.set('email', '');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/podcasts/submit',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  },
  data: encodedParams,
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const { URLSearchParams } = require('url');
const fetch = require('node-fetch');

const encodedParams = new URLSearchParams();
encodedParams.set('rss', '');
encodedParams.set('email', '');

const url = '{{baseUrl}}/podcasts/submit';
const options = {
  method: 'POST',
  headers: {
    'x-listenapi-key': '{{apiKey}}',
    'content-type': 'application/x-www-form-urlencoded'
  },
  body: encodedParams
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"x-listenapi-key": @"{{apiKey}}",
                           @"content-type": @"application/x-www-form-urlencoded" };

NSMutableData *postData = [[NSMutableData alloc] initWithData:[@"rss=" dataUsingEncoding:NSUTF8StringEncoding]];
[postData appendData:[@"&email=" dataUsingEncoding:NSUTF8StringEncoding]];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/podcasts/submit"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/podcasts/submit" in
let headers = Header.add_list (Header.init ()) [
  ("x-listenapi-key", "{{apiKey}}");
  ("content-type", "application/x-www-form-urlencoded");
] in
let body = Cohttp_lwt_body.of_string "rss=&email=" in

Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/podcasts/submit",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => "rss=&email=",
  CURLOPT_HTTPHEADER => [
    "content-type: application/x-www-form-urlencoded",
    "x-listenapi-key: {{apiKey}}"
  ],
]);

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

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/podcasts/submit', [
  'form_params' => [
    'rss' => '',
    'email' => ''
  ],
  'headers' => [
    'content-type' => 'application/x-www-form-urlencoded',
    'x-listenapi-key' => '{{apiKey}}',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/podcasts/submit');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}',
  'content-type' => 'application/x-www-form-urlencoded'
]);

$request->setContentType('application/x-www-form-urlencoded');
$request->setPostFields([
  'rss' => '',
  'email' => ''
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(new http\QueryString([
  'rss' => '',
  'email' => ''
]));

$request->setRequestUrl('{{baseUrl}}/podcasts/submit');
$request->setRequestMethod('POST');
$request->setBody($body);

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}',
  'content-type' => 'application/x-www-form-urlencoded'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$headers.Add("content-type", "application/x-www-form-urlencoded")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/podcasts/submit' -Method POST -Headers $headers -ContentType 'application/x-www-form-urlencoded' -Body 'rss=&email='
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$headers.Add("content-type", "application/x-www-form-urlencoded")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/podcasts/submit' -Method POST -Headers $headers -ContentType 'application/x-www-form-urlencoded' -Body 'rss=&email='
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "rss=&email="

headers = {
    'x-listenapi-key': "{{apiKey}}",
    'content-type': "application/x-www-form-urlencoded"
}

conn.request("POST", "/baseUrl/podcasts/submit", payload, headers)

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

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/podcasts/submit"

payload = {
    "rss": "",
    "email": ""
}
headers = {
    "x-listenapi-key": "{{apiKey}}",
    "content-type": "application/x-www-form-urlencoded"
}

response = requests.post(url, data=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/podcasts/submit"

payload <- "rss=&email="

encode <- "form"

response <- VERB("POST", url, body = payload, add_headers('x-listenapi-key' = '{{apiKey}}'), content_type("application/x-www-form-urlencoded"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/podcasts/submit")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["x-listenapi-key"] = '{{apiKey}}'
request["content-type"] = 'application/x-www-form-urlencoded'
request.body = "rss=&email="

response = http.request(request)
puts response.read_body
require 'faraday'

data = {
  :rss => "",
  :email => "",
}

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/x-www-form-urlencoded'}
)

response = conn.post('/baseUrl/podcasts/submit') do |req|
  req.headers['x-listenapi-key'] = '{{apiKey}}'
  req.body = URI.encode_www_form(data)
end

puts response.status
puts response.body
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/podcasts/submit";

    let payload = json!({
        "rss": "",
        "email": ""
    });

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("x-listenapi-key", "{{apiKey}}".parse().unwrap());
    headers.insert("content-type", "application/x-www-form-urlencoded".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .form(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/podcasts/submit \
  --header 'content-type: application/x-www-form-urlencoded' \
  --header 'x-listenapi-key: {{apiKey}}' \
  --data rss= \
  --data email=
http --form POST {{baseUrl}}/podcasts/submit \
  content-type:application/x-www-form-urlencoded \
  x-listenapi-key:'{{apiKey}}' \
  rss='' \
  email=''
wget --quiet \
  --method POST \
  --header 'x-listenapi-key: {{apiKey}}' \
  --header 'content-type: application/x-www-form-urlencoded' \
  --body-data 'rss=&email=' \
  --output-document \
  - {{baseUrl}}/podcasts/submit
import Foundation

let headers = [
  "x-listenapi-key": "{{apiKey}}",
  "content-type": "application/x-www-form-urlencoded"
]

let postData = NSMutableData(data: "rss=".data(using: String.Encoding.utf8)!)
postData.append("&email=".data(using: String.Encoding.utf8)!)

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/podcasts/submit")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "status": "found",
  "podcast": {
    "image": "https://cdn-images-1.listennotes.com/podcasts/exponent-ben-thompson-james-allworth-OaJSjb4xQv3.1400x1400.jpg",
    "thumbnail": "https://cdn-images-1.listennotes.com/podcasts/exponent-ben-thompson-james-allworth-OaJSjb4xQv3.300x300.jpg",
    "title": "Star Wars 7x7 | Star Wars News, Interviews, and More!",
    "listennotes_url": "https://www.listennotes.com/c/4d3fe717742d4963a85562e9f84d8c79/",
    "id": "4d3fe717742d4963a85562e9f84d8c79",
    "publisher": "Planet Broadcasting",
    "listen_score": 81,
    "listen_score_global_rank": "0.5%"
  }
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/search?q=");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "x-listenapi-key: {{apiKey}}");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/search" {:headers {:x-listenapi-key "{{apiKey}}"}
                                                  :query-params {:q ""}})
require "http/client"

url = "{{baseUrl}}/search?q="
headers = HTTP::Headers{
  "x-listenapi-key" => "{{apiKey}}"
}

response = HTTP::Client.get url, headers: headers
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/search?q="),
    Headers =
    {
        { "x-listenapi-key", "{{apiKey}}" },
    },
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/search?q=");
var request = new RestRequest("", Method.Get);
request.AddHeader("x-listenapi-key", "{{apiKey}}");
var response = client.Execute(request);
package main

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

func main() {

	url := "{{baseUrl}}/search?q="

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

	req.Header.Add("x-listenapi-key", "{{apiKey}}")

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

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

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

}
GET /baseUrl/search?q= HTTP/1.1
X-Listenapi-Key: {{apiKey}}
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/search?q=")
  .setHeader("x-listenapi-key", "{{apiKey}}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/search?q="))
    .header("x-listenapi-key", "{{apiKey}}")
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/search?q=")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/search?q=")
  .header("x-listenapi-key", "{{apiKey}}")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/search?q=');
xhr.setRequestHeader('x-listenapi-key', '{{apiKey}}');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/search',
  params: {q: ''},
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/search?q=';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/search?q=',
  method: 'GET',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/search?q=")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/search?q=',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

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

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

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

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/search',
  qs: {q: ''},
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/search');

req.query({
  q: ''
});

req.headers({
  'x-listenapi-key': '{{apiKey}}'
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/search',
  params: {q: ''},
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/search?q=';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"x-listenapi-key": @"{{apiKey}}" };

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/search?q="]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
[request setAllHTTPHeaderFields:headers];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/search?q=" in
let headers = Header.add (Header.init ()) "x-listenapi-key" "{{apiKey}}" in

Client.call ~headers `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/search?q=",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => [
    "x-listenapi-key: {{apiKey}}"
  ],
]);

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

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/search?q=', [
  'headers' => [
    'x-listenapi-key' => '{{apiKey}}',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/search');
$request->setMethod(HTTP_METH_GET);

$request->setQueryData([
  'q' => ''
]);

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/search');
$request->setRequestMethod('GET');
$request->setQuery(new http\QueryString([
  'q' => ''
]));

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/search?q=' -Method GET -Headers $headers
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/search?q=' -Method GET -Headers $headers
import http.client

conn = http.client.HTTPSConnection("example.com")

headers = { 'x-listenapi-key': "{{apiKey}}" }

conn.request("GET", "/baseUrl/search?q=", headers=headers)

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

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/search"

querystring = {"q":""}

headers = {"x-listenapi-key": "{{apiKey}}"}

response = requests.get(url, headers=headers, params=querystring)

print(response.json())
library(httr)

url <- "{{baseUrl}}/search"

queryString <- list(q = "")

response <- VERB("GET", url, query = queryString, add_headers('x-listenapi-key' = '{{apiKey}}'), content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/search?q=")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["x-listenapi-key"] = '{{apiKey}}'

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/search') do |req|
  req.headers['x-listenapi-key'] = '{{apiKey}}'
  req.params['q'] = ''
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/search";

    let querystring = [
        ("q", ""),
    ];

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("x-listenapi-key", "{{apiKey}}".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.get(url)
        .query(&querystring)
        .headers(headers)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url '{{baseUrl}}/search?q=' \
  --header 'x-listenapi-key: {{apiKey}}'
http GET '{{baseUrl}}/search?q=' \
  x-listenapi-key:'{{apiKey}}'
wget --quiet \
  --method GET \
  --header 'x-listenapi-key: {{apiKey}}' \
  --output-document \
  - '{{baseUrl}}/search?q='
import Foundation

let headers = ["x-listenapi-key": "{{apiKey}}"]

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/search?q=")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "next_offset": 10,
  "took": 0.093,
  "total": 1989,
  "count": 10
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/typeahead?q=");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "x-listenapi-key: {{apiKey}}");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/typeahead" {:headers {:x-listenapi-key "{{apiKey}}"}
                                                     :query-params {:q ""}})
require "http/client"

url = "{{baseUrl}}/typeahead?q="
headers = HTTP::Headers{
  "x-listenapi-key" => "{{apiKey}}"
}

response = HTTP::Client.get url, headers: headers
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/typeahead?q="),
    Headers =
    {
        { "x-listenapi-key", "{{apiKey}}" },
    },
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/typeahead?q=");
var request = new RestRequest("", Method.Get);
request.AddHeader("x-listenapi-key", "{{apiKey}}");
var response = client.Execute(request);
package main

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

func main() {

	url := "{{baseUrl}}/typeahead?q="

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

	req.Header.Add("x-listenapi-key", "{{apiKey}}")

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

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

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

}
GET /baseUrl/typeahead?q= HTTP/1.1
X-Listenapi-Key: {{apiKey}}
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/typeahead?q=")
  .setHeader("x-listenapi-key", "{{apiKey}}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/typeahead?q="))
    .header("x-listenapi-key", "{{apiKey}}")
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/typeahead?q=")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/typeahead?q=")
  .header("x-listenapi-key", "{{apiKey}}")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/typeahead?q=');
xhr.setRequestHeader('x-listenapi-key', '{{apiKey}}');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/typeahead',
  params: {q: ''},
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/typeahead?q=';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/typeahead?q=',
  method: 'GET',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/typeahead?q=")
  .get()
  .addHeader("x-listenapi-key", "{{apiKey}}")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/typeahead?q=',
  headers: {
    'x-listenapi-key': '{{apiKey}}'
  }
};

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

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

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

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/typeahead',
  qs: {q: ''},
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/typeahead');

req.query({
  q: ''
});

req.headers({
  'x-listenapi-key': '{{apiKey}}'
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/typeahead',
  params: {q: ''},
  headers: {'x-listenapi-key': '{{apiKey}}'}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/typeahead?q=';
const options = {method: 'GET', headers: {'x-listenapi-key': '{{apiKey}}'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"x-listenapi-key": @"{{apiKey}}" };

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/typeahead?q="]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
[request setAllHTTPHeaderFields:headers];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/typeahead?q=" in
let headers = Header.add (Header.init ()) "x-listenapi-key" "{{apiKey}}" in

Client.call ~headers `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/typeahead?q=",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => [
    "x-listenapi-key: {{apiKey}}"
  ],
]);

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

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/typeahead?q=', [
  'headers' => [
    'x-listenapi-key' => '{{apiKey}}',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/typeahead');
$request->setMethod(HTTP_METH_GET);

$request->setQueryData([
  'q' => ''
]);

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/typeahead');
$request->setRequestMethod('GET');
$request->setQuery(new http\QueryString([
  'q' => ''
]));

$request->setHeaders([
  'x-listenapi-key' => '{{apiKey}}'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/typeahead?q=' -Method GET -Headers $headers
$headers=@{}
$headers.Add("x-listenapi-key", "{{apiKey}}")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/typeahead?q=' -Method GET -Headers $headers
import http.client

conn = http.client.HTTPSConnection("example.com")

headers = { 'x-listenapi-key': "{{apiKey}}" }

conn.request("GET", "/baseUrl/typeahead?q=", headers=headers)

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

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/typeahead"

querystring = {"q":""}

headers = {"x-listenapi-key": "{{apiKey}}"}

response = requests.get(url, headers=headers, params=querystring)

print(response.json())
library(httr)

url <- "{{baseUrl}}/typeahead"

queryString <- list(q = "")

response <- VERB("GET", url, query = queryString, add_headers('x-listenapi-key' = '{{apiKey}}'), content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/typeahead?q=")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["x-listenapi-key"] = '{{apiKey}}'

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/typeahead') do |req|
  req.headers['x-listenapi-key'] = '{{apiKey}}'
  req.params['q'] = ''
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/typeahead";

    let querystring = [
        ("q", ""),
    ];

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("x-listenapi-key", "{{apiKey}}".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.get(url)
        .query(&querystring)
        .headers(headers)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url '{{baseUrl}}/typeahead?q=' \
  --header 'x-listenapi-key: {{apiKey}}'
http GET '{{baseUrl}}/typeahead?q=' \
  x-listenapi-key:'{{apiKey}}'
wget --quiet \
  --method GET \
  --header 'x-listenapi-key: {{apiKey}}' \
  --output-document \
  - '{{baseUrl}}/typeahead?q='
import Foundation

let headers = ["x-listenapi-key": "{{apiKey}}"]

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/typeahead?q=")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "terms": [
    "startup sales",
    "startup",
    "startups",
    "star wars"
  ],
  "genres": [
    {
      "id": 140,
      "parent_id": 127,
      "name": "Web Design"
    }
  ]
}