Custom Fields

Create a new custom field

Returns the newly created custom field object.

De-duplication: If a custom field with the provided name already exists, an error would be returned in the format of:

{
    "code": 400,
    "errors": {
        "json": {
            "custom_field": {
                "id": "example_custom_field_id",
                "is_hidden": false,
                "name": "multi_select",
                "options": [
                    {
                        "id": "example_option_id",
                        "is_hidden": false,
                        "value": "example_value"
                    },
                ],
                "project_id": "UHJvamVjdDox",
                "scope": "project",
                "value_type": "multi_select"
            }
        }
    },
    "message": "A custom field with the name already existed",
    "status": "Bad Request"
}
post/v0/custom_fields

Request

  • Base URL
    https://api.gem.com (the document declares no server; this is the origin it was published from)
  • URL
    https://api.gem.com/v0/custom_fields
  • Auth
    none declared

Request body

namestring required

The name of the custom field is unique in its scope. Any leading and trailing spaces of the name string will be removed.

value_type'date' | 'text' | 'single_select' | 'multi_select' required

When value_type is text, value is a string. When value_type is date, value is a string of format yyyy-mm-dd. When value_type is single_select, value is a string of an option value. When value_type is multi_select, value is an array of strings of option values.

scope'team' | 'project' required

Custom fields under team scope apply to all candidates. Custom fields under project scope apply to candidates in a specific project.

project_idstring ObjectID nullable

Applicable and required when scope is project. If the custom field has project scope, this is the project ID that its associated with.

option_valuesstring[]

Applicable and required when value_type is one of (single_select, multi_select).

Response

Created

idstring ObjectID
created_atinteger
namestring
value_type'date' | 'text' | 'single_select' | 'multi_select'

When value_type is text, value is a string. When value_type is date, value is a string of format yyyy-mm-dd. When value_type is single_select, value is a string of an option value. When value_type is multi_select, value is an array of strings of option values.

scope'team' | 'project'

Custom fields under team scope apply to all candidates. Custom fields under project scope apply to candidates in a specific project.

project_idstring ObjectID

If the custom field has project scope, this is the project ID that its associated with.

is_hiddenboolean

hidden custom fields in the candidate info are not displayed in the Gem product or not returned when making a query on the Candidates endpoint.

Changes

No recorded changes to this operation across all 1 revision of this API.