veriql-goat
v0.3.0
Published
Veriql plugin for GOAT: check a recipient (OFAC, Drain Watch, Tether/Circle freeze) before an agent pays, check a USDT transfer goes through before it is sent, and decode a signing request (approvals, Permit2, EIP-7702) before it signs.
Maintainers
Readme
veriql-goat
Veriql checks for GOAT agents that move money.
| Tool | When the agent should call it | Cost |
|---|---|---|
| veriql_check_payee | Before sending funds to any address. Checks the OFAC SDN sanctions list, the Drain Watch list of known drainer and scam addresses, and whether Tether or Circle has frozen the address (read from the issuer's own contract). Works for EVM, Solana, Bitcoin and Tron addresses. | $0.01 |
| veriql_check_send | Before sending USDT on Tron or Ethereum. Pass from, to and optionally amount. Answers both questions in one call: will it go through (frozen sender, unactivated account, too little USDT, too little TRX or ETH for the fee, read off the chain with the exact fee), and should it go there (recipient against OFAC, Drain Watch and Tether's freeze list). Tether checks the sender, not the recipient, so USDT sent to a frozen address confirms and can never leave. Answers do_not_send, will_fail, may_fail, goes_through or incomplete. | $0.01 |
| veriql_check_signature | Before signing anything. Decodes approvals, Permit and Permit2, EIP-7702 delegations, transfers and revokes, and checks whoever gains the power. Answers block, warn or allow. A payload it can't decode is block, and you're not charged for it. | $0.01 |
| veriql_check_denylist | A free, instant screen against OFAC SDN plus Drain Watch, cached for an hour. | free |
Veriql is read-only. It never asks for a key, never signs a transaction and never moves funds.
Install
npm install veriql-goatimport { getOnChainTools } from "@goat-sdk/adapter-vercel-ai";
import { veriql } from "veriql-goat";
const tools = await getOnChainTools({
wallet: viem(walletClient),
plugins: [veriql()],
});Works with @goat-sdk/core 0.4 and 0.5, on any chain.
Paying for calls
There are two ways to pay. Pick one:
- x402, no account. With an EVM wallet, the agent pays each call itself in USDC on Base. A price above
maxPaymentUsdc(default0.05, or set theVERIQL_MAX_PAYMENT_USDCenv var) is refused before anything is signed. - An API key. Pass
apiKeyor setVERIQL_API_KEY. Calls then spend prepaid credits and nothing is signed. This is the option for Solana and other non-EVM wallets. A free key with 250 calls is at https://veriql.app/api/checkout?pack=free.
veriql({ apiKey: process.env.VERIQL_API_KEY, maxPaymentUsdc: 0.05 });What the answers mean
no_known_riskorallowmeans nothing adverse was found when the check ran. It's not a guarantee.incompletemeans a check couldn't run. Treat the address as unverified, not as clean.goes_throughmeans every check on both ends answered and nothing blocks the transfer. It's not a guarantee about the recipient.will_failanddo_not_sendstand even when another check could not run.- Every failure comes back as
{ error: true, ... }and tells the agent to treat the input as unverified. A failure is never reported as clean, and if the denylist feed is down, that's an error, not "not listed".
Tests
npm testThe payment test pays a real x402 challenge captured from production with a fresh key. It then checks that the signed USDC authorisation recovers to that key, pays the published address, and pays exactly the published price.
Licence
MIT.
