You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# +String+ +client_order_id+:: Optional. If given must be unique within the trading day, including all active orders. If not given, is generated by the server
396
396
# +String+ +type+:: Optional. 'limit', 'market', 'stopLimit', 'stopMarket', 'takeProfitLimit' or 'takeProfitMarket'. Default is 'limit'
# +String+ +time_in_force+:: Optional. 'GTC', 'IOC', 'FOK', 'Day', 'GTD'. Default is 'GTC' if 'limit', 'stopLimit' or 'takeProfitLimit' order, Default is 'FOK' if 'market', 'stopMarket' or 'takeProfitMarket' order
398
398
# +String+ +price+:: Optional. Required for 'limit' and 'stopLimit'. limit price of the order
399
399
# +String+ +stop_price+:: Optional. Required for 'stopLimit' and 'stopMarket' orders. stop price of the order
400
400
# +String+ +expire_time+:: Optional. Required for orders with timeInForce = GDT
# - For an OTOCO order list, the symbol code of orders must be the same for all orders in the list (placing orders in different order books is not supported).
438
438
#
439
439
# = OrderType restrictions
440
-
# - For an AON order list, orders must be Args::OrderType::LIMIT or Args::OrderType::Market
441
-
# - For an OCO order list, orders must be Args::OrderType::LIMIT, Args::OrderType::STOP_LIMIT, Args::OrderType::STOP_MARKET, Args::OrderType::TAKE_PROFIT_LIMIT or Args::OrderType::TAKE_PROFIT_MARKET.
440
+
# - For an AON order list, orders must be 'limit' or 'market'
441
+
# - For an OCO order list, orders must be 'limit', 'stopLimit', 'stopMarket', takeProfitLimit or takeProfitMarket.
442
442
# - An OCO order list cannot include more than one limit order (the same
443
443
# applies to secondary orders in an OTOCO order list).
444
444
# - For OTO order list, there are no order type restrictions.
445
-
# - For an OTOCO order list, the first order must be Args::OrderType::LIMIT, Args::OrderType::MARKET, Args::OrderType::STOP_LIMIT, Args::OrderType::STOP_MARKET, Args::OrderType::TAKE_PROFIT_LIMIT or Args::OrderType::TAKE_PROFIT_MARKET.
445
+
# - For an OTOCO order list, the first order must be 'limit', 'market', 'stopLimit', 'stopMarket', takeProfitLimit or takeProfitMarket.
446
446
# - For an OTOCO order list, the secondary orders have the same restrictions as an OCO order
# +String+ +order_list_id+:: order list identifier. If ommited, it will be generated by the system. Must be equal to the client order id of the first order in the request
453
-
# +String+ +contingency_type+:: order list type. allOrNone, oneCancelOther or oneTriggerOneCancelOther
454
-
# +Array[]+ +orders+:: the list of orders
453
+
# +String+ +contingency_type+:: order list type. 'allOrNone', 'oneCancelOther' or 'oneTriggerOneCancelOther'
454
+
# +Array[]+ +orders+:: the list of orders. aech order in the list has the same parameters of a new spot order
# +Proc+ +result_callback+:: Optional. A +Proc+ called with a boolean value, indicating the success of the subscription
76
74
# +Proc+ +String+ +mode+:: Optional. The type of subscription, Either 'updates' or 'batches'. Update messages arrive after an update. Batch messages arrive at equal intervals after a first update
# +Proc+ +callback+:: Optional. A +Proc+ of two arguments, An exception and a result, called either with the exception or with the result, a boolean value indicating the success of the unsubscription
# +Proc+ +callback+:: A +Proc+ of two arguments, An exception and a result, called either with the exception or with the result, a list of reports for all active spot orders
# +String+ +take_rate+:: Optional. Liquidity taker fee, a fraction of order volume, such as 0.001 (for 0.1% fee). Can only increase the fee. Used for fee markup.
129
125
# +String+ +make_rate+:: Optional. Liquidity provider fee, a fraction of order volume, such as 0.001 (for 0.1% fee). Can only increase the fee. Used for fee markup.
130
126
# +Proc+ +callback+:: Optional. A +Proc+ of two arguments, An exception and a result, called either with the exception or with the result, the report of the created order
# - For an OTOCO order list, the symbol code of orders must be the same for all orders in the list (placing orders in different order books is not supported).
161
156
#
162
157
# = OrderType restrictions
163
-
# - For an AON order list, orders must be OrderType.LIMIT or OrderType.Market
164
-
# - For an OCO order list, orders must be OrderType.LIMIT, OrderType.STOP_LIMIT, OrderType.STOP_MARKET, OrderType.TAKE_PROFIT_LIMIT or OrderType.TAKE_PROFIT_MARKET.
158
+
# - For an AON order list, orders must be 'limit' or 'market'
159
+
# - For an OCO order list, orders must be 'limit', 'stopLimit', 'stopMarket', takeProfitLimit or takeProfitMarket.
165
160
# - An OCO order list cannot include more than one limit order (the same
166
161
# applies to secondary orders in an OTOCO order list).
167
162
# - For OTO order list, there are no order type restrictions.
168
-
# - For an OTOCO order list, the first order must be OrderType.LIMIT, OrderType.MARKET, OrderType.STOP_LIMIT, OrderType.STOP_MARKET, OrderType.TAKE_PROFIT_LIMIT or OrderType.TAKE_PROFIT_MARKET.
163
+
# - For an OTOCO order list, the first order must be 'limit', 'market', 'stopLimit', 'stopMarket', takeProfitLimit or takeProfitMarket.
169
164
# - For an OTOCO order list, the secondary orders have the same restrictions as an OCO order
# +String+ +order_list_id+:: order list identifier. If ommited, it will be generated by the system. Must be equal to the client order id of the first order in the request
176
-
# +String+ +contingency_type+:: order list type. allOrNone, oneCancelOther or oneTriggerOneCancelOther
177
-
# +Array[]+ +orders+:: the list of orders
178
-
# +Proc+ +callback+:: Optional. A +Proc+ of two arguments, An exception and a result, called either with the exception or with the result, a list of reports of the created orders
179
-
171
+
# +String+ +contingency_type+:: order list type. 'allOrNone', 'oneCancelOther' or 'oneTriggerOneCancelOther'
172
+
# +Array[]+ +orders+:: the list of orders. aech order in the list has the same parameters of a new spot order
# +Proc+ +callback+:: A +Proc+ of two arguments, An exception and a result, called either with the exception or with the result, a report of the canceled order
# +String+ +symbol+:: The symbol of the commission rate
276
268
# +Proc+ +callback+:: A +Proc+ of two arguments, An exception and a result, called either with the exception or with the result, a commission for a symbol for the user
Copy file name to clipboardExpand all lines: lib/cryptomarket/websocket/wallet_client.rb
+7-2Lines changed: 7 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -6,13 +6,15 @@
6
6
7
7
moduleCryptomarket
8
8
moduleWebsocket
9
-
# WalletClient connects via websocket to cryptomarket to get wallet information of the user. uses SHA256 as auth method and authenticates automatically.
9
+
# WalletClient connects via websocket to cryptomarket to get wallet information of the user.
10
+
# Uses SHA256 as auth method and authenticates automatically.
10
11
classWalletClient < AuthClient
11
12
# Creates a new client and authenticates it to the server
12
13
# ==== Params
13
14
# +String+ +api_key+:: the user api key
14
15
# +String+ +api_secret+:: the user api secret
15
16
# +Integer+ +window+:: Maximum difference between the creation of the request and the moment of request processing in milliseconds. Max is 60_000. Defaul is 10_000
# +Proc+ +result_callback+:: Optional. A +Proc+ of two arguments, An exception and a result, called either with the exception or with the result, a boolean value, indicating the success of the subscription
0 commit comments