API Reference
Log In
API Reference

Get PRs by department, per day

Returns a daily merged-PR series (both github and gitlab sources combined) for the organization, one call for the whole [startDate, endDate] range. Without groupBy, returns the plain workspace daily total (one row per UTC calendar day). With groupBy=orgUnit, returns one row per (day, department) instead, using the point-in-time department the merging user belonged to on that day (SubscriberDirectoryLink -> OrgUnitMembership, valid_from inclusive / valid_to exclusive, primary membership only) -- a mid-range department transfer splits correctly by day. Users who never resolve to a department are bucketed under orgUnitId=null, orgUnitName="Unassigned" rather than dropped, so grouped totals still reconcile against the ungrouped total. orgUnitId scopes the result to that department's subtree (includeDescendants=true) or that department alone (false, the default); the Unassigned bucket is excluded whenever orgUnitId is set, since an unresolved user cannot be "under" a specific department. Capped at 35 days per request, matching granularity=day above. There is no commits field: this reconciles by construction against getVcsPrsSummary's merged-PR totals, which is the only per-day PR source with department attribution today.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Query Params
date
required

Start date (ISO yyyy-MM-dd)

date
required

End date (ISO yyyy-MM-dd)

string

When set to 'orgUnit', returns one row per (day, department) instead of the plain daily total. Only 'orgUnit' is supported.

int64

Scope the result to a single department (and, with includeDescendants, its subtree). Must belong to the caller's organization.

boolean
Defaults to false

When orgUnitId is set, also include its descendant departments. Ignored when orgUnitId is omitted.

Headers
string
enum
Defaults to application/json

Generated from available response content types

Allowed:
Responses

Language
Credentials
Header
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json
*/*