firestore_delete_rest.php
#! /usr/bin/php
<?php
//
// firestore_delete_rest.php
//
// Feb/16/2020
//
// ------------------------------------------------------------------
include('Requests/library/Requests.php');
include("get_token.php");
//
// ------------------------------------------------------------------

// ------------------------------------------------------------------
fputs (STDERR,"*** 開始 ***\n");
Requests::register_autoloader();
//
$key_in = $argv[1];
print($key_in . "\n");

$token = get_token_proc();
//
$project = 'project-jan25-2020';
$headers = array('Authorization' => 'Bearer ' . $token);
$options = array();
$url_base = "https://firestore.googleapis.com/v1/projects/" . $project . "/databases/(default)/documents/cities";
$url = $url_base . "/" . $key_in;

$request = Requests::delete($url, $headers);
var_dump($request->status_code);

$rvalue = $request->body;

print($rvalue);

fputs (STDERR,"*** 終了 ***\n");
// ------------------------------------------------------------------
?>

get_token.py はこちら
PHP の Rest で Cloud Firestore のデータを作成 (Create)

実行コマンド

export GOOGLE_APPLICATION_CREDENTIALS="***.json"
./firestore_delete_rest.php t0922