feat: add BasePay action provider — gasless USDC, batch pay, escrow, subscriptions on Base Mainnet#1333
Open
osr21 wants to merge 4 commits into
Open
feat: add BasePay action provider — gasless USDC, batch pay, escrow, subscriptions on Base Mainnet#1333osr21 wants to merge 4 commits into
osr21 wants to merge 4 commits into
Conversation
🟡 Heimdall Review Status
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR adds BasePay as a community action provider for AgentKit, giving AI agents five USDC payment primitives on Base Mainnet with no additional dependencies.
Actions added
basepay_send_usdcbasepay_send_usdc_gaslessbasepay_batch_pay_usdcbasepay_create_escrowbasepay_subscribeHow gasless works
The agent signs an EIP-3009
TransferWithAuthorizationtyped message (no on-chain tx). The BasePay relay submits it toUSDC.transferWithAuthorization(), paying the ETH gas. This means agents can send USDC with zero ETH balance — a critical unlock for autonomous agent wallets.Verified contracts (Base Mainnet)
0xe40d…c680x1eb2…4990x1019…421Usage
Or via the standalone npm package:
Self-hosting the relay
The relay is open-source (github.com/osr21/basepay) and requires only a funded EOA (ETH on Base) to operate. Configurable via
basePayActionProvider({ relayUrl: "https://your-relay.example.com" }).No new dependencies
The provider uses only packages already in the AgentKit dependency graph (
viem,zod). The relay call uses nativefetch.Live dApp: https://base-pay.replit.app
npm package: https://www.npmjs.com/package/basepay-agentkit
Contracts + source: https://github.com/osr21/basepay