taler-docs

Documentation for GNU Taler components, APIs and protocols
Log | Files | Refs | README | LICENSE

fail-transaction.rst (1117B)


      1 .. ts:op:: failTransaction
      2 
      3   Mark a transaction as failed, giving up on its ongoing processing.
      4 
      5   **Request:**
      6 
      7     The request ``args`` must be a `FailTransactionRequest` object.
      8 
      9   **Response:**
     10 
     11     On success, the result is an empty object.
     12 
     13   **Side effects:**
     14 
     15     Marks an aborting transaction as finally failed, giving up on
     16     the ongoing recovery.
     17 
     18   **Expected errors:**
     19 
     20     The caller can handle the following errors inline:
     21     ``WALLET_TRANSACTION_NOT_FOUND``,
     22     ``WALLET_TRANSACTION_ACTION_UNSUPPORTED``,
     23     ``WALLET_REQUEST_TRANSACTION_STATE_UNSUPPORTED``.
     24 
     25   **Details:**
     26 
     27     This is typically used for transactions in an ``aborting`` state
     28     (for example while recovering an aborted payment via a refund):
     29     the user stops waiting for the recovery, and the transaction
     30     transitions to the final ``failed`` state.  The reason is
     31     recorded in the transaction's ``failReason``.  Whether a
     32     transaction can currently be failed is advertised in its
     33     ``txActions``.
     34 
     35 .. ts:def:: FailTransactionRequest
     36 
     37   interface FailTransactionRequest {
     38     transactionId: TransactionIdStr;
     39   }