Adding products one at a time can slow down a growing BigCommerce store. With the BigCommerce API, you can create products programmatically, making it easier to manage large catalogs, automate workflows, and keep product information consistent.
This guide walks you through the essentials of using the BigCommerce API to create products, from preparing your store’s API credentials to sending product details in a request. Whether you’re building an integration or streamlining routine updates, you’ll have a clear starting point for creating products with confidence.
BigCommerce API Create Products: Get Ready
Before sending product data, it helps to make two choices: which store the request will affect and what kind of product you’re adding. Getting these details straight first can prevent avoidable errors once you start testing your integration.
Set Up API Credentials
Your integration needs permission to change catalog data. In the BigCommerce control panel, create an API account with the Products: modify scope, then save the credentials BigCommerce provides. I recommend storing them in a secure environment variable or secrets manager—not in browser code or a public repository.
You’ll use the store hash to build the request URL and the access token to authenticate the API call. For example, product creation uses the Catalog Products endpoint, with a URL pattern like https://api.bigcommerce.com/stores/{storehash}/v3/catalog/products. Keep the token private, and make sure your request includes the required X-Auth-Token header and a JSON content type.
- Store hash: identifies the store in the endpoint URL.
- Access token: authorizes the request according to the account’s scopes.
- API scope: should allow product modifications.
I also suggest testing with a development or sandbox store first. That gives you room to check permissions and request formatting without changing a live catalog.
Choose a Store and Product Type
With authentication ready, confirm the target store before preparing the product body. This matters when you work across several storefronts: a valid token paired with the wrong store hash can send a perfectly formed request to the wrong catalog.
Next, decide whether the item is physical or digital. BigCommerce uses the product’s type field to distinguish these cases, so choose the value that matches how the item is fulfilled. For a physical item, you may also need details such as weight; for a digital product, consider how customers will receive the downloadable content.
Think about variations before creating the record, too. A shirt offered in several sizes or colors may need product options and variants, while a one-size item may only need a basic product. I find it useful to list the required fields before making the first call:
- Store: the intended store hash.
- Product type: physical or digital.
- Catalog structure: a single item or an item with options and variants.
Once these decisions are clear, you can build a request body that fits the product rather than trying to correct its structure afterward.
Create a Product with the API
With the store and product structure decided, the next step is to turn those choices into a request BigCommerce can process. I usually start with a small, complete product record, then add extra details once the basic call succeeds.
The request needs the correct endpoint, headers, and a JSON body. Here’s how I put those pieces together and check what BigCommerce sends back.
Build the BigCommerce API create products Request
Start with a POST request to the Catalog Products endpoint. The store hash belongs in the URL, while the access token goes in the request headers.
For example, a request body for a simple physical item could look like this:
{
"name": "Everyday Canvas Tote",
"type": "physical",
"price": 24.99,
"weight": 0.4,
"description": "A reusable canvas tote for daily errands.",
"categories": [23]
}
Send it with X-Auth-Token and Content-Type: application/json. Use a category ID that exists in the target store; an invalid ID can cause the request to fail.
Once the basic payload is in place, you can add the information shoppers need to make a purchase. Pay special attention to pricing and image URLs, since errors there can make an otherwise valid listing less useful.
Add Product Details, Pricing, and Images
Set price as a number, not a currency-formatted string such as “$24.99.” Add details like a description, SKU, brand, or inventory settings as needed. For physical products, include an accurate weight if shipping calculations depend on it.
To attach an image, add an images array with an image URL that BigCommerce can access. For example, an image object can include imageurl and isthumbnail. I use a stable, publicly reachable URL and check that it loads before sending the request; a private or broken link may prevent the image from appearing.
After sending the payload, check both the HTTP status and the response body rather than assuming the product was created. This quick verification helps catch field-level issues before you build the call into a larger workflow.
Submit and Read the API Response
A successful create request typically returns 201 Created, with the new product in the response’s data object. Save the returned product ID: you’ll need it for later updates, images, or related catalog operations.
If the request fails, read the response details and correct the specific field or permission issue. I recommend checking these items first:
- 400-level response: review required fields, value formats, and category IDs.
- 401 or 403 response: verify the token and its product modification scope.
- Unexpected product data: confirm the store hash and inspect the returned record.
Once the response matches your intended listing, you have a reliable starting point for adding more products or automating catalog creation.
Check and Improve Your Product Setup
A successful response is a good start, but it doesn’t guarantee the listing will look or behave as expected in your store. I check the saved product first, then use any errors or missing details to guide the next update.
Before adding more catalog data, confirm that the new record appears in the right place and has the values you intended. A quick check in both the API response and the control panel can catch mismatches early.
Verify the Product in BigCommerce
Use the product ID returned by the create request to retrieve the record from the Catalog Products endpoint. I compare key fields such as name, price, categories, and isvisible with the original payload.
Then I open the product in the BigCommerce control panel or storefront preview. Check that the listing is visible when intended, the image loads, and the description displays correctly. If the product is hidden, review its visibility setting before troubleshooting the API call.
If something differs from your request, the response can help narrow down the cause. When a call is rejected, I read the error details before changing the payload.
Handle Validation Errors
BigCommerce may return an error response when a field is missing, uses the wrong format, or refers to an item that does not exist. Look at the response’s status and title, along with any field-specific details in errors; these clues are more useful than repeatedly resending the same request.
In my experience, these checks resolve many first-pass issues:
- Invalid category: confirm the category ID belongs to the target store.
- Incorrect value type: send prices as numbers, not formatted currency strings.
- Authorization failure: check the store hash, token, and product-modification scope.
- Duplicate or unsuitable data: review fields such as SKU and product type.
After correcting one issue, resend the request and inspect the new response. Changing a single thing at a time makes it easier to identify what fixed the problem.
Once the basic listing checks out, you can build on it for products with selectable choices or extra catalog information. The right approach depends on how shoppers need to configure or identify the item.
Expand with Variants and Custom Fields
For sizes, colors, or other purchasable combinations, create the product’s options and values, then add variants that connect those choices to details such as SKU, price, or inventory. I recommend testing one complete combination first, since a variant needs to match the options customers will select.
Use custom fields for useful product-specific details that don’t fit standard fields, such as material or care instructions. Keep names and values consistent across your catalog, and avoid using custom fields as a substitute for options that change what a customer buys.
After adding either structure, retrieve the product again and confirm the options, variants, or custom fields are attached as expected. This final check helps ensure your expanded setup is ready for shoppers and future catalog updates.
Build a More Scalable BigCommerce Catalog
Creating products with the BigCommerce API gives you a practical way to scale catalog management while keeping product data consistent. With the right credentials, a clear product structure, and a well-formed request, you can add listings programmatically and confirm they’re saved as intended.
Start with a simple product, check the API response and storefront display, and use validation feedback to refine your process. As your needs grow, you can extend your setup with variants and custom fields. A careful, step-by-step approach makes BigCommerce API product creation easier to maintain—and gives you a solid foundation for automating more of your store.
0 Comments
No comments yet. Share your thoughts or questions below.