gnunet-svn
[Top][All Lists]
Advanced

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

[taler-docs] branch master updated: update wallet-core API docs


From: gnunet
Subject: [taler-docs] branch master updated: update wallet-core API docs
Date: Mon, 25 Mar 2024 12:16:39 +0100

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

dold pushed a commit to branch master
in repository docs.

The following commit(s) were added to refs/heads/master by this push:
     new ebab1b66 update wallet-core API docs
ebab1b66 is described below

commit ebab1b66dc50b884eac0ff6f512d63c91b7812c8
Author: Florian Dold <florian@dold.me>
AuthorDate: Mon Mar 25 12:16:35 2024 +0100

    update wallet-core API docs
---
 wallet/wallet-core.md | 726 ++++++++++++++------------------------------------
 1 file changed, 193 insertions(+), 533 deletions(-)

diff --git a/wallet/wallet-core.md b/wallet/wallet-core.md
index 977e100d..2960fafe 100644
--- a/wallet/wallet-core.md
+++ b/wallet/wallet-core.md
@@ -56,6 +56,7 @@ This file is auto-generated from 
[wallet-core](https://git.taler.net/wallet-core
 * [AddKnownBankAccountsOp](#addknownbankaccountsop)
 * [ForgetKnownBankAccountsOp](#forgetknownbankaccountsop)
 * [SetExchangeTosAcceptedOp](#setexchangetosacceptedop)
+* [SetExchangeTosForgottenOp](#setexchangetosforgottenop)
 * [GetExchangeTosOp](#getexchangetosop)
 * [GetExchangeDetailedInfoOp](#getexchangedetailedinfoop)
 * [GetExchangeEntryByUrlOp](#getexchangeentrybyurlop)
@@ -104,12 +105,14 @@ This file is auto-generated from 
[wallet-core](https://git.taler.net/wallet-core
 * [WithdrawTestkudosOp](#withdrawtestkudosop)
 * [TestPayOp](#testpayop)
 * [GetPendingTasksOp](#getpendingtasksop)
+* [GetActiveTasksOp](#getactivetasksop)
 * [DumpCoinsOp](#dumpcoinsop)
 * [TestingSetTimetravelOp](#testingsettimetravelop)
+* [TestingListTasksForTransactionOp](#testinglisttasksfortransactionop)
 * [TestingWaitTransactionsFinalOp](#testingwaittransactionsfinalop)
 * [TestingWaitRefreshesFinalOp](#testingwaitrefreshesfinalop)
-* [TestingWaitTasksProcessedOp](#testingwaittasksprocessedop)
 * [TestingWaitTransactionStateOp](#testingwaittransactionstateop)
+* [TestingGetDenomStatsOp](#testinggetdenomstatsop)
 * [SetCoinSuspendedOp](#setcoinsuspendedop)
 * [ForceRefreshOp](#forcerefreshop)
 ## Operation Reference
@@ -130,7 +133,56 @@ export type InitWalletOp = {
 ```
 ```typescript
 export interface InitRequest {
-  skipDefaults?: boolean;
+  config?: PartialWalletRunConfig;
+}
+
+```
+```typescript
+export interface PartialWalletRunConfig {
+  builtin?: Partial<WalletRunConfig["builtin"]>;
+  testing?: Partial<WalletRunConfig["testing"]>;
+  features?: Partial<WalletRunConfig["features"]>;
+}
+
+```
+```typescript
+export interface WalletRunConfig {
+  /**
+   * Initialization values useful for a complete startup.
+   *
+   * These are values may be overridden by different wallets
+   */
+  builtin: {
+    exchanges: BuiltinExchange[];
+  };
+  /**
+   * Unsafe options which it should only be used to create
+   * testing environment.
+   */
+  testing: {
+    /**
+     * Allow withdrawal of denominations even though they are about to expire.
+     */
+    denomselAllowLate: boolean;
+    devModeActive: boolean;
+    insecureTrustExchange: boolean;
+    preventThrottling: boolean;
+    skipDefaults: boolean;
+    emitObservabilityEvents?: boolean;
+  };
+  /**
+   * Configurations values that may be safe to show to the user
+   */
+  features: {
+    allowHttp: boolean;
+  };
+}
+
+```
+```typescript
+export interface BuiltinExchange {
+  exchangeBaseUrl: string;
+  currencyHint?: string;
 }
 
 ```
@@ -209,7 +261,7 @@ export declare enum BalanceFlag {
 export type GetBalancesDetailOp = {
   op: WalletApiOperation.GetBalanceDetail;
   request: GetBalanceDetailRequest;
-  response: MerchantPaymentBalanceDetails;
+  response: PaymentBalanceDetails;
 };
 // GetBalanceDetail = "getBalanceDetail"
 
@@ -221,7 +273,7 @@ export interface GetBalanceDetailRequest {
 
 ```
 ```typescript
-export interface MerchantPaymentBalanceDetails {
+export interface PaymentBalanceDetails {
   /**
    * Balance of type "available" (see balance.ts for definition).
    */
@@ -237,11 +289,18 @@ export interface MerchantPaymentBalanceDetails {
   /**
    * Balance of type "merchant-acceptable" (see balance.ts for definition).
    */
-  balanceMerchantAcceptable: AmountJson;
+  balanceReceiverAcceptable: AmountJson;
   /**
    * Balance of type "merchant-depositable" (see balance.ts for definition).
    */
-  balanceMerchantDepositable: AmountJson;
+  balanceReceiverDepositable: AmountJson;
+  /**
+   * Balance that's depositable with the exchange.
+   * This balance is reduced by the exchange's debit restrictions
+   * and wire fee configuration.
+   */
+  balanceExchangeDepositable: AmountJson;
+  maxEffectiveSpendAmount: AmountJson;
 }
 
 ```
@@ -844,7 +903,7 @@ export type PreparePayForTemplateOp = {
 ```typescript
 export interface PreparePayTemplateRequest {
   talerPayTemplateUri: string;
-  templateParams: Record<string, string>;
+  templateParams?: TemplateParams;
 }
 
 ```
@@ -893,8 +952,6 @@ export interface WalletContractData {
       }
     | undefined;
   autoRefund: TalerProtocolDuration | undefined;
-  maxWireFee: AmountString;
-  wireFeeAmortization: number;
   payDeadline: TalerProtocolTimestamp;
   refundDeadline: TalerProtocolTimestamp;
   allowedExchanges: AllowedExchangeInfo[];
@@ -1336,6 +1393,7 @@ export interface PaytoUriTalerBank extends 
PaytoUriGeneric {
 export interface PaytoUriBitcoin extends PaytoUriGeneric {
   isKnown: true;
   targetType: "bitcoin";
+  address: string;
   segwitAddrs: Array<string>;
 }
 
@@ -1390,11 +1448,18 @@ export type SetExchangeTosAcceptedOp = {
 // SetExchangeTosAccepted = "setExchangeTosAccepted"
 
 ```
+
+### SetExchangeTosForgottenOp
 ```typescript
-export interface AcceptExchangeTosRequest {
-  exchangeBaseUrl: string;
-  etag: string | undefined;
-}
+/**
+ * Accept a particular version of the exchange terms of service.
+ */
+export type SetExchangeTosForgottenOp = {
+  op: WalletApiOperation.SetExchangeTosForgotten;
+  request: AcceptExchangeTosRequest;
+  response: EmptyObject;
+};
+// SetExchangeTosForgotten = "SetExchangeTosForgotten"
 
 ```
 
@@ -2195,13 +2260,7 @@ export type ConfirmPeerPushCreditOp = {
 ```
 ```typescript
 export interface ConfirmPeerPushCreditRequest {
-  /**
-   * Transparent identifier of the incoming peer push payment.
-   *
-   * @deprecated specify transactionId instead!
-   */
-  peerPushCreditId?: string;
-  transactionId?: string;
+  transactionId: string;
 }
 
 ```
@@ -2323,13 +2382,7 @@ export type ConfirmPeerPullDebitOp = {
 ```
 ```typescript
 export interface ConfirmPeerPullDebitRequest {
-  /**
-   * Transparent identifier of the incoming peer pull payment.
-   *
-   * @deprecated use transactionId instead
-   */
-  peerPullDebitId?: string;
-  transactionId?: TransactionIdStr;
+  transactionId: TransactionIdStr;
 }
 
 ```
@@ -2550,36 +2603,10 @@ export interface TestPayArgs {
 ```
 ```typescript
 export interface TestPayResult {
-  payCoinSelection: PayCoinSelection;
-}
-
-```
-```typescript
-/**
- * Result of selecting coins, contains the exchange, and selected
- * coins with their denomination.
- */
-export interface PayCoinSelection {
-  /**
-   * Amount requested by the merchant.
-   */
-  paymentAmount: AmountString;
-  /**
-   * Public keys of the coins that were selected.
-   */
-  coinPubs: string[];
-  /**
-   * Amount that each coin contributes.
-   */
-  coinContributions: AmountString[];
   /**
-   * How much of the wire fees is the customer paying?
+   * Number of coins used for the payment.
    */
-  customerWireFees: AmountString;
-  /**
-   * How much of the deposit fees is the customer paying?
-   */
-  customerDepositFees: AmountString;
+  numCoins: number;
 }
 
 ```
@@ -2588,362 +2615,26 @@ export interface PayCoinSelection {
 ```typescript
 /**
  * Get wallet-internal pending tasks.
+ *
+ * @deprecated
  */
 export type GetPendingTasksOp = {
   op: WalletApiOperation.GetPendingOperations;
   request: EmptyObject;
-  response: PendingTasksResponse;
+  response: any;
 };
 // GetPendingOperations = "getPendingOperations"
 
 ```
-```typescript
-/**
- * Response returned from the pending operations API.
- */
-export interface PendingOperationsResponse {
-  /**
-   * List of pending operations.
-   */
-  pendingOperations: PendingTaskInfo[];
-}
-
-```
-```typescript
-/**
- * Information about a pending operation.
- */
-export type PendingTaskInfo = PendingTaskInfoCommon &
-  (
-    | PendingExchangeUpdateTask
-    | PendingExchangeCheckRefreshTask
-    | PendingPurchaseTask
-    | PendingRefreshTask
-    | PendingTipPickupTask
-    | PendingWithdrawTask
-    | PendingRecoupTask
-    | PendingDepositTask
-    | PendingBackupTask
-    | PendingPeerPushInitiationTask
-    | PendingPeerPullInitiationTask
-    | PendingPeerPullDebitTask
-    | PendingPeerPushCreditTask
-  );
-
-```
-```typescript
-/**
- * Fields that are present in every pending operation.
- */
-export interface PendingTaskInfoCommon {
-  /**
-   * Type of the pending operation.
-   */
-  type: PendingTaskType;
-  /**
-   * Unique identifier for the pending task.
-   */
-  id: TaskId;
-  /**
-   * Set to true if the operation indicates that something is really in 
progress,
-   * as opposed to some regular scheduled operation that can be tried later.
-   */
-  givesLifeness: boolean;
-  /**
-   * Operation is active and waiting for a longpoll result.
-   */
-  isLongpolling: boolean;
-  /**
-   * Operation is waiting to be executed.
-   */
-  isDue: boolean;
-  /**
-   * Timestamp when the pending operation should be executed next.
-   */
-  timestampDue: AbsoluteTime;
-  /**
-   * Retry info.  Currently used to stop the wallet after any operation
-   * exceeds a number of retries.
-   */
-  retryInfo?: DbRetryInfo;
-  /**
-   * Internal operation status for debugging.
-   */
-  internalOperationStatus?: string;
-}
-
-```
-```typescript
-export enum PendingTaskType {
-  ExchangeUpdate = "exchange-update",
-  ExchangeCheckRefresh = "exchange-check-refresh",
-  Purchase = "purchase",
-  Refresh = "refresh",
-  Recoup = "recoup",
-  RewardPickup = "reward-pickup",
-  Withdraw = "withdraw",
-  Deposit = "deposit",
-  Backup = "backup",
-  PeerPushDebit = "peer-push-debit",
-  PeerPullCredit = "peer-pull-credit",
-  PeerPushCredit = "peer-push-credit",
-  PeerPullDebit = "peer-pull-debit",
-}
-
-```
-```typescript
-export type TaskId = string & {
-  [__taskId]: true;
-};
-
-```
-```typescript
-export interface DbRetryInfo {
-  firstTry: DbPreciseTimestamp;
-  nextRetry: DbPreciseTimestamp;
-  retryCounter: number;
-}
 
-```
+### GetActiveTasksOp
 ```typescript
-/**
- * Timestamp, stored as microseconds.
- */
-export type DbPreciseTimestamp = number & {
-  [symDbPreciseTimestamp]: true;
+export type GetActiveTasksOp = {
+  op: WalletApiOperation.GetActiveTasks;
+  request: EmptyObject;
+  response: GetActiveTasks;
 };
-
-```
-```typescript
-export interface RetryPolicy {
-  readonly backoffDelta: Duration;
-  readonly backoffBase: number;
-  readonly maxTimeout: Duration;
-}
-
-```
-```typescript
-// Declare "static" methods in Error
-interface ErrorConstructor {
-  /** Create .stack property on a target object */
-  captureStackTrace(targetObject: object, constructorOpt?: Function): void;
-  /**
-   * Optional override for formatting stack traces
-   *
-   * @see https://v8.dev/docs/stack-trace-api#customizing-stack-traces
-   */
-  prepareStackTrace?:
-    | ((err: Error, stackTraces: NodeJS.CallSite[]) => any)
-    | undefined;
-  stackTraceLimit: number;
-}
-
-```
-```typescript
-interface CallSite {
-  /**
-   * Value of "this"
-   */
-  getThis(): unknown;
-  /**
-   * Type of "this" as a string.
-   * This is the name of the function stored in the constructor field of
-   * "this", if available.  Otherwise the object's [[Class]] internal
-   * property.
-   */
-  getTypeName(): string | null;
-  /**
-   * Current function
-   */
-  getFunction(): Function | undefined;
-  /**
-   * Name of the current function, typically its name property.
-   * If a name property is not available an attempt will be made to try
-   * to infer a name from the function's context.
-   */
-  getFunctionName(): string | null;
-  /**
-   * Name of the property [of "this" or one of its prototypes] that holds
-   * the current function
-   */
-  getMethodName(): string | null;
-  /**
-   * Name of the script [if this function was defined in a script]
-   */
-  getFileName(): string | null;
-  /**
-   * Current line number [if this function was defined in a script]
-   */
-  getLineNumber(): number | null;
-  /**
-   * Current column number [if this function was defined in a script]
-   */
-  getColumnNumber(): number | null;
-  /**
-   * A call site object representing the location where eval was called
-   * [if this function was created using a call to eval]
-   */
-  getEvalOrigin(): string | undefined;
-  /**
-   * Is this a toplevel invocation, that is, is "this" the global object?
-   */
-  isToplevel(): boolean;
-  /**
-   * Does this call take place in code defined by a call to eval?
-   */
-  isEval(): boolean;
-  /**
-   * Is this call in native V8 code?
-   */
-  isNative(): boolean;
-  /**
-   * Is this a constructor call?
-   */
-  isConstructor(): boolean;
-}
-
-```
-```typescript
-/**
- * The wallet is currently updating information about an exchange.
- */
-export interface PendingExchangeUpdateTask {
-  type: PendingTaskType.ExchangeUpdate;
-  exchangeBaseUrl: string;
-  lastError: TalerErrorDetail | undefined;
-}
-
-```
-```typescript
-/**
- * The wallet should check whether coins from this exchange
- * need to be auto-refreshed.
- */
-export interface PendingExchangeCheckRefreshTask {
-  type: PendingTaskType.ExchangeCheckRefresh;
-  exchangeBaseUrl: string;
-}
-
-```
-```typescript
-/**
- * A purchase needs to be processed (i.e. for download / payment / refund).
- */
-export interface PendingPurchaseTask {
-  type: PendingTaskType.Purchase;
-  proposalId: string;
-  retryInfo?: DbRetryInfo;
-  /**
-   * Status of the payment as string, used only for debugging.
-   */
-  statusStr: string;
-  lastError: TalerErrorDetail | undefined;
-}
-
-```
-```typescript
-/**
- * Status of an ongoing withdrawal operation.
- */
-export interface PendingRefreshTask {
-  type: PendingTaskType.Refresh;
-  lastError?: TalerErrorDetail;
-  refreshGroupId: string;
-  finishedPerCoin: boolean[];
-  retryInfo?: DbRetryInfo;
-}
-
-```
-```typescript
-/**
- * The wallet is picking up a tip that the user has accepted.
- */
-export interface PendingTipPickupTask {
-  type: PendingTaskType.RewardPickup;
-  tipId: string;
-  merchantBaseUrl: string;
-  merchantTipId: string;
-}
-
-```
-```typescript
-/**
- * Status of an ongoing withdrawal operation.
- */
-export interface PendingWithdrawTask {
-  type: PendingTaskType.Withdraw;
-  lastError: TalerErrorDetail | undefined;
-  retryInfo?: DbRetryInfo;
-  withdrawalGroupId: string;
-}
-
-```
-```typescript
-export interface PendingRecoupTask {
-  type: PendingTaskType.Recoup;
-  recoupGroupId: string;
-  retryInfo?: DbRetryInfo;
-  lastError: TalerErrorDetail | undefined;
-}
-
-```
-```typescript
-/**
- * Status of an ongoing deposit operation.
- */
-export interface PendingDepositTask {
-  type: PendingTaskType.Deposit;
-  lastError: TalerErrorDetail | undefined;
-  retryInfo: DbRetryInfo | undefined;
-  depositGroupId: string;
-}
-
-```
-```typescript
-export interface PendingBackupTask {
-  type: PendingTaskType.Backup;
-  backupProviderBaseUrl: string;
-  lastError: TalerErrorDetail | undefined;
-}
-
-```
-```typescript
-/**
- * The wallet wants to send a peer push payment.
- */
-export interface PendingPeerPushInitiationTask {
-  type: PendingTaskType.PeerPushDebit;
-  pursePub: string;
-}
-
-```
-```typescript
-/**
- * The wallet wants to send a peer pull payment.
- */
-export interface PendingPeerPullInitiationTask {
-  type: PendingTaskType.PeerPullCredit;
-  pursePub: string;
-}
-
-```
-```typescript
-/**
- * The wallet wants to send a peer pull payment.
- */
-export interface PendingPeerPullDebitTask {
-  type: PendingTaskType.PeerPullDebit;
-  peerPullDebitId: string;
-}
-
-```
-```typescript
-/**
- */
-export interface PendingPeerPushCreditTask {
-  type: PendingTaskType.PeerPushCredit;
-  peerPushCreditId: string;
-}
+// GetActiveTasks = "getActiveTasks"
 
 ```
 
@@ -3120,6 +2811,32 @@ export interface TestingSetTimetravelRequest {
 
 ```
 
+### TestingListTasksForTransactionOp
+```typescript
+/**
+ * Add an offset to the wallet's internal time.
+ */
+export type TestingListTasksForTransactionOp = {
+  op: WalletApiOperation.TestingListTaskForTransaction;
+  request: TestingListTasksForTransactionRequest;
+  response: TestingListTasksForTransactionsResponse;
+};
+// TestingListTaskForTransaction = "testingListTasksForTransaction"
+
+```
+```typescript
+export interface TestingListTasksForTransactionRequest {
+  transactionId: TransactionIdStr;
+}
+
+```
+```typescript
+export interface TestingListTasksForTransactionsResponse {
+  taskIdList: string[];
+}
+
+```
+
 ### TestingWaitTransactionsFinalOp
 ```typescript
 /**
@@ -3148,20 +2865,6 @@ export type TestingWaitRefreshesFinalOp = {
 
 ```
 
-### TestingWaitTasksProcessedOp
-```typescript
-/**
- * Wait until all tasks have been processed and the wallet is idle.
- */
-export type TestingWaitTasksProcessedOp = {
-  op: WalletApiOperation.TestingWaitTasksProcessed;
-  request: EmptyObject;
-  response: EmptyObject;
-};
-// TestingWaitTasksProcessed = "testingWaitTasksProcessed"
-
-```
-
 ### TestingWaitTransactionStateOp
 ```typescript
 /**
@@ -3183,6 +2886,34 @@ export interface TestingWaitTransactionRequest {
 
 ```
 
+### TestingGetDenomStatsOp
+```typescript
+/**
+ * Get stats about an exchange denomination.
+ */
+export type TestingGetDenomStatsOp = {
+  op: WalletApiOperation.TestingGetDenomStats;
+  request: TestingGetDenomStatsRequest;
+  response: TestingGetDenomStatsResponse;
+};
+// TestingGetDenomStats = "testingGetDenomStats"
+
+```
+```typescript
+export interface TestingGetDenomStatsRequest {
+  exchangeBaseUrl: string;
+}
+
+```
+```typescript
+export interface TestingGetDenomStatsResponse {
+  numKnown: number;
+  numOffered: number;
+  numLost: number;
+}
+
+```
+
 ### SetCoinSuspendedOp
 ```typescript
 /**
@@ -3467,6 +3198,7 @@ export declare enum TransactionMinorState {
   Proposed = "proposed",
   RefundAvailable = "refund-available",
   AcceptRefund = "accept-refund",
+  PaidByOther = "paid-by-other",
 }
 ```
 ```typescript
@@ -3558,10 +3290,15 @@ export interface WithdrawalExchangeAccountDetails {
    * amount for withdrawal.
    *
    * Redundant with the amount in paytoUri, just included to avoid parsing.
+   */
+  transferAmount: AmountString;
+  /**
+   * Beneficiary name of the exchange's bank account.
+   * Optional in general, mandatory for "iban" and "x-taler-bank" (and others).
    *
-   * Only included if this account does a currency conversion.
+   * Redundant with the beneficiary-name in paytoUri, just included to avoid 
parsing.
    */
-  transferAmount?: AmountString;
+  beneficiaryName?: string;
   /**
    * Currency specification for the external currency.
    *
@@ -3720,11 +3457,11 @@ export interface OrderShortInfo {
 ```typescript
 export interface MerchantInfo {
   name: string;
-  jurisdiction?: Location;
-  address?: Location;
-  logo?: string;
-  website?: string;
   email?: string;
+  website?: string;
+  logo?: ImageDataUrl;
+  address?: Location;
+  jurisdiction?: Location;
 }
 ```
 ```typescript
@@ -4016,6 +3753,7 @@ export interface AbortTransactionRequest {
  */
 export interface ExchangeListItem {
   exchangeBaseUrl: string;
+  masterPub: string | undefined;
   currency: string | undefined;
   paytoUris: string[];
   tosStatus: ExchangeTosStatus;
@@ -4023,6 +3761,7 @@ export interface ExchangeListItem {
   exchangeUpdateStatus: ExchangeUpdateStatus;
   ageRestrictionOptions: number[];
   scopeInfo: ScopeInfo | undefined;
+  lastUpdateTimestamp: TalerPreciseTimestamp | undefined;
   /**
    * Information about the last error that occurred when trying
    * to update the exchange info.
@@ -4087,7 +3826,7 @@ export interface PreparePayResultInsufficientBalance {
   contractTerms: MerchantContractTerms;
   amountRaw: AmountString;
   talerUri: string;
-  balanceDetails: PayMerchantInsufficientBalanceDetails;
+  balanceDetails: PaymentInsufficientBalanceDetails;
 }
 ```
 ```typescript
@@ -4096,115 +3835,32 @@ export interface PreparePayResultInsufficientBalance {
  * FIXME: Add type field!
  */
 export interface MerchantContractTerms {
-  /**
-   * Hash of the merchant's wire details.
-   */
   h_wire: string;
-  /**
-   * Hash of the merchant's wire details.
-   */
   auto_refund?: TalerProtocolDuration;
-  /**
-   * Wire method the merchant wants to use.
-   */
   wire_method: string;
-  /**
-   * Human-readable short summary of the contract.
-   */
   summary: string;
   summary_i18n?: InternationalizedString;
-  /**
-   * Nonce used to ensure freshness.
-   */
-  nonce: string;
-  /**
-   * Total amount payable.
-   */
+  order_id: string;
   amount: string;
-  /**
-   * Deadline to pay for the contract.
-   */
+  nonce: string;
   pay_deadline: TalerProtocolTimestamp;
-  /**
-   * Maximum deposit fee covered by the merchant.
-   */
-  max_fee: string;
-  /**
-   * Information about the merchant.
-   */
   merchant: MerchantInfo;
-  /**
-   * Public key of the merchant.
-   */
   merchant_pub: string;
-  /**
-   * Time indicating when the order should be delivered.
-   * May be overwritten by individual products.
-   */
   delivery_date?: TalerProtocolTimestamp;
-  /**
-   * Delivery location for (all!) products.
-   */
   delivery_location?: Location;
-  /**
-   * List of accepted exchanges.
-   */
   exchanges: ExchangeHandle[];
-  /**
-   * Products that are sold in this contract.
-   */
   products?: Product[];
-  /**
-   * Deadline for refunds.
-   */
   refund_deadline: TalerProtocolTimestamp;
-  /**
-   * Deadline for the wire transfer.
-   */
   wire_transfer_deadline: TalerProtocolTimestamp;
-  /**
-   * Time when the contract was generated by the merchant.
-   */
   timestamp: TalerProtocolTimestamp;
-  /**
-   * Order id to uniquely identify the purchase within
-   * one merchant instance.
-   */
-  order_id: string;
-  /**
-   * Base URL of the merchant's backend.
-   */
   merchant_base_url: string;
-  /**
-   * Fulfillment URL to view the product or
-   * delivery status.
-   */
   fulfillment_url?: string;
-  /**
-   * URL meant to share the shopping cart.
-   */
   public_reorder_url?: string;
-  /**
-   * Plain text fulfillment message in the merchant's default language.
-   */
   fulfillment_message?: string;
-  /**
-   * Internationalized fulfillment messages.
-   */
   fulfillment_message_i18n?: InternationalizedString;
-  /**
-   * Share of the wire fee that must be settled with one payment.
-   */
-  wire_fee_amortization?: number;
-  /**
-   * Maximum wire fee that the merchant agrees to pay for.
-   */
-  max_wire_fee?: string;
-  minimum_age?: number;
-  /**
-   * Extra data, interpreted by the mechant only.
-   */
+  max_fee: string;
   extra?: any;
+  minimum_age?: Integer;
 }
 ```
 ```typescript
@@ -4213,27 +3869,19 @@ export interface MerchantContractTerms {
  * merchant's contract terms.
  */
 export interface ExchangeHandle {
-  /**
-   * Master public signing key of the exchange.
-   */
-  master_pub: string;
-  /**
-   * Base URL of the exchange.
-   */
   url: string;
+  master_pub: EddsaPublicKeyString;
 }
 ```
 ```typescript
 export interface Product {
   product_id?: string;
   description: string;
-  description_i18n?: {
-    [lang_tag: string]: string;
-  };
-  quantity?: number;
+  description_i18n?: InternationalizedString;
+  quantity?: Integer;
   unit?: string;
   price?: AmountString;
-  image?: string;
+  image?: ImageDataUrl;
   taxes?: Tax[];
   delivery_date?: TalerProtocolTimestamp;
 }
@@ -4248,7 +3896,7 @@ export interface Tax {
 /**
  * Detailed reason for why the wallet's balance is insufficient.
  */
-export interface PayMerchantInsufficientBalanceDetails {
+export interface PaymentInsufficientBalanceDetails {
   /**
    * Amount requested by the merchant.
    */
@@ -4268,21 +3916,28 @@ export interface PayMerchantInsufficientBalanceDetails {
   /**
    * Balance of type "merchant-acceptable" (see balance.ts for definition).
    */
-  balanceMerchantAcceptable: AmountString;
+  balanceReceiverAcceptable: AmountString;
   /**
    * Balance of type "merchant-depositable" (see balance.ts for definition).
    */
-  balanceMerchantDepositable: AmountString;
-  /**
-   * If the payment would succeed without fees
-   * (i.e. balanceMerchantDepositable >= amountRequested),
-   * this field contains an estimate of the amount that would additionally
-   * be required to cover the fees.
-   *
-   * It is not possible to give an exact value here, since it depends
-   * on the coin selection for the amount that would be additionally withdrawn.
-   */
-  feeGapEstimate: AmountString;
+  balanceReceiverDepositable: AmountString;
+  balanceExchangeDepositable: AmountString;
+  /**
+   * Maximum effective amount that the wallet can spend,
+   * when all fees are paid by the wallet.
+   */
+  maxEffectiveSpendAmount: AmountString;
+  perExchange: {
+    [url: string]: {
+      balanceAvailable: AmountString;
+      balanceMaterial: AmountString;
+      balanceExchangeDepositable: AmountString;
+      balanceAgeAcceptable: AmountString;
+      balanceReceiverAcceptable: AmountString;
+      balanceReceiverDepositable: AmountString;
+      maxEffectiveSpendAmount: AmountString;
+    };
+  };
 }
 ```
 ```typescript
@@ -4341,6 +3996,11 @@ export interface AddExchangeRequest {
 }
 ```
 ```typescript
+export interface AcceptExchangeTosRequest {
+  exchangeBaseUrl: string;
+}
+```
+```typescript
 export interface BackupRecovery {
   walletRootPriv: string;
   providers: {

-- 
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]