BookatlasTwo-Day MuleSoft → Salesforce Bootcamp
77 / 81 · Module 18 — Interview Coding Scenarios · filtered: interview← prev⊞ allnext →

18.24Scenario 23 — Account then Contacts

Prompt:

“Write pseudocode for creating/updating an Account and then Contacts.”

Write:

POST /customer

Validate request

vars.original = payload

Transform Account

Salesforce Upsert Account
by External_Customer_ID__c

vars.accountId = payload[0].id

Transform:
vars.original.contacts
map Contact with AccountId = vars.accountId

Salesforce Upsert Contacts
by External_Contact_ID__c

Build response

That's perfectly acceptable whiteboard code.