mirror of
https://codeberg.org/demostf/api-client.git
synced 2026-11-30 03:20:47 +01:00
27 lines
585 B
Markdown
27 lines
585 B
Markdown
# api-client
|
|
|
|

|
|
|
|
Rust api client for demos.tf
|
|
|
|
## Example
|
|
|
|
```rust
|
|
use demostf_client::{ListOrder, ListParams, ApiClient};
|
|
|
|
#[tokio::main]
|
|
async fn main() -> Result<(), demostf_client::Error> {
|
|
let client = ApiClient::new();
|
|
|
|
let demos = client.list(ListParams::default().with_order(ListOrder::Ascending), 1).await?;
|
|
|
|
for demo in demos {
|
|
println!("{}: {}", demo.id, demo.name);
|
|
}
|
|
Ok(())
|
|
}
|
|
```
|
|
|
|
## Contribution guidelines
|
|
|
|
LLM created contributions are not welcome in this project.
|