killbill-client 0.7.1 → 0.7.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- YmM1ZjRkNzgyZTcwMmYyYmZkM2Q0NWI4YjRlZjg4OGIzNjZkNDBhYg==
4
+ MWJjMTIzOWViMDQ3Zjc3YzdhMzI4ZTM5ZTk2YjJiMzkxNmEyM2QzZA==
5
5
  data.tar.gz: !binary |-
6
- ZjM2M2Q1YWRjMmMxN2ZkMTY0N2RhNzUzMmZjNTBkMmY3M2I2Yjk2Nw==
6
+ OWFjNWM2ODg0Nzc2NzdkY2ZlODlmMjk4Y2NlNjMyOTZhYTgxZmUzZA==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- MjMxZDk5NjY3OWM1OTNmOGU1YmI2MzBkODk2ZDM5NWNkNDJkY2I4ZmNkMThl
10
- NGZkN2E2OTIyYWExNWU4NDMxYjQ1OGM1MWQ5OWMxMGVhOThiMTIxYTMzYWE5
11
- ZDA4OTk2ODkzMjI4Mzg2OWE0YjMwYzNkZDY2MzUyNWRkYTM1NGM=
9
+ YzczODUxNjM0NzBiZTBmMjZmMWNhY2ZhYmUyZWQ0ZTllMzIxZGIxNGNlZDM1
10
+ MjFkMDRmMzdlYjhjOTJlODE3NGVmNWFkMzc5NGE1NDA1ZDU1NDAyNzQ2MTEx
11
+ MWU4ZWY3NDg5YjMwNDAxNDg0NWI3NWEzNjZhMjI2Njk3ZDYxN2Y=
12
12
  data.tar.gz: !binary |-
13
- Y2NkNTgxNGM2NDg0MWNkZTQ3NzQzNzdjNDM5ZTY3NDc5MGFkOGJiYmFkZjFk
14
- MDViODA4ODYxZTA1NTQ3ZWUyZjBjZjNjOGVjMThhM2MzZGRiNDYwMDUwY2U3
15
- OTc0YTg2ZTFiZjkzNmIxOGY3YTU4YTdmODA0MDcwN2U3NjFlM2Y=
13
+ ODBjZTdmYzYyY2JlNmJkMGRmNjBlODhhMWNiNDQwZjAyYmNkM2Y3MDMwNWZm
14
+ YjcwMTRlNjFiNzE2ZTE1ZDQzZTk3YTRhY2U0YjNiODg1MjAwNTgzMmY1Yjc5
15
+ ZmU5OGZhMGIzZjJhNWMxNDMzYWRhYjNiZmQzMWUwYzkwZDM0MDY=
@@ -20,6 +20,7 @@ require 'killbill_client/models/security'
20
20
  require 'killbill_client/models/tag'
21
21
  require 'killbill_client/models/tag_definition'
22
22
  require 'killbill_client/models/tenant'
23
+ require 'killbill_client/models/usage'
23
24
  require 'killbill_client/models/account_timeline'
24
25
 
25
26
  module KillBillClient
@@ -0,0 +1,32 @@
1
+ module KillBillClient
2
+ module Model
3
+ class Usage < UsageAttributes
4
+
5
+ has_many :audit_logs, KillBillClient::Model::AuditLog
6
+
7
+
8
+ KILLBILL_API_USAGES_PREFIX = "#{KILLBILL_API_PREFIX}/usages"
9
+
10
+ class << self
11
+ def find_by_subscription_id(subscription_id, options = {})
12
+ get "#{KILLBILL_API_USAGES_PREFIX}/#{subscription_id}",
13
+ {
14
+ },
15
+ options
16
+ end
17
+ end
18
+
19
+ def create(user = nil, reason = nil, comment = nil, options = {})
20
+ self.class.post KILLBILL_API_USAGES_PREFIX,
21
+ to_json,
22
+ {},
23
+ {
24
+ :user => user,
25
+ :reason => reason,
26
+ :comment => comment,
27
+ }.merge(options)
28
+ end
29
+
30
+ end
31
+ end
32
+ end
@@ -2,7 +2,7 @@ module KillBillClient
2
2
  module Version
3
3
  MAJOR = 0
4
4
  MINOR = 7
5
- PATCH = 1
5
+ PATCH = 2
6
6
  PRE = nil
7
7
 
8
8
  VERSION = [MAJOR, MINOR, PATCH, PRE].compact.join('.').freeze
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: killbill-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.1
4
+ version: 0.7.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Killbill core team
@@ -129,6 +129,7 @@ files:
129
129
  - lib/killbill_client/models/tag.rb
130
130
  - lib/killbill_client/models/tag_definition.rb
131
131
  - lib/killbill_client/models/tenant.rb
132
+ - lib/killbill_client/models/usage.rb
132
133
  - lib/killbill_client/utils.rb
133
134
  - lib/killbill_client/version.rb
134
135
  - lib/rails/generators/killbill_client/config_generator.rb