# Update template's custom field responses.

This endpoint updates the template's custom field responses.

Endpoint: PUT /v2/event-templates/{templateId}/custom-field-responses
Version: v2
Security: Bearer

## Security:

  - `Bearer` (unknown)
    http bearer

## Path parameters:

  - `templateId` (string, required)
    Template ID

## Request fields (application/json):

  - `customFieldResponses` (array)
    Preselected custom field responses for the event template.

  - `customFieldResponses.customFieldId` (string, required)
    The unique identifier for the custom field.
    Example: f49d00fe-1eda-4304-ba79-a980f565281d

  - `customFieldResponses.responseItems` (array)
    Responses selected by the event coordinator.

  - `customFieldResponses.responseItems.response` (string, required)
    The response of the custom field. It can be a text input from the user or a custom field code if the input is from a radio button or checkbox.
    Example: Leisure travel

  - `customFieldResponses.responseItems.additionalInput` (string)
    This contains additional input to the above response. It will only be used for checkbox with percentage and will contain the percentage value.
    Example: 20

  - `customFieldResponses.travelerAccess` (string, required)
    Traveler access for a custom field
    Enum: "HIDDEN", "READ_ACCESS", "WRITE_ACCESS"

  - `customFieldV3Responses` (array)
    List of custom field responses for an event.

  - `customFieldV3Responses.fieldId` (string, required)
    Custom field id

  - `customFieldV3Responses.fieldName` (string)
    Name of the custom field

  - `customFieldV3Responses.armId` (string, required)
    Arm id which is applicable

  - `customFieldV3Responses.readOnly` (boolean)
    Indicates whether the user can change the pre-selected options.
    Example: true

  - `customFieldV3Responses.hidden` (boolean)
    Whether this code will be hidden to the user.
    Example: true

  - `customFieldV3Responses.selectedOptions` (array, required)
    The list of options that are selected by user or auto populated.

  - `customFieldV3Responses.selectedOptions.name` (string, required)
    Value of the selection

  - `customFieldV3Responses.selectedOptions.translatedName` (string)
    Translated value of the selection

  - `customFieldV3Responses.selectedOptions.description` (string)
    Description of the selection

  - `customFieldV3Responses.selectedOptions.translatedDescription` (string)
    Translated description of the selection

  - `customFieldV3Responses.selectedOptions.additionalUserInput` (string)
    Additional user input

  - `customFieldV3Responses.selectedOptions.additionalInfos` (array)
    Actual values of the additional infos

  - `customFieldV3Responses.selectedOptions.additionalInfoConfigs` (array)
    Additional info configs for the selected option

  - `customFieldV3Responses.selectedOptions.additionalInfoConfigs.type` (string, required)
    Enum: "VARIABLE", "EXPRESSION"

  - `customFieldV3Responses.selectedOptions.additionalInfoConfigs.name` (string, required)
    Name of the variable.
    Enum: "PUBLISHED_FARE", "LLF", "ADD_COLLECT_AMOUNT", "SELECTED_FARE", "SPLIT_PAYMENT_FARE"

  - `customFieldV3Responses.selectedOptions.additionalInfoConfigs.formatExpression` (string, required)
    The expression must be of format : `<any_text> ${expression} <any_text>`.The expression
can consist of a combination of variables and mathematical operations.
Variable names must be same as VariableName Enum.
To define mathematical operations, the operation name should follow the format
`math.<math_op>(arg1, arg2)`. Both `arg1` and `arg2` can be variables or constants.
The supported math operations (math_op) include: `add, mul, div, sub, min, and max`. All keywords, such as `<math_op>, math, and var` must be written in lowercase.
    Example: Result:  ${math.mul(LLF,5)}  ${ADD_COLLECT_AMOUNT}

  - `customFieldV3Responses.selectedOptions.additionalInfoConfigs.variables` (array)
    Reference names of the variables present in the expression.

  - `customFieldV3Responses.selectedOptions.optionId` (string)
    Id of the selected option; sent by clients, never returned

## Response 200:

  - `200` (unknown)
    OK

## Response 400:

  - `400` (unknown)
    Bad request

## Response 400 fields (application/json):

  - `debugIdentifier` (string)
    Link to debug the error internally.

  - `errorMessages` (array)

  - `errorMessages.errorCode` (string)
    Error code to identify the specific errors.

  - `errorMessages.message` (string)
    Message containing details of error.

  - `errorMessages.errorParameters` (array)
    Error message parameters.

  - `errorMessages.errorParameters.name` (string)
    Parameter name

  - `errorMessages.errorParameters.value` (string)
    Parameter value

  - `errorMessages.errorDetail` (string)
    More details about the error.

## Response 401:

  - `401` (unknown)
    Unauthorized

## Response 401 fields (application/json):

  - `debugIdentifier` (string)
    Link to debug the error internally.

  - `errorMessages` (array)

  - `errorMessages.errorCode` (string)
    Error code to identify the specific errors.

  - `errorMessages.message` (string)
    Message containing details of error.

  - `errorMessages.errorParameters` (array)
    Error message parameters.

  - `errorMessages.errorParameters.name` (string)
    Parameter name

  - `errorMessages.errorParameters.value` (string)
    Parameter value

  - `errorMessages.errorDetail` (string)
    More details about the error.

## Response 403:

  - `403` (unknown)
    Forbidden

## Response 403 fields (application/json):

  - `debugIdentifier` (string)
    Link to debug the error internally.

  - `errorMessages` (array)

  - `errorMessages.errorCode` (string)
    Error code to identify the specific errors.

  - `errorMessages.message` (string)
    Message containing details of error.

  - `errorMessages.errorParameters` (array)
    Error message parameters.

  - `errorMessages.errorParameters.name` (string)
    Parameter name

  - `errorMessages.errorParameters.value` (string)
    Parameter value

  - `errorMessages.errorDetail` (string)
    More details about the error.

