New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@injectivelabs/chain-consumer

Package Overview
Dependencies
Maintainers
8
Versions
109
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@injectivelabs/chain-consumer - npm Package Compare versions

Comparing version 0.0.75 to 0.0.76

11

CHANGELOG.md

@@ -6,2 +6,13 @@ # Change Log

## [0.0.76](https://github.com/InjectiveLabs/injective-ts/compare/@injectivelabs/chain-consumer@0.0.75...@injectivelabs/chain-consumer@0.0.76) (2021-09-08)
### Features
* creating insurance fund composer ([dfb603c](https://github.com/InjectiveLabs/injective-ts/commit/dfb603cfa05ec90ec7811a07b43b6852950c8b20))
## [0.0.75](https://github.com/InjectiveLabs/injective-ts/compare/@injectivelabs/chain-consumer@0.0.72...@injectivelabs/chain-consumer@0.0.75) (2021-08-20)

@@ -8,0 +19,0 @@

import { AccountAddress } from '@injectivelabs/ts-types';
import { OracleTypeMap } from '@injectivelabs/chain-api/injective/oracle/v1beta1/oracle_pb';
export declare class InsuranceComposer {

@@ -19,3 +20,20 @@ static underwrite({ marketId, amount, denom, injectiveAddress, }: {

};
static createInsuranceFund({ fund, deposit, injectiveAddress, }: {
fund: {
ticker: string;
quoteDenom: string;
oracleBase: string;
oracleQuote: string;
oracleType: OracleTypeMap[keyof OracleTypeMap];
expiry?: number;
};
deposit: {
amount: string;
denom: string;
};
injectiveAddress: AccountAddress;
}): {
'@type': string;
};
}
//# sourceMappingURL=InsuranceComposer.d.ts.map

@@ -31,4 +31,19 @@ "use strict";

}
static createInsuranceFund({ fund, deposit, injectiveAddress, }) {
const initialDeposit = new coin_pb_1.Coin();
initialDeposit.setAmount(deposit.amount);
initialDeposit.setDenom(deposit.denom);
const message = new tx_pb_1.MsgCreateInsuranceFund();
message.setTicker(fund.ticker);
message.setQuoteDenom(fund.quoteDenom);
message.setOracleBase(fund.oracleBase);
message.setOracleQuote(fund.oracleQuote);
message.setOracleType(fund.oracleType);
message.setSender(injectiveAddress);
message.setInitialDeposit(initialDeposit);
message.setExpiry(fund.expiry ? fund.expiry : -1);
return Object.assign(Object.assign({}, snakecase_keys_1.default(message.toObject())), { '@type': '/injective.insurance.v1beta1.MsgCreateInsuranceFund' });
}
}
exports.InsuranceComposer = InsuranceComposer;
//# sourceMappingURL=InsuranceComposer.js.map

4

package.json
{
"name": "@injectivelabs/chain-consumer",
"description": "Interacting with our Chain API made easy. Can be reused throughout Injective's projects.",
"version": "0.0.75",
"version": "0.0.76",
"license": "MIT",

@@ -42,3 +42,3 @@ "main": "dist/index.js",

},
"gitHead": "0c2f3d87cd80c7e75b5c568df7c67a7b55e83307"
"gitHead": "632f7fe8ab5a1376d02b4840664b060cfd80c027"
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc