Skip to content

fix(auth): send expiring: 1 on OAuth code grant in server.js - #26

Merged
arsalan-arshad merged 1 commit into
mainfrom
fix/oauth-expiring-token
Nov 6, 2026
Merged

arsalan-arshad merged 1 commit into
mainfrom
fix/oauth-expiring-token

Conversation

@arsalan-arshad

Copy link
Copy Markdown
Owner

Summary

  • Expiring offline tokens on OAuth code grant: In server.js, updated manual OAuth authorization code exchange (POST /admin/oauth/access_token) to explicitly include expiring: 1 per Shopify's migration guide for expiring offline tokens.
  • Expiry tracking: Parsed expires_in and persisted the computed expires Date in the Session table, maintaining refreshToken: null for minimal secrets at rest.
  • Testing: Allowed optional fetchFn in createRequestListener and added a unit test in test/server.test.js asserting expiring: 1 is sent and expiry timestamp is saved.
  • Docs & counts: Updated test counts to 582 passing unit tests across README, BUILD_PLAN, and PROJECT_CONTEXT.

@arsalan-arshad
arsalan-arshad merged commit ee76792 into main Nov 6, 2026
1 check passed
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.

1 participant