Tinify API client for Rust
Rust client for the Tinify API, used for TinyPNG and TinyJPG. Tinify compresses your images intelligently. Read more at https://tinify.com.
Documentation
Go to the documentation for the HTTP client.
Status
In currently development.
There are still features of TinyPNG to implement.
To look at all the features of Tinify API: Documentation.
Getting Started
Install the API client with Cargo. Add this to Cargo.toml:
[]
= "0.2.0"
Usage
-
About key
Get an API key from https://tinypng.com/developers
-
Compress from a file
use tinify;
- Compress from an url file
use tinify;
- Compress from a file buffer
use tinify;
use fs;
set_key;
let bytes = read.unwrap;
let buffer = from_buffer.to_buffer;
let save = write;
}
Running tests
cargo test
Contribution
All contributions will be welcomed. Feel free to open any issues or pull requests.