> ## Documentation Index
> Fetch the complete documentation index at: https://www.propeldata.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Types

> Object types in the Query API

<div />

## PageInfo

The page info object used for pagination.

<ParamField path="startCursor" type="String">
  Points to the first item returned in the results. Used when paginating backward.
</ParamField>

<ParamField path="endCursor" type="String">
  Points to the last item returned in the results. Used when paginating forward.
</ParamField>

<ParamField path="hasNextPage" type="Boolean" required>
  A boolean that indicates whether a next page of results exists. Can be used to display a "next page" button in user interfaces, for example.
</ParamField>

<ParamField path="hasPreviousPage" type="Boolean" required>
  A boolean that indicates whether a previous page of results exists. Can be used to display a "previous page" button in user interfaces, for example.
</ParamField>

## MetricReportConnection

The Metric Report connection object.

It includes `headers` and `rows` for a single page of a report. It also allows paging forward and backward to other
pages of the report.

<ParamField path="pageInfo" type="PageInfo" required>
  The report connection's page info.

  <Expandable title="PageInfo">
    The page info object used for pagination.

    <ParamField path="startCursor" type="String">
      Points to the first item returned in the results. Used when paginating backward.
    </ParamField>

    <ParamField path="endCursor" type="String">
      Points to the last item returned in the results. Used when paginating forward.
    </ParamField>

    <ParamField path="hasNextPage" type="Boolean" required>
      A boolean that indicates whether a next page of results exists. Can be used to display a "next page" button in user interfaces, for example.
    </ParamField>

    <ParamField path="hasPreviousPage" type="Boolean" required>
      A boolean that indicates whether a previous page of results exists. Can be used to display a "previous page" button in user interfaces, for example.
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="edges" type="[MetricReportEdge!]" required>
  The report connection's edges.

  <Expandable title="MetricReportEdge">
    The Metric Report edge object.

    <ParamField path="node" type="MetricReportNode" required>
      The edge's node.

      <Expandable title="MetricReportNode">
        The Metric Report node object.

        This type represents a single row of a report.

        <ParamField path="headers" type="[String]" required>
          An ordered array of display names for your dimensions and Metrics, as defined in the report input. Use this to display your table's header.
        </ParamField>

        <ParamField path="row" type="[String]" required>
          An ordered array of columns. Each column contains the dimension and Metric values for a single row, as defined in the report input. Use this to display a single row within your table.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="cursor" type="String" required>
      The edge's cursor.
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="nodes" type="[MetricReportNode!]" required>
  The report connection's nodes.

  <Expandable title="MetricReportNode">
    The Metric Report node object.

    This type represents a single row of a report.

    <ParamField path="headers" type="[String]" required>
      An ordered array of display names for your dimensions and Metrics, as defined in the report input. Use this to display your table's header.
    </ParamField>

    <ParamField path="row" type="[String]" required>
      An ordered array of columns. Each column contains the dimension and Metric values for a single row, as defined in the report input. Use this to display a single row within your table.
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="headers" type="[String]" required>
  An ordered array of display names for your dimensions and Metrics, as defined in the report input. Use this to display your table's header.
</ParamField>

<ParamField path="rows" type="[[String]!]" required>
  An ordered array of rows. Each row contains dimension and Metric values, as defined in the report input. Use these to display the rows of your table.
</ParamField>

<ParamField path="query" type="QueryInfo" required>
  The Query statistics and metadata.

  <Expandable title="QueryInfo">
    The Query Info object. It contains metadata and statistics about a Query performed.

    <ParamField path="id" type="ID" required>
      The Query's unique identifier.
    </ParamField>

    <ParamField path="createdAt" type="DateTime" required>
      The date and time in UTC when the Query was created.
    </ParamField>

    <ParamField path="createdBy" type="String" required>
      The unique identifier of the actor that performed the Query.
    </ParamField>

    <ParamField path="modifiedAt" type="DateTime" required>
      The date and time in UTC when the Query was last modified.
    </ParamField>

    <ParamField path="modifiedBy" type="String" required>
      The unique identifier of the actor that modified the Query.
    </ParamField>

    <ParamField path="bytesProcessed" type="String" required>
      The bytes processed by the Query.
    </ParamField>

    <ParamField path="durationInMilliseconds" type="Int" required>
      The duration of the Query in milliseconds.
    </ParamField>

    <ParamField path="recordsProcessed" type="String" required>
      The number of records processed by the Query.
    </ParamField>

    <ParamField path="resultingBytes" type="Int" required>
      The bytes returned by the Query.
    </ParamField>

    <ParamField path="resultingRecords" type="Int" required>
      The number of records returned by the Query.
    </ParamField>

    <ParamField path="propeller" type="Propeller">
      The Propeller used for this query.

      <Expandable title="Propeller">
        A Propeller determines your Application's query processing power. The larger the Propeller, the faster the queries and the higher the cost. Every Propel Application (and therefore every set of API credentials) has a Propeller that determines the speed and cost of queries.

        <ParamField path=" ">
          * `P1_X_SMALL`: Max records per second: 5,000,000 records per second
          * `P1_SMALL`: Max records per second: 25,000,000 records per second
          * `P1_MEDIUM`: Max records per second: 100,000,000 records per second
          * `P1_LARGE`: Max records per second: 250,000,000 records per second
          * `P1_X_LARGE`: Max records per second: 500,000,000 records per second
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="status" type="QueryStatus" required>
      The Query status.

      <Expandable title="QueryStatus">
        The Query status.

        <ParamField path=" ">
          * `COMPLETED`: The Query was completed succesfully.
          * `ERROR`: The Query experienced an error.
          * `TIMED_OUT`: The Query timed out.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="type" type="QueryType" required>
      The Query type.

      <Expandable title="QueryType">
        The Query type.

        <ParamField path=" ">
          * `METRIC`: Indicates a Metric Query.
          * `STATS`: Indicates a Dimension Stats Query.
          * `REPORT`: Indicates a Report Query.
          * `RECORDS`: Indicates a Record Table Query.
          * `RECORDS_BY_UNIQUE_ID`: Indicates records queried by unique ID.
          * `SQL`: Indicates a SQL Query.
          * `TOP_VALUES`: Indicates a Top Values Query.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="subtype" type="QuerySubtype">
      The Query subtype.

      <Expandable title="QuerySubtype">
        The Query subtype.

        <ParamField path=" ">
          * `COUNTER`: Indicates a Metric counter Query.
          * `TIME_SERIES`: Indicates a Metric time series Query.
          * `LEADERBOARD`: Indicates a Metric leaderboard Query.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="sql" type="String" required>
      The SQL the query executed.
    </ParamField>
  </Expandable>
</ParamField>

## MetricReportEdge

The Metric Report edge object.

<ParamField path="node" type="MetricReportNode" required>
  The edge's node.

  <Expandable title="MetricReportNode">
    The Metric Report node object.

    This type represents a single row of a report.

    <ParamField path="headers" type="[String]" required>
      An ordered array of display names for your dimensions and Metrics, as defined in the report input. Use this to display your table's header.
    </ParamField>

    <ParamField path="row" type="[String]" required>
      An ordered array of columns. Each column contains the dimension and Metric values for a single row, as defined in the report input. Use this to display a single row within your table.
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="cursor" type="String" required>
  The edge's cursor.
</ParamField>

## MetricReportNode

The Metric Report node object.

This type represents a single row of a report.

<ParamField path="headers" type="[String]" required>
  An ordered array of display names for your dimensions and Metrics, as defined in the report input. Use this to display your table's header.
</ParamField>

<ParamField path="row" type="[String]" required>
  An ordered array of columns. Each column contains the dimension and Metric values for a single row, as defined in the report input. Use this to display a single row within your table.
</ParamField>

## TimeSeriesResponse

The time series response object. It contains an array of time series labels and an array of Metric values for the given time range and Query Filters.

<ParamField path="labels" type="[String!]" required>
  The time series labels.
</ParamField>

<ParamField path="values" type="[String]" required>
  The time series values.
</ParamField>

<ParamField path="groups" type="[TimeSeriesResponseGroup!]">
  The time series values for each group in `groupBy`, if specified.

  <Expandable title="TimeSeriesResponseGroup">
    The time series response object for a group specified in `groupBy`. It contains an array of time series labels and an array of Metric values for a particular group.

    <ParamField path="group" type="[String]" required>
      The time series group's columns.
    </ParamField>

    <ParamField path="labels" type="[String!]" required>
      The time series group's labels.
    </ParamField>

    <ParamField path="values" type="[String]" required>
      The time series group's values.
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="query" type="QueryInfo" required>
  The Query statistics and metadata.

  <Expandable title="QueryInfo">
    The Query Info object. It contains metadata and statistics about a Query performed.

    <ParamField path="id" type="ID" required>
      The Query's unique identifier.
    </ParamField>

    <ParamField path="createdAt" type="DateTime" required>
      The date and time in UTC when the Query was created.
    </ParamField>

    <ParamField path="createdBy" type="String" required>
      The unique identifier of the actor that performed the Query.
    </ParamField>

    <ParamField path="modifiedAt" type="DateTime" required>
      The date and time in UTC when the Query was last modified.
    </ParamField>

    <ParamField path="modifiedBy" type="String" required>
      The unique identifier of the actor that modified the Query.
    </ParamField>

    <ParamField path="bytesProcessed" type="String" required>
      The bytes processed by the Query.
    </ParamField>

    <ParamField path="durationInMilliseconds" type="Int" required>
      The duration of the Query in milliseconds.
    </ParamField>

    <ParamField path="recordsProcessed" type="String" required>
      The number of records processed by the Query.
    </ParamField>

    <ParamField path="resultingBytes" type="Int" required>
      The bytes returned by the Query.
    </ParamField>

    <ParamField path="resultingRecords" type="Int" required>
      The number of records returned by the Query.
    </ParamField>

    <ParamField path="propeller" type="Propeller">
      The Propeller used for this query.

      <Expandable title="Propeller">
        A Propeller determines your Application's query processing power. The larger the Propeller, the faster the queries and the higher the cost. Every Propel Application (and therefore every set of API credentials) has a Propeller that determines the speed and cost of queries.

        <ParamField path=" ">
          * `P1_X_SMALL`: Max records per second: 5,000,000 records per second
          * `P1_SMALL`: Max records per second: 25,000,000 records per second
          * `P1_MEDIUM`: Max records per second: 100,000,000 records per second
          * `P1_LARGE`: Max records per second: 250,000,000 records per second
          * `P1_X_LARGE`: Max records per second: 500,000,000 records per second
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="status" type="QueryStatus" required>
      The Query status.

      <Expandable title="QueryStatus">
        The Query status.

        <ParamField path=" ">
          * `COMPLETED`: The Query was completed succesfully.
          * `ERROR`: The Query experienced an error.
          * `TIMED_OUT`: The Query timed out.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="type" type="QueryType" required>
      The Query type.

      <Expandable title="QueryType">
        The Query type.

        <ParamField path=" ">
          * `METRIC`: Indicates a Metric Query.
          * `STATS`: Indicates a Dimension Stats Query.
          * `REPORT`: Indicates a Report Query.
          * `RECORDS`: Indicates a Record Table Query.
          * `RECORDS_BY_UNIQUE_ID`: Indicates records queried by unique ID.
          * `SQL`: Indicates a SQL Query.
          * `TOP_VALUES`: Indicates a Top Values Query.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="subtype" type="QuerySubtype">
      The Query subtype.

      <Expandable title="QuerySubtype">
        The Query subtype.

        <ParamField path=" ">
          * `COUNTER`: Indicates a Metric counter Query.
          * `TIME_SERIES`: Indicates a Metric time series Query.
          * `LEADERBOARD`: Indicates a Metric leaderboard Query.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="sql" type="String" required>
      The SQL the query executed.
    </ParamField>
  </Expandable>
</ParamField>

## TimeSeriesResponseGroup

The time series response object for a group specified in `groupBy`. It contains an array of time series labels and an array of Metric values for a particular group.

<ParamField path="group" type="[String]" required>
  The time series group's columns.
</ParamField>

<ParamField path="labels" type="[String!]" required>
  The time series group's labels.
</ParamField>

<ParamField path="values" type="[String]" required>
  The time series group's values.
</ParamField>

## CounterResponse

The counter response object. It contains a single Metric value for the given time range and Query Filters.

<ParamField path="value" type="String">
  The value of the counter.
</ParamField>

<ParamField path="query" type="QueryInfo" required>
  The Query statistics and metadata.

  <Expandable title="QueryInfo">
    The Query Info object. It contains metadata and statistics about a Query performed.

    <ParamField path="id" type="ID" required>
      The Query's unique identifier.
    </ParamField>

    <ParamField path="createdAt" type="DateTime" required>
      The date and time in UTC when the Query was created.
    </ParamField>

    <ParamField path="createdBy" type="String" required>
      The unique identifier of the actor that performed the Query.
    </ParamField>

    <ParamField path="modifiedAt" type="DateTime" required>
      The date and time in UTC when the Query was last modified.
    </ParamField>

    <ParamField path="modifiedBy" type="String" required>
      The unique identifier of the actor that modified the Query.
    </ParamField>

    <ParamField path="bytesProcessed" type="String" required>
      The bytes processed by the Query.
    </ParamField>

    <ParamField path="durationInMilliseconds" type="Int" required>
      The duration of the Query in milliseconds.
    </ParamField>

    <ParamField path="recordsProcessed" type="String" required>
      The number of records processed by the Query.
    </ParamField>

    <ParamField path="resultingBytes" type="Int" required>
      The bytes returned by the Query.
    </ParamField>

    <ParamField path="resultingRecords" type="Int" required>
      The number of records returned by the Query.
    </ParamField>

    <ParamField path="propeller" type="Propeller">
      The Propeller used for this query.

      <Expandable title="Propeller">
        A Propeller determines your Application's query processing power. The larger the Propeller, the faster the queries and the higher the cost. Every Propel Application (and therefore every set of API credentials) has a Propeller that determines the speed and cost of queries.

        <ParamField path=" ">
          * `P1_X_SMALL`: Max records per second: 5,000,000 records per second
          * `P1_SMALL`: Max records per second: 25,000,000 records per second
          * `P1_MEDIUM`: Max records per second: 100,000,000 records per second
          * `P1_LARGE`: Max records per second: 250,000,000 records per second
          * `P1_X_LARGE`: Max records per second: 500,000,000 records per second
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="status" type="QueryStatus" required>
      The Query status.

      <Expandable title="QueryStatus">
        The Query status.

        <ParamField path=" ">
          * `COMPLETED`: The Query was completed succesfully.
          * `ERROR`: The Query experienced an error.
          * `TIMED_OUT`: The Query timed out.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="type" type="QueryType" required>
      The Query type.

      <Expandable title="QueryType">
        The Query type.

        <ParamField path=" ">
          * `METRIC`: Indicates a Metric Query.
          * `STATS`: Indicates a Dimension Stats Query.
          * `REPORT`: Indicates a Report Query.
          * `RECORDS`: Indicates a Record Table Query.
          * `RECORDS_BY_UNIQUE_ID`: Indicates records queried by unique ID.
          * `SQL`: Indicates a SQL Query.
          * `TOP_VALUES`: Indicates a Top Values Query.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="subtype" type="QuerySubtype">
      The Query subtype.

      <Expandable title="QuerySubtype">
        The Query subtype.

        <ParamField path=" ">
          * `COUNTER`: Indicates a Metric counter Query.
          * `TIME_SERIES`: Indicates a Metric time series Query.
          * `LEADERBOARD`: Indicates a Metric leaderboard Query.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="sql" type="String" required>
      The SQL the query executed.
    </ParamField>
  </Expandable>
</ParamField>

## LeaderboardResponse

The leaderboard response object. It contains an array of headers and a table (array of rows) with the selected Dimensions and corresponding Metric values for the given time range and Query Filters.

<ParamField path="headers" type="[String!]" required>
  The table headers. It contains the Dimension and Metric names.
</ParamField>

<ParamField path="rows" type="[[String]!]" required>
  An ordered array of rows. Each row contains the Dimension values and the corresponding Metric value. A Dimension value can be empty. A Metric value will never be empty.
</ParamField>

<ParamField path="query" type="QueryInfo" required>
  The Query statistics and metadata.

  <Expandable title="QueryInfo">
    The Query Info object. It contains metadata and statistics about a Query performed.

    <ParamField path="id" type="ID" required>
      The Query's unique identifier.
    </ParamField>

    <ParamField path="createdAt" type="DateTime" required>
      The date and time in UTC when the Query was created.
    </ParamField>

    <ParamField path="createdBy" type="String" required>
      The unique identifier of the actor that performed the Query.
    </ParamField>

    <ParamField path="modifiedAt" type="DateTime" required>
      The date and time in UTC when the Query was last modified.
    </ParamField>

    <ParamField path="modifiedBy" type="String" required>
      The unique identifier of the actor that modified the Query.
    </ParamField>

    <ParamField path="bytesProcessed" type="String" required>
      The bytes processed by the Query.
    </ParamField>

    <ParamField path="durationInMilliseconds" type="Int" required>
      The duration of the Query in milliseconds.
    </ParamField>

    <ParamField path="recordsProcessed" type="String" required>
      The number of records processed by the Query.
    </ParamField>

    <ParamField path="resultingBytes" type="Int" required>
      The bytes returned by the Query.
    </ParamField>

    <ParamField path="resultingRecords" type="Int" required>
      The number of records returned by the Query.
    </ParamField>

    <ParamField path="propeller" type="Propeller">
      The Propeller used for this query.

      <Expandable title="Propeller">
        A Propeller determines your Application's query processing power. The larger the Propeller, the faster the queries and the higher the cost. Every Propel Application (and therefore every set of API credentials) has a Propeller that determines the speed and cost of queries.

        <ParamField path=" ">
          * `P1_X_SMALL`: Max records per second: 5,000,000 records per second
          * `P1_SMALL`: Max records per second: 25,000,000 records per second
          * `P1_MEDIUM`: Max records per second: 100,000,000 records per second
          * `P1_LARGE`: Max records per second: 250,000,000 records per second
          * `P1_X_LARGE`: Max records per second: 500,000,000 records per second
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="status" type="QueryStatus" required>
      The Query status.

      <Expandable title="QueryStatus">
        The Query status.

        <ParamField path=" ">
          * `COMPLETED`: The Query was completed succesfully.
          * `ERROR`: The Query experienced an error.
          * `TIMED_OUT`: The Query timed out.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="type" type="QueryType" required>
      The Query type.

      <Expandable title="QueryType">
        The Query type.

        <ParamField path=" ">
          * `METRIC`: Indicates a Metric Query.
          * `STATS`: Indicates a Dimension Stats Query.
          * `REPORT`: Indicates a Report Query.
          * `RECORDS`: Indicates a Record Table Query.
          * `RECORDS_BY_UNIQUE_ID`: Indicates records queried by unique ID.
          * `SQL`: Indicates a SQL Query.
          * `TOP_VALUES`: Indicates a Top Values Query.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="subtype" type="QuerySubtype">
      The Query subtype.

      <Expandable title="QuerySubtype">
        The Query subtype.

        <ParamField path=" ">
          * `COUNTER`: Indicates a Metric counter Query.
          * `TIME_SERIES`: Indicates a Metric time series Query.
          * `LEADERBOARD`: Indicates a Metric leaderboard Query.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="sql" type="String" required>
      The SQL the query executed.
    </ParamField>
  </Expandable>
</ParamField>

## QueryInfo

The Query Info object. It contains metadata and statistics about a Query performed.

<ParamField path="id" type="ID" required>
  The Query's unique identifier.
</ParamField>

<ParamField path="createdAt" type="DateTime" required>
  The date and time in UTC when the Query was created.
</ParamField>

<ParamField path="createdBy" type="String" required>
  The unique identifier of the actor that performed the Query.
</ParamField>

<ParamField path="modifiedAt" type="DateTime" required>
  The date and time in UTC when the Query was last modified.
</ParamField>

<ParamField path="modifiedBy" type="String" required>
  The unique identifier of the actor that modified the Query.
</ParamField>

<ParamField path="bytesProcessed" type="String" required>
  The bytes processed by the Query.
</ParamField>

<ParamField path="durationInMilliseconds" type="Int" required>
  The duration of the Query in milliseconds.
</ParamField>

<ParamField path="recordsProcessed" type="String" required>
  The number of records processed by the Query.
</ParamField>

<ParamField path="resultingBytes" type="Int" required>
  The bytes returned by the Query.
</ParamField>

<ParamField path="resultingRecords" type="Int" required>
  The number of records returned by the Query.
</ParamField>

<ParamField path="propeller" type="Propeller">
  The Propeller used for this query.

  <Expandable title="Propeller">
    A Propeller determines your Application's query processing power. The larger the Propeller, the faster the queries and the higher the cost. Every Propel Application (and therefore every set of API credentials) has a Propeller that determines the speed and cost of queries.

    <ParamField path=" ">
      * `P1_X_SMALL`: Max records per second: 5,000,000 records per second
      * `P1_SMALL`: Max records per second: 25,000,000 records per second
      * `P1_MEDIUM`: Max records per second: 100,000,000 records per second
      * `P1_LARGE`: Max records per second: 250,000,000 records per second
      * `P1_X_LARGE`: Max records per second: 500,000,000 records per second
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="status" type="QueryStatus" required>
  The Query status.

  <Expandable title="QueryStatus">
    The Query status.

    <ParamField path=" ">
      * `COMPLETED`: The Query was completed succesfully.
      * `ERROR`: The Query experienced an error.
      * `TIMED_OUT`: The Query timed out.
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="type" type="QueryType" required>
  The Query type.

  <Expandable title="QueryType">
    The Query type.

    <ParamField path=" ">
      * `METRIC`: Indicates a Metric Query.
      * `STATS`: Indicates a Dimension Stats Query.
      * `REPORT`: Indicates a Report Query.
      * `RECORDS`: Indicates a Record Table Query.
      * `RECORDS_BY_UNIQUE_ID`: Indicates records queried by unique ID.
      * `SQL`: Indicates a SQL Query.
      * `TOP_VALUES`: Indicates a Top Values Query.
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="subtype" type="QuerySubtype">
  The Query subtype.

  <Expandable title="QuerySubtype">
    The Query subtype.

    <ParamField path=" ">
      * `COUNTER`: Indicates a Metric counter Query.
      * `TIME_SERIES`: Indicates a Metric time series Query.
      * `LEADERBOARD`: Indicates a Metric leaderboard Query.
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="sql" type="String" required>
  The SQL the query executed.
</ParamField>

## SqlColumnResponse

<ParamField path="columnName" type="String" required>
  The name of the returned column.
</ParamField>

<ParamField path="type" type="ColumnType" required>
  The returned column's type.

  <Expandable title="ColumnType">
    The Propel data types.

    <ParamField path=" ">
      * `BOOLEAN`: True or false.
      * `STRING`: A variable-length string.
      * `FLOAT`: A 32-bit signed double-precision floating point number.
      * `DOUBLE`: A 64-bit signed double-precision floating point number.
      * `INT8`: An 8-bit signed integer, with a minimum value of -2⁷ and a maximum value of 2⁷-1.
      * `INT16`: A 16-bit signed integer, with a minimum value of -2¹⁵ and a maximum value of 2¹⁵-1.
      * `INT32`: A 32-bit signed integer, with a minimum value of -2³¹ and a maximum value of 2³¹-1.
      * `INT64`: A 64-bit signed integer, with a minimum value of -2⁶³ and a maximum value of 2⁶³-1.
      * `DATE`: A date without a timestamp. For example, "YYYY-MM-DD".
      * `TIMESTAMP`: A date with a timestamp. For example, "yyy-MM-dd HH:mm:ss".
      * `JSON`: A JavaScript Object Notation (JSON) document.
      * `CLICKHOUSE`: A ClickHouse-specific type.
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="isNullable" type="Boolean" required>
  Whether the column is nullable, meaning whether it accepts a null value.
</ParamField>

## SqlResponse

Response from the SQL API.

<ParamField path="columns" type="[SqlColumnResponse!]" required>
  The column names in the same order as present in the `data` field.

  <Expandable title="SqlColumnResponse">
    <ParamField path="columnName" type="String" required>
      The name of the returned column.
    </ParamField>

    <ParamField path="type" type="ColumnType" required>
      The returned column's type.

      <Expandable title="ColumnType">
        The Propel data types.

        <ParamField path=" ">
          * `BOOLEAN`: True or false.
          * `STRING`: A variable-length string.
          * `FLOAT`: A 32-bit signed double-precision floating point number.
          * `DOUBLE`: A 64-bit signed double-precision floating point number.
          * `INT8`: An 8-bit signed integer, with a minimum value of -2⁷ and a maximum value of 2⁷-1.
          * `INT16`: A 16-bit signed integer, with a minimum value of -2¹⁵ and a maximum value of 2¹⁵-1.
          * `INT32`: A 32-bit signed integer, with a minimum value of -2³¹ and a maximum value of 2³¹-1.
          * `INT64`: A 64-bit signed integer, with a minimum value of -2⁶³ and a maximum value of 2⁶³-1.
          * `DATE`: A date without a timestamp. For example, "YYYY-MM-DD".
          * `TIMESTAMP`: A date with a timestamp. For example, "yyy-MM-dd HH:mm:ss".
          * `JSON`: A JavaScript Object Notation (JSON) document.
          * `CLICKHOUSE`: A ClickHouse-specific type.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="isNullable" type="Boolean" required>
      Whether the column is nullable, meaning whether it accepts a null value.
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="rows" type="[[String]!]" required>
  The data gathered by the SQL query. The data is returned in an N x M matrix format, where the
  first dimension are the rows retrieved, and the second dimension are the columns. Each cell
  can be either a string or null, and the string can represent a number, text, date or boolean value.
</ParamField>

<ParamField path="info" type="QueryInfo" required>
  The Query statistics and metadata.

  <Expandable title="QueryInfo">
    The Query Info object. It contains metadata and statistics about a Query performed.

    <ParamField path="id" type="ID" required>
      The Query's unique identifier.
    </ParamField>

    <ParamField path="createdAt" type="DateTime" required>
      The date and time in UTC when the Query was created.
    </ParamField>

    <ParamField path="createdBy" type="String" required>
      The unique identifier of the actor that performed the Query.
    </ParamField>

    <ParamField path="modifiedAt" type="DateTime" required>
      The date and time in UTC when the Query was last modified.
    </ParamField>

    <ParamField path="modifiedBy" type="String" required>
      The unique identifier of the actor that modified the Query.
    </ParamField>

    <ParamField path="bytesProcessed" type="String" required>
      The bytes processed by the Query.
    </ParamField>

    <ParamField path="durationInMilliseconds" type="Int" required>
      The duration of the Query in milliseconds.
    </ParamField>

    <ParamField path="recordsProcessed" type="String" required>
      The number of records processed by the Query.
    </ParamField>

    <ParamField path="resultingBytes" type="Int" required>
      The bytes returned by the Query.
    </ParamField>

    <ParamField path="resultingRecords" type="Int" required>
      The number of records returned by the Query.
    </ParamField>

    <ParamField path="propeller" type="Propeller">
      The Propeller used for this query.

      <Expandable title="Propeller">
        A Propeller determines your Application's query processing power. The larger the Propeller, the faster the queries and the higher the cost. Every Propel Application (and therefore every set of API credentials) has a Propeller that determines the speed and cost of queries.

        <ParamField path=" ">
          * `P1_X_SMALL`: Max records per second: 5,000,000 records per second
          * `P1_SMALL`: Max records per second: 25,000,000 records per second
          * `P1_MEDIUM`: Max records per second: 100,000,000 records per second
          * `P1_LARGE`: Max records per second: 250,000,000 records per second
          * `P1_X_LARGE`: Max records per second: 500,000,000 records per second
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="status" type="QueryStatus" required>
      The Query status.

      <Expandable title="QueryStatus">
        The Query status.

        <ParamField path=" ">
          * `COMPLETED`: The Query was completed succesfully.
          * `ERROR`: The Query experienced an error.
          * `TIMED_OUT`: The Query timed out.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="type" type="QueryType" required>
      The Query type.

      <Expandable title="QueryType">
        The Query type.

        <ParamField path=" ">
          * `METRIC`: Indicates a Metric Query.
          * `STATS`: Indicates a Dimension Stats Query.
          * `REPORT`: Indicates a Report Query.
          * `RECORDS`: Indicates a Record Table Query.
          * `RECORDS_BY_UNIQUE_ID`: Indicates records queried by unique ID.
          * `SQL`: Indicates a SQL Query.
          * `TOP_VALUES`: Indicates a Top Values Query.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="subtype" type="QuerySubtype">
      The Query subtype.

      <Expandable title="QuerySubtype">
        The Query subtype.

        <ParamField path=" ">
          * `COUNTER`: Indicates a Metric counter Query.
          * `TIME_SERIES`: Indicates a Metric time series Query.
          * `LEADERBOARD`: Indicates a Metric leaderboard Query.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="sql" type="String" required>
      The SQL the query executed.
    </ParamField>
  </Expandable>
</ParamField>

## DescribeSqlResponse

Response from the describe SQL API.

<ParamField path="columns" type="[SqlColumnResponse!]" required>
  The columns that the query would return.

  <Expandable title="SqlColumnResponse">
    <ParamField path="columnName" type="String" required>
      The name of the returned column.
    </ParamField>

    <ParamField path="type" type="ColumnType" required>
      The returned column's type.

      <Expandable title="ColumnType">
        The Propel data types.

        <ParamField path=" ">
          * `BOOLEAN`: True or false.
          * `STRING`: A variable-length string.
          * `FLOAT`: A 32-bit signed double-precision floating point number.
          * `DOUBLE`: A 64-bit signed double-precision floating point number.
          * `INT8`: An 8-bit signed integer, with a minimum value of -2⁷ and a maximum value of 2⁷-1.
          * `INT16`: A 16-bit signed integer, with a minimum value of -2¹⁵ and a maximum value of 2¹⁵-1.
          * `INT32`: A 32-bit signed integer, with a minimum value of -2³¹ and a maximum value of 2³¹-1.
          * `INT64`: A 64-bit signed integer, with a minimum value of -2⁶³ and a maximum value of 2⁶³-1.
          * `DATE`: A date without a timestamp. For example, "YYYY-MM-DD".
          * `TIMESTAMP`: A date with a timestamp. For example, "yyy-MM-dd HH:mm:ss".
          * `JSON`: A JavaScript Object Notation (JSON) document.
          * `CLICKHOUSE`: A ClickHouse-specific type.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="isNullable" type="Boolean" required>
      Whether the column is nullable, meaning whether it accepts a null value.
    </ParamField>
  </Expandable>
</ParamField>

## DataGridConnection

The Data Grid connection.

It includes `headers` and `rows` for a single page of a Data Grid table. It also allows paging forward and backward to other
pages of the Data Grid table.

<ParamField path="headers" type="[String!]" required>
  The Data Grid table's headers.
</ParamField>

<ParamField path="rows" type="[[String]!]" required>
  An array of arrays containing the values of the Data Grid table's rows.
</ParamField>

<ParamField path="query" type="QueryInfo" required>
  The Query statistics and metadata.

  <Expandable title="QueryInfo">
    The Query Info object. It contains metadata and statistics about a Query performed.

    <ParamField path="id" type="ID" required>
      The Query's unique identifier.
    </ParamField>

    <ParamField path="createdAt" type="DateTime" required>
      The date and time in UTC when the Query was created.
    </ParamField>

    <ParamField path="createdBy" type="String" required>
      The unique identifier of the actor that performed the Query.
    </ParamField>

    <ParamField path="modifiedAt" type="DateTime" required>
      The date and time in UTC when the Query was last modified.
    </ParamField>

    <ParamField path="modifiedBy" type="String" required>
      The unique identifier of the actor that modified the Query.
    </ParamField>

    <ParamField path="bytesProcessed" type="String" required>
      The bytes processed by the Query.
    </ParamField>

    <ParamField path="durationInMilliseconds" type="Int" required>
      The duration of the Query in milliseconds.
    </ParamField>

    <ParamField path="recordsProcessed" type="String" required>
      The number of records processed by the Query.
    </ParamField>

    <ParamField path="resultingBytes" type="Int" required>
      The bytes returned by the Query.
    </ParamField>

    <ParamField path="resultingRecords" type="Int" required>
      The number of records returned by the Query.
    </ParamField>

    <ParamField path="propeller" type="Propeller">
      The Propeller used for this query.

      <Expandable title="Propeller">
        A Propeller determines your Application's query processing power. The larger the Propeller, the faster the queries and the higher the cost. Every Propel Application (and therefore every set of API credentials) has a Propeller that determines the speed and cost of queries.

        <ParamField path=" ">
          * `P1_X_SMALL`: Max records per second: 5,000,000 records per second
          * `P1_SMALL`: Max records per second: 25,000,000 records per second
          * `P1_MEDIUM`: Max records per second: 100,000,000 records per second
          * `P1_LARGE`: Max records per second: 250,000,000 records per second
          * `P1_X_LARGE`: Max records per second: 500,000,000 records per second
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="status" type="QueryStatus" required>
      The Query status.

      <Expandable title="QueryStatus">
        The Query status.

        <ParamField path=" ">
          * `COMPLETED`: The Query was completed succesfully.
          * `ERROR`: The Query experienced an error.
          * `TIMED_OUT`: The Query timed out.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="type" type="QueryType" required>
      The Query type.

      <Expandable title="QueryType">
        The Query type.

        <ParamField path=" ">
          * `METRIC`: Indicates a Metric Query.
          * `STATS`: Indicates a Dimension Stats Query.
          * `REPORT`: Indicates a Report Query.
          * `RECORDS`: Indicates a Record Table Query.
          * `RECORDS_BY_UNIQUE_ID`: Indicates records queried by unique ID.
          * `SQL`: Indicates a SQL Query.
          * `TOP_VALUES`: Indicates a Top Values Query.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="subtype" type="QuerySubtype">
      The Query subtype.

      <Expandable title="QuerySubtype">
        The Query subtype.

        <ParamField path=" ">
          * `COUNTER`: Indicates a Metric counter Query.
          * `TIME_SERIES`: Indicates a Metric time series Query.
          * `LEADERBOARD`: Indicates a Metric leaderboard Query.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="sql" type="String" required>
      The SQL the query executed.
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="pageInfo" type="PageInfo" required>
  The Data Grid table's page info.

  <Expandable title="PageInfo">
    The page info object used for pagination.

    <ParamField path="startCursor" type="String">
      Points to the first item returned in the results. Used when paginating backward.
    </ParamField>

    <ParamField path="endCursor" type="String">
      Points to the last item returned in the results. Used when paginating forward.
    </ParamField>

    <ParamField path="hasNextPage" type="Boolean" required>
      A boolean that indicates whether a next page of results exists. Can be used to display a "next page" button in user interfaces, for example.
    </ParamField>

    <ParamField path="hasPreviousPage" type="Boolean" required>
      A boolean that indicates whether a previous page of results exists. Can be used to display a "previous page" button in user interfaces, for example.
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="edges" type="[DataGridEdge!]" required>
  The Data Grid table's edges.

  <Expandable title="DataGridEdge">
    The Data Grid edge object.

    <ParamField path="node" type="DataGridNode" required>
      The edge's node.

      <Expandable title="DataGridNode">
        The Data Grid table's node.

        This type represents a single row of a Data Grid table.

        <ParamField path="headers" type="[String!]" required>
          The Data Grid table's headers.
        </ParamField>

        <ParamField path="row" type="[String]" required>
          An array of the values for the row.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="cursor" type="String" required>
      The edge's cursor.
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="nodes" type="[DataGridNode!]" required>
  The Data Grid table's nodes.

  <Expandable title="DataGridNode">
    The Data Grid table's node.

    This type represents a single row of a Data Grid table.

    <ParamField path="headers" type="[String!]" required>
      The Data Grid table's headers.
    </ParamField>

    <ParamField path="row" type="[String]" required>
      An array of the values for the row.
    </ParamField>
  </Expandable>
</ParamField>

## DataGridEdge

The Data Grid edge object.

<ParamField path="node" type="DataGridNode" required>
  The edge's node.

  <Expandable title="DataGridNode">
    The Data Grid table's node.

    This type represents a single row of a Data Grid table.

    <ParamField path="headers" type="[String!]" required>
      The Data Grid table's headers.
    </ParamField>

    <ParamField path="row" type="[String]" required>
      An array of the values for the row.
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="cursor" type="String" required>
  The edge's cursor.
</ParamField>

## DataGridNode

The Data Grid table's node.

This type represents a single row of a Data Grid table.

<ParamField path="headers" type="[String!]" required>
  The Data Grid table's headers.
</ParamField>

<ParamField path="row" type="[String]" required>
  An array of the values for the row.
</ParamField>

## RecordsByUniqueIdResponse

<ParamField path="columns" type="[String!]" required>
  The Data Pool columns for the record.
</ParamField>

<ParamField path="values" type="[[String]!]" required>
  An array of values for the record.
</ParamField>

<ParamField path="query" type="QueryInfo" required>
  The Query statistics and metadata.

  <Expandable title="QueryInfo">
    The Query Info object. It contains metadata and statistics about a Query performed.

    <ParamField path="id" type="ID" required>
      The Query's unique identifier.
    </ParamField>

    <ParamField path="createdAt" type="DateTime" required>
      The date and time in UTC when the Query was created.
    </ParamField>

    <ParamField path="createdBy" type="String" required>
      The unique identifier of the actor that performed the Query.
    </ParamField>

    <ParamField path="modifiedAt" type="DateTime" required>
      The date and time in UTC when the Query was last modified.
    </ParamField>

    <ParamField path="modifiedBy" type="String" required>
      The unique identifier of the actor that modified the Query.
    </ParamField>

    <ParamField path="bytesProcessed" type="String" required>
      The bytes processed by the Query.
    </ParamField>

    <ParamField path="durationInMilliseconds" type="Int" required>
      The duration of the Query in milliseconds.
    </ParamField>

    <ParamField path="recordsProcessed" type="String" required>
      The number of records processed by the Query.
    </ParamField>

    <ParamField path="resultingBytes" type="Int" required>
      The bytes returned by the Query.
    </ParamField>

    <ParamField path="resultingRecords" type="Int" required>
      The number of records returned by the Query.
    </ParamField>

    <ParamField path="propeller" type="Propeller">
      The Propeller used for this query.

      <Expandable title="Propeller">
        A Propeller determines your Application's query processing power. The larger the Propeller, the faster the queries and the higher the cost. Every Propel Application (and therefore every set of API credentials) has a Propeller that determines the speed and cost of queries.

        <ParamField path=" ">
          * `P1_X_SMALL`: Max records per second: 5,000,000 records per second
          * `P1_SMALL`: Max records per second: 25,000,000 records per second
          * `P1_MEDIUM`: Max records per second: 100,000,000 records per second
          * `P1_LARGE`: Max records per second: 250,000,000 records per second
          * `P1_X_LARGE`: Max records per second: 500,000,000 records per second
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="status" type="QueryStatus" required>
      The Query status.

      <Expandable title="QueryStatus">
        The Query status.

        <ParamField path=" ">
          * `COMPLETED`: The Query was completed succesfully.
          * `ERROR`: The Query experienced an error.
          * `TIMED_OUT`: The Query timed out.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="type" type="QueryType" required>
      The Query type.

      <Expandable title="QueryType">
        The Query type.

        <ParamField path=" ">
          * `METRIC`: Indicates a Metric Query.
          * `STATS`: Indicates a Dimension Stats Query.
          * `REPORT`: Indicates a Report Query.
          * `RECORDS`: Indicates a Record Table Query.
          * `RECORDS_BY_UNIQUE_ID`: Indicates records queried by unique ID.
          * `SQL`: Indicates a SQL Query.
          * `TOP_VALUES`: Indicates a Top Values Query.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="subtype" type="QuerySubtype">
      The Query subtype.

      <Expandable title="QuerySubtype">
        The Query subtype.

        <ParamField path=" ">
          * `COUNTER`: Indicates a Metric counter Query.
          * `TIME_SERIES`: Indicates a Metric time series Query.
          * `LEADERBOARD`: Indicates a Metric leaderboard Query.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="sql" type="String" required>
      The SQL the query executed.
    </ParamField>
  </Expandable>
</ParamField>

## TopValuesResponse

<ParamField path="values" type="[String!]" required>
  An array with the list of values.
</ParamField>

<ParamField path="metricReport" type="MetricReportConnection">
  Build a report, or table, consisting of multiple Metrics broken down by one-or-more dimensions.

  The first few columns of the report are the dimensions you choose to break down by. The subsequent columns are the
  Metrics you choose to query. By default, the report sorts on the first Metric in descending order, but you can
  configure this with the `orderByMetric` and `sort` inputs.

  Finally, reports use cursor-based pagination. You can control page size with the `first` and
  `last` inputs.

  ### Arguments

  <ParamField notPatch path="input" type="MetricReportInput" required>
    <Expandable title="MetricReportInput">
      The fields for querying a Metric Report.

      A Metric Report is a table whose columns include dimensions and Metric values, calculated over a given time range.

      <ParamField path="timeRange" type="TimeRangeInput">
        The time range for calculating the Metric Report.

        <Expandable title="TimeRangeInput">
          The fields required to specify the time range for a time series, counter, or leaderboard Metric query.

          If no relative or absolute time ranges are provided, Propel defaults to an absolute time range beginning with the earliest record in the Metric's Data Pool and ending with the latest record.

          If both relative and absolute time ranges are provided, the relative time range will take precedence.

          If a `LAST_N` relative time period is selected, an `n` ≥ 1 must be provided. If no `n` is provided or `n` \< 1, a `BAD_REQUEST` error will be returned.

          <ParamField path="timestamp" type="String">
            The timestamp field to use when querying. Defaults to the timestamp configured on the Data Pool or Metric, if any.
            Set this to filter on an alternative timestamp field.
          </ParamField>

          <ParamField path="relative" type="RelativeTimeRange">
            The relative time period.

            See <a href="/docs/query-apis/api-reference/enums#relativetimerange">RelativeTimeRange</a>
          </ParamField>

          <ParamField path="n" type="Int">
            The number of time units for the `LAST_N` relative periods.
          </ParamField>

          <ParamField path="start" type="DateTime">
            The optional start timestamp (inclusive). Defaults to the timestamp of the earliest record in the Data Pool.
          </ParamField>

          <ParamField path="stop" type="DateTime">
            The optional end timestamp (exclusive). Defaults to the timestamp of the latest record in the Data Pool.
          </ParamField>
        </Expandable>
      </ParamField>

      <ParamField path="timeZone" type="String">
        The time zone to use. Dates and times are always returned in UTC, but setting the time zone influences relative time ranges and granularities.

        You can set this to "America/Los\_Angeles", "Europe/Berlin", or any other value in the [IANA time zone database](https://en.wikipedia.org/wiki/Tz_database). Defaults to "UTC".
      </ParamField>

      <ParamField path="dimensions" type="[MetricReportDimensionInput!]" required>
        One or many dimensions to group the Metric values by. Typically, dimensions in a report are what you want to compare and rank.

        <Expandable title="MetricReportDimensionInput">
          The fields for specifying a dimension to include in a Metric Report.

          <ParamField path="columnName" type="String" required>
            The column name of the dimension to include in a Metric Report. This must match the name of a Data Pool column.
          </ParamField>

          <ParamField path="displayName" type="String">
            The name to display in the `headers` array when displaying the report. This defaults to the column name if unspecified.
          </ParamField>

          <ParamField path="sort" type="Sort">
            The sort order for the dimension. It can be ascending (`ASC`) or descending (`DESC`) order. Defaults to ascending (`ASC`) order when not provided.

            See <a href="/docs/query-apis/api-reference/enums#sort">Sort</a>
          </ParamField>
        </Expandable>
      </ParamField>

      <ParamField path="metrics" type="[MetricReportMetricInput!]" required>
        One or more Metrics to include in the Metric Report. These will be broken down by `dimensions`.

        <Expandable title="MetricReportMetricInput">
          The fields for specifying a Metric to include in a Metric Report.

          <ParamField path="metric" type="MetricInput">
            The Metric to query. You can query a pre-configured Metric by ID or name, or you can query an ad hoc Metric that you define inline.

            See <a href="/docs/query-apis/api-reference/inputs#metricinput">MetricInput</a>
          </ParamField>

          <ParamField path="displayName" type="String">
            The name to display in the `headers` array when displaying the report. This defaults to the Metric's unique name if unspecified.
          </ParamField>

          <ParamField path="filterSql" type="String">
            The Query Filters to apply when calculating the Metric, in the form of SQL.
          </ParamField>

          <ParamField path="sort" type="Sort">
            The sort order for the Metric. It can be ascending (`ASC`) or descending (`DESC`) order. Defaults to descending (`DESC`) order when not provided.

            See <a href="/docs/query-apis/api-reference/enums#sort">Sort</a>
          </ParamField>

          <Expandable title="Deprecated Fields">
            <ParamField path="uniqueName" type="String" deprecated>
              The Metric's unique name. If not specified, Propel will lookup the Metric by ID.

              <span style={{ fontStyle: 'italic' }}>deprecated: Use `metric`</span>
            </ParamField>

            <ParamField path="id" type="ID" deprecated>
              The Metric's ID. If not specified, Propel will lookup the Metric by unique name.

              <span style={{ fontStyle: 'italic' }}>deprecated: Use `metric`</span>
            </ParamField>

            <ParamField path="filters" type="[FilterInput!]" deprecated>
              The Query Filters to apply when calculating the Metric.

              <span style={{ fontStyle: 'italic' }}>deprecated: Use `filterSql` instead</span>

              See <a href="/docs/query-apis/api-reference/inputs#filterinput">FilterInput</a>
            </ParamField>
          </Expandable>
        </Expandable>
      </ParamField>

      <ParamField path="filterSql" type="String">
        The Query Filters to apply when building the Metric Report, in the form of SQL. These can be used to filter out rows.
      </ParamField>

      <ParamField path="orderByColumn" type="Int">
        The index of the column to order the Metric Report by. The index is 1-based and defaults to the first Metric column. In other words, by default, reports are ordered by the first Metric; however, you can order by the second Metric, third Metric, etc., by overriding the `orderByColumn` input. You can also order by dimensions this way.
      </ParamField>

      <ParamField path="first" type="Int">
        The number of rows to be returned when paging forward. It can be a number between 1 and 1,000.
      </ParamField>

      <ParamField path="after" type="String">
        The cursor to use when paging forward.
      </ParamField>

      <ParamField path="last" type="Int">
        The number of rows to be returned when paging forward. It can be a number between 1 and 1,000.
      </ParamField>

      <ParamField path="before" type="String">
        The cursor to use when paging backward.
      </ParamField>

      <Expandable title="Deprecated Fields">
        <ParamField path="filters" type="[FilterInput!]" deprecated>
          The Query Filters to apply when building the Metric Report. These can be used to filter out rows.

          <span style={{ fontStyle: 'italic' }}>deprecated: Use `filterSql` instead</span>

          <Expandable title="FilterInput">
            The fields of a filter.

            You can construct more complex filters using `and` and `or`. For example, to construct a filter equivalent to

            ```
            (value > 0 AND value <= 100) OR status = "confirmed"
            ```

            you could write

            ```
            {
              "column": "value",
              "operator": "GREATER_THAN",
              "value": "0",
              "and": [{
                "column": "value",
                "operator": "LESS_THAN_OR_EQUAL_TO",
                "value": "0"
              }],
              "or": [{
                "column": "status",
                "operator": "EQUALS",
                "value": "confirmed"
              }]
            }
            ```

            Note that `and` takes precedence over `or`.

            <ParamField path="column" type="String" required>
              The name of the column to filter on.
            </ParamField>

            <ParamField path="operator" type="FilterOperator" required>
              The operation to perform when comparing the column and filter values.

              See <a href="/docs/query-apis/api-reference/enums#filteroperator">FilterOperator</a>
            </ParamField>

            <ParamField path="value" type="String">
              The value to compare the column to.
            </ParamField>

            <ParamField path="and" type="[FilterInput!]">
              Additional filters to AND with this one. AND takes precedence over OR.
            </ParamField>

            <ParamField path="or" type="[FilterInput!]">
              Additional filters to OR with this one. AND takes precedence over OR.
            </ParamField>
          </Expandable>
        </ParamField>
      </Expandable>
    </Expandable>
  </ParamField>

  <Expandable title="MetricReportConnection">
    The Metric Report connection object.

    It includes `headers` and `rows` for a single page of a report. It also allows paging forward and backward to other
    pages of the report.

    <ParamField path="pageInfo" type="PageInfo" required>
      The report connection's page info.

      <Expandable title="PageInfo">
        The page info object used for pagination.

        <ParamField path="startCursor" type="String">
          Points to the first item returned in the results. Used when paginating backward.
        </ParamField>

        <ParamField path="endCursor" type="String">
          Points to the last item returned in the results. Used when paginating forward.
        </ParamField>

        <ParamField path="hasNextPage" type="Boolean" required>
          A boolean that indicates whether a next page of results exists. Can be used to display a "next page" button in user interfaces, for example.
        </ParamField>

        <ParamField path="hasPreviousPage" type="Boolean" required>
          A boolean that indicates whether a previous page of results exists. Can be used to display a "previous page" button in user interfaces, for example.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="edges" type="[MetricReportEdge!]" required>
      The report connection's edges.

      <Expandable title="MetricReportEdge">
        The Metric Report edge object.

        <ParamField path="node" type="MetricReportNode" required>
          The edge's node.

          See <a href="/docs/query-apis/api-reference/types#metricreportnode">MetricReportNode</a>
        </ParamField>

        <ParamField path="cursor" type="String" required>
          The edge's cursor.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="nodes" type="[MetricReportNode!]" required>
      The report connection's nodes.

      <Expandable title="MetricReportNode">
        The Metric Report node object.

        This type represents a single row of a report.

        <ParamField path="headers" type="[String]" required>
          An ordered array of display names for your dimensions and Metrics, as defined in the report input. Use this to display your table's header.
        </ParamField>

        <ParamField path="row" type="[String]" required>
          An ordered array of columns. Each column contains the dimension and Metric values for a single row, as defined in the report input. Use this to display a single row within your table.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="headers" type="[String]" required>
      An ordered array of display names for your dimensions and Metrics, as defined in the report input. Use this to display your table's header.
    </ParamField>

    <ParamField path="rows" type="[[String]!]" required>
      An ordered array of rows. Each row contains dimension and Metric values, as defined in the report input. Use these to display the rows of your table.
    </ParamField>

    <ParamField path="query" type="QueryInfo" required>
      The Query statistics and metadata.

      <Expandable title="QueryInfo">
        The Query Info object. It contains metadata and statistics about a Query performed.

        <ParamField path="id" type="ID" required>
          The Query's unique identifier.
        </ParamField>

        <ParamField path="createdAt" type="DateTime" required>
          The date and time in UTC when the Query was created.
        </ParamField>

        <ParamField path="createdBy" type="String" required>
          The unique identifier of the actor that performed the Query.
        </ParamField>

        <ParamField path="modifiedAt" type="DateTime" required>
          The date and time in UTC when the Query was last modified.
        </ParamField>

        <ParamField path="modifiedBy" type="String" required>
          The unique identifier of the actor that modified the Query.
        </ParamField>

        <ParamField path="bytesProcessed" type="String" required>
          The bytes processed by the Query.
        </ParamField>

        <ParamField path="durationInMilliseconds" type="Int" required>
          The duration of the Query in milliseconds.
        </ParamField>

        <ParamField path="recordsProcessed" type="String" required>
          The number of records processed by the Query.
        </ParamField>

        <ParamField path="resultingBytes" type="Int" required>
          The bytes returned by the Query.
        </ParamField>

        <ParamField path="resultingRecords" type="Int" required>
          The number of records returned by the Query.
        </ParamField>

        <ParamField path="propeller" type="Propeller">
          The Propeller used for this query.

          See <a href="/docs/query-apis/api-reference/enums#propeller">Propeller</a>
        </ParamField>

        <ParamField path="status" type="QueryStatus" required>
          The Query status.

          See <a href="/docs/query-apis/api-reference/enums#querystatus">QueryStatus</a>
        </ParamField>

        <ParamField path="type" type="QueryType" required>
          The Query type.

          See <a href="/docs/query-apis/api-reference/enums#querytype">QueryType</a>
        </ParamField>

        <ParamField path="subtype" type="QuerySubtype">
          The Query subtype.

          See <a href="/docs/query-apis/api-reference/enums#querysubtype">QuerySubtype</a>
        </ParamField>

        <ParamField path="sql" type="String" required>
          The SQL the query executed.
        </ParamField>
      </Expandable>
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="sqlV1" type="SqlResponse" required>
  Query Data Pools using SQL.

  ### Arguments

  <ParamField notPatch path="input" type="SqlV1Input" required>
    <Expandable title="SqlV1Input">
      Input to the SqlV1 api.

      <ParamField path="query" type="String" required>
        The SQL query.
      </ParamField>

      <ParamField path="dialect" type="SqlDialectV1">
        The SQL dialect to use. If not provided, the query is parsed on a best-effort basis.

        <Expandable title="SqlDialectV1">
          The SQL dialect to use when parsing queries.

          <ParamField path=" ">
            * `POSTGRESQL`: Parse as PostgreSQL-compatible SQL.
            * `CLICKHOUSE`: Parse as ClickHouse-compatible SQL.
          </ParamField>
        </Expandable>
      </ParamField>
    </Expandable>
  </ParamField>

  <Expandable title="SqlResponse">
    Response from the SQL API.

    <ParamField path="columns" type="[SqlColumnResponse!]" required>
      The column names in the same order as present in the `data` field.

      <Expandable title="SqlColumnResponse">
        <ParamField path="columnName" type="String" required>
          The name of the returned column.
        </ParamField>

        <ParamField path="type" type="ColumnType" required>
          The returned column's type.

          See <a href="/docs/query-apis/api-reference/enums#columntype">ColumnType</a>
        </ParamField>

        <ParamField path="isNullable" type="Boolean" required>
          Whether the column is nullable, meaning whether it accepts a null value.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="rows" type="[[String]!]" required>
      The data gathered by the SQL query. The data is returned in an N x M matrix format, where the
      first dimension are the rows retrieved, and the second dimension are the columns. Each cell
      can be either a string or null, and the string can represent a number, text, date or boolean value.
    </ParamField>

    <ParamField path="info" type="QueryInfo" required>
      The Query statistics and metadata.

      <Expandable title="QueryInfo">
        The Query Info object. It contains metadata and statistics about a Query performed.

        <ParamField path="id" type="ID" required>
          The Query's unique identifier.
        </ParamField>

        <ParamField path="createdAt" type="DateTime" required>
          The date and time in UTC when the Query was created.
        </ParamField>

        <ParamField path="createdBy" type="String" required>
          The unique identifier of the actor that performed the Query.
        </ParamField>

        <ParamField path="modifiedAt" type="DateTime" required>
          The date and time in UTC when the Query was last modified.
        </ParamField>

        <ParamField path="modifiedBy" type="String" required>
          The unique identifier of the actor that modified the Query.
        </ParamField>

        <ParamField path="bytesProcessed" type="String" required>
          The bytes processed by the Query.
        </ParamField>

        <ParamField path="durationInMilliseconds" type="Int" required>
          The duration of the Query in milliseconds.
        </ParamField>

        <ParamField path="recordsProcessed" type="String" required>
          The number of records processed by the Query.
        </ParamField>

        <ParamField path="resultingBytes" type="Int" required>
          The bytes returned by the Query.
        </ParamField>

        <ParamField path="resultingRecords" type="Int" required>
          The number of records returned by the Query.
        </ParamField>

        <ParamField path="propeller" type="Propeller">
          The Propeller used for this query.

          See <a href="/docs/query-apis/api-reference/enums#propeller">Propeller</a>
        </ParamField>

        <ParamField path="status" type="QueryStatus" required>
          The Query status.

          See <a href="/docs/query-apis/api-reference/enums#querystatus">QueryStatus</a>
        </ParamField>

        <ParamField path="type" type="QueryType" required>
          The Query type.

          See <a href="/docs/query-apis/api-reference/enums#querytype">QueryType</a>
        </ParamField>

        <ParamField path="subtype" type="QuerySubtype">
          The Query subtype.

          See <a href="/docs/query-apis/api-reference/enums#querysubtype">QuerySubtype</a>
        </ParamField>

        <ParamField path="sql" type="String" required>
          The SQL the query executed.
        </ParamField>
      </Expandable>
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="describeSqlV1" type="DescribeSqlResponse" required>
  Describe SQL statements Data Pools.

  ### Arguments

  <ParamField notPatch path="input" type="DescribeSqlV1Input" required>
    <Expandable title="DescribeSqlV1Input">
      Input for describing SqlV1 inputs.

      <ParamField path="query" type="String" required>
        The SQL query.
      </ParamField>

      <ParamField path="dialect" type="SqlDialectV1">
        The SQL dialect to use. If not provided, the query is parsed on a best-effort basis.

        <Expandable title="SqlDialectV1">
          The SQL dialect to use when parsing queries.

          <ParamField path=" ">
            * `POSTGRESQL`: Parse as PostgreSQL-compatible SQL.
            * `CLICKHOUSE`: Parse as ClickHouse-compatible SQL.
          </ParamField>
        </Expandable>
      </ParamField>
    </Expandable>
  </ParamField>

  <Expandable title="DescribeSqlResponse">
    Response from the describe SQL API.

    <ParamField path="columns" type="[SqlColumnResponse!]" required>
      The columns that the query would return.

      <Expandable title="SqlColumnResponse">
        <ParamField path="columnName" type="String" required>
          The name of the returned column.
        </ParamField>

        <ParamField path="type" type="ColumnType" required>
          The returned column's type.

          See <a href="/docs/query-apis/api-reference/enums#columntype">ColumnType</a>
        </ParamField>

        <ParamField path="isNullable" type="Boolean" required>
          Whether the column is nullable, meaning whether it accepts a null value.
        </ParamField>
      </Expandable>
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="dataGrid" type="DataGridConnection" required>
  Returns the individual records of a Data Pool with the convenience of built-in pagination, filtering, and sorting.

  ### Arguments

  <ParamField notPatch path="input" type="DataGridInput" required>
    <Expandable title="DataGridInput">
      The fields for querying Data Grid records.

      <ParamField path="dataPool" type="DataPoolInput" required>
        The Data Pool to be queried.

        <Expandable title="DataPoolInput">
          <ParamField path="id" type="ID">
            The ID of the Data Pool.
          </ParamField>

          <ParamField path="name" type="String">
            The name of the Data Pool.
          </ParamField>
        </Expandable>
      </ParamField>

      <ParamField path="timeRange" type="TimeRangeInput">
        The time range for retrieving the records.

        <Expandable title="TimeRangeInput">
          The fields required to specify the time range for a time series, counter, or leaderboard Metric query.

          If no relative or absolute time ranges are provided, Propel defaults to an absolute time range beginning with the earliest record in the Metric's Data Pool and ending with the latest record.

          If both relative and absolute time ranges are provided, the relative time range will take precedence.

          If a `LAST_N` relative time period is selected, an `n` ≥ 1 must be provided. If no `n` is provided or `n` \< 1, a `BAD_REQUEST` error will be returned.

          <ParamField path="timestamp" type="String">
            The timestamp field to use when querying. Defaults to the timestamp configured on the Data Pool or Metric, if any.
            Set this to filter on an alternative timestamp field.
          </ParamField>

          <ParamField path="relative" type="RelativeTimeRange">
            The relative time period.

            See <a href="/docs/query-apis/api-reference/enums#relativetimerange">RelativeTimeRange</a>
          </ParamField>

          <ParamField path="n" type="Int">
            The number of time units for the `LAST_N` relative periods.
          </ParamField>

          <ParamField path="start" type="DateTime">
            The optional start timestamp (inclusive). Defaults to the timestamp of the earliest record in the Data Pool.
          </ParamField>

          <ParamField path="stop" type="DateTime">
            The optional end timestamp (exclusive). Defaults to the timestamp of the latest record in the Data Pool.
          </ParamField>
        </Expandable>
      </ParamField>

      <ParamField path="timeZone" type="String">
        The time zone to use. Dates and times are always returned in UTC, but setting the time zone influences relative time ranges and granularities.

        You can set this to "America/Los\_Angeles", "Europe/Berlin", or any other value in the [IANA time zone database](https://en.wikipedia.org/wiki/Tz_database). Defaults to "UTC".
      </ParamField>

      <ParamField path="columns" type="[String!]" required>
        The columns to retrieve.
      </ParamField>

      <ParamField path="orderByColumn" type="Int">
        The index of the column to order the table by. The index is 1-based. If not provided, records will be ordered by their timestamp by default.
      </ParamField>

      <ParamField path="sort" type="Sort">
        The sort order of the rows. It can be ascending (`ASC`) or descending (`DESC`) order. Defaults to descending (`DESC`) order when not provided.

        <Expandable title="Sort">
          The available sort orders.

          <ParamField path=" ">
            * `ASC`: Sort in ascending order.
            * `DESC`: Sort in descending order.
          </ParamField>
        </Expandable>
      </ParamField>

      <ParamField path="filterSql" type="String">
        The filters to apply to the records, in the form of SQL. You may only filter on columns included in the `columns` array input.
      </ParamField>

      <ParamField path="first" type="Int">
        The number of rows to be returned when paging forward. It can be a number between 1 and 1,000.
      </ParamField>

      <ParamField path="after" type="String">
        The cursor to use when paging forward.
      </ParamField>

      <ParamField path="last" type="Int">
        The number of rows to be returned when paging forward. It can be a number between 1 and 1,000.
      </ParamField>

      <ParamField path="before" type="String">
        The cursor to use when paging backward.
      </ParamField>

      <Expandable title="Deprecated Fields">
        <ParamField path="filters" type="[FilterInput!]" deprecated>
          The filters to apply to the records. You may only filter on columns included in the `columns` array input.

          <span style={{ fontStyle: 'italic' }}>deprecated: Use `filterSql` instead</span>

          <Expandable title="FilterInput">
            The fields of a filter.

            You can construct more complex filters using `and` and `or`. For example, to construct a filter equivalent to

            ```
            (value > 0 AND value <= 100) OR status = "confirmed"
            ```

            you could write

            ```
            {
              "column": "value",
              "operator": "GREATER_THAN",
              "value": "0",
              "and": [{
                "column": "value",
                "operator": "LESS_THAN_OR_EQUAL_TO",
                "value": "0"
              }],
              "or": [{
                "column": "status",
                "operator": "EQUALS",
                "value": "confirmed"
              }]
            }
            ```

            Note that `and` takes precedence over `or`.

            <ParamField path="column" type="String" required>
              The name of the column to filter on.
            </ParamField>

            <ParamField path="operator" type="FilterOperator" required>
              The operation to perform when comparing the column and filter values.

              See <a href="/docs/query-apis/api-reference/enums#filteroperator">FilterOperator</a>
            </ParamField>

            <ParamField path="value" type="String">
              The value to compare the column to.
            </ParamField>

            <ParamField path="and" type="[FilterInput!]">
              Additional filters to AND with this one. AND takes precedence over OR.
            </ParamField>

            <ParamField path="or" type="[FilterInput!]">
              Additional filters to OR with this one. AND takes precedence over OR.
            </ParamField>
          </Expandable>
        </ParamField>
      </Expandable>
    </Expandable>
  </ParamField>

  <Expandable title="DataGridConnection">
    The Data Grid connection.

    It includes `headers` and `rows` for a single page of a Data Grid table. It also allows paging forward and backward to other
    pages of the Data Grid table.

    <ParamField path="headers" type="[String!]" required>
      The Data Grid table's headers.
    </ParamField>

    <ParamField path="rows" type="[[String]!]" required>
      An array of arrays containing the values of the Data Grid table's rows.
    </ParamField>

    <ParamField path="query" type="QueryInfo" required>
      The Query statistics and metadata.

      <Expandable title="QueryInfo">
        The Query Info object. It contains metadata and statistics about a Query performed.

        <ParamField path="id" type="ID" required>
          The Query's unique identifier.
        </ParamField>

        <ParamField path="createdAt" type="DateTime" required>
          The date and time in UTC when the Query was created.
        </ParamField>

        <ParamField path="createdBy" type="String" required>
          The unique identifier of the actor that performed the Query.
        </ParamField>

        <ParamField path="modifiedAt" type="DateTime" required>
          The date and time in UTC when the Query was last modified.
        </ParamField>

        <ParamField path="modifiedBy" type="String" required>
          The unique identifier of the actor that modified the Query.
        </ParamField>

        <ParamField path="bytesProcessed" type="String" required>
          The bytes processed by the Query.
        </ParamField>

        <ParamField path="durationInMilliseconds" type="Int" required>
          The duration of the Query in milliseconds.
        </ParamField>

        <ParamField path="recordsProcessed" type="String" required>
          The number of records processed by the Query.
        </ParamField>

        <ParamField path="resultingBytes" type="Int" required>
          The bytes returned by the Query.
        </ParamField>

        <ParamField path="resultingRecords" type="Int" required>
          The number of records returned by the Query.
        </ParamField>

        <ParamField path="propeller" type="Propeller">
          The Propeller used for this query.

          See <a href="/docs/query-apis/api-reference/enums#propeller">Propeller</a>
        </ParamField>

        <ParamField path="status" type="QueryStatus" required>
          The Query status.

          See <a href="/docs/query-apis/api-reference/enums#querystatus">QueryStatus</a>
        </ParamField>

        <ParamField path="type" type="QueryType" required>
          The Query type.

          See <a href="/docs/query-apis/api-reference/enums#querytype">QueryType</a>
        </ParamField>

        <ParamField path="subtype" type="QuerySubtype">
          The Query subtype.

          See <a href="/docs/query-apis/api-reference/enums#querysubtype">QuerySubtype</a>
        </ParamField>

        <ParamField path="sql" type="String" required>
          The SQL the query executed.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="pageInfo" type="PageInfo" required>
      The Data Grid table's page info.

      <Expandable title="PageInfo">
        The page info object used for pagination.

        <ParamField path="startCursor" type="String">
          Points to the first item returned in the results. Used when paginating backward.
        </ParamField>

        <ParamField path="endCursor" type="String">
          Points to the last item returned in the results. Used when paginating forward.
        </ParamField>

        <ParamField path="hasNextPage" type="Boolean" required>
          A boolean that indicates whether a next page of results exists. Can be used to display a "next page" button in user interfaces, for example.
        </ParamField>

        <ParamField path="hasPreviousPage" type="Boolean" required>
          A boolean that indicates whether a previous page of results exists. Can be used to display a "previous page" button in user interfaces, for example.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="edges" type="[DataGridEdge!]" required>
      The Data Grid table's edges.

      <Expandable title="DataGridEdge">
        The Data Grid edge object.

        <ParamField path="node" type="DataGridNode" required>
          The edge's node.

          See <a href="/docs/query-apis/api-reference/types#datagridnode">DataGridNode</a>
        </ParamField>

        <ParamField path="cursor" type="String" required>
          The edge's cursor.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="nodes" type="[DataGridNode!]" required>
      The Data Grid table's nodes.

      <Expandable title="DataGridNode">
        The Data Grid table's node.

        This type represents a single row of a Data Grid table.

        <ParamField path="headers" type="[String!]" required>
          The Data Grid table's headers.
        </ParamField>

        <ParamField path="row" type="[String]" required>
          An array of the values for the row.
        </ParamField>
      </Expandable>
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="recordsByUniqueId" type="RecordsByUniqueIdResponse" required>
  Returns records by the given unique IDs.

  ### Arguments

  <ParamField notPatch path="input" type="RecordsByUniqueIdInput" required>
    <Expandable title="RecordsByUniqueIdInput">
      The fields for querying records by unique ID.

      <ParamField path="dataPool" type="DataPoolInput" required>
        The Data Pool to be queried. A Data Pool ID or unique name can be provided.

        <Expandable title="DataPoolInput">
          <ParamField path="id" type="ID">
            The ID of the Data Pool.
          </ParamField>

          <ParamField path="name" type="String">
            The name of the Data Pool.
          </ParamField>
        </Expandable>
      </ParamField>

      <ParamField path="columns" type="[String!]" required>
        The columns to retrieve.
      </ParamField>

      <ParamField path="uniqueIds" type="[String!]" required>
        The unique IDs of the records to retrieve.
      </ParamField>
    </Expandable>
  </ParamField>

  <Expandable title="RecordsByUniqueIdResponse">
    <ParamField path="columns" type="[String!]" required>
      The Data Pool columns for the record.
    </ParamField>

    <ParamField path="values" type="[[String]!]" required>
      An array of values for the record.
    </ParamField>

    <ParamField path="query" type="QueryInfo" required>
      The Query statistics and metadata.

      <Expandable title="QueryInfo">
        The Query Info object. It contains metadata and statistics about a Query performed.

        <ParamField path="id" type="ID" required>
          The Query's unique identifier.
        </ParamField>

        <ParamField path="createdAt" type="DateTime" required>
          The date and time in UTC when the Query was created.
        </ParamField>

        <ParamField path="createdBy" type="String" required>
          The unique identifier of the actor that performed the Query.
        </ParamField>

        <ParamField path="modifiedAt" type="DateTime" required>
          The date and time in UTC when the Query was last modified.
        </ParamField>

        <ParamField path="modifiedBy" type="String" required>
          The unique identifier of the actor that modified the Query.
        </ParamField>

        <ParamField path="bytesProcessed" type="String" required>
          The bytes processed by the Query.
        </ParamField>

        <ParamField path="durationInMilliseconds" type="Int" required>
          The duration of the Query in milliseconds.
        </ParamField>

        <ParamField path="recordsProcessed" type="String" required>
          The number of records processed by the Query.
        </ParamField>

        <ParamField path="resultingBytes" type="Int" required>
          The bytes returned by the Query.
        </ParamField>

        <ParamField path="resultingRecords" type="Int" required>
          The number of records returned by the Query.
        </ParamField>

        <ParamField path="propeller" type="Propeller">
          The Propeller used for this query.

          See <a href="/docs/query-apis/api-reference/enums#propeller">Propeller</a>
        </ParamField>

        <ParamField path="status" type="QueryStatus" required>
          The Query status.

          See <a href="/docs/query-apis/api-reference/enums#querystatus">QueryStatus</a>
        </ParamField>

        <ParamField path="type" type="QueryType" required>
          The Query type.

          See <a href="/docs/query-apis/api-reference/enums#querytype">QueryType</a>
        </ParamField>

        <ParamField path="subtype" type="QuerySubtype">
          The Query subtype.

          See <a href="/docs/query-apis/api-reference/enums#querysubtype">QuerySubtype</a>
        </ParamField>

        <ParamField path="sql" type="String" required>
          The SQL the query executed.
        </ParamField>
      </Expandable>
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="topValues" type="TopValuesResponse" required>
  Returns an array of the most frequent values in a given column. The resulting array is sorted in descending order of approximate frequency of values.

  ### Arguments

  <ParamField notPatch path="input" type="TopValuesInput" required>
    <Expandable title="TopValuesInput">
      The fields for querying the top values in a given column.

      <ParamField path="dataPool" type="DataPoolInput" required>
        The Data Pool to be queried. A Data Pool ID or unique name can be provided.

        <Expandable title="DataPoolInput">
          <ParamField path="id" type="ID">
            The ID of the Data Pool.
          </ParamField>

          <ParamField path="name" type="String">
            The name of the Data Pool.
          </ParamField>
        </Expandable>
      </ParamField>

      <ParamField path="columnName" type="String" required>
        The column to fetch the unique values from.
      </ParamField>

      <ParamField path="timeRange" type="TimeRangeInput">
        The time range for calculating the top values.

        <Expandable title="TimeRangeInput">
          The fields required to specify the time range for a time series, counter, or leaderboard Metric query.

          If no relative or absolute time ranges are provided, Propel defaults to an absolute time range beginning with the earliest record in the Metric's Data Pool and ending with the latest record.

          If both relative and absolute time ranges are provided, the relative time range will take precedence.

          If a `LAST_N` relative time period is selected, an `n` ≥ 1 must be provided. If no `n` is provided or `n` \< 1, a `BAD_REQUEST` error will be returned.

          <ParamField path="timestamp" type="String">
            The timestamp field to use when querying. Defaults to the timestamp configured on the Data Pool or Metric, if any.
            Set this to filter on an alternative timestamp field.
          </ParamField>

          <ParamField path="relative" type="RelativeTimeRange">
            The relative time period.

            See <a href="/docs/query-apis/api-reference/enums#relativetimerange">RelativeTimeRange</a>
          </ParamField>

          <ParamField path="n" type="Int">
            The number of time units for the `LAST_N` relative periods.
          </ParamField>

          <ParamField path="start" type="DateTime">
            The optional start timestamp (inclusive). Defaults to the timestamp of the earliest record in the Data Pool.
          </ParamField>

          <ParamField path="stop" type="DateTime">
            The optional end timestamp (exclusive). Defaults to the timestamp of the latest record in the Data Pool.
          </ParamField>
        </Expandable>
      </ParamField>

      <ParamField path="timeZone" type="String">
        The time zone to use. Dates and times are always returned in UTC, but setting the time zone influences relative time ranges and granularities.

        You can set this to "America/Los\_Angeles", "Europe/Berlin", or any other value in the [IANA time zone database](https://en.wikipedia.org/wiki/Tz_database). Defaults to "UTC".
      </ParamField>

      <ParamField path="maxValues" type="Int">
        The maximum number of values to return. It can be a number between 1 and 1,000. If the parameter is omitted, default value 10 is used.
      </ParamField>
    </Expandable>
  </ParamField>

  <Expandable title="TopValuesResponse">
    <ParamField path="values" type="[String!]" required>
      An array with the list of values.
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="counter" type="CounterResponse">
  Query a metric in counter format. Returns a single metric value for the given time range and filters.

  ### Arguments

  <ParamField notPatch path="input" type="CounterInput" required>
    <Expandable title="CounterInput">
      The fields for querying a Metric in counter format.

      A Metric's counter query returns a single value over a given time range.

      <ParamField path="metric" type="MetricInput">
        The Metric to query. You can query a pre-configured Metric by ID or name, or you can query an ad hoc Metric that you define inline.

        <Expandable title="MetricInput">
          <ParamField path="id" type="ID">
            The ID of a pre-configured Metric.
          </ParamField>

          <ParamField path="name" type="String">
            The name of a pre-configured Metric.
          </ParamField>

          <ParamField path="custom" type="CustomMetricQueryInput">
            An ad hoc Custom Metric.

            See <a href="/docs/query-apis/api-reference/inputs#custommetricqueryinput">CustomMetricQueryInput</a>
          </ParamField>

          <ParamField path="count" type="CountMetricQueryInput">
            An ad hoc Count Metric.

            See <a href="/docs/query-apis/api-reference/inputs#countmetricqueryinput">CountMetricQueryInput</a>
          </ParamField>

          <ParamField path="sum" type="SumMetricQueryInput">
            An ad hoc Sum Metric.

            See <a href="/docs/query-apis/api-reference/inputs#summetricqueryinput">SumMetricQueryInput</a>
          </ParamField>

          <ParamField path="average" type="AverageMetricQueryInput">
            An ad hoc Average Metric.

            See <a href="/docs/query-apis/api-reference/inputs#averagemetricqueryinput">AverageMetricQueryInput</a>
          </ParamField>

          <ParamField path="min" type="MinMetricQueryInput">
            An ad hoc Min Metric.

            See <a href="/docs/query-apis/api-reference/inputs#minmetricqueryinput">MinMetricQueryInput</a>
          </ParamField>

          <ParamField path="max" type="MaxMetricQueryInput">
            An ad hoc Max Metric.

            See <a href="/docs/query-apis/api-reference/inputs#maxmetricqueryinput">MaxMetricQueryInput</a>
          </ParamField>

          <ParamField path="countDistinct" type="CountDistinctMetricQueryInput">
            An ad hoc Count Distinct Metric.

            See <a href="/docs/query-apis/api-reference/inputs#countdistinctmetricqueryinput">CountDistinctMetricQueryInput</a>
          </ParamField>
        </Expandable>
      </ParamField>

      <ParamField path="timeRange" type="TimeRangeInput">
        The time range for calculating the counter.

        <Expandable title="TimeRangeInput">
          The fields required to specify the time range for a time series, counter, or leaderboard Metric query.

          If no relative or absolute time ranges are provided, Propel defaults to an absolute time range beginning with the earliest record in the Metric's Data Pool and ending with the latest record.

          If both relative and absolute time ranges are provided, the relative time range will take precedence.

          If a `LAST_N` relative time period is selected, an `n` ≥ 1 must be provided. If no `n` is provided or `n` \< 1, a `BAD_REQUEST` error will be returned.

          <ParamField path="timestamp" type="String">
            The timestamp field to use when querying. Defaults to the timestamp configured on the Data Pool or Metric, if any.
            Set this to filter on an alternative timestamp field.
          </ParamField>

          <ParamField path="relative" type="RelativeTimeRange">
            The relative time period.

            See <a href="/docs/query-apis/api-reference/enums#relativetimerange">RelativeTimeRange</a>
          </ParamField>

          <ParamField path="n" type="Int">
            The number of time units for the `LAST_N` relative periods.
          </ParamField>

          <ParamField path="start" type="DateTime">
            The optional start timestamp (inclusive). Defaults to the timestamp of the earliest record in the Data Pool.
          </ParamField>

          <ParamField path="stop" type="DateTime">
            The optional end timestamp (exclusive). Defaults to the timestamp of the latest record in the Data Pool.
          </ParamField>
        </Expandable>
      </ParamField>

      <ParamField path="timeZone" type="String">
        The time zone to use. Dates and times are always returned in UTC, but setting the time zone influences relative time ranges and granularities.

        You can set this to "America/Los\_Angeles", "Europe/Berlin", or any other value in the [IANA time zone database](https://en.wikipedia.org/wiki/Tz_database). Defaults to "UTC".
      </ParamField>

      <ParamField path="filterSql" type="String">
        The Query Filters to apply before retrieving the counter data, in the form of SQL. If no Query Filters are provided, all data is included.
      </ParamField>

      <Expandable title="Deprecated Fields">
        <ParamField path="metricId" type="ID" deprecated>
          The ID of the Metric to query.

          Required if `metricName` is not specified.

          <span style={{ fontStyle: 'italic' }}>deprecated: Use `metric`</span>
        </ParamField>

        <ParamField path="metricName" type="String" deprecated>
          The name of the Metric to query.

          Required if `metricId` is not specified.

          <span style={{ fontStyle: 'italic' }}>deprecated: Use `metric`</span>
        </ParamField>

        <ParamField path="filters" type="[FilterInput!]" deprecated>
          The Query Filters to apply before retrieving the counter data. If no Query Filters are provided, all data is included.

          <span style={{ fontStyle: 'italic' }}>deprecated: Use `filterSql` instead</span>

          <Expandable title="FilterInput">
            The fields of a filter.

            You can construct more complex filters using `and` and `or`. For example, to construct a filter equivalent to

            ```
            (value > 0 AND value <= 100) OR status = "confirmed"
            ```

            you could write

            ```
            {
              "column": "value",
              "operator": "GREATER_THAN",
              "value": "0",
              "and": [{
                "column": "value",
                "operator": "LESS_THAN_OR_EQUAL_TO",
                "value": "0"
              }],
              "or": [{
                "column": "status",
                "operator": "EQUALS",
                "value": "confirmed"
              }]
            }
            ```

            Note that `and` takes precedence over `or`.

            <ParamField path="column" type="String" required>
              The name of the column to filter on.
            </ParamField>

            <ParamField path="operator" type="FilterOperator" required>
              The operation to perform when comparing the column and filter values.

              See <a href="/docs/query-apis/api-reference/enums#filteroperator">FilterOperator</a>
            </ParamField>

            <ParamField path="value" type="String">
              The value to compare the column to.
            </ParamField>

            <ParamField path="and" type="[FilterInput!]">
              Additional filters to AND with this one. AND takes precedence over OR.
            </ParamField>

            <ParamField path="or" type="[FilterInput!]">
              Additional filters to OR with this one. AND takes precedence over OR.
            </ParamField>
          </Expandable>
        </ParamField>
      </Expandable>
    </Expandable>
  </ParamField>

  <Expandable title="CounterResponse">
    The counter response object. It contains a single Metric value for the given time range and Query Filters.

    <ParamField path="value" type="String">
      The value of the counter.
    </ParamField>

    <ParamField path="query" type="QueryInfo" required>
      The Query statistics and metadata.

      <Expandable title="QueryInfo">
        The Query Info object. It contains metadata and statistics about a Query performed.

        <ParamField path="id" type="ID" required>
          The Query's unique identifier.
        </ParamField>

        <ParamField path="createdAt" type="DateTime" required>
          The date and time in UTC when the Query was created.
        </ParamField>

        <ParamField path="createdBy" type="String" required>
          The unique identifier of the actor that performed the Query.
        </ParamField>

        <ParamField path="modifiedAt" type="DateTime" required>
          The date and time in UTC when the Query was last modified.
        </ParamField>

        <ParamField path="modifiedBy" type="String" required>
          The unique identifier of the actor that modified the Query.
        </ParamField>

        <ParamField path="bytesProcessed" type="String" required>
          The bytes processed by the Query.
        </ParamField>

        <ParamField path="durationInMilliseconds" type="Int" required>
          The duration of the Query in milliseconds.
        </ParamField>

        <ParamField path="recordsProcessed" type="String" required>
          The number of records processed by the Query.
        </ParamField>

        <ParamField path="resultingBytes" type="Int" required>
          The bytes returned by the Query.
        </ParamField>

        <ParamField path="resultingRecords" type="Int" required>
          The number of records returned by the Query.
        </ParamField>

        <ParamField path="propeller" type="Propeller">
          The Propeller used for this query.

          See <a href="/docs/query-apis/api-reference/enums#propeller">Propeller</a>
        </ParamField>

        <ParamField path="status" type="QueryStatus" required>
          The Query status.

          See <a href="/docs/query-apis/api-reference/enums#querystatus">QueryStatus</a>
        </ParamField>

        <ParamField path="type" type="QueryType" required>
          The Query type.

          See <a href="/docs/query-apis/api-reference/enums#querytype">QueryType</a>
        </ParamField>

        <ParamField path="subtype" type="QuerySubtype">
          The Query subtype.

          See <a href="/docs/query-apis/api-reference/enums#querysubtype">QuerySubtype</a>
        </ParamField>

        <ParamField path="sql" type="String" required>
          The SQL the query executed.
        </ParamField>
      </Expandable>
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="counters" type="[CounterResponse]" required>
  Query metrics in counter format. Returns a metric value for each input in the array of inputs.

  ### Arguments

  <ParamField notPatch path="input" type="[CounterInput!]" required>
    <Expandable title="[CounterInput!]">
      The fields for querying a Metric in counter format.

      A Metric's counter query returns a single value over a given time range.

      <ParamField path="metric" type="MetricInput">
        The Metric to query. You can query a pre-configured Metric by ID or name, or you can query an ad hoc Metric that you define inline.

        <Expandable title="MetricInput">
          <ParamField path="id" type="ID">
            The ID of a pre-configured Metric.
          </ParamField>

          <ParamField path="name" type="String">
            The name of a pre-configured Metric.
          </ParamField>

          <ParamField path="custom" type="CustomMetricQueryInput">
            An ad hoc Custom Metric.

            See <a href="/docs/query-apis/api-reference/inputs#custommetricqueryinput">CustomMetricQueryInput</a>
          </ParamField>

          <ParamField path="count" type="CountMetricQueryInput">
            An ad hoc Count Metric.

            See <a href="/docs/query-apis/api-reference/inputs#countmetricqueryinput">CountMetricQueryInput</a>
          </ParamField>

          <ParamField path="sum" type="SumMetricQueryInput">
            An ad hoc Sum Metric.

            See <a href="/docs/query-apis/api-reference/inputs#summetricqueryinput">SumMetricQueryInput</a>
          </ParamField>

          <ParamField path="average" type="AverageMetricQueryInput">
            An ad hoc Average Metric.

            See <a href="/docs/query-apis/api-reference/inputs#averagemetricqueryinput">AverageMetricQueryInput</a>
          </ParamField>

          <ParamField path="min" type="MinMetricQueryInput">
            An ad hoc Min Metric.

            See <a href="/docs/query-apis/api-reference/inputs#minmetricqueryinput">MinMetricQueryInput</a>
          </ParamField>

          <ParamField path="max" type="MaxMetricQueryInput">
            An ad hoc Max Metric.

            See <a href="/docs/query-apis/api-reference/inputs#maxmetricqueryinput">MaxMetricQueryInput</a>
          </ParamField>

          <ParamField path="countDistinct" type="CountDistinctMetricQueryInput">
            An ad hoc Count Distinct Metric.

            See <a href="/docs/query-apis/api-reference/inputs#countdistinctmetricqueryinput">CountDistinctMetricQueryInput</a>
          </ParamField>
        </Expandable>
      </ParamField>

      <ParamField path="timeRange" type="TimeRangeInput">
        The time range for calculating the counter.

        <Expandable title="TimeRangeInput">
          The fields required to specify the time range for a time series, counter, or leaderboard Metric query.

          If no relative or absolute time ranges are provided, Propel defaults to an absolute time range beginning with the earliest record in the Metric's Data Pool and ending with the latest record.

          If both relative and absolute time ranges are provided, the relative time range will take precedence.

          If a `LAST_N` relative time period is selected, an `n` ≥ 1 must be provided. If no `n` is provided or `n` \< 1, a `BAD_REQUEST` error will be returned.

          <ParamField path="timestamp" type="String">
            The timestamp field to use when querying. Defaults to the timestamp configured on the Data Pool or Metric, if any.
            Set this to filter on an alternative timestamp field.
          </ParamField>

          <ParamField path="relative" type="RelativeTimeRange">
            The relative time period.

            See <a href="/docs/query-apis/api-reference/enums#relativetimerange">RelativeTimeRange</a>
          </ParamField>

          <ParamField path="n" type="Int">
            The number of time units for the `LAST_N` relative periods.
          </ParamField>

          <ParamField path="start" type="DateTime">
            The optional start timestamp (inclusive). Defaults to the timestamp of the earliest record in the Data Pool.
          </ParamField>

          <ParamField path="stop" type="DateTime">
            The optional end timestamp (exclusive). Defaults to the timestamp of the latest record in the Data Pool.
          </ParamField>
        </Expandable>
      </ParamField>

      <ParamField path="timeZone" type="String">
        The time zone to use. Dates and times are always returned in UTC, but setting the time zone influences relative time ranges and granularities.

        You can set this to "America/Los\_Angeles", "Europe/Berlin", or any other value in the [IANA time zone database](https://en.wikipedia.org/wiki/Tz_database). Defaults to "UTC".
      </ParamField>

      <ParamField path="filterSql" type="String">
        The Query Filters to apply before retrieving the counter data, in the form of SQL. If no Query Filters are provided, all data is included.
      </ParamField>

      <Expandable title="Deprecated Fields">
        <ParamField path="metricId" type="ID" deprecated>
          The ID of the Metric to query.

          Required if `metricName` is not specified.

          <span style={{ fontStyle: 'italic' }}>deprecated: Use `metric`</span>
        </ParamField>

        <ParamField path="metricName" type="String" deprecated>
          The name of the Metric to query.

          Required if `metricId` is not specified.

          <span style={{ fontStyle: 'italic' }}>deprecated: Use `metric`</span>
        </ParamField>

        <ParamField path="filters" type="[FilterInput!]" deprecated>
          The Query Filters to apply before retrieving the counter data. If no Query Filters are provided, all data is included.

          <span style={{ fontStyle: 'italic' }}>deprecated: Use `filterSql` instead</span>

          <Expandable title="FilterInput">
            The fields of a filter.

            You can construct more complex filters using `and` and `or`. For example, to construct a filter equivalent to

            ```
            (value > 0 AND value <= 100) OR status = "confirmed"
            ```

            you could write

            ```
            {
              "column": "value",
              "operator": "GREATER_THAN",
              "value": "0",
              "and": [{
                "column": "value",
                "operator": "LESS_THAN_OR_EQUAL_TO",
                "value": "0"
              }],
              "or": [{
                "column": "status",
                "operator": "EQUALS",
                "value": "confirmed"
              }]
            }
            ```

            Note that `and` takes precedence over `or`.

            <ParamField path="column" type="String" required>
              The name of the column to filter on.
            </ParamField>

            <ParamField path="operator" type="FilterOperator" required>
              The operation to perform when comparing the column and filter values.

              See <a href="/docs/query-apis/api-reference/enums#filteroperator">FilterOperator</a>
            </ParamField>

            <ParamField path="value" type="String">
              The value to compare the column to.
            </ParamField>

            <ParamField path="and" type="[FilterInput!]">
              Additional filters to AND with this one. AND takes precedence over OR.
            </ParamField>

            <ParamField path="or" type="[FilterInput!]">
              Additional filters to OR with this one. AND takes precedence over OR.
            </ParamField>
          </Expandable>
        </ParamField>
      </Expandable>
    </Expandable>
  </ParamField>

  <Expandable title="CounterResponse">
    The counter response object. It contains a single Metric value for the given time range and Query Filters.

    <ParamField path="value" type="String">
      The value of the counter.
    </ParamField>

    <ParamField path="query" type="QueryInfo" required>
      The Query statistics and metadata.

      <Expandable title="QueryInfo">
        The Query Info object. It contains metadata and statistics about a Query performed.

        <ParamField path="id" type="ID" required>
          The Query's unique identifier.
        </ParamField>

        <ParamField path="createdAt" type="DateTime" required>
          The date and time in UTC when the Query was created.
        </ParamField>

        <ParamField path="createdBy" type="String" required>
          The unique identifier of the actor that performed the Query.
        </ParamField>

        <ParamField path="modifiedAt" type="DateTime" required>
          The date and time in UTC when the Query was last modified.
        </ParamField>

        <ParamField path="modifiedBy" type="String" required>
          The unique identifier of the actor that modified the Query.
        </ParamField>

        <ParamField path="bytesProcessed" type="String" required>
          The bytes processed by the Query.
        </ParamField>

        <ParamField path="durationInMilliseconds" type="Int" required>
          The duration of the Query in milliseconds.
        </ParamField>

        <ParamField path="recordsProcessed" type="String" required>
          The number of records processed by the Query.
        </ParamField>

        <ParamField path="resultingBytes" type="Int" required>
          The bytes returned by the Query.
        </ParamField>

        <ParamField path="resultingRecords" type="Int" required>
          The number of records returned by the Query.
        </ParamField>

        <ParamField path="propeller" type="Propeller">
          The Propeller used for this query.

          See <a href="/docs/query-apis/api-reference/enums#propeller">Propeller</a>
        </ParamField>

        <ParamField path="status" type="QueryStatus" required>
          The Query status.

          See <a href="/docs/query-apis/api-reference/enums#querystatus">QueryStatus</a>
        </ParamField>

        <ParamField path="type" type="QueryType" required>
          The Query type.

          See <a href="/docs/query-apis/api-reference/enums#querytype">QueryType</a>
        </ParamField>

        <ParamField path="subtype" type="QuerySubtype">
          The Query subtype.

          See <a href="/docs/query-apis/api-reference/enums#querysubtype">QuerySubtype</a>
        </ParamField>

        <ParamField path="sql" type="String" required>
          The SQL the query executed.
        </ParamField>
      </Expandable>
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="timeSeries" type="TimeSeriesResponse">
  Query a metric in time series format. Returns arrays of timestamps and metric values for the given time range and filters.

  ### Arguments

  <ParamField notPatch path="input" type="TimeSeriesInput" required>
    <Expandable title="TimeSeriesInput">
      The fields for querying a Metric in time series format.

      A Metric's time series query returns the values over a given time range aggregated by a given time granularity; day, month, or year, for example.

      <ParamField path="metric" type="MetricInput">
        The Metric to Query. It can be a pre-created one or it can be inlined here.

        <Expandable title="MetricInput">
          <ParamField path="id" type="ID">
            The ID of a pre-configured Metric.
          </ParamField>

          <ParamField path="name" type="String">
            The name of a pre-configured Metric.
          </ParamField>

          <ParamField path="custom" type="CustomMetricQueryInput">
            An ad hoc Custom Metric.

            See <a href="/docs/query-apis/api-reference/inputs#custommetricqueryinput">CustomMetricQueryInput</a>
          </ParamField>

          <ParamField path="count" type="CountMetricQueryInput">
            An ad hoc Count Metric.

            See <a href="/docs/query-apis/api-reference/inputs#countmetricqueryinput">CountMetricQueryInput</a>
          </ParamField>

          <ParamField path="sum" type="SumMetricQueryInput">
            An ad hoc Sum Metric.

            See <a href="/docs/query-apis/api-reference/inputs#summetricqueryinput">SumMetricQueryInput</a>
          </ParamField>

          <ParamField path="average" type="AverageMetricQueryInput">
            An ad hoc Average Metric.

            See <a href="/docs/query-apis/api-reference/inputs#averagemetricqueryinput">AverageMetricQueryInput</a>
          </ParamField>

          <ParamField path="min" type="MinMetricQueryInput">
            An ad hoc Min Metric.

            See <a href="/docs/query-apis/api-reference/inputs#minmetricqueryinput">MinMetricQueryInput</a>
          </ParamField>

          <ParamField path="max" type="MaxMetricQueryInput">
            An ad hoc Max Metric.

            See <a href="/docs/query-apis/api-reference/inputs#maxmetricqueryinput">MaxMetricQueryInput</a>
          </ParamField>

          <ParamField path="countDistinct" type="CountDistinctMetricQueryInput">
            An ad hoc Count Distinct Metric.

            See <a href="/docs/query-apis/api-reference/inputs#countdistinctmetricqueryinput">CountDistinctMetricQueryInput</a>
          </ParamField>
        </Expandable>
      </ParamField>

      <ParamField path="timeRange" type="TimeRangeInput">
        The time range for calculating the time series.

        <Expandable title="TimeRangeInput">
          The fields required to specify the time range for a time series, counter, or leaderboard Metric query.

          If no relative or absolute time ranges are provided, Propel defaults to an absolute time range beginning with the earliest record in the Metric's Data Pool and ending with the latest record.

          If both relative and absolute time ranges are provided, the relative time range will take precedence.

          If a `LAST_N` relative time period is selected, an `n` ≥ 1 must be provided. If no `n` is provided or `n` \< 1, a `BAD_REQUEST` error will be returned.

          <ParamField path="timestamp" type="String">
            The timestamp field to use when querying. Defaults to the timestamp configured on the Data Pool or Metric, if any.
            Set this to filter on an alternative timestamp field.
          </ParamField>

          <ParamField path="relative" type="RelativeTimeRange">
            The relative time period.

            See <a href="/docs/query-apis/api-reference/enums#relativetimerange">RelativeTimeRange</a>
          </ParamField>

          <ParamField path="n" type="Int">
            The number of time units for the `LAST_N` relative periods.
          </ParamField>

          <ParamField path="start" type="DateTime">
            The optional start timestamp (inclusive). Defaults to the timestamp of the earliest record in the Data Pool.
          </ParamField>

          <ParamField path="stop" type="DateTime">
            The optional end timestamp (exclusive). Defaults to the timestamp of the latest record in the Data Pool.
          </ParamField>
        </Expandable>
      </ParamField>

      <ParamField path="timeZone" type="String">
        The time zone to use. Dates and times are always returned in UTC, but setting the time zone influences relative time ranges and granularities.

        You can set this to "America/Los\_Angeles", "Europe/Berlin", or any other value in the [IANA time zone database](https://en.wikipedia.org/wiki/Tz_database). Defaults to "UTC".
      </ParamField>

      <ParamField path="granularity" type="TimeSeriesGranularity" required>
        The time granularity (hour, day, month, etc.) to aggregate the Metric values by.

        <Expandable title="TimeSeriesGranularity">
          The available time series granularities. Granularities define the unit of time to aggregate the Metric data for a time series query.

          For example, if the granularity is set to `DAY`, then the the time series query will return a label and a value for each day.

          If there are no records for a given time series granularity, Propel will return the label and a value of "0" so that the time series can be properly visualized.

          <ParamField path=" ">
            * `MINUTE`: Aggregates values by minute intervals.
            * `FIVE_MINUTES`: Aggregates values by 5-minute intervals.
            * `TEN_MINUTES`: Aggregates values by 10-minute intervals.
            * `FIFTEEN_MINUTES`: Aggregates values by 15-minute intervals.
            * `HOUR`: Aggregates values by hourly intervals.
            * `DAY`: Aggregates values by daily intervals.
            * `WEEK`: Aggregates values by weekly intervals.
            * `MONTH`: Aggregates values by monthly intervals.
            * `YEAR`: Aggregates values by yearly intervals.
          </ParamField>
        </Expandable>
      </ParamField>

      <ParamField path="filterSql" type="String">
        The Query Filters to apply before retrieving the time series data, in the form of SQL. If no Query Filters are provided, all data is included.
      </ParamField>

      <ParamField path="groupBy" type="[String!]">
        Columns to group by.
      </ParamField>

      <Expandable title="Deprecated Fields">
        <ParamField path="metricId" type="ID" deprecated>
          The ID of the Metric to query.

          Required if `metricName` is not specified.

          <span style={{ fontStyle: 'italic' }}>deprecated: Use `metric`</span>
        </ParamField>

        <ParamField path="metricName" type="String" deprecated>
          The name of the Metric to query.

          Required if `metricId` is not specified.

          <span style={{ fontStyle: 'italic' }}>deprecated: Use `metric`</span>
        </ParamField>

        <ParamField path="filters" type="[FilterInput!]" deprecated>
          The Query Filters to apply before retrieving the time series data. If no Query Filters are provided, all data is included.

          <span style={{ fontStyle: 'italic' }}>deprecated: Use `filterSql` instead</span>

          <Expandable title="FilterInput">
            The fields of a filter.

            You can construct more complex filters using `and` and `or`. For example, to construct a filter equivalent to

            ```
            (value > 0 AND value <= 100) OR status = "confirmed"
            ```

            you could write

            ```
            {
              "column": "value",
              "operator": "GREATER_THAN",
              "value": "0",
              "and": [{
                "column": "value",
                "operator": "LESS_THAN_OR_EQUAL_TO",
                "value": "0"
              }],
              "or": [{
                "column": "status",
                "operator": "EQUALS",
                "value": "confirmed"
              }]
            }
            ```

            Note that `and` takes precedence over `or`.

            <ParamField path="column" type="String" required>
              The name of the column to filter on.
            </ParamField>

            <ParamField path="operator" type="FilterOperator" required>
              The operation to perform when comparing the column and filter values.

              See <a href="/docs/query-apis/api-reference/enums#filteroperator">FilterOperator</a>
            </ParamField>

            <ParamField path="value" type="String">
              The value to compare the column to.
            </ParamField>

            <ParamField path="and" type="[FilterInput!]">
              Additional filters to AND with this one. AND takes precedence over OR.
            </ParamField>

            <ParamField path="or" type="[FilterInput!]">
              Additional filters to OR with this one. AND takes precedence over OR.
            </ParamField>
          </Expandable>
        </ParamField>
      </Expandable>
    </Expandable>
  </ParamField>

  <Expandable title="TimeSeriesResponse">
    The time series response object. It contains an array of time series labels and an array of Metric values for the given time range and Query Filters.

    <ParamField path="labels" type="[String!]" required>
      The time series labels.
    </ParamField>

    <ParamField path="values" type="[String]" required>
      The time series values.
    </ParamField>

    <ParamField path="groups" type="[TimeSeriesResponseGroup!]">
      The time series values for each group in `groupBy`, if specified.

      <Expandable title="TimeSeriesResponseGroup">
        The time series response object for a group specified in `groupBy`. It contains an array of time series labels and an array of Metric values for a particular group.

        <ParamField path="group" type="[String]" required>
          The time series group's columns.
        </ParamField>

        <ParamField path="labels" type="[String!]" required>
          The time series group's labels.
        </ParamField>

        <ParamField path="values" type="[String]" required>
          The time series group's values.
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField path="query" type="QueryInfo" required>
      The Query statistics and metadata.

      <Expandable title="QueryInfo">
        The Query Info object. It contains metadata and statistics about a Query performed.

        <ParamField path="id" type="ID" required>
          The Query's unique identifier.
        </ParamField>

        <ParamField path="createdAt" type="DateTime" required>
          The date and time in UTC when the Query was created.
        </ParamField>

        <ParamField path="createdBy" type="String" required>
          The unique identifier of the actor that performed the Query.
        </ParamField>

        <ParamField path="modifiedAt" type="DateTime" required>
          The date and time in UTC when the Query was last modified.
        </ParamField>

        <ParamField path="modifiedBy" type="String" required>
          The unique identifier of the actor that modified the Query.
        </ParamField>

        <ParamField path="bytesProcessed" type="String" required>
          The bytes processed by the Query.
        </ParamField>

        <ParamField path="durationInMilliseconds" type="Int" required>
          The duration of the Query in milliseconds.
        </ParamField>

        <ParamField path="recordsProcessed" type="String" required>
          The number of records processed by the Query.
        </ParamField>

        <ParamField path="resultingBytes" type="Int" required>
          The bytes returned by the Query.
        </ParamField>

        <ParamField path="resultingRecords" type="Int" required>
          The number of records returned by the Query.
        </ParamField>

        <ParamField path="propeller" type="Propeller">
          The Propeller used for this query.

          See <a href="/docs/query-apis/api-reference/enums#propeller">Propeller</a>
        </ParamField>

        <ParamField path="status" type="QueryStatus" required>
          The Query status.

          See <a href="/docs/query-apis/api-reference/enums#querystatus">QueryStatus</a>
        </ParamField>

        <ParamField path="type" type="QueryType" required>
          The Query type.

          See <a href="/docs/query-apis/api-reference/enums#querytype">QueryType</a>
        </ParamField>

        <ParamField path="subtype" type="QuerySubtype">
          The Query subtype.

          See <a href="/docs/query-apis/api-reference/enums#querysubtype">QuerySubtype</a>
        </ParamField>

        <ParamField path="sql" type="String" required>
          The SQL the query executed.
        </ParamField>
      </Expandable>
    </ParamField>
  </Expandable>
</ParamField>

<ParamField path="leaderboard" type="LeaderboardResponse">
  Query a metric in leaderboard format. Returns a table (array of rows) with the selected dimensions and the metric's corresponding values for the given time range and filters.

  ### Arguments

  <ParamField notPatch path="input" type="LeaderboardInput" required>
    <Expandable title="LeaderboardInput">
      The fields for querying a Metric in leaderboard format.

      A Metric's leaderboard query returns an ordered table of Dimension and Metric values over a given time range.

      <ParamField path="metric" type="MetricInput">
        The Metric to query. You can query a pre-configured Metric by ID or name, or you can query an ad hoc Metric that you define inline.

        <Expandable title="MetricInput">
          <ParamField path="id" type="ID">
            The ID of a pre-configured Metric.
          </ParamField>

          <ParamField path="name" type="String">
            The name of a pre-configured Metric.
          </ParamField>

          <ParamField path="custom" type="CustomMetricQueryInput">
            An ad hoc Custom Metric.

            See <a href="/docs/query-apis/api-reference/inputs#custommetricqueryinput">CustomMetricQueryInput</a>
          </ParamField>

          <ParamField path="count" type="CountMetricQueryInput">
            An ad hoc Count Metric.

            See <a href="/docs/query-apis/api-reference/inputs#countmetricqueryinput">CountMetricQueryInput</a>
          </ParamField>

          <ParamField path="sum" type="SumMetricQueryInput">
            An ad hoc Sum Metric.

            See <a href="/docs/query-apis/api-reference/inputs#summetricqueryinput">SumMetricQueryInput</a>
          </ParamField>

          <ParamField path="average" type="AverageMetricQueryInput">
            An ad hoc Average Metric.

            See <a href="/docs/query-apis/api-reference/inputs#averagemetricqueryinput">AverageMetricQueryInput</a>
          </ParamField>

          <ParamField path="min" type="MinMetricQueryInput">
            An ad hoc Min Metric.

            See <a href="/docs/query-apis/api-reference/inputs#minmetricqueryinput">MinMetricQueryInput</a>
          </ParamField>

          <ParamField path="max" type="MaxMetricQueryInput">
            An ad hoc Max Metric.

            See <a href="/docs/query-apis/api-reference/inputs#maxmetricqueryinput">MaxMetricQueryInput</a>
          </ParamField>

          <ParamField path="countDistinct" type="CountDistinctMetricQueryInput">
            An ad hoc Count Distinct Metric.

            See <a href="/docs/query-apis/api-reference/inputs#countdistinctmetricqueryinput">CountDistinctMetricQueryInput</a>
          </ParamField>
        </Expandable>
      </ParamField>

      <ParamField path="timeRange" type="TimeRangeInput">
        The time range for calculating the leaderboard.

        <Expandable title="TimeRangeInput">
          The fields required to specify the time range for a time series, counter, or leaderboard Metric query.

          If no relative or absolute time ranges are provided, Propel defaults to an absolute time range beginning with the earliest record in the Metric's Data Pool and ending with the latest record.

          If both relative and absolute time ranges are provided, the relative time range will take precedence.

          If a `LAST_N` relative time period is selected, an `n` ≥ 1 must be provided. If no `n` is provided or `n` \< 1, a `BAD_REQUEST` error will be returned.

          <ParamField path="timestamp" type="String">
            The timestamp field to use when querying. Defaults to the timestamp configured on the Data Pool or Metric, if any.
            Set this to filter on an alternative timestamp field.
          </ParamField>

          <ParamField path="relative" type="RelativeTimeRange">
            The relative time period.

            See <a href="/docs/query-apis/api-reference/enums#relativetimerange">RelativeTimeRange</a>
          </ParamField>

          <ParamField path="n" type="Int">
            The number of time units for the `LAST_N` relative periods.
          </ParamField>

          <ParamField path="start" type="DateTime">
            The optional start timestamp (inclusive). Defaults to the timestamp of the earliest record in the Data Pool.
          </ParamField>

          <ParamField path="stop" type="DateTime">
            The optional end timestamp (exclusive). Defaults to the timestamp of the latest record in the Data Pool.
          </ParamField>
        </Expandable>
      </ParamField>

      <ParamField path="timeZone" type="String">
        The time zone to use. Dates and times are always returned in UTC, but setting the time zone influences relative time ranges and granularities.

        You can set this to "America/Los\_Angeles", "Europe/Berlin", or any other value in the [IANA time zone database](https://en.wikipedia.org/wiki/Tz_database). Defaults to "UTC".
      </ParamField>

      <ParamField path="dimensions" type="[DimensionInput!]" required>
        One or many Dimensions to group the Metric values by. Typically, Dimensions in a leaderboard are what you want to compare and rank.

        <Expandable title="DimensionInput">
          The fields for creating or modifying a Dimension.

          <ParamField path="columnName" type="String" required>
            The name of the column to create the Dimension from.
          </ParamField>
        </Expandable>
      </ParamField>

      <ParamField path="sort" type="Sort">
        The sort order of the rows. It can be ascending (`ASC`) or descending (`DESC`) order. Defaults to descending (`DESC`) order when not provided.

        <Expandable title="Sort">
          The available sort orders.

          <ParamField path=" ">
            * `ASC`: Sort in ascending order.
            * `DESC`: Sort in descending order.
          </ParamField>
        </Expandable>
      </ParamField>

      <ParamField path="rowLimit" type="Int" required>
        The number of rows to be returned. It can be a number between 1 and 1,000.
      </ParamField>

      <ParamField path="filterSql" type="String">
        The Query Filters to apply before retrieving the leaderboard data, in the form of SQL. If no Query Filters are provided, all data is included.
      </ParamField>

      <Expandable title="Deprecated Fields">
        <ParamField path="metricId" type="ID" deprecated>
          The ID of the Metric to query.

          Required if `metricName` is not specified.

          <span style={{ fontStyle: 'italic' }}>deprecated: Use `metric`</span>
        </ParamField>

        <ParamField path="metricName" type="String" deprecated>
          The name of the Metric to query.

          Required if `metricId` is not specified.

          <span style={{ fontStyle: 'italic' }}>deprecated: Use `metric`</span>
        </ParamField>

        <ParamField path="filters" type="[FilterInput!]" deprecated>
          The Query Filters to apply before retrieving the leaderboard data. If no Query Filters are provided, all data is included.

          <span style={{ fontStyle: 'italic' }}>deprecated: Use `filterSql` instead</span>

          <Expandable title="FilterInput">
            The fields of a filter.

            You can construct more complex filters using `and` and `or`. For example, to construct a filter equivalent to

            ```
            (value > 0 AND value <= 100) OR status = "confirmed"
            ```

            you could write

            ```
            {
              "column": "value",
              "operator": "GREATER_THAN",
              "value": "0",
              "and": [{
                "column": "value",
                "operator": "LESS_THAN_OR_EQUAL_TO",
                "value": "0"
              }],
              "or": [{
                "column": "status",
                "operator": "EQUALS",
                "value": "confirmed"
              }]
            }
            ```

            Note that `and` takes precedence over `or`.

            <ParamField path="column" type="String" required>
              The name of the column to filter on.
            </ParamField>

            <ParamField path="operator" type="FilterOperator" required>
              The operation to perform when comparing the column and filter values.

              See <a href="/docs/query-apis/api-reference/enums#filteroperator">FilterOperator</a>
            </ParamField>

            <ParamField path="value" type="String">
              The value to compare the column to.
            </ParamField>

            <ParamField path="and" type="[FilterInput!]">
              Additional filters to AND with this one. AND takes precedence over OR.
            </ParamField>

            <ParamField path="or" type="[FilterInput!]">
              Additional filters to OR with this one. AND takes precedence over OR.
            </ParamField>
          </Expandable>
        </ParamField>
      </Expandable>
    </Expandable>
  </ParamField>

  <Expandable title="LeaderboardResponse">
    The leaderboard response object. It contains an array of headers and a table (array of rows) with the selected Dimensions and corresponding Metric values for the given time range and Query Filters.

    <ParamField path="headers" type="[String!]" required>
      The table headers. It contains the Dimension and Metric names.
    </ParamField>

    <ParamField path="rows" type="[[String]!]" required>
      An ordered array of rows. Each row contains the Dimension values and the corresponding Metric value. A Dimension value can be empty. A Metric value will never be empty.
    </ParamField>

    <ParamField path="query" type="QueryInfo" required>
      The Query statistics and metadata.

      <Expandable title="QueryInfo">
        The Query Info object. It contains metadata and statistics about a Query performed.

        <ParamField path="id" type="ID" required>
          The Query's unique identifier.
        </ParamField>

        <ParamField path="createdAt" type="DateTime" required>
          The date and time in UTC when the Query was created.
        </ParamField>

        <ParamField path="createdBy" type="String" required>
          The unique identifier of the actor that performed the Query.
        </ParamField>

        <ParamField path="modifiedAt" type="DateTime" required>
          The date and time in UTC when the Query was last modified.
        </ParamField>

        <ParamField path="modifiedBy" type="String" required>
          The unique identifier of the actor that modified the Query.
        </ParamField>

        <ParamField path="bytesProcessed" type="String" required>
          The bytes processed by the Query.
        </ParamField>

        <ParamField path="durationInMilliseconds" type="Int" required>
          The duration of the Query in milliseconds.
        </ParamField>

        <ParamField path="recordsProcessed" type="String" required>
          The number of records processed by the Query.
        </ParamField>

        <ParamField path="resultingBytes" type="Int" required>
          The bytes returned by the Query.
        </ParamField>

        <ParamField path="resultingRecords" type="Int" required>
          The number of records returned by the Query.
        </ParamField>

        <ParamField path="propeller" type="Propeller">
          The Propeller used for this query.

          See <a href="/docs/query-apis/api-reference/enums#propeller">Propeller</a>
        </ParamField>

        <ParamField path="status" type="QueryStatus" required>
          The Query status.

          See <a href="/docs/query-apis/api-reference/enums#querystatus">QueryStatus</a>
        </ParamField>

        <ParamField path="type" type="QueryType" required>
          The Query type.

          See <a href="/docs/query-apis/api-reference/enums#querytype">QueryType</a>
        </ParamField>

        <ParamField path="subtype" type="QuerySubtype">
          The Query subtype.

          See <a href="/docs/query-apis/api-reference/enums#querysubtype">QuerySubtype</a>
        </ParamField>

        <ParamField path="sql" type="String" required>
          The SQL the query executed.
        </ParamField>
      </Expandable>
    </ParamField>
  </Expandable>
</ParamField>
