Home Notices Documents Classes Download Others Rice
Classes  >  bitbankapi  >  Depth(string)
bitbankapi クラス : Depth(string) メソッド

説明

板情報を取得します。

構文

bitbankapiInstance.Depth(string currencyPair)

引数

クラス名前説明
stringcurrencyPair通貨ペア。

返り値

クラス説明
bitbankres要求に対する応答、JSON文字列を持つ。

サンプルコード

1:

bitbankapi bitbankapiIns = new bitbankapi();

2:

bitbankres bitbankresIns = bitbankapiIns.Depth("btc_jpy");

3:

string jsonStr = bitbankresIns.Result;

JSON-text 例

{"success":1,"data":{"asks":[["1081339","0.5788"],["1081341","0.2885"],["1081342","0.1000"],["1081343","1.2033"],["1081685","0.3000"],["1081803","0.5074"],["1081804","0.0990"],["1081806","0.0990"],["1081808","0.0990"],["1081809","0.3800"],["1081819","0.3000"],["1082000","1.7969"],["1082072","0.5217"],["1082200","0.5217"],["1082359","0.0303"],["1082496","0.0600"],["1083082","0.0600"],["1083275","0.2644"],["1083470","0.0002"],["1083496","0.0040"],["1083914","0.0693"],["1084000","0.1955"],["1084194","0.0800"],["1084622","0.0011"],["1084735","0.9691"],["1084736","0.0260"],["1084999","0.0147"],["1085000","0.2368"],["1085797","0.0068"],["1085920","0.1000"],["1086000","0.0029"],["1086215","0.0072"],["1086218","0.0106"],["1086469","0.0007"],["1086568","0.0001"],["1086926","0.0055"],["1087000","0.1013"],["1087338","0.5669"],["1087463","0.1000"],["1087500","0.0175"],["1087599","0.1000"],["1087600","0.0093"],["1087738","0.0300"],["1087740","10.1153"],["1088355","0.0013"],["1088542","0.2000"],["1089000","0.0583"],["1089473","0.0330"],["1089992","0.0164"],["1090000","0.2945"],["1090002","0.5672"],["1090101","0.1185"],["1090236","0.0007"],["1090550","0.1000"],["1090781","0.3420"],["1091000","0.2198"],["1091413","0.0500"],["1091414","0.0096"],["1091928","0.0006"],["1091989","0.0294"],["1091999","0.0075"],["1092000","0.6160"],["1092010","0.0040"],["1092244","0.9643"],["1092437","0.0480"],["1092500","0.0273"],["1092631","0.0005"],["1092690","0.1005"],["1093000","0.1027"],["1093003","0.7000"],["1093390","0.2600"],["1093499","0.1000"],["1093500","0.1348"],["1094250","0.0120"],["1094750","0.0900"],["1094766","0.0057"],["1094992","0.0091"],["1095000","1.7866"],["1095300","0.0004"],["1095500","0.0521"],["1095640","0.0004"],["1095900","0.0100"],["1096000","3.6412"],["1096010","0.0040"],["1096500","0.0005"],["1096963","0.0100"],["1096990","0.0085"],["1097000","1.0126"],["1098000","1.4509"],["1098001","0.2370"],["1098444","0.3717"],["1098499","0.0700"],["1098678","0.1000"],["1098869","0.0095"],["1098950","0.0050"],["1098999","0.2052"],["1099250","0.0029"],["1099880","0.0686"],["1099990","4.6203"],["1099994","1.0080"],["1099997","0.0045"],["1099998","0.0010"],["1099999","0.1000"],["1100000","13.4218"],["1100001","0.1000"],["1101000","5.0002"],["1101212","0.1636"],["1101409","0.0141"],["1101600","0.0005"],["1102000","8.0000"],["1102200","0.5000"],["1102894","0.0168"],["1103000","5.0000"],["1103249","0.0210"],["1104000","5.0640"],["1104791","0.0009"],["1104999","0.1000"],["1105000","5.2013"],["1106000","5.0000"],["1106621","0.1000"],["1106700","0.0005"],["1107000","5.0000"],["1108000","5.2400"],["1108500","3.0000"],["1108800","0.0010"],["1109000","5.1000"],["1109999","0.1000"],["1110000","3.5401"],["1110519","0.0554"],["1110990","0.0686"],["1111000","0.0100"],["1111100","0.0100"],["1111111","0.1400"],["1111231","0.5847"],["1111525","0.0200"],["1111612","0.0100"],["1111800","0.0005"],["1112000","1.0000"],["1113000","0.4376"],["1114998","0.0010"],["1114999","0.1000"],["1115000","0.2439"],["1116000","0.2794"],["1116391","0.0009"],["1116900","0.0005"],["1117800","0.0010"],["1118000","0.5110"],["1118750","0.0500"],["1118990","0.1000"],["1119000","0.0095"],["1119012","0.0091"],["1119800","0.4385"],["1119999","0.1000"],["1120000","4.0532"],["1121000","0.1714"],["1122000","1.8894"],["1122200","0.5000"],["1122212","0.0686"],["1122457","0.0100"],["1123000","0.1073"],["1124500","0.0100"],["1124550","0.0005"],["1124998","0.0010"],["1125000","0.5176"],["1125009","1.0000"],["1125186","0.0575"],["1126101","0.0499"],["1126726","0.0100"],["1127000","0.0050"],["1127100","0.0005"],["1127564","0.0300"],["1128114","0.0009"],["1128789","0.1000"],["1128900","1.7710"],["1129000","0.4641"],["1129648","0.0718"],["1130000","8.7915"],["1130500","0.0464"],["1130671","0.0952"],["1131000","0.1000"],["1131111","0.0010"],["1131234","0.3292"],["1131464","0.0100"],["1131477","0.0392"],["1132000","0.4244"],["1132200","0.0005"],["1132948","0.0270"],["1133000","0.1334"],["1133683","0.0050"],["1133999","0.1000"],["1134000","1.2660"],["1134750","0.0005"],["1134920","1.0000"],["1134999","0.1000"],["1135000","7.5655"],["1135036","0.0120"],["1135103","0.0100"],["1135200","0.0885"],["1135515","0.1170"],["1135550","0.1510"]],"bids":[["1081334","0.0288"],["1081319","0.0147"],["1081298","0.2697"],["1081035","0.1658"],["1081034","0.0039"],["1080947","0.0001"],["1080900","0.0003"],["1080765","0.2901"],["1080764","0.0022"],["1080570","0.0090"],["1080398","0.4782"],["1080340","0.0062"],["1080254","0.4782"],["1080028","0.2644"],["1080000","0.0146"],["1079358","0.0400"],["1079357","0.0400"],["1079356","0.0400"],["1079355","0.0400"],["1079354","0.5930"],["1079281","0.0100"],["1079011","8.5948"],["1078500","0.3000"],["1078364","0.0500"],["1078200","0.3736"],["1078001","0.9692"],["1078000","0.9388"],["1077032","0.4630"],["1077000","0.1100"],["1076988","0.0002"],["1076664","0.0024"],["1076482","0.0010"],["1076000","0.0100"],["1075000","0.2700"],["1074832","0.0095"],["1074207","10.1154"],["1073999","5.0000"],["1073858","0.0010"],["1073736","0.0900"],["1073000","0.0651"],["1072262","0.1000"],["1072001","0.0010"],["1072000","1.4047"],["1071254","0.0024"],["1071127","0.0087"],["1071031","0.0240"],["1071004","0.5000"],["1071003","0.0994"],["1071000","0.1414"],["1070709","0.0009"],["1070020","0.1000"],["1070000","18.4056"],["1069983","0.0001"],["1069533","0.5000"],["1069003","0.1000"],["1068800","0.0100"],["1068700","0.0261"],["1068652","0.0300"],["1068010","0.0040"],["1068000","0.2299"],["1067952","0.0001"],["1067000","0.0197"],["1066029","4.9021"],["1066005","0.0001"],["1065700","0.0200"],["1065569","0.0100"],["1065305","0.0100"],["1065250","0.0582"],["1065052","0.0001"],["1065000","1.4764"],["1064344","0.0001"],["1064000","0.0170"],["1063888","3.3305"],["1063730","0.0006"],["1063380","0.0010"],["1063123","0.5668"],["1063000","0.2379"],["1062867","0.0001"],["1062512","0.0686"],["1062000","0.2506"],["1061100","0.0150"],["1061000","0.3466"],["1060836","0.0001"],["1060193","0.0007"],["1060123","0.0582"],["1060020","0.1000"],["1060010","0.0040"],["1060007","0.6243"],["1060000","1.8166"],["1059583","0.0009"],["1059308","0.0266"],["1058917","0.0001"],["1058800","0.0200"],["1058765","1.5000"],["1058001","1.0000"],["1058000","0.8560"],["1057811","0.0001"],["1057530","0.0473"],["1057001","0.5000"],["1057000","0.0548"],["1056913","0.6587"],["1056877","0.0001"],["1056867","0.0100"],["1056790","4.8224"],["1056666","0.2000"],["1056619","0.0500"],["1056601","0.0500"],["1056002","0.5000"],["1056000","0.1031"],["1055711","0.0001"],["1055559","0.0030"],["1055200","0.2761"],["1055055","0.0596"],["1055005","1.0000"],["1055002","0.0020"],["1055000","1.3231"],["1054146","0.0001"],["1054000","0.0037"],["1053573","0.1000"],["1053000","0.8000"],["1052900","0.1000"],["1052810","0.0001"],["1052584","1.0000"],["1052000","0.1157"],["1051992","0.0700"],["1051899","1.0000"],["1051480","0.0010"],["1051436","0.0001"],["1051212","0.0016"],["1051111","1.0000"],["1051001","1.0000"],["1051000","3.2886"],["1050913","0.1000"],["1050800","0.1000"],["1050673","0.0006"],["1050519","0.0100"],["1050500","0.0567"],["1050447","0.0020"],["1050389","0.0362"],["1050122","0.0839"],["1050061","0.0031"],["1050020","0.1000"],["1050003","0.2000"],["1050002","0.2000"],["1050001","0.1497"],["1050000","8.7721"],["1049999","0.1400"],["1049938","0.0001"],["1049507","0.2000"],["1049272","0.0025"],["1049000","0.2978"],["1048999","0.1000"],["1048800","0.3521"],["1048619","0.2000"],["1048573","0.0009"],["1048538","0.0001"],["1048222","0.4750"],["1048178","0.0200"],["1048000","1.8284"],["1047884","0.0009"],["1047868","0.0022"],["1047800","0.0500"],["1047526","0.5946"],["1047512","1.0000"],["1047275","0.0020"],["1047028","0.0015"],["1047000","0.8000"],["1046826","0.0001"],["1046325","0.0270"],["1046002","0.5000"],["1046001","0.5030"],["1046000","0.9092"],["1045900","0.0095"],["1045875","0.0500"],["1045800","0.0010"],["1045787","0.1046"],["1045555","0.0007"],["1045500","0.2406"],["1045420","0.0496"],["1045270","0.0010"],["1045220","0.0105"],["1045212","0.1919"],["1045121","0.0016"],["1045092","0.0001"],["1045072","1.0079"],["1045010","0.0500"],["1045002","0.1000"],["1045001","0.0500"],["1045000","4.2989"],["1044800","1.0651"],["1044680","0.0006"],["1044444","0.1912"],["1044213","1.5000"],["1044050","0.0020"],["1044001","0.0500"],["1044000","2.1089"],["1043912","0.0009"],["1043883","0.0100"],["1043777","0.0001"],["1043291","0.0010"]],"timestamp":1582336414448,"sequenceId":"198030759"}}

注意

公開APIです。API キーと秘密キーを設定しなくても情報を取得できます。

引数に有効な通貨ペア名を指定した場合、その通貨ペアの板情報が返ります。

有効な引数 : btc_jpy, xrp_jpy, ltc_btc, eth_btc, mona_jpy, mona_btc, bcc_jpy, bcc_btc

売板情報("asks")は価格の昇順、買板情報("bids")は価格の降順でソートされた状態で返ります。

要求に対する応答として bitbankres クラスのインスタンスが返ります。このインスタンスが応答の結果の JSON-text を保持しています。

引数が正しくない場合、以下の様な JSON-text が返ります。

{"success": 1000,"return": { "message": "http error"}}

HTTP エラーが発生した場合、以下の様な JSON-text が返ります。

{"success": -1000,"error": { "statuscode" : 404, "message": "Not Found"}}

"statuscode" と "message" は、それぞれの HTTP エラーで異なります。

要求がタイムアウトした場合、以下の JSON-text が返ります。

{"success": -1001,"error": { "typename" : "TaskCanceledException", "message": "タスクが取り消されました。"}}

その他の例外が発生して要求が失敗した場合、以下の様な JSON-text が返ります。

{"success": -1002,"error": { "typename" : "...", "message": "..."}}

"typename" と "message" は、それぞれの例外で異なります。

参照リンク

Copyright © Rice All rights reserved.