Request for Support for GS1 Encoded QR Code Creation in iOS Swift

Hello Team,

I am writing to request support for creating GS1 encoded QR codes within an iOS application developed using Swift. Our application requires the generation of QR codes that comply with GS1 standards to ensure interoperability and accurate data representation in various supply chain and logistics processes.

What we have done:

We have prepared a label (String) with gs1 compliant using below instructions.

https://www.gs1us.org/upcs-barcodes-prefixes/gs1-128

Ex: 400PO12345678-10241PART123372510GR-BATCH1123070417250704

Note: There are hidden separators in above string. You can find in below attachments.

But when I try to create QR code for above string using below code and scan, we are resulting that it is not GS1 encoded QRcode.

func generateQRCode(from string: String) -> UIImage? {
        let data = string.data(using: String.Encoding.ascii)
        if let filter = CIFilter(name: "CIQRCodeGenerator") {
            filter.setValue(data, forKey: "inputMessage")
            filter.setValue("Q", forKey: "inputCorrectionLevel")
            if let outputImage = filter.outputImage {
                // outputImage is QR Code image
		   return outputImage
            }
        }
        return nil
    }

We generally used to create QR/BAR code above apple APIs in that we can pass different Filters to get different encoding results. But it supports very limited encodings. Apple provided the below filters :

  • CICategoryGenerator
  • CIAztecCodeGenerator
  • CICode128BarcodeGenerator
  • CIPDF417BarcodeGenerator
  • CIQRCodeGenerator

More details, please check Apple documentation link

To support more encoding mechanism, we are using ZXing third party library.

The following barcodes are currently supported for both encoding and decoding in Zxing library

  • UPC-A and UPC-E
  • EAN-8 and EAN-13
  • Code 39
  • Code 93
  • Code 128
  • ITF
  • Codabar
  • RSS-14 (all variants)
  • QR Code
  • Data Matrix
  • Maxicode
  • Aztec ('beta' quality)
  • PDF 417 ('beta' quality)

So unfortunately we could not find any encoding type, neither the Apple default API nor the ZXing library. 

But when I use the same string to create GS1 encoding using https://barcode.tec-it.com/en/GS1DataMatrix, it is properly decoding as GS1 encoded string.

Question:

Is there any way to create GS1 encoded QRcode in ios either direct apple api or any third party open source library?

Request:

I would greatly appreciate any guidance, documentation, or library recommendations that could assist in implementing this functionality. Specifically, we are looking for:

  • Example code or library that supports GS1 encoded QR code creation in Swift.
  • Documentation or guidelines on implementing GS1 standards for QR codes.
  • Any additional tools or resources that could facilitate this process.

Thank you for your attention to this matter. We look forward to your assistance in integrating GS1 encoded QR code generation into our iOS application.

Please visit the Feedback Assistant to make a formal request. Posts on the forums are not guaranteed to be seen by the teams necessary to resolve your issue.

Request for Support for GS1 Encoded QR Code Creation in iOS Swift
 
 
Q