> For the complete documentation index, see [llms.txt](https://pangeaswap.gitbook.io/pangeaswap/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://pangeaswap.gitbook.io/pangeaswap/en/developers/contracts/core-contracts/airdropdistributor.md).

# AirdropDistributor

{% embed url="<https://github.com/pangea-protocol/pangea-core/blob/main/contracts/distribution/AirdropDistributor.sol>" %}

## Overview

For the protocol that lists tokens for the first time and creates a liquidity pool, an incentive mechanism is needed to induce many users to supply liquidity to the initial pool. To meet this demand, Pangea's pool has a built-in airdrop function. Anyone can freely add airdrop rewards to the pool to add incentives for liquidity supply. The types of airdrop rewards that can be added to the pool are **limited to the tokens constituting the pool**, and liquidity providers **receive airdrop rewards along with swap/flash loan fees**.

If you deposit airdrop rewards in `AirdropDistributor`, the rewards will start to be distributed every Thursday at 09:00 (KST, UTC+9) and be **distributed linearly for one week**. During the reward distribution period, you can receive airdrop rewards in proportion to the amount of liquidity you supplied within the pool price range.

## Methods

### airdrop

```solidity
function airdrop(address pool) external nonpayable;
```

Starts the distribution of the deposited airdrop rewards of the pool

### airdropPool

```solidity
function airdropPool(uint256 idx) external view returns (address)
```

Returns the address of airdrop pool

### airdropPoolLength

```solidity
function airdropPoolLength() external view returns (uint256)
```

Returns the number of the pools that have ever been deposited

### airdropSnapshot

```solidity
function airdropSnapshot(address pool, uint256 idx) external view returns (struct IAirdropDistributorStruct.AirdropInfo snapshot)
```

Returns the record of the past airdrop distribution

### airdropSnapshotLength

```solidity
function airdropSnapshotLength(address pool) external view returns (uint256 length)
```

Returns the number of the airdrop distribution of the pool

### depositKlay

```solidity
function depositKlay(address pool) external payable
```

Deposits KLAY to the pool. Deposited KLAY will be distributed in the next epoch

*transaction will revert if the asset in the pool is not WKLAY*

### depositToken

```solidity
function depositToken(address pool, address token, uint128 amount) external nonpayable
```

Deposits token to the pool. Deposited token will be distributed in the next epoch

*Approval (token.approve(airdropDistributor, amount)) must be performed before transaction*

### depositedAirdrop

```solidity
function depositedAirdrop(address pool) external view returns (struct IAirdropDistributorStruct.AirdropInfo)
```

Current deposited airdrop reward information of the pool. amount0 & amount1 will be zero after the airdrop allocation

## Events

### Airdrop

```solidity
event Airdrop(address indexed pool, address token0, address token1, uint128 amount0, uint128 amount1, uint256 startTime, uint256 period)
```

### Deposit

```solidity
event Deposit(address indexed pool, address token, uint256 amount, address depositor)
```
