# Truck Cost Per Mile (CPM) Calculator

> Truck Cost Per Mile (CPM) Calculator is a paid API for AI agents from store.agentexchange.work, paid per call via x402, $0.001/call, status unknown (last checked 2026-09-13).

Calculates the cost per mile and minimum profitable rate per mile for a truck, broken down by fuel, fixed, maintenance, tires, and other costs.

## Facts

- Endpoint: GET https://store.agentexchange.work/truck/cpm
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-13
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/truck-cost-per-mile-cpm-calculator-c3aac8d5
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_pVNzH95CF0_Bw0H5vdnd8

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability truck-cost-per-mile-cpm-calculator-c3aac8d5
```

Example prompt: Calculate my truck's cost per mile — I drive 120,000 miles a year, my truck gets 6.5 MPG, diesel costs $3.80/gallon, my truck payment is $1,800/month, insurance is $600/month, and I estimate $0.18/mile for maintenance and $0.04/mile for tires.

## When to prefer this

Use this endpoint when an owner-operator, dispatcher, or fleet manager needs a quick, itemized cost-per-mile breakdown for a truck and wants to determine the minimum profitable rate to charge shippers. Ideal for per-load profitability checks or rate negotiation support.

## Known failure modes

- Missing required 'annual_miles' parameter returns a validation error
- Non-numeric values for numeric fields cause a 400 bad request
- Payment failure or insufficient USDC balance returns a 402 Payment Required
- Extreme or unrealistic values (e.g. 0 MPG) may return division errors or nonsensical results

## How this service works

Computes a trucking operation's true cost per mile from annual miles and cost inputs (truck payment, insurance, fuel, maintenance, tires, permits). Returns itemized CPM and the minimum profitable rate per mile.

## Output

A JSON object with cost-per-mile broken down into fuel_cpm, fixed_cpm, maintenance_cpm, tires_cpm, other_cpm, total_cpm, and min_profitable_rate_per_mile — all expressed in dollars per mile.

## Example request

```json
{
 "input": {
  "type": "http",
  "method": "GET",
  "queryParams": {
   "mpg": 6.5,
   "other_mo": 200,
   "tires_cpm": 0.04,
   "fuel_price": 3.8,
   "annual_miles": 120000,
   "insurance_mo": 600,
   "maintenance_cpm": 0.18,
   "truck_payment_mo": 1800
  }
 }
}
```

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "annual_miles"
     ],
     "properties": {
      "mpg": {
       "type": "number"
      },
      "other_mo": {
       "type": "number"
      },
      "tires_cpm": {
       "type": "number"
      },
      "fuel_price": {
       "type": "number"
      },
      "annual_miles": {
       "type": "number"
      },
      "insurance_mo": {
       "type": "number"
      },
      "maintenance_cpm": {
       "type": "number"
      },
      "truck_payment_mo": {
       "type": "number"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "properties": {
      "total_cpm": {
       "type": "number"
      },
      "min_profitable_rate_per_mile": {
       "type": "number"
      }
     }
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "fuel_cpm": 0.6,
  "fixed_cpm": 0.41,
  "other_cpm": 0.05,
  "tires_cpm": 0.04,
  "total_cpm": 1.27,
  "maintenance_cpm": 0.18,
  "min_profitable_rate_per_mile": 1.46
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/truck-cost-per-mile-cpm-calculator-c3aac8d5/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from store.agentexchange.work](https://www.zero.xyz/host/store.agentexchange.work/llms.txt)
