aboutsummaryrefslogtreecommitdiff
path: root/packages/taler-util
diff options
context:
space:
mode:
Diffstat (limited to 'packages/taler-util')
-rw-r--r--packages/taler-util/src/taler-error-codes.ts8
-rw-r--r--packages/taler-util/src/wallet-types.ts23
2 files changed, 15 insertions, 16 deletions
diff --git a/packages/taler-util/src/taler-error-codes.ts b/packages/taler-util/src/taler-error-codes.ts
index 5e3c8fdfb..9e735817d 100644
--- a/packages/taler-util/src/taler-error-codes.ts
+++ b/packages/taler-util/src/taler-error-codes.ts
@@ -3249,6 +3249,14 @@ export enum TalerErrorCode {
/**
+ * The wallet does not have sufficient balance to pay for an invoice.
+ * Returned with an HTTP status code of #MHD_HTTP_UNINITIALIZED (0).
+ * (A value of 0 indicates that the error is generated client-side).
+ */
+ WALLET_PEER_PULL_PAYMENT_INSUFFICIENT_BALANCE = 7028,
+
+
+ /**
* We encountered a timeout with our payment backend.
* Returned with an HTTP status code of #MHD_HTTP_GATEWAY_TIMEOUT (504).
* (A value of 0 indicates that the error is generated client-side).
diff --git a/packages/taler-util/src/wallet-types.ts b/packages/taler-util/src/wallet-types.ts
index 3a1176021..06edfe285 100644
--- a/packages/taler-util/src/wallet-types.ts
+++ b/packages/taler-util/src/wallet-types.ts
@@ -2164,20 +2164,11 @@ export interface PayPeerInsufficientBalanceDetails {
*/
balanceMaterial: AmountString;
- /**
- * Acceptable balance based on restrictions on which
- * exchange can be used.
- */
- balanceExchangeAcceptable: AmountString
-
- /**
- * If the payment would succeed without fees
- * (i.e. balanceExchangeAcceptable >= amountRequested),
- * this field contains an estimate of the amount that would additionally
- * be required to cover the fees.
- *
- * It is not possible to give an exact value here, since it depends
- * on the coin selection for the amount that would be additionally withdrawn.
- */
- feeGapEstimate: AmountString;
+ perExchange: {
+ [url: string]: {
+ balanceAvailable: AmountString;
+ balanceMaterial: AmountString;
+ feeGapEstimate: AmountString;
+ };
+ };
}