March 14, 2023

Notify Custom Webhooks – Real-Time Data with Moralis Streams

Table of Contents
Check out Moralis´ Streams API for the best way to work with real-time blockchain data!

With Moralis Streams, developers can easily get real-time blockchain data. This free tool especially shines when compared to similar, more limited options, such as Alchemy’s Notify Custom Webhooks. But don’t just take our word for it. In this article, discover why Moralis Streams is the premier Web3 real-time data listener. Also, learn how to leverage this enterprise-grade Web3 API to set up streams in minutes! Here is an example illustrating how easy Streams makes it to monitor wallet activity based on an address: 

import Moralis from 'moralis';
import { EvmChain } from "@moralisweb3/common-evm-utils";

Moralis.start({
  apiKey: 'YOUR_API_KEY',
});

const stream = {
  chains: [EvmChain.ETHEREUM, EvmChain.POLYGON], // List of blockchains to monitor
  description: "monitor Bob’s wallet", // Your description
  tag: "bob", // Give it a tag
  webhookUrl: "https://YOUR_WEBHOOK_URL", // Webhook URL to receive events
}

const newStream = await Moralis.Streams.add(stream);
const { id } = newStream.toJSON(); // { id: 'YOUR_STREAM_ID', ...newStream }

// Now we attach Bobs address to the stream
const address = "0x68b3f12d6e8d85a8d3dbbc15bba9dc5103b888a4";

await Moralis.Streams.addAddress({ address, id });

Moralis Streams offers all the functionality of Notify webhooks. Plus, it doesn’t require you to request beta access. Moreover, Moralis Streams has already proven to be a reliable Web3 data tool powering some of the industry’s biggest projects since its launch in mid-2022! This means you can rest safely knowing Moralis Streams offer all the functionality of Notify Custom Webhooks in a reliable package that works for real-world use cases! Therefore, if you’ve been interested in Notify Custom Webhooks, you should make sure to sign up for Moralis Streams!

Scale Beyond Notify Custom Webhooks - Sign Up for Moralis Streams

Overview 

This article will start by diving into the intricacies of Notify Custom Webhooks from Alchemy, which currently remains in beta testing. From there, we take the following section to explore the best Notify Custom Webhooks alternative: Moralis Streams! In combination with exploring both options, we will also compare Moralis Streams vs Notify Custom Webhooks. This will highlight the differences between the alternatives and some of the reasons why seasoned devs prefer using Web3 streams vs Notify webhooks, according to a wealth of testimonials.

Lastly, to top things off, we will show you the best way to get real-time blockchain data by demonstrating how easy it is to set up your own Moralis stream. So, if you are eager to start coding, jump straight into the ”Best Way to Get Real-Time Data” section. 

Along with the Web3 Streams API, Moralis also provides other enterprise blockchain solutions and development resources. For example, the Moralis Web3 blog features comprehensive content for both new and more experienced developers. So, if you are looking for other blockchain development guides, check out our articles on Web3 marketplace development or crypto wallet tracking

Also, remember to sign up with Moralis if you want to access all these amazing Web3 development resources. You can set up an account for free and immediately start leveraging the full power of blockchain!

Notify Webhooks vs Moralis Streams

What is Notify Custom Webhooks? 

Notify Custom Webhooks is Alchemy’s recently announced real-time data solution within the Notify suite. The Notify Custom Webhooks solution remains in beta, and through this service, Alchemy suggests that users can track smart contract or marketplace activity, monitor oracle updates or contract creation, and apply filters to get the data they are looking for. 

Title - What is Alchemy Notify Custom Webhooks?

According to Alchemy’s website, this Notify webhooks solution is their answer to the challenges associated with Web3 data. Blockchain data is central to Web3 development; however, accessing this information and getting the specific data you are after can be challenging. So, how is Alchemy looking to solve this problem? 

Alchemy suggests that the Notify Custom Webhooks solution tackle the blockchain data accessibility challenges through two central dimensions: control and flexibility. Let’s take a closer look at these: 

  • Control – Notify Custom Webhooks will feature filters, allowing users to specify what information they receive. 
  • Flexibility – According to Alchemy, this Notify webhooks solution will help users understand contract-based events. This ranges from token activity to more complex data ingestion. 

So, what type of data will you actually be able to acquire through the Notify Custom Webhooks solution?

Access Data with Notify Custom Webhooks 

With a better understanding of what a Notify Custom Webhooks solution entails, let us look closer at the data you can acquire and how it can be used. Here are three examples of on-chain data you can get: 

  1. Token Activity – You will be able to get token-related activity through Notify webhooks. This includes staking, transfers, mints, burns, etc.
  1. Marketplace Activity – In the future, you can track marketplace activity at the level of detail that suits your projects. 
  1. Data Ingestion – You will be able to ingest any useful data stream for your project. 
Notify Custom Webhooks Data Graph

Now that you know what types of data you will be able to acquire through the Notify Custom Webhooks solution, how can it be used in practice? To answer this question, you can find three examples of use cases below: 

  • Track Particular Activity Types – Through Notify webhooks, you will be able to track particular event types. This includes token activity, marketplace activity, oracle activity, etc. 
  • Notifications – You can set up notifications and alerts when a particular event triggers on-chain.
  • Database Data Ingestion – With Notify Custom Webhooks, you can push data into your databases to enrich and transform the information. 

Accessing on-chain data this way might sound like new, revolutionary tech; however, it is not. In fact, Moralis – the preferred Notify Custom Webhooks alternative for Web3 devs – has provided a more advanced solution in the form of Web3 Streams, without requiring any beta signup, since October 2022! 

Notify Custom Webhooks vs Moralis Streams 

Through the Notify Custom Webhooks real-time data solution, Alchemy is looking to provide a similar service to Moralis Streams. These two services share many similarities, which can make it challenging to determine what alternative to go for. As such, let us compare Notify Custom Webhooks vs Moralis Streams so that you can make an informed decision. 

We already familiarized ourselves with Alchemy’s Notify Custom Webhooks in the previous two sections. So, let us take the following parts to focus more on Moralis Streams and the Web3 Streams API.

Moralis Streams is the premier Web3 real-time data listener. With the Web3 Streams API, you can seamlessly set up streams to funnel blockchain data into the backend of all your projects via Web3 webhooks. This means you can receive instant, customizable updates when important events trigger on-chain!

Streams API vs Notify Webhooks

Moralis Streams support all types of events, NFTs, fungible tokens, DeFi transfers, smart contracts, wallets, and much more! Here are five examples of Moralis Streams’ most prominent features: 

  • Listen to contract events or wallets, or both with multiple streams. 
  • Get blockchain data streamed to your backend in real-time.
  • Track one or millions of addresses using a single stream.
  • Add custom ABIs and choose the events you want to monitor. 
  • Fully customize your streams using filters.

These are only a few exciting features making this the best Notify Custom Webhooks alternative, and there is much more to the Moralis Streams real-time data solution. To further explore the capabilities of Moralis Streams, let us dive into some of this service’s most compelling use cases in the next section! 

Moralis Streams Use Cases 

With a more profound understanding of the premier Moralis Streams real-time data solution, let us explore three prominent use cases: 

  1. Get User Asset Transfers – With Moralis Streams, you can effortlessly monitor and track your users’ balances and transactions. Stream any on-chain event, including NFTs, DeFi transactions, tokens, etc., into your app’s backend. 
Notify Custom Webhooks vs Moralis Streams Use Cases
  1. Notify Users Automatically – Optimize user engagement with real-time notifications. Stay ahead of your competitors with seamless real-time notifications and updates for wallets or users. What’s more, set up filters to only monitor relevant blockchain events. 
Notifications from Alchemy Notify Webhooks vs Web3 Streams
  1. The Fastest Way to Get Smart Contract Events – Track particular on-chain events and contracts seamlessly. All you need to do is input the contract you are interested in, add your ABI, and set up custom data filters on metadata and topics to receive events, addresses, interactions, and much more! 

Lastly, to fully understand the accessibility of Moralis Streams, let us take the following section to explore the benefits of using the Moralis Web3 Streams API! 

Benefits of Moralis Streams 

By opting for the Streams API, Moralis does all the heavy lifting for you. Consequently, you can save both valuable time and resources. Here are three ways in which Moralis Streams benefit you: 

  • Total Customization – Moralis Streams feature the industry’s most customizable and flexible real-time API for on-chain data. This means you can set up streams for any custom Web3 use case you can imagine. 
  • Built for Scale – Experience streams with unparalleled scalability. For instance, effortlessly listen to the 100,000,000 most active Ethereum wallets in one single stream. 
  • Go to Market Faster – With this industry-leading API, you get an accessible workflow, enabling you to set up streams quickly. This means you can avoid reinventing the wheel and beat your competition to market.

So, in the battle between Moralis Streams vs Notify Custom Webhooks, which of the alternatives should you opt for? With a better understanding of Moralis Streams, we can now compare the two in the next section!

Alchemy’s Notify Custom Webhooks and Web3 Tools Comparison 

First of all, the most significant difference between Notify webhooks from Alchemy and Moralis Streams is that the latter is fully up and running. As we mentioned in the introduction, Notify webhooks are still in beta. On the other hand, Moralis Streams launched last year in October and has been operational since. So, if you want to access real-time blockchain data today, your best option is, without a doubt, Moralis Streams! 

What’s more, what Alchemy is aiming to do with the Notify Custom Webhooks, Moralis already offers with the Streams API. This includes everything from tracking various activity types to setting up notifications and much more. 

Lastly, Moralis’ cross-chain capabilities also exceed those of Alchemy. Notify Custom Webhooks only support four blockchain networks: Ethereum, Polygon, Arbitrum, and Optimism. Meanwhile, Moralis supports all of these, along with chains such as BNB Chain, Solana, Aptos, and others.

To summarize, Moralis Streams offers all the functionality of Notify webhooks, does not require you to request beta access, and Moralis has been around since last year. Consequently, by opting for Moralis, you can be confident in knowing Moralis Streams provide all the functionality of Notify Custom Webhooks in a trusted and tested package that works for real-world use cases and several additional blockchain networks! 

So, now that you know that Moralis is the best Notify Custom Webhooks alternative, you might be asking yourself, ”how do I set up Moralis Streams?”. To answer this question, join us in the next section as we explore the easiest and best way to get real-time blockchain data!

Best Way to Get Real-Time Data 

As you found out in the previous section, Moralis Streams provides everything Alchemy’s Notify Custom Webhooks offers and more, making this the best way to get real-time data. However, how exactly does Moralis Streams work? We will answer this question by showing you how to set one up in three steps using the Moralis Web3 Streams API for monitoring wallet activity: 

  1. Set Up a Project and Moralis – First, create a new project folder with an ”index.js” file and open it in your IDE. Next, launch a new terminal, cd into the project’s root folder, and install the required Moralis dependencies by running the following command:
npm i moralis

From here, you now need to import and initialize Moralis. To do so, open ”index.js” and input the following snippet at the top: 

import Moralis from 'moralis';
import { EvmChain } from "@moralisweb3/common-evm-utils";

Moralis.start({
  apiKey: 'YOUR_API_KEY',
});

As you can see, you must add your Moralis API key by replacing YOUR_API_KEY. To get one, sign up with Moralis, log in to the admin panel, navigate to the ”Web3 APIs” tab, and copy your key:

  1. Create a stream Object – For the second step, you must create a new stream object and add a few parameters. Here is an example of what it might look like:
const stream = {
  chains: [EvmChain.ETHEREUM, EvmChain.POLYGON], // List of blockchains to monitor
  description: "monitor Bob's wallet", // Your description
  tag: "bob", // Give it a tag
  webhookUrl: "https://YOUR_WEBHOOK_URL", // Webhook URL to receive events,
}
  1. Call the Moralis.Streams.add() Function – Lastly, call the Moralis.Streams.add() function while passing the stream object as a parameter. You can then add new {id} and address variables to the stream:
const newStream = await Moralis.Streams.add(stream);
const { id } = newStream.toJSON(); // { id: 'YOUR_STREAM_ID', ...newStream }

// Now we attach Bob’s address to the stream
const address = "0x68b3f12d6e8d85a8d3dbbc15bba9dc5103b888a4";

await Moralis.Streams.addAddress({ address, id });

All in all, your ”index.js” file should now look similar to this: 

import Moralis from 'moralis';
import { EvmChain } from "@moralisweb3/common-evm-utils";

Moralis.start({
  apiKey: 'YOUR_API_KEY',
});

const stream = {
  chains: [EvmChain.ETHEREUM, EvmChain.POLYGON], // List of blockchains to monitor
  description: "monitor Bob’s wallet", // Your description
  tag: "bob", // Give it a tag
  webhookUrl: "https://YOUR_WEBHOOK_URL", // Webhook URL to receive events,
}

const newStream = await Moralis.Streams.add(stream);
const { id } = newStream.toJSON(); // { id: 'YOUR_STREAM_ID', ...newStream }

// Now we attach Bob’s address to the stream
const address = "0x68b3f12d6e8d85a8d3dbbc15bba9dc5103b888a4";

await Moralis.Streams.addAddress({ address, id });

From here, you can run the program with the following terminal command: 

node index.js

In return, when the address specified partakes in a transaction, you will receive a webhook containing transaction details. 

Congratulations, you have just created your very own Web3 stream! 

For more information on creating and customizing streams, check out our guide on how to get blockchain data!

Summary – Notify Custom Webhooks 

In this article, we’ve explored Alchemy’s Notify Custom Webhooks real-time data solution that currently remains in beta testing. Along with diving into the intricacies of Notify webhooks, we also explored the number one Notify Custom Webhooks alternative: Moralis Streams! 

From there, we compared Notify Custom Webhooks vs Moralis Streams, highlighting their similarities and differences. In doing so, you learned that Moralis Streams is the best option for getting real-time blockchain data. 

The reasoning behind this is that Moralis Streams offer all the functionality of Notify Custom Webhooks, does not require you to request beta access, and has been live since October 2022. As such, by going for Moralis Streams, you get all the functionality of Notify webhooks in a trusted package working for real-life use cases and across multiple blockchain networks!

In addition to exploring the best Notify Custom Webhooks alternative, you also got to learn how to set up your very own Moralis stream in only three straightforward steps: 

  1. Set Up a Project and Moralis
  2. Create a stream Object
  3. Call the Moralis.Streams.add() Function

If you liked this article, you might also want to check out other content on the blog to learn Web3 development. For instance, we have two articles following the same theme exploring the Alchemy NFT API and the best Notify API alternative.

Also, remember to sign up with Moralis if you want to access any of the Web3 APIs from Moralis. You can register for free and start leveraging the full power of Web3 technology in a heartbeat! 

Streams API
Stream Web3 events and get real-time notifications whenever something important happens on-chain!
Streams API
Related Articles
December 15, 2022

Exploring Web3 Contract Methods – How to Run Web3 Methods on Ethereum

July 2, 2024

Fantom RPC Nodes – How to Set Up a Fantom Node for Free 

June 18, 2024

Streams Vs. Ethers.js – The Best Way to Get Real-Time Web3 Data

November 6, 2022

Web3 Provider – Why Blockchain Developers Should Use One

August 22, 2022

How to Integrate Backend Web3 Authentication Functionality

November 20, 2023

What’s the Difference Between Polygon PoS vs Polygon zkEVM?

September 12, 2022

How to Build a Cronos Dapp in 5 Steps

November 29, 2023

List of Smart Contract Ideas and Examples for Developers

January 21, 2023

How to Create a Twitter Bot for Crypto

🔥 LIMITED-TIME OFFER - Get early access to an Enhanced Token Page & boost your token project’s exposure! GET EARLY ACCESS 🔥