Skip to content

Depot portaldashboard

Registers GET …/dashboard and …/dashboard/data.

This page is generated from the Depot route table. Every operation carries the permission it needs and the anchor an agent can link to.

GET /api/portal/v1/orgs/{clientID}/dashboard

Section titled “GET /api/portal/v1/orgs/{clientID}/dashboard”

GETportal facemspIdempotent

Source: [object Object]

portalDashboard answers the template’s name and its portal-safe definition.

NameInTypeRequiredDescription
clientIDpathstringYes
StatusBodyDescription
200application/json, PortalDashboardSuccess.
404application/problem+json, ProblemDetailsThis organization has no dashboard.
500application/problem+json, ProblemDetailsCould not read the dashboard.

200 response body

FieldTypeDescription
definitionrequiredDefinition

Definition is the stored dashboard ("Dashboard"."DefinitionJson").

definition.rangerequiredRange

Range is a preset, or custom with RFC3339 From and To.

definition.range.fromstring
definition.range.presetrequiredstring
definition.range.tostring
definition.versionrequiredinteger
definition.widgetsrequiredarray of Widget
definition.widgets[].chartstring
definition.widgets[].comparestring
definition.widgets[].drillboolean or null
definition.widgets[].idrequiredstring
definition.widgets[].kindrequiredstring
definition.widgets[].layoutrequiredLayout

Layout is library-neutral, on 12 columns (D16).

definition.widgets[].layout.hrequiredinteger
definition.widgets[].layout.wrequiredinteger
definition.widgets[].layout.xrequiredinteger
definition.widgets[].layout.yrequiredinteger
definition.widgets[].mineboolean
definition.widgets[].rangeRange

Range is a preset, or custom with RFC3339 From and To.

definition.widgets[].range.fromstring
definition.widgets[].range.presetrequiredstring
definition.widgets[].range.tostring
definition.widgets[].sourcerequiredSource

Source is one struct with a Type discriminator (D2).

definition.widgets[].source.asstring, one of count, list
definition.widgets[].source.bucketBucket

Bucket mirrors reporting.Bucket without the time zone, which comes from the request (D3).

definition.widgets[].source.columnsarray of string
definition.widgets[].source.datasetstring
definition.widgets[].source.filtersarray of Filter
definition.widgets[].source.groupBystring
definition.widgets[].source.keystring
definition.widgets[].source.limitinteger
definition.widgets[].source.metricMetric

Metric mirrors reporting.Metric with JSON tags (D15).

definition.widgets[].source.paramsobject
definition.widgets[].source.queryobject
definition.widgets[].source.sortarray of SortKey
definition.widgets[].source.surfacestring
definition.widgets[].source.typerequiredstring
definition.widgets[].source.viewIdstring
definition.widgets[].source.viewNamestring
definition.widgets[].targetnumber or null

double.

definition.widgets[].thresholdsThresholds

Thresholds (D4).

definition.widgets[].thresholds.badrequirednumber

double.

definition.widgets[].thresholds.basisrequiredstring
definition.widgets[].thresholds.directionrequiredstring
definition.widgets[].thresholds.warnrequirednumber

double.

definition.widgets[].titlerequiredstring
namerequiredstring
Terminal window
# Sign in first. __Host-portal_session is a session cookie, so send it with every request.
# This operation is idempotent. Repeating it does not repeat its effect.
curl -X GET 'https://depot.example.com/api/portal/v1/orgs/<clientID>/dashboard' \
-H 'X-Csrf-Token: <portal-csrf>' \
-H 'Accept: application/json' \
-b '__Host-portal_session=<portal-session>'

GET /api/portal/v1/orgs/{clientID}/dashboard/data

Section titled “GET /api/portal/v1/orgs/{clientID}/dashboard/data”

GETportal facemspIdempotent

Source: [object Object]

portalDashboardData answers the D7 body for the org, read as the member.

NameInTypeRequiredDescription
clientIDpathstringYes
fromquerystringNo
rangequerystringNo
toquerystringNo
tzquerystringNo
StatusBodyDescription
200application/json, DataSuccess.
404application/problem+json, ProblemDetailsThis organization has no dashboard.
500application/problem+json, ProblemDetailsCould not read the dashboard.

200 response body

FieldTypeDescription
fleetEmptyboolean
generatedAtrequiredstring (date-time)
rangerequiredDataRange

DataRange is the resolved dashboard range.

range.fromrequiredstring (date-time)
range.torequiredstring (date-time)
scoperequiredDataScope

DataScope drives the "9 of 12 clients" banner.

scope.clientNamestring
scope.clientsrequiredinteger
scope.kindrequiredstring, one of client, practice
scope.unavailableClientsrequiredarray of string
widgetsrequiredobject
Terminal window
# Sign in first. __Host-portal_session is a session cookie, so send it with every request.
# This operation is idempotent. Repeating it does not repeat its effect.
curl -X GET 'https://depot.example.com/api/portal/v1/orgs/<clientID>/dashboard/data?from=<from>&range=<range>&to=<to>&tz=<tz>' \
-H 'X-Csrf-Token: <portal-csrf>' \
-H 'Accept: application/json' \
-b '__Host-portal_session=<portal-session>'

Content is licensed CC BY 4.0. Code samples are MIT. Outpost and the Outpost mark are trademarks of Outpost Business Solutions, PBC and are not covered by either license.