@verified-network/verified-sdk 2.0.3 → 2.0.5

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.
@@ -12,6 +12,7 @@ export default class Custody extends VerifiedContract {
12
12
  functionName: string;
13
13
  }>;
14
14
  createVault(_creator: string, _id: string, options?: Options): any;
15
+ resetPin(_creator: string, _id: string, _new: string, options?: Options): any;
15
16
  getVaults(): any;
16
17
  transferVault(_creator: string, _id: string, _transferee: string, options?: Options): any;
17
18
  getCreator(_creator: string, _pin: string, options?: Options): any;
@@ -19,6 +20,7 @@ export default class Custody extends VerifiedContract {
19
20
  removeParticipant(_creator: string, _id: string, _participant: string, options?: Options): any;
20
21
  confirmParticipant(_creator: string, _id: string, _participant: string, _pin: string, _confirmation: string, options?: Options): any;
21
22
  defineQuorum(_creator: string, _id: string, _minParticipants: string, options?: Options): any;
23
+ getQuorum(_creator: string, _id: string, options?: Options): any;
22
24
  promptSignatures(_creator: string, _id: string, options?: Options): any;
23
25
  signTransaction(_creator: string, _id: string, _participant: string, _tx: string, _pin: string, options?: Options): any;
24
26
  checkQuorum(_creator: string, _id: string, _participant: string, _txid: string, options?: Options): any;
@@ -7,6 +7,7 @@ const Vault_json_1 = require("../../abi/custody/Vault.json");
7
7
  var FUNCTIONS;
8
8
  (function (FUNCTIONS) {
9
9
  FUNCTIONS["CREATEVAULT"] = "createVault";
10
+ FUNCTIONS["RESETPIN"] = "resetPin";
10
11
  FUNCTIONS["GETVAULTS"] = "getVaults";
11
12
  FUNCTIONS["TRANSFERVAULT"] = "transferVault";
12
13
  FUNCTIONS["GETCREATOR"] = "getCreator";
@@ -14,6 +15,7 @@ var FUNCTIONS;
14
15
  FUNCTIONS["REMOVEPARTICIPANT"] = "removeParticipant";
15
16
  FUNCTIONS["CONFIRMPARTICIPANT"] = "confirmParticipant";
16
17
  FUNCTIONS["DEFINEQUORUM"] = "defineQuorum";
18
+ FUNCTIONS["GETQUORUM"] = "getQuorum";
17
19
  FUNCTIONS["PROMPTSIGNATURES"] = "promptSignatures";
18
20
  FUNCTIONS["SIGNTRANSACTION"] = "signTransaction";
19
21
  FUNCTIONS["CHECKQUORUM"] = "checkQuorum";
@@ -39,6 +41,12 @@ class Custody extends index_1.VerifiedContract {
39
41
  await this.validateInput(index_1.DATATYPES.STRING, _id);
40
42
  return this.callContract(FUNCTIONS.CREATEVAULT, this.sanitiseInput(index_1.DATATYPES.BYTE32, _creator), _id, options);
41
43
  }
44
+ async resetPin(_creator, _id, _new, options) {
45
+ await this.validateInput(index_1.DATATYPES.STRING, _creator);
46
+ await this.validateInput(index_1.DATATYPES.STRING, _id);
47
+ await this.validateInput(index_1.DATATYPES.STRING, _new);
48
+ return this.callContract(FUNCTIONS.RESETPIN, this.sanitiseInput(index_1.DATATYPES.BYTE32, _creator), _id, _new, options);
49
+ }
42
50
  async getVaults() {
43
51
  return this.callContract(FUNCTIONS.GETVAULTS);
44
52
  }
@@ -80,6 +88,11 @@ class Custody extends index_1.VerifiedContract {
80
88
  await this.validateInput(index_1.DATATYPES.NUMBER, _minParticipants);
81
89
  return this.callContract(FUNCTIONS.DEFINEQUORUM, this.sanitiseInput(index_1.DATATYPES.BYTE32, _creator), _id, _minParticipants, options);
82
90
  }
91
+ async getQuorum(_creator, _id, options) {
92
+ await this.validateInput(index_1.DATATYPES.STRING, _creator);
93
+ await this.validateInput(index_1.DATATYPES.STRING, _id);
94
+ return this.callContract(FUNCTIONS.GETQUORUM, this.sanitiseInput(index_1.DATATYPES.BYTE32, _creator), _id, options);
95
+ }
83
96
  async promptSignatures(_creator, _id, options) {
84
97
  await this.validateInput(index_1.DATATYPES.STRING, _creator);
85
98
  await this.validateInput(index_1.DATATYPES.STRING, _id);
@@ -328,7 +328,7 @@ const contractAddress = {
328
328
  'BalancerSecondaryIssueManager': '0xE3e3e9b8c0c292eD3756C7A1037322738de6B7FC',
329
329
  'MarginTradingPoolFactory': '0xB1ae3Fc5B16d3736bf0db20606fB9a10b435392c',
330
330
  'BalancerMarginIssueManager': '0x095a3075De6950530F6053C97dB06cc74E78E11e',
331
- 'Custody': '0x60bc622E02424ACDD415373B6Dd40870d077faa4',
331
+ 'Custody': '0x260A6Afc5a200b721D643CbeBD16d83833F4E0BB',
332
332
  'Compound': '0x8c364b06741C9fE045E0e510A39BCbAf7445D8fD',
333
333
  'CASH': {
334
334
  'VCUSD': '0xC824FCCfe6545c42B609cF6aD6219748A306D83a',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@verified-network/verified-sdk",
3
- "version": "2.0.3",
3
+ "version": "2.0.5",
4
4
  "description": "An SDK to develop applications on the Verified Network",
5
5
  "repository": {
6
6
  "type": "git",