試用 Google Analytics 的 MCP 伺服器。從
GitHub 安裝,詳情請參閱
公告。
Method: accountSummaries.list
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
HTTP 要求
GET https://analyticsadmin.googleapis.com/v1alpha/accountSummaries
這個網址使用 gRPC 轉碼語法。
查詢參數
參數 |
pageSize |
integer
要傳回的 AccountSummary 資源數量上限。即使有其他頁面,服務傳回的產品數量可能會少於這個值。如未指定,最多將傳回 50 個資源。許可的最大值為 200;超出的數值將一律指定為 200
|
pageToken |
string
從先前 accountSummaries.list 呼叫收到的網頁權杖。提供此項目即可擷取後續網頁。進行分頁時,提供至 accountSummaries.list 的所有其他參數須與提供網頁權杖的呼叫相符。
|
回應主體
accountSummaries.list RPC 的回應訊息。
如果成功,回應主體會含有以下結構的資料:
JSON 表示法 |
{
"accountSummaries": [
{
object (AccountSummary )
}
],
"nextPageToken": string
} |
欄位 |
accountSummaries[] |
object (AccountSummary )
呼叫端可存取的所有帳戶帳戶摘要。
|
nextPageToken |
string
可做為 pageToken 傳送的權杖,用於擷取後續網頁。如果省略這個欄位,就不會有後續頁面。
|
授權範圍
需要下列其中一種 OAuth 範圍:
https://www.googleapis.com/auth/analytics.readonly
https://www.googleapis.com/auth/analytics.edit
AccountSummary
虛擬資源,代表帳戶及其所有 Google Analytics 子資源的概況。
JSON 表示法 |
{
"name": string,
"account": string,
"displayName": string,
"propertySummaries": [
{
object (PropertySummary )
}
]
} |
欄位 |
name |
string
這個帳戶摘要的資源名稱。格式:accountSummaries/{account_id} 範例:「accountSummaries/1000」
|
account |
string
這個帳戶摘要所參照的帳戶資源名稱。格式:accounts/{account_id}。範例:「accounts/1000」
|
displayName |
string
這個帳戶摘要中所提及帳戶的顯示名稱。
|
propertySummaries[] |
object (PropertySummary )
這個帳戶的子帳戶摘要清單。
|
PropertySummary
代表 Google Analytics 資源的結構描述資料虛擬資源。
JSON 表示法 |
{
"property": string,
"displayName": string,
"propertyType": enum (PropertyType ),
"parent": string
} |
欄位 |
property |
string
這個屬性摘要所參照的資源名稱。格式:properties/{property_id}。範例:「properties/1000」。
|
displayName |
string
這項資源摘要中所指的資源顯示名稱。
|
propertyType |
enum (PropertyType )
房源的房源類型。
|
parent |
string
此房源邏輯父項的資源名稱。 注意:您可以使用資源移動 UI 變更父項。格式:accounts/{account}、properties/{property} 範例:「accounts/100」、「properties/200」
|
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2025-07-26 (世界標準時間)。
[null,null,["上次更新時間:2025-07-26 (世界標準時間)。"],[[["\u003cp\u003eLists and summarizes all Google Analytics 4 (GA4) accounts and their properties accessible to the authenticated user.\u003c/p\u003e\n"],["\u003cp\u003eAllows for pagination to handle large numbers of accounts using \u003ccode\u003epageSize\u003c/code\u003e and \u003ccode\u003epageToken\u003c/code\u003e parameters.\u003c/p\u003e\n"],["\u003cp\u003eEach account summary includes the account name, display name, and a list of associated property summaries.\u003c/p\u003e\n"],["\u003cp\u003eProvides property details such as property name, display name, type, and its parent resource.\u003c/p\u003e\n"],["\u003cp\u003eRequires specific authorization scopes for access, including 'analytics.readonly' or 'analytics.edit'.\u003c/p\u003e\n"]]],["This document details how to retrieve summaries of accessible Google Analytics accounts via an HTTP GET request to `https://analyticsadmin.googleapis.com/v1alpha/accountSummaries`. Key actions include setting optional `pageSize` and `pageToken` query parameters for pagination. The request body is empty. The response provides a list of `accountSummaries`, each containing account details and `propertySummaries`, with the possibility of a `nextPageToken` for subsequent pages. Authorization requires specific OAuth scopes.\n"],null,["# Method: accountSummaries.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.ListAccountSummariesResponse.SCHEMA_REPRESENTATION)\n- [Authorization scopes](#body.aspect)\n- [AccountSummary](#AccountSummary)\n - [JSON representation](#AccountSummary.SCHEMA_REPRESENTATION)\n- [PropertySummary](#PropertySummary)\n - [JSON representation](#PropertySummary.SCHEMA_REPRESENTATION)\n- [Try it!](#try-it)\n\nReturns summaries of all accounts accessible by the caller.\n\n### HTTP request\n\n`GET https://analyticsadmin.googleapis.com/v1alpha/accountSummaries`\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 AccountSummary resources to return. The service may return fewer than this value, even if there are additional pages. If unspecified, at most 50 resources will be returned. The maximum value is 200; (higher values will be coerced to the maximum) |\n| `pageToken` | `string` A page token, received from a previous `accountSummaries.list` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `accountSummaries.list` must match the call that provided the page token. |\n\n### Request body\n\nThe request body must be empty.\n\n### Response body\n\nResponse message for accountSummaries.list RPC.\n\nIf successful, the response body contains data with the following structure:\n\n| JSON representation |\n|------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"accountSummaries\": [ { object (/analytics/devguides/config/admin/v1/rest/v1alpha/accountSummaries/list#AccountSummary) } ], \"nextPageToken\": string } ``` |\n\n| Fields ||\n|----------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `accountSummaries[]` | `object (`[AccountSummary](/analytics/devguides/config/admin/v1/rest/v1alpha/accountSummaries/list#AccountSummary)`)` Account summaries of all accounts the caller has access to. |\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. |\n\n### Authorization scopes\n\nRequires one of the following OAuth scopes:\n\n- `https://www.googleapis.com/auth/analytics.readonly`\n- `https://www.googleapis.com/auth/analytics.edit`\n\nAccountSummary\n--------------\n\nA virtual resource representing an overview of an account and all its child Google Analytics properties.\n\n| JSON representation |\n|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"name\": string, \"account\": string, \"displayName\": string, \"propertySummaries\": [ { object (/analytics/devguides/config/admin/v1/rest/v1alpha/accountSummaries/list#PropertySummary) } ] } ``` |\n\n| Fields ||\n|-----------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `name` | `string` Resource name for this account summary. Format: accountSummaries/{account_id} Example: \"accountSummaries/1000\" |\n| `account` | `string` Resource name of account referred to by this account summary Format: accounts/{account_id} Example: \"accounts/1000\" |\n| `displayName` | `string` Display name for the account referred to in this account summary. |\n| `propertySummaries[]` | `object (`[PropertySummary](/analytics/devguides/config/admin/v1/rest/v1alpha/accountSummaries/list#PropertySummary)`)` List of summaries for child accounts of this account. |\n\nPropertySummary\n---------------\n\nA virtual resource representing metadata for a Google Analytics property.\n\n| JSON representation |\n|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"property\": string, \"displayName\": string, \"propertyType\": enum (/analytics/devguides/config/admin/v1/rest/v1alpha/properties#PropertyType), \"parent\": string } ``` |\n\n| Fields ||\n|----------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `property` | `string` Resource name of property referred to by this property summary Format: properties/{property_id} Example: \"properties/1000\" |\n| `displayName` | `string` Display name for the property referred to in this property summary. |\n| `propertyType` | `enum (`[PropertyType](/analytics/devguides/config/admin/v1/rest/v1alpha/properties#PropertyType)`)` The property's property type. |\n| `parent` | `string` Resource name of this property's logical parent. Note: The Property-Moving UI can be used to change the parent. Format: accounts/{account}, properties/{property} Example: \"accounts/100\", \"properties/200\" |"]]