Fund any AI agent from any chain. One URL. Three payment rails.
Fiat β Crypto β Bridge β all settling on Stellar.
Live Demo Β· Integration Guide Β· Wormhole Bridge Docs Β· Stellar Tutorial Β· Contributing
AI agents are becoming autonomous economic participants β they purchase APIs, rent compute, pay for storage, and subscribe to SaaS. But funding them is broken:
- Crypto users need to know the exact chain, token, and address
- Fiat users have no checkout flow at all
- Cross-chain users must manually bridge and swap before sending
There is no universal, chain-agnostic way for a human to fund an AI agent.
ASG Pay is an open-source checkout page that any AI agent generates with a single URL:
https://fund.asgcard.dev/?agentName=MyBot&toAddress=GDQP...&toAmount=50&toToken=USDC
The user clicks the link, picks any payment method, and the agent's wallet is funded. That's it.
| Built with | Stellar |
Wormhole |
Stripe |
Circle USDC |
MasterCard |
| Source chains |
Ethereum |
Solana |
Base |
Polygon |
BNB Chain |
β | Stellar |
| Rail | How it Works | Source | Settlement | Status |
|---|---|---|---|---|
| π¦ Bank & Card | Stripe Checkout β USDC purchase β Stellar delivery | Fiat (Card / Bank) | Stellar | β Live |
| π Bridge & Swap | Wormhole cross-chain bridge β auto-route β Stellar | Ethereum, Solana, Base, Polygon, BSC | Stellar | β Live |
| π€ Direct Send | Freighter wallet β sign β Horizon submit | Stellar (XLM / USDC) | Stellar | β Live |
All three rails share the same universal URL interface. No matter how the user pays, the agent receives USDC on Stellar.
ASG Pay uses Wormhole as its cross-chain interoperability layer, enabling users on any supported EVM chain to fund AI agents on Stellar in a single transaction.
graph LR
subgraph Source Chains
ETH[Ethereum]
SOL[Solana]
BASE[Base]
POLY[Polygon]
BSC[BNB Chain]
end
subgraph Wormhole
WH["π Wormhole Bridge<br/>Token Bridge + Connect"]
end
subgraph Settlement
STELLAR["β Stellar Network<br/>USDC Settlement"]
end
subgraph Destination
AGENT["π€ AI Agent Wallet"]
end
ETH --> WH
SOL --> WH
BASE --> WH
POLY --> WH
BSC --> WH
WH --> STELLAR
STELLAR --> AGENT
style WH fill:#7c3aed,stroke:#fff,stroke-width:2px,color:#fff
style STELLAR fill:#000,stroke:#fff,stroke-width:2px,color:#fff
style AGENT fill:#22c55e,stroke:#fff,stroke-width:2px,color:#000
- User selects source chain and token (e.g., USDC on Ethereum)
- ASG Pay generates a Wormhole transfer via the Token Bridge
- User signs in their wallet (MetaMask, Phantom, etc.)
- Wormhole bridges the tokens cross-chain to Stellar
- Agent receives USDC on their Stellar address
| From | Token | To | Bridge |
|---|---|---|---|
| Ethereum | USDC, USDT, ETH | Stellar (USDC) | Wormhole Token Bridge |
| Solana | USDC, SOL | Stellar (USDC) | Wormhole Token Bridge |
| Base | USDC, ETH | Stellar (USDC) | Wormhole Token Bridge |
| Polygon | USDC, POL | Stellar (USDC) | Wormhole Token Bridge |
| BNB Chain | USDC, BNB | Stellar (USDC) | Wormhole Token Bridge |
See docs/WORMHOLE_BRIDGE.md for detailed integration documentation.
https://fund.asgcard.dev/?agentName=MyBot&toAddress=GDQP...&toAmount=100&toToken=USDC
git clone https://github.com/ASGCompute/asg-pay-public.git
cd asg-pay-public
npm install
npm run dev # β http://localhost:5173| Parameter | Required | Default | Description |
|---|---|---|---|
agentName |
Recommended | Stacy agent |
Display name of the AI agent |
toAddress |
Required | Demo address | Stellar public key (G...) |
toAmount |
Recommended | 50 |
Amount to fund |
toToken |
No | USDC |
Token to receive (USDC, XLM) |
toChain |
No | Stellar |
Settlement chain |
graph TB
Agent["π€ AI Agent"] -->|Generates URL| Portal["ASG Pay Portal"]
User["π€ User"] -->|Opens link| Portal
Portal --> Selection["Payment Method Selection"]
Selection --> Fiat["π¦ Bank & Card"]
Selection --> Bridge["π Bridge & Swap"]
Selection --> Send["π€ Direct Send"]
Fiat -->|"Stripe Checkout"| StripeAPI["Stripe API"]
StripeAPI -->|"Webhook"| Settlement["Settlement Engine"]
Settlement -->|"USDC"| AgentWallet["Agent Wallet<br/>(Stellar)"]
Bridge -->|"Wormhole SDK"| WH["Wormhole<br/>Token Bridge"]
WH -->|"Cross-chain settle"| AgentWallet
Send -->|"Freighter Sign"| Horizon["Stellar Horizon"]
Horizon --> AgentWallet
style AgentWallet fill:#22c55e,stroke:#fff,stroke-width:2px,color:#000
style Portal fill:#7c3aed,stroke:#fff,stroke-width:2px,color:#fff
style WH fill:#6366f1,stroke:#fff,stroke-width:2px,color:#fff
| Layer | Technology |
|---|---|
| Frontend | React 19, TypeScript, Vite 8 |
| Styling | Vanilla CSS (glassmorphic design system, 1700+ lines) |
| Stellar | @stellar/stellar-sdk, @stellar/freighter-api |
| Cross-chain | Wormhole Token Bridge, Wormhole Connect |
| Fiat | Stripe Checkout |
| Hosting | Vercel (auto-deploy from main) |
ASG Pay is part of the broader ASG Card ecosystem β a suite of open-source tools for AI agent payments:
| Package | Description | Install |
|---|---|---|
| ASG Pay | Cross-chain funding portal (this repo) | git clone / hosted |
| @asgcard/sdk | TypeScript SDK for payment integration | npm i @asgcard/sdk |
| @asgcard/cli | CLI for wallet setup + card management | npx @asgcard/cli |
| @asgcard/mcp-server | MCP Server (11 tools) for AI agents | npx @asgcard/mcp-server |
Python β Generate payment link
from urllib.parse import urlencode
def create_funding_url(agent_name: str, address: str, amount: float) -> str:
params = {
"agentName": agent_name,
"toAddress": address,
"toAmount": str(amount),
"toToken": "USDC",
}
return f"https://fund.asgcard.dev/?{urlencode(params)}"
# Usage
url = create_funding_url("Trading Bot", "GDQP2KPQ...", 100)
print(f"Fund your agent: {url}")TypeScript β Generate payment link
function createFundingUrl(params: {
agentName: string;
toAddress: string;
toAmount: number;
toToken?: string;
}): string {
const search = new URLSearchParams({
agentName: params.agentName,
toAddress: params.toAddress,
toAmount: String(params.toAmount),
toToken: params.toToken || "USDC",
});
return `https://fund.asgcard.dev/?${search.toString()}`;
}MCP Tool β Auto-generate via AI agent
# Install the MCP server
npx @asgcard/mcp-server
# The MCP server provides payment URL generation as a built-in tool
# AI agents using Claude, Cursor, or Codex can create funding links automaticallyStellar β Monitor incoming payments
import { Horizon } from "@stellar/stellar-sdk";
const server = new Horizon.Server("https://horizon.stellar.org");
server.payments()
.forAccount("YOUR_AGENT_ADDRESS")
.cursor("now")
.stream({
onmessage: (payment) => {
if (payment.type === "payment") {
console.log(`Received ${payment.amount} ${payment.asset_code || "XLM"}`);
}
},
});src/
βββ App.tsx # Root: URL params, balance fetching, routing
βββ types.ts # TypeScript interfaces (AppState, TokenInfo)
βββ index.css # Design system (1700+ lines, CSS variables)
βββ providers.tsx # React context providers
βββ components/
β βββ AgentInfoCard.tsx # Left panel: agent identity, destination, balances
β βββ PaymentSelection.tsx # Payment method selection (Fiat / Stablecoin / Crypto)
β βββ ExchangeWidget.tsx # Tabbed widget: Bank & Card / Bridge & Swap / Send
β βββ ReceiveWidget.tsx # Route selection and bridge confirmation
β βββ Header.tsx # Page header with wallet status
β βββ ErrorBoundary.tsx # React error boundary
β βββ modals/
β βββ TokenModal.tsx # Multi-chain token selector
β βββ SettingsModal.tsx # Bridge settings (slippage, gas, routes)
β βββ WalletModal.tsx # Wallet connection (Freighter, MetaMask, Phantom, WC)
β βββ ProgressOverlay.tsx # Tx progress + Wormhole bridge tracking + success state
βββ utils/
βββ stellar.ts # Stellar SDK: build, sign, submit transactions
| Wallet | Chains | Protocol |
|---|---|---|
| Freighter | Stellar | Native (TESTNET + MAINNET) |
| MetaMask | Ethereum, Base, Polygon, BSC | EVM + Wormhole Bridge |
| Phantom | Solana | Solana + Wormhole Bridge |
| WalletConnect | Multi-chain | QR Code |
- π Destination locked β recipient address is pre-filled and immutable
- π No private keys β all signing happens in the user's wallet extension
- π Client-side only β no backend stores sensitive data
- β Open source β fully auditable codebase
- π‘οΈ CSP headers β Content Security Policy enforced via Vercel
| Phase | Status | Description |
|---|---|---|
| β Phase 1 | Complete | Core UI: agent card, payment selection, glassmorphic design system |
| β Phase 2 | Complete | Stellar wallet: Freighter integration, real tx signing, Horizon submission |
| β Phase 3 | Complete | Fiat on-ramp: Stripe Checkout with fee calculation |
| β Phase 4 | Complete | Cross-chain bridge: Wormhole Token Bridge integration |
| π§ Phase 5 | In Progress | Wormhole Connect widget embedding + advanced route optimization |
| π Phase 6 | Planned | Payment API: programmatic checkout sessions + webhook callbacks |
| π Phase 7 | Planned | Soroban: on-chain payment verification smart contract |
We welcome contributions from the Stellar and Wormhole communities. See CONTRIBUTING.md for guidelines.
- Add Wormhole Connect widget to Bridge & Swap tab
- Implement bridge transaction status polling via Wormhole API
- Add loading skeletons while Horizon balance data loads
- Keyboard accessibility for modal overlays
|
Stellar Settlement network |
Wormhole Cross-chain bridge |
Stripe Fiat on-ramp |
Circle USDC issuer |
MasterCard Card issuance (via ASG Card) |
Apache 2.0 β Use it, fork it, build on it.