using System;
using System.Net;
using System.Text;
namespace All open fund
{
class Program
{
static void Main(string[] args)
{
string key = "*******************************";
string url = "http://apis.haoservice.com/lifeservice/netdata/all?key="+key;
WebClient wc = new WebClient();
wc.Encoding=Encoding.UTF8;
string str=wc.DownloadString(url);
Console.WriteLine(str);
Console.ReadKey();
}
}
}
全部开放基金
接口信息:
URL:http://apis.haoservice.com/lifeservice/netdata/all
支持格式:json
http请求方式:GET
参数说明:
名称 类型 必须 说明
key string 是 应用APPKEY(应用详细页查询)
返回结果示例:
{
"error_code":"0",
"reason":"Success",
"result":[
{
"1":{
"code":"990001", /*基金代码*/
"name":"新点FOF固定收益", /*基金简称*/
"newnet":"1.0393", /*最新净值*/
"totalnet":"1.0393", /*累计净值*/
"dayincrease":"0.0002", /*日增长值*/
"daygrowrate":"0.0192", /*日增长率%*/
"weekgrowrate":"0.1500", /*周增长率%*/
"monthgrowrate":"0.7100", /*月增长率%*/
"annualincome":"3.9300", /*本年收益%*/
"time":" 2012年12月18日" /*最新净值时间*/
},
......
"1305":{
"code":"000001",
"name":"华夏成长",
"newnet":"--",
"totalnet":"--",
"dayincrease":"--",
"daygrowrate":"--",
"weekgrowrate":"--",
"monthgrowrate":"--",
"annualincome":"--",
"time":" 2012年12月18日"
}
}
]
}