# Court Records Scraper - PACER Alternative API (`maydit/us-court-cases-scraper`) Actor

Free court records scraper and PACER alternative. Export federal court dockets AND case-law opinions from CourtListener to CSV/JSON. No PACER account.

- **URL**: https://apify.com/maydit/us-court-cases-scraper.md
- **Developed by:** [Brandt May](https://apify.com/maydit) (community)
- **Categories:** News, Developer tools
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.80 / 1,000 results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#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

## Court Records Scraper - Federal Dockets & Case Law (PACER Alternative)

> Pull US court records without a PACER account: federal dockets AND case-law opinions in one Actor, exported straight to CSV or JSON.

### What it does

This **court records scraper** searches US federal court dockets and published case-law opinions through the official **CourtListener / RECAP** public API and returns clean, normalized records. It works as a free **PACER alternative** for teams that need structured litigation data without per-page PACER fees. Run it in two modes from a single Actor: **dockets** mode pulls RECAP federal case records (parties, judges, law firms, causes), and **opinions** mode pulls case law with reporter citations and precedential status. Filter by keyword, court, and date window, then export to CSV, JSON, or Excel, or wire it into your own pipeline via the Apify API. Because it covers both federal dockets and court opinions, it doubles as a **litigation data scraper**, a **court opinions scraper**, and a **court docket monitoring** tool.

### Who it's for

- **Legal tech and litigation intelligence teams** building case databases and analytics
- **Law firms** running due diligence and conflict / party checks
- **Journalists and investigative reporters** tracking court activity
- **Academic and legal researchers** assembling case-law and citation datasets
- **Compliance, risk, and litigation-finance analysts** monitoring new filings

### What you get / Output

Every record is normalized to consistent fields. Availability of some fields depends on the mode (dockets vs. opinions) and what the source publishes for a given case.

| Field | Description |
|---|---|
| `type` | Record type (docket or opinion) |
| `caseName` | Full case / matter name |
| `court` | Court name |
| `courtId` | CourtListener court identifier (e.g. `scotus`, `cand`, `nysd`) |
| `docketNumber` | Docket number for the case |
| `dateFiled` | Date the case or opinion was filed |
| `dateTerminated` | Date the case was terminated (dockets) |
| `dateArgued` | Date the case was argued (where available) |
| `judge` | Assigned or authoring judge |
| `cause` | Legal cause of action |
| `natureOfSuit` | Nature of suit classification |
| `jurisdictionType` | Jurisdiction type |
| `citation` | Reporter citation(s) for opinions |
| `status` | Precedential / case status |
| `attorneys` | Counsel of record (where available) |
| `firm` | Law firm(s) associated with the case (where available) |
| `url` | Source link to the record on CourtListener |

### Input / How to query

Configure a run with these inputs:

- **`searchType`** - choose the mode: `dockets` (RECAP federal cases with parties, judges, firms, causes) or `opinions` (published case law with citations and precedential status).
- **`keyword`** - full-text query, e.g. a company name, `data breach`, or `patent infringement`. Leave empty to browse the newest records with filters only.
- **`court`** - restrict to one CourtListener court by ID, e.g. `scotus` (Supreme Court), `cand` (N.D. Cal.), `nysd` (S.D.N.Y.), `dcd` (D.D.C.). Leave empty for all courts.
- **`filedSince`** - only records filed on or after this date (`YYYY-MM-DD`). Ideal for weekly monitoring.
- **`filedUntil`** - only records filed on or before this date (`YYYY-MM-DD`).
- **`orderBy`** - sort results, e.g. `dateFiled desc` (newest first) or `dateFiled asc` (oldest first).
- **`maxResults`** - upper bound on records returned per run.

### Example use cases

- **Track lawsuits against a company** - set `searchType=dockets`, `keyword="Acme Corp"`, `orderBy=dateFiled desc` to surface the newest federal cases naming that party.
- **Weekly new-filings monitor** - schedule a run with `filedSince` set to the past week and a `court` (e.g. `nysd`) to capture fresh litigation in a jurisdiction you care about.
- **Build a case-law dataset** - set `searchType=opinions` to export published opinions with their reporter citations and precedential status for research.
- **Due-diligence conflict check** - run keyword searches on parties and counsel across all courts, then export to CSV for review before onboarding a client or closing a deal.
- **Topic-based litigation intelligence** - search `data breach` or `patent infringement` to feed a compliance or risk dashboard with structured docket metadata.

### Recurring use / scheduling

This Actor is built for **court docket monitoring** on a schedule. Use Apify **Schedules** to run it daily or weekly with a rolling `filedSince` date so each run captures only newly filed cases and opinions. Point runs at the same named dataset to accumulate a growing corpus over time, or keep runs separate and dedupe downstream on `url` or `docketNumber`, which are stable identifiers for each record. Pair scheduling with Apify integrations (webhooks, Zapier, Make, Slack, or email) to get alerts whenever new records match your keyword or court.

### FAQ

#### How do I get court case data without paying PACER fees?

Run this Actor. It pulls federal case records from the CourtListener RECAP archive, a free public source, so you get structured docket data without a PACER account or per-page fees.

#### How can I scrape federal court dockets from CourtListener?

Set `searchType=dockets`, add a `keyword` and optional `court` / date filters, then run. You get normalized docket records with case name, docket number, court, judge, cause, nature of suit, and counsel where available.

#### What is the best free alternative to the PACER API?

CourtListener's RECAP archive is the leading free source for federal docket data, and this Actor turns it into clean CSV / JSON output. It is free to run on Apify and needs no PACER credentials.

#### How do I download court opinions and case law as CSV or JSON?

Set `searchType=opinions` and run, then export the dataset from Apify as CSV, JSON, or Excel, or fetch it via the API. Opinion records include reporter citations and precedential status.

#### How can I track lawsuits filed against a specific company?

Use `searchType=dockets` with the company name as your `keyword` and `orderBy=dateFiled desc`. Schedule it weekly with a rolling `filedSince` to catch each new case as it is filed.

#### How do I monitor new federal court filings by court or date?

Combine the `court` filter (e.g. `cand`, `nysd`) with `filedSince` / `filedUntil`, sorted `dateFiled desc`, and schedule the run so each execution returns only the latest filings in that court and window.

#### What court data fields can I export?

Records include case name, court and court ID, docket number, filing / argued / terminated dates, judge, cause, nature of suit, jurisdiction type, citation, status, attorneys, firm, and a source URL - see the output table above.

#### Is scraping public court records legal?

This Actor reads public court data from CourtListener's official API. Court records in these sources are public. As with any data use, follow CourtListener's terms and apply your own judgment for your jurisdiction and use case.

#### How do I search both federal dockets and case-law opinions in one tool?

That is this Actor's core advantage: flip the `searchType` input between `dockets` and `opinions` to search RECAP federal dockets or published case law from the same Actor - no second tool needed.

#### How can I set up alerts for new litigation matching a keyword?

Schedule the Actor with your `keyword` and a rolling `filedSince`, then connect an Apify integration (webhook, Slack, email, Zapier, or Make) so you are notified whenever a new matching record appears.

### Data source & notes

- **Source:** [CourtListener](https://www.courtlistener.com/) by the **Free Law Project**, via its official public API (including the RECAP federal docket archive).
- **Coverage:** US federal court dockets (RECAP) and published court opinions / case law. Field availability varies by mode and by what the source publishes for each record - for example, `attorneys`, `firm`, and some dates may be absent on individual cases.
- **Access:** Free to run; no PACER account required.
- **Use responsibly:** Data reflects what is publicly available on CourtListener at run time. Verify critical facts against primary court sources for legal decisions, and follow the source's terms of use.
- **Actor:** `maydit/us-court-cases-scraper` (id `cjLNkDqsBxobJ02Hb`).

### Related actors

Part of a set of US public-records tools that work well together:

- [SEC EDGAR Filings Scraper](https://apify.com/maydit/sec-edgar-filings-scraper) - company filings to pair with litigation research
- [Federal Register Scraper](https://apify.com/maydit/us-federal-register-scraper) - the regulatory backdrop to many federal cases

See all fifteen at [apify.com/maydit](https://apify.com/maydit).

### Found this useful?

If this actor saved you time, a short review on the Apify Store genuinely helps. Reviews are how the next person decides whether a tool is worth trying.

Something broken, missing a field, or a source you want covered? Open an issue on the **Issues** tab and it will get looked at - that is the fastest route to getting it changed.

# Actor input Schema

## `searchType` (type: `string`):

Dockets = RECAP federal court cases (parties, judges, firms, causes). Opinions = published case law / court opinions (citations, status).

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

Full-text search query, e.g. a company name, 'data breach', 'patent infringement'. Leave empty to browse the newest cases (with filters).

## `court` (type: `string`):

Restrict to one CourtListener court, e.g. 'scotus' (Supreme Court), 'cand' (N.D. Cal.), 'nysd' (S.D.N.Y.), 'dcd' (D.D.C.). Leave empty for all courts.

## `filedSince` (type: `string`):

Only cases/opinions filed on or after this date (YYYY-MM-DD). Great for weekly litigation monitoring.

## `filedUntil` (type: `string`):

Only cases/opinions filed on or before this date (YYYY-MM-DD).

## `orderBy` (type: `string`):

Sort order. 'dateFiled desc' = newest first. 'score desc' = most relevant. 'citeCount desc' = most-cited (opinions).

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

Upper bound on records returned per run.

## `apiToken` (type: `string`):

Optional free CourtListener API token for higher rate limits on large runs. Get one at courtlistener.com. Not required for normal use.

## Actor input object example

```json
{
  "searchType": "dockets",
  "keyword": "\"data breach\"",
  "filedSince": "2026-06-01",
  "orderBy": "dateFiled desc",
  "maxResults": 1000
}
```

# 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("maydit/us-court-cases-scraper").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("maydit/us-court-cases-scraper").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 maydit/us-court-cases-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=maydit/us-court-cases-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

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