Google アナリティクスの MCP サーバーを試します。
GitHub からインストールし、詳細については
お知らせをご覧ください。
Google uses AI technology to translate content into your preferred language. AI translations can contain errors.
Method: properties.fetchConnectedGa4Property
コレクションでコンテンツを整理
必要に応じて、コンテンツの保存と分類を行います。
指定された UA プロパティが与えられると、それに接続されている GA4 プロパティが検索されます。注: GA4 プロパティでは使用できません。
HTTP リクエスト
GET https://analyticsadmin.googleapis.com/v1alpha/properties:fetchConnectedGa4Property
この URL は gRPC Transcoding 構文を使用します。
クエリ パラメータ
| パラメータ |
property |
string
必須。接続された GA4 プロパティを検索する UA プロパティ。このリクエストでは、UA-XXXXXX-YY 形式のトラッキング ID ではなく、内部プロパティ ID が使用されます。形式: properties/{internal_web_property_id} 例: properties/1234
|
リクエスト本文
リクエストの本文は空にする必要があります。
レスポンスの本文
UA プロパティに接続されている GA4 プロパティを検索するためのレスポンス。
成功した場合、レスポンスの本文には次の構造のデータが含まれます。
| JSON 表現 |
{
"property": string
} |
| フィールド |
property |
string
UA プロパティに接続されている GA4 プロパティ。接続された GA4 プロパティがない場合は、空の文字列が返されます。形式: properties/{property_id} 例: properties/1234
|
認可スコープ
次の OAuth スコープのいずれかが必要です。
https://www.googleapis.com/auth/analytics.readonly
https://www.googleapis.com/auth/analytics.edit
特に記載のない限り、このページのコンテンツはクリエイティブ・コモンズの表示 4.0 ライセンスにより使用許諾されます。コードサンプルは Apache 2.0 ライセンスにより使用許諾されます。詳しくは、Google Developers サイトのポリシーをご覧ください。Java は Oracle および関連会社の登録商標です。
最終更新日 2025-07-26 UTC。
[null,null,["最終更新日 2025-07-26 UTC。"],[],["This document details how to find a connected GA4 property using its associated UA property. A `GET` request to `https://analyticsadmin.googleapis.com/v1alpha/properties:fetchConnectedGa4Property` is made. The request requires a `property` query parameter, which is the UA property's internal ID, formatted as `properties/{internal_web_property_id}`. The request body must be empty. The response body returns a JSON structure containing a `property` field with the GA4 property ID or an empty string if none exists. The request needs authorization with specific OAuth scopes.\n"]]