Environments
The 3PLGuys API provides two separate environments. Use sandbox for development and testing, then switch to production when your integration is ready to go live.
Production
https://api.3plguys.comLive data and real shipments. Rate limits apply based on your plan. Use your production OAuth credentials.
Sandbox
https://sandbox.3plguys.comIsolated test environment with separate data and credentials. Ideal for development, integration testing, and debugging.
Comparison
| Feature | Sandbox | Production |
|---|---|---|
| Base URL | sandbox.3plguys.com | api.3plguys.com |
| Data | Test data — safe to create/delete freely | Live data — real inventory and shipments |
| Rate Limits | 1,000 requests/hour | Varies by plan |
| Authentication | Separate sandbox OAuth credentials | Production OAuth credentials |
| Shipments | Not processed by warehouse | Processed and fulfilled |
Making Requests
All API endpoints use the same paths in both environments. Simply change the base URL to switch between them.
curl -X GET https://sandbox.3plguys.com/v0/shipments \-H "Authorization: Bearer <sandbox_token>"
curl -X GET https://api.3plguys.com/v0/shipments \-H "Authorization: Bearer <production_token>"
Environment Switching Pattern
Keep environment configuration in a single variable to simplify switching:
const BASE_URL = process.env.NODE_ENV === "production"? "https://api.3plguys.com": "https://sandbox.3plguys.com";// All API calls use BASE_URLconst res = await fetch(`${BASE_URL}/v0/shipments`, {headers: { Authorization: `Bearer ${token}` },});
import osBASE_URL = ("https://api.3plguys.com"if os.environ.get("ENV") == "production"else "https://sandbox.3plguys.com")res = httpx.get(f"{BASE_URL}/v0/shipments", headers={"Authorization": f"Bearer {token}"})
Go-Live Checklist
Test the full shipment lifecycle in sandbox (create → configure → submit → track)
Verify token refresh works automatically without user re-authorization
Handle all error codes gracefully (400, 401, 404, 429)
Swap to production OAuth credentials and base URL
Store secrets in environment variables or a secrets manager
Important
- Sandbox and production use completely separate databases — data does not sync between them.
- OAuth credentials are environment-specific. A sandbox token will not work in production and vice versa.
- Test your full integration flow in sandbox before going live.