Skip to main content

What is Delegation?

Delegation enables users with non-custodial wallets to grant spending authority to the platform for card payments while maintaining full custody of their assets. In traditional custodial systems, users transfer funds to the platform, giving up control. With delegation, users keep their private keys and assets in their own wallets, only granting permission for the platform to spend up to a specified limit.
Users maintain full custody of their funds. The platform can only spend within approved limits, and users can revoke access at any time through their blockchain wallet.

Why Delegation?

Non-Custodial Benefits

User Maintains Control

Users keep their private keys and full custody of funds. No need to transfer assets to the platform.

Transparent Spending

All transactions are on-chain and verifiable. Users can monitor spending limits and transaction history.

Reduced Platform Risk

Platform doesn’t hold user funds, reducing regulatory complexity and security liability.

Revocable Access

Users can revoke or modify spending authority at any time through their wallet.

Key Concepts

External Wallet

A user-controlled wallet where private keys are managed by the user through wallet applications like:
  • EVM Chains: MetaMask, WalletConnect, Coinbase Wallet, Rainbow Wallet
  • Solana: Phantom, Solflare, Backpack
The platform never has access to private keys or full control over these wallets.

Allowance

The maximum amount the platform can spend from a delegated wallet. This is set by the user during the delegation process. Example: User approves a 5,000 USDC allowance. The platform can charge up to 5,000 USDC for card purchases, but no more.
Users can increase or decrease their allowance by redelegating their wallet with a new amount.

Priority

When users delegate multiple wallets, priority determines the order in which wallets are charged for transactions.
  • Lower number = Higher priority (Priority 1 is charged before Priority 2)
  • Platform attempts wallets in order until transaction succeeds
  • Useful for managing balances across multiple wallets or optimizing gas fees
Example Priority Configuration:
Priority 1: Linea USDC wallet (5,000 USDC)
Priority 2: Ethereum USDT wallet (2,000 USDT)
Priority 3: Solana USDC wallet (10,000 USDC)

Spending Authority

On-chain approval that grants the platform’s smart contracts permission to transfer tokens from the user’s wallet up to the allowance limit.
  • EVM Chains: Implemented via ERC20 approve() function
  • Solana: Implemented via SPL Token delegation

Supported Networks and Currencies

Network: Linea (Layer 2) Chain ID: 59144 Currencies: USDC, USDTPrimary network for most integrations. Low gas fees and fast transactions.
For US-specific routing, set the x-us-env: true header or region=us query parameter.

Use Cases

Personal Card Payments

Enable users to make card purchases directly from their non-custodial wallets without depositing funds to the platform.
  1. User delegates wallet with 5,000 USDC allowance
  2. User makes $50 purchase with physical/virtual card
  3. Platform charges $50 from delegated wallet
  4. Remaining allowance: 4,950 USDC

Multi-Wallet Management

Users can delegate multiple wallets and set priorities for flexible fund management. Scenario: User has funds across multiple networks
  • High-priority wallet for frequent transactions (Linea USDC)
  • Backup wallet for when primary runs low (Ethereum USDC)
  • Long-term holdings wallet with higher limits (Solana USDC)

Business Expense Cards

Companies can delegate corporate wallets to employee cards with controlled spending limits.
  • Each employee gets a card linked to company wallet
  • Spending limits enforced on-chain
  • All transactions transparent and auditable
  • Company maintains full custody of funds

How Delegation Works

1

Backend: Request Token

Your backend calls GET /v1/delegation/token to generate a single-use delegation token.
2

Frontend: Wallet Interaction

Your frontend application:
  1. Connects user’s wallet (MetaMask, Phantom, etc.)
  2. Requests blockchain approval transaction
  3. User signs message to prove wallet ownership
  4. Collects transaction data for next step
3

Backend: Submit Proof

Your backend submits the delegation proof to finalize registration using POST /v1/delegation/evm/post-approval for Linea/Ethereum or POST /v1/delegation/solana/post-approval for Solana.
4

Verify Registration

Confirm wallet was successfully registered using GET /v1/wallet/external.
See the Implementation Guide for detailed step-by-step instructions with code examples.

Security Model

What the Platform CAN Do

  • Charge up to the approved allowance for card transactions
  • Initiate transactions from delegated wallet within spending limit
  • View wallet balance and allowance on-chain

What the Platform CANNOT Do

  • Access or store private keys
  • Transfer more than the approved allowance
  • Move funds outside of approved use cases
  • Prevent user from revoking access
The platform operates within strict on-chain constraints. All spending authority is enforced by smart contracts, not the platform.

Next Steps

Ready to implement delegation? Here’s your learning path:

Frequently Asked Questions

Yes, users can revoke spending authority at any time directly through their wallet by setting the allowance to zero or switching to a different spender address.
Transactions will fail if the remaining allowance is insufficient. Users will need to redelegate their wallet with a higher allowance to continue making purchases.
Yes, but each platform would need its own approval. ERC20 approvals are per-spender, so multiple platforms can have different allowances for the same wallet.
Yes, users pay standard gas fees for the approval transaction on their chosen blockchain. Linea typically has lower gas fees than Ethereum mainnet.
The entire process typically takes 2-5 minutes, depending on blockchain confirmation times and network congestion.