title: PHP Curl API GET Call using authorization key and secret
body: <p>I am using PHP Curl to make a GET Call to an API (manheim api). 
  Below is the code I am using :</p>
  
  <pre><code>$vin    = 'abc.............';
  $atoken = 'xzc.......................';
  
  $request_headers   = array();
  $request_headers[] ='Authorization: Bearer: '.$atoken;
  $request_headers[] ='Content-Type: application/x-www-form-urlencoded';
  
  $handle  = curl_init();
  $api_url = 'https://api.manheim.com/descriptions/capture/vin/'.$vin;    
  
  $rawPostData = array( 'grant_type' =&gt; 'client_credentials', 'client_id' =&gt; 'xzc.......................', 'client_secret' =&gt; '6sd.......' ); 
  // $data_string     = json_encode($rawPostData);
  
  $data_string = '';
  
  //create name value pairs seperated by &amp;
  foreach($rawPostData as $k =&gt; $v) 
  { 
      $data_string .= $k . '='.$v.'&amp;'; 
  }
  
  rtrim($data_string, '&amp;');
  
  curl_setopt_array(
      $handle,
      array(
          CURLOPT_URL             =&gt; $api_url,
          CURLOPT_POST            =&gt; true,
          CURLOPT_POSTFIELDS      =&gt; $data_string,
          CURLOPT_RETURNTRANSFER  =&gt; true,
          CURLOPT_HTTPHEADER      =&gt; $request_headers,
          CURLOPT_SSL_VERIFYPEER  =&gt; false,
          CURLOPT_HEADER          =&gt; true,
          CURLOPT_TIMEOUT         =&gt; -1
      )
  );
  
  $data = curl_exec($handle);
  echo serialize($data);
  </code></pre>
  
  <p>I am getting the following in response:</p>
  
  <p>"HTTP/1.1 401 Unauthorized Content-Type: text/xml Date: Fri, 19 Jan 2018 06:44:21 GMT Server: Mashery Proxy WWW-Authenticate: Bearer realm="api.manheim.com" X-Error-Detail-Header: Account Inactive X-Mashery-Error-Code: ERR_403_DEVELOPER_INACTIVE X-Mashery-Responder: prod-j-worker-us-east-1e-123.mashery.com Content-Length: 27 Connection: keep-alive
  <strong>Developer Inactive</strong></p>
  
  <p>It is showing "Developer inactive". I am not sure where I am wrong.</p>