@raac/rpc 1.1.0-beta.62 → 1.1.0-beta.63
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.
|
@@ -4,7 +4,7 @@ const _helpers_1 = require("./_helpers");
|
|
|
4
4
|
async function getParameters(chainId, provider) {
|
|
5
5
|
try {
|
|
6
6
|
const lendingPoolContract = await (0, _helpers_1.getLendingPoolContract)(chainId, provider);
|
|
7
|
-
const [canPaybackDebt, withdrawalsPaused, liquidationThreshold, liquidationGracePeriod, insuranceFee, depositFee, liquidityBufferRatio, supplyCap, borrowCap,
|
|
7
|
+
const [canPaybackDebt, withdrawalsPaused, liquidationThreshold, liquidationGracePeriod, insuranceFee, depositFee, liquidityBufferRatio, supplyCap, borrowCap, vaultOpeningFee, borrowThreshold,] = await lendingPoolContract.parameters();
|
|
8
8
|
const parameters = {
|
|
9
9
|
canPaybackDebt,
|
|
10
10
|
withdrawalsPaused,
|
|
@@ -15,10 +15,8 @@ async function getParameters(chainId, provider) {
|
|
|
15
15
|
liquidityBufferRatio,
|
|
16
16
|
supplyCap,
|
|
17
17
|
borrowCap,
|
|
18
|
-
withdrawTimelockDuration,
|
|
19
18
|
vaultOpeningFee,
|
|
20
19
|
borrowThreshold,
|
|
21
|
-
withdrawTimelockDelay
|
|
22
20
|
};
|
|
23
21
|
return parameters;
|
|
24
22
|
}
|
package/dist/scripts/index.js
CHANGED
|
@@ -68,6 +68,7 @@ async function setup() {
|
|
|
68
68
|
const TreasuryContract = new ethers_1.ethers.Contract(TreasuryAddress, TreasuryABI, signer);
|
|
69
69
|
console.log(await LendingPoolContract.parameters());
|
|
70
70
|
// await rpc.pools.lendingPool.openVaultPosition(chainId, signer);
|
|
71
|
+
console.log(await lendingPoolContract.vaultOpened(signer.address));
|
|
71
72
|
// const secretsReference = await encryptSecrets(chainId, {
|
|
72
73
|
// apiKey: process.env.FRED_API_KEY as string,
|
|
73
74
|
// }, "encryptedFunctionsPrimeRateSecrets.json", signerV5);
|
|
@@ -75,7 +76,6 @@ async function setup() {
|
|
|
75
76
|
// return;
|
|
76
77
|
// const encryptedURL = await encryptSecretURLs(chainId, ["https://emerald-many-grasshopper-318.mypinata.cloud/ipfs/bafkreidwvgtxxeijgdfpujh7dh6wwliomxsmn2qg4ey37ql52oqqoly55m"], signerV5);
|
|
77
78
|
// console.log(encryptedURL);
|
|
78
|
-
return;
|
|
79
79
|
// const secretReference = await generateSecretReference(chainId, {
|
|
80
80
|
// ATTESTATIONS_AUDITOR_BISCUIT: process.env.ATTESTATIONS_AUDITOR_BISCUIT as string,
|
|
81
81
|
// ATTESTATION_BATCHES_BISCUIT: process.env.ATTESTATION_BATCHES_BISCUIT as string,
|
|
@@ -130,8 +130,12 @@ async function setup() {
|
|
|
130
130
|
// signer
|
|
131
131
|
// );
|
|
132
132
|
// set the base uri to instruxi data gateway
|
|
133
|
-
await rpc.nfts.setBaseUri(
|
|
134
|
-
|
|
133
|
+
// await rpc.nfts.setBaseUri(
|
|
134
|
+
// chainId,
|
|
135
|
+
// "http://3.86.253.54:3000/v1/properties/",
|
|
136
|
+
// signer
|
|
137
|
+
// );
|
|
138
|
+
// return;
|
|
135
139
|
const RWAVaultAddress = (0, contracts_1.getContractAddress)(chainId, "rwavault");
|
|
136
140
|
const RWAVaultABI = (0, artifacts_1.getABI)("rwavault");
|
|
137
141
|
const RWAVaultContract = new ethers_1.ethers.Contract(RWAVaultAddress, RWAVaultABI, signer);
|
|
@@ -145,7 +149,7 @@ async function setup() {
|
|
|
145
149
|
// }
|
|
146
150
|
console.log("hello");
|
|
147
151
|
// // // set the oracle address of the RAACHousePrice. TEmporarily simulating that I AM THE ORACLE
|
|
148
|
-
await rpc.contracts.housePrices.setOracle(chainId, signer.address, signer);
|
|
152
|
+
// await rpc.contracts.housePrices.setOracle(chainId, signer.address, signer);
|
|
149
153
|
const raacNFTAddress = (0, contracts_1.getContractAddress)(chainId, "raacnft");
|
|
150
154
|
const raacNFTABI = (0, artifacts_1.getABI)("raacnft");
|
|
151
155
|
const raacNFTContract = new ethers_1.ethers.Contract(raacNFTAddress, raacNFTABI, signer);
|
|
@@ -10,9 +10,7 @@ declare function getParameters(chainId: ChainId, provider: Provider): Promise<{
|
|
|
10
10
|
liquidityBufferRatio: bigint;
|
|
11
11
|
supplyCap: bigint;
|
|
12
12
|
borrowCap: bigint;
|
|
13
|
-
withdrawTimelockDuration: bigint;
|
|
14
13
|
vaultOpeningFee: bigint;
|
|
15
14
|
borrowThreshold: bigint;
|
|
16
|
-
withdrawTimelockDelay: bigint;
|
|
17
15
|
}>;
|
|
18
16
|
export default getParameters;
|