From c53264869451ccbfbaf1976e01df8c7636163068 Mon Sep 17 00:00:00 2001 From: Florian Dold Date: Thu, 14 Oct 2021 11:36:43 +0200 Subject: implement fakebank withdrawal --- packages/taler-util/src/walletTypes.ts | 28 ++++++++++++++++++++++------ 1 file changed, 22 insertions(+), 6 deletions(-) (limited to 'packages/taler-util/src/walletTypes.ts') diff --git a/packages/taler-util/src/walletTypes.ts b/packages/taler-util/src/walletTypes.ts index 63ece1e60..6e68ee080 100644 --- a/packages/taler-util/src/walletTypes.ts +++ b/packages/taler-util/src/walletTypes.ts @@ -590,11 +590,11 @@ export interface GetExchangeTosResult { * if any. */ acceptedEtag: string | undefined; - + /** * Accepted content type */ - contentType: string; + contentType: string; } export interface TestPayArgs { @@ -658,9 +658,9 @@ export interface GetExchangeTosRequest { export const codecForGetExchangeTosRequest = (): Codec => buildCodecForObject() - .property("exchangeBaseUrl", codecForString()) - .property("acceptedFormat", codecOptional(codecForList(codecForString()))) - .build("GetExchangeTosRequest"); + .property("exchangeBaseUrl", codecForString()) + .property("acceptedFormat", codecOptional(codecForList(codecForString()))) + .build("GetExchangeTosRequest"); export interface AcceptManualWithdrawalRequest { exchangeBaseUrl: string; @@ -734,7 +734,10 @@ export const codecForGetExchangeWithdrawalInfo = (): Codec() .property("exchangeBaseUrl", codecForString()) .property("amount", codecForAmountJson()) - .property("tosAcceptedFormat", codecOptional(codecForList(codecForString()))) + .property( + "tosAcceptedFormat", + codecOptional(codecForList(codecForString())), + ) .build("GetExchangeWithdrawalInfo"); export interface AbortProposalRequest { @@ -1029,3 +1032,16 @@ export const codecForSetWalletDeviceIdRequest = (): Codec() .property("walletDeviceId", codecForString()) .build("SetWalletDeviceIdRequest"); + +export interface WithdrawFakebankRequest { + amount: AmountString; + exchange: string; + bank: string; +} + +export const codecForWithdrawFakebankRequest = (): Codec => + buildCodecForObject() + .property("amount", codecForAmountString()) + .property("bank", codecForString()) + .property("exchange", codecForString()) + .build("WithdrawFakebankRequest"); -- cgit v1.2.3