 Okay. Let's go live. Hello, everyone. I am Sanjay Gupta. I welcome you on Sanjay Gupta Tech School. So today we are having one more session that is on Salesforce Omni Studio. So it is episode six. So till now we have completed five episodes in this season two. In those sessions, Abhishek delivered different scenario implementation. Those were related to data rector. So today also I have Abhishek with me and today he will be explaining you few scenarios which are based on integration procedures. So you will get to know how you can integrate your data rector with integration procedures so that calculations can be done. So data rector is just to fetch data to store data. But in integration procedure we can do some calculations also. So you will get to know about those. So welcome Abhishek once again on the platform. And over to you please let everybody know about you. Yeah. Thank you Sanjay. So hi everyone myself Abhishek and I am working as a Salesforce velocity developer in this ecosystem since five plus years now and I have done some certifications around Velocity slash Omni Studio as well as some certification around core Salesforce as well. And some of them are like Omni Studio developer and then some industry specific certifications like industry CPQ then I am also holding a certification around health insurance voting which is also from Velocity and some of the Salesforce certifications. So yeah, thanks all about. Okay thank you Abhishek. So guys if you want to become part of a community where lots of folks are connected and they are just exchanging their information on Salesforce so you can join and you can scan this QR code. It is on telegram so you can join that. And if you are following all the sessions so please provide some reviews or feedback about the bootcamp. Okay so I think we can start with the scenario implementations now. So we'll be having three scenarios. So data adapter turbo extract data rector extract and data rector load. So you will get to know like how you can use these like data adapters different data adapters in integration procedures. Over to you Abhishek. Yeah. So I mean like the way Sanjay have mentioned like right till now we have completed all the data adapter scenario for all four types of data adapter and in today's session we're going to implement the integration procedure. So if you are following us the following us from the season one then IPs or integration procedures are generally used for you know whenever you want to build some sort of business logic the way we do into our apex classes let's say you are fetching some sort of data from SQL and now you want to do some sort of modification or by creating any loop writing any loop you want to do some business logic and build some build some some sort of logic in there that that we can do with the help of IP and I mean like obviously I mean data adapters all alone cannot be there are there is no use for them in order to use data adapters we have to create IPs or omniscripts. So that's the panda. So in today's session we're going to execute three scenarios where we will be calling our three data adapters type turbo extract extract and the data adapter load from the integration procedure. So let's jump into the art now. I think this is taking a bit of time. Yeah sometimes it happens. We're going to create a new integration procedure and I mean like just to reiterate I mean you must you all must be knowing I mean how integration procedure we can configure what are the properties of integration procedure. So just a just a recap. This is your IP name. This is an IP type and subtype and the combination of type and subtype is the uniquely identifier for an IP and label you can give it anything you want to like. So I'm going to get like IP example data vector turbo and here I'm going to say let's say IP will be my type and example DR turbo will be my subtype. So that's how we can create an IP. These type and subtype can also be custom anything we can write here. Yeah and the basic funda behind type and subtype is like let's say you want to build five integration procedures around the account object. So you can keep the account type as account and subtype as per the functionality. So that I mean like when we will be we will be having the component sheet we will be able to categorize all of the components like these IPs are related to account object. Right. So IP contains three sections. First is available components second is structured and third is properties and in the properties we have a preview as well which is similar to the data vector just pass the input parameters and execute and you'll get output. So in the in the available components you will be you will be able to see similar things which we have in epics like cache a block conditional loop track edge and in actions you will be able to see all of the actions that you can perform by using an IP like chatter action expressions at DR all four types of DR actions some delete actions Dr. Ryan's email and even you can call an IP from an IP. So these are the available components which you can use and it's a it's a zero zero port component. So you don't have to write any sort of component like if you want to use a loop log you can I mean this loop block will execute in the format of loop block but you don't have to write anything. So in order to call in data after turbo turbo we will be dragging and dropping the DR turbo action from available components to the structure panel and here you can give the name as like DR turbo. So this is your you can say that element name. So this this structure can contain multiple multiple actions or groups and you have to give a unique name to each and every element. So I'm going to give like DR turbo let's account extract and in this data after interface when as soon as you click on this one you will be able to see all the data after turbo extract that you have into your environment a Salesforce environment. So let's say I'm going to select this DR TV account records and when you click on this small icon which is kind of an attachment icon if you link icon if you click on this you will be able to navigate to the data after from the IP only. So in this data after what we are saying is give us the values of active where and the rating where and you will get the output and if I go to preview and click execute I will be able to fetch one account with this input parameters rating where and acting where active where. So similarly if I want to call this data after from IP I have to pass these these parameters. So how you can pass these parameters from the IP you can go to the input parameters and on the left hand side you have to write the exact parameter name that you have into your data app. So for example I have a first parameter is active if I go here and I can pass a hard coded value for now and similarly the other parameter is rating where and the second parameter let's say it is hard okay and if I go to preview now if I click on execute you will be able to see two sections in this IP first is the response response section and second is the debug lock section errors debug log output section similar to the data actor kind of in the response you will see the response that data actor is given error debug you will be able to see all the queries and all these things but IP works a bit differently. So let's say I have executed I have drag and drop the element data actor turquoise set and we have called the data actor and we have passed the input parameters but similar to data actor it will not give us the output into the response it will give us the output into the response but there is a way of doing it that I'll be explaining now but if you see the debug logs in the debug debug logs you will be able to see so many things debug response full debug log full data JSON response original input execution sequence and after that execution sequence you will be able to see your element names so I just drag and dropped only one element which is dr turbo account and for that there are two elements dr turbo account and dr turbo account debug right so if you click on the dr turbo account debug you will be able to see what inputs you are passing to your data actor okay and if you click on this dr turbo underscore account you will see what data actor is giving back to this IP right okay so I mean if you want to know more about more about these things what are what are these you can follow the season one IP sessions you will be able to understand so so back to the back to the response section I mean like unlike not similar to the data actor it will not give us the output directly into the response section in in the IP the reason is data actor will only have one query or multiple queries or in the in the mappings I mean like the mappings are fixed like these mappings will always come into the data output that is where response action response gets generated automatically but in IP what happens we can have multiple elements we can call dr turbo then we can call dr extract then we can call some sort of email action so IP do do not know what output you need into your IP similar to epics when you are creating an epics method you can fetch multiple data but as a return type what you want to pass that is up to you so in the IP also we have one thing called as response action so in this response action you have to give so let's say I want the output of this element dr turbo account right so in the sand response transformation I have to give this dr turbo account and if I go to execute now now it will give me the output into the response section right so in the IP we have to specifically tell that what you need into your output so that's the point of IP and if we have two data adapters so we need two response actions or one can no so I mean like we can do in that way as well we can have two response action and according to whatever data adapter is getting called we can show the data but standard way is like let's say I am calling another data adapter turbo extract okay just give me a second and I'm going to give the name as this and I'm going to call the same same data adapter here as well so if you see I have called the drt same and if I go to preview it will give me the only the account the first element but I am having the response from dr turbo account one element so if you want the output from both both of them then what you have to do is you have to go to the additional output and now you have to create multiple mappings so like this okay this will be your one and oh sorry okay so on left hand side like same name and on right hand side different no yeah I mean like on the left hand side you can give whatever you want to do but on the right hand side you have to use the same name that you have used as your element names right right and okay both the results will be combined and it will be rendered and as the response correct okay two different lists because we have created you know for the dr turbo account we have created another variable as output and for dr account one we have created another variable okay so this is how you get results from multiple elements and similar to this turbo extract we can use extracts also like same way right correct so I mean like the next example will be for the data rector turbo data rector extract so and one more thing in above sections and response transformation we have four options so we use send json path it will be like showing data in the response then correct we have sent json node response json path and response json node so these are also useful or not so these are useful so okay I'll tell you the significance of these two things if I go here dr turbo account I'm going to delete this one I don't need this anymore preview execute so my data is coming now what I want is as whatever result I'm receiving in this dr turbo underscore account I want this data into a parent node okay so what I can do here is let's I'm gonna say account records okay so that data will go into under this json node correct so this will come under this right and so basically there are two concepts whenever we are calling any sort of element from an id first is for example when I'm calling this data rector turbo extract right so in this element I am sending some data to the data rector and I'm receiving some data from the data rector right right so in this data rector also you can see we have these options so I mean like right now we have to pass two parameters that is why we have used the input parameter if I wanted to pass only one parameter I would have done that in that way as well so that would have also worked okay but so what will happen so my results are coming into this acc data right so if I go here and let's say I want my acc data into acc data one okay and if I click on execute so now you can see the response is null and oh okay so what I want is that as an output of this data rector I just want only acc data active field only not all the output so if I click on execute here and if you see the output you will receive only no value okay correct so if you want to trim down your data within the data rector element only then you can use this thing okay so like in real-time scenarios like is it useful or not sometimes it is useful because let's say your data rector is giving you a multiple list let's say account list contact list opportunity list for example and as an output you just only want account list so here you can just trim down your data okay rather than receiving all the data you can trim down your data and you can use that okay and here data like node name is acc data I think we didn't provide this anywhere or we no this no if you remove this still like in the response it is coming as acc data correct yeah I mean like it will come like this okay so I mean that acc data node have been removed from if you can see no but that name acc data from where it was coming this one this is coming from the data okay okay yeah this is coming from data right so so yeah if I go come back to the the fundamentals so in the element call you are passing some data and you are receiving some data correct so these four nodes will be useful for you but in the response action only the sent json path and sent json node will be useful the reason is in the response action you just only pass the data you don't receive any data back from the response action if you write anything in there there will be no use of it so I mean like you can say it's it's a it's kind of a thing that omnis studio provided but it doesn't make any sense okay yeah so let's go back to our new omniscript sorry new integration procedure and we'll call the data after extract from it let's call it ip underscore example dr extract here we're going to select the ip again and for this one we will say dr extract and in the similar way we will drag and drop one dr extract action let's call it as a account sorry dr e underscore account and in this in this one you will be able to see all the data after extract not data pollute node that are up to targo for example let's i'm going to use this data rector account records and if I open this data rector here we just need to pass active parameter the similar way to be passed to the data rector turbo if I go back here input parameters this let's say no okay let's say yes and similarly we'll add one response action and in the data this data rector account let's have into the response and if I go to preview click execute I will receive whatever data is being retrieved from the data rector now what will happen let's say I am passing a hard coded value from here right yes well for example I want to use this ip into multiple only script from one I want to pass yes from one second I want to pass no so that would be problematic for me because I have to create another ip for that so in order to resolve that thing what we can do is here we can say active active param and this input we can pass it from the input parameters so now if I pass no so I will receive the values as whatever accounts have active as no so basically this ip becomes dynamic now it's kind of a dynamic mapping for your ip the similar way we did for the data rector we can do it for the ip so similar concept everything is similar in this one as well all send this one and all response action thing last thing that we're going to do is I mean that would be also pretty simple as I mean like I have mentioned into the previous sessions as well we have mentioned in the previous sessions like if you know the concept of data rector in a good manner or in a perfect manner you will be able to incorporate ip omniscript and flexcard very easy so data rector is the only concept concept where you need to learn how it is tricky how what are the tricks that we can perform because as you can see now it becomes very easy to use ip I mean I know we have so many options in there but I mean calling in data rector from an ip it's very easy we are we don't have to use our logical mind here right right just drag and drop correct for this one as well I'm going to call it like ip underscore example we are load data rector load sometimes called as data rector post section as well so don't get confused by this one data rector post section is kind of for calling a data rector load yeah this is very important to learn sometimes it is like confusing yeah data rector so I generally call data rector load always like data rector post I mean whenever I create a data rector load as well I always call it data rector post yeah because load load means we are getting some data correct and post makes sense yeah yeah so as soon as you will click on this one you will get all the account I mean like whatever data rector load you have created in your org so let's I'm gonna use this one dr load insert account and this one I think will be expecting only the account name so we're gonna pass this ecc name from here and as you can see let me go back to the data rector extract here we have this input parameters but into the data rector post action we don't have that one so the main reason behind that is whenever you are calling a data rector turbo data rector extract there will be a pop I mean like you can think of think of it like it as a SQL query right where you can where you are passing the where clause but when you are calling the calling a data rector post or data rector load action you have to pass a list of record a single single record so it cannot I mean like if you want to create an account there will be at least two three fields that you wanted to pass you will pass so you always pass those things as a object in the json format so that's why they they haven't included that input parameters section into the data rector post so if you want to pass multiple things you can always click on this additional input and you can pass like this let's I'm gonna hard code is like a sgts account if you and for example let's say you are already receiving an object from your flex card or your opening script you will be getting into into a node right so that node you can pass into the send json node that will automatically get passed to your data rector data rector load correct so right now I just want to pass only one parameter that is I am using the data send only additional inputs if I'll be I will be having object then I can pass it from the send json path or I can pass it from the additional input as well there is no detention and this acc name it should be same as it is available in data rector right yeah this one yes okay and whatever I mean like this data rector post is giving us we I want either the output and if I go to preview and execute so as you can see this data rector is giving me this output because I have mapped the name ID ID is coming automatically and as object type and absurd success is also true because I think we have the absurd okay we don't have the absurd but okay I mean like this this is the default functionality of data rector so if I go here and see the output of this this is what I'm receiving from the data rector correct so let's let's say you want whenever you have inserted an account with the help of an ip and you want this id to be used further into your omniscript or flex card this you can take this ip into your omniscript and you can use it anywhere okay yeah I think that's it on the scenario side and if we if you're using in our data rector load like multiple bulk data we are creating so in in ip like how we can pass the data because we just passed one name here and suppose data rector load is creating multiple records okay so from here we need to create json right correct correct so what okay I'll give you an example so let me do one thing I think it should be similar to data rector load because there also we create this json as an input yeah data rector extract okay so what we can do is we'll copy this data from here we'll paste it here and close this one so that we'll be able to come this I think we need to have one more curly basis outside yeah and now we are just passing the as an input we we are just passing this acc name so I'm going to replace all the names with this and I don't want this this this because I'm not passing these and now what we will do here is comma we have put them again yeah so now we have a list of accounts where we have two accounts where let's say it's as is the svp1 there is a psvp2 and now what we're gonna do is from the data rector yeah as a whole we will just pass this send into json but okay and these two objects will get passed to your data rector and if I if I click on execute this will give me the result of two accounts right so this is how you can use it for the bulk update so bulk insert so for individual we can use key value pair and otherwise we need to use that send json path json and also I mean like if you will pass this thing from here as well uh this will also work now but now the only reason only change that we have to do into the data rector is uh before this ecc name you have to append that account as well right right okay and whenever we will be using this ip into omniscript of flexcard so this account name we need to use there as well because here we are receiving correct to account correct okay so yeah I think yeah so I think all three examples you covered so whoever will watch this video so automatically like will be able to understand how different data rectors we can integrate with integration procedure and when omniscript and flexcard will be learning so this all the dots will be connected like how a data rector is passing data to ip then ip to omniscript and the reverse order also yep so um I think we can have a couple of more session on ip so that we can explain few more scenarios but that we will be doing in the next week and next to next week like one one session we can do for omniscript and flexcard and then we will be like explaining some projects so that end to end people can understand like how these things are connected right okay so thank you so much for sharing your knowledge and thank you for whoever is watching live and thanks to those also who are watching the recordings so please follow all the sessions because here we are just focusing on the scenario implementation no theoretical thing so if you go through all these scenarios so I think it will give you more insight like how practically you can implement things in omnis studio okay thank you so much for joining this session see you in the next session bye everyone