cancel
Showing results for 
Search instead for 
Did you mean: 

Any interest in knowing how to work with API's?

ashokr
Community Ambassador

I'm a command line junkie :-). I have some scripts that can perform sales analysis and employee timecard tasks on the command line.

  • Works well on macOS and Linux. 
  • For Windows, I think the best is to install WSL for a Linux environment.
  • I have a cron job set up that can simply email me the timing for each employee. Every Sunday since our pay dates are Sunday - Saturday. And flexible to do different things for different employees if you don't have the same schedule. 

If there is interest, I can post the scripts here or give a pointer to a git repo. 

Ashoks-Air:toast-menu-generator araj$ ./sales.py -
--all --file --last-year --this-year -h
--compare --help --range --today
--date --last-month --this-month --yesterday
--debug --last-week --this-week -d

(venv) Ashoks-Air:toast-menu-generator araj$ ./emptime.py -h
usage: emptime.py [-h] [-t] [-s START] [-e END] [-d]

Toast API Time Logs Manager

============================================================
TIME LOG SUMMARY (2025-08-17 to 2025-08-23)
============================================================
Emp1:
Regular Hours: 40.00
Overtime Hours: 14.80
Total Hours: 54.80
Entries: 11

Emp2
Regular Hours: 27.55
Overtime Hours: 0.00
Total Hours: 27.55
Entries: 6


Detailed time log entries saved to time_logs_detailed_2025-08-17_to_2025-08-23.json
Total detailed entries: 17

optional arguments:
-h, --help show this help message and exit
-t, --time-logs Get time logs for employees (uses previous week:
Sunday to Saturday)
-s START, --start START
Start date (YYYY-MM-DD) - must be used with -e
-e END, --end END End date (YYYY-MM-DD) - must be used with -s
-d, --debug Enable debug output showing detailed API responses

Cheers, Ashok

 

- Ashok Raj
Toast Community Ambassador
6 REPLIES 6

very nice! I haven't looked into these yet, but I would like to be able to calculate employee reliability (time scheduled vs actual clock in times) so they can see it and so I can use it for performance reviews and reward the team members that are reliable.
we use sling for scheduling which integrates with Toast.

That sounds like a great idea.. I assume you have Toast Payroll then?  Ot just sling for scheduling? Is there a benefit between using sling vs Toast for scheduling? 

This is good, I'll look into it for sure. Does Slack has any API's to get data like Toast? If you have a reference would help the hunt!

 

- Ashok Raj
Toast Community Ambassador

Well, the difference between a single developer and a big company. I just finished my prototype and its mostly functional at this time. But Toast beat me to it LOL. 

This is how my interface looks. 

 

My version of sales support !!!My version of sales support !!!Official Toast Version. The results are identical to how my version works.Official Toast Version. The results are identical to how my version works.

- Ashok Raj
Toast Community Ambassador

Rob
Community Manager
Community Manager

This is super cool, thanks for posting this! 



Robert Anderson, Community Manager
Toast