Reading list Switch to dark mode

    Guide for Magento 2 ChatGPT Bot

    Updated 5 October 2023

    Magento 2 ChatGPT Bot allows the admin to add Magento 2 product database to the ChatGPT bot and thereby allows the users at the storefront to use our real-time virtual assistant that utilizes NLP to provide answers accordingly for the products within the Magento 2 store via the intelligent ChatGPT bot.


    • Enable or disable the functionality for the store.
    • Add/export products to the ChatGPT bot from the Magento 2 backend.
    • After enabling the functionality a ChatGPT bot is added to the Magento 2 store frontend.
    • Customers can interact with the ChatGPT bot and ask queries regarding the products within the store.
    • ChatGPT bot replies with the required information about the products in the Magento 2 store.
    • The extension uses NLP to give customers instant answers from the Magento 2 product database.
    • The ChatGPT Bot uses OpenAI’s large language model, GPT-4.


    #Download Module

    Firstly, you need to log in to Webkul Store, go to My Account>My Purchased Products section, verify and then download and extract the contents of this zip folder on the system.

    #Upload Folder

    Once the module zip for Magento 2 OpenCart Connector is extracted, follow path src>app and then copy the app folder into the Magento 2 root directory on the server as shown below:

    Magento 2 opencart connector installation

    #3 Run Commands

    You need to run the following commands:

    • php bin/magento setup:upgrade
    • php bin/magento setup:di:compile
    • php bin/magento setup:static-content:deploy
    • php bin/magento indexer:reindex
    • php bin/magento cache:flush

    Language Translation

    For translating the module language, navigate through src/app/code/Webkul/ChatGptBot/i18n and edit the en_US.csv file. Thereafter, rename the CSV as “en_SA.csv” and translate all right side content after the comma in the Arabic language. After editing the CSV, save it.

    Searching for an experienced
    Magento 2 Company ?
    Find out More
    Magento 2 opencart connector language translation

    Now, upload it to the path src/app/code/Webkul/ChatGptBot/i18n where the installation of Magento 2 is on the server. The module gets translated into the Arabic Language. It supports both RTL and LTR languages.

    The user can edit the CSV like the image below.

    Magento 2 OpenCart Connector language translation

    Generate Secret Key – OpenAI Account

    The user has to first create an OpenAI account and log in to the OpenAI dashboard as shown in the screenshot.


    Now the user will have to click on the Personal in the top-right corner and a popup will appear. The user will click on the View API Keys option.


    A page will open and a button Create New Secret Key will be visible as shown in the screenshot.


    Once, the user clicks on this button a pop-up will display with the API key. The user can copy the key from here with the help of copy button.


    The generated key is to be used in the extension’s configuration settings section in the Magento 2 backend.

    Generate Pinecone – Secret Key & Index

    To generate the Pinecone secret key and the index, navigate to the Pinecone website and register yourself.


    After registration, you can sign in to the Pinecone account.


    After login, navigate to the API Keys section. Here, you can find all of the keys that you have created.


    To generate a new API key tap the Create API Key button on the top right-hand corner. After that, enter the key name and tap the Create Key button after that.


    The key will be created and then you can copy the key and use it in the extension’s configuration settings in the Magento 2 backend.


    Now, to create the Index, navigate to the Indexes sections from the side panel option. Here, tap the Create your first index button.


    After that, a pop-up will appear. Here, enter the index name, enter the dimension as 1536, set the metric, select the Pod Type as required, and tap the Create Index button after that.


    After tapping the Create Index button, the index will be created. Now, you have to copy this index into the extension Pinecore index section.


    Initial Configuration

    After successfully installing the extension navigate through Stores->Configuration->ChatGPT Bot.

    chatgpt bot configuration settings

    Here, the admin will be able to –

    • Enable the extension functionality
    • Enter the ChatGPT Open AI secret key.

    Apart from that, under the Pinecone settings the admin will –

    • Enter the Pinecode secret key.
    • Enter the Pinecone index as required.

    Under the Chat window configuration, the admin will –

    • Upload the chat window avatar that is visible on the ChatGPT bot window.
    • Set the title for the ChatGPT chat window as required.

    Lastly, the admin needs to save the configuration settings.

    Adding Products to ChatGPT Bot

    The admin will navigate to the Catalog->Products.

    Here, the admin will select the products that the admin wants to add to the ChatGPT bot. For the same select the products and from the actions dropdown select the option Add To ChatGPT bot.

    Magento 2 ChatGPT Bot add products to Bot

    This brings up a prompt, just tap ok on that.

    Magento 2 ChatGPT Bot

    After that, you will see the success message for the same.

    Magento 2 ChatGPT Bot products added to ChatGPT bot

    Magento 2 ChatGPT Bot – Storefront Working

    The users of your website will find the ChatGPT bot at the storefront. They can ask their queries to the ChatGPT bot by entering their specific queries.

    Magento 2 ChatGPT Bot at store front

    Also, if you want the store admin and the marketplace vendors to generate the product, category, and CMS page content using ChatGPT then you can check the Magento 2 Multi Vendor ChatGPT Content Generator extension.

    The users can interact with the ChatGPT bot as required.

    Magento 2 ChatGPT Bot question asked to bot

    According to the asked query, the ChatGPT bot will respond.

    Magento 2 ChatGPT Bot reply form chat GPT bot

    If the customer asked for a product page of the product, the ChatGPT will respond back with the product page link as shown below in the snapshot.

    Magento 2 ChatGPT Bot reply from ChatGPT bot

    If the user asked for the price of the product then the ChatGPT bot or the virtual assistant will respond accordingly.

    Magento 2 ChatGPT Bot reply from chat Bot for the respective product price

    Tapping on the product link will redirect the customer to the product page from where the customer can then make a checkout as required.

    Magento 2 ChatGPT Bot product page displayed by ChatGPT bot


    That is all about the Magento 2 ChatGPT Bot extension. If you have any queries regarding the plugin, please contact us at Webkul Support System.

    If you’re looking to create a custom e-commerce website, it’s a great idea to hire Magento developers who can help you build a powerful and scalable online store.

    You can also check our complete Magento 2 extensions.

    . . .

    Leave a Comment

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

    Be the first to comment.

    Back to Top

    Message Sent!

    If you have more details or questions, you can reply to the received confirmation email.

    Back to Home

    Table of Content