lago-ruby-client 0.43.0.pre.beta → 0.47.0.pre.beta

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
  SHA256:
3
- metadata.gz: e66776c9abf23db6d6d19179b54d373b1567e152f71617dd4574f76da7c652a1
4
- data.tar.gz: 44adeded21ca193a9466bd6f1de79bb3441381183ab22738416cf1b8628129c8
3
+ metadata.gz: 1cdb77cda34cce9253e6346276881fdaadeacfdd35d53ab7989ec9429bb66c16
4
+ data.tar.gz: 3f090677a5bda43b49803fa806bc125a32548884911b7d83181063096c0cc844
5
5
  SHA512:
6
- metadata.gz: 204e2cf5a31c3d2736351b6a0f2f518389faef6f39a61d4ec107cd1ee65f54f371626779ce8baeb168d8d757daf9ae43df57871158ff5f8340ab688b6a36116c
7
- data.tar.gz: e4326b2d4d76e2b1eaff45424f72ec75fceb620c1f9a7916dbe2b07c20b0635cd60ea22fa0b74a6cba58893f4261f03e153d9d4c45428c64f05a2ccdf84ba07d
6
+ metadata.gz: 22bb546383f575dba754bcbeaf62f7a09a5eb2a01adcc4417226ae5bcbb0d03e6fe6568439444eba6cfffafe0c99c2dc051aff5b5fb0c631c9be9d34922280c3
7
+ data.tar.gz: b9a13ab8d440f7baf0be609b7442a01bfe9cf6ab5a64e24c3afece9aecbb84ed8191c5e5a4caf3f2342cb1a3ce05c61c17233f631c67a979281082f1e1d633b2
@@ -47,10 +47,6 @@ module Lago
47
47
  Lago::Api::Resources::AppliedCoupon.new(self)
48
48
  end
49
49
 
50
- def applied_add_ons
51
- Lago::Api::Resources::AppliedAddOn.new(self)
52
- end
53
-
54
50
  def billable_metrics
55
51
  Lago::Api::Resources::BillableMetric.new(self)
56
52
  end
@@ -19,7 +19,8 @@ module Lago
19
19
  code: params[:code],
20
20
  description: params[:description],
21
21
  amount_cents: params[:amount_cents],
22
- amount_currency: params[:amount_currency]
22
+ amount_currency: params[:amount_currency],
23
+ tax_codes: params[:tax_codes],
23
24
  }.compact
24
25
  }
25
26
  end
@@ -90,7 +90,7 @@ module Lago
90
90
  processed_fees = []
91
91
 
92
92
  fees.each do |f|
93
- result = (f || {}).slice(:add_on_code, :unit_amount_cents, :units, :description)
93
+ result = (f || {}).slice(:add_on_code, :unit_amount_cents, :units, :description, :tax_codes)
94
94
 
95
95
  processed_fees << result unless result.empty?
96
96
  end
@@ -36,7 +36,7 @@ module Lago
36
36
  def whitelist_charges(charges)
37
37
  processed_charges = []
38
38
 
39
- charges.each do |c|
39
+ charges&.each do |c|
40
40
  result = (c || {}).slice(
41
41
  :id,
42
42
  :billable_metric_id,
data/lib/lago/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Lago
4
- VERSION = '0.43.0-beta'
4
+ VERSION = '0.47.0-beta'
5
5
  end
@@ -13,7 +13,6 @@ require 'lago/api/http_error'
13
13
 
14
14
  require 'lago/api/resources/base'
15
15
  require 'lago/api/resources/add_on'
16
- require 'lago/api/resources/applied_add_on'
17
16
  require 'lago/api/resources/applied_coupon'
18
17
  require 'lago/api/resources/billable_metric'
19
18
  require 'lago/api/resources/coupon'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lago-ruby-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.43.0.pre.beta
4
+ version: 0.47.0.pre.beta
5
5
  platform: ruby
6
6
  authors:
7
7
  - Lovro Colic
8
- autorequire:
8
+ autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2023-08-10 00:00:00.000000000 Z
11
+ date: 2023-09-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jwt
@@ -122,7 +122,7 @@ dependencies:
122
122
  - - ">="
123
123
  - !ruby/object:Gem::Version
124
124
  version: '0'
125
- description:
125
+ description:
126
126
  email:
127
127
  - lovro@getlago.com
128
128
  executables: []
@@ -134,7 +134,6 @@ files:
134
134
  - lib/lago/api/connection.rb
135
135
  - lib/lago/api/http_error.rb
136
136
  - lib/lago/api/resources/add_on.rb
137
- - lib/lago/api/resources/applied_add_on.rb
138
137
  - lib/lago/api/resources/applied_coupon.rb
139
138
  - lib/lago/api/resources/base.rb
140
139
  - lib/lago/api/resources/billable_metric.rb
@@ -161,7 +160,7 @@ metadata:
161
160
  homepage_uri: https://www.getlago.com/
162
161
  source_code_uri: https://github.com/getlago/lago-ruby-client
163
162
  documentation_uri: https://doc.getlago.com
164
- post_install_message:
163
+ post_install_message:
165
164
  rdoc_options: []
166
165
  require_paths:
167
166
  - lib
@@ -176,8 +175,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
176
175
  - !ruby/object:Gem::Version
177
176
  version: 1.3.1
178
177
  requirements: []
179
- rubygems_version: 3.3.3
180
- signing_key:
178
+ rubygems_version: 3.4.6
179
+ signing_key:
181
180
  specification_version: 4
182
181
  summary: Lago Rest API client
183
182
  test_files: []
@@ -1,28 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module Lago
4
- module Api
5
- module Resources
6
- class AppliedAddOn < Base
7
- def api_resource
8
- 'applied_add_ons'
9
- end
10
-
11
- def root_name
12
- 'applied_add_on'
13
- end
14
-
15
- def whitelist_params(params)
16
- {
17
- root_name => {
18
- external_customer_id: params[:external_customer_id],
19
- add_on_code: params[:add_on_code],
20
- amount_cents: params[:amount_cents],
21
- amount_currency: params[:amount_currency]
22
- }.compact
23
- }
24
- end
25
- end
26
- end
27
- end
28
- end