In most cases, you can use the Metrics API to get information for your coding metrics. However, you may have a need to extract other data about your commits from the Commits API directly.
Who can use this?
Core | Plus | ||
✓ |
Note: If you want to see values for Efficiency, Coding days, Commits per day, or Impact, use the Metrics API. Use the Commit API for other information like finding a list of commits or seeing the HALOC of specific commits.
If you use this API to gather commit data, here are some filters we recommend you use to have the data most closely match the data you’d see in Flow reports. You can use other filters as needed.
The standard filters to use are:
is_merge
=falseexclude_outliers
=truesmart_dedupe
=trueis_trivial
=falseis_pr_orphan
=falseexclude_blocked
=true
Note: Make sure you filter by author_date
and not committer_date
. While committer dates and author dates are usually the same, in some cases, they can differ greatly. Flow reports use author_date
.
If you have no rules set for advanced outlier detection, set:
haloc_lt
=1000
Note: If your development process includes squashing and merging, you may see pre-squashed commits returned from the Commits API. These deleted commits cannot be filtered out of the API response.
If you need help, please contact Pluralsight Support.