diff --git a/src/gitlab.rs b/src/gitlab.rs index bd72639075ae9ce69d81af141b3cfcf29313ce7d..b8e417729a628dd0c9fed2706f17620cb8ad7cb6 100644 --- a/src/gitlab.rs +++ b/src/gitlab.rs @@ -727,6 +727,11 @@ impl Gitlab { self.get_paged(&format!("projects/{}/labels", project)) } + /// Get the labels with open/closed/merge requests count + pub fn labels_with_counts(&self, project: ProjectId) -> Result> { + self.get_paged_with_param(&format!("projects/{}/labels", project), vec![("with_counts", "true")]) + } + /// Get label by ID. pub fn label(&self, project: ProjectId, label: LabelId) -> Result