{ "info": { "author": "xycfree", "author_email": "xycfree@163.com", "bugtrack_url": null, "classifiers": [], "description": " $ pip install ccwt_client\r\r\n \r\r\n python setup.py sdist build\r\r\n twine upload dist/*\r\r\n \r\r\n ## 1.0\u66f4\u65b0\r\r\n \u4fee\u6539\u8bf7\u6c42\u9ed8\u8ba4\u8d85\u65f6\u65f6\u95f4 __DEFAULT_TIMEOUT = 90\r\r\n future_index\u6307\u6570bar\u6570\u636e\u8865\u5145\uff0c\u6839\u636eticker kline\u7684\u9891\u7387\u8865\u5145\uff0c\u65e0\u6570\u636e\u5219\u586b\u5145\u524d\u4e00\u6761\u6570\u636e\r\r\n \r\r\n ## 0.9\u66f4\u65b0\r\r\n \u4fee\u6539\u8bf7\u6c42\u9ed8\u8ba4\u8d85\u65f6\u65f6\u95f4 __DEFAULT_TIMEOUT = 90\r\r\n bar\u6570\u636e\u8865\u5145\uff0c\u6839\u636eticker kline\u7684\u9891\u7387\u8865\u5145\uff0c\u65e0\u6570\u636e\u5219\u586b\u5145\u524d\u4e00\u6761\u6570\u636e\r\r\n \r\r\n ##\u3000\uff10.8\u66f4\u65b0\r\r\n feed\u6570\u636e\u589e\u52a0future_ticker/future_kline, future_index, future_this_week_ticker/future_this_week_kline\r\r\n future_next_week_tickeer/future_next_week_kline, future_quarter_ticker/future_quarter_kline\r\r\n \r\r\n #Ccwt_web: ccwt_web\u63a5\u53e3\u7684\u6570\u636e\u6ca1\u6709\u8fdb\u884c\u8f6c\u6362\uff0c\u76f4\u63a5\u4eceMongoDB\u8bfb\u53d6\uff1b\r\r\n ## Host: http: //52.194.88.72:8002\r\r\n ### Kline: /api/kline \r\r\n \u53c2\u6570\uff1a\r\r\n exchange: \u4ea4\u6613\u6240 str \r\r\n symbol: \u4ea4\u6613\u5bf9\uff0c\u53ef\u4ee5\u591a\u4e2a\uff0c\u4ee5\u9017\u53f7\u5206\u9694 str\r\r\n time_frame: \u65f6\u95f4\u8303\u56f4\uff081m\u30011d\uff0c1w, 1M\uff09\uff0c\u9ed8\u8ba41m str \r\r\n limit: \u6761\u6570,\u9ed8\u8ba4100\u6761 str\r\r\n format: \u8fd4\u56de\u6570\u636e\u683c\u5f0f, \u9ed8\u8ba4API\u683c\u5f0f\uff0c \uff08json: json\u683c\u5f0f\uff0c api: api\u683c\u5f0f\uff09 str\r\r\n http://52.194.88.72:8002/api/kline?exchange=bitmex&symbol=TRXZ18&time_frame=1m&limit=10\r\r\n [\r\r\n {\r\r\n \"bitmex_TRXZ18_kline_1m\": [\r\r\n {\r\r\n \"_id\": \"1540369140.0\",\r\r\n \"volume\": 1910.0,\r\r\n \"vwap\": 3.7e-06,\r\r\n \"turnover\": 706700,\r\r\n \"sys_time\": \"2018-10-24 08:19:15\",\r\r\n \"open\": 3.7e-06,\r\r\n \"date\": 20181024,\r\r\n \"home_notional\": null,\r\r\n \"low\": 3.7e-06,\r\r\n \"last_size\": 10,\r\r\n \"high\": 3.7e-06,\r\r\n \"close\": 3.7e-06,\r\r\n \"exchange_time\": \"2018-10-24 08:19:00.000000\",\r\r\n \"count\": 2,\r\r\n \"foreign_notional\": null,\r\r\n \"time_stamp\": \"2018-10-24T08:19:00\"\r\r\n },\r\r\n \r\r\n {\r\r\n \"_id\": \"1540369320.0\",\r\r\n \"date\": 20181024,\r\r\n \"foreign_notional\": null,\r\r\n \"volume\": 40000.0,\r\r\n \"low\": 3.71e-06,\r\r\n \"last_size\": 29900,\r\r\n \"time_stamp\": \"2018-10-24T08:22:00\",\r\r\n \"turnover\": 14840000,\r\r\n \"sys_time\": \"2018-10-24 08:22:15\",\r\r\n \"exchange_time\": \"2018-10-24 08:22:00.000000\",\r\r\n \"open\": 3.7e-06,\r\r\n \"high\": 3.71e-06,\r\r\n \"vwap\": 3.71e-06,\r\r\n \"home_notional\": null,\r\r\n \"count\": 3,\r\r\n \"close\": 3.71e-06\r\r\n },\r\r\n ]\r\r\n }\r\r\n ]\r\r\n \r\r\n ## Ticker: /api/ticker \r\r\n \u53c2\u6570\uff1a\r\r\n exchange: \u4ea4\u6613\u6240 str \r\r\n symbol: \u4ea4\u6613\u5bf9\uff0c\u53ef\u4ee5\u591a\u4e2a\uff0c\u4ee5\u9017\u53f7\u5206\u9694 str\r\r\n limit: \u6761\u6570,\u9ed8\u8ba4100\u6761 str\r\r\n format: \u8fd4\u56de\u6570\u636e\u683c\u5f0f, \u9ed8\u8ba4API\u683c\u5f0f\uff0c \uff08json: json\u683c\u5f0f\uff0c api: api\u683c\u5f0f\uff09 str\r\r\n \r\r\n http://52.194.88.72:8002/api/ticker?exchange=bitmex&symbol=TRXZ18&limit=10\r\r\n \r\r\n [\r\r\n {\r\r\n \"bitmex_TRXZ18_ticker\": [\r\r\n {\r\r\n \"_id\": \"2018-10-23T08:33:01.866Z\",\r\r\n \"symbol\": \"TRXZ18\",\r\r\n \"rootSymbol\": \"TRX\",\r\r\n \"state\": \"Open\",\r\r\n \"typ\": \"FFCCSX\",\r\r\n \"listing\": \"2018-09-21T02:00:00.000Z\",\r\r\n \"front\": \"2018-11-30T12:00:00.000Z\",\r\r\n \"expiry\": \"2018-12-28T12:00:00.000Z\",\r\r\n \"settle\": \"2018-12-28T12:00:00.000Z\",\r\r\n \"relistInterval\": null,\r\r\n \"inverseLeg\": \"\",\r\r\n \"sellLeg\": \"\",\r\r\n \"buyLeg\": \"\",\r\r\n \"optionStrikePcnt\": null,\r\r\n \"optionStrikeRound\": null,\r\r\n \"optionStrikePrice\": null,\r\r\n \"optionMultiplier\": null,\r\r\n \"positionCurrency\": \"TRX\",\r\r\n \"underlying\": \"TRX\",\r\r\n \"quoteCurrency\": \"XBT\",\r\r\n \"underlyingSymbol\": \"TRXXBT=\",\r\r\n \"reference\": \"BMEX\",\r\r\n \"referenceSymbol\": \".TRXXBT30M\",\r\r\n \"calcInterval\": null,\r\r\n \"publishInterval\": null,\r\r\n \"publishTime\": null,\r\r\n \"maxOrderQty\": 10000000,\r\r\n \"maxPrice\": 100,\r\r\n \"lotSize\": 1,\r\r\n \"tickSize\": 1e-08,\r\r\n \"multiplier\": 100000000,\r\r\n \"settlCurrency\": \"XBt\",\r\r\n \"underlyingToPositionMultiplier\": 1,\r\r\n \"underlyingToSettleMultiplier\": null,\r\r\n \"quoteToSettleMultiplier\": 100000000,\r\r\n \"isQuanto\": false,\r\r\n \"isInverse\": false,\r\r\n \"initMargin\": 0.05,\r\r\n \"maintMargin\": 0.025,\r\r\n \"riskLimit\": 5000000000,\r\r\n \"riskStep\": 5000000000,\r\r\n \"limit\": null,\r\r\n \"capped\": false,\r\r\n \"taxed\": true,\r\r\n \"deleverage\": true,\r\r\n \"makerFee\": -0.0005,\r\r\n \"takerFee\": 0.0025,\r\r\n \"settlementFee\": 0,\r\r\n \"insuranceFee\": 0,\r\r\n \"fundingBaseSymbol\": \"\",\r\r\n \"fundingQuoteSymbol\": \"\",\r\r\n \"fundingPremiumSymbol\": \"\",\r\r\n \"fundingTimestamp\": null,\r\r\n \"fundingInterval\": null,\r\r\n \"fundingRate\": null,\r\r\n \"indicativeFundingRate\": null,\r\r\n \"rebalanceTimestamp\": null,\r\r\n \"rebalanceInterval\": null,\r\r\n \"openingTimestamp\": \"2018-10-23T08:00:00.000Z\",\r\r\n \"closingTimestamp\": \"2018-10-23T09:00:00.000Z\",\r\r\n \"sessionInterval\": \"2000-01-01T01:00:00.000Z\",\r\r\n \"limitDownPrice\": null,\r\r\n \"limitUpPrice\": null,\r\r\n \"bankruptLimitDownPrice\": null,\r\r\n \"bankruptLimitUpPrice\": null,\r\r\n \"prevTotalVolume\": 15128735716,\r\r\n \"totalVolume\": 15129304596,\r\r\n \"volume24h\": 288268049,\r\r\n \"prevTotalTurnover\": 5709724915753,\r\r\n \"totalTurnover\": 5709934517131,\r\r\n \"turnover\": 209601378,\r\r\n \"turnover24h\": 107140555974,\r\r\n \"homeNotional24h\": 288268049,\r\r\n \"foreignNotional24h\": 1071.4055597400004,\r\r\n \"prevPrice24h\": 3.77e-06,\r\r\n \"vwap\": 3.72e-06,\r\r\n \"lastPriceProtected\": 3.69e-06,\r\r\n \"lastTickDirection\": \"ZeroPlusTick\",\r\r\n \"lastChangePcnt\": -0.0212,\r\r\n \"midPrice\": 3.685e-06,\r\r\n \"impactBidPrice\": 3.68e-06,\r\r\n \"impactMidPrice\": 3.685e-06,\r\r\n \"impactAskPrice\": 3.69e-06,\r\r\n \"hasLiquidity\": true,\r\r\n \"openInterest\": 316012128,\r\r\n \"openValue\": 116292463104,\r\r\n \"fairMethod\": \"ImpactMidPrice\",\r\r\n \"fairBasisRate\": 0.1,\r\r\n \"fairBasis\": 7e-08,\r\r\n \"fairPrice\": 3.68e-06,\r\r\n \"markMethod\": \"FairPrice\",\r\r\n \"markPrice\": 3.68e-06,\r\r\n \"indicativeTaxRate\": 0,\r\r\n \"indicativeSettlePrice\": 3.61e-06,\r\r\n \"optionUnderlyingPrice\": null,\r\r\n \"settledPrice\": null,\r\r\n \"timestamp\": \"2018-10-23T08:33:01.866Z\",\r\r\n \"high\": 3.79e-06,\r\r\n \"low\": 3.64e-06,\r\r\n \"close\": 3.69e-06,\r\r\n \"preclose\": 3.77e-06,\r\r\n \"bid\": 3.68e-06,\r\r\n \"ask\": 3.69e-06,\r\r\n \"base_volume\": 568880,\r\r\n \"sys_time\": \"2018-10-23 16:33:04\",\r\r\n \"date\": \"20181023\"\r\r\n },]\r\r\n }\r\r\n ]\r\r\n \r\r\n ### Depth: /api/depth\r\r\n \u53c2\u6570\uff1a\r\r\n exchange: \u4ea4\u6613\u6240 str \r\r\n symbol: \u4ea4\u6613\u5bf9\uff0c\u53ef\u4ee5\u591a\u4e2a\uff0c\u4ee5\u9017\u53f7\u5206\u9694 str\r\r\n limit: \u6761\u6570,\u9ed8\u8ba4100\u6761 str\r\r\n format: \u8fd4\u56de\u6570\u636e\u683c\u5f0f, \u9ed8\u8ba4API\u683c\u5f0f\uff0c \uff08json: json\u683c\u5f0f\uff0c api: api\u683c\u5f0f\uff09 str\r\r\n \r\r\n http://52.194.88.72:8002/api/depth?exchange=binance&symbol=ADABTC&limit=10\r\r\n [\r\r\n {\r\r\n \"binance_ADABTC_depth\": [\r\r\n {\r\r\n \"_id\": \"95474933\",\r\r\n \"last_ID\": 95474933,\r\r\n \"bids\": [\r\r\n [\r\r\n 1.004e-05,\r\r\n 1.004e-05\r\r\n ],\r\r\n [\r\r\n 1.003e-05,\r\r\n 1.003e-05\r\r\n ],\r\r\n [\r\r\n 1.002e-05,\r\r\n 1.002e-05\r\r\n ],\r\r\n [\r\r\n 1.001e-05,\r\r\n 1.001e-05\r\r\n ],\r\r\n [\r\r\n 1e-05,\r\r\n 1e-05\r\r\n ],\r\r\n [\r\r\n 9.99e-06,\r\r\n 9.99e-06\r\r\n ],\r\r\n [\r\r\n 9.98e-06,\r\r\n 9.98e-06\r\r\n ],\r\r\n [\r\r\n 9.97e-06,\r\r\n 9.97e-06\r\r\n ],\r\r\n [\r\r\n 9.96e-06,\r\r\n 9.96e-06\r\r\n ],\r\r\n [\r\r\n 9.95e-06,\r\r\n 9.95e-06\r\r\n ],\r\r\n [\r\r\n 9.94e-06,\r\r\n 9.94e-06\r\r\n ],\r\r\n [\r\r\n 9.93e-06,\r\r\n 9.93e-06\r\r\n ],\r\r\n [\r\r\n 9.92e-06,\r\r\n 9.92e-06\r\r\n ],\r\r\n [\r\r\n 9.91e-06,\r\r\n 9.91e-06\r\r\n ],\r\r\n [\r\r\n 9.9e-06,\r\r\n 9.9e-06\r\r\n ],\r\r\n [\r\r\n 9.89e-06,\r\r\n 9.89e-06\r\r\n ],\r\r\n [\r\r\n 9.88e-06,\r\r\n 9.88e-06\r\r\n ],\r\r\n [\r\r\n 9.87e-06,\r\r\n 9.87e-06\r\r\n ],\r\r\n [\r\r\n 9.86e-06,\r\r\n 9.86e-06\r\r\n ],\r\r\n [\r\r\n 9.85e-06,\r\r\n 9.85e-06\r\r\n ]\r\r\n ],\r\r\n \"asks\": [\r\r\n [\r\r\n 1.006e-05,\r\r\n 1.006e-05\r\r\n ],\r\r\n [\r\r\n 1.007e-05,\r\r\n 1.007e-05\r\r\n ],\r\r\n [\r\r\n 1.008e-05,\r\r\n 1.008e-05\r\r\n ],\r\r\n [\r\r\n 1.009e-05,\r\r\n 1.009e-05\r\r\n ],\r\r\n [\r\r\n 1.01e-05,\r\r\n 1.01e-05\r\r\n ],\r\r\n [\r\r\n 1.011e-05,\r\r\n 1.011e-05\r\r\n ],\r\r\n [\r\r\n 1.012e-05,\r\r\n 1.012e-05\r\r\n ],\r\r\n [\r\r\n 1.013e-05,\r\r\n 1.013e-05\r\r\n ],\r\r\n [\r\r\n 1.014e-05,\r\r\n 1.014e-05\r\r\n ],\r\r\n [\r\r\n 1.015e-05,\r\r\n 1.015e-05\r\r\n ],\r\r\n [\r\r\n 1.016e-05,\r\r\n 1.016e-05\r\r\n ],\r\r\n [\r\r\n 1.017e-05,\r\r\n 1.017e-05\r\r\n ],\r\r\n [\r\r\n 1.018e-05,\r\r\n 1.018e-05\r\r\n ],\r\r\n [\r\r\n 1.019e-05,\r\r\n 1.019e-05\r\r\n ],\r\r\n [\r\r\n 1.02e-05,\r\r\n 1.02e-05\r\r\n ],\r\r\n [\r\r\n 1.021e-05,\r\r\n 1.021e-05\r\r\n ],\r\r\n [\r\r\n 1.022e-05,\r\r\n 1.022e-05\r\r\n ],\r\r\n [\r\r\n 1.023e-05,\r\r\n 1.023e-05\r\r\n ],\r\r\n [\r\r\n 1.024e-05,\r\r\n 1.024e-05\r\r\n ],\r\r\n [\r\r\n 1.025e-05,\r\r\n 1.025e-05\r\r\n ]\r\r\n ],\r\r\n \"date\": \"20180918\",\r\r\n \"sys_time\": \"2018-09-18 09:09:45\"\r\r\n },]\r\r\n }\r\r\n ]\r\r\n \r\r\n \r\r\n ### Order: /api/order\r\r\n \u53c2\u6570\uff1a\r\r\n exchange: \u4ea4\u6613\u6240 str \r\r\n symbol: \u4ea4\u6613\u5bf9\uff0c\u53ef\u4ee5\u591a\u4e2a\uff0c\u4ee5\u9017\u53f7\u5206\u9694 str\r\r\n limit: \u6761\u6570,\u9ed8\u8ba4100\u6761 str\r\r\n format: \u8fd4\u56de\u6570\u636e\u683c\u5f0f, \u9ed8\u8ba4API\u683c\u5f0f\uff0c \uff08json: json\u683c\u5f0f\uff0c api: api\u683c\u5f0f\uff09 str\r\r\n http://52.194.88.72:8002/api/order?exchange=binance&symbol=ADABTC&limit=10\r\r\n [\r\r\n {\r\r\n \"binance_ADABTC_order\": [\r\r\n {\r\r\n \"_id\": \"1537232981738\",\r\r\n \"time_stamp\": 1537232981738,\r\r\n \"first_ID\": \"95474920\",\r\r\n \"last_ID\": \"95474920\",\r\r\n \"bids\": [],\r\r\n \"asks\": [\r\r\n [\r\r\n 1.055e-05,\r\r\n 1.055e-05\r\r\n ]\r\r\n ],\r\r\n \"exchange_time\": \"2018-09-18 01:09:41.000000\",\r\r\n \"date\": \"20180918\",\r\r\n \"sys_time\": \"2018-09-18 09:09:41\"\r\r\n },]\r\r\n }\r\r\n ]\r\r\n \r\r\n \r\r\n ### Trade: /api/trade\r\r\n \u53c2\u6570\uff1a\r\r\n exchange: \u4ea4\u6613\u6240 str \r\r\n symbol: \u4ea4\u6613\u5bf9\uff0c\u53ef\u4ee5\u591a\u4e2a\uff0c\u4ee5\u9017\u53f7\u5206\u9694 str\r\r\n limit: \u6761\u6570,\u9ed8\u8ba4100\u6761 str\r\r\n format: \u8fd4\u56de\u6570\u636e\u683c\u5f0f, \u9ed8\u8ba4API\u683c\u5f0f\uff0c \uff08json: json\u683c\u5f0f\uff0c api: api\u683c\u5f0f\uff09 str\r\r\n http://52.194.88.72:8002/api/trade?exchange=binance&symbol=ADABTC&limit=10\r\r\n [\r\r\n {\r\r\n \"binance_ADABTC_trade\": [\r\r\n {\r\r\n \"_id\": \"14793414\",\r\r\n \"time_stamp\": 1537232982570,\r\r\n \"order\": \"null\",\r\r\n \"type\": \"null\",\r\r\n \"side\": \"buy\",\r\r\n \"taker_or_maker\": \"null\",\r\r\n \"price\": 1.006e-05,\r\r\n \"amount\": 6.0,\r\r\n \"cost\": 6.036e-05,\r\r\n \"fee_cost\": 0.0,\r\r\n \"fee_currency\": \"null\",\r\r\n \"fee_rate\": 0.0,\r\r\n \"exchange_time\": \"2018-09-18 01:09:42.000000\",\r\r\n \"date\": \"20180918\",\r\r\n \"sys_time\": \"2018-09-18 09:09:42\"\r\r\n },]\r\r\n }\r\r\n ]\r\r\n \r\r\n \r\r\n ## Ccwt_client: ccwt_web\u5ba2\u6237\u7aef:\r\r\n \u4e0b\u8f7dccwt_client\u5305\uff1apip install ccwt_client\uff0c\u4e0b\u8f7d\u8fc7\u7684\u53ef\u8fdb\u884c\u66f4\u65b0 pip install ccwt_client -U\r\r\n \r\r\n ### Ccwt_client.core.py\r\r\n Cli.tieker(**kwargs):\r\r\n from ccwt_client.core import cli\r\r\n params = {\r\r\n 'exchange': 'bitmex', 'symbol': 'XBTUSD', 'limit': '1'\r\r\n }\r\r\n res = cli.ticker(**params)\r\r\n print(res)\r\r\n [{'bitmex_XBTUSD_ticker': [{'_id': '2018-10-23T08:20:16.103Z', 'symbol': 'XBTUSD', 'rootSymbol': 'XBT', 'state': 'Open', 'typ': 'FFWCSX', 'listing': '2016-05-13T12:00:00.000Z', 'front': '2016-05-13T12:00:00.000Z', 'expiry': None, 'settle': None, 'relistInterval': None, 'inverseLeg': '', 'sellLeg': '', 'buyLeg': '', 'optionStrikePcnt': None, 'optionStrikeRound': None, 'optionStrikePrice': None, 'optionMultiplier': None, 'positionCurrency': 'USD', 'underlying': 'XBT', 'quoteCurrency': 'USD', 'underlyingSymbol': 'XBT=', 'reference': 'BMEX', 'referenceSymbol': '.BXBT', 'calcInterval': None, 'publishInterval': None, 'publishTime': None, 'maxOrderQty': 10000000, 'maxPrice': 1000000, 'lotSize': 1, 'tickSize': 0.5, 'multiplier': -100000000, 'settlCurrency': 'XBt', 'underlyingToPositionMultiplier': None, 'underlyingToSettleMultiplier': -100000000, 'quoteToSettleMultiplier': None, 'isQuanto': False, 'isInverse': True, 'initMargin': 0.01, 'maintMargin': 0.005, 'riskLimit': 20000000000, 'riskStep': 10000000000, 'limit': None, 'capped': False, 'taxed': True, 'deleverage': True, 'makerFee': -0.00025, 'takerFee': 0.00075, 'settlementFee': 0, 'insuranceFee': 0, 'fundingBaseSymbol': '.XBTBON8H', 'fundingQuoteSymbol': '.USDBON8H', 'fundingPremiumSymbol': '.XBTUSDPI8H', 'fundingTimestamp': '2018-10-23T12:00:00.000Z', 'fundingInterval': '2000-01-01T08:00:00.000Z', 'fundingRate': 0.0001, 'indicativeFundingRate': 0.0001, 'rebalanceTimestamp': None, 'rebalanceInterval': None, 'openingTimestamp': '2018-10-23T08:00:00.000Z', 'closingTimestamp': '2018-10-23T09:00:00.000Z', 'sessionInterval': '2000-01-01T01:00:00.000Z', 'limitDownPrice': None, 'limitUpPrice': None, 'bankruptLimitDownPrice': None, 'bankruptLimitUpPrice': None, 'prevTotalVolume': 866877370056, 'totalVolume': 866879525586, 'volume24h': 584437921, 'prevTotalTurnover': 11862857877788048, 'totalTurnover': 11862891578522378, 'turnover': 33700734329, 'turnover24h': 9131853536643, 'homeNotional24h': 91318.53536643005, 'foreignNotional24h': 584437921, 'prevPrice24h': 6403, 'vwap': 6400, 'lastPriceProtected': 6396.3157, 'lastTickDirection': 'ZeroPlusTick', 'lastChangePcnt': -0.001, 'midPrice': 6396.25, 'impactBidPrice': 6395.9066, 'impactMidPrice': 6396, 'impactAskPrice': 6396.3157, 'hasLiquidity': True, 'openInterest': 763308087, 'openValue': 11930505399810, 'fairMethod': 'FundingRate', 'fairBasisRate': 0.1095, 'fairBasis': 0.29, 'fairPrice': 6397.95, 'markMethod': 'FairPrice', 'markPrice': 6397.95, 'indicativeTaxRate': 0, 'indicativeSettlePrice': 6397.66, 'optionUnderlyingPrice': None, 'settledPrice': None, 'timestamp': '2018-10-23T08:20:16.103Z', 'high': 6423, 'low': 6369, 'close': 6396.5, 'preclose': 6399.85, 'bid': 6396, 'ask': 6396.5, 'base_volume': 2155330, 'sys_time': '2018-10-23 16:20:19', 'date': '20181023', 'volume': 2155530}], 'cached': False}]\r\r\n \r\r\n ### Cli.kline(**kwargs):\r\r\n \r\r\n from ccwt_client.core import cli\r\r\n params = {\r\r\n 'exchange': 'bitmex', 'symbol': 'XBTUSD', 'limit': '1'\r\r\n }\r\r\n res = cli.kline(**params)\r\r\n print(res)\r\r\n [{'bitmex_XBTUSD_kline_1m': [{'_id': '1540369140.0', 'close': 6437.5, 'open': 6438.0, 'count': 13, 'turnover': 776697187, 'sys_time': '2018-10-24 08:19:15', 'time_stamp': '2018-10-24T08:19:00', 'low': 6437.5, 'date': 20181024, 'foreign_notional': None, 'high': 6438.0, 'last_size': 556, 'exchange_time': '2018-10-24 08:19:00.000000', 'volume': 50003.0, 'vwap': 6437.9064, 'home_notional': None}], 'cached': False}]\r\r\n \r\r\n \r\r\n ### Cli.depth(**kwargs):\r\r\n from ccwt_client.core import cli\r\r\n params = {\r\r\n 'exchange': 'binance', 'symbol': 'ZILBTC', 'limit': '1'\r\r\n }\r\r\n res = cli.depth(**params)\r\r\n print(res)\r\r\n [{'binance_ZILBTC_depth': [{'_id': '53744627', 'last_ID': 53744627, 'bids': [[4.97e-06, 4.97e-06], [4.95e-06, 4.95e-06], [4.94e-06, 4.94e-06], [4.93e-06, 4.93e-06], [4.92e-06, 4.92e-06], [4.91e-06, 4.91e-06], [4.9e-06, 4.9e-06], [4.89e-06, 4.89e-06], [4.88e-06, 4.88e-06], [4.87e-06, 4.87e-06], [4.86e-06, 4.86e-06], [4.85e-06, 4.85e-06], [4.84e-06, 4.84e-06], [4.83e-06, 4.83e-06], [4.82e-06, 4.82e-06], [4.81e-06, 4.81e-06], [4.8e-06, 4.8e-06], [4.79e-06, 4.79e-06], [4.78e-06, 4.78e-06], [4.77e-06, 4.77e-06]], 'asks': [[4.98e-06, 4.98e-06], [4.99e-06, 4.99e-06], [5e-06, 5e-06], [5.01e-06, 5.01e-06], [5.02e-06, 5.02e-06], [5.03e-06, 5.03e-06], [5.04e-06, 5.04e-06], [5.05e-06, 5.05e-06], [5.06e-06, 5.06e-06], [5.07e-06, 5.07e-06], [5.08e-06, 5.08e-06], [5.09e-06, 5.09e-06], [5.1e-06, 5.1e-06], [5.11e-06, 5.11e-06], [5.12e-06, 5.12e-06], [5.13e-06, 5.13e-06], [5.14e-06, 5.14e-06], [5.15e-06, 5.15e-06], [5.16e-06, 5.16e-06], [5.17e-06, 5.17e-06]], 'date': '20180918', 'sys_time': '2018-09-18 09:09:44'}], 'cached': False}]\r\r\n \r\r\n ### Cli.order(**kwargs):\r\r\n from ccwt_client.core import cli\r\r\n params = {\r\r\n 'exchange': 'binance', 'symbol': 'ZILBTC', 'limit': '1'\r\r\n }\r\r\n res = cli.order(**params)\r\r\n print(res)\r\r\n [{'binance_ZILBTC_order': [{'_id': '1537232981739', 'time_stamp': 1537232981739, 'first_ID': '53744625', 'last_ID': '53744625', 'bids': [[4.91e-06, 4.91e-06]], 'asks': [], 'exchange_time': '2018-09-18 01:09:41.000000', 'date': '20180918', 'sys_time': '2018-09-18 09:09:42'}], 'cached': False}]\r\r\n \r\r\n ### Cli.trade(**kwargs):\r\r\n from ccwt_client.core import cli\r\r\n params = {\r\r\n 'exchange': 'binance', 'symbol': 'ZILBTC', 'limit': '1'\r\r\n }\r\r\n res = cli.trade(**params)\r\r\n print(res)\r\r\n [{'binance_ZILBTC_trade': [{'_id': '5014013', 'time_stamp': 1537232986458, 'order': 'null', 'type': 'null', 'side': 'buy', 'taker_or_maker': 'null', 'price': 4.98e-06, 'amount': 4254.0, 'cost': 0.02118492, 'fee_cost': 0.0, 'fee_currency': 'null', 'fee_rate': 0.0, 'exchange_time': '2018-09-18 01:09:46.000000', 'date': '20180918', 'sys_time': '2018-09-18 09:09:46'}], 'cached': False}]\r\r\n \r\r\n \r\r\n ## Ccwt_client.core_feed.py:\r\r\n \u6570\u636e\u683c\u5f0f\u652f\u6301pyalgotrade\u6846\u67b6\r\r\n feed = Feed(bar.Frequency.SECOND)\r\r\n \u201c\u201d\u201d\r\r\n SECOND = 1\r\r\n MINUTE = 60\r\r\n HOUR = 60*60\r\r\n DAY = 24*60*60\r\r\n WEEK = 24*60*60*7\r\r\n MONTH = 24*60*60*31\r\r\n \u201c\u201d\u201d\r\r\n \r\r\n feed.loadBars(\"bitmex_XBTUSD\") \r\r\n \r\r\n \u6570\u636e\u683c\u5f0f\uff1a\r\r\n __slots__ = (\r\r\n '__dateTime',\r\r\n '__open',\r\r\n '__close',\r\r\n '__high',\r\r\n '__low',\r\r\n '__volume',\r\r\n '__adjClose',\r\r\n '__frequency',\r\r\n '__useAdjustedValue',\r\r\n '__extra',\r\r\n )\r\r\n \r\r\n [[datetime.datetime(2018, 10, 23, 8, 20, 58, 136000), 6399.85, 6423, 6369, 6396, 2155330, None, 1], [datetime.datetime(2018, 10, 23, 8, 20, 16, 103000), 6399.85, 6423, 6369, 6396.5, 2155330, None, 1], [datetime.datetime(2018, 10, 23, 7, 19, 9, 591000), 6399.85, 6423, 6369, 6401.5, 6151444, None, 1],]\r\r\n \r\r\n \r\r\n \r\nPlatform: UNKNOWN\r\nClassifier: License :: OSI Approved :: Apache Software License\r\nClassifier: Development Status :: 5 - Production/Stable\r\nClassifier: Intended Audience :: Developers\r\nClassifier: Programming Language :: Python\r\nClassifier: Programming Language :: Python :: 2.7\r\nClassifier: Programming Language :: Python :: 3.6\r\nClassifier: Topic :: Software Development :: Libraries :: Python Modules\r\nDescription-Content-Type: text/markdown\r\n", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/nigelliyang/ccwt_client", "keywords": "", "license": "Apache v2.0 License", "maintainer": "", "maintainer_email": "", "name": "ccwt-client", "package_url": "https://pypi.org/project/ccwt-client/", "platform": "", "project_url": "https://pypi.org/project/ccwt-client/", "project_urls": { "Homepage": "https://github.com/nigelliyang/ccwt_client" }, "release_url": "https://pypi.org/project/ccwt-client/1.0.3/", "requires_dist": null, "requires_python": "", "summary": "ccwt server client", "version": "1.0.3" }, "last_serial": 4760072, "releases": { "0.5": [ { "comment_text": "", "digests": { "md5": "a973ecdc955b82aecd681edf2965da33", "sha256": "37ea7a31501aa8552411c62f701fd95660e1f3b8820dae65515ea3f2bbba5618" }, "downloads": -1, "filename": "ccwt_client-0.5.tar.gz", "has_sig": false, "md5_digest": "a973ecdc955b82aecd681edf2965da33", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 13274, "upload_time": "2018-11-01T11:53:30", "url": "https://files.pythonhosted.org/packages/37/c7/279fa5aa6b5c983cd14ae1c2e36dc3522889e536f8abd138be3b0a62fab8/ccwt_client-0.5.tar.gz" } ], "0.6": [ { "comment_text": "", "digests": { "md5": "229b820496cc56d747a4119a9a9c98ee", "sha256": "f2a1536bfdc278b8fcac44c4d88eb6ae18ae2b125e5d297c1e3b7d2fae8d6336" }, "downloads": -1, "filename": "ccwt_client-0.6.tar.gz", "has_sig": false, "md5_digest": "229b820496cc56d747a4119a9a9c98ee", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 11776, "upload_time": "2018-11-12T13:26:18", "url": "https://files.pythonhosted.org/packages/5f/92/867b4fe48e4dc91275d33ff5f39d4c91ef59817b208f05084d179725f8a1/ccwt_client-0.6.tar.gz" } ], "0.7": [ { "comment_text": "", "digests": { "md5": "5f00f70b29670ce300e71655ad78b96a", "sha256": "307fd584762029bf258a06d170d0e114f201bec91ee671ebdb77bc56e9061cff" }, "downloads": -1, "filename": "ccwt_client-0.7.tar.gz", "has_sig": false, "md5_digest": "5f00f70b29670ce300e71655ad78b96a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 11790, "upload_time": "2018-11-19T10:27:40", "url": "https://files.pythonhosted.org/packages/ab/5d/5f93da4f9e676e0761ec179b53e9b25c34ac2984bf3502192b6d1fdcbc8f/ccwt_client-0.7.tar.gz" } ], "0.8": [ { "comment_text": "", "digests": { "md5": "3bd4f805bbdcfec5a2ff030ad1fca47f", "sha256": "f4d2abde11205af00f965d83d9b4b8178d1bef2cde54d817b42802c46aa4b623" }, "downloads": -1, "filename": "ccwt_client-0.8.tar.gz", "has_sig": false, "md5_digest": "3bd4f805bbdcfec5a2ff030ad1fca47f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 12541, "upload_time": "2018-12-16T14:22:29", "url": "https://files.pythonhosted.org/packages/69/aa/de22d23b227d1eb0d99c634a19c5bc0ee26f8845f996e08de1d3861e3fcb/ccwt_client-0.8.tar.gz" } ], "0.9": [ { "comment_text": "", "digests": { "md5": "f37d726a603adc5a27377a64d4d0a096", "sha256": "8136f525b993f1a614bf76d3b68cf245a092ec2c4d2725d707f83d710fce1653" }, "downloads": -1, "filename": "ccwt_client-0.9.tar.gz", "has_sig": false, "md5_digest": "f37d726a603adc5a27377a64d4d0a096", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 17909, "upload_time": "2018-12-27T15:47:08", "url": "https://files.pythonhosted.org/packages/a8/69/6a84446b81ea3e326a56e6d9d0566e9b7ca47c9c8a84c9e6550ca1fa0f0b/ccwt_client-0.9.tar.gz" } ], "1.0": [ { "comment_text": "", "digests": { "md5": "2ec113dde401f774e327f69aac0e11ce", "sha256": "52c8db596bf723911b0b0dc6ed358e1522d9a1bbbe11b9a1ac24c64a712e654a" }, "downloads": -1, "filename": "ccwt_client-1.0.tar.gz", "has_sig": false, "md5_digest": "2ec113dde401f774e327f69aac0e11ce", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 17971, "upload_time": "2019-01-18T10:52:25", "url": "https://files.pythonhosted.org/packages/18/8c/df16b010cfbd6e01091f460a42e92abc1114a2e6c405234291af8c3c4c36/ccwt_client-1.0.tar.gz" } ], "1.0.1": [ { "comment_text": "", "digests": { "md5": "53bcca36d6b1f21a8ee523dc4ba8745e", "sha256": "9225dd58d39d0a0e8219f191cfbacc118ec5ee8c951c91159b6fecdc094bd8fa" }, "downloads": -1, "filename": "ccwt_client-1.0.1.tar.gz", "has_sig": false, "md5_digest": "53bcca36d6b1f21a8ee523dc4ba8745e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 17989, "upload_time": "2019-01-30T14:38:08", "url": "https://files.pythonhosted.org/packages/94/a6/6c59185b98623094566f78dd463bd91a38e11cd80c37e6b075cfbde9c938/ccwt_client-1.0.1.tar.gz" } ], "1.0.3": [ { "comment_text": "", "digests": { "md5": "0ac71dc3df3a8e39b3c88f340b9ae3ec", "sha256": "a9aeb706943b9b444cdd58f7306addf2a8d409da7d2e501949dcb4e74da5bc49" }, "downloads": -1, "filename": "ccwt_client-1.0.3.tar.gz", "has_sig": false, "md5_digest": "0ac71dc3df3a8e39b3c88f340b9ae3ec", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 17986, "upload_time": "2019-01-30T14:52:53", "url": "https://files.pythonhosted.org/packages/bb/ce/029874ee4f7bbc23952f29d1db39bbd02debd0cab6ce67400cc0b48f1c43/ccwt_client-1.0.3.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "0ac71dc3df3a8e39b3c88f340b9ae3ec", "sha256": "a9aeb706943b9b444cdd58f7306addf2a8d409da7d2e501949dcb4e74da5bc49" }, "downloads": -1, "filename": "ccwt_client-1.0.3.tar.gz", "has_sig": false, "md5_digest": "0ac71dc3df3a8e39b3c88f340b9ae3ec", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 17986, "upload_time": "2019-01-30T14:52:53", "url": "https://files.pythonhosted.org/packages/bb/ce/029874ee4f7bbc23952f29d1db39bbd02debd0cab6ce67400cc0b48f1c43/ccwt_client-1.0.3.tar.gz" } ] }