Choice Lists API

The Choice Lists API gives you access to the choice lists within your Fulcrum account. Choice lists can be shared between multiple apps.

Properties

PropertyTypeRequiredReadonlyDescription
namestringyesnoThe name of the choice list.
choicesarray of choice objectsyesnoThe choice list options. ([{"label": "Excellent Condition","value": "excellent"},{"label": "Poor Condition","value": "poor"})
descriptionstringnonoOptional choice list description.
versionnumbernoyesAutoincremented version of the choice list for history tracking.
idstringnoyesThe id of the choice list.
created_atstringnoyesTimestamp when the choice list was created.
updated_atstringnoyesTimestamp when the choice list was last updated.

Validations

The following properties must be included in order to create/update a choice_list object in our system. Any validation errors will return a 422 and an object with a list of validation errors.

Required Properties

PropertyTypeDescriptionExample
namestringThe name of the choice list."Inspection Conditions"
choicesarray of choice objectsThe choice list options.See choices properties table below.

Choices Properties

PropertyTypeRequiredReadonlyDescription
labelstringyesnoChoice label.
valuestringnonoChoice value, stored in the database.

Example validation response if choices is not included:

{
  "choice_list": {
    "errors": {
      "choices": ["must be an array object"]
    }
  }
}

Notes

  • The entire choice_list object is required when making an update. Omitting fields with existing data will result in data loss! The typical workflow for updating an existing choice list is to fetch the choice_list object, modify it, and then submit the PUT request.

Sample Response

{
  "choice_list": {
    "name": "Bridge Inspection Conditions",
    "description": "",
    "version": 1,
    "id": "56734070-0042-4f95-a914-b0307e65f9f3",
    "created_at": "2014-08-28T14:03:30Z",
    "updated_at": "2014-08-28T14:03:30Z",
    "choices": [{
      "label": "Excellent",
      "value": "Excellent"
    },
    {
      "label": "Good",
      "value": "Good"
    },
    {
      "label": "Fair",
      "value": "Fair"
    },
    {
      "label": "Poor",
      "value": "Poor"
    },
    {
      "label": "Unrated",
      "value": "Unrated"
    },
    {
      "label": "N/A",
      "value": "N/A"
    }]
  }
}