Async Python client for DART — Korea's Financial Supervisory Service corporate disclosure OpenAPI (KOSPI / KOSDAQ / KONEX filings, financials, ownership)
Project description
opendart-py
Async Python client for DART (Korea FSS) OpenAPI — the official Korean corporate disclosure system.
A lightweight async Python client for the DART OpenAPI — Korea's equivalent of SEC EDGAR, run by the Financial Supervisory Service. Fetch filings, financial statements, ownership reports, and major corporate decisions for any KOSPI / KOSDAQ / KONEX listed company in one line.
If you've ever used sec-edgar-downloader or edgar for US equities, this is the same idea — but for the Korean market (~2,400 listed companies, ~$2T market cap).
- Async-first — built on
httpx+asyncio. Drops into FastAPI / aiohttp servers - Typed — Pydantic v2 models for request and response validation
- No globals — no env-var or singleton magic. API key is passed explicitly
- Zero infra — no Redis or DB dependency. Inject your own cache backend if you need one
Install
pip install opendart-py
Quickstart
import asyncio
from opendart import DartClient, DisclosureSearchParams, MarketType
async def main():
async with DartClient(api_key="YOUR_DART_KEY") as dart:
disclosures, total = await dart.search_disclosures(
DisclosureSearchParams(
bgn_de="20260101",
end_de="20260131",
corp_cls=MarketType.KOSPI.value,
)
)
for d in disclosures[:5]:
print(d.rcept_dt, d.corp_name, d.report_nm)
asyncio.run(main())
Get a DART API key (free, 20,000 requests/day): https://opendart.fss.or.kr/uss/umt/login/loginPage.do
Stock code → corp_code
DART uses its own 8-digit corp_code rather than the 6-digit KRX stock code. To convert:
from opendart import CorpCodeResolver
resolver = CorpCodeResolver(api_key="YOUR_DART_KEY")
samsung = await resolver.resolve("005930") # → "00126380"
The full corpCode.xml is downloaded once and cached in memory. For multi-process deployments you can inject any async cache backend (e.g. Redis):
import redis.asyncio as redis
cache = redis.from_url("redis://localhost")
resolver = CorpCodeResolver(api_key="...", cache=cache)
Coverage
| Category | DART group | Methods |
|---|---|---|
| Disclosure search | — | search_disclosures, get_document |
| Company overview | DS001 | get_company_overview |
| Periodic reports | DS002 | get_dividends, get_major_shareholders, get_shareholder_changes, get_executives, get_executive_compensation, get_top_compensation, get_treasury_stock, get_employees, get_minor_shareholders, get_audit_opinion |
| Financial statements | DS003 | get_single_account, get_full_statements, get_financial_indicators |
| Ownership reports | DS004 | get_major_stock_reports, get_executive_stock_reports |
| Major decisions | DS005 | get_cb_issuance, get_bw_issuance, get_paid_increase, get_free_increase, get_capital_reduction, get_merger_decision |
| Securities registration | DS006 | get_equity_registration, get_debt_registration |
Examples
Treasury stock (Korea Value-Up program tracking)
treasury = await dart.get_treasury_stock(
corp_code="00126380", # Samsung Electronics
bsns_year="2025",
reprt_code="11011", # Annual report
)
reprt_code: 11011 annual / 11012 half-year / 11013 Q1 / 11014 Q3.
Convertible bond issuance monitoring
cb = await dart.get_cb_issuance(
corp_code="...",
bgn_de="20260101",
end_de="20260507",
)
Financial indicators
profitability = await dart.get_financial_indicators(
corp_code="00126380",
bsns_year="2025",
reprt_code="11011",
idx_cl_code="M210000", # Profitability
)
idx_cl_code: M210000 profitability / M220000 stability / M230000 growth / M240000 activity.
Production
This library was extracted from the production codebase of Alpha Lenz — an AI-powered Korean equity research platform — and is currently used to ingest daily disclosures across 10,000+ KRX-listed tickers.
Development
git clone https://github.com/treasurer-co/opendart-py
cd opendart-py
pip install -e ".[dev]"
pytest
License
MIT — see LICENSE.
See also
- DART OpenAPI official documentation
pykrx— KRX market data (complementary)dart-fss— synchronous DART client (predecessor project)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file opendart_py-0.1.0.tar.gz.
File metadata
- Download URL: opendart_py-0.1.0.tar.gz
- Upload date:
- Size: 9.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e47bf1d77479cafd3a84213386e6df7af2410b7b3ea5d500d95a853f076ba4b8
|
|
| MD5 |
df9d5f272d3ecc27e1b0d0d579fe4b66
|
|
| BLAKE2b-256 |
482725cc456cba31eafe12d71c69648e897dcd0cf1ff5d0cc34430ecaab394ad
|
File details
Details for the file opendart_py-0.1.0-py3-none-any.whl.
File metadata
- Download URL: opendart_py-0.1.0-py3-none-any.whl
- Upload date:
- Size: 10.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
40f12aa2bfed3500c05177fdf2c17508fdda2f549f562576b305c1db4e4b93e4
|
|
| MD5 |
a773abf222a1d3127e64d59f9b7d3ba5
|
|
| BLAKE2b-256 |
c27cb77b210a7f880c4636988ec0f0ecf0f3d64fbf71534cd1ade5679ea9c9fb
|