If when you are downloading transactions from your Opayo account into your Sage 50c Accounts your stock and products are not being referenced correctly this will be due to the product codes not being referenced correctly within your basket contents.
When using the MySagePay download wizard to import transactions into your accounts software you are able to reference product codes that you have created within your Sage 50c Accounts to manage your stock more effectively.
Stock item or Service Codes
When creating a stock item or service code in your accounts software you will be required to create a product code for the item.
The product code is a reference that is used to relate to the item your shopper is purchasing and allows you to see the reference when the order is placed.
You are also able to apply this to the items on your web store so, when the MySagePay download wizard is ran your accounts software will be able to reference the item that has been purchased and deduct this from your stock lists.
For more information on creating stock items in your accounts product please check out our article (link to article O-00080)
Codes and Opayo
Once you have created your product codes in your Sage 50c Accounts software you will be able to include these on the items on your website.
In order to apply these product codes to items on your website you will need to speak with your web developer who will be able to help you with this.
After the codes have been applied to your items when the transaction is placed the product code will then be included in the basket field that is passed with your transaction.
When passing the basket field through with any order on your site, the field is populated with 6 columns.
- Items – A description of the item that has been purchased. The product code will be included here.
- Quantity – The volume of the product that have been ordered.
- Item Value – The amount for each individual item ordered.
- Item Tax – The tax that is applied to each individual item.
- Item Total – The total cost of the item plus tax.
- Line Total – The overall cost of the items plus tax in each line of the basket.
The basket contents can then be used to reference stock on your Sage 50c Accounts product.
A common basket field will be displayed as –
As you can see there are no product codes referenced within the basket that is passed for this transaction.
By including your product code in the Items column your accounts software will be able to reference and deduct this from the stock levels on your account.
Including the code
To include the product code in your basket field you will need to enter this at the beginning of the Item column and in enclosed [ ] square brackets.
If you use other brackets this will not work correctly and not deduct from your stock.
By including the product code into your basket it will then appear as –
When downloading the transaction using the MySagePay download wizard your software will then be able to deduct the items from the correct stock.
When passing the basket field through with the transaction your basket will now be passed as –
4 : [PROD0001] Product 1 : 1 : 424.00 : 74.32 : 499.00 : 499.00 : [PROD0002] Product 2 : 3 : 11.91 : 2.08 : 13.99 : 41.97 : [PROD0003] Product 3 : 2 : 11.05 : 1.94 : 12.99 : 25.98 : Delivery : 1 : 0.00 : 0.00 : 0.00 : 4.99
The product codes will then be used in line with those in your accounts software.