使用Tenderly为区块链交易设置警报通知

去中心化金融社区Publicado a 2022-03-31Actualizado a 2022-03-31

Resumen

Tenderly有内置的定制警报,即使是新手用户也可以在多个链上事件创建警报。

“Tenderly有内置的定制警报,即使是新手用户也可以在多个链上事件创建警报。”

现在让我们先来看看除了以太坊主网之外,我们还可以使用哪些网络:

Tenderly支持的网络

登录项目后,我们将探索位于Tenderly仪表板侧边栏的“监控->警报”服务:

登录后左侧边栏

有一个免费使用的警告,当我们打开警报页面时将显示:

我们将收到一批在15分钟内发生的警报。升级到TenderlyPro/Dev以接收实时警报。

对于测试来说,这不是一个问题,所以我们可以继续使用免费版本。为了更可靠地使用警报,我们必须升级我们的帐户。

让我们从检查创建新警报时可以完成的事情开始。

创建警报

警报类型是我们为触发通知的链事件设置的条件:

所有的警报类型

“警报目标”指的是为上述事件和条件进行监控的合约:

所有警报目标

警报目的地是当上述合约满足警报条件时将收到通知的地点:

所有警报的目的地

在创建一个新的警报之前,我们必须首先:

决定我们希望被通知哪个合约的哪些事件。

在“Contracts”选项卡中添加我们想要监控的合约,这样我们就可以在步骤2中将它作为目标。

连接将接收消息的目的地(在本指南中我们将使用电报),因此我们将能够在步骤3中向它发送通知。

将Telegram添加为目的地

在警报标签中,点击顶部菜单中的“目的地”,点击“Telegram”:

添加电报为目的地

标记它,并按照说明,让机器人发送消息给我们:

按照指示,让机器人向我们发送消息

要完成上述过程,复制指令第三步中的“魔法字”。将它粘贴到与Tenderly的电报机器人聊天中,点击@TenderlyRobot即可打开聊天。

机器人现在可以在此聊天中发送消息的确认消息!

监控YearnVault存款/取款

让我们从监控Fantom网络上的SPELLyVault上的一些事件开始。我们需要知道SPELLyVault合约地址,我们可以通过进入YearnVaults界面,点击SPELLvault找到它。

Fantom上的YearnVaults

单击它后,我们将看到包含所有金库详细信息的页面,单击“区块浏览器”按钮,就会进入金库的合约:

SPELLyVault详细信息

这将打开FTMScan(Etherscan的Fantom分叉)上的SPELLyVault合约:

在FTMScan上的SPELLyVault合约

我按顺序突出显示了用例的重要信息:

首先是合约地址

然后是“代币名称”(当打开许多合约选项卡时会有所帮助)

最后是合约执行的方法(函数)的历史

对于我们的示例,我们将在有人将代币存入Vault时添加通知。为此,需要复制合约页面URL:

https://ftmscan.com/address/0xD3c19eB022CAC706c898D60d756bf1535d605e1d

然后进入Tenderly的合约标签,点击将该合约导入到他们的仪表盘中,这将使我们能够为其创建警报:

在Tenderly中导入合约

粘贴该地址,选择“VyperContract”(名称如下所示,YearnVaults使用Vyper编程语言)。当它出现时,点击“导入”:

在Tenderly中导入合约

导入合约后,我们就可以为它创建警报了!

在Tenderly中导入合约

让我们创建一个警报:

创建新警报

我们希望每次有人存入SPELLyVault时都会收到通知。为此,我们将检查yVault合约中存在的“存款”方法。“方法”是一个类似于“函数调用”的名称,所以这是我们将在本例中使用的警报类型。

选择警报类型

目标是一个地址:

选择警报目标

我们可以选择之前添加的合约,然后选择其中存在的任何函数。许多函数可能有类似的名称,以“_”开头的函数通常是私有的内部函数,不是我们要寻找的函数。

在本例中,我们有_deposit(私有:供内部使用)和deposit(公共:供外部用户使用)。我们将选择一个公共的:

选择警报目标

最后,选择之前设置的电报目的地并保存警报:

选择警报目的地

警报已被创建,每当有人将SPELL存入该yVault时,我都会收到一条消息!

警报成功创建!

以下是我在设置这个示例并触发它后所得到的通知示例,我在交易确认后立即收到通知!

FantomyVault的新SPELL存款通知已发送至我的电报!

总结

这个Yearn示例展示了一种监控合约函数调用的简单方法。如果探索警报系统的所有选项,我们会发现可以更容易地调整到许多不同的用法,例如:

NFT的开发者可以监控他们的合约何时调用了一个新代币的铸造,并在Discord上自动宣布它。

监控Tokenomics流程的人可以使用通知来关注钱包余额和合约行为,看看开发者是否在做预期要做的事情。

我们可以看到任何一种链上活动,并得到它的通知。

Source:https://medium.com/iearn/setup-notifications-for-blockchain-transactions-with-tenderly-407a3df6e1ba

Lecturas Relacionadas

465% Growth in One Day: How a Memory Shortage Made CXMT China's Most Valuable Company

Chinese memory chip maker CXMT (ChangXin Memory Technologies) saw its shares surge 465.82% on its debut on the Shanghai STAR Market on July 27, 2026, closing at 49 yuan. Its market capitalization reached over 3.2 trillion yuan (~$473-488B), making it mainland China's most valuable listed company. This explosive debut coincided with staggering industry-wide profit growth. China's major integrated circuit manufacturers saw profits soar 2579.5% year-on-year in H1 2026. Specific companies like Shenzhen Longsys Electronics and GigaDevice Semiconductor reported profit growth exceeding 62,000% and 1000%, respectively. The primary driver is the AI boom, which has triggered massive global data center construction. Major memory giants like Samsung, SK Hynix, and Micron shifted capacity to high-margin AI accelerator memory (HBM), creating a severe shortage of standard DRAM used in servers, PCs, and smartphones. Contract DRAM prices spiked 90-95% QoQ in Q1 2026 and another 50-60% in Q2. CXMT, as China's largest domestic DRAM producer, capitalized on this deficit. It ramped up standard DRAM supply, secured long-term contracts with clients like ByteDance and Tencent, and expanded capacity. It forecasts H1 2026 revenue of 110-120B yuan and net profit of 50-57B yuan. A low comparative base from 2025's industry downturn and domestic policy support further fueled growth. However, analysts note a significant constraint: U.S. export controls on advanced lithography and manufacturing equipment limit CXMT's access to tools needed for cutting-edge HBM production. Its future trajectory will depend not just on global DRAM demand but also on China's ability to develop domestic semiconductor manufacturing equipment.

cryptonews.ruHace 1 min(s)

465% Growth in One Day: How a Memory Shortage Made CXMT China's Most Valuable Company

cryptonews.ruHace 1 min(s)

SkyCapital Expands Cooperation with Crypto Services Amid Regulatory Changes

SkyCapital, a financial technology company, has announced an expansion of its partnership program for crypto services in response to new, stricter regulations coming into force in Russia in September 2026. The company will offer its infrastructure to other market participants to help them transition from anonymous P2P transfers to a more transparent, legally compliant business model. According to SkyCapital's managing director, Dmitry Galkin, the move addresses a growing industry demand. He explained that after the new law takes effect, services lacking proper KYC/AML checks, anti-fraud protection, and SBP (Russia's Fast Payments System) acquiring will only be able to operate under a transitional period. Ultimately, they will face a clear choice: adapt with compliant infrastructure or shut down. The partnership model allows other crypto services to maintain their own brand and customer interface while utilizing SkyCapital's backend infrastructure. This includes SBP-acquiring, transaction execution, KYC/AML verification, anti-fraud systems, and regulatory reporting. This approach enables faster, more cost-effective compliance for partners without needing to build such systems from scratch. Galkin warned that non-compliant operators risk not just payment blocks and business limitations, but also potential criminal and administrative prosecution. SkyCapital believes the crypto market is entering a phase where competition is increasingly supplemented by partnerships focused on shared, reliable infrastructure to mitigate operational, regulatory, and reputational risks. This strategic shift signifies SkyCapital's broader role in the market, moving beyond its own platform to provide technological and compliance solutions for the wider industry. It reflects a broader trend in the Russian crypto sector away from fragmented, informal models towards collaboration around secure and formalized solutions.

cryptonews.ruHace 9 min(s)

SkyCapital Expands Cooperation with Crypto Services Amid Regulatory Changes

cryptonews.ruHace 9 min(s)

South Korean Giants LG CNS and POSCO International Implement Real-Time Trade Transaction Data on Injective Blockchain

South Korean conglomerates POSCO International and LG CNS have launched a pilot project to tokenize real trade accounts receivable on the Injective blockchain, using actual commercial data from POSCO's overseas subsidiaries. POSCO International, a major trading firm with over $22 billion in revenue, and LG CNS, a leading IT services provider, are testing this as an advanced real-world asset (RWA) initiative in Korea. The pilot issues POSCO's receivables as permissioned tokens on Injective. Authorized parties can hold and transfer these assets, with settlements executed on-chain. This moves away from the current fragmented tracking by subsidiaries, banks, and counterparties—which slows reconciliation and delays cash access—to a single shared ledger. Compliance rules are embedded with the tokens, enabling uniform checks across jurisdictions. Injective was chosen for its native real-world asset module, which enforces regulatory compliance at the protocol level. Its fast transaction finality (under one second per block) and built-in order book designed to prevent front-running were cited as essential for tokenizing real monetary claims. The companies aim to build a unified infrastructure for inter-subsidiary trade, enabling faster settlements than the current multi-day cycle and border-agnostic compliance. POSCO plans to refine the pilot structure in the second half of the year for real business application. This project is part of a global acceleration in enterprise tokenization, with Korea being a particularly active market.

cryptonews.ruHace 11 min(s)

South Korean Giants LG CNS and POSCO International Implement Real-Time Trade Transaction Data on Injective Blockchain

cryptonews.ruHace 11 min(s)

Trading

Spot
活动图片