API Reference
Base URL: https://wildfirecost-api.smarttechinvest.com
Pass your API key via the X-API-Key header on every request (except /v1/signup and /v1/login).
/v1/risk/county/:fipsGet wildfire risk and hardening ROI for a U.S. county by FIPS code.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| fips | path | required | 5-digit county FIPS code (e.g., 06037) |
Response
{
"success": true,
"data": {
"county_name": "Los Angeles County, CA",
"state_abbr": "CA",
"risk": {
"burn_probability": 0.010482155,
"likelihood_rank_national": 0.97,
"risk_rank_national": 0.99,
"risk_to_homes": 0.99,
"risk_percentile": 99,
"buildings_fraction_minimal_exposure": 0.8034,
"wui_class": null,
"fhsz_tier": null
},
"total_cost": 119025,
"money_status": "computed",
"total_annual_savings": "<computed from your inputs>",
"package_roi_percentage": "<computed from your inputs>"
}
}
// burn_probability is a probability: the county's mean annual chance of burning, across its
// wildfire-exposed land (USFS Wildfire Risk to Communities, 2026). likelihood_rank_national and
// risk_rank_national are percentile RANKS from 0 to 1 (0.97 = at or above 97% of U.S. counties),
// not probabilities and not dollars. When no supported probability exists, burn_probability is null,
// money_status is "unavailable", and every dollar figure that depends on it is null (never 0).Error Codes
- 400 Invalid FIPS code format
- 404 No data found for FIPS code
- 429 Rate limit exceeded
/v1/risk/zip/:zipGet wildfire risk by ZIP code (auto-resolves to county).
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| zip | path | required | 5-digit U.S. ZIP code |
Response
{
"success": true,
"data": {
"county_name": "San Diego County, CA",
"state_abbr": "CA",
"risk": {
"burn_probability": 0.026927942,
"likelihood_rank_national": 1,
"risk_rank_national": 1,
"risk_to_homes": 1,
"risk_percentile": 100,
"wui_class": null,
"fhsz_tier": null
}
}
}Error Codes
- 400 Invalid ZIP code
- 404 ZIP not found
- 429 Rate limit exceeded
/v1/risk/compareCompare wildfire hardening costs and ROI across multiple counties.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| fips | query | required | 2-5 county FIPS codes, repeated: ?fips=06037&fips=06073 |
Response
{
"success": true,
"data": {
"comparisons": [
{ "county_name": "Los Angeles County, CA", "risk": { "burn_probability": 0.010482155, "likelihood_rank_national": 0.97, "risk_percentile": 99 }, "total_cost": 119025, "money_status": "computed" },
{ "county_name": "San Diego County, CA", "risk": { "burn_probability": 0.026927942, "likelihood_rank_national": 1, "risk_percentile": 100 }, "total_cost": 119025, "money_status": "computed" }
],
"count": 2,
"risk_field_notes": { "burn_probability": "Annual burn probability as a fraction ..." }
}
}Error Codes
- 400 Invalid request body
- 401 API key required
- 429 Rate limit exceeded
/v1/measuresList all available hardening measures with cost estimates and effectiveness.
Response
{
"success": true,
"data": [
{ "id": "class_a_roof", "name": "Class A Roof", "category": "Structure", "avg_cost": 12000, "effectiveness": 0.85 },
{ "id": "ember_vents", "name": "Ember-Resistant Vents", "category": "Structure", "avg_cost": 2500, "effectiveness": 0.72 },
{ "id": "defensible_space", "name": "Defensible Space (Zone 0-1)", "category": "Landscape", "avg_cost": 3500, "effectiveness": 0.68 },
{ "id": "fire_resistant_siding", "name": "Fire-Resistant Siding", "category": "Structure", "avg_cost": 15000, "effectiveness": 0.78 }
]
}/v1/signupCreate an account and receive an API key.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| name | body | required | User display name |
| body | required | Email address | |
| password | body | required | Password (min 8 characters) |
Response
{
"success": true,
"data": {
"name": "Jane Doe",
"email": "jane@example.com",
"tier": "free",
"apiKey": "wfc_abc123..."
}
}Error Codes
- 400 Invalid input
- 409 Email already registered
/v1/loginAuthenticate with email and password.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| body | required | Email address | |
| password | body | required | Password |
Response
{
"success": true,
"data": {
"name": "Jane Doe",
"email": "jane@example.com",
"tier": "free"
}
}Error Codes
- 401 Invalid credentials
/v1/accountGet current account information and tier.
Response
{
"success": true,
"data": {
"name": "Jane Doe",
"email": "jane@example.com",
"tier": "pro",
"usage": { "today": 12, "month": 340 }
}
}Error Codes
- 401 API key required
/v1/account/keysList all API keys for the authenticated user.
Response
{
"success": true,
"data": {
"keys": [
{ "id": 1, "prefix": "wfc_abc...", "lastUsed": "2026-03-01T12:00:00Z" }
]
}
}Error Codes
- 401 API key required
/v1/account/keys/rotateRotate API key -- generates a new key and invalidates the old one.
Response
{
"success": true,
"data": {
"apiKey": "wfc_new_key..."
}
}Error Codes
- 401 API key required
/v1/account/keys/:idRevoke a specific API key.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| id | path | required | API key ID |
Response
{
"success": true,
"data": { "message": "Key revoked" }
}Error Codes
- 401 API key required
- 404 Key not found
/v1/accountPermanently delete your account and all data.
Response
{
"success": true,
"data": { "message": "Account deleted" }
}Error Codes
- 401 API key required
/v1/forgot-passwordRequest a password reset email. Returns 200 regardless of email existence.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| body | required | Email address |
Response
{
"success": true,
"data": { "message": "If an account exists, a reset email was sent." }
}/v1/reset-passwordReset password using a token from the reset email.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| token | body | required | Reset token from email |
| password | body | required | New password (min 8 characters) |
Response
{
"success": true,
"data": { "message": "Password updated" }
}Error Codes
- 400 Invalid or expired token
Rate Limiting
Requests that exceed your plan limit return 429 Too Many Requests with a Retry-After header indicating seconds until the limit resets.
| Plan | Requests/Day | Hardening ROI |
|---|---|---|
| Free | 1 | No |
| Single Report ($9.99) | 5 | Yes |
| Buyer Pack ($14.99/mo) | 10 | Yes |
| Pro ($19.99/mo) | 100 | Yes |
| Lifetime ($99) | 100 | Yes |