Blueprint
Constraints

Constraints allow you to indicate additional validations that will be applied to fields of a Sheet. These constraints are in addition to the implicit constraints based on types of data. (eg: String, Number) For example, a value is required for every record (RequiredConstraint), or every record must contain a unique value for the field (UniqueConstraint).

RequiredConstraint

Required Constraints indicate that the given field must be provided with a non-empty value.

UniqueConstraint

Unique Constraints indicates that the given field value must only appear once in all the values for that field. One caveat is that “null” (empty value) may appear many times. Instead use RequiredConstraint if you want to disallow nulls entirely.

// within the context of a create Workbook API call 
 "fields": [
  {
    "key": "firstName",
    "type": "string",
    "label": "First Name",
    "constraints": [{"type": "required"}]
  },
  {
    "key": "internalCustomerId",
    "type": "number",
    "label": "Internal Customer Id",
    "constraints": [
      {
        "type": "unique"
      },
      {
        "type": "required"
      }
    ]
  }
]

ComputedValue

You might notice a ComputedValue type within the Blueprint code. Please do not use this value at this time as it is unsupported and may be deprecated without notice.