Skip to main content
GET
https://api.fintool.com
/
v1
/
documents
/
{publication_id}
/
extract
Extract
curl --request GET \
  --url https://api.fintool.com/v1/documents/{publication_id}/extract
{
  "publication_id": "<string>",
  "ticker": "<string>",
  "doc_type": "<string>",
  "filing_date": "<string>",
  "period": "<string>",
  "metrics": {
    "value": 123,
    "unit": "<string>",
    "period": "<string>",
    "yoy_change": 123
  },
  "tables": [
    {
      "id": "<string>",
      "title": "<string>",
      "section": "<string>",
      "headers": [
        {}
      ],
      "rows": [
        {}
      ],
      "unit": "<string>",
      "format": "<string>"
    }
  ],
  "exhibits": [
    {
      "number": "<string>",
      "description": "<string>",
      "url": "<string>"
    }
  ],
  "signatures": {
    "signed_date": "<string>",
    "signers": [
      {}
    ]
  }
}

Overview

Extract structured data from SEC filings including financial metrics, tables, exhibits, and signatures. Build financial datasets without parsing HTML.

GET /v1/documents//extract

Extract structured data from a document.

Path Parameters

publication_id
string
required
SEC accession number (e.g., 0000320193-24-000123)

Query Parameters

fields
string
default:"all"
Comma-separated list of fields to extract:
  • tables - Financial tables and data tables
  • metrics - Key financial metrics
  • exhibits - Attached exhibits
  • signatures - Document signatories
  • all - All available fields (default)

Request Example

curl -X GET "https://api.fintool.com/v1/documents/0000320193-24-000123/extract?fields=tables,metrics" \
  -H "Authorization: Bearer YOUR_API_KEY"

Response

publication_id
string
SEC accession number
ticker
string
Stock ticker symbol
doc_type
string
Document type
filing_date
string
Filing date (ISO 8601)
period
string
Reporting period
metrics
object
Extracted financial metrics
tables
array
Extracted tables
exhibits
array
Document exhibits
signatures
object
Document signatories

Response Example

{
  "publication_id": "0000320193-24-000123",
  "ticker": "AAPL",
  "doc_type": "10-K",
  "filing_date": "2024-11-01",
  "period": "FY 2024",

  "metrics": {
    "revenue": {
      "value": 383285000000,
      "unit": "USD",
      "period": "FY 2024",
      "yoy_change": -0.028
    },
    "net_income": {
      "value": 96995000000,
      "unit": "USD",
      "period": "FY 2024",
      "yoy_change": -0.033
    },
    "eps_diluted": {
      "value": 6.42,
      "unit": "USD",
      "period": "FY 2024"
    },
    "total_assets": {
      "value": 352583000000,
      "unit": "USD"
    },
    "total_debt": {
      "value": 104590000000,
      "unit": "USD"
    },
    "cash_and_equivalents": {
      "value": 29965000000,
      "unit": "USD"
    },
    "shares_outstanding": {
      "value": 15115823000,
      "unit": "shares"
    }
  },

  "tables": [
    {
      "id": "tbl_001",
      "title": "Consolidated Statements of Operations",
      "section": "Item 8. Financial Statements",
      "headers": ["", "2024", "2023", "2022"],
      "rows": [
        ["Net sales", "383,285", "394,328", "391,035"],
        ["Cost of sales", "210,352", "214,137", "212,981"],
        ["Gross margin", "172,933", "180,191", "178,054"],
        ["Operating income", "118,658", "123,216", "119,437"],
        ["Net income", "96,995", "100,913", "99,803"]
      ],
      "unit": "millions USD",
      "format": "json"
    },
    {
      "id": "tbl_002",
      "title": "Revenue by Segment",
      "section": "Item 7. MD&A",
      "headers": ["Segment", "2024", "2023", "Change %"],
      "rows": [
        ["iPhone", "200,583", "205,489", "-2.4%"],
        ["Mac", "29,984", "29,357", "2.1%"],
        ["iPad", "26,694", "28,300", "-5.7%"],
        ["Wearables, Home and Accessories", "37,005", "39,845", "-7.1%"],
        ["Services", "89,019", "91,337", "-2.5%"]
      ],
      "unit": "millions USD"
    },
    {
      "id": "tbl_003",
      "title": "Debt Maturities",
      "section": "Notes to Financial Statements",
      "headers": ["Year", "Amount"],
      "rows": [
        ["2025", "10,912"],
        ["2026", "12,485"],
        ["2027", "9,750"],
        ["2028", "7,000"],
        ["2029", "6,500"],
        ["Thereafter", "57,943"]
      ],
      "unit": "millions USD"
    }
  ],

  "exhibits": [
    {
      "number": "21.1",
      "description": "Subsidiaries of the Registrant",
      "url": "/v1/documents/0000320193-24-000123?exhibit=21.1"
    },
    {
      "number": "23.1",
      "description": "Consent of Independent Registered Public Accounting Firm",
      "url": "/v1/documents/0000320193-24-000123?exhibit=23.1"
    },
    {
      "number": "31.1",
      "description": "CEO Certification pursuant to Section 302",
      "url": "/v1/documents/0000320193-24-000123?exhibit=31.1"
    }
  ],

  "signatures": {
    "signed_date": "2024-10-31",
    "signers": [
      {"name": "Tim Cook", "title": "Chief Executive Officer"},
      {"name": "Luca Maestri", "title": "Senior Vice President, Chief Financial Officer"}
    ]
  }
}

GET /v1/extract/metrics

Bulk metrics extraction across multiple filings.

Query Parameters

tickers
string
required
Comma-separated ticker symbols
metrics
string
required
Comma-separated metrics: revenue, net_income, eps, total_assets, total_debt, etc.
doc_types
string
default:"10-K,10-Q"
Comma-separated document types
start_date
string
Filter from date (ISO 8601)
end_date
string
Filter to date (ISO 8601)
frequency
string
default:"all"
Frequency filter: annual, quarterly, or all

Request Example

curl -X GET "https://api.fintool.com/v1/extract/metrics?tickers=AAPL&metrics=revenue,net_income,eps_diluted&frequency=annual&start_date=2020-01-01" \
  -H "Authorization: Bearer YOUR_API_KEY"

Response Example

{
  "ticker": "AAPL",
  "company_name": "Apple Inc.",
  "metrics": {
    "revenue": {
      "unit": "USD",
      "data": [
        {"period": "FY 2024", "value": 383285000000, "filing_date": "2024-11-01"},
        {"period": "FY 2023", "value": 394328000000, "filing_date": "2023-11-03"},
        {"period": "FY 2022", "value": 391035000000, "filing_date": "2022-10-28"},
        {"period": "FY 2021", "value": 365817000000, "filing_date": "2021-10-29"},
        {"period": "FY 2020", "value": 274515000000, "filing_date": "2020-10-30"}
      ]
    },
    "net_income": {
      "unit": "USD",
      "data": [
        {"period": "FY 2024", "value": 96995000000, "filing_date": "2024-11-01"},
        {"period": "FY 2023", "value": 100913000000, "filing_date": "2023-11-03"},
        {"period": "FY 2022", "value": 99803000000, "filing_date": "2022-10-28"},
        {"period": "FY 2021", "value": 94680000000, "filing_date": "2021-10-29"},
        {"period": "FY 2020", "value": 57411000000, "filing_date": "2020-10-30"}
      ]
    },
    "eps_diluted": {
      "unit": "USD",
      "data": [
        {"period": "FY 2024", "value": 6.42, "filing_date": "2024-11-01"},
        {"period": "FY 2023", "value": 6.16, "filing_date": "2023-11-03"},
        {"period": "FY 2022", "value": 6.11, "filing_date": "2022-10-28"},
        {"period": "FY 2021", "value": 5.67, "filing_date": "2021-10-29"},
        {"period": "FY 2020", "value": 3.31, "filing_date": "2020-10-30"}
      ]
    }
  }
}

GET /v1/extract/tables

Bulk table extraction across multiple filings.

Query Parameters

tickers
string
required
Comma-separated ticker symbols
table_type
string
Table type filter:
  • income_statement - Consolidated income statements
  • balance_sheet - Balance sheets
  • cash_flow - Cash flow statements
  • segment_revenue - Revenue by segment/geography
  • all - All tables (default)
doc_types
string
default:"10-K"
Comma-separated document types
format
string
default:"json"
Output format: json or csv

Request Example

cURL
curl -X GET "https://api.fintool.com/v1/extract/tables?tickers=AAPL,MSFT&table_type=income_statement&format=json" \
  -H "Authorization: Bearer YOUR_API_KEY"

Available Metrics

MetricDescription
revenueTotal revenue / net sales
net_incomeNet income
gross_profitGross profit / gross margin
operating_incomeOperating income
eps_basicBasic earnings per share
eps_dilutedDiluted earnings per share
total_assetsTotal assets
total_liabilitiesTotal liabilities
total_equityTotal stockholders’ equity
total_debtTotal debt
cash_and_equivalentsCash and cash equivalents
shares_outstandingShares outstanding
book_value_per_shareBook value per share

Use Cases

Financial Modeling

Extract historical financials to build DCF models

Competitive Analysis

Compare metrics across competitors

Dataset Building

Create structured datasets for ML training

Automated Reports

Generate financial reports programmatically

Example: Build Revenue Comparison

import requests
import pandas as pd
import matplotlib.pyplot as plt

def get_revenue_comparison(tickers, start_year=2020):
    """Compare revenue across multiple companies"""
    url = "https://api.fintool.com/v1/extract/metrics"
    headers = {"Authorization": "Bearer YOUR_API_KEY"}

    all_data = []

    for ticker in tickers:
        params = {
            "tickers": ticker,
            "metrics": "revenue",
            "frequency": "annual",
            "start_date": f"{start_year}-01-01"
        }

        response = requests.get(url, headers=headers, params=params)
        data = response.json()

        for point in data["metrics"]["revenue"]["data"]:
            all_data.append({
                "ticker": ticker,
                "period": point["period"],
                "revenue": point["value"] / 1e9  # Convert to billions
            })

    return pd.DataFrame(all_data)

# Compare tech giants
tickers = ["AAPL", "MSFT", "GOOGL"]
df = get_revenue_comparison(tickers)

# Pivot and plot
pivot = df.pivot(index="period", columns="ticker", values="revenue")
pivot.plot(kind="bar", figsize=(12, 6))
plt.title("Annual Revenue Comparison (Billions USD)")
plt.ylabel("Revenue ($B)")
plt.legend(title="Company")
plt.tight_layout()
plt.savefig("revenue_comparison.png")

Next Steps