CheckWarranty.info

ERP · WMS · ITAM · Refurbished inventory

Connect warranty lookups to your inventory workflow

Retrieve available warranty and factory data for Lenovo, Dell, HP and Apple. Start with simulated sandbox records, then test the fields available for your own inventory.

Create a sandbox API key

1. Run your first sandbox request

Set the CW_API_KEY environment variable to a cw_test_ key from your dashboard. Sandbox records are simulated and consume no scan credits. Production keys can incur charges for useful device data.

# Set CW_API_KEY to a cw_test_ key from your dashboard.
# Reuse this idempotency key when retrying the same request.
REQUEST_ID=$(uuidgen)
curl -i -X POST "https://checkwarranty.info/api/v1/devices/lookup" \
  -H "X-API-Key: $CW_API_KEY" \
  -H "Idempotency-Key: $REQUEST_ID" \
  -H "Content-Type: application/json" \
  -d '{"serialNumber":"TEST-LENOVO-001","brand":"lenovo"}'
# HTTP 202: retrieve the result from the Location response header.

Keep the Idempotency-Key unchanged when retrying the same request. A new operation needs a new key. Read the idempotency contract.

2. Enrich a CSV file with Python

The downloadable Python 3 script uses the standard library. It submits rows sequentially, preserves each complete JSON response in the output CSV, follows asynchronous results and records failures separately.

python3 checkwarranty-csv.py sandbox-inventory.csv results.csv --run-id sandbox-intake-001

CSV columns: serialNumber, brand, optional productNumber. Use lowercase brand names. Some HP devices require the product number from the same device label.

For a retry, preserve the input file, row order and run ID; choose a new output filename. The script refuses to overwrite existing output. It requires an explicit --live flag for production keys. It stops polling after 60 attempts; pending work may still finish later.

Map results back to your inventory

Keep your internal asset ID and original serial number in your inventory. Match returned records by brand and serial number rather than row order. The downloadable recipe does not copy extra asset-ID columns into its output.

The web upload reads the first column and applies one selected brand to the batch. Split a mixed-brand file before using the web scanner. The bulk API supports an explicit brand on each item; some HP lookups also need productNumber.

Store missing warranty dates as unknown, not expired. Keep factory configuration separate from the installed RAM and SSD. Inspect upgraded devices separately.

CSV upload and export instructions

3. Add a Node.js request to your application

Run this server-side in a current Node.js runtime with native fetch. Keep API keys out of browser bundles and source control.

// Set CW_API_KEY to a cw_test_ key. Reuse requestId for retries.
const requestId = crypto.randomUUID();
const response = await fetch("https://checkwarranty.info/api/v1/devices/lookup", {
  method: "POST",
  redirect: "error",
  headers: {
    "X-API-Key": process.env.CW_API_KEY,
    "Idempotency-Key": requestId,
    "Content-Type": "application/json"
  },
  body: JSON.stringify({serialNumber: "TEST-LENOVO-001", brand: "lenovo"})
});
if (!response.ok) throw new Error(await response.text());
if (response.status === 202) {
  console.log("Processing; retrieve result:", response.headers.get("Location"));
} else {
  console.log(await response.json());
}

HTTP 202 means accepted, not completed. Authenticate GET requests to the Location URL and inspect the batch status and individual items. Accept only polling URLs on the API origin. Handle pending results, missing fields, product-number requirements and errors explicitly.

4. Move from a trial file to warehouse batches

The web app accepts up to 100 devices per batch; the bulk API accepts up to 500. A credit package can cover multiple batches. The Python recipe above uses single lookups; use the bulk endpoint for a queued batch workflow.

Bulk request and status contract · Webhook delivery and verification

Factory data does not confirm components installed after an upgrade. Useful partial data, such as warranty only or specifications only, is chargeable. No useful device data means the scan reservation is released.

5. Open-source ITAM integrations: Snipe-IT

If you use Snipe-IT for IT asset management, you can automate warranty tracking and factory hardware specification enrichment without writing custom API code.

Our open-source synchronization script runs with zero external pip dependencies, supports safe dry-run mode, and maps factory CPU, RAM, and SSD details to your Snipe-IT custom fields.

View checkwarranty/snipeit-warranty-sync on GitHub →