azure_devops/projects/methods/list.rs
1use super::super::models::ProjectList;
2use super::super::ProjectsClient;
3use crate::constants::ApiPath;
4use crate::error::Result;
5
6impl ProjectsClient<'_> {
7 /// List all projects in the organization.
8 ///
9 /// # Returns
10 ///
11 /// A [`ProjectList`] containing a `count` and `value` vector of
12 /// [`ProjectReference`](crate::projects::models::ProjectReference) objects.
13 pub async fn list(&self) -> Result<ProjectList> {
14 self.http.get(&ApiPath::projects(), &[]).await
15 }
16}