REST API - Option Lists

Version 2

    The REST API provides access to create, retrieve, update and delete option lists.

     

    Accessing Option Lists

    • GET  /assets/optionList/{id}?depth={depth}

     

    Response

    The response from this call looks as follows :

     

    {
      "type": "OptionList",
      "id": "2",
      "depth": "complete",
      "name": "Company Revenue",
      "elements": [
        {
          "type": "Option",
          "displayName": "-- Please Select --",
          "value": ""
        },
        {
          "type": "Option",
          "displayName": "0 - 49 Million",
          "value": "0 - 49 Million"
        },
        {
          "type": "Option",
          "displayName": "50 - 99 Million",
          "value": "50 - 99 Million"
        },
        {
          "type": "Option",
          "displayName": "100 - 249 Million",
          "value": "100 - 249 Million"
        },
        {
          "type": "Option",
          "displayName": "250 - 999 Million",
          "value": "250 - 999 Million"
        },
        {
          "type": "Option",
          "displayName": "1 - 5 Billion",
          "value": "1 - 5 Billion"
        },
        {
          "type": "Option",
          "displayName": "5+ Billion",
          "value": "5+ Billion"
        }
      ]
    }
      

     

    Properties

     

    Name

    Type

    Description

    Notes

    Validations

    type"OptionList"
    idintegerThe unique id of the Option ListReadOnlyIdRequirement
    elementsList<Option>Dictionary of elements in the Option List

     

     

    Name

    Type

    Description

    Notes

    Validations

    type"Option"
    displayNamestringThe display name of the Option List item
    valuestringThe value of the Option List item

     

     

     

    Related Operations

    • POST :  /assets/optionList
    • PUT :  /assets/optionList/{id}
    • DELETE :  /assets/optionList/{id}
    • GET (list) :  /assets/optionLists?search={searchTerm}&page={page}&count={count}

     

    Sample Code