This tutorial will run through what is required to upload products from Zynk XML format (export from Sage 50 demo company)to Magento simple products. Note you will need to have access to a Magento installation with API credentials to upload productdata. To begin you will need to find the attribute set id to use when creating new products, you can find this from yourMagento admin.
The Workflow, XSLT and sample XML files can be found here, and the XSLT can be found in the Auto Mapper task within Zynk. If you do not have a copy of Zynk you can register for a trial here. The following libraries and tasks will be used in this tutorial:
Building the Workflow
- Open Zynk and click on the New Workflow button or choose File > New from the main menu
- You should now see the Task Library pane displayed.
- Navigate down to the Connect for Sage 50 library and then Double-click (or Drag and drop) the Export Stock Records task to copy that task into the Tasks List
- Select the Export Stock Records task in the Task List and set the Output File to sage_products.xml
- Locate the Auto Mapper task from the Zynk library and add that task into the Tasks List, setting the following
- Set Input File to sage_products.xml
- Set Output File to magento_products.xml
- Edit Mapping (use the button on the right hand side of the setting)
- Choose Input File Format Zynk XML
- Choose Input File Data Type Products
- Choose Output File Format Magento
- Choose Output File Date Type Products
- If required change the values of the parameters
- Locate the Upload Products task in the Magento library and add to the workflow, setting the following
- Set Input File to magento_products.xml
- Set Success File to magento_success.xml
- Set Fail File to magento_fail.xml
- Click on the Save button and enter the name Sage to Magento for the name of the Workflow and click Save
Running the Workflow
To run the workflow click the Run Workflow button, or hit F5. The workflow should prompt for your connection details to Sage 50, the sample data is from the Sage 50 Demo Company, but you can choose any company you have setup. Once the workflow has exported and converted the data it will then prompt for the Magento connection details, enter your URL, Username and Password to continue. Depending on the amount of products you have it can take a while for the information to be uploaded, but you should start to see products appearing in the Magento product list.
Modifying the Mapping
The mapping provided in the Auto Mapper is a basic example of creating Magento products. You will more than likely need to modify the mapping to set the fields you require in your integration. As part of the Auto Mapper you can set the attribute set id for the products you are uploading (edit the mapping and set the parameter value).
If you require any custom fields you can add these to the Fields collection in the XSLT. The name of the field can be found from your Magento installation. Note by default you can only set text field values, not select options.
If you have any queries on any of the above, feel free to contact our support team via email at email@example.com or via telephone on 0191 303 7279. Please note, as stated on the Auto Mapper task we do not support any changes to XSLT.
Back | Edit on Github