Expand description
Bitcoin OTS anchor loop.
Periodically submits the current tree head to multiple
OpenTimestamps calendar servers. The OTS proofs are stored in
the database and served via GET /v1/head/<N>/ots.
ยงFrequency
Every 10 minutes by default. OTS aggregation means the per-batch Bitcoin cost is amortized across many log submitters; the actual on-chain footprint is one OP_RETURN per calendar per hour.
ยงCalendar servers
The default set mirrors what opentimestamps-client ships:
https://a.pool.opentimestamps.orghttps://b.pool.opentimestamps.orghttps://a.eternity.collegehttps://ots.btc.cat
A calendar failure is non-fatal โ the anchor proceeds with whichever calendars respond.
Functionsยง
- anchor_
once ๐ - One anchor cycle: snapshot the current tree head, submit to OTS calendars, store the result. Returns Ok if at least one calendar accepted.
- build_
placeholder_ ๐proof - Build a placeholder OTS proof for testing. The real implementation would parse the calendar server responses and assemble the proof per the OTS wire format (RFC opentimestamps).
- run_
anchor_ loop - Run the OTS anchor loop in the background. Submits the current tree root to calendar servers at the configured interval.