Build a DORA report
This walkthrough pulls DORA metrics for a set of repositories end to end: discover the repositories and teams to scope by, query the metrics, and interpret the results. It uses only endpoints in the public API.
Assumes you already have a GitKraken API key — if not, see Authentication.
Export your key for the session so the examples below can use it:
export GK_TOKEN="gk_tkn_xxxxxxxxxxxxxxxx"
1. Find the repositories to scope by
List the repositories available to your organization:
curl "https://staging-api.gitkraken.dev/v1/insights/repositories?page=1&pageSize=50" \
-H "Authorization: Bearer $GK_TOKEN"
Optionally list teams to scope the report to a team:
curl "https://staging-api.gitkraken.dev/v1/insights/teams" \
-H "Authorization: Bearer $GK_TOKEN"
Note the repository (or team) identifiers you want to include.
2. Query a DORA metric
Fetch a specific metric — here, deployment frequency — over a date range:
curl "https://staging-api.gitkraken.dev/v1/insights/dora/deploy_frequency?startDate=2026-08-01&endDate=2026-08-31" \
-H "Authorization: Bearer $GK_TOKEN"
Then fetch the summary for the same window to get headline figures:
curl "https://staging-api.gitkraken.dev/v1/insights/dora/deploy_frequency/summary?startDate=2026-08-01&endDate=2026-08-31" \
-H "Authorization: Bearer $GK_TOKEN"
Repeat for the other DORA metrics you want in the report (for example
change_lead_time, change_failure_rate, mean_time_to_recover). See the
API Reference for the full list of metric values and query parameters.
3. Interpret the response
Metric data is returned under the data envelope; time-bucketed series come
back as arrays you can chart or aggregate. Pair each metric with its /summary
for the headline number, and paginate list endpoints via page/pageSize.
Where to go next
- Full metric list and parameters: API Reference (top navigation)
- Authentication — key lifecycle and rate limits