xero-mcp
Version:
A Model Context Protocol server allows Clients to interact with Xero
18 lines (17 loc) • 473 B
JavaScript
class AuditLog {
records = [];
record(name) {
const time = Date.now();
console.error(`${name} at ${new Date(time).toISOString()}`);
this.records.push({ name, time });
if (this.records.length > 200) {
this.records.shift();
}
}
lastRecordTime() {
return this.records.length > 0
? this.records[this.records.length - 1].time
: 0;
}
}
export const Auditor = new AuditLog();