Jump to content
thirty bees forum

Recommended Posts

Posted (edited)

This is a module I got the Copilot AI to create which exports products from a Thirty Bees store to a XML format that can be used to upload to Google Merchant center so they can be added to the shopping feed.

The module extracts the following product details from a Thirty Bees store database: Product ID (<g:id>) Title (<g:title>) Short description (<g:description>) Product URL (<g:link>) Image URL (<g:image_link>) Price in store currency (<g:price>) Stock availability (<g:availability>) Product condition (<g:condition>) Brand (Manufacturer) (<g:brand>) MPN (Manufacturer Part Number) (<g:mpn>) GTIN (EAN or UPC if available) (<g:gtin>) Category name (<g:product_type>)

These are far from the total number of field you can use with Google Merchant center but they include the minimum amount to get the product feed accepted.

To install the module download the attachment exportgoogleshopping.zip from this post, and add a new module from your TB admin area and it will appear in the administration section when uploaded

Screenshotfrom2025-05-1317-18-06.png.3ff982e792364b2a936bf6ebf60fde81.png
I created this module purely for my own personal use, but thought i would share it with the community for anyone else found it useful. It was my first time using AI to generate a module and I was suprised how well it managed to do it. But as i am not a developer I don't know if the code itself maybe buggy or insecure so if you are worried about that then maybe don't use it on a live store or uninstall it after you generated the XML file. 

Screenshotfrom2025-05-1317-30-00.png.5db574143c500a67ddf25e9af36e05c0.png
I have tested it on both 1.5.1 and on 1.6.1 versions of TB and it worked OK on both for me, and the feed was accepted by Google Merchant center as valid. But I cannot offer any support for it should it not work for someone else or take any responsibility for any problems that might occur.
I am happy if someone else wants to update and improve on this should module should they wish to.
For those who might be interest in what prompts to give to an AI to generate a module like this one see below:
 

"Create a Thirty Bees module that exports product data to an XML feed for Google Shopping. The module should include the following features:

Manual XML generation via a "Generate XML" button in the back office Customizable title and description for the feed Dynamic price handling based on the store's default currency Stock availability pulled from the database (in_stock or out_of_stock) Condition extracted from the product's condition field (new, used, refurbished) Correct image retrieval using Product::getCover() Brand (manufacturer) added to <g:brand> if available MPN (manufacturer part number) added to <g:mpn> if available GTIN field dynamically populated with EAN or UPC if available Category assigned to <g:product_type> A "Return to Modules" button for navigation back after interaction Ensure clean XML output without empty fields Store feed file in a configurable location (default: /google_feed.xml)

Include full module code in PHP that correctly integrates with Thirty Bees, following best practices for PrestaShop-based platforms. The module should be installable and configurable from the back office."

 

exportgoogleshopping.zip

Edited by ukclearance
Uploaded new version of the module which fixed some errors
  • Thanks 1

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...