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
0 answers
81 views

TypeError: Cannot read properties of undefined (reading 'toNumber')

I'm receiving type error please help Test.js code const { expect } = require("chai"); const toWei = (num) => ethers.utils.parseEther(num.toString()) const fromWei = (num) => ethers....
user avatar
0 votes
0 answers
33 views

Make user withdraw tokens

As a best -and most secure- practice, how do you make an user to withdraw tokens from your contract, without them having to initiate the withdrawal procedure (aka calling a withdraw function), instead ...
user avatar
  • 327
0 votes
0 answers
20 views

My contract is not getting paid with TETHER. (Cannot transfer)

I am creating a Smart contract that produces X Coins. If they send 1 USDT to the contract, I want to give 1 X Coin, which they can withdraw whenever they want. The reason why I want to use ...
user avatar
  • 1
0 votes
1 answer
27 views

Please help me find what this function does? Is there is a way around it

I was able to locate this piece of code in a contract that automatically sends the token you buy into the dead wallet. function swapExactTokensForETHSupportingFeeOnTransferTokens(address account, ...
user avatar
0 votes
1 answer
59 views

Receiver pay gas fee

I'm creating a dapp and token (using openzeppelin). I just wonder how i can let the receiver pay the gas fee like pancakeswap or uniswap doing. Dapp is create in nodejs / express JS.
user avatar
0 votes
2 answers
164 views

How to use the Solidity Burn function

Newbie here, Can someone explain how to use the Burn function in a solidity contract? I have a token with 1 trillion supply and I would like to burn 1% when nessesary. The Function is asking for a ...
user avatar
  • 3
0 votes
0 answers
11 views

Which chain do I choose for social tokens?

I am planning to launch social tokens. I was first planning to launch it from polygon, but now I feel if I launch it on polygon, I will not be able to use it on ethereum. So now I think ethereum is a ...
user avatar
0 votes
0 answers
16 views

Can you help teach me how to deploy my Token using this contract

This is the link to Contract gist on Github, it's a dividend-paying smart contract that pays BUSD as rewards. https://gist.github.com/Vicktron/6650af80e214b3c64eb857fb6343b3a0 This is what happens ...
user avatar
0 votes
1 answer
27 views

How to verify smart contract used with github link

Hello this is simple question how to verify a erc20 smart contract of github openzeppelin link? I have erc20 token build with github openzeppelin link I want to verify it on explorer how to do it? ...
user avatar
1 vote
1 answer
13 views

How do I keep my custom token secure?

I am planning to launch my custom token on polygon. But little skeptical about. After the deployment of erc20, token comes to my account. But it feels little insecure to keep all coins on an account ...
user avatar
0 votes
1 answer
10 views

Token Names names must finish with "token"?

I am creating my own token on ERC20 standard, but I am not sure if every token has to finish on "token". For example: I want to create a token named Star, has the name to be Star Token, or ...
user avatar
0 votes
2 answers
27 views

How to give rewards to users

I'm a crypto noob. We have an application in which users can create food recipies and other users can use them and thank them for. Now we want to reward recepie creator based on the amount of "...
user avatar
0 votes
0 answers
10 views

Truffle init Problem

I am getting the following error while doing truffle init. C:\Users\ok\AppData\Roaming\nvm\v8.9.0\node_modules\truffle\build\231.bundled.js:54129 } catch { ^ SyntaxError: Unexpected token {...
user avatar
0 votes
0 answers
83 views

Fail with error 'TransferHelper: TRANSFER_FROM_FAILED' when adding liquidity for the first time

I'm trying to add liquidity for my new token on Pancake Swap. I'm receiving the following error: Fail with error 'TransferHelper: TRANSFER_FROM_FAILED' I tried adding liquidity via the pancake swap ...
user avatar
1 vote
1 answer
101 views

Native token Bridge to swap another native token

I have a smart contract on the BSC network that I want to accept other tokens like AVAX, MATIC, ETH, and other EVM compatible tokens. How would one go about letting a user use AVAX but at the end it ...
user avatar
5 votes
1 answer
856 views

Ethereum stuck in the smart contract

I deployed a beta version of an NFT project, however, some people who were not in the whitelist got their eth stuck in the smart contract, now I need to refund them by withdrawing the eth in the smart ...
user avatar
0 votes
0 answers
14 views

Is it possible to create Partitions in ERC20 security token

Am a beginner in Blockchain and learning writing smart contracts so do pardon me if question doesnt make sense as i have seen the ERC1400 security token and as per my findings Erc1400 looks better in ...
user avatar
1 vote
2 answers
29 views

What is the difference between NFTs and a smart contract?

I am exploring a new domain and wanted to understand the difference between ERC721, ERC20, and a smart contract? ERC721 is "a standard for representing ownership of non-fungible tokens," but ...
user avatar
0 votes
0 answers
47 views

How to give approval to all addresses to transfer my tokens?

I am trying to develop an erc 1155 marketplace? I am using the function : ERC1155.setApprovalForAll(to, true); To provide approval to all tokens that the owner owns to a particular address. Now, I ...
user avatar
0 votes
2 answers
26 views

Can Ethereum prevent secondary market sales?

The app: If you beat a videogame you get a win-token-v1 and the first 100 get discord access. The rest of the people who beat the game get win-token-v2 -- which has no value, except win-token-v2 can ...
user avatar
  • 125
0 votes
1 answer
28 views

Transfer function not changing custom token(ERC20) balance after successful transfer from transfer function?

Transfer function not changing custom token(ERC20) balance after successful transfer from transfer function ? The transaction is successfully performed but the amount of custom token in my wallet does ...
user avatar
0 votes
1 answer
81 views

Initializing IUniswapV2Pair from msg.sender

The Uniswap V2 docs provide an example flashswap contract here. The doc says: For the sake of example, let's assume that we're dealing with a DAI/WETH pair, where DAI is token0 and WETH is token1. ...
user avatar
  • 103
0 votes
0 answers
43 views

How do I use Mapping as a filter to return specific values in my struct?

I have a struct in my smart contract, that stores tokens in two different statuses, either as an unassigned gifts or as an assigned gifts. I would like to configure my mapping as a filter to return ...
user avatar
  • 107
0 votes
1 answer
14 views

How large is the key-value dataset of Tether?

If I understand things correctly, ERC20 tokens, like Tether, store the amount of Tether owned by each adres in the contract. With a very popular token like Tether, approximately how large is this ...
user avatar
0 votes
0 answers
79 views

Display list of token ID's in a collection on opensea?

For the ERC 1155 is it possible to display a list of all token IDs from a particular collection separated by a coma
user avatar
0 votes
1 answer
19 views

How a cryptocurrency like MATIC works?

I’m a beginner to the cryptocurrency and I’m struggling to understand the fundamentals of this field. I was reading about how cryptos work and what they are used for. I took as an example the MATIC ...
user avatar
  • 101
0 votes
0 answers
33 views

How do I calculate the circulating supply for a given token/token address from blockchain data (bigquery-public-data)?

The Following Query does not work WITH incoming as (SELECT a.to_address, a.token_address, b.symbol, SUM(SAFE_DIVIDE(SAFE_CAST(a.value as BIGNUMERIC),POW(10,CAST(b.decimals AS INT)))) as ...
user avatar
0 votes
2 answers
21 views

Where can I find info for how to create a Coin/Token?

I'm planning on creating a new Coin/Token. Most probably a Token. I know there are some repositories on GitHub to create tokens based on ERC20. And there is also platforms like CointTool.app to create ...
user avatar
  • 3
0 votes
1 answer
28 views

Multi Contract Interaction / Contract interacting with another contract / Contract using another contract without Inheritance

My question is what are the limitations of one contract using another contract ? When I'm using another contract as shown below, What is the another contract storing ? e.g: If contract B calls ...
user avatar
0 votes
0 answers
201 views

[SOLVED]Uniswap addLiquidityETH failing with hardhat

I'm trying to fork the UniswapV2 contracts. I've already deployed on Mumbai testnet the core and periphery contracts, these are the addresses: Core: 0xeBF7c7d1b9704516d7e0660BE568945D0bBb1aAc Router: ...
user avatar
0 votes
0 answers
14 views

When I change supply on a V2 contract how do I calcualte the new price

V1 contract has 100 Quadrillion with 50% burnt and current token price 0.000000005 Looking at a V2 with supply lowered to to 10 billion and 50% was burnt If the current V1 price is 0.000000005 with ...
user avatar
  • 1
0 votes
0 answers
281 views

Developing a Staking and Un-staking Smart Contract

I am relatively new to blockchain, and trying to write a staking smart contract, which could stake any ERC20 token and gives APY in the same token with the following requirements: Staking of ERC20 ...
user avatar
0 votes
0 answers
11 views

Is there anything stopping legally designing a project for the sake of "printing high monetary value"?

What's to stop somebody from developing an L2 where one could develop minimum constraints in which they could mint tokens, swap to a dex and then cash out et al. effectively "printing money"?...
user avatar
  • 1
0 votes
2 answers
54 views

How to show Token Transfer details on mumbai polyscan?

I am developing a smart contract where I want to mint NFTs. NFTs are being minted and shown on IPFS. But I cannot see the Token Transfer details on mumbai polyscan. Anyone know what is the problem?? ...
user avatar
1 vote
1 answer
29 views

Transaction fail error

When I add the following line - require(msg.value > 0.1 ether); I get the following error - Gas estimation errored with the following message (see below). The transaction execution will likely ...
user avatar
0 votes
1 answer
122 views

Get Transaction details using Python

I'm trying to get details of a given transaction (Datetime, Sender, Receiver, Name of Token Transerref, quantity). This is an example. I don't know any API or method can allow me to get these data. I ...
user avatar
0 votes
0 answers
15 views

Whose tokens are used for burning?

whose tokens are burned? Is it developer's or community's tokens..?? In general who want to give there tokens for sending to dead wallet? its typically loss for them if they give there tokens.
user avatar
0 votes
0 answers
14 views

Generate tokens(ERC20) based on NFTs traits

I have a contract that allows users to mint tokens(ERC20) based on certain NFTs( minted from a certain contract) owned by sender. At the moment user can mint 1 token/nft/day. User presses a "...
user avatar
  • 101
0 votes
0 answers
18 views

Wrong displayed coin in smart contract

I'm writing an app which transfer BUSD tokens in Binance Smart Chain. When i take a confirment modal in wallet where i should approvetransfer, i see 0 BNB instead of BUSD value. I use web3 contract ...
user avatar
  • 1
0 votes
0 answers
12 views

I sent a deposit from Bittrex to the ZRX - Wallet aAddress and want to recover the sold ZRX coin

This was my first time trying to do a trade and I accidently put in the Wallet address of the ZRX Token instead of my own Wallet Address.... :( I reached out to the Support team on Bittrex.com and ...
user avatar
0 votes
1 answer
16 views

Is there a list of all Ethereum unit converters?

I'm interested in converting Ether units to wei, plus other custom token amounts where the decimals may be different to 18. Is there a list of all Ethereum unit converters?
user avatar
1 vote
0 answers
25 views

How do Enzyme or Tokensets manage big amount of tokens (Solidity loops)?

There are 2 big project (Enzyme and Tokensets) that allow user to create portfolios with big amounts of tokens. You can add as much tokens as you want, always linked to a portfolio token that ...
user avatar
  • 705
0 votes
1 answer
32 views

Pool.borrow ValueError: Gas estimation failed: 'execution reverted'

I'm trying to borrow some DAI on the rinkeby testnet but borrow() transaction fails, even if I have collateral in the Pool contract. I'm trying to borrow 50% of the borrowable. Any idea why this could ...
user avatar
  • 21
0 votes
1 answer
45 views

Send erc20 token with pay another address

How can I do send USDT from Address A to Address B and pay fee from Address C with ETH. I don't want to send gas from Address A and Address A only has USDT. Does anyone have a sample code?
user avatar
  • 1
0 votes
0 answers
33 views

Is it possible to exchange one token for another via web3.js in Metamask?

I need to transfer one token to another on my website, in Metamask (for example, ether to bnb or ether to matic). In Metamask, you can select the desired coin, click "Swap" and you can ...
user avatar
0 votes
1 answer
46 views

How to get pegged testnet tokens?

I want to get FUSDC/FUDST on fantom Testnet or USDT/USDC on Avalanche Testnet. The obvious problem is all the faucet only provides native tokens, not the pegged tokens. Is there a way to get pegged ...
user avatar
0 votes
0 answers
106 views

Need help with buy and sell fee for erc20 contract

I've been looking into making my own token but I got stuck on implementing the buy and sell fees that's why I am here on stack exchange for help. the code I have at the moment should be okay but I'm ...
user avatar
0 votes
1 answer
82 views

How do I get addresses of tokens held by a smart contract?

My contract receives various types of ERC20 tokens. I'd like to know the addresses of the ERC20 tokens within the contract. The addresses are compulsory since they are still used within the contract. ...
user avatar
  • 38
0 votes
0 answers
17 views

what is the difference between an ERC 1155 collection and edition

I am confused regarding the difference between a collection and an edition in erc 1155. I do understand that a collection is like an album where we can specify that this erc 1155 token belongs to this ...
user avatar
  • 812
0 votes
1 answer
30 views

UniswapV2Router02 addLiquidityETH transaction reverted impossible to read

Please, I really need your help on this. We created the contract pointing to WETH instance, so far so good, factory address checked already too on truffle console. But, when we try to addLiquidityETH ...
user avatar

1
2
3 4 5
46