wallaby-cash 2.2.2 → 2.2.4

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.
@@ -1,5 +1,5 @@
1
1
  import { Base } from '../../base';
2
- import { WallabyConfig, TokenStandard, FeeEstimatesResponse, Transaction, BlockchainName, GetPendingTransactionsRequest, GetPendingTransactionsResponse, ResolvePendingTransactionRequest, ResolvePendingTransactionResponse } from '../../types';
2
+ import { WallabyConfig, TokenStandard, FeeEstimatesResponse, Transaction, BlockchainName, GetPendingTransactionsRequest, GetPendingTransactionsResponse, ResolvePendingTransactionRequest, ResolvePendingTransactionResponse, TransactionResponse } from '../../types';
3
3
  import { CreateAllowanceRequest, TransactionStatusResponse, TransferRequest } from '../../types';
4
4
  import { FeeEstimateRequest } from './transactions.model';
5
5
  export declare class Transactions extends Base {
@@ -61,10 +61,7 @@ export declare class Transactions extends Base {
61
61
  * @param {string} memo
62
62
  * @returns {TransactionResponse}
63
63
  */
64
- transfer({ originAddress, recipientAddress, amount, assetId, walletId, reference, authenticationOptions, memo, }: TransferRequest): Promise<{
65
- message: string;
66
- transaction: Transaction;
67
- }>;
64
+ transfer({ originAddress, recipientAddress, amount, assetId, walletId, reference, authenticationOptions, memo, }: TransferRequest): Promise<TransactionResponse>;
68
65
  /**
69
66
  *
70
67
  * @public
@@ -80,9 +77,7 @@ export declare class Transactions extends Base {
80
77
  * @returns {CreateAllowanceResponse}
81
78
  *
82
79
  */
83
- createAllowance({ authenticationOptions, walletId, ownerAddress, spenderAddress, amount, assetId, suiObjectId, contractAddress, chainName, assetSymbol, reference, memo, }: CreateAllowanceRequest): Promise<{
84
- transaction: Transaction;
85
- }>;
80
+ createAllowance({ authenticationOptions, walletId, ownerAddress, spenderAddress, amount, assetId, suiObjectId, contractAddress, chainName, assetSymbol, reference, memo, }: CreateAllowanceRequest): Promise<TransactionResponse>;
86
81
  /**
87
82
  *
88
83
  * @public
@@ -114,7 +114,7 @@ export declare class Cipher {
114
114
  * @param {string} deviceKeyPair - The public key to encrypt the data with.
115
115
  * @returns {Promise<Encrypted>} The encrypted data ready for storage.
116
116
  */
117
- prepareDecryptedDataForStorage({ decryptedData, credentialsKeyPair, deviceKeyPair, }: {
117
+ doubleEncrypt({ decryptedData, credentialsKeyPair, deviceKeyPair, }: {
118
118
  decryptedData: string;
119
119
  credentialsKeyPair: {
120
120
  publicKey: string;
@@ -44,3 +44,4 @@ export declare const env: {
44
44
  isServer: boolean;
45
45
  isWeb: boolean;
46
46
  };
47
+ export declare const currentPackageVersion: string;
@@ -5,6 +5,8 @@ export declare class WalletService extends Base {
5
5
  private authService;
6
6
  private handlers;
7
7
  private passkeyService;
8
+ private passwordResetAttempts;
9
+ private migrationAttempts;
8
10
  constructor(config: WallabyConfig);
9
11
  /**
10
12
  * @public
package/dist/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "wallaby-cash",
3
- "version": "2.2.2",
3
+ "version": "2.2.4",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git@github.com:WALLABY-WaaS/wallaby-sdk-js.git"
@@ -64,6 +64,7 @@
64
64
  "@rollup/plugin-commonjs": "^26.0.1",
65
65
  "@rollup/plugin-json": "^6.1.0",
66
66
  "@rollup/plugin-node-resolve": "^15.2.3",
67
+ "@rollup/plugin-replace": "^6.0.3",
67
68
  "@rollup/plugin-terser": "^0.4.4",
68
69
  "@rollup/plugin-typescript": "^11.1.6",
69
70
  "@semantic-release/changelog": "^6.0.3",
@@ -33,6 +33,7 @@ export declare enum ErrorResponseCodes {
33
33
  'sdk_jwt_invalid' = "sdk_jwt_invalid",
34
34
  'sdk_jwt_expired' = "sdk_jwt_expired",
35
35
  'sdk_unknown_error' = "sdk_unknown_error",
36
+ 'sdk_too_many_requests' = "sdk_too_many_requests",
36
37
  'sdk_seed_phrase_decryption_failed' = "sdk_seed_phrase_decryption_failed",
37
38
  'sdk_key_shares_not_found' = "sdk_key_shares_not_found",
38
39
  'sdk_key_share_decryption_failed' = "sdk_key_share_decryption_failed",
@@ -55,5 +55,7 @@ export declare enum V2KeyNames {
55
55
  EncryptedStandardSeedPhrase = "encrypted-standard-seedPhrase",
56
56
  PasskeyCredential = "pass-key-credential",
57
57
  PrimaryDeviceKeyShare = "primary-device-key-share",
58
- WallabyAuthPubKey = "wallaby-auth-pub-key"
58
+ WallabyAuthPubKey = "wallaby-auth-pub-key",
59
+ MigrationVersion = "wsdk_migrated_with_version",
60
+ LastMigratedAt = "wsdk_last_migrated_at"
59
61
  }
@@ -1,7 +1,6 @@
1
1
  import { AssetConfig, BlockchainName, BlockchainSlip44, Encrypted, OwnershipType, TokenStandard, User } from './common';
2
2
  import { Merchant } from './merchants';
3
3
  import { AuthenticationResponse } from './auth';
4
- import { CreateAllowanceTransactionData } from '../generated/api';
5
4
  export declare type Transaction = {
6
5
  id: string;
7
6
  reference: string;
@@ -112,7 +111,10 @@ export declare type CreateAllowanceRequestWithAmends = Omit<CreateAllowanceReque
112
111
  encryptedSeed?: CreateAllowanceRequest['encryptedSeed'];
113
112
  encryptedShares?: CreateAllowanceRequest['encryptedShares'];
114
113
  };
115
- export declare type TransactionResponse = CreateAllowanceTransactionData;
114
+ export declare type TransactionResponse = {
115
+ message: string;
116
+ transaction: Transaction;
117
+ };
116
118
  export declare type TransactionStatusResponse = {
117
119
  status: TransactionStatus;
118
120
  transactionHash: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "wallaby-cash",
3
- "version": "2.2.2",
3
+ "version": "2.2.4",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git@github.com:WALLABY-WaaS/wallaby-sdk-js.git"
@@ -64,6 +64,7 @@
64
64
  "@rollup/plugin-commonjs": "^26.0.1",
65
65
  "@rollup/plugin-json": "^6.1.0",
66
66
  "@rollup/plugin-node-resolve": "^15.2.3",
67
+ "@rollup/plugin-replace": "^6.0.3",
67
68
  "@rollup/plugin-terser": "^0.4.4",
68
69
  "@rollup/plugin-typescript": "^11.1.6",
69
70
  "@semantic-release/changelog": "^6.0.3",