Skip to content

Salesforce - Create Record

↩ Part of the Salesforce integration.

Creates a record of any sObject (POST /sobjects/{sobject}). You name the object, pass its fields as JSON, and the node returns the id Salesforce assigned.

It is the natural next step after a form, a webhook or an order: turning an incoming request into a Lead, an Account or a Case.

FieldTypeRequiredDescription
credentials_idcredentialsYesSalesforce credential
sobjecttextYesAPI name of the object: Account, Contact, Lead, Opportunity, Case, MyObject__c…
fieldsjsonYesRecord fields, e.g. {"Name":"ACME"}

Both sobject and fields accept dynamic variables: the fields string is resolved as text before being parsed as JSON, so {"Email":"{{data.email}}"} is valid.

This module requires a Salesforce credential:

FieldDescription
login_urlhttps://login.salesforce.com or https://test.salesforce.com for a sandbox
client_id / client_secretConsumer Key and Secret of the Connected App
usernameSalesforce user
passwordPassword plus the security token, concatenated

data is a small object with the new id:

{
"id": "00Q5g00000AbCdEFGH",
"success": true
}

Along with it, _meta:

{ "moduleVersion": "1.0.0", "success": true, "id": "00Q5g00000AbCdEFGH", "totalMs": 380 }

The node does not return the full record. If you need the stored values (formula fields, auto-numbers, defaults), read it back with Get record.

{
"credentials_id": "salesforce_prod",
"sobject": "Lead",
"fields": {
"LastName": "{{data.lastName}}",
"FirstName": "{{data.firstName}}",
"Company": "{{data.company}}",
"Email": "{{data.email}}",
"LeadSource": "Web"
}
}
{
"credentials_id": "salesforce_prod",
"sobject": "Account",
"fields": {
"Name": "ACME S.A.",
"Phone": "+34600111222",
"Website": "https://acme.com",
"Industry": "Manufacturing"
}
}
{
"credentials_id": "salesforce_prod",
"sobject": "Opportunity",
"fields": {
"Name": "ACME - annual renewal",
"AccountId": "{{data.accountId}}",
"StageName": "Prospecting",
"CloseDate": "2026-12-31",
"Amount": 12000
}
}
{
"credentials_id": "salesforce_prod",
"sobject": "Case",
"fields": {
"Subject": "{{data.subject}}",
"Description": "{{data.message}}",
"Origin": "Web",
"ContactId": "{{data.contactId}}"
}
}
  • Field keys are API names, case-sensitive, and custom fields end in __c. LastName works, lastname does not.
  • Relationships are set by id: AccountId, ContactId, OwnerId. To link by an external key instead, use Upsert record.
  • Dates go as YYYY-MM-DD, date-times as ISO 8601 (2026-12-31T10:00:00Z).
  • A 400 with REQUIRED_FIELD_MISSING means a mandatory field is absent (LastName and Company on a Lead, Name on an Account, StageName and CloseDate on an Opportunity). Validation rules and duplicate rules surface the same way. These errors are not retried — fix the data and run again.
  • If fields is not a JSON object (an array or invalid JSON), the node stops before calling Salesforce.