Moralis and Chiliz

Moralis is a leading crypto data provider that helps companies build great user experiences, drive engagement, growth and revenue in their applications.

What this means for you

Moralis has integrated Chiliz Chain to its roster of APIs, so that developers can enjoy Chiliz Chain features combined with the swift and efficient capabilities of Moralis.

Through Moralis, you can easily use several Chiliz-specific APIs: Token API, NFT API, Wallet API, Blockchain API, and Streams API.

Moralis APIs​

All Moralis APIs are supported on Chiliz Chain and across all other major EVM blockchains. All endpoints support powerful filtering capabilities.

Wallet API​

With Moralis Wallet API you can get Wallet balances for tokens, NFTs and native assets, get full wallet history, net worth and a lot more.

NFT API​

With Moralis NFT API you can get NFT data like collections, owners, prices, images and metadata.

Token API​

With Moralis Token API you can get ERC20 token data like prices, ownership, metadata, transfers, approvals, liquidity, mints and burns.

Blockchain API​

With Moralis Blockchain API you can get core blockchain data like blocks, transactions and logs.

Moralis Streams​

Moralis Streams allow you to stream blockchain data in real-time via webhooks. Subscribe to any on-chain event, like NFT or token mints, transfers or swaps, add powerful filters and then watch the data flow to your destination in real time.

Use it to build things like wallet notifications, Telegram alerts or just to keep your user balances up to date in real-time by streaming data to your database.

Getting started with Moralis APIs​

In order to use the Moralis APIs you need a Moralis account and a Moralis API key.

  1. Go to admin.moralis.io and create a Moralis account

  2. Login to access the admin interface

  3. Go to settings and find your API key

  4. Find all endpoints and SDKs in the Moralis documentation

You can now call any Moralis endpoint, see below for an example.

Get NFT balances of Wallet​

Request

import Moralis from 'moralis';

try {
  await Moralis.start({
    apiKey: "mmRBnJ94TQu5Fr2FSMCYBAtDtpDKz3axFSqcUZ7wr6skFnJtfrJXW3XRt3AeRyph"
  });

  const response = await Moralis.EvmApi.nft.getWalletNFTs({
    "chain": "0x1",
    "format": "decimal",
    "mediaItems": false,
    "address": "0xd8da6bf26964af9d7eed9e03e53415d37aa96045"
  });

  console.log(response.raw);
} catch (e) {
  console.error(e);
}

Response

{
  "page": 1,
  "page_size": 100,
  "cursor": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJjdXN0b21QYXJhbXMiOnsid2FsbGV0QWRkcmVzcyI6IjB4ZDhkYTZiZjI2OTY0YWY5ZDdlZWQ5ZTAzZTUzNDE1ZDM3YWE5NjA0NSJ9LCJrZXlzIjpbIjE2ODU5MzY5NDQuNTE3Il0sIndoZXJlIjp7Im93bmVyX29mIjoiMHhkOGRhNmJmMjY5NjRhZjlkN2VlZDllMDNlNTM0MTVkMzdhYTk2MDQ1In0sImxpbWl0IjoxMDAsIm9mZnNldCI6MCwib3JkZXIiOltdLCJkaXNhYmxlX3RvdGFsIjp0cnVlLCJleGNsdWRlX3NwYW0iOmZhbHNlLCJ0b3RhbCI6bnVsbCwicGFnZSI6MSwidGFpbE9mZnNldCI6MSwiaWF0IjoxNjkzNDY3ODc0fQ.z5vEhLXquK4l91WxS62KgGzL3zgI8vYuWOe2Uzi64iI",
  "result": [
    {
      "token_address": "0xb365e53b64655476e3c3b7a3e225d8bf2e95f71d",
      "token_id": "1",
      "amount": "1",
      "owner_of": "0xd8da6bf26964af9d7eed9e03e53415d37aa96045",
      ...
    },
    ...
  ]
}

Getting started with Moralis Streams​

  1. Go to admin.moralis.io and create a Moralis account

  2. Login to access the admin interface

  3. Go to the Streams page

  4. From there you can configure your Moralis Stream from the UI

  5. Configure the trigger, what events or what addresses to watch

  6. Configure the filters you want

  7. Configure which chains you want the Stream to be active on.

  8. Set up your destination webhook (where the data should be sent)

You can also set up Streams programmatically, check out the Moralis Streams documentation for a guide on how to do that.

Tutorials & Guides​

Tutorials​

Guides​

Last updated