Four causes, one error message
The message names the value it rejected, which is useful, and says nothing about why, which is not. Working through the four possibilities in order resolves it faster than staring at the string.
First and most common, the payload carries the label rather than the value. Admins rename labels for the UI while the underlying value stays fixed, so the two drift apart and a mapping built by reading the UI is built on the wrong strings.
Second, a case or whitespace difference. Matching is exact: "Closed Won", "closed won" and "Closed Won " are three distinct strings and only one is the value. A trailing space arriving from a spreadsheet import is invisible in every log you will look at.
Third, an inactive value. A value that was deactivated rather than deleted is still visible in the field's configuration and is rejected exactly like one that never existed.
Fourth, a record type restriction. The value is in the global set and is not among those the target record type exposes — see the record type guide on this site for the endpoint that answers that specifically.
The rejection is exact-string, case-sensitive, whitespace-sensitive and scoped to the record type. "It looks right" is not a test; a character-by-character comparison against the describe value is.
Get the authoritative value set
One describe call returns every entry on the field with its value, its label, whether it is active and whether the field is restricted at all. That settles three of the four causes immediately: compare your failing string against the values, check active, and confirm restrictedPicklist is true so you are debugging the right thing.
GET /services/data/v66.0/sobjects/Opportunity/describe
Authorization: Bearer ACCESS_TOKEN
# fields[] entry for StageName:
# { "name": "StageName", "restrictedPicklist": true,
# "picklistValues": [
# { "value": "Closed Won", "label": "Closed Won", "active": true },
# { "value": "Working", "label": "In Progress", "active": true },
# { "value": "Needs Review", "label": "Needs Review", "active": false }
# ] }
#
# Sent "In Progress" -> rejected. The VALUE is "Working".
# Sent "Needs Review" -> rejected. active is false.
# Sent "closed won" -> rejected. Case must match exactly.
The fix: a mapping step that fails loudly
Put a lookup between the source data and the Salesforce node — a Set node with an expression or a small Code node holding the map. It normalises the incoming value, resolves it to the exact API value, and routes anything it cannot resolve to an error branch rather than sending it onward.
That error branch is the important half. Without it, an unmapped value either fails at Salesforce (costing the whole batch on an allOrNone write) or gets quietly replaced with a default, which is worse because it writes wrong data successfully. With it, the workflow produces a readable item naming the field and the unresolvable value, and someone can decide whether the source data or the Salesforce configuration is what needs to change.
// n8n Code node — normalise to the exact Salesforce API value
const valueMap = {
"won": "Closed Won",
"closed-won": "Closed Won",
"lost": "Closed Lost",
"in progress": "Working", // label "In Progress", value "Working"
};
const raw = String($json.stage ?? "").trim().toLowerCase();
const sfValue = valueMap[raw];
if (!sfValue) {
return [{ json: { error: "unmapped picklist value",
field: "StageName", raw: $json.stage } }];
}
return [{ json: { StageName: sfValue } }]; // exact value, exact case
Three things that look like fixes
Un-restricting the picklist makes the error stop and lets bad values flow into Salesforce permanently, breaking reports, validation rules and downstream automation that assume a clean set. It converts a visible failure into an invisible one.
Blanking the field to dodge the error only works if blank is genuinely correct. Sending null to a required restricted picklist swaps this error for a missing-required-field one.
Adding every source variant to the value set to force a match fills the picklist with near-duplicates — "USA", "U.S.A.", "United States" — and defeats the point of restricting it. When the business genuinely needs a new value, add that one value in Salesforce and enable it for the relevant record types before the workflow sends it. That is a configuration change, not something to work around in the integration.
Verifying
Take the exact value from the last failing payload and compare it character by character with the describe value: case, spaces, punctuation. That comparison identifies the cause in nearly every instance.
Then run one record for each distinct source value you expect and confirm each writes. Send a deliberately unmapped value and confirm it lands in the error branch and never reaches Salesforce. If record types are involved, run one record per record type — a value accepted for one and rejected for another means the mapping is not record-type-aware yet.
- Failing string differs from the describe value only by case, spaces or punctuation.
- The entry's active flag is true.
- restrictedPicklist is true, so you are debugging the right mechanism.
- Every expected source value writes successfully.
- An unmapped value is caught in the workflow, not by Salesforce.
- Mapped values are accepted for every record type targeted.
Multi-select fields fail one value at a time
A restricted multi-select picklist applies the same rule to every value in the selection, so a write containing four values and one typo is rejected in its entirety. The message names the offending value, which helps, but the mapping step has to validate each element rather than the string as a whole — a naive lookup on the joined value finds no match and reports the entire selection as unmapped.
Salesforce expects multi-select values separated by semicolons, and whitespace around the separator is part of the value. "Gold; Silver" with a space after the semicolon sends a second value of " Silver", which fails exactly as any other unexpected string would. Split, trim and map each element, then join with a bare semicolon.
Order is not significant and duplicates are worth removing before sending, since a selection containing the same value twice is not meaningful and can produce results that differ from what the payload appears to say.
// Map each element, not the joined string
const valueMap = { "gold": "Gold", "silver": "Silver" };
const parts = String($json.tiers ?? "")
.split(";").map((s) => s.trim().toLowerCase()).filter(Boolean);
const mapped = parts.map((p) => valueMap[p]);
const bad = parts.filter((p, i) => !mapped[i]);
if (bad.length) {
return [{ json: { error: "unmapped picklist values", field: "Tiers__c", bad } }];
}
return [{ json: { Tiers__c: [...new Set(mapped)].join(";") } }]; // no spaces
Where these facts come from