Jobs API - Added support for referencing custom field values by external code
Description
The Create Job (POST /jobs), Update Job (PUT /jobs/{id}) and Patch Job (PATCH /jobs/{id}) endpoints now accept an externalCode alongside the existing id when providing a value for a single-select custom field property (e.g. picklist, foundation object, or generic object):
{
"properties": [
{
"id": "JOB_FIELD_ID",
"value": {
"externalCode": "FULL_TIME"
}
}
]
}externalCode is the source system's natural key for a value: the stable, human-readable identifier assigned by the external system (e.g. SuccessFactors externalCode on picklist entries or org objects). It is used to correlate SmartRecruiters field values with their counterparts in the originating system, letting you reference existing values without first looking up their internal id.
Getting a job (GET /jobs/{id}) now also returns the resolved externalCode, alongside the existing id and label, for any property value that has one.
Example property value with externalCode:
{
"id": "JOB_FIELD_ID",
"value": {
"id": "abc123",
"label": "Full Time",
"externalCode": "FULL_TIME"
}
}Example property value without externalCode (field absent, not null):
{
"id": "JOB_FIELD_ID",
"value": {
"id": "def456",
"label": "Part Time"
}
}Impact
This is an additive, backward-compatible change. Existing requests using value.id continue to work unchanged. Providing both id and externalCode for the same property is rejected as invalid input; providing a single-select property with neither results in a validation error.