CKANDex

crates.io

A rust-powered NetKAN resolver and indexer library, for both KSP 1 and KSP 2.

About

This library was created for the Wormhole project, as we needed a way to query and list mods in CKAN's NetKAN database. However, there wasn't an easy API to do this, as the NetKAN database is essentially a ton of JSON and YAML files crammed into a bunch of folders, so we had to develop our own solution.

Features

Example

Here's an example of CKANDex in action:

```rs use tokio::main; use ckandex::CKANDex;

[main]

pub async fn main() { let ckan = CKANDex::new().update().await;

let res = ckan.filter_mods("wasd");
let mut item = ckan.find_mod(res.nth(0).unwrap().name.unwrap());

item.resolve_download().await;

println!("Found mod: {:?}", item);

} ```

For more examples, check out the example/ folder in this repo.

Contributing

This library is still WIP! Please don't be afraid to make feature requests, pull requests, and anything else. If you have any questions, or you have found any bugs, please create an issue! I'll be happy to help as soon as I can.

Code Style

The code style is as follows: