Skip to content

feat: add optional Edge Signals Token Verdict action provider - #1666

Open
konstantinbozukov wants to merge 1 commit into
coinbase:mainfrom
konstantinbozukov:feat/edgesignals-token-verdict-action-provider
Open

konstantinbozukov wants to merge 1 commit into
coinbase:mainfrom
konstantinbozukov:feat/edgesignals-token-verdict-action-provider

Conversation

@konstantinbozukov

Copy link
Copy Markdown

Description

This PR adds an optional Edge Signals action provider with a single action, get_token_verdict.

Token Verdict is a pre-trade token risk check for ERC-20s. The agent calls it before swapping, transferring, or otherwise interacting with an unknown token, and gets back a letter grade (A–F), a band (SAFE | CAUTION | AVOID), a score from 0–100, and human-readable reasons.

Disclosure: I built Edge Signals / Token Verdict (Konstantin Bozukov). This provider is opt-in: it is not added to any default AgentKit instance or example chatbot. Existing actions, prices, and provider lists are unchanged. Each call is paid — $0.01 USDC on Base via x402, charged to the agent's wallet. There is no API key. The result is not financial advice.

Payment uses the same @x402/fetch / @x402/evm path as the existing x402 action provider, signed with the agent's EvmWalletProvider. The action is only offered when the wallet is on Base mainnet (supportsNetwork).

Docs:

A Python port is not included, to keep this change small. Happy to add one in a follow-up if useful.

Commit signing: I was not able to sign this commit from this environment (no signing key is attached to the GitHub account used to open the PR). I can re-sign if that is required before merge.

Tests

Unit tests for the new provider (10 tests) cover supportsNetwork (Base mainnet only), a successful paid fetch via mocked wrapFetchWithPayment, URL construction, HTTP errors, JSON parse errors, and network failures:

cd typescript/agentkit
pnpm test -- src/action-providers/edgesignals/edgesignalsActionProvider.test.ts
# 10 passed

pnpm exec eslint on the new files and pnpm run check (tsc --noEmit) both pass.

I did not run a live chatbot against Base mainnet in this PR, because that would spend real USDC. The unit tests mock the x402 payment wrapper and assert the Token Verdict URL, method, and formatted output. I can follow up with a recorded chatbot transcript if a reviewer wants one:

Chatbot: typescript/examples/langchain-cdp-smart-wallet-chatbot (not run live)
Network: Base mainnet
Setup: AgentKit configured with edgeSignalsActionProvider(); wallet funded with USDC

Prompt: get a token verdict for 0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913 on base

<not run in this PR — unit tests only>

Checklist

A couple of things to include in your PR for completeness:

  • Added documentation to all relevant README.md files
  • Added a changelog entry

Adds an opt-in action provider that fetches a Token Verdict for an ERC-20
before a swap or other interaction. Each call costs $0.01 USDC on Base via
x402, paid from the agent's wallet. Existing actions and default provider
lists are unchanged.
@cb-heimdall

Copy link
Copy Markdown

🟡 Heimdall Review Status

Requirement Status More Info
Reviews 🟡 0/2
Denominator calculation
Show calculation
1 if user is bot 0
1 if user is external 0
2 if repo is sensitive 0
From .codeflow.yml 1
Additional review requirements
Show calculation
Max 0
0
From CODEOWNERS 0
Global minimum 0
Max 1
1
1 if commit is unverified 1
1 if authored by an app that is not allowlisted and lacks verified human attribution 0
Sum 2

@github-actions github-actions Bot added documentation Improvements or additions to documentation action provider New action provider typescript labels Nov 19, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

action provider New action provider documentation Improvements or additions to documentation typescript

Development

Successfully merging this pull request may close these issues.

2 participants