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
3answers
24 views

Can an NFT (e.g. ERC721) simultaneously belong to two different entities, say an user Owner, as well as a user Custodian?

For example, on the blockchain say you own a ERC721 Car token at your wallet address, but you want to park it in the ERC998ERC721 top down composable Garage owned by your friend, while still retaining ...
1
vote
1answer
21 views

Deploy a token which you can only send in multiples of x

Im a beginner in solidity. Is there a way to deploy an ERC20 token that can only be sent in multiples of X or else the tx fails?
1
vote
2answers
37 views

Is it possible to circumvent a require statement if the ordering of the requirements are incorrect?

Please take the following hypothetical code as an example mapping (address => uint256) public accountBalance; function deposit(uint256 amount) public { accountBalance[msg.sender] = ...
0
votes
2answers
23 views

What triggers a transaction to be recorded on the Blockchain?

I am new to blockchain development. I am trying to understand where, when, and how a transaction is sent to the blockchain to be recorded. Here is the sample code I am studying: pragma solidity ^0.4....
0
votes
1answer
18 views

Automate token distribution?

How can I execute a function on a smart contract from a web-app backend? (Laravel / PHP) My smart contracts holds X tokens. In my MySQL database, users are owed X tokens. I have their wallet ...
0
votes
2answers
30 views

How to find the coin/token type of crypto payer in Ethereum blockchain?

I'm new in Ethereum based crypto concepts. I would like to know how can I differ the incomming crypto amounts based on their orginal token type? Imagine I have an address on Ethereum blockchain. ...
0
votes
1answer
35 views

Wrong Vesting Smart Contract

For my project I created vesting contract. The contract codes and vesting contract codes are same with MATIC token contracts but in my vesting contract there is wrong. https://etherscan.io/address/...
0
votes
0answers
19 views

Do Ethereum tokens have symbol name?

I am not familiar with Ethereum contract development. I wonder if Ethereum tokens ( like ERC20, ERC1155 or ERC721) have symbol name or not. On EOSIO the asset is a structure composed of amount and ...
1
vote
1answer
45 views

How will the existing Smart Contract handle ETH Fork Upgrades (E.g., ETH's Istanbul Upgrade) or Outages

I have created my token and deployed on ethereum network before ETH Fork Upgrades (E.g., ETH's Istanbul Upgrade), What will be the huge impact of Fork update on my smart contracts and how can i manage ...
0
votes
1answer
22 views

all erc 721 tokens being collectibles

Considering all NFTs are unique, are all erc 721 tokens collectibles? I'm asking this because on the Etherscan website some NFTs have the collectibles tag and some do not.
0
votes
0answers
13 views

How to filter erc20 events with particular address

Hi i want to filter events with address below is my code how can i get filtered data array. contract.getPastEvents("Transfer", { filter: {to: account1}, ...
0
votes
1answer
18 views

How to store token number with their holders?

I am actually looking towards cost reasonable design idea where I can know that which token number belongs to which wallet address. let's say addressA bought first five tokens, so token no 1,2,3,4,5 ...
2
votes
0answers
20 views

Address to create a contract

This query is for informational purposes, with something that has had me in doubt all night. I am trying to send a self-signed transaction for the creation of a contract My Tx transaction to send is ...
0
votes
0answers
14 views

Is function like that prone to reentrancy?

function transfer() payable public returns(bool) { balances[msg.sender] = SafeMath.sub(balances[msg.sender], msg.value); if(msg.sender.call.gas(100000).value(msg.value)()) { ...
0
votes
0answers
7 views

Where can I get list of tokens that allow direct conversion to ether and not just from token to token?

Most tokens simply utilize the ERC20 functions transferfrom/transferto which just use some balances to add from one user to another - but what are the ones who allow you to: buy token cashout to ...
0
votes
1answer
33 views

I am using already deployed tokens in my contract

My question is if I'm not implementing ERC-20 methods in my contract, but I'm using already deployed ERC-20 contract methods in my contract, so can we say this will be ERC-20 compliant contract? ...
0
votes
1answer
31 views

Unable to invoke smart contract function from Web3j contract wrapper

I've been learning about interacting with smart contracts through Android and the Web3j framework but have run into an issue. I'm trying to mint an ERC721 token and send it to an address but it doesn'...
0
votes
0answers
34 views

Api to get total transfer count of an ERC-721 Token

I want to retrieve the total number of an erc 721 token's transfers/ transactions. I couldn't scrape the transfers value from etherscan as well e.g. given here https://etherscan.io/token/...
1
vote
1answer
47 views

msg.sender problem for calling ERC20 token contract from another contract returns contract address

when i am going to call approve function of erc20 contract.log prints tokenOwner and tokenSpender address same which is contract address msg.sender returns contract address. but i want tokenWner = ...
2
votes
1answer
24 views

Confusion regarding total number of ERC-721 Tokens

I have two questions: 1) I want to retrieve the list of all ERC-721 tokens. The main block explorer for Ethereum which is Etherscan shows 2,883 ERC-721 tokens on its website https://etherscan.io/...
0
votes
0answers
14 views

Assertion error running truffle test

I cant seem to understand where this error comes from. Maybe someone can help My token solidity file : pragma solidity >=0.4.2 <0.6.0; contract LairToken { //Name string public name = "Lair ...
0
votes
1answer
21 views

ERC-721 - How to avoid that an updatable tokenURI becomes a vulnerability for token trust?

I understand that one can use the tokenURI field to add the address for an endpoint that returns meta data for the given token. Let's imagine we create a unique asset with tokenId = "1" tokenURI = "...
0
votes
0answers
25 views

GasToken.io free transaction fails above certain 'threshold'

I've played around with the gastoken.io GST2 contract in remix (and on the mainnet) and immediately stumbled across the following problem: If I want to free previously minted token the execution of ...
0
votes
1answer
33 views

Can someone send their stable coin ERC-20 tokens to my smart contract?

Here is a business case. Two people own an asset, and they estimate the annual maintenance on that asset is $1000 over the next year. So they each want to put $500 and lock it up in my smart ...
0
votes
2answers
22 views

How can I talk to other contracts and store their function call returns as variables?

For example, I want to grab the current borrow rate for a token on compound.finance. In this contract InterestRateModel.sol, is there a way to call getBorrowRate from my own contract and get the ...
0
votes
0answers
23 views

SendSignedTransaction is not sending tokens

I tried to use sendSignedTransaction function, it signed and sent the transaction successfully(i think), but it's not transferring tokens as it ought to. It's basically not doing the intended task 😔 ...
0
votes
0answers
20 views

What must I do for withdrawal from vesting contract?

I created my token and my token's codes are same with Matic token's codes. Also my vesting contract code is same with Matic token(https://etherscan.io/address/...
0
votes
0answers
18 views

How can i send transaction with the another “From” address

I have created two test tokens and a contract. But when i call transferFrom function with web3 (i called approve function first), it is successful when the from address is the account that deployed it ...
0
votes
0answers
9 views

Retrieving ERC-223 token address on tokenFallback() function

I made a sample smart contract that can update the value of different existing ERC-223 tokens received in the contract as below. Assuming that the IERC223 was taken from here. address[] ...
-1
votes
1answer
22 views

How can we use private chain token in public chain?

I'm software engineer in japan. now, I'm trying to create a dapp by using private chain like kaleid, then will create token in private chain. In the future, I'd like our token to be listed to ...
0
votes
2answers
77 views

Super simple token with Open Zeppelin

I want to create a super simple token for my community. I read some tutorials and I found this code: pragma solidity ^0.5.2; import "./lib/oz/contracts/token/ERC20/ERC20Pausable.sol"; import "./lib/...
0
votes
1answer
35 views

Smart Contract Transfer Event Log Data & transfer _value [Rust]

I'd like to have a better understanding of events and logs data, more specifically when it comes to interacting with ERC20 tokens smart contracts and their Transfer events. I'm looking for a way to ...
2
votes
2answers
58 views

How to generate a new token for ERC1155?

Developing an ERC1155 contract, how to generate an address for a new token? I need to create an API function like function createToken() returns (address). How? Should I just use an incrementing-by-...
2
votes
1answer
23 views

If external function declarations are saving gas, why aren't we using it for the transfer functions?

All the source code I could find (to date) has declared transfer, transferFrom, approve, approveAndCall as public and not external. Although external can be used, what is the reason behind not using ...
1
vote
0answers
10 views

Offchain voting

Are there any voting based approaches where voting would happen off chain, via signed messages, but then the result could be indepedently verified or even stored on chain? Voting rights are based on ...
0
votes
2answers
30 views

Can an Ethereum token be bound or pegged to the value of the gold? [closed]

Could a token be built in ethereum that its price would be bound or pegged to lets say .00006 times the price of an once of gold?
0
votes
1answer
18 views

Tokens are not being transferred with web3js

i have been using following code for transferring tokens from wallet to another with the use of web3js. async Transfer(eth_address, amount){ let tokenAddress = "...
-1
votes
1answer
31 views

Can we send tokens with data input? [duplicate]

Can we send tokens with data input? I did a bit of research on erc20 but maybe this is quite complicated. Will erc 721 do this?
2
votes
0answers
45 views

Combine two addresses into one

I want Solidity code to define a function f that would map two Ethereum addresses A, B into a new address X = f(A,B) such that there is nearly zero probability that X is an already taken address (an ...
1
vote
2answers
52 views

Advantages of using Tokens?

Why should I use a (ERC 20) Token instead of just using Ether? What advatages does it have, besides making money out of nothing?
0
votes
1answer
36 views

How to set different signer and gas payer for a single transaction

I am trying to make a transaction of DAI tokens from user wallet 0xDAIUserWallet to some random token contract say 0xRandomContractAddress. In this scenario I am using the private key of DAI User to ...
0
votes
1answer
14 views

Is QTUM is a coin or a Token?

According to Etherscan Qtum is a Token, holding supply with verified smart contract. But its official site contains its own protocol and integration mechanism. Is it still a token under ETH or it has ...
0
votes
0answers
43 views

Transfer ERC20 Token with vyper

Hello i m learning vyper and i have this issue: I deployed a standard ERC20 token contract using vyper default contract: https://github.com/ethereum/vyper/blob/master/examples/tokens/ERC20.vy When i ...
0
votes
2answers
64 views

Could I use Infura to get the token details?

I went through https://infura.io/docs but not sure if Infura could allow me to read token details like owner, token Id, etc. I also googled on how to read token using Infura but to no avail. Has ...
0
votes
1answer
31 views

Can I put a lock on an already issued erc20 token?

Can I put a lock on an already issued erc20 token? I have issued a fixed erc20 and I want to know if it is possible to apply locku to smart contracts.
0
votes
0answers
21 views

How can link metamask wallet to create Android and web wallet for ERC20 token

I studied Solidity and Web3.js .I still need to know how can use metamask wallet that use in chrome extension to create as a mobile wallet and web wallet for client side.
1
vote
0answers
29 views

Web3 method getTransactionReceipt() does not return token transfer value for particular token transaction

I've tested getTransactionReceipt(), to get all detail about transaction with amount of token transfer. Also tested getTransaction but it returns only Ether transferred value. Is there any other ...
1
vote
1answer
40 views

Is Egretia (EGT) is still Ethereum Token? Or It has been moved as a Coin to its own Blockchain?

Currently Egretia (EGT) is represented as a Token of Ethereum Network, but is there any changes regarding shifting from Token to Coin on its own Chain?
0
votes
1answer
48 views

Detect failed token transfer via RPC

It seems like Etherscan can detect failed token transfer even though the transaction itself is successful and the gas isn't used completely. Like in this transfer of Huobi Tokens Is there a way to ...
1
vote
2answers
230 views

How to check Ethereum smart contract info?

I want to know 3 things: Is an address a smart contract? Is this smart contract an ERC20 or ERC721 token? Is the Solidity code public?