SK SKYVVA Documentation

4. How to use Push JSON Payload to Agent Using V4/integrate?

Introduction:

We have two types of response:

  1. standard response
  2. custom response using the response (outbound) interface to do the mapping
if we want to get data from the response interface then we need to do mapping for the response interface and link it to the request interface. Only data send from the input will return back as a response. If we want anything other than the input data then we have to use VLOOKUP formulae in the response mapping.

Difference between two api v4/integrate api to skyvva and to agent:

Incase of v4/integrate api to skyvva, data transformation happens on the Salesforce side using skyvva API., and Incase of an agent, Data transformation happens in Agent for the agent side API where agent works as a middleware. we are using agents to push data through the Agent to Salesforce.

Usecase:

Objective: custom response using the response (outbound) interface to do the mapping

Pre-requisites:

[su_box title="Note" box_color="#2a8af0" title_color="#000000"]

[/su_box]

Steps:

Follow the given steps to use v4/integrate api to agent for standard response: step1: Create Agent Inbound Adapter.

Then Go to the adapter tab and create an Inbound adapter. Here we are using the Rest adapter for the Inbound direction.

Step 2: Create Inbound Interface.  To create an Inbound interface refer tutorial from our website: How to create Interface?

Step3: Do mapping and save it.

[su_box title="Note" box_color="#2a8af0" title_color="#000000"]

[/su_box]

step4: Configuration on postman side

[su_box title="Note" box_color="#2a8af0" title_color="#000000"] Please make sure there is no  unwanted space after value inside query params[/su_box]

1. V4 API:-

V4 API pass Integration, Interface, mode, request-format, response-format parameter inside the URL query parameter.

2. The URL contains:-

Please check the sample below:- [aux_code language="javascript" theme="tomorrow" title="" extra_classes=""]http://3.122.44.62:9055/application/agent/rest/V4/integrate?integration=AgentV4/Integrate&interface=V4IntegrateSkyvva&instance-url=https://momentum-app-8830-dev-ed.cs101.my.salesforce.com&mode=synchronous&response-format=json&request-format=json[/aux_code]

3. Authorization:

4. Header:-

[su_box title="Note" box_color="#2a8af0" title_color="#000000"] To generate session id for your org:

Userinfo.getOrganizationId()+ Userinfo.getsessionId().substring(15) );

[/su_box]

5. Body:-

6. Send the Request:-

7. Check the Result:

8. Check Result on Message monitoring:-

Open this article in the interactive viewer →