Skip to content

Preview Object Report Api

POST
/reports/preview

Run an unsaved report with this credential’s own access and a 10 second budget (nothing partial is returned).

Authorizations

Parameters

Header Parameters

X-Target-Org-Id
Any of:
string

Request Body required

Run an unsaved report with the caller’s own access (the builder’s live preview). No drilldown.

object
as_of
Any of:
string format: date
chart_type
required
string
Allowed values: table bar line funnel stage_over_time time_in_stage
config
required

What a report computes. timezone (an IANA name) fixes how dates are bucketed and what “end of day” means; when absent the organization’s time zone applies (never the server’s).

object
filters
Array<object>
<= 10 items

One filter on a field of the source, or (with relationship_slug) on a field of the contact, company or deal the source points at: the record passes when a linked record it may see matches. in is “is any of” and takes a list of values.

object
attribute_slug
required
string
>= 1 characters <= 100 characters
operator
required
string
Allowed values: eq ne gt gte lt lte contains starts_with is_null is_not_null in
relationship_slug
Any of:
string
>= 1 characters <= 100 characters
value
group_by
Array<object>
<= 3 items

One group-by. attribute: a field of the source (a date or timestamp field needs a grain); related_attribute: a field of the ONE record a single-valued relationship points at; created_at: the record’s creation time, bucketed by grain.

object
attribute_slug
Any of:
string
<= 100 characters
grain
Any of:
string
Allowed values: day week month quarter year
kind
string
default: attribute
Allowed values: attribute related_attribute created_at
relationship_slug
Any of:
string
<= 100 characters
measures
Array<object>
<= 10 items

One measure. count counts each record once (COUNT DISTINCT record id); sum / avg / min / max read a numeric field’s value; related_count counts the live records a relationship links each record to.

object
attribute_slug
Any of:
string
<= 100 characters
kind
required
string
Allowed values: count sum avg min max related_count
label
Any of:
string
>= 1 characters <= 120 characters
relationship_slug
Any of:
string
<= 100 characters
range
Any of:

The calendar range a stage-over-time report snapshots, one column per grain period end (in the report’s time zone).

object
from
required
string format: date
grain
string
default: month
Allowed values: day week month quarter year
to
required
string format: date
stage
Any of:

The stage field and the ORDERED stages a funnel, stage-over-time or time-in-stage report walks.

object
attribute_slug
required
string
>= 1 characters <= 100 characters
order
required
Array<string>
>= 2 items <= 20 items
timezone
Any of:
string
<= 64 characters
object_slug
required
string
>= 1 characters <= 100 characters

Responses

200

Successful Response

object
data
required
object
as_of
Any of:
object
date
required
string format: date
instant
required
string format: date-time
timezone
required
string
chart_limit
integer
default: 20
chart_other
Any of:

What the chart folds into “Other”: every group beyond chart_limit. Only additive measures (count, sum, related_count) are filled in; an average, minimum or maximum cannot be folded and is None.

object
group_count
required
integer
measures
required
object
key
additional properties
Any of:
number
record_count
required
integer
chart_truncated
boolean
chart_type
required
string
Allowed values: table bar line funnel stage_over_time time_in_stage
columns
Array<object>
object
grain
Any of:
string
Allowed values: day week month quarter year
id
required
string
kind
required
string
Allowed values: group_by measure stage gap
label
Any of:
string
restricted
boolean
value_type
Any of:
string
disclosures
Array<string>
gaps
Array<object>
object
component
required
string
kind
string
default: no_history
records
required
integer
history_supported
boolean
default: true
kind
string
default: result
measure_meta
Array<object>

How one measure counts, so a screen can say it in words under the measure (UI-23, PR 3.9). Only for a measure the viewer may see (a restricted one has none). grain: what one unit is, the source’s singular noun (“deployment”) or, for a linked count, the far records’ (“stakeholder”). time_basis: value_at_date a field’s current value, or its value on the as-of day; records_at_date each record that existed then, once; links_today linked records as linked today (links keep no history). unit: a currency field’s ISO code (“USD”); named unit so a result never spells a hidden measure’s type for a viewer who may not see it. visible_to: who may see the measure’s field, told only to an admin AUTHORING the report (a preview), so they learn before sharing that some members will see the measure restricted.

object
grain
required
string
id
required
string
time_basis
required
string
Allowed values: value_at_date records_at_date links_today
unit
Any of:
string
visible_to
Any of:
string
Allowed values: everyone some_roles admins
restricted
Array<object>

A part of a report the viewer may not see. Hidden means ABSENT: it carries no title, no object name, no type and no reason, only its position id (m0 the first measure, g0 the first group-by, f0 the first filter, stage the stage field), so a client can lock that slot in place.

object
id
required
string
restricted
boolean
default: true
row_limit
integer
default: 500
rows
Array<object>
object
drilldown
required
One of: discriminator: kind

One row of a table, bar or line report: the group values in dimension order. gaps[i] is "no_history" when dimension i is the history-gap group of an as-of report. A numeric value a JSON number cannot carry exactly (past 15 significant digits) is its exact decimal text here; echo the target unchanged.

object
gaps
Array
<= 3 items
kind
string
default: group
values
Array
<= 3 items
group
Array<object>
object
gap
Any of:
string
id
required
string
value
key
required
string
measures
object
key
additional properties
Any of:
number
partial
boolean
record_count
integer
unstaged
object
key
additional properties
integer
source
required
object
is_archived
boolean
kind
required
string
Allowed values: object process_list
plural_noun
required
string
singular_noun
required
string
slug
required
string
status
string
default: ok
Allowed values: ok restricted
timezone
required
string
total_base_records
integer
total_groups
integer
totals
Any of:
object
measures
object
key
additional properties
Any of:
number
record_count
required
integer
truncated
boolean
pagination
Any of:
object
has_next
required

Whether there are more pages

boolean
limit
required

Items per page

integer
next_cursor
Any of:
string
notes
Any of:
Array<string>
page
required

Current page number (1-indexed)

integer
total
required

Total number of items

integer
total_available
Any of:
integer
total_is_lower_bound
Any of:
boolean

422

Validation Error

object
detail
Array<object>
object
loc
required
Array
msg
required
string
type
required
string