Types of form parameters

List of available types for form parameters when building custom form collections.

When building custom form collections for employee onboarding, form parameters support the following data types:

Type

Description

boolean

Represents a parameter that accepts boolean values (true/false). Typically rendered as Yes/No select options in the UI.

currency

Represents a parameter that accepts currency values with up to 2 decimal places. Used for dollar amounts like additional withholding amounts.

number

Represents a parameter that accepts positive integer values. Used for whole number inputs like number of dependents or allowances.

percent

Represents a parameter that accepts positive decimal values ranging from 0 to 100. Used for percentage inputs like withholding percentages.

select

Represents a parameter that accepts values from a predefined list of options. Each option has a value and human-readable label property. The options field will be populated with the available choices.

string

Represents a parameter that accepts any text string. Used for text inputs like names, addresses, SSN, and other free-form text fields.

Usage Example

When retrieving a form via GET /forms/:form_id, each parameter in the response will include a type field indicating which of these types it expects:

{
  "parameters": [
    {
      "name": "additional_withholding",
      "label": "Additional amount to withhold",
      "type": "currency",
      "required": false
    },
    {
      "name": "filing_status",
      "label": "Filing status",
      "type": "select",
      "options": [
        {"value": "single", "label": "Single"},
        {"value": "married", "label": "Married"}
      ],
      "required": true
    },
    {
      "name": "allowances",
      "label": "Number of allowances",
      "type": "number",
      "required": true
    },
    {
      "name": "exempt",
      "label": "Exempt from withholding",
      "type": "boolean",
      "required": false
    },
    {
      "name": "withholding_percentage",
      "label": "Additional withholding percentage",
      "type": "percent",
      "required": false
    },
    {
      "name": "employee_signature",
      "label": "Employee signature",
      "type": "string",
      "required": true
    }
  ]
}

Validation

Each parameter type has specific validation rules:

  • boolean: Must be either "true" or "false" as strings
  • currency: Numeric value with up to 2 decimal places (e.g., "123.45")
  • number: Positive integer values only (e.g., "5")
  • percent: Decimal value between 0 and 100 (e.g., "15.5")
  • select: Value must match one of the provided option values
  • string: Any text string, subject to field-specific validation (e.g., SSN format)

When submitting form data, ensure values are provided as strings matching the expected format for each type.