Skip to main content
Version: 2.23.X

Custom Fields Authoring

A custom field is a value computed from the fields of an element, which can be used in place of a field in a constraint. The custom field view is reachable by selecting Custom Field from a field's dropdown menu in a constraint, either at the time of creating the constraint or when editing it via the constraint editor in the details panel. The user interface of the custom field view appears as an overlay atop the event pattern view. Click Save in the footer to save the custom field, or click Cancel to discard it.

note

Custom fields were previously referred to as "constraint computations."

Working with Custom Fields​

For the most part, the custom field view operates in the same way as the view described in Outcome Computations Authoring:

  • It provides access to the same computation elements.
  • To form computations, you draw links between input fields, computation elements, and outputs.
  • You can search, print, zoom, pan, clone, delete, and so on, just like you would in the outcome computations view.

However, the custom field view differs in the following ways:

  • The computations are for constraints, not outcomes.
  • You only have access to the element associated with the constraint end where the custom field is defined.
  • The computations only produce one single output value. The output's data type is determined by the result of the computations in the diagram.

Naming Custom Fields​

The name of a custom field determines its label in the pattern view. A custom field must be named before it can be saved.

To name a custom field:

  1. In the header of the custom field view, click the Custom Field Name field.
  2. Enter a name for the custom field.

Parameter Mapping​

The computations view is also used to map values to the input parameters of HTTP and Cogynt AI event types. Parameter mappings are not custom fields, and do not need to be named.

HTTP Parameter Mapping​

  • For constraints with an HTTP element, the computation outputs are the input parameters (i.e. Path Parameters, Query Parameters, Header Parameters, and Body Parameters) of the HTTP element.
  • Input fields from the joined element can be mapped to input parameters directly, or transformed using computation functions prior to mapping to input parameters.

Cogynt AI Parameter Mapping​

  • For constraints with a Cogynt AI element, the computation outputs are the input parameters defined in the Cogynt AI event type's Input Parameters section.
  • Parameter mapping works the same way as HTTP parameter mapping: input fields from the joined element can be mapped to input parameters directly, or transformed using computation functions prior to mapping to input parameters.
  • For more information about defining input parameters, see Cogynt AI Event Types.