// Example of queuing a transaction signing preparation
const aeonClient = new AeonClient({ simulationUrl: "..." }); // Backend URL for prepareSigning services
const transactionIdToPrepare = "existing-tx-intent-id-123";
const currentWorkspace = "workspace-main-ops";
aeonClient.prepareSigning({
txId: transactionIdToPrepare,
workspaceId: currentWorkspace,
});
// Optionally, chain other operations if needed
// .simulate("evm", { ... }) // etc.
// Later, to process the queue and get the signable transaction data:
// async function getPreparedTransaction() {
// const buildResult = await aeonClient.build();
// // The buildResult will contain outputs for each queued operation.
// // You'll need to find the output corresponding to the prepareSigning call.
// // Assuming buildResult.outputs is an array in order of queuing:
// const preparedTxData = buildResult.outputs[0]; // Or find by a unique ID if available
// if (preparedTxData && preparedTxData.type === "PREPARED_SIGNING_DATA") { // Hypothetical type
// const txbToSign = preparedTxData.payload.txb_serialized_b64; // Example structure
// console.log("Transaction ready for signing:", txbToSign);
// return txbToSign;
// } else {
// console.error("Could not find prepared signing data in build result.");
// }
// }