Struct fractal_api::ClientV1 [] [src]

pub struct ClientV1 {
    // some fields omitted
}

The client struct.

This struct will be in charge of connections to the Fractal Global Credits API.

Methods

impl ClientV1
[src]

fn new() -> ClientV1

Creates a new Fractal Global Credits API client.

fn new_with_url<S: AsRef<str>>(url: S) -> ClientV1

Creates a new Fractal Global Credits API client.

fn new_dev() -> ClientV1

Creates a new Fractal Global Credits API development client.

fn set_read_timeout(&mut self, timeout: Option<Duration>)

Sets the read timeout for requests.

fn set_write_timeout(&mut self, timeout: Option<Duration>)

Sets the write timeout for requests.

fn token<S: AsRef<str>>(&self, app_id: S, secret: S) -> Result<AccessToken>

Gets a token from the API.

fn get_all_users(&self, access_token: AccessToken) -> Result<Vec<User>>

Gets all users from the database.