createSubject hook unblocks JWT-bearer connectors
@vercel/connect@0.2.5
2 featuresThis release2 featuresNew capabilitiesAI-tallied from the release notes
Patch Changes
- ed811f4: Update the optional AI SDK peer dependency range to accept the
ai@7.0.0beta line. - b1c1606: Add a context-aware
createSubjecthook toconnect()from@vercel/connect/eve. The newcreateSubject?: (principal, ctx) => ConnectTokenSubjectoption receives both the framework-resolved principal and Eve's per-connection authorization context (currently the declared serverurl), unblocking jwt-bearer-style connectors whose subject/assertion needs more than the principal — custom claims, the connection URL, or an audience derived from it. The adapter now threads theconnectioncontext Eve already passes togetToken/startAuthorization/completeAuthorization(previously dropped) into subject resolution, and the context type is exported asEveConnectionAuthorizationContext. Precedence iscreateSubject>principalToSubject> default principal mapping;principalToSubjectkeeps working but is now deprecated in favor ofcreateSubject.
Fetched June 17, 2026

