import { ChoiceRequest } from "../models"; import { StepResult } from "./stepResult"; export interface Step { /** * Step job. * If the step wants to exclude a campaign, it should remove it from request, as well as * adding it in the result object. * The step can also add some metadata and metrics to the result object, for an eventual * decorators use. * @param {ChoiceRequest} request * @return {Promise} */ execute(request: ChoiceRequest): Promise; /** * Returns tha name of the step. * @return {string} */ getName(): string; getMetricName(): string; /** * Returns labels that should be used (metrics) * @return {string[]} */ getLabels(): string[]; /** * Returns true if step is a creative-filtering step. * @return {boolean} */ shouldReportCreativeFiltering(): boolean; /** * Return the bucket for the metric decorator */ getMetricBucket(): number[]; }