Deputy and MySQL: Daily Attendance Snapshot Template
A scheduled Spojit workflow that reads each day's Deputy timesheets and writes an attendance snapshot to MySQL for historical reporting.
What It Builds
A Schedule trigger fires once a day and a Deputy Connector node in Direct mode pulls the previous day's timesheets, including clock-in and clock-out times per employee. A Transform node shapes those rows into a tidy snapshot, then a MySQL Connector node inserts them into your reporting table. Over time you build a clean attendance history you can query for payroll, audits, and trend analysis.
The Prompt
Paste this into Miraxa and it builds the workflow, connecting the tools for you:
Build a workflow that runs every day at 6am, reads yesterday's Deputy timesheets including each employee's clock-in and clock-out times, and inserts one attendance snapshot row per employee into the daily_attendance table in MySQL with the date, employee name, hours worked, and shift status.
Connectors Used
- Schedule trigger - runs the workflow once a day on a cron schedule in your timezone.
- Deputy - reads timesheets and clock-in records for the reporting day.
- MySQL - writes the attendance snapshot rows into your reporting table.
Customize It
Change the run time in the prompt, point it at a different MySQL table name, or adjust which fields land in each row (add overtime hours, location, or department). You can also widen the window to a weekly snapshot by asking for the last seven days instead of yesterday.
Tips
- Give the Deputy connection read scope for timesheets, and the MySQL connection insert rights on the target table.
- Keep the Deputy and MySQL nodes in Direct mode for predictable, no-AI-cost runs.
- Use a unique key on date plus employee so re-runs do not create duplicate snapshot rows.