Aggregate transactions merge multiple transactions into one, allowing trustless swaps, and other advanced logic. Symbol does this by generating a one-time disposable smart contract.
When all involved accounts have cosigned the AggregateTransaction, all the inner transactions are executed at the same time.
Symbol’s public network supports aggregate transaction containing up to 100 inner transactions involving up to 25 different cosignatories (as defined by the
Other aggregate transactions are not allowed as inner transactions.
An AggregateTransaction is complete when all the required participants have signed it.
The cosigners can sign the transaction without using the blockchain. Once it has all the required signatures, one of them can announce it to the network. If the inner transaction setup is valid, and there is no validation error, the transactions will get executed at the same time.
Aggregate complete transactions enable adding more transactions per block by gathering multiple inner transactions.
An AggregateTransaction is bonded when it requires signatures from other participants.
Before announcing an AggregateBondedTransaction, an account must announce and get confirmed a HashLockTransaction locking
Once an aggregate bonded is announced, it reaches partial state—where it can live up to
2 days—and notifies its status through WebSockets or HTTP API calls.
Every time a cosignatory signs the transaction and announces an aggregate bonded cosignature, the network checks if all the required cosigners have signed. When all signatures are acquired, the transaction changes to unconfirmed state until the network includes it in a block.
Dan announces an AggregateTransaction that merges two transfer transactions. Alice and Bob will receive the mosaics at the same time.
In this example, Alice is buying tickets with
When the ticket distributor cosigns the AggregateTransaction, the swap will happen atomically.
Alice sends 10
currency.euro to Bob using an app to make payments.
However, Alice doesn’t own
symbol.xym to pay the transaction fee.
By creating an AggregateBondedTransaction, Alice can convert
symbol.xym to pay the fee.
Now, Alice and Bob can use Symbol’s public blockchain without ever having to buy or hold
Since the app creator can put its own branding on the open source payment app, Alice and Bob may not even know they are using blockchain technology.
Send transactions to different accounts at the same time, using aggregate transactions.
Learn about aggregate bonded transactions creating an escrow contract.
Create a bot to cosign automatically transactions that require your account’s signature.
Cosign aggregate transactions pending to be signed.
This guide will show you how to add cosignatures to an aggregate complete transaction without using the partial cache.
Continue: Account Restrictions.
Last updated by Xavi Artigas on 2021-10-06.Did you find what you were looking for? Give us your feedback.