๐Ÿš€Intent Encoding

The user intent structure consists of 3 parts: sender, intentData and signature. The data structure is defined as follows:-

struct UserIntent {

address sender;

bytes[] intentData;

bytes signature;

}

Definitions:

  • sender: The user sending the intent request.

  • intentData: Standardized intent data.

  • signature: The userโ€™s signature on the intent data.

Although the userโ€™s intent is parsed and resolved by the Solver on the target chain, the Solver is a service running off-chain that can access the userโ€™s intent by reading it on the source chain. Therefore, the userโ€™s intent does not actually need to be transferred to the target chain, which helps reduce the time and cost of on-chain confirmations. Additionally, in this protocol, the intent itself does not need to be parsed by smart contracts, so it can be stored through encoding and compression, thereby reducing on-chain storage costs.

Last updated