Skip to content

GET /api/v1/disclosures/recent

의도

최근 공시 목록 조회. 대시보드 피드에 사용.

인증

없음 (공개)

입력

  • Query: limit (optional, default 10, max 50)

응답

200 OK

json
[
  {
    "rcept_no": "20260413800802",
    "corp_name": "삼성전자",
    "corp_code": "00126380",
    "report_name": "분기보고서",
    "rcept_dt": "20260413",
    "submitter": "삼성전자",
    "summary": "분기 매출 X 원, YoY +Y%"
  }
]
  • summary: AI 분석 한줄요약. analysis_cache 와 LEFT JOIN — 분석 미완성/없으면 omit.

curl 예제

bash
curl -s "https://api.dartbrief.com/api/v1/disclosures/recent?limit=20" | jq
curl -s "http://localhost:8000/api/v1/disclosures/recent" | jq

비즈니스 메모

  • HTTP Cache TTL 30초

GET /api/v1/disclosures/

의도

공시 메타 단건 조회 (corp_name, report_name 등 disclosures 테이블 필드). 원문 텍스트 미포함.

인증

없음 (공개)

curl 예제

bash
curl -s "https://api.dartbrief.com/api/v1/disclosures/20260413800802" | jq

비즈니스 메모

  • HTTP Cache TTL 5분

GET /api/v1/disclosures

의도

공시 컬렉션 조회 — 필터 파라미터로 모드 결정. 응답 스키마는 모드 무관 동일 (Disclosure[]); 필터는 어떤 row 가 포함되냐만 좁힘.

인증

없음 (공개)

입력

다음 중 하나 필수 (없으면 400):

  • Query: corpCode — 기업 코드 (예: 00126380) — 해당 종목 전체 공시
  • Query: beginDate + endDateYYYYMMDD 날짜 범위
  • Query: hasSummary=truesummary(AI 한줄요약) 있는 공시만 (analysis_cache.status='COMPLETED' AND summary <> '' INNER JOIN). 웹 피드가 사용. corpCode 와 조합 가능 (해당 종목 중 요약 있는 것만)

limit:

  • 기업별(corpCode) 조회: default 50, max 200 — 다공시 종목 페이로드 폭주 방지
  • hasSummary=true 모드: default 20, max 20 — 웹은 페이징 없음, 상한 고정 (그 이상은 앱 유도)

정렬은 모든 모드 ORDER BY rcept_dt DESC, created_at DESC, rcept_no DESCrcept_dt 가 일(YYYYMMDD) 단위라 동률을 created_at·rcept_no 로 결정적 고정 (페이징 없는 고정 노출에서 비결정 정렬 → 캐시 일관성 깨짐 방지).

hasSummary=true 응답은 summary 가 항상 채워짐 (omit 안 됨). 다른 모드는 summary omitempty.

curl 예제

bash
# 기업별 (기본 50건)
curl -s "https://api.dartbrief.com/api/v1/disclosures?corpCode=00126380" | jq

# 날짜 범위
curl -s "https://api.dartbrief.com/api/v1/disclosures?beginDate=20260401&endDate=20260430" | jq

# 웹 피드 — 요약 있는 최신 20건
curl -s "https://api.dartbrief.com/api/v1/disclosures?hasSummary=true&limit=20" | jq

# 웹 피드 + 종목 필터
curl -s "https://api.dartbrief.com/api/v1/disclosures?hasSummary=true&corpCode=00126380&limit=20" | jq

비즈니스 메모

  • HTTP Cache TTL 1분 (모든 모드 공통 — ^/api/v1/disclosures$ path 기준)

GET /api/v1/companies/

의도

기업 기본 정보 조회.

인증

없음 (공개)

curl 예제

bash
curl -s "https://api.dartbrief.com/api/v1/companies/00126380" | jq

비즈니스 메모

  • HTTP Cache TTL 10분