rive_http/authentication/
onboarding.rs1use rive_models::{data::CompleteOnboardingData, onboarding::OnboardingStatus};
2
3use crate::prelude::*;
4
5impl Client {
6 pub async fn check_onboarding_status(&self) -> Result<OnboardingStatus> {
10 Ok(self
11 .client
12 .get(ep!(self, "/onboarding/hello"))
13 .auth(&self.authentication)
14 .send()
15 .await?
16 .process_error()
17 .await?
18 .json()
19 .await?)
20 }
21
22 pub async fn complete_onboarding(&self, data: CompleteOnboardingData) -> Result<()> {
24 self.client
25 .post(ep!(self, "/onboarding/complete"))
26 .json(&data)
27 .auth(&self.authentication)
28 .send()
29 .await?
30 .process_error()
31 .await?;
32 Ok(())
33 }
34}