Build your first custom router with load balancing, caching, and rate limiting in 5 minutes
http://localhost:8080/router/{name}
ai-gateway-config.yaml
:
my-router
http://localhost:8080/router/my-router
Save the configuration
ai-gateway-config.yaml
in your current directory.Restart the gateway
Test your router
Update your configuration
ai-gateway-config.yaml
with the configuration above.Restart the gateway
Test caching
sk-helicone-
)Router | Endpoint | Rate Limit | Use Case |
---|---|---|---|
production | /router/production... | 1000/min | High-traffic customer requests |
development | /router/development... | 100/hour | Cost-controlled development |
Update configuration
ai-gateway-config.yaml
with the multi-environment config above.Restart the gateway
Test your routers