Sign in
Developer tools
0%

The iohr command line

Install and sign in

Install iohr on Linux, macOS or Windows, check what you installed, sign in, keep accounts as profiles, manage tokens, use it in CI and find every command.

iohr signs you in, keeps each account you use as a profile, manages API tokens, makes authenticated calls, generates clients and installs extensions. It is one binary, open source in inorbithr/sdk, and talks only to api.inorbit.hr and auth.inorbit.hr (and to the extension registry, only when you install an extension). No telemetry, no update check.

The current release is 0.1.0-alpha.39, a pre-release: commands and output can still change before 1.0, and the release notes say what did.

Install

sudo install -d -m 0755 /etc/apt/keyrings
curl -fsSL https://packages.inorbit.hr/iohr.gpg | sudo tee /etc/apt/keyrings/iohr.gpg >/dev/null
sudo tee /etc/apt/sources.list.d/iohr.sources >/dev/null <<'SOURCES'
Types: deb
URIs: https://packages.inorbit.hr/apt
Suites: stable
Components: main
Signed-By: /etc/apt/keyrings/iohr.gpg
SOURCES
sudo apt update && sudo apt install iohr
  • APT serves amd64 and arm64. Upgrades come with apt upgrade like any other package.
  • Homebrew uses the tap inorbithr/homebrew-tap; brew install inorbithr/tap/iohr adds it on first use.
  • winget is not available yet. The package, InOrbit.iohr, is submitted to winget's catalogue from the first stable release; until then use the PowerShell installer or the .msi from the release.
  • The installers (install.sh, install.ps1) are short enough to read before you pipe them to a shell. Each downloads the archive for your machine from the GitHub release, refuses it unless its SHA-256 matches the release's SHA256SUMS, checks its build attestation when the GitHub CLI is installed and signed in, and copies one binary into your user directory.
  • Every release also has plain archives (Linux musl, macOS, Windows; x86-64 and arm64), a .deb and an .msi, each with a CycloneDX SBOM: github.com/inorbithr/sdk/releases.

Check what you installed

The APT repository is signed with a key used for nothing else:

gpg --show-keys /etc/apt/keyrings/iohr.gpg
KeyFingerprint
Primary (certifies, kept offline)5FF6 7AF3 D50A 6B06 FFE6 EA8A FFA5 11CF 585B F28D
Signing subkey (signs the repository, expires 2028-10-01)1725 799F E6C8 0810 9671 0D42 E7B1 639B 4435 8981

Every file on a release has a build provenance attestation from the SDK repository's release workflow:

tag=$(gh release list --repo inorbithr/sdk --limit 100 --json tagName \
  --jq 'map(select(.tagName | startswith("iohr/v")))[0].tagName')
gh release download "$tag" --repo inorbithr/sdk \
  --pattern 'iohr-*-x86_64-unknown-linux-musl.tar.gz' --pattern SHA256SUMS
sha256sum --check --ignore-missing SHA256SUMS
gh attestation verify iohr-*-x86_64-unknown-linux-musl.tar.gz --repo inorbithr/sdk

If a check fails, do not use the file; report it privately as the repository's SECURITY.md describes.

Sign in

iohr login
iohr whoami

On a machine with a browser, iohr login opens the InOrbit sign-in page and waits up to five minutes for it to come back to the terminal. Over SSH, in a container or without a display it prints a link and a short code instead: open the link on any device, sign in, and enter the code. --web and --device choose one. Only ever enter a code that you started yourself.

A signed-in session keeps a 15-minute access token and a 30-day refresh token, replaced on every use, in the operating system's credential store (macOS Keychain, Windows Credential Manager, the Secret Service on Linux); iohr refreshes it on its own. The console's sign-in devices list shows the session and can end it. iohr logout revokes it at the sign-in service, then forgets it on this machine.

Profiles

A profile is one way of calling the API: who signed in, and which account the calls count against. Keep one per account:

iohr login --profile acme          # a second sign-in, for your team's account
iohr profile list
iohr profile use acme              # the default from now on
iohr whoami --profile personal     # or pick one per command

--profile wins over IOHR_PROFILE, which wins over the default. Nothing depends on a global switch, so two terminals can use two profiles at once.

Environments

--env <name> (or IOHR_ENV) picks the environment to call: production, the default, or local. Any other name is refused. --base-url and IOHR_BASE_URL still win over it. The local environment has no public address: it is reached on loopback (http://localhost:28080, sign-in at http://auth.localhost:28080) through a tunnel to the machine that runs it. The SDKs take no environment name; point one at an environment with INORBIT_BASE_URL.

API tokens

iohr token create --name ci --scope radar:read --days 30
iohr token list
iohr token revoke <id>

token create prints the token once, on its own line, and nowhere else. A token never goes on the command line, where shell history and the process list would keep it; to sign in with one, pipe it in:

iohr login --with-token --profile ci < token.txt

In CI

Set IOHR_TOKEN and nothing is written to disk:

IOHR_TOKEN="$INORBIT_TOKEN" iohr api GET /v1/radar/digests -f limit=5

iohr api <METHOD> <PATH> makes one call with the active credential and prints the JSON answer; -f key=value adds a string field, -F key=json a typed one, --input file a body.

An SDK for your account

iohr sdk generate --lang rust --for personal --for ci --out src/iohr   # or typescript, go, python, csharp, java
iohr sdk check

sdk generate writes a client with exactly the operations each profile's credential may call, and sdk check fails in CI when that set has moved: Generate an SDK for your account.

Commands

CommandWhat it does
iohr login [--web | --device]Sign in and add a profile
iohr login --with-tokenRead an API token from stdin and add a profile
iohr logoutRevoke the session and forget the profile on this machine
iohr profile list | use | showThe profiles here and the default one
iohr profile account NAME ID|SLUGPoint a signed-in profile at one of its teams
iohr whoamiSubject, account, plan, scopes and expiry of the active profile
iohr authA profile's current access token, for another program that needs one
iohr accounts listThe accounts the credential can see
iohr token create | list | revokeAPI tokens for an account (a signed-in person only)
iohr api <METHOD> <PATH>One call; -f k=v, -F k=json, --input file; --all walks every page of a list
iohr openapi pullThe OpenAPI document this credential sees, to openapi.json
iohr sdk generate --lang … --for P… --out DIRA client cut to what the profiles may call (guide)
iohr sdk check [--files]Exit 1 with what moved when that cut changed; for CI
iohr sdk add [LANG] [--version V] [--dry-run]Add the published SDK to the project here with its own package manager (below)
iohr sdk config [--profile NAME]What an SDK's load would resolve here, secrets redacted
iohr domains add | verify | confirm | list | rmProve the account controls a domain with one DNS TXT record (Domains)
iohr connectors list [--category C] | show IDThe catalogue of apps a connection can be made from (Connections)
iohr connections list | show | add | test | history | pause | resume | rename | delete | reconnectThe account's connections: connect an app with a key or by signing in at the provider
iohr connections grant | grants | revoke-grantGrant a product, an API key or an agent named actions of a connection until an expiry
iohr project init NAMEStart a project: a folder, a record, an atlas, Roles, memory and a git repository (Projects)
iohr project template list | show | newThe project templates, what one writes, and your own
iohr atlas init | newAdd the atlas folder to a project; write a new PRD, RFC, ADR or study in it
iohr sync [--dry-run]Send the atlas to the space the project is linked to (Projects)
iohr memory remember | recall | list | forget | checkWhat a project has learned, as files with a reason (Projects)
iohr ask "question"Ask Io from the terminal, on Claude Code or Codex; ? at the prompt does the same (Ask Io from your prompt)
iohr shell hook zshThe zsh snippet that turns a line starting with ? into a question
iohr permissions list | allow | deny | remove | checkThe rules for what Io may run or open when you ask it something, for the project or for you
iohr asks list | show | count | approve | deny | questionThe asks agents file for you; approve waits while you approve on your phone
iohr ext show | searchThe extensions catalogue (Extensions)
iohr ext install | list | upgrade | remove | verify | syncExtensions: install, verify and pin them; iohr <name> … runs one
iohr packagesEvery package you have in one table: published, shared with you, in progress here and installed
iohr config set | get | unsetext.registry (a mirror) and ext.trusted_keys
iohr upgrade [--check]Update iohr the way it was installed; --check only reports. Needs no sign-in
iohr lab check [PATH…]Check RFCs and studies offline
iohr decisions …Decisions: list and read RFCs, PRDs and ADRs, create one, save a version, comment, ask for a review
iohr completion <shell>A completion script for bash, zsh, fish, elvish or PowerShell

Every command takes --profile (or IOHR_PROFILE), --json for machine-readable output and --verbose. --verbose prints method, path, status, time and request id on stderr, never a header, a query value or a body.

Sessions, Roles and asks

CommandWhat it does
iohr session [DIR]Open the project's session: its Roles answer every ? and ?? beside Io until the last session leaves. Needs the session profile set up once (below); macOS and Linux
iohr stop [DIR] [--wait S]End the project's session and wait up to --wait seconds (default 15) for its Roles to stop
iohr ask --role NAME "question"Answer in one Role: the project's, then your account's, then a built-in one (Roles)
iohr ask --read FOLDER "question"Let Io read one more folder for this question; repeat it for more (Folders Io may read)
iohr ask --mode manual | plan | autoWhere the ? mode starts (Modes)
iohr asks key enroll | show | removeOn a Mac, a key that lets iohr asks approve sign a review, a document, a decision or a run after Touch ID; a merge or a roll still goes to your phone

The session runs its own runner under the profile session, so set that up once:

iohr login --profile session
iohr --profile session runner register --name HOST-session

Exit codes

CodeMeaning
0success
1the call failed
2a usage error
3not signed in, or the token was refused
4forbidden by scope, role or plan

Add the SDK to a project

iohr sdk add             # the language and the package manager from the project's files
iohr sdk add --dry-run   # print the command, run nothing

iohr sdk add installs the published library with the package manager the project already uses. How it picks the language and the manager, and what it refuses: Add a library.

Where things are kept

  • Profiles: config.toml in the platform's config directory (~/.config/iohr on Linux, ~/Library/Application Support/hr.InOrbit.iohr on macOS, %APPDATA%\InOrbit\iohr\config on Windows). No secret is written there.
  • Secrets: the operating system's credential store (macOS Keychain, Windows Credential Manager, the Secret Service on Linux). Without one, --insecure-storage keeps the token in a file with mode 0600.
  • Extensions: the platform's data directory (~/.local/share/iohr/extensions on Linux), readable only by your user, with the machine's iohr-ext.lock.