---
title: "Read an object's analytics dashboard: panels, field roles, the strip's collapsed flag, the named view's own dashboard (if any), and the fields panels may bucket on (synthetic $createdAt / $location last)"
method: GET
path: "/crm/objects/{objectName}/analytics"
tags: ["crm"]
---

# Read an object's analytics dashboard: panels, field roles, the strip's collapsed flag, the named view's own dashboard (if any), and the fields panels may bucket on (synthetic $createdAt / $location last)

`GET /crm/objects/{objectName}/analytics`

## Request

- Base URL: `https://www.dench.com/api/v1`
- URL: `https://www.dench.com/api/v1/crm/objects/{objectName}/analytics`
- Auth: one of:
  - HTTP bearer
  - HTTP bearer

Read an object's analytics dashboard: panels, field roles, the strip's collapsed flag, the named view's own dashboard (if any), and the fields panels may bucket on (synthetic $createdAt / $location last).

## Path parameters

- `objectName` string, required

## Query parameters

- `viewName` string: Also return this saved view's own dashboard (viewAnalytics) when it has one.

## Response `200`

Successful response

- object
  - `objectName` string, required
  - `analytics` object, nullable, required
    - `panels` object[], required
      - `id` string, required: Stable id (template panels use `tpl:<template>:<slug>`).
      - `title` string, required
      - `type` 'stat' | 'bar' | 'line' | 'area' | 'donut' | 'funnel' | 'leaderboard' | 'forecast' | 'map', required
      - `metric` 'count' | 'sum' | 'avg' | 'min' | 'max', required
      - `metricField` string: Numeric field for sum/avg/min/max. Ignored for count.
      - `groupBy` string: Bucketing field (enum/user/relation/boolean/text, or $location). On a time-series panel it splits the series into one line per value.
      - `dateField` string: Date field for line/area/forecast bucketing (or $createdAt).
      - `dateBucket` 'day' | 'week' | 'month' | 'quarter'
      - `filters` object: Panel-scoped FilterGroup, same shape as saved-view filters.
      - `size` 'sm' | 'md' | 'lg': Deprecated; ignored for layout. Use `span`.
      - `span` union: Card width on the 6-track dashboard grid: 2 = a third, 3 = half, 4 = two thirds, 6 = full row. Defaults: funnel 4; map and leaderboard 2; bar/donut grouped by a user field 2, by anything else 4; trends 3.
        - 2
        - 3
        - 4
        - 6
      - `hidden` boolean: Hide from the strip above the table; still shown in the full analytics view.
      - `sortOrder` number, required
      - `derived` 'conversion_rate' | 'win_rate' | 'won_amount' | 'lost_amount' | 'open_pipeline' | 'pipeline_forecast' | 'mrr' | 'arr': Role-driven derived metric; when set the panel computes from fieldRoles instead of metric/groupBy.
    - `removedPanelIds` string[]: Template panel ids the user deleted; never resurrected.
    - `fieldRoles` object: The object's analytics setup, shared by every chart and every view: the semantic field roles derived metrics (win rate, won $, open pipeline, forecast, MRR/ARR), maps and card defaults read.
      - `amount` string: Numeric field holding the deal value ("Amount") — the "Value field" in the setup sheet.
      - `stage` string: Enum field driving the pipeline ("Stage" / "Status") — the "Progress field".
      - `wonValues` string[]: `stage` options that count as won (closed, successful).
      - `lostValues` string[]: `stage` options that count as lost (closed, gone).
      - `convertedValues` string[]: `stage` options that count as converted (a lead reached "Qualified").
      - `closeDate` string: Date field for time bucketing, forecasts and the period pill (falls back to $createdAt).
      - `owner` string: User field naming who owns each record ("Owner"). Rankings on it default to a narrow card and draw member faces.
      - `location` string: Place-name field maps plot. May be a relation path like "Account.HQ Location" (one hop through a relation).
      - `recurrence` 'monthly' | 'annual' | 'one_time': How a won amount recurs: annual treats Amount as ARR, monthly as MRR, one_time disables MRR/ARR panels.
      - `stageProbabilities` object: Chance of closing per OPEN stage, 0..1, for the weighted forecast. Unlisted stages are spaced evenly; won = 1, lost = 0.
    - `stripCollapsed` boolean
  - `viewAnalytics` object, nullable, required: The named view's own dashboard, or null when it inherits.
    - `panels` object[], required
      - `id` string, required: Stable id (template panels use `tpl:<template>:<slug>`).
      - `title` string, required
      - `type` 'stat' | 'bar' | 'line' | 'area' | 'donut' | 'funnel' | 'leaderboard' | 'forecast' | 'map', required
      - `metric` 'count' | 'sum' | 'avg' | 'min' | 'max', required
      - `metricField` string: Numeric field for sum/avg/min/max. Ignored for count.
      - `groupBy` string: Bucketing field (enum/user/relation/boolean/text, or $location). On a time-series panel it splits the series into one line per value.
      - `dateField` string: Date field for line/area/forecast bucketing (or $createdAt).
      - `dateBucket` 'day' | 'week' | 'month' | 'quarter'
      - `filters` object: Panel-scoped FilterGroup, same shape as saved-view filters.
      - `size` 'sm' | 'md' | 'lg': Deprecated; ignored for layout. Use `span`.
      - `span` union: Card width on the 6-track dashboard grid: 2 = a third, 3 = half, 4 = two thirds, 6 = full row. Defaults: funnel 4; map and leaderboard 2; bar/donut grouped by a user field 2, by anything else 4; trends 3.
        - 2
        - 3
        - 4
        - 6
      - `hidden` boolean: Hide from the strip above the table; still shown in the full analytics view.
      - `sortOrder` number, required
      - `derived` 'conversion_rate' | 'win_rate' | 'won_amount' | 'lost_amount' | 'open_pipeline' | 'pipeline_forecast' | 'mrr' | 'arr': Role-driven derived metric; when set the panel computes from fieldRoles instead of metric/groupBy.
    - `removedPanelIds` string[]: Template panel ids the user deleted; never resurrected.
  - `viewExists` boolean, required
  - `fields` object[], required
    - `name` string, required
    - `type` string, required
    - `enumValues` string[], nullable, required
    - `enumColors` string[], nullable, required

## Other responses

- `400`: Invalid request
- `401`: Missing or invalid authentication
- `404`: Operation or resource not found
- `500`: Server error

---

[API](https://skmtc.dev/dench/apis/dench-api.md) - [All operations](https://skmtc.dev/dench/apis/dench-api/llms.txt) - [OpenAPI document](https://skmtc.dev/dench/apis/dench-api/revisions/4a145b38f19c?raw)
