Quickstart

Make your first API call in 5 minutes.

1. Register an account

curl -X POST https://api.trusttrade.com/v1/auth/register \
  -H "Content-Type: application/json" \
  -d '{
    "email": "dev@example.com",
    "password": "securepassword",
    "company_name": "Acme Corp"
  }'

Check your inbox and click the verification link.

2. Log in

curl -X POST https://api.trusttrade.com/v1/auth/login \
  -H "Content-Type: application/json" \
  -d '{
    "email": "dev@example.com",
    "password": "securepassword"
  }'

Save the access_token from the response.

3. Create an API key

curl -X POST https://api.trusttrade.com/v1/account/keys \
  -H "Authorization: Bearer YOUR_ACCESS_TOKEN"

::: warning Save the key value immediately — it will not be shown again. :::

4. Look up a device

curl -H "X-API-Key: YOUR_API_KEY" \
  https://api.trusttrade.com/v1/devices/MBA-M2-256-8GB

You'll get back current market valuations in three conditions:

{
  "deviceId": "MBA-M2-256-8GB",
  "displayName": "MacBook Air 13\" M2 256GB 8GB",
  "currentValuation": {
    "fair": 475,
    "good": 500,
    "excellent": 525
  },
  "msrp": 1199,
  "residualPct": 41.7,
  "valueTier": "Strong",
  "currency": "USD",
  "confidence": "high"
}

5. Batch valuation

Price multiple devices at once:

curl -X POST https://api.trusttrade.com/v1/devices/batch \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "devices": [
      "MBA-M2-256-8GB",
      { "id": "IPAD-10-64-WIFI", "qty": 5 },
      { "id": "MBP-M3PRO-14-512-18GB", "qty": 2 }
    ]
  }'

The response includes per-device valuations, any unmatched devices, and a fleet-level summary with total value and refresh signals.

Next steps