# UniCourt MCP

> UniCourt connects your AI agent directly to real-time legal data and court records. It lets you search millions of cases, track litigation updates automatically, and pull structured profiles for attorneys, judges, and law firms using natural language queries.

## Overview
- **Category:** data-management
- **Price:** Free
- **Tags:** court-records, legal-research, litigation-tracking, case-search, attorney-data

## Description

UniCourt hooks your AI agent right into live legal data and court records. You'll use this server to search millions of filed cases, track updates on ongoing litigation, and pull detailed, structured profiles for anyone involved—attorneys, judges, firms, or parties. 

To get started, you first need credentials management. Your agent can **`get_pacer_credential`** to check the current status of your PACER account details, use **`update_pacer_credential`** to manage those accounts, and even call **`delete_pacer_credential`** if you need to wipe the slate clean. If you're building a new connection, **`generate_token`** creates a fresh UniCourt access token for your agent.

When it comes to finding cases, you've got several routes. You can run a broad search across the entire court database using **`search_cases`**, letting you filter by keywords and criteria to locate records. If you know exactly what you want, **`get_case`** pulls every available detail for a specific case ID. For direct lookups through PACER, the **`search_pacer_case_locator`** handles it. You can also bring cases into your system using high priority by calling **`import_case`**, or if a record is missing, **`import_pacer_case`** gets that case added using your existing PACER credentials. For big picture analysis, **`get_case_count_analytics`** retrieves analytics showing how many cases fall into different types.

To keep tabs on active litigation, you set up monitoring with **`track_case`**, which schedules automatic checks for a given case ID and alerts your agent when the court record changes. You can also trigger an immediate check for updates using **`request_case_update`**; whether that request finished or not, **`get_case_update_status`** tells you if it's ready. When you need to track someone's professional life—an attorney or a law firm—you use specialized tracking tools: **`track_norm_attorney`** schedules recurring data refreshes for an attorney’s record, and **`track_norm_law_firm`** sets up scheduled updates for the entire firm profile.

For profiles on people, you've got structured search tools. You can find normalized attorneys using **`search_norm_attorney`**, or locate judges with **`search_norm_judge`**. To look up law firms, use **`search_norm_law_firm`**; for any involved party—person or entity—you check records with **`search_norm_party`**. Once you find them, your agent can pull deep details and analytics: **`get_norm_attorney`** gives comprehensive data on an attorney's history, **`get_norm_judge`** retrieves rulings and background on a judge, **`get_norm_law_firm`** provides full insights into a law firm, and **`get_norm_party`** pulls structured background info for any party. You also have the ability to find these profiles by searching them first: you can call **`search_norm_attorney`**, **`search_norm_judge`**, or **`search_norm_law_firm`**.

When it comes to documents and exporting data, the server handles it all. You initiate a specific court document order using **`order_case_document`**, and once that document is ready for you to grab, **`get_document_order_callback`** provides the file URL. If you need to export everything, **`request_case_export`** asks the server to compile all case data into a single ZIP file; when that massive export is done processing, **`get_case_export_callback`** returns the final download link. Finally, if you just want basic analytics on how many cases exist by type, **`get_case_count_analytics`** gives you that count.

## Tools

### delete_pacer_credential
Removes current PACER account credentials from the system.

### generate_token
Creates a new UniCourt access token for your account.

### get_case_count_analytics
Retrieves analytics showing the count of cases grouped by their type.

### get_case_export_callback
Gets the file URL once a bulk export of case data is finished processing.

### get_case
Pulls specific, detailed information for one case ID.

### get_case_update_status
Checks if an asynchronous request to update a case status has completed.

### get_document_order_callback
Gets the file URL once a court document order is ready for download.

### get_norm_attorney
Pulls detailed analytics and structured profiles for an attorney.

### get_norm_judge
Retrieves analytics and data about a specific judge's history and rulings.

### get_norm_law_firm
Gets comprehensive analytics and details on a law firm profile.

### get_norm_party
Pulls structured data and background information for any involved party (person or entity).

### get_pacer_credential
Reads the current status of your PACER account credentials.

### import_case
Uploads a case record directly into UniCourt's system using high priority.

### import_pacer_case
Brings a case into the system if it's missing, using PACER credentials.

### order_case_document
Initiates the process to order a specific court document by ID or name.

### request_case_export
Asks the server to compile and export all case data into a single ZIP file.

### request_case_update
Starts an asynchronous request to check for new updates on a specific case ID.

### search_cases
Searches the entire database of court cases using keywords and filters.

### search_norm_attorney
Finds normalized attorney profiles based on name or practice area.

### search_norm_judge
Locates normalized judge profiles by name or jurisdiction.

### search_norm_law_firm
Searches for law firms and returns their structured data.

### search_norm_party
Finds normalized party records using search criteria.

### search_pacer_case_locator
Performs a direct case lookup through the PACER Case Locator tool.

### track_case
Sets up automatic, scheduled updates for monitoring an ongoing legal case.

### track_norm_attorney
Schedules recurring data refreshes for a specific attorney's professional records.

### track_norm_law_firm
Sets up scheduled, recurring source updates for law firm profiles.

### update_pacer_credential
Manage PACER account credentials

## Prompt Examples

**Prompt:** 
```
Search for court cases with the keyword 'Apple Inc' and sort by filing date.
```

**Response:** 
```
I've found several cases for 'Apple Inc'. The most recent ones include 'Apple Inc. vs. Epic Games' (ID: 12345) and 'State of California vs. Apple' (ID: 67890). Would you like the full details for any of these?
```

**Prompt:** 
```
Set up automated tracking for case ID 1205934 with a daily refresh.
```

**Response:** 
```
Case 1205934 is now being tracked. I've set the refresh window to 1 day. You will be notified of any changes in the court record for this case.
```

**Prompt:** 
```
Get the professional analytics for attorney ID ATTY-98765.
```

**Response:** 
```
Retrieving analytics for attorney ATTY-98765... This attorney has handled 150+ cases, primarily in Intellectual Property. Their win rate in federal courts is approximately 65%. Would you like a breakdown of their most recent cases?
```

## Capabilities

### Find specific case details
Retrieves all available information for a single, known court case ID using `get_case`.

### Search across all cases
Scans millions of records to locate cases based on keywords and criteria using `search_cases`.

### Monitor case changes over time
Sets up recurring checks on a case ID via `track_case`, notifying you when the court record updates.

### Build professional profiles
Access structured data and analytics for attorneys, judges, law firms, and parties using specialized search tools (e.g., `search_norm_attorney`).

### Export case records in bulk
Requests a ZIP file containing comprehensive data exports for an entire set of cases (`request_case_export`).

## Use Cases

### Assessing litigation risk for an acquisition.
A compliance officer needs to know if the target company has any active, high-profile legal issues. Instead of manually checking case databases, they use `search_norm_party` to find the corporate entity and then run `get_norm_law_firm` on all associated law firms. The agent pulls a complete risk report detailing current litigation exposure.

### Monitoring a key court date.
A paralegal has a critical case ID (e.g., 1205934) that needs daily tracking for an upcoming hearing. They use `track_case` to set up automated monitoring. The agent receives an alert if any document is filed or status changes, eliminating the need for manual follow-up.

### Building a market intelligence report.
A researcher needs data on patent litigation trends in a specific state. They use `search_cases` with filters (state, keyword) and then call `request_case_export`. The agent delivers a ZIP file containing thousands of records, allowing the researcher to analyze case counts by type using `get_case_count_analytics`.

### Finding an obscure historical record.
A lawyer needs to confirm details on an attorney from five years ago. They run `search_norm_attorney` and then use the resulting ID with `get_norm_attorney`. This pulls structured professional data, confirming past cases and specialties that basic search wouldn't surface.

## Benefits

- Automate monitoring with `track_case`: Instead of manually checking case status daily, set up a recurring check. Your agent gets notified when the court record changes, saving you hours of repetitive work.
- Deep dive into profiles: Use `get_norm_party` and `get_norm_law_firm` to build out complete background histories on involved parties—way beyond what basic search results show. This is critical for due diligence.
- Consolidate data with exports: Don't pull case data piece by piece. Run `request_case_export` to get a single ZIP file containing all the required records, ready for immediate analysis in Excel or Python.
- Seamlessly find who you need: Need an attorney? Use `search_norm_attorney`. The system handles the messy legal schema so your agent returns clean, usable profile data right away.
- Cross-reference everything: You can combine searches—start with a case ID via `get_case`, then use that information to find associated parties with `get_norm_party` for a full picture.

## How It Works

The bottom line is that you don't write complex SQL; you just tell your AI what kind of legal information you need, and we handle the rest.

1. First, you subscribe to the server and pass your unique UniCourt Access Token.
2. Next, your AI client calls a specific tool—for example, `search_cases` with parameters like a keyword or date range.
3. Finally, the server executes the query against the legal database and passes the resulting structured data back to your agent.

## Frequently Asked Questions

**How do I find a case ID before running `get_case`?**
You must first search the records using `search_cases` or `search_pacer_case_locator`. These tools return a list of IDs; use one of those results to feed into `get_case`.

**Can I schedule automatic updates for my case using `track_case`?**
Yes. Calling `track_case` sets up an automated, recurring job that checks the court record on a defined schedule and alerts your agent when changes occur.

**Which tool should I use to pull firm data: `get_norm_law_firm` or just searching for it?**
`search_norm_law_firm` finds the ID, but you need `get_norm_law_firm` afterwards. The latter pulls all the deep analytics and structured details that make the profile useful.

**If I want a bulk export of cases, what tool do I use? Is it instant?**
Use `request_case_export`. This doesn't give you the file right away. You must then call `get_case_export_callback` later to check when the ZIP file is ready.

**What process do I follow after calling `order_case_document` to actually get the file?**
You must call the `get_document_order_callback` tool. This function checks the status of your order and, once complete, returns a direct file URL that you can pass to your agent client.

**If I need to start fresh or switch accounts, how do I manage my tokens using `generate_token`?**
Use the `generate_token` tool. It creates a new access token for your specific AI client session. You should run this before any data retrieval call if you are connecting a different user account.

**If I suspect a case isn't in UniCourt, can I still find it using `search_pacer_case_locator`?**
Yes, the tool searches PACER directly. This bypasses the internal UniCourt index and allows you to locate cases that haven't been added or indexed into the platform yet.

**Does running `search_cases` too many times quickly hit any performance limits?**
Yes, frequent searches trigger rate limiting. The API documentation specifies throttling rules for query volume. You need to build backoff logic into your agent client when executing search commands.

**How can I search for court cases involving a specific company?**
Use the `search_cases` tool with a query like `caseName:"Company Name"`. The agent will return a list of matching cases with their UniCourt IDs and basic details.

**Can the AI automatically track a case for new updates?**
Yes! By using the `track_case` tool with a specific `caseId`, you can set up automated monitoring. You can even specify a `refreshWindow` like '1d' for daily updates.

**Is it possible to get professional background data for an attorney?**
Absolutely. Use `search_norm_attorney` to find the attorney and then `get_norm_attorney` with their ID to retrieve detailed analytics and professional history.