This guide details how to manage Kemicard Templates (Template_Pass__c), which control the branding, data mapping, and visual layout of digital wallet passes for Apple and Google Wallet. Templates are linked to a specific configuration which determines the target Salesforce object (e.g., Contact).
Overview
A Kemicard Template serves as the visual and functional blueprint for your digital passes. It manages:
- Branding: Logos, colors, images, and organization names.
- Data Mapping: Defining which Salesforce fields appear on the front and back of the pass.
- Barcode Configuration: QR code types and the source data field.
- Email Delivery: Selection of email templates for pass distribution.
- Notifications: Appearance of push notifications on mobile devices.
Editing Methods
Note: We recommend using template builder for updating existing templates
- Template Record Page: A standard Salesforce detail page for editing specific field values.
- Template Builder: A custom visual editor within the Kemicard Console providing live side-by-side previews of Apple and Google passes.
Navigating to a Template
Via Template Record Page
Users can navigate directly to a Template_Pass__c record. The page includes a Configuration Banner showing the linked configuration status (e.g., “Configuration ‘Contact’ is active”).
Via Template Builder
- Open the Kemicard Console.
- In the Template Builder section, use the search box to find a template by name (e.g., “Woofly”).
- Selecting a template loads the visual editor with live previews.
Template Record Page — Details Tab
The Details Tab contains the full field layout. While many fields are in the Template Builder, some are only editable here.
Key Template Fields
| Field | API Name | Woofly Example Value | Notes |
| Template Name | Name | Woofly Membership Pass | Standard record name. |
| Active | Active__c | true | Required for pass generation. |
| Organization Name | Organization_Name__c | Woofly | Displayed on pass and notifications. |
| QR Code Field | QR_Code_Field__c | Id | Field encoded into the QR code. |
| Background Color | Back_Ground_Color__c | rgb(255, 255, 255) | CSS RGB triple format. |
| Apple Type | Apple_Type__c | Event With Strip | Controls the Apple layout. |
Fields NOT Available in Template Builder
The following must be edited via the standard record page:
- Subheader__c: Title label for usage location.
- App_Launch_URL__c: URL for associated mobile apps.
- Relevant_Date__c & Expiration_Date__c: Logic for pass relevance and expiry.
- Sample_Record__c: Salesforce ID used for builder previews.
- From_Email_Address__c: The sender’s email address.
Template Builder — Visual Settings
The Template Builder is divided into a Settings Panel and a Preview Panel.
Style Tab
Controls the color scheme:
- Background Color: Sets the pass background.
- Font Color (Apple): Sets text color; may be overridden by Apple if a Strip Image is used.
- Label Color (Apple): Sets the color for field labels.
- Strict Format: Colors must be rgb(R, G, B) with no decimal values.
Barcodes Tab
Configures the QR code:
- Allows selection of barcode formats for both Apple and Google.
- QR Data Field: A dropdown of fields from the target object. For Woofly, selecting Id ensures the Contact ID is encoded for scanning.
Setup Tab
Provides access to three critical configuration modals:
- Images: Manage logos, strip/banner images, and hero images. These are packaged into a ZIP file stored in Wallet_Resources_ID__c.
- Fields: Maps Salesforce fields to specific pass slots, building the Fields_Map__c JSON.
- Email Templates: Selects the Email_Template__c for initial delivery and Update_Email_Template__c for Google Wallet updates.
Preview Panel Functionality
The Preview Panel provides real-time feedback across three views:
1. Front Side
Renders the pass based on the selected Apple_Type__c (e.g., Event With Strip, Loyalty).
- Apple Preview: Renders header, secondary, and auxiliary fields.
- Google Preview: Renders subheader, header, and Google Wallet data rows.
- Error Accordion: If validation fails, an expandable pane displays platform-specific errors.
2. Back Side
Displays the reverse of the passes:
- Apple Back: Shows informational fields like terms and conditions.
- Google Back: Displays Google-specific back-of-pass content.
3. Notification
Simulates push notifications on lock screens:
- Shows the organization name, notification icon, and message body.
- Allows clicking on icons or text to edit them directly.
Fields Map & Data Configuration
The Fields_Map__c JSON defines the specific data slots.
Woofly Configuration Example
- Apple Row 0 (Header): Maps to Contact.Kcard__Member_Number__c.
- Apple Row 1 (Secondary): Maps to Salutation, FirstName, and LastName.
- Google Row 2 (Wallet Fields): Maps to Contact.Kcard__Member_Since__c.
Technical Validation & Triggers
- RGB Validation: The Check_Values_of_RGB_in_Fields rule prevents decimal values in color fields.
- TemplatePass Trigger:
- Before Insert: Auto-populates Class_Id__c and validates email addresses.
- Before Update: Strictly prevents changes to the Class_Id__c once created.
- Record Types: Supports Generic, Event Ticket, Store Card, Coupon, and Boarding Pass.
Editing Workflow Summary
To update a template like the Woofly Membership Pass:
- Search for the template in the Kemicard Console.
- Adjust Style (colors) and Barcodes (QR data source).
- Use Setup Modals to update images or remap Salesforce fields.
- Preview the Front, Back, and Notification views with a Sample Record for live data.
- Save to persist changes to the record and update the Field Map JSON.
Example:
This guide covers how to update an existing Kemicard template, including adding new fields, modifying Apple/Google wallet barcodes, and updating the background color.