Zetect Expressions & Transforms Back to zetect.inSwitch portal ⇄

Using Transforms

A transform is a JSON object whose type names an operation, plus the options that operation needs. Zetect runs it against the attributes the screen provides and returns one value. Use a transform when an expression's plain substitution isn't enough.

Applies to

Provisioning mappings and identity matching on applications and privileged assets, and the Value transform of provisioning risk signals.

Required permission

Administrator access to the console, with access to the screen where you edit the mapping.

Transform shape

{
  "type": "concat",
  "values": ["${firstName}", " ", "${lastName}"]
}
→ Priya Sharma
  • type is required and picks the operation. It is not case-sensitive.
  • Every text option can contain ${name} tokens, which are filled in the same way as in an expression.
  • Most types take an input, the value they work on. Inside a pipeline, a step with no input uses the previous step's result. See Chaining Transforms.
  • Whole-number options such as days or index can be JSON numbers or text.

Adding a transform to a mapping

To fill an account attribute with a transform:

  1. Open the application and select Provisioning mappings under Map.
  2. Select Add Mapping and choose the Account Attribute.
  3. In Source, choose Transform.
  4. Write the definition in the editor, or start from a template:
    • After Insert:, select concat, lookup, decision, date-format, windows-filetime or pipeline. The starter replaces whatever is in the editor.
    • Select an attribute chip to insert its ${name} token at the cursor.
  5. Fix any message shown under the editor.
  6. In Send on, choose when to send the value.
  7. Select Save Mappings.

The transform runs the next time Zetect creates or updates an account, as set by Send on. On Identity matching the steps are the same after you choose Transform following equals, and the transform runs at the next account sync.

Editor messages

The editor checks the text as you type.

MessageMeaning
Transform must be a JSON object.The text is valid JSON but not an object, for example a list or a quoted string.
Transform is missing a "type" property.The object has no type.
Transform definition is required.The editor is empty.
Any other messageThe JSON can't be read. The message describes where, for example a missing comma or quote.

Transform types

CategoryTypes
Stringuppercase, lowercase, trim, replace, concat, split, regex
Numericmath
Datedate-format, date-add, current-date
Logiclookup, decision, if
Utilitystatic, uuid, pipeline

The Transform Reference lists every option and default.

What a transform returns

  • One text value, or no value.
  • No value when the input is missing for types that need one, when nothing matches and there is no default, or when the transform can't run: malformed JSON, an unknown type or operator, an invalid regular expression or date pattern, or a date that can't be read.
  • A blank or missing result means a provisioning mapping is not sent and an identity matching rule is skipped.

Troubleshooting

  • The attribute never reaches the account. The transform is producing no value. Check the type name and option names for typos. Option names are case-sensitive, for example sourceFormat.
  • A lookup or condition never matches. Comparisons are exact and case-sensitive. Trim and change case first in a pipeline. See Chaining Transforms.
  • The value comes out as text beginning with {type=. A transform was nested where plain text is expected. Only pipeline steps and if branches accept nested transforms. Move the nested transform into a pipeline step.