Crates.io | tencent_sms |
lib.rs | tencent_sms |
version | 0.1.2 |
source | src |
created_at | 2021-01-22 11:44:17.042802 |
updated_at | 2021-06-30 12:22:03.84931 |
description | tencent sms |
homepage | https://github.com/tingfeng-key/tencent_sms |
repository | https://github.com/tingfeng-key/tencent_sms |
max_upload_size | |
id | 345285 |
size | 22,600 |
腾讯云短信发送接口实现
//发送
let response = TencentSms::new(
"secret_id",
"secret_key",
"sdk_app_id",
"template_id",
"sign",
vec![
String::from("+8612345678912"),
String::from("+8612345678913"),
],
vec![String::from("1234"), String::from("5678")],
)
.send()
.await;
//检查是否发送成功
println!(
"{:#?}",
response
.unwrap()
.check_is_success(String::from("+8612345678912"))
);