summaryrefslogtreecommitdiff
path: root/libeufin/api-nexus.rst
diff options
context:
space:
mode:
authorFlorian Dold <florian.dold@gmail.com>2020-05-19 18:24:46 +0530
committerFlorian Dold <florian.dold@gmail.com>2020-05-19 18:24:46 +0530
commita073c127d324bb0667bacff1f94499340c3f6385 (patch)
treed8f615a2022bf36a747e95615dc5770da9cd0ec0 /libeufin/api-nexus.rst
parentc6014d72d0db9f199a6462c9841ffa4785985d45 (diff)
downloaddocs-a073c127d324bb0667bacff1f94499340c3f6385.tar.gz
docs-a073c127d324bb0667bacff1f94499340c3f6385.tar.bz2
docs-a073c127d324bb0667bacff1f94499340c3f6385.zip
libeufin docs
Diffstat (limited to 'libeufin/api-nexus.rst')
-rw-r--r--libeufin/api-nexus.rst111
1 files changed, 51 insertions, 60 deletions
diff --git a/libeufin/api-nexus.rst b/libeufin/api-nexus.rst
index 681811aa..f175c9d9 100644
--- a/libeufin/api-nexus.rst
+++ b/libeufin/api-nexus.rst
@@ -36,7 +36,7 @@ Users Management
.. http:post:: <nexus>/users
- Create a new user. Only the super-user can call this API.
+ Create a new user. Only a superuser can call this API.
**Request:**
@@ -59,6 +59,11 @@ Users Management
password: string;
}
+
+.. http:get:: <nexus>/users
+
+ Return list of users.
+
Bank Account Management
-----------------------
@@ -95,27 +100,13 @@ Bank Account Management
// to submit at the bank.
uuid: string;
- // Specify the bank transport to use for the submission.
- transport?: Transport;
+ // Specify the bank connectionto use for the submission.
+ connection?: string;
}
- .. ts:def:: Transport
-
- interface Transport {
-
- // Transport type: 'ebics', 'local', 'fints' (forthcoming).
- // It must match one of the types actually implemented by
- // nexus.
- type: string;
-
- // A mnemonic identifier given by the user to one particular
- // transport instance.
- name: string;
- }
-
:status 404 Not Found: the unique identifier **or**
- the bank transport could not be found in the system
+ the bank connection could not be found in the system
.. http:get:: <nexus>/bank-accounts/<my-acct>/prepared-payments/$uuid
@@ -193,16 +184,16 @@ Bank Account Management
.. http:post:: <nexus>/bank-accounts/collected-transactions
- Nexus will download bank transactions from the given transport.
+ Nexus will download bank transactions using the given connection.
**Request:**
.. ts:def:: CollectedTransaction
interface CollectedTransaction {
- // Optional field to specify the bank transport to
+ // Optional field to specify the bank connection to
// use for such operation.
- bankTransport?: Transport;
+ bankConnection: connection;
// dashed date (YYYY-MM-DD) of the earliest payment
// in the result. Optional, defaults to "earliest
// possible" date.
@@ -254,57 +245,58 @@ Bank Account Management
subject: string;
}
-Bank Transports
+
+Bank Connections
---------------
-Bank transports connect the local LibEuFin bank account
+Bank connections connect the local LibEuFin bank account
to the real bank.
-.. http:post:: <nexus>/bank-transports
+.. http:post:: <nexus>/bank-connections
- Activate a new bank transport for the requesting user.
+ Activate a new bank connection for the requesting user.
**Request:**
- .. ts:def:: BankTransport
+ .. ts:def:: BankConnectionRestoreRequest
- interface BankTransport {
+ interface BankConnectionRestoreRequest {
- transport: Transport;
+ name: string;
- // Restore a previous transport. Take precedence
+ // Restore a previous connection. Take precedence
// over the 'new' field.
- backup?: TransportBackup;
+ backup?: BankConnectionBackup;
- // Data to create a fresh bank transport without
+ // Data to create a fresh bank connection without
// restoring any backup.
- data?: TransportNew;
+ data?: BankConnectionNew;
}
- .. ts:def:: TransportNew
+ .. ts:def:: ConnectionNew
- interface TransportNew {
+ interface ConnectionNew {
// This type is strictly dependent on
- // the transport being created. For Ebics,
+ // the connection being created. For Ebics,
// it will contain the required fields (as strings):
// 'ebicsURL', 'userID', 'partnerID', 'hostID', and
// the optional 'systemID'.
- // Other transport types, like 'local' (used for testing
+ // Other connection types, like 'local' (used for testing
// purposes skipping any interaction with the bank service)
// and 'fints' are all work in progress!
}
- .. ts:def:: TransportBackup
+ .. ts:def:: BankConnectionBackup
- interface TransportBackup {
+ interface BankConnectionBackup {
// The information needed in this type depend entirely
- // on which transport is being restored.
+ // on which connectionis being restored.
}
@@ -313,30 +305,29 @@ to the real bank.
:status 409 Conflict: The ``name`` field exists already for
the requesting user.
-.. http:post:: <nexus>/bank-transports/sendMSG.
-
- Perform the ``MSG`` operation offered by ``transport-name``
- **without** affecting the nexus database.
- **Request:**
-
- A `Transport` object.
+.. http:post:: <nexus>/bank-connections
- **Response:**
+ List available bank connections.
- :status 404 Not Found: ``transport-name`` doesn't exist for
- the requesting user.
-.. http:post:: <nexus>/bank-transports/<transport-name>/syncMSG.
-
- Some transports **do** have operations that aren't semantically
- related to a bank account but need to be stored locally at the nexus.
- One typical example is the downloading of the bank's keys vie the
- EBICS transport. This API lets the user perform the ``MSG``
- operation that should result in new data being stored locally
- at the nexus.
+EBICS-specific APIs
+-------------------
- **Response:**
+The following endpoints are only available for EBICS bank connections.
+They are namespaced under the ``/ebics/`` sub-resource.
- :status 404 Not Found: ``transport-name`` doesn't exist for
- the requesting user.
+.. http:post:: <nexus>/bank-connections/<connection-name>/ebics/download/<msg>
+
+
+ Perform an EBICS download transaction of type ``msg``.
+ This request will not affect any bank account or other state
+ in the nexus database. It will just make a request to the bank
+ and return the answer.
+
+.. http:post:: <nexus>/bank-connections/<connection-name>/ebics/upload/<msg>
+
+ Perform an EBICS upload transaction of type ``msg``.
+ This request will not affect any bank account or other state
+ in the nexus database. It will just make a request to the bank
+ and return the answer.