<!-- Agent Datasets docs · Hazards REST endpoints · canonical: https://www.agentdatasets.com/docs/rest/hazards · rendered from https://www.agentdatasets.com -->

# Hazards REST endpoints

US natural-hazard risk — FEMA National Risk Index county and census-tract profiles, components, and rankings.

3 endpoints. Paths are relative to `https://api.agentdatasets.com`. Every endpoint mirrors an MCP tool over the same service layer — https://www.agentdatasets.com/docs/tools.md documents the same operations for MCP clients.

## GET /v1/hazards/hazard-components

Hazard Components

Return a bounded page of one geography's FEMA NRI hazard components.

### Parameters

| Parameter | In | Type | Required | Default | Constraints | Description |
| --- | --- | --- | --- | --- | --- | --- |
| geography | query | `string` | yes | — | — | County/tract name, FIPS, or geo_key |
| hazard_type | query | `string \| null` | no | — | — | Optional FEMA hazard code or display name |
| limit | query | `integer` | no | 10 | min 1, max 18 | Hazard components to return |
| cursor | query | `string \| null` | no | — | — | Opaque cursor from pagination.next_cursor |

### Example request

Required parameters only, with values taken from the schema.

```bash
curl --fail --silent --show-error \
  --header "X-API-KEY: adk_..." \
  "https://api.agentdatasets.com/v1/hazards/hazard-components?geography=GEOGRAPHY"
```

### Response

`200` Successful Response — `HazardComponentsResult`.

- `data` `HazardComponentsData` (required)
  - `geography` `HazardGeographyRef` (required)
    - `geo_key` `string` (required)
    - `level` `"county" | "tract"` (required)
    - `fips` `string` (required)
    - `name` `string` (required)
    - `state_code` `string | null` (required)
  - `hazard_type` `string | null` (required)
  - `units` `HazardComponentUnits`
    - `risk_score` `"score"`
    - `risk_value` `"index_value"`
    - `eal_total` `"USD/year"`
    - `eal_score` `"score"`
  - `components` `array<HazardComponent>` (required)
    - `hazard_code` `string` (required)
    - `hazard_name` `string` (required)
    - `risk_score` `string | null` (required)
    - `risk_rating` `string | null` (required)
    - `risk_value` `string | null` (required)
    - `eal_total` `string | null` (required)
    - `eal_score` `string | null` (required)
    - `eal_rating` `string | null` (required)
- `meta` `HazardReleaseMeta` (required)
  - `source` `string` (required)
  - `as_of` `string (date-time) | string (date) | null`
  - `period_type` `"annual"`
  - `currency` `"USD"`
  - `release_version` `string` (required)
  - `release_date` `string (date)` (required)
- `pagination` `Pagination | null`
  - `limit` `integer` (required)
  - `has_more` `boolean` (required)
  - `next_cursor` `string | null`

Fields are shown to 3 levels; the full schema is in https://www.agentdatasets.com/docs/machine/openapi.json

## GET /v1/hazards/rankings

Rankings

Rank county or tract profiles by a FEMA NRI metric.

### Parameters

| Parameter | In | Type | Required | Default | Constraints | Description |
| --- | --- | --- | --- | --- | --- | --- |
| level | query | `"county" \| "tract"` | yes | — | — | Geography level to rank: county or tract |
| metric | query | `string` | yes | — | — | Composite or hazard-specific FEMA NRI metric |
| state | query | `string \| null` | no | — | — | Optional state name, postal abbreviation, FIPS, or geo_key |
| limit | query | `integer` | no | 10 | min 1, max 100 | Ranked geographies to return |
| cursor | query | `string \| null` | no | — | — | Opaque cursor from pagination.next_cursor |

### Example request

Required parameters only, with values taken from the schema.

```bash
curl --fail --silent --show-error \
  --header "X-API-KEY: adk_..." \
  "https://api.agentdatasets.com/v1/hazards/rankings?level=LEVEL&metric=METRIC"
```

### Response

`200` Successful Response — `HazardRankingsResult`.

- `data` `HazardRankingsData` (required)
  - `level` `"county" | "tract"` (required)
  - `metric` `string` (required)
  - `metric_unit` `string` (required)
  - `state` `HazardStateRef | null` (required)
    - `geo_key` `string` (required)
    - `code` `string` (required)
    - `name` `string` (required)
    - `state_code` `string` (required)
  - `rankings` `array<HazardRankingItem>` (required)
    - `rank` `integer` (required)
    - `geography` `HazardGeographyRef` (required)
      - `geo_key` `string` (required)
      - `level` `"county" | "tract"` (required)
      - `fips` `string` (required)
      - `name` `string` (required)
      - `state_code` `string | null` (required)
    - `metric_value` `string` (required)
    - `rating` `string | null` (required)
    - `release_version` `string` (required)
    - `release_date` `string (date)` (required)
    - `as_of` `string (date-time)` (required)
- `meta` `HazardRankingMeta` (required)
  - `source` `string` (required)
  - `as_of` `string (date-time) | string (date) | null`
  - `period_type` `"annual"`
  - `currency` `"USD"`
- `pagination` `Pagination | null`
  - `limit` `integer` (required)
  - `has_more` `boolean` (required)
  - `next_cursor` `string | null`

Fields are shown to 3 levels; the full schema is in https://www.agentdatasets.com/docs/machine/openapi.json

## GET /v1/hazards/risk-profile

Risk Profile

Return one county or census tract's newest FEMA NRI profile.

### Parameters

| Parameter | In | Type | Required | Default | Constraints | Description |
| --- | --- | --- | --- | --- | --- | --- |
| geography | query | `string` | yes | — | — | County/tract name, FIPS, or geo_key |

### Example request

Required parameters only, with values taken from the schema.

```bash
curl --fail --silent --show-error \
  --header "X-API-KEY: adk_..." \
  "https://api.agentdatasets.com/v1/hazards/risk-profile?geography=GEOGRAPHY"
```

### Response

`200` Successful Response — `HazardRiskProfileResult`.

- `data` `HazardRiskProfileData` (required)
  - `geography` `HazardGeographyRef` (required)
    - `geo_key` `string` (required)
    - `level` `"county" | "tract"` (required)
    - `fips` `string` (required)
    - `name` `string` (required)
    - `state_code` `string | null` (required)
  - `units` `HazardValueUnits`
    - `risk_score` `"score"`
    - `risk_value` `"index_value"`
    - `risk_percentile` `"percentile"`
    - `eal_total` `"USD/year"`
    - `eal_score` `"score"`
    - `eal_percentile` `"percentile"`
    - `sovi_score` `"score"`
    - `resl_score` `"score"`
    - `population` `"people"`
    - `building_value` `"USD"`
    - `agriculture_value` `"USD"`
  - `risk_score` `string | null` (required)
  - `risk_rating` `string | null` (required)
  - `risk_value` `string | null` (required)
  - `risk_percentile` `string | null` (required)
  - `eal_total` `string | null` (required)
  - `eal_score` `string | null` (required)
  - `eal_rating` `string | null` (required)
  - `eal_percentile` `string | null` (required)
  - `sovi_score` `string | null` (required)
  - `sovi_rating` `string | null` (required)
  - `resl_score` `string | null` (required)
  - `resl_rating` `string | null` (required)
  - `population` `integer | null` (required)
  - `building_value` `string | null` (required)
  - `agriculture_value` `string | null` (required)
- `meta` `HazardReleaseMeta` (required)
  - `source` `string` (required)
  - `as_of` `string (date-time) | string (date) | null`
  - `period_type` `"annual"`
  - `currency` `"USD"`
  - `release_version` `string` (required)
  - `release_date` `string (date)` (required)
- `pagination` `Pagination | null`
  - `limit` `integer` (required)
  - `has_more` `boolean` (required)
  - `next_cursor` `string | null`

Fields are shown to 3 levels; the full schema is in https://www.agentdatasets.com/docs/machine/openapi.json
