The development crew here has been busy improving our API and the tools for accessing it. We have much more planned, but wanted to announce the immediate availability of toolkit downloads for those PHP and Perl developers out there. These toolkits make accessing your TSheets data and doing things like clock-ins, clock-outs and job-code management a breeze.
Simple PHP Clock-in Example ∞
require_once('tsheets.inc.php'); $tsheets = new TSheetsRestClient($url, $api_key, $username, $password); $json = $tsheets->request('clock_in', array('job_code_id' => 12345678));
Simple Perl Clock-in Example ∞
require("HtGet.pm"); require("TSheetsRestClient.pm"); $tsheets = TSheetsRestClient->new($url, $api_key, $username, $password); %params = ('job_code_id' => '12345678'); $json = $tsheets->request('clock_in', \%params);
What else can the API Do? ∞
The full list is documented on the API page. A few examples:
- Find out if you’re on the clock or not
- Load a list of users on-the-clock
- Clock-in, clock-out & switch job-codes
- Add, edit, list & delete users
- Add, edit, list & delete job-codes
- Get day and week totals for hours logged
Please download these from the API Toolkit Downloads page.
Future Plans ∞
We actually have a number of enhancements to the API coming in the near future. A few worth mentioning are the ability to work with “manual” time entries (entries with no in/out times) and better reporting options. Enjoy what’s there and keep the stream of requests coming, it helps us prioritize what happens first.
Holiday cheer from the TSheets crew :)