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
1 vote
1 answer
12 views

How do I turn the "_shares" into ERC20 Tokens in this contract?

I was tinkering a bit with the following Vault contract. The contract works like that: Deposit Token X and receive minted shares. Withdraw Token X for the amount of shares you are holding and the ...
user avatar
0 votes
1 answer
15 views

Why am I getting incorrect WBTC when swapping it with DAI using Uniswap?

Hi I created a smart contract but when I am swaping 1 Million DAI with WBTC tokens I am getting only ~3379786784 WEI (~34 WBTC) but when I am checking its value on UNISWAP website it is showing 43 ...
user avatar
0 votes
2 answers
40 views

How to call a contract within smart contract?

I need solidity analog of web3 command: const contract = new web3.eth.Contract(contractJSON.abi, deployedAddress) The context is: Contract A call contract B Contract B receives an address of ...
user avatar
  • 259
0 votes
0 answers
6 views

Can someone explain the What is Granuality in ERC77 ? (in simpler terms)

I was going through openzeppeline code for ERC777.Found that it uses Granuality as 1, I don't understand difference between ERC20 Decimal and ERC777 Granuality are they different?
user avatar
  • 1
1 vote
2 answers
33 views

Facing Problem in a simple contract

I was following a course and wrote this same code from there. Here I am facing issues while buying the token. As I have set the price to 1 ether I should be able to buy with ether but the moment I try ...
user avatar
0 votes
2 answers
23 views

Token gated coontent

I'm creating an NFT website and using Wix as the development platform. I have implemented minting possibilities using ThirdWeb. Now I want to implement token-gated content that allows people to ...
user avatar
0 votes
1 answer
8 views

How to go from v3 to v2 on Uniswap?

There are tokens that offer a better exchange rate in version 2. Uniswap used to offer a friendly way to switch between versions.
user avatar
0 votes
0 answers
13 views

Storing USDC in secure inaccessible place

Im creating 2 erc20 tokens, one (A) that replaces the amount it is bought for with USDC, and another (B) that stores this USDC. So the second one is an INDEX of the USDC, and the first B is the one ...
user avatar
1 vote
2 answers
56 views

withdrawing OP token from Optimism

I think Coinbase accidentally deposited my purchased OP token onto the Optimism network (!!) I confirmed this on etherscan. I never selected the optimism network (that isn't even an option in coinbase)...
user avatar
  • 13
0 votes
1 answer
19 views

How do I check if a block contains a transaction for a token like USDC or USDT

I'm exploring Blocks & Transactions at the moment. I can see in the blocks there's transactions which show what addresses sent ETH and where to. However, I'm wondering how to tell if these are for ...
user avatar
1 vote
0 answers
33 views

Pros and cons of interest bearing elastic supply (rebase) tokens

Single asset vaults usually choose from 2 types of tokens that represent user shares. Tokens pegged 1:1 to underlying assets employing the rebase architecture. When underlying asset volume grows then ...
user avatar
0 votes
1 answer
30 views

Why should I create a fix supply/unlimited supply for my token

I am about to create my own ERC20 just to practice what I've learnt in the tutorial I watch, so here in openzeppelin doc https://docs.openzeppelin.com/contracts/4.x/wizard, I can create a contract to ...
user avatar
0 votes
1 answer
14 views

Transfer Bitcoin and other tokens through a Binance Smart Chain

How would one transfer tokens such as Bitcoin through a finance smart chain (so from Binance) to a hardware wallet like Trezor, in order to avoid higher fees? Also, which the third party could be used?...
user avatar
0 votes
1 answer
11 views

Ethereum Token Standard Naming

What are the criteria to name an ERC? I'm creating an ERC and I wonder how should I name it. I've been looking everywhere (Medium, Hash node, ETH Stack Exchange) and I haven't been able to find an ...
user avatar
0 votes
0 answers
8 views

I Want to See a Token Contract's Functions

For example, I want to see Truefeedback(TFBX) token's contract functions or maybe that contract's values. Is the code I wrote not true? What am i doing with this code actually? // SPDX-License-...
user avatar
  • 13
2 votes
2 answers
146 views

how to Get All tokens against a specific Walllet Addresse?

Is It Possible to get All tokens against a specific wallet Address , whether it is deployed on a ethereum blockchain , solna , polygone or whatever ?
user avatar
0 votes
1 answer
20 views

Does the mapping in smart contracts define the ownership of a token?

Lately became interested in Ethereum. I have some questions which I could not find an exact answer to. Maybe someone can help. Do you "own" an NFT via the mapping in the smart contract? ...
user avatar
  • 3
0 votes
0 answers
12 views

How can I obtain the market cap from a coin via bitquery? (BNB, BUSD, PanCake,...)

It's my first job (I'm working for a friend) and first time with JS, so graphql is a bit hard for me, any help would be appreciated. I need to get the market cap from some coins via graphql The code ...
user avatar
  • 1
1 vote
1 answer
24 views

How can i make fully decentralized token pegged to BUSD or USDT?

I am making an ecosystem, where i want to give rewards in my own stablecoin. How is it possible for me to make it fully decentralized, with minting and burning to maintain a fixed price to $1 when ...
user avatar
1 vote
0 answers
14 views

ERC20 Claimable Utility Tokens / InGame Currency Standard Implementation

Can anyone point me to a resource where I can see a standard implementation of a UTILITY TOKEN (claimable unlimited supply) that are used as...well... utility in game. I've checked multiple Utility ...
user avatar
0 votes
1 answer
18 views

Send token from owner account from backend (Custom ERC20 token)

I made a smart contract for token on the Polygon network. The server part is NodeJS. Now I'm trying to implement the functionality of sending tokens to the recipient's wallet from the token creator's ...
user avatar
0 votes
3 answers
45 views

What is the easiest way to get an NFT json file?

I have an NFT in my wallet. It's contract address is 0x3cd266509d127d0eac42f4474f57d0526804b44e in Polygon mainnet. My NFT ID is 1234. What is the easiest way to get the NFT json file (getTokenURI) ...
user avatar
1 vote
0 answers
9 views

AXS Tokens missing

I have a problem tracking down what happened to some AXS tokens. When looking at transfers for the address, you can see 4 deposits : https://etherscan.io/token/...
user avatar
  • 121
0 votes
0 answers
34 views

How can I check the state of an uninitialized contract variable?

I have something like this: import "./Null.sol"; //ERC20 token contract WrapperCon { Null public nullToken; } then later on I launch the token in the contract with function ...
user avatar
0 votes
1 answer
9 views

Please I need explanation on this code below can someone help me out?

Hello friends please am learning on Ethereum Development with remix and I got into a confusing code that I cannot explain. The mathematics is really confusing me. Can some explain this code to me I ...
user avatar
0 votes
0 answers
28 views

swapExactTokensForTokens fails with CALL_EXCEPTION error

I'm trying to swap from tokens to WBNB but I get CALL_EXCEPTION error. In other forums read that gas_limit was too low so I increased to what seems to be enough for transaction to happen but still the ...
user avatar
0 votes
0 answers
19 views

Handling (expensive) ERC20 deposits on exchanges

i am currently trying to find a solution how to handle ERC20 deposits in a more economical and cheaper way with the possibilites existing today. with our current setup each ERC20 deposit would ...
user avatar
0 votes
1 answer
109 views

Polygon Mumbai - transaction pending infinetly when interacting with contract

I am trying to implement a ERC721 NFT smart contract at polygon mumbai network. First of all, contract code is here: https://github.com/Lorenzobattistela/melk-smart-contract When I first deployed with ...
user avatar
0 votes
0 answers
13 views

IERC20 safeTransfer sender issue

0 I need to transfer some amount of an especific token (100) when the "father"(TTDT01) token is used.It is some kind of tax on a "child" token (ttdttoken) when the "father&...
user avatar
1 vote
0 answers
21 views

Does smartcontract make sense in a truely trustless world?

How can a common person verify the smart contract code is not a scammy code? We can never have a smart contract that is feature ready all at once or even bugless. An upgradeable smart contract is done ...
user avatar
  • 877
0 votes
1 answer
41 views

HTTPError: 401 Client Error: Unauthorized for url: https://rinkeby.infura.io/v3/$WEB3_INFURA_PROJECT_ID

I'm following this solidity tutorial from Patrick Collins and when running a script: brownie run scripts/1_deploy_token.py --network rinkeby I get this error: INFO: Could not find files for the given ...
user avatar
0 votes
0 answers
10 views

Best way to track the history of tokens

I want to create a dApp that can track the history of tokens (specifically ETH as of now) and store a status with them. It needs to be able to get the history of tokens that belong to an address. I ...
user avatar
0 votes
0 answers
23 views

how to figure out IERC20 token address from javascript

I would like to send some IERC20 tokens from metamask for contract I link an HTML button to following javascript function const placeFunds = async (side, e) => { e.preventDefault(); await ...
user avatar
  • 101
0 votes
0 answers
33 views

error: Overflow uinit uint256

I have a token with overflow function can you help me use it Now i can't use this function, please anyone can help me??? I will pay 2 BNB salary
user avatar
0 votes
1 answer
28 views

why i'm Showing this error when i fetch Market items?

function : function fetchMarketItems () public view returns(MarketItem[] memory) { uint itemCount = _tokenIds.current(); uint unsoldItemCount = _tokenIds....
user avatar
1 vote
1 answer
36 views

Is it possible? send ERC20 token from user to user, but server pays gas fee

I am a newbie in this field. Me and my team are trying to build an app that gives users an ERC20 token every time they write, and allows users to give their tokens to other users. However, whenever a ...
user avatar
0 votes
1 answer
22 views

NFT tokenID question

I've got an ERC721 contract as part of a larger react dApp. My app is connected using web3 tools to the user's wallet. I need to be able to see if the address connected has a token balance for my ...
user avatar
  • 1
0 votes
0 answers
10 views

how to extend ERC20 Token to ERC20Capped

I have been trying to Update ERC20 Token to ERC20Capped token how can I do this ? I have been using Openzepplin documentation
user avatar
  • 23
0 votes
0 answers
14 views

Can We Transfer Token to The HighestBidder Automatically in NFT- MARKETPLACE Contract?

This is bidding function : function createBidOnItem( uint256 itemId ) public payable nonReentrant { uint price = idToMarketItem[itemId].price; uint tokenId = idToMarketItem[itemId]....
user avatar
0 votes
0 answers
30 views

TypeError: contract.methods.mintToken is not a function

I am testing the creation of tokens in ethereum and here's my issue : I have this error TypeError: contract.methods.mintToken is not a function at HTMLButtonElement.mintToken (token.js:51:32) It's ...
user avatar
  • 1
0 votes
1 answer
77 views

execution reverted: "ERC20: insufficient allowance" on transfer method (not transferFrom)

I'm developing a Smart Contract that transfer tokens that are owned by the Smart Contract itself. The function to do that is pretty simple: pragma solidity 0.8.1; import "@openzeppelin/contracts/...
user avatar
  • 705
0 votes
1 answer
39 views

How to send ERC20 token to another account using web3.py, rinkeby and infura

I built an ERC20 token with smart contract. It's AZ Token. I have a problem with building transaction from the account that has the total supply to another account Here is the source code and below, i ...
user avatar
0 votes
0 answers
10 views

How does a stackable token benefit its maker?

I see some tokens are stackable, but how does a stackable token benefit its creators? I know how a PoS coin work, but token doesn't have an independent blockchain. So how token creators pay the stake ...
user avatar
3 votes
1 answer
55 views

ETH address with 35 leading zeros transacting?

I've noticed several addresses receive AND SEND tokens in Ethereum which have an uncomfortably large number of leading 0s. [1] I thought all transfers had to be signed by a private key that ...
user avatar
0 votes
1 answer
26 views

How to Air Drop rewards to NFT Holders?

How can you know which users are still holding your NFTs? What if someone Mints an NFT and then at some point they sell/transfer it to someone else? How would you go about updating the holders then ...
user avatar
0 votes
0 answers
18 views

Transfer multiple tokens with one confirmation in Smart chain

I want to send several tokens at the same time with a transaction in Smart Chain with the web3 DApps Trust Wallet
user avatar
  • 1
0 votes
1 answer
50 views

How do I write smart contracts that are LP tokens?

I'm very new to blockchain and DeFi, and I'd like to ask a questions regarding LP tokens. If I wanted to list 4 LP tokens, with farm reward proportions of: 80/60/40/20, how do I go about writing them? ...
user avatar
0 votes
0 answers
71 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

1
2 3 4 5
46