Introduction #
In this tutorial, we will learn about what is Salesforce ID Handling with request and response? Why do we use this feature? and how to use this feature? This function is the new feature that allows to use in Skyvva version 2.47.11 and go on.
What is Salesforce ID Handling with request and response? #
Salesforce Id Handling is a feature that Skyvva enhances in adapter that uses the response of the system to update the records that are sent.
As a field property in all adapters, Salesforce ID handling with request and response is new functionality. This is a picklist field, and there are two options: “None,” which is the default behavior and does not return the Salesforce ID into the response, and “Return Salesforce ID into the response,” which does return the Salesforce ID into the responses.
Why do we use this feature? #
When a user requests records from Salesforce and requires the response to update the record on Salesforce, this functionality comes in useful. Example: In Sap Business One Client Server, a user requests records from Salesforce to the BusinessPartners module. As a result, when a user makes a request to the BusinessPartners module, the response will be returned, and the user will require some values from BusinessPartners that are contained in the Response in order to update the records for which the user made the request.
How to use this feature? #
Pre- Required:
- Create Integration
- Create Connection destination on SAP Control Board.
- Generate SAP Business one Metadata by using Import SAP Metadata.
- Create Outbound Interface and Inbound Interface linked with Metadata SAP Business one.
- Create SAP Business one Adapter on SAP Control Board.
Step1: Create Integration
- Here’s the Integration
Step2:Create Sap business one Connection
- Click SAP Control Board on Integration
- Here’s an example.
- Fill Host URL, Port Forward, Username, Password, URL Path, and Company Database of SAP Business one Application.
- Click ping SAP Connection and Click Save Button.
- Here’s Example.
Step3: Create Metadata SAP by using SAP Import Metadata.
Note: We need to create Metadata and a Repository.
- Go to Repository and click Import SAP Meta
- Choosing Direct SAP Connection? select Connection Type, Select Connection Destination, Choose to Create Message Type to invoke SAP Business One API, and click Retrieve.
- Search Metadata Name Business Partner, choose business partner, and click create Message Type.
After that, we will see the message type object Business Partner.
- Here’s the message type of business Partner.
[su_box title=”Note” box_color=”#2a8af0″ title_color=”#000000″] To Update the records from response we need to mapping the request Interface and the response Interface as the same level. Example: If we want to get response Account contact and case, we need to map both Interface Account contact and case too. [/su_box]
Step 4: Create Outbound Interface, Inbound Interface, and linked with Message Type that we generated.
- Create Outbound Interface as a Request Interface and linked SAP BusinessParner message type.
- Here’s Request Interface.
- Do mapping and click save.
- Create Inbound Interface as Response Interface and linked SAP Business Partner message type.
- We use operation Updates to avoid creating a new record.
Here’s Response Interface
- Do mapping
[su_box title=”Note” box_color=”#2a8af0″ title_color=”#000000″] To use the response salesforce ID to update the records, Each level of mapping need fomula Id from Business object object to Salesforce ID. [/su_box]
– See the example,
- We need to put Id manually.
- Each Node needs to map Id like above if we want to update their children.
- Go to Request Interface to link the response Interface.
- Scroll down and put the response Interface.
Step5: Create SAP Business One adapter.
- Go to the SAP control board and click tap Adapter.
- Click New Button.
- Fill Name, Type: SAP Business one, Deployment: On-Premise, Integration Framework: Service Layer, Protocol: Rest, Authentication: Basic, API service Endpoint Url: Business Partners, Choosing Operation Post, Request and Response Format Json, salesforce ID Handling and choosing connection Destination.
- Click ping connection to make sure that we configuration adapter is success and click save
Here’s Example.
- Go to Request Interface and Linked this adapter.
- Here’s example
Step 6: Callout Data by using Manual Process.
- Go to Interface tap on SAP Control board, select Request Interface, and click Manual Process.
- Select Manually Select the subjects using the Query Builder and click Next.
- Click Execute SOQL, select record that we want to send to SAP business one, and click OK.
- Click Send
- Go to message Monitor to see the result.