Cover Image for How to Get Newly Created Ethereum Tokens?

How to Get Newly Created Ethereum Tokens?

Product
Tutorial
NFT
Digital Asset

Anyone can create different types of tokens using Ethereum smart contracts. At the time of writing this article, more than 112,373 different tokens were already created on the Ethereum blockchain using ERC20, ERC721, ERC223, ERC827 standards.

Ethereum users create more than 100 tokens on an average day. This data can help you to get early access to new projects, which can 

This article will show you how to get newly created Ethereum tokens using a simple GraphQL query.

The following query provides all the newly created token for ERC20, ERC721, ERC223, ERC827 standards. It means whenever a new smart contract of this standard is deployed, our database index those smart contract as Tokens.

You can run the given query, our Bitquery GraphQL editor. (https://graphql.bitquery.io/)

Newly created Ethereum Tokens

{
    ethereum {
        smartContractCalls(options: {desc: "block.height", limit: 10}, 
        smartContractMethod: {is: "Contract Creation"}, 
        smartContractType: {is: Token}) {
            block {
                height
                timestamp {
                    time
                }
            }
            smartContract {
                contractType
                address {
                    address
                    annotation
                }
                currency {
                    name
                    symbol
                    decimals
                    tokenType
                }
            }
        }
    }
}

Here is the Github gist for the above query. Besides, the above GraphQL query can be used as an API.

Results

{
    "data": {
        "ethereum": {
            "smartContractCalls": [
                {
                    "block": {
                        "height": 10999795,
                        "timestamp": {
                            "time": "2020-10-06 03:36:28"
                        }
                    },
                    "smartContract": {
                        "contractType": "Token",
                        "address": {
                            "address": "0xc5ffbdce0a51b96f3df227b48245389d4c3ed833",
                            "annotation": null
                        },
                        "currency": {
                            "name": "MachiX Dao Shares",
                            "symbol": "MACHIXDAO",
                            "decimals": 18,
                            "tokenType": "ERC20"
                        }
                    }
                },
                {
                    "block": {
                        "height": 10998520,
                        "timestamp": {
                            "time": "2020-10-05 22:47:49"
                        }
                    },
                    "smartContract": {
                        "contractType": "Token",
                        "address": {
                            "address": "0x6065651e64e94e3148490ab56027034aebb3fe86",
                            "annotation": null
                        },
                        "currency": {
                            "name": "ydex.finance",
                            "symbol": "YDEX",
                            "decimals": 18,
                            "tokenType": "ERC20"
                        }
                    }
                },
                {
                    "block": {
                        "height": 10998232,
                        "timestamp": {
                            "time": "2020-10-05 21:38:47"
                        }
                    },
                    "smartContract": {
                        "contractType": "Token",
                        "address": {
                            "address": "0x02413c345233f06963cf86c642f5f41f3a189c16",
                            "annotation": null
                        },
                        "currency": {
                            "name": "Gifts by Adam Priester",
                            "symbol": "GIFTSBYADAMPRIESTER",
                            "decimals": 0,
                            "tokenType": "ERC721"
                        }
                    }
                }

As you can see above query provide the token details and also the token standard types. 

You can tweak the query to get more details or filter the results based on your needs. Besides, you can also add a data time filter if you want.

Here is an example:

{
    ethereum {
        smartContractCalls(options: {desc: "block.height", limit: 10}, 
        date:{since: "2020-10-01", till: "2020-10-31"},
        smartContractMethod: {is: "Contract Creation"}, 
        smartContractType: {is: Token}) {
            block {
                height
                timestamp {
                    time
                }
            }
            smartContract {
                contractType
                address {
                    address
                    annotation
                }
                currency {
                    name
                    symbol
                    decimals
                    tokenType
                }
            }
        }
    }
}

Let us know how you plan to use this API. If you have any questions, you can ask them on our Telegram channel. Also, let us know if you are looking for blockchain data APIs.

You might also be interested in:

About Bitquery

Bitquery is a set of software tools that parse, index, access, search, and use information across blockchain networks in a unified way. Our products are:

  • Coinpath® APIs provide blockchain money flow analysis for more than 24 blockchains. With Coinpath’s APIs, you can monitor blockchain transactions, investigate crypto crimes such as bitcoin money laundering, and create crypto forensics tools. Read this to get started with Coinpath®.

  • Digital Assets API provides index information related to all major cryptocurrencies, coins, and tokens.

  • DEX API provides real-time deposits and transactions, trades, and other related data on different DEX protocols like Uniswap, Kyber Network, Airswap, Matching Network, etc.

If you have any questions about our products, ask them on our Telegram channel or email us at sales@bitquery.io. Also, subscribe to our newsletter below, we will keep you updated with the latest in the cryptocurrency world.

Subscribe to our newsletter

Subscribe and never miss any updates related to our APIs, new developments & latest news etc. Our newsletter is sent once a week on Monday.