Skip to main content
5 votes

How to get Token balances

To get all the ERC20 Tokens Balance, you can use Moralis API const Moralis = require("moralis").default; const { EvmChain } = require("@moralisweb3/common-evm-utils"); const ...
Iulian Novenschi's user avatar
3 votes

DEX Real-Time Data

You can use smart contract logs of emitted events to retrieve a stream of real-time logs emitted by the Uniswap smart contract. You have two options: Use the eth_newFilter method combined with ...
Dave Dev Advocate Chainstack's user avatar
3 votes
Accepted

Passing bytes32 to constructor

This is intended behavior, the value is padded right ( = zeroes are added to the left of your number to fill the entire 32 bytes). I don't think you actually want to "fix" this, but if you ...
Foxxxey's user avatar
  • 4,337
2 votes
Accepted

get back the parameter in fulfill function

You can store the _id into some state variable like: uint256 id; function requestVolumeData(uint256 _id) public returns (bytes32 requestId) { Collab memory collab; // You can set the values ...
SYED ASAD KAZMI's user avatar
2 votes
Accepted

Getting NFTs of an address in a specific collection

(1) Get all the NFTs of an address owned within a specific network by ( You have to do the network configuration earlier ): await alchemy.nft.getNftsForOwner(address) (2) Then store the response ( It'...
Sina Rahimi's user avatar
2 votes

Get signer for Blockchain API without private Key

Unless you are on a local network like ganache, hardhat node or foundry's anvil, you will need to have a private key in order to sign transactions from an account. One alternative is to have the user ...
Travis Jacobs's user avatar
2 votes
Accepted

Is private key sent out at any ocassion in a request to any RPC?

A private key is only used to sign some RPC calls or transactions locally? Only locally. Why can't a third-party RPC service take any of my transactions and re-send it on my behalf any time it may ...
Mikko Ohtamaa's user avatar
2 votes
Accepted

How to get block and receipts data?

This data can be fetched from the chain using just one single RPC, using the Single Flight RPC Add-on of QuickNode Marketplace. First, enable the Single Flight RPC Add-on on your QuickNode Ethereum ...
Sahil - QuickNode's user avatar
2 votes
Accepted

How do you return the market cap of an ERC20 token?

Market cap = price of currency * circulating supply So, as an example, the market capitalization at the time of writing of Tezos is 1,550,977,120 euros: €2.19 (unit price of an XTZ token) * 708,208,...
forexmp45's user avatar
2 votes
Accepted

How to collect Contract Addresses via blockchain API?

Dev Advocate at Chainstack here. There are a couple of options depending on your goal. Efficient way If you want to efficiently build a local database of all contract addresses, a third-party API like ...
Dave Dev Advocate Chainstack's user avatar
1 vote

Safe Transaction API balance - returns 0 for fiatConversion for all tokens

Thanks for your question. We were returning an estimate USD price for the tokens in our transactions service, until last week. With the big amount of tokens it's very difficult for us to maintain that ...
Louis - Safe Core Team's user avatar
1 vote
Accepted

Building Cryptocurrency Tracking system for monitoring stolen cryptocurrency transactions

You can track the wallets in real time using the Streams API provided by moralis. Morlais streams can track any wallet, contract transactions, and contract events send you alerts in real-time and can ...
JohnVersus's user avatar
1 vote

How to get Token balances

Disclosure: I work at Chainbase You can use this api to get all the token balance you want. curl --request GET \ --url 'https://api.chainbase.online/v1/account/tokens?chain_id=1&address=...
masterdai's user avatar
1 vote
Accepted

How to get Token balances

Disclaimer: I work with QuickNode You can get all the ERC20 tokens in a wallet address by using just one custom QuickNode RPC qn_getWalletTokenBalance To use this, enable the Token and NFT API bundle ...
Sahil - QuickNode's user avatar
1 vote
Accepted

Ethereum RPC API

Though latency usually depends on a lot of factors but from a perspective of an RPC provider, latency always depends on the following factors: Distance between your machine and node Node ...
Sahil - QuickNode's user avatar
1 vote

DEX Real-Time Data

So I figured that the best way to get real-time data from uniswap v2 is to use WebSocket and subscribe to uniswap contract and read new data everytime new block is mined this is free and fast way of ...
Said's user avatar
  • 31
1 vote

Etherscan API get Tokens Transferred Information

You should try to get the past events (or listen them in real time) that are triggered from that specific contract in the operation you are willing to monitor. You have an explanation and working ...
Alexander Herranz's user avatar
1 vote

Is there an api that compiles solidity contracts?

Unfortunately, there is no public API that directly allows you to send uncompiled Solidity code and receive the compiled bytecode. However, you could consider setting up your own server to compile the ...
AmariS1's user avatar
  • 77
1 vote
Accepted

Can you setup a Chainlink function where the end user pays the LINK gas fee?

Chainlink Functions rely on subscriptions that are controlled by an EOA (the admin). This subscriptions holds the LINK. But any wallet can add funds to a subscription even if they dont own it as ...
ZeusLawyer's user avatar
1 vote

What's the best way to open a wallet on behalf of the user?

There are multiple 3rd party APIs to create custodial wallets for user but I would personally recommend you to use web3.js to create wallets for the user yourself and save extra charges you are going ...
Talha Sajid Chaudhary's user avatar
1 vote

Binance smart chain node API provider without billing per websocket response

You can leverage dedicated nodes on Chainstack with unlimited calls included
Eugene Aseev's user avatar
1 vote
Accepted

How can I get a list of all blocks proposed by a validator?

You can get this with the website https://beaconcha.in/ For instance you can get the list of blocks proposed by the validator 255334 with the link https://beaconcha.in/validator/255334#blocks.
upavloff's user avatar
  • 1,120
1 vote
Accepted

Does Moralis "Get NFTs by Wallet" API support ERC-1155?

Yes, it does support ERC1155 NFT, so all ERC1155 and ERC721, including non-standard NFT (e.g. Cryptopunk) will be fetched and indexed with this API. Hope this helps~
Yoseph Kurnia Soenggoro's user avatar
1 vote
Accepted

I need an API that gets "input data"field from the blockchain

You can use Binance's api for this purpose. Go there: https://docs.bnbchain.org/docs/beaconchain/develop/api-reference/node-rpc/ Scroll to 6. APIs and then look at 6.1 query APIs.
Akall's user avatar
  • 463
1 vote

Getting NFTs of an address in a specific collection

I am not familiar with Alchemy's API, but you could definitely do this by building a subgraph for this, to index the data specific to your needs. And then query the data from a frontend like you would ...
Priyank Gupta's user avatar
1 vote
Accepted

Can you fetch the whole transaction history of specific contracts somewhere?

If you like to fetch specific contracts (or to an extent general account) address history, then you can use service such as Moralis. They have Transaction API that can help you index transaction data ...
Yoseph Kurnia Soenggoro's user avatar
1 vote

Can you fetch the whole transaction history of specific contracts somewhere?

Yes, there are several services that allow you to query all transactions related to a specific smart contract. Etherscan, for example, provides a "View Contract" feature that allows you to ...
vgonearth's user avatar
  • 139
1 vote
Accepted

Retrive data from chainlink node

So let's say we have Contract CallingAPIConsumer and Contract APIConsumer. You could have a function in CallingAPIConsumer that APIConsumer calls when fullfill() is executed, let's call it ...
shankar's user avatar
  • 109
1 vote
Accepted

Getting the latest outgoing transaction of an Ethereum address

usually I don't use RPC node services like Infura as it is a bit cumbersome now that there are several API services out there that makes it easy to index these data with a few lines of code. One ...
Yoseph Kurnia Soenggoro's user avatar
1 vote

Etherscan returns values of 0 instead correct amount! (same thing for bscscan)

The contract address you have supplied in the api call 0xfb1b36bef010d6b073d35d40cf3069ad0d1d153a is not a contract address rather it is a wallet address. The correct contract address for DEXT token ...
Safi's user avatar
  • 883

Only top scored, non community-wiki answers of a minimum length are eligible