Load Market
Getting started

Test mode

There is no separate sandbox server. Test mode runs on the production API and is selected by the key: requests made with your test partner key work on test tracking items, requests made with your live key work on real ones. The two never see each other's tracking items.

What is simulated

Live keyTest key
Driver SMS / push notificationSentNever sent
Tracking requests consumed from the planYesNever
Driver behaviorReal driver in the appYou drive it with POST /test/simulate
WebhooksEvery minute while something changesOnly when you call /test/simulate, one attempt
LifetimeUntil expDate (max 10 days)At most 24 hours: expDate / schedule.end must be within the next 24 hours (400 EXP_DATE_INVALID / SCHEDULE_INVALID), and the tracking is deleted automatically 24 hours after it was created
LimitsYour plan200 test tracking items created per key per UTC day (429 TEST_LIMIT_REACHED, and deleting test tracking items does not give the quota back) and 60 requests per minute per key (429 RATE_LIMITED). Both answers carry Retry-After
Not simulated-publicLink is always null and driverFiles always []. No stop arrivals, no Smart Arrival Alerts status, no derived statuses (notMoving, waiting, settings) and no email updates. No text message is sent, so driverInvite.smsStatus stays null. requestDriverDetails=true returns a made-up driver (Test Driver on an iPhone), requestPhoneSettings=true healthy settings. History is a single page (nextCursor is always null). TRACKING_LIMIT_REACHED and PAYMENT_FAILED never occur
Potential Fraud AlertsSignals from the driver's phoneA clean phone by default, raise or clear alerts with the driver.flagged event. Filled under the same rules as live: a PRO or VIP plan, only while the tracking is active or stop
ELD and Hybrid carrierThe carrier approves by email, the truck's ELD reportsNo email and no ELD provider: only the shape of the eld block is checked, and you drive the carrier with the carrier.* events. The organization still needs ELD tracking enabled

Apart from that, test mode behaves like live: the same endpoints, request validation, error codes, response shapes and plan checks (for example 403 PRO_PLAN_REQUIRED for stop expectedArrival), but the plan's allowance is never checked or used. The create response carries testMode: true, and test mode requires the client key (x-api-client-key) on create: without it the answer is 400 ORG_IDENTIFIER_REQUIRED, or 400 CLIENT_KEY_REQUIRED when you send mcNum or dotNum.

The request examples in the API reference use fixed dates. With a test key, set expDate (or schedule.end) to a time within the next 24 hours - the Quickstart shows how.

Choosing the starting state

Create requestStarting state
driverPhone: 5555550100Driver already has the app: status request (Pending driver's approval)
Any other valid phone numberPending installation: status request (Pending installation), driverHasApp: false
schedule instead of expDateStatus scheduled (the whole window must end within the next 24 hours). At schedule.start it becomes request (5555550100) or pending installation (any other valid phone)
trackingSource: "eld"Status requestEld (Pending ELD admin approval), waiting for the carrier, driverHasApp: false
trackingSource: "hybrid" with driverPhone: 5555550100Status requestEld, in the driver's app and waiting for the driver and the carrier
trackingSource: "hybrid" with any other valid phoneStatus requestEld, pending installation (driverHasApp: false) and waiting for the carrier
trackingSource eld or hybrid with scheduleStatus scheduledEld. At schedule.start it becomes activeEld when the carrier already approved, otherwise requestEld (a hybrid also loses its schedule)

Simulating events

TerminalCode
curl -X POST https://api.load-market.com/v1/test/simulate \ -H "x-api-key: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "trackingId": "api-test-Zr8pL3nW6yQ1cV5kT9xB", "event": "location", "coords": { "lat": 39.781721, "lng": -89.650148, "speed": 28.6, "heading": 205, "battery": 0.82, "accuracy": 6.5, "locationSource": "gps" } }'
EventAllowed fromNew status
driver.installedpending installation, or scheduled with another phonerequest - the driver now has the app. A scheduled tracking gets driverHasApp: true and stays scheduled
driver.acceptedrequest (driver has the app, not pending installation)active
driver.rejectedrequest (driver has the app, not pending installation)cancel
locationactiveactive, with the new driverCoords. coords.lat and coords.lng are required. Optional, like a live driver-app fix: speed (m/s), heading (degrees, 0-360), battery (0-1), accuracy (meters) and locationSource (gps or cell-tower, default gps)
driver.pausedactivestop
driver.resumedstopactive
tracking.finishedactive, stopdone
webhook.pinganyunchanged - sends the current state again
driver.flaggedany, except pending installation and scheduledunchanged. Raises the Potential Fraud Alerts listed in alerts (for example ["vpn", "ipOutsideUsCa"]) on the simulated driver's phone, an empty list clears them. They show in fraudAlerts while the tracking is active or stop

An event that is not allowed from the current status returns 400 TEST_EVENT_INVALID. Calling /test/simulate with a live key returns 403 TEST_MODE_ONLY.

ELD and Hybrid test tracking items

The carrier.* events play the links of the carrier's approval email (Start, Stop and Cancel), and the driver events play the hybrid's driver. On a phone test tracking the carrier.* events answer 400 TEST_EVENT_INVALID.

TerminalCode
curl -X POST https://api.load-market.com/v1/test/simulate \ -H "x-api-key: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "trackingId": "api-test-Gn5vR8kQ2wM7xT4cL9pB", "event": "carrier.approved" }'
EventAllowed fromNew status
carrier.approvedrequestEld waiting for the carrier, scheduledEld, or a hybrid in the driver's app the carrier has not approved (also after carrier.rejected)activeEld - the truck's ELD starts reporting. On scheduledEld the approval is recorded and the status stays until schedule.start, then becomes activeEld. A hybrid the driver already moved keeps its status
carrier.pausedapproved by the carrierunchanged - the truck's ELD stops reporting
carrier.resumedpaused by the carrierunchanged - the truck's ELD reports again
carrier.rejectedany, until the tracking is finished (not twice in a row)ELD only: cancelEld. Hybrid: only the ELD part ends and the status stays, unless the driver declined too (cancelEld)
driver.installedhybrid whose driver has no appdriverHasApp: true. A pending one moves into the driver's app with status requestEld, one the carrier already started keeps its status
driver.acceptedhybrid in the driver's app, requestEld or activeEldactiveEld - the phone reports too
driver.rejectedhybrid in the driver's app, not acceptedunchanged, or cancelEld when the carrier already cancelled
driver.pausedhybrid activeEld the driver acceptedstopEld - the truck's ELD keeps reporting
driver.resumedstopEldactiveEld
locationactiveEld, or a hybrid stopEldunchanged, with the new driverCoords. A position from the truck's ELD (no live phone) has battery, accuracy and locationSource null
tracking.finishedactiveEld, stopElddoneEld
webhook.pinganyunchanged - sends the current state again
driver.flaggedhybrid in the driver's appunchanged, as above. Alerts show only while the driver has accepted the tracking

Like on live tracking items, driverCoords is returned only while the tracking is active or stop (ELD: activeEld or stopEld): after tracking.finished it is null (see Tracking lifecycle).

Test webhooks

Every /test/simulate call sends one signed webhook with the new state to the webhook URL configured on your test key - no retries, no batching with other tracking items. The URL is never taken from the request. The response tells you what your endpoint did:

JSONCode
{ "webhook": { "attempted": true, "status": 200, "webhookId": "msg_2b7c1f0e-5d3a-4c8e-9b61-7a4f0d2e9c35", "reason": null } }
  • attempted: false - webhooks are not enabled or no webhook URL is configured on the test key (reason says so).
  • status - the HTTP status your endpoint returned, or null when it did not answer within 7 seconds or could not be reached (reason explains).

The payload, headers and signature are identical to live webhooks, so the signature check you write against test mode works unchanged in production. The item's events carries the event the simulate stands for, with the same name as the live event (driver.accepted, driver.paused, carrier.rejected, ...). location, webhook.ping and driver.flagged change only the snapshot and carry no event. The response returns the same events. Stop arrivals and Smart Arrival Alerts are not simulated, so their events (stop.*) come from live tracking items only. See Webhooks.

Going live

  1. Replace the test key with the live key in your configuration.
  2. Use real driver phone numbers - the driver receives a push notification or an SMS invitation.
  3. Expect live webhooks once per minute while a tracking changes, with up to 2 retries.
Last modified on