User path

The following scenario may help you understand how zSwap works in a practical setting:

  • Alice wants to swap her ETH for USDC. As a privacy-conscious user, she already holds her ETH as zETH within Panther Protocol (ETH deposited into a Shielded Pool). This grants her access to the privacy-preserving functionalities of zSwap.

  • Alice connects her wallet to Panther and navigates to the Swap page on the Panther dApp’s interface.

  • Alice navigates to the left side of the UI and chooses the selling token and an amount based on her historical deposits (for example, zETH). She then chooses the receivable token (for example, zUSDC.

  • zSwap automatically calculates the exchange rate between the sellable and receivable asset (e.g. 1750 zUSDC per 1 zETH) according to real-time market data from DEXs.

  • zSwap will automatically display the best swapping route identified and the details of the swap. Alice can choose to expand the list of DEX routing options to compare the costs of using a different DEX and select it if she decides to do so.

  • After Alice finds a preferred option among all the DEX options available, she executes the transaction by pressing the Swap button.

  • The DeFi Adaptor generates a unique hashed time-locked contract (HTLC) for this atomic swap.

  • During the swap process, Panther user reveals their secret keys within the predefined time limit, allowing the DeFi Adaptor to execute the atomic swap. This process preserves her privacy, as Panther’s user identity and transaction details remain shielded within the Pool.

  • Once her transaction goes through, the newly deposited asset (in our example, USDC) is delivered to Alice as a zUSDC. Alice also gets rewarded for conducting a transaction on zSwap through Privacy Reward Points (PRPs), which reward users for increasing the anonymity rate of the Panther ecosystem. Should there be an issue that causes the transaction to fail at any step of the way, Alice’s asset balance would remain unchanged.

Last updated