pi-mono/packages/coding-agent/src/utils
Vegard Stikbakke 9b9cb30ae1 feat(coding-agent): add pi auth login and logout
pi auth login <provider> logs in from the shell without starting a
session, like pi mcp login. Account sign-in is the default and takes
the provider's browser method; when the provider has another method,
it prints a hint to rerun with --no-browser. --no-browser skips the
browser method and uses the other one, such as device code, asking
only when there are several. --api-key saves an API key instead and
cannot be combined with --no-browser. After logging in, it fetches the
provider's model catalog, and for Radius it points the Radius MCP
server in the global mcp.json at the login without asking.

pi auth logout <provider> removes the stored credentials like /logout
and succeeds when nothing is stored. For MCP servers that use provider
credentials, pi mcp login and logout now refer to these commands
instead of /login and /logout.

/login shares the check for the Radius MCP server entry and the web
URL helpers with the new command.
2026-11-05 12:07:14 +01:00
..
abort.ts fix(coding-agent): make model refresh cancellation caller-owned 2026-08-04 00:03:52 +02:00
ansi.ts fix(coding-agent): strip private-parameter CSI sequences in stripAnsi 2026-10-28 20:14:09 +01:00
changelog.ts fix(coding-agent): ignore prerelease suffix of last seen changelog version (#11753) 2026-11-03 21:59:05 +01:00
child-process.ts fix: drain stdout before resolving when a child holds the pipe past exit (#5753) 2026-06-15 09:55:45 +02:00
clipboard-command.ts fix(coding-agent): start WSL interop helpers from / and report external editor failures (#11627) 2026-10-30 21:47:58 +01:00
clipboard-image.ts fix(coding-agent): require advertised X11 clipboard images 2026-09-24 09:15:58 +02:00
clipboard.ts feat(coding-agent): add PI_CLIPBOARD_OSC52 to force OSC 52 copies 2026-10-12 18:07:27 +02:00
deprecation.ts fix(coding-agent): make config env references explicit 2026-05-28 11:58:38 +02:00
exif-orientation.ts fix(coding-agent): scan past non-EXIF APP1 segments (#8616) 2026-09-03 11:02:39 +02:00
frontmatter.ts fix(coding-agent): normalize UTF-8 BOMs in text inputs 2026-08-19 14:11:02 +02:00
fs-watch.ts fix(coding-agent,mom): retry fs watchers on async errors closes #3564 2026-04-22 23:03:19 +02:00
git.ts fix(coding-agent): refresh temporary git sources pinned to a branch ref 2026-10-29 21:43:11 +01:00
highlight-js.d.ts fix(coding-agent,tui): reuse syntax highlighting and rendered Markdown blocks 2026-11-01 14:40:56 +01:00
html.ts chore(deps): replace cli-highlight (#4468) 2026-05-13 12:19:45 +02:00
image-convert.ts fix(tui,coding-agent): convert non-PNG images for Kitty in Image 2026-10-03 00:14:52 +02:00
image-process.ts fix(coding-agent): process BMP images from disk 2026-06-25 12:52:21 +02:00
image-resize-core.ts fix(coding-agent): pick the smaller of PNG and JPEG when resizing images (#11577) 2026-10-29 16:14:56 +01:00
image-resize-worker.ts fix(coding-agent): ignore Node's own worker messages in image resize 2026-10-07 12:26:43 +02:00
image-resize.ts fix(coding-agent): ignore Node's own worker messages in image resize 2026-10-07 12:26:43 +02:00
json.ts fix(coding-agent): make config env references explicit 2026-05-28 11:58:38 +02:00
management-http.ts fix(coding-agent): retry hung model catalog requests 2026-08-17 12:55:56 +02:00
mime.ts fix: require complete GIF image signatures 2026-09-21 10:30:42 +02:00
open-browser.ts fix(coding-agent): start WSL interop helpers from / and report external editor failures (#11627) 2026-10-30 21:47:58 +01:00
output-files.ts feat(coding-agent): save codemode image() output to temp files 2026-10-04 23:32:43 +02:00
paths.ts fix(coding-agent): compare paths case-insensitively on Windows (#11588) 2026-10-29 21:53:06 +01:00
photon.ts fix(coding-agent): load photon wasm in compiled binaries 2026-01-18 17:11:49 +01:00
pi-user-agent.ts feat(ai,agent,coding-agent): move client identity and provider attribution into pi-ai 2026-10-21 11:17:02 +00:00
shell.ts fix(coding-agent): stop macOS shell groups before killing them 2026-10-22 20:22:20 +02:00
sleep.ts refactor(coding-agent): simplify AgentSession 2026-01-24 01:38:58 +01:00
syntax-highlight.ts fix(coding-agent,tui): reuse syntax highlighting and rendered Markdown blocks 2026-11-01 14:40:56 +01:00
terminal-question.ts feat(coding-agent): add pi auth login and logout 2026-11-05 12:07:14 +01:00
text.ts fix(coding-agent): normalize UTF-8 BOMs in text inputs 2026-08-19 14:11:02 +02:00
tool-result-images.ts feat(ai,coding-agent): add image input limits (closes #9631) 2026-09-20 22:59:16 +02:00
tools-manager.ts fix(coding-agent): skip fd/rg downloads on unsupported architectures 2026-10-23 19:48:59 +02:00
version-check.ts fix: build error on request info (#7645) 2026-08-05 09:56:43 +02:00
web-url.ts feat(coding-agent): add pi auth login and logout 2026-11-05 12:07:14 +01:00
windows-self-update.ts chore(ts): use source import extensions 2026-05-20 00:04:03 +02:00
wsl.ts fix(coding-agent): restore OSC 52 clipboard fallback for headless sessions 2026-09-20 12:42:15 +02:00
zip.ts feat(coding-agent): add bug reporting 2026-09-19 17:55:49 +02:00