通过API播放Google Analytics(分析)事件:如何从Web客户端从Firebase SDK获取App_instance_id或client_id?

问题描述 投票:0回答:2
Gtag.js

)从Firebase SDK获取

app_instance_id
client_id
? Reference:Https://developers.google.com/analytics/devguides/collection/collection/protocol/ga4/sending-events?client_type =firebase

i使用了firebase/installations

const installationId = await installations.getId( installations.getInstallations() );

但是在使用GA4 API处使用此类请求时,我会得到:

installationId

我假设您现在已经解决了这个问题,但是我了解到的是Firebase协议是针对移动应用程序的。对于Web应用程序,您应该使用GTAG。如果您使用的是移动应用程序,则
docs

描述了如何使用移动特定平台获取ID,该平台不是来自Firebase安装模块。
    
google-analytics google-analytics-api google-analytics-firebase google-analytics-4
2个回答
0
投票
如果我正确理解您的问题,您正在搜索firebase SDK。

最简单的选择是允许在Firebase集成中流入您的BigQuery表。然后在BigQuery Intra Intra tables中找到您的description: "Measurement app_instance_id is expected to be a 32 digit hexadecimal number but was [22] digits." fieldPath: "app_instance_id" validationCode: "VALUE_INVALID"

app_instance_id

-1
投票
在BigQuery中,您将在以下列下:

client_id

=
app_instance_id
client_id

=

app_instance_id

AROTHER选项设置为代理 - 例如

Charles

Mitm
,并从您的应用程序中获取真实日志。然后,您可以轻松地抓住它。
其他选项#2是安装
adb
。并使用LogCat探索PC上使用连接的设备的日志(最好是Android设备。我没有iOS设备的经验)
我希望有帮助。
	
最新问题
© www.soinside.com 2019 - 2024. All rights reserved.