Skip to main content

Aeon SDK: Architectural Overview

This document provides a comprehensive overview of the Aeon SDK, its core components (AeonClient and AeonSigner), how to get started, and how it interacts with backend services for advanced functionalities like transaction simulation and DApp interactions. For a higher-level overview of how Aeon empowers builders, see the Why Aeon for Builders? section.

Installation

npm install @aeon-protocol/aeon-sdk
# or
yarn add @aeon-protocol/aeon-sdk

Aeon SDK Core Components

The Aeon SDK provides developers with a comprehensive toolkit to interact with various blockchain networks and services offered by Aeon. It simplifies common tasks such as transaction simulation, preparation, signing, and execution, as well as interactions with DApps. The SDK is designed with two primary components in mind:
  • AeonClient: Responsible for defining a sequence of workspace transaction operations. It allows you to synchronously queue up aeon Tx requests with their involved async fetches (e.g. running tx simulation for various chains). These requests are then processed by a build() method, which asynchronously executes the fetch operations, gathers results, and assembles a final aeon transaction block (TXB). AeonClient internally manages this queue of operations and the construction of the transaction, enabling chainable calls.
  • AeonSigner: Focused solely on cryptographic signing operations. It allows signing of prepared transaction data (the TXB output from AeonClient.build()) as well as signing with the MPC shares. Detailed reference for AeonSigner methods can be found in the AeonSigner Methods Reference.

Key Features

  • Cross-chain compatibility
  • Transaction simulation and gas estimation (powered by backend services called by AeonClient)
  • Secure transaction signing (via AeonSigner)
  • Robust error handling

General Error Handling for the SDK

Errors will be instances of a custom AeonError class, providing more context about what went wrong.