Skip to content

User Guides

These guides cover common patterns and best practices for working with SandBase in production.

Available Guides

GuideDescription
Model RoutingHow SandBase routes requests across providers — fallback chains, priority-based routing, and capability-aware selection
StreamingSSE protocol details, OpenAI vs Anthropic streaming formats, and client-side handling
Error HandlingRetry strategies, exponential backoff, circuit breaker patterns, and idempotency
Rate LimitingUnderstanding rate limit headers, handling 429 responses, and high-throughput best practices
Billing & PricingCredit system, top-up flow, per-model pricing, usage tracking, and cost optimization

Quick Tips

  • Use streaming for chat interfaces — it reduces perceived latency significantly
  • Implement retries with backoff — transient errors from upstream providers are normal
  • Monitor your usage — the dashboard shows real-time token consumption and costs
  • Choose models wisely — smaller models (GPT-4o Mini, Claude 3.5 Haiku) are 10-50x cheaper for simple tasks