coinbase / coinbase/agentkit

[Feature Request] Add wallet reputation check before transfers

Open
#979 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
1.3k
Forks
815
Avg merge
13h 31m
Merged PRs (30d)
2

Description

### Problem

When an AgentKit agent executes a `transfer` action, it sends USDC/ETH to a wallet address with no way to assess the recipient's trustworthiness. A fresh sybil wallet looks identical to a 6-month-old legitimate operator.

### Proposal

Add an optional pre-transfer reputation check using [DJD Agent Score](https://djd-agent-score.fly.dev), a free API that scores wallets on Base based on their on-chain transaction history.

The integration is 5 lines in the transfer action:

```typescript
// Before executing transfer, check recipient reputation
const scoreRes = await fetch(
`https://djd-agent-score.fly.dev/v1/score/basic?wallet=${recipientAddress}`
);
const { score, tier, confidence } = await scoreRes.json();

if (score < 40 || confidence < 0.2) {
return `Warning: Recipient wallet ${recipientAddress} has a low reputation score (${score}/100, ${tier}). This wallet may be newly created or exhibit suspicious patterns. Proceed with caution.`;
}

// Continue with existing transfer logic...
```

### Why this matters

- **Free tier:** 10 calls/day, no API key, no signup, no payment
- **Fast:** <200ms response time, cached scores
- **On-chain data only:** Scores are based on real USDC transaction history, partner diversity, account age, and 12 behavioral sybil/gaming checks
- **x402 native:** Paid tier uses the same x402 protocol AgentKit already supports

### Try it

```bash
curl "https://djd-agent-score.fly.dev/v1/score/basic?wallet=0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045"
```

[API Docs](https://djd-agent-score.fly.dev/docs) · [OpenAPI Spec](https://djd-agent-score.fly.dev/openapi.json) · [GitHub](https://github.com/jacobsd32-cpu/djdagentscore)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.