google-analytics-admin-api-basics

Configure Google Analytics accounts, properties, and data streams via the Admin API.

Updated May 11, 2026
One-click install
npx skills add https://github.com/alon3153/upe-social-publisher --skill google-analytics-admin-api-basics-alon3153
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: google-analytics-admin-api-basics
Source: https://github.com/alon3153/upe-social-publisher/tree/main/.agents/skills/google-analytics-admin-api-basics
Command: npx skills add https://github.com/alon3153/upe-social-publisher --skill google-analytics-admin-api-basics-alon3153

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Manually configuring Google Analytics accounts, properties, data streams, and integrations through the web UI is slow and error-prone. This Skill enables programmatic management of Google Analytics configuration through the Admin API, including authentication setup and client library installation. ## Core Features & Use Cases - API Enablement & Authentication: Enable the Analytics Admin API via gcloud and configure Application Default Credentials with the correct OAuth scopes. - Account & Property Management: List accounts and properties, manage data retention, conversion events, custom dimensions, and Measurement Protocol secrets. - Multi-Language Client Setup: Installation and quickstart guides for Python, Java, PHP, Node.js, Go, .NET, and Ruby client libraries. - Use Case: You need to provision a new GA4 property and configure its data streams across environments. Use this Skill to authenticate, install the Python client, and script the entire configuration. ## Quick Start Ask the AI to enable the Google Analytics Admin API and list all accounts and properties using the Python client library.

Frequently Asked Questions about google-analytics-admin-api-basics

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I list Google Analytics accounts and properties with the Admin API?▼

Use the list_account_summaries method from the AnalyticsAdminServiceClient after configuring Application Default Credentials. It returns all accounts accessible to the authenticated user along with their child properties.

How do I enable the Google Analytics Admin API in my Cloud project?▼

Run gcloud services enable analyticsadmin.googleapis.com to activate the API, then verify with gcloud services list --enabled. This allocates the quota and permissions needed for Admin API calls.

What OAuth scopes does the Google Analytics Admin API require?▼

Read operations need the analytics.readonly scope, while configuration changes require the analytics.edit scope. Both are granted via gcloud auth application-default login alongside the cloud-platform scope.

Which programming languages have Google Analytics Admin API client libraries?▼

Official client libraries exist for Python, Java, PHP, Node.js, Go, .NET, and Ruby. Each has a dedicated setup guide covering installation and a quickstart example for listing account summaries.

What is the difference between the v1alpha and v1beta Admin API versions?▼

v1beta is the most stable version and covers core account, property, and data stream management. v1alpha adds newer features like rollup properties, subproperties, audiences, channel groups, and BigQuery links.