> ## Documentation Index
> Fetch the complete documentation index at: https://www.diadata.org/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Slippage Calculation (for Uniswap V2 and its forks)

> To predict the amount of tokens required to reach a specified slippage, you can use `Pool Slippage` endpoint. It works for any pool that exists on Uniswap V2 or any fork DEX on supported list of exchanges.

<Card title="Here is an exemplary API call" href="https://api.diadata.org/v1/poolSlippage/Ethereum/0xb4e16d0168e52d35cacd2c6185b44281ec28c9dc/0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48/UniswapV2/100" icon="angle-right" horizontal>
  [https://api.diadata.org/v1/poolSlippage/Ethereum/0xb4e16d0168e52d35cacd2c6185b44281ec28c9dc/0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48/UniswapV2/100](https://api.diadata.org/v1/poolSlippage/Ethereum/0xb4e16d0168e52d35cacd2c6185b44281ec28c9dc/0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48/UniswapV2/100)
</Card>

The logic is as follows:

Provide the address of the pool, select a token in which you wish to have slippage calculated (e.g. if selected ETH from ETH-USDC, it will show how much is ETH is required to move the price by selected amount) and determine the goal for price movement.

## Path Parameters

<ParamField path=":blockchain" type="string" required>
  Name of the blockchain of the requested pool (e.g. Ethereum, Moonbeam, etc.)
</ParamField>

<ParamField path=":pool_address" type="string" required>
  Address of the requested pool
</ParamField>

<ParamField path=":token1_address" type="string" required>
  Address of either of the tokens in the pool
</ParamField>

<ParamField path=":pool_type" type="string" required>
  Type of the pool (e.g. UniswapV2)
</ParamField>

<ParamField path=":desired_slippage" type="integer" required>
  Desired slippage in per mille (e.g. 100 will result in 10% slippage)
</ParamField>

<ResponseExample>
  ```json 200: OK theme={"system"}
  {
    // Response
  }
  ```
</ResponseExample>
