Ingest sample data ÃÛ¶¹ÊÓÆµ Commerce Optimizer
Learn how to ingest the sample data for your ÃÛ¶¹ÊÓÆµ Commerce Optimizer instance. This video outlines the entire process from start to finish using the official GitHub repository readme as a guide.
Who is this video for?
- Commerce Solution Architect
- Technical Marketing Engineers
- eCommerce Platform Administrators
Video content
- Ingest sample data for an ÃÛ¶¹ÊÓÆµ Commerce Optimizer instance step by step.
- Create Policies.
- Create Catalog Views.
Hi, this is Russell with ÃÛ¶¹ÊÓÆµ Commerce, and this session is about adding sample data to your ÃÛ¶¹ÊÓÆµ Commerce Optimizer instance. You can read the in-depth doc guide, Get Started with ÃÛ¶¹ÊÓÆµ Commerce Optimizer, that can be found in Experience League whenever you’re ready.
This sample data was created to help with the Storefront and Catalog Administrator end-to-end use case. This use case is based on a fictitious automobile conglomerate called Carvelo Automobile, and it demonstrates how to use ÃÛ¶¹ÊÓÆµ Commerce Optimizer to manage a catalog that supports multiple brands, dealerships, and price books.
This document guide can also be found in Experience League and read whenever you like. For now, it’s time to head over to the GitHub repository, and we’ll start with the readme. The first step is to ensure that we satisfy some dependencies. The first is to be able to clone the repository. We’ll use a terminal window and run the git clone command, and we’re also going Once again, we’re looking for the instance ID, and we can copy this value, and it’ll be used for a future task. Up next is generating IMS credentials. It’s important to note that you need to make sure that the organization used to create your Commerce Optimizer instance matches the organization that you’re logged into for your ÃÛ¶¹ÊÓÆµ Developer Console. Otherwise the permissions won’t link up. Clicking Create New Project starts the process. And then we’re going to click Add API. And then we’re going to choose ÃÛ¶¹ÊÓÆµ Commerce Optimizer Ingestion.
Next we’ll choose OAuth Server to Server. And then I’m also just going to give it a new name.
So with that new name entered, we can click Next. Then we can choose the default cloud manager. And at the bottom right, we can hit Saved Configured API.
Now we can hit Generate Access Token. And doing this exposes some values that we need for our next step, which is configuring Those environment variables are located in the same directory that we cloned the GitHub repository earlier. We’re going to head back to our terminal window. We’re going to copy the .env.dist. And we’re going to create a new file called .env. And we’re going to enter some of the values that were retrieved earlier in our previous steps, starting with the tenant ID. And then we’re going to enter the client ID and then the client secret. And then if we’re happy, we use colon wq to save and quit. And we’re ready to move on to the next step, which is starting the data ingestion.
So we’re going to open up our terminal window again. And as long as we’re in that same folder that we checked out the GitHub code, we’re ready to type in the command node space index.js. And after we hit enter, it’ll start the catalog ingestion process. And you can see it happen in small batches. Once it’s done, you’re ready to move on to the next, which is going to be creating catalog views and policies.
We’re going to head back over to experience.adobe.com. And we’re going to ensure that we’re using our correct ÃÛ¶¹ÊÓÆµ Commerce Optimizer instance. And it’s time to create our first policy. On the left hand side, click policies and then on the top right, add policy. We’re going to start by giving it a name, West Coast Incorporated Brands. And then we’re going to click add filter. Our first one is going to be the attribute of brand and the operator will be in.
We’re going to do the value source of static and our values are going to be Aurora, Bolt, and Cruise.
And then we can just double check to make sure everything looks good. Go ahead and hit enter to save those as selected values. And then if we’re happy, we can go ahead and hit save. And one thing to note is that these are going to be disabled by default. So every time you create a new policy, they’re disabled. So you’ll have to click on those three dots and it’ll expose some new statuses. We’re going to change it to enabled. And one other thing to note is that at this point, nothing’s actually been saved. So if you hit that arrow to head back to create a new policy, you’re going to get a message that asks you if you want to cancel your changes. In this case, we don’t want to do that. We actually do want to save it. So on the top right, we’re going to click save and then we’re given our green message at the bottom and we’ve successfully saved our policy. Now we can hit that arrow to go back and create a new policy.
So if you follow that read me, you’re going to be aware that there are more policies that you need to create. And the process is exactly the same. I’m not really going to bother you showing you all of those right now. And you can go ahead and take care of the rest of them on your own. Now it’s time to create catalog views. So once again, I’m going to show you the first one, but the process is identical for all of them listed in that GitHub read me.
So let’s go ahead and get started. We’re going to click a create catalog view on the top right. And we’re going to start by giving it a name. And for this one, we’ll use the name global.
Our catalog sources for now we only have one en-us.
For policies, it’s a dropdown. So we’ll go ahead and select brand, but you’ll notice that it filters as you type or whatever’s left in the box. So you could go ahead and type in the word modal and you’ll notice as you do, it’ll filter out the list. So we’re going to try to find one more, which is going to be West and that’s part of West Coast ink brands. So as we start typing it in West Coast, our list will shrink and it’ll give us the option to select it.
So I think that we’re good. We can hit the save catalog and it worked. We’ll get our green message at the bottom and now we can hit the back arrow to start the process all over again to create the rest of the policies.
So our final step is to head back and look at our data sync because we’re going to make sure that all of the products that we expected were ingested. So by clicking on data sync, it does look like 1,080 products were ingested, which is exactly what’s in the sample data. So at this point we’re in good shape. We can start to test our code using GraphQL, but that’s in a different session. And that’s all for this session for ingesting sample data in your ÃÛ¶¹ÊÓÆµ Commerce Optimizer project. I hope you continue to come back to Experience League to learn more about ÃÛ¶¹ÊÓÆµ Commerce as well as all of the other ÃÛ¶¹ÊÓÆµ products.