lago-javascript-client 0.51.0-beta → 0.53.0-beta
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm/openapi/client.d.ts +521 -7
- package/esm/openapi/client.js +103 -1
- package/package.json +1 -1
- package/script/openapi/client.d.ts +521 -7
- package/script/openapi/client.js +103 -1
package/esm/openapi/client.js
CHANGED
|
@@ -148,7 +148,7 @@ export class HttpClient {
|
|
|
148
148
|
}
|
|
149
149
|
/**
|
|
150
150
|
* @title Lago API documentation
|
|
151
|
-
* @version 0.
|
|
151
|
+
* @version 0.53.0-beta
|
|
152
152
|
* @license AGPLv3
|
|
153
153
|
* @baseUrl https://api.getlago.com/api/v1
|
|
154
154
|
* @externalDocs https://github.com/getlago
|
|
@@ -244,6 +244,76 @@ export class Api extends HttpClient {
|
|
|
244
244
|
...params,
|
|
245
245
|
}),
|
|
246
246
|
};
|
|
247
|
+
analytics = {
|
|
248
|
+
/**
|
|
249
|
+
* @description 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.
|
|
250
|
+
*
|
|
251
|
+
* @tags analytics
|
|
252
|
+
* @name FindAllGrossRevenues
|
|
253
|
+
* @summary List gross revenue
|
|
254
|
+
* @request GET:/analytics/gross_revenue
|
|
255
|
+
* @secure
|
|
256
|
+
*/
|
|
257
|
+
findAllGrossRevenues: (query, params = {}) => this.request({
|
|
258
|
+
path: `/analytics/gross_revenue`,
|
|
259
|
+
method: "GET",
|
|
260
|
+
query: query,
|
|
261
|
+
secure: true,
|
|
262
|
+
format: "json",
|
|
263
|
+
...params,
|
|
264
|
+
}),
|
|
265
|
+
/**
|
|
266
|
+
* @description 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`.
|
|
267
|
+
*
|
|
268
|
+
* @tags analytics
|
|
269
|
+
* @name FindAllInvoiceCollections
|
|
270
|
+
* @summary List of finalized invoices
|
|
271
|
+
* @request GET:/analytics/invoice_collection
|
|
272
|
+
* @secure
|
|
273
|
+
*/
|
|
274
|
+
findAllInvoiceCollections: (query, params = {}) => this.request({
|
|
275
|
+
path: `/analytics/invoice_collection`,
|
|
276
|
+
method: "GET",
|
|
277
|
+
query: query,
|
|
278
|
+
secure: true,
|
|
279
|
+
format: "json",
|
|
280
|
+
...params,
|
|
281
|
+
}),
|
|
282
|
+
/**
|
|
283
|
+
* @description 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.
|
|
284
|
+
*
|
|
285
|
+
* @tags analytics
|
|
286
|
+
* @name FindAllInvoicedUsages
|
|
287
|
+
* @summary List usage revenue
|
|
288
|
+
* @request GET:/analytics/invoiced_usage
|
|
289
|
+
* @secure
|
|
290
|
+
*/
|
|
291
|
+
findAllInvoicedUsages: (query, params = {}) => this.request({
|
|
292
|
+
path: `/analytics/invoiced_usage`,
|
|
293
|
+
method: "GET",
|
|
294
|
+
query: query,
|
|
295
|
+
secure: true,
|
|
296
|
+
format: "json",
|
|
297
|
+
...params,
|
|
298
|
+
}),
|
|
299
|
+
/**
|
|
300
|
+
* @description This endpoint is used to list MRR.
|
|
301
|
+
*
|
|
302
|
+
* @tags analytics
|
|
303
|
+
* @name FindAllMrrs
|
|
304
|
+
* @summary List MRR
|
|
305
|
+
* @request GET:/analytics/mrr
|
|
306
|
+
* @secure
|
|
307
|
+
*/
|
|
308
|
+
findAllMrrs: (query, params = {}) => this.request({
|
|
309
|
+
path: `/analytics/mrr`,
|
|
310
|
+
method: "GET",
|
|
311
|
+
query: query,
|
|
312
|
+
secure: true,
|
|
313
|
+
format: "json",
|
|
314
|
+
...params,
|
|
315
|
+
}),
|
|
316
|
+
};
|
|
247
317
|
appliedCoupons = {
|
|
248
318
|
/**
|
|
249
319
|
* @description This endpoint is used to apply a specific coupon to a customer, before or during a subscription.
|
|
@@ -727,6 +797,22 @@ export class Api extends HttpClient {
|
|
|
727
797
|
format: "json",
|
|
728
798
|
...params,
|
|
729
799
|
}),
|
|
800
|
+
/**
|
|
801
|
+
* @description This endpoint regenerates the Payment Provider Checkout URL of a Customer.
|
|
802
|
+
*
|
|
803
|
+
* @tags customers
|
|
804
|
+
* @name GenerateCustomerCheckoutUrl
|
|
805
|
+
* @summary Generate a Customer Payment Provider Checkout URL
|
|
806
|
+
* @request POST:/customers/{external_customer_id}/checkout_url
|
|
807
|
+
* @secure
|
|
808
|
+
*/
|
|
809
|
+
generateCustomerCheckoutUrl: (externalCustomerId, params = {}) => this.request({
|
|
810
|
+
path: `/customers/${externalCustomerId}/checkout_url`,
|
|
811
|
+
method: "POST",
|
|
812
|
+
secure: true,
|
|
813
|
+
format: "json",
|
|
814
|
+
...params,
|
|
815
|
+
}),
|
|
730
816
|
};
|
|
731
817
|
events = {
|
|
732
818
|
/**
|
|
@@ -986,6 +1072,22 @@ export class Api extends HttpClient {
|
|
|
986
1072
|
secure: true,
|
|
987
1073
|
...params,
|
|
988
1074
|
}),
|
|
1075
|
+
/**
|
|
1076
|
+
* @description This endpoint is used for voiding an invoice. You can void an invoice only when it's in a `finalized` status, and the payment status is not `succeeded`.
|
|
1077
|
+
*
|
|
1078
|
+
* @tags invoices
|
|
1079
|
+
* @name VoidInvoice
|
|
1080
|
+
* @summary Void an invoice
|
|
1081
|
+
* @request POST:/invoices/{lago_id}/void
|
|
1082
|
+
* @secure
|
|
1083
|
+
*/
|
|
1084
|
+
voidInvoice: (lagoId, params = {}) => this.request({
|
|
1085
|
+
path: `/invoices/${lagoId}/void`,
|
|
1086
|
+
method: "POST",
|
|
1087
|
+
secure: true,
|
|
1088
|
+
format: "json",
|
|
1089
|
+
...params,
|
|
1090
|
+
}),
|
|
989
1091
|
};
|
|
990
1092
|
organizations = {
|
|
991
1093
|
/**
|