@@ -8,17 +8,17 @@ use crate::output::{
88} ;
99
1010#[ derive( Debug , Serialize ) ]
11- struct ListRestoresQuery {
11+ pub struct ListRestoresQuery {
1212 #[ serde( skip_serializing_if = "Option::is_none" ) ]
13- r#type : Option < String > ,
13+ pub r#type : Option < String > ,
1414 #[ serde( skip_serializing_if = "Option::is_none" ) ]
15- site_id : Option < String > ,
15+ pub site_id : Option < String > ,
1616 #[ serde( skip_serializing_if = "Option::is_none" ) ]
17- environment_id : Option < String > ,
17+ pub environment_id : Option < String > ,
1818 #[ serde( skip_serializing_if = "Option::is_none" ) ]
19- backup_id : Option < String > ,
20- page : u32 ,
21- per_page : u32 ,
19+ pub backup_id : Option < String > ,
20+ pub page : u32 ,
21+ pub per_page : u32 ,
2222}
2323
2424#[ derive( Debug , Serialize ) ]
@@ -29,22 +29,9 @@ struct CreateRestoreRequest {
2929
3030pub fn list (
3131 client : & ApiClient ,
32- site_id : Option < String > ,
33- environment_id : Option < String > ,
34- restore_type : Option < String > ,
35- backup_id : Option < String > ,
36- page : u32 ,
37- per_page : u32 ,
32+ query : ListRestoresQuery ,
3833 format : OutputFormat ,
3934) -> Result < ( ) , ApiError > {
40- let query = ListRestoresQuery {
41- r#type : restore_type,
42- site_id,
43- environment_id,
44- backup_id,
45- page,
46- per_page,
47- } ;
4835 let response: Value = client. get_with_query ( "/api/v1/vector/restores" , & query) ?;
4936
5037 if format == OutputFormat :: Json {
0 commit comments