@bulletxyz/bullet-sdk 0.25.4-rc.2 → 0.25.4-rc.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.
- package/dist/browser/index.js +67 -11
- package/dist/browser/index.js.map +2 -2
- package/dist/node/index.js +67 -11
- package/dist/node/index.js.map +2 -2
- package/dist/types/client.d.ts +2 -1
- package/dist/types/rollupTypes.d.ts +16 -0
- package/package.json +1 -1
package/dist/node/index.js
CHANGED
|
@@ -9589,17 +9589,73 @@ var Client = class _Client {
|
|
|
9589
9589
|
init_borrow_lend_market: {
|
|
9590
9590
|
args: {
|
|
9591
9591
|
asset_id: asset,
|
|
9592
|
-
optimal_utilisation_rate:
|
|
9593
|
-
|
|
9594
|
-
|
|
9595
|
-
|
|
9596
|
-
|
|
9597
|
-
|
|
9598
|
-
|
|
9599
|
-
|
|
9600
|
-
|
|
9601
|
-
|
|
9602
|
-
|
|
9592
|
+
optimal_utilisation_rate: BulletWasm.convert_rust_decimal_to_json(
|
|
9593
|
+
optimalUtilisationRate.toFixed()
|
|
9594
|
+
),
|
|
9595
|
+
min_borrow_rate: BulletWasm.convert_rust_decimal_to_json(
|
|
9596
|
+
minBorrowRate.toFixed()
|
|
9597
|
+
),
|
|
9598
|
+
max_borrow_rate: BulletWasm.convert_rust_decimal_to_json(
|
|
9599
|
+
maxBorrowRate.toFixed()
|
|
9600
|
+
),
|
|
9601
|
+
optimal_borrow_rate: BulletWasm.convert_rust_decimal_to_json(
|
|
9602
|
+
optimalBorrowRate.toFixed()
|
|
9603
|
+
),
|
|
9604
|
+
asset_weight: BulletWasm.convert_rust_decimal_to_json(
|
|
9605
|
+
assetWeight.toFixed()
|
|
9606
|
+
),
|
|
9607
|
+
initial_liability_weight: BulletWasm.convert_rust_decimal_to_json(
|
|
9608
|
+
initialLiabilityWeight.toFixed()
|
|
9609
|
+
),
|
|
9610
|
+
maintenance_liability_weight: BulletWasm.convert_rust_decimal_to_json(
|
|
9611
|
+
maintenanceLiabilityWeight.toFixed()
|
|
9612
|
+
),
|
|
9613
|
+
deposit_limit: BulletWasm.convert_rust_decimal_to_json(
|
|
9614
|
+
depositLimit.toFixed()
|
|
9615
|
+
),
|
|
9616
|
+
borrow_limit: BulletWasm.convert_rust_decimal_to_json(
|
|
9617
|
+
borrowLimit.toFixed()
|
|
9618
|
+
),
|
|
9619
|
+
liquidation_reward_ratio: BulletWasm.convert_rust_decimal_to_json(
|
|
9620
|
+
liquidationRewardRatio.toFixed()
|
|
9621
|
+
),
|
|
9622
|
+
liability_liquidation_limit_ratio: BulletWasm.convert_rust_decimal_to_json(
|
|
9623
|
+
liabilityLiquidationLimitRatio.toFixed()
|
|
9624
|
+
)
|
|
9625
|
+
}
|
|
9626
|
+
}
|
|
9627
|
+
}
|
|
9628
|
+
});
|
|
9629
|
+
}
|
|
9630
|
+
async updateBorrowLendMarket(asset, optimalUtilisationRate, minBorrowRate, maxBorrowRate, optimalBorrowRate, assetWeight, initialLiabilityWeight, maintenanceLiabilityWeight, depositLimit, borrowLimit, liquidationRewardRatio, liabilityLiquidationLimitRatio) {
|
|
9631
|
+
return await this.submitTransaction({
|
|
9632
|
+
exchange: {
|
|
9633
|
+
init_borrow_lend_market: {
|
|
9634
|
+
args: {
|
|
9635
|
+
asset_id: asset,
|
|
9636
|
+
optimal_utilisation_rate: optimalUtilisationRate ? BulletWasm.convert_rust_decimal_to_json(
|
|
9637
|
+
optimalUtilisationRate.toFixed()
|
|
9638
|
+
) : null,
|
|
9639
|
+
min_borrow_rate: minBorrowRate ? BulletWasm.convert_rust_decimal_to_json(minBorrowRate.toFixed()) : null,
|
|
9640
|
+
max_borrow_rate: maxBorrowRate ? BulletWasm.convert_rust_decimal_to_json(maxBorrowRate.toFixed()) : null,
|
|
9641
|
+
optimal_borrow_rate: optimalBorrowRate ? BulletWasm.convert_rust_decimal_to_json(
|
|
9642
|
+
optimalBorrowRate.toFixed()
|
|
9643
|
+
) : null,
|
|
9644
|
+
asset_weight: assetWeight ? BulletWasm.convert_rust_decimal_to_json(assetWeight.toFixed()) : null,
|
|
9645
|
+
initial_liability_weight: initialLiabilityWeight ? BulletWasm.convert_rust_decimal_to_json(
|
|
9646
|
+
initialLiabilityWeight.toFixed()
|
|
9647
|
+
) : null,
|
|
9648
|
+
maintenance_liability_weight: maintenanceLiabilityWeight ? BulletWasm.convert_rust_decimal_to_json(
|
|
9649
|
+
maintenanceLiabilityWeight.toFixed()
|
|
9650
|
+
) : null,
|
|
9651
|
+
deposit_limit: depositLimit ? BulletWasm.convert_rust_decimal_to_json(depositLimit.toFixed()) : null,
|
|
9652
|
+
borrow_limit: borrowLimit ? BulletWasm.convert_rust_decimal_to_json(borrowLimit.toFixed()) : null,
|
|
9653
|
+
liquidation_reward_ratio: liquidationRewardRatio ? BulletWasm.convert_rust_decimal_to_json(
|
|
9654
|
+
liquidationRewardRatio.toFixed()
|
|
9655
|
+
) : null,
|
|
9656
|
+
liability_liquidation_limit_ratio: liabilityLiquidationLimitRatio ? BulletWasm.convert_rust_decimal_to_json(
|
|
9657
|
+
liabilityLiquidationLimitRatio.toFixed()
|
|
9658
|
+
) : null
|
|
9603
9659
|
}
|
|
9604
9660
|
}
|
|
9605
9661
|
}
|