
Security News
CISA’s 2025 SBOM Guidance Adds Hashes, Licenses, Tool Metadata, and Context
CISA’s 2025 draft SBOM guidance adds new fields like hashes, licenses, and tool metadata to make software inventories more actionable.
Toki.app command-line client and API server.
Access your Toki data from the local database or from the App.net backup channel, via the CLI interface or the served API.
UPDATE
Toki.app will cease to function when App.net will shut down their servers on 2017/03/14.
TokiCLI will continue to function but will then be irrelevant as there will not be anything to track anymore via Toki.app (and TokiCLI's App.net-related will also cease to function, of course).
You will still be able to read and analyse your existing data with TokiCLI.
gem install TokiCLI
toki
shows the basic commands.
toki help <command>
shows help and available options for a specific command.
Example:
toki help bundle
The total command shows the total usage time for all apps.
toki total
The results are sorted by ascending usage time.
The top command shows your top used apps.
toki top
TokiCLI shows the top 5 by default, but you can specify a number with the -n
option:
toki top -n 10
The day command shows your top used apps on a specific day.
The date you type has to be formatted like this: year-month-day
toki day 2014-04-19
The since command shows your top used apps since a specific day.
toki since 2014-04-19
The before command shows your top used apps before a specific day.
toki before 2014-04-19
The range command shows your top used apps between two specific days.
toki range 2014-04-17 2014-04-19
Complete log for an app
toki app airmail
Several apps may contain the same name. In that case, they will all be processed.
Example: toki app apple
Complete log for an app before a specific day
toki app airmail --before 2014-04-19
Complete log for an app since a specific day
toki app airmail --since 2014-04-19
Complete log for an app on a specific day
toki app airmail --day 2014-04-19
Complete log for an app between two specific days
toki app airmail --range 2014-04-19 2014-05-12
Complete log for an app, given its exact bundle ID.
Same features as for app
, just give an app bundle instead of an app name.
This should always return only one app log.
toki bundle it.bloop.airmail
toki bundle it.bloop.airmail --before 2014-04-19
toki bundle it.bloop.airmail --since 2014-04-19
toki bundle it.bloop.airmail --day 2014-04-19
toki bundle it.bloop.airmail --range 2014-04-19 2014-05-12
Recent Toki activity log.
toki activity
Complete Toki activity log since a specific day.
toki activity --since 2014-04-19
Complete Toki activity log for a specific day.
toki activity --day 2014-04-19
Scan for apps name.
Will crawl the Applications folder and try to resolve app names from bundle identifiers.
Toki can display apps names in results only if apps have been scanned.
Export the Toki results as a JSON file with the --json
option:
toki total --json
toki day 2014-04-18 --json
toki top -n10 -J
Export the Toki results as a CSV file with the --csv
option:
toki total --csv
toki day 2014-04-18 --csv
toki top -n10 -C
Completely delete all traces of an app in the database.
With backup:
toki delete it.bloop.airmail
Without backup:
toki delete it.bloop.airmail --no-backup
Toki.app backs up your Toki tracked apps data 'in the cloud' via an App.net channel.
TokiCLI should be able to download this data and rebuild the Toki database if you lost your local install or if it has been compromised.
toki restore
toki serve
Returns a JSON response for each request.
Examples of API calls with curl:
curl http://localhost:4567/api/apps/top/10
curl http://localhost:4567/api/apps/day/2014-05-27
curl http://localhost:4567/api/apps/range/2014-05-27/2014-05-30
curl http://localhost:4567/api/logs/app/safari/
curl http://localhost:4567/api/logs/app/safari/since/2014-05-27
curl http://localhost:4567/api/logs/bundle/com.apple.Safari/before/2014-05-27
curl http://localhost:4567/api/user
curl http://localhost:4567/api/bundles
Find the list of all endpoints with curl http://localhost:4567/api
.
You can also use the TokiCLI API in another app:
require 'TokiCLI'
Create a basic TokiCLI API instance without referencing bundles:
toki = TokiCLI::TokiAPI.new("#{~/Library/path/to/tokiapp/db}", {})
Create a TokiCLI FileOps instance:
fileops = TokiCLI::FileOps.new
Scan for apps names (see ##Tools):
fileops.save_bundles
Create a TokiCLI API instance:
toki = TokiCLI::TokiAPI.new(fileops.db_file, fileops.bundles)
See toki_api.rb
and fileops.rb
for the list of available methods.
Toki is a Mac OS X app written by Keitaroh Kobayashi.
It's a time tracker for your apps that sits in the menu bar.
TokiCLI does not track your apps.
Tracking is the job of Toki.app by @keita.
TokiCLI interacts only with the Toki.app database or the App.net backup channel.
FAQs
Unknown package
We found that TokiCLI demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
CISA’s 2025 draft SBOM guidance adds new fields like hashes, licenses, and tool metadata to make software inventories more actionable.
Security News
A clarification on our recent research investigating 60 malicious Ruby gems.
Security News
ESLint now supports parallel linting with a new --concurrency flag, delivering major speed gains and closing a 10-year-old feature request.