Komga Rust SDK
A modern, async Rust client for the Komga REST API, generated and maintained with best practices for real-world use.
Features
- Full async support (tokio-based)
- All Komga API endpoints covered
- File upload support (multipart)
- Strongly typed models
- Native TLS and Rustls support (feature flags)
Documentation
- API Reference: See API.md for the full autogenerated API documentation.
- Komga API Reference:
Installation
Add to your Cargo.toml:
[]
= "1.23.4"
# or, for local development:
# komga-sdk = { path = "./komga-sdk" }
Feature Flags
native-tls(default): Use system TLSrustls-tls: Use Rustls for TLS
Usage Examples
Authentication
use Configuration;
let mut config = new;
config.api_key = Some;
// or for basic auth:
config.basic_auth = Some;
Get Current User
use get_current_user;
let user = get_current_user.await?;
println!;
File Upload Example
use add_user_uploaded_book_thumbnail;
let result = add_user_uploaded_book_thumbnail.await?;
println!;
Testing
- To run tests:
cargo test - For integration tests, you need a running Komga instance (see Komga Docker).
- You may use the public demo server for read-only tests, but write operations require your own instance.
Contributing
Pull requests and issues are welcome! Please see CONTRIBUTING.md if available.
License
MIT
Kudos & Acknowledgements
- Generated using OpenAPI Generator
- Powered by Komga and its open API
- Thanks to all open-source contributors
For the full autogenerated API documentation, see API.md.