Zypher Trade
Private perp trade
Awards
The problem it solves
Privacy and private transactions are paramount in financial and capital markets. Traditional DeFi perpetual trading platforms require users to connect wallets and expose their on-chain identity, creating a permanent link between their trading activity and public addresses.
Zypher Trade solves this by marrying Zcash’s shielded transaction technology with decentralized perpetual trading on Hyperliquid.
All users need to do is send Zcash (ZEC) to a single address with a memo containing their trading instructions - that’s it. No wallet connections, no KYC, no on-chain identity exposure. The platform:
Receives shielded ZEC deposits with JSON-encoded trading instructions in the memo field Swaps ZEC → USDC via Near Intent cross-chain swaps Executes leveraged perp trades on Hyperliquid Auto-closes positions and returns profits as ZEC to the user’s shielded address This creates a truly private DeFi trading experience where your financial activity remains completely shielded.
Challenges we ran into
1. Zcash Node Synchronization & Connectivity Challenge: Setting up and syncing the Zcash node (migrating from zcashd to Zebra) proved extremely challenging. Initial connection issues prevented block downloads, and syncing to mainnet took considerable time.
Solution: We containerized the infrastructure using Docker, configured lightwalletd for efficient transaction monitoring, and implemented robust retry mechanisms in the LightwalletdService to handle network interruptions gracefully.
2. Real-time Transaction Monitoring Challenge: Detecting incoming Zcash deposits in real-time, including mempool transactions before confirmation, required careful orchestration to avoid duplicates while ensuring no transactions were missed.
Solution: Built a custom polling service that monitors both confirmed blocks and mempool, using Redis to track processed transaction IDs and last scanned heights for resumability.
3. Cross-Chain Swap Integration Challenge: Integrating ZEC ↔ USDC swaps was complex. We initially explored SwapKit/THORChain but encountered “swap halted” errors, requiring us to pivot to Near Intent’s OneClick SDK.
Solution: Implemented a flexible SwapService with proper intent creation, status polling, and timeout handling. Added refund mechanisms to return funds to users if swaps fail.
4. Hyperliquid API Stability Challenge: The Hyperliquid SDK threw HyperliquidAPIError: No response received from server during initialization and WebSocket processing, causing unhandled promise rejections and application crashes.
Solution: Wrapped SDK calls with comprehensive error handling, implemented exponential backoff retries, and added graceful degradation so the application continues running even during API outages.
5. Temporal Workflow Reliability Challenge: Orchestrating the complex multi-step deposit→swap→bridge→trade flow with proper error handling, retries, and state management was difficult. “Failed to start deposit workflow” errors appeared intermittently.
Solution: Leveraged Temporal’s durable execution guarantees, configured appropriate timeouts and retry policies, and implemented proper activity separation for each step of the flow.
6. Bridging USDC to Hyperliquid Challenge: After swapping ZEC to USDC on Arbitrum, bridging funds to Hyperliquid’s L1 for perp trading required tracking balance changes and implementing polling with timeouts.
Solution: Implemented balance polling loops in workflows with configurable timeout periods, ensuring funds are confirmed on Hyperliquid before trade execution.
7. Memo Parsing & Instruction Validation Challenge: The entire user experience depends on correctly parsing JSON memos from Zcash transactions. Malformed memos or unsupported instructions needed graceful handling.
Solution: Implemented schema validation for memo parsing with clear error responses and refund mechanisms for invalid instructions.