Skip to main content
The RunAgent Rust SDK provides a high-performance interface for interacting with your deployed agents. It supports both synchronous and asynchronous operations with built-in streaming capabilities.

Installation

Add the SDK to your Cargo.toml:

Quick Start

Basic Usage

With Specific Address

Authentication

The SDK automatically uses configuration from the environment or database:

Response Handling

Standard Response

Streaming Response

Error Handling

The SDK provides comprehensive error handling:

Common Error Types

Configuration Options

Framework Examples

LangChain Integration

AutoGen Integration

CrewAI Integration

Best Practices

  • Reuse client instances for multiple requests
  • Handle errors appropriately for production use
  • Use streaming for long responses
  • Configure timeouts based on agent complexity
  • Use structured logging for debugging

Next Steps