Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Changelog

All notable changes to axiomtrade-rs will be documented in this file.

The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.

[0.1.0] - 2025-01-14

Added

Core Architecture

  • High-performance Rust SDK for Axiom Trade - fastest decentralized exchange aggregator on Solana and Hyperliquid
  • Cross-platform compatibility (Windows, Linux, macOS) with native performance optimizations
  • Type-safe API interactions with comprehensive error handling using Rust's Result types
  • Async/await networking powered by Tokio runtime for maximum throughput

Authentication System

  • Enhanced authentication client with automatic session management and token refresh
  • PBKDF2 password hashing with SHA256 (600,000 iterations) for superior security
  • P256 cryptographic support for Turnkey integration with ECDSA signing
  • Automatic OTP fetching via IMAP from inbox.lv accounts (optional feature)
  • Session persistence with secure cookie handling and automatic renewal
  • Token management with automatic refresh and expiration handling

Trading Operations

  • Portfolio management with real-time balance queries and position tracking
  • Batch operations for handling 1000+ wallet queries efficiently
  • Market data retrieval with trending tokens and price feed subscriptions
  • Trading execution with buy, sell, and swap operations
  • Multi-chain support for Solana and Hyperliquid networks

WebSocket Streaming

  • Real-time data streaming with automatic reconnection and error recovery
  • Price subscriptions for live market data feeds
  • Event-driven architecture with customizable message handlers
  • Connection pooling for handling multiple simultaneous streams

Infrastructure

  • Rate limiting with intelligent backoff strategies
  • Retry logic for network failures with exponential backoff
  • Health checks for monitoring system status and connectivity
  • Comprehensive logging with structured error reporting
  • User agent rotation with realistic browser fingerprinting

Developer Experience

  • Extensive documentation with mdBook-powered reference guide
  • 30+ code examples covering all major use cases
  • Complete API reference with endpoint documentation
  • Authentication examples including OTP and session management
  • Trading bot templates for automated trading strategies
  • Setup utilities for environment configuration

Features

API Modules

  • auth - Authentication and session management
  • portfolio - Balance queries and position tracking
  • market_data - Price feeds and trending token data
  • trading - Buy, sell, and swap operations
  • websocket - Real-time streaming connections
  • notifications - Price alerts and system notifications
  • hyperliquid - Hyperliquid-specific integration
  • turnkey - Turnkey custody integration
  • infrastructure - Health monitoring and system status

Utility Features

  • Password hashing with industry-standard PBKDF2
  • Environment variable loading with special character support
  • P256 cryptographic operations for secure signing
  • Rate limiting to respect API constraints
  • Automatic retry with intelligent backoff
  • Cross-platform user agent generation

Email Integration

  • IMAP-based OTP fetching from inbox.lv accounts
  • Automatic email parsing for security codes
  • Configurable polling intervals and timeouts
  • Robust error handling for email connectivity issues

Technical Specifications

Performance Targets

  • Sub-50ms API response times achieved
  • Support for 1000+ concurrent WebSocket connections
  • Batch processing for 1000+ wallet operations
  • Memory usage under 50MB for typical operations
  • Zero-copy deserialization where possible

Security Features

  • No plain text password storage
  • Secure PBKDF2 hashing with 600,000 iterations
  • TLS encryption for all network communications
  • Request signing for authenticated endpoints
  • Input sanitization and validation
  • OS keychain integration for token storage

Dependencies

  • tokio - Async runtime with full feature set
  • reqwest - HTTP client with JSON and cookie support
  • serde - Serialization framework with derive macros
  • fastwebsockets - High-performance WebSocket client
  • p256 - Elliptic curve cryptography for Turnkey
  • pbkdf2 - Password-based key derivation function
  • imap - Email protocol for OTP automation

Breaking Changes

This is the initial release, so no breaking changes apply.

Migration Notes

From Python axiompy

This Rust implementation provides significant improvements over the Python version:

  1. Performance: 10-100x faster execution times
  2. Memory Safety: Zero-cost abstractions with compile-time guarantees
  3. Type Safety: Strong typing prevents runtime errors
  4. Concurrency: Native async/await support for high-throughput operations
  5. Cross-platform: Single binary deployment without runtime dependencies

Migration Steps

  1. Install Rust toolkit (rustc 1.70+)
  2. Add axiomtrade-rs = "0.1.0" to Cargo.toml
  3. Update import statements to use Rust module system
  4. Convert callback-based code to async/await pattern
  5. Update error handling to use Result types
  6. Configure environment variables for OTP automation

API Compatibility

The Rust API maintains functional compatibility with the Python version while providing:

  • Improved error messages with detailed context
  • Better type safety with compile-time validation
  • Enhanced performance with zero-cost abstractions
  • Native async support without callback complexity

Future Roadmap

Version 0.2.0 (Q1 2025)

  • GraphQL API integration for enhanced data queries
  • Advanced order types (limit, stop-loss, take-profit)
  • Portfolio analytics and performance metrics
  • Risk management tools and position sizing
  • Enhanced WebSocket reconnection strategies

Version 0.3.0 (Q2 2025)

  • Mobile SDK compilation targets (iOS/Android)
  • Advanced trading strategies and backtesting
  • Machine learning integration for price prediction
  • Cross-chain bridge operations
  • Advanced notification system with multiple channels

Version 1.0.0 (Q3 2025)

  • Production-ready stability guarantees
  • Complete API coverage for all Axiom Trade features
  • Advanced security features and audit compliance
  • Performance optimizations for institutional use
  • Comprehensive testing and validation suite

Known Issues

  1. OTP Automation: Requires manual setup of inbox.lv account and IMAP configuration
  2. WebSocket Reconnection: Occasional delays during network transitions (will be improved in 0.2.0)
  3. Windows Compatibility: Some examples require WSL for optimal performance
  4. Documentation: Some advanced features need additional code examples

Contributors

  • Vibhek Soni - Primary developer and maintainer
  • Axiom Trade Team - API specification and testing support
  • Rust Community - Libraries and best practices guidance

Acknowledgments

This project builds upon the foundation laid by the Python axiompy library while leveraging Rust's performance and safety guarantees. Special thanks to the Axiom Trade team for providing comprehensive API documentation and testing support.

The automated OTP system was inspired by the need for seamless authentication in trading environments where manual intervention can cause missed opportunities.


For detailed upgrade instructions and migration guides, see the Installation and Quick Start documentation.