Skip to content

Proxy Pattern

Use Case: Proxy Service transforms and enriches payload before creating record in Salesforce. We have system A where our support agents are working are not in Salesforce(system B). These support agents need to create case in system B . System A can invoke SOAP API’s. We do not want System A to directly make calls to System B. We want mediator to proxy System B. In our case we will use MuleSoft as mediator. Initiator: System A where support agents are working. Proxy: MuleSoft is acting as a web service… Read more Proxy Pattern

Relate Salesforce records using external id in related objects.

Salesforce provides convenient way to related records when creating or upserting records for lookup relations. Using external id of related records avoids use of performing lookup SOQL queries when integrating records using create or upsert operations. Import Salesforce WSDL into SOAP UI, use create request and format message to use external id, example when creating Case to an Account(Customer) we can use external id of Account object and modify request message to replace accountId fields with following snippet. This will relate to Case to Account where external id is specified.… Read more Relate Salesforce records using external id in related objects.

Enforcing CRUD and FLS in Apex

Salesforce apps runs under two contexts one is user context and other is system context. User context is the default context that we see when you’re interacting with the UI in Salesforce, In user context, the current user’s permissions, field-level security, and sharing rules are taken into account as we browse the UI or execute code. Application executes in user context when: A user browses the application via the standard Salesforce-provided UI. A user views a Visual force page that uses a standard controller. A user views a Visual force… Read more Enforcing CRUD and FLS in Apex