lago_ruby 0.51.0.pre.beta → 0.52.0.pre.beta
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +18 -4
- data/docs/AddOnCreateInputAddOn.md +1 -1
- data/docs/AnalyticsApi.md +299 -0
- data/docs/CreditNoteItemObjectFee.md +4 -4
- data/docs/CustomerChargeUsageObjectCharge.md +3 -1
- data/docs/CustomersApi.md +70 -0
- data/docs/FeeObject.md +4 -4
- data/docs/GenerateCustomerCheckoutURL200Response.md +24 -0
- data/docs/GrossRevenueObject.md +22 -0
- data/docs/GrossRevenues.md +18 -0
- data/docs/InvoicedUsageObject.md +24 -0
- data/docs/InvoicedUsages.md +18 -0
- data/docs/MrrObject.md +22 -0
- data/docs/Mrrs.md +18 -0
- data/docs/OrganizationObject.md +2 -0
- data/docs/OrganizationUpdateInputOrganization.md +2 -0
- data/docs/OutstandingInvoiceObject.md +26 -0
- data/docs/OutstandingInvoices.md +18 -0
- data/docs/PlanOverridesObjectChargesInner.md +2 -0
- data/lago_ruby.gemspec +1 -1
- data/lib/lago_ruby/api/add_ons_api.rb +1 -1
- data/lib/lago_ruby/api/analytics_api.rb +268 -0
- data/lib/lago_ruby/api/billable_metrics_api.rb +1 -1
- data/lib/lago_ruby/api/coupons_api.rb +1 -1
- data/lib/lago_ruby/api/credit_notes_api.rb +1 -1
- data/lib/lago_ruby/api/customers_api.rb +64 -1
- data/lib/lago_ruby/api/events_api.rb +1 -1
- data/lib/lago_ruby/api/fees_api.rb +1 -1
- data/lib/lago_ruby/api/invoices_api.rb +1 -1
- data/lib/lago_ruby/api/organizations_api.rb +1 -1
- data/lib/lago_ruby/api/plans_api.rb +1 -1
- data/lib/lago_ruby/api/subscriptions_api.rb +1 -1
- data/lib/lago_ruby/api/taxes_api.rb +1 -1
- data/lib/lago_ruby/api/wallets_api.rb +1 -1
- data/lib/lago_ruby/api/webhook_endpoints_api.rb +1 -1
- data/lib/lago_ruby/api/webhooks_api.rb +1 -1
- data/lib/lago_ruby/api_client.rb +1 -1
- data/lib/lago_ruby/api_error.rb +1 -1
- data/lib/lago_ruby/configuration.rb +1 -1
- data/lib/lago_ruby/models/add_on.rb +1 -1
- data/lib/lago_ruby/models/add_on_base_input.rb +1 -1
- data/lib/lago_ruby/models/add_on_create_input.rb +1 -1
- data/lib/lago_ruby/models/add_on_create_input_add_on.rb +1 -1
- data/lib/lago_ruby/models/add_on_object.rb +1 -1
- data/lib/lago_ruby/models/add_on_update_input.rb +1 -1
- data/lib/lago_ruby/models/add_ons_paginated.rb +1 -1
- data/lib/lago_ruby/models/api_error_bad_request.rb +1 -1
- data/lib/lago_ruby/models/api_error_forbidden.rb +1 -1
- data/lib/lago_ruby/models/api_error_not_allowed.rb +1 -1
- data/lib/lago_ruby/models/api_error_not_found.rb +1 -1
- data/lib/lago_ruby/models/api_error_unauthorized.rb +1 -1
- data/lib/lago_ruby/models/api_error_unprocessable_entity.rb +1 -1
- data/lib/lago_ruby/models/applied_coupon.rb +1 -1
- data/lib/lago_ruby/models/applied_coupon_input.rb +1 -1
- data/lib/lago_ruby/models/applied_coupon_input_applied_coupon.rb +1 -1
- data/lib/lago_ruby/models/applied_coupon_object.rb +1 -1
- data/lib/lago_ruby/models/applied_coupon_object_extended.rb +1 -1
- data/lib/lago_ruby/models/applied_coupons_paginated.rb +1 -1
- data/lib/lago_ruby/models/base_applied_tax.rb +1 -1
- data/lib/lago_ruby/models/billable_metric.rb +1 -1
- data/lib/lago_ruby/models/billable_metric_base_input.rb +1 -1
- data/lib/lago_ruby/models/billable_metric_create_input.rb +1 -1
- data/lib/lago_ruby/models/billable_metric_create_input_billable_metric.rb +1 -1
- data/lib/lago_ruby/models/billable_metric_group.rb +1 -1
- data/lib/lago_ruby/models/billable_metric_group_values_inner.rb +1 -1
- data/lib/lago_ruby/models/billable_metric_group_values_inner_one_of.rb +1 -1
- data/lib/lago_ruby/models/billable_metric_object.rb +1 -1
- data/lib/lago_ruby/models/billable_metric_update_input.rb +1 -1
- data/lib/lago_ruby/models/billable_metrics_paginated.rb +1 -1
- data/lib/lago_ruby/models/charge_object.rb +1 -1
- data/lib/lago_ruby/models/charge_object_properties.rb +1 -1
- data/lib/lago_ruby/models/charge_properties.rb +1 -1
- data/lib/lago_ruby/models/charge_properties_graduated_percentage_ranges_inner.rb +1 -1
- data/lib/lago_ruby/models/charge_properties_graduated_ranges_inner.rb +1 -1
- data/lib/lago_ruby/models/charge_properties_volume_ranges_inner.rb +1 -1
- data/lib/lago_ruby/models/country.rb +1 -1
- data/lib/lago_ruby/models/coupon.rb +1 -1
- data/lib/lago_ruby/models/coupon_base_input.rb +1 -1
- data/lib/lago_ruby/models/coupon_base_input_applies_to.rb +1 -1
- data/lib/lago_ruby/models/coupon_create_input.rb +1 -1
- data/lib/lago_ruby/models/coupon_create_input_coupon.rb +1 -1
- data/lib/lago_ruby/models/coupon_object.rb +1 -1
- data/lib/lago_ruby/models/coupon_update_input.rb +1 -1
- data/lib/lago_ruby/models/coupons_paginated.rb +1 -1
- data/lib/lago_ruby/models/credit_note.rb +1 -1
- data/lib/lago_ruby/models/credit_note_applied_tax_object.rb +1 -1
- data/lib/lago_ruby/models/credit_note_create_input.rb +1 -1
- data/lib/lago_ruby/models/credit_note_create_input_credit_note.rb +1 -1
- data/lib/lago_ruby/models/credit_note_estimate_input.rb +1 -1
- data/lib/lago_ruby/models/credit_note_estimate_input_credit_note.rb +1 -1
- data/lib/lago_ruby/models/credit_note_estimate_input_credit_note_items_inner.rb +1 -1
- data/lib/lago_ruby/models/credit_note_estimated.rb +1 -1
- data/lib/lago_ruby/models/credit_note_estimated_estimated_credit_note.rb +1 -1
- data/lib/lago_ruby/models/credit_note_estimated_estimated_credit_note_applied_taxes_inner.rb +1 -1
- data/lib/lago_ruby/models/credit_note_estimated_estimated_credit_note_items_inner.rb +1 -1
- data/lib/lago_ruby/models/credit_note_item_object.rb +1 -1
- data/lib/lago_ruby/models/credit_note_item_object_fee.rb +5 -5
- data/lib/lago_ruby/models/credit_note_object.rb +1 -1
- data/lib/lago_ruby/models/credit_note_update_input.rb +1 -1
- data/lib/lago_ruby/models/credit_note_update_input_credit_note.rb +1 -1
- data/lib/lago_ruby/models/credit_notes.rb +1 -1
- data/lib/lago_ruby/models/credit_object.rb +1 -1
- data/lib/lago_ruby/models/credit_object_invoice.rb +1 -1
- data/lib/lago_ruby/models/credit_object_item.rb +1 -1
- data/lib/lago_ruby/models/currency.rb +1 -1
- data/lib/lago_ruby/models/customer.rb +1 -1
- data/lib/lago_ruby/models/customer_billing_configuration.rb +1 -1
- data/lib/lago_ruby/models/customer_charge_usage_object.rb +1 -1
- data/lib/lago_ruby/models/customer_charge_usage_object_billable_metric.rb +1 -1
- data/lib/lago_ruby/models/customer_charge_usage_object_charge.rb +15 -5
- data/lib/lago_ruby/models/customer_charge_usage_object_groups_inner.rb +1 -1
- data/lib/lago_ruby/models/customer_create_input.rb +1 -1
- data/lib/lago_ruby/models/customer_create_input_customer.rb +1 -1
- data/lib/lago_ruby/models/customer_create_input_customer_metadata_inner.rb +1 -1
- data/lib/lago_ruby/models/customer_metadata.rb +1 -1
- data/lib/lago_ruby/models/customer_object.rb +1 -1
- data/lib/lago_ruby/models/customer_object_extended.rb +1 -1
- data/lib/lago_ruby/models/customer_past_usage.rb +1 -1
- data/lib/lago_ruby/models/customer_usage.rb +1 -1
- data/lib/lago_ruby/models/customer_usage_object.rb +1 -1
- data/lib/lago_ruby/models/customers_paginated.rb +1 -1
- data/lib/lago_ruby/models/event.rb +1 -1
- data/lib/lago_ruby/models/event_batch_input.rb +1 -1
- data/lib/lago_ruby/models/event_batch_input_event.rb +1 -1
- data/lib/lago_ruby/models/event_batch_input_event_properties.rb +1 -1
- data/lib/lago_ruby/models/event_estimate_fees_input.rb +1 -1
- data/lib/lago_ruby/models/event_estimate_fees_input_event.rb +1 -1
- data/lib/lago_ruby/models/event_input.rb +1 -1
- data/lib/lago_ruby/models/event_input_event.rb +1 -1
- data/lib/lago_ruby/models/event_input_event_timestamp.rb +1 -1
- data/lib/lago_ruby/models/event_object.rb +1 -1
- data/lib/lago_ruby/models/event_object_properties.rb +1 -1
- data/lib/lago_ruby/models/fee.rb +1 -1
- data/lib/lago_ruby/models/fee_applied_tax_object.rb +1 -1
- data/lib/lago_ruby/models/fee_object.rb +5 -5
- data/lib/lago_ruby/models/fee_object_item.rb +1 -1
- data/lib/lago_ruby/models/fee_update_input.rb +1 -1
- data/lib/lago_ruby/models/fee_update_input_fee.rb +1 -1
- data/lib/lago_ruby/models/fees.rb +1 -1
- data/lib/lago_ruby/models/fees_paginated.rb +1 -1
- data/lib/lago_ruby/models/generate_customer_checkout_url200_response.rb +246 -0
- data/lib/lago_ruby/models/get_customer_portal_url200_response.rb +1 -1
- data/lib/lago_ruby/models/get_customer_portal_url200_response_customer.rb +1 -1
- data/lib/lago_ruby/models/gross_revenue_object.rb +241 -0
- data/lib/lago_ruby/models/gross_revenues.rb +223 -0
- data/lib/lago_ruby/models/group_object.rb +1 -1
- data/lib/lago_ruby/models/group_properties_object.rb +1 -1
- data/lib/lago_ruby/models/group_properties_object_values.rb +1 -1
- data/lib/lago_ruby/models/groups_paginated.rb +1 -1
- data/lib/lago_ruby/models/invoice.rb +1 -1
- data/lib/lago_ruby/models/invoice_applied_tax_object.rb +1 -1
- data/lib/lago_ruby/models/invoice_metadata_object.rb +1 -1
- data/lib/lago_ruby/models/invoice_object.rb +1 -1
- data/lib/lago_ruby/models/invoice_object_customer.rb +1 -1
- data/lib/lago_ruby/models/invoice_object_extended.rb +1 -1
- data/lib/lago_ruby/models/invoice_one_off_create_input.rb +1 -1
- data/lib/lago_ruby/models/invoice_one_off_create_input_invoice.rb +1 -1
- data/lib/lago_ruby/models/invoice_one_off_create_input_invoice_fees_inner.rb +1 -1
- data/lib/lago_ruby/models/invoice_update_input.rb +1 -1
- data/lib/lago_ruby/models/invoice_update_input_invoice.rb +1 -1
- data/lib/lago_ruby/models/invoice_update_input_invoice_metadata_inner.rb +1 -1
- data/lib/lago_ruby/models/invoiced_usage_object.rb +265 -0
- data/lib/lago_ruby/models/invoiced_usages.rb +223 -0
- data/lib/lago_ruby/models/invoices_paginated.rb +1 -1
- data/lib/lago_ruby/models/mrr_object.rb +241 -0
- data/lib/lago_ruby/models/mrrs.rb +223 -0
- data/lib/lago_ruby/models/organization.rb +1 -1
- data/lib/lago_ruby/models/organization_billing_configuration.rb +1 -1
- data/lib/lago_ruby/models/organization_object.rb +11 -2
- data/lib/lago_ruby/models/organization_update_input.rb +1 -1
- data/lib/lago_ruby/models/organization_update_input_organization.rb +11 -2
- data/lib/lago_ruby/models/outstanding_invoice_object.rb +309 -0
- data/lib/lago_ruby/models/outstanding_invoices.rb +223 -0
- data/lib/lago_ruby/models/pagination_meta.rb +1 -1
- data/lib/lago_ruby/models/plan.rb +1 -1
- data/lib/lago_ruby/models/plan_create_input.rb +1 -1
- data/lib/lago_ruby/models/plan_create_input_plan.rb +1 -1
- data/lib/lago_ruby/models/plan_create_input_plan_charges_inner.rb +1 -1
- data/lib/lago_ruby/models/plan_create_input_plan_charges_inner_group_properties_inner.rb +1 -1
- data/lib/lago_ruby/models/plan_object.rb +1 -1
- data/lib/lago_ruby/models/plan_overrides_object.rb +1 -1
- data/lib/lago_ruby/models/plan_overrides_object_charges_inner.rb +12 -2
- data/lib/lago_ruby/models/plan_update_input.rb +1 -1
- data/lib/lago_ruby/models/plan_update_input_plan.rb +1 -1
- data/lib/lago_ruby/models/plan_update_input_plan_charges_inner.rb +1 -1
- data/lib/lago_ruby/models/plans_paginated.rb +1 -1
- data/lib/lago_ruby/models/subscription.rb +1 -1
- data/lib/lago_ruby/models/subscription_create_input.rb +1 -1
- data/lib/lago_ruby/models/subscription_create_input_subscription.rb +1 -1
- data/lib/lago_ruby/models/subscription_object.rb +1 -1
- data/lib/lago_ruby/models/subscription_object_extended.rb +1 -1
- data/lib/lago_ruby/models/subscription_update_input.rb +1 -1
- data/lib/lago_ruby/models/subscription_update_input_subscription.rb +1 -1
- data/lib/lago_ruby/models/subscriptions_paginated.rb +1 -1
- data/lib/lago_ruby/models/tax.rb +1 -1
- data/lib/lago_ruby/models/tax_base_input.rb +1 -1
- data/lib/lago_ruby/models/tax_create_input.rb +1 -1
- data/lib/lago_ruby/models/tax_create_input_tax.rb +1 -1
- data/lib/lago_ruby/models/tax_object.rb +1 -1
- data/lib/lago_ruby/models/tax_update_input.rb +1 -1
- data/lib/lago_ruby/models/taxes_paginated.rb +1 -1
- data/lib/lago_ruby/models/timezone.rb +1 -1
- data/lib/lago_ruby/models/wallet.rb +1 -1
- data/lib/lago_ruby/models/wallet_create_input.rb +1 -1
- data/lib/lago_ruby/models/wallet_create_input_wallet.rb +1 -1
- data/lib/lago_ruby/models/wallet_object.rb +1 -1
- data/lib/lago_ruby/models/wallet_transaction_create_input.rb +1 -1
- data/lib/lago_ruby/models/wallet_transaction_create_input_wallet_transaction.rb +1 -1
- data/lib/lago_ruby/models/wallet_transaction_object.rb +1 -1
- data/lib/lago_ruby/models/wallet_transactions.rb +1 -1
- data/lib/lago_ruby/models/wallet_transactions_paginated.rb +1 -1
- data/lib/lago_ruby/models/wallet_update_input.rb +1 -1
- data/lib/lago_ruby/models/wallet_update_input_wallet.rb +1 -1
- data/lib/lago_ruby/models/wallets_paginated.rb +1 -1
- data/lib/lago_ruby/models/webhook_endpoint.rb +1 -1
- data/lib/lago_ruby/models/webhook_endpoint_create_input.rb +1 -1
- data/lib/lago_ruby/models/webhook_endpoint_create_input_webhook_endpoint.rb +1 -1
- data/lib/lago_ruby/models/webhook_endpoint_object.rb +1 -1
- data/lib/lago_ruby/models/webhook_endpoint_update_input.rb +1 -1
- data/lib/lago_ruby/models/webhook_endpoints_paginated.rb +1 -1
- data/lib/lago_ruby/version.rb +2 -2
- data/lib/lago_ruby.rb +11 -1
- data/spec/api/analytics_api_spec.rb +85 -0
- data/spec/api_client_spec.rb +1 -1
- data/spec/configuration_spec.rb +1 -1
- data/spec/models/generate_customer_checkout_url200_response_spec.rb +54 -0
- data/spec/models/gross_revenue_object_spec.rb +48 -0
- data/spec/models/gross_revenues_spec.rb +36 -0
- data/spec/models/invoiced_usage_object_spec.rb +54 -0
- data/spec/models/invoiced_usages_spec.rb +36 -0
- data/spec/models/mrr_object_spec.rb +48 -0
- data/spec/models/mrrs_spec.rb +36 -0
- data/spec/models/outstanding_invoice_object_spec.rb +64 -0
- data/spec/models/outstanding_invoices_spec.rb +36 -0
- data/spec/spec_helper.rb +1 -1
- metadata +204 -164
@@ -6,7 +6,7 @@
|
|
6
6
|
The version of the OpenAPI document: 0.51.0-beta
|
7
7
|
Contact: tech@getlago.com
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
OpenAPI Generator version: 7.
|
9
|
+
OpenAPI Generator version: 7.2.0-SNAPSHOT
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -18,6 +18,9 @@ module LagoAPI
|
|
18
18
|
# Unique identifier of the charge created by Lago.
|
19
19
|
attr_accessor :id
|
20
20
|
|
21
|
+
# Unique identifier of the billable metric created by Lago.
|
22
|
+
attr_accessor :billable_metric_id
|
23
|
+
|
21
24
|
# Specifies the name that will be displayed on an invoice. If no value is set for this field, the name of the actual charge will be used as the default display name.
|
22
25
|
attr_accessor :invoice_display_name
|
23
26
|
|
@@ -36,6 +39,7 @@ module LagoAPI
|
|
36
39
|
def self.attribute_map
|
37
40
|
{
|
38
41
|
:'id' => :'id',
|
42
|
+
:'billable_metric_id' => :'billable_metric_id',
|
39
43
|
:'invoice_display_name' => :'invoice_display_name',
|
40
44
|
:'min_amount_cents' => :'min_amount_cents',
|
41
45
|
:'properties' => :'properties',
|
@@ -53,6 +57,7 @@ module LagoAPI
|
|
53
57
|
def self.openapi_types
|
54
58
|
{
|
55
59
|
:'id' => :'String',
|
60
|
+
:'billable_metric_id' => :'String',
|
56
61
|
:'invoice_display_name' => :'String',
|
57
62
|
:'min_amount_cents' => :'Integer',
|
58
63
|
:'properties' => :'ChargeObjectProperties',
|
@@ -86,6 +91,10 @@ module LagoAPI
|
|
86
91
|
self.id = attributes[:'id']
|
87
92
|
end
|
88
93
|
|
94
|
+
if attributes.key?(:'billable_metric_id')
|
95
|
+
self.billable_metric_id = attributes[:'billable_metric_id']
|
96
|
+
end
|
97
|
+
|
89
98
|
if attributes.key?(:'invoice_display_name')
|
90
99
|
self.invoice_display_name = attributes[:'invoice_display_name']
|
91
100
|
end
|
@@ -132,6 +141,7 @@ module LagoAPI
|
|
132
141
|
return true if self.equal?(o)
|
133
142
|
self.class == o.class &&
|
134
143
|
id == o.id &&
|
144
|
+
billable_metric_id == o.billable_metric_id &&
|
135
145
|
invoice_display_name == o.invoice_display_name &&
|
136
146
|
min_amount_cents == o.min_amount_cents &&
|
137
147
|
properties == o.properties &&
|
@@ -148,7 +158,7 @@ module LagoAPI
|
|
148
158
|
# Calculates hash code according to all attributes.
|
149
159
|
# @return [Integer] Hash code
|
150
160
|
def hash
|
151
|
-
[id, invoice_display_name, min_amount_cents, properties, group_properties, tax_codes].hash
|
161
|
+
[id, billable_metric_id, invoice_display_name, min_amount_cents, properties, group_properties, tax_codes].hash
|
152
162
|
end
|
153
163
|
|
154
164
|
# Builds the object from hash
|
data/lib/lago_ruby/models/tax.rb
CHANGED
data/lib/lago_ruby/version.rb
CHANGED
@@ -6,10 +6,10 @@
|
|
6
6
|
The version of the OpenAPI document: 0.51.0-beta
|
7
7
|
Contact: tech@getlago.com
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
OpenAPI Generator version: 7.
|
9
|
+
OpenAPI Generator version: 7.2.0-SNAPSHOT
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
13
13
|
module LagoAPI
|
14
|
-
VERSION = '0.
|
14
|
+
VERSION = '0.52.0-beta'
|
15
15
|
end
|
data/lib/lago_ruby.rb
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
The version of the OpenAPI document: 0.51.0-beta
|
7
7
|
Contact: tech@getlago.com
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
OpenAPI Generator version: 7.
|
9
|
+
OpenAPI Generator version: 7.2.0-SNAPSHOT
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -118,8 +118,11 @@ require 'lago_ruby/models/fee_update_input'
|
|
118
118
|
require 'lago_ruby/models/fee_update_input_fee'
|
119
119
|
require 'lago_ruby/models/fees'
|
120
120
|
require 'lago_ruby/models/fees_paginated'
|
121
|
+
require 'lago_ruby/models/generate_customer_checkout_url200_response'
|
121
122
|
require 'lago_ruby/models/get_customer_portal_url200_response'
|
122
123
|
require 'lago_ruby/models/get_customer_portal_url200_response_customer'
|
124
|
+
require 'lago_ruby/models/gross_revenue_object'
|
125
|
+
require 'lago_ruby/models/gross_revenues'
|
123
126
|
require 'lago_ruby/models/group_object'
|
124
127
|
require 'lago_ruby/models/group_properties_object'
|
125
128
|
require 'lago_ruby/models/group_properties_object_values'
|
@@ -136,12 +139,18 @@ require 'lago_ruby/models/invoice_one_off_create_input_invoice_fees_inner'
|
|
136
139
|
require 'lago_ruby/models/invoice_update_input'
|
137
140
|
require 'lago_ruby/models/invoice_update_input_invoice'
|
138
141
|
require 'lago_ruby/models/invoice_update_input_invoice_metadata_inner'
|
142
|
+
require 'lago_ruby/models/invoiced_usage_object'
|
143
|
+
require 'lago_ruby/models/invoiced_usages'
|
139
144
|
require 'lago_ruby/models/invoices_paginated'
|
145
|
+
require 'lago_ruby/models/mrr_object'
|
146
|
+
require 'lago_ruby/models/mrrs'
|
140
147
|
require 'lago_ruby/models/organization'
|
141
148
|
require 'lago_ruby/models/organization_billing_configuration'
|
142
149
|
require 'lago_ruby/models/organization_object'
|
143
150
|
require 'lago_ruby/models/organization_update_input'
|
144
151
|
require 'lago_ruby/models/organization_update_input_organization'
|
152
|
+
require 'lago_ruby/models/outstanding_invoice_object'
|
153
|
+
require 'lago_ruby/models/outstanding_invoices'
|
145
154
|
require 'lago_ruby/models/pagination_meta'
|
146
155
|
require 'lago_ruby/models/plan'
|
147
156
|
require 'lago_ruby/models/plan_create_input'
|
@@ -192,6 +201,7 @@ require 'lago_ruby/models/webhook_endpoints_paginated'
|
|
192
201
|
|
193
202
|
# APIs
|
194
203
|
require 'lago_ruby/api/add_ons_api'
|
204
|
+
require 'lago_ruby/api/analytics_api'
|
195
205
|
require 'lago_ruby/api/billable_metrics_api'
|
196
206
|
require 'lago_ruby/api/coupons_api'
|
197
207
|
require 'lago_ruby/api/credit_notes_api'
|
@@ -0,0 +1,85 @@
|
|
1
|
+
=begin
|
2
|
+
#Lago API documentation
|
3
|
+
|
4
|
+
#Lago API allows your application to push customer information and metrics (events) from your application to the billing application.
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 0.51.0-beta
|
7
|
+
Contact: tech@getlago.com
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 7.2.0-SNAPSHOT
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
|
16
|
+
# Unit tests for LagoAPI::AnalyticsApi
|
17
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
18
|
+
# Please update as you see appropriate
|
19
|
+
describe 'AnalyticsApi' do
|
20
|
+
before do
|
21
|
+
# run before each test
|
22
|
+
@api_instance = LagoAPI::AnalyticsApi.new
|
23
|
+
end
|
24
|
+
|
25
|
+
after do
|
26
|
+
# run after each test
|
27
|
+
end
|
28
|
+
|
29
|
+
describe 'test an instance of AnalyticsApi' do
|
30
|
+
it 'should create an instance of AnalyticsApi' do
|
31
|
+
expect(@api_instance).to be_instance_of(LagoAPI::AnalyticsApi)
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
# unit tests for find_all_gross_revenues
|
36
|
+
# List gross revenue
|
37
|
+
# Gross revenue is the sum of monthly `finalized` invoice payments and fees paid in advance that are not invoiceable. This total is calculated after deducting taxes and discounts.
|
38
|
+
# @param [Hash] opts the optional parameters
|
39
|
+
# @option opts [Currency] :currency Currency of revenue analytics. Format must be ISO 4217.
|
40
|
+
# @option opts [String] :external_customer_id The customer external unique identifier (provided by your own application). Use it to filter revenue analytics at the customer level.
|
41
|
+
# @return [GrossRevenues]
|
42
|
+
describe 'find_all_gross_revenues test' do
|
43
|
+
it 'should work' do
|
44
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
45
|
+
end
|
46
|
+
end
|
47
|
+
|
48
|
+
# unit tests for find_all_invoiced_usages
|
49
|
+
# List usage revenue
|
50
|
+
# Reports a monthly analysis focused on the revenue generated from all usage-based fees. It exclusively accounts for revenue that has been formally invoiced. Importantly, this report does not include revenue related to the usage in the current billing period, limiting its scope to previously invoiced amounts.
|
51
|
+
# @param [Hash] opts the optional parameters
|
52
|
+
# @option opts [Currency] :currency The currency of invoiced usage analytics. Format must be ISO 4217.
|
53
|
+
# @return [InvoicedUsages]
|
54
|
+
describe 'find_all_invoiced_usages test' do
|
55
|
+
it 'should work' do
|
56
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
57
|
+
end
|
58
|
+
end
|
59
|
+
|
60
|
+
# unit tests for find_all_mrrs
|
61
|
+
# List MRR
|
62
|
+
# This endpoint is used to list MRR.
|
63
|
+
# @param [Hash] opts the optional parameters
|
64
|
+
# @option opts [Currency] :currency Quantifies the revenue generated from `subscription` fees on a monthly basis. This figure is calculated post-application of applicable taxes and prior to the deduction of any applicable discounts. The method of calculation varies based on the subscription billing cycle: - Revenue from `monthly` subscription invoices is included in the MRR for the month in which the invoice is issued. - Revenue from `quarterly` subscription invoices is distributed evenly over three months. This distribution applies to fees paid in advance (allocated to the next three months) as well as to fees paid in arrears (allocated to the preceding three months). - Revenue from `yearly` subscription invoices is distributed evenly over twelve months. This allocation is applicable for fees paid in advance (spread over the next twelve months) and for fees paid in arrears (spread over the previous twelve months). - Revenue from `weekly` subscription invoices, the total revenue from all invoices issued within a month is summed up. This total is then divided by the number of invoices issued during that month, and the result is multiplied by 4.33, representing the average number of weeks in a month.
|
65
|
+
# @option opts [Integer] :months Show data only for given number of months.
|
66
|
+
# @return [Mrrs]
|
67
|
+
describe 'find_all_mrrs test' do
|
68
|
+
it 'should work' do
|
69
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
70
|
+
end
|
71
|
+
end
|
72
|
+
|
73
|
+
# unit tests for find_all_outstanding_invoices
|
74
|
+
# List outstanding invoices
|
75
|
+
# Represents a monthly aggregation, detailing both the total count and the cumulative amount of invoices that have been marked as `finalized`. This report sorts invoices categorically based on their `payment_status`.
|
76
|
+
# @param [Hash] opts the optional parameters
|
77
|
+
# @option opts [Currency] :currency The currency of revenue analytics. Format must be ISO 4217.
|
78
|
+
# @return [OutstandingInvoices]
|
79
|
+
describe 'find_all_outstanding_invoices test' do
|
80
|
+
it 'should work' do
|
81
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
82
|
+
end
|
83
|
+
end
|
84
|
+
|
85
|
+
end
|