Build

Record enough context to retry, correct and export.

Every retry, import and correction asks the same question: did the system preserve the event, or invent a second one? Start by separating temporary player state from durable history.

Start with the event boundary

Decide which input is temporary player state, which input updates progress and which input creates durable history. Do not rely on the transport endpoint to define the domain event.

Preserve five facts

  1. Event identity: a stable identifier for the durable record.
  2. Media context: the work or unit known by the source.
  3. Represented time: playback, diary or completion time, named explicitly.
  4. Native progress: value, unit and denominator when one exists.
  5. Provenance: manual entry, player, import, webhook, correction or sync.

Design correction before synchronization

Users need to fix a wrong title, timestamp or duplicate before the record is copied elsewhere. Exports should preserve corrections and deletions instead of requiring a false replacement event.

Test the failure path

Retry the same logical event. Deliver events out of order. Interrupt an import. Apply a remote update while local progress is dirty. Verify that the final history remains explainable.

Review the draft principles. Add a sourced implementation note to Scrobble.dev, or contribute a reproducible software case to Floppy.