summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2016-01-27 15:09:20 +0100
committerChristian Grothoff <christian@grothoff.org>2016-01-27 15:09:20 +0100
commit0217f2b19bc2967a5d27ea42055ea3244647dfcf (patch)
treefe8873ef8e12eadb325a774d74aac46c77ee7052
parent2f285ace2fcdc7993f8191716cfbbf7eb9466245 (diff)
downloaddocs-0217f2b19bc2967a5d27ea42055ea3244647dfcf.tar.gz
docs-0217f2b19bc2967a5d27ea42055ea3244647dfcf.tar.bz2
docs-0217f2b19bc2967a5d27ea42055ea3244647dfcf.zip
update spec for #4159
-rw-r--r--api-merchant.rst27
1 files changed, 22 insertions, 5 deletions
diff --git a/api-merchant.rst b/api-merchant.rst
index 3a7cce1..46c9cee 100644
--- a/api-merchant.rst
+++ b/api-merchant.rst
@@ -121,7 +121,7 @@ The contract must have the following structure:
.. _tsref-type-Product:
.. code-block:: tsref
-
+
interface Product {
// Human-readable product description.
description: string;
@@ -150,7 +150,7 @@ The contract must have the following structure:
.. _tsref-type-Merchant:
.. code-block:: ts
-
+
interface Merchant {
// label for a location with the business address of the merchant
address: string;
@@ -200,7 +200,7 @@ The contract must have the following structure:
// master public key of the mint
master_pub: EddsaPublicKey;
}
-
+
.. _`Signature specification`:
@@ -221,6 +221,25 @@ should be set to ``TALER_SIGNATURE_MERCHANT_CONTRACT``.
struct MERCHANT_Contract
{
struct GNUNET_CRYPTO_EccSignaturePurpose purpose;
+ /**
+ * Transaction ID must match the one in the JSON contract, here given
+ * in big endian.
+ */
+ uint64_t transaction_id;
+
+ /**
+ * Total amount to be paid for the contract, must match JSON "amount".
+ */
+ struct TALER_AmountNBO total_amount;
+
+ /**
+ * Total amount to be paid for the contract, must match JSON "max_fee".
+ */
+ struct TALER_AmountNBO max_fee;
+
+ /**
+ * Hash of the overall JSON contract.
+ */
struct GNUNET_HashCode h_contract;
}
@@ -272,5 +291,3 @@ merchant's offer.
``$pay_url`` in the context of the execution page. This mechanism is
necessary since the request to ``$pay_url`` must be made from the merchant's
origin domain in order to preserve information (e.g. cookies, origin header).
-
-