Biteship provides a reliable and flexible API service for managing shipments. To maintain the performance and stability of the service, Biteship implements rate limits on API usage in both production and sandbox environments. Rate limits refer to the maximum number of requests that can be sent within a certain period. Understanding these limits is important to ensure your application functions smoothly without interruptions while optimizing the user experience.
What Is Rate Limit?
Rate limit is a restriction on the number of API requests that can be sent within a specific time frame. This limitation is applied to prevent server overload, ensure stable response speed, and maintain service quality.
Rate Limits on Biteship API
Production Environment
| API | Production |
| Maps | 50 requests per second |
| Rates | 20 requests per second |
| Location | 10 requests per second |
| Order | 20 requests per second |
| Tracking | 50 requests per second |
| Draft Order | 20 requests per second |
| Courier | 10 requests per second |
Sandbox Environment
| API | Sandbox |
| Maps | 5 requests per second |
| Rates | 5 requests per second |
| Location | 5 requests per second |
| Order | 5 requests per second |
| Tracking | 5 requests per second |
| Draft Order | 5 requests per second |
| Courier | 5 requests per second |
API Rate Limit in the Sandbox Environment
The sandbox environment is a place for developers to test API features and integrations before launching them in the production environment. Sandbox provides a safe space for simulations without affecting production data.
• Purpose: API integration testing, data verification, and shipment flow simulation.
• Sandbox Rate Limit: Rate limits in the sandbox environment are generally stricter compared to production to reduce load on test servers and monitor uncontrolled testing.
• Example Limit: 100 requests per minute.
• Note: These rate limits may vary depending on testing needs and current policies. Users exceeding the rate limit will receive a 429 Too Many Requests response.
Tips for Optimal Usage in Sandbox:
• Batch Requests: Try sending requests gradually rather than in large batches simultaneously.
• Log Testing Activity: Record your testing activities to avoid unnecessary repeated requests.
• Optimize Testing: Focus testing on important endpoints and simulate real scenarios.
API Rate Limit in the Production Environment
The production environment is where you run real operations with live data. Here, you manage shipments, orders, tracking, and other features to serve your customers.
• Purpose: Manage actual shipments, tracking, and other operational services.
• Production Rate Limit: Rate limits in production are generally more lenient than sandbox to support larger transaction volumes.
• Example Limit: 1000 requests per minute.
• 429 Response: If you exceed the limit, you will receive a 429 Too Many Requests response. To avoid this error, consider implementing retry mechanisms or resend logic.
Tips for Optimal Usage in Production:
• Cache Frequently Used Data: Reducing repeated requests for data that does not change often helps avoid excessive use of rate limits.
• Use Retry Logic: Implement retry mechanisms with delays if you receive a 429 response to ensure smooth operations.
• Monitor API Usage: Use logs or monitoring tools to track API usage in real-time.
Managing and Optimizing Rate Limits
1. Optimize Requests: Only send requests that are truly necessary and combine requests if possible.
2. Use Webhooks for Notifications: Instead of relying on continuous polling, use Biteship’s webhook feature to receive real-time notifications when there are status changes.
3. Consult Support: If you frequently face rate limit restrictions, contact Biteship support at support@biteship.com to discuss your specific needs.
Frequently Asked Questions
• What Happens If I Exceed the Rate Limit?
If you exceed the rate limit, the server will return a 429 Too Many Requests response. Wait a moment before resending your requests.
• Are Rate Limits Different for Each User?
Rate limits may vary depending on the account type or specific agreements made with Biteship.
• How Can I Monitor API Usage?
You can monitor API usage through request logs in your application or by using third-party API monitoring tools for deeper analysis.
If you have further questions, please contact support@biteship.com.