/migrate-to-orchestra:prefect-automations-to-orchestrafrom migrate-to-orchestra
Maps Prefect Automations (S3/GCS file arrivals, DB polling, webhooks, schedules) to Orchestra sensors. Use when converting event-triggered Prefect flows to Orchestra's sensor-based pipeline triggers.
Ships in migrate-to-orchestra. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Prefect Automations react to external events (file arrivals, database state, webhook calls, or schedules) and trigger flow runs. In Orchestra, the equivalent is the sensors: block — a set of named checks that poll external systems on a cron schedule and gate the pipeline run. Automations that fire on flow state changes (failed/succeeded) are not sensors; those become alerts: (see prefect-alerts-to-orchestra).
| Prefect construct | Orchestra field | Notes |
|---|---|---|
| Automation: S3 object created event → trigger | sensors.checks with sensor_type: AWS_S3_FILE | integration: AWS_S3 |
| Automation: scheduled (cron) | schedule: at pipeline root | see prefect-flow-structure-to-orchestra |
| Automation: webhook trigger | webhook: {enabled: true} at pipeline root | |
@flow polling a DB table (Snowflake) | sensors.checks with sensor_type: SNOWFLAKE_QUERY | |
@flow polling SQL Server | sensors.checks with sensor_type: SQL_SERVER_QUERY | |
| Automation: upstream flow completion → trigger | trigger_events: at pipeline root | see prefect-cross-flow-to-orchestra |
| Automation: flow failed → notify | alerts: block | NOT a sensor |
SensorModel.timeout_mins | max 1440 (24 h) | Prefect has no equivalent cap |
map_outputs | pipes sensor query result to pipeline inputs: | declare matching key in pipeline inputs: |
Valid sensor_type values (SensorChecksEnum):
ADLS_FILE, AWS_S3_FILE, CLICKHOUSE_QUERY, DATABRICKS_QUERY, FABRIC_SYNAPSE_QUERY, GCP_BIG_QUERY_QUERY, GCP_CLOUD_STORAGE_FILE, MARIADB_QUERY, MONGODB_QUERY, MYSQL_QUERY, ORCHESTRA_PIPELINE_STATUS, ORCHESTRA_TASK_STATUS, ORCHESTRA_WEBHOOK_EVENT, POSTGRES_QUERY, SNOWFLAKE_QUERY, SFTP_FILE, SHAREPOINT_FILE, SQL_SERVER_QUERY
Check the enum against the live pipeline schema before emitting a value — it grows as Orchestra adds sensor types, so a list memorised from an older conversion goes stale.
An Automation watching one upstream task rather than a whole flow run maps to
ORCHESTRA_TASK_STATUS, which takes pipeline_id, task_id, statuses and
check_latest_run. It reads only the task's final attempt, so a failure a retry recovers
from won't satisfy a check waiting on FAILED
(Orchestra task sensor).
version: v1
name: pipeline-name
sensors:
<sensor-key>:
name: <human-readable name>
cron: '<cron expression>'
timezone: UTC
timeout_mins: 60 # max 1440
frequency_secs: 60 # how often checks are polled within the window
checks:
<check-key>:
integration: <INTEGRATION>
sensor_type: <SensorChecksEnum value>
connection: <connection_name>
parameters:
<integration-specific params>
map_outputs: # optional — pipe result to pipeline inputs
<input_key>: result
pipeline:
<stages and tasks>
version: v1
name: webhook-triggered-pipeline
webhook:
enabled: true
pipeline:
{}
prefect-alerts-to-orchestra insteadAWS_S3_FILE check; set connection to Orchestra AWS connection nameerror_threshold_expression if using SNOWFLAKE_RUN_TEST (testing skill); for sensors just use SNOWFLAKE_QUERYwebhook: {enabled: true} at pipeline root; remove trigger logic from flow bodyschedule: at pipeline roottrigger_events: (see prefect-cross-flow-to-orchestra)timeout_mins — never exceed 1440map_outputs and a matching inputs: key at pipeline rootsensor_type is a current SensorChecksEnum value, checked against the live schema# Automation: "When S3 object is created in s3://my-bucket/data/daily/ → run nightly-elt/prod"
# (Configured in Prefect UI — no Python code needed for the trigger itself)
# Separately, a polling flow:
@task
def wait_for_snowflake_data():
connector = SnowflakeConnector.load("sf-prod")
with connector.get_connection() as conn:
while True:
count = conn.cursor().execute(
"SELECT COUNT(*) FROM orders WHERE created_date = CURRENT_DATE"
).fetchone()[0]
if count > 0:
return count
time.sleep(300)
@flow
def nightly_elt():
order_count = wait_for_snowflake_data()
# ... rest of pipeline
version: v1
name: nightly-elt
sensors:
wait-for-s3-file:
name: Wait for daily S3 file
cron: '0 6 * * ? *'
timezone: UTC
timeout_mins: 60
frequency_secs: 60
checks:
s3-file-check:
integration: AWS_S3
sensor_type: AWS_S3_FILE
connection: aws_default_12345
parameters:
bucket_name: my-bucket
prefix: data/daily/
wait-for-snowflake-data:
name: Wait for daily order records
cron: '0 4 * * ? *'
timezone: UTC
timeout_mins: 120
frequency_secs: 300
checks:
row-check:
integration: SNOWFLAKE
sensor_type: SNOWFLAKE_QUERY
connection: snowflake_prod_12345
parameters:
query: 'SELECT COUNT(*) FROM orders WHERE created_date = CURRENT_DATE'
map_outputs:
order_count: result
inputs:
order_count:
type: integer
default: 0
pipeline:
stage-main:
tasks:
{}
SensorChecksEnum has exactly 9 values — POSTGRES_QUERY and GCP_BIG_QUERY_QUERY are NOT valid; use SNOWFLAKE_QUERY or SQL_SERVER_QUERY insteadalerts: → see prefect-alerts-to-orchestratimeout_mins max is 1440 (24 hours); Prefect has no enforced capmap_outputs pipes sensor query results to pipeline inputs — you must declare matching keys in the pipeline inputs: blockwebhook: {enabled: true} at pipeline root; no sensor block neededfrequency_secs controls polling interval within the sensor window; cron controls when the window opensSee prefect-alerts-to-orchestra for all notification patterns.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
npx claudepluginhub orchestra-hq/orchestra-skills --plugin migrate-to-orchestra52 skills in this plugin
/airbyte-cloud-airflow-to-orchestraUse this skill when the user wants to convert an Airflow task that uses AirbyteTriggerSyncOperator or AirbyteSensor (apache-airflow-providers-airbyte) into an equivalent Orchestra pipeline task targeting Airbyte Cloud. Triggers: any mention of migrating, converting, or rewriting Airflow Airbyte tasks to Orchestra; any Airflow DAG code containing AirbyteTriggerSyncOperator or AirbyteSensor pointed at Airbyte Cloud./airbyte-cloud-dagster-to-orchestraUse this skill when the user wants to convert a Dagster integration that syncs Airbyte Cloud — AirbyteCloudResource, build_airbyte_assets, load_airbyte_cloud_asset_specs, or airbyte_assets — into an equivalent Orchestra pipeline task targeting Airbyte Cloud. Triggers: any mention of migrating or rewriting Dagster Airbyte assets/resources to Orchestra; any Dagster code importing from dagster_airbyte pointed at Airbyte Cloud./airbyte-cloud-prefect-to-orchestraUse this skill when the user wants to convert a Prefect task that syncs Airbyte Cloud — AirbyteConnection block, trigger_sync_run_and_wait_for_completion, or AirbyteSyncResult — into an equivalent Orchestra pipeline task targeting Airbyte Cloud. Triggers: any mention of migrating or rewriting Prefect Airbyte tasks to Orchestra; any Prefect flow code importing from prefect_airbyte pointed at Airbyte Cloud.Other plugins' skills for the same job