gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[taler-docs] branch master updated: Add product images to ContractTerms


From: gnunet
Subject: [taler-docs] branch master updated: Add product images to ContractTerms and PoS config
Date: Tue, 10 Mar 2020 19:18:50 +0100

This is an automated email from the git hooks/post-receive script.

torsten-grote pushed a commit to branch master
in repository docs.

The following commit(s) were added to refs/heads/master by this push:
     new 6f81ed1  Add product images to ContractTerms and PoS config
6f81ed1 is described below

commit 6f81ed1c54dc39de23bc63e9637633ceb8608943
Author: Torsten Grote <address@hidden>
AuthorDate: Tue Mar 10 15:18:23 2020 -0300

    Add product images to ContractTerms and PoS config
---
 core/api-common.rst             | 14 ++++++++++++++
 core/api-merchant.rst           |  3 +++
 taler-merchant-pos-terminal.rst |  3 +++
 3 files changed, 20 insertions(+)

diff --git a/core/api-common.rst b/core/api-common.rst
index a7ebe3a..8a885f0 100644
--- a/core/api-common.rst
+++ b/core/api-common.rst
@@ -342,6 +342,20 @@ When no sign is present, the amount is assumed to be 
positive.
 
   type SignedAmount = string;
 
+Images
+^^^^^^
+
+.. ts:def:: ImageDataUrl
+
+  // The string must be a data URL according to RFC 2397
+  // with explicit mediatype and base64 parameters.
+  //
+  //     ``data:<mediatype>;base64,<data>``
+  //
+  // Supported mediatypes are ``image/jpeg`` and ``image/png``.
+  // Invalid strings will be rejected by the wallet.
+  type ImageDataUrl = string;
+
 
 --------------
 Binary Formats
diff --git a/core/api-merchant.rst b/core/api-merchant.rst
index f6297ae..469ce76 100644
--- a/core/api-merchant.rst
+++ b/core/api-merchant.rst
@@ -873,6 +873,9 @@ The contract terms must have the following structure:
       // merchant-internal identifier for the product
       product_id?: string;
 
+      // An optional base64-encoded product image
+      image?: ImageDataUrl;
+
       // a list of objects indicating a 'taxname' and its amount. Again, 
italics denotes the object field's name.
       taxes?: any[];
 
diff --git a/taler-merchant-pos-terminal.rst b/taler-merchant-pos-terminal.rst
index 27860cf..d65183c 100644
--- a/taler-merchant-pos-terminal.rst
+++ b/taler-merchant-pos-terminal.rst
@@ -163,6 +163,9 @@ The elements of the JSON file are defined as follows:
       // The price of the product
       price: Amount;
 
+      // An optional base64-encoded product image
+      image?: ImageDataUrl;
+
       // A list of category IDs this product belongs to.
       // Typically, a product only belongs to one category, but more than one 
is supported.
       categories: number[];

-- 
To stop receiving notification emails like this one, please contact
address@hidden.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]