บาร์โค้ดกระเป๋าสตางค์มือถือ: Apple Wallet, Google Pay และ Passbook

Embed This Widget

Theme


      
    

Widget powered by . Free, no account required.

How barcodes power mobile wallet passes — boarding passes, event tickets, loyalty cards, and the PKPass/SaveToPay formats.

Mobile Wallet Barcodes: Apple Wallet, Google Pay & Passbook

Mobile wallets store digital versions of boarding passes, event tickets, loyalty cards, and coupons, each represented by a barcode that is scanned at the point of use. Understanding the barcode formats and pass specifications enables seamless integration.

Supported Barcode Formats

Wallet Supported Symbologies
Apple Wallet PDF417, QR Code, Aztec, Code 128, Data Matrix
Google Wallet QR Code, Aztec, PDF417, Code 128, Data Matrix, EAN-13, UPC-A

Apple Wallet (PKPass)

Apple Wallet passes are distributed as .pkpass files (ZIP archives) containing:

  • pass.json: Pass data, barcode configuration, and styling
  • Images: Logo, icon, strip, background
  • Manifest and signature: Cryptographic signing

The barcode section of pass.json:

{
  "barcodes": [{
    "format": "PKBarcodeFormatQR",
    "message": "PASS-DATA-HERE",
    "messageEncoding": "iso-8859-1"
  }]
}

Google Wallet

Google Wallet passes are created via the Google Wallet API:

  • Define the pass class (template) and pass object (instance)
  • Specify the barcode type and value
  • Passes are added to Google Wallet via links or app integration

Pass Types and Their Barcodes

Pass Type Typical Barcode Data Encoded
Boarding pass quiet zone needed." data-category="2D & Matrix Symbologies">Aztec Code IATA BCBP passenger data
Event ticket QR Code or PDF417 Ticket ID or seat assignment
Loyalty card QR Code or Code 128 Membership number
Coupon QR Code or Code 128 Offer code
Transit pass QR Code Pass ID or session token

Screen Brightness and Scanning

Mobile wallet barcodes are displayed on phone screens, requiring:

  • Maximum screen brightness for scanning (most wallet apps auto-maximize)
  • High contrast barcode rendering (black on white)
  • Adequate barcode size (minimum 30mm for reliable scanning)
  • Anti-glare considerations for outdoor scanning

Implementation Workflow

  1. Design the pass template (layout, colors, logo)
  2. Define the barcode type and data format
  3. Generate signed pass files (Apple) or API calls (Google)
  4. Distribute passes via email, web links, or in-app
  5. Test scanning with the actual scanners at venues/POS
  6. Implement pass updates (push notifications for gate changes, balance updates)

Best Practices

  • Use Aztec Code for boarding passes (IATA standard)
  • Use QR Code for most other pass types (universal scanner support)
  • Encode a unique pass ID rather than sensitive data in the barcode
  • Implement server-side validation: scan the barcode, verify against your backend
  • Support pass updates for dynamic information (gate changes, balance updates)