Skip to main content
Glama
EdgeworthHitbox

Colorado DWR MCP Server

README.md
# Colorado DWR MCP Server

This is a Model Context Protocol (MCP) server that interfaces with the Colorado Division of Water Resources (DWR) REST API. It allows AI models to retrieve water data, rights, permits, and administrative calls.

## Features

- **Surface Water Stations**: Search for stations by name, location, etc.
- **Surface Water Time Series**: Get daily time series data (streamflow, etc.).
- **Water Rights**: Query net amounts and transactions.
- **Well Permits**: Search for well permits.
- **Administrative Calls**: Get active administrative calls.
- **Generic Query**: Flexible tool to query any DWR API endpoint.

## Installation

1.  Clone this repository.
2.  Install dependencies:
    ```bash
    npm install
    ```
3.  Build the server:
    ```bash
    npm run build
    ```

## Usage

### Stdio Mode (for local clients like Claude Desktop)

```bash
node build/index.js
```

### HTTP/SSE Mode (for remote connections)

```bash
node build/sse.js
```

This will start a server at `http://localhost:3000`.
- **SSE Endpoint**: `http://localhost:3000/sse`

### Configuration

No API key is strictly required for basic usage, but if you have one, you can set it via the `DWR_API_KEY` environment variable.

### Tools

- `get_surface_water_stations`
- `get_surface_water_ts_day`
- `get_water_rights_net_amount`
- `get_well_permits`
- `get_active_admin_calls`
- `query_dwr_api`

## Development

Run the test client to verify functionality:

```bash
npx tsx test_client.ts
```

TDQS

B3.1/5.0

Scored across 6 tools

Disambiguation4/5

Most tools have distinct purposes targeting different DWR resources like administrative calls, surface water stations, water rights, and well permits. However, 'get_surface_water_stations' and 'get_surface_water_ts_day' could potentially be confused as both relate to surface water stations, though their actions (search vs. get time series) differ. The 'query_dwr_api' tool is clearly distinct as a generic fallback.

Naming Consistency5/5

All tools follow a consistent 'get_' or 'query_' verb prefix with snake_case naming, making them predictable and readable. The pattern is uniform across all six tools, with no deviations in style or convention.

Tool Count4/5

With 6 tools, the count is reasonable for a DWR data server, covering key resources like water stations, rights, and permits. It's slightly lean but not inadequate, as the generic 'query_dwr_api' tool can extend functionality. A few more specialized tools might enhance coverage, but this is well-scoped.

Completeness3/5

The tools cover read operations for major DWR data types, but there are notable gaps in lifecycle coverage. For example, there are no tools for creating, updating, or deleting records, which might be expected in a full administrative system. The generic query tool helps mitigate this, but the surface is incomplete for CRUD workflows.

Maintenance

ActivityInactive
ResponsivenessNo issues