🇺🇸 English · 🇨🇳 中文 | Table of Contents ↗️
Tencent Cloud API SDK for Rust. Async-first with an optional blocking client, sharing the same service layer, types and error model. Requests are authenticated using TC3-HMAC-SHA256.
Usage
Add the crate
[]
= "0.1"
= { = "1", = ["macros", "rt-multi-thread"] }
Blocking-only (no Tokio):
[]
= { = "0.1", = false, = ["blocking-rustls"] }
Configure credentials and create clients
use Duration;
use ;
use ;
async
The blocking client mirrors the async API (does not require Tokio):
use ;
Features
- Feature flags
async(default) with TLS backend:rustls(default) ornative-tlsblockingviablocking-rustlsorblocking-native-tls- Optional integrations:
tracing,metrics
- Async-first, optional blocking:
Client(async) +BlockingClient(feature gated), sharing the same services and types. - No HTTP types in public API: the SDK does not expose reqwest/ureq types in public signatures.
- TC3 signing: built-in TC3-HMAC-SHA256 signing with credential redaction in
Debugoutput. - Actionable errors: structured
Errorwith status / request_id / body snippet and service classification.
Implemented Interfaces
-
CVM
- DescribeInstances
- ResetInstancesPassword
- DescribeInstanceVncUrl
- StartInstances
- RebootInstances
- StopInstances
- ModifyInstancesProject
- RunInstances
- TerminateInstances
- DescribeImages
-
Tag
- DescribeProjects
-
Billing
- DescribeAccountBalance
-
CDN
- UpdateDomainConfig (HTTPS certificate switch)
-
DNSPod
- CreateRecord (TXT)
- ModifyRecord (TXT)
- DeleteRecord
-
SSL
- ApplyCertificate
- DescribeCertificate
- DownloadCertificate
- UploadCertificate