# US Court Filing Alerts (CourtListener) (`texxupport/court-filing-alerts-courtlistener`) Actor

Search US court opinions and federal dockets, or watch dockets for new filings, using the CourtListener API. Needs your own free CourtListener token. Public court records, not legal advice. Pay per row.

- **URL**: https://apify.com/texxupport/court-filing-alerts-courtlistener.md
- **Developed by:** [Kye Williams](https://apify.com/texxupport) (community)
- **Security:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $4.00 / 1,000 court records

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

## US Court Filing Alerts (CourtListener)

Search US court opinions and federal dockets, or watch specific dockets for new filings, using the CourtListener API. Get clean rows (case name, court, docket number, filing date, a short excerpt, a link) and run it on a schedule to receive only results you have not seen.

**You need your own free CourtListener API token.** The Actor calls CourtListener with your token, so the requests count against your own account's allowance. Getting a token takes a few minutes (see "Get your token" below).

**Not legal advice, and not for consumer reports.** This Actor returns public court records as they appear on CourtListener. It does not interpret them. CourtListener's terms do not allow its data to be used for consumer reporting (FCRA) purposes.

### Three modes

| Mode | Give it | You get |
| --- | --- | --- |
| Opinions | Search queries, courts, case name or docket number | One row per case-law opinion cluster: case name, court, filing date, docket number, judge, citations, how often it is cited, an excerpt and a link. |
| Dockets | The same filters | One row per federal docket (including bankruptcy courts): case name, court, docket number, filing date, judge, cause, nature of suit, parties, up to three recent documents and a link. |
| Docket entries | CourtListener docket numbers | One row per new filing on the dockets you watch: date, entry number, description, its documents and links. |

Use the Dockets mode to find a case and its docket number, then put that number in Docket entries mode to be alerted to new filings in the case.

### Get your token

1. Create a free CourtListener account and sign in.
2. Open the API page of your profile and copy your token.
3. Paste it into the **CourtListener API token** field. It is stored as a secret setting, so it is hidden after you save it.

CourtListener refuses requests without a token. Free accounts have small limits: their documentation lists about 5 requests a minute, 50 an hour and 125 a day. This Actor is built around that: each request returns up to 20 results, the default is 5 requests per run, and when CourtListener asks for a short pause (under about a minute and a half) the Actor waits and continues. If a longer limit is reached, the run ends with a note and keeps what it delivered. Check your own account's limits on CourtListener; paid memberships raise them.

### Input

| Field | What it does |
| --- | --- |
| `courtListenerToken` | Your CourtListener token (required). |
| `mode` | opinions, dockets or docket-entries. Default opinions. |
| `queries` | Search queries for opinions and dockets. Each is a separate search. Quotes match phrases; AND, OR and NOT work as on the CourtListener website. |
| `courts` | CourtListener court codes such as scotus, ca9, cand or nysb. Empty means all courts. |
| `caseName`, `docketNumber` | Optional filters. |
| `includeUnpublished` | Opinions mode only. CourtListener leaves out unpublished and unknown-status opinions unless asked, which hides many trial-court rulings. On by default, so those are included; turn it off for published opinions only. |
| `docketIds` | Docket-entries mode: docket numbers or CourtListener docket page addresses. |
| `daysBack`, `dateFrom`, `dateTo` | The filing-date window. Default: the last 7 days. |
| `onlyNew` | Deliver only results not delivered before for this search or docket. On by default. |
| `maxResults` | Stop after this many rows. Default 100. |
| `maxRequests` | Safety limit on requests per run. Default 5. |

A search needs at least one of `queries`, `courts`, `caseName` or `docketNumber`, so it cannot accidentally match every court record.

### Alerts on a schedule

1. Choose a mode, paste your token and set your search (or your docket numbers).
2. Leave `onlyNew` on and set `daysBack` to a little more than the gap between runs.
3. Schedule the Actor from the Apify Console (for example every morning).
4. Each run delivers only results you have not seen. If a run stops early (cost cap, request cap or a CourtListener limit), the next run continues where it stopped.

The "already delivered" list is kept in a storage called `court-filing-alerts-state` in your own Apify account. The first time you watch a docket, the Actor also saves its case name and docket number there so it does not spend a request on them again.

### Pricing

You pay per row delivered (pay per event). Apify's platform usage is included, so you are not billed for it separately. See the Pricing tab for the current price. Set a maximum cost per run in the run options to cap spending: the Actor stops as soon as the cap is reached. CourtListener's own charges, if any, are between you and CourtListener.

### Limits and good to know

- **Small allowances.** With a free token you can read roughly 20 results per request and a limited number of requests per day, so very broad searches take several runs. Narrow searches with courts and dates.
- **Dockets mode finds cases by their filing date.** To follow what happens inside a case, put its docket number in Docket entries mode.
- **Coverage depends on CourtListener.** Federal dockets and documents in the RECAP archive are only as complete as CourtListener's collection; not every filing on PACER is there.
- **Descriptions are the court's.** Docket entry descriptions are cut at 1,000 characters.
- **Your token, your use.** The Actor uses the token you supply. CourtListener's terms cover how its API and data may be used, including for commercial products; read them before building a business on this data.
- Court records can contain personal information. You are responsible for using it lawfully.

### Data source and disclaimer

Data comes from CourtListener, a project of the Free Law Project. This Actor is not affiliated with, endorsed by or sponsored by CourtListener or the Free Law Project.

# Actor input Schema

## `courtListenerToken` (type: `string`):

Required unless the Actor's owner has set one. Free: create a CourtListener account, open the API page of your profile and copy your token. Free accounts have small limits (a few requests a minute, tens an hour, about a hundred a day), so this Actor keeps its requests low.

## `mode` (type: `string`):

Opinions searches case law, including unpublished rulings unless you turn that off. Dockets searches federal case dockets, including bankruptcy courts. Docket entries watches the dockets you list for new filings.

## `queries` (type: `array`):

Each query is a separate search and uses at least one request. Quotes match phrases, and AND, OR and NOT work as on the CourtListener website.

## `courts` (type: `array`):

CourtListener court codes such as scotus, ca9, cand or nysb (a bankruptcy court). Leave empty for all courts.

## `caseName` (type: `string`):

Only cases whose name matches this text.

## `docketNumber` (type: `string`):

Only dockets with this docket number, for example 1:24-cv-01234.

## `includeUnpublished` (type: `boolean`):

CourtListener leaves out unpublished and unknown-status opinions unless asked, which hides many trial-court rulings. Leave this on to include them. Opinions search only.

## `docketIds` (type: `array`):

CourtListener docket numbers such as 4214664, or the address of a docket page on CourtListener. Find a docket's number with the dockets mode.

## `daysBack` (type: `integer`):

How far back to look, counted from the end date. Ignored when you fill in a start date.

## `dateFrom` (type: `string`):

First filing date to include, written YYYY-MM-DD.

## `dateTo` (type: `string`):

Last filing date to include, written YYYY-MM-DD. Defaults to today (UTC).

## `onlyNew` (type: `boolean`):

Turn this on and run the Actor on a schedule to get an alert-style feed. The Actor remembers what it delivered for each search or docket.

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

Stop after this many rows. You pay per row delivered, so this also caps your cost.

## `maxRequests` (type: `integer`):

Safety limit per run. Each page of up to 20 results is one request, and every request counts against your free allowance. Raise it only if you need more pages.

## Actor input object example

```json
{
  "mode": "opinions",
  "queries": [
    "\"data breach\""
  ],
  "includeUnpublished": true,
  "daysBack": 7,
  "onlyNew": true,
  "maxResults": 100,
  "maxRequests": 5
}
```

# Actor output Schema

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

Every row delivered by this run, as a table you can download as CSV, Excel or 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 = {
    "queries": [
        "\"data breach\""
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("texxupport/court-filing-alerts-courtlistener").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 = { "queries": ["\"data breach\""] }

# Run the Actor and wait for it to finish
run = client.actor("texxupport/court-filing-alerts-courtlistener").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 '{
  "queries": [
    "\\"data breach\\""
  ]
}' |
apify call texxupport/court-filing-alerts-courtlistener --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,texxupport/court-filing-alerts-courtlistener"
        }
    }
}
```

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/qpC0kVAXP999HfSil/builds/bwhjaoj8bNCjcgUVW/openapi.json
