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

# Read analytics catalog

> Retrieves the data sources available to analytics queries and their availability for the caller's organization. With `dataSource`, returns that source's full descriptor: time fields, measure functions, dimension kinds, limits, every field with its capabilities, and the time vocabulary (`durationPairs`, `ageFields`, `bucketPresets`). The list carries one `task:<flowId>` summary per flow of the organization (`kind: flow`, `flowId`, `flowName`; the client labels it "Task - {flowName}") for organizations with Big Data, and one `data:<dataTypeId>` summary per internal data type for every organization (`kind: dataType`, `dataTypeId`, `dataTypeName`, `commonData`; the client labels it "Data - {dataTypeName}"); a data type that extends a user record is listed unavailable (`data_source_blocked.extends_entity`), an external data type is not listed. `task_detail` is listed only for organizations without Big Data (always unavailable).

Task columns follow the product field list, the same list Report and Export show: Task (all) has `_id` (Id), `flow`, `flowId` (filter only), `hubName` (Hub), `hubIdentifier` (Hub id), `title`, `content`, `label`, `status`, `startTime`, `endTime`, `updatedTime`, `assignee`, `assignedBy`, `createdBy`, `createdFrom`, `createdTime`, `doneBy`, `doneCoordinate`, `doneTime`, `travelDuration` and `refId` (Ref id, the client's own task id). Hub id is named `hubIdentifier` because `hubId` stays a protected field (`protected_field_rejected`); a filter on `hubName` or `hubIdentifier` can only narrow the hub scope the server applies. No Task column is listed unavailable. The old Task fields `docId`, `organizationName`, `organizationEmail`, `hubCountry`, `hubLat`, `hubLng` and `year` are no longer listed; a stored card that names one fails only its own card with `field_unavailable`, and saving such a spec is refused.

User columns are a fixed list, in this order: `status` (account status: `active`, `pending`, `disable`, `reject`, `inactive`, `unverified`), `roleId` (the stored role id), `roleName` (the role name), `teamId` (team ids, several values, fans out), `hub` (the user's hub ids, several values, fans out; picked from the caller's hubs), `email`, `name`, `language`, `firstLogin` (`true` / `false`), `userId` (the user id), and the dates `createdTime`, `verifiedTime`, `updatedTime`, `lastLogin`. `teamId` and `hub` stay ids in the result; the item carries `valueLabels` with their names. Every User column filters and groups; count is the only measure. The Users source is listed for every organization, with or without Big Data. Secret and contact fields of a user (phone number, avatar, activation code, authenticator, permissions and the like) are never listed, and a spec naming one, or a removed field such as `lastActivity`, is `422 field_unknown`.

Columns are typed by the search index, not by the form or data type definition: a per-flow descriptor has every Task (all) column except `flow`, with the same behaviour and always available (a column the flow's tasks never filled answers empty), plus the flow's own reserved keys the index maps (for example `travelDistance`), one `pageNDoneTime` column per page (title like "Page1Done Time"), and every flow component (`origin: component`), and a Data descriptor has the data type fields (`origin: data`) plus the system fields `createdTime`, `updatedTime`, `createdBy`, `updatedBy` (`origin: core`). A column the index stores as keyword filters and groups, as a number is a measure field, as a date is a time field and a date grouping, as a geolocation (`type: geolocation`, for example `doneCoordinate` or a Geolocation component) is one raw "lat, lng" Sample rows column with no filter, grouping or measure; any other storage is not listed. A date column is `type: date` (no time of day) when its flow component input type is `Date` or its data type field is `date`, else `dateTime`; a `date` column offers no hourly grouping. Photo, signature, voice, video, bill and list components are never offered. Components and data type fields hidden for a role in Field Accessibility are NOT removed: they appear like any other column. A data type field no record carries yet is listed unavailable with `field_blocked.no_values_yet`; when the index could not be checked every data type field is listed unavailable with `field_blocked.unconfirmed` and `componentStatus` is `unchecked`.



## OpenAPI

````yaml /openapi/public/openapi-analytics.json get /analytics/catalog
openapi: 3.0.0
info:
  title: API - Analytics
  version: 3.0.0
  description: API Documentation - RESTful API for field operations management.
servers:
  - url: https://apiweb.mile.app/api/v3
security:
  - bearerAuth: []
tags:
  - name: Dashboard
    description: >-
      Dashboard lets a user compose their own dashboard from any number of
      cards, start from a template, duplicate a dashboard, share it with roles,
      and save it back as an organization template. Each card owns its own
      widget row (a chart type plus a query spec), cloned from the widget
      catalogue (built-in widgets plus the organization's custom widgets), so
      renaming or editing a card never touches the catalogue or another
      dashboard. Dashboards are owned by their creator: roles they are shared
      with can view, duplicate and save as template, but only the owner can edit
      or delete. Every write reuses the dashboard permission family (view, add,
      edit and delete dashboard).


      The numbers behind each card come from one generic aggregation endpoint
      instead of one endpoint per chart: the client sends a batch of up to 12
      declarative query specs, the server injects the caller's organization, hub
      and soft-delete scope from the session, runs each spec read-only, and
      returns a flat columns and rows table per item. The catalog endpoints
      describe the data sources, fields and limits a client may use.
  - name: Report
    description: >-
      A report is a saved table definition over tasks of one flow or records of
      one data type: which fields to show, which hubs to include, and the
      default filters.
  - name: Insight Report
    description: >-
      Insight reports are written summaries of your operations, generated from
      your task and data records: findings, a summary and suggested actions. You
      set the context once per flow, then generate reports on demand or on a
      schedule.
paths:
  /analytics/catalog:
    get:
      tags:
        - Dashboard
      summary: Read analytics catalog
      description: >-
        Retrieves the data sources available to analytics queries and their
        availability for the caller's organization. With `dataSource`, returns
        that source's full descriptor: time fields, measure functions, dimension
        kinds, limits, every field with its capabilities, and the time
        vocabulary (`durationPairs`, `ageFields`, `bucketPresets`). The list
        carries one `task:<flowId>` summary per flow of the organization (`kind:
        flow`, `flowId`, `flowName`; the client labels it "Task - {flowName}")
        for organizations with Big Data, and one `data:<dataTypeId>` summary per
        internal data type for every organization (`kind: dataType`,
        `dataTypeId`, `dataTypeName`, `commonData`; the client labels it "Data -
        {dataTypeName}"); a data type that extends a user record is listed
        unavailable (`data_source_blocked.extends_entity`), an external data
        type is not listed. `task_detail` is listed only for organizations
        without Big Data (always unavailable).


        Task columns follow the product field list, the same list Report and
        Export show: Task (all) has `_id` (Id), `flow`, `flowId` (filter only),
        `hubName` (Hub), `hubIdentifier` (Hub id), `title`, `content`, `label`,
        `status`, `startTime`, `endTime`, `updatedTime`, `assignee`,
        `assignedBy`, `createdBy`, `createdFrom`, `createdTime`, `doneBy`,
        `doneCoordinate`, `doneTime`, `travelDuration` and `refId` (Ref id, the
        client's own task id). Hub id is named `hubIdentifier` because `hubId`
        stays a protected field (`protected_field_rejected`); a filter on
        `hubName` or `hubIdentifier` can only narrow the hub scope the server
        applies. No Task column is listed unavailable. The old Task fields
        `docId`, `organizationName`, `organizationEmail`, `hubCountry`,
        `hubLat`, `hubLng` and `year` are no longer listed; a stored card that
        names one fails only its own card with `field_unavailable`, and saving
        such a spec is refused.


        User columns are a fixed list, in this order: `status` (account status:
        `active`, `pending`, `disable`, `reject`, `inactive`, `unverified`),
        `roleId` (the stored role id), `roleName` (the role name), `teamId`
        (team ids, several values, fans out), `hub` (the user's hub ids, several
        values, fans out; picked from the caller's hubs), `email`, `name`,
        `language`, `firstLogin` (`true` / `false`), `userId` (the user id), and
        the dates `createdTime`, `verifiedTime`, `updatedTime`, `lastLogin`.
        `teamId` and `hub` stay ids in the result; the item carries
        `valueLabels` with their names. Every User column filters and groups;
        count is the only measure. The Users source is listed for every
        organization, with or without Big Data. Secret and contact fields of a
        user (phone number, avatar, activation code, authenticator, permissions
        and the like) are never listed, and a spec naming one, or a removed
        field such as `lastActivity`, is `422 field_unknown`.


        Columns are typed by the search index, not by the form or data type
        definition: a per-flow descriptor has every Task (all) column except
        `flow`, with the same behaviour and always available (a column the
        flow's tasks never filled answers empty), plus the flow's own reserved
        keys the index maps (for example `travelDistance`), one `pageNDoneTime`
        column per page (title like "Page1Done Time"), and every flow component
        (`origin: component`), and a Data descriptor has the data type fields
        (`origin: data`) plus the system fields `createdTime`, `updatedTime`,
        `createdBy`, `updatedBy` (`origin: core`). A column the index stores as
        keyword filters and groups, as a number is a measure field, as a date is
        a time field and a date grouping, as a geolocation (`type: geolocation`,
        for example `doneCoordinate` or a Geolocation component) is one raw
        "lat, lng" Sample rows column with no filter, grouping or measure; any
        other storage is not listed. A date column is `type: date` (no time of
        day) when its flow component input type is `Date` or its data type field
        is `date`, else `dateTime`; a `date` column offers no hourly grouping.
        Photo, signature, voice, video, bill and list components are never
        offered. Components and data type fields hidden for a role in Field
        Accessibility are NOT removed: they appear like any other column. A data
        type field no record carries yet is listed unavailable with
        `field_blocked.no_values_yet`; when the index could not be checked every
        data type field is listed unavailable with `field_blocked.unconfirmed`
        and `componentStatus` is `unchecked`.
      operationId: getAnalyticsCatalog
      parameters:
        - name: dataSource
          in: query
          required: false
          description: >-
            `task`, `user`, `task_detail`, `task:<flowId>` or
            `data:<dataTypeId>` (24 lowercase hex). A bare 24-hex id is `422
            data_source_id_invalid`. Omit to list data sources.
          schema:
            type: string
      responses:
        '200':
          description: >-
            Success - data-source list, or one full descriptor. The example is
            the Task descriptor. A Data source descriptor
            (`?dataSource=data:<dataTypeId>`, excerpt: some fields and keys left
            out) reads:


            ```json

            {
              "id": "data:6ae211692fd5463064096512",
              "kind": "dataType",
              "label": "data_source.data_type",
              "timeFieldCandidates": [
                "launchDate",
                "createdTime",
                "updatedTime"
              ],
              "defaultTimeField": "createdTime",
              "aggregations": {
                "measures": {
                  "count": "supported",
                  "cardinality": "supported",
                  "avg": "supported",
                  "sum": "supported",
                  "min": "supported",
                  "max": "supported",
                  "avgDuration": "supported",
                  "avgAge": "unsupported",
                  "doneShare": "unsupported"
                },
                "dimensions": {
                  "terms": "supported",
                  "dateHistogram": "supported",
                  "geoGrid": "unsupported",
                  "range": "unsupported",
                  "filters": "unsupported",
                  "ageBucket": "unsupported",
                  "hourOfDay": "supported",
                  "dayOfWeek": "supported"
                }
              },
              "scope": {
                "commonData": false,
                "rowLevelSecurity": "none"
              },
              "requiresBigData": false,
              "availability": {
                "available": true,
                "reason": null,
                "description": null
              },
              "fields": [
                {
                  "name": "status",
                  "label": "Status",
                  "optionData": [
                    "open",
                    "closed",
                    "hold"
                  ],
                  "unit": null,
                  "capability": {
                    "filterable": true,
                    "groupable": true,
                    "metricable": false,
                    "distinctCountable": true,
                    "timeFieldEligible": false,
                    "sortable": true
                  },
                  "valuePicker": "list",
                  "cardinality": "low",
                  "origin": "data",
                  "availability": {
                    "available": true,
                    "blockedReason": null
                  }
                },
                {
                  "name": "qty",
                  "label": "Quantity",
                  "optionData": null,
                  "unit": "plain",
                  "capability": {
                    "filterable": true,
                    "groupable": false,
                    "metricable": true,
                    "distinctCountable": false,
                    "timeFieldEligible": false,
                    "sortable": true
                  },
                  "valuePicker": "none",
                  "cardinality": "high",
                  "origin": "data",
                  "availability": {
                    "available": true,
                    "blockedReason": null
                  }
                },
                {
                  "name": "launchDate",
                  "label": "Launch date",
                  "optionData": null,
                  "unit": null,
                  "capability": {
                    "filterable": true,
                    "groupable": true,
                    "metricable": false,
                    "distinctCountable": false,
                    "timeFieldEligible": true,
                    "sortable": true
                  },
                  "valuePicker": "none",
                  "cardinality": "high",
                  "origin": "data",
                  "availability": {
                    "available": true,
                    "blockedReason": null
                  }
                },
                {
                  "name": "postalCode",
                  "label": "Postal code",
                  "optionData": null,
                  "unit": null,
                  "capability": {
                    "filterable": false,
                    "groupable": false,
                    "metricable": false,
                    "distinctCountable": false,
                    "timeFieldEligible": false,
                    "sortable": false
                  },
                  "valuePicker": "none",
                  "cardinality": "unknown",
                  "origin": "data",
                  "availability": {
                    "available": false,
                    "blockedReason": "field_blocked.no_values_yet"
                  }
                },
                {
                  "name": "createdTime",
                  "label": "field.data.createdTime",
                  "optionData": null,
                  "unit": null,
                  "capability": {
                    "filterable": true,
                    "groupable": true,
                    "metricable": false,
                    "distinctCountable": false,
                    "timeFieldEligible": true,
                    "sortable": true
                  },
                  "valuePicker": "none",
                  "cardinality": "high",
                  "origin": "core",
                  "availability": {
                    "available": true,
                    "blockedReason": null
                  }
                }
              ],
              "durationPairs": [],
              "ageFields": [],
              "bucketPresets": {},
              "viewPermission": "view/data",
              "previewColumns": [
                "status",
                "qty",
                "launchDate",
                "createdTime",
                "updatedTime",
                "createdBy",
                "updatedBy"
              ],
              "durationEndpoints": [
                "launchDate",
                "createdTime"
              ],
              "flowId": null,
              "flowName": null,
              "componentStatus": "ok",
              "timeless": true,
              "dataTypeId": "6ae211692fd5463064096512",
              "dataTypeName": "Outlets"
            }

            ```
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: boolean
                    example: true
                  data:
                    type: object
                    description: >-
                      Array of summaries without `dataSource` (`id, kind, label,
                      requiresBigData, availability, viewPermission`, plus
                      `flowId` and `flowName` on a `kind: flow` entry, and
                      `dataTypeId`, `dataTypeName` and `commonData` on a `kind:
                      dataType` entry); one descriptor with it
                    properties:
                      id:
                        type: string
                      kind:
                        type: string
                        enum:
                          - builtin
                          - flow
                          - dataType
                        description: >-
                          `flow` for a Task - {Flow} source, `dataType` for a
                          Data - {name} source
                      label:
                        type: string
                      specVersion:
                        type: integer
                      timeFieldCandidates:
                        type: array
                        items:
                          type: string
                      defaultTimeField:
                        type: string
                      aggregations:
                        type: object
                        properties:
                          measures:
                            type: object
                            description: >-
                              Function -> `supported`/`unsupported`: `count`,
                              `cardinality`, `avg`, `sum`, `min`, `max`,
                              `avgDuration`, `avgAge`, `doneShare`. A Data
                              source: `avgAge` and `doneShare` are
                              `unsupported`; `avgDuration` is `supported` only
                              as a From / To, when there are at least two
                              `durationEndpoints`.
                            additionalProperties: true
                          dimensions:
                            type: object
                            description: >-
                              Kind -> `supported`/`unsupported`: `terms`,
                              `dateHistogram`, `geoGrid`, `range`, `filters`,
                              and on Task `ageBucket`, `hourOfDay`, `dayOfWeek`.
                              A Data source: `ageBucket` and `geoGrid` are
                              `unsupported`; `hourOfDay` is `supported` on a
                              `dateTime` field only with a `range` filter on
                              that field of at most 31 days (else the card fails
                              with `time_grouping_needs_range`, like a
                              `minute`/`hour` `dateHistogram`), and never on a
                              `date` field (`time_grouping_date_only`).
                            additionalProperties: true
                      limits:
                        type: object
                        additionalProperties: true
                      scope:
                        type: object
                        properties:
                          commonData:
                            type: boolean
                            description: >-
                              Data sources: `true` for a data type shared by
                              every hub. The hub scope and the dashboard hub
                              filter do not apply to it.
                          rowLevelSecurity:
                            type: string
                            description: >-
                              `none`, or `restricted` for a data type with the
                              per-user restriction (`limitUser`): a record is
                              counted only when its user list holds the caller's
                              email or `all`. A session without an email sees
                              only the records shared with `all` (fail closed).
                      requiresBigData:
                        type: boolean
                      availability:
                        type: object
                        properties:
                          available:
                            type: boolean
                          reason:
                            type: string
                            description: >-
                              When `available` is false:
                              `data_source_blocked.needs_bigdata`
                              (`task_detail`) or
                              `data_source_blocked.extends_entity` (a data type
                              that extends a user record; not in dashboards yet)
                          description:
                            type: string
                      fields:
                        type: array
                        items:
                          type: object
                          description: >-
                            A catalog field. Besides the keys below each field
                            carries `type`, its platform type (`text`, `option`,
                            `number`, `dateTime`, `geolocation`, `primaryKey`);
                            it is left out of the schema and example on this
                            page only because the docs build rewrites keys named
                            `type`.
                          properties:
                            name:
                              type: string
                              description: Logical field name used in specs
                            label:
                              type: string
                              description: >-
                                i18n key for a core field (e.g.
                                `field.task.status`, `field.data.createdTime`);
                                the field title, shown as is, for a flow
                                component or a data type field
                            optionData:
                              type: array
                              items:
                                type: string
                            isArray:
                              type: boolean
                            unit:
                              type: string
                            capability:
                              type: object
                              properties:
                                filterable:
                                  type: boolean
                                groupable:
                                  type: boolean
                                metricable:
                                  type: boolean
                                distinctCountable:
                                  type: boolean
                                timeFieldEligible:
                                  type: boolean
                                sortable:
                                  type: boolean
                            valuePicker:
                              type: string
                              enum:
                                - none
                                - search
                                - list
                                - user
                                - flow
                                - hub
                              description: >-
                                How a filter value is picked: `user` = a user
                                picker (assignee), `flow` = a flow picker
                                (`flowId`), `hub` = the caller's accessible hubs
                                (`hubName`, `hubIdentifier`, User `hub`;
                                operator `in`), `list` = fixed options, `search`
                                = typed search, `none` = no picker
                            valuePickerField:
                              type: string
                              description: >-
                                With `valuePicker: hub`: the hub key the filter
                                value holds, `name` (`hubName`) or `_id`
                                (`hubIdentifier`, User `hub`); `null` otherwise
                            cardinality:
                              type: string
                            fanOut:
                              type: boolean
                            availability:
                              type: object
                              properties:
                                available:
                                  type: boolean
                                blockedReason:
                                  type: string
                                  description: >-
                                    When `available` is false. On a Data source:
                                    `field_blocked.no_values_yet` (no record has
                                    a value in this field yet) or
                                    `field_blocked.unconfirmed` (the index could
                                    not be checked right now). A Task or Task -
                                    {Flow} column is never listed unavailable.
                                    No User column is listed unavailable.
                            quality:
                              type: object
                              properties:
                                level:
                                  type: string
                                note:
                                  type: string
                                fillRate:
                                  type: number
                                zeroRate:
                                  type: number
                                measuredAt:
                                  type: string
                                sampleSize:
                                  type: integer
                            origin:
                              type: string
                              enum:
                                - core
                                - component
                                - data
                              description: >-
                                `component` for a flow component of a Task -
                                {Flow} source, `data` for a data type field of a
                                Data source, `core` otherwise (including the
                                Data system fields). Components and data type
                                fields are typed by the index: keyword (filter,
                                Group by), number (measure field, unit `plain`)
                                date (Date field, date grouping, From / To) or
                                geolocation (raw "lat, lng" in Sample rows
                                only).
                      durationPairs:
                        type: array
                        description: >-
                          Duration pairs `avgDuration` accepts, suggested pairs
                          first. Empty when the source has none (`user`, every
                          Data source; a Data source offers From / To only).
                        items:
                          type: object
                          properties:
                            id:
                              type: string
                              description: Value for the measure `field`
                            from:
                              type: string
                              description: Start date field
                            to:
                              type: string
                              description: End date field
                            labelKey:
                              type: string
                              description: i18n key; `null` on a non-suggested pair
                            requireStatus:
                              type: array
                              items:
                                type: string
                              description: >-
                                Statuses the population is limited to
                                (`["DONE"]` on a pair touching `doneTime`);
                                `null` = any status
                            signed:
                              type: boolean
                              description: >-
                                `true` when a negative value is meaningful
                                (`endToDone`, `startToDone`)
                            suggested:
                              type: boolean
                              description: One of the five pairs offered first
                      ageFields:
                        type: array
                        description: >-
                          Fields `avgAge` and `ageBucket` accept. Empty when the
                          source has none (`user`, every Data source).
                        items:
                          type: object
                          properties:
                            field:
                              type: string
                            labelKey:
                              type: string
                              description: i18n key
                            statuses:
                              type: array
                              items:
                                type: string
                              description: >-
                                Statuses whose tasks are still ageing (`avgAge`
                                population)
                      bucketPresets:
                        type: object
                        description: >-
                          Preset id -> its bucket keys in order, the values of
                          an `ageBucket` dimension `buckets`. Bounds are
                          computed server-side and are not listed.
                        additionalProperties:
                          type: array
                          items:
                            type: object
                            properties:
                              key:
                                type: string
                      viewPermission:
                        type: string
                        description: >-
                          The permission a role needs to choose this source in
                          the composer and to read its Sample rows (`view/task`
                          for Task, Task - {Flow} and task_detail; `view/user`
                          for User; `view/data` for a Data source). Aggregates
                          need `view/dashboard` only, except a User card that
                          groups or filters, which also needs `view/user` (a
                          plain count does not).
                      previewColumns:
                        type: array
                        items:
                          type: string
                        description: >-
                          The Sample rows columns, in column order. The preview
                          limits rows (at most 20), not columns: every available
                          column of the source is shown. Task: `flow, status,
                          hubName, label, createdFrom, createdTime, startTime,
                          endTime, doneTime, updatedTime, travelDuration` first,
                          then `_id, flowId, hubIdentifier, title, content,
                          assignee, assignedBy, createdBy, doneBy,
                          doneCoordinate, refId` (emails included;
                          `doneCoordinate` as "lat, lng"); Task - {Flow}: the
                          same without `flow`, then the flow's other reserved
                          keys, its `pageNDoneTime` columns and every offered
                          flow component in flow order (photo, signature, voice,
                          video, bill and list never); Data: the available data
                          type fields in data type order, then `createdTime`,
                          `updatedTime`, `createdBy`, `updatedBy`; User:
                          `status, roleId, roleName, teamId, hub, email, name,
                          language, firstLogin, userId, createdTime,
                          verifiedTime, updatedTime, lastLogin`.
                      durationEndpoints:
                        type: array
                        items:
                          type: string
                        description: >-
                          The date columns a From / To measure may use. Task:
                          `createdTime, startTime, endTime, doneTime`; Task -
                          {Flow}: those plus the flow's confirmed date
                          components; Data: the data type's date fields and
                          `createdTime` (never `updatedTime`); User: `[]`.
                      flowId:
                        type: string
                        description: Task - {Flow} only (`null` otherwise)
                      flowName:
                        type: string
                        description: >-
                          Task - {Flow} only: the current flow name, so a
                          renamed flow keeps its id and its cards
                      componentStatus:
                        type: string
                        enum:
                          - ok
                          - no_flow_tasks
                          - unchecked
                        description: >-
                          Task - {Flow} and Data only (`null` otherwise). `ok`:
                          the columns were checked; `no_flow_tasks` (Task -
                          {Flow}): no task of this flow in the current or
                          previous year, so no component is offered;
                          `unchecked`: the check failed or the flow's indices
                          disagree on a type, so no component is offered and
                          every data type field is `field_blocked.unconfirmed`
                          (a card that needs one gets the retryable
                          `source_columns_unchecked`).
                      timeless:
                        type: boolean
                        description: >-
                          `true` for User and every Data source: the dashboard
                          time range does not apply, every record is counted.
                          `timeField` is recorded but not applied.
                      dataTypeId:
                        type: string
                        description: >-
                          Data sources only (`null` otherwise): the data type
                          id, the part after `data:`
                      dataTypeName:
                        type: string
                        description: >-
                          Data sources only (`null` otherwise): the current data
                          type name, so a renamed data type keeps its id and its
                          cards
                      commonData:
                        type: boolean
                        description: >-
                          Summary list, Data sources only: `true` for a data
                          type shared by every hub (the hub filter does not
                          apply). In a descriptor it is `scope.commonData`.
              examples:
                response:
                  value:
                    status: true
                    data:
                      id: task
                      kind: builtin
                      label: data_source.task
                      specVersion: 1
                      timeFieldCandidates:
                        - createdTime
                        - updatedTime
                        - startTime
                        - endTime
                        - doneTime
                      defaultTimeField: startTime
                      aggregations:
                        measures:
                          count: supported
                          cardinality: supported
                          avg: supported
                          sum: supported
                          min: supported
                          max: supported
                          avgDuration: supported
                          avgAge: supported
                          doneShare: supported
                        dimensions:
                          terms: supported
                          dateHistogram: supported
                          geoGrid: supported
                          range: unsupported
                          filters: unsupported
                          ageBucket: supported
                          hourOfDay: supported
                          dayOfWeek: supported
                      limits:
                        maxMeasures: 3
                        maxDimensions: 2
                        maxNestingDepth: 2
                        maxBuckets: 5000
                        maxTermsSize: 50
                        maxTermsSizeHardCap: 1000
                        maxTimeRangeDays: 31
                        maxQueriesPerBatch: 12
                        maxRows: 1000
                        queryTimeoutSeconds: 10
                        batchBudgetSeconds: 20
                        tuningStatus: untuned_defaults
                      scope:
                        commonData: false
                        rowLevelSecurity: none
                      requiresBigData: false
                      availability:
                        available: true
                        reason: null
                        description: null
                      fields:
                        - name: status
                          label: field.task.status
                          optionData:
                            - UNASSIGNED
                            - ONGOING
                            - DONE
                          isArray: false
                          unit: null
                          capability:
                            filterable: true
                            groupable: true
                            metricable: false
                            distinctCountable: true
                            timeFieldEligible: false
                            sortable: true
                          valuePicker: list
                          valuePickerField: null
                          cardinality: low
                          fanOut: false
                          availability:
                            available: true
                            blockedReason: null
                          quality:
                            level: ok
                            fillRate: null
                            zeroRate: null
                            measuredAt: null
                            sampleSize: null
                            note: null
                        - name: travelDuration
                          label: field.task.travelDuration
                          optionData: null
                          isArray: false
                          unit: duration
                          capability:
                            filterable: true
                            groupable: false
                            metricable: true
                            distinctCountable: true
                            timeFieldEligible: false
                            sortable: true
                          valuePicker: none
                          valuePickerField: null
                          cardinality: high
                          fanOut: false
                          availability:
                            available: true
                            blockedReason: null
                          quality:
                            level: unverified
                            fillRate: null
                            zeroRate: null
                            measuredAt: null
                            sampleSize: null
                            note: field_quality.unverified
                      durationPairs:
                        - id: createdToDone
                          from: createdTime
                          to: doneTime
                          labelKey: pair.createdToDone
                          requireStatus:
                            - DONE
                          signed: false
                          suggested: true
                        - id: endToDone
                          from: endTime
                          to: doneTime
                          labelKey: pair.endToDone
                          requireStatus:
                            - DONE
                          signed: true
                          suggested: true
                        - id: startToDone
                          from: startTime
                          to: doneTime
                          labelKey: pair.startToDone
                          requireStatus:
                            - DONE
                          signed: true
                          suggested: true
                        - id: createdToStart
                          from: createdTime
                          to: startTime
                          labelKey: pair.createdToStart
                          requireStatus: null
                          signed: false
                          suggested: true
                        - id: startToEnd
                          from: startTime
                          to: endTime
                          labelKey: pair.startToEnd
                          requireStatus: null
                          signed: false
                          suggested: true
                        - id: createdToEnd
                          from: createdTime
                          to: endTime
                          labelKey: null
                          requireStatus: null
                          signed: false
                          suggested: false
                      ageFields:
                        - field: createdTime
                          labelKey: age_field.createdTime
                          statuses:
                            - UNASSIGNED
                            - ONGOING
                        - field: endTime
                          labelKey: age_field.endTime
                          statuses:
                            - UNASSIGNED
                            - ONGOING
                      bucketPresets:
                        age_default:
                          - key: lt1d
                          - key: 1to3d
                          - key: 3to7d
                          - key: gte7d
        '401':
          description: >-
            Unauthorized - no valid token (`auth-034`), or an authenticated user
            with no organization
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: boolean
                    example: false
                  message:
                    type: string
                    description: Human-readable reason
                  failedCode:
                    type: string
                    description: Structured error code, see Status Codes
              examples:
                response:
                  value:
                    status: false
                    message: Unauthenticated.
                    failedCode: auth-034
        '403':
          description: Forbidden - the caller's role lacks `view/dashboard`
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: boolean
                    example: false
                  message:
                    type: string
                    description: Human-readable reason
                  failedCode:
                    type: string
                    description: Structured error code, see Status Codes
              examples:
                response:
                  value:
                    status: false
                    message: >-
                      Access denied. You do not have permission for view
                      dashboard. Please contact your admin to request access.
                    failedCode: sys-035
        '422':
          description: >-
            Unprocessable - `dataSource` is malformed (`data_source_id_invalid`,
            including a bare 24-hex id) or unknown (`data_source_unknown`: a
            flow or data type that is not the organization's, deleted, a system
            flow or an external data type)
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: boolean
                    example: false
                  message:
                    type: string
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: >-
                          Descriptive string code, e.g. `batch_too_large`,
                          `field_unknown`, `hub_not_allowed`
                      message:
                        type: string
                      field:
                        type: string
                        description: Offending key, when known
              examples:
                response:
                  value:
                    status: false
                    message: Unknown data source 'data:6ae2116a2fd54630640965ff'.
                    error:
                      code: data_source_unknown
                      message: Unknown data source 'data:6ae2116a2fd54630640965ff'.
                      field: dataSourceId
      security:
        - bearerAuth: []
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: Use a valid Bearer token to authenticate.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.