Skip to main content

Get options for a specific product field

GET 

/v1/products/:id/field-options/:field_key

Retrieve the available options for a specific ENUM field of a product. This is useful for products that have fields with predefined options (e.g occupation for medical malpractice).These options should used to populate the dropdowns in the UI.

Request

Path Parameters

    id integerrequired

    The ID of the product or the code of the product when the using_product_code parameter is set to 1

    field_key stringrequired

    The key of the field for which to retrieve options (e.g., 'indemnity_limit', 'duration', 'occupation', 'aggregated_claim_limit')

Query Parameters

    using_product_code integer

    Possible values: [0, 1]

    Must be one of 1,0. Set to 1 when the id path parameter contains the product code instead of the product ID

Responses

OK

Schema
    data object
    field_key string

    The field key for which options were retrieved

    options object[]

    Array of available options for the specified field

  • Array [
  • key string

    The option key/value

    label string

    The human-readable label for the option

  • ]
Loading...