# Congress Stock Trades Data API (`khadinakbar/congress-stock-trades-data-api`) Actor

Query US House and Senate STOCK Act stock trades as structured rows for MCP and APIs. Filter by politician, ticker, chamber, date range, and buy/sell. $0.008 per trade row.

- **URL**: https://apify.com/khadinakbar/congress-stock-trades-data-api.md
- **Developed by:** [Khadin Akbar](https://apify.com/khadinakbar) (community)
- **Categories:** News, AI, MCP servers
- **Stats:** 1 total users, 0 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $8.00 / 1,000 congress trade rows

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/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
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.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — 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

## Congress Stock Trades Data API

Turn a politician name, ticker, chamber, or date window into **one STOCK Act trade disclosure row each**. This Actor returns structured US **House and Senate** disclosures for MCP agents, journalists, compliance teams, and researchers: politician, party when available, ticker, asset, buy/sell, amount range, dates, and a public source URL.

Use it when you want a **filter-first Congress trades feed** across both chambers. For official House Clerk PTR PDFs only, start with [US Stock Trades — House STOCK Act](https://apify.com/khadinakbar/us-stock-trades-scraper). For live quotes after you have tickers, continue with [Stock Price Tracker](https://apify.com/khadinakbar/stock-price-tracker).

### Use when

- You need recently disclosed House and Senate equity or other reportable transactions as clean JSON rows.
- You already know a member such as `Kean` or a ticker such as `MIDD` and want matching rows plus provenance without maintaining a multi-site disclosure scraper.
- An MCP or research workflow needs delayed STOCK Act disclosures from both chambers in one call.

### Related workflows

- For official House Clerk PTR PDFs with filing-year ZIP parsing, start with [US Stock Trades — House STOCK Act](https://apify.com/khadinakbar/us-stock-trades-scraper).
- For company-insider Form 4 filings, continue with [SEC EDGAR All-in-One Scraper](https://apify.com/khadinakbar/sec-edgar-all-in-one-scraper).
- For current US quotes after you have a ticker list, continue with [Stock Price Tracker](https://apify.com/khadinakbar/stock-price-tracker).

### Practical scenario

A political-risk analyst wants the newest Senate disclosures. They set `chamber` to `Senate`, leave other filters empty, and cap `maxResults` at `5`. The Actor loads the public recent Congress trading feed, keeps Senate rows, and returns politician, ticker when present, `transactionType`, `amountRange`, dates, and `sourceUrl`. A date window with no matching trades finishes `SUCCEEDED` with `VALID_EMPTY` and no `trade-row` charge.

### Quick start input

```json
{
  "maxResults": 8,
  "chamber": "all",
  "transactionType": "all",
  "enrichDetail": false
}
```

That prefill returns up to eight newest public House and Senate disclosure rows. Add `tickers`, `politicianNames`, or dates when you already know the symbol, member, or window.

### Input reference

| Field | Type | What it controls |
|---|---|---|
| `politicianNames` | array | Optional member name filters such as `Kean`. Empty means any filer in the recent feed. |
| `tickers` | array | Optional symbols such as `MIDD` or `AAPL`. Empty means every disclosed symbol. |
| `chamber` | enum | `all`, `House`, or `Senate`. |
| `transactionType` | enum | `all`, `purchase`, `sale`, or `exchange`. Partial sales stay inside sale. |
| `startDate` / `endDate` | string | Inclusive `YYYY-MM-DD` bounds on **transaction** dates. |
| `maxResults` | integer | Billed row cap. Default 25, max 200. |
| `enrichDetail` | boolean | When true with politician or ticker filters, also load matching public politician or ticker pages for deeper history. |

### What data you receive

One dataset item is one disclosed STOCK Act transaction from the public Congress trading feed.

```json
{
  "recordId": "house-k000398-185|amcr|sale|2026-08-10|$1,001---$15,000",
  "politicianName": "Thomas H. Kean, Jr.",
  "chamber": "House",
  "party": "R",
  "bioguideId": "K000398",
  "ticker": "AMCR",
  "assetName": "AMCOR PLC ORDINARY SHARES",
  "assetType": "ST",
  "transactionType": "sale",
  "amountRange": "$1,001 - $15,000",
  "amountMinUsd": 1001,
  "amountMaxUsd": 15000,
  "amountMidUsd": 8001,
  "transactionDate": "2026-08-10",
  "disclosureDate": "2026-09-12",
  "disclosureDelayDays": 33,
  "lateFiling": false,
  "sourceId": "House-K000398-185",
  "sourceUrl": "https://www.quiverquant.com/congresstrading/",
  "source": "quiverquant-congress-trading",
  "scrapedAt": "2026-09-15T12:00:00.000Z"
}
```

| Field | Meaning |
|---|---|
| `politicianName` + `chamber` + `party` | Filer identity and chamber; party when the public source exposes it |
| `ticker` + `assetName` | Symbol when listed, plus the asset description |
| `transactionType` | `purchase`, `partial-purchase`, `sale`, `partial-sale`, or `exchange` |
| `amountRange` | STOCK Act band, not an exact fill price |
| `transactionDate` / `disclosureDate` | Trade date and disclosure date as `YYYY-MM-DD` |
| `sourceUrl` | Public provenance page used for the row |

`OUTPUT` and `RUN_SUMMARY` in the default key-value store hold `outcome`, `itemsPushed`, and `chargedEventCounts`.

### Use through the API

```bash
curl -X POST "https://api.apify.com/v2/acts/khadinakbar~congress-stock-trades-data-api/runs" \
  -H "Authorization: Bearer $APIFY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"maxResults":8,"chamber":"all","transactionType":"all"}'
```

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

const client = new ApifyClient({ token: process.env.APIFY_TOKEN });
const run = await client.actor('khadinakbar/congress-stock-trades-data-api').call({
  maxResults: 8,
  chamber: 'all',
  transactionType: 'all',
});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items);
```

Download rows as JSON, CSV, Excel, or HTML from the Dataset tab.

### Use with AI agents through Apify MCP

> Get the newest US Congress STOCK Act stock trades for both House and Senate. Return politicianName, chamber, ticker, transactionType, transactionDate, amountRange, and sourceUrl. Cap at eight rows.

Connect via <https://mcp.apify.com>. Read `OUTPUT.outcome` before retrying an empty dataset. Cost signal: `$0.008` per saved trade plus platform usage. Scope is delayed public disclosures; live exchange tape stays outside this tool.

### Connect the workflow

- For official House Clerk PTR PDFs, start with [US Stock Trades — House STOCK Act](https://apify.com/khadinakbar/us-stock-trades-scraper) when you need filing PDFs rather than a both-chamber feed.
- For company-insider Form 4 filings, continue with [SEC EDGAR All-in-One Scraper](https://apify.com/khadinakbar/sec-edgar-all-in-one-scraper).
- For current US quotes after you have a ticker list, continue with [Stock Price Tracker](https://apify.com/khadinakbar/stock-price-tracker).

### Pricing

This Actor uses Pay per event plus Apify platform usage. The live Pricing tab is the current source of truth for billing details.

- `apify-actor-start`: $0.00005 at start
- `trade-row`: **$0.008** per saved Congress disclosure row

**Worked example:** a one-trade lookup bills `$0.00805` in events (`$0.008` + start). A short HTTP job usually adds a few tenths of a millidollar of platform usage, so the customer total stays near `$0.0083` with usage pass-through. Eight billed trades are `$0.06405` in events plus the same short job. Empty matches and invalid input have no `trade-row` charge.

### How it works

- Load the public Quiver Quantitative Congress trading page and parse the embedded recent-trades table.
- Optionally enrich matching politician or ticker pages when `enrichDetail` is on.
- Apply politician, ticker, chamber, date, and transaction filters, then cap with `maxResults`.
- Charge `trade-row` only after a validated row is ready, then write the dataset item.

### Best results

- Leave filters empty when you want the latest disclosures; add a ticker or politician only when you can accept a `VALID_EMPTY` miss in a narrow window.
- Keep `enrichDetail` off for fast MCP calls. Turn it on when you need deeper history for a known member or symbol that appears in the recent feed.
- Amounts are statutory ranges. `amountMidUsd` is a convenience midpoint, not a fill price.
- Date filters apply to **transaction dates**, not disclosure filing dates.

### Troubleshooting

| Symptom | Likely cause | What to do |
|---|---|---|
| `VALID_EMPTY`, zero rows | No matching ticker, member, chamber, or date in the loaded pages | Clear filters, widen the date window, or enable `enrichDetail` for a known member/ticker |
| Fewer rows than `maxResults` | The recent feed simply has fewer matching trades | Raise `maxResults` only after confirming matches exist, or clear filters |
| Politician enrich stays empty | The member is outside the recent feed, so no bioguide URL can be resolved | Run without enrich first, or use a member visible in the newest disclosures |
| `INVALID_INPUT` | Bad date order or invalid tickers | Use `YYYY-MM-DD` with start ≤ end, and real symbols such as `AAPL` |
| `UPSTREAM_FAILED` | Public feed page unavailable | Retry; Residential fallback activates only after direct HTTP does not succeed |

### Builder's note

I found that official Senate eFD search often returns an edge challenge to plain HTTP clients, while the public Quiver Quantitative Congress trading page embeds a ready House-and-Senate recent-trades table. That is why this SKU is filter-first over that public aggregator, and why official House PTR PDF extraction stays in a separate Actor for callers who need Clerk PDFs.

### Legal and responsible use

STOCK Act filings are public legislative records. Quiver Quantitative is an independent third-party aggregator of those disclosures. The US House, US Senate, Clerk of the House, and Quiver Quantitative are named here only as sources. This independent Actor is not affiliated with, associated with, or endorsed by Quiver Quantitative, the US House, the US Senate, or the Clerk of the House. Output is delayed disclosure data for journalism, compliance, and research — not live exchange tape or investment advice. Follow applicable law and your own compliance review.

Issues and feature requests: use the Actor Issues tab on Apify.

# Actor input Schema

## `politicianNames` (type: `array`):

Optional member name filters such as Pelosi or Kean. Case-insensitive contains match against the filer display name. Leave empty to return trades from any member in the recent public feed. This is not a party or committee filter.

## `tickers` (type: `array`):

Optional US ticker filters such as AAPL or AMCR. Leave empty to keep every disclosed symbol. With enrichDetail enabled, matching ticker pages are also loaded for deeper history. This is not a company-name search.

## `chamber` (type: `string`):

Keep House trades, Senate trades, or both. Default all. Use Senate when you need senator disclosures that official Senate eFD search often blocks for plain HTTP clients.

## `transactionType` (type: `string`):

Keep purchases, sales, exchanges, or all disclosed transaction types. Partial sales and full sales both match sale. This is the STOCK Act disclosure type, not a broker order type.

## `startDate` (type: `string`):

Inclusive lower bound on transaction date as YYYY-MM-DD. Example: 2026-07-01. Leave blank for no lower bound. This filters trade dates, not disclosure filing dates.

## `endDate` (type: `string`):

Inclusive upper bound on transaction date as YYYY-MM-DD. Pair with startDate. Leave blank for no upper bound.

## `maxResults` (type: `integer`):

Hard cap on billed dataset rows. Default 25, maximum 200. Each saved trade costs $0.008. Use this to bound spend for MCP and API callers.

## `enrichDetail` (type: `boolean`):

When true and politicianNames or tickers are set, also load matching Quiver politician or ticker pages for deeper history beyond the recent feed. Default false keeps the run on the recent public list only.

## Actor input object example

```json
{
  "chamber": "all",
  "transactionType": "all",
  "maxResults": 8,
  "enrichDetail": false
}
```

# Actor output Schema

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

Dataset items with politician, chamber, ticker, transaction type, amount range, dates, and source URL.

## `summary` (type: `string`):

Compact OUTPUT record with outcome, itemsPushed, warnings, and chargedEventCounts.

## `runSummary` (type: `string`):

Detailed RUN\_SUMMARY record for integrations that read RUN\_SUMMARY directly.

# 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 = {
    "chamber": "all",
    "transactionType": "all",
    "maxResults": 8
};

// Run the Actor and wait for it to finish
const run = await client.actor("khadinakbar/congress-stock-trades-data-api").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 = {
    "chamber": "all",
    "transactionType": "all",
    "maxResults": 8,
}

# Run the Actor and wait for it to finish
run = client.actor("khadinakbar/congress-stock-trades-data-api").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 '{
  "chamber": "all",
  "transactionType": "all",
  "maxResults": 8
}' |
apify call khadinakbar/congress-stock-trades-data-api --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,khadinakbar/congress-stock-trades-data-api"
        }
    }
}
```

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/PTZmSHUBvXPImo2vL/builds/1keRa8rPRkHr1g1x1/openapi.json
