summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--core/api-bank-access.rst51
1 files changed, 51 insertions, 0 deletions
diff --git a/core/api-bank-access.rst b/core/api-bank-access.rst
index 9d9477bf..a5307600 100644
--- a/core/api-bank-access.rst
+++ b/core/api-bank-access.rst
@@ -137,6 +137,57 @@ name and account password, at least in the GNU Taler demo bank implementation.
:http:statuscode:`422 Unprocessable Entity` (New):
The withdraw operation cannot be confirmed because no exchange and reserve public key selection happened before.
+------------
+Transactions
+------------
+
+.. http:GET:: ${BANK_API_BASE_URL}/accounts/${account_name}/transactions
+
+ Retrieve all the transactions where the bank account with the label ``account_name``
+ was debited or credited.
+
+ **Response**
+
+ .. ts:def:: BankAccountTransaction
+
+ interface BankAccountTransactionsResponse {
+ transactions: BankAccountTransaction[];
+ }
+
+.. http:GET:: ${BANK_API_BASE_URL}/accounts/${account_name}/transactions/${transaction_id}
+
+ **Response**
+
+ Retrieve the transaction whose identifier is ``transaction_id``,
+ in the following format:
+
+ .. ts:def:: BankAccountTransaction
+
+ interface BankAccountTransaction {
+
+ creditorIban: string;
+ creditorBic: string;
+ creditorName: string;
+
+ debtorIban: string;
+ debtorBic: string;
+ debtorName: string;
+
+ amount: number;
+ currency: string;
+ subject: string;
+
+ date: string; // YYYY-MM-DD
+ uid: string; // transaction (unique) ID
+ direction: "DBIT" | "CRDT";
+ }
+
+
+.. http:POST:: ${BANK_API_BASE_URL}/accounts/${account_name}/transactions
+
+ Create a new transaction where the bank account with the label ``account_name`` is **debited**.
+
+
----------------------
Registration (Testing)
----------------------