# Grants.gov Scraper: Federal Grant Opportunities & Deadlines (`hirethomas/grants-gov-opportunity-intelligence`) Actor

Grants.gov scraper: search official US federal grant opportunities by keyword, agency and status. Export opportunity titles, numbers, open/close dates, ALN codes and days to deadline to JSON or CSV. Official public API, $1.20 per 1,000 results.

- **URL**: https://apify.com/hirethomas/grants-gov-opportunity-intelligence.md
- **Developed by:** [Brindlewave Data](https://apify.com/hirethomas) (community)
- **Categories:** Business, Lead generation
- **Security:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per event

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

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

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
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.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## 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.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Grants.gov Opportunity Intelligence

Search the official Grants.gov public API and export clean, normalized federal grant opportunity rows. Designed for grant researchers, nonprofit prospecting, academic funding searches and internal deadline monitoring.

**This product uses the Grants.gov API but is not endorsed or certified by the U.S. Department of Health and Human Services.**

### Quick start

```json
{"keyword":"cybersecurity","oppStatuses":"posted","rows":5,"maxPages":1}
```

Search by `keyword`, `agencies`, `oppNum`, `aln`, `fundingCategories` or `eligibilities`. Statuses are pipe-separated, for example `forecasted|posted`. `rows` controls results requested per page, capped at 100. `maxPages` caps API pages at 20. Start with a small run before requesting a larger dataset.

### Output

Each row contains ID, opportunity number, title, agency code/name, normalized open/close dates, status, document type, ALN values, a retrieval timestamp and the required non-endorsement notice. `daysUntilClose` is a UTC-based approximate calendar-day count, not a guaranteed submission cutoff. Blank closing dates produce null. Export JSON or CSV from the Apify dataset.

`STATUS` reports successful API-page count, returned rows, source hit count and whether the result is partial because of a page or charge cap. Source failures produce an `ERROR` record and a failed run. Duplicate IDs within a run are suppressed.

### Limitations

This first release uses `search2` search-result fields only. It does not return full synopsis, award ranges, application instructions or attachment contents. Eligibility codes filter source results but do not establish your eligibility. Confirm deadlines and requirements on Grants.gov before acting. This is public registry information, not grant-writing, eligibility, legal or funding advice. Returned opportunities do not imply likely awards. Source data and availability may change.

### Access and pricing

No API key, login or proxy is needed. The Actor uses bounded sequential POST requests, waits between pages and retries transient failures with exponential backoff. It does not bypass source limits. Pay per result: $0.0012 per grant opportunity saved, plus a tiny $0.00005 run start fee. Apify platform usage may also apply to your account.

### Sources

- https://www.grants.gov/api/common/search2
- https://api.grants.gov/v1/api/search2
- https://grants.gov/api/terms-conditions

#### FAQ

##### How do I search Grants.gov for open federal grants?

Enter a keyword, optional agency codes and status (forecasted, posted) and run. You get each opportunity with its number, open and close dates, ALN code and days left to the deadline.

##### Is there a Grants.gov API?

Yes, and this Actor uses the official Grants.gov search API, so you get the same data without writing code. Export JSON, CSV or Excel.

##### Can I get alerts for new grant opportunities?

Save your search as an Apify task, schedule it daily and connect a webhook, Slack or Google Sheets to see new opportunities as they post.

##### Who uses this?

Nonprofits, grant writers, universities and companies that sell to grant-funded organizations.

# Actor input Schema

## `keyword` (type: `string`):

Free text keyword or phrase.

## `agencies` (type: `string`):

Optional Grants.gov agency filter, for example HHS or HHS-NIH11.

## `oppStatuses` (type: `string`):

Pipe-separated posted, closed, archived or forecasted.

## `oppNum` (type: `string`):

Optional exact opportunity-number filter.

## `aln` (type: `string`):

Optional Assistance Listing Number, for example 93.866.

## `fundingCategories` (type: `string`):

Optional Grants.gov category codes.

## `eligibilities` (type: `string`):

Optional pipe-separated Grants.gov eligibility codes.

## `rows` (type: `integer`):

Opportunities requested per call.

## `maxPages` (type: `integer`):

Hard page limit for this run.

## Actor input object example

```json
{
  "keyword": "cybersecurity",
  "oppStatuses": "forecasted|posted",
  "rows": 5,
  "maxPages": 1
}
```

# Actor output Schema

## `results` (type: `string`):

Normalized source records. See README for row fields and limitations.

## `status` (type: `string`):

Returned count and source request status, including partial results.

# 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 = {
    "keyword": "cybersecurity",
    "rows": 5,
    "maxPages": 1
};

// Run the Actor and wait for it to finish
const run = await client.actor("hirethomas/grants-gov-opportunity-intelligence").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 = {
    "keyword": "cybersecurity",
    "rows": 5,
    "maxPages": 1,
}

# Run the Actor and wait for it to finish
run = client.actor("hirethomas/grants-gov-opportunity-intelligence").call(run_input=run_input)

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

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

```

## CLI example

```bash
echo '{
  "keyword": "cybersecurity",
  "rows": 5,
  "maxPages": 1
}' |
apify call hirethomas/grants-gov-opportunity-intelligence --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,hirethomas/grants-gov-opportunity-intelligence"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/YqvymBga124kr8xCh/builds/ysI2XBxoyl4uRz4pL/openapi.json
