ZenMux/dsh-plugins0

@zenmux/dsh-plugins

ZenMux OAuth 2.0 PKCE login, token refresh, and Harness credential mirroring

包名
@zenmux/dsh-plugins
版本
0.1.7
许可证
MIT
最近更新
2026年8月17日

安装

$npx -p @deepseek-ai/dsh dsh plugin --profile web add github:ZenMux/dsh-plugins

Configuration

FieldDefaultMeaning
oauthOriginZENMUX_OAUTH_ORIGIN or https://zenmux.aiAuthorization-server origin; HTTPS is required except for loopback development
clientIdZenMux Harness public clientRegistered public OAuth client id
scopesinference:invoke, offline_accessRequired inference and refresh scopes
callbackPort0Loopback port; zero selects a free OS port
proxyUrlemptyOptional deployment-supplied http://, https://, socks4a://, or socks5h:// proxy; otherwise inherits HTTPS_PROXY/https_proxy, then connects directly
browserAutoOpendisabled only when ZENMUX_OAUTH_NO_BROWSER=1Automatically open the login URL in DSH Web while retaining the manual link
accessTokenRefZENMUX_OAUTH_ACCESS_TOKENRaw access-token mirror read by the LLM provider
tokenSetRefZENMUX_OAUTH_TOKENSVersioned JSON access/refresh token set
loginTimeoutMs300000Pending loopback-login lifetime
requestTimeoutMs30000Discovery, token, and revocation request timeout
refreshSkewMs60000Refresh lead time before expiry
refreshRetryMs30000Delay between failed background refresh attempts

Both credential references must be distinct writable references. Environment-supplied credentials are intentionally read-only in dsh-credentials-local; choose unshadowed references rather than expecting OAuth login to overwrite an exported variable.

Environment variables

VariableDefaultPurpose
ZENMUX_OAUTH_ORIGINhttps://zenmux.aiOAuth authorization-server origin
ZENMUX_OAUTH_CLIENT_IDbundled public clientOverride the OAuth public client ID
ZENMUX_OAUTH_SCOPESinference:invoke offline_accessWhitespace-separated login scopes
ZENMUX_API_BASE_URLhttps://zenmux.ai/api/v1Generic ZenMux API base; its origin is used to derive /api/anthropic
ZENMUX_ANTHROPIC_BASE_URLderived from ZENMUX_API_BASE_URLExact Anthropic Messages endpoint override
ZENMUX_OAUTH_NO_BROWSERunsetSet to 1 to suppress automatic browser opening
HTTPS_PROXY / https_proxyunsetOAuth discovery/token/revocation proxy when proxyUrl is empty

CODEX_HOME, ZENMUX_OAUTH_STATE_DIR, and ZENMUX_OAUTH_STORAGE belong to Codex-style file/keychain clients and are intentionally not consumed: DSH owns persistence through its credentials service. ZENMUX_MODELS_CATALOG_URL and ZENMUX_ANTHROPIC_MODELS_CATALOG_URL are build-time inputs for pnpm sync:models; they do not change a running DSH profile.