This article will help you get started with the Shopify ERP integration in nShift On-premises. The example is based on an On-premises solution but the Shopify integration also works for Ticket and Shipment Server.
- Enable Shopify API
- Configure the integration in nShift On-premises
- Configure nShift On-premises production view
Enable Shopify API
- Log in to Shopify.
- Click the Apps button in the left side menu
- Click the link saying Manage private apps at the bottom of the page.
- You will be sent to a page containing your private apps if you have any. Click the button Create a new private app.
- Fill in a name for your app and an email address under App details.
- In the permissions box under Admin API, you must set Orders, transactions and fulfillments to Read access. This is the only option that is relevant for nShift. Let the other options keep the default settings or set them as you like.
- Click Save to finish creating the private app and accept the Shopify API terms when asked by clicking I understand, create the app.
- Shopify will now generate the API credentials. You need the API key and the password for later so copy these and store them securely.
Configure the integration in nShift On-premises
Follow these steps to activate the Shopify integration in nShift On-premises. If you are using Ticket or Shipment Server, our customer service can help set it up.
- Go to Setup and navigate to the level in your installation where you want the ERP integration to work. It can be activated on Installation, Location or Actor level.
- Right-click in the pane to the right and select New > ERP integration
- Select nShift On-premises Web Integration in Vendor and Web Service in Database Engine. Click Next to continue.
- Fill in the Shopify API key in the User Name field and the password in the Password field. If you click the Connect button, the status at the bottom of the window should change from Not connected to database to Web service active.
Note: The password is Admin API Access Token, not the API Secret Key
- Enable Order Number as the search key and use the endpoint https://storename.myshopify.com/admin/orders as the address. (Use the endpoint for your store) The Integration type should be set to Shopify.
- Click Next twice until you reach the Rules for Order Search page. Click Default Mapping and then OK. (Do not use the preview button before this)
Configure Production View in nShift On-premises
You must configure the Production view to use ERP integration:
- Go to Main > Production.
- Right-click in the field My orders and choose Search properties.
- Under the General tab, check Search by: Order number.
- Under the Integration tab, check ERP database.
- Click OK to save.
- In the Production view, try to enter an order number to verify that the integration works. Use one of the order numbers from the order page in Shopify and test that the order loads in nShift On-premises.
Note: If no order is returned when testing, please verify that the order number is valid and that you have set the read rights correctly in your Shopify account. You can use an URL following this pattern to test:
//<user name>:<password>@<sitename>.myshopify.com/admin/orders.json?name=<order number>
If this URL returns the error below, it means that read access has not been set correctly:
{"errors":"[API] This action requires merchant approval for read_orders scope."}