DeFi and DEX Integration Guide
This guide describes how to integrate Webacy APIs into your DeFi platform. We'll highlight where defi platforms get the most benefit from Webacy and share the tools that make integration fast & easy.
Where to Integrate Webacy
Here are common places to integrate Webacy to get the most benefit:
Upon wallet connection
Your token / asset list display screens
Monitoring protocol activity
Transaction confirmation pages
Let's see what each of these might look like.
1) Safety of Connected Wallets
At a baseline, your application should restrict sanctioned and dangerous wallets from accessing it. This is to protect the company and your team. Webacy APIs are a quick and easy way to make the check when wallets connect to your service.
You can also choose to display the Wallet Safety Score to the user. This provides many benefits:
Informing the user of wallet health, ensuring the assets within the wallet stay safe and the user can continue being valuable to your platform
Additional value to the end-user, as well as interaction with your protocol and platform
Differentiation from other platforms
A visual indication of your commitment to user safety
The risk data of connected wallets give you additional insight into the types of users accessing your platform, and gives your users additional value to keep them coming back.
2) Token Display Screens
You may be filtering out spam tokens already (or if you're not, you can use Webacy APIs to do so and improve your current filtering!) but it may also be a good idea to display individual risk flags for any risky assets or approvals that do make their way into a user's account.
Webacy's APIs also enable you to assess smart contract code in real time, giving you the most up-to-date analysis for tokens on your platform.
In the self-custodial space, your users will ultimately do whatever they want to do, but adding a layer of safety and educational data helps you protect your platform and delivers additional value to your customers. Using Webacy APIs to assess the risk of individual tokens or NFTs can help identify scam tokens, dangerous contracts, and other nefarious activity.
3) Monitoring Protocol Activity
Webacy Wallet Watch is the industry's fastest notification and monitoring system. Track addresses important to your protocol, and immediately get notified of any and all transactions involved with those addresses, including a risk score for each.
Here are a few ways to leverage the Webacy Wallet Watch service:
Monitor your smart contracts, flag for high risk transactions
Monitor addresses important to your company: signer wallets, multisig wallets, deployer wallets, and more
Offer your end-users wallet monitoring, so they can be notified of activity regarding their wallet (and prompt them to return to your application).
4) Transaction Confirmation Pages
Before a user approves a blockchain transaction, they should be informed of the risk associated with it. With Webacy, you can display the counterparty risk (the address they are sending assets to/from), as well as the interaction risk (the address or smart contract involved in the transaction, if any), and warn users about dangerous transactions with an automated warning.
The API response returns warning flags and a consolidated Risk Score. You can choose to take action depending on certain flags that appear (ex. "sanctioned") or leverage the Risk Score to determine what to show your user. It is also important to review the URL the user is accessing to make the transaction. Webacy's URL Risk endpoint supports this functionality.
Some options for leveraging the response:
Block the user with a large warning before the transaction signature screen
Visual indicators on the signature screen of a risky transaction
While self-custody leaves the decision making up to the end-user, it is the platform's responsibility to offer the best possible information and protection to the end-user.
For self-custodial solutions, it may be best to still allow the user to bypass the warning screen and proceed with signing the transaction. There are cases where the user still wants to assume the risks.
..
Get started with Webacy!
Last updated