protofsm: add option to allow conf resp to return full back

In this commit, we add an option to allow a conf req caller to receive
the full block. This is useful if the caller wants to be able to create
an SPV proof.
This commit is contained in:
Olaoluwa Osuntokun committed 2025-06-03 16:39:48 -07:00
1 parent a8930773a4
commit 4908d76653
2 files changed
+11 -1

No files matched your search

+5
View File
@@ -116,6 +116,11 @@ type RegisterConf[Event any] struct {
// transaction needs to dispatch an event.
NumConfs fn.Option[uint32]
// FullBlock is a boolean that indicates whether we want the full block
// in the returned response. This is useful if callers want to create an
// SPV proof for the transaction post conf.
FullBlock bool
// PostConfMapper is a special conf mapper, that if present, will be
// used to map the protofsm confirmation event to a custom event.
PostConfMapper fn.Option[ConfMapper[Event]]