Skip to content

Get the sales pipeline report

GET
/reports/pipeline
Code sample: Shell / cURL
curl --request GET \
--url 'https://example.com/api/v1/reports/pipeline?from=example&to=example' \
--header 'Authorization: Bearer <token>'

What is open and in which stage, the weighted forecast, per-stage conversion and dwell time, win rate, mean sales cycle and loss reasons. Amounts are grouped by currency (the company’s own, else the workspace’s) and never summed across currencies. A stage with no default probability is left out of the weighted figure rather than counted as zero. from and to are workspace-timezone days, to inclusive. Requires the deals.view permission and both the Sales and Reports modules. Without deals.view_all the report covers only the deals the caller owns or reaches through a company they can see.

from
required

Start of the period, YYYY-MM-DD, in the workspace timezone.

string
/^\d{4}-\d{2}-\d{2}$/

Start of the period, YYYY-MM-DD, in the workspace timezone.

to
required

End of the period, YYYY-MM-DD, inclusive.

string
/^\d{4}-\d{2}-\d{2}$/

End of the period, YYYY-MM-DD, inclusive.

ownerId

Only deals owned by this member.

string

Only deals owned by this member.

leadSourceId

Only deals attributed to this lead source.

string

Only deals attributed to this lead source.

lostReasonId

Only deals lost for this reason, an id from the lost reasons list. Open and won deals carry no reason, so the report then covers just those lost deals.

string
>= 1 characters

Only deals lost for this reason, an id from the lost reasons list. Open and won deals carry no reason, so the report then covers just those lost deals.

Open pipeline, conversion by stage, and the closed figures for the period.

Media typeapplication/json
object
data
required

Open figures are a snapshot of now; won, lost and cycle figures cover the deals closed inside the period.

object
byOwner
required
Array<object>

Open deals owned by one member.

object
amounts
required
Array<object>

An amount in a single currency.

object
amount
required

Sum in that currency, rounded to cents.

number
currency
required

The company’s own currency, or the workspace’s when the company has none. Never converted.

string
deals
required
integer
>= -9007199254740991 <= 9007199254740991
ownerId
required
string
ownerName
required
string
weightedAmounts
required
Array<object>

An amount in a single currency.

object
amount
required

Sum in that currency, rounded to cents.

number
currency
required

The company’s own currency, or the workspace’s when the company has none. Never converted.

string
byStage
required
Array<object>

Open deals in one stage.

object
amounts
required
Array<object>

An amount in a single currency.

object
amount
required

Sum in that currency, rounded to cents.

number
currency
required

The company’s own currency, or the workspace’s when the company has none. Never converted.

string
color
required
string
deals
required
integer
>= -9007199254740991 <= 9007199254740991
probability
required

The stage’s default probability. Null when the stage carries none.

number | null
sortOrder
required
integer
>= -9007199254740991 <= 9007199254740991
stageId
required
string
stageName
required
string
weightedAmounts
required

Amounts times the stage probability. Empty when the stage has no probability.

Array<object>

An amount in a single currency.

object
amount
required

Sum in that currency, rounded to cents.

number
currency
required

The company’s own currency, or the workspace’s when the company has none. Never converted.

string
conversion
required
Array<object>

How deals moved through one stage.

object
conversionRate
required

Percent of entered deals that advanced, one decimal. Null when none entered.

number | null
dealsAdvanced
required

Of those, the deals that left it for a later stage or for a WON one.

integer
>= -9007199254740991 <= 9007199254740991
dealsEntered
required

Distinct deals that entered the stage inside the period.

integer
>= -9007199254740991 <= 9007199254740991
deleted
required
boolean
meanDaysInStage
required

Mean length of every stay that ended by the end of the period, one decimal. Null when none ended.

number | null
sortOrder
required
integer
>= -9007199254740991 <= 9007199254740991
stageId
required

The stage id, or deleted:<name> for a stage deleted since, which keeps its history under the name its moves recorded.

string
stageName
required
string
lossReasons
required

Lost deals grouped by their lost reason. A deal lost before reasons existed is grouped by the text it was given, or Not given when it has none.

Array<object>
object
deals
required
integer
>= -9007199254740991 <= 9007199254740991
reason
required
string
lostDeals
required
integer
>= -9007199254740991 <= 9007199254740991
meanSalesCycleDays
required

Mean days from creation to won for the deals won in the period.

number | null
openAmounts
required
Array<object>

An amount in a single currency.

object
amount
required

Sum in that currency, rounded to cents.

number
currency
required

The company’s own currency, or the workspace’s when the company has none. Never converted.

string
openDeals
required
integer
>= -9007199254740991 <= 9007199254740991
openWeightedAmounts
required

Open amounts times each stage’s probability. A stage with no probability is left out rather than counted as zero.

Array<object>

An amount in a single currency.

object
amount
required

Sum in that currency, rounded to cents.

number
currency
required

The company’s own currency, or the workspace’s when the company has none. Never converted.

string
winRate
required

Percent of the deals closed in the period that were won. Null when none closed.

number | null
wonAmounts
required

Won value in the period, from the accepted amount when one was recorded.

Array<object>

An amount in a single currency.

object
amount
required

Sum in that currency, rounded to cents.

number
currency
required

The company’s own currency, or the workspace’s when the company has none. Never converted.

string
wonDeals
required
integer
>= -9007199254740991 <= 9007199254740991

Example generated

{
"data": {
"byOwner": [
{
"amounts": [
{
"amount": 1,
"currency": "example"
}
],
"deals": 1,
"ownerId": "example",
"ownerName": "example",
"weightedAmounts": [
{
"amount": 1,
"currency": "example"
}
]
}
],
"byStage": [
{
"amounts": [
{
"amount": 1,
"currency": "example"
}
],
"color": "example",
"deals": 1,
"probability": 1,
"sortOrder": 1,
"stageId": "example",
"stageName": "example",
"weightedAmounts": [
{
"amount": 1,
"currency": "example"
}
]
}
],
"conversion": [
{
"conversionRate": 1,
"dealsAdvanced": 1,
"dealsEntered": 1,
"deleted": true,
"meanDaysInStage": 1,
"sortOrder": 1,
"stageId": "example",
"stageName": "example"
}
],
"lossReasons": [
{
"deals": 1,
"reason": "example"
}
],
"lostDeals": 1,
"meanSalesCycleDays": 1,
"openAmounts": [
{
"amount": 1,
"currency": "example"
}
],
"openDeals": 1,
"openWeightedAmounts": [
{
"amount": 1,
"currency": "example"
}
],
"winRate": 1,
"wonAmounts": [
{
"amount": 1,
"currency": "example"
}
],
"wonDeals": 1
}
}

Validation error. Parse failures include field paths and expectations.

Media typeapplication/json

Validation error with safe field paths and expected values; submitted values are never returned.

object
error
required
object
code
required

Stable machine-readable error code.

string
issues
Array<object>
object
expected
required
string
message
required
string
path
required
Array<string | number>
message
required

Human-readable error message.

string
status
required

HTTP status code, mirrored in the body.

integer
>= -9007199254740991 <= 9007199254740991

Example

{
"error": {
"code": "UNAUTHORIZED"
}
}

Unauthorized.

Media typeapplication/json

Standard error envelope.

object
error
required
object
code
required

Stable machine-readable error code.

string
message
required

Human-readable error message.

string
status
required

HTTP status code, mirrored in the body.

integer
>= -9007199254740991 <= 9007199254740991

Example

{
"error": {
"code": "UNAUTHORIZED"
}
}

Missing the deals.view permission.

Media typeapplication/json

Standard error envelope.

object
error
required
object
code
required

Stable machine-readable error code.

string
message
required

Human-readable error message.

string
status
required

HTTP status code, mirrored in the body.

integer
>= -9007199254740991 <= 9007199254740991

Example

{
"error": {
"code": "UNAUTHORIZED"
}
}

The Sales or Reports module is turned off for the workspace.

Media typeapplication/json

Standard error envelope.

object
error
required
object
code
required

Stable machine-readable error code.

string
message
required

Human-readable error message.

string
status
required

HTTP status code, mirrored in the body.

integer
>= -9007199254740991 <= 9007199254740991

Example

{
"error": {
"code": "UNAUTHORIZED"
}
}

Rate limit exceeded. Wait for Retry-After before retrying.

Media typeapplication/json

Standard error envelope.

object
error
required
object
code
required

Stable machine-readable error code.

string
message
required

Human-readable error message.

string
status
required

HTTP status code, mirrored in the body.

integer
>= -9007199254740991 <= 9007199254740991

Example

{
"error": {
"code": "UNAUTHORIZED"
}
}
RateLimit-Limit
string
/^\d+$/

Maximum requests in the current quota window.

RateLimit-Policy
string

Quota policy in requests and window seconds, for example 60;w=60.

RateLimit-Remaining
string
/^\d+$/

Requests left in this quota window (zero when blocked).

RateLimit-Reset
string
/^\d+$/

Seconds until the current quota window resets, when available from the rate-limit store.

Retry-After
string
/^\d+$/

Seconds until another request may be attempted.