Method: photos.batchDelete
Tetap teratur dengan koleksi
Simpan dan kategorikan konten berdasarkan preferensi Anda.
Permintaan HTTP
POST https://streetviewpublish.googleapis.com/v1/photos:batchDelete
URL menggunakan sintaksis gRPC Transcoding.
Isi permintaan
Isi permintaan memuat data dengan struktur berikut:
Representasi JSON |
{
"photoIds": [
string
]
} |
Kolom |
photoIds[] |
string
Wajib. ID Photos . Permintaan GET HTTP memerlukan sintaksis berikut untuk parameter kueri URL: photoIds=<id1>&photoIds=<id2>&... .
|
Isi respons
Respons terhadap penghapusan batch satu atau beberapa Photos
.
Jika berhasil, isi respons memuat data dengan struktur berikut:
Representasi JSON |
{
"status": [
{
object (Status )
}
]
} |
Kolom |
status[] |
object (Status )
Status operasi untuk menghapus satu Photo dalam permintaan batch.
|
Cakupan otorisasi
Memerlukan cakupan OAuth berikut:
https://www.googleapis.com/auth/streetviewpublish
Untuk informasi selengkapnya, lihat Ringkasan OAuth 2.0.
Kecuali dinyatakan lain, konten di halaman ini dilisensikan berdasarkan Lisensi Creative Commons Attribution 4.0, sedangkan contoh kode dilisensikan berdasarkan Lisensi Apache 2.0. Untuk mengetahui informasi selengkapnya, lihat Kebijakan Situs Google Developers. Java adalah merek dagang terdaftar dari Oracle dan/atau afiliasinya.
Terakhir diperbarui pada 2025-07-25 UTC.
[null,null,["Terakhir diperbarui pada 2025-07-25 UTC."],[[["\u003cp\u003eThe \u003ccode\u003ephotos.batchDelete\u003c/code\u003e API allows for deleting multiple photos and their metadata within Street View Publish.\u003c/p\u003e\n"],["\u003cp\u003eThe request body requires a list of \u003ccode\u003ephotoIds\u003c/code\u003e for the photos to be deleted.\u003c/p\u003e\n"],["\u003cp\u003eThe response provides individual status updates for each photo deletion attempt.\u003c/p\u003e\n"],["\u003cp\u003eAuthorization with the \u003ccode\u003ehttps://www.googleapis.com/auth/streetviewpublish\u003c/code\u003e scope is necessary.\u003c/p\u003e\n"],["\u003cp\u003eFailures may occur for individual photos even if the overall batch deletion request is successful, details of which can be found in the response.\u003c/p\u003e\n"]]],["This describes how to batch delete photos and their metadata via a POST request to `https://streetviewpublish.googleapis.com/v1/photos:batchDelete`. The request body requires a JSON array of `photoIds`. The response body includes an array of `status` objects, indicating the success or failure of each individual photo deletion. Authentication requires the `https://www.googleapis.com/auth/streetviewpublish` OAuth scope. The URL uses gRPC transcoding. Failures may occur due to missing fields or authentication errors.\n"],null,["# Method: photos.batchDelete\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Request body](#body.request_body)\n - [JSON representation](#body.request_body.SCHEMA_REPRESENTATION)\n- [Response body](#body.response_body)\n - [JSON representation](#body.BatchDeletePhotosResponse.SCHEMA_REPRESENTATION)\n- [Authorization scopes](#body.aspect)\n- [Try it!](#try-it)\n\nDeletes a list of [Photos](/streetview/publish/reference/rest/v1/photo#Photo) and their metadata.\n\nNote that if [photos.batchDelete](/streetview/publish/reference/rest/v1/photos/batchDelete#google.streetview.publish.v1.StreetViewPublishService.BatchDeletePhotos) fails, either critical fields are missing or there is an authentication error. Even if [photos.batchDelete](/streetview/publish/reference/rest/v1/photos/batchDelete#google.streetview.publish.v1.StreetViewPublishService.BatchDeletePhotos) succeeds, individual photos in the batch may have failures. These failures are specified in each [PhotoResponse.status](/streetview/publish/reference/rest/v1/PhotoResponse#FIELDS.status) in [BatchDeletePhotosResponse.results](/streetview/publish/reference/rest/v1/photos/batchDelete#body.BatchDeletePhotosResponse.FIELDS.status). See [photo.delete](/streetview/publish/reference/rest/v1/photo/delete#google.streetview.publish.v1.StreetViewPublishService.DeletePhoto) for specific failures that can occur per photo.\n\n### HTTP request\n\n`POST https://streetviewpublish.googleapis.com/v1/photos:batchDelete`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Request body\n\nThe request body contains data with the following structure:\n\n| JSON representation |\n|------------------------------------|\n| ``` { \"photoIds\": [ string ] } ``` |\n\n| Fields ||\n|--------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `photoIds[]` | `string` Required. IDs of the [Photos](/streetview/publish/reference/rest/v1/photo#Photo). HTTP GET requests require the following syntax for the URL query parameter: `photoIds=\u003cid1\u003e&photoIds=\u003cid2\u003e&...`. |\n\n### Response body\n\nResponse to batch delete of one or more [Photos](/streetview/publish/reference/rest/v1/photo#Photo).\n\nIf successful, the response body contains data with the following structure:\n\n| JSON representation |\n|-------------------------------------------------------------------------------------|\n| ``` { \"status\": [ { object (/streetview/publish/reference/rest/v1/Status) } ] } ``` |\n\n| Fields ||\n|------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `status[]` | `object (`[Status](/streetview/publish/reference/rest/v1/Status)`)` The status for the operation to delete a single [Photo](/streetview/publish/reference/rest/v1/photo#Photo) in the batch request. |\n\n### Authorization scopes\n\nRequires the following OAuth scope:\n\n- `https://www.googleapis.com/auth/streetviewpublish`\n\nFor more information, see the [OAuth 2.0 Overview](https://developers.google.com/identity/protocols/OAuth2)."]]