#client-instance #api-client #social

instances-social

API Client for the instances.social API

5 stable releases

2.0.0 Feb 26, 2019
1.1.0 Feb 22, 2019
1.0.2 Feb 21, 2019
1.0.1 Feb 20, 2019

#5 in #client-instance

AGPL-3.0

52KB
622 lines

instances.social API client

this is a rust client for the https://instances.social API

installation

add the following to your Cargo.toml:

[dependencies]
instances_social = "1"

usage

// src/main.rs

use instances_social::Client;

fn main() {
    let client = Client::new(API_TOKEN);
    let instance_list = client.instances().list().expect();
}

lib.rs:

Rust API client for the instances.social API

use instances_social::Client;

const TOKEN: &'static str = "...";

fn main() {
let client = Client::new(TOKEN);
// all the API calls are available like this:
//
// client.instances().list()
// client.instances().sample()
// client.instances().search()
// client.instances().show()
// client.versions().list()
// client.versions().show()
}

Dependencies

~23MB
~496K SLoC