> ## Documentation Index
> Fetch the complete documentation index at: https://docs.secapi.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Search SEC Enforcement Actions

> Search SEC litigation releases, administrative proceedings, and AAERs by category, respondent, date, and disclosed penalty amount.

This tutorial builds a small source-aware search over SEC enforcement releases. The useful result is not a label by itself: it is a short list of releases, each with a stable URL a researcher can read.

## Prerequisites

* An API key in `SECAPI_API_KEY`
* Node.js 18+ for the JavaScript example, or curl

## 1. Start with a bounded query

```bash theme={null}
curl -H "x-api-key: $SECAPI_API_KEY" \
  "https://api.secapi.ai/v1/events/enforcement?source_type=litigation_release&date_from=2025-01-01&limit=10"
```

The endpoint returns a list envelope: `data`, `hasMore`, `nextCursor`, and `requestId`. Each row includes a source type, publication date, title, excerpt, document URL, and any respondent or classification fields that were available from the release.

## 2. Add a retrieval filter

The API accepts these normalized `violation_type` values:

`fraud`, `insider_trading`, `reporting_violation`, `market_manipulation`, `registration_violation`, `investment_adviser`, `broker_dealer`, `municipal_securities`, and `other`.

```bash theme={null}
curl -H "x-api-key: $SECAPI_API_KEY" \
  "https://api.secapi.ai/v1/events/enforcement?violation_type=insider_trading&respondent=example&limit=10"
```

You can also pass `ticker` or `cik`, `penalty_min`, `penalty_max`, `date_from`, and `date_to`. These filters help discover releases; they are not evidence that an issuer or person is a respondent.

## 3. Keep the source with the result

```ts theme={null}
import { SecApiClient } from "@secapi/sdk-js";

const client = new SecApiClient({ apiKey: process.env.SECAPI_API_KEY! });
const result = await client.enforcementActions({
  violation_type: "insider_trading",
  date_from: "2025-01-01",
  limit: 10,
});

for (const action of result.data) {
  console.log({
    publishedAt: action.publishedAt,
    sourceType: action.sourceType,
    title: action.title,
    release: action.documentUrl,
  });
}
```

When you save a match, retain `documentUrl` and `requestId`. Read the release before assigning a risk label, calculating a penalty total, or joining the record to an issuer.

## 4. Page safely

```ts theme={null}
let cursor: string | undefined;

do {
  const page = await client.enforcementActions({
    source_type: "aaer",
    limit: 50,
    cursor,
  });

  for (const action of page.data) {
    // Store the source URL alongside your own review status.
    console.log(action.documentUrl);
  }

  cursor = page.hasMore ? page.nextCursor ?? undefined : undefined;
} while (cursor);
```

## What still requires judgment

* `violationType` is a retrieval label inferred from release language, not the SEC's final legal classification.
* `penaltyAmount` can be null or can capture only the amount the release made machine-readable.
* A name, ticker, or CIK association should be checked against the linked release before it is used in a compliance, legal, or investment workflow.

## Next steps

* [Events API reference](/api-reference/events/get-v1-events-enforcement)
* [Enforcement product guide](/products/enforcement)
* [Search filings](/api-reference/filings)
