@n1k1t/mock-server
Version:
The ultimate toolkit to intercept, transform, and simulate HTTP/WS traffic with type-safe expectations
13 lines • 592 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
const models_1 = require("../models");
exports.default = models_1.EndpointFactory
.build()
.http({ method: 'GET', path: '/history/compact' })
.io({ path: 'history:compact:get-list' })
.compile(({ reply, server }) => reply.ok(server.providers
.extract()
.reduce((acc, provider) => acc.concat([...provider.storages.history.values()]), [])
.sort((a, b) => b.timestamp - a.timestamp)
.map((history) => history.toCompact())));
//# sourceMappingURL=history.compact.get-list.endpoint.js.map