hashgraph / hashgraph/hedera-forking
Implement the `cryptoTransfer` method defined in the `IHederaTokenService`
- Dominant language
- Solidity
- Stars
- 3
- Forks
- 4
- PR merge metrics
- No merged PRs in 30d
Description
The `cryptoTransfer` method from the IHederaTokenService interface is a functionality that enables transfers of both HBAR (Hedera’s native cryptocurrency) and tokens (fungible or non-fungible) within the Hedera network.
It requires logic that is not yet present in the IERC721 and IERC20 interfaces, as it processes balance changes for fungible tokens in a different manner. Instead of handling individual transfers with sender, recipient, and amount details, it accounts for the net changes in balances (positive and/or negative) across all accounts. This approach requires ensuring that the overall balances reconcile to zero.
Additionally, it incorporates HBAR transfer functionality.
Interface to implement:
```
function cryptoTransfer(
TransferList memory transferList,
TokenTransferList[] memory tokenTransfers
) payable htsCall external returns (int64 responseCode)
```
Contributor guide
Assessment
This issue has not been assessed yet.