Complete YAML reference for transformation and transformation-library resources managed with Rudder CLI.
Available Plans
free
growth
enterprise
13 minute read
This guide provides a complete YAML reference for managing transformation resources using Rudder CLI.
Overview
You can define transformation resources in YAML files anywhere inside your CLI project directory. Rudder CLI scans the project recursively and processes valid resource files.
Supported resource kinds for this workflow:
transformation
transformation-library
Transformation resource
Use kind: transformation to define a transformation.
Same URN imported by both a manifest and inline metadata
The URN event:order_completed is declared in both the manifest and an inline metadata.import block — an ambiguous double import. The rule flags both locations; remove one.
import-manifest.yaml/spec/workspaces/0/resources/0/urnURN 'event:order_completed' is defined in both an import-manifest and inline metadata
events.yaml/metadata/import/workspaces/0/resources/0/urnURN 'event:order_completed' is defined in both an import-manifest and inline metadata
Manifest URN overlaps a legacy rudder/0.1 inline local_id import
The events spec uses the legacy rudder/0.1 format, whose inline imports reference resources by local_id + remote_id. The local_id order_completed resolves to the URN event:order_completed — the same URN the manifest imports. Legacy specs are still subject to the conflict rule, so both locations are flagged; remove the inline metadata entry.
Same URN imported by both a manifest and inline metadata
The URN event:order_completed is declared in both the manifest and an inline metadata.import block — an ambiguous double import. The rule flags both locations; remove one.
import-manifest.yaml/spec/workspaces/0/resources/0/urnURN 'event:order_completed' is defined in both an import-manifest and inline metadata
events.yaml/metadata/import/workspaces/0/resources/0/urnURN 'event:order_completed' is defined in both an import-manifest and inline metadata
Manifest URN overlaps a legacy rudder/0.1 inline local_id import
The events spec uses the legacy rudder/0.1 format, whose inline imports reference resources by local_id + remote_id. The local_id order_completed resolves to the URN event:order_completed — the same URN the manifest imports. Legacy specs are still subject to the conflict rule, so both locations are flagged; remove the inline metadata entry.
Valid transformation library spec with inline JavaScript
spec.yamlyaml
version:rudder/v1kind:transformation-librarymetadata:name:my-librariesspec:libraries:- id:math-utilsname:Math Utilsimport_name:mathUtilsdescription:Utility functions for math operationslanguage:javascriptcode:| export function round(value) {
return Math.round(value);
}
Transformation library spec missing required id
spec.yamlyaml
version:rudder/v1kind:transformation-librarymetadata:name:my-librariesspec:libraries:- name:Math Utilsimport_name:mathUtilslanguage:javascriptcode:| export function round(value) {
return Math.round(value);
}
This site uses cookies to improve your experience. If you want to learn more about cookies and why we use them, visit our cookie policy. We'll assume you're ok with this, but you can opt-out if you wish
Privacy Overview
This site uses cookies to improve your experience while you navigate through the website. Out of these cookies, the cookies that are categorized as necessary are stored on your browser as they are as essential for the working of basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website. These cookies will be stored in your browser only with your consent. You also have the option to opt-out of these cookies. But opting out of some of these cookies may have an effect on your browsing experience.
Necessary cookies are absolutely essential for the website to function properly. This category only includes cookies that ensures basic functionalities and security features of the website. These cookies do not store any personal information.