trace-moe
Rust client for the trace.moe anime scene search API.
Features
- Simple async client built on
reqwest - Search by image URL or upload bytes
- Optional AniList info in results
- Query your quota/limits via
me
Install
Quickstart
use ;
async
Usage
Authentication
- API key is optional for low-volume usage. For higher quotas, set
TRACE_MOE_API_KEYand usenew_client_with_key(Some(key)). - The client sends the key as
x-trace-key.
Search by URL
let query = SearchQuery ;
let results: SearchResponse = client.tracemoe_search_by_url.await?;
Upload bytes
let bytes = read?;
let results: SearchResponse = client.tracemoe_search_upload.await?;
Check quota/limits
let me = client.tracemoe_me.await?;
println!;
API Overview
new_client_with_key(Option<&str>) -> ClientClient::tracemoe_search_by_url(&SearchQuery) -> SearchResponse<TAnilist>Client::tracemoe_search_upload(bytes) -> SearchResponse<TAnilist>Client::tracemoe_me() -> MeResponse- Types:
SearchQuery,SearchResponse<TAnilist>,SearchResult<TAnilist>,Episode,AnilistInfo,AnilistInfoTitle,MeResponse
Docs: https://docs.rs/trace-moe
Examples
Run the included example:
# with API key
TRACE_MOE_API_KEY=your_key
License
Licensed under MIT.