Company

Custom Field

Create CustomFields at the company level which a company could be assigned.

post/companies/{companyId}/customfields

Request

Path parameters

companyIdstring required

ID associated with desired company.

Request body

customFieldIdstring

The unique identifier that is autogenerated when a custom field is created

customFieldNamestring

The name of the custom field

categoryIdstring

The unique identifier that is autogenerated when creating a category

requiredboolean

Where to indicate if the custom field is required on the worker where true = required and false = not required

checkStubboolean

Where to indicate if the custom field is required on the worker's pay stub, where true = required and false = not required

employeeEditableboolean

Where to indicate if the custom field is able to be edited by the employee, where true = required and false = not required

type'DROPDOWN' | 'TEXT' | 'BOOLEAN' | 'DATE' | 'NUMERIC, NUMERIC__0_00_ OR NUMERIC__0_0000_'

The type of field the custom field is.

booleanValueboolean

The value for BOOLEAN type (true / false)

dateValuestring date-time

The value for DATE type , example : 2012-02-01T05:00:00Z

textValuestring

The value for TEXT type (any text, alphanumeric, special characters allowed)

maxTextLengthnumber

The maximum allowed value for textValue

numericValuenumber

Numeric data type can have three formats namely - whole number, second decimal place and fourth decimal place, example: 12 , 12.34 or 12.3456

Example request

{
  "customFieldId": "1040014203417589",
  "customFieldName": "Hobbies",
  "categoryId": "1040014179116276",
  "type": "DROPDOWN",
  "dropdown": [
    {
      "dropdownId": "1040014203453303",
      "dropdownValue": "Basketball",
      "dropdownDefault": true
    }
  ]
}

Response

successful operation

Example response

{
  "content": {
    "customFieldId": "1040014203417589",
    "customFieldName": "Hobbies",
    "categoryId": "1040014179116276",
    "type": "DROPDOWN",
    "dropdown": [
      {
        "dropdownId": "1040014203453303",
        "dropdownValue": "Basketball",
        "dropdownDefault": true
      }
    ]
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.