$client = new \GuzzleHttp\Client;
$resource = fopen( $tmpfile, 'r');
$response = $client->request(
'POST',
$upload_url,
[
'multipart' => [
[
'name' => 'file',
'contents' => $resource
]
]
]
);
$uploadResult = json_decode( $response->getBody());