210 похожих чатов

I was wondering if there was a way to collect

the total supply of several erc20 token on several blockchain.
I would like to know the total supply of an erc20 token on a first blockchain and sum with another erc20 token in another blockchain.
Is that possible with Chainlink?

1 ответов

4 просмотра

You just need to know the address of the ERC20 token and execute function totalSupply(). If you want to have that in a simple contract, you could have something like this: pragma solidity ^0.8.1; import "https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/token/ERC20/IERC20.sol"; contract Test { IERC20 public token; function getTotalSupply(address addr) public view returns(uint256) { return IERC20(addr).totalSupply(); } } And You want to learn how to use VRF in your project , - https://blog.chain.link/verifiable-random-function-vrf/ If you have any questions, dm me🙏🏻☺️

Похожие вопросы

Обсуждают сегодня

Anyone knows where there are some instructions or discort about failed bridge transactions ?
Jochem
21
Also, why can’t the community have a vote/ say when it comes to initiatives like buybacks. Isn’t the point of crypto decentralisation? Don’t we deserve input as long term supp...
👨🏽‍🦰
13
any reference of this implementation?
BitBuddha
29
Hi guys, any problem with Pulsebrige? Trying to transfer from wETH to ETH. First it tells me to connect my metamask "through mobile app" not desktop. Then I did and confirmed ...
Snowflakecrypto
13
Ready for some fun AND a chance to win TKO Tokens? Join us for exciting minigames in our Telegram group! 🕒 Don’t miss out—games start on today 25 October 2024, at 8 PM! Ge...
Milkyway | Tokocrypto
255
Ⓐrtto, [4/23/24 7:02 PM] Please explain more fully how it is not working exactly, and what are the steps you are taking, and what error messages come or what happens. Ⓐrtto, ...
Ezza Kezza
2
Btw looks like Kushti is at it with 6.0, has he shared any plans to stop developing Ergo or just to keep going indefinitely?
Original Ergonaut Manley
16
sounds like people have lost their kaspa on tradeogre... does this mean tradeogre not trustworthy?
Ezza Kezza
15
So much speculation in the last week. So much volatility in price. This is because Hedera has a GC that isn't using the network it's governing. Why aren't people asking why a...
Summit Seeker R
9
Question: How viable is it to use Anvil as the backend infrastructure for managing a TradFi portfolio, while integrating Flexa for instant liquidity and payment solutions? Cou...
Kevin
2
Карта сайта