Method: inventory.partners.feeds.record.batchDelete
Sử dụng bộ sưu tập để sắp xếp ngăn nắp các trang
Lưu và phân loại nội dung dựa trên lựa chọn ưu tiên của bạn.
Xoá bản ghi của loại nguồn cấp dữ liệu đã chỉ định. Chỉ thực hiện quy trình xác thực cơ bản (như yêu cầu không đúng định dạng), sau đó hệ thống sẽ trả về phản hồi thích hợp cho đối tác ngay lập tức. Google thực hiện việc xác thực logic nghiệp vụ trên yêu cầu một cách không đồng bộ. Lệnh gọi hàng loạt này không đảm bảo tính nguyên tử.
Yêu cầu HTTP
POST https://mapsbooking.googleapis.com/v1alpha/inventory/{parent=partners/*/feeds/*}/record:batchDelete
URL sử dụng cú pháp Chuyển mã gRPC.
Tham số đường dẫn
Thông số |
parent |
string
Tên tài nguyên có định dạng – partners/{partner_id}/feeds/{feed_name} .
|
Nội dung yêu cầu
Nội dung yêu cầu chứa dữ liệu có cấu trúc sau:
Trường |
records[] |
object (GenericDeleteRecord )
Bản ghi cần xoá. Mỗi lệnh gọi API chỉ được phép có tối đa 1.000 bản ghi.
|
Nội dung phản hồi
Nếu thành công thì nội dung phản hồi sẽ trống.
Phạm vi uỷ quyền
Yêu cầu phạm vi OAuth sau:
https://www.googleapis.com/auth/mapsbooking
GenericDeleteRecord
Bản ghi cần xoá của loại nguồn cấp dữ liệu được đề cập trong yêu cầu URL.
Biểu diễn dưới dạng JSON |
{
"deleteTime": string,
// Union field record_type can be only one of the following:
"dataRecord": string,
"protoRecord": {
"@type": string,
field1: ...,
...
}
// End of list of possible types for union field record_type .
} |
Trường |
deleteTime |
string (Timestamp format)
Bắt buộc. Dấu thời gian này được dùng để xác định thứ tự áp dụng lệnh xoá cho khoảng không quảng cáo. Dấu thời gian ở định dạng "Zulu" RFC3339 UTC, có độ phân giải nano giây và tối đa 9 chữ số thập phân. Ví dụ: "2014-10-02T15:01:23Z" và "2014-10-02T15:01:23.045123456Z" .
|
Trường hợp hợp nhất record_type . Đóng gói nhiều loại nguồn cấp dữ liệu (ndjson, dựa trên proto, v.v.) Đối tác có thể cung cấp bản ghi đầy đủ tương tự như cách cung cấp bản ghi trong nguồn cấp dữ liệu hoặc API BatchPush. Đối tác cũng có thể chỉ cung cấp các trường thiết yếu của một bản ghi cần thiết để xác định chính xác bản ghi đó. record_type chỉ có thể là một trong những trạng thái sau đây: |
dataRecord |
string (bytes format)
Đối với nguồn cấp dữ liệu không dựa trên proto. Chuỗi được mã hoá base64.
|
protoRecord |
object
Đối với nguồn cấp dữ liệu dựa trên proto. Một đối tượng có chứa các trường thuộc loại tuỳ ý. Một trường bổ sung "@type" chứa URI xác định loại. Ví dụ: { "id": 1234, "@type": "types.example.com/standard/id" } .
|
Trừ phi có lưu ý khác, nội dung của trang này được cấp phép theo Giấy phép ghi nhận tác giả 4.0 của Creative Commons và các mẫu mã lập trình được cấp phép theo Giấy phép Apache 2.0. Để biết thông tin chi tiết, vui lòng tham khảo Chính sách trang web của Google Developers. Java là nhãn hiệu đã đăng ký của Oracle và/hoặc các đơn vị liên kết với Oracle.
Cập nhật lần gần đây nhất: 2025-07-24 UTC.
[null,null,["Cập nhật lần gần đây nhất: 2025-07-24 UTC."],[[["\u003cp\u003eThis API endpoint (\u003ccode\u003ebatchDelete\u003c/code\u003e) is used to delete records from a specified feed within the Google Maps Booking inventory.\u003c/p\u003e\n"],["\u003cp\u003eThe request requires specifying the \u003ccode\u003eparent\u003c/code\u003e (partner and feed) and an array of \u003ccode\u003erecords\u003c/code\u003e to be deleted, with a maximum of 1000 records per call.\u003c/p\u003e\n"],["\u003cp\u003eEach record to be deleted (\u003ccode\u003eGenericDeleteRecord\u003c/code\u003e) can be identified either by a full data record or a unique identifier, depending on the feed type.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003edeleteTime\u003c/code\u003e field is crucial for determining the order of deletion, ensuring data consistency.\u003c/p\u003e\n"],["\u003cp\u003eSuccessful deletion requests will return an empty response body.\u003c/p\u003e\n"]]],[],null,["# Method: inventory.partners.feeds.record.batchDelete\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Path parameters](#body.PATH_PARAMETERS)\n- [Request body](#body.request_body)\n - [JSON representation](#body.request_body.SCHEMA_REPRESENTATION)\n- [Response body](#body.response_body)\n- [Authorization scopes](#body.aspect)\n- [GenericDeleteRecord](#GenericDeleteRecord)\n - [JSON representation](#GenericDeleteRecord.SCHEMA_REPRESENTATION)\n\nDeletes records of specified feed type. Only performs basic validation (like malformed request) after which an appropriate response is returned to the partner immediately. Google performs business logic validation on the request asynchronously. This batch call does not guarantee atomicity.\n\n### HTTP request\n\n`POST https://mapsbooking.googleapis.com/v1alpha/inventory/{parent=partners/*/feeds/*}/record:batchDelete`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Path parameters\n\n| Parameters ||\n|----------|----------------------------------------------------------------------------------------------|\n| `parent` | `string` Resource name, which has the format of - `partners/{partner_id}/feeds/{feed_name}`. |\n\n### Request body\n\nThe request body contains data with the following structure:\n\n| JSON representation |\n|---------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"records\": [ { object (/maps-booking/reference/maps-booking-api/rest/v1alpha/inventory.partners.feeds.record/batchDelete#GenericDeleteRecord) } ] } ``` |\n\n| Fields ||\n|-------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `records[]` | `object (`[GenericDeleteRecord](/maps-booking/reference/maps-booking-api/rest/v1alpha/inventory.partners.feeds.record/batchDelete#GenericDeleteRecord)`)` Records to be deleted. Maximum of 1000 records are allowed in one api call. |\n\n### Response body\n\nIf successful, the response body is empty.\n\n### Authorization scopes\n\nRequires the following OAuth scope:\n\n- `https://www.googleapis.com/auth/mapsbooking`\n\nGenericDeleteRecord\n-------------------\n\nRecord to be deleted of the feed type mentioned in url request.\n\n| JSON representation |\n|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"deleteTime\": string, // Union field `record_type` can be only one of the following: \"dataRecord\": string, \"protoRecord\": { \"@type\": string, field1: ..., ... } // End of list of possible types for union field `record_type`. } ``` |\n\n| Fields ||\n|-----------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `delete``Time` | `string (`[Timestamp](https://protobuf.dev/reference/protobuf/google.protobuf/#timestamp)` format)` Required. This timestamp is used to determine the order in which a delete will be applied to the inventory. A timestamp in RFC3339 UTC \"Zulu\" format, with nanosecond resolution and up to nine fractional digits. Examples: `\"2014-10-02T15:01:23Z\"` and `\"2014-10-02T15:01:23.045123456Z\"`. |\n| Union field `record_type`. Encapsulate different types of feed (ndjson, proto-based, etc.) Partner can provide a full record similar to how a record is provided in a feed or BatchPush API. Partners also have the option to include only the essential fields of a record required to uniquely identify it. `record_type` can be only one of the following: ||\n| `data``Record` | `string (`[bytes](https://developers.google.com/discovery/v1/type-format)` format)` For non-proto based feeds. A base64-encoded string. |\n| `proto``Record` | `object` For proto-based feeds. An object containing fields of an arbitrary type. An additional field `\"@type\"` contains a URI identifying the type. Example: `{ \"id\": 1234, \"@type\": \"types.example.com/standard/id\" }`. |"]]