> For the complete documentation index, see [llms.txt](https://docs.peach.ag/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.peach.ag/documentation/arc/aggregator/core-features/slippage.md).

# Slippage

Display the signed minimum net output and preserve the accepted transaction through execution.

### Slippage tolerance

Slippage is the difference between the quoted and executed outcome as market conditions change. Price impact describes how the trade itself affects the price through available liquidity. A slippage limit does not bound price impact, remove trading fees or guarantee a successful transaction.

The SDK’s `slippageBps` is an integer from 0 to 9999, with a default of 50. Pass it in the `swap` or `prepareDelegatedSwap` request, then display and confirm the returned terms.

| Tolerance          | `slippageBps` |
| ------------------ | ------------- |
| 0.1%               | 10            |
| 0.5% (SDK default) | 50            |
| 1%                 | 100           |

A lower tolerance allows less deterioration but can cause more reverts. A higher tolerance permits worse execution. Let users make that choice explicitly; do not raise it automatically after a failure. The SDK default is not a recommendation for every token or market.

### Minimum net output

Apply the tolerance after the aggregator custom fee. Underlying pool, curve and Hook fees are already reflected in the route output. All amounts are token base units; calculate with `bigint` and round down at each division.

```ts
const grossOutput = 1003n;
const customFeeBps = 333n;
const slippageBps = 50n;
const customFee = grossOutput * customFeeBps / 10000n; // 33
const expectedNetOutput = grossOutput - customFee; // 970
const minimumNetOutput = expectedNetOutput * (10000n - slippageBps) / 10000n; // 965
```

For this example the expected net output is 970 units and the minimum is 965. At small amounts, rounding by one base unit can materially affect the displayed percentage; always show the minimum in token units as well as the chosen tolerance. Fees and tolerance are separate settings; see [Fees](https://docs.peach.ag/documentation/arc/aggregator/core-features/custom-fee-and-slippage) for the current fee policy and allocation.

### Preserve the confirmed result

The quote and signed minimum returned by `swap()` belong to the same transaction. Display `prepared.expectAmountOut`, `prepared.tx.amountOutMin`, recipient and fee terms before confirmation. Submit that accepted result without another quote request.

For delegated swaps, show `prepared.expectAmountOut` and `BigInt(prepared.raw.amount_out_min)` from `prepareDelegatedSwap()` before the payer signs. The SDK validates the built transaction against these prepared terms. Retain the full prepared object unchanged through signing and build.

A new result can have different amounts even with the same tolerance. If the plan expires, call `swap()` again (or prepare and sign again for delegated execution), display the replacement terms and obtain new acceptance. Do not silently replace a confirmed plan or lower its minimum.

Invalidate confirmation whenever tokens, amount, accounts, recipient, network, routing, fees or tolerance change. Never rewrite signed calldata.

### Amount direction

Arc Aggregator currently supports fixed-input swaps only. The input amount stays fixed, while the slippage limit protects the minimum output the user receives.

### Failure and settlement

A minimum-output failure stops the swap; a reverted on-chain transaction can still consume gas. Refresh the quote and let the user reconsider the trade. If submission timed out, resolve the existing transaction before retrying.

The minimum is a lower bound, not the amount guaranteed to be received. Show the actual output after a successful receipt, keeping expected output, minimum output and settled output distinct. See [Transaction Safety](https://docs.peach.ag/documentation/arc/aggregator/core-features/validation-approvals-and-expiry) for validation, expiry and receipt handling.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

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

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.peach.ag/documentation/arc/aggregator/core-features/slippage.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
