Questions tagged [transfer]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0
votes
0answers
4 views

Etherscan get ERC20 transactions with multiple transfers

I want to get a list of all ERC20 transfers of an address for a specific ERC20 contract. I am using the following Etherscan query: https://api.etherscan.io/api?module=account&action=tokentx&...
0
votes
1answer
10 views

Ownership question about Ethereum ERC20 tokens

I been considering creating my own Ethereum ERC20 token and I have one main question. When you create a Ethereum ERC20 token and you launch it, do you automatically own all of that Ethereum ERC20 ...
1
vote
0answers
43 views

How to transfer an ERC1155 Matic token using Node.js?

I'm trying to write a Node script that will transfer an ERC1155 token on the Matic network from my address to someone else's address. Here's an example token: https://opensea.io/assets/matic/...
0
votes
1answer
35 views

BEP-20 Token Transfer Error

I am unable to transfer test tokens from my address (say address A) to another address B. The steps I did were deploy and verify a rebase contract, all tokens were automatically sent to my address. ...
0
votes
1answer
19 views

Cannot transfer ERC-20 tokens from a contract

pragma solidity ^0.6.2; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; contract MyContract { IERC20 LINK; constructor(address token) public { LINK = ...
0
votes
1answer
38 views

Handle different token transfer to contract

Any way to handle token transfer to contract with another token? For example: first contract - token A second contract - token B how to handle transfer token A to contract of token B and make some ...
0
votes
1answer
33 views

Using signature to send NFT

is it possible to use signatures (EIP-712) to execute transactions. For example Person A gives his signature to a Smart Contract, to transfer A's NFT. Now there is person B, which wants to buy the NFT....
0
votes
0answers
11 views

Transferring NFTs with approved Smart Contract

Im currently developing an ERC-721 DApp and I would like to give the owner of the NFT the chance to approve a Smart Contract Address, so that the Smart Contract can do the transaction. Now I have the ...
0
votes
1answer
53 views

Solidity contract - Best way to airdrop a single time a user

I've got this very simple Airdrop contract below: contract ERC20 { function transfer(address _to, uint256 _value)public returns(bool); function balanceOf(address tokenOwner)public view ...
0
votes
1answer
111 views

ERC721 approve Smart Contract and send transaction from it

I am developing an ERC721. I want the NFT to be approved and to do transactions. When I call getApproved() the address is the Smart Contracts address, but when I try to do a transaction by calling the ...
0
votes
0answers
9 views

Payment not showing up in wallet

I have the following solidity function that a wallet calls: function giveupStake(uint amount) public payable { if (initialStakes[msg.sender] >= amount) { initialStakes[msg....
1
vote
1answer
23 views

How to call .increaseAllowance() from another token

I'm deploying a contract that is the owner of a token. In that contract i want to say that the token increaseAllowance to msg.sender and the amount that msg.send have putted in arguments of the ...
0
votes
2answers
23 views

TranferOwnership Recursion

If i have a contract C that is the owner of contract B and contract B is owner of contract A. Can C in is contract call transferownership from contract A? Please help
0
votes
1answer
19 views

Transfer from contract address to sender

I am coding a crowdfunding contract where senders have two options. First, payIn which invokes a transfer to the contract's address. Second, withdraw which invokes a transfer from the contract's ...
0
votes
1answer
12 views

Transfer of ERC-20 tokens fails, even though smart contract has enough token balance

I am trying to develop a buy function for my token smart contract, but it fails on the transfer: transfer(msg.sender, amountToBuy); It fails with the Error: 'ERC20: transfer amount exceeds balance', ...
0
votes
1answer
102 views

Ethers.js transfer event filters

In my dapp I'm building I want to update the contracts' balance of an ERC20 token automatically using the transfer event from the token contract. I have created the contract object using: const ...
0
votes
0answers
316 views

Fee on transfer causing error "Uniswap invariant not satisfied"

I am working on building an ERC20 token with the help of the OpenZeppelin project. I wanted to add a burn fee on transfer, so I overrode my transfer function as follows: function transfer(address _to, ...
0
votes
1answer
119 views

Trying to understand Etherscan output for token swap via Uniswap

I am trying to understand a token swap transaction via Uniswap on Etherscan. Looking at the Uniswap V2: Router 2 contract for a transaction, I see the following; My question is regarding the second ...
0
votes
0answers
20 views

Trying to give tokens the new users on my Dapp

pragma solidity ^0.8.0; contract Coin is ERC20{ mapping(address => uint256) private _balances; mapping(address => bool) private _airdrop; uint private _totalSupply; string ...
0
votes
1answer
15 views

Need to understand the logic used in multiTransfer function,

* @notice Transfer tokens to multiple recipient * @dev Left 160 bits are the recipient address and the right 96 bits are the token amount. * @param bits array of uint * @return true/...
1
vote
1answer
70 views

Is there a way to transfer ETH to block miner coinbase address using a transaction without a smart contract?

Is there something similar to block.coinbase.call{value: _ethAmountToCoinbase}(new bytes(0)) executing using Smart Contract? For example, from EthersJS: const tx = signer.sendTransaction({ to: &...
0
votes
1answer
32 views

How to set payment amount to be passed in msg.value

I am working on truffle (solc 0.5) and trying to fetch amount in wei from user and send it to another account. Following is my code: contract pay { uint amount; function payment(uint _amount, ...
0
votes
1answer
15 views

ERC20 transfer not updating account values

I'm doing the DAPP university create a token tutorial as a way to learn solidity,etc. Things look good - except that the transfer function doesn't see to actually do anything. When the contract ...
0
votes
0answers
35 views

Interaction between my webapp and smart contract

I am experimenting for the first time with smart contracts and NFT stuff. So I am at the point where I have a react webapp with metamask integration. The user can connect his wallet. I want to ...
0
votes
0answers
36 views

Getting error: 'approve caller is not owner nor approved for all' when calling approve() from ERC721 owner wallet

I am getting this error message when trying to call approve() on an ERC721 token: "code": 3, "message": "execution reverted: ERC721: approve caller is not owner nor approved ...
0
votes
1answer
251 views

Estimating transfer gas for ERC20 tokens using ethers js without needing the token

I am trying to be able to accurately estimate the gas it will take to send an ERC20 token using Ethers js without first needing that token. Currently, I am able to get an estimate though it does not ...
0
votes
0answers
534 views

web3 how to send transaction with BNB

i'm begin working with web3.js api and i cant understand how to send transaction in BNB. According to documentation https://eth.wiki/json-rpc/API#eth_sendtransaction i cant find some parameter that ...
0
votes
0answers
23 views

No chance to transfer ETH from contract to address whatever gas I set

I looked through suggested similar tickets. Not my case. The problem is that I can't transfer ETH from contract to any address: (bool success1, ) = payable(recipients[index]).call{value: uint256(...
1
vote
1answer
43 views

Burn function without emitting Transfer to address 0

I have found some code samples for "burn function" on token contract. In this function, burn amount is substracted from the balance and then "Transfer Event" is emit to address 0. ...
0
votes
0answers
22 views

Questions concerning the modification of an existing contract. Two liquidity pools, fee that can be taken out, testing on remix, buying the token

I am learning Solidity, and I am trying to modify an existing contract. But the questions I have I can ask independently from the contract. is there a possibility to have two liquidity pools? One as ...
0
votes
0answers
11 views

Is it possible to stop a deposit, while being in process by the contract owner?

function disableDeposit() onlyowner public{ require(timeToWait + userdeposit[msg.sender].timeCreate < block.timestamp); ERC20(tokenContract).transfer(msg.sender, userdeposit[amount]); } Would I ...
0
votes
0answers
7 views

How to validate transfers?

As far as I understand, events associated with transactions are completely arbitrary pieces of data emitted by a contract, i.e. just because transaction event log says that a Transfer took place, ...
0
votes
1answer
142 views

ERC721 TransferFrom problem - How can the buyer calls Transfer from function in order to buy a ERC-721 token?

Recently I am working on a NFT marketplace and I had difficulties in implementing safeTransferFrom function. At this stage I use _transfer function to allow the buyer calling the function directly so ...
0
votes
1answer
11 views

Can we have a instance of a interface?

I came across this code, I wanted to know what exactly IERC20(token address) is signifying here whether it is the instance of token or just the reference to the contract of token to which the user is ...
0
votes
0answers
496 views

How to transfer ERC721 token to address from the smart contract?

I am working on a smart contract (OpenZeppelin ERC721), where trades can be created by only the owner of smart contract, and then regular users can buy them. When owner creates a trade, a new ERC721 ...
0
votes
1answer
29 views

Transfer ether between two addressrd using call

I have this code: function regAgent(uint[] memory _preferences) notOwner onlyBeforeEnd public { require(msg.sender.balance - fee >= 0, "You can't pay the fee."); require(!...
0
votes
0answers
26 views

How to send a fixed amount of ether to a smart contract from an account?

Is it possible to send a fixed amount of ether to smart contract from an account every time a function is executed or button is clicked? No input fields should be used.
0
votes
1answer
494 views

ERC-20 Token Transfer Error (Unable to locate corresponding Transfer Event Logs), Check with Sender

Token was created under ERC223. Every transfer that I have done received: ERC-20 Token Transfer Error (Unable to locate corresponding Transfer Event Logs), Check with Sender. Please help to check and ...
0
votes
0answers
9 views

options to retrieve 24h transfer data between main DeFi protocols

I am trying to build a daily graph showing the transfers between the main DeFi protocols as well as some of their properties (for example, collateralization). What are your recommendations for places ...
0
votes
1answer
77 views

How can I use the payable function to transfer fixed ether in a transaction?

contract MyContract { address payable[] recipients; function sendEther(address payable recipient) external payable { recipient.transfer(1 ether); } } Error- transact to ...
0
votes
0answers
10 views

Transfer ether between two EOAs without security breaches

I have this function (is a SC implementing and auction): /// @notice Register a new participant /// @param _preferences agent' preferences function regAgent(uint[] memory _preferences) notOwner ...
0
votes
0answers
18 views

How do get every token transfer for a token?

I initially thought this would be trivial, just using the tokens transfer event but this misses transactions done by disperse, multisend and I am sure there could be a few more methods I don't know ...
0
votes
0answers
22 views

Multisender.app transactions aren't emitting transfer events for Ampleforth

I am trying to collate the whole of Ampleforth's transaction history. To do this I was grabbing the transfer events every 1000 blocks since Ampleforth's inception. In doing this I noticed that some ...
0
votes
1answer
108 views

Pancake/Uniswap: tell inside contract if a transfer is a buy or sell

I have a token contract that will exclusively use Pancakeswap as trading platform. How can I tell in the contract if a transfer represents someone buying the token or someone selling it?
0
votes
0answers
24 views

Truffle test - doesn't send funds to msg.sender

it seems like I have a wrong gnache or truffle setup ... I already ask a simular question here: Owner of contract is set to contract address? Basicly there is some mess up with addresses on my local ...
1
vote
0answers
124 views

Transferring ERC20 token to a contract using custom function

I have a couple of questions related to transferring ERC20 token to a contract. I am developing a protocol that has its own token to provide incentive mechanisms. For certain operations I need to lock ...
0
votes
1answer
162 views

How to send erc20 tokens through web3 on nodejs

My transactions go through without errors, while they're pending the data field shows the amount of tokens I'm sending, but when the transaction goes through the data field is empty. Here is my code: ...
0
votes
0answers
99 views

ETH token transfer Fail and error is: Warning! Error encountered during contract execution [Bad instruction]

sometimes I am encountering a problem where I am trying to send tokens (USDT in this particular case) to other address and the transaction fails, because of "Warning! Error encountered during ...
4
votes
0answers
654 views

What is the difference between ERC-2665 and what is proposed in EIP-2981? Royalties vs Transfer Fee

There is an EIP for Royalty standards. But there is already a ERC for a Transfer Fee Could ERC-2665 be used to implement royalties across all market places for NFT? What is the difference between ...
0
votes
0answers
13 views

Need help identifying where coin transfer is and how to get it back [duplicate]

I Transferred some ENJ coins from my DeFI wallet to what I thought was my Trading account wallet. Long story short the address it I was sent too was off by one number. About 3/4 of the way into the ...