Documentation Index
Fetch the complete documentation index at: https://astronomer-preview.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
Blueprint is a template-based Dag authoring mode in the Astro IDE. Platform teams define reusable building blocks in Python. Analysts, analytics engineers, and data scientists assemble those blocks into production Dags through a visual builder and form-driven configuration, without writing Airflow code.
The open-source astronomer/blueprint library powers Blueprint in the Astro IDE, handling blueprint definition, YAML parsing, validation, and Dag generation. See the GitHub repository for the full API reference, blueprint authoring guide, and examples.
How Blueprint works
Blueprint has two sides: platform teams define blueprints; other team members use them.| Concept | What it is |
|---|---|
| Blueprint | A reusable building block defined in Python by the platform team. Each blueprint has a configuration schema that controls what users see and configure. |
| Step | An instance of a blueprint placed on the canvas and configured with specific values. |
| Workflow | A collection of steps with dependencies and a schedule, stored as a Dag YAML file in your project repository. |
| Airflow Dag | The production Dag generated automatically from the workflow Dag YAML. |
Prerequisites
- An Astro Workspace with Astro IDE access.
- Workspace Author permissions to use the Astro IDE. You need Workspace Operator permissions to start ephemeral test Deployments.
- The
airflow-blueprintlibrary (version 0.2.0 or later) added to your project’srequirements.txt. - At least one blueprint defined in your project with its JSON schema generated. See Set up blueprints.
Set up blueprints
Platform teams complete this setup so blueprints appear in the Astro IDE library for other team members to use.Create blueprint files in your project under
dags/templates/. Each blueprint is a Python class that defines a configuration schema and a render() method. The field descriptions you write become the form labels users see in the IDE.The Astro IDE renders supported Pydantic field types as interactive form fields. The following types are supported:
strintfloatboolLiteral["a","b"]list[str]list[int]list[float]list (untyped)Field(ge=, le=, pattern=, etc.)exclusiveMin/exclusiveMax, converted to ±1Field(multiple_of=)float; int always uses step=1Optional[T] / T | NoneOptional[Literal["a","b"]]selectedVersion; defaults to latestThe following types are not supported and render as an unsupported field with a warning in the IDE:
str | int (true unions)BaseModellist[Model]list[bool]dict[str, T]For full details on defining blueprints, including configuration models, field validation, and versioning, see the Blueprint GitHub repository.
Airflow scans the
dags/ folder for Python files that contain Dag objects. This file tells Blueprint to discover all .dag.yaml files in your project, parse them, and register the resulting Dags with Airflow automatically.For the Astro IDE to discover your blueprints, generate a JSON schema for each blueprint and output it to
blueprint/generated-schemas/ in your project:Repeat this command for each blueprint. The IDE reads this folder to determine which blueprints are available and uses the schemas to render configuration forms.
Build a workflow with Blueprint
After your platform team has set up blueprints, other team members can build workflows in the Astro IDE without writing Airflow code.Click New DAG to create a new workflow. Enter a Dag ID and click Generate DAG. Blueprint creates a new Dag YAML file in your project’s
dags/ folder.The configuration form only shows fields your platform team has explicitly exposed. Operational settings like retry logic, connection credentials, and default values are baked into the blueprint.
Test a workflow
After building your workflow, test it in an ephemeral Deployment. See Test and run code with the Astro IDE for instructions.Fix issues
If a task fails or produces unexpected output:- Edit the configuration directly: Click the step on the canvas to reopen its configuration form and adjust the values.
- Use Ask AI to Fix: Click Ask AI to Fix next to an error message for AI-generated suggestions on how to resolve the issue.