Decodes a Sandcorn ID into its components
The Sandcorn ID to decode
Object containing the timestamp, machine ID, and sequence number
const id = generateId();const { tick, machineId, seq } = decodeSandcorn(id);print(`This ID was generated:`);print(`- On computer #${machineId}`);print(`- At hour ${tick} since epoch`);print(`- Was ID #${seq} that hour`); Copy
const id = generateId();const { tick, machineId, seq } = decodeSandcorn(id);print(`This ID was generated:`);print(`- On computer #${machineId}`);print(`- At hour ${tick} since epoch`);print(`- Was ID #${seq} that hour`);
Decodes a Sandcorn ID into its components