Skip to content

feat(core): session handshake + PactoSession#22

Merged
aguilar1x merged 2 commits into
PACTO-LAT:mainfrom
jean1222312432:feat/session-handshake-pacto-session
Jun 17, 2026
Merged

feat(core): session handshake + PactoSession#22
aguilar1x merged 2 commits into
PACTO-LAT:mainfrom
jean1222312432:feat/session-handshake-pacto-session

Conversation

@jean1222312432

@jean1222312432 jean1222312432 commented Jun 17, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Add Gateway checkout session handshake: CheckoutSession model, HMAC-bound clientSecret, POST /v1/session and POST /v1/session/refresh, with typed session errors (session_invalid / session_expired).
  • Extend @pacto-connect/core with createCheckoutSession, PactoSession (expiration + refresh), and typed PactoSessionError / PactoError.
  • Re-export new session types from @pacto-connect/react.

Closes #12

Test plan

  • npm run lint
  • npm run type-check
  • npm run test
  • Run prisma migrate deploy on Gateway DB for CheckoutSession
  • Manual: create session with publishable key + allowed Origin, refresh, confirm expired/invalid secrets return typed errors

@aguilar1x aguilar1x merged commit 3772ccd into PACTO-LAT:main Jun 17, 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.

feat(core): session handshake + PactoSession

2 participants