project screenshot 1
project screenshot 2
project screenshot 3
project screenshot 4
project screenshot 5
project screenshot 6

PDFi

When did your PDF last send a payment? PDeFi makes invoices pay on-chain, instantly, securely.

PDFi

Created At

ETHGlobal New York 2025

Winner of

Coinbase

Coinbase Developer Platform - Build a Great Onchain App Using CDP

Fern

Fern - Best Finance App on Fern

Project Description

PDFi: The First Interactive PDF Blockchain Platform

PDFs have been static documents for 30+ years. We've cracked the code to make them interactive with blockchain networks. A PDF that can actually send cryptocurrency transactions is revolutionary.

📄 Why PDFs Are Perfect

Universal Familiarity

  • Everyone knows PDFs - from your grandma to corporate executives
  • No learning curve - people already understand how to open, view, and interact with PDFs
  • Trusted format - PDFs are the gold standard for official documents
  • Works everywhere - every device, every operating system, every browser

Traditional Finance Still Runs on PDFs

  • Invoices are sent as PDFs
  • Contracts are signed as PDFs
  • Receipts are generated as PDFs
  • Bank statements come as PDFs
  • Tax documents are PDFs

The entire financial world already operates on PDFs. We're just making them functional.

💰 Real-World Impact: Hackathon Example

The Problem: Hackathon organizers spend weeks chasing winners for payment details, bank accounts, wire transfers, international fees, currency conversions.

The PDFi Solution:

  • Winner gets a PDF invoice
  • Clicks "Pay Now"
  • Money is sent instantly
  • No back-and-forth emails
  • No bank account sharing
  • No international wire fees
  • The PDF pays for itself

🔗 Multi-Chain, Multi-Token Support

Users can withdraw from:

  • Ethereum (ETH, USDC, USDT, DAI)
  • Base (ETH, USDC, USDT)
  • And more chains coming...

One PDF wallet, access to the entire crypto ecosystem.

The Core Innovation: PDF + Blockchain Connection

We've connected the world's most trusted document format to the world's most innovative financial technology.

📋 Endless Use Cases

Business & Finance

  • Invoices that pay themselves
  • Credit memos with instant settlement
  • Purchase orders with automatic payment
  • Expense reports with direct reimbursement

Digital Assets

  • Gift cards that work globally
  • Vouchers with blockchain verification
  • Burner wallets for temporary use
  • Prepaid cards without physical cards

Events & Services

  • Event tickets with built-in payment
  • Service contracts with automatic billing
  • Subscription renewals via PDF
  • Membership cards with crypto benefits

�� Why This Changes Everything

1. No More App Downloads

  • Users don't need MetaMask, Coinbase Wallet, or any crypto app
  • Just open the PDF and start using it
  • Works on any device with a PDF reader

2. Instant Global Payments

  • Send money to anyone, anywhere, instantly
  • No bank accounts needed
  • No international wire fees
  • No currency conversion delays

3. Self-Executing Documents

  • PDFs that actually do what they say
  • Invoices that pay themselves
  • Contracts that execute automatically
  • Receipts that verify on blockchain

4. Trust Through Transparency

  • Every transaction is recorded on blockchain
  • No chargebacks or fraud
  • Permanent audit trail
  • Public verification

How it's Made

How PDFi Was Built: The Technical Deep Dive

The Core Architecture

PDFi is built on a three-tier architecture that bridges the gap between static PDF documents and dynamic blockchain networks. The frontend creates interactive PDFs, the backend handles blockchain operations, and the PDFs themselves contain embedded JavaScript that communicates with our infrastructure.

CDP (Coinbase Developer Platform) Integration

The backbone of our blockchain operations is CDP, which provides enterprise-grade account management and transaction capabilities. CDP handles the complex aspects of blockchain interaction that would be impossible to implement securely in a PDF environment.

Key CDP Features We Leverage:

  • Account Management: Each PDF wallet gets a dedicated CDP account with its own address
  • Transaction Signing: CDP handles the cryptographic signing of transactions
  • Multi-Chain Support: Seamless switching between Ethereum, Base, and other networks
  • Balance Management: Real-time balance checking across multiple tokens
  • Gas Optimization: Automatic gas estimation and fee management

Technical Implementation: The CDP service handles all blockchain operations through their REST API, creating accounts for PDF wallets with unique identifiers and managing the entire lifecycle of each wallet. When a user creates a PDF wallet, we instantiate a new CDP account that becomes the underlying blockchain address for that specific PDF.

FERN API Integration

FERN provides the swap functionality that enables PDF wallets to exchange between different cryptocurrencies. This is particularly crucial for the "send-eth-with-swap" PDF variant.

FERN's Role:

  • Quote Generation: Real-time exchange rates for crypto pairs
  • Swap Execution: Atomic swaps between different tokens
  • Slippage Protection: Ensures users get fair exchange rates
  • Multi-DEX Aggregation: Routes through multiple decentralized exchanges

Technical Challenges with FERN:

  • Quote Expiration: FERN quotes expire quickly, requiring careful timing
  • Slippage Management: Need to handle price movements during transaction confirmation

Dynamic Wallet Integration

Dynamic provides the wallet connection layer that allows users to interact with PDFs using their existing crypto wallets. This eliminates the need for users to manage private keys within PDFs.

Dynamic's Benefits:

  • Multi-Wallet Support: Works with MetaMask, Coinbase Wallet, WalletConnect, etc.
  • Cross-Platform: Functions on web, mobile, and desktop
  • Security: Private keys never leave the user's wallet
  • User Experience: Familiar wallet connection flow

Implementation Details: The Dynamic context provides wallet connection capabilities, allowing users to connect their existing wallets to the PDF creation process. Contract interactions use the connected wallet through Wagmi hooks, ensuring that all blockchain transactions are signed by the user's own wallet rather than our backend.

The FDF (Forms Data Format) Challenge

FDF is Adobe's standard for PDF form data exchange, but it has significant limitations that made our implementation particularly challenging.

FDF Limitations We Overcame:

  • No Direct JavaScript Support: FDF can't execute JavaScript functions
  • Limited Data Types: Only supports basic string/number values
  • No Callback Mechanisms: Can't receive responses from external APIs
  • Browser Security Restrictions: PDFs can't make direct HTTP requests

Our FDF Workaround: We created a custom handler system that processes FDF data through our backend. FDF data comes in as form submissions containing action types and JSON-encoded data. The backend processes these requests and returns results in a format the PDF can display.

The Hacky Part: Since FDF can't directly call APIs, we implemented a polling mechanism where the PDF continuously submits form data to our backend, which processes the request and returns the result in a format the PDF can display. This creates the illusion of real-time interaction despite the fundamental limitations of the PDF format.

PDF JavaScript Integration

The most technically complex part is embedding JavaScript within PDFs that can communicate with our backend infrastructure.

PDF JavaScript Limitations:

  • No Fetch API: Can't make HTTP requests directly
  • Limited DOM Access: Can't manipulate web page elements
  • Security Restrictions: Sandboxed execution environment
  • Version Dependencies: Different PDF readers support different JavaScript features

Our Solution: We use Adobe's Forms JavaScript API to create interactive elements within PDFs. The JavaScript handles user interactions like button clicks, form submissions, and status updates. All communication with external services happens through FDF form submissions to our backend.

Backend Architecture

The backend serves as the bridge between PDFs and blockchain networks, handling all the complex operations that can't be performed within the PDF environment.

Key Components:

  • Handler Registry: Routes FDF actions to appropriate services
  • Blockchain Service: Direct blockchain interactions using ethers.js and viem
  • CDP Service: Coinbase Developer Platform integration
  • FERN Service: Swap functionality integration
  • PDF Account Service: MongoDB storage for PDF wallet metadata

Technical Challenges:

  • Concurrent Processing: Multiple PDFs making simultaneous requests
  • Error Handling: Graceful degradation when blockchain operations fail
  • Rate Limiting: Preventing abuse while maintaining responsiveness
  • Data Consistency: Ensuring PDF state matches blockchain state

Decentralization Through TEE (Trusted Execution Environment)

To maintain true decentralization, our backend will be implemented as a TEE (Trusted Execution Environment). This ensures that even our own infrastructure cannot access or manipulate user data or transactions.

TEE Benefits:

  • Data Privacy: User data is encrypted and only accessible within the secure enclave
  • Code Integrity: Backend logic cannot be modified without detection
  • Audit Transparency: All operations are cryptographically verifiable
  • Decentralized Trust: Users don't need to trust our infrastructure

TEE Implementation: The backend will run within Intel SGX or AMD SEV secure enclaves, ensuring that even if our servers are compromised, user data and transaction signing remain secure. This creates a truly decentralized system where the backend acts as a trusted intermediary without having access to sensitive information.

The Smart Contract Layer

We deployed custom smart contracts on Ethereum Sepolia and Ethereum Mainnet to handle PDF account creation and management.

Contract Features:

  • Account Creation: Creates new CDP accounts for PDF wallets
  • Ownership Management: Links PDF wallets to creator addresses
  • Metadata Storage: Stores PDF wallet information on-chain
  • Access Control: Ensures only authorized users can create accounts

Technical Implementation: The smart contract manages the creation and ownership of PDF accounts, storing metadata on-chain while the actual CDP accounts are managed through Coinbase's infrastructure. This hybrid approach provides the security of blockchain with the scalability of enterprise infrastructure.

Security Considerations

PDF Security:

  • No Private Keys in PDFs: All cryptographic operations happen on backend
  • Input Validation: Sanitize all user inputs before processing
  • Rate Limiting: Prevent abuse of backend services
  • Audit Logging: Track all PDF interactions for security analysis

Blockchain Security:

  • Multi-Signature Support: CDP accounts can use multi-sig for additional security
  • Transaction Monitoring: Real-time monitoring of all blockchain operations
  • Error Recovery: Graceful handling of failed transactions
  • Gas Optimization: Automatic gas estimation to prevent transaction failures

Performance Optimizations

Backend Optimizations:

  • Connection Pooling: Reuse database and blockchain connections
  • Caching: Cache frequently accessed data like account balances
  • Async Processing: Non-blocking operations for better responsiveness
  • Load Balancing: Distribute requests across multiple backend instances

PDF Optimizations:

  • Minimal JavaScript: Keep PDF file sizes small for faster loading
  • Efficient Polling: Smart polling intervals based on transaction status
  • Progressive Enhancement: Basic functionality works even with limited JavaScript support

The Integration Challenge

The biggest technical challenge was creating seamless integration between three fundamentally different systems: static PDF documents, dynamic blockchain networks, and traditional web infrastructure.

Integration Points:

  • PDF → Backend: FDF form submissions with embedded data
  • Backend → Blockchain: CDP API calls and smart contract interactions
  • Blockchain → PDF: Status updates and transaction confirmations
  • User → System: Dynamic wallet connections and transaction signing

This required careful orchestration of multiple APIs, real-time data synchronization, and robust error handling across all layers of the system.

The result is a platform where users can create a PDF wallet in seconds, send cryptocurrency transactions with a single click, and have all the complexity of blockchain technology abstracted away behind a familiar document interface, all while maintaining true decentralization through TEE technology.

background image mobile

Join the mailing list

Get the latest news and updates