比特幣價格 比特幣價格
Ctrl+D 比特幣價格
ads
首頁 > Coinw > Info

ENT:非小號公共API_STRI

Author:

Time:1900/1/1 0:00:00

非小號公共API

FeixiaohaoAPI是一套高性能的RESTful接口,專門設計用于滿足應用程序開發人員、數據科學家和企業業務平臺的需求。

------------------------------------------------------------------------------------

終結點

FeixiaohaoAPI目前只有1個頂級目錄。

目錄:https://fxhapi.feixiaohao.info/public/v1/ticker/*

描述:返回加密貨幣數據,如有序加密貨幣列表或價格和數量數據。

------------------------------------------------------------------------------------

快速開始

Ticker(行情)

更新頻率:1分鐘更新一次

訪問方式:

GET

URL參數

可選:

start=(指定結果集的開始排名)

limit=(指定結果集的最大數量)

convert=(將返回的price,24hvolume,和marketcap字段轉換到指定貨幣單位并補充到結果對象.可用的貨幣單位有:"AUD","BRL","CAD","CHF","CLP","CNY","CZK","DKK","EUR","GBP","HKD","HUF","IDR","ILS","INR","JPY","KRW","MXN","MYR","NOK","NZD","PHP","PKR","PLN","RUB","SEK","SGD","THB","TRY","TWD","ZAR")

訪問成功:

返回碼:200

返回內容:

[

{

"id":"bitcoin",

"name":"Bitcoin",

"symbol":"BTC",

"rank":1,

"logo-ioqf":"https://s1.bqiapp.com/coin/20181030_72_webp/bitcoin_200_200.webp",

"logo_png":"https://s1.bqiapp.com/coin/20181030_72_png/bitcoin_200_200.png",

"price_usd":5225,

"price_btc":1,

"volume_24h_usd":5150321567,

"market_cap_usd":92163602317,

"available_supply":17637575,

"total_supply":17637575,

"max_supply":21000000,

"percent_change_1h":0.21,

"percent_change_24h":0.64,

"percent_change_7d":6,

"last_updated":1554886833

},

{

"id":"ethereum",

"name":"Ethereum",

"symbol":"ETH",

"rank":2,

"logo-ioqf":"https://s1.bqiapp.com/coin/20181030_72_webp/ethereum_200_200.webp",

"logo_png":"https://s1.bqiapp.com/coin/20181030_72_png/ethereum_200_200.png",

"price_usd":179.65,

"price_btc":0.0344,

"volume_24h_usd":2766496907,

"market_cap_usd":18971178569,

"available_supply":105598041,

"total_supply":105598041,

"max_supply":105598041,

"percent_change_1h":0.35,

"percent_change_24h":2.18,

"percent_change_7d":8.42,

"last_updated":1554886833

}

]

其中各字段的說明如下:

"id":"幣種代碼",

"name":"幣種英文名稱",

"symbol":"幣種的簡稱",

"rank":幣種的排名,

"logo-ioqf":"幣種的logo",

"logo_png":"幣種的logo",

"price_usd":最新價格,

"price_btc":最新價格,

"volume_24h_usd":24h的成交額,

"market_cap_usd":流通市值,

"available_supply":流通數量,

"total_supply":總發行量,

"max_supply":最大發行量,

"percent_change_1h":1小時漲跌幅,

"percent_change_24h":24小時漲跌幅,

"percent_change_7d":7天漲跌幅,

"last_updated":行情更新時間

訪問失敗:

返回碼:401/403或者429

內容:{"message":"APIratelimitexceeded"}

示例請求:

CURL:

curl-H"Accept:application/json"-G"https://fxhapi.feixiaohao.com/public/v1/ticker?limit=5"

C#:

usingSystem;

usingSystem.Net;

usingSystem.Web;

classCSharpExample

{

publicstaticvoidMain(stringargs)

{

try

{

Console.WriteLine(makeAPICall());

}

catch(WebExceptione)

{

Console.WriteLine(e.Message);

}

}

staticstringmakeAPICall()

{

varURL=newUriBuilder("https://fxhapi.feixiaohao.com/public/v1/ticker");

varqueryString=System.Web.HttpUtility.ParseQueryString(string.Empty);

queryString="5";

queryString="5";

queryString="USD";

URL.Query=queryString.ToString();

varclient=newSystem.Net.WebClient();

client.Headers.Add("Accepts","application/json");

returnclient.DownloadString(URL.ToString());

}

}

Java:

importjava.io.IOException;

importjava.net.URISyntaxException;

importjava.util.ArrayList;

importjava.util.List;

publicclassJavaExample{

publicstaticvoidmain(Stringargs){

Stringuri="https://fxhapi.feixiaohao.com/public/v1/ticker";

Listparatmers=newArrayList();

paratmers.add(newBasicNameValuePair("start","5"));

paratmers.add(newBasicNameValuePair("limit","5"));

paratmers.add(newBasicNameValuePair("convert","USD"));

try{

Stringresult=makeAPICall(uri,paratmers);

System.out.println(result);

}catch(IOExceptione){

System.out.println("Error:cannontaccesscontent-"+e.toString());

}catch(URISyntaxExceptione){

System.out.println("Error:InvalidURL"+e.toString());

}

}

publicstaticStringmakeAPICall(Stringuri,Listparameters)

throwsURISyntaxException,IOException{

Stringresponse_content="";

URIBuilderquery=newURIBuilder(uri);

query.addParameters(parameters);

CloseableHttpClientclient=HttpClients.createDefault();

HttpGetrequest=newHttpGet(query.build());

request.setHeader(HttpHeaders.ACCEPT,"application/json");

CloseableHttpResponseresponse=client.execute(request);

try{

System.out.println(response.getStatusLine());

HttpEntityentity=response.getEntity();

response_content=EntityUtils.toString(entity);

EntityUtils.consume(entity);

}finally{

response.close();

}

returnresponse_content;

}

}

Golang:

packagemain

import(

"fmt"

"io/ioutil"

"log"

"net/http"

"net/url"

"os"

)

funcmain(){

client:=&http.Client{}

req,err:=http.NewRequest("GET","https://fxhapi.feixiaohao.com/public/v1/ticker",nil)

iferr!=nil{

log.Print(err)

os.Exit(1)

}

q:=url.Values{}

q.Add("start","5")

q.Add("limit","5")

q.Add("convert","USD")

req.Header.Set("Accepts","application/json")

req.URL.RawQuery=q.Encode()

resp,err:=client.Do(req);

iferr!=nil{

fmt.Println("Errorsendingrequesttoserver")

os.Exit(1)

}

fmt.Println(resp.Status);

respBody,_:=ioutil.ReadAll(resp.Body)

fmt.Println(string(respBody));

}

Tags:ENTRININGSTRIENTONEturingaiCryptoMechaKingStrikeX

Coinw
加密貨幣:Messari 2022年加密趨勢最新預測研報:第一章「十大投資主題」(上)_加密貨幣和中國數字貨幣

本文為Messari2022年加密趨勢研報第一章「十大投資主題」譯文版,后續譯文還將持續跟進。也許你是70%的美國人中的一員,他們不信任國會,也不信任決策者會做正確的事情,因為他們不計后果地印錢.

1900/1/1 0:00:00
THE:Gate.io Startup Initial Offering-DAO SHO Project- Blockasset (BLOCK)_BLOCK價格

Gate.iohaslaunchedStartup,aplatformthataimstoprovideuserswithaccesstoinnovativeandadvancedproject.

1900/1/1 0:00:00
BIT:BitMart上線Qredo (QRDO)_ART

親愛的BitMart用戶:BitMart將于2021年12月14日上線代幣Qredo(QRDO)。屆時將開通QRDO/USDT交易對.

1900/1/1 0:00:00
DOGE:ZT創新板即將上線GST_TPS

親愛的ZT用戶: ZT創新板即將上線GST,並開啟GST/USDT交易對。具體上線時間如下:充值:已開啟;交易:2021年12月3日16:30; GST 項目簡介:GunstarMetavers.

1900/1/1 0:00:00
Gate.io Copy Trading: The Highest Commission Received By A Strategy Provider Is 11,397 USDT

Gate.ioquantitativetradingcenterhasbeenrenamed"copytrading"andisfullylaunched.

1900/1/1 0:00:00
THE:Gate.io MemePad (MEPAD) Trading Competition, Win a Share of $18,000 Mega Reward_GATE

Gate.ioiscurrentlyholdingaMEPADtradingcompetition.Wehaveapoolof$18.

1900/1/1 0:00:00
ads