# NY Dept. of State MCP Server (`rl1987/ny-dos-mcp-server`) Actor

MCP server exposing NY Dept. of State business entity search and local law search as tools.

- **URL**: https://apify.com/rl1987/ny-dos-mcp-server.md
- **Developed by:** [R.L.](https://apify.com/rl1987) (community)
- **Categories:** MCP servers, Lead generation
- **Stats:** 1 total users, 0 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $10.00 / 1,000 mcp tool calls

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

### NY Dept. of State MCP server

An [MCP](https://modelcontextprotocol.io) server, built with [FastMCP](https://gofastmcp.com), that gives an AI agent tools to search NY Dept. of State public data:

- **Business entity search** — mirrors [apps.dos.ny.gov/publicInquiry](https://apps.dos.ny.gov/publicInquiry/) (corporations, LLCs, LPs, LLPs, assumed names).
- **Local law search** — mirrors [dos.ny.gov/local-law-search](https://dos.ny.gov/local-law-search) (filed local laws and county administrative codes).
- **UCC lien search** — mirrors [ucc-efiling.dos.ny.gov](https://ucc-efiling.dos.ny.gov/OnlineUCCSearch/PublicOnlineUccSearch) (UCC and federal tax liens).

### Tools

#### `search_business_entities`

Search by entity name, DOS ID, or assumed name. Params: `search_value`, `search_by` (`EntityName` / `DosId` / `AssumedName` / `AssumedNameId`), `search_expression` (`BeginsWith` / `Contains` / `BaseWord`), `status` (`AllStatuses` / `Active` / `Inactive` / `Suspended`), `entity_types` (list, defaults to all of Corporation/LLC/LP/LLP), `limit`, `offset`.

Returns `entityName`, `dosID`, `entityType`, `entityStatus`, `county`, `jurisdiction`, `initialFilingDate` per match. The upstream service caps how many matches a single search returns — narrow your terms if `totalMatchingCount` looks truncated.

#### `get_business_entity_details`

Full record for one entity: `dos_id` and `entity_name` (both from a search result), plus `is_assumed_name` if the record's `nameType` wasn't `ACTUAL`. Returns filing info, Service of Process address, registered agent, CEO, location/PO addresses, and stock share info. DOS does not serve filing documents as direct PDFs through this API — copies must be ordered separately via [dos.ny.gov/copies-corporation-or-business-entity-documents](https://dos.ny.gov/copies-corporation-or-business-entity-documents).

#### `search_local_laws`

Search filed local laws or county codes. Params: `law_type` (`localLaws` / `countyCodes`), `municipality_name`, `municipality_type` (`COUNTY`/`CITY`/`TOWN`/`VILLAGE`, `localLaws` only), `law_number`, `date_filed_from`/`date_filed_to` (YYYY-MM-DD), `search_terms` (full-text, searches document text too), `limit` (max 100), `offset` (offset + limit must be ≤ 10000, an upstream limit).

Each result includes metadata (municipality, law number, year, date filed, title) and a direct `pdfUrl` — every local law/county code is a PDF, so the URL is just included in the output rather than fetched.

#### `search_ucc_filings`

Search by filing number, or by debtor name (individual or organization). Params: `search_by` (`FilingNumber` / `DebtorName`), `filing_number`, `debtor_type` (`Individual` / `Organization`), name fields (`last_name`/`first_name`/`middle_name` or `org_name`/`org_id`/`org_jurisdiction`), `search_logic` (`Standard`/`StartsWith`/`ExactMatch`/`ContainsAllWordsInOrder`), `lien_type` (`All`/`UCCLien`/`FederalTaxLien`), `lien_status` (`All`/`Active`/`Released`/`Withdrawn`/`Purged`/`Lapsed`), `filing_date_from`/`filing_date_to`, `lapse_date_from`/`lapse_date_to` (all dates YYYY-MM-DD), `limit`, `offset`.

Returns matching liens (`lienId`, `lienNumber`, debtor name/address/type, filing/lapse dates, status). Pass a result's `lienId` to `get_ucc_lien_details` for the full record.

#### `get_ucc_lien_details`

Full record for one lien: `lien_id` (from a search result). Returns lien info, every debtor, every secured party, and the filing history (each UCC-1/UCC-3 action against the lien).

Note: UCC filing documents are scanned images served only through an authenticated download flow on the source site, not direct URLs — neither UCC tool returns document links.

### Connect to this MCP server

No installation, no code to write — you just need an Apify account and its API token.

#### 1. Get your Apify API token

1. Go to [console.apify.com](https://console.apify.com) and sign in (a free account works — this actor is billed per tool call via Pay Per Event, not a subscription).
2. Open [Settings → Integrations](https://console.apify.com/account/integrations) and copy your **Personal API token**.

This token is *yours* (the caller's) — it identifies you for billing and usage, not the actor's owner. Keep it secret; anyone with it can run actors and spend on your account.

#### 2. Find the endpoint URL

Once this actor is published on Apify, its Standby MCP endpoint is:

````

https://rl1987--ny-dos-mcp-server.apify.actor/mcp

````

You can also find this exact URL on the actor's page in Apify Console, under the **Integrations** / **MCP** tab — copy it from there rather than guessing the owner's username.

#### 3. Connect your AI tool

**Claude Code (CLI):**

```bash
claude mcp add --transport http ny-dos \
  https://rl1987--ny-dos-mcp-server.apify.actor/mcp \
  --header "Authorization: Bearer <YOUR_APIFY_API_TOKEN>"
````

**Claude Desktop / other JSON-config MCP clients** — add to your MCP config file:

```json
{
  "mcpServers": {
    "ny-dos": {
      "url": "https://rl1987--ny-dos-mcp-server.apify.actor/mcp",
      "headers": {
        "Authorization": "Bearer <YOUR_APIFY_API_TOKEN>"
      }
    }
  }
}
```

**Any other MCP-compatible client** (Cursor, Windsurf, etc.): the same URL + `Authorization: Bearer <token>` header pattern applies — look for an "MCP server" or "custom connector" setting that takes a URL and custom headers.

#### 4. Verify it worked

- Claude Code: run `claude mcp list` or type `/mcp` in a session — you should see `ny-dos` connected with 5 tools.
- Other clients: ask your AI assistant something like *"search NY business entities for Apple"* — if it calls a tool and returns results, you're connected.

#### Sharing with a team

Commit a `.mcp.json` with just the `url` (no token) to a shared repo. Each teammate then adds their own token locally:

```bash
claude mcp add --scope local ny-dos https://rl1987--ny-dos-mcp-server.apify.actor/mcp \
  --header "Authorization: Bearer <THEIR_OWN_APIFY_API_TOKEN>"
```

This way nobody's token ends up in version control, and each person is billed individually for their own tool calls.

#### What it costs

Every completed tool call (a search or a detail lookup) charges one flat fee — see the price on the actor's Console page under **Pricing**. There's no charge for a failed call or for just connecting/listing tools. New Apify accounts get free platform credits, so light testing is typically free.

### Resources

- [What is Anthropic's Model Context Protocol?](https://blog.apify.com/what-is-model-context-protocol/)
- [FastMCP documentation](https://gofastmcp.com/getting-started/welcome)
- [Apify MCP server documentation](https://docs.apify.com/platform/integrations/mcp)
- [Apify SDK for Python documentation](https://docs.apify.com/sdk/python/)

# Actor input Schema

## Actor input object example

```json
{}
```

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {};

// Run the Actor and wait for it to finish
const run = await client.actor("rl1987/ny-dos-mcp-server").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {}

# Run the Actor and wait for it to finish
run = client.actor("rl1987/ny-dos-mcp-server").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{}' |
apify call rl1987/ny-dos-mcp-server --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=rl1987/ny-dos-mcp-server",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "NY Dept. of State MCP Server",
        "description": "MCP server exposing NY Dept. of State business entity search and local law search as tools.",
        "version": "0.0",
        "x-build-id": "zVxxFEuJ0axVMYry6"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/rl1987~ny-dos-mcp-server/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-rl1987-ny-dos-mcp-server",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/rl1987~ny-dos-mcp-server/runs": {
            "post": {
                "operationId": "runs-sync-rl1987-ny-dos-mcp-server",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/rl1987~ny-dos-mcp-server/run-sync": {
            "post": {
                "operationId": "run-sync-rl1987-ny-dos-mcp-server",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "properties": {}
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
