Registry / http-networking / opencode-zed-auth-fixed

opencode-zed-auth-fixed

JSON →
library0.0.11jsnpmunverified

OpenCode plugin for routing model discovery and completions through Zed's hosted AI APIs. Version 0.0.11 is the latest release. It authenticates using Zed desktop credentials (Linux via secret-tool) or pasted tokens, exchanges them for short-lived LLM tokens, fetches the Zed model catalog, and forwards completions with SSE stream conversion. Designed for local development and requires manual provider bootstrap for first use. Differentiators: direct Zed integration, Linux secret-tool support, and SSE conversion from newline-delimited JSON.

npm install opencode-zed-auth-fixed
INSTALL
IMPORT
SIG · OPENCODE-ZED-AUTH-
O
opencode-zed-auth-fixed
http-networkingjavascriptv0.0.11
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

default
import plugin from 'opencode-zed-auth-fixed'
const plugin = require('opencode-zed-auth-fixed')
ESM-only; no CommonJS support.
createProvider
import { createProvider } from 'opencode-zed-auth-fixed'
Named export for custom provider creation; not typically used directly.
ZedAuthPlugin
import { ZedAuthPlugin } from 'opencode-zed-auth-fixed'
import { ZedPlugin } from 'opencode-zed-auth-fixed'
Ensure exact casing; case-sensitive import.

Shows local install, provider bootstrap, authentication, and a quick model query. Uses symlink to plugin file and runs bootstrap to register provider.

mkdir -p ~/.opencode/plugins ln -sfn $(pwd)/index.mjs ~/.opencode/plugins/zed-auth.js bun run bootstrap-config opencode auth login # Select 'Other' -> provider id: 'zed' -> 'Use local Zed desktop credentials (Linux)' opencode models zed opencode run -m zed/gpt-5-nano "say hello in one short sentence"
Debug
Known issues
gotchaProvider not found: zed on first run if plugin is not bootstrapped properly.
fix
Run 'bun run bootstrap-config' to seed provider entry in opencode.json.
affects: >=0.0.11
gotchaManual credential paste requires full 'secret =' value, not just inner token.
fix
When pasting, provide the entire secret string including 'secret = ...'
affects: >=0.0.11
breakingLinux-only secret-tool authentication; no macOS or Windows credential store support.
fix
Use paste credentials method on non-Linux platforms.
affects: >=0.0.11
Errors
Common errors & fixes
Provider not found: zed
Provider not registered in opencode.json, or plugin not symlinked correctly.
fix
Run 'bun run bootstrap-config' and ensure symlink is in ~/.opencode/plugins/zed-auth.js.
Error: Cannot find module 'opencode-zed-auth-fixed'
Package not installed or not resolvable in current directory.
fix
Run 'npm install opencode-zed-auth-fixed' or symlink index.mjs directly.
Error: secret-tool: not found
secret-tool not installed (required for automatic credential retrieval on Linux).
fix
Install libsecret-tools (e.g., apt install libsecret-tools) or use paste method.
Upgrade
Version history
0.0.11latest on npm
Audit
Dependencies
opencodeoptionalPlugin runtime; requires OpenCode to be installed and configured.
Agent activity
13 hits · last 30 days
node
12
OpenAI (training)
1
Resources
opencode-zed-auth-fixed — npm install opencode-zed-auth-fixed · libregistry