> 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-v2/sdk-modules/cetusprotocol-farms-sdk/contract-error-codes.md).

# Contract Error Codes

the Cetus smart contract may return the following error codes:

<table><thead><tr><th width="177.9656982421875">Module</th><th width="96.6656494140625">Error Code</th><th width="237.9544677734375">Description</th><th width="232.06689453125">Contract Methods</th></tr></thead><tbody><tr><td>stable_farming::pool</td><td>1</td><td>Invalid CLMM Pool ID</td><td>collect_clmm_reward, collect_fee</td></tr><tr><td>stable_farming::pool</td><td>2</td><td>Pool Position Not Match</td><td>remove_liquidity, deposit，withdraw，harvest ，add_liquidity，add_liquidity_fix_coin</td></tr><tr><td>stable_farming::pool</td><td>3</td><td>Pool CLMM Pool Not Match</td><td>remove_liquidity, add_liquidity ，add_liquidity_fix_coin</td></tr><tr><td>stable_farming::pool</td><td>4</td><td>Rewarder Not Harvested</td><td>withdraw，</td></tr><tr><td>stable_farming::pool</td><td>5</td><td>Effective Range Error</td><td>check_effective_range</td></tr><tr><td>stable_farming::pool</td><td>6</td><td>Rewarder Not Exists</td><td>harvest</td></tr><tr><td>stable_farming::pool</td><td>7</td><td>Rewarder Already Exists</td><td>add_rewarder</td></tr><tr><td>stable_farming::pool</td><td>8</td><td>Pool Has No Rewarder</td><td>deposit</td></tr><tr><td>stable_farming::pool</td><td>9</td><td>Start Error</td><td>update_effective_tick_range</td></tr><tr><td>stable_farming::pool</td><td>10</td><td>Invalid Tick Range</td><td>calculate_position_share</td></tr><tr><td>stable_farming::pool</td><td>11</td><td>Invalid Sqrt Price</td><td>calculate_position_share</td></tr><tr><td>stable_farming::pool</td><td>12</td><td>Amount In Above Max Limit</td><td>add_liquidity_fix_coin_to_clmm，add_liquidity_to_clmm</td></tr><tr><td>stable_farming::pool</td><td>15</td><td>Amount Out Below Min Limit</td><td>remove_liquidity_from_clmm</td></tr></tbody></table>


---

# 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-v2/sdk-modules/cetusprotocol-farms-sdk/contract-error-codes.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.
