Skip to main content
13 votes
Accepted

Is it secure to read USD / ETH rate from exchanges directly without using price oracles?

TL;DR: It is not secure to read pricing information from an exchange or other protocol. Always use a decentralized oracle. You're setting yourself up to be hacked when building smart contracts. ...
Patrick Collins's user avatar
11 votes
Accepted

How can I get USDT/USDC for Polygon Mumbai Testnet?

I've gotten some assets for polygon mumbai here: https://faucet.paradigm.xyz/ Including DAI/wETH/MATIC. Should be able to trade those for USDC/USDT. From a quick search, can trade for USDT on Mumbai ...
Kyle Baker's user avatar
6 votes
Accepted

"Dropped & Replaced" tx - what should I do?

"Dropped & Replaced" means the transaction has been replaced by a new one and the new one has been validated by the network (more info here : https://info.etherscan.com/transaction-...
clement's user avatar
  • 4,352
5 votes
Accepted

I'm getting "invalid opcode: opcode 0xfe not defined", when trying to estimate the gas fees

An invalid opcode is typically the result of either one of the following runtime operations: assert of an expression which evaluates to false array[i] where i >= array.length Dividing by zero ...
goodvibration's user avatar
4 votes

swap token for usdt, create function send 1 usdt and receive 1 token

For ERC20 the usual approach is to require the user to approve your contract. You have to do something like this from the front end. // USDT parameters const erc20Token = new web3.eth.Contract(...
Ismael's user avatar
  • 30.3k
4 votes
Accepted

How can I create a local USDT testnet?

I will try to answer as best as I can, although the question is not 100% clear to me. Eth transfer Transfer of Ether between accounts is handled natively by the blockchain. You do not need to deploy ...
Undead8's user avatar
  • 3,630
4 votes
Accepted

Approve USDT on Ethereum

The USDT contract on ethereum doesn't implement the IERC20 interface correctly. Namely, functions that are supposed to return a bool (like approve does) don't. Since you're using the standard IERC20 ...
Foxxxey's user avatar
  • 4,457
3 votes
Accepted

Is there any contract to get USD value of Ether

What you are asking for is an Oracle. Check out Tellor. It's the simplest one out there to integrate directly in your contracts.
Anshu Jalan's user avatar
3 votes
Accepted

How to do transaction USDT using web3.js

I'm happy to be able to help you as I fixed this a few days ago. const sendERC20Transaction = async (receiver, amount) => { var Tx = require('ethereumjs-tx') const Web3 = require('web3') const ...
James Huang's user avatar
3 votes

Whether usdt or usdc freeze people accounts often?

Looking at the analytics... There are 256 banned USDT addresses. There is 1 banned USDC address. (Which is probably why USDC hasn't been in the news as much.) Regardless of how often this happens, the ...
Richard Horrocks's user avatar
3 votes

How can I get USDT/USDC for Polygon Mumbai Testnet?

The only way I found so far is (that still works): Create a developers account on Circle (here) and get an API key Use their demo app to add balance to your account available here or use their ...
Augusto's user avatar
  • 31
3 votes

How Can i make (my token / eth ) paring as / usdt

You have to create a new liquidity pair on the exchange you are using. You will send your token and usdt to provide liquidity to the new pair. This is also how you will set the initial price. here is ...
GrizzlyWebDev's user avatar
3 votes

Do banks store the money when we buy stablecoins? Then how is it decentralized?

There is no difference between a stable coin and any other ERC20 token. The Value of the stablecoin is given by the funds that the company that issues the stablecoin token claim to have in bank ...
Jaime's user avatar
  • 8,390
3 votes

Why does my USDT transaction fail?

Short Answer: Because the address you are approving to spend your USDT is already approved for a nonzero amount, which is a USDT no no. Long Answer: The Etherscan link you shared shows two failed ...
Rohan Nero's user avatar
  • 1,745
2 votes

How to send PAXOS token which has not transfer method?

It does have a transfer function, you just don't see in the contract because the author has used the Upgradable Contract design-pattern, which (as implied by its name) allows him/her to upgrade the ...
goodvibration's user avatar
2 votes

Is it secure to read USD / ETH rate from exchanges directly without using price oracles?

You can use the USDC/ETH rate e.g. on Uniswap v2 pools. You can calculate the token price from reserve ratio of tokens on this pools, because reserves follow simple XY liquidity model. Range based ...
Mikko Ohtamaa's user avatar
2 votes

I am having trouble transferring my Tether USD from coin-base wallet to everywhere

You will need the cryptocurrency of the blockchain to pay the gasfee if you are on binance blockchain you will need BNB to pay the gas fee
create team's user avatar
2 votes
Accepted

Gas limit issue when transfer USDT

eventually i manage to find out this answer for myself. This phenomenon happen because contract execution trigger refund gas mechanism. Back to time when i transfer my whole USDT, upon contract ...
Atlas Chiew's user avatar
2 votes
Accepted

Make my smart contract receive usdt

Your smart contract can receive USDT without you doing anything at all. By default, any smart contract created can receive virtually any ERC20, since the ERC20 contract can send tokens to any address. ...
Meriadoc's user avatar
  • 427
2 votes

Information about Apply mining pool rewards ERC-20 Smart Contract

You were not contacted by a girl from Singapore. You were contacted by a computer program pretending to be a girl from Singapore. The scammer operating the program then took over the conversation. You ...
Jesbus's user avatar
  • 10.5k
2 votes
Accepted

chainlink price feeds

Yes, it is possible to use Chainlink Price Feeds on the BNB Chain. To find the contract addresses of USDT pairs on the Chainlink Docs page, you can visit the following link: https://docs.chain.link/...
DevCrypto's user avatar
  • 432
2 votes
Accepted

Monitor USDT Deposits in Multiple Wallets on BSC

You could monitor the real-time USDT deposit transactions using the Moralis streams API. All you need is to setup a streams with a webhook to receive the real-time data. This is an example of how the ...
JohnVersus's user avatar
2 votes
Accepted

USDT on Sepolia

Here are the two USDT token contracts I found on the sepolia testnet, USDT1 USDT2. You can check either of these. On the other hand, you can also deploy by your side for testing. To get the tokens, ...
Zartaj Afser's user avatar
  • 5,320
2 votes

Contract accept USDT transfer

You need to call approve function of the USDT token contract that you’re using in the buyCoin() function for creating an instance of ERC20, with these arguments: spender: ...
SYED ASAD KAZMI's user avatar
2 votes

Why can't I buy ETH on Rice Wallet?

Whenever you make transactions on the blockchain, you have to pay for the processing of the transactions. These fees are called "gas fees". The fees are typically paid in the blockchain's ...
Lauri Peltonen's user avatar
1 vote

Tokem ERC20 eth accept payament usdt

Work in the following order. Use the USDT contract's approve function to allow the user USDT to be sent to your contract address. Write a payment function in your contract. The user calls this ...
smarteasy's user avatar
  • 306
1 vote
Accepted

How can I find the incoming balance of a erc20 (usdt/shiba etc) using its transcation hash?

Within the context of smart contracts, token amounts are always denoted in integers. So, in your case, 196880000 tokens were transferred. What makes this concept a bit tricky is the UIs which make the ...
Lauri Peltonen's user avatar
1 vote

cannot withdraw usdt out from metamask to bybit

Since each Ethereum transaction requires computational resources to execute, each transaction requires a fee. Gas refers to the fee required to conduct a transaction on Ethereum successfully. you ...
Surbhi Audichya's user avatar
1 vote

Is it secure to read USD / ETH rate from exchanges directly without using price oracles?

Patrick gave a great answer on why an exchange based oracle is bad, but unfortunately LINK is pretty far from trustless. Depending on the size of your contract or what you're using it for, an AMM ...
thefett's user avatar
  • 3,920
1 vote
Accepted

Accidentally sent USDT to USDT contract address instead of wallet

Sorry whether on Tron or Ethereum it's the same you send your crypto to USDT contract and as no private key is attached to a smart contract it will not be possible for you to recover your funds (...
n1c01a5's user avatar
  • 294

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