Overview
How delivery works
How events are detected, filtered, signed, confirmed, and retried on their way to your URL.
Overview
Every event goes through the same steps:
One transaction can produce several events, for example a coin transfer and a token transfer. Each one is filtered and sent on its own.
Seen, then confirmed
A transaction can be seen in a new block and then dropped if the chain reorganizes. Gray3 handles this with two messages that share the same id:
confirmed: falseas soon as the transaction is in a block. Use it for fast UI feedback.confirmed: trueonce the block has the network's confirmation depth, for example 6 blocks on Ethereum. Use it to move money or credit balances.
If a block is replaced before it confirms, the confirmed message for that transaction never arrives. Treat an unconfirmed message as pending, never as final. See Unconfirmed and confirmed messages.
Ordering and duplicates
Messages usually arrive in block order, but retries can make an older message arrive after a newer one. A message may also arrive more than once, for example when your server handled it but the reply timed out. Store each id together with confirmed, and skip pairs you have already processed. The id is unique per watched address, so if two of your addresses are in the same transfer you get two messages with different IDs. See Process each event once.
Quiet addresses switch off
To keep your list lean, an address with no activity for 30 days is switched off and stops receiving events. You can switch it back on for free at any time. See Switched-off addresses.