9. Fetching Historical Punch Logs
Sometimes you need to backfill attendance data for example, when setting up the integration for the first time, or when a connectivity gap caused some punches to be missed.
9.0 Using Load Punchlog
- Navigate to CAMS Biometric Settings
- Enter a Start Date in the designated field
- Enter an End Date
- Click the Load Punchlog button
- The app makes a LoadLog API call to the CAMS Gateway, which instructs the device to resend punch data for the specified range
- The returned punch records are processed through
handle_punch_logs()and inserted as Employee Checkin records
9.1 Subscription Dependency
The historical punch log retrieval feature depends on your CAMS subscription plan. Not all plans include the LoadLog (Operation #12) capability. Verify with your CAMS account representative that your subscription supports historical log retrieval before attempting to use this feature.
9.2 Recommended Date Range
The CAMS API documentation recommends a maximum range of 30 days per LoadLog request. For longer historical periods, split the request into multiple 30-day windows and load them sequentially.
9.3 Duplicate Prevention
The app includes logic to prevent duplicate Employee Checkin records when historical data is loaded. If a checkin record for the same employee and timestamp already exists, it will not be created again.