taler-docs

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

commit 71b57101aaf9887640ade601148d9a237ac92664
parent c2868fced3adf4b57e30dd70e1828d2c72135cae
Author: MS <ms@taler.net>
Date:   Wed, 12 Apr 2023 12:24:29 +0200

Nexus API.

Including the 'index' field into the JSON
Transaction type.

Diffstat:
Mlibeufin/api-nexus.rst | 16++++++++++++++--
1 file changed, 14 insertions(+), 2 deletions(-)

diff --git a/libeufin/api-nexus.rst b/libeufin/api-nexus.rst @@ -390,7 +390,8 @@ tracks the initiations of payments. :query start: Optional number to express the **earliest** transaction index, starting from **1**. For example, if *start* is 6 and three transactions are returned, they will have the following indexes: - 6, 7, 8. This parameter defaults to 1. + 6, x, y, where x and y are both greater than 6 but not necessarily + sequential. This parameter defaults to 1. :query size: Optional number indicating how many transactions are to be included in the response. It defaults to 5. @@ -399,12 +400,23 @@ tracks the initiations of payments. :http:statuscode:`200 OK`: a JSON object with a unique field named ``transactions`` that is a list of `Transaction` objects. This status code applies - even for an **empty** list. + even for an **empty** list. The list is such that index **x-1** + is always a **earlier** transaction than **x**. For example, the + transaction having the 'start' index lies always at index zero. + Note that the order does NOT reflect the transaction's timestamp + as given by the bank, but rather the order that Nexus stored them + into its database. .. ts:def:: Transaction interface Transaction { + // index identifying this transaction at Nexus. + // Note: users can ONLY expect that this index grows + // as new transactions get fetched from the bank, but + // should NOT expect it to grow continuously. + index: number; + // money moved by the transaction amount: string;