> For the complete documentation index, see [llms.txt](https://cetus-1.gitbook.io/cetus-developer-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://cetus-1.gitbook.io/cetus-developer-docs/developer/via-sdk/features-available/get-reward.md).

# Get reward

## 1. Get the position reward list of one pool

use `SDK.Pool.fetchPositionRewardList()` method

#### Function input params

* poolID: The pool object ID.
* coinTypeA: Coin A type.
* coinTypeB: Coin B type.

#### Example

```typescript
async function getRewardListOfOnePool() {
  const poolId = '0x83c101a55563b037f4cd25e5b326b26ae6537dc8048004c1408079f7578dd160'
  const pool = await TestnetSDK.Pool.getPool(poolId)
  const res = await TestnetSDK.Pool.fetchPositionRewardList({
    pool_id: pool.poolAddress,
    coinTypeA: pool.coinTypeA,
    coinTypeB: pool.coinTypeB,
  })
  console.log('retrieva reward list of one pool', res)
}

// getRewardListOfOnePool()
/*
{
    liquidity: '1178890675',
    tick_lower_index: -2,
    tick_upper_index: 2,
    reward_amount_owed_0: '0',
    reward_amount_owed_1: '0',
    reward_amount_owed_2: '0',
    reward_growth_inside_0: '0',
    reward_growth_inside_1: '0',
    reward_growth_inside_2: '0',
    fee_growth_inside_a: '0',
    fee_owed_a: '0',
    fee_growth_inside_b: '0',
    fee_owed_b: '0',
    pos_object_id: '0x88e9779719cdb9d5e722267ca2ddd0681d6c845eadfe4f6e46f9e456b26ad15e'
  },

  ...

  {
    liquidity: '496569205127',
    tick_lower_index: -6,
    tick_upper_index: 4,
    reward_amount_owed_0: '0',
    reward_amount_owed_1: '0',
    reward_amount_owed_2: '0',
    reward_growth_inside_0: '0',
    reward_growth_inside_1: '0',
    reward_growth_inside_2: '0',
    fee_growth_inside_a: '0',
    fee_owed_a: '0',
    fee_growth_inside_b: '0',
    fee_owed_b: '0',
    pos_object_id: '0x004dcb4665475ed18b3327e35cdbd6360ce1028d08bec185bafdbfb57d2ef085'
  }, 
*/
```

## 2. Get the daily reward emission info for one pool

use `sdk.Rewarder.emissionsEveryDay()` method

#### Function input params

* poolID: The pool object ID.

#### Example

```typescript
async function getRewardEmissionInfosForOnePoolEveryDay() {
  const poolObjectId = '0x83c101a55563b037f4cd25e5b326b26ae6537dc8048004c1408079f7578dd160'
  const emissionsEveryDay = await TestnetSDK.Rewarder.emissionsEveryDay(poolObjectId)
  console.log({ emissionsEveryDay })
}

// getRewardEmissionInfosForOnePoolEveryDay()
/*
{
  emissionsEveryDay: [
    {
      emissions: 86400000000,
      coin_address: '0x0588cff9a50e0eaf4cd50d337c1a36570bc1517793fd3303e1513e8ad4d2aa96::usdc::USDC'
    },
    {
      emissions: 0,
      coin_address: '0x0588cff9a50e0eaf4cd50d337c1a36570bc1517793fd3303e1513e8ad4d2aa96::usdt::USDT'
    },
    {
      emissions: 0,
      coin_address: '0x0588cff9a50e0eaf4cd50d337c1a36570bc1517793fd3303e1513e8ad4d2aa96::cetus::CETUS'
    }
  ]
}
*/
```

## 3. Get rewards of position

use `sdk.Rewarder.betchFetchPositionRewarders()` method

#### Function input params

* positionIDs: Array of position object IDs.

#### Example

```typescript
async function getPositionRewardAmount() {
  const pool = await TestnetSDK.Pool.getPool('0x83c101a55563b037f4cd25e5b326b26ae6537dc8048004c1408079f7578dd160')

  const posRewardersAmount = await TestnetSDK.Rewarder.batchFetchPositionRewarders(
    ['0xf10d37cc00bcd60f85cef3fe473ea979e3f7f3631d522618e80c876b349e56bc']
  )
  console.log({ posRewardersAmount })
}

//getPositionRewardAmount()
/*
{
  posRewardersAmount: [
      {
          amount_owed: <BN: 5592f46cb>,
          coin_address: '0x26b3bc67befc214058ca78ea9a2690298d731a2d4309485ec3d40198063c4abc::usdc::USDC'
      },
      {
          amount_owed: <BN: 1db694dea>,
          coin_address: '0x26b3bc67befc214058ca78ea9a2690298d731a2d4309485ec3d40198063c4abc::usdt::USDT'
      },
      {
          amount_owed: <BN: 5cda9137bcc>,
          coin_address: '0x26b3bc67befc214058ca78ea9a2690298d731a2d4309485ec3d40198063c4abc::cetus::CETUS'
      }
  ]
}
*/
```


---

# 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 dynamically by asking a question.

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

```
GET https://cetus-1.gitbook.io/cetus-developer-docs/developer/via-sdk/features-available/get-reward.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
