@verified-network/verified-sdk 1.9.9 → 2.0.1

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.
Files changed (41) hide show
  1. package/README.md +1 -1
  2. package/dist/abi/assetmanager/balancer/MarginIssueManager.json +7309 -7271
  3. package/dist/contract/amm/margin/index.d.ts +20 -45
  4. package/dist/contract/amm/margin/index.js +20 -17
  5. package/dist/contract/amm/primary/index.d.ts +22 -53
  6. package/dist/contract/amm/primary/index.js +3 -0
  7. package/dist/contract/amm/secondary/index.d.ts +16 -29
  8. package/dist/contract/amm/secondary/index.js +3 -0
  9. package/dist/contract/bond/index.d.ts +24 -31
  10. package/dist/contract/bond/index.js +25 -22
  11. package/dist/contract/cash/index.d.ts +21 -28
  12. package/dist/contract/cash/index.js +19 -16
  13. package/dist/contract/client/index.d.ts +33 -73
  14. package/dist/contract/client/index.js +11 -8
  15. package/dist/contract/custody/index.d.ts +20 -45
  16. package/dist/contract/custody/index.js +3 -0
  17. package/dist/contract/distribution/index.d.ts +32 -42
  18. package/dist/contract/distribution/index.js +20 -17
  19. package/dist/contract/erc20/index.d.ts +16 -29
  20. package/dist/contract/erc20/index.js +3 -0
  21. package/dist/contract/factory/index.d.ts +32 -66
  22. package/dist/contract/factory/index.js +14 -11
  23. package/dist/contract/index.d.ts +15 -0
  24. package/dist/contract/index.js +172 -16
  25. package/dist/contract/liquidity/index.d.ts +98 -144
  26. package/dist/contract/liquidity/index.js +63 -60
  27. package/dist/contract/loans/compound/index.d.ts +17 -21
  28. package/dist/contract/loans/compound/index.js +7 -4
  29. package/dist/contract/pool/index.d.ts +12 -13
  30. package/dist/contract/pool/index.js +4 -1
  31. package/dist/contract/rates/index.d.ts +13 -17
  32. package/dist/contract/rates/index.js +3 -0
  33. package/dist/contract/securitiesfactory/index.d.ts +23 -48
  34. package/dist/contract/securitiesfactory/index.js +6 -3
  35. package/dist/contract/security/index.d.ts +36 -109
  36. package/dist/contract/security/index.js +3 -0
  37. package/dist/contract/token/index.d.ts +19 -35
  38. package/dist/contract/token/index.js +7 -4
  39. package/dist/contractAddress/index.js +1 -1
  40. package/dist/utils/constants.js +1 -0
  41. package/package.json +5 -4
@@ -40,6 +40,9 @@ class Security extends index_1.VerifiedContract {
40
40
  super(address, JSON.stringify(Security_json_1.abi), signer);
41
41
  this.contractAddress = address;
42
42
  }
43
+ async _getMeeQuote(paymentTokenAddress, functionName, args) {
44
+ return await this.getQuote(paymentTokenAddress, functionName, args);
45
+ }
43
46
  async whiteList(_spender, _amount, options) {
44
47
  await this.validateInput(index_1.DATATYPES.ADDRESS, _spender);
45
48
  await this.validateInput(index_1.DATATYPES.NUMBER, _amount);
@@ -1,51 +1,35 @@
1
- import { VerifiedContract } from '../index';
1
+ import { VerifiedContract, Options } from "../index";
2
2
  import { VerifiedWallet } from "../../wallet";
3
3
  export default class Token extends VerifiedContract {
4
4
  contractAddress: string;
5
5
  constructor(signer: VerifiedWallet, bondCurrencyAddress: string);
6
+ _getMeeQuote(paymentTokenAddress: string, functionName: string, args: any[]): Promise<{
7
+ tokenAddress: string;
8
+ amount: string;
9
+ amountInWei: string;
10
+ amouuntValue: string;
11
+ chainId: number;
12
+ functionName: string;
13
+ }>;
6
14
  /**
7
15
  * Lend by purchasing bond token against other cash token [callable by client]
8
16
  * _sender is address of bond token redeemed,
9
17
  * _receiver is bond token address,
10
18
  * _tokens is amount of tokens redeemed
11
19
  * @param (address _sender, address _receiver, uint256 _tokens)
12
- * @returns bool
13
- */
14
- transferFrom(_senderAddress: string, _recieverAddress: string, _tokens: string, options?: {
15
- gasPrice: number;
16
- gasLimit: number;
17
- }): any;
18
- balanceOf(_wallet: string, options?: {
19
- gasPrice: number;
20
- gasLimit: number;
21
- }): any;
20
+ * @returns bool
21
+ */
22
+ transferFrom(_senderAddress: string, _recieverAddress: string, _tokens: string, options?: Options): any;
23
+ balanceOf(_wallet: string, options?: Options): any;
22
24
  getIssuer(): any;
23
- requestTransfer(_recieverAddress: string, _tokens: string, options?: {
24
- gasPrice: number;
25
- gasLimit: number;
26
- }): any;
27
- requestTransaction(_amount: string, _payer: string, _collateralName: string, _collateralContract: string, options?: {
28
- gasPrice: number;
29
- gasLimit: number;
30
- }): any;
25
+ requestTransfer(_recieverAddress: string, _tokens: string, options?: Options): any;
26
+ requestTransaction(_amount: string, _payer: string, _collateralName: string, _collateralContract: string, options?: Options): any;
31
27
  name(): any;
32
28
  symbol(): any;
33
29
  decimals(): any;
34
30
  totalSupply(): any;
35
- approve(_spender: string, _amount: string, options?: {
36
- gasPrice: number;
37
- gasLimit: number;
38
- }): any;
39
- allowance(_owner: string, _spender: string, options?: {
40
- gasPrice: number;
41
- gasLimit: number;
42
- }): any;
43
- increaseAllowance(_spender: string, _addedValue: string, options?: {
44
- gasPrice: number;
45
- gasLimit: number;
46
- }): any;
47
- decreaseAllowance(_spender: string, _subtractedValue: string, options?: {
48
- gasPrice: number;
49
- gasLimit: number;
50
- }): any;
31
+ approve(_spender: string, _amount: string, options?: Options): any;
32
+ allowance(_owner: string, _spender: string, options?: Options): any;
33
+ increaseAllowance(_spender: string, _addedValue: string, options?: Options): any;
34
+ decreaseAllowance(_spender: string, _subtractedValue: string, options?: Options): any;
51
35
  }
@@ -27,14 +27,17 @@ class Token extends index_1.VerifiedContract {
27
27
  super(address, JSON.stringify(Token_json_1.abi), signer);
28
28
  this.contractAddress = address;
29
29
  }
30
+ async _getMeeQuote(paymentTokenAddress, functionName, args) {
31
+ return await this.getQuote(paymentTokenAddress, functionName, args);
32
+ }
30
33
  /**
31
34
  * Lend by purchasing bond token against other cash token [callable by client]
32
35
  * _sender is address of bond token redeemed,
33
36
  * _receiver is bond token address,
34
37
  * _tokens is amount of tokens redeemed
35
38
  * @param (address _sender, address _receiver, uint256 _tokens)
36
- * @returns bool
37
- */
39
+ * @returns bool
40
+ */
38
41
  async transferFrom(_senderAddress, _recieverAddress, _tokens, options) {
39
42
  await this.validateInput(index_1.DATATYPES.ADDRESS, _senderAddress);
40
43
  await this.validateInput(index_1.DATATYPES.ADDRESS, _recieverAddress);
@@ -42,13 +45,13 @@ class Token extends index_1.VerifiedContract {
42
45
  return this.callContract(FUNCTIONS.TRANSFERFROM, _senderAddress, _recieverAddress, _tokens, options);
43
46
  }
44
47
  /* Request bond token balance of wallet
45
- */
48
+ */
46
49
  async balanceOf(_wallet, options) {
47
50
  await this.validateInput(index_1.DATATYPES.ADDRESS, _wallet);
48
51
  return this.callContract(FUNCTIONS.BALANCE, _wallet, options);
49
52
  }
50
53
  /* Get address of issuer of token
51
- */
54
+ */
52
55
  async getIssuer() {
53
56
  return this.callContract(FUNCTIONS.GETISSUER);
54
57
  }
@@ -327,7 +327,7 @@ const contractAddress = {
327
327
  'SecondaryIssuePoolFactory': '0x4519148Cc4030c2e3573f1f886ed4071Fa35d62B',
328
328
  'BalancerSecondaryIssueManager': '0xE3e3e9b8c0c292eD3756C7A1037322738de6B7FC',
329
329
  'MarginTradingPoolFactory': '0xB1ae3Fc5B16d3736bf0db20606fB9a10b435392c',
330
- 'BalancerMarginIssueManager': '0x96E90554cD3895b29d68Be37c518F5f22cba1A36',
330
+ 'BalancerMarginIssueManager': '0x095a3075De6950530F6053C97dB06cc74E78E11e',
331
331
  'Custody': '0xA166F1f0dD40fFEBA529e327f17188d3Db0aB709',
332
332
  'Compound': '0x8c364b06741C9fE045E0e510A39BCbAf7445D8fD',
333
333
  'CASH': {
@@ -12,6 +12,7 @@ exports.PaymasterConstants = {
12
12
  PAYMASTER_API_KEY: "BuFP2-5w-.5b3daf3a-d044-4dda-819c-4c4d8431df88",
13
13
  BUNDLER_API_KEY: "nJPK7B3ru.dd7f7861-190d-41bd-af80-6877f74b8f44",
14
14
  RPC_URL: "https://rpc.sepolia.org",
15
+ PAYMENT_TOKEN: "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee",
15
16
  },
16
17
  //polgon mainnet
17
18
  137: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@verified-network/verified-sdk",
3
- "version": "1.9.9",
3
+ "version": "2.0.1",
4
4
  "description": "An SDK to develop applications on the Verified Network",
5
5
  "repository": {
6
6
  "type": "git",
@@ -31,11 +31,12 @@
31
31
  "greet": "./bin/index.bin.js"
32
32
  },
33
33
  "dependencies": {
34
+ "@biconomy/abstractjs": "^1.0.13",
34
35
  "@biconomy/account": "^4.1.1",
35
- "ethereumjs-tx": "^2.1.2",
36
+ "@rhinestone/module-sdk": "^0.2.8",
36
37
  "ethers": "^5.7.2",
37
38
  "tslib": "^2.6.2",
38
- "viem": "^2.12.0"
39
+ "viem": "^2.29.3"
39
40
  },
40
41
  "devDependencies": {
41
42
  "@types/mocha": "^10.0.6",
@@ -43,4 +44,4 @@
43
44
  "ts-node": "^10.9.1",
44
45
  "typescript": "^5.4.5"
45
46
  }
46
- }
47
+ }