summaryrefslogtreecommitdiff
path: root/core/api-merchant.rst
diff options
context:
space:
mode:
authorChristian Grothoff <grothoff@gnunet.org>2023-08-31 19:35:38 +0200
committerChristian Grothoff <grothoff@gnunet.org>2023-08-31 19:35:38 +0200
commit47b4c292a77493d6ea6e9c207632a087867e8025 (patch)
tree6a1b0b728b0c830aca77825094e9b2a83976106d /core/api-merchant.rst
parentea7f2170ae9ee5e1d8de1fc74544280c17a55cc9 (diff)
downloaddocs-47b4c292a77493d6ea6e9c207632a087867e8025.tar.gz
docs-47b4c292a77493d6ea6e9c207632a087867e8025.tar.bz2
docs-47b4c292a77493d6ea6e9c207632a087867e8025.zip
do not let client choose salt
Diffstat (limited to 'core/api-merchant.rst')
-rw-r--r--core/api-merchant.rst18
1 files changed, 15 insertions, 3 deletions
diff --git a/core/api-merchant.rst b/core/api-merchant.rst
index 7b77aba0..80314473 100644
--- a/core/api-merchant.rst
+++ b/core/api-merchant.rst
@@ -1355,12 +1355,12 @@ into any of the active bank accounts of an instance.
**Request:**
- The request must be an `AccountAddDetails`.
+ The request must have an `AccountAddDetails` body.
**Response:**
- :http:statuscode:`204 No content`:
- Adding the account was successful.
+ :http:statuscode:`200 Ok`:
+ Adding the account was successful, we return the salt selected by the backend and the resulting wire hash in an `AccountAddResponse`.
:http:statuscode:`404 Not found`:
The merchant instance is unknown or it is not in our data.
:http:statuscode:`409 Conflict`:
@@ -1419,6 +1419,18 @@ into any of the active bank accounts of an instance.
password: string;
};
+ .. ts:def:: AccountAddResponse
+
+ interface AccountAddResponse {
+
+ // Hash over the wire details (including over the salt).
+ h_wire: HashCode;
+
+ // Salt used to compute h_wire.
+ salt: HashCode;
+
+ }
+
.. http:patch:: [/instances/$INSTANCE]/private/accounts/$H_WIRE