You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Proposal for More Granular Transaction Processing in Chain Classes
Currently, the Chain Classes interface in multichain-tools only supports calling handleTransaction. The process should be more granular, allowing the caller to interact with intermediate transaction states. Below is the proposed interface:
Chain.attachProperties(tx): tx // Fetch all the necessary online information. All subsequent steps should be able to be performed on-chain (offline).
Chain.serializeAndHash(tx): hashedTx // Should be able to be performed on-chain (offline).
Chain.parseSignature(mpcSignature): chainSignature // Parses the rsvSignature and returns the chain-specific signature.
Chain.broadcastTx(signedTx): txHash // Broadcasts the transaction.
Chain Properties
async sign(txHash): mpcSignature // Provides enough information for the caller to sign using a wallet or local signer.
async offlineSigner(offlineDataReady): void // Provides enough information for the caller to use their own smart contract to generate the signature. All the data that include web requests should have been done before this function it's called.
Contract Methods
Contract.getPublicKey(contractId): mpcPublicKey
Contract.getCurrentFee(contractId): currentFee
Contract.sign(hashedTx): rsvSignature
Goal
The goal of this proposal is to provide more granularity in transaction state management for signing.
It should enable users to access two key stages of the transaction:
A transaction ready to be signed by a wallet, either via signDelegate or a prepared transaction.
A transaction ready to be sent to a smart contract (offline), including all necessary data, allowing the contract to handle offline preparations, sign, and return the signature.
The text was updated successfully, but these errors were encountered:
Proposal for More Granular Transaction Processing in Chain Classes
Currently, the Chain Classes interface in multichain-tools only supports calling handleTransaction. The process should be more granular, allowing the caller to interact with intermediate transaction states. Below is the proposed interface:
Chain Class Methods
Chain Properties
Contract Methods
Goal
The goal of this proposal is to provide more granularity in transaction state management for signing.
It should enable users to access two key stages of the transaction:
The text was updated successfully, but these errors were encountered: