Skip to main content

Crate authora

Crate authora 

Source
Expand description

§Authora SDK for Rust

Official Rust client for the Authora agent authorization platform.

§Quick start

use authora::{AuthoraClient, types::CreateAgentInput};

#[tokio::main]
async fn main() -> Result<(), authora::AuthoraError> {
    let client = AuthoraClient::new("authora_live_...")?;

    let agent = client.agents().create(CreateAgentInput {
        workspace_id: "ws_123".into(),
        name: "my-agent".into(),
        created_by: "user_456".into(),
        ..Default::default()
    }).await?;

    println!("Created agent: {:?}", agent.id);
    Ok(())
}

Re-exports§

pub use client::AuthoraClient;
pub use client::AuthoraClientBuilder;
pub use error::AuthoraError;

Modules§

client
error
http
resources
types