Google Analytics · Schema

RealtimeData

Real time data for a given view (profile).

AnalyticsDataGoogleMetricsReportingWeb AnalyticsMachine LearningAttribution

Properties

Name Type Description
columnHeaders array Column headers that list dimension names followed by the metric names. The order of dimensions and metrics is same as specified in the request.
id string Unique ID for this data response.
kind string Resource type.
profileInfo object Information for the view (profile), for which the real time data was requested.
query object Real time data request query parameters.
rows array Real time data rows, where each row contains a list of dimension values followed by the metric values. The order of dimensions and metrics is same as specified in the request.
selfLink string Link to this page.
totalResults integer The total number of rows for the query, regardless of the number of rows in the response.
totalsForAllResults object Total values for the requested metrics over all the results, not just the results returned in this response. The order of the metric totals is same as the metric order specified in the request.
View JSON Schema on GitHub

JSON Schema

google-analytics-realtimedata-schema.json Raw ↑
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "#/components/schemas/RealtimeData",
  "title": "RealtimeData",
  "description": "Real time data for a given view (profile).",
  "properties": {
    "columnHeaders": {
      "description": "Column headers that list dimension names followed by the metric names. The order of dimensions and metrics is same as specified in the request.",
      "items": {
        "properties": {
          "columnType": {
            "description": "Column Type. Either DIMENSION or METRIC.",
            "type": "string"
          },
          "dataType": {
            "description": "Data type. Dimension column headers have only STRING as the data type. Metric column headers have data types for metric values such as INTEGER, DOUBLE, CURRENCY etc.",
            "type": "string"
          },
          "name": {
            "description": "Column name.",
            "type": "string"
          }
        },
        "type": "object"
      },
      "type": "array"
    },
    "id": {
      "description": "Unique ID for this data response.",
      "type": "string"
    },
    "kind": {
      "default": "analytics#realtimeData",
      "description": "Resource type.",
      "type": "string"
    },
    "profileInfo": {
      "description": "Information for the view (profile), for which the real time data was requested.",
      "properties": {
        "accountId": {
          "description": "Account ID to which this view (profile) belongs.",
          "type": "string"
        },
        "internalWebPropertyId": {
          "description": "Internal ID for the web property to which this view (profile) belongs.",
          "type": "string"
        },
        "profileId": {
          "description": "View (Profile) ID.",
          "type": "string"
        },
        "profileName": {
          "description": "View (Profile) name.",
          "type": "string"
        },
        "tableId": {
          "description": "Table ID for view (profile).",
          "type": "string"
        },
        "webPropertyId": {
          "description": "Web Property ID to which this view (profile) belongs.",
          "type": "string"
        }
      },
      "type": "object"
    },
    "query": {
      "description": "Real time data request query parameters.",
      "properties": {
        "dimensions": {
          "description": "List of real time dimensions.",
          "type": "string"
        },
        "filters": {
          "description": "Comma-separated list of dimension or metric filters.",
          "type": "string"
        },
        "ids": {
          "description": "Unique table ID.",
          "type": "string"
        },
        "max-results": {
          "description": "Maximum results per page.",
          "format": "int32",
          "type": "integer"
        },
        "metrics": {
          "description": "List of real time metrics.",
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "sort": {
          "description": "List of dimensions or metrics based on which real time data is sorted.",
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "type": "object"
    },
    "rows": {
      "description": "Real time data rows, where each row contains a list of dimension values followed by the metric values. The order of dimensions and metrics is same as specified in the request.",
      "items": {
        "items": {
          "type": "string"
        },
        "type": "array"
      },
      "type": "array"
    },
    "selfLink": {
      "description": "Link to this page.",
      "type": "string"
    },
    "totalResults": {
      "description": "The total number of rows for the query, regardless of the number of rows in the response.",
      "format": "int32",
      "type": "integer"
    },
    "totalsForAllResults": {
      "additionalProperties": {
        "description": "Key-value pair for the total value of a metric. Key is the metric name and the value is the total value for that metric.",
        "type": "string"
      },
      "description": "Total values for the requested metrics over all the results, not just the results returned in this response. The order of the metric totals is same as the metric order specified in the request.",
      "type": "object"
    }
  },
  "type": "object"
}