Request Withdraw

Overview

Users that have a fresh recipient address with no gas will need to request their withdraw to be executed by a relayer on their behalf. You offer the relayers a fee. Relayers are free to ignore a fee offer that is too small.

If your recipient address already has plenty of gas to call withdraw and do any subsequent actions that you want, you do not need to request a withdraw and can see User Withdraw.

Request Withdraw for PulseChain

Gas & Fee

TL;DR - Using around ~0.3% relayer fee is fine for the "Fee (%)" field. If you need gas for the road for your fresh recipient, 10,000 PLS is a great starting amount to request for the "Gas" field.

Gas = Gas for the road for you, given to you by the relayer during withdraw execution.

If you are in this section, your recipient address has no gas. Even after it gets a PRC20 withdraw, it will have no PLS to perform any actions. Therefore, you can set the gas value to a non-zero value if you need/want extra gas sent to you during the withdraw execution. You should set this gas value to 0 for PLS withdraws (since you'll have plenty of gas once the withdraw is finished).

Fee = Your offered fee given to the relayer (deducted from your deposit amount) to pay for all their expenses.

A relayer has two main expenses:

  1. Gas cost of calling withdraw() for you.

  2. Any gas for the road value that you specified.

Your fee offer needs to cover both of these at a bare minimum, otherwise it's highly likely your withdraw request will be IGNORED by relayers.

If your withdraw request offer is being ignored by relayers, you can request another offer with a higher relayer fee. You can make multiple requests, but relayers will only fulfill your best offer.

A higher fee offer will likely increase fulfillment chance, and the speed of the fulfillment.

As a general rule of thumb, entering a fee from 0.1%-0.3% should be enough for a relayer to fulfill your withdraw request, as long as your input Gas value is reasonable (less than around 50,000 or 100,000 PLS).

Generally:

  • The larger your deposit size the smaller you can make your fee offer.

  • The larger your requested gas amount, the higher your fee offer should be.

Example

You request a withdraw for 1M pHEX and 20,000 PLS gas for the road. Assume 1 pHEX = 100 PLS for simplicity, and assume it costs 3,000 PLS to call withdraw() .

You need to think of a sufficient fee offer so a relayer fulfills your request because it's worthwhile.

Total Relayer costs = 20,000 + 3,000 = 23,000 PLS.

(1,000,000 pHEX * X%) * (100 PLS/ 1 pHEX) = 23,000PLS

100,000,000 PLS * X% = 23,000 PLS

X% = 2.3/10000 = 0.023%.

The percentage decimals can only be the nearest hundredth, so 0.03% would be the minimum fee for a relayer to profit from your request and even consider. You'd likely want to go higher than this.

In reality, relayers may never bother accepting any requests below 0.1%, 0.2%, or even 0.3%, because anything below is too small of a margin.

Request Withdraw Button

Clicking the Request Withdraw button does not call any contract function and does not require gas.

It checks that your nullifier is valid and publishes your public proof data as a JSON object to t.me/pulseinprivate where relayers listen to fulfill withdraw requests.

Note: When you enter your nullifier value client side, this is only kept client side and used to generate a valid proof for your deposit, and is never exposed in the public proof data. Only the hash of the nullifier is ever exposed, which keeps your deposit safe.

Last updated