# AirdropDistributor

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

## Overview

최초로 토큰을 상장하고 유동성 풀을 생성하는 프로토콜의 입장에서는 초기 풀에 많은 유저가 유동성을 공급하도록 유도할 인센티브 장치가 필요합니다. 이러한 수요를 만족하기 위해 판게아의 풀에는 에어드랍 기능이 내장되어 있습니다. 누구든 자유롭게 풀에 에어드랍 보상을 추가하여 유동성 공급에 대한 인센티브를 추가할 수 있습니다. 풀에 추가할 수 있는 에어드랍 보상의 종류는 **풀을 구성하고 있는 토큰**으로 한정되며, 유동성 공급자는 **스왑/플래시론 수수료와 함께 에어드랍 보상을 수취**하게 됩니다.&#x20;

`AirdropDistributor` 에 에어드랍 보상을 예치하면 매주 목요일 09:00(KST, UTC+9)부터 보상의 분배가 시작되어 **1주일간 선형적으로 분배**됩니다. 보상이 분배되는 기간 동안 풀 가격 구간 내에서 공급한 유동성의 크기에 비례하여 에어드랍 보상을 받을 수 있습니다.

## 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)
```


---

# 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://pangeaswap.gitbook.io/pangeaswap/developers/contracts/core-contracts/airdropdistributor.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.
