Skip to main content

Google Analytics integration

Run GA4 traffic, conversion and realtime reports on your clients' properties and send the numbers to Slack, Sheets or any other app.

What it does

The Google Analytics integration runs GA4 reports from a workflow. Connect the Google account that can see a client's GA4 property, pick the property, and pull sessions, users, key events or any other metric by date, page, channel or any dimension the property reports on, including its custom dimensions. Pair it with the Schedule trigger to send a weekly client report to Slack or append it to a Google Sheet.

The connection is read-only. TaskJuice asks Google for analytics.readonly, so a workflow can read reports and settings but can never change a property.

Connect a Google Analytics account

  1. Start the connection

    In your workspace, open Apps, choose Google Analytics and click Connect account. You can also click Connect on any Google Analytics step in the workflow editor.

  2. Sign in with the right Google account

    Use the Google account that has at least Viewer access to the client's GA4 property.

  3. Grant read-only access

    Google asks to let TaskJuice see your Google Analytics data. That is the only permission requested, besides your name and email address, which label the connection.

The connection stays signed in: TaskJuice renews its access automatically, so scheduled workflows keep running. To revoke access, open Google Account permissions and remove TaskJuice.

Pick the property

Every property-scoped action has two pickers. Choose the Account first, then the Property list shows that account's GA4 properties. The account picker only narrows the property list and is never sent to Google.

You can also type or map the property ID instead of picking it. Both forms work and send the same request:

You enterSent to Google
123456properties/123456
properties/123456properties/123456

Find the ID in Google Analytics under Admin, Property details. It is a number, not the G- measurement ID of a web stream.

The Dimensions and Metrics pickers on Run Report and Check Compatibility load the chosen property's own list, so custom dimensions and metrics appear by name. You can type an API name such as customEvent:plan_tier too.

Report dates

GA4 report actions take a start and end date. Each accepts any of these:

  • A date: 2026-10-01
  • today or yesterday
  • A number of days ago: 7daysAgo, 28daysAgo, 90daysAgo

Run Report defaults to 28daysAgo through yesterday. Relative dates are resolved in the property's time zone each time the workflow runs, so a scheduled report always covers the latest period without an expression.

Actions

Reports

  • Run Report runs a GA4 report: up to 9 dimensions and 10 metrics over a date range, with optional order, dimension and metric filters, a row limit (default 10,000, up to 100,000) and an offset for paging. Advanced Request Fields accepts any other runReport field as JSON, for example {"keepEmptyRows":true} or comparisons. A key you set there replaces the same field set above it.
  • Run Realtime Report reports on the last 30 minutes of activity (60 minutes on GA4 360), for example active users by country. It uses the realtime dimensions and metrics, such as country, unifiedScreenName and activeUsers.
  • Run Pivot Report runs a pivot report. Supply the whole request as JSON: dimensions, metrics, date ranges and pivots.
  • Batch Run Reports and Batch Run Pivot Reports run 1 to 5 reports on one property in one step. Each returns one report per request, in order.
  • Check Compatibility lists the dimensions and metrics that can, or cannot, be added to a report alongside the ones you chose.
  • Get Metadata lists every dimension and metric the property reports on, including its custom ones.

Audience exports

  • Create Audience Export starts an export of the users currently in an audience. Pick the audience and the user fields to export, such as deviceId or userId. The export runs in the background.
  • Get Audience Export returns an export's state. Read its rows once the state is ACTIVE.
  • List Audience Exports lists the exports created on the property in the last 7 days.
  • Query Audience Export returns the user rows of an ACTIVE export, with a row limit and offset for paging.

Get and Query Audience Export take the export ID: the number at the end of the export's name, for example 456 from properties/123/audienceExports/456.

Accounts and properties

  • List Account Summaries lists every account the connection can see with its properties.
  • List Accounts, Get Account and Get Data Sharing Settings read the Google Analytics accounts.
  • List Properties, Get Property and Get Data Retention Settings read the GA4 properties of an account.
  • List Data Streams and Get Data Stream read a property's web and app streams, including a web stream's G- measurement ID.
  • List Key Events and Get Key Event read the property's key events, formerly called conversions.
  • List Custom Dimensions, Get Custom Dimension, List Custom Metrics and Get Custom Metric read the property's custom definitions.
  • List Google Ads Links and List Firebase Links read the property's product links.
  • List Measurement Protocol Secrets and Get Measurement Protocol Secret read a stream's Measurement Protocol API secrets. These need the Editor role on the property, and the run view hides each secret's value.
  • Run Account Access Report and Run Property Access Report report who read the data and when. These need the Administrator role.

The Get actions for data streams, key events, custom dimensions, custom metrics and secrets take the number at the end of the item's name, which the matching List action returns.

What a report returns

Report actions return Google's report as is: dimensionHeaders, metricHeaders, one entry in rows per dimension combination, and rowCount. Each row holds dimensionValues and metricValues in header order, and every metric value is a string:

{
  "dimensionHeaders": [{ "name": "date" }, { "name": "pagePath" }],
  "metricHeaders": [{ "name": "sessions", "type": "TYPE_INTEGER" }],
  "rows": [
    {
      "dimensionValues": [{ "value": "20261012" }, { "value": "/" }],
      "metricValues": [{ "value": "37" }]
    }
  ],
  "rowCount": 579
}

To turn rows into records such as { "page": "/", "sessions": 37 }, add a Transform step after the report. rowCount is the total number of rows for the query, not just the rows returned, so compare it with your limit to know when to page with Offset.

Send a weekly organic report

This workflow posts last week's top organic landing pages and Google search queries to Slack and appends them to a Google Sheet every Monday.

  1. Add a Schedule trigger

    Set it to run weekly on Monday at 8:00 in your client's time zone.

  2. Add Run Report

    Pick the client's property. Set Dimensions to landingPage and sessionDefaultChannelGroup, Metrics to sessions, Start Date to 7daysAgo and End Date to yesterday. Set Dimension Filter to keep organic traffic only:

    {
      "filter": {
        "fieldName": "sessionDefaultChannelGroup",
        "stringFilter": { "value": "Organic Search" }
      }
    }

    Set Order By to [{"metric":{"metricName":"sessions"},"desc":true}] and Limit to 25.

  3. Add Query Search Analytics

    From the Google Search Console app, pick the client's site, group by query, and set Row Limit to 25. Rows come back sorted by clicks.

  4. Reshape the rows

    Add a Transform step that turns each report's rows into records with the fields your message needs.

  5. Post and append

    Add a Slack message with the two lists, and a Google Sheets append that writes one row per page.

Errors

ErrorWhen it happens
INVALID_INPUTGoogle rejected the request: an unknown dimension or metric name, an incompatible combination, a bad date, or more than 5 batch requests.
AUTH_EXPIREDThe connection's Google access was revoked or has lapsed. Reconnect the account.
FORBIDDENThe connected account cannot see the property, or lacks the role an action needs (Editor for secrets, Administrator for access reports).
NOT_FOUNDThe property, export or item does not exist, for example a Get Audience Export on a property with no exports.
RATE_LIMITEDToo many requests, or the property's hourly or daily report quota is spent. TaskJuice retries with backoff.

Run Check Compatibility when Run Report fails with INVALID_INPUT on a dimension and metric combination.

Known limitations

  • There are no Google Analytics triggers. GA4 has no webhooks, and a "daily report ready" trigger is the Schedule trigger followed by Run Report. Alerting when a metric crosses a threshold is not available as a trigger; run the report on a schedule and add a Branch step that compares the value.
  • The connection is read-only. Creating or changing key events, custom dimensions, data streams, properties or links needs Google's edit permission, which this app does not request.
  • Sending events with the Measurement Protocol is not supported, because it uses a per-stream API secret rather than your Google sign-in. Use the HTTP Request node for it.
  • Report rows come back in Google's format. Reshape them with a Transform step.
  • Limit accepts up to 100,000 rows per step; page past that with Offset. Google also spends a token quota per property per day and per hour, so keep Limit as low as the report needs.
  • Realtime reports accept only the realtime dimensions and metrics, and only user-scoped custom dimensions.
  • Universal Analytics properties are not supported. Google shut Universal Analytics down; use the GA4 property.
Was this helpful?