{"id":18876080,"url":"https://github.com/activitywatch/aw-client","last_synced_at":"2025-10-10T14:11:32.966Z","repository":{"id":37998240,"uuid":"56850164","full_name":"ActivityWatch/aw-client","owner":"ActivityWatch","description":"Client library for ActivityWatch","archived":false,"fork":false,"pushed_at":"2025-01-10T17:39:34.000Z","size":531,"stargazers_count":57,"open_issues_count":16,"forks_count":50,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-09-21T12:33:54.833Z","etag":null,"topics":["activitywatch","client","library","python"],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ActivityWatch.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null},"funding":{"github":["ActivityWatch"],"open_collective":"activitywatch","liberapay":"ActivityWatch","custom":["https://activitywatch.net/donate/"]}},"created_at":"2016-04-22T11:19:48.000Z","updated_at":"2025-09-15T16:43:26.000Z","dependencies_parsed_at":"2024-11-06T07:30:27.555Z","dependency_job_id":"84087d69-2862-42ba-9498-76671e5af280","html_url":"https://github.com/ActivityWatch/aw-client","commit_stats":{"total_commits":304,"total_committers":16,"mean_commits":19.0,"dds":0.3421052631578947,"last_synced_commit":"16ff14f169e84b0ab75cf4704562aaa8bc7e83eb"},"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"purl":"pkg:github/ActivityWatch/aw-client","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ActivityWatch%2Faw-client","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ActivityWatch%2Faw-client/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ActivityWatch%2Faw-client/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ActivityWatch%2Faw-client/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ActivityWatch","download_url":"https://codeload.github.com/ActivityWatch/aw-client/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ActivityWatch%2Faw-client/sbom","scorecard":{"id":8390,"data":{"date":"2025-08-11","repo":{"name":"github.com/ActivityWatch/aw-client","commit":"8f9483ddb46e2dea3293092b26888e52bf38bb04"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.8,"checks":[{"name":"Code-Review","score":1,"reason":"Found 4/29 approved changesets -- score normalized to 1","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Info: jobLevel 'contents' permission set to 'read': .github/workflows/codeql.yml:17","Info: jobLevel 'actions' permission set to 'read': .github/workflows/codeql.yml:16","Warn: no topLevel permission defined: .github/workflows/build.yml:1","Warn: no topLevel permission defined: .github/workflows/codeql.yml:1","Warn: no topLevel permission defined: .github/workflows/examples.yml:1","Warn: no topLevel permission defined: .github/workflows/lint.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/build.yml:20: update your workflow using https://app.stepsecurity.io/secureworkflow/ActivityWatch/aw-client/build.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/build.yml:25: update your workflow using https://app.stepsecurity.io/secureworkflow/ActivityWatch/aw-client/build.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codeql.yml:27: update your workflow using https://app.stepsecurity.io/secureworkflow/ActivityWatch/aw-client/codeql.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codeql.yml:30: update your workflow using https://app.stepsecurity.io/secureworkflow/ActivityWatch/aw-client/codeql.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codeql.yml:36: update your workflow using https://app.stepsecurity.io/secureworkflow/ActivityWatch/aw-client/codeql.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codeql.yml:39: update your workflow using https://app.stepsecurity.io/secureworkflow/ActivityWatch/aw-client/codeql.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/examples.yml:21: update your workflow using https://app.stepsecurity.io/secureworkflow/ActivityWatch/aw-client/examples.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/examples.yml:26: update your workflow using https://app.stepsecurity.io/secureworkflow/ActivityWatch/aw-client/examples.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/examples.yml:44: update your workflow using https://app.stepsecurity.io/secureworkflow/ActivityWatch/aw-client/examples.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/lint.yml:13: update your workflow using https://app.stepsecurity.io/secureworkflow/ActivityWatch/aw-client/lint.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/lint.yml:14: update your workflow using https://app.stepsecurity.io/secureworkflow/ActivityWatch/aw-client/lint.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/lint.yml:15: update your workflow using https://app.stepsecurity.io/secureworkflow/ActivityWatch/aw-client/lint.yml/master?enable=pin","Warn: pipCommand not pinned by hash: .github/workflows/build.yml:32","Warn: downloadThenRun not pinned by hash: .github/workflows/build.yml:48","Warn: pipCommand not pinned by hash: .github/workflows/examples.yml:33","Warn: pipCommand not pinned by hash: .github/workflows/examples.yml:39","Warn: pipCommand not pinned by hash: .github/workflows/examples.yml:55","Info:   0 out of  10 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   2 third-party GitHubAction dependencies pinned","Info:   0 out of   4 pipCommand dependencies pinned","Info:   0 out of   1 downloadThenRun dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE.txt:0","Info: FSF or OSI recognized license: Mozilla Public License 2.0: LICENSE.txt:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Vulnerabilities","score":7,"reason":"3 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-9hjg-9r4m-mvj7","Warn: Project is vulnerable to: GHSA-48p4-8xcf-vxj5","Warn: Project is vulnerable to: GHSA-pq67-6m6q-mj2v"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"SAST","score":8,"reason":"SAST tool detected but not run on all commits","details":["Info: SAST configuration detected: CodeQL","Warn: 4 commits out of 8 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-14T14:03:44.305Z","repository_id":37998240,"created_at":"2025-08-14T14:03:44.306Z","updated_at":"2025-08-14T14:03:44.306Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279004181,"owners_count":26083688,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-10T02:00:06.843Z","response_time":62,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["activitywatch","client","library","python"],"created_at":"2024-11-08T06:10:35.992Z","updated_at":"2025-10-10T14:11:32.933Z","avatar_url":"https://github.com/ActivityWatch.png","language":"Python","readme":"aw-client\n=========\n\n[![GitHub Actions badge](https://github.com/ActivityWatch/aw-client/workflows/Build/badge.svg)](https://github.com/ActivityWatch/aw-client/actions)\n[![PyPI](https://img.shields.io/pypi/v/aw-client)](https://pypi.org/project/aw-client/)\n[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)\n[![Typechecking: Mypy](http://www.mypy-lang.org/static/mypy_badge.svg)](http://mypy-lang.org/)\n\nClient library for ActivityWatch in Python.\n\nPlease see [the documentation][docs] for usage, and take a look at `examples/`.\n\n - [Documentation][docs]\n - [API Reference][apiref]\n\n[docs]: https://docs.activitywatch.net/en/latest/\n[apiref]: https://docs.activitywatch.net/en/latest/api/python.html#aw-client\n\n## How to install\n\nInstall from pip: `pip install aw-client`\n\nInstall the latest version directly from github without cloning: `pip install git+https://github.com/ActivityWatch/aw-client.git`\n\nTo install from a cloned version:\n\n - clone repo: `git clone https://github.com/ActivityWatch/aw-client.git`\n - cd into the directory: `cd aw-client`\n - run `poetry install` (will create a virtualenv, if none activated)\n   - If you don't want to use poetry you can also use `pip install .`, but that might not get the exact version of the dependencies (due to not reading the `poetry.lock` file).\n\n## Usage\n\nFor the CLI:\n\n```\n$ aw-client --help\nUsage: aw-client [OPTIONS] COMMAND [ARGS]...\n\n  CLI utility for aw-client to aid in interacting with the ActivityWatch\n  server\n\nOptions:\n  --host TEXT     Address of host\n  --port INTEGER  Port to use\n  -v, --verbose   Verbosity\n  --testing       Set to use testing ports by default\n  --help          Show this message and exit.\n\nCommands:\n  buckets    List all buckets\n  canonical  Query 'canonical events' for a single host (filtered,...\n  events     Query events from bucket with ID `bucket_id`\n  heartbeat  Send a heartbeat to bucket with ID `bucket_id` with JSON `data`\n  query      Run a query in file at `path` on the server\n  report     Generate an activity report\n```\n\n\n## Debugging\n\n* Run python with `LOG_LEVEL=debug` to get additional debugging output\n* If invalid events have been queued for submission, you may need to delete the file-based queues generated by this library\n* To use the development version of this library use `aw-client = {path = \"../aw-client\" }` in `pyproject.toml`\n\n## Examples\n\nThe [`examples/`](examples/) directory contains a couple of example scripts, including:\n\n - [`time_spent_today.py`](examples/time_spent_today.py) - fetches all non-afk events and sums their duration to get the total active time for the day.\n - [`working_hours.py`](https://github.com/ActivityWatch/aw-client/blob/master/examples/working_hours.py) - computes hours worked per day (matching a \"work\" category rule), and exports matching events to a JSON file (for auditing).\n - [`load_dataframe.py`](https://github.com/ActivityWatch/aw-client/blob/master/examples/load_dataframe.py) - loads events from a host using a categorizing \u0026 AFK-filtering query, put result in a pandas dataframe, and export as CSV.\n - [`merge_buckets.py`](examples/merge_buckets.py) - merges two buckets with non-intersecting events by moving all events from one into the other.\n - [`redact_sensitive.py`](examples/redact_sensitive.py) - redact sensitive events.\n","funding_links":["https://github.com/sponsors/ActivityWatch","https://opencollective.com/activitywatch","https://liberapay.com/ActivityWatch","https://activitywatch.net/donate/"],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Factivitywatch%2Faw-client","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Factivitywatch%2Faw-client","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Factivitywatch%2Faw-client/lists"}