wallaby-cash 2.3.6 → 2.3.7-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/base.d.ts +1 -0
- package/dist/generated/api.d.ts +84 -55
- package/dist/helpers/omit.d.ts +1 -0
- package/dist/index.cjs.js +443 -231
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.esm.js +443 -232
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +443 -232
- package/dist/index.js.map +1 -1
- package/dist/lib/auth/auth.service.d.ts +2 -3
- package/dist/lib/network/network-diagnostic.d.ts +43 -0
- package/dist/lib/transactions/index.d.ts +2 -3
- package/dist/lib/utils/storage.service.d.ts +0 -12
- package/dist/lib/wallet/wallet-data.service.d.ts +1 -1
- package/dist/lib/wallet/wallet-handlers.service.d.ts +1 -16
- package/dist/lib/wallet/wallet.service.d.ts +3 -0
- package/dist/package.json +1 -2
- package/dist/types/auth.d.ts +9 -7
- package/dist/types/common.d.ts +4 -0
- package/dist/types/error-response-codes.d.ts +6 -1
- package/dist/types/network-diagnostic.d.ts +23 -0
- package/dist/types/storage.d.ts +0 -1
- package/dist/types/transactions.d.ts +7 -4
- package/dist/types/wallet.d.ts +3 -3
- package/package.json +1 -2
- package/dist/lib/auth/auth.model.d.ts +0 -108
- package/dist/lib/transactions/transactions.model.d.ts +0 -22
package/dist/base.d.ts
CHANGED
|
@@ -42,6 +42,7 @@ export declare abstract class Base {
|
|
|
42
42
|
* @throws Error if the API returns an error response or network failure occurs
|
|
43
43
|
*/
|
|
44
44
|
protected request<T>(route: RequestRoute, options?: RequestOptions): Promise<T>;
|
|
45
|
+
private mapCategoryToErrorCode;
|
|
45
46
|
private _getRequestHeaders;
|
|
46
47
|
protected securityWorker(securityData: any): Promise<any>;
|
|
47
48
|
}
|
package/dist/generated/api.d.ts
CHANGED
|
@@ -1062,6 +1062,15 @@ export interface BalanceQueryDto {
|
|
|
1062
1062
|
* @example "ERC_20"
|
|
1063
1063
|
*/
|
|
1064
1064
|
tokenType?: "ERC_20" | "ERC_1404" | "BEP_20" | "ARC_20" | "ARC_1404" | "MRC_20" | "BRC_20" | "ALGO_STANDARD" | "ALGO_APP" | "SUI_COIN" | "SUI_MOVE_COIN" | "SUI_SECURITY_TOKEN" | "TOKEN_FACTORY" | "SEI_ERC_20" | "APT_FUNGIBLE_ASSET" | "SPL_TOKEN" | "SPL_TOKEN_2022" | "POLYMESH_ASSET" | "HBAR_ERC_20";
|
|
1065
|
+
/**
|
|
1066
|
+
* Wallet ID
|
|
1067
|
+
* @format uuid
|
|
1068
|
+
* @minLength 36
|
|
1069
|
+
* @maxLength 36
|
|
1070
|
+
* @pattern ^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$
|
|
1071
|
+
* @example "123e4567-e89b-12d3-a456-426614174000"
|
|
1072
|
+
*/
|
|
1073
|
+
walletId?: string;
|
|
1065
1074
|
}
|
|
1066
1075
|
export interface BalanceResponseDto {
|
|
1067
1076
|
/**
|
|
@@ -1138,6 +1147,15 @@ export interface BalanceResponseDto {
|
|
|
1138
1147
|
* @example "20"
|
|
1139
1148
|
*/
|
|
1140
1149
|
unlockedTokenBalance?: string;
|
|
1150
|
+
/**
|
|
1151
|
+
* Wallet ID
|
|
1152
|
+
* @format uuid
|
|
1153
|
+
* @minLength 36
|
|
1154
|
+
* @maxLength 36
|
|
1155
|
+
* @pattern ^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$
|
|
1156
|
+
* @example "123e4567-e89b-12d3-a456-426614174000"
|
|
1157
|
+
*/
|
|
1158
|
+
walletId?: string;
|
|
1141
1159
|
}
|
|
1142
1160
|
export interface BulkBalanceQueryDto {
|
|
1143
1161
|
/**
|
|
@@ -1891,6 +1909,15 @@ export interface FetchBalanceParams {
|
|
|
1891
1909
|
* @example "ERC_20"
|
|
1892
1910
|
*/
|
|
1893
1911
|
tokenType?: "ERC_20" | "ERC_1404" | "BEP_20" | "ARC_20" | "ARC_1404" | "MRC_20" | "BRC_20" | "ALGO_STANDARD" | "ALGO_APP" | "SUI_COIN" | "SUI_MOVE_COIN" | "SUI_SECURITY_TOKEN" | "TOKEN_FACTORY" | "SEI_ERC_20" | "APT_FUNGIBLE_ASSET" | "SPL_TOKEN" | "SPL_TOKEN_2022" | "POLYMESH_ASSET" | "HBAR_ERC_20";
|
|
1912
|
+
/**
|
|
1913
|
+
* Wallet ID
|
|
1914
|
+
* @format uuid
|
|
1915
|
+
* @minLength 36
|
|
1916
|
+
* @maxLength 36
|
|
1917
|
+
* @pattern ^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$
|
|
1918
|
+
* @example "123e4567-e89b-12d3-a456-426614174000"
|
|
1919
|
+
*/
|
|
1920
|
+
walletId?: string;
|
|
1894
1921
|
}
|
|
1895
1922
|
export type FetchBulkBalanceData = BulkBalanceResponseDto;
|
|
1896
1923
|
export type FetchEvmTokenAssetInfoData = AssetTokenInfoResponseDto;
|
|
@@ -1964,6 +1991,15 @@ export interface FetchOnlyBalanceParams {
|
|
|
1964
1991
|
* @example "ERC_20"
|
|
1965
1992
|
*/
|
|
1966
1993
|
tokenType?: "ERC_20" | "ERC_1404" | "BEP_20" | "ARC_20" | "ARC_1404" | "MRC_20" | "BRC_20" | "ALGO_STANDARD" | "ALGO_APP" | "SUI_COIN" | "SUI_MOVE_COIN" | "SUI_SECURITY_TOKEN" | "TOKEN_FACTORY" | "SEI_ERC_20" | "APT_FUNGIBLE_ASSET" | "SPL_TOKEN" | "SPL_TOKEN_2022" | "POLYMESH_ASSET" | "HBAR_ERC_20";
|
|
1994
|
+
/**
|
|
1995
|
+
* Wallet ID
|
|
1996
|
+
* @format uuid
|
|
1997
|
+
* @minLength 36
|
|
1998
|
+
* @maxLength 36
|
|
1999
|
+
* @pattern ^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$
|
|
2000
|
+
* @example "123e4567-e89b-12d3-a456-426614174000"
|
|
2001
|
+
*/
|
|
2002
|
+
walletId?: string;
|
|
1967
2003
|
}
|
|
1968
2004
|
export type FetchTransactionByHashOrReferenceData = TransactionStatusDataResponseDto;
|
|
1969
2005
|
export interface FetchTransactionByHashOrReferenceParams {
|
|
@@ -2055,11 +2091,6 @@ export interface GenerateMissingAddressRequestDto {
|
|
|
2055
2091
|
walletId: string;
|
|
2056
2092
|
}
|
|
2057
2093
|
export interface GenerateMissingAddressResponseDto {
|
|
2058
|
-
/**
|
|
2059
|
-
* Wallet address information for the chains supported by the wallet. Use `walletAddressesInfo` instead.
|
|
2060
|
-
* @deprecated
|
|
2061
|
-
*/
|
|
2062
|
-
walletAddressInfo: WalletAddressInfo;
|
|
2063
2094
|
/**
|
|
2064
2095
|
* Array of encrypted shares which will be utilized to reconstruct the seed to generate the missing addresses
|
|
2065
2096
|
* @maxItems 100
|
|
@@ -2988,11 +3019,6 @@ export interface GetUserAssetResponseDto {
|
|
|
2988
3019
|
groupedAssets: object[];
|
|
2989
3020
|
/** Pagination data */
|
|
2990
3021
|
pagination: PaginationDto;
|
|
2991
|
-
/**
|
|
2992
|
-
* Wallet address information for the chains supported by the wallet. Use `walletAddressesInfo` instead.
|
|
2993
|
-
* @deprecated
|
|
2994
|
-
*/
|
|
2995
|
-
walletAddressInfo: WalletAddressInfo;
|
|
2996
3022
|
/** Typed list of wallet addresses. */
|
|
2997
3023
|
walletAddressesInfo: WalletAddressesInfoEntry[];
|
|
2998
3024
|
}
|
|
@@ -5913,19 +5939,13 @@ export interface WallabyAuthPubKeyResponseDto {
|
|
|
5913
5939
|
wallabyAuthPubKey: string;
|
|
5914
5940
|
}
|
|
5915
5941
|
export interface Wallet {
|
|
5916
|
-
/** The default Algo address */
|
|
5917
|
-
algoAddress: string;
|
|
5918
5942
|
/** Total number of assets in the wallet */
|
|
5919
5943
|
assetsCount: number;
|
|
5920
|
-
/** The default BTC address */
|
|
5921
|
-
btcAddress: string;
|
|
5922
5944
|
/**
|
|
5923
5945
|
* How the wallet was created
|
|
5924
5946
|
* @example "user_created"
|
|
5925
5947
|
*/
|
|
5926
5948
|
creationType?: "user_imported" | "user_created" | null;
|
|
5927
|
-
/** The default EVM address */
|
|
5928
|
-
evmAddress: string;
|
|
5929
5949
|
/** Wallet ID */
|
|
5930
5950
|
id: string;
|
|
5931
5951
|
keyShares: KeyShare;
|
|
@@ -5957,17 +5977,6 @@ export interface WalletAddress {
|
|
|
5957
5977
|
/** Wallet ID */
|
|
5958
5978
|
walletId: string;
|
|
5959
5979
|
}
|
|
5960
|
-
export interface WalletAddressInfo {
|
|
5961
|
-
algoAddress: string;
|
|
5962
|
-
aptAddress: string;
|
|
5963
|
-
btcAddress: string;
|
|
5964
|
-
ccAddress: string;
|
|
5965
|
-
evmAddress: string;
|
|
5966
|
-
injAddress: string;
|
|
5967
|
-
polyxAddress: string;
|
|
5968
|
-
solAddress: string;
|
|
5969
|
-
suiAddress: string;
|
|
5970
|
-
}
|
|
5971
5980
|
export interface WalletAddressType {
|
|
5972
5981
|
/** Address Type ID */
|
|
5973
5982
|
id: number;
|
|
@@ -6053,6 +6062,8 @@ export interface WalletCreatedDto {
|
|
|
6053
6062
|
wallabyAuthPubKey: string;
|
|
6054
6063
|
/** Wallet Info */
|
|
6055
6064
|
wallet: WalletDto;
|
|
6065
|
+
/** Typed list of wallet addresses. */
|
|
6066
|
+
walletAddressesInfo: WalletAddressesInfoEntry[];
|
|
6056
6067
|
}
|
|
6057
6068
|
export interface WalletDto {
|
|
6058
6069
|
/**
|
|
@@ -8146,6 +8157,24 @@ export declare namespace Transactions {
|
|
|
8146
8157
|
};
|
|
8147
8158
|
type ResponseBody = GetEstimateFeeData;
|
|
8148
8159
|
}
|
|
8160
|
+
/**
|
|
8161
|
+
* @description The sign and broadcast transaction API was designed and implemented specifically for uses cases where the caller has their own custom raw transaction that is not yet currently supported by Wallaby
|
|
8162
|
+
* @tags Transactions, Raw, Transactions
|
|
8163
|
+
* @name SignAndBroadcastRawTx
|
|
8164
|
+
* @summary Sign and broadcast raw transaction API
|
|
8165
|
+
* @request POST:/api/v1/transactions/sign-broadcast-rawtx
|
|
8166
|
+
* @secure
|
|
8167
|
+
*/
|
|
8168
|
+
namespace SignAndBroadcastRawTx {
|
|
8169
|
+
type RequestParams = {};
|
|
8170
|
+
type RequestQuery = {};
|
|
8171
|
+
type RequestBody = RawTxRequestDto;
|
|
8172
|
+
type RequestHeaders = {
|
|
8173
|
+
/** A unique identifier for the request, used for tracing and debugging */
|
|
8174
|
+
"x-client-request-id"?: string;
|
|
8175
|
+
};
|
|
8176
|
+
type ResponseBody = SignAndBroadcastRawTxData;
|
|
8177
|
+
}
|
|
8149
8178
|
/**
|
|
8150
8179
|
* No description
|
|
8151
8180
|
* @tags Transactions, Query
|
|
@@ -8177,24 +8206,6 @@ export declare namespace Transactions {
|
|
|
8177
8206
|
};
|
|
8178
8207
|
type ResponseBody = FetchTransactionByHashOrReferenceData;
|
|
8179
8208
|
}
|
|
8180
|
-
/**
|
|
8181
|
-
* @description The sign and broadcast transaction API was designed and implemented specifically for uses cases where the caller has their own custom raw transaction that is not yet currently supported by Wallaby
|
|
8182
|
-
* @tags Transactions, Raw, Transactions
|
|
8183
|
-
* @name SignAndBroadcastRawTx
|
|
8184
|
-
* @summary Sign and broadcast raw transaction API
|
|
8185
|
-
* @request POST:/api/v1/transactions/sign-broadcast-rawtx
|
|
8186
|
-
* @secure
|
|
8187
|
-
*/
|
|
8188
|
-
namespace SignAndBroadcastRawTx {
|
|
8189
|
-
type RequestParams = {};
|
|
8190
|
-
type RequestQuery = {};
|
|
8191
|
-
type RequestBody = RawTxRequestDto;
|
|
8192
|
-
type RequestHeaders = {
|
|
8193
|
-
/** A unique identifier for the request, used for tracing and debugging */
|
|
8194
|
-
"x-client-request-id"?: string;
|
|
8195
|
-
};
|
|
8196
|
-
type ResponseBody = SignAndBroadcastRawTxData;
|
|
8197
|
-
}
|
|
8198
8209
|
/**
|
|
8199
8210
|
* No description
|
|
8200
8211
|
* @tags Transactions, Transactions, Multisig, Raw
|
|
@@ -8476,6 +8487,15 @@ export declare namespace Query {
|
|
|
8476
8487
|
* @example "ERC_20"
|
|
8477
8488
|
*/
|
|
8478
8489
|
tokenType?: "ERC_20" | "ERC_1404" | "BEP_20" | "ARC_20" | "ARC_1404" | "MRC_20" | "BRC_20" | "ALGO_STANDARD" | "ALGO_APP" | "SUI_COIN" | "SUI_MOVE_COIN" | "SUI_SECURITY_TOKEN" | "TOKEN_FACTORY" | "SEI_ERC_20" | "APT_FUNGIBLE_ASSET" | "SPL_TOKEN" | "SPL_TOKEN_2022" | "POLYMESH_ASSET" | "HBAR_ERC_20";
|
|
8490
|
+
/**
|
|
8491
|
+
* Wallet ID
|
|
8492
|
+
* @format uuid
|
|
8493
|
+
* @minLength 36
|
|
8494
|
+
* @maxLength 36
|
|
8495
|
+
* @pattern ^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$
|
|
8496
|
+
* @example "123e4567-e89b-12d3-a456-426614174000"
|
|
8497
|
+
*/
|
|
8498
|
+
walletId?: string;
|
|
8479
8499
|
};
|
|
8480
8500
|
type RequestBody = never;
|
|
8481
8501
|
type RequestHeaders = {
|
|
@@ -8521,6 +8541,15 @@ export declare namespace Query {
|
|
|
8521
8541
|
* @example "ERC_20"
|
|
8522
8542
|
*/
|
|
8523
8543
|
tokenType?: "ERC_20" | "ERC_1404" | "BEP_20" | "ARC_20" | "ARC_1404" | "MRC_20" | "BRC_20" | "ALGO_STANDARD" | "ALGO_APP" | "SUI_COIN" | "SUI_MOVE_COIN" | "SUI_SECURITY_TOKEN" | "TOKEN_FACTORY" | "SEI_ERC_20" | "APT_FUNGIBLE_ASSET" | "SPL_TOKEN" | "SPL_TOKEN_2022" | "POLYMESH_ASSET" | "HBAR_ERC_20";
|
|
8544
|
+
/**
|
|
8545
|
+
* Wallet ID
|
|
8546
|
+
* @format uuid
|
|
8547
|
+
* @minLength 36
|
|
8548
|
+
* @maxLength 36
|
|
8549
|
+
* @pattern ^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$
|
|
8550
|
+
* @example "123e4567-e89b-12d3-a456-426614174000"
|
|
8551
|
+
*/
|
|
8552
|
+
walletId?: string;
|
|
8524
8553
|
};
|
|
8525
8554
|
type RequestBody = never;
|
|
8526
8555
|
type RequestHeaders = {
|
|
@@ -10308,16 +10337,6 @@ export declare class Api<SecurityDataType extends unknown> {
|
|
|
10308
10337
|
* @secure
|
|
10309
10338
|
*/
|
|
10310
10339
|
getEstimateFee: (query: GetEstimateFeeParams, params?: RequestParams) => Promise<FeeEstimatesResponseDto>;
|
|
10311
|
-
/**
|
|
10312
|
-
* No description
|
|
10313
|
-
*
|
|
10314
|
-
* @tags Transactions, Query
|
|
10315
|
-
* @name FetchTransactionByHashOrReference
|
|
10316
|
-
* @summary Fetch transaction status data using a reference or transaction hash
|
|
10317
|
-
* @request GET:/api/v1/transactions/status
|
|
10318
|
-
* @secure
|
|
10319
|
-
*/
|
|
10320
|
-
fetchTransactionByHashOrReference: (query: FetchTransactionByHashOrReferenceParams, params?: RequestParams) => Promise<TransactionStatusDataResponseDto>;
|
|
10321
10340
|
/**
|
|
10322
10341
|
* @description The sign and broadcast transaction API was designed and implemented specifically for uses cases where the caller has their own custom raw transaction that is not yet currently supported by Wallaby
|
|
10323
10342
|
*
|
|
@@ -10328,6 +10347,16 @@ export declare class Api<SecurityDataType extends unknown> {
|
|
|
10328
10347
|
* @secure
|
|
10329
10348
|
*/
|
|
10330
10349
|
signAndBroadcastRawTx: (data: RawTxRequestDto, params?: RequestParams) => Promise<TransactionResponseDto>;
|
|
10350
|
+
/**
|
|
10351
|
+
* No description
|
|
10352
|
+
*
|
|
10353
|
+
* @tags Transactions, Query
|
|
10354
|
+
* @name FetchTransactionByHashOrReference
|
|
10355
|
+
* @summary Fetch transaction status data using a reference or transaction hash
|
|
10356
|
+
* @request GET:/api/v1/transactions/status
|
|
10357
|
+
* @secure
|
|
10358
|
+
*/
|
|
10359
|
+
fetchTransactionByHashOrReference: (query: FetchTransactionByHashOrReferenceParams, params?: RequestParams) => Promise<TransactionStatusDataResponseDto>;
|
|
10331
10360
|
/**
|
|
10332
10361
|
* No description
|
|
10333
10362
|
*
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function omit<T extends object, K extends keyof T>(obj: T | null | undefined, keys: K[]): Omit<T, K>;
|