# SEC EDGAR API: Financials, Ratios & Red Flags (`reclarative_kernel/sec-edgar-api-financials-ratios-red-flags`) Actor

Look up any US public company by ticker. Get SEC filings, deterministic financial ratios (margins, growth, debt/equity) and rule-based red flags as clean JSON.

- **URL**: https://apify.com/reclarative\_kernel/sec-edgar-api-financials-ratios-red-flags.md
- **Developed by:** [Marcus AureliusII](https://apify.com/reclarative_kernel) (community)
- **Categories:** AI, Developer tools, MCP servers
- **Stats:** 1 total users, 1 monthly users, 0.0% runs succeeded, NaN bookmarks
- **User rating**: No ratings yet

## Pricing

from $40.00 / 1,000 company scrapeds

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

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
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.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use 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

SEC EDGAR Financial Data & Filings API — Company Financials by Ticker
Get SEC company financials, 10-K / 10-Q / 8-K filings, and financial ratios as clean JSON — from a single ticker or company name. Built for AI agents and MCP, due-diligence workflows, and investment research.
Type `AAPL` (or `Apple`) and get back company metadata, recent SEC filings with direct document links, the latest key financials, deterministically computed ratios (profit margin, revenue growth, debt-to-equity), and rule-based financial red flags — in one fast call.
What this actor does
Get SEC financial data by ticker or company name — resolves to the official SEC CIK, no manual EDGAR lookups.
Extract 10-K, 10-Q and 8-K filings as JSON — form type, filing date, and a direct link to each document.
Pull key financials from XBRL — revenue, net income, operating income, assets, liabilities, equity, cash, EPS.
Compute financial ratios automatically — profit margin, year-over-year revenue growth, debt-to-equity, each with the fiscal years it used.
Detect financial red flags — net loss, revenue decline, negative equity, high leverage, operating loss.
Why use this instead of a raw data feed
Most financial APIs hand an AI agent raw numbers and let the model compute ratios itself — which is exactly where one-shot LLM calls hallucinate. This actor does the opposite:
Every figure is computed deterministically from official XBRL filings. No LLM estimates any number.
Red flags are rule-based with explicit, configurable thresholds — explainable and reproducible, not a guess.
Decision-shaped output — a verdict-ready snapshot, not a 50 KB dump to summarize.
Official, stable source (data.sec.gov) — no anti-bot fragility, minimal maintenance.
Use cases
AI agent financial research — an MCP tool an agent calls to fetch a company snapshot mid-task.
Investment due diligence — screen a US public company's financial health in one call.
Company financial health check by ticker — margins, growth, leverage, and warning signs at a glance.
Automated SEC filing monitoring — pull the latest 10-K / 10-Q / 8-K for a watchlist.
Feeding financial data into LLM apps — structured, trustworthy figures instead of scraped HTML.
Input
Field	Type	Description
`query`	string (required)	Stock ticker (`AAPL`) or company name (`Apple`).
`contactEmail`	string	Your email — the SEC requires a contact in the request User-Agent.
`filingTypes`	array	Form types to include. Default: `10-K`, `10-Q`, `8-K`.
`maxFilings`	integer	Max recent filings. Default: `10`.
`maxDebtToEquity`	integer	Threshold for the HIGH_LEVERAGE flag. Default: `2`.
Output (shape)
```json
{
  "found": true,
  "company": { "name": "Apple Inc.", "cik": "0000320193", "ticker": "AAPL", "exchange": "Nasdaq", "sicDescription": "Electronic Computers" },
  "recentFilings": [ { "form": "10-K", "filingDate": "2025-11-01", "documentUrl": "https://www.sec.gov/Archives/edgar/data/320193/.../aapl.htm" } ],
  "keyFinancials": {
    "revenue":   { "value": 391035000000, "unit": "USD", "fiscalYear": 2024, "concept": "RevenueFromContractWithCustomerExcludingAssessedTax" },
    "netIncome": { "value": 93736000000,  "unit": "USD", "fiscalYear": 2024 }
  },
  "snapshot": {
    "profitMargin":     { "value": 0.2397, "formatted": "24.0%", "basis": "FY2024 net income / FY2024 revenue" },
    "revenueGrowthYoY": { "value": -0.028, "formatted": "-2.8%", "from": "FY2024", "to": "FY2025" },
    "debtToEquity":     { "value": 6.08, "basis": "FY2025 total liabilities / stockholders equity" }
  },
  "redFlags": [ { "code": "HIGH_LEVERAGE", "severity": "medium", "message": "Debt-to-equity 6.08 exceeds threshold 2.0." } ],
  "source": "SEC EDGAR (data.sec.gov)",
  "disclaimer": "Figures computed deterministically from XBRL filings. Informational only, not investment advice."
}
````

How the numbers are computed (auditable)
profitMargin = latest annual net income / latest annual revenue.
revenueGrowthYoY = latest annual revenue / prior annual revenue − 1.
debtToEquity = latest annual total liabilities / stockholders' equity.
Concepts are never mixed within a metric, so a revenue definition stays consistent across years. Each result reports the fiscal years it used.
Red-flag rules (deterministic)
`NET_LOSS`, `REVENUE_DECLINE`, `NEGATIVE_EQUITY`, `HIGH_LEVERAGE`, `OPERATING_LOSS`. An empty `redFlags` array means none of the checked rules triggered — not a clean bill of health.
Use as an MCP tool for AI agents
Once published, this actor is reachable through the hosted Apify MCP server at mcp.apify.com (Streamable HTTP). An agent can discover it, read its input and output schema, and call it with a ticker — getting a verdict-ready financial snapshot back in one turn. Clean schema + one clear job = a tool an LLM can pick and call reliably.
FAQ
How do I get SEC financial data for a company by ticker?
Pass the ticker (e.g. `AAPL`) as `query`. The actor resolves it to the SEC CIK and returns filings, financials, ratios, and red flags as JSON.
Is the data official?
Yes — it comes directly from the SEC EDGAR public APIs (`data.sec.gov` and `www.sec.gov`), the authoritative source for US public-company filings.
Are the financial ratios reliable?
They're computed with exact arithmetic from XBRL data, never estimated by a language model. Each ratio reports the fiscal years it used so you can audit it.
Which companies are covered?
US SEC filers (companies filing 10-K / 20-F annual reports). For UK companies, see the related actor below.
Related actors
Part of a financial-intelligence actor suite:
UK Companies House Financial Intelligence — KYB (officers, PSC, status, charges) + financials from filed accounts + red flags for UK companies. (Add your published Store URL here once live.)
Run locally

```bash
npm i -g apify-cli
apify run -i '{"query": "AAPL", "contactEmail": "you@example.com"}'
```

Limits
US SEC filers only (10-K / 20-F annual data). EU/private companies are covered by separate actors.
EDGAR rate limit ~10 req/s; this actor makes ~3 calls per lookup.

# Actor input Schema

## `query` (type: `string`):

Stock ticker (e.g. AAPL) or company name (e.g. Apple). Ticker matches are exact; names match the first company containing the text.

## `contactEmail` (type: `string`):

Your email. The SEC requires a contact address in the request User-Agent header for fair-access compliance.

## `filingTypes` (type: `array`):

Which SEC form types to include in recent filings.

## `maxFilings` (type: `integer`):

Maximum number of recent filings to return.

## `maxDebtToEquity` (type: `integer`):

Raise a HIGH\_LEVERAGE red flag when debt-to-equity exceeds this value (equity must be positive). Default 2.

## Actor input object example

```json
{
  "query": "AAPL",
  "filingTypes": [
    "10-K",
    "10-Q",
    "8-K"
  ],
  "maxFilings": 10,
  "maxDebtToEquity": 2
}
```

# Actor output Schema

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

No description

# 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 = {
    "query": "AAPL",
    "filingTypes": [
        "10-K",
        "10-Q",
        "8-K"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("reclarative_kernel/sec-edgar-api-financials-ratios-red-flags").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 = {
    "query": "AAPL",
    "filingTypes": [
        "10-K",
        "10-Q",
        "8-K",
    ],
}

# Run the Actor and wait for it to finish
run = client.actor("reclarative_kernel/sec-edgar-api-financials-ratios-red-flags").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 '{
  "query": "AAPL",
  "filingTypes": [
    "10-K",
    "10-Q",
    "8-K"
  ]
}' |
apify call reclarative_kernel/sec-edgar-api-financials-ratios-red-flags --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=reclarative_kernel/sec-edgar-api-financials-ratios-red-flags",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "SEC EDGAR API: Financials, Ratios & Red Flags",
        "description": "Look up any US public company by ticker. Get SEC filings, deterministic financial ratios (margins, growth, debt/equity) and rule-based red flags as clean JSON.",
        "version": "0.0",
        "x-build-id": "PquUcqixsU4XV9jy1"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/reclarative_kernel~sec-edgar-api-financials-ratios-red-flags/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-reclarative_kernel-sec-edgar-api-financials-ratios-red-flags",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/reclarative_kernel~sec-edgar-api-financials-ratios-red-flags/runs": {
            "post": {
                "operationId": "runs-sync-reclarative_kernel-sec-edgar-api-financials-ratios-red-flags",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/reclarative_kernel~sec-edgar-api-financials-ratios-red-flags/run-sync": {
            "post": {
                "operationId": "run-sync-reclarative_kernel-sec-edgar-api-financials-ratios-red-flags",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "query"
                ],
                "properties": {
                    "query": {
                        "title": "Company ticker or name",
                        "type": "string",
                        "description": "Stock ticker (e.g. AAPL) or company name (e.g. Apple). Ticker matches are exact; names match the first company containing the text."
                    },
                    "contactEmail": {
                        "title": "Contact email",
                        "type": "string",
                        "description": "Your email. The SEC requires a contact address in the request User-Agent header for fair-access compliance."
                    },
                    "filingTypes": {
                        "title": "Filing form types",
                        "type": "array",
                        "description": "Which SEC form types to include in recent filings.",
                        "default": [
                            "10-K",
                            "10-Q",
                            "8-K"
                        ],
                        "items": {
                            "type": "string"
                        }
                    },
                    "maxFilings": {
                        "title": "Max recent filings",
                        "minimum": 1,
                        "maximum": 100,
                        "type": "integer",
                        "description": "Maximum number of recent filings to return.",
                        "default": 10
                    },
                    "maxDebtToEquity": {
                        "title": "Debt-to-equity red-flag threshold",
                        "minimum": 1,
                        "maximum": 20,
                        "type": "integer",
                        "description": "Raise a HIGH_LEVERAGE red flag when debt-to-equity exceeds this value (equity must be positive). Default 2.",
                        "default": 2
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
