There's some great examples of how to use subxt to listen to all events.
Polkadot-js events screen seem to show events grouped by the extrinsic that created them. Can I do the same in rust?
(if not subxt is there an alternative way?)
Substrate and Polkadot Stack Exchange is a question and answer site for developers building blockchains with the Substrate SDK. It only takes a minute to sign up.Sign up to join this community
The logic in subxt will map through in a similar way.
So the way to map it is -
ApplyExtrinsic, it doesn't map to a transaction, e.g. it is a system event
ApplyExtrinsic, get the index from this value