---
title: "Create transform"
method: POST
path: "/transforms"
tags: ["Transforms"]
---

# Create transform

`POST /transforms`

Create a new transform. Provide sql_template with {{weldTag}} references. Set publish=true to immediately materialize in the data warehouse. With publish=true and materialization "table", cron_expression puts the transform on its own materialization schedule.

## Request body

- TransformCreateRequestDto
  - `name` string, required — The name of the transform.
  - `folder_path` string — The folder path for the transform. Intermediate folders will be auto-created if they do not exist.
  - `sql_template` string, required — The SQL template with {{weldTag}} parameter references.
  - `materialization` 'view' | 'table' — The materialization type. Defaults to "view".
  - `documentation` string — Documentation for the transform.
  - `publish` boolean — If true, the transform will be published (materialized to DWH) immediately after creation.
  - `cron_expression` string — Cron expression (UTC) defining the transform's own materialization schedule, applied once it has been published. Requires publish=true and materialization "table". Omit for a transform that should only be materialized on demand.
  - `wait_for_completion` boolean — If true, the API will wait for table materialization to complete before returning, up to a configured timeout (default ~45 seconds; may differ per environment). Only relevant when publishing with materialization set to "table". If the materialization does not complete within the timeout, the response will still succeed with materialization_status "running".

## Response `201`

The transform has been successfully created.

- TransformDto
  - `id` string, required — The ID of the transform.
  - `name` string, required — The name of the transform.
  - `folder_path` string, required — The folder path for the transform.
  - `status` 'draft' | 'published', required — The status of the transform.
  - `materialization` 'view' | 'table', required — The materialization type.
  - `sql_template` string, required — The SQL template with {{weldTag}} parameter references.
  - `parameters` TransformParameterDto[], required — The parameters (dependencies) referenced in the SQL template.
    - `weld_tag` string, required — The weld tag reference used in the SQL template.
    - `type` 'raw_view' | 'model_view' | 'materialized_table', required — The type of dependency.
    - `dw_item_id` string, required — The fully-qualified data warehouse item identifier.
  - `documentation` string — Documentation for the transform.
  - `materialization_status` 'running' | 'completed' | 'failed', nullable — The status of the table materialization in the data warehouse. Set to "running", "completed", or "failed" for published table transforms, or null for drafts and view-type transforms.
  - `materialization_error` string — Error message from the data warehouse if table materialization failed.
  - `orchestration_workflow_id` string — The ID of the Orchestration Workflow that this transform is attached to, if any.
  - `cron_expression` string, nullable — Cron expression (UTC) configured as the transform's own materialization schedule, or null if none has been set. It is only *acted on* while the transform is published, materialized as a "table", and not attached to an Orchestration Workflow. It is still reported in the other cases — a draft, a view, or a transform running as part of a workflow (see orchestration_workflow_id) — so you can see the schedule the transform would fall back to once it is published as a table again or detached from the workflow. Use materialization, status and orchestration_workflow_id to tell whether it is currently in effect.
  - `created_at` string, date-time, required — The datetime when the transform was created.
  - `updated_at` string, date-time, required — The datetime when the transform was last updated.

---

[API](https://skmtc.net/weld/apis/weld-rest-api.md) · [All operations](https://skmtc.net/weld/apis/weld-rest-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/weld/weld-rest-api/revisions/75294f591cc2/schema)
