#ddnet #teeworlds #api #ddstats

ddapi-rs

A simple Rust library to get data from DDNet and DDStats APIs

15 releases (5 breaking)

0.9.3 Dec 9, 2025
0.9.1 Nov 20, 2025
0.8.1 Oct 30, 2025
0.4.2 May 29, 2025
0.1.3 Nov 30, 2024

#585 in Caching

MIT license

61KB
1.5K SLoC

A simple Rust library to get data from DDNet and DDStats APIs

What is this?

This library lets you easily access:

  • Player stats and rankings
  • Server information
  • Game data from DDNet
  • Statistics from DDStats

Installation

  cargo add ddapi-rs -F ddstats

Quick Example

use ddapi_rs::prelude::*;

#[tokio::main]
async fn main() {
    let ddapi = DDApi::new();
    let player = "ByFox";
    let result = ddapi.s_player(player).await; // ddstats.tw
    println!("{}: {}", player, result.unwrap().url());
}

Features

  • ddstats - Get data from ddstats.tw
  • ddnet - Get data from ddnet.org
  • cache - Memory cache
  • full - All features

Dependencies

~8–25MB
~283K SLoC