$obejct = rawurlencode ($obejct); // $object : object name
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "https://www.googleapis.com/storage/v1/b/".BUCKET."/o/".$obejct);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "DELETE");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
$headers = array();
$headers[] = "Authorization: Bearer ".$token;
$headers[] = "Content-Type: application/http";
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
$result = curl_exec($ch);
if (curl_errno($ch)) {
echo 'Error:' . curl_error($ch);
}
curl_close ($ch);
echo $result