2013-02-11 139 views
0

我已經定義了一些自定義指標和自定義維度。我可以在我的自定義報告中看到並使用它們,或者在標準報告中將它們用作次級維度。如何從Google Core Reporting API訪問自定義指標和自定義維度

我無法從Core Reporting API訪問它們。我希望能夠以類似於自定義變量的方式提取它們。

我迄今無法做到這一點,或無法找到此的任何文檔除了這個參考

https://developers.google.com/analytics/devguides/platform/features/customdimsmets#reporting

After the collection, configuration, and other processing stages of 
the pipeline are complete, custom dimensions and metrics become available 
via the web reporting interface or th Core Reporting API. 

對我來說這倒像是它應該是可能的。

任何幫助將不勝感激!

回答

0

檢查了這一點:https://developers.google.com/resources/api-libraries/documentation/analytics/v3/java/latest/

檢查方法:Analytics.Data.Ga.get(字符串ID, 字符串的startDate, 字符串結束日期, 字符串度量) 參數:

.....

指標 - 逗號分隔Google Analytics指標的對比列表。例如,'ga:訪問,ga:綜合瀏覽'。至少必須指定一個指標。

我認爲第四個參數是一種基於自定義變量,維度或指標檢索過濾報表的方法。

相關問題