name() β string
Returns the name of the token.symbol() β string
Returns the symbol of the token, usually a shorter version of the name.decimals() β uint8
Returns the number of decimals used to get its user representation. For example, if decimal equals 2, a balance of 505 tokens should be displayed to a user as 5,05 (505 / 10 ** 2).
Tokens usually opt for a value of 18, imitating the relationship between Ether and Wei.totalSupply() β uint256
Returns the number of tokens in existence.balanceOf(address account) β uint256
Returns the number of tokens owned by the account.allowance(address owner, address spender) β uint256
Returns the remaining number of tokens that the spender will be allowed to spend on behalf of the owner through transferFrom
. It is zero by default.approve(address spender, uint256 amount)
Sets amount as the allowance of spender over the callerβs tokens.transfer(address recipient, uint256 amount)
Moves tokens from the callerβs account to the recipient.transferFrom(address sender, address recipient, uint256 amount)
Moves tokens from sender to recipient using the allowance mechanism. The amount is deducted from the callerβs allowance.increaseAllowance(address spender, uint256 addedValue)
Automatically increases the allowance granted to spender by the caller.decreaseAllowance(address spender, uint256 addedValue)
Automatically decreases the allowance granted to spender by the caller.;extension=gmp
;extension=curl
;curl.cainfo =
curl.cainfo = "C:\Users\HP\Downloads\cacert.pem"
choco install openssl
$obj1->getName($contractAddress);
$obj1->getSymbol($contractAddress);
$obj1->getDecimal($contractAddress);
$obj1->getTotalSupply($contractAddress);
$obj1->getBalanceOf($contractAddress,$ownerAddress);
$obj1->getAllowance($contractAddress,$ownerAddress,$spenderAddress);
$obj1->getApprove($contractAddress,$ownerAddress,$ownerPrivateKey,$spenderAddress,$tokenAmount);
; $obj1->increaseAllowance($contractAddress,$ownerAddress,$ownerPrivateKey,$spenderAddress,$tokenAmount);
$obj1->decreaseAllowance($contractAddress,$ownerAddress,$ownerPrivateKey,$spenderAddress,$tokenAmount);
$obj1->transferFrom($contractAddress,$ownerAddress,$spenderAddress,$spenderPrivateKey,$recieverAddress,$tokenAmount);
$obj1->transferToken($contractAddress,$senderAddress,$senderPrivateKey,$recieverAddress,$tokenAmount);
$obj1->transferXdc($contractAddress,$senderAddress,$senderPrivateKey,$recieverAddress,$xdcAmount);
$obj3 = new createXDCWallet();
$obj3->createWallet();
?>XRC721
and XRC165
interfaces.symbol() β string
Provides the symbol of the token, mostly just an abbreviation of the name.name() β string
Provides the name of the token.totalSupply() β uint256
Returns the total amount of tokens in the contract.balanceOf(address account) β uint256
Provides the number of non-fungible tokens in the owner's account.ownerOf(tokenId) β address
Returns the NFT owner specified by tokenId
.tokenURI(uint256 tokenId) β string
Gives the URI for a tokenID
.tokenOfOwnerByIndex(address owner, uint256 index) β uint256
Returns the token ID at a given index of the requested owner.tokenByIndex(uint256 index) β uint256
Returns the token ID at a given index.supportInterface(tokenId) β bool
Sets its value true if the contract implements the interface defined by interfaceId
. getApproved(tokenId) β address
Returns the approved address for a token ID or sets it to zero if no address. If the token ID does not exist, it reverts.isApprovedForAll (address owner, address operator) β bool
Tells whether a given owner approves an operator.approve(address to, uint256 tokenId)
Approves the address that sends the given token ID. It ensures to approve only one address per token at a given time. Only the token owner or an approved operator can call the approve
method. The zero address means that no approved address exists.transferFrom(address from, address to, uint256 tokenId)
Provides the ownership of a given token ID to another address.safeTransferFrom(address from, address to, uint256 tokenId)
Safely provides the ownership of the requested token ID to another address.setApprovalForAll(address operator, bool approved)
setApprovalForAll
method grants or revokes the approval of a given operator. An operator can send all tokens of the sender on their behalf.;extension=gmp
;extension=curl
;curl.cainfo =
curl.cainfo = "C:\Users\HP\Downloads\cacert.pem"
choco install openssl
$obj2->getName($contractAddress);
$obj2->getSymbol($contractAddress);
$obj2->getTotalSupply($contractAddress);
$obj2->getBalanceOf($contractAddress,$ownerAddress);
$obj2->getSupportInterface($contractAddress,$interfaceId);
$obj2->getOwnerOf($contractAddress,$tokenId);
$obj2->getTokenURI($contractAddress,$tokenId);
$obj2->getTokenByIndex($contractAddress,$index);
$obj2->getTokenOfOwnerByIndex($contractAddress,$ownerAddress,$index);
$obj2->getApproved($contractAddress,$tokenId);
$obj2->approve($contractAddress,$recieverAddress,$tokenId,$privateKey);
$obj2->setApprovalForAll($contractAddress,$operatorAddress,$approvedStatus,$ownerPrivateKey,$tokenId);
$obj2->setApprovalForAll($contractAddress,$operatorAddress,$approvedStatus,$ownerPrivateKey,$tokenId);
$obj2->safeTransferFrom($contractAddress,$ownerAddress,$recieverAddress,$tokenId,$approvedPrivateKey);
$obj2->transferFrom($contractAddress,$ownerAddress,$recieverAddress,$tokenId,$approvedPrivateKey);
$obj2->transfer($contractAddress,$ownerAddress,$recieverAddress,$tokenId,$approvedPrivateKey);