Keep-going: tree shares, health flags, CI, compose, timestamp Zapier action

Directory-tree encrypted share mock; /health reports mockVerae/nats;
middleware OpenAPI extended; zappier receipt by jobId; activate Create
Timestamp (local mock or hosted); GitHub Actions test:offline; compose
builds zappier image; seed-demo.mjs.

No Zapier login or live Verae required.
This commit is contained in:
George Lambert 2026-09-09 03:02:08 -04:00
parent 645a24909a
commit 5925e76c72
39 changed files with 514 additions and 33 deletions

View file

@ -101,6 +101,7 @@ export function buildApp(deps: AppDeps = {}): {
string,
{ jobId: string; sha256: string; data?: string; timestamp: string }
>();
const jobIndex = new Map<string, { jobId: string; sha256: string; data?: string; timestamp: string }>();
const app = express();
app.use(express.json());
@ -177,10 +178,29 @@ export function buildApp(deps: AppDeps = {}): {
}
const jobId = randomUUID();
const timestamp = new Date().toISOString();
hashIndex.set(sha256, { jobId, sha256, data, timestamp });
const rec = { jobId, sha256, data, timestamp };
hashIndex.set(sha256, rec);
jobIndex.set(jobId, rec);
res.status(202).json({ jobId, sha256, existing: false, timestamp });
});
app.get('/v1/receipts/:jobId', meter('receipt', usage, pricing), (req, res) => {
const rec = jobIndex.get(String(req.params.jobId));
if (!rec) {
res.status(404).json({ error: 'Job not found' });
return;
}
res.json({
type: 'verae.retrieval-receipt',
format: 'json',
jobId: rec.jobId,
sha256: rec.sha256,
timestamp: rec.timestamp,
extraSeal: { event: 'document.retrieved', retrievedAt: new Date().toISOString() },
quote: res.locals.quote,
});
});
app.get('/v1/hashes/:sha256', meter('hash-lookup', usage, pricing), (req, res) => {
const sha256 = String(req.params.sha256 || '').toLowerCase();
const rec = hashIndex.get(sha256);