Skip to content

docs: add zsxq adapter documentation#589

Closed
bhutano wants to merge 8 commits intojackwener:mainfrom
bhutano:feat/spotify-adapter
Closed

docs: add zsxq adapter documentation#589
bhutano wants to merge 8 commits intojackwener:mainfrom
bhutano:feat/spotify-adapter

Conversation

@bhutano
Copy link
Copy Markdown
Contributor

@bhutano bhutano commented Mar 29, 2026

Adds missing documentation for the zsxq adapter that was included in the spotify branch but lacked docs.

bhutano and others added 8 commits March 28, 2026 14:08
Adds a new adapter for controlling Spotify via the official Web API.
Uses Strategy.PUBLIC with OAuth2 — no browser session required.

Commands: auth, status, play, pause, next, prev, volume, search, queue, shuffle, repeat.
Credentials are loaded from ~/.opencli/spotify.env or environment variables.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Renamed src/clis/spotify/index.ts to spotify.ts so the build-manifest
  picks it up (index.js is intentionally excluded from manifest scanning)
- Fixed 4 CliError calls: constructor now requires (code, message, hint?)
  so each throw now passes an appropriate error code as first argument

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…alidation

- refreshAccessToken: check res.ok before parsing; construct Tokens object
  directly instead of mutating loadTokens() result to avoid writing
  undefined/NaN on Spotify error responses; preserve existing refresh_token
  when Spotify omits it from the response
- loadEnv: split on first '=' only so values containing '=' are preserved
- SCOPES: remove write/library/top scopes not used by any command
- status: guard against data.item being null (active device but no track)
- volume: validate 0-100 range before API call
- auth: check tokenRes.ok on initial token exchange; add server.on('error')
  handler for EADDRINUSE; add 5-minute timeout with clearTimeout on close
…tall

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…, corrupted tokens, invalid search limit

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@bhutano
Copy link
Copy Markdown
Contributor Author

bhutano commented Mar 29, 2026

Il file zsxq.md esiste già nel main branch. Per fixare il doc-coverage check, fai rebase di feat/spotify-adapter su main.

@bhutano bhutano closed this Mar 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants