fix(wallet): Add invoice_requires_successful_payment field to Wallet and WalletTransaction models
#341
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Context
The lago API supports setting
invoice_requires_successful_paymentduring creation of Wallet and Wallet Transaction but this python library is missing these variables.This PR fixes that.
Description
This pull request adds support for
invoice_requires_successful_paymentfield to the wallet and wallet transaction models, their response models, and updates related tests to include this field. This change ensures that the client library can handle scenarios where invoices require successful payment for wallet operations.Model updates:
invoice_requires_successful_paymentfield (as an optional boolean) to theWallet,WalletResponse,WalletTransaction, andWalletTransactionResponseclasses inlago_python_client/models/wallet.pyandlago_python_client/models/wallet_transaction.pywhich is supported by lago API. [1] [2] [3] [4]Test updates:
wallet_objectfactory intests/test_wallet_client.pyand thewallet_transaction_objectfactory intests/test_wallet_transaction_client.pyto include theinvoice_requires_successful_paymentfield, ensuring tests validate the functionality. [1] [2]