Examples

Inbox CLI

A command-line inbox for the notifications of every forge you configure.

inbox-cli prints one line per notification, newest first, from every forge you configure. View the source.

It reads providers from the FORGES_<KIND>_<FIELD> environment variables with providersFromEnv(). Some providers can't list notifications, such as Bitbucket, Azure DevOps and Cursor Origin. For those providers, the CLI lists the open threads in the repository that you set in FORGES_<KIND>_DEMO_REPO. Provider warnings go to stderr.

Run it

FORGES_GITHUB_TOKEN=ghp_... \
FORGES_BITBUCKET_USERNAME=me FORGES_BITBUCKET_PASSWORD=app-password \
FORGES_BITBUCKET_DEMO_REPO=acme/widgets \
pnpm --filter @forges-examples/inbox-cli start
github:github.com:notification/901234567  2025-09-18 09:12  github  acme/widgets  pull_request  review_requested  Add retry handling to the uploader

The first column is the key of the row. To mark a notification done, pass its key to --done:

pnpm --filter @forges-examples/inbox-cli start -- --done \
github:github.com:notification/901234567

On a forge that has only a read state, --done marks the notification read.

What it shows

  • Loading providers with providersFromEnv() and reading the skipped reasons.
  • Falling back from notifications.list() to threads.list() when can() says no.
  • Using notificationKey() to give each row a stable ID.

Run the tests

pnpm --filter @forges-examples/inbox-cli test

The tests run the real providers against fixtures, without a network connection.

Copyright © 2026