1.5.3 Connect ACCS to AEM Assets CS

IMPORTANT
In order to complete this exercise, you need to have access to a working AEM Sites and Assets CS with EDS environment.
If you don’t have such an environment yet, go to exercise Adobe Experience Manager Cloud Service & Edge Delivery Services. Follow the instructions there, and you’ll have access to such an environment.
IMPORTANT
If you have previously configured an AEM CS Program with an AEM Sites and Assets CS environment, it may be that your AEM CS sandbox was hibernated. Given that dehibernating such a sandbox takes 10-15 minutes, it would be a good idea to start the dehibernation process now so that you don’t have to wait for it at a later time.

After completing the previous exercise, you could see a product being returned by ACCS to your website but it didn’t have an image yet. At the end of this exercise, you should see an image being returned as well.

ACCS+AEM Sites

1.5.3.1 Update Pipeline Config

Go to https://my.cloudmanager.adobe.com. The org you should select is --aepImsOrgName--.

Click to open your Cloud Manager Program, which should be named like one of the below:

  • --aepUserLdap-- - CitiSignal AEM+ACCS
  • For in-person tech lab sessions: Tech Insiders - AEM + ACCS XX (replace XX by the number that was assigned to you)
  • For guided on-demand sessions: Tech Insiders On Demand - AEM + ACCS XX (replace XX by the number that was assigned to you)

ACCS+AEM Assets

Scoll down a little bit and then click Access Repo Info on the Pipelines tab.

ACCS+AEM Assets

You should then see this. Click Generate Password.

ACCS+AEM Assets

Click Generate Password again.

ACCS+AEM Assets

You should then have a password available. Next, click the copy icon next to the Git command line field.

ACCS+AEM Assets

Create a new directory in a location of choice on your computer and name it AEM Pipeline GitHub.

ACCS+AEM Assets

Right-click your folder and then select New Terminal at Folder.

ACCS+AEM Assets

You should then see this.

ACCS+AEM Assets

Paste the Git command line command that you copied before in the Terminal window.

ACCS+AEM Assets

You need to enter a user name. Copy the user name from the Cloud Manager’s Program Pipeline Access Repo Info and hit enter.

ACCS+AEM Assets

Next, you need to enter the password. Copy the password from the Cloud Manager’s Program Pipeline Access Repo Info and hit enter.

ACCS+AEM Assets

This maye take a minute. Once completed, you’ll have a local opy of the Git Repo that is linked to your Program’s Pipeline.

ACCS+AEM Assets

You’ll see a new directory in the AEM Pipeline GitHub directory. Open that directory.

ACCS+AEM Assets

Select all the files in that directory and delete all of them.

ACCS+AEM Assets

Make sure the directory is empty.

ACCS+AEM Assets

Go to https://github.com/ankumalh/assets-commerce. Click <> Code and then select Download ZIP. Download the file and then drop it on your desktop.

ACCS+AEM Assets

Next, copy the file assets-commerce-main.zip to your desktop and unzip it. Open the folder assets-commerce-main.

ACCS+AEM Assets

Copy all the files from the directory assets-commerce-main to the empty directory of your Program’s Pipeline Repository directory.

ACCS+AEM Assets

Next, open Microsoft Visual Studio Code and open the folder that contains your Program’s Pipeline Repository in Microsoft Visual Studio Code.

ACCS+AEM Assets

Go to Search in the left menu and search for <my-app>. You need to replace all occurences of <my-app> by techinsiderscitisignalaemaccs.

Click the replace all icon.

ACCS+AEM Assets

Click Replace.

ACCS+AEM Assets

The new files are now ready to be uploaded back to the Git Repo that is linked to your Program’s Pipeline Repository. To do that, open the folder AEM Pipeline GitHub and right-click on the folder that contains the new files. Select New Terminal at Folder.

ACCS+AEM Assets

You should then see this. Paste the following command and hit enter.

git add .

ACCS+AEM Assets

You should then see this. Paste the following command and hit enter.

git commit -m "add assets integration"

ACCS+AEM Assets

You should then see this. Paste the following command and hit enter.

git push origin main

ACCS+AEM Assets

You should then see this. Your changes have now been deployed to your Program’s Pipeline Git Repo.

ACCS+AEM Assets

Go back to Cloud Manager and click Close.

ACCS+AEM Assets

After making changes to the Pipeline’s Git Repo, you need to run the Deploy to Dev pipeline again. Click the 3 dots and select Run.

ACCS+AEM Assets

Click Run. Running a pipeline deployment may take 10-15 minutes. You need to wait until the pipeline deployment completes successfully before continuing.

ACCS+AEM Assets

1.5.3.2 Enable AEM Assets integration in ACCS

Go back to your ACCS instance. In the left menu, go to Stores and then select Configuration.

ACCS+AEM Assets

Scroll down in the menu to ADOBE SERVICES and then open AEM Assets Integration. You should then see this.

ACCS+AEM Assets

From the dropdown list for AEM Environment, select your environment.

Then, set Visualization Owner to AEM Assets (disable the use system value checkbox if needed).

Then, set Synchronization enabled to Yes (disable the use system value checkbox if needed).

Ensure that these settings are set as follows:

  • Asset matching rule: Match by product SKU
  • Match by product SKU attribute name: commerce:skus

Click Save Config.

ACCS+AEM Assets

You should then see this.

ACCS+AEM Assets

1.5.3.3 Update config.json

Go to the GitHub repository that was created when setting up your AEM Sites CS/EDS environment.

In the root directory, scroll down and click to open the file config.json.

You should see the below line in your config.json file (line 17 in this image), make sure it is set to true.

 "commerce-assets-enabled": "true",

ACCS+AEM Assets

If the value of commerce-assets-enabled is set to false, update your file and set the value to true. Then, commit your changes.

1.5.3.4 Verify Commerce Fields in AEM Assets CS

Log in to your AEM CS Author environment and go to Assets.

ACCS+AEM Assets

Go to Files.

ACCS+AEM Assets

Open the CitiSignal folder.

ACCS+AEM Assets

Hover over any asset and click the info icon.

ACCS+AEM Assets

You should now see a Commerce tab that contains 2 new metadata attributes.

ACCS+AEM Assets

Your AEM Assets CS environment now support the Commerce integration. You can now start uploading product images.

Download the product images here. Once downloaded, export the files onto your desktop.

ACCS+AEM Assets

Click Create and then select Folder.

ACCS+AEM Assets

Enter the value Product_Images for the fields Title and Name. Click Create.

ACCS+AEM Assets

Click to open the folder you just created.

ACCS+AEM Assets

Click Create and then select Files.

ACCS+AEM Assets

Navigate to the Product_Images folder on your desktop, select all the files and then click Open.

ACCS+AEM Assets

Click Upload.

ACCS+AEM Assets

Your images will then be available in your folder. Hover over the product iPhone-Air-Light-Gold.png and click the Properties icon.

ACCS+AEM Assets

Scroll down and set the field Review Status to Approved. The AEM Assets CS - ACCS integration only works for approved images.

ACCS+AEM Assets

Scroll up, go to the Commerce tab and then click Add under Product skus.

ACCS+AEM Assets

Add the following SKU’s for this product:

Key
Value
Usage
iPhone-Air-Light-Gold
1
thumbnail, image, swatch_image, small_image
iPhone-Air-Light-Gold-256GB
1
thumbnail, image, swatch_image, small_image
iPhone-Air-Light-Gold-512GB
1
thumbnail, image, swatch_image, small_image
iPhone-Air-Light-Gold-1TB
1
thumbnail, image, swatch_image, small_image

You should then have this. Click Save & Close.

ACCS+AEM Assets

Hover over the product iPhone-Air-Space-Black.png and click the Properties icon.

ACCS+AEM Assets

Scroll down and set the field Review Status to Approved. The AEM Assets CS - ACCS integration only works for approved images.

ACCS+AEM Assets

Scroll up, go to the Commerce tab and then click Add under Product skus.

ACCS+AEM Assets

Add the following SKU’s for this product:

Key
Value
Usage
iPhone-Air-Space-Black
1
thumbnail, image, swatch_image, small_image
iPhone-Air-Space-Black-256GB
1
thumbnail, image, swatch_image, small_image
iPhone-Air-Space-Black-512GB
1
thumbnail, image, swatch_image, small_image
iPhone-Air-Space-Black-1TB
1
thumbnail, image, swatch_image, small_image
iPhone-Air
1
thumbnail, image, swatch_image, small_image

You should then have this. Click Save & Close.

ACCS+AEM Assets

Hover over the product iPhone-Air-Sky-Blue.png and click the Properties icon.

ACCS+AEM Assets

Scroll down and set the field Review Status to Approved. The AEM Assets CS - ACCS integration only works for approved images.

ACCS+AEM Assets

Scroll up, go to the Commerce tab and then click Add under Product skus.

ACCS+AEM Assets

Add the following SKU’s for this product:

Key
Value
Usage
iPhone-Air-Sky-Blue
1
thumbnail, image, swatch_image, small_image
iPhone-Air-Sky-Blue-256GB
1
thumbnail, image, swatch_image, small_image
iPhone-Air-Sky-Blue-512GB
1
thumbnail, image, swatch_image, small_image
iPhone-Air-Sky-Blue-1TB
1
thumbnail, image, swatch_image, small_image

You should then have this. Click Save & Close.

ACCS+AEM Assets

Hover over the product iPhone-Air-Cloud-White.png and click the Properties icon.

ACCS+AEM Assets

Scroll down and set the field Review Status to Approved. The AEM Assets CS - ACCS integration only works for approved images.

ACCS+AEM Assets

Scroll up, go to the Commerce tab and then click Add under Product skus.

ACCS+AEM Assets

Add the following SKU’s for this product:

Key
Value
Usage
iPhone-Air-Cloud-White
1
thumbnail, image, swatch_image, small_image
iPhone-Air-Cloud-White-256GB
1
thumbnail, image, swatch_image, small_image
iPhone-Air-Cloud-White-512GB
1
thumbnail, image, swatch_image, small_image
iPhone-Air-Cloud-White-1TB
1
thumbnail, image, swatch_image, small_image

You should then have this. Click Save & Close.

ACCS+AEM Assets

Every iPhone Air image should now have a green thumbs up, indicating that the asset has been approved.

ACCS+AEM Assets

You should now repeat these steps for the remaining products, using the table below. Don’t forget to approve each image, and then configure the. below SKU settings in the Commerce tab.

Product Name
Key
Value
Usage
Apple Watch Ultra 3-Black
Apple-Watch-Ultra-3-Black
1
thumbnail, image, swatch_image, small_image
Apple Watch Ultra 3-Natural
Apple-Watch-Ultra-3-Natural
1
thumbnail, image, swatch_image, small_image
CitiSignal Fiber Max
CitiSignal-Fiber-Max
1
thumbnail, image, swatch_image, small_image
Apple One
Apple-One
1
thumbnail, image, swatch_image, small_image
YouTube Premium
YouTube-Premium
1
thumbnail, image, swatch_image, small_image
Disney Plus
Disney
1
thumbnail, image, swatch_image, small_image
Netflix + HBO Max
Netflix-HBO-Max
1
thumbnail, image, swatch_image, small_image

All your images should then be approved.

ACCS+AEM Assets

1.5.3.5 Verify Product Images on AEM Sites CS/EDS Storefront

NOTE
It may take up to 15 minutes before the changes you made above are successfully deployed. If you don’t see your image being shown yet, wait 15 minutes and then try again.

To verify that the integration is working, you need to open your CitiSignal website.

You should then see this. Go to Phones.

ACCS+AEM Assets

You should then see a product image being shown for the iPhone Air. Click iPhone Air.

ACCS+AEM Assets

You should then see this. Make a change to the color and storage options, and you’ll see the images dynamically change based on the choices you made.

ACCS+AEM Assets

Here’s an example of changing the color to Light-Gold and the storage size to 256GB.

ACCS+AEM Assets

Go Back to Adobe Commerce as a Cloud Service

Go Back to All Modules

recommendation-more-help
4bbf020c-24db-4a43-b239-88fab142f02d