aboutsummaryrefslogtreecommitdiff
path: root/packages/taler-wallet-core/src/types/walletTypes.ts
diff options
context:
space:
mode:
Diffstat (limited to 'packages/taler-wallet-core/src/types/walletTypes.ts')
-rw-r--r--packages/taler-wallet-core/src/types/walletTypes.ts27
1 files changed, 23 insertions, 4 deletions
diff --git a/packages/taler-wallet-core/src/types/walletTypes.ts b/packages/taler-wallet-core/src/types/walletTypes.ts
index e64187e72..511d7766c 100644
--- a/packages/taler-wallet-core/src/types/walletTypes.ts
+++ b/packages/taler-wallet-core/src/types/walletTypes.ts
@@ -653,16 +653,16 @@ export interface GetExchangeTosResult {
}
export interface TestPayArgs {
- merchant: string;
- apikey: string;
+ merchantBaseUrl: string;
+ merchantApiKey: string;
amount: string;
summary: string;
}
export const codecForTestPayArgs = (): Codec<TestPayArgs> =>
buildCodecForObject<TestPayArgs>()
- .property("merchant", codecForString())
- .property("apikey", codecForString())
+ .property("merchantBaseUrl", codecForString())
+ .property("merchantApiKey", codecForString())
.property("amount", codecForString())
.property("summary", codecForString())
.build("TestPayArgs");
@@ -829,3 +829,22 @@ export interface CoreApiResponseError {
id: string;
error: OperationErrorDetails;
}
+
+export interface WithdrawTestBalanceRequest {
+ amount: string;
+ bankBaseUrl: string;
+ exchangeBaseUrl: string;
+}
+
+export const withdrawTestBalanceDefaults = {
+ amount: "TESTKUDOS:10",
+ bankBaseUrl: "https://bank.test.taler.net/",
+ exchangeBaseUrl: "https://exchange.test.taler.net/",
+};
+
+export const codecForWithdrawTestBalance = (): Codec<WithdrawTestBalanceRequest> =>
+ buildCodecForObject<WithdrawTestBalanceRequest>()
+ .property("amount", codecForString())
+ .property("bankBaseUrl", codecForString())
+ .property("exchangeBaseUrl", codecForString())
+ .build("WithdrawTestBalanceRequest");