lago-javascript-client 1.53.0 → 1.54.0
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 +110 -29
- package/esm/openapi/client.js +4 -3
- package/esm/openapi/webhooks.d.ts +90 -35
- package/package.json +1 -1
- package/script/openapi/client.d.ts +110 -29
- package/script/openapi/client.js +4 -3
- package/script/openapi/webhooks.d.ts +90 -35
package/esm/openapi/client.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/** @example "USD" */
|
|
2
|
-
export type Currency = "AED" | "AFN" | "ALL" | "AMD" | "ANG" | "AOA" | "ARS" | "AUD" | "AWG" | "AZN" | "BAM" | "BBD" | "BDT" | "BGN" | "BIF" | "BMD" | "BND" | "BOB" | "BRL" | "BSD" | "BWP" | "BYN" | "BZD" | "CAD" | "CDF" | "CHF" | "CLF" | "CLP" | "CNY" | "COP" | "CRC" | "CVE" | "CZK" | "DJF" | "DKK" | "DOP" | "DZD" | "EGP" | "ETB" | "EUR" | "FJD" | "FKP" | "GBP" | "GEL" | "GHS" | "GIP" | "GMD" | "GNF" | "GTQ" | "GYD" | "HKD" | "HNL" | "HRK" | "HTG" | "HUF" | "IDR" | "ILS" | "INR" | "ISK" | "JMD" | "JPY" | "KES" | "KGS" | "KHR" | "KMF" | "KRW" | "KYD" | "KZT" | "LAK" | "LBP" | "LKR" | "LRD" | "LSL" | "MAD" | "MDL" | "MGA" | "MKD" | "MMK" | "MNT" | "MOP" | "MRO" | "MUR" | "MVR" | "MWK" | "MXN" | "MYR" | "MZN" | "NAD" | "NGN" | "NIO" | "NOK" | "NPR" | "NZD" | "PAB" | "PEN" | "PGK" | "PHP" | "PKR" | "PLN" | "PYG" | "QAR" | "RON" | "RSD" | "RUB" | "RWF" | "SAR" | "SBD" | "SCR" | "SEK" | "SGD" | "SHP" | "SLL" | "SOS" | "SRD" | "STD" | "SZL" | "THB" | "TJS" | "TOP" | "TRY" | "TTD" | "TWD" | "TZS" | "UAH" | "UGX" | "USD" | "UYU" | "UZS" | "VND" | "VUV" | "WST" | "XAF" | "XCD" | "XOF" | "XPF" | "YER" | "ZAR" | "ZMW";
|
|
2
|
+
export type Currency = "AED" | "AFN" | "ALL" | "AMD" | "ANG" | "AOA" | "ARS" | "AUD" | "AWG" | "AZN" | "BAM" | "BBD" | "BDT" | "BGN" | "BIF" | "BMD" | "BND" | "BOB" | "BRL" | "BSD" | "BWP" | "BYN" | "BZD" | "CAD" | "CDF" | "CHF" | "CLF" | "CLP" | "CNY" | "COP" | "CRC" | "CVE" | "CZK" | "DJF" | "DKK" | "DOP" | "DZD" | "EGP" | "ETB" | "EUR" | "FJD" | "FKP" | "GBP" | "GEL" | "GHS" | "GIP" | "GMD" | "GNF" | "GTQ" | "GYD" | "HKD" | "HNL" | "HRK" | "HTG" | "HUF" | "IDR" | "ILS" | "INR" | "ISK" | "JMD" | "JPY" | "KES" | "KGS" | "KHR" | "KMF" | "KRW" | "KYD" | "KZT" | "LAK" | "LBP" | "LKR" | "LRD" | "LSL" | "MAD" | "MDL" | "MGA" | "MKD" | "MMK" | "MNT" | "MOP" | "MRO" | "MUR" | "MVR" | "MWK" | "MXN" | "MYR" | "MZN" | "NAD" | "NGN" | "NIO" | "NOK" | "NPR" | "NZD" | "PAB" | "PEN" | "PGK" | "PHP" | "PKR" | "PLN" | "PYG" | "QAR" | "RON" | "RSD" | "RUB" | "RWF" | "SAR" | "SBD" | "SCR" | "SEK" | "SGD" | "SHP" | "SLL" | "SOS" | "SRD" | "STD" | "SYP" | "SZL" | "THB" | "TJS" | "TND" | "TOP" | "TRY" | "TTD" | "TWD" | "TZS" | "UAH" | "UGX" | "USD" | "UYU" | "UZS" | "VND" | "VUV" | "WST" | "XAF" | "XCD" | "XOF" | "XPF" | "YER" | "ZAR" | "ZMW";
|
|
3
3
|
/** @example "US" */
|
|
4
4
|
export type CountryOrNull = "AD" | "AE" | "AF" | "AG" | "AI" | "AL" | "AM" | "AO" | "AQ" | "AR" | "AS" | "AT" | "AU" | "AW" | "AX" | "AZ" | "BA" | "BB" | "BD" | "BE" | "BF" | "BG" | "BH" | "BI" | "BJ" | "BL" | "BM" | "BN" | "BO" | "BQ" | "BR" | "BS" | "BT" | "BV" | "BW" | "BY" | "BZ" | "CA" | "CC" | "CD" | "CF" | "CG" | "CH" | "CI" | "CK" | "CL" | "CM" | "CN" | "CO" | "CR" | "CU" | "CV" | "CW" | "CX" | "CY" | "CZ" | "DE" | "DJ" | "DK" | "DM" | "DO" | "DZ" | "EC" | "EE" | "EG" | "EH" | "ER" | "ES" | "ET" | "FI" | "FJ" | "FK" | "FM" | "FO" | "FR" | "GA" | "GB" | "GD" | "GE" | "GF" | "GG" | "GH" | "GI" | "GL" | "GM" | "GN" | "GP" | "GQ" | "GR" | "GS" | "GT" | "GU" | "GW" | "GY" | "HK" | "HM" | "HN" | "HR" | "HT" | "HU" | "ID" | "IE" | "IL" | "IM" | "IN" | "IO" | "IQ" | "IR" | "IS" | "IT" | "JE" | "JM" | "JO" | "JP" | "KE" | "KG" | "KH" | "KI" | "KM" | "KN" | "KP" | "KR" | "KW" | "KY" | "KZ" | "LA" | "LB" | "LC" | "LI" | "LK" | "LR" | "LS" | "LT" | "LU" | "LV" | "LY" | "MA" | "MC" | "MD" | "ME" | "MF" | "MG" | "MH" | "MK" | "ML" | "MM" | "MN" | "MO" | "MP" | "MQ" | "MR" | "MS" | "MT" | "MU" | "MV" | "MW" | "MX" | "MY" | "MZ" | "NA" | "NC" | "NE" | "NF" | "NG" | "NI" | "NL" | "NO" | "NP" | "NR" | "NU" | "NZ" | "OM" | "PA" | "PE" | "PF" | "PG" | "PH" | "PK" | "PL" | "PM" | "PN" | "PR" | "PS" | "PT" | "PW" | "PY" | "QA" | "RE" | "RO" | "RS" | "RU" | "RW" | "SA" | "SB" | "SC" | "SD" | "SE" | "SG" | "SH" | "SI" | "SJ" | "SK" | "SL" | "SM" | "SN" | "SO" | "SR" | "SS" | "ST" | "SV" | "SX" | "SY" | "SZ" | "TC" | "TD" | "TF" | "TG" | "TH" | "TJ" | "TK" | "TL" | "TM" | "TN" | "TO" | "TR" | "TT" | "TV" | "TW" | "TZ" | "UA" | "UG" | "UM" | "US" | "UY" | "UZ" | "VA" | "VC" | "VE" | "VG" | "VI" | "VN" | "VU" | "WF" | "WS" | "YE" | "YT" | "ZA" | "ZM" | "ZW";
|
|
5
5
|
/** @example "America/Los_Angeles" */
|
|
@@ -1072,7 +1072,7 @@ export interface Usages {
|
|
|
1072
1072
|
usages: UsageObject[];
|
|
1073
1073
|
}
|
|
1074
1074
|
/** @example "USD" */
|
|
1075
|
-
export type CurrencyOrNull = "AED" | "AFN" | "ALL" | "AMD" | "ANG" | "AOA" | "ARS" | "AUD" | "AWG" | "AZN" | "BAM" | "BBD" | "BDT" | "BGN" | "BIF" | "BMD" | "BND" | "BOB" | "BRL" | "BSD" | "BWP" | "BYN" | "BZD" | "CAD" | "CDF" | "CHF" | "CLF" | "CLP" | "CNY" | "COP" | "CRC" | "CVE" | "CZK" | "DJF" | "DKK" | "DOP" | "DZD" | "EGP" | "ETB" | "EUR" | "FJD" | "FKP" | "GBP" | "GEL" | "GIP" | "GMD" | "GNF" | "GTQ" | "GYD" | "HKD" | "HNL" | "HRK" | "HTG" | "HUF" | "IDR" | "ILS" | "INR" | "ISK" | "JMD" | "JPY" | "KES" | "KGS" | "KHR" | "KMF" | "KRW" | "KYD" | "KZT" | "LAK" | "LBP" | "LKR" | "LRD" | "LSL" | "MAD" | "MDL" | "MGA" | "MKD" | "MMK" | "MNT" | "MOP" | "MRO" | "MUR" | "MVR" | "MWK" | "MXN" | "MYR" | "MZN" | "NAD" | "NGN" | "NIO" | "NOK" | "NPR" | "NZD" | "PAB" | "PEN" | "PGK" | "PHP" | "PKR" | "PLN" | "PYG" | "QAR" | "RON" | "RSD" | "RUB" | "RWF" | "SAR" | "SBD" | "SCR" | "SEK" | "SGD" | "SHP" | "SLL" | "SOS" | "SRD" | "STD" | "SZL" | "THB" | "TJS" | "TOP" | "TRY" | "TTD" | "TWD" | "TZS" | "UAH" | "UGX" | "USD" | "UYU" | "UZS" | "VND" | "VUV" | "WST" | "XAF" | "XCD" | "XOF" | "XPF" | "YER" | "ZAR" | "ZMW";
|
|
1075
|
+
export type CurrencyOrNull = "AED" | "AFN" | "ALL" | "AMD" | "ANG" | "AOA" | "ARS" | "AUD" | "AWG" | "AZN" | "BAM" | "BBD" | "BDT" | "BGN" | "BIF" | "BMD" | "BND" | "BOB" | "BRL" | "BSD" | "BWP" | "BYN" | "BZD" | "CAD" | "CDF" | "CHF" | "CLF" | "CLP" | "CNY" | "COP" | "CRC" | "CVE" | "CZK" | "DJF" | "DKK" | "DOP" | "DZD" | "EGP" | "ETB" | "EUR" | "FJD" | "FKP" | "GBP" | "GEL" | "GIP" | "GMD" | "GNF" | "GTQ" | "GYD" | "HKD" | "HNL" | "HRK" | "HTG" | "HUF" | "IDR" | "ILS" | "INR" | "ISK" | "JMD" | "JPY" | "KES" | "KGS" | "KHR" | "KMF" | "KRW" | "KYD" | "KZT" | "LAK" | "LBP" | "LKR" | "LRD" | "LSL" | "MAD" | "MDL" | "MGA" | "MKD" | "MMK" | "MNT" | "MOP" | "MRO" | "MUR" | "MVR" | "MWK" | "MXN" | "MYR" | "MZN" | "NAD" | "NGN" | "NIO" | "NOK" | "NPR" | "NZD" | "PAB" | "PEN" | "PGK" | "PHP" | "PKR" | "PLN" | "PYG" | "QAR" | "RON" | "RSD" | "RUB" | "RWF" | "SAR" | "SBD" | "SCR" | "SEK" | "SGD" | "SHP" | "SLL" | "SOS" | "SRD" | "STD" | "SYP" | "SZL" | "THB" | "TJS" | "TND" | "TOP" | "TRY" | "TTD" | "TWD" | "TZS" | "UAH" | "UGX" | "USD" | "UYU" | "UZS" | "VND" | "VUV" | "WST" | "XAF" | "XCD" | "XOF" | "XPF" | "YER" | "ZAR" | "ZMW";
|
|
1076
1076
|
export interface AppliedCouponObject {
|
|
1077
1077
|
/**
|
|
1078
1078
|
* Unique identifier of the applied coupon, created by Lago.
|
|
@@ -1096,6 +1096,11 @@ export interface AppliedCouponObject {
|
|
|
1096
1096
|
* @example "Startup Deal"
|
|
1097
1097
|
*/
|
|
1098
1098
|
coupon_name: string;
|
|
1099
|
+
/**
|
|
1100
|
+
* The description of the parent coupon.
|
|
1101
|
+
* @example "I am a coupon description"
|
|
1102
|
+
*/
|
|
1103
|
+
coupon_description?: string | null;
|
|
1099
1104
|
/**
|
|
1100
1105
|
* The status of the parent coupon. Can be either `active` or `terminated`.
|
|
1101
1106
|
* @example "active"
|
|
@@ -3805,7 +3810,7 @@ export interface PaymentObject {
|
|
|
3805
3810
|
/** List of invoice IDs associated with the payment. */
|
|
3806
3811
|
invoice_ids: string[];
|
|
3807
3812
|
/** List of invoice numbers associated with the payment. */
|
|
3808
|
-
invoice_numbers
|
|
3813
|
+
invoice_numbers: string[];
|
|
3809
3814
|
/**
|
|
3810
3815
|
* The unique identifier of the paid resource, created by Lago.
|
|
3811
3816
|
* @format uuid
|
|
@@ -3843,15 +3848,15 @@ export interface PaymentObject {
|
|
|
3843
3848
|
*/
|
|
3844
3849
|
type: "manual" | "provider";
|
|
3845
3850
|
/**
|
|
3846
|
-
* Reference for the payment.
|
|
3851
|
+
* Reference for the payment. Set on manual payments only; it is always `null` for payments collected through a payment provider.
|
|
3847
3852
|
* @example "ref1"
|
|
3848
3853
|
*/
|
|
3849
|
-
reference: string;
|
|
3854
|
+
reference: string | null;
|
|
3850
3855
|
/**
|
|
3851
|
-
* Code of the payment provider
|
|
3856
|
+
* Code of the payment provider. It is `null` for manual payments, which are not attached to a payment provider.
|
|
3852
3857
|
* @example "stripe_prod"
|
|
3853
3858
|
*/
|
|
3854
|
-
payment_provider_code: string;
|
|
3859
|
+
payment_provider_code: string | null;
|
|
3855
3860
|
/**
|
|
3856
3861
|
* The type of payment provider
|
|
3857
3862
|
* @example "stripe"
|
|
@@ -3865,16 +3870,10 @@ export interface PaymentObject {
|
|
|
3865
3870
|
*/
|
|
3866
3871
|
provider_payment_id: string | null;
|
|
3867
3872
|
/**
|
|
3868
|
-
* Unique identifier of the customer within the payment provider
|
|
3873
|
+
* Unique identifier of the customer within the payment provider. It is `null` for manual payments.
|
|
3869
3874
|
* @example "cus_5eb0285bcf941bc6ba"
|
|
3870
3875
|
*/
|
|
3871
|
-
provider_customer_id: string;
|
|
3872
|
-
/**
|
|
3873
|
-
* The unique identifier of the payment method used for this payment.
|
|
3874
|
-
* @format uuid
|
|
3875
|
-
* @example "1a901a90-1a90-1a90-1a90-1a901a901a90"
|
|
3876
|
-
*/
|
|
3877
|
-
payment_method_id?: string | null;
|
|
3876
|
+
provider_customer_id: string | null;
|
|
3878
3877
|
/**
|
|
3879
3878
|
* The next action to be taken by the customer to complete the payment. Should usually be empty, except when receiving the `payment.requires_action` webhook.
|
|
3880
3879
|
* @example {"type":"redirect_to_url","redirect_to_url":{"url":"https://hooks.stripe.com/3d_secure_2/hosted?merchant=acct_AAA&payment_intent=pi_BBB&payment_intent_client_secret=pi_BBB&publishable_key=pk_test_CCC","return_url":"https://app.example.com"}}
|
|
@@ -3899,11 +3898,11 @@ export interface PaymentRequestObject {
|
|
|
3899
3898
|
*/
|
|
3900
3899
|
lago_id: string;
|
|
3901
3900
|
/**
|
|
3902
|
-
* The
|
|
3901
|
+
* The email address used for sending dunning notifications. It defaults to the customer's own email address, and is `null` when the customer has none.
|
|
3903
3902
|
* @format email
|
|
3904
3903
|
* @example "dinesh@piedpiper.test"
|
|
3905
3904
|
*/
|
|
3906
|
-
email: string;
|
|
3905
|
+
email: string | null;
|
|
3907
3906
|
/**
|
|
3908
3907
|
* The sum of the total amounts of all the invoices included in the payment request, expressed in cents.
|
|
3909
3908
|
* @example 100
|
|
@@ -4378,7 +4377,7 @@ export interface WalletObject {
|
|
|
4378
4377
|
*/
|
|
4379
4378
|
code?: string | null;
|
|
4380
4379
|
/**
|
|
4381
|
-
* Wallet priority for ordering when a customer has multiple wallets. Allowed values: 1-50, where 1 is highest priority and 50 is lowest. Defaults to 50.
|
|
4380
|
+
* Wallet priority for ordering when a customer has multiple wallets. Allowed values: 1-50, where 1 is highest priority and 50 is lowest. Defaults to 50. Wallets with the same priority are applied by expiration date, soonest first, with wallets without an expiration date last, then by creation date, oldest first.
|
|
4382
4381
|
* @min 1
|
|
4383
4382
|
* @max 50
|
|
4384
4383
|
* @example 50
|
|
@@ -4522,7 +4521,7 @@ export interface InvoiceCustomSectionInput {
|
|
|
4522
4521
|
invoice_custom_section_codes?: string[];
|
|
4523
4522
|
}
|
|
4524
4523
|
export interface WalletCreateInput {
|
|
4525
|
-
wallet
|
|
4524
|
+
wallet: {
|
|
4526
4525
|
/**
|
|
4527
4526
|
* The name of the wallet.
|
|
4528
4527
|
* @example "Prepaid"
|
|
@@ -4534,7 +4533,7 @@ export interface WalletCreateInput {
|
|
|
4534
4533
|
*/
|
|
4535
4534
|
code?: string | null;
|
|
4536
4535
|
/**
|
|
4537
|
-
* Wallet priority for ordering when a customer has multiple wallets. Allowed values: 1-50, where 1 is highest priority and 50 is lowest. Defaults to 50.
|
|
4536
|
+
* Wallet priority for ordering when a customer has multiple wallets. Allowed values: 1-50, where 1 is highest priority and 50 is lowest. Defaults to 50. Wallets with the same priority are applied by expiration date, soonest first, with wallets without an expiration date last, then by creation date, oldest first.
|
|
4538
4537
|
* @min 1
|
|
4539
4538
|
* @max 50
|
|
4540
4539
|
* @example 50
|
|
@@ -4594,6 +4593,13 @@ export interface WalletCreateInput {
|
|
|
4594
4593
|
* @example "Tokens for models 'high-fidelity-boost'"
|
|
4595
4594
|
*/
|
|
4596
4595
|
transaction_name?: string | null;
|
|
4596
|
+
/**
|
|
4597
|
+
* The priority of the wallet transactions triggered when creating the wallet. It drives the order in which credits are consumed. Allowed values: 1-50, where 1 is highest priority and 50 is lowest. Defaults to 50.
|
|
4598
|
+
* @min 1
|
|
4599
|
+
* @max 50
|
|
4600
|
+
* @example 50
|
|
4601
|
+
*/
|
|
4602
|
+
transaction_priority?: number;
|
|
4597
4603
|
/**
|
|
4598
4604
|
* The purchase order number associated with the wallet. It will be added to invoices generated for wallet top-ups, unless a more specific purchase order number is set on the wallet transaction or recurring transaction rule that triggered the top-up.
|
|
4599
4605
|
* @example "PO-123"
|
|
@@ -4653,7 +4659,7 @@ export interface WalletUpdateInput {
|
|
|
4653
4659
|
*/
|
|
4654
4660
|
code?: string | null;
|
|
4655
4661
|
/**
|
|
4656
|
-
* Wallet priority for ordering when a customer has multiple wallets. Allowed values: 1-50, where 1 is highest priority and 50 is lowest. Defaults to 50.
|
|
4662
|
+
* Wallet priority for ordering when a customer has multiple wallets. Allowed values: 1-50, where 1 is highest priority and 50 is lowest. Defaults to 50. Wallets with the same priority are applied by expiration date, soonest first, with wallets without an expiration date last, then by creation date, oldest first.
|
|
4657
4663
|
* @min 1
|
|
4658
4664
|
* @max 50
|
|
4659
4665
|
* @example 50
|
|
@@ -4670,6 +4676,16 @@ export interface WalletUpdateInput {
|
|
|
4670
4676
|
* @example false
|
|
4671
4677
|
*/
|
|
4672
4678
|
invoice_requires_successful_payment?: boolean;
|
|
4679
|
+
/**
|
|
4680
|
+
* Minimum amount of cents that can be top-up with a single paid transaction.
|
|
4681
|
+
* @example 100
|
|
4682
|
+
*/
|
|
4683
|
+
paid_top_up_min_amount_cents?: number | null;
|
|
4684
|
+
/**
|
|
4685
|
+
* Maximum amount of cents that can be top-up with a single paid transaction.
|
|
4686
|
+
* @example 1000
|
|
4687
|
+
*/
|
|
4688
|
+
paid_top_up_max_amount_cents?: number | null;
|
|
4673
4689
|
/**
|
|
4674
4690
|
* The code of the billing entity associated with the wallet.
|
|
4675
4691
|
* @example "default"
|
|
@@ -5470,14 +5486,14 @@ export interface PaymentMethodObject {
|
|
|
5470
5486
|
* Code of the payment provider associated with this payment method.
|
|
5471
5487
|
* @example "stripe_prod"
|
|
5472
5488
|
*/
|
|
5473
|
-
payment_provider_code
|
|
5489
|
+
payment_provider_code: string | null;
|
|
5474
5490
|
/**
|
|
5475
5491
|
* Human-readable name of the payment provider.
|
|
5476
5492
|
* @example "Stripe"
|
|
5477
5493
|
*/
|
|
5478
|
-
payment_provider_name
|
|
5494
|
+
payment_provider_name: string | null;
|
|
5479
5495
|
/**
|
|
5480
|
-
* The type of the payment provider.
|
|
5496
|
+
* The type of the payment provider. It is `null` when the payment method is no longer attached to a payment provider.
|
|
5481
5497
|
* @example "stripe"
|
|
5482
5498
|
*/
|
|
5483
5499
|
payment_provider_type: "adyen" | "cashfree" | "gocardless" | "stripe" | "flutterwave" | "moneyhash";
|
|
@@ -7185,6 +7201,16 @@ export interface PaymentReceiptObject {
|
|
|
7185
7201
|
* @example "LAG-1234-001-002"
|
|
7186
7202
|
*/
|
|
7187
7203
|
number: string;
|
|
7204
|
+
/**
|
|
7205
|
+
* The PDF file of the payment receipt. It is `null` while no PDF has been generated.
|
|
7206
|
+
* @example "https://getlago.com/payment_receipt/file"
|
|
7207
|
+
*/
|
|
7208
|
+
file_url?: string | null;
|
|
7209
|
+
/**
|
|
7210
|
+
* The e-invoicing XML file of the payment receipt. It is `null` while no XML file has been generated.
|
|
7211
|
+
* @example "https://getlago.com/payment_receipt/xml"
|
|
7212
|
+
*/
|
|
7213
|
+
xml_url?: string | null;
|
|
7188
7214
|
payment: PaymentObject;
|
|
7189
7215
|
}
|
|
7190
7216
|
export interface PaymentReceiptsPaginated {
|
|
@@ -7202,11 +7228,11 @@ export interface PaymentRequestCreateInput {
|
|
|
7202
7228
|
*/
|
|
7203
7229
|
external_customer_id: string;
|
|
7204
7230
|
/**
|
|
7205
|
-
* The
|
|
7231
|
+
* The email address used for sending dunning notifications. When omitted, the customer's own email address is used.
|
|
7206
7232
|
* @format email
|
|
7207
7233
|
* @example "dinesh@piedpiper.test"
|
|
7208
7234
|
*/
|
|
7209
|
-
email
|
|
7235
|
+
email?: string;
|
|
7210
7236
|
/** A list of Lago IDs for the customer's overdue invoices to start the dunning process */
|
|
7211
7237
|
lago_invoice_ids: string[];
|
|
7212
7238
|
/** Optional payment method to use for processing the payment request. */
|
|
@@ -7230,6 +7256,7 @@ export interface PaymentCreateInput {
|
|
|
7230
7256
|
amount_cents: number;
|
|
7231
7257
|
/**
|
|
7232
7258
|
* Reference for the payment
|
|
7259
|
+
* @maxLength 40
|
|
7233
7260
|
* @example "ref1"
|
|
7234
7261
|
*/
|
|
7235
7262
|
reference: string;
|
|
@@ -9549,6 +9576,19 @@ export interface WalletTransactionCreateInput {
|
|
|
9549
9576
|
* @example "5.0"
|
|
9550
9577
|
*/
|
|
9551
9578
|
voided_credits?: string | null;
|
|
9579
|
+
/**
|
|
9580
|
+
* Unique identifier of the inbound wallet transaction to void. Only available on traceable wallets, and the target transaction must still have a remaining amount.
|
|
9581
|
+
* @format uuid
|
|
9582
|
+
* @example "1a901a90-1a90-1a90-1a90-1a901a901a90"
|
|
9583
|
+
*/
|
|
9584
|
+
voided_transaction_id?: string | null;
|
|
9585
|
+
/**
|
|
9586
|
+
* The priority of the wallet transaction. It drives the order in which credits are consumed. Allowed values: 1-50, where 1 is highest priority and 50 is lowest. Defaults to 50.
|
|
9587
|
+
* @min 1
|
|
9588
|
+
* @max 50
|
|
9589
|
+
* @example 50
|
|
9590
|
+
*/
|
|
9591
|
+
priority?: number;
|
|
9552
9592
|
/**
|
|
9553
9593
|
* A boolean setting that, when set to true, delays issuing an invoice for a wallet top-up until a successful payment is made; if false, the invoice is issued immediately upon wallet top-up, regardless of the payment status. Default value of false.
|
|
9554
9594
|
* @example false
|
|
@@ -9588,6 +9628,11 @@ export interface WalletTransactionObject {
|
|
|
9588
9628
|
* @example "1a901a90-1a90-1a90-1a90-1a901a901a90"
|
|
9589
9629
|
*/
|
|
9590
9630
|
lago_wallet_id: string;
|
|
9631
|
+
/**
|
|
9632
|
+
* The code of the billing entity associated with the wallet transaction. Falls back to the wallet's billing entity when the transaction does not carry one.
|
|
9633
|
+
* @example "default"
|
|
9634
|
+
*/
|
|
9635
|
+
billing_entity_code?: string;
|
|
9591
9636
|
/**
|
|
9592
9637
|
* Unique identifier assigned to the invoice associated with this wallet transaction. This ID is exclusively created by Lago and serves as a unique identifier for the invoice's record within the Lago system.
|
|
9593
9638
|
* @format uuid
|
|
@@ -10427,7 +10472,7 @@ export declare class HttpClient<SecurityDataType = unknown> {
|
|
|
10427
10472
|
}
|
|
10428
10473
|
/**
|
|
10429
10474
|
* @title Lago API documentation
|
|
10430
|
-
* @version 1.
|
|
10475
|
+
* @version 1.54.0
|
|
10431
10476
|
* @license AGPLv3 (https://github.com/getlago/lago-openapi/blob/main/LICENSE)
|
|
10432
10477
|
* @baseUrl https://api.getlago.com/api/v1
|
|
10433
10478
|
* @externalDocs https://github.com/getlago
|
|
@@ -11665,6 +11710,11 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
11665
11710
|
* @example 20
|
|
11666
11711
|
*/
|
|
11667
11712
|
per_page?: number;
|
|
11713
|
+
/**
|
|
11714
|
+
* Filter the results by currency, expressed as an ISO 4217 code.
|
|
11715
|
+
* @example "EUR"
|
|
11716
|
+
*/
|
|
11717
|
+
currency?: string;
|
|
11668
11718
|
/**
|
|
11669
11719
|
* Filter by payment status. Possible values are `pending`, `failed` or `succeeded`.
|
|
11670
11720
|
* @example "pending"
|
|
@@ -11765,6 +11815,11 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
11765
11815
|
* @example 20
|
|
11766
11816
|
*/
|
|
11767
11817
|
per_page?: number;
|
|
11818
|
+
/**
|
|
11819
|
+
* Filter the results by currency, expressed as an ISO 4217 code.
|
|
11820
|
+
* @example "EUR"
|
|
11821
|
+
*/
|
|
11822
|
+
currency?: string;
|
|
11768
11823
|
/**
|
|
11769
11824
|
* Filter wallets by billing entity codes.
|
|
11770
11825
|
* @example ["billing_entity_code_1","billing_entity_code_2"]
|
|
@@ -11850,7 +11905,18 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
11850
11905
|
* @request GET:/customers/{external_customer_id}/wallets/{wallet_code}/alerts
|
|
11851
11906
|
* @secure
|
|
11852
11907
|
*/
|
|
11853
|
-
getCustomerWalletAlerts: (externalCustomerId: string, walletCode: string,
|
|
11908
|
+
getCustomerWalletAlerts: (externalCustomerId: string, walletCode: string, query?: {
|
|
11909
|
+
/**
|
|
11910
|
+
* Page number.
|
|
11911
|
+
* @example 1
|
|
11912
|
+
*/
|
|
11913
|
+
page?: number;
|
|
11914
|
+
/**
|
|
11915
|
+
* Number of records per page.
|
|
11916
|
+
* @example 20
|
|
11917
|
+
*/
|
|
11918
|
+
per_page?: number;
|
|
11919
|
+
}, params?: RequestParams) => Promise<HttpResponse<WalletAlerts, ApiErrorUnauthorized | ApiErrorNotFound>>;
|
|
11854
11920
|
/**
|
|
11855
11921
|
* @description This endpoint allows you to create new alerts for a wallet. Send a single alert object wrapped in `alert` key to create one alert, or an array of alert objects wrapped in `alerts` key to create multiple alerts atomically.
|
|
11856
11922
|
*
|
|
@@ -12066,7 +12132,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
12066
12132
|
per_page?: number;
|
|
12067
12133
|
}, params?: RequestParams) => Promise<HttpResponse<PaymentMethodsPaginated, ApiErrorUnauthorized | ApiErrorNotFound>>;
|
|
12068
12134
|
/**
|
|
12069
|
-
* @description
|
|
12135
|
+
* @description This endpoint sets a payment method as the customer's default one. It is the payment method Lago uses when a payment is triggered without an explicit one. Any other default payment method of the customer is unset.
|
|
12070
12136
|
*
|
|
12071
12137
|
* @tags payment_methods
|
|
12072
12138
|
* @name PaymentMethodSetAsDefault
|
|
@@ -13593,6 +13659,16 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
13593
13659
|
* @example "active"
|
|
13594
13660
|
*/
|
|
13595
13661
|
subscription_status?: "pending" | "active" | "terminated" | "canceled";
|
|
13662
|
+
/**
|
|
13663
|
+
* Page number.
|
|
13664
|
+
* @example 1
|
|
13665
|
+
*/
|
|
13666
|
+
page?: number;
|
|
13667
|
+
/**
|
|
13668
|
+
* Number of records per page.
|
|
13669
|
+
* @example 20
|
|
13670
|
+
*/
|
|
13671
|
+
per_page?: number;
|
|
13596
13672
|
}, params?: RequestParams) => Promise<HttpResponse<Alerts, ApiErrorUnauthorized | ApiErrorNotFound>>;
|
|
13597
13673
|
/**
|
|
13598
13674
|
* @description This endpoint allows you to create alerts for a subscription. Send a single alert object wrapped in `alert` key to create one alert, or an array of alert objects wrapped in `alerts` key to create multiple alerts atomically.
|
|
@@ -14180,6 +14256,11 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
14180
14256
|
* @example "inbound"
|
|
14181
14257
|
*/
|
|
14182
14258
|
transaction_type?: string;
|
|
14259
|
+
/**
|
|
14260
|
+
* Filter wallet transactions by metadata. Replace `key` with the actual metadata key you want to match, and provide the corresponding value. For example, `metadata[color]=blue`.
|
|
14261
|
+
* @example "someValue"
|
|
14262
|
+
*/
|
|
14263
|
+
"metadata[key]"?: string;
|
|
14183
14264
|
}, params?: RequestParams) => Promise<HttpResponse<WalletTransactionsPaginated, ApiErrorUnauthorized | ApiErrorForbidden | ApiErrorNotFound>>;
|
|
14184
14265
|
};
|
|
14185
14266
|
walletTransactions: {
|
package/esm/openapi/client.js
CHANGED
|
@@ -156,7 +156,7 @@ export class HttpClient {
|
|
|
156
156
|
}
|
|
157
157
|
/**
|
|
158
158
|
* @title Lago API documentation
|
|
159
|
-
* @version 1.
|
|
159
|
+
* @version 1.54.0
|
|
160
160
|
* @license AGPLv3 (https://github.com/getlago/lago-openapi/blob/main/LICENSE)
|
|
161
161
|
* @baseUrl https://api.getlago.com/api/v1
|
|
162
162
|
* @externalDocs https://github.com/getlago
|
|
@@ -1381,9 +1381,10 @@ export class Api extends HttpClient {
|
|
|
1381
1381
|
* @request GET:/customers/{external_customer_id}/wallets/{wallet_code}/alerts
|
|
1382
1382
|
* @secure
|
|
1383
1383
|
*/
|
|
1384
|
-
getCustomerWalletAlerts: (externalCustomerId, walletCode, params = {}) => this.request({
|
|
1384
|
+
getCustomerWalletAlerts: (externalCustomerId, walletCode, query, params = {}) => this.request({
|
|
1385
1385
|
path: `/customers/${externalCustomerId}/wallets/${walletCode}/alerts`,
|
|
1386
1386
|
method: "GET",
|
|
1387
|
+
query: query,
|
|
1387
1388
|
secure: true,
|
|
1388
1389
|
format: "json",
|
|
1389
1390
|
...params,
|
|
@@ -1556,7 +1557,7 @@ export class Api extends HttpClient {
|
|
|
1556
1557
|
...params,
|
|
1557
1558
|
}),
|
|
1558
1559
|
/**
|
|
1559
|
-
* @description
|
|
1560
|
+
* @description This endpoint sets a payment method as the customer's default one. It is the payment method Lago uses when a payment is triggered without an explicit one. Any other default payment method of the customer is unset.
|
|
1560
1561
|
*
|
|
1561
1562
|
* @tags payment_methods
|
|
1562
1563
|
* @name PaymentMethodSetAsDefault
|