use serde::{Deserialize, Serialize};
use crate::{config::Config, constants::APPLY_APP_TICKET_PATH, SDKResult};
pub async fn apply_app_ticket(config: &Config) -> SDKResult<()> {
let url = format!("{}{}", config.base_url(), APPLY_APP_TICKET_PATH);
let body = ResendAppTicketReq {
app_id: config.app_id().to_string(),
app_secret: config.app_secret().to_string(),
};
let _response = config.http_client().post(&url).json(&body).send().await?;
Ok(())
}
#[derive(Serialize, Deserialize)]
struct ResendAppTicketReq {
app_id: String,
app_secret: String,
}