New to Kestra?
Use blueprints to kickstart your first workflows.
Trigger Metaplane monitors right after a data load with Kestra. One fire-and-forget Run task enqueues the sweep so anomaly detection never lags the warehouse.
Scheduled monitor sweeps have a blind spot, the gap between a load finishing and the next sweep starting. If the load lands at 02:25 and the monitors run at 06:00, a broken load sits undetected for hours. This blueprint closes the gap with io.kestra.plugin.metaplane.Run: the moment the load task succeeds, Kestra enqueues an immediate run of the monitors covering the loaded tables. The call is fire-and-forget, the Metaplane API answers as soon as the run is enqueued, so the flow finishes in seconds while detection happens on Metaplane's side.
load_data stands in for the real ingestion step, a dlt pipeline, an Airbyte sync, or a warehouse COPY. Because run_monitors only executes after it succeeds, monitors always sweep post-load data, never a half-written table.run_monitors (io.kestra.plugin.metaplane.Run) posts the monitorIds to Metaplane in one call. The task returns the enqueued monitor IDs as its output and does not wait for the monitors to complete.note_enqueued posts a Discord note with the count of enqueued monitors, computed from the task output, so the channel knows fresh results are on the way.errors block sends a distinct alert when the load or the enqueue fails, because a silently skipped sweep means anomalies wait for the next scheduled run.Schedule trigger runs the flow after the nightly load window.Only the orchestrator knows the exact moment a load finished. Kestra turns that knowledge into action: the Run task fires as the next step of the same execution, inherits the flow's error handling, and leaves an audit trail tying each load to the sweep it triggered. When the sweep should block rather than inform, the same plugin's Gate task swaps in without changing the flow's shape.
METAPLANE_API_TOKEN: Metaplane API token.DISCORD_WEBHOOK_URL: Discord incoming webhook URL.monitorIds with UUIDs from your Metaplane workspace.load_data stand-in with your real ingestion task and enable the after_nightly_load trigger.io.kestra.plugin.dlt.Run, an Airbyte sync task, or a dbt build so the sweep follows your real load.io.kestra.plugin.metaplane.Gate with runFirst: true when downstream steps should wait for the results instead of firing and forgetting, as shown in the quality gate blueprint.