chargebee 2.8.1 → 2.8.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/CHANGELOG.md +61 -0
- data/chargebee.gemspec +4 -2
- data/lib/chargebee.rb +7 -1
- data/lib/chargebee/environment.rb +1 -1
- data/lib/chargebee/models/customer.rb +7 -7
- data/lib/chargebee/models/differential_price.rb +1 -1
- data/lib/chargebee/models/estimate.rb +16 -0
- data/lib/chargebee/models/gift.rb +4 -0
- data/lib/chargebee/models/hosted_page.rb +4 -0
- data/lib/chargebee/models/item.rb +2 -1
- data/lib/chargebee/models/item_price.rb +2 -1
- data/lib/chargebee/models/model.rb +3 -2
- data/lib/chargebee/models/subscription.rb +7 -3
- data/lib/chargebee/models/usage.rb +31 -0
- data/lib/chargebee/rest.rb +1 -1
- data/lib/chargebee/result.rb +6 -1
- metadata +34 -20
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 46990b6f724d8987af5ca53aa8588d2f71e665993a05bd8ea5cdcbddb166d314
|
4
|
+
data.tar.gz: aa12907a95a8738a10d1df728f52a264472184825959c693f7cb0559625b6676
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a3e90c08db516003f2f2a28e7cd27f16ef76915214755dc8eb01a66444e2bf856659b60fab3edb0eb7ab5c22b341e3b7073504905bb74d93a9c30edb6c27000c
|
7
|
+
data.tar.gz: 38ac3c32d1b2f7f56924e8798ba087497cc9487e4356c5ac8a45caf108e83104d9a91459a1202e7ba15a595fbe6eaca60f91785448a0b5291916791119f4154b
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,64 @@
|
|
1
|
+
### v2.8.6 (2021-05-31)
|
2
|
+
* * *
|
3
|
+
* Added support for Ruby 3.0
|
4
|
+
|
5
|
+
### v2.8.5 (2021-02-04)
|
6
|
+
* * *
|
7
|
+
* fixed: missing requires for Product Catalog V2 resources.
|
8
|
+
|
9
|
+
### v2.8.4 (2021-01-20)
|
10
|
+
* * *
|
11
|
+
* Ruby Library-URL encoding Issue - bugfix
|
12
|
+
### v2.8.3 (2021-01-19)
|
13
|
+
* * *
|
14
|
+
##### New resources:
|
15
|
+
* Usages is added. Applicable only for Product Catalog V2
|
16
|
+
|
17
|
+
##### New end points:
|
18
|
+
* hosted_pages#checkout_one-time_payments has been added in hosted_pages resource
|
19
|
+
|
20
|
+
##### New attributes:
|
21
|
+
* auto_close_invoices has been added to customers, subscriptions resources
|
22
|
+
* metered, usage_calculation have been added to items resources
|
23
|
+
* create_pending_invoices, auto_close_invoices have been added to subscriptions resources
|
24
|
+
|
25
|
+
##### New parameters:
|
26
|
+
* auto_close_invoices has been added to the endpoint: customers#create_a_customer, customers#list_customers, customers#update_a_customer
|
27
|
+
* invoice_allocations[invoice_id] has been added to the endpoint: customers#collect_payment_for_customer
|
28
|
+
* coupon_ids has been added to the endpoint: estimates#create_invoice_for_items_estimate. Applicable only for Product Catalog V2
|
29
|
+
* subscription[auto_close_invoices] has been added to the endpoint: exports#export_revenue_recognition_reports, exports#export_deferred_revenue_reports, exports#export_subscriptions
|
30
|
+
* customer[auto_close_invoices] has been added to the endpoint: exports#export_revenue_recognition_reports, exports#export_deferred_revenue_reports, exports#export_customers
|
31
|
+
* item[metered], item[usage_calculation] have been added to the endpoint: exports#export_items. Applicable only for Product Catalog V2
|
32
|
+
* subscription_id has been added to the endpoint: invoices#add_one-time_charge_to_a_pending_invoice, invoices#add_non-recurring_addon_to_a_pending_invoice
|
33
|
+
* subscription_id has been added to the endpoint: invoices#add_a_charge-item_to_a_pending_invoice. Applicable only for Product Catalog V2
|
34
|
+
* metered, usage_calculation have been added to the endpoint: items#create_an_item, items#list_item. Applicable only for Product Catalog V2
|
35
|
+
* create_pending_invoices, auto_close_invoices, first_invoice_pending have been added to the endpoint: subscriptions#create_subscription_for_items, subscriptions#update_subscription_for_items,subscriptions#import_subscription_for_items. Applicable only for Product Catalog V2
|
36
|
+
* create_pending_invoices, auto_close_invoices have been added to the endpoint: subscriptions#list_subscriptions
|
37
|
+
|
38
|
+
### v2.8.2 (2020-12-15)
|
39
|
+
* * *
|
40
|
+
##### New end points:
|
41
|
+
* estimate_for_creating_a_customer_and_subscription, cancel_subscription_for_items_estimate, gift_subscription_estimate_for_items have been added in estimate resource. Applicable only for Product Catalog V2
|
42
|
+
* regenerate_invoice_estimate has been added in estimate resource
|
43
|
+
* create_a_gift_subscription_for_items has been added in gift resource. Applicable only for Product Catalog V2
|
44
|
+
* regenerate_invoice has been added in subscription resource
|
45
|
+
|
46
|
+
##### New attributes:
|
47
|
+
* show_description_in_invoices, show_description_in_quotes have been added to the resource item_prices
|
48
|
+
* tiers[starting_unit_in_decimal], tiers[ending_unit_in_decimal], tiers[price_in_decimal] have been added to the resource differential_prices
|
49
|
+
* show_description_in_invoices, show_description_in_quotes have been added to the resource item_prices. Applicable only for Product Catalog V2
|
50
|
+
|
51
|
+
##### New parameters:
|
52
|
+
* payment_intent[additional_info] has been added to the endpoints customers#create_a_customer, invoices#create_an_invoice, payment_sources#create_using_payment_intent, subscriptions#create_a_subscription, subscriptions#update_a_subscription, subscriptions#create_subscription_for_customer, subscriptions#reactivate_a_subscription, subscriptions#resume_a_subscription
|
53
|
+
* payment_intent[additional_info] has been added to the endpoints gifts#create_a_gift_subscription_for_items, invoices#create_invoice_for_items_and_one-time_charges, subscriptions#create_subscription_for_items, subscriptions#update_subscription_for_items. Applicable only for Product Catalog V2
|
54
|
+
* contract_term[action_at_term_end], contract_term[cancellation_cutoff_period], subscription[contract_term_billing_cycle_on_renewal] has been added to the endpoint estimates#estimate_for_creating_a_subscription. Applicable only for Product Catalog V2
|
55
|
+
* cancel_at, contract_term_cancel_option, cancel_reason_code have been added to the endpoint estimates#cancel_subscription_for_items_estimate
|
56
|
+
* event_based_addons has been added to the endpoint estimates#cancel_subscription_for_items_estimate
|
57
|
+
* redirect_url has been added to the endpoint hosted_pages#accept_a_quote
|
58
|
+
* token_id, retain_payment_source, card, bank_account, payment_method added have been added to the endpoint invoices#create_an_invoice
|
59
|
+
* token_id, retain_payment_source, card, bank_account, payment_method added have been added to the endpoint invoices#create_invoice_for_items_and_one-time_charges. Applicable only for Product Catalog V2
|
60
|
+
* show_description_in_invoices, show_description_in_quotes have been added to the endpoints item_prices#create_an_item_price, item_prices#update_an_item_price. Applicable only for Product Catalog V2
|
61
|
+
|
1
62
|
### v2.8.1 (2020-11-26)
|
2
63
|
* * *
|
3
64
|
##### New resources:
|
data/chargebee.gemspec
CHANGED
@@ -4,8 +4,8 @@ Gem::Specification.new do |s|
|
|
4
4
|
s.rubygems_version = '1.3.5'
|
5
5
|
s.required_ruby_version = '>= 1.9.3'
|
6
6
|
s.name = 'chargebee'
|
7
|
-
s.version = '2.8.
|
8
|
-
s.date = '
|
7
|
+
s.version = '2.8.6'
|
8
|
+
s.date = '2021-06-09'
|
9
9
|
|
10
10
|
s.summary = "Ruby client for Chargebee API."
|
11
11
|
s.description = "Subscription Billing - Simple. Secure. Affordable. More details at www.chargebee.com."
|
@@ -22,6 +22,7 @@ Gem::Specification.new do |s|
|
|
22
22
|
|
23
23
|
s.add_dependency('json_pure', '~> 2.1')
|
24
24
|
s.add_dependency('rest-client', '>= 1.8', '< 3.0')
|
25
|
+
s.add_dependency('cgi', '> 0')
|
25
26
|
|
26
27
|
s.add_development_dependency('rspec', '~> 3.0.0')
|
27
28
|
s.add_development_dependency('mocha')
|
@@ -84,6 +85,7 @@ Gem::Specification.new do |s|
|
|
84
85
|
lib/chargebee/models/token.rb
|
85
86
|
lib/chargebee/models/transaction.rb
|
86
87
|
lib/chargebee/models/unbilled_charge.rb
|
88
|
+
lib/chargebee/models/usage.rb
|
87
89
|
lib/chargebee/models/virtual_bank_account.rb
|
88
90
|
lib/chargebee/request.rb
|
89
91
|
lib/chargebee/rest.rb
|
data/lib/chargebee.rb
CHANGED
@@ -44,10 +44,16 @@ require File.dirname(__FILE__) + '/chargebee/models/quote'
|
|
44
44
|
require File.dirname(__FILE__) + '/chargebee/models/contact.rb'
|
45
45
|
require File.dirname(__FILE__) + '/chargebee/models/hierarchy.rb'
|
46
46
|
require File.dirname(__FILE__) + '/chargebee/models/payment_intent.rb'
|
47
|
+
require File.dirname(__FILE__) + '/chargebee/models/attached_item.rb'
|
48
|
+
require File.dirname(__FILE__) + '/chargebee/models/differential_price.rb'
|
49
|
+
require File.dirname(__FILE__) + '/chargebee/models/item.rb'
|
50
|
+
require File.dirname(__FILE__) + '/chargebee/models/item_family.rb'
|
51
|
+
require File.dirname(__FILE__) + '/chargebee/models/item_price.rb'
|
52
|
+
require File.dirname(__FILE__) + '/chargebee/models/usage.rb'
|
47
53
|
|
48
54
|
module ChargeBee
|
49
55
|
|
50
|
-
VERSION = '2.8.
|
56
|
+
VERSION = '2.8.6'
|
51
57
|
|
52
58
|
@@default_env = nil
|
53
59
|
@@verify_ca_certs = true
|
@@ -37,12 +37,12 @@ module ChargeBee
|
|
37
37
|
:offline_payment_method, :net_term_days, :vat_number_validated_time, :vat_number_status, :allow_direct_debit,
|
38
38
|
:is_location_valid, :created_at, :created_from_ip, :exemption_details, :taxability, :entity_code,
|
39
39
|
:exempt_number, :resource_version, :updated_at, :locale, :billing_date, :billing_date_mode,
|
40
|
-
:billing_day_of_week, :billing_day_of_week_mode, :pii_cleared, :
|
41
|
-
:
|
42
|
-
:
|
43
|
-
:
|
44
|
-
:
|
45
|
-
:parent_account_access, :child_account_access
|
40
|
+
:billing_day_of_week, :billing_day_of_week_mode, :pii_cleared, :auto_close_invoices, :card_status,
|
41
|
+
:fraud_flag, :primary_payment_source_id, :backup_payment_source_id, :billing_address, :referral_urls,
|
42
|
+
:contacts, :payment_method, :invoice_notes, :preferred_currency_code, :promotional_credits,
|
43
|
+
:unbilled_charges, :refundable_credits, :excess_payments, :balances, :meta_data, :deleted, :registered_for_gst,
|
44
|
+
:consolidated_invoicing, :customer_type, :business_customer_without_vat_number, :client_profile_id,
|
45
|
+
:relationship, :use_default_hierarchy_settings, :parent_account_access, :child_account_access
|
46
46
|
|
47
47
|
# OPERATIONS
|
48
48
|
#-----------
|
@@ -107,7 +107,7 @@ module ChargeBee
|
|
107
107
|
Request.send('post', uri_path("customers",id.to_s,"record_excess_payment"), params, env, headers)
|
108
108
|
end
|
109
109
|
|
110
|
-
def self.collect_payment(id, params
|
110
|
+
def self.collect_payment(id, params, env=nil, headers={})
|
111
111
|
Request.send('post', uri_path("customers",id.to_s,"collect_payment"), params, env, headers)
|
112
112
|
end
|
113
113
|
|
@@ -2,7 +2,7 @@ module ChargeBee
|
|
2
2
|
class DifferentialPrice < Model
|
3
3
|
|
4
4
|
class Tier < Model
|
5
|
-
attr_accessor :starting_unit, :ending_unit, :price
|
5
|
+
attr_accessor :starting_unit, :ending_unit, :price, :starting_unit_in_decimal, :ending_unit_in_decimal, :price_in_decimal
|
6
6
|
end
|
7
7
|
|
8
8
|
class ParentPeriod < Model
|
@@ -11,6 +11,10 @@ module ChargeBee
|
|
11
11
|
Request.send('post', uri_path("estimates","create_subscription"), params, env, headers)
|
12
12
|
end
|
13
13
|
|
14
|
+
def self.create_sub_item_estimate(params, env=nil, headers={})
|
15
|
+
Request.send('post', uri_path("estimates","create_subscription_for_items"), params, env, headers)
|
16
|
+
end
|
17
|
+
|
14
18
|
def self.create_sub_for_customer_estimate(id, params, env=nil, headers={})
|
15
19
|
Request.send('get', uri_path("customers",id.to_s,"create_subscription_estimate"), params, env, headers)
|
16
20
|
end
|
@@ -35,6 +39,10 @@ module ChargeBee
|
|
35
39
|
Request.send('post', uri_path("subscriptions",id.to_s,"advance_invoice_estimate"), params, env, headers)
|
36
40
|
end
|
37
41
|
|
42
|
+
def self.regenerate_invoice_estimate(id, params={}, env=nil, headers={})
|
43
|
+
Request.send('post', uri_path("subscriptions",id.to_s,"regenerate_invoice_estimate"), params, env, headers)
|
44
|
+
end
|
45
|
+
|
38
46
|
def self.upcoming_invoices_estimate(id, env=nil, headers={})
|
39
47
|
Request.send('get', uri_path("customers",id.to_s,"upcoming_invoices_estimate"), {}, env, headers)
|
40
48
|
end
|
@@ -47,6 +55,10 @@ module ChargeBee
|
|
47
55
|
Request.send('post', uri_path("subscriptions",id.to_s,"cancel_subscription_estimate"), params, env, headers)
|
48
56
|
end
|
49
57
|
|
58
|
+
def self.cancel_subscription_for_items(id, params={}, env=nil, headers={})
|
59
|
+
Request.send('post', uri_path("subscriptions",id.to_s,"cancel_subscription_for_items_estimate"), params, env, headers)
|
60
|
+
end
|
61
|
+
|
50
62
|
def self.pause_subscription(id, params={}, env=nil, headers={})
|
51
63
|
Request.send('post', uri_path("subscriptions",id.to_s,"pause_subscription_estimate"), params, env, headers)
|
52
64
|
end
|
@@ -59,6 +71,10 @@ module ChargeBee
|
|
59
71
|
Request.send('post', uri_path("estimates","gift_subscription"), params, env, headers)
|
60
72
|
end
|
61
73
|
|
74
|
+
def self.gift_subscription_for_items(params, env=nil, headers={})
|
75
|
+
Request.send('post', uri_path("estimates","gift_subscription_for_items"), params, env, headers)
|
76
|
+
end
|
77
|
+
|
62
78
|
def self.create_invoice(params={}, env=nil, headers={})
|
63
79
|
Request.send('post', uri_path("estimates","create_invoice"), params, env, headers)
|
64
80
|
end
|
@@ -23,6 +23,10 @@ module ChargeBee
|
|
23
23
|
Request.send('post', uri_path("gifts"), params, env, headers)
|
24
24
|
end
|
25
25
|
|
26
|
+
def self.create_for_items(params, env=nil, headers={})
|
27
|
+
Request.send('post', uri_path("gifts","create_for_items"), params, env, headers)
|
28
|
+
end
|
29
|
+
|
26
30
|
def self.retrieve(id, env=nil, headers={})
|
27
31
|
Request.send('get', uri_path("gifts",id.to_s), {}, env, headers)
|
28
32
|
end
|
@@ -22,6 +22,10 @@ module ChargeBee
|
|
22
22
|
Request.send('post', uri_path("hosted_pages","checkout_new"), params, env, headers)
|
23
23
|
end
|
24
24
|
|
25
|
+
def self.checkout_one_time(params={}, env=nil, headers={})
|
26
|
+
Request.send('post', uri_path("hosted_pages","checkout_one_time"), params, env, headers)
|
27
|
+
end
|
28
|
+
|
25
29
|
def self.checkout_new_for_items(params, env=nil, headers={})
|
26
30
|
Request.send('post', uri_path("hosted_pages","checkout_new_for_items"), params, env, headers)
|
27
31
|
end
|
@@ -7,7 +7,8 @@ module ChargeBee
|
|
7
7
|
|
8
8
|
attr_accessor :id, :name, :description, :status, :resource_version, :updated_at, :item_family_id,
|
9
9
|
:type, :is_shippable, :is_giftable, :redirect_url, :enabled_for_checkout, :enabled_in_portal,
|
10
|
-
:included_in_mrr, :item_applicability, :gift_claim_redirect_url, :unit, :
|
10
|
+
:included_in_mrr, :item_applicability, :gift_claim_redirect_url, :unit, :metered, :usage_calculation,
|
11
|
+
:applicable_items, :metadata
|
11
12
|
|
12
13
|
# OPERATIONS
|
13
14
|
#-----------
|
@@ -17,7 +17,8 @@ module ChargeBee
|
|
17
17
|
:pricing_model, :price, :period, :currency_code, :period_unit, :trial_period, :trial_period_unit,
|
18
18
|
:shipping_period, :shipping_period_unit, :billing_cycles, :free_quantity, :free_quantity_in_decimal,
|
19
19
|
:price_in_decimal, :resource_version, :updated_at, :created_at, :invoice_notes, :tiers, :is_taxable,
|
20
|
-
:tax_detail, :accounting_detail, :metadata, :item_type, :archivable, :parent_item_id
|
20
|
+
:tax_detail, :accounting_detail, :metadata, :item_type, :archivable, :parent_item_id, :show_description_in_invoices,
|
21
|
+
:show_description_in_quotes
|
21
22
|
|
22
23
|
# OPERATIONS
|
23
24
|
#-----------
|
@@ -1,8 +1,9 @@
|
|
1
1
|
require 'uri'
|
2
|
+
require 'cgi'
|
2
3
|
|
3
4
|
module ChargeBee
|
4
5
|
class Model
|
5
|
-
|
6
|
+
|
6
7
|
def initialize(values, sub_types={}, dependant_types={})
|
7
8
|
@values = values
|
8
9
|
@sub_types = sub_types
|
@@ -56,7 +57,7 @@ module ChargeBee
|
|
56
57
|
if(path.nil? || path.strip.length < 1)
|
57
58
|
raise "Id is empty or nil"
|
58
59
|
end
|
59
|
-
url = "#{url}/#{
|
60
|
+
url = "#{url}/#{CGI.escape(path.strip).gsub("+","%20").gsub("%21","!").gsub("%24","$").gsub("%26","&").gsub("%27","'").gsub("%28","(").gsub("%29", ")").gsub("%2A","*").gsub("%2B","+").gsub("%2C",",").gsub("%2F", "/").gsub("%3A",":").gsub("%3B",";").gsub("%3D","=").gsub("%3F","?").gsub("%40","@").gsub("%5B","[").gsub("%5D","]")}"
|
60
61
|
end
|
61
62
|
return url
|
62
63
|
end
|
@@ -2,11 +2,11 @@ module ChargeBee
|
|
2
2
|
class Subscription < Model
|
3
3
|
|
4
4
|
class SubscriptionItem < Model
|
5
|
-
attr_accessor :item_price_id, :item_type, :quantity, :unit_price, :amount, :free_quantity, :trial_end, :billing_cycles, :service_period_days, :charge_on_event, :charge_once, :charge_on_option
|
5
|
+
attr_accessor :item_price_id, :item_type, :quantity, :metered_quantity, :last_calculated_at, :unit_price, :amount, :free_quantity, :trial_end, :billing_cycles, :service_period_days, :charge_on_event, :charge_once, :charge_on_option
|
6
6
|
end
|
7
7
|
|
8
8
|
class ItemTier < Model
|
9
|
-
attr_accessor :item_price_id, :starting_unit, :ending_unit, :price
|
9
|
+
attr_accessor :item_price_id, :starting_unit, :ending_unit, :price, :starting_unit_in_decimal, :ending_unit_in_decimal, :price_in_decimal
|
10
10
|
end
|
11
11
|
|
12
12
|
class ChargedItem < Model
|
@@ -52,7 +52,7 @@ module ChargeBee
|
|
52
52
|
:due_invoices_count, :due_since, :total_dues, :mrr, :exchange_rate, :base_currency_code, :addons,
|
53
53
|
:event_based_addons, :charged_event_based_addons, :coupon, :coupons, :shipping_address, :referral_info,
|
54
54
|
:invoice_notes, :meta_data, :metadata, :deleted, :contract_term, :cancel_reason_code, :free_period,
|
55
|
-
:free_period_unit
|
55
|
+
:free_period_unit, :create_pending_invoices, :auto_close_invoices
|
56
56
|
|
57
57
|
# OPERATIONS
|
58
58
|
#-----------
|
@@ -141,6 +141,10 @@ module ChargeBee
|
|
141
141
|
Request.send('post', uri_path("subscriptions",id.to_s,"remove_advance_invoice_schedule"), params, env, headers)
|
142
142
|
end
|
143
143
|
|
144
|
+
def self.regenerate_invoice(id, params={}, env=nil, headers={})
|
145
|
+
Request.send('post', uri_path("subscriptions",id.to_s,"regenerate_invoice"), params, env, headers)
|
146
|
+
end
|
147
|
+
|
144
148
|
def self.import_subscription(params, env=nil, headers={})
|
145
149
|
Request.send('post', uri_path("subscriptions","import_subscription"), params, env, headers)
|
146
150
|
end
|
@@ -0,0 +1,31 @@
|
|
1
|
+
module ChargeBee
|
2
|
+
class Usage < Model
|
3
|
+
|
4
|
+
attr_accessor :id, :usage_date, :subscription_id, :item_price_id, :invoice_id, :line_item_id,
|
5
|
+
:quantity, :source, :note, :resource_version, :updated_at, :created_at
|
6
|
+
|
7
|
+
# OPERATIONS
|
8
|
+
#-----------
|
9
|
+
|
10
|
+
def self.create(id, params, env=nil, headers={})
|
11
|
+
Request.send('post', uri_path("subscriptions",id.to_s,"usages"), params, env, headers)
|
12
|
+
end
|
13
|
+
|
14
|
+
def self.retrieve(id, params, env=nil, headers={})
|
15
|
+
Request.send('get', uri_path("subscriptions",id.to_s,"usage"), params, env, headers)
|
16
|
+
end
|
17
|
+
|
18
|
+
def self.delete(id, params, env=nil, headers={})
|
19
|
+
Request.send('post', uri_path("subscriptions",id.to_s,"delete_usage"), params, env, headers)
|
20
|
+
end
|
21
|
+
|
22
|
+
def self.list(params, env=nil, headers={})
|
23
|
+
Request.send_list_request('get', uri_path("usages"), params, env, headers)
|
24
|
+
end
|
25
|
+
|
26
|
+
def self.pdf(params, env=nil, headers={})
|
27
|
+
Request.send('post', uri_path("usages","pdf"), params, env, headers)
|
28
|
+
end
|
29
|
+
|
30
|
+
end # ~Usage
|
31
|
+
end # ~ChargeBee
|
data/lib/chargebee/rest.rb
CHANGED
data/lib/chargebee/result.rb
CHANGED
@@ -16,7 +16,7 @@ module ChargeBee
|
|
16
16
|
return contract_term;
|
17
17
|
end
|
18
18
|
|
19
|
-
def advance_invoice_schedule()
|
19
|
+
def advance_invoice_schedule()
|
20
20
|
advance_invoice_schedule = get(:advance_invoice_schedule, AdvanceInvoiceSchedule,
|
21
21
|
{:fixed_interval_schedule => AdvanceInvoiceSchedule::FixedIntervalSchedule, :specific_dates_schedule => AdvanceInvoiceSchedule::SpecificDatesSchedule});
|
22
22
|
return advance_invoice_schedule;
|
@@ -179,6 +179,11 @@ module ChargeBee
|
|
179
179
|
return address;
|
180
180
|
end
|
181
181
|
|
182
|
+
def usage()
|
183
|
+
usage = get(:usage, Usage);
|
184
|
+
return usage;
|
185
|
+
end
|
186
|
+
|
182
187
|
def event()
|
183
188
|
event = get(:event, Event,
|
184
189
|
{:webhooks => Event::Webhook});
|
metadata
CHANGED
@@ -1,76 +1,90 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: chargebee
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.8.
|
4
|
+
version: 2.8.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Rajaraman S
|
8
8
|
- Thiyagarajan T
|
9
|
-
autorequire:
|
9
|
+
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2021-06-09 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: json_pure
|
16
16
|
requirement: !ruby/object:Gem::Requirement
|
17
17
|
requirements:
|
18
|
-
- - ~>
|
18
|
+
- - "~>"
|
19
19
|
- !ruby/object:Gem::Version
|
20
20
|
version: '2.1'
|
21
21
|
type: :runtime
|
22
22
|
prerelease: false
|
23
23
|
version_requirements: !ruby/object:Gem::Requirement
|
24
24
|
requirements:
|
25
|
-
- - ~>
|
25
|
+
- - "~>"
|
26
26
|
- !ruby/object:Gem::Version
|
27
27
|
version: '2.1'
|
28
28
|
- !ruby/object:Gem::Dependency
|
29
29
|
name: rest-client
|
30
30
|
requirement: !ruby/object:Gem::Requirement
|
31
31
|
requirements:
|
32
|
-
- -
|
32
|
+
- - ">="
|
33
33
|
- !ruby/object:Gem::Version
|
34
34
|
version: '1.8'
|
35
|
-
- - <
|
35
|
+
- - "<"
|
36
36
|
- !ruby/object:Gem::Version
|
37
37
|
version: '3.0'
|
38
38
|
type: :runtime
|
39
39
|
prerelease: false
|
40
40
|
version_requirements: !ruby/object:Gem::Requirement
|
41
41
|
requirements:
|
42
|
-
- -
|
42
|
+
- - ">="
|
43
43
|
- !ruby/object:Gem::Version
|
44
44
|
version: '1.8'
|
45
|
-
- - <
|
45
|
+
- - "<"
|
46
46
|
- !ruby/object:Gem::Version
|
47
47
|
version: '3.0'
|
48
|
+
- !ruby/object:Gem::Dependency
|
49
|
+
name: cgi
|
50
|
+
requirement: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - ">"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0'
|
55
|
+
type: :runtime
|
56
|
+
prerelease: false
|
57
|
+
version_requirements: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - ">"
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
48
62
|
- !ruby/object:Gem::Dependency
|
49
63
|
name: rspec
|
50
64
|
requirement: !ruby/object:Gem::Requirement
|
51
65
|
requirements:
|
52
|
-
- - ~>
|
66
|
+
- - "~>"
|
53
67
|
- !ruby/object:Gem::Version
|
54
68
|
version: 3.0.0
|
55
69
|
type: :development
|
56
70
|
prerelease: false
|
57
71
|
version_requirements: !ruby/object:Gem::Requirement
|
58
72
|
requirements:
|
59
|
-
- - ~>
|
73
|
+
- - "~>"
|
60
74
|
- !ruby/object:Gem::Version
|
61
75
|
version: 3.0.0
|
62
76
|
- !ruby/object:Gem::Dependency
|
63
77
|
name: mocha
|
64
78
|
requirement: !ruby/object:Gem::Requirement
|
65
79
|
requirements:
|
66
|
-
- -
|
80
|
+
- - ">="
|
67
81
|
- !ruby/object:Gem::Version
|
68
82
|
version: '0'
|
69
83
|
type: :development
|
70
84
|
prerelease: false
|
71
85
|
version_requirements: !ruby/object:Gem::Requirement
|
72
86
|
requirements:
|
73
|
-
- -
|
87
|
+
- - ">="
|
74
88
|
- !ruby/object:Gem::Version
|
75
89
|
version: '0'
|
76
90
|
description: Subscription Billing - Simple. Secure. Affordable. More details at www.chargebee.com.
|
@@ -139,6 +153,7 @@ files:
|
|
139
153
|
- lib/chargebee/models/token.rb
|
140
154
|
- lib/chargebee/models/transaction.rb
|
141
155
|
- lib/chargebee/models/unbilled_charge.rb
|
156
|
+
- lib/chargebee/models/usage.rb
|
142
157
|
- lib/chargebee/models/virtual_bank_account.rb
|
143
158
|
- lib/chargebee/request.rb
|
144
159
|
- lib/chargebee/rest.rb
|
@@ -154,25 +169,24 @@ homepage: https://apidocs.chargebee.com/api/docs?lang=ruby
|
|
154
169
|
licenses:
|
155
170
|
- MIT
|
156
171
|
metadata: {}
|
157
|
-
post_install_message:
|
172
|
+
post_install_message:
|
158
173
|
rdoc_options:
|
159
|
-
- --charset=UTF-8
|
174
|
+
- "--charset=UTF-8"
|
160
175
|
require_paths:
|
161
176
|
- lib
|
162
177
|
required_ruby_version: !ruby/object:Gem::Requirement
|
163
178
|
requirements:
|
164
|
-
- -
|
179
|
+
- - ">="
|
165
180
|
- !ruby/object:Gem::Version
|
166
181
|
version: 1.9.3
|
167
182
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
168
183
|
requirements:
|
169
|
-
- -
|
184
|
+
- - ">="
|
170
185
|
- !ruby/object:Gem::Version
|
171
186
|
version: '0'
|
172
187
|
requirements: []
|
173
|
-
|
174
|
-
|
175
|
-
signing_key:
|
188
|
+
rubygems_version: 3.0.3
|
189
|
+
signing_key:
|
176
190
|
specification_version: 2
|
177
191
|
summary: Ruby client for Chargebee API.
|
178
192
|
test_files:
|