# Instant Trading

Usually, when trading on-chain, every action needs a wallet signature and a network confirmation: to open a trade, close a trade, cancel etc. That’s secure, but it can feel slow and clunky, especially if you’re used to the speed of execution on centralized exchanges. Instant Trading on SYMMIO is a way to keep the same trustless backend while making the trading experience feel almost as fast as a CEX. Instead of signing every single trade, you set up a secure “session” with a solver once, and they can then execute specific actions on your behalf, within strict limits you control.

In previous versions, instant trading relied on **delegated access** through the [MultiAccount ](/contract-documentation/symmio-perps-v0.8.5/multiaccount-legacy.md)contract. You would grant a solver permission to call specific functions (like "send quote" or "close position") on your behalf. The solver could then execute trades for you without needing your wallet signature each time.

This worked, but had a trust trade-off: once you granted a solver access, they technically *could* misuse it. In practice this wasn't a concern because solvers are trusted entities, but if a solver were ever compromised, your funds could be at risk.

The Instant Layer replaces broad delegation with a more secure approach. Instead of giving a solver open-ended permission to act on your behalf, you now have two options:

#### Option 1: One-time signed actions

You sign a specific action with exact parameters "open a long on BTCUSDT at this price, this size, with this collateral"  and hand that signature to the solver. The solver bundles your signed action with their own (lock the quote, open the position) and submits everything to the contract in a single transaction. The contract verifies your signature, confirms the parameters match exactly what you signed, and executes.

In this case, the solver can only do exactly what you signed. They can't change the price, the size, or anything else. And each signature can only be used once.

#### Option 2: Session keys

For a smoother experience, the frontend generates a temporary key pair in your browser at the start of each session. You sign one transaction granting this session key permission to call specific functions on your behalf — i.e. "this key can send quotes and request closes for the next 24 hours." From that point on, all your trading actions use the session key.

This is similar to the old delegation, but with important improvements:

* **You don't need to trust the solver.** The session key is generated locally in your browser — the solver never has it.
* **Permissions are scoped.** You choose exactly which functions the key can call.
* **Permissions expire.** The session key has a built-in expiration timestamp.
* **You can revoke anytime.** There's a cooldown-based revocation process so the solver gets fair notice.

#### How it feels in practice

From your perspective as a trader, nothing changes about the UX. You click "Open" or "Close" and the trade executes almost instantly. The difference is entirely under the hood: your funds are better protected because the solver never gets broad access to your account.

When you first visit a SYMMIO frontend on v0.8.5, you'll activate "instant action mode" for your account. This is a one-time on-chain transaction. After that, the frontend builder should handle session keys automatically generating a new one each session and cleaning up old ones.

### Batched execution

One of the biggest speed improvements is that the solver can now bundle multiple actions into a single transaction. For example, when you click "Open," the solver can submit your `sendQuote`, their `lockQuote`, and their `openPosition` all at once. Previously doing these actions requirred three separate transactions. The contract processes them in order and automatically passes the quote ID from the first step to the second and third.

This means your position opens in one block instead of three, cutting latency dramatically.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.symm.io/trader-documentation/how-trading-works-in-symmio/instant-trading.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
