diff options
author | Sebastian <sebasjm@gmail.com> | 2023-10-14 01:40:50 -0300 |
---|---|---|
committer | Sebastian <sebasjm@gmail.com> | 2023-10-14 01:40:50 -0300 |
commit | 53998741a6f280c5c56573c2db6ffd35ce5c34d9 (patch) | |
tree | 5425164817dc59c5a6de24cac2d04196522e5a89 /packages/taler-util/src | |
parent | 592ecda944bf5b32e86f6c42ee8e1f17d9c86451 (diff) | |
download | wallet-core-53998741a6f280c5c56573c2db6ffd35ce5c34d9.tar.xz |
breaking api: currency spec as the doc mention
Diffstat (limited to 'packages/taler-util/src')
-rw-r--r-- | packages/taler-util/src/http-client/bank-integration.ts | 7 | ||||
-rw-r--r-- | packages/taler-util/src/http-client/index.ts | 0 | ||||
-rw-r--r-- | packages/taler-util/src/index.ts | 5 | ||||
-rw-r--r-- | packages/taler-util/src/taler-types.ts | 8 | ||||
-rw-r--r-- | packages/taler-util/src/wallet-types.ts | 21 |
5 files changed, 17 insertions, 24 deletions
diff --git a/packages/taler-util/src/http-client/bank-integration.ts b/packages/taler-util/src/http-client/bank-integration.ts index cdba66fa5..cd6462417 100644 --- a/packages/taler-util/src/http-client/bank-integration.ts +++ b/packages/taler-util/src/http-client/bank-integration.ts @@ -1,7 +1,10 @@ import { HttpRequestLibrary, readSuccessResponseJsonOrThrow } from "../http-common.js"; import { createPlatformHttpLib } from "../http.js"; -import { codecForBankWithdrawalOperationPostResponse } from "../taler-types.js"; -import { TalerBankIntegrationApi, codecForBankVersion, codecForBankWithdrawalOperationStatus } from "./types.js"; +import { + TalerBankIntegrationApi, + codecForBankWithdrawalOperationPostResponse, + codecForBankWithdrawalOperationStatus +} from "./types.js"; export class TalerBankIntegrationHttpClient { httpLib: HttpRequestLibrary; diff --git a/packages/taler-util/src/http-client/index.ts b/packages/taler-util/src/http-client/index.ts new file mode 100644 index 000000000..e69de29bb --- /dev/null +++ b/packages/taler-util/src/http-client/index.ts diff --git a/packages/taler-util/src/index.ts b/packages/taler-util/src/index.ts index 568e2f438..71d4253f0 100644 --- a/packages/taler-util/src/index.ts +++ b/packages/taler-util/src/index.ts @@ -42,3 +42,8 @@ export * from "./transaction-test-data.js"; export * from "./libeufin-api-types.js"; export * from "./MerchantApiClient.js"; export * from "./bank-api-client.js"; +export * from "./http-client/bank-core.js"; +export * from "./http-client/bank-integration.js"; +export * from "./http-client/bank-revenue.js"; +export * from "./http-client/bank-wire.js"; +export * from "./http-client/types.js"; diff --git a/packages/taler-util/src/taler-types.ts b/packages/taler-util/src/taler-types.ts index d8fdc2519..767adb799 100644 --- a/packages/taler-util/src/taler-types.ts +++ b/packages/taler-util/src/taler-types.ts @@ -951,7 +951,7 @@ export interface AccountInfo { /** * @deprecated */ -export interface ExchangeWireJson {} +export interface ExchangeWireJson { } /** * Proposal returned from the contract URL. @@ -1310,12 +1310,6 @@ export const codecForDenominationPubKey = () => .alternative(DenomKeyType.ClauseSchnorr, codecForCsDenominationPubKey()) .build("DenominationPubKey"); -export const codecForBankWithdrawalOperationPostResponse = - (): Codec<BankWithdrawalOperationPostResponse> => - buildCodecForObject<BankWithdrawalOperationPostResponse>() - .property("transfer_done", codecForBoolean()) - .build("BankWithdrawalOperationPostResponse"); - export type AmountString = string; export type Base32String = string; export type EddsaSignatureString = string; diff --git a/packages/taler-util/src/wallet-types.ts b/packages/taler-util/src/wallet-types.ts index 9a4e15ae1..49dae9bd4 100644 --- a/packages/taler-util/src/wallet-types.ts +++ b/packages/taler-util/src/wallet-types.ts @@ -46,6 +46,7 @@ import { codecOptional, renderContext, } from "./codec.js"; +import { CurrencySpecification } from "./index.js"; import { VersionMatchResult } from "./libtool-version.js"; import { PaytoUri } from "./payto.js"; import { AgeCommitmentProof } from "./taler-crypto.js"; @@ -429,16 +430,6 @@ export interface GetCurrencySpecificationResponse { currencySpecification: CurrencySpecification; } -export interface CurrencySpecification { - decimal_separator: string; - fractional_input_digits: number; - fractional_normal_digits: number; - fractional_trailing_zero_digits: number; - is_currency_name_leading: boolean; - name: string; - alt_unit_names: { [n: number]: string }; -} - export interface InitRequest { skipDefaults?: boolean; } @@ -556,11 +547,11 @@ export interface CoinDumpJson { withdrawal_reserve_pub: string | undefined; coin_status: CoinStatus; spend_allocation: - | { - id: string; - amount: string; - } - | undefined; + | { + id: string; + amount: string; + } + | undefined; /** * Information about the age restriction */ |