Skip to main content
The HaulStow Developer API lets your software talk to HaulStow. Your backend can ask for a price, create a delivery, check its status, and receive automatic status updates. You do not need to understand HaulStow’s internal systems. If you can send an HTTP request and read JSON, you can use this API.
This is a server-to-server API. Your frontend calls your backend, and your backend calls HaulStow. Never put a HaulStow API key in browser JavaScript, a mobile app, or a public repository.

What you need

Before you begin, get these from the HaulStow developer portal:
  1. A developer application.
  2. A test API key beginning with hsg_test_key_.
  3. A tool for sending HTTP requests. The quickstart uses curl, which is already available on most macOS and Linux computers.
Start with the sandbox. It behaves like the live API but does not dispatch a rider, charge money, send messages, or create a real delivery.

Base URLs

The URL and key must match. A live key cannot access sandbox data, and a test key cannot access live data. There is no environment field to add to your JSON.

The three ideas to remember

1. Put the key in the Authorization header

Bearer is required, followed by one space and the complete API key.

2. Send an idempotency key when creating something

An idempotency key is a unique label for one action. It makes retrying safe if your network disconnects.
Reuse that value only when retrying the exact same request. Use a new value for a new recipient, address, delivery, or sandbox transition.

3. Read the data field

Every response has the same outer shape, called an envelope. On success, the useful result is inside data.

Response envelope

Success
Error
On failure, error.code is the short, stable value your program should check. message is the human-readable explanation. Every response also includes X-Request-ID. Save it in your logs. If you contact HaulStow support about a request, include this value so the request can be found quickly.

Common words

Start integrating

  1. Follow the 10-minute quickstart to create a simulated delivery.
  2. Read authentication before saving a key in your app.
  3. Read idempotency before creating live deliveries.
  4. Use webhooks for automatic updates, or polling as a simpler fallback while learning.
  5. Open common errors when a request does not work.
  6. Use the API reference when you need every field and status code.