Using the San Francisco building data MCP tools
Category: SF Housing
Read time: 5 minutes
Applies to: San Francisco buildings only
The Augrented MCP server gives AI coding agents read-only access to every SF building dataset in the platform — DBI Notices of Violation, building permits, fire safety records, 311 service requests, tenant buyout agreements, and rent-control analysis. SF's data is structured differently from NYC (no HPD equivalent), so the tools are organized around the Department of Building Inspection and the Rent Board.
What you can do
The SF-specific MCP tools (sf_* prefix) after selecting a building by block-lot give your agent the ability to:
- Pull the full building risk profile with DBI violation counts, rent-control status, and risk forecast
- Fetch recent records from any of 13 SF datasets
- Search landlords and rank their portfolios by DBI Notice of Violation severity
- Check soft-story seismic retrofit compliance
- Look up tenant buyout (Ellis Act) filings
SF tool reference
| Tool | What it returns |
|---|---|
sf_find_buildings(query, limit) |
Search SF buildings by address fragment. Returns address, block-lot, neighborhood, and summary violation counts. |
sf_get_building_profile(blocklot) |
Full building profile: ownership, physical specs, risk score, rent-control analysis, DBI violation aggregates, and premium report availability. |
sf_get_building_records(dataset_name, blocklot, limit) |
Recent records from one dataset. See the table below for valid dataset_name values. |
sf_find_landlords(name, limit) |
Search owners and management companies. Returns portfolio summaries with building counts, units, and DBI NOV totals. |
sf_select_landlord(name) |
Set this session's landlord for subsequent sf_list_landlord_buildings calls. |
sf_list_landlord_buildings(landlord_name, limit) |
A landlord's buildings sorted by DBI Notice of Violation count — worst properties first. |
sf_get_selected_building() |
Return the currently selected building's block-lot and address. |
Available SF datasets
These are the dataset_name values you can pass to sf_get_building_records:
| Data source | Key | Agency | What it shows |
|---|---|---|---|
| Building Permits | building_permits |
SF DBI | Construction, alteration, repair permits — with estimated costs and status |
| Plumbing Permits | plumbing_permits |
SF DBI | Plumbing installation, repair, and replacement permits |
| Electrical Permits | electrical_permits |
SF DBI | Wiring, panel upgrades, and related electrical permits |
| Soft Story Program | soft_story |
SF DBI | Seismic retrofit compliance for soft-story wood-frame buildings |
| DBI Violations (NOV) | building_violations |
SF DBI | Notices of Violation for code violations — unresolved ones can escalate to legal action |
| DBI Complaints | dbi_complaints |
SF DBI | Code violation complaints filed with DBI, lifecycle from filing to abatement |
| Planning Projects | planning_project |
SF Planning | Entitlements — discretionary review, conditional use, variances |
| Planning Non-Projects | planning_non_project |
SF Planning | Administrative records — pre-app meetings, compliance, referrals |
| 311 Service Requests | calls_311 |
SF 311 | Maintenance, street, and quality-of-life requests geocoded to the parcel |
| Fire Complaints | fire_complaints |
SFFD | Fire code complaints, type, disposition, and outcome |
| Fire Incidents | fire_incidents |
SFFD | Structure fires, alarms, and emergency responses |
| Fire Violations | fire_violations |
SFFD | Fire code violations with corrective actions |
| Tenant Buyout Agreements | buyouts |
SF Rent Board | Ellis Act buyout amounts paid to tenants to vacate rent-controlled units |
Applies to: San Francisco buildings only. SF has 13 datasets vs. NYC's 26+ — a smaller set that reflects fewer agency silos. DBI functions as both NYC's HPD and DOB.
Example queries
Find a building and check its rent control status:
Look up 500 Jones Street in SF and tell me if it's rent-controlled
Your agent calls sf_find_buildings("500 Jones Street") to get the block-lot, then sf_get_building_profile to get the full report — which includes rent-control analysis (pre-1979 construction, Costa-Hawkins exemptions, Rent Board registration).
Check soft story compliance:
Is 888 Howard Street compliant with the soft story program?
Calls sf_get_building_records(dataset_name="soft_story", blocklot="..."). Returns retrofit compliance status for this wood-frame building.
Look up landlord risk:
Show me the worst buildings owned by Veritas Investments in SF
Calls sf_find_landlords(name="Veritas") then sf_list_landlord_buildings(landlord_name="Veritas Investments"). Results sorted by DBI Notice of Violation count.
What's different from NYC via MCP
| Aspect | NYC MCP | SF MCP |
|---|---|---|
| Building identifier | BBL (10-digit) | Block-Lot (e.g., 1234-567) |
| Code enforcement agency | HPD (violations) + DOB (permits) | DBI (does both) |
| Rent regulation | Rent Stabilization (DHCR/RGB) | Rent Control (SF Rent Board) |
| Unique SF datasets | Not available | Soft story compliance, tenant buyouts |
| Unique NYC datasets | Bedbug, rodent, OATH, tax liens | Not available |
Tips
- Block-lot format —
block-lotseparated by a hyphen, e.g.,1234-567. Unlike NYC's BBL, there's no borough prefix - Some datasets are locked — DBI complaints, fire incidents, and premium-owned records require an Augrented account and may need credits
- Tenant buyouts are SF-specific — this data comes from the SF Rent Board and has no NYC equivalent. It reflects Ellis Act buyout agreements
- Rent control vs. rent stabilization — SF uses the pre-1979 threshold and Costa-Hawkins exemptions. The analysis is included in the building profile
Search any SF address — free for your first 10 buildings.