Skip to content

[codex] Export public client session types#60

Merged
osamasayed merged 2 commits into
mainfrom
codex/public-entrypoint-types
May 18, 2026
Merged

[codex] Export public client session types#60
osamasayed merged 2 commits into
mainfrom
codex/public-entrypoint-types

Conversation

@basit3407
Copy link
Copy Markdown
Collaborator

@basit3407 basit3407 commented May 18, 2026

Summary

Fixes #59 by re-exporting the public OAuth session storage types from the @quranjs/api/public entrypoint.

The runtime public entrypoint already uses these types in its declaration surface, but only createPublicClient and PublicClient were exported. Consumers importing TokenStorage or UserSession from @quranjs/api/public hit TypeScript export errors even though the root package entrypoint exported them.

Changes

  • Re-export TokenStorage and UserSession from packages/api/src/public.ts as type-only exports.
  • Add a TypeScript compiler smoke test that imports the storage/session types from the public package subpath.
  • Add a patch changeset for @quranjs/api.
  • Refresh the generated operation catalog so CI matches the current OpenAPI source.

Validation

  • pnpm --filter @quranjs/api build with Node v22.16.0
  • pnpm --filter @quranjs/api exec vitest run test/public-types.test.ts test/public-client.test.ts
  • pnpm --filter @quranjs/api check:operation-catalogs
  • C:\Code\qf-user-poc POC check: in-memory TypeScript compile importing PublicClient, TokenStorage, and UserSession from @quranjs/api/public against the linked local SDK build

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 18, 2026

size-limit report 📦

Path Size
dist/index.min.js 4.44 KB (0%)
dist/index.min.mjs 4.49 KB (0%)
dist/server.min.js 10.37 KB (+0.58% 🔺)
dist/public.min.js 5.84 KB (0%)

@basit3407 basit3407 requested a review from Copilot May 18, 2026 11:30
@basit3407 basit3407 marked this pull request as ready for review May 18, 2026 11:30
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the @quranjs/api/public entrypoint to expose OAuth/session-related types needed by consumers building custom public-client session storage.

Changes:

  • Re-exports selected session/token types from packages/api/src/public.ts.
  • Adds a patch changeset for @quranjs/api.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
packages/api/src/public.ts Adds type-only exports for public OAuth/session-related types.
.changeset/public-type-exports.md Records the patch release note for the new public type exports.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread packages/api/src/public.ts Outdated
Comment thread packages/api/src/public.ts Outdated
@basit3407 basit3407 force-pushed the codex/public-entrypoint-types branch from 7d76a97 to 61ef3d0 Compare May 18, 2026 11:52
@basit3407 basit3407 requested a review from Copilot May 18, 2026 12:00
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated no new comments.

@basit3407 basit3407 requested a review from osamasayed May 18, 2026 12:10
@osamasayed osamasayed merged commit 7e5f93a into main May 18, 2026
6 checks 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.

DX: /public entrypoint doesn't re-export UserSession / TokenStorage type literals

3 participants