Metadata-Version: 2.4
Name: abelfeed-bidnetdirect
Version: 0.1.1
Summary: Python SDK, CLI, and MCP client for US Government Solicitations on BidNet Direct.
Author: Abelfeed
License-Expression: MIT
Project-URL: Homepage, https://apify.com/abelfeed/bidnetdirect-solicitations-fast-api
Project-URL: Repository, https://github.com/abelfeed/bidnetdirect-solicitations-api
Project-URL: Issues, https://github.com/abelfeed/bidnetdirect-solicitations-api/issues
Keywords: bidnet,bidnetdirect,government-bids,rfp,procurement,govtech,apify,mcp
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Office/Business
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: apify-client>=1.8.0
Dynamic: license-file

# BidNet Direct Solicitations API (Python SDK, CLI & MCP)

[![CI](https://github.com/abelfeed/bidnetdirect-solicitations-api/actions/workflows/ci.yml/badge.svg)](https://github.com/abelfeed/bidnetdirect-solicitations-api/actions/workflows/ci.yml)
[![PyPI](https://img.shields.io/pypi/v/abelfeed-bidnetdirect.svg)](https://pypi.org/project/abelfeed-bidnetdirect/)
[![Python](https://img.shields.io/pypi/pyversions/abelfeed-bidnetdirect.svg)](https://pypi.org/project/abelfeed-bidnetdirect/)
[![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)

Open-source Python client, CLI (`bidnetdirect-fetch`), and Model Context Protocol (MCP) manifest for querying Open and Closed US government solicitations (Federal, State & Local, Member Agency) from BidNet Direct.

## Installation

```bash
pip install abelfeed-bidnetdirect
export APIFY_TOKEN="your_apify_token"
```

## Python Usage

```python
from abelfeed_bidnetdirect import BidNetDirectClient

client = BidNetDirectClient()
bids = client.fetch(
    status="open",
    location="California",
    category="Construction",
    publish_date="WEEK_1",
    max_items=50,
    include_details=True,
    exclude_keywords=["janitorial", "landscaping"],
)

for bid in bids[:5]:
    print(bid["solicitationId"], bid["closingAtIso"], bid["title"])
```

## CLI Usage

```bash
# Latest 25 open Federal bids mentioning "cybersecurity"
bidnetdirect-fetch --scope federal --keywords cybersecurity --max-items 25 -o bids.json

# Closed Member Agency bids with public issuing organization and source URLs
bidnetdirect-fetch --status closed --scope member_agency --max-items 20
```

## MCP Server (Claude Desktop / Cursor / VS Code)

Registered on the Official MCP Registry as `io.github.abelfeed/bidnetdirect-solicitations` (see [server.json](server.json)):

```json
{
  "mcpServers": {
    "abelfeed-bidnetdirect": {
      "url": "https://mcp.apify.com/?tools=abelfeed/bidnetdirect-solicitations-fast-api",
      "headers": {
        "Authorization": "Bearer YOUR_APIFY_TOKEN"
      }
    }
  }
}
```

## Development & Testing

```bash
pip install -e . pytest
pytest -v
```

## Hosted Backend & Security

This package is a thin MIT-licensed wrapper around the hosted Apify Actor [`abelfeed/bidnetdirect-solicitations-fast-api`](https://apify.com/abelfeed/bidnetdirect-solicitations-fast-api). See [SECURITY.md](SECURITY.md) for vulnerability disclosure and OIDC Trusted Publishing details.

## License

MIT - see [LICENSE](LICENSE).
