/
Connecting to a BigCommerce instance

Connecting to a BigCommerce instance

This page tells you how to configure the connection of a Styla front to a BigCommerce instance.
It also explains how product data is pulled by Styla from BigCommerce and what the data is used for in the Styla Frontend.

On this page:

Styla Frontend needs a source of product data to generate product and category pages and to handle purchase workflow. This source are the Management APIs provided by BigCommerce. Styla Frontend proxies the APIs and both pulls data from and pushes data to them.

In order to connect Styla Frontend to this API you will need to:

  1. create an API user for Styla in your BigCommerce backend and grant it all privileges needed,

  2. set the API user’s credentials in your Styla front settings (in the shop JSON node in FRONT CONFIGURATION).

Once these steps are completed (and page bases are set up), Styla Frontend will automatically generate category and product details pages.

Without the connection to the BigCommerce API, Styla will still be able to render pages you publish with the Editor but no product content will be delivered nor any shop functionalities work.

Creating API user in BigCommerce backend

You need to be logged in to BigCommerce with the shop owner account to go through the below steps. Lower privilege levels can’t access the “API Accounts“ tab nor manage the account’s domain.

  1. Enter the Advanced Settings > API Accounts tab in your BigCommerce backend.

  2. Click the blue Create API Account button top-left and then the Create V2/V3 API Token:

  3. On the resulting form with the API account settings, assign it the full rights scope and click Save bottom-right:

  4. In the last step you will be displayed the API credentials for the new user on an overlay and download a .txt file with the same credentials. Keep the file to fill in the credentials in Styla Admin (described below):

Setting up the API user’s credentials in Styla front configuration

Enter the credentials from the .txt file in the shop JSON node of the FRONT CONFIGURATION, as shown below:

Instructions on the specific fields below:

type - enter bigcommerce for accounts using the BigCommerce API

domain - enter your Styla front name

currency - enter your three-letter ISO currency symbol

client_id - enter the 10-character account hash present in your original BigCommerce shop URL

token - enter the ACCESS TOKEN from the .txt file

store_url - enter the original BigCommerce shop URL (the URL your BigCommerce backend runs on)

client_id - enter the CLIENT ID from the .txt file

client_secret - enter the CLIENT SECRET from the .txt file

channel_id - this field will be updated by Styla once you fill in all the other credentials. Without it the checkout process won’t work but rendering of product details and category pages will work already.

One more thing you will need for the checkout process to work is having your BigCommerce shop open. As long it is preview mode, neither checkout nor account creation will work.