Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How i can add new project to google analytics?

I have an application that creates mobile applications. I want to know is it possible to programmatically add each mobile app in the existing Google Analytics account for tracking?

Google analytic has API for getting report like following link(https://developers.google.com/analytics/) but unfortunately I couldn't find proper document for adding new project to existing account.

Thanks in advance.

like image 796
Arman Feyzi Avatar asked Oct 29 '22 14:10

Arman Feyzi


1 Answers

It is possible to programmatically add web properties to Google Analytics. It is part of the management API the method is called Web Properties: insert

The first thing you need to know is that this method is in beta. You need permission to use it. If you want to use this I suggest you apply for beta now it can take a while (Like a month) to get access Google will email you if they allow you to join the beta. The link to beta can be found at the top of this page in blue Web Properties: insert

Write operations in the Management API (e.g. create, update, delete, patch) for Web Property, View (Profile), and Goal resources are currently available as a developer preview in limited beta. If you're interested in using these features, request access to the beta.

The second thing you should know is that I am not sure it will allow you to create a mobile tracking account. By what I can see in the documentation it only works with web analytics accounts which will not work for you since its a mobile application you want to track.

I think I have an account with access to this API I am going to check. I will let you know. If its not supported then I guess we could create a feature request but it might take them a while to add it.

like image 93
DaImTo Avatar answered Nov 14 '22 04:11

DaImTo