diff options
Diffstat (limited to 'packages/taler-wallet-core/src/wallet-api-types.ts')
-rw-r--r-- | packages/taler-wallet-core/src/wallet-api-types.ts | 37 |
1 files changed, 31 insertions, 6 deletions
diff --git a/packages/taler-wallet-core/src/wallet-api-types.ts b/packages/taler-wallet-core/src/wallet-api-types.ts index 7d3dc86a3..2cbf693f5 100644 --- a/packages/taler-wallet-core/src/wallet-api-types.ts +++ b/packages/taler-wallet-core/src/wallet-api-types.ts @@ -130,6 +130,9 @@ import { WithdrawUriInfoResponse, WithdrawalTransactionByURIRequest, TransactionWithdrawal, + GetExchangeResourcesRequest, + DeleteExchangeRequest, + GetExchangeResourcesResponse, } from "@gnu-taler/taler-util"; import { AddBackupProviderRequest, @@ -238,6 +241,8 @@ export enum WalletApiOperation { ListExchangesForScopedCurrency = "listExchangesForScopedCurrency", PrepareWithdrawExchange = "prepareWithdrawExchange", TestingInfiniteTransactionLoop = "testingInfiniteTransactionLoop", + GetExchangeResources = "getExchangeResources", + DeleteExchange = "deleteExchange", } // group: Initialization @@ -668,6 +673,24 @@ export type GetExchangeEntryByUrlOp = { }; /** + * Get resources associated with an exchange. + */ +export type GetExchangeResourcesOp = { + op: WalletApiOperation.GetExchangeResources; + request: GetExchangeResourcesRequest; + response: GetExchangeResourcesResponse; +}; + +/** + * Get resources associated with an exchange. + */ +export type DeleteExchangeOp = { + op: WalletApiOperation.GetExchangeResources; + request: DeleteExchangeRequest; + response: EmptyObject; +}; + +/** * List currencies known to the wallet. */ export type ListCurrenciesOp = { @@ -1206,6 +1229,8 @@ export type WalletOperations = { [WalletApiOperation.UpdateExchangeEntry]: UpdateExchangeEntryOp; [WalletApiOperation.PrepareWithdrawExchange]: PrepareWithdrawExchangeOp; [WalletApiOperation.TestingInfiniteTransactionLoop]: any; + [WalletApiOperation.DeleteExchange]: DeleteExchangeOp; + [WalletApiOperation.GetExchangeResources]: GetExchangeResourcesOp; }; export type WalletCoreRequestType< @@ -1229,10 +1254,10 @@ type Primitives = string | number | boolean; type RecursivePartial<T extends object> = { [P in keyof T]?: T[P] extends Array<infer U extends object> - ? Array<RecursivePartial<U>> - : T[P] extends Array<infer J extends Primitives> - ? Array<J> - : T[P] extends object - ? RecursivePartial<T[P]> - : T[P]; + ? Array<RecursivePartial<U>> + : T[P] extends Array<infer J extends Primitives> + ? Array<J> + : T[P] extends object + ? RecursivePartial<T[P]> + : T[P]; } & object; |