[关闭]
@hbec-public 2016-05-19T07:12:36.000000Z 字数 11831 阅读 719

金融数据业务接口


1>行业涨幅榜分页接口(包含领涨股)

金融数据封装,尚未提供

/**
* 行业按等级分页排序
* @param from 下标,0开始
* @param size 数量
* @param desc 排序方式
* @param level 等级 取值范围[2,3,4,5],分别表示1级,2级,3级,4级行业
* @return
*/
public List findIndustryChgEntityByPage(int from,int size,boolean desc, int level);

API : http://api-wwwtest.touker.com/chgQuotationService.findIndustryChgEntityByPage.open?from=0&size=100&desc=true&level=3

/**
*
* @param codes ["600123","000123"]
* @return
*/
public List getStockMarkets(String[] codes);

2>行业成份股分页接口

钱钱后台封装
/**
* 根据行业板块代码查询成分股行情,按涨跌幅进行分页排序
* @param code 代码
* @param from下标,0开始
* @param size 数量
* @param desc 排序方式
* @return
*/
public List findIndustryChgEntityByCode2Page(String code, int from,int size,boolean desc);

3>概念涨幅榜分页接口(包含领涨股)

金融数据封装,尚未提供
/**
* 查询概念板块按涨跌幅进行分页排序
* @param from 下标,0开始
* @param size 数量
* @param desc
* @return
*/
public List findConceptChgByPage(int from,int size,boolean desc);

/**
*
* @param codes ["600123","000123"]
* @return
*/
public List getStockMarkets(String[] codes);

4>概念成份股分页接口

钱钱后台封装
/**
* 根据概念代码查询成分股行情,按涨跌幅进行分页排序
* @param code 代码
* @param from 下标,0开始
* @param size 数量
* @param desc 排序方式
* @return
*/
public List findConceptChgByCode2Page(String code,int from,int size,boolean desc);

5>领涨股票分页接口

后台封装
/**
* //按照分页获取涨幅榜
* @param from 开始下标,从0开始
* @param size 数量
* @param desc 是否倒序,默认从小到大
* @return
*/
public List listByChangePercent(int from,int size,boolean desc);

6>领跌股票分页接口

后台封装
/**
* //按照分页获取涨幅榜
* @param from 开始下标,从0开始
* @param size 数量
* @param desc 是否倒序,默认从小到大
* @return
*/
public List listByChangePercent(int from,int size,boolean desc);

7>振幅榜分页接口

后台封装
/**
* 分页获取振幅排行榜
* @param from 开始下标,从0开始
* @param size 数量
* @param desc 是否倒序,默认从小到大
* @return
*/
public List listByWave(int from, int size, boolean desc);

8>领涨分级基金分页接口

后台封装
含分级基金全部分页数据、分级A分页数据、分级B分页数据、指数分页数据
1:全部基金
/**
* 分页查询场内基金(有序)
* @param from 取值开始位置
* @param size 取值数量
* @param orderField 排序字段
* @param asc 排序方式(默认升序)
* @return
*/
public List getOrderVenueFundByPage(int from, int size, String orderField, boolean asc);

/**
* 分页查询场内分级基金(有序)
* @param from 取值开始位置
* @param size 取值数量
* @param orderField 排序字段
* @param asc 排序方式(默认升序)
* @return
*/
public List getOrderVenueGradedFundByPage(int from, int size, String orderField, boolean asc);

/**
* 分页查询场内分级A类基金(有序)
* @param from 取值开始位置
* @param size 取值数量
* @param orderField 排序字段
* @param asc 排序方式(默认升序)
* @return
*/
public List getOrderVenueGradedAFundByPage(int from, int size, String orderField, boolean asc);

/**
 * 分页查询场内分级B类基金(有序)
 * @param from 取值开始位置
 * @param size 取值数量
 * @param orderField 排序字段
 * @param asc  排序方式(默认升序)
 * @return
 */
public List<FundMarketEntity> getOrderVenueGradedBFundByPage(int from, int size, String orderField, boolean asc);

9>领涨指数基金分页接口

后台封装
/**
* 分页查询场内指数型基金(有序)
* @param from 取值开始位置
* @param size 取值数量
* @param orderField 排序字段
* @param asc 排序方式(默认升序)
* @return
*/
public List getOrderVenueIndexFundByPage(int from, int size, String orderField, boolean asc);

10>股票、指数、基金分时走势图接口

移动端调用API

股票分时
http://api-wwwtest.touker.com/financeData.queryMarket.open?qJson={entityName:StockMarketTimeSeriesEntity,timeSeriesReturnFieldNames:[code,name,currentPrice],restriction:{op:eq,value:%22002741%22,fieldName:code},withCountStar:false,n:0,skips:0,from:%222015-04-10%2009:00:00%22,to:%222015-04-10%2015:00:00%22,maxResults:0}

指数分时
http://api-wwwtest.touker.com/financeData.queryMarket.open?qJson={entityName:IndexMarketTimeSeriesEntity,timeSeriesReturnFieldNames:[code,name],restriction:{op:eq,value:000300,fieldName:code},withCountStar:false,n:0,skips:0,from:%222015-04-10%2001:00:00%22,to:%222015-04-10%2023:00:00%22,maxResults:0}

基金分时:
http://api.touker.com/financeData.queryMarket.open?qJson={entityName:FundMarketTimeSeriesEntity,timeSeriesReturnFieldNames:[code,name,currentPrice],restriction:{op:eq,value:%22150248%22,fieldName:code},withCountStar:false,n:0,skips:0,from:%222015-09-07%2009:00:00%22,to:%222015-09-07%2015:00:00%22,maxResults:0}

11>股票、指数、基金五日走势图接口

移动端调用API

基金5日:
http://api-wwwtest.touker.com/financeData.queryMarket.open?qJson={'entityName':'FundMarketTimeSeriesEntity','timeSeriesReturnFieldNames':['code'],'restriction':{'op':'eq','value':'150318','fieldName':'code','includeFrom':false,'includeTo':false},'withCountStar':false,'n':0,'skips':0,'lastTMode':'daily','lastDate':'2015-12-1 15:00:00','t':[5,5],'maxResults':0,'isDesc':false}

http://api.touker.com/financeData.queryMarket.open?qJson={entityName:FundMarketTimeSeriesEntity,timeSeriesReturnFieldNames:[code,name,currentPrice],restriction:{op:eq,value:%22150318%22,fieldName:code},withCountStar:false,'lastTMode':'daily','lastDate':'2015-12-08%2008:00:00','t':[5,10]}

股票5日:
http://api-wwwtest.touker.com/financeData.queryMarket.open?qJson={'entityName':'StockMarketTimeSeriesEntity','timeSeriesReturnFieldNames':['code'],'restriction':{'op':'eq','value':'000001','fieldName':'code','includeFrom':false,'includeTo':false},'withCountStar':false,'n':0,'skips':0,'lastTMode':'daily','lastDate':'2015-12-1 15:00:00','t':[5,5],'maxResults':0,'isDesc':false}

指数5日:
http://api-wwwtest.touker.com/financeData.queryMarket.open?qJson={'entityName':'IndexMarketTimeSeriesEntity','timeSeriesReturnFieldNames':['code'],'restriction':{'op':'eq','value':'000001','fieldName':'code','includeFrom':false,'includeTo':false},'withCountStar':false,'n':0,'skips':0,'lastTMode':'daily','lastDate':'2015-12-1 15:00:00','t':[5,5],'maxResults':0,'isDesc':false}

12>股票、指数、基金日K走势图接口

移动端调用API
/**
* 查询场内基金K线
* @param frontPurshCode 代码
* @param date 日期
* @param n 数量(点)
* @param kts 类型,Daily,Week
* @return
*/
http://api-wwwtest.touker.com/kTimeSeriseService.findFKtsByCode.open?frontPurshCode=150075&date=%272015-11-07%2000:00:00%27&n=60&kts=Daily

http://api-wwwtest.touker.com/financeDataTimeSeries.queryTimeSeriesEntites.open?qJson={'entityName':'FundMarketTimeSeries','timeSeriesReturnFieldNames':['frontPurchaseCode','abbrName','turnoverVal','turnoverVol','prevClosingPrice','prevAvgPrice','openingPrice','closingPrice','highestPrice','lowestPrice','avgPrice','prevClosingPrice'],'averageSeriesSetFieldNames':{'turnoverVol':'average','turnoverVal':'average'},'returnSeriesFieldNames':['turnoverVal5','turnoverVal10','turnoverVal20','turnoverVol5','turnoverVol10','turnoverVol20'],'restriction':{'op':'eq','value':'150197','fieldName':'frontPurchaseCode','includeFrom':false,'includeTo':false},'withCountStar':false,'lastMode':'daily','n':60,'skips':0,'lastTMode':'daily','lastDate':'2015-12-07%2015:00:00','t':[5,10,20],'maxResults':0,'isDesc':false}

http://api-wwwtest.touker.com/financeDataTimeSeries.queryTimeSeriesEntites.open?qJson={'entityName':'FundMarketTimeSeries','timeSeriesReturnFieldNames':['frontPurchaseCode','abbrName','turnoverVal','turnoverVol','prevClosingPrice','prevAvgPrice','openingPrice','closingPrice','highestPrice','lowestPrice','avgPrice','prevClosingPrice'],'averageSeriesSetFieldNames':{'turnoverVol':'average','turnoverVal':'average'},'returnSeriesFieldNames':['turnoverVal5','turnoverVal10','turnoverVal20','turnoverVol5','turnoverVol10','turnoverVol20'],'restriction':{'op':'eq','value':'150197','fieldName':'frontPurchaseCode','includeFrom':false,'includeTo':false},'withCountStar':false,'lastMode':'daily','n':60,'skips':0,'lastTMode':'daily','lastDate':'2015-12-07%2015:00:00','t':[5,10,20],'maxResults':0,'isDesc':false}

股票日K
https://api.touker.com/financeDataTimeSeries.queryTimeSeriesEntites.open?qJson={'entityName':'StockTimeSeries','lastTMode':'daily','maxResults':0,'skips':0,'restriction':{'fieldName':'code','op':'eq','value':'000020'},'timeSeriesReturnFieldNames':['code','name','totalAmt','totalNum','openPrice','closePrice','previousPrice','changesPercent','changes','upPrice','lowPrice','totalNum','theDate'],'returnSeriesFieldNames':['closePrice5','closePrice10','closePrice20'],'lastMode':'daily','lastDate':'2016-01-0400:00:00','t':['5','10','20'],'averageSeriesSetFieldNames':{'closePrice':'average'},'n':59,'withCountStar':false}

/**
* 查询指数K线
* @param frontPurshCode 代码
* @param date 日期
* @param n 数量(点)
* @param kts 类型,Daily,Week
* @return
/
http://api-wwwtest.touker.com/kTimeSeriseService.findIKtsByCode.open?frontPurshCode=000001&date='2015-08-07 00:00:00'&n=60&kts=Daily
/*

* 查询股票K线
* @param frontPurshCode 代码
* @param date 日期
* @param n 数量(点)
* @param kts 类型,Daily,Week,Month
* @return
*/
http://api-wwwtest.touker.com/kTimeSeriseService.findSKtsByCode.open?frontPurshCode=000002&date='2015-08-07 00:00:00'&n=60&kts=Daily

13>股票、指数、基金周K走势图接口

移动端调用API
/**
* 查询场内基金K线
* @param frontPurshCode 代码
* @param date 日期
* @param n 数量(点)
* @param kts 类型,Daily,Week
* @return
*/
http://api-wwwtest.touker.com/kTimeSeriseService.findFKtsByCode.open?frontPurshCode=150075&date=%272015-11-07%2000:00:00%27&n=60&kts=Week

旧版接口
http://api.touker.com/financeDataTimeSeries.queryTimeSeriesEntites.open?qJson={ 'entityName':'FundMarketTimeSeries', 'timeSeriesReturnFieldNames':['frontPurchaseCode','theDate','openingPrice','closingPrice','lowestPrice','highestPrice'], 'n':'60', 'lastMode':'weekly', 'lastTMode':'weekly', 'withCountStar':'false', 'lastDate':'2015-12-07 00:00:00', 'averageSeriesSetFieldNames':{'closingPrice':'average'}, 't':['5','10','20'], 'returnSeriesFieldNames':['closingPrice5','closingPrice10','closingPrice20'], 'restriction':{'fieldName':'frontPurchaseCode','op':'eq','value':'150197'}}

/**
* 查询指数K线
* @param frontPurshCode 代码
* @param date 日期
* @param n 数量(点)
* @param kts 类型,Daily,Week
* @return
/
http://api-wwwtest.touker.com/kTimeSeriseService.findIKtsByCode.open?frontPurshCode=000001&date='2015-08-07 00:00:00'&n=60&kts=Week
/*

* 查询股票K线
* @param frontPurshCode 代码
* @param date 日期
* @param n 数量(点)
* @param kts 类型,Daily,Week,Month
* @return
*/
http://api-wwwtest.touker.com/kTimeSeriseService.findSKtsByCode.open?frontPurshCode=000002&date='2015-08-07 00:00:00'&n=60&kts=Week

14>基金净值走势图

移动端调用API
http://api.touker.com/financeDataTimeSeries.queryTimeSeriesEntites.open?qJson={'entityName':'FundTimeSeries','timeSeriesReturnFieldNames':['id','frontPurchaseCode','fundId','theDate','netPresentValue','netPresentValueChange','yield','cumulativeYield'],'restriction':{'op':'eq','value':'150248','fieldName':'frontPurchaseCode'},'withCountStar':false,'lastMode':'monthly','n':3,'skips':0}

15>搜索接口

接口暂时不变

搜索条件:
非退市 and marketType 为股票、指数、或场内基金(基金类型限制为分级AB、指数型ETF、指数型LOF)
and 符合搜索条件(securityCode或securityAbbrName或pinyinSecurityAbbr like '%搜索关键字%')

最多20条,搜索结果按股票、基金、指数排序

16>新闻列表分页接口

接口暂时不变

17>新闻详情

接口暂时不变

18>简况

接口暂时不变

19>股东接口

接口暂时不变

20>根据股票代码查行情

后台封装
/**
* //根据单个code获取指定股票代码行情
* @param code 600123
* @return
*/
public StockMarketEntity getStockMarket(String code);

21> V1.0接口归档

22> 金融数据接口DEMO

插叙指数详情信息

http://api.touker.com/financeData.queryEntites.open?qJson={entityName:IndexMarketEntity,returnFieldNames:[exchange,tradeDate,name,code,currentPrice,openPrice],maxResults:0,firstResult:0,restriction:{op:eq,fieldName:code,value:%22000300%22,includeFrom:false,includeTo:false},orders:{},maps:{},withCountStar:false}

股票接口

http://api.touker.com/financeData.queryEntites.open?qJson={entityName:StockMarketEntity,returnFieldNames:[earningsMultiple,haltState,state,id,tradeDate,name,pe,code,currentPrice,openPrice,changesPercent,changes],maxResults:0,firstResult:0,restriction:{op:eq,fieldName:code,value:'002466',includeFrom:false,includeTo:false},orders:{},maps:{},withCountStar:false}

指数接口

http://api.touker.com/financeData.queryEntites.open?qJson={entityName:IndexMarketEntity,returnFieldNames:[exchange,tradeDate,name,code,currentPrice,openPrice,changesPercent,changes],maxResults:0,firstResult:0,restriction:{op:eq,fieldName:code,value:000001,includeFrom:false,includeTo:false}}

添加新批注
在作者公开此批注前,只有你和作者可见。
回复批注