How to connect OpenCart to Stokis
Upload stokis.ocmod.zip under Extensions → Installer, install Stokis Connector under Extensions → Extensions → Modules, then paste the shop address and key from its settings page into Stokis. It works on OpenCart 3.0 and 4.
What you need before you start
OpenCart's own API cannot list products, stock and orders for another service, so Stokis reads them through a small extension that you install once.
- An OpenCart 3.0 or 4 shop that you can sign in to as an administrator, because you will upload and install an extension.
- A shop address that opens over https in a browser. Stokis connects over https only.
- A Stokis account with a workspace that has no shop connected yet. One workspace holds one shop.
Download the extension for your OpenCart version
There is one file for OpenCart 4 and one for OpenCart 3. Both are named stokis.ocmod.zip. The same two downloads are on the Integrations page in Stokis.
Keep the file name exactly as it is. OpenCart accepts only a name that ends in .ocmod.zip, so a second copy that your browser saved as stokis.ocmod (1).zip is refused as an invalid file type.
Upload the file under Extensions → Installer
In the OpenCart admin open Extensions → Installer and upload the file. On OpenCart 4 the upload button is the blue one at the top right, and the extension then appears in the list, where you press the green plus to install it. OpenCart 3 installs the file as soon as the upload finishes.
Install Stokis Connector under Extensions → Modules
Uploading is only the first half. The extension starts working, and makes its key, when you install it in the list of modules.
- Open Extensions → Extensions and choose Modules in the extension type list.
- Find Stokis Connector. The list is in alphabetical order.
- Press the green plus button to install it. The button turns into a red minus.
- Press the blue pencil button to open its settings page.
Copy the shop address and the key
The settings page shows the Shop address and the Key, each with a Copy button, and two switches. Copy both values. Copy the key whole: a key that is cut short is refused.
- Status is on after the install. Switching it off stops Stokis reading the shop without removing the extension.
- Stock updates is off after the install, so Stokis can only read. See the stock section below before you switch it on.
- Make a new key stops the old key at once. Use it if the key was shared by mistake, then paste the new key into Stokis.
Paste both values into Stokis
- In Stokis open Integrations and choose OpenCart.
- Paste the shop address into Store URL and the key into Key.
- Press Test connection. Stokis checks the key against your shop before anything is saved.
- Press Connect. The first sync starts on its own and a dialog shows each step.
After the first sync Stokis reads the shop again on the schedule of your plan, and Sync now reads it on the spot.
Let Stokis add received orders to your stock
This step is optional. With both switches below on, receiving a purchase order in Stokis adds the received quantity to the product's stock in OpenCart. With either one off, Stokis only reads.
- In OpenCart, switch Stock updates on in the Stokis Connector's settings page and save.
- In Stokis, switch Push stock back to store on in the Integrations page and save.
A product with Subtract Stock off, and a product sold in combinations of several options, has no stock level of its own in OpenCart. Stokis shows such a unit as Not tracked, counts its sales, and does not hold a stock figure for it.
What the extension reads
The extension adds one settings page and changes no OpenCart file, theme or template. It answers only requests signed with your key.
| The extension reads | Stokis uses it for |
|---|---|
| Products with their options, SKU, model and price | The product list. Each option value you sell as its own unit becomes its own product |
| Stock quantities | Stock levels, stock cover and reorder points |
| Categories and manufacturers | Filters, and suppliers if you choose to use the brand as supplier |
| Orders from every store of the shop: status, date, total and the lines with the chosen options | Sales history and the demand forecast |
| Nothing about your customers | No names, emails, addresses or phone numbers leave the shop |
An order counts as a sale while its status is one that your shop treats as processing or complete. OpenCart has no cost price, so products arrive without a cost.
When OpenCart does not connect
Stokis names what it found. Match the message you see.
| What you see | Cause | Fix |
|---|---|---|
| The key doesn't match this shop | The key in Stokis is not the one the extension holds now. Someone pressed Make a new key, or the key was copied in part | Copy the key again from the settings page and paste it into Stokis |
| We reached your shop, but the Stokis Connector isn't installed there | The file was uploaded and never installed, or the address is not the shop's own | Finish the install under Extensions → Extensions → Modules and use the address the settings page shows |
| The Stokis Connector is switched off in your shop | The Status switch on the settings page is off | Switch it on and save |
| Your shop answered with a page instead of data | Maintenance mode, or a security check in front of the shop, answered in place of the extension | Switch maintenance mode off, or let Stokis through the firewall, then test again |
| Stokis connects over https. Check that your address opens in your browser | The shop has no working https address | Set up https for the shop, then test again |
| Stock updates are switched off in your shop | Push stock back to store is on in Stokis while Stock updates is off in the extension | Switch Stock updates on in the settings page, or switch the push off in Stokis |
| Invalid file type, in OpenCart, when you upload | The browser renamed the download, for example to stokis.ocmod (1).zip | Rename it back to stokis.ocmod.zip and upload it again |
How to pause, replace the key or remove the extension
- To pause, switch Status off in the settings page. Stokis stops reading and the extension stays installed.
- To replace the key, press Make a new key. The old key stops working at once, so paste the new one into Stokis.
- To remove the extension, uninstall it under Extensions → Extensions → Modules. Its key is deleted with it.
- To disconnect on the Stokis side, press Disconnect in the Integrations page. The automatic sync stops and the saved key is removed. Your products and sales history in Stokis stay, and you can connect again later.
Questions about connecting OpenCart
OpenCart 3.0 and 4. The steps and pictures here were taken on 3.0.5.1 and 4.1.0.4. If another release does not connect, tell us the version.
It only reads unless you switch Stock updates on. With that switch on, the one thing it writes is the stock quantity of a product when you receive a purchase order in Stokis.
No. Orders arrive as dates, quantities and prices only. Names, emails, addresses and phone numbers stay in the shop.
Open Extensions → Extensions, choose Modules, and press the pencil next to Stokis Connector. The page shows the shop address and the key, each with a Copy button.
Yes. Orders from every store are counted, because the stores of one OpenCart share one stock.
Yes, the download is free. Stokis itself has a free plan and paid plans, listed on the pricing page.