Wisieńką na torcie podczas oddawania strony WWW klientowi z zintegrowanym Alfred CMSem jest wyświetlenie statystyk pochodzących z Google Analytics na Dashboardzie. Ten poradnik wskazuje jak krok po kroku udostępnić Alfredowi dane z Google Analytics i jak skonfigurować Dashboard w CMSie, aby wykresy i niezbędne analizy wyświetlały się z poziomu Alfreda.
How to add Google Analytics Stats to Alfred Dashboard
- Log into https://console.cloud.google.com using marketing@biggerpicture.agency Google account (credentials in LastPass).
- Select the required project from the ‘Select a project’ dropdown in the top nav bar, if project does not exist please create.
- Within selected project, click „Enable APIs and Services” - https://console.cloud.google.com/apis/library.
- Navigate to Google Analytics API, select and enable the API.
- Navigate to Credentials on the APIs & Services screen - https://console.cloud.google.com/apis/credentials.
- Click ‚Create credentials’ -> Service Account Key.
- Choose New service account from the Service account dropdown and fill out the Service account name (preferably as ‚alfred-cms’). Role should be set to Project -> Viewer for client projects. Choose P12 format and click Create. Save the P12 key in Lastpass under client project name.
- Navigate to Manage service accounts link under the ‘Service account keys’ and click.
- Copy the email address of the newly created account.
- Log into Google Analytics account (as marketing@biggerpicture.agency) and select correct project.
- Navigate to Admin and click User Management.
- Add a new user, setting the email address copied from Google Cloud Platform. Permissions should be set to Read & Analyze.
- Log in to Alfred and go to Settings -> CMS Settings -> Marketing Dashboard. Click on „Enabled” and fill out all fields. The Client ID is the „Key ID” and „Email” is the „Email” from Google Cloud Platform.
- Once all the Marketing Dashboard settings are complete, save and reload Alfred. Go to the Dashboard and check the stats from Google Analytics are correctly displaying.