> For the complete documentation index, see [llms.txt](https://docs.metanovaverse.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.metanovaverse.com/protocol-developers/modules/vesting/antehandlers.md).

# AnteHandlers

The `x/vesting` module provides `AnteDecorator`s that are recursively chained together into a single [`Antehandler`](https://github.com/cosmos/cosmos-sdk/blob/v0.43.0-alpha1/docs/architecture/adr-010-modular-antehandler.md). These decorators perform basic validity checks on an Ethereum or SDK transaction, such that it could be thrown out of the transaction Mempool.

Note that the `AnteHandler` is called on both `CheckTx` and `DeliverTx`, as Tendermint proposers presently have the ability to include in their proposed block transactions that fail `CheckTx`.

### Decorators <a href="#decorators" id="decorators"></a>

The following decorators implement the vesting logic for token delegation and performing EVM transactions.

#### `VestingDelegationDecorator` <a href="#vestingdelegationdecorator" id="vestingdelegationdecorator"></a>

Validates if a transaction contains a staking delegation of unvested coins. This AnteHandler decorator will fail if:

* the message is not a `MsgDelegate`
* sender account cannot be found
* sender account is not a `ClawbackVestingAccount`
* the bond amount is greater than the coins already vested

#### `EthVestingTransactionDecorator` <a href="#ethvestingtransactiondecorator" id="ethvestingtransactiondecorator"></a>

Validates if a clawback vesting account is permitted to perform Ethereum transactions, based on if it has its vesting schedule has surpassed the vesting cliff and first lockup period. This AnteHandler decorator will fail if:

* the message is not a `MsgEthereumTx`
* sender account cannot be found
* sender account is not a `ClawbackVestingAccount`
* block time is before surpassing vesting cliff end (with zero vested coins) AND
* block time is before surpassing all lockup periods (with non-zero locked coins)


---

# 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://docs.metanovaverse.com/protocol-developers/modules/vesting/antehandlers.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.
