How to create barcoce automatically for your products in Shopify - Shopify app

Generate Barcode / Stickers

Our new barcode sticker generation app for Shopify allows you to view your products and generate barcodes for their variants. To generate a barcode, simply click the "Create Barcode" button.

You can also generate SKU and barcode for the product itself before generating barcodes for its variants in the "Product data generator" tab of this app.

 

barcode sticker with ean13 code and product data

Generate Missing Product Data

In this section of the app, you will find a list of products that are missing either SKU or barcode information. The app will not overwrite existing values, so it will only create a SKU or barcode if the product has none. When the barcode and SKU are created, the app will remove the product from the list.

The missing product data generator is designed to help you quickly identify and fill in missing information for your products, ensuring that your inventory management and order fulfillment processes run smoothly.

Conclusion

Our new barcode sticker generation app is designed for a technical audience seeking a straightforward, efficient solution for managing product data in their Shopify store. With its intuitive interface and focus on providing only the necessary features, this app is the perfect tool for managing your store's barcode and SKU data.

 

Technical details 

The Barcode Sticker Generation Shopify App is a server-side application that helps store owners manage their product data, specifically focusing on generating barcodes and SKUs for products and their variants. The app is built using Shopify's official libraries and is designed to work seamlessly with a Shopify store.

Key Features:

  1. Fetching products with missing data: The app fetches products that are missing either a SKU or a barcode using the Shopify REST API. It filters the products that have at least one variant with missing SKU or barcode information.
  2. Generating SKU: The app generates a unique SKU for a product variant by combining a substring derived from the product title and the option name. This is done using the createSkuFromName function.
  3. Generating EAN-13 barcode: The app generates a random EAN-13 barcode for product variants that do not have a barcode assigned. The getEan13 function is responsible for this functionality.
  4. Updating product data: The app updates product data by saving the generated SKU and barcode to the product variants using the Shopify REST API.
  5. Generating barcodes for all products: The app provides an endpoint to generate barcodes for all products at once. This is done using the /api/create-product-data-all-products/ route.
  6. Barcode generation API: The app proxies a request to an external barcode generation API to create barcodes for products. This is done using the httpProxy library and the /api/products/:productId/generate-barcode route.

The app uses the Express.js web framework and is designed to be run alongside the store owner's Shopify store. The routes are secured using Shopify's authentication middleware, ensuring that only authorized users can access the app's functionality.

Back to blog