diff options
author | Florian Dold <florian@dold.me> | 2024-04-30 11:50:59 +0200 |
---|---|---|
committer | Florian Dold <florian@dold.me> | 2024-04-30 11:51:07 +0200 |
commit | 8b5d1276b9d9043e85cba91704c908ff544916e0 (patch) | |
tree | bc558f2ec7fb7b77731c5afd3838567e32c7eb4f /packages/taler-util/src/wallet-types.ts | |
parent | 22709ff4e2918a8d0e528539d11d761381920b45 (diff) | |
download | wallet-core-8b5d1276b9d9043e85cba91704c908ff544916e0.tar.xz |
wallet-core: new states for withdrawal, prepare/confirm requests
Diffstat (limited to 'packages/taler-util/src/wallet-types.ts')
-rw-r--r-- | packages/taler-util/src/wallet-types.ts | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/packages/taler-util/src/wallet-types.ts b/packages/taler-util/src/wallet-types.ts index 9575e6d7d..ccf3c230a 100644 --- a/packages/taler-util/src/wallet-types.ts +++ b/packages/taler-util/src/wallet-types.ts @@ -1883,6 +1883,36 @@ export interface GetWithdrawalDetailsForAmountRequest { clientCancellationId?: string; } +export interface PrepareBankIntegratedWithdrawalRequest { + talerWithdrawUri: string; + exchangeBaseUrl: string; + forcedDenomSel?: ForcedDenomSel; + restrictAge?: number; +} + +export const codecForPrepareBankIntegratedWithdrawalRequest = + (): Codec<PrepareBankIntegratedWithdrawalRequest> => + buildCodecForObject<PrepareBankIntegratedWithdrawalRequest>() + .property("exchangeBaseUrl", codecForString()) + .property("talerWithdrawUri", codecForString()) + .property("forcedDenomSel", codecForAny()) + .property("restrictAge", codecOptional(codecForNumber())) + .build("PrepareBankIntegratedWithdrawalRequest"); + +export interface PrepareBankIntegratedWithdrawalResponse { + transactionId: string; +} + +export interface ConfirmWithdrawalRequest { + transactionId: string; +} + +export const codecForConfirmWithdrawalRequestRequest = + (): Codec<ConfirmWithdrawalRequest> => + buildCodecForObject<ConfirmWithdrawalRequest>() + .property("transactionId", codecForString()) + .build("ConfirmWithdrawalRequest"); + export interface AcceptBankIntegratedWithdrawalRequest { talerWithdrawUri: string; exchangeBaseUrl: string; |