title: Empty array output result
body: <p>I hope you can help identify where I am making mistakes in the following code: </p>
  
  <pre><code>    public function yee() {
  
      $json = array();
      $params = array(
                  'token'             =&gt; $this-&gt;_token,
                  'receiver_name'         =&gt; 'Test Name',
  
                  'sender_city'           =&gt; 'copenhagen',
                  'sender_country'        =&gt; 'DK',
                  'order_id'              =&gt; 150
              );
  
      $ch = curl_init();      
      $query = http_build_query($params);
  
          curl_setopt($ch, CURLOPT_URL, self::API_ENDPOINT . '/' . 'shipments/imported_shipment');
          curl_setopt($ch, CURLOPT_POST, 1);
          curl_setopt($ch, CURLOPT_POSTFIELDS, $query);
  
          curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
  
              $output = curl_exec ($ch);
              $http_code = curl_getinfo( $ch, CURLINFO_HTTP_CODE);
              curl_close ($ch);
  
              $output = json_decode($output, true);
  
              if ($http_code != 200){
                  if(is_array($output['message'])){
                          $json['error'] = $output['message'];
                  }else{
                          $json['error'] = $output['message'];
                  }
              } else {
                  $json['error'] = "Import Successully";
              } 
      return $output;
          }
      }
  </code></pre>
  
  <p>I have this in my class.php file, along with a few more lines doing the authentication.</p>
  
  <p>Then I try to call the function after initializing it: </p>
  
  <pre><code>$testObject-&gt;yee();
  echo $testObject-&gt;yee(); ?&gt;
  </code></pre>
  
  <p>The authentication part works correctly, as I'm also outputting tokens and a few other variables, however when I echo the yee() function - all it displays is "Array"</p>
  
  <p>In case you didn't notice, I am extremely green in JSON/API territory, and my PHP skills are rusty at best. So I am hoping for any and all pointers to lead me closer to solving this. Thanks!</p>