Inject a flood zone into Revit parameters
powershell.exe -NoProfile -ExecutionPolicy Bypass -Command 'iwr -useb https://bimcli.com/install.ps1?src=site -OutFile $env:TEMP\bim-install.ps1; powershell -NoProfile -ExecutionPolicy Bypass -File $env:TEMP\bim-install.ps1'
Getting a flood zone into a Revit model usually means looking it up on a government web map, writing down the result, and setting the parameter by hand. This page does it in one line: your assistant queries the FEMA National Flood Hazard Layer and pipes the zone and Base Flood Elevation directly into your model's project parameters.
bim-cli queries the FEMA National Flood Hazard Layer and pipes the flood zone and Base Flood Elevation directly into Revit project parameters — no API key, no account, no web map required.
Prompt
Copy this into your AI coding tool:
Look up the FEMA flood zone for a project address and inject the flood zone and Base Flood Elevation into Revit project parameters.Step 1 — install bim-cli if not already installed: powershell.exe -NoProfile -ExecutionPolicy Bypass -Command 'iwr -useb https://bimcli.com/install.ps1?src=site -OutFile $env:TEMP\bim-install.ps1; powershell -NoProfile -ExecutionPolicy Bypass -File $env:TEMP\bim-install.ps1'
Step 2 — refresh PATH: pwsh: $env:Path += ";$env:LOCALAPPDATA\bim-cli"
Step 3 — look up the flood zone (FEMA NFHL ArcGIS REST, no API key): bim site flood lookup --lat <latitude> --lon <longitude> # or by address (uses Census Geocoder): bim site flood lookup --address "123 Main St, City, ST 00000"
Step 4 — open the Revit model: bim revit open "C:\path\to\model.rvt"
Step 5 — write flood zone and BFE into two text parameters on Project Information (FloodZone, BaseFloodElevation). Save a short C# script as set-flood.cs that sets them from args.zone and args.bfe (see https://bimcli.com/flood-zone-revit/), then pipe the lookup into it: bim site flood lookup --lat <lat> --lon <lon> | bim revit exec --file set-flood.cs --args-json -
This replaces the manual workflow of: open FEMA web map → find zone → screenshot → open Revit → manually type zone and BFE into parameters.
The pipeline
bim site flood lookup --lat 40.762 --lon -73.963
{"ok":true,"result":{"zone":"AE","sfha":true,"bfe":12.0,"panel_id":"36061C0338H","source":"fema-nfhl","queried_at":"2026-05-03T18:06:07Z","lat":40.762,"lon":-73.963}}
zone: FEMA flood zone designation (AE = high-risk; X = minimal risk; AO, VE etc.). sfha: whether the location is in a Special Flood Hazard Area (zones A and V). bfe: Base Flood Elevation in feet NAVD88 — null for zone X where BFE is not determined. panel_id: the FIRM panel that covers this location.
bim site flood lookup --address "123 Main St, City, ST 00000"
bim site flood lookup --lat <lat> --lon <lon> | bim revit exec --file set-flood.cs --args-json -
// set-flood.cs: args is the flood lookup result { zone, sfha, bfe, panel_id, ... }
var info = doc.ProjectInformation;
info.LookupParameter("FloodZone")?.Set(argStr("zone") ?? "");
info.LookupParameter("BaseFloodElevation")?.Set(args["bfe"]?.ToString() ?? "");
return new { zone = argStr("zone"), bfe = args["bfe"] };
The provider is the FEMA NFHL ArcGIS REST layer 28. Free, no key, no account. --args-json - hands the lookup result to the script as args, and the script writes the zone and BFE into two text parameters on Project Information, FloodZone and BaseFloodElevation, inside one Revit transaction. Add them as project parameters first, or change the names in the script to match yours.
bim revit element-list --category OST_ProjectInformation
bim revit param set --id <id> --name FloodZone --value AE --dry-run
bim revit param set --id <id> --name FloodZone --value AE
bim revit param set --id <id> --name BaseFloodElevation --value 12
bim revit param set writes one parameter on one element (the Project Information id from element-list), reports the old and new value, and returns an undo block; --dry-run checks it without keeping anything. The script is the one-line pipe; the verb is the no-code path.
What the test harness checks
This scenario runs the flood lookup end-to-end (Revit is not required for this step):
bim scenario run tests/scenarios/flood-zone-revit.yaml --strict
Why this exists
For projects in flood-prone areas, architects and site engineers must determine the FEMA flood zone and Base Flood Elevation during schematic design and include them in the Revit site model. The current workflow is: open the FEMA Flood Map Service Center, search the address, read the flood zone from the map, screenshot or note it, then manually enter it into Revit. There is no existing CLI or API wrapper for the full lookup-to-Revit pipeline. bim site flood lookup uses the same underlying NFHL ArcGIS REST endpoint (free, no key) and the pipe to bim revit exec writes the data directly into the model — the entire workflow collapses to one command.
powershell.exe -NoProfile -ExecutionPolicy Bypass -Command 'iwr -useb https://bimcli.com/install.ps1?src=site -OutFile $env:TEMP\bim-install.ps1; powershell -NoProfile -ExecutionPolicy Bypass -File $env:TEMP\bim-install.ps1'
Then ask your assistant to run bim describe --json. See what the installer does.