export class AddFieldsFilter {
    name = 'add_fields';
    stage;
    fields;
    constructor(stage, fields) {
        this.stage = stage;
        this.fields = fields || {};
    }
    apply(input) {
        const out = JSON.parse(JSON.stringify(input || {}));
        for (const [k, v] of Object.entries(this.fields)) {
            out[k] = v;
        }
        return { ok: true, data: out };
    }
}
