Loading...
Loading...
Programmatic access to stored price records with source links where available, published API changes, and webhooks.
Fetch stored model price records with a single request.
curl -H "Authorization: Bearer mpl_your_api_key" \
"https://api.modelpricelab.com/v1/prices"| Endpoint | Method | Auth | Description | Limit |
|---|---|---|---|---|
| /v1/prices | GET | API key | Returns stored model price records across vendors and platforms. | API Free or current paid entitlement |
| /v1/changes | GET | API key | Returns published price and API changes; incidents are excluded by default. | Current paid entitlement required |
| /v1/webhooks | GET | API key | List configured webhook endpoints. | Current paid entitlement required |
| /v1/webhooks | POST | API key | Subscribe an HTTPS URL to change.alert events. | Current paid entitlement required |
| /v1/webhooks/{id} | DELETE | API key | Remove a webhook subscription. | Current paid entitlement required |
Current Developer/Scale API or Team entitlements can receive deliveries. Verify the exact raw body with HMAC SHA-256 from x-mpl-signature (sha256=…).
import { createHmac, timingSafeEqual } from 'node:crypto';
const signature = req.headers['x-mpl-signature'];
// Capture the exact raw UTF-8 request bytes before JSON parsing.
const rawBody = req.rawBody;
const expected = 'sha256=' + createHmac('sha256', WEBHOOK_SECRET)
.update(rawBody)
.digest('hex');
const valid = typeof signature === 'string'
&& signature.length === expected.length
&& timingSafeEqual(Buffer.from(signature), Buffer.from(expected));
if (!valid) {
res.status(401).send('Invalid signature');
return;
}Each API key has a daily request quota based on its plan. Requests exceeding the quota return HTTP 429.
New self-serve API plan purchases are paused. Endpoints return stored records; record-update timestamps are not independent source verification.