Skip to main content
Glama
ChunSam

kiwoom-mcp-server

by ChunSam

외국인·기관 순매매 상위 / 연속매매 현황

get_investor_rank

Find which stocks foreigners and institutions are net buying today or over consecutive days. Answers 'What did foreigners buy today?' and 'Which stocks are foreigners buying for days?'

Instructions

외국인과 기관이 많이 사고판 종목을 조회합니다 (키움 ka90009/ka10131). view: daily(일자별 순매수·순매도 상위, 기본) / streak(N일 연속 순매수 상위). "오늘 외국인이 뭘 샀나", "외국인이 며칠째 사는 종목" 질문에 사용하세요. daily는 market all/kospi/kosdaq, streak는 kospi/kosdaq만 지원합니다. 여기서 말하는 순매수·연속은 매매 기준입니다 — 외국인 보유주식수·한도소진률 기준의 연속 순매매는 get_foreign_holding(rank=streak)이고 데이터 소스가 달라 같은 종목에서 부호가 반대일 수 있습니다. 연기금·투신처럼 12주체를 고르려면 get_net_buy_rank를 쓰세요.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dateNoview=daily의 조회 일자 (기본값: 최근 거래일)
daysNoview=streak의 집계 기간(일) (기본값 5)
unitNo금액/수량 기준 (기본값: amount)
viewNodaily=일자별 상위 (기본), streak=연속 순매수
limitNo표시할 종목 수 (기본값 10, 최대 30)
marketNo시장 구분 (기본값: daily=all, streak=kospi)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.23.0

TDQS

A4.6/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the transparency burden. It explains that the data is based on trading (매매 기준) and notes potential sign differences from get_foreign_holding, but it does not describe the output format or any side effects. Still, it effectively communicates the data semantics and default behaviors.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is dense yet well-structured, using semicolons to separate ideas. Each sentence adds essential information without redundancy, making it efficient and easy to parse.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the lack of an output schema, the description does not explicitly state what the return data looks like, but it covers key contextual aspects like view-specific market support and differentiation from sibling tools. It is sufficiently complete for practical usage, though a mention of the output structure would improve it.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so baseline is 3. The description adds value by specifying which market values are valid for daily vs. streak views and clarifying that days applies only to streak. This goes beyond the schema's basic parameter descriptions.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's function: querying stocks heavily bought/sold by foreigners and institutions, with explicit daily and streak views. It also distinguishes itself from related tools like get_foreign_holding and get_net_buy_rank, making its purpose unambiguous.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides explicit guidance on when to use this tool versus alternatives, such as using get_net_buy_rank for 12-entity selection and get_foreign_holding for holding-based criteria. It also clarifies the valid market options for each view, enabling correct selection.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.