A股数据 API (A-Share Data API)

A-share market data over MCP: quotes, K-line, financials, money flow, boards, sectors, macro.

Rate this Server

One-Click Install

Add this to your `claude_desktop_config.json` file:

{
  "mcpServers": {
    "ashare-data-api": {
      "url": "https://api.ashareapi.com/mcp"
    }
  }
}

Remote endpoints

https://api.ashareapi.com/mcpstreamable-http

Tool inventory

Tools (22)

🟢 Read-only🟡 Write🔴 Delete⚪ Unknown
ashare_quote(code)

A股/港股实时行情快照(现价/开高低/成交额/换手)。用户问'某股票现在多少钱/什么价'用这个。· 免费工具(无需 Key)

Input Schema

{
  "type": "object",
  "properties": {
    "code": {
      "title": "Code",
      "type": "string"
    }
  },
  "required": [
    "code"
  ],
  "title": "ashare_quoteArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_quoteOutput"
}
ashare_kline(code, period, count)

K线(日/周/月)。用户问'走势/最近表现/历史K线'用这个。· 免费工具(无需 Key)

Input Schema

{
  "type": "object",
  "properties": {
    "code": {
      "title": "Code",
      "type": "string"
    },
    "period": {
      "default": "day",
      "title": "Period",
      "type": "string"
    },
    "count": {
      "default": 30,
      "title": "Count",
      "type": "integer"
    }
  },
  "required": [
    "code"
  ],
  "title": "ashare_klineArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_klineOutput"
}
ashare_finance(code, num)

财务报表(利润表/资产负债表/现金流量表)。用户问'营收/净利润/负债/财务'用这个。

Input Schema

{
  "type": "object",
  "properties": {
    "code": {
      "title": "Code",
      "type": "string"
    },
    "num": {
      "default": 4,
      "title": "Num",
      "type": "integer"
    }
  },
  "required": [
    "code"
  ],
  "title": "ashare_financeArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_financeOutput"
}
ashare_fund(code)

个股级交易面:这只股的 主力资金(当日/5/10/20 日净流入+全市场排名)+ 龙虎榜上榜明细(上榜原因/营业部)+ 大宗交易 + 融资融券。用户问'某只股票的主力资金/机构动向'用这个。⚠️ 全市场榜单(今天机构榜/游资榜/活跃席位)请用 ashare_lhb——本工具只针对单只股票。

Input Schema

{
  "type": "object",
  "properties": {
    "code": {
      "title": "Code",
      "type": "string"
    }
  },
  "required": [
    "code"
  ],
  "title": "ashare_fundArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_fundOutput"
}
ashare_technical(code)

技术指标 MA/MACD/KDJ/RSI/BOLL。用户问'技术面/指标/金叉死叉'用这个。

Input Schema

{
  "type": "object",
  "properties": {
    "code": {
      "title": "Code",
      "type": "string"
    }
  },
  "required": [
    "code"
  ],
  "title": "ashare_technicalArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_technicalOutput"
}
ashare_shareholder(code)

股东研究:十大股东/股东户数/机构持仓。用户问'谁在持有/股东变化/筹码'用这个。

Input Schema

{
  "type": "object",
  "properties": {
    "code": {
      "title": "Code",
      "type": "string"
    }
  },
  "required": [
    "code"
  ],
  "title": "ashare_shareholderArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_shareholderOutput"
}
ashare_events(code)

个股事件标签(42 类:大宗/龙虎榜/回购/分红/解禁等)。

Input Schema

{
  "type": "object",
  "properties": {
    "code": {
      "title": "Code",
      "type": "string"
    }
  },
  "required": [
    "code"
  ],
  "title": "ashare_eventsArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_eventsOutput"
}
ashare_lhb(type)

全市场龙虎榜分榜:type=institution 机构榜(机构买入/净买/机构数)/ hotmoney 游资榜 / activeseat 活跃席位。用户问'今天机构买了什么/游资动向/活跃席位'用这个。⚠️ 某只股票的上榜明细(上榜原因/营业部)请用 ashare_fund——本工具是市场级榜单,不针对单只股票。

Input Schema

{
  "type": "object",
  "properties": {
    "type": {
      "default": "institution",
      "title": "Type",
      "type": "string"
    }
  },
  "title": "ashare_lhbArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_lhbOutput"
}
ashare_screen(expr, orderby, limit)

因子选股(量化筛股)。expression 是多因子交集表达式,例:intersect([PE_TTM > 0, PE_TTM < 20, ROETTM > 15]);常用字段:PE_TTM/PB/PS_TTM/ROE/ROETTM/ROIC/DividendRatioTTM/OperatingRevenueGrowRate/DebtAssetsRatio。用户问'筛选/选股/符合条件的股票'用这个。

Input Schema

{
  "type": "object",
  "properties": {
    "expr": {
      "title": "Expr",
      "type": "string"
    },
    "orderby": {
      "default": "",
      "title": "Orderby",
      "type": "string"
    },
    "limit": {
      "default": 20,
      "title": "Limit",
      "type": "integer"
    }
  },
  "required": [
    "expr"
  ],
  "title": "ashare_screenArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_screenOutput"
}
ashare_sector

板块行情榜(行业/概念/地域涨幅+领涨股)。用户问'哪些板块在涨/板块轮动'用这个。

Input Schema

{
  "type": "object",
  "properties": {},
  "title": "ashare_sectorArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_sectorOutput"
}
ashare_sector_valuation(code)

板块估值(PE/PB/PS + 历史百分位)。code=pt01801780 这类申万板块代码。

Input Schema

{
  "type": "object",
  "properties": {
    "code": {
      "title": "Code",
      "type": "string"
    }
  },
  "required": [
    "code"
  ],
  "title": "ashare_sector_valuationArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_sector_valuationOutput"
}
ashare_market_overview(type)

市场级画像。type=summary 画像总评/trade 收盘/interval 多周期/technical 大盘技术/valuation 估值分位/rotation 风格轮动。用户问'今天市场怎么样/大盘环境/风格轮动/估值分位'用这个。⚠️ 涨跌家数(市场广度)请用 ashare_changedist:本工具的 updown 模块为 **T-1 口径**(返回里会标数据日期,可能滞后一个交易日),已不推荐用于回答'今天的涨跌家数'。· 免费工具(无需 Key)

Input Schema

{
  "type": "object",
  "properties": {
    "type": {
      "default": "summary",
      "title": "Type",
      "type": "string"
    }
  },
  "title": "ashare_market_overviewArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_market_overviewOutput"
}
ashare_changedist

全市场涨跌家数与市场广度(**当期口径**):上涨/下跌/平盘/停牌家数 + 上涨占比 + 涨停/跌停 + 11 档涨跌幅区间分布 + 两市成交额。用户问'今天涨跌家数/多少家涨停/市场情绪/市场广度'用这个——这是市场广度的**唯一推荐入口**。⚠️ 不要用 ashare_market_overview 的 updown 模式取同一数据(那是 T-1 口径,数值会与此不一致)。· 免费工具(无需 Key)

Input Schema

{
  "type": "object",
  "properties": {},
  "title": "ashare_changedistArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_changedistOutput"
}
ashare_hot(limit)

热搜榜(A股/美股/ETF 关注度)。用户问'什么股票热门/大家在看什么'用这个。· 免费工具(无需 Key)

Input Schema

{
  "type": "object",
  "properties": {
    "limit": {
      "default": 30,
      "title": "Limit",
      "type": "integer"
    }
  },
  "title": "ashare_hotArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_hotOutput"
}
ashare_macro(region, names)

宏观数据(GDP/CPI/PMI/LPR/国债收益率)。region=cn/us/jp/eu/hk。

Input Schema

{
  "type": "object",
  "properties": {
    "region": {
      "default": "cn",
      "title": "Region",
      "type": "string"
    },
    "names": {
      "default": "",
      "title": "Names",
      "type": "string"
    }
  },
  "title": "ashare_macroArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_macroOutput"
}
ashare_bond(code)

可转债条款(溢价率/双低/强赎触发价/转股价)。code=sh113052。

Input Schema

{
  "type": "object",
  "properties": {
    "code": {
      "title": "Code",
      "type": "string"
    }
  },
  "required": [
    "code"
  ],
  "title": "ashare_bondArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_bondOutput"
}
ashare_etf(code)

ETF 概览(规模/溢折率/资金流)。code=sh510300。

Input Schema

{
  "type": "object",
  "properties": {
    "code": {
      "title": "Code",
      "type": "string"
    }
  },
  "required": [
    "code"
  ],
  "title": "ashare_etfArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_etfOutput"
}
ashare_ipo(days)

新股日历(发行/上市/中签)。用户问'新股/打新'用这个。

Input Schema

{
  "type": "object",
  "properties": {
    "days": {
      "default": 15,
      "title": "Days",
      "type": "integer"
    }
  },
  "title": "ashare_ipoArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_ipoOutput"
}
ashare_dividend(code, years)

分红送转历史。

Input Schema

{
  "type": "object",
  "properties": {
    "code": {
      "title": "Code",
      "type": "string"
    },
    "years": {
      "default": 3,
      "title": "Years",
      "type": "integer"
    }
  },
  "required": [
    "code"
  ],
  "title": "ashare_dividendArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_dividendOutput"
}
ashare_dehydrated(mode, symbol, limit)

脱水研报(券商研报摘要)。mode=list 列表 / detail 详情。

Input Schema

{
  "type": "object",
  "properties": {
    "mode": {
      "default": "list",
      "title": "Mode",
      "type": "string"
    },
    "symbol": {
      "default": "",
      "title": "Symbol",
      "type": "string"
    },
    "limit": {
      "default": 10,
      "title": "Limit",
      "type": "integer"
    }
  },
  "title": "ashare_dehydratedArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_dehydratedOutput"
}
🟢ashare_search(q)

股票/基金/板块搜索(模糊词消歧)。用户只给名称时先用这个确认代码。

Input Schema

{
  "type": "object",
  "properties": {
    "q": {
      "title": "Q",
      "type": "string"
    }
  },
  "required": [
    "q"
  ],
  "title": "ashare_searchArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_searchOutput"
}
ashare_usage

查自己的 API 用量与剩余额度。

Input Schema

{
  "type": "object",
  "properties": {},
  "title": "ashare_usageArguments"
}

Output Schema

{
  "type": "object",
  "properties": {
    "result": {
      "title": "Result",
      "type": "string"
    }
  },
  "required": [
    "result"
  ],
  "title": "ashare_usageOutput"
}

Recent observations

verifiedversion not recorded22 tools