bcnmy / hyphen-sdk

Repository containing Hyphen SDK code that helps you integrate Hyphen cross-chain asset transfer protocol in your Dapp. Hyphen SDK provides you simple to use methods that connects directly with Hyphen liquidity pools on supported chains and hyphen nodes to fetch information related to cross chain transfer transactions.
MIT License
5 stars 4 forks source link

Hp 141 #25

Closed divyaN73 closed 2 years ago

divyaN73 commented 2 years ago

Description

Type of change

Steps to reproduce

Using New Sample Function

Signature: async DepositManager.getGasTokenDistribution(request: GasTokenDistributionRequest) => Promise<GetTransferFeeResponse>

Sample Request:

  const request: GasTokenDistributionRequest = {
      fromChainId: 5,
      fromChainTokenAddress: "0x64ef393b6846114bad71e2cb2ccc3e10736b5716",
      amount: "100000"
  };

  const response = await depositManager.getGasTokenDistribution(request);

Sample Response:

{
   code: 200,
   message: mockedSuccessMessage,
   responseCode: 200,
   gasTokenPercentage: 2.423995995995996
}

Automated Tests Added/Updated

Coverage

Checklist: