gnunet-svn
[Top][All Lists]
Advanced

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

[taler-docs] 09/11: dd46: shared type TokenClass for input and output to


From: gnunet
Subject: [taler-docs] 09/11: dd46: shared type TokenClass for input and output tokens
Date: Fri, 15 Mar 2024 09:47:02 +0100

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

christian-blaettler pushed a commit to branch master
in repository docs.

commit 9b0678d5fb4b7ffafae92539797858a84680c656
Author: Christian Blättler <blatc2@bfh.ch>
AuthorDate: Tue Mar 5 22:13:54 2024 +0100

    dd46: shared type TokenClass for input and output tokens
---
 design-documents/046-mumimo-contracts.rst | 54 +++++++++++++++++--------------
 1 file changed, 29 insertions(+), 25 deletions(-)

diff --git a/design-documents/046-mumimo-contracts.rst 
b/design-documents/046-mumimo-contracts.rst
index 9c693b01..5f1d1d98 100644
--- a/design-documents/046-mumimo-contracts.rst
+++ b/design-documents/046-mumimo-contracts.rst
@@ -188,7 +188,7 @@ The contract terms v1 will have the following structure:
     extra?: any;
 
     // Fee limits and wire account details by currency.
-    limits: { [currency:string] : CurrencyLimit };
+    limits: { [currency: string]: CurrencyLimit };
   }
 
 .. ts:def:: CurrencyLimit
@@ -303,9 +303,9 @@ The contract terms v1 will have the following structure:
 
     type: "token";
 
-    // Hash over the public key used to sign the
-    // type of subscription token required.
-    h_issuer: HashCode;
+    // Label of the token authority in the
+    // 'token_types' map on the top-level.
+    authority_label: string;
 
     // Number of tokens of this type required.
     // Defaults to one if the field is not provided.
@@ -316,17 +316,17 @@ The contract terms v1 will have the following structure:
 .. ts:def:: ContractOutput
 
   type ContractOutput =
-    | ContractOutputCurrency
-    | ContractOutputTaxReceipt
-    | ContractOutputToken;
+    ContractOutputCoin |
+    ContractOutputTaxReceipt |
+    ContractOutputToken;
 
-.. ts:def:: ContractOutputCurrency
+.. ts:def:: ContractOutputCoin
 
-  interface ContractOutputCurrency {
+  interface ContractOutputCoin {
 
-    type: "currency";
+    type: "coins";
 
-    // Amount of currency that will be yielded.
+    // Amount of coins that will be yielded.
     // This excludes any applicable withdraw fees.
     brutto_yield: Amount;
 
@@ -358,24 +358,21 @@ The contract terms v1 will have the following structure:
     // 'token_types' map on the top-level.
     authority_label: string;
 
-    // Must a wallet understand this token type to
-    // process contracts that consume or yield it?
-    critical: boolean;
+    // Number of tokens to be yelded.
+    // Defaults to one if the field is not provided.
+    number?: Integer;
 
-    // Information about the class of token that will
-    // be yielded.
-    details: OutputTokenClass;
   }
 
-.. ts:def:: OutputTokenClass
+.. ts:def:: TokenClass
 
-  type OutputTokenClass =
-    | OutputTokenClassSubscription
-    | OutputTokenClassDiscount
+  type TokenClass =
+    TokenClassSubscription
+    | TokenClassDiscount
 
-.. ts:def:: OutputTokenClassSubscription
+.. ts:def:: TokenClassSubscription
 
-  interface OutputTokenClassSubscription {
+  interface TokenClassSubscription {
 
     class: "subscription";
 
@@ -394,9 +391,9 @@ The contract terms v1 will have the following structure:
 
   };
 
-.. ts:def:: OutputTokenClassDiscount
+.. ts:def:: TokenClassDiscount
 
-  interface OutputTokenClassDiscount {
+  interface TokenClassDiscount {
 
     class: "discount";
 
@@ -431,6 +428,13 @@ The contract terms v1 will have the following structure:
     // When will tokens signed by this key expire?
     token_expiration: Timestamp;
 
+    // Class-specific information of the token
+    details: TokenClass;
+
+    // Must a wallet understand this token type to
+    // process contracts that consume or yield it?
+    critical: boolean;
+
     // Number of tokens issued according to ASS authority
     // FIXME: this is still rather speculative in the design...
     ass?: Integer;

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

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