You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: v1.1.0/get-started/bidders/best-practices.mdx
+2-4Lines changed: 2 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -61,7 +61,7 @@ Bidders will start receiving commitments instantly in most cases. If you're havi
61
61
62
62
Bidders on mev-commit need funds available in their account to submit bids, which can be obtained via bridging to your wallet address and then depositing to your node address. For testnet, you can obtain funds by using the [bridge](/v1.1.0/get-started/bridge). Once funds are deposited, the auto deposit function will automatically deposit funds into your account for the next 3 [windows](/v1.1.0/concepts/bids/bidder-deposit) to bid. Unused funds will automatically transfer into upcoming windows for bidding. You can read more about the auto deposit feature [here](https://docs.primev.xyz/v1.1.0/get-started/bidders/bidder-node-commands#autodeposit-funds).
63
63
64
-
<!--##(Optional)ProviderRPCs
64
+
{/* ## (Optional) Provider RPCs
65
65
66
66
If you don't send transaction payloads in your bid, you can send your transactions directly to block builders. Below is a table of Provider RPCs to send your transactions to on testnet. You may already be sending transactions to these providers if you have existing transaction operations.
67
67
@@ -84,6 +84,4 @@ If you don't send transaction payloads in your bid, you can send your transactio
Bidders need to deposit funds to be able to place bids on the mev-commit network. As bids are posted privately, providers cannot determine how much bidders have bid previously. To still ensure that bidders can cover all their bids, we bind deposits to specific L1 block numbers. Providers con thus ensure that bids from a given bidder do not exceed the amount deposited for the corresponding L1 block number. It is important to note that if a bidder deposits, for example, 1 ETH for some L1 block number, they can post bids totaling 1 ETH for each provider. This is because only a single provider can post the block to L1, meaning bids made to other providers will not be executed.
6
+
Bidders need to deposit funds to be able to place bids on the mev-commit network. As bids are posted privately, providers cannot determine how much bidders have bid to other providers for the relevant L1 block. To ensure that bidders can cover all their bids, we bind deposits to specific providers. Providers can thus ensure that bids from a given bidder do not exceed the amount deposited for them.
7
7
8
-
To simplify the user experience, mev-commit considers windows consisting of $\text{blocksPerWindow} = 10$ blocks and splits deposits to a window evenly over the corresponding blocks.
8
+
It is important to note that if a bidder deposits, for example, 1 ETH for every provider, they can still only post bids totaling 1 ETH for a given block. This is because only a single provider can post the block to L1, meaning bids made to other providers will not be executed.
9
9
10
-
The remaining funds of a bidder from a window (if any) can be unlocked after the corresponding blocks have been settled. The bidder can then withdraw the funds from the deposit. To further ease the user experience, bidders can enable autodeposits in their nodes, to automatically withdraw deposits from previous windows and redeposit them into future ones.
10
+
Deposited funds can be withdrawn by the bidder at any time, after waiting the ~10 minute cooldown period.
11
11
12
-
## Current window number
12
+
## Deposit Manager
13
13
14
-
The window number for a given L1 block can be calculated via the following formula, where `blocksPerWindow` is equal to 10 and `blockNumber` is the L1 block number for which the bidder wants to bid:
14
+
It's recommended that bidders leverage the _deposit manager_to deposit, and automate ongoing re-deposits to specific providers.
The deposit manager is an on-chain contract that a bidder account can enable by "setting their code" to the implementation using EIP-7702. After enabling the deposit manager, a bidder's deposits are automatically replenished from the bidder's EOA balance during the preconf settlement process, according to _target deposit_ amounts configured by the bidder.
19
17
20
-
21
-
## Minimum Deposit
22
-
23
-
Since deposits are split across $\text{blocksPerWindow} = 10$ L1 blocks, bidders have to deposit at least 10 times the amount they want to bid for a single block.
24
-
25
-
In the case of autodeposit, the deposits would be locked for around 3 windows at a time. Therefore, the total amount locked would be 30 times the amount.
26
-
27
-
## Withdrawal Time
28
-
29
-
The earliest withdrawal time can be calculated as follows: the withdrawal start time plus 20 L1 blocks (which is 240 seconds or 4 minutes) and the oracle lag of 10 L1 blocks (which is 120 seconds or 2 minutes), totaling 360 seconds or 6 minutes. Therefore, the total time before funds can be withdrawn is approximately 30 blocks (6 minutes) from the initial deposit.
30
-
31
-
## Deposit/Withdrawal Flow
32
-
33
-
<Frame>
34
-
<imgsrc="/v1.2.x/images/bidder-deposit.png" />
35
-
</Frame>
36
-
37
-
This diagram illustrates the process and timeline of bidding, settlements, and withdrawals within mev-commit system, structured around a series of windows.
38
-
39
-
### Diagram Description
40
-
41
-
#### Timeline of Blocks
42
-
43
-
- The horizontal axis represents a sequence of windows.
44
-
- Windows are labeled as `n-2`, `n-1`, `n` and `n+1`, indicating their position relative to the current window `n`.
45
-
46
-
#### Current Window
47
-
48
-
- The "Current Window" is the interval within which bidding occurs.
49
-
- The window consists of 10 L1 blocks.
50
-
51
-
#### Bidding Phase
52
-
53
-
- Bidding occurs in the current window, starting from the current block `n` and extending into the future blocks (`n+1`, etc.).
54
-
- The arrow labeled "Bidding" points to the right, indicating that bidding continues into future blocks.
55
-
56
-
#### Settlements Phase
57
-
58
-
- Settlements happen after the bidding window closes.
59
-
- The arrow labeled "Settlements" points downward, showing the transition from the bidding phase to the settlement phase.
60
-
61
-
#### Withdrawals Phase
62
-
63
-
- Withdrawals occur after settlements are completed.
64
-
- The arrow labeled "Withdrawals" points to the left, indicating the final phase where bidders can withdraw their remaining funds.
18
+
A target deposit is the desired amount of funds that a bidder wants to be deposited for a specific provider. Bidders should set this to the maximum cumulative amount of ETH they would ever bid to a provider with respect to a single L1 block.
First, retrieve the Ethereum account address of your node:
28
34
29
35
```shell
@@ -49,52 +55,124 @@ sidebarTitle: Managing Your Bidder Deposit
49
55
}
50
56
```
51
57
52
-
To add funds to your account on the mev-commit chain, you may use the [bridge](/v1.2.x/getting-started/bridge).
58
+
To add funds to your bidder EOA on the mev-commit chain, you may use the [bridge](/v1.2.x/get-started/bridge).
53
59
60
+
**Automate depositing - The easy way**
54
61
55
-
-**Adding to Your Deposit:**
62
+
It's recommended that bidders leverage the _deposit manager_to deposit, and automate ongoing re-deposits to specific providers.
56
63
57
-
To increase your deposit for the current window, use the following command, specifying the desired amount:
64
+
The deposit manager is an on-chain contract that a bidder account can enable by "setting their code" to the implementation using EIP-7702. After enabling the deposit manager, a bidder's deposits are automatically replenished from the bidder's EOA balance during the preconf settlement process, according to _target deposit_ amounts configured by the bidder.
65
+
66
+
The easiest way to enable the deposit manager is by setting two flags/environment variables upon starting your bidder node:
58
67
59
68
```shell
60
-
>curl -X POST localhost/v1/bidder/deposit/YOUR_AMOUNT | jq
To increase your deposit for the specific window, use the following command, specifying the desired amount and window number:
72
+
Where the target deposit amount will be set for all valid providers that're currently a part of the network. Alternatively you can use the `MEV_COMMIT_ENABLE_DEPOSIT_MANAGER` and `MEV_COMMIT_TARGET_DEPOSIT_AMOUNT` environment variables.
73
+
74
+
**Automate depositing - Through API**
75
+
76
+
To enable the deposit manager through API, use the following command:
64
77
65
78
```shell
66
-
> curl -X POST "localhost/v1/bidder/deposit/YOUR_AMOUNT" \
67
-
-H "Content-Type: application/json" \
68
-
-d '{
69
-
"window_number": 1
70
-
}'| jq
79
+
> curl -s -X POST http://localhost:13523/v1/bidder/enable_deposit_manager | jq
80
+
{
81
+
"success": true
82
+
}
83
+
```
84
+
85
+
Then to set target deposits customized to each provider:
Copy file name to clipboardExpand all lines: v1.2.x/get-started/bidders/best-practices.mdx
+4-4Lines changed: 4 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -57,11 +57,11 @@ The `decayStartTimestamp` and `decayEndTimestamp` are important components for h
57
57
## Troubleshooting
58
58
Bidders will start receiving commitments instantly in most cases. If you're having trouble receiving commitments, check your bid parameters and ensure your bid is high enough for the commitment you're requesting. Additionally check that you are connected to providers (via the [topology endpoint](https://docs.primev.xyz/v1.2.x/get-started/bidders/bidder-node-commands#topology)) and that you are receiving mev-commit events (via the [health endpoint](https://docs.primev.xyz/v1.2.x/get-started/bidders/bidder-node-commands#health)).
59
59
60
-
## Bidder Funds and Autodeposit Window
60
+
## Bidder Depositing
61
61
62
-
Bidders on mev-commit need funds available in their account to submit bids, which can be obtained via bridging to your wallet address and then depositing to your node address. For testnet, you can obtain funds by using the [bridge](/v1.2.x/get-started/bridge). Once funds are deposited, the auto deposit function will automatically deposit funds into your account for the next 3 [windows](/v1.2.x/concepts/bids/bidder-deposit) to bid. Unused funds will automatically transfer into upcoming windows for bidding. You can read more about the auto deposit feature[here](https://docs.primev.xyz/v1.2.x/get-started/bidders/bidder-node-commands#autodeposit-funds).
62
+
Bidders on mev-commit need to be funded with ETH which can be obtained via [bridging](/v1.2.x/get-started/bridge). Then a bidder must deposit toward one or more providers. To automate this process, the bidder can enable the deposit manager and set target deposits for each provider. Read more about the deposit manager[here](https://docs.primev.xyz/v1.2.x/get-started/bidders/bidder-node-commands#deposit-manager).
63
63
64
-
<!--##(Optional)ProviderRPCs
64
+
{/* ## (Optional) Provider RPCs
65
65
66
66
If you don't send transaction payloads in your bid, you can send your transactions directly to block builders. Below is a table of Provider RPCs to send your transactions to on testnet. You may already be sending transactions to these providers if you have existing transaction operations.
67
67
@@ -84,6 +84,6 @@ If you don't send transaction payloads in your bid, you can send your transactio
0 commit comments