I have an HTTP GET request in Wordpress that looks like this:
$remote = vip_safe_wp_remote_get($api_base . "get.json?genre=" . $genre, false, 1, 3)
works fine, but I now need to pass in a couple of headers that look like this:
apikey: [key]
authtoken: [token]
How can I pass these in? I've tried doing $headers = array() with the arguments passed in as key value pairs, but that returns an HTTP 503 error. The service works when I try to access it from the command line with cURL.