Background
The wrapper supports OAuth authorization-code flow, device-code flow, and token refresh. The README and examples show sign-in flows, but a short refresh-token example would help apps keep Trakt sessions alive without making users sign in again.
Proposed change
Add a concise example showing trakt.auth.refreshToken and trakt.setAccessToken, with a note that apps should persist the returned refresh token securely.
Acceptance criteria
docs/examples.md includes a token refresh example.
- The example uses the existing
auth.refreshToken method.
- The wording does not recommend storing tokens in client-side source code.
bun run verify passes.
Files likely involved
docs/examples.md
README.md
Background
The wrapper supports OAuth authorization-code flow, device-code flow, and token refresh. The README and examples show sign-in flows, but a short refresh-token example would help apps keep Trakt sessions alive without making users sign in again.
Proposed change
Add a concise example showing
trakt.auth.refreshTokenandtrakt.setAccessToken, with a note that apps should persist the returned refresh token securely.Acceptance criteria
docs/examples.mdincludes a token refresh example.auth.refreshTokenmethod.bun run verifypasses.Files likely involved
docs/examples.mdREADME.md