Expand description
Typed client crate for the documented X-Plane local web API.
- REST API: generated from OpenAPI at build time with Progenitor.
- WebSocket API: typed request/response models and a small async client.
- CLI: optional command-line interface for REST operations.
- Error: shared typed REST error classification helpers.
§Basic REST Example
use xplane_web_api::error::RestClientError;
use xplane_web_api::rest::{Client, DEFAULT_REST_API_BASE_URL};
async fn fetch_capabilities() -> Result<(), RestClientError> {
let client = Client::new(DEFAULT_REST_API_BASE_URL);
let response = client
.get_capabilities()
.await
.map_err(RestClientError::from)?;
println!("{:#?}", response.as_ref());
Ok(())
}