Google Business Performance API 的
NEW API 方法可擷取單一 API 要求中的多個「DailyMetrics」。
請詳閱
淘汰時間表和從 v4 reportInsights API 方法遷移至 Google Business Profile Performance API 的操作說明。
Method: accounts.locations.reviews.list
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
傳回指定地點的分頁評論清單。只有在指定位置已通過驗證時,這項作業才會生效。
HTTP 要求
GET https://mybusiness.googleapis.com/v4/{parent=accounts/*/locations/*}/reviews
這個網址使用 gRPC 轉碼語法。
路徑參數
參數 |
parent |
string
要擷取評論的地點名稱。
|
查詢參數
參數 |
pageSize |
integer
每頁要擷取的評論數量。pageSize 上限為 50。
|
pageToken |
string
如果有指定,它會擷取下一頁的評論。
|
orderBy |
string
指定評論排序依據的欄位。如未指定,傳回的評論順序將預設為 updateTime desc 。可排序的有效訂單為 rating 、rating desc 和 updateTime desc 。
|
回應主體
如果成功,回應主體會含有以下結構的資料:
Review.ListReviews 的回應訊息。
JSON 表示法 |
{
"reviews": [
{
object (Review )
}
],
"averageRating": number,
"totalReviewCount": integer,
"nextPageToken": string
} |
欄位 |
reviews[] |
object (Review )
評論。
|
averageRating |
number
這個地點所有評論的平均星級評等,以 1 到 5 表示,5 是最高評分。
|
totalReviewCount |
integer
這個地點的評論總數。
|
nextPageToken |
string
如果評論數量超過要求的頁面大小,這個欄位就會填入符記,以擷取後續呼叫 review.list 的下一頁。如果已經沒有評論,系統就不會在回覆中顯示這個欄位。
|
授權範圍
需要下列其中一種 OAuth 範圍:
https://www.googleapis.com/auth/plus.business.manage
https://www.googleapis.com/auth/business.manage
詳情請參閱 OAuth 2.0 總覽。
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2024-10-14 (世界標準時間)。
[[["容易理解","easyToUnderstand","thumb-up"],["確實解決了我的問題","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["缺少我需要的資訊","missingTheInformationINeed","thumb-down"],["過於複雜/步驟過多","tooComplicatedTooManySteps","thumb-down"],["過時","outOfDate","thumb-down"],["翻譯問題","translationIssue","thumb-down"],["示例/程式碼問題","samplesCodeIssue","thumb-down"],["其他","otherDown","thumb-down"]],["上次更新時間:2024-10-14 (世界標準時間)。"],[[["Retrieves a paginated list of reviews for a specified, verified Google My Business location."],["Allows filtering by page size, page token, and sorting order (rating, rating descending, or update time descending)."],["Returns review details, average rating, total review count, and a token for retrieving subsequent pages if available."],["Requires authorization with specific OAuth scopes for business management."]]],["This content outlines the process of retrieving a paginated list of reviews for a verified location using a `GET` request to a specific URL. The URL utilizes path parameters like `parent` to identify the location. Query parameters such as `pageSize`, `pageToken`, and `orderBy` are used to manage pagination and sorting. The request body is empty. A successful response returns a JSON object containing a list of `reviews`, `averageRating`, `totalReviewCount`, and optionally `nextPageToken` for pagination. Authorization requires specific OAuth scopes.\n"]]