Questions tagged [tokens]

A token is a transferable, divisible object on the blockchain, such as a subcurrency or a prediction market share.

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

Build with Library IterableMapping

I'm trying to compile my contract, which uses the IterableMapping library. IterableMapping is being created in the file itself, but even so, apparently an error is being raised, saying that I should ...
0
votes
1answer
11 views

Setting token price on a Dex

There are various opinions and parameters when it comes to the setting of a token price. What are the best practices when setting the token price on a Dex?
0
votes
1answer
9 views

How to remove Fake token contact signed

I participated in multiple airdrops and recently checked the account on etherscan which was showing multiple Coins in my wallet... I approved one of them and got some sort of "sign" pop up ...
0
votes
1answer
15 views

Verify and Publish in BSC Scan not working

I have a contract, where I compiled it optimized in 200. When I go to publish in BSC Scan, it gives me some messages as attached. I'm informing in bsc scan the optimization in 200. It points out ...
0
votes
0answers
6 views

ERC 721 Token to Ledger “Swap Only”

Attempting to sent ERC 721 token to Ledger and am only given the option to "swap" the token not "send" Anyone else seen this issue with tokens?
0
votes
0answers
11 views

Wierd exploit in auto-liquidity token

i dont know if this is a known exploit or not, but this caught my attention. It seems that address on mainnet is a contract (unverified of course) that takes advantage of a vulnerability somewhere ...
0
votes
1answer
12 views

Metamask Chrome extension can't send deployed ERC721?

I deployed an ERC721 token on bsc testnet, added it to Metamask Chrome extension. It shows up correctly, but the button "send" is faded out. Am I missing something?
0
votes
0answers
23 views

Token contract can't retrieve the allowance

https://ethereum.org/en/developers/tutorials/transfers-and-approval-of-erc-20-tokens-from-a-solidity-smart-contract/ I was trying this tutorial in Remix IDE. But I couldn't get the sell function to ...
0
votes
0answers
9 views

How to identify transactions that create a token?

I need to identify when a transaction is creating a token, and in that case the address of the token being created. I have an example of tx and output: tx = w3.eth.get_transaction('...
0
votes
1answer
16 views

What happens to coins located in contract address(BEP-20/ERC-20 token)

Let's say that I created a token using remix, and this token has an initial supply of 1 million, and half of that is sent to the contract address. Those 500k on the contract address should become ...
0
votes
0answers
10 views

What is your opinion for decentralized social media for cryptocurrency users should be

Vitalik has talked about the potential of decentralized social media for cryptocurrency users. So, I would like to ask cryptocurrency users what is your opinion for decentralized social media for ...
0
votes
1answer
20 views

How to change the bet of ether into bep-20 token?

The link of Betting Contract:https://github.com/laronlineworld/Voting-Betting-Smart-Contract/blob/main/Voting-Betting-Smart-Contract.sol How to change the bet ether into token(BEP20) function ...
0
votes
0answers
9 views

How to use CHI gas? Any documentation on their method?

Right now the only information I can find for Chi gas is their contract code/methods and their calculation. I also found a snippet around that look like this but I have no idea where the numbers are ...
0
votes
1answer
29 views

Accepting multiple ERC20 tokens

I've been doing a little project of mine where users could donate ether to a certain campaign to reach a certain goal, but I wanted to extend this project a little further and wanted to allow the ...
0
votes
0answers
12 views

Is it possible to use ethereum smart contracts for cryptocurrency exchange

I know ether can easily be accepted by smart contracts, however, would it be possible to exchange ether sent to the contract for another cryptocurrency? Wouldn't a private key need to be stored in the ...
0
votes
1answer
71 views

How to get your smart contract to accept UNI Token?

I'm working on creating a simple contract which will receive UNI tokens from an external account and swap it for ether from UniSwap. I'm having a very hard time understanding the documents. Can anyone ...
0
votes
0answers
15 views

How to choose number of decimal places for token

What should I consider when choosing the number of decimal places for an ERC20 token/stablecoin? My first thought was to just use 18 which seems to be the standard because Ether uses 18. However ...
0
votes
1answer
11 views

Can I get ETH in redistribution wallet

I am trying to create a token on Ethereum, basic one like usual redistribution tokens that sends a percentage to my wallet on sells. I am receiving tokens in the wallet, but I want to use that wallet ...
0
votes
1answer
13 views

Is there a smart contract that rewards someone who has held a token for a certain amount of time with additional tokens?

Basically if someone holds a token for a given time "x" amount then they are rewarded extra tokens? Is there a smart contract that can do this or is it even possible? Thank you.
0
votes
0answers
13 views

tx.wait() never resolves using ethers library

I am using ethers library in my nodejs , and trying to call a function in smartcontract which looks like: const tx = await router.swapETHForExactTokens( amountOut, [bnb,...
0
votes
1answer
44 views

How can I get the token symbol from the token contract address using Node.js?

PLEASE DO NOT HELP ME BY SUGGESTING PYTHON CODE. I'M ONLY INTERESTED IN SOLUTIONS THAT RELY EXCLUSIVELY ON NODE.JS. I am trying to build out a sniping bot in Node.js using a snippet from EatTheBlocks ...
0
votes
1answer
25 views

Can I see who holds my token in solidity

I'm learning to code in solidity and have started learning through making an ERC-20 token. I want to be able to see who is holding the tokens without using a for loop. So far I've mapped each address ...
0
votes
1answer
19 views

ERC20 token conversion to ETH or USDC

How can we convert ( via smart contract coding ) any erc20 token like BAT back to ETH or USDC ? I am very new to smart contract programming and I want to write the smart contract for the conversion. ...
0
votes
0answers
14 views

How to get the balance of tokens inside my MetaMask wallet?

I am trying to get the balance of the Alpacas I have in my MetaMask wallet. Googling around I found different ways but many didn't work. So this is the most recent code I found but it is returning ...
0
votes
1answer
36 views

Failing to fill 0x quote

I'm trying to fill a quote that I get from the 0x API: const qs = createQueryString({ sellToken: 'TUSD', buyToken: 'WETH', sellAmount: BigInt(882693 * 10 ** 18) }); ..but the transaction ...
-1
votes
0answers
16 views

How to understand why my contract is not fulfilling the dividendtoken distribution

I am trying to understand why the dividends in my contract are not paying out. From what I understand, the tokens in the dividend tracker fulfill the required min amount, but dividends aren't being ...
0
votes
0answers
14 views

“Undefined” when trying to use async/await/promise

I'm currently trying to put in the function: truffle console truffle (development) > const token = await Token.deployed() And the result is coming up as undefined. I've started over my DAPP project ...
0
votes
0answers
115 views

Web3 Python token sell pancakeswap

I am trying to sell my tokens via python web3. But sometimes I get an error "execution reverted: Pancake: K". I researched this error and it has to do with the slippage but pancake swap docs ...
0
votes
1answer
17 views

Is it possible to add withdraw tokens/transfer from vesting contract?

This is the contract:https://github.com/laronlineworld/vestingcontract/blob/main/VestingContract.sol Is it possible to add withdraw/transfer token from vesting contract? And the access is for owner ...
0
votes
0answers
16 views

Calling Functions of a child contract using an owner contract

I had deployed a smart contract (contract #1) that uses another smart contract (#2) for some transaction logic. Contract #2 was imported in the first contract itself and deployed with the help of ...
0
votes
0answers
18 views

ETH Mainnet deployment: Transaction was not mined within 750 seconds

"Migrations" -- Transaction was not mined within 750 seconds, please make sure your transaction was properly sent. Be aware that it might still be mined!. Error: /root/.nvm/versions/node/v14....
0
votes
1answer
29 views

Can you reserve your token name and symbol before releasing to mainnet?

Is it possible to list our token to reserve the name and symbol before our contracts are released on mainnet?
0
votes
0answers
17 views

What's the most efficient way to batch mint NFTs?

It seems inefficient to batch mint from the client side (eg. web3). Apparently Cargo does batch minting but I couldn't find their code. My default approach would be a Solidity function that loops ...
0
votes
0answers
11 views

Error encoding arguments: Error: types/values length mismatch (count={“types”:2,“values”:5}

struct 721Data { uint tokenId; string tokenURI; LibPart.Part[] creators; LibPart.Part[] royalties; bytes[] signatures; } struct Part { address ...
1
vote
1answer
18 views

How an asset is tokenized?

Suppose I have a car and I want to tokenized it. Now I have following questions. What will be the process to make a digital token of my car. If someone buy this token, Will I have to transfer token ...
0
votes
1answer
24 views

Provide liquidity to Uniswap without initial funds on one side?

Is there a way to provide liquidity to Uniswap-like contracts without initial funds on one side of the trade? For example, if I create my own token called Token, I believe this token should be worth ...
0
votes
1answer
37 views

Is there a way to lower BEP20 smart contract function gas fee costs?

A BEP20 smart contract needs to have a function called periodically (At least once a day) to process some data. The gas fee required to do so is quite high (>0.1 BNB every call). What are some ways ...
0
votes
0answers
11 views

Function doesn't run after receiving custom token

I have an issue with my smart contract when it receives a custom token: uint256 private privatePrice = 20; uint256 public totalCollected; uint256 public previousCollected = 0; uint256 public ...
0
votes
0answers
9 views

Understanding floorcalculator and ERC31337 from rootkit finance

I'm trying to understand ERC31337 from rootkit finance and got introduced to floorCalculator code as follows: function calculateSubFloor(IERC20 wrappedToken, IERC20 backingToken) public override view ...
0
votes
0answers
11 views

Claim Airdrop doesn't add another claim reward value to existing value, the value will change but will add to existing reward

Source code link: https://github.com/BIMPFinance/ClaimAirdrop/blob/main/claimPrize.sol This contract send token to address/addresses, and the user will redeem the airdrop token of this contract ...
0
votes
0answers
15 views

Help needed-Lost Dai token sent from Matic network to nexo.io wallet [duplicate]

Any support on my issues is appreciated, suggestions or solutions out there for my issue. I have sent Dai token money to Nexo.io but from the Matic-mainnet. My funds are currently received on wallet ...
1
vote
0answers
17 views

Transferring NFT Tokens without the ownership of the tokens but approving the contract address as operator

https://github.com/ProjectOpenSea/opensea-creatures/blob/master/contracts/ERC721Tradable.sol Someone please explain me the function at line 91
2
votes
0answers
32 views

How can I stop bots from using my smart contract?

My use case involves a contract with a fixed prize pool, users interact with the contract by making a payment and receiving a reward, I made it so in the long term the reward is greater than the cost, ...
0
votes
1answer
56 views

How to deal with liquidity for a BEP-20 token?

I've released a few BEP-20 tokens so far and some of them have been quite successful at launch but then suffer from lack of perpetual marketing, my team and I are dealing with this challenge. However, ...
0
votes
0answers
23 views

Can a token on uniswap control its price within the smart contract?

Is it possible to have a token smart contract on Uniswap where the price of the token can be influenced or set by the smart contract itself, rather than the free market on uniswap? E.g. suppose the ...
0
votes
0answers
12 views

What does this parameter mean in this curve fi function?

I am trying to add 22 dai to a polygon curve pool. Here is the function I am using: If I am trying to add 22 dai into the pool, what do I put for the parameters? Thanks!
5
votes
2answers
945 views

Is burning tokens effective without buy-back?

What's the deal with this "burn on deployment"? almost every deflationary token is bragging about the number of tokens they've burned before providing liquidity and isn't this useless? For ...
0
votes
2answers
57 views

How to set token transaction limit?

If I create a token on Cointool.app, is there any way I can add a limit on the number of tokens bought in any transaction? Or does it depend on the amount that's in the liquidity? e.g. If I want to ...
1
vote
0answers
51 views

Token w/ liquidty fees - create LP pair before send tokens to pancakeswap or to burn?

If I create a token (through cointool.app) that has liquidity fees, and I want to burn some of the supply after creating it, and I need to send the rest to pancakeswap for trading - do I need to ...
0
votes
0answers
13 views

Vyper uint256 division with decimal precision

I am aware of this question here and the answer is correct however I am struggling to understand how to actually divide uint256 values with an arbitrary decimal precision Here is the function I am ...

1
2 3 4 5
38