mondo 0.4.4 → 0.4.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: d7874c919b8e0e24d37bbaf352f9c95ef5a88429
4
- data.tar.gz: 94d23a1fbd5c3def65176130be33931c7c7c5df4
3
+ metadata.gz: a44071b97b0fc8ee7fb8bb871a51d44137123871
4
+ data.tar.gz: 41291a742f922ea9158275b3a96533a12a8df905
5
5
  SHA512:
6
- metadata.gz: 2d6c9253787bb7ca2d7ef3fa8a17d60cd89e453ed15f8ea4d3adf9d81155c3c22aea36cd788e0a49bd281524bc6271be6578f897d964e7c37f2d9d459197bb8e
7
- data.tar.gz: 72746375dd7a41a8eff35b0fa23c88d714d8b6bcd9f0a9b6ef824a6cfc1afffd952071f3dc876077bb8f7bd438782357d97f067b8f4876d02c7c2ef3275a7874
6
+ metadata.gz: 783a7f93c202ce1d75c82ef19954391a970455511b207923d3348edea6a7c647732fce3bdf66d4fe69bc8425d96756d1bf9a073a7e4fefbf38709f7f0554f0cc
7
+ data.tar.gz: 8d2a87abe38ea6fe33f3b69d98ecbd6b111bdbcbbc15082417fc15fcce8e0f62afec3fa883d84686dcc281daa4a69b612e94c626d31fa0e9443d48f23cf2360a
data/CHANGELOG.md CHANGED
@@ -1,3 +1,8 @@
1
+ ## 0.4.5 - Novermber 14, 2015
2
+
3
+ - Add support for balance
4
+
5
+
1
6
  ## 0.4.4 - Novermber 14, 2015
2
7
 
3
8
  - Deeply nested hash support - make Feed Item creation work again
data/README.md CHANGED
@@ -27,6 +27,15 @@ mondo.ping
27
27
  => "pong"
28
28
  ```
29
29
 
30
+ ## Get Balance
31
+
32
+ ```ruby
33
+ mondo.balance
34
+
35
+ => {"balance"=>-7708, "currency"=>"GBP", "spend_today"=>-12708}
36
+ ```
37
+
38
+
30
39
  ## List Transactions
31
40
 
32
41
  ```ruby
data/lib/mondo/client.rb CHANGED
@@ -121,6 +121,12 @@ module Mondo
121
121
  Transaction.new(resp.parsed['transaction'], self)
122
122
  end
123
123
 
124
+ # Returns {"balance"=>-7708, "currency"=>"GBP", "spend_today"=>-12708}
125
+ def balance
126
+ raise ClientError.new("You must provide an account id to see your balance") unless self.account_id
127
+ api_get("balance", account_id: self.account_id).parsed
128
+ end
129
+
124
130
  def create_feed_item(params)
125
131
  FeedItem.new(params, self).save
126
132
  end
data/lib/mondo/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Mondo
2
- VERSION = '0.4.4'.freeze
2
+ VERSION = '0.4.5'.freeze
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mondo
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.4
4
+ version: 0.4.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tom Blomfield