rudder-cli-setup
Installs and authenticates rudder-cli. Use when installing rudder-cli, setting up rudder cli, rudder-cli command not found, or authenticating with RudderStack
Creates and manages RudderStack transformations and libraries with local testing. Use when creating, editing, or managing RudderStack transformations and transformation libraries using the Rudder CLI
$ npx -y skills add rudderlabs/rudder-agent-skills --skill rudder-transformations --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/rudder-transformationsContext preview
The summary Claude sees to decide when to auto-load this skill.
Creates and manages RudderStack transformations and libraries with local testing. Use when creating, editing, or managing RudderStack transformations and transformation libraries using the Rudder CLI
name: rudder-transformations description: Creates and manages RudderStack transformations and libraries with local testing. Use when creating, editing, or managing RudderStack transformations and transformation libraries using the Rudder CLI allowed-tools: "Bash(rudder-cli *), Read, Write, Edit"
RudderStack transformations allow real-time event manipulation using JavaScript or Python. Libraries provide reusable code shared across transformations. Both are managed as code using YAML specs and the Rudder CLI.
Follow this loop for every change — authoring a new transformation or library, or editing existing code. Testing locally with fixtures is the key step that distinguishes transformations work from other CLI workflows.
digraph transformations_workflow {
rankdir=TB;
"rudder-cli workspace info" [shape=box];
"Authenticated?" [shape=diamond];
"rudder-cli auth login" [shape=box];
"Edit YAML / JS / fixtures" [shape=box];
"rudder-cli validate -l ./" [shape=box];
"Validation errors?" [shape=diamond];
"Fix errors" [shape=box];
"rudder-cli transformations test --all -l ./" [shape=box];
"Tests pass?" [shape=diamond];
"Fix code or expected output" [shape=box];
"rudder-cli apply --dry-run -l ./" [shape=box];
"Diff matches intent?" [shape=diamond];
"Adjust specs" [shape=box];
"rudder-cli apply -l ./" [shape=box];
"Done" [shape=doublecircle];
"rudder-cli workspace info" -> "Authenticated?";
"Authenticated?" -> "rudder-cli auth login" [label="no"];
"rudder-cli auth login" -> "rudder-cli workspace info";
"Authenticated?" -> "Edit YAML / JS / fixtures" [label="yes"];
"Edit YAML / JS / fixtures" -> "rudder-cli validate -l ./";
"rudder-cli validate -l ./" -> "Validation errors?";
"Validation errors?" -> "Fix errors" [label="yes"];
"Fix errors" -> "rudder-cli validate -l ./";
"Validation errors?" -> "rudder-cli transformations test --all -l ./" [label="no"];
"rudder-cli transformations test --all -l ./" -> "Tests pass?";
"Tests pass?" -> "Fix code or expected output" [label="no"];
"Fix code or expected output" -> "rudder-cli validate -l ./";
"Tests pass?" -> "rudder-cli apply --dry-run -l ./" [label="yes"];
"rudder-cli apply --dry-run -l ./" -> "Diff matches intent?";
"Diff matches intent?" -> "Adjust specs" [label="no"];
"Adjust specs" -> "rudder-cli validate -l ./";
"Diff matches intent?" -> "rudder-cli apply -l ./" [label="yes"];
"rudder-cli apply -l ./" -> "Done";
}**Steps:** 1. **Verify auth** — `rudder-cli workspace info`; re-auth with `rudder-cli auth login` if needed. 2. **Validate** — `rudder-cli validate -l ./` catches YAML schema errors, missing files, camelCase `import_name` violations. 3. **Test locally** — `rudder-cli transformations test --all -l ./` runs each transformation against its `tests/input/*.json` fixtures and diffs against `tests/output/*.json`. Use `--modified` for faster iteration or pass a specific transformation id. 4. **Dry run** — `rudder-cli apply --dry-run -l ./` shows the diff that would be applied. Check for unexpected deletions. 5. **Apply** — `rudder-cli apply -l ./` publishes libraries and transformations atomically (correct order handled by the CLI).
For the broader validate → apply cycle that applies to all CLI-managed resources, see the `rudder-cli-workflow` skill. This skill specializes it with the local-test step.
A complete end-to-end project — library, transformation, fixtures, and README — lives at `examples/transformations-workflow/` in this repo. It includes a ported Base64 library (`base64-lib`), a sample transformation that uses it, and input/output test fixtures. Use it as a scaffold for new transformations or as a reference for `tests/` structure.
transformations/
my-transformation.yaml # Transformation spec
my-library.yaml # Library spec
javascript/
my-transformation.js # JavaScript code
my-library.js # Library code
python/
my-transformation.py # Python code
my-library.py # Library code
tests/
input/
event1.json # Test input events
output/
event1.json # Expected outputsversion: "rudder/v1"
kind: "transformation"
metadata:
name: "transformations"
# Optional: import section for linking to existing workspace resources
import:
workspaces:
- workspace_id: "your-workspace-id"
resources:
- remote_id: "existing-transformation-id"
urn: "transformation:my-transformation"
spec:
id: "my-transformation" # Unique identifier (used as external ID)
name: "My Transformation" # Human-readable name
description: "Description" # Optional
language: "javascript" # "javascript" or "python"
file: "javascript/my-transformation.js" # Path to code (relative to YAML)
# OR inline:
# code: |
# export function transformEvent(event) { return event; }
tests: # Optional - local testing only
- name: "basic-test"
input: "./tests/input" # Directory with JSON events
output: "./tests/output" # Directory with expected results**Note:** The `metadata.import` section is auto-generated when importing existing resources from a workspace. It links local files to remote resources.
version: "rudder/v1" kind: "transformation-library" metadata: name: "transformation-libraries" spec: id: "my-library" # Unique identifier name: "My Library" # Human-readable name description: "Reusable utilities" # Optional language: "javascript" # "javascript" or "python" import_name: "myLibrary"
A Claude Code plugin marketplace and Agent Skills collection that teaches your AI coding agent how to drive every programmatic RudderStack surface — CLI, MCP server, Terraform, and Profiles — with the right preflight checks, commands, and recovery paths.
Installs and authenticates rudder-cli. Use when installing rudder-cli, setting up rudder cli, rudder-cli command not found, or authenticating with RudderStack
Validates, previews, and applies RudderStack resource changes via YAML specs. Use when iterating on RudderStack resources with rudder-cli - validates specs,…
Imports existing RudderStack workspace resources into YAML files for git-based management. Use when importing existing RudderStack resources to CLI management…
Generates type-safe SDKs (Swift/Kotlin) from tracking plans with compile-time validation. Use when generating type-safe event tracking code from tracking plans…
Derives tracking plans from existing codebase types and structures. Use when instrumenting an existing product that wasn't well-instrumented or restructuring…
Creates and manages events, properties, categories, and custom types for instrumentation schemas. Use when creating or managing events, properties, categories,…