type t = {mutable paused: bool}
let cancel: t => unit
let onEnd: (t, unit => unit) => unit
let then: (t, unit => unit) => t