Skip to main content

settings/customfields/{id}/options/items

Download all options of a pick list. This method works with any kind of pick list.

Wordbee supports pick list custom fields. Such custom fields define different options from which a user can select from. Use settings/customfields to enumerate all fields and see which ones are pick lists (look for “Combo”). Please note that options come in two flavors:

  • List of strings: Most field types only allow to configure a list of strings. This concerns fields Combo, ComboEditable and ComboMultiSelect.

  • List of strings with meta data: Fields of type ComboAuto are like regular pick lists but with a nice twist: You can also specify a list of strings but also add meta-data to each string. Read more.

URL

CODE
(GET) /api/settings/customfields/{id}/options/items

PARAMETERS

The URL has these parameters:

id

The unique ID of the custom field. Easily find all your fields' IDs with: settings/customfields

Note: The ID is of the following format. The first number identifies the object to which the field relates (such as project, job, person, segment, etc.). The second number is a sequential field number.

CODE
2-5

The first number is the object:

  • 1 : Segment

  • 2 : Project

  • 3 : Resource (project memory, translation memory or termbase)

  • 4 : Order

  • 5 : Company

  • 6 : Job

  • 7 : Invoice

  • 8 : Person

  • 9 : Service

string, Mandatory

RESULTS

The result is a JSON array with all the options. Each element represents one option with these properties:

value

The option’s value. This is the text that is shown in the pick list and selected by a user.

string

meta

An array of meta data. If there is no meta data then the array is empty.

Meta data might look like this.

CODE
"meta": [
    { "key": "author", "title": "Author", "value": "John Updike", "show": true },
    { "key": "reader", "title": "Reader", "value": "Oh my god", "show": true },
    { "key": null, title": "ID", "value": "2121", "show": false }
]

object[]

meta.key

An optional key assigned to the data. Null if none.

string?

meta.title

A mandatory title for the meta data.

string

meta.value

The actual value. Can be null.

string?

meta.show

An indicator if this field is shown to users in the UI or should not be shown.

bool

Note: Options are always sorted alphabetically by their value.

Examples

Options with meta data:

CODE
[
    {
        "value": "10009",
        "meta": [ 
            { "title": "Project", "value": "Project A-10009 - Henderson", "show": true }
        ]
    },
    {
        "value": "10054",
        "meta": [ 
            { "title": "Project", "value": "Project X-33223 - IBM", "show": true },
            { "title": "Owner", "value": "John", "key": "owner", "show": false }  
        ]
    },
    {
        "value": "20092",
        "meta": []
    }
]

Options for a pick list that does not support meta data. Here the “meta” node is always an empty array.

CODE
[
  { "value": "London", "meta": [] },
  { "value": "Paris", "meta": [] }
]

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.