ephemeris_forge_github/api/operations/
labels.rs1use ephemeris_forge::{LabelColor, RepoRef};
2
3use crate::api::error::ForgeError;
4use crate::api::model::Label;
5
6pub trait LabelsApi {
8 fn create_label(
10 &self,
11 repository: &RepoRef,
12 name: &str,
13 color: &LabelColor,
14 description: &str,
15 ) -> impl Future<Output = Result<(), ForgeError>> + Send;
16
17 fn delete_label(
19 &self,
20 repository: &RepoRef,
21 name: &str,
22 ) -> impl Future<Output = Result<(), ForgeError>> + Send;
23
24 fn labels(
26 &self,
27 repository: &RepoRef,
28 ) -> impl Future<Output = Result<Vec<Label>, ForgeError>> + Send;
29
30 fn update_label(
32 &self,
33 repository: &RepoRef,
34 name: &str,
35 color: &LabelColor,
36 description: &str,
37 ) -> impl Future<Output = Result<(), ForgeError>> + Send;
38}