sideko_rest_api 0.9.2

Rust API Client
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#[serial_test::serial]
#[tokio::test]
async fn test_create_200_success_all_params() {
    let mut client = sideko_rest_api::SidekoClient::default()
        .with_api_key_auth("API_KEY")
        .with_cookie_auth("API_KEY")
        .with_environment(sideko_rest_api::Environment::MockServer);
    let res = client
        .sdk()
        .doc()
        .create(sideko_rest_api::resources::sdk::doc::CreateRequest {
            modules_filter: Some(vec!["user.admin".to_string()]),
            sdk_id: "h1jasdf123".to_string(),
        })
        .await;
    println!("{res:?}");
    assert!(res.is_ok());
}