Google Analytics · Arazzo Workflow

Google Analytics Batch Run Reports

Version 1.0.0

Confirm a property exists, then run several core reports for it in a single batch.

1 workflow 1 source API 1 provider
View Spec View on GitHub AnalyticsDataGoogleMetricsReportingWeb AnalyticsMachine-LearningAttributionArazzoWorkflows

Provider

google-analytics

Workflows

batch-run-reports
Run multiple core reports for one GA4 property in a single batch request.
Lists the properties under an account and submits a batchRunReports request containing two report definitions for the supplied property.
2 steps inputs: accessToken, account, endDate, property, startDate outputs: properties, reports
1
listProperties
List the GA4 properties under the account so the target property can be confirmed before submitting the batch.
2
batchRunReports
Submit two report definitions for the property in a single batch: active users by country and event count by event name.

Source API Descriptions

Arazzo Workflow Specification

Raw ↑
arazzo: 1.0.1
info:
  title: Google Analytics Batch Run Reports
  summary: Confirm a property exists, then run several core reports for it in a single batch.
  description: >-
    A batched reporting flow across the GA4 Admin and Data APIs. The workflow
    first lists the properties under an account to confirm the target property,
    then issues a single batchRunReports request carrying multiple report
    definitions for that same property — a users-by-country report and an
    events-by-event-name report — so several views are retrieved in one round
    trip. Every request is spelled out inline, including the OAuth bearer
    authorization.
  version: 1.0.0
sourceDescriptions:
- name: propertiesApi
  url: ../openapi/google-analytics-properties-api-openapi.yml
  type: openapi
workflows:
- workflowId: batch-run-reports
  summary: Run multiple core reports for one GA4 property in a single batch request.
  description: >-
    Lists the properties under an account and submits a batchRunReports request
    containing two report definitions for the supplied property.
  inputs:
    type: object
    required:
    - accessToken
    - account
    - property
    properties:
      accessToken:
        type: string
        description: OAuth 2.0 bearer access token with an analytics read scope.
      account:
        type: string
        description: 'Account resource name to list properties under (e.g. accounts/123).'
      property:
        type: string
        description: 'GA4 property resource name to report on (e.g. properties/1234).'
      startDate:
        type: string
        description: Inclusive start date for both reports as YYYY-MM-DD or NdaysAgo.
        default: 28daysAgo
      endDate:
        type: string
        description: Inclusive end date for both reports as YYYY-MM-DD, yesterday, or today.
        default: yesterday
  steps:
  - stepId: listProperties
    description: >-
      List the GA4 properties under the account so the target property can be
      confirmed before submitting the batch.
    operationId: analyticsadmin.properties.list
    parameters:
    - name: Authorization
      in: header
      value: Bearer $inputs.accessToken
    - name: filter
      in: query
      value: parent:$inputs.account
    - name: pageSize
      in: query
      value: 200
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      properties: $response.body#/properties
  - stepId: batchRunReports
    description: >-
      Submit two report definitions for the property in a single batch: active
      users by country and event count by event name.
    operationId: analyticsdata.properties.batchRunReports
    parameters:
    - name: Authorization
      in: header
      value: Bearer $inputs.accessToken
    - name: property
      in: path
      value: $inputs.property
    requestBody:
      contentType: application/json
      payload:
        requests:
        - dimensions:
          - name: country
          metrics:
          - name: activeUsers
          dateRanges:
          - startDate: $inputs.startDate
            endDate: $inputs.endDate
          limit: "100"
        - dimensions:
          - name: eventName
          metrics:
          - name: eventCount
          dateRanges:
          - startDate: $inputs.startDate
            endDate: $inputs.endDate
          limit: "100"
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      reports: $response.body#/reports
      kind: $response.body#/kind
  outputs:
    properties: $steps.listProperties.outputs.properties
    reports: $steps.batchRunReports.outputs.reports

Work with this as data

Every workflow here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for arazzo workflows

4 MCP tools reach this
  • find_arazzoBrowse and filter every workflow in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This workflow
curl "https://apis.io/api/v1/arazzo/google-analytics-batch-run-reports-workflow"
All arazzo workflows
curl "https://apis.io/api/v1/arazzo?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.