Skip to content
michaelsanfordPublic

About

A native Windows system tray app that turns GitHub and Bitbucket activity into a focused developer inbox. It monitors pull requests, reviews, comments, mentions, pushes, and other repository movement across the projects you care about, then surfaces only the items that need your attention.

Topics

Resources

Code of conduct

Security policy

Stars

2 stars

Watchers

1 watching

Forks

Repository files navigation

Trayage

Trayage

CI Coverage PowerShell Lint CodeQL Release

.NET 11 Platform License: MIT Mirror

SLSA 3 Build provenance SBOM Signed

A .NET 11 Windows system-tray app that gathers your GitHub, Bitbucket Cloud, and GitLab.com activity into one unified inbox, lets you jump straight to the relevant page with a click, and raises native Windows toast notifications for the things you care about.

Trayage is the successor to bittray — a Go tray app that watched Bitbucket Server for pull requests needing review. Trayage modernises the idea on .NET 11 with a Fluent (Windows 11) UI, adds GitHub, and broadens "needs review" into a configurable inbox.

Website: https://www.michaelsanford.com/Trayage/

Mirrors: read-only copies (no collaboration — issues and PRs stay on GitHub) are mirrored to GitLab and Bitbucket.

Install

Grab the latest build from the Releases page: download the .zip for your architecture (win-x64 for most PCs, win-arm64 for Arm devices), unzip it anywhere, and run Trayage.exe. The build is self-contained — no .NET runtime install required. It lands in the system tray; there's no main window.

Each release ships with build provenance, a cosign signature, and a CycloneDX SBOM — see Verifying a release if you'd like to check them first.

Features

  • Unified inbox in a tray flyout — grouped by repository, by owner or organisation, or ungrouped as a flat newest-first list under Today / Yesterday headers. Groups sort alphabetically with the newest items first inside each, collapse when you click their header, and stay collapsed across restarts. Already-read items can be hidden. Click any item to open it in your browser.
  • Mark as read — one item from its row, a whole repository or owner from its group header, or the entire inbox from the flyout header; opening an item marks it read too. Trayage tells the service where it can (see the limitations below) and always remembers locally, so a mark takes effect at once, survives a restart, and works offline. If the thread later sees genuine new activity it comes back as unread and still raises a notification.
  • Several accounts per service — a work and a personal GitHub, two Bitbucket workspaces under different logins. Each account keeps its own sign-in, its own watched repositories, and can be paused without disconnecting it. When more than one account is connected to the same service, inbox items say which one they came from.
  • Sources
    • GitHub via the notifications API — review requests, mentions, assignments, CI activity, and watched-repo activity.
    • Bitbucket Cloud via pull-request queries — PRs you authored, PRs in watched repos where you're a reviewer, and all activity in watched repos. Because Bitbucket has no notification inbox, each Bitbucket account's card in Settings → Accounts lets you load the repositories that account can reach and toggle the ones to watch (no need to type owner/repo by hand). Watched repositories are per account, so a repository only one account can see is never queried with another's token.
    • GitLab.com via the to-do API — assignments, mentions, review/approval requests, failed pipelines, and other to-dos. Like GitHub, GitLab has a centralized server-side inbox, so there's nothing to configure per-repository.
  • Native toast notifications with per-class toggles (review requests, mentions & assignments, CI/check status) plus all activity on repositories you choose to watch. Clicking a toast opens the page. Toasts use the Windows App SDK and require the Windows App Runtime; if it isn't present Trayage still runs and tracks your inbox from the tray, and Settings → Notifications shows a one-click link to install it.
  • Tray icon — three descending priority bars (a sorted queue) whose tint reflects state: blue with an amber top bar when items are waiting, plain blue when you're caught up, grey when nothing is connected, and red when an account is configured but has no live session. The icon comes back on its own if Explorer restarts.
  • Settings window with five pages — Accounts, Notifications, Inbox, General, and About. Accounts is the list of connected accounts: expand one to rename it, pause it, disconnect or remove it, pick its watched repositories (Bitbucket), or jump to the service's own notification settings (GitHub and GitLab, where that activity is actually controlled). The rest cover notification classes and sound, how the inbox groups its items and whether read ones show, poll cadence, light/dark/system theme, "start with Windows", and verbose logging.
  • Secure tokens — OAuth tokens are encrypted at rest with Windows DPAPI, keyed per account; nothing is stored in plaintext.

Requirements

  • Windows 10 (1809+) or Windows 11 (the app targets net11.0-windows10.0.19041.0 and uses WPF + WinRT toast APIs, so it builds and runs on Windows only)
  • .NET 11 SDK to build (or the .NET 11 Desktop Runtime to run a framework-dependent build)

Build & run

dotnet build                             # builds the solution
dotnet test                              # runs the Trayage.Core unit tests
dotnet run --project src/Trayage.App     # launches the tray app

The app runs in the system tray — there is no main window. Left-click the tray icon for the inbox flyout; right-click for the menu (Open inbox / Refresh / Settings / Quit).

To produce a distributable build for a given architecture:

dotnet publish src/Trayage.App -c Release -r win-x64   --self-contained
dotnet publish src/Trayage.App -c Release -r win-arm64 --self-contained

Where Trayage stores data

Everything lives under %APPDATA%\Trayage\:

File Contents
settings.json Non-secret settings (poll interval, theme, and the connected accounts with their watched repos)
secrets.dat OAuth access/refresh tokens, one set per account, each encrypted with DPAPI (CurrentUser)
logs\trayage.log Rolling application log
logs\crash.log Unhandled-exception records

Logs stay on your machine and are never transmitted. Tokens are never written to them, and Trayage keeps account identifiers — your provider login and user ID — out of the logs on a best-effort basis.

OAuth setup (source builds only)

Released builds ship with OAuth client identifiers baked in, so end users never configure anything — they just open Settings → Accounts and click Connect. This section applies only when running from source.

Register one OAuth app per provider (once), then drop the identifiers into a gitignored src/Trayage.App/appsettings.local.json (loaded after, and overriding, the committed appsettings.json):

{
  "GitHub": { "ClientId": "Ov23li…" },
  "Bitbucket": { "Key": "…", "Secret": "…" },
  "GitLab": { "ApplicationId": "…" }
}
  • GitHub — Settings → Developer settings → OAuth Apps → New OAuth App. Tick Enable Device Flow, set any callback URL (unused by the device flow), and copy the Client ID. The device flow needs no client secret.
  • Bitbucket Cloud — Workspace settings → OAuth consumers → Add consumer. Set the callback to exactly http://localhost:33418/callback, grant Account, Repositories, and Pull requests read access, and copy the Client ID (older UIs label it the Key) and the Secret. Two read permissions are load-bearing, and they are separate checkboxes: Account backs the /2.0/user and /2.0/user/workspaces calls (workspace discovery), and Repositories backs the per-workspace repo listing (/2.0/repositories/{workspace}) behind each Bitbucket account's repository picker. "Pull requests: Read" does not grant repository listing — enable Repositories: Read explicitly. Trayage logs the token's granted scopes on connect (Bitbucket token scopes: …); if the picker errors or shows nothing, check that line for account and repository. A token only carries the scopes it was first authorized with, so after changing consumer permissions you must disconnect and reconnect (a refresh keeps the old scopes) for the new ones to take effect.
  • GitLab.com — Preferences → Applications → Add new application. Leave Confidential unchecked (Trayage is a public client using the OAuth device flow), tick the read_api (to-do inbox) and read_user (account username via /user) scopes, and copy the Application ID. The device flow needs no redirect URI and no secret.
Provider UI field Config key Release secret
GitHub Client ID GitHub:ClientId GH_OAUTH_CLIENT_ID
Bitbucket Client ID / Key Bitbucket:Key BITBUCKET_OAUTH_KEY
Bitbucket Secret Bitbucket:Secret BITBUCKET_OAUTH_SECRET
GitLab Application ID GitLab:ApplicationId GITLAB_OAUTH_APP_ID

Releases inject these in CI from repository secrets (right column). The Bitbucket secret ships embedded in the binary, so it isn't truly confidential — treat it as a public identifier, as gh and other desktop OAuth clients do. Tokens obtained at connect time are stored separately and DPAPI-encrypted (see data storage).

Verifying a release

Every tagged release is built in GitHub Actions and published with supply-chain evidence:

  • GitHub build-provenance attestation for each .zip (proves which workflow, commit, and runner produced it).
  • cosign keyless signature — a .zip.bundle next to each archive (Sigstore, GitHub OIDC, no long-lived keys).
  • CycloneDX SBOM (trayage-<tag>-sbom.cdx.json) listing the dependency graph.

One command

Verify-Release.ps1 downloads the release assets and checks all three:

./Verify-Release.ps1                 # latest release
./Verify-Release.ps1 -Tag v1.0.0     # a specific tag

It needs gh and cosign on PATH (winget install GitHub.cli sigstore.cosign); install CycloneDX.CLI too for formal SBOM schema validation.

By hand

# 1. Build provenance
gh attestation verify trayage-v1.0.0-win-x64.zip --repo michaelsanford/Trayage

# 2. cosign signature (identity = the release workflow at that tag)
cosign verify-blob `
  --bundle trayage-v1.0.0-win-x64.zip.bundle `
  --certificate-identity "https://github.com/michaelsanford/Trayage/.github/workflows/release.yml@refs/tags/v1.0.0" `
  --certificate-oidc-issuer "https://token.actions.githubusercontent.com" `
  trayage-v1.0.0-win-x64.zip

Known limitations

  • Bitbucket mentions and CI/check status are not surfaced. Bitbucket Cloud has no notification inbox and no first-class mention feed, so Trayage assembles its Bitbucket inbox from pull-request queries only.
  • Bitbucket PRs surface only for watched repos. Bitbucket retired its cross-repo endpoints (CHANGE-2770), so authored PRs, review requests, and repo activity are all queried per watched repo. A PR appears only if its repository is on that account's watched list — add repositories from the account's card in Settings → Accounts.
  • Marking read reaches each service differently. On GitHub the notification thread is marked read on GitHub itself. On GitLab the to-do is marked done, which removes the item rather than dimming it — Trayage reads the pending to-do list, and a done to-do is no longer pending. Bitbucket has no notification inbox to mark, so its read marks are local to Trayage and won't show anywhere else.
  • GitLab accounts connected before mark-as-read existed need reconnecting. GitLab offers no narrow write scope, so marking a to-do done needs the full api scope where Trayage previously asked only for read_api. Reads keep working on an older token; the first attempt to mark read prompts you to reconnect that account, and the mark is kept locally meanwhile.
  • Bitbucket loopback port is fixed at 33418 to match the consumer callback URL. If that port is in use, the connect step will report an error. It also means only one Bitbucket account can be authorized at a time — connect them one after another.

Architecture

Project Responsibility
Trayage.App WPF + WPF-UI shell: tray icon, inbox flyout, Settings window, toast notifier, host/DI
Trayage.Core Provider abstraction & per-account registry, inbox aggregation & diffing, polling, notification rules, settings & migration, DPAPI secret store, GitHub, Bitbucket & GitLab providers
Trayage.Core.Tests xUnit tests for the inbox/notification/settings/secret-store logic

Providers implement IInboxProvider, one instance per connected account, and translate their native payloads into a shared InboxItem. ProviderFactory builds them and ProviderRegistry owns the live set, so connecting or removing an account takes effect on the next poll rather than after a restart. InboxPollingService refreshes on an interval, the InboxDiffer detects new activity, and the NotificationRuleEngine decides what becomes a toast. The first poll after launch is silent so you aren't flooded with notifications for items already waiting.

Icons

The Trayage mark and all icon assets are generated from a single glyph definition by tools/Build-TrayageIcons.ps1 (PowerShell 7 + GDI+, no external tooling). It emits the app/.exe icon and the four tray-state glyphs (caught-up, unread, disconnected, error) into src/Trayage.App/Assets/, plus the full-colour OAuth tile under assets/oauth/. assets/trayage-mark.svg is the committed vector master. Pass -Preview to drop a contact sheet of every variant in tools/preview/ for review. Re-run the script after changing the glyph.

Contributing

Issues and pull requests are welcome. For bugs and feature requests, please use the issue templates — they pre-fill the details that make triage fast. Run dotnet build and dotnet test before opening a PR.

NuGet dependencies are pinned in committed packages.lock.json files and CI restores in locked mode, so after changing a PackageReference run dotnet restore --force-evaluate and commit the updated lock files. The SDK version is pinned in global.json. Dependabot opens weekly PRs for NuGet packages, the CI tools in .config/dotnet-tools.json, and GitHub Actions (actions stay pinned to commit SHAs). Run dotnet tool restore to get the same ReportGenerator and CycloneDX versions CI uses.

By participating you agree to the Code of Conduct.

Security

Please report vulnerabilities privately — see the security policy. It covers the Trayage application itself; issues with GitHub, Bitbucket, or their services should go to those providers.

Acknowledgements

Trayage stands on the shoulders of bittray, its Go predecessor that watched Bitbucket Server for pull requests needing review a decade ago.

Audio Assets

The notification sounds included in this project are sourced from Mixkit and used under the Mixkit Sound Effects Free License. Special thanks to Mixkit for providing these high-quality resources.

Disclaimer

Trayage is not affiliated with or endorsed by GitHub or Atlassian.

License

Trayage is released under the MIT License.

About

A native Windows system tray app that turns GitHub and Bitbucket activity into a focused developer inbox. It monitors pull requests, reviews, comments, mentions, pushes, and other repository movement across the projects you care about, then surfaces only the items that need your attention.

Topics

Resources

Code of conduct

Security policy

Stars

2 stars

Watchers

1 watching

Forks

Releases

Sponsor this project

Used by

Contributors

Languages