How to Migrate from Rudder CLI Spec v0.1 to v1
Beta
Migrate your Rudder CLI project from spec format v0.1 to v1 with an automated command.
Available Plans
free
starter
growth
enterprise
7 minute read
This migration guide helps you migrate your Rudder CLI project from spec version 0.1 to v1.
Overview
rudder/v1 is a comprehensive redesign of the original rudder/v0.1 spec format. It improves consistency across resource kinds, replaces ambiguous field names, adopts snake case conventions, and moves to compact URN-style references throughout.
When you run the migrate command, Rudder CLI automatically rewrites the spec files present in the specified location and applies changes related to:
Spec version upgrades
Rename resource kinds
Using compact URN references
Updating property and custom type definitions
Updating Tracking Plan rules
Updating variant definitions
Updating import metadata
Updating event stream source references
As the migration process rewrites the spec files in place, RudderStack recommends committing or backing up your project before running the migrate command.
Run the migration
To migrate your project automatically, run the following command:
rudder-cli migrate --location <path-to-project>
Breaking changes
The following sections list the breaking changes introduced in the spec format upgrade from v0.1 to v1.
The migrate command automatically handles these changes.
Update the version field
The field-name, convention, and reference changes in rudder/v1 break the existing spec contract. The version is bumped to signal the new contract, so tooling and validation can distinguish it from legacy spec version rudder/v0.1.
version:rudder/v1
version:rudder/0.1# orversion:rudder/v0.1
Rename the Tracking Plan kind
The Tracking Plan kind changes from tp to tracking-plan. The abbreviated tp was an opaque abbreviation, while tracking-plan is self-documenting and consistent with how the resource is named everywhere else.
version:rudder/v1kind:tracking-plan
version:rudder/v0.1kind:tp
Compact URN references
All cross-resource references change from the path-based format (#/<kind>/<group>/<id>) to the compact URN format (#<resource-type>:<id>). Path-based references were verbose and order-dependent, while compact URNs are shorter and encode the resource type, making references unambiguous and easier to read.
The following table lists the updated reference format for each resource type:
Resource
v0.1
v1
Property
#/properties/group/prop_id
#property:prop_id
Event
#/events/group/event_id
#event:event_id
Category
#/categories/group/cat_id
#category:cat_id
Custom type
#/custom-types/group/type_id
#custom-type:type_id
Tracking plan
#/tp/group/tp_id
#tracking-plan:tp_id
The following example shows an event referencing a category:
version:rudder/v1kind:propertiesmetadata:name:api_trackingspec:properties:- id:api_methodname:API Methodtype:stringdescription:"http method of the api called"config:enum:["GET","PUT","POST","DELETE","PATCH"]- id:http_retry_countname:HTTP Retry Counttype:integerdescription:"Number of times to retry the API call"config:minimum:0maximum:10multiple_of:2- id:passwordname:Passwordtype:stringconfig:min_length:10max_length:64
version:rudder/v0.1kind:propertiesmetadata:name:api_trackingspec:properties:- id:api_methodname:API Methodtype:stringdescription:"http method of the api called"propConfig:enum:["GET","PUT","POST","DELETE","PATCH"]- id:http_retry_countname:HTTP Retry Counttype:integerdescription:"Number of times to retry the API call"propConfig:minimum:0maximum:10multipleOf:2- id:passwordname:Passwordtype:stringpropConfig:minLength:10maxLength:64
Custom type definitions
Custom type definitions undergo two changes:
$ref (a JSON Schema artifact with no semantic meaning in this context) is replaced by the clearer property
config keys follow the same snake case convention as properties
Tracking Plan rules undergo two structural changes:
The event object wrapper was redundant, so event now holds a direct reference string consistent with how other references are expressed.
allow_unplanned is renamed to additional_properties and moved to rule level for clarity.
$ref is replaced by property in rule properties, using compact URNs
The event object replaced with a direct reference string
The event field changes from an object (containing $ref, allow_unplanned, and identity_section) to a direct reference string. The allow_unplanned and identity_section fields move to rule level:
event.$ref becomes event (direct string)
event.allow_unplanned becomes additional_properties (moved to rule level and renamed)
event.identity_section becomes identity_section (moved to rule level)
Variants appear in both custom types and Tracking Plan rules — they undergo the following changes:
The variant default is restructured to remove an array-of-objects pattern in favor of an explicit properties wrapper that matches the shape used in rules
All $ref fields within variant discriminators and cases are replaced by property with compact URN references
The local_id field in import metadata is replaced by a urn field that includes the resource type. The urn field encodes the resource type alongside the local ID, eliminating ambiguity when multiple resource types share the same ID values.
The Tracking Plan reference in event stream source governance uses the compact URN format, consistent with the unified compact URN format adopted for all cross-resource references in v1.
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
Always Enabled
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.
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 Cookie Settings.