Skip to main content

nil_client/client/cheat/
behavior.rs

1// Copyright (C) Call of Nil contributors
2// SPDX-License-Identifier: AGPL-3.0-only
3
4use crate::client::Client;
5use crate::error::Result;
6use crate::http;
7use nil_core::behavior::build::BuildStep;
8use nil_payload::cheat::behavior::*;
9
10impl Client {
11  pub async fn cheat_get_build_steps(
12    &self,
13    req: CheatGetBuildStepsRequest,
14  ) -> Result<Vec<BuildStep>> {
15    http::json_post("cheat-get-build-steps")
16      .body(req)
17      .server(self.server)
18      .maybe_authorization(self.authorization.as_ref())
19      .user_agent(&self.user_agent)
20      .send()
21      .await
22  }
23}