fix: 해외 매수가능금액 ord_psbl_frcr_amt → ovrs_ord_psbl_amt 교체 (#269) #270

Merged
jihoson merged 1 commits from feature/issue-269-overseas-cash-ovrs-ord-psbl-amt into main 2026-02-26 02:01:57 +09:00
Collaborator

변경 요약

해외주식 매수가능금액 조회 필드를 ord_psbl_frcr_amt → ovrs_ord_psbl_amt로 교체.

원인

ord_psbl_frcr_amt는 외화 예수금만 반영($139)하고, 미결제 매도 대금($7,292)을 포함하지 않아 충분한 잔고가 있음에도 매수 불가 판정이 반복됨. (#264 수정이 절반만 해결한 상태)

실제 API 응답 확인

  • ord_psbl_frcr_amt = $139.25 (외화 예수금만, 기존 사용 필드)
  • sll_ruse_psbl_amt = $7,292.70 (미결제 매도 대금, 별도)
  • ovrs_ord_psbl_amt = $7,391.30 (외화+미결제 합산, 수정 후 사용)
  • frcr_ord_psbl_amt1 = $11,772.44 (원화 포함, 미사용)

수정 내용

  • src/main.py 2곳: ord_psbl_frcr_amt → ovrs_ord_psbl_amt
  • tests/test_main.py 13곳: mock 응답 필드명 동일하게 교체

테스트

889 passed

출처: KIS 공식문서(20260221) 해외주식 매수가능금액조회 시트

## 변경 요약 해외주식 매수가능금액 조회 필드를 ord_psbl_frcr_amt → ovrs_ord_psbl_amt로 교체. ## 원인 ord_psbl_frcr_amt는 외화 예수금만 반영($139)하고, 미결제 매도 대금($7,292)을 포함하지 않아 충분한 잔고가 있음에도 매수 불가 판정이 반복됨. (#264 수정이 절반만 해결한 상태) ## 실제 API 응답 확인 - ord_psbl_frcr_amt = $139.25 (외화 예수금만, 기존 사용 필드) - sll_ruse_psbl_amt = $7,292.70 (미결제 매도 대금, 별도) - ovrs_ord_psbl_amt = $7,391.30 (외화+미결제 합산, 수정 후 사용) - frcr_ord_psbl_amt1 = $11,772.44 (원화 포함, 미사용) ## 수정 내용 - src/main.py 2곳: ord_psbl_frcr_amt → ovrs_ord_psbl_amt - tests/test_main.py 13곳: mock 응답 필드명 동일하게 교체 ## 테스트 889 passed 출처: KIS 공식문서(20260221) 해외주식 매수가능금액조회 시트
agentson added 1 commit 2026-02-26 02:01:35 +09:00
fix: 해외 매수가능금액 ord_psbl_frcr_amt → ovrs_ord_psbl_amt 교체 (#269)
Some checks failed
CI / test (pull_request) Has been cancelled
6ff887c047
외화 예수금만 반영하는 ord_psbl_frcr_amt 대신
미결제 매도 대금(sll_ruse_psbl_amt)을 포함하는
ovrs_ord_psbl_amt (앱 '외화' 기준 통합 주문가능금액)를 사용하도록 수정.

실제 API 응답 확인:
  ord_psbl_frcr_amt  = $139.25  (외화 예수금만)
  sll_ruse_psbl_amt  = $7292.70 (미결제 매도 대금)
  ovrs_ord_psbl_amt  = $7391.30 (합산, 원화 미포함)

원화 환산(frcr_ord_psbl_amt1)은 요구사항에 따라 사용하지 않음.
출처: KIS 공식문서(20260221) '해외주식 매수가능금액조회' 시트.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
jihoson merged commit 7b3ba27ef7 into main 2026-02-26 02:01:57 +09:00
Sign in to join this conversation.
No Reviewers
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: jihoson/The-Ouroboros#270