EncryptedSubmitted
Event v361 → current #0Emitted when an encrypted transaction wrapper is accepted into the MEV protection queue.
View events on chainThe Big Picture
MevShield protects users from front-running by encrypting transactions until after ordering is finalized. This event confirms your encrypted submission was accepted into the queue. The next block author will decrypt and execute it, but they announced their key before seeing your submission, preventing MEV extraction.
Why This Matters
When you submit an encrypted transaction, you want confirmation it was accepted. This event tells you the submission is queued and will be processed in the next block. Watch for DecryptedExecuted or DecryptedRejected to see the final outcome.
Example Scenario
You encrypt a 500 TAO stake operation. After calling submit_encrypted, EncryptedSubmitted fires with id=0x123..., who=your_address. Your submission is now pending. In the next block, watch for DecryptedExecuted(0x123...) to confirm your stake succeeded.
Common Questions
- What's the 'id' field?
- A unique identifier (H256 hash) for this submission, computed from author, commitment, and ciphertext. Use it to track the submission through decryption.
- How long until my transaction executes?
- One block. Encrypted submissions are decrypted and executed in the immediately following block by the block author who announced the encryption key.
Use Cases
- Track your encrypted submission was accepted
- Monitor MEV protection usage across network
- Build MEV-protected trading interfaces
- Audit encrypted transaction flow
How to Use This Event
- → Subscribe to your account's submissions for confirmation
- → Monitor all submissions to track MEV protection adoption
- → Index submission IDs for decryption tracking
From Chain Metadata
Encrypted wrapper accepted.
Triggers
Emitted by
Preconditions
- NextKey available in storage
- Valid commitment hash provided
- Ciphertext in correct ML-KEM + XChaCha20-Poly1305 format
- Submission ID doesn't already exist
Effects
Storage Modified
Postconditions
- Submission stored in Submissions map
- Transaction queued for decryption in next block
Side Effects
- Increases pending submission count
- Key hash bound to submission epoch
Event Data
Code Examples
import { ApiPromise, WsProvider } from "@polkadot/api";
import { stringCamelCase } from "@polkadot/util";
const provider = new WsProvider("wss://entrypoint-finney.opentensor.ai:443");
const api = await ApiPromise.create({ provider });
// Subscribe to EncryptedSubmitted events
api.query.system.events((events) => {
events
.filter(({ event }) =>
event.section === stringCamelCase("MevShield") &&
event.method === "EncryptedSubmitted"
)
.forEach(({ event }) => {
console.log("EncryptedSubmitted:", event.data.toHuman());
});
});On-Chain Activity
Regular feature-level activity
#36 most emitted event
As of block 7,429,232
Runtime Info
View Source- Pallet Index
- 30
- Event Index
- 0
- First Version
- v361
- Current Version
- v393