Skip to main content Link Search Menu Expand Document (external link)

YFD Contract Queries

Table of contents
  1. YFD Contract Queries
    1. Token Info:
    2. Marketing Info:
    3. All Accounts:
    4. Balance:
    5. Allowance:
    6. All Allowances:

Below I will describe the possible Query messages that can be used on this YFD contract in both object and JSON formats

Token Info:

Gets the on-chain information about the token stored on the blockchain


        
  
{token_info: {}}


      

        
  
{"token_info": {}}


      

        
  
{
  "name": "Y-Foundry DAO",
  "symbol": "YFD",
  "decimals": 6,
  "total_supply": "10000000000000"
}  


      

Downloads the on-chain logo for the YFD token if there is one


        
  
{download_logo:{}}


      

        
  
{"download_logo":{}}


      

        
  
logo not found: query wasm contract failed: invalid request


      

Marketing Info:

Gets the marketing information for the YFD token


        
  
{marketing_info:{}}


      

        
  
{"marketing_info":{}}


      

        
  
{
  "project": null,
  "description": null,
  "logo": {
    "url": "https://yfoundry.io/logo-512-orange-transparent-square.png"
  },
  "marketing": null
}


      

All Accounts:

Gets all wallet addressess that hold YFD


        
  
{all_accounts:{}}


      

        
  
{"all_accounts":{}}


      

        
  
{"accounts":["address", "address", "address", ...]}


      

Balance:

Gets the YFD balance of the given wallet address. Balance is returned in microunits


        
  
{balance: { address: [account_address]}}


      

        
  
{"balance": { "address": "[account_address]"}}


      

        
  
{"balance": "78999989667"}


      

Allowance:

Gets the allowance list of the given owner and spender


        
  
{
  allowance: {
    owner: "Addr",
    spender: "Addr"
  }
}


      

        
  
{
  "allowance": {
    "owner": "Addr",
    "spender": "Addr"
  }
}


      

        
  
Work In Progress


      

All Allowances:

Gets the list of all allowances of the token that owner received and not expired


        
  
{
  all_allowances: {
    owner: "Addr",
    start_after: "Addr",
    limit: 1 
  }
}


      

        
  
{
  "all_allowances": {
    "owner": "Addr",
    "start_after": "Addr",
    "limit": 1 
  }
}


      

        
  
{"allowances": []}