Aeon SDK: Operational Flows
This section describes how an application using the Aeon SDK (AeonClient and AeonSigner) automates interactions and operations.
Operational Flows
Creating a Workspace This is currently handled via the Aeon platform’s frontend. We will expose an SDK interface for this in the future. Adding an API User- Your application generates an EVM compatible private key and stores it securely.
- In the Aeon platform’s frontend, an administrator adds a User using the corresponding EVM address associated with the generated private key.
- Upon approval of the config request in the frontend, a capability is associated with the EVM address, making it redeemable.
- Your application initializes an
AeonSignerinstance with the EVM private key. (See AeonSigner Constructor for initialization). - Your application calls
aeonSigner.signAcceptWorkspaceMessage(workspaceId)to generate a signature for the workspace invitation. - Then, your application calls
aeonClient.acceptWorkspaceInvite(signedMessage)using the signature from the previous step. This queues the operation. - The transaction for accepting the invite is then executed by calling
aeonClient.build()and thenaeonSigner.signAndExecuteAeonTx(txbFromBuild). - The end-user (owner of the workspace/keys) receives a request on their device to share their key shares with the AeonSigner’s public key.
- Once the user approves and shares, your application calls
aeonSigner.acceptPendingUserShares(workspaceId)to detect, validate, and integrate these shares. (See acceptPendingUserShares()).
- Define and Simulate Operations with
AeonClient:- Your application uses
AeonClientto define one or more transaction operations. - Call methods
aeonClient.simulate("evm", params),aeonClient.simulate("sui", params), for each part of the desired transaction. (See specific simulation docs under AeonClient Request for details). - The
AeonClient.build()method is then called:
- Your application uses
- Sign Locally with
AeonSignerand Execute:- The
assembledTxData.txb(the unsigned transaction block) is passed toAeonSigner. AeonSignersigns the TXB (await aeonSigner.signAndExecuteAeonTx(txb)). The signed TXB is sent to Aeon’s backend for gas sponsoring and execution.
- The
- Prepare Transaction with
AeonClientfor Server-Side Adjustments:- Your application uses
AeonClientto request signing preparation for a specific chain, for example,aeonClient.prepareTransactionForSigning(params). - The
AeonClient.build()method is called. The backend service performs these actions:- Estimates gas fees.
- Gets the correct nonce (if applicable).
- Performs other necessary preparations based on the chain.
- Returns a serialized, unsigned transaction ready for signing.
- Your application uses
- Sign prepareSigning Aeon Tx Locally with
AeonSignerand Execute:- The
assembledTxData.txb(the unsigned transaction block) is passed toAeonSigner. AeonSignersigns the TXB (await aeonSigner.signAndExecuteAeonTx(txb)). The signed TXB is sent to Aeon’s backend for gas sponsoring and execution.
- The
- MPC signing:
- The
AeonSignerparticipates in the distributed signature generation process using its locally managed key share. - Your application calls
aeonSigner.signWithUserShare(hashedMessages_b64, signatureScheme). (SeesignWithUserShare()for more details). - The method returns the user’s signature contribution (
signature_b64). - After signing is completed, the resulting signature is broadcast on the Ika network, is picked up by our backend service and submitted to chain. We will add a guide in the future how to host this relay yourself.
- The