published on Tuesday, Mar 31, 2026 by Pulumi
published on Tuesday, Mar 31, 2026 by Pulumi
This resource supports the “/transform/transformation/{name}” Vault endpoint.
It creates or updates a transformation with the given name. If a transformation with the name does not exist, it will be created. If the transformation exists, it will be updated with the new attributes.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as vault from "@pulumi/vault";
const example = new vault.Mount("example", {
path: "transform",
type: "transform",
});
const exampleTransformation = new vault.transform.Transformation("example", {
path: example.path,
name: "ccn-fpe",
type: "fpe",
template: "ccn",
tweakSource: "internal",
allowedRoles: ["payments"],
});
import pulumi
import pulumi_vault as vault
example = vault.Mount("example",
path="transform",
type="transform")
example_transformation = vault.transform.Transformation("example",
path=example.path,
name="ccn-fpe",
type="fpe",
template="ccn",
tweak_source="internal",
allowed_roles=["payments"])
package main
import (
"github.com/pulumi/pulumi-vault/sdk/v7/go/vault"
"github.com/pulumi/pulumi-vault/sdk/v7/go/vault/transform"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
example, err := vault.NewMount(ctx, "example", &vault.MountArgs{
Path: pulumi.String("transform"),
Type: pulumi.String("transform"),
})
if err != nil {
return err
}
_, err = transform.NewTransformation(ctx, "example", &transform.TransformationArgs{
Path: example.Path,
Name: pulumi.String("ccn-fpe"),
Type: pulumi.String("fpe"),
Template: pulumi.String("ccn"),
TweakSource: pulumi.String("internal"),
AllowedRoles: pulumi.StringArray{
pulumi.String("payments"),
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Vault = Pulumi.Vault;
return await Deployment.RunAsync(() =>
{
var example = new Vault.Mount("example", new()
{
Path = "transform",
Type = "transform",
});
var exampleTransformation = new Vault.Transform.Transformation("example", new()
{
Path = example.Path,
Name = "ccn-fpe",
Type = "fpe",
Template = "ccn",
TweakSource = "internal",
AllowedRoles = new[]
{
"payments",
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.vault.Mount;
import com.pulumi.vault.MountArgs;
import com.pulumi.vault.transform.Transformation;
import com.pulumi.vault.transform.TransformationArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var example = new Mount("example", MountArgs.builder()
.path("transform")
.type("transform")
.build());
var exampleTransformation = new Transformation("exampleTransformation", TransformationArgs.builder()
.path(example.path())
.name("ccn-fpe")
.type("fpe")
.template("ccn")
.tweakSource("internal")
.allowedRoles("payments")
.build());
}
}
resources:
example:
type: vault:Mount
properties:
path: transform
type: transform
exampleTransformation:
type: vault:transform:Transformation
name: example
properties:
path: ${example.path}
name: ccn-fpe
type: fpe
template: ccn
tweakSource: internal
allowedRoles:
- payments
Tutorials
Refer to the Codify Management of Vault Enterprise Using Terraform tutorial for additional examples of configuring data transformation using the Transform secrets engine.
Create Transformation Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Transformation(name: string, args: TransformationArgs, opts?: CustomResourceOptions);@overload
def Transformation(resource_name: str,
args: TransformationArgs,
opts: Optional[ResourceOptions] = None)
@overload
def Transformation(resource_name: str,
opts: Optional[ResourceOptions] = None,
path: Optional[str] = None,
allowed_roles: Optional[Sequence[str]] = None,
deletion_allowed: Optional[bool] = None,
masking_character: Optional[str] = None,
name: Optional[str] = None,
namespace: Optional[str] = None,
template: Optional[str] = None,
templates: Optional[Sequence[str]] = None,
tweak_source: Optional[str] = None,
type: Optional[str] = None)func NewTransformation(ctx *Context, name string, args TransformationArgs, opts ...ResourceOption) (*Transformation, error)public Transformation(string name, TransformationArgs args, CustomResourceOptions? opts = null)
public Transformation(String name, TransformationArgs args)
public Transformation(String name, TransformationArgs args, CustomResourceOptions options)
type: vault:transform:Transformation
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args TransformationArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args TransformationArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args TransformationArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args TransformationArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args TransformationArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var transformationResource = new Vault.Transform.Transformation("transformationResource", new()
{
Path = "string",
AllowedRoles = new[]
{
"string",
},
DeletionAllowed = false,
MaskingCharacter = "string",
Name = "string",
Namespace = "string",
Template = "string",
Templates = new[]
{
"string",
},
TweakSource = "string",
Type = "string",
});
example, err := transform.NewTransformation(ctx, "transformationResource", &transform.TransformationArgs{
Path: pulumi.String("string"),
AllowedRoles: pulumi.StringArray{
pulumi.String("string"),
},
DeletionAllowed: pulumi.Bool(false),
MaskingCharacter: pulumi.String("string"),
Name: pulumi.String("string"),
Namespace: pulumi.String("string"),
Template: pulumi.String("string"),
Templates: pulumi.StringArray{
pulumi.String("string"),
},
TweakSource: pulumi.String("string"),
Type: pulumi.String("string"),
})
var transformationResource = new Transformation("transformationResource", TransformationArgs.builder()
.path("string")
.allowedRoles("string")
.deletionAllowed(false)
.maskingCharacter("string")
.name("string")
.namespace("string")
.template("string")
.templates("string")
.tweakSource("string")
.type("string")
.build());
transformation_resource = vault.transform.Transformation("transformationResource",
path="string",
allowed_roles=["string"],
deletion_allowed=False,
masking_character="string",
name="string",
namespace="string",
template="string",
templates=["string"],
tweak_source="string",
type="string")
const transformationResource = new vault.transform.Transformation("transformationResource", {
path: "string",
allowedRoles: ["string"],
deletionAllowed: false,
maskingCharacter: "string",
name: "string",
namespace: "string",
template: "string",
templates: ["string"],
tweakSource: "string",
type: "string",
});
type: vault:transform:Transformation
properties:
allowedRoles:
- string
deletionAllowed: false
maskingCharacter: string
name: string
namespace: string
path: string
template: string
templates:
- string
tweakSource: string
type: string
Transformation Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The Transformation resource accepts the following input properties:
- Path string
- Path to where the back-end is mounted within Vault.
- Allowed
Roles List<string> - The set of roles allowed to perform this transformation.
- Deletion
Allowed bool - If true, this transform can be deleted.
Otherwise, deletion is blocked while this value remains false. Default:
falseOnly supported on vault-1.12+ - Masking
Character string - The character used to replace data when in masking mode
- Name string
- The name of the transformation.
- Namespace string
- The namespace to provision the resource in.
The value should not contain leading or trailing forward slashes.
The
namespaceis always relative to the provider's configured namespace. Available only for Vault Enterprise. - Template string
- The name of the template to use.
- Templates List<string>
- Templates configured for transformation.
- Tweak
Source string - The source of where the tweak value comes from. Only valid when in FPE mode.
- Type string
- The type of transformation to perform.
- Path string
- Path to where the back-end is mounted within Vault.
- Allowed
Roles []string - The set of roles allowed to perform this transformation.
- Deletion
Allowed bool - If true, this transform can be deleted.
Otherwise, deletion is blocked while this value remains false. Default:
falseOnly supported on vault-1.12+ - Masking
Character string - The character used to replace data when in masking mode
- Name string
- The name of the transformation.
- Namespace string
- The namespace to provision the resource in.
The value should not contain leading or trailing forward slashes.
The
namespaceis always relative to the provider's configured namespace. Available only for Vault Enterprise. - Template string
- The name of the template to use.
- Templates []string
- Templates configured for transformation.
- Tweak
Source string - The source of where the tweak value comes from. Only valid when in FPE mode.
- Type string
- The type of transformation to perform.
- path String
- Path to where the back-end is mounted within Vault.
- allowed
Roles List<String> - The set of roles allowed to perform this transformation.
- deletion
Allowed Boolean - If true, this transform can be deleted.
Otherwise, deletion is blocked while this value remains false. Default:
falseOnly supported on vault-1.12+ - masking
Character String - The character used to replace data when in masking mode
- name String
- The name of the transformation.
- namespace String
- The namespace to provision the resource in.
The value should not contain leading or trailing forward slashes.
The
namespaceis always relative to the provider's configured namespace. Available only for Vault Enterprise. - template String
- The name of the template to use.
- templates List<String>
- Templates configured for transformation.
- tweak
Source String - The source of where the tweak value comes from. Only valid when in FPE mode.
- type String
- The type of transformation to perform.
- path string
- Path to where the back-end is mounted within Vault.
- allowed
Roles string[] - The set of roles allowed to perform this transformation.
- deletion
Allowed boolean - If true, this transform can be deleted.
Otherwise, deletion is blocked while this value remains false. Default:
falseOnly supported on vault-1.12+ - masking
Character string - The character used to replace data when in masking mode
- name string
- The name of the transformation.
- namespace string
- The namespace to provision the resource in.
The value should not contain leading or trailing forward slashes.
The
namespaceis always relative to the provider's configured namespace. Available only for Vault Enterprise. - template string
- The name of the template to use.
- templates string[]
- Templates configured for transformation.
- tweak
Source string - The source of where the tweak value comes from. Only valid when in FPE mode.
- type string
- The type of transformation to perform.
- path str
- Path to where the back-end is mounted within Vault.
- allowed_
roles Sequence[str] - The set of roles allowed to perform this transformation.
- deletion_
allowed bool - If true, this transform can be deleted.
Otherwise, deletion is blocked while this value remains false. Default:
falseOnly supported on vault-1.12+ - masking_
character str - The character used to replace data when in masking mode
- name str
- The name of the transformation.
- namespace str
- The namespace to provision the resource in.
The value should not contain leading or trailing forward slashes.
The
namespaceis always relative to the provider's configured namespace. Available only for Vault Enterprise. - template str
- The name of the template to use.
- templates Sequence[str]
- Templates configured for transformation.
- tweak_
source str - The source of where the tweak value comes from. Only valid when in FPE mode.
- type str
- The type of transformation to perform.
- path String
- Path to where the back-end is mounted within Vault.
- allowed
Roles List<String> - The set of roles allowed to perform this transformation.
- deletion
Allowed Boolean - If true, this transform can be deleted.
Otherwise, deletion is blocked while this value remains false. Default:
falseOnly supported on vault-1.12+ - masking
Character String - The character used to replace data when in masking mode
- name String
- The name of the transformation.
- namespace String
- The namespace to provision the resource in.
The value should not contain leading or trailing forward slashes.
The
namespaceis always relative to the provider's configured namespace. Available only for Vault Enterprise. - template String
- The name of the template to use.
- templates List<String>
- Templates configured for transformation.
- tweak
Source String - The source of where the tweak value comes from. Only valid when in FPE mode.
- type String
- The type of transformation to perform.
Outputs
All input properties are implicitly available as output properties. Additionally, the Transformation resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing Transformation Resource
Get an existing Transformation resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: TransformationState, opts?: CustomResourceOptions): Transformation@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
allowed_roles: Optional[Sequence[str]] = None,
deletion_allowed: Optional[bool] = None,
masking_character: Optional[str] = None,
name: Optional[str] = None,
namespace: Optional[str] = None,
path: Optional[str] = None,
template: Optional[str] = None,
templates: Optional[Sequence[str]] = None,
tweak_source: Optional[str] = None,
type: Optional[str] = None) -> Transformationfunc GetTransformation(ctx *Context, name string, id IDInput, state *TransformationState, opts ...ResourceOption) (*Transformation, error)public static Transformation Get(string name, Input<string> id, TransformationState? state, CustomResourceOptions? opts = null)public static Transformation get(String name, Output<String> id, TransformationState state, CustomResourceOptions options)resources: _: type: vault:transform:Transformation get: id: ${id}- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Allowed
Roles List<string> - The set of roles allowed to perform this transformation.
- Deletion
Allowed bool - If true, this transform can be deleted.
Otherwise, deletion is blocked while this value remains false. Default:
falseOnly supported on vault-1.12+ - Masking
Character string - The character used to replace data when in masking mode
- Name string
- The name of the transformation.
- Namespace string
- The namespace to provision the resource in.
The value should not contain leading or trailing forward slashes.
The
namespaceis always relative to the provider's configured namespace. Available only for Vault Enterprise. - Path string
- Path to where the back-end is mounted within Vault.
- Template string
- The name of the template to use.
- Templates List<string>
- Templates configured for transformation.
- Tweak
Source string - The source of where the tweak value comes from. Only valid when in FPE mode.
- Type string
- The type of transformation to perform.
- Allowed
Roles []string - The set of roles allowed to perform this transformation.
- Deletion
Allowed bool - If true, this transform can be deleted.
Otherwise, deletion is blocked while this value remains false. Default:
falseOnly supported on vault-1.12+ - Masking
Character string - The character used to replace data when in masking mode
- Name string
- The name of the transformation.
- Namespace string
- The namespace to provision the resource in.
The value should not contain leading or trailing forward slashes.
The
namespaceis always relative to the provider's configured namespace. Available only for Vault Enterprise. - Path string
- Path to where the back-end is mounted within Vault.
- Template string
- The name of the template to use.
- Templates []string
- Templates configured for transformation.
- Tweak
Source string - The source of where the tweak value comes from. Only valid when in FPE mode.
- Type string
- The type of transformation to perform.
- allowed
Roles List<String> - The set of roles allowed to perform this transformation.
- deletion
Allowed Boolean - If true, this transform can be deleted.
Otherwise, deletion is blocked while this value remains false. Default:
falseOnly supported on vault-1.12+ - masking
Character String - The character used to replace data when in masking mode
- name String
- The name of the transformation.
- namespace String
- The namespace to provision the resource in.
The value should not contain leading or trailing forward slashes.
The
namespaceis always relative to the provider's configured namespace. Available only for Vault Enterprise. - path String
- Path to where the back-end is mounted within Vault.
- template String
- The name of the template to use.
- templates List<String>
- Templates configured for transformation.
- tweak
Source String - The source of where the tweak value comes from. Only valid when in FPE mode.
- type String
- The type of transformation to perform.
- allowed
Roles string[] - The set of roles allowed to perform this transformation.
- deletion
Allowed boolean - If true, this transform can be deleted.
Otherwise, deletion is blocked while this value remains false. Default:
falseOnly supported on vault-1.12+ - masking
Character string - The character used to replace data when in masking mode
- name string
- The name of the transformation.
- namespace string
- The namespace to provision the resource in.
The value should not contain leading or trailing forward slashes.
The
namespaceis always relative to the provider's configured namespace. Available only for Vault Enterprise. - path string
- Path to where the back-end is mounted within Vault.
- template string
- The name of the template to use.
- templates string[]
- Templates configured for transformation.
- tweak
Source string - The source of where the tweak value comes from. Only valid when in FPE mode.
- type string
- The type of transformation to perform.
- allowed_
roles Sequence[str] - The set of roles allowed to perform this transformation.
- deletion_
allowed bool - If true, this transform can be deleted.
Otherwise, deletion is blocked while this value remains false. Default:
falseOnly supported on vault-1.12+ - masking_
character str - The character used to replace data when in masking mode
- name str
- The name of the transformation.
- namespace str
- The namespace to provision the resource in.
The value should not contain leading or trailing forward slashes.
The
namespaceis always relative to the provider's configured namespace. Available only for Vault Enterprise. - path str
- Path to where the back-end is mounted within Vault.
- template str
- The name of the template to use.
- templates Sequence[str]
- Templates configured for transformation.
- tweak_
source str - The source of where the tweak value comes from. Only valid when in FPE mode.
- type str
- The type of transformation to perform.
- allowed
Roles List<String> - The set of roles allowed to perform this transformation.
- deletion
Allowed Boolean - If true, this transform can be deleted.
Otherwise, deletion is blocked while this value remains false. Default:
falseOnly supported on vault-1.12+ - masking
Character String - The character used to replace data when in masking mode
- name String
- The name of the transformation.
- namespace String
- The namespace to provision the resource in.
The value should not contain leading or trailing forward slashes.
The
namespaceis always relative to the provider's configured namespace. Available only for Vault Enterprise. - path String
- Path to where the back-end is mounted within Vault.
- template String
- The name of the template to use.
- templates List<String>
- Templates configured for transformation.
- tweak
Source String - The source of where the tweak value comes from. Only valid when in FPE mode.
- type String
- The type of transformation to perform.
Package Details
- Repository
- Vault pulumi/pulumi-vault
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
vaultTerraform Provider.
published on Tuesday, Mar 31, 2026 by Pulumi
