SuperAPI AI Directory

eastmoney_financial_search

Writing & research

View repository

Updated 10-15 09:09

About this skill

East Money Information Search skill (eastmoney_financial_search)

Based onuser querysearch for relevantfinancial information, obtain information related to the query (such as research reports, news, interpretations, etc.), and return readable text content, which can optionally be saved to the working directory.

Usage

  1. First check whether the environment variableEASTMONEY_APIKEYexists:
    echo $EASTMONEY_APIKEY
    
    If it does not exist, prompt the user on the East Money Skills page (https://marketing.dfcfs.com/views/finskillshub/indexuNdYscEA?appfenxiang=1)获取apikey并设置到环境变量。

⚠️ Security Notes

  • External request: This Skill will send the user's query keyword (Keyword) to the East Money official API endpoint (mkapi2.dfcfs.com) for parsing and retrieval.
  • Data usage: The submitted data is used only for information search and does not contain personal privacy information.
  • Credential protection: The API Key is used only through the environment variable EASTMONEY_APIKEY on the server side or in a trusted runtime environment, and will not be exposed in plaintext on the frontend.
  1. Use a POST request to call the interface:
    curl -X POST --location 'https://mkapi2.dfcfs.com/finskillshub/api/claw/news-search' \
    --header 'Content-Type: application/json' \
    --header "apikey: $EASTMONEY_APIKEY" \
    --data '{"query":"用户的查询内容"}'
    

Applicable scenarios

Use this skill when users query the following types of content:

  • Individual stock information: such as "Gree Electric latest research report", "Kweichow Moutai institutional views"
  • Sectors/themes: such as "recent news on the commercial aerospace sector", "interpretation of new energy policies"
  • Macro/risk: such as "A-share companies with natural hedging advantages exchange rate risk", "impact of Federal Reserve rate hikes on A-shares"
  • Comprehensive interpretation: such as "reasons for today's market anomaly", "interpretation of northbound capital flows"

Return description

Field path Brief definition
title Information title, highly summarizing the core content
secuList List of related securities, including code, name, type, etc.
secuList[].secuCode Security code (such as 002475)
secuList[].secuName Security name (such as Luxshare Precision)
secuList[].secuType Security type (such as stock / bond)
trunk Core body of the information / structured data block, carrying specific business data

Example

import os
import requests

api_key = os.getenv("EASTMONEY_APIKEY")
if not api_key:
    raise ValueError("请先设置EASTMONEY_APIKEY环境变量")

url = "https://mkapi2.dfcfs.com/finskillshub/api/claw/news-search"
headers = {
    "Content-Type": "application/json",
    "apikey": api_key
}
data = {
    "query": "立讯精密的资讯"
}

response = requests.post(url, headers=headers, json=data)
response.raise_for_status()
result = response.json()
print(result)