summaryrefslogtreecommitdiff
path: root/taler-wallet.rst
diff options
context:
space:
mode:
Diffstat (limited to 'taler-wallet.rst')
-rw-r--r--taler-wallet.rst52
1 files changed, 42 insertions, 10 deletions
diff --git a/taler-wallet.rst b/taler-wallet.rst
index 11167ea..beae206 100644
--- a/taler-wallet.rst
+++ b/taler-wallet.rst
@@ -92,8 +92,8 @@ Transactions are all operations or events that are affecting the balance.
.. ts:def:: TransactionsRequest
interface TransactionsRequest {
- // return only transactions in the given currency
- currency: string;
+ // return only transactions in the given currency, if present
+ currency?: string;
// if present, results will be limited to transactions related to the given search string
search?: string;
@@ -177,9 +177,8 @@ Transactions are all operations or events that are affecting the balance.
// Additional information about the payment.
info: TransactionInfo;
- // true if the payment failed, false otherwise.
- // Note that failed payments with zero effective amount will not be returned by the API.
- failed: boolean;
+ // The current status of this payment.
+ status: PaymentStatus;
// Amount that must be paid for the contract
amountRaw: Amount;
@@ -210,6 +209,26 @@ Transactions are all operations or events that are affecting the balance.
fulfillmentUrl: string;
}
+ .. ts:def:: PaymentStatus
+
+ enum PaymentStatus {
+ // Explicitly aborted after timeout / failure
+ Aborted = "aborted",
+
+ // Payment failed, wallet will auto-retry.
+ // User should be given the option to retry now / abort.
+ Failed = "failed",
+
+ // Paid successfully
+ Paid = "paid",
+
+ // Only offered, user must accept / decline
+ Offered = "offered",
+
+ // User accepted, payment is processing.
+ Accepted = "accepted",
+ }
+
.. ts:def:: TransactionRefund
interface TransactionRefund extends Transaction {
@@ -236,11 +255,8 @@ Transactions are all operations or events that are affecting the balance.
interface TransactionTip extends Transaction {
type: string = "tip",
- // true if the user still needs to accept/decline this tip
- waiting: boolean;
-
- // true if the user has accepted this top, false otherwise
- accepted: boolean;
+ // The current status of this tip.
+ status: TipStatus;
// Exchange that the tip will be (or was) withdrawn from
exchangeBaseUrl: string;
@@ -255,6 +271,22 @@ Transactions are all operations or events that are affecting the balance.
amountEffective: Amount;
}
+ .. ts:def:: TipStatus
+
+ enum TipStatus {
+ // Only offered, user must accept / decline
+ Offered = "offered",
+
+ // User accepted, tip is processing.
+ Accepted = "accepted",
+
+ // User declined.
+ Declined = "declined",
+
+ // Received successfully
+ Received = "received",
+ }
+
.. ts:def:: TransactionRefresh
// A transaction shown for refreshes that are not associated to other transactions