Method: hashLists.list
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.
Liệt kê các danh sách hàm băm.
Trong API V5, Google sẽ không bao giờ xoá danh sách hàm băm mà phương thức này từng trả về. Cách này cho phép khách hàng bỏ qua phương thức này và chỉ cần mã hoá cứng tất cả danh sách băm mà họ cần.
Đây là một phương thức List (Danh sách) chuẩn theo xác định của https://google.aip.dev/132 và phương thức HTTP là GET.
Yêu cầu HTTP
GET https://safebrowsing.googleapis.com/v5alpha1/hashLists
URL sử dụng cú pháp Chuyển mã gRPC.
Tham số truy vấn
Tham số |
pageSize |
integer
Số lượng danh sách băm tối đa cần trả về. Dịch vụ có thể trả về ít hơn giá trị này. Nếu bạn không chỉ định, máy chủ sẽ chọn một kích thước trang. Kích thước này có thể lớn hơn số lượng danh sách băm để không cần phân trang.
|
pageToken |
string
Mã thông báo trang, nhận được từ lệnh gọi hashLists.list trước đó. Cung cấp mã này để truy xuất trang tiếp theo.
|
Nội dung yêu cầu
Nội dung yêu cầu phải trống.
Nội dung phản hồi
Phản hồi chứa siêu dữ liệu về danh sách hàm băm.
Nếu thành công, phần nội dung phản hồi sẽ chứa dữ liệu có cấu trúc sau:
Biểu diễn dưới dạng JSON |
{
"hashLists": [
{
object (HashList )
}
],
"nextPageToken": string
} |
Trường |
hashLists[] |
object (HashList )
Các danh sách hàm băm theo thứ tự tuỳ ý. Chỉ siêu dữ liệu về các danh sách băm mới được đưa vào, chứ không phải nội dung.
|
nextPageToken |
string
Mã thông báo có thể được gửi dưới dạng pageToken để truy xuất trang tiếp theo. Nếu trường này bị bỏ qua thì sẽ không có trang tiếp theo.
|
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-25 UTC.
[null,null,["Cập nhật lần gần đây nhất: 2025-07-25 UTC."],[[["\u003cp\u003eRetrieves a list of available hash lists with metadata, excluding their contents.\u003c/p\u003e\n"],["\u003cp\u003eAllows for pagination to retrieve large sets of hash lists using \u003ccode\u003epageSize\u003c/code\u003e and \u003ccode\u003epageToken\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eGoogle guarantees that hash lists once returned will never be removed, enabling client-side hardcoding.\u003c/p\u003e\n"],["\u003cp\u003eEmploys standard List method with a GET request to \u003ccode\u003ehttps://safebrowsing.googleapis.com/v5alpha1/hashLists\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eResponse includes details about each hash list and a token for retrieving subsequent pages if available.\u003c/p\u003e\n"]]],["This document details the process for retrieving metadata about hash lists using the V5 API's `hashLists.list` method. It uses an HTTP GET request to `https://safebrowsing.googleapis.com/v5alpha1/hashLists`. Optional query parameters include `pageSize` to limit results and `pageToken` for pagination. The request body must be empty. The response body includes an array of `hashLists` and an optional `nextPageToken` for subsequent pages. The API never removes returned hash lists.\n"],null,["# Method: hashLists.list\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Query parameters](#body.QUERY_PARAMETERS)\n- [Request body](#body.request_body)\n- [Response body](#body.response_body)\n - [JSON representation](#body.ListHashListsResponse.SCHEMA_REPRESENTATION)\n\nList hash lists.\n\nIn the V5 API, Google will never remove a hash list that has ever been returned by this method. This enables clients to skip using this method and simply hard-code all hash lists they need.\n\nThis is a standard List method as defined by \u003chttps://google.aip.dev/132\u003e and the HTTP method is GET.\n\n### HTTP request\n\n`GET https://safebrowsing.googleapis.com/v5alpha1/hashLists`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Query parameters\n\n| Parameters ||\n|-------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `pageSize` | `integer` The maximum number of hash lists to return. The service may return fewer than this value. If unspecified, the server will choose a page size, which may be larger than the number of hash lists so that pagination is not necessary. |\n| `pageToken` | `string` A page token, received from a previous `hashLists.list` call. Provide this to retrieve the subsequent page. |\n\n### Request body\n\nThe request body must be empty.\n\n### Response body\n\nThe response containing metadata about hash lists.\n\nIf successful, the response body contains data with the following structure:\n\n| JSON representation |\n|-----------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"hashLists\": [ { object (/safe-browsing/reference/rest/v5alpha1/hashList#HashList) } ], \"nextPageToken\": string } ``` |\n\n| Fields ||\n|-----------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `hashLists[]` | `object (`[HashList](/safe-browsing/reference/rest/v5alpha1/hashList#HashList)`)` The hash lists in an arbitrary order. Only metadata about the hash lists will be included, not the contents. |\n| `nextPageToken` | `string` A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted, there are no subsequent pages. |"]]