Add CI for vercel-node-connect-token (install, lint, test, build)#44
Merged
Conversation
CI workflow runs on pushes to master and PRs that touch examples/vercel-node-connect-token/** or the workflow itself. Steps: 1. pnpm install --frozen-lockfile - preinstall runs pnpm audit + pnpm audit signatures. 2. Lint / Test / Build all run `tsc --noEmit` over api/**. Plumbing added: - tsconfig.json (target ES2022, NodeNext, strict, isolatedModules, noEmit, includes api/**) - typescript 5.9.3 devDependency - typecheck / lint / test / build scripts (all -> tsc --noEmit) Source fix surfaced by the type check: - api/token.ts guards on PLUGGY_CLIENT_ID / PLUGGY_CLIENT_SECRET before constructing PluggyClient. Pluggy-sdk 0.7.1 types those as `string` (not `string | undefined`), so the previous version was a type error in strict mode and could ship undefined creds silently. Now returns 500 with a clear message when missing. Concurrency-cancel older runs on the same ref.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a GitHub Actions workflow that validates `examples/vercel-node-connect-token` on every push to master and every PR touching its files. Same shape as #41 (`aws-sst`), #42 (`frontend/nextjs`), and #43 (`vercel-quickdeploy-nextjs`).
Workflow
`.github/workflows/vercel-connect-token-ci.yml` — path-filtered, concurrency-cancelled. Steps:
This is a serverless-function project, not a Next.js app — there is no separate framework build step, so all three CI checks are TypeScript compile checks.
Plumbing changes
`examples/vercel-node-connect-token/`:
Source fix surfaced by the type check
`api/token.ts` previously passed `process.env.PLUGGY_CLIENT_ID` and `PLUGGY_CLIENT_SECRET` (each `string | undefined`) directly to `new PluggyClient({...})`, whose typings require `string`. In strict mode this is a type error, and at runtime it would have silently constructed a client with `undefined` credentials.
Now the handler guards both env vars and returns a 500 with a clear message when either is missing.
Verification