Spiral gives your agent every tool with one account. Browse the tools →

Windsurf · Listings

How to Use DataSF record count in Windsurf

Returns the number of records matching a DataSF dataset query. Use it for a how-many question or to size an extraction, while checking whether several rows can describe the same permit or event.

Prompts to try with DataSF record count in Windsurf

Copy an example into Windsurf, or ask in your own words.

Use DataSF record count to count 311 Cases created during October 2026, then add the result and query criteria to this project's report.

DataSF record countWindsurf
Try asking
  • Use DataSF record count to look this up and give me the result as a table. Save the result in ./assets.

  • Pull the latest numbers from DataSF record count and tell me what changed since last week.

  • Check DataSF record count and summarize what you find in three bullet points.

  • Pull the newest data from DataSF record count and give me the result as a table.

How to set up DataSF record count in Windsurf

Pick the way that suits you. Each takes about two minutes.

Use Spiral's MCP server

  1. Add the server

    Open the Customize page from the Agents window and click MCPs. Under This computer, open the config file, or edit it directly: ~/.config/devin/mcp_config.json on macOS and Linux, %APPDATA%\devin\mcp_config.json on Windows. Add this:

    {
      "mcpServers": {
        "spiral": {
          "url": "https://api.spiral.ai/mcp"
        }
      }
    }
  2. Sign in

    Click Authenticate on the Spiral server in Customize › MCPs, or let the agent call Spiral once: your browser opens. Sign in to Spiral, pick the organization and click Authorize. No API key.

    devin mcp login spiral
  3. Check it

    Spiral is listed under This computer in Customize › MCPs. From the terminal:

    devin mcp list

Use the Spiral skill

  1. Send Windsurf this message

    Your agent reads Spiral's skill and sets itself up.

    set up https://spiral.ai/SKILL.md
  2. Sign in or paste a key

    Approve Spiral in the browser, or give the agent a key from the console.

Use the Spiral CLI

  1. Install and sign in

    Installs the Spiral CLI, signs you in and adds its skill to your coding agents.

    npx -y spiral-cli@latest init

Call the Spiral API

  1. Create an API key

    In the console, under API keys.

  2. Run DataSF record count

    One request; the result comes back by polling or a webhook.

    curl https://api.spiral.ai/v1/runs \
      -H "Authorization: Bearer $SPIRAL_API_KEY" \
      -H "Content-Type: application/json" \
      -H "Idempotency-Key: $(uuidgen)" \
      -d '{
        "provider": "alexandria",
        "model": "data-sf-gov/open-data/row_count",
        "input": {
          "dataset_id": "<dataset_id>"
        }
      }'

Then paste one of the prompts above: Windsurf finds DataSF record count on Spiral, shows the price and runs it.

DataSF record count providers and prices

Spiral runs DataSF record count through Alexandria. Open a card for today's price, with every fee included.

AlexandriaListings
DataSF open data portal · Row count
data-sf-gov/open-data/row_count

What can you do with DataSF record count in Windsurf?

Build a San Francisco civic report backed by source definitions and queryable records. A coding agent can turn catalog discovery, schema inspection, and record counts into an analysis that fits your project's files.

Build a permit activity briefing

Find permit sources through the catalog's categories and tags, inspect their definitions, count the selected period, and retrieve records for a monthly construction briefing. Account for permits that cover multiple addresses.

Compare neighborhood service requests

Locate the 311 source through catalog discovery, verify its neighborhood and date definitions, and compare matching record totals with a breakdown of requests. Label the result as service requests.

Prepare a scoped data extraction

Discover relevant tables using the catalog vocabulary, inspect their schemas, and count matching records before retrieving a defined date range. Use the result to populate a civic analysis project.

Audit sources behind a civic report

Review the categories, search results, and dataset definitions behind a housing or city services report. Recalculate its record totals and retrieve supporting records so the published figures can be checked.

Check permit counting assumptions

Inspect the Building Permits documentation, count records for a selected period, and examine repeated permit numbers. Establish whether a report needs address-level rows or a deduplicated permit total.

Questions about DataSF record count in Windsurf

Can Windsurf use DataSF record count?

Yes. Add Spiral to Windsurf as an MCP server, and Windsurf can find and run DataSF record count like any built-in tool.

How much does DataSF record count cost in Windsurf?

$0.00873 per call. You pay from your Spiral balance as you go, with no subscription, and a failed run is not charged. Your Windsurf plan is separate.

Do I need an Alexandria account to use DataSF record count in Windsurf?

No. Spiral runs DataSF record count on its own Alexandria account. You sign in to Spiral once and never paste a key.

How long does it take to set up DataSF record count in Windsurf?

About two minutes: add the server, then sign in, then check it.

Does Windsurf wait while DataSF record count runs?

DataSF record count runs in the background. Windsurf starts the run, checks on it and gives you the json when it's ready.

Is every DataSF search result a dataset?

No. The catalog can include tables, charts, maps, stories, and derived views. Check the result's type before choosing a source for record analysis.

How fresh is DataSF data?

Refresh schedules depend on the dataset. DataSF documents an approximately 10 a.m. daily refresh for 311 Cases, while DBI uploads Building Permits nightly.

How much historical data is available?

History depends on the selected dataset. For example, 311 Cases covers eligible cases created on July 1, 2008, or later.

Does a row count equal the number of permits?

Not necessarily. Building Permits can repeat one permit across multiple rows when it has multiple associated addresses, so counting rows can overstate the number of permits.

Does DataSF guarantee the data is accurate?

No. The city's terms say the data is subject to error and cannot be relied on without verification or a site inspection.

Get started

Start using DataSF record count in Windsurf

One Spiral account for every tool your agent needs. No subscription; you pay per run.

Paste this into Windsurf:

Set up Windsurf

set up https://spiral.ai/SKILL.md
Are you an AI agent? See setup options