This is the continuation of integrating AEM with Magento, if the Magento is not yet installed in your local environment then I would recommend you please refer this article to set up Magento.
Before integrating Magento with AEM, you need to perform some checks, the first thing which I recommend you to check whether the graphql is working or not. Because the AEM access Magento data via GraphQL.
You can test GraphQL queries on the browser by installing the ChromeiQL extension.  After plugin installation is completed then in the address bar enter your hostname by appending with graphql.
On the left-hand side enter the below JSON to check whether graphql is working or not. If everything works fine then you should see the output in the right-hand side.

cmsPage(id: 2) {

Output :
The second thing is you need to enable Web API access for anonymous users. Just follow below navigation steps to enable anonymous access. By default it is disabled, if you want to access Catalog and Store APIs then you must enable it.
Store > Configuration > Services > Magento Web API > Web API Security

By coderss

2 thought on “Integrate AEM with Magento – 2”
  1. Hi,
    I am also doing this intergartion (AEM 6.5 with Magento 2.3.2) for self learning. But I am stuck and not able to move executing GraphQL Endpoint. Appreciate if you can help me.
    I have installed Magento ver2.3.2 “Full Release with Sample Data”. I have installed the Magento and now I can see the LUMA pages http://localhost/magento2“.
    I have also installed ChromeiQL in browser.
    But I am not able to execute “http://localhost/magento2/graphql” from ChromeiQL. I am getting error “TypeError: Failed to fetch”. Can you please help, what additional configuration you have doen for executing “endpoint’ of graphQL.

    1. Hi,
      I am seeing same issue in my local environment, but for testing this I have installed Magento in my linux server there I did not see any issue. I suspect the GraphQL module might be missing in local environment.

Leave a Reply

Your email address will not be published. Required fields are marked *