vertpig 0.0.4 → 0.0.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ed1701ab78a33c1926220ffb4ce4e88c99450dd0
4
- data.tar.gz: fa363c8efb249526256529384ffe5c644619b5d0
3
+ metadata.gz: da5640a9b92e8fed891b45d12c9d21e5e1e1a85b
4
+ data.tar.gz: e969a1e1b36b7141f49a0092ffa03b1ce82060b5
5
5
  SHA512:
6
- metadata.gz: 4088c54edf1262ce25ae2212e09e355505e012e767365f951010dc930a859538d065424a2c5ef75808dcd82a22c025b18ee4f8efceeb2640ac84fd09cb804145
7
- data.tar.gz: 137b116380a40b9022f9610764182ac2b3819b5835f9cb20201aef5a7ee303c95288bf4f6eb0bcc671f629a97b8902c1d447913a88f4c5954c2eb72d0296d57f
6
+ metadata.gz: 8104bc5adada7167232c4ce47927f344443598fe7d24680488df30f9e3a105286b88a7a712555b597344a1bee776d71063ca6572679e7aee7b9d927c91d6bed0
7
+ data.tar.gz: 965ee2f7eb3be7e8671a569af27783c8f877913b0afb0082bf89f62cd7ec243209fa2cbad565b756df476e47a77fa1e10887b9a8d2868d17dae26134fab5cb71
@@ -22,10 +22,6 @@ module Vertpig
22
22
  client.get('public/getmarkets').map{|data| new(data) }
23
23
  end
24
24
 
25
- def self.buylimit(market, quantity, rate, type, postonly)
26
- new(market, client.get('/market/buylimit', market: market, quantity: quantity, rate: rate, type: type, postonly: postonly))
27
- end
28
-
29
25
  private
30
26
 
31
27
  def self.client
data/lib/vertpig/order.rb CHANGED
@@ -41,6 +41,28 @@ module Vertpig
41
41
  orders
42
42
  end
43
43
 
44
+ def self.buy(market, amount, price)
45
+ client.get('/market/buylimit', {
46
+ market: market,
47
+ quantity: amount,
48
+ rate: price
49
+ })
50
+ end
51
+
52
+ def self.sell(market, amount, price)
53
+ client.get('/market/selllimit', {
54
+ market: market,
55
+ quantity: amount,
56
+ rate: price
57
+ })
58
+ end
59
+
60
+ def self.cancel(order_id)
61
+ client.get('/market/cancel', {
62
+ uuid: order_id
63
+ })
64
+ end
65
+
44
66
  def self.open
45
67
  client.get('market/getopenorders').map{|data| new(data) }
46
68
  end
@@ -1,3 +1,3 @@
1
1
  module Vertpig
2
- VERSION = "0.0.4"
2
+ VERSION = "0.0.5"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vertpig
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.4
4
+ version: 0.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Vertbase