Skip to content

feat: add OfframpActionProvider for Base USDC cash-out - #1442

Open
ADWilkinson wants to merge 5 commits into
coinbase:mainfrom
ADWilkinson:andrew/offramp-action-provider
Open

feat: add OfframpActionProvider for Base USDC cash-out#1442
ADWilkinson wants to merge 5 commits into
coinbase:mainfrom
ADWilkinson:andrew/offramp-action-provider

Conversation

@ADWilkinson

@ADWilkinson ADWilkinson commented Aug 14, 2026

Copy link
Copy Markdown

Description

AgentKit already supports bringing funds onchain with get_onramp_buy_url. This PR completes the other half of the flow by adding OfframpActionProvider, giving agents a native way to cash out Base USDC to fiat through @usdctofiat/offramp.

With this provider, agents can:

  • Use fast for live market pricing with 0% spread
  • Use best to cash out through the Delegate strategy
  • Send fiat to eligible payment rails such as Revolut and Venmo

This enables complete fiat-to-crypto-to-fiat workflows inside AgentKit: fund a wallet, transact onchain, and cash out when the user is ready.

Implementation

The new offramp action wraps:

cashout({ mode, signer, amount, currency, platform, payee })

It follows the existing AgentKit action-provider pattern and supports Base mainnet.

Tests

Added 10 unit tests covering provider behavior, network support, argument forwarding, and SDK responses. The SDK is mocked, so no USDC is spent during tests.

cd typescript/agentkit
pnpm test -- offrampActionProvider

pnpm exec changeset status recognises @coinbase/agentkit for a patch release.

The action-provider contract is covered with a mocked SDK, so no USDC is spent. A live chatbot cash-out was not run because it would sign and submit a financial transaction; that path remains host-controlled.

Links

Checklist

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

@cb-heimdall

cb-heimdall commented Aug 14, 2026

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
Sum 2

@github-actions github-actions Bot added documentation Improvements or additions to documentation action provider New action provider typescript labels Aug 14, 2026
@ADWilkinson ADWilkinson changed the title feat: add OfframpActionProvider wrapping USDCtoFiat cashout feat: add OfframpActionProvider for Base USDC cash-out Aug 14, 2026
Native AgentKit action wrapping @usdctofiat/offramp@7.0.1 cashout({ mode: fast|best }).
Fast stays Fast. Best is delegated 10 bps. Galleon/USDCtoFiat disclosed.
Base mainnet only. Does not republish the SDK.
@ADWilkinson
ADWilkinson force-pushed the andrew/offramp-action-provider branch from 82fee9a to dfa0c32 Compare August 14, 2026 06:12
@ADWilkinson

ADWilkinson commented Aug 23, 2026

Copy link
Copy Markdown
Author

Updated to current main in cc80691. The current lint rules exposed missing public JSDoc and stale schema formatting; fixed in d4f82e3. On the merged head, all 10 focused offramp tests pass; targeted ESLint and Prettier checks pass; TypeScript compilation with tsc --noEmit passes; git diff --check passes. Remaining gates are maintainer review / Heimdall.

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