---
title: "user.setCustomFieldValues"
method: POST
path: "/user.setCustomFieldValues"
tags: ["User"]
---

# user.setCustomFieldValues

`POST /user.setCustomFieldValues`

Set the values of multiple custom fields on an employee in a single call.
This is the recommended approach when updating multiple fields on the same employee
to avoid race conditions that can occur with concurrent `user.setCustomFieldValue` calls.

The values accepted in the `fieldValue` param depend on the type of field being updated. See the [customField.setValue](https://developers.ashbyhq.com/reference/customfieldsetvalue) docs for accepted types.

**Requires the [`organizationWrite`](authentication#permissions-usersetcustomfieldvalues) permission.**

## Request body

- UserSetCustomFieldValuesRequest
  - `userId` string, uuid, required — The id of the employee to set custom field values for
  - `values` object[], required — Array of custom field updates to apply
    - `fieldId` string, uuid, required — The unique id of the Custom Field definition for the field
    - `fieldValue` union, required — The value to store in the field. Type depends on the custom field type (boolean, string, number, object, etc.) - Location field: An object with the following properties: `{ country: "USA", city: "San Francisco", region: "California" }`. You may provide any combination of these properties and we will attempt to geocode the location. For best results, provide all three properties.
      - boolean
      - number
      - string
      - string[]
      - object
        - `value` number, required — The currency amount
        - `currencyCode` string, required — The currency code
      - object
        - `type` string, required — The range type
        - `minValue` number, required — The minimum value
        - `maxValue` number, required — The maximum value
      - object
        - `type` string, required — The compensation range type
        - `minValue` number, required — The minimum compensation value
        - `maxValue` number, required — The maximum compensation value
        - `currencyCode` string, required — The currency code
        - `interval` string, required — The compensation interval
      - object
        - `country` string — The country of the location
        - `region` string — The region of the location
        - `city` string — The city of the location

## Response `200`

Responses from the user.setCustomFieldValues endpoint

- union
  - UserSetCustomFieldValuesSuccessResponse
    - `success` true, required
    - `results` UserCustomField[], required
      - `id` string, uuid, required — The unique id of the custom field definition
      - `title` string, required — The title of the custom field
      - `value` union, required — The current value of the custom field
        - boolean
        - number
        - string
        - string[]
        - object
          - `value` number, required — The currency amount
          - `currencyCode` string, required — The currency code
        - object
          - `type` string, required — The range type
          - `minValue` number, required — The minimum value
          - `maxValue` number, required — The maximum value
        - object
          - `type` string, required — The compensation range type
          - `minValue` number, required — The minimum compensation value
          - `maxValue` number, required — The maximum compensation value
          - `currencyCode` string, required — The currency code
          - `interval` string, required — The compensation interval
        - object
          - `country` string — The country of the location
          - `region` string — The region of the location
          - `city` string — The city of the location
      - `isPrivate` boolean — Whether the field is private
      - `valueLabel` union — The label of the custom field value. Only present for ValueSelect fields.
        - string
        - string[]
  - ErrorResponse
    - `success` false, required
    - `errors` ErrorDetail[], required
      - `message` string, required
      - `parameter` string

---

[API](https://skmtc.net/ashbyhq/apis/ashby-api.md) · [All operations](https://skmtc.net/ashbyhq/apis/ashby-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/ashbyhq/ashby-api/revisions/778b919dc743/schema)
