💡 Inspiration
In online commerce, freelancing, and digital services, standard payment receipts only prove that money moved—never whether the agreed outcome was actually delivered. When misunderstandings or fraud occur, merchants and buyers spend 14 to 30 days in manual dispute claims, costing platforms billions in chargebacks.
We built PayPal PromisePay™ to eliminate this proof-of-outcome blind spot by cryptographically binding what was promised to delayed escrow captures, multi-judge AI verification, and deterministic dispute dossiers.
🚀 What it does
PromisePay governs the entire payment lifecycle around an immutable Promise ID:
- Agreement Decomposition: Natural language project deliverables are parsed into atomic, machine-verifiable requirements.
- PPCP Delayed Escrow: Server-initiated PayPal Orders v2 (
intent: CAPTURE,disbursement_mode: DELAYED) locks funds securely in PayPal’s infrastructure, eliminating client-side price tampering. - Multi-Modal Evidence Vault: Deliverables (live web crawls, Git commits, carrier tracking scans, PDF contracts) are ingested, anti-SSRF screened, and SHA-256 hashed.
- Multi-Judge AI Consensus & DLP Shield: Google Gemini (Flash + Pro) audits deliverables with 100% prompt-injection screening and mathematical Luhn algorithm PCI-DSS card scrubbing.
- Rust Merkle Dispute Defense Dossiers: A native Rust micro-engine compiles the audit trail into an RFC 6962 SHA-256 Merkle tree formatted for PayPal Customer Disputes API v1 (
POST /v1/customer/disputes/{id}/provide-evidence) and 1-click SLA cancellation refunds.
Crucial Safety Guarantee: The AI acts strictly as an auditor and never has the authority or credentials to move money. All funds movement requires deterministic server business logic and human approval.
🛠️ How we built it
- Frontend: Next.js 15 (App Router), AG Grid Enterprise ledger with Server-Sent Events (SSE) live streaming, and
@paypal/react-paypal-js. - Backend API: FastAPI (Python 3.11+) with Redis Redlock for strict 24-hour idempotency and PostgreSQL.
- Cryptography Engine: Native Rust crate (
crates/promisepay-verify) implementing RFC 6962 Merkle tree proofs. - AI Verification: Google Gemini 2.5 Flash and Pro in multi-judge consensus with confidence clamping ($\le 0.59$ on divergence).
- Payment Platform: PayPal Commerce Platform (PPCP) delayed disbursement, Orders v2, and Disputes API v1.
🧗 Challenges we ran into
- Payment & Escrow Compliance: Ensuring fund flows adhere strictly to FinCEN and PSD2 standards by guaranteeing that AI never controls financial keys.
- LLM Non-Determinism in Auditing: Solved by implementing multi-judge consensus with rule evaluators and conservative confidence score clamping.
- Secure Evidence Ingestion: Defending against malicious inputs using a hostile injection regex firewall and Luhn credit card redaction before prompts touch the model.
🏆 Accomplishments that we're proud of
- 102 / 102 Tests Passing (100%) across backend, Rust cryptography, and financial state transitions.
- Fully functional live deployed app with official PayPal smart buttons and sandbox checkout.
- Strict Zero Non-Markdown Invariance across documentation and verification suites.
📚 What we learned
- Deep mechanics of PayPal Commerce Platform delayed disbursement flows and the Customer Disputes evidence schemas.
- High-efficiency Merkle inclusion proof compilation in Rust for legal and arbitration dossiers.
🔮 What's next for PayPal PromisePay
- Direct production integration with PayPal Resolution Center automated webhooks.
- Multi-currency cross-border milestone payouts.
Built With
- fastapi
- google-gemini
- next.js
- paypal
- postgresql
- python
- react
- rust
- sha-256
- tailwindcss