Custom / REST API Integration
On a headless storefront or a platform without a first-party plugin? Build directly against the ShipRateAPI REST API — the same one every plugin uses.
Build your own integration on any platform
The ShipRateAPI REST API accepts a standard JSON payload from any platform or custom storefront. Normalise your checkout data to the standard format, pass your x-api-key and X-Platform: custom, and you get the same live rates the first-party plugins use.
One normalised endpoint
Every platform uses the same POST /api/v1/quotes endpoint. Map your checkout data to the standard JSON payload once and you’re done.
Simple API-key auth
Authenticate with an x-api-key header — no OAuth flow or token exchange. Each key is scoped to a single store.
Server-side & secure
Call the API from your backend so the key never reaches the browser, exactly as the first-party plugins do.
Same engine, same tags
You get the identical rating engine and routing-tag behaviour as the plugins — pass tags per line item to control carrier selection.
How it works
Four steps from API key to live rates at your checkout.
Generate an API key
Create a key in the admin portal under Settings → API Keys. It’s scoped to one store and shown in full only once.
Normalise your payload
Map your cart and destination to the standard JSON format — destination fields plus an items array with weight, price, and tags.
POST the rate request
Send it server-side with your x-api-key and the X-Platform: custom header so requests are attributed correctly in logs.
Render the rates
Read the response array and display only the methods where available is true, using amount as the customer-facing price.
Make your first request
Send a POST with a JSON body describing the destination and cart items. Authentication is a single x-api-key header — no token exchange.
A 200 OK returns an array of rate objects. Display only the methods where available is true, using amount as the customer-facing price. See the API Reference for every field.
curl -X POST https://api.shiprateapi.com/api/v1/quotes \
-H "Content-Type: application/json" \
-H "x-api-key: YOUR_API_KEY" \
-H "X-Platform: custom" \
-d '{
"dest_country_id": "GB",
"dest_postcode": "SW1A 1AA",
"package_weight": 2.5,
"package_value": 49.99,
"items": [
{
"sku": "WIDGET-001",
"name": "Blue Widget",
"qty": 2,
"price": 24.99,
"weight": 1.25,
"tags": ["fragile"]
}
]
}'When to build a custom integration
If you’re on Shopify, Magento 2, BigCommerce, or commercetools, use the first-party integration. Reach for the REST API directly when:
Headless storefronts
A custom React, Vue, or mobile checkout calling your own backend for rates.
Unsupported platforms
WooCommerce, OpenCart, PrestaShop, or any cart without a first-party ShipRateAPI plugin.
ERP / OMS / middleware
Rating shipments inside an order management system, ERP, or internal tooling.
Start building
The Quick Start gets you from API key to a live rate in minutes. The API Reference and interactive Swagger UI cover every field and response.
Read the Quick StartAPI ReferenceSwagger UI