From 1e00724a0dcd0d65e6d786a1d8d7cdffc9fe2a85 Mon Sep 17 00:00:00 2001 From: Sebastian Date: Tue, 6 Sep 2022 17:17:44 -0300 Subject: listExchangesDetailed to getExchangeDetailedInfo & ageRestriction taken from the denoms --- packages/taler-util/src/transactionsTypes.ts | 1 - packages/taler-util/src/walletTypes.ts | 24 +++++++++++++----------- 2 files changed, 13 insertions(+), 12 deletions(-) (limited to 'packages/taler-util/src') diff --git a/packages/taler-util/src/transactionsTypes.ts b/packages/taler-util/src/transactionsTypes.ts index e4b1faf2e..a46f304d1 100644 --- a/packages/taler-util/src/transactionsTypes.ts +++ b/packages/taler-util/src/transactionsTypes.ts @@ -190,7 +190,6 @@ export interface TransactionWithdrawal extends TransactionCommon { export interface PeerInfoShort { expiration: TalerProtocolTimestamp | undefined; summary: string | undefined; - completed: boolean; } /** diff --git a/packages/taler-util/src/walletTypes.ts b/packages/taler-util/src/walletTypes.ts index 095266f22..7ca56b4ff 100644 --- a/packages/taler-util/src/walletTypes.ts +++ b/packages/taler-util/src/walletTypes.ts @@ -568,12 +568,12 @@ export interface DepositInfo { ageCommitmentProof?: AgeCommitmentProof; } -export interface ExchangesListRespose { +export interface ExchangesListResponse { exchanges: ExchangeListItem[]; } -export interface ExchangeDetailledListRespose { - exchanges: ExchangeFullDetailsListItem[]; +export interface ExchangeDetailedResponse { + exchange: ExchangeFullDetails; } export interface WalletCoreVersion { @@ -733,7 +733,7 @@ export interface DenominationInfo { stampExpireDeposit: TalerProtocolTimestamp; } -export interface ExchangeFullDetailsListItem { +export interface ExchangeFullDetails { exchangeBaseUrl: string; currency: string; paytoUris: string[]; @@ -771,9 +771,9 @@ const codecForExchangeTos = (): Codec => .property("content", codecOptional(codecForString())) .build("ExchangeTos"); -export const codecForExchangeFullDetailsListItem = - (): Codec => - buildCodecForObject() +export const codecForExchangeFullDetails = + (): Codec => + buildCodecForObject() .property("currency", codecForString()) .property("exchangeBaseUrl", codecForString()) .property("paytoUris", codecForList(codecForString())) @@ -791,10 +791,10 @@ export const codecForExchangeListItem = (): Codec => .property("tos", codecForExchangeTos()) .build("ExchangeListItem"); -export const codecForExchangesListResponse = (): Codec => - buildCodecForObject() - .property("exchanges", codecForList(codecForExchangeFullDetailsListItem())) - .build("ExchangesListRespose"); +export const codecForExchangesListResponse = (): Codec => + buildCodecForObject() + .property("exchanges", codecForList(codecForExchangeListItem())) + .build("ExchangesListResponse"); export interface AcceptManualWithdrawalResult { /** @@ -965,6 +965,7 @@ export const codecForGetWithdrawalDetailsForAmountRequest = buildCodecForObject() .property("exchangeBaseUrl", codecForString()) .property("amount", codecForString()) + .property("restrictAge", codecOptional(codecForNumber())) .build("GetWithdrawalDetailsForAmountRequest"); export interface AcceptExchangeTosRequest { @@ -1022,6 +1023,7 @@ export interface GetExchangeWithdrawalInfo { exchangeBaseUrl: string; amount: AmountJson; tosAcceptedFormat?: string[]; + ageRestricted?: number; } export const codecForGetExchangeWithdrawalInfo = -- cgit v1.2.3