Rust
Install
cargo add antd-clientConnect to the daemon
use antd_client::{Client, DEFAULT_BASE_URL, discover_daemon_url};
use std::time::Duration;
// Default REST client
let client = Client::new(DEFAULT_BASE_URL);
// Use discovered URL if available
let discovered = discover_daemon_url().unwrap_or_else(|| DEFAULT_BASE_URL.to_string());
let discovered_client = Client::new(&discovered);
// Custom timeout
let slow_client = Client::with_timeout(DEFAULT_BASE_URL, Duration::from_secs(30));Store and retrieve data
Type mappings
Autonomi type
Rust type
Error handling
Full API reference
Last updated