@opensaas/stack-auth 0.28.0 → 0.30.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.turbo/turbo-build.log +1 -1
- package/CHANGELOG.md +10 -0
- package/README.md +1 -1
- package/dist/mcp/better-auth.d.ts +2 -3
- package/dist/mcp/better-auth.d.ts.map +1 -1
- package/dist/mcp/better-auth.js +2 -3
- package/dist/mcp/better-auth.js.map +1 -1
- package/package.json +2 -2
- package/src/mcp/better-auth.ts +2 -3
- package/tsconfig.tsbuildinfo +1 -1
package/.turbo/turbo-build.log
CHANGED
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,15 @@
|
|
|
1
1
|
# @opensaas/stack-auth
|
|
2
2
|
|
|
3
|
+
## 0.30.0
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#741](https://github.com/OpenSaasAU/stack/pull/741) [`afa865f`](https://github.com/OpenSaasAU/stack/commit/afa865f62ed7968b494a87e0621cf71bacd36f39) Thanks [@borisno2](https://github.com/borisno2)! - Update documentation links to the restructured docs site URLs (Diátaxis layout)
|
|
8
|
+
|
|
9
|
+
- [#744](https://github.com/OpenSaasAU/stack/pull/744) [`5e135ef`](https://github.com/OpenSaasAU/stack/commit/5e135ef635dd7cd97ab106f46fbf808250aa079e) Thanks [@borisno2](https://github.com/borisno2)! - Fix stale `withMcpAuth` JSDoc example that imported a nonexistent generated module
|
|
10
|
+
|
|
11
|
+
## 0.29.0
|
|
12
|
+
|
|
3
13
|
## 0.28.0
|
|
4
14
|
|
|
5
15
|
### Minor Changes
|
package/README.md
CHANGED
|
@@ -233,7 +233,7 @@ better-auth user, e.g. `AuthUser`). It does not assume that list is your app's
|
|
|
233
233
|
own domain `User` — when the keys differ, your `User` is never extended or
|
|
234
234
|
overwritten. **Linking your domain `User` to the Auth identity is your app's
|
|
235
235
|
concern** (declare a `relationship({ ref: 'AuthUser' })` on your `User`). See the
|
|
236
|
-
[Authentication guide](https://stack.opensaas.au/docs/
|
|
236
|
+
[Authentication guide](https://stack.opensaas.au/docs/how-to/authentication) for
|
|
237
237
|
the full migrator walkthrough and a Schema-parity (clean-diff) check.
|
|
238
238
|
|
|
239
239
|
## UI Components
|
|
@@ -41,11 +41,10 @@ export declare function createBetterAuthMcpAdapter(auth: BetterAuthInstance): Mc
|
|
|
41
41
|
* ```typescript
|
|
42
42
|
* import { withMcpAuth } from '@opensaas/stack-auth/mcp'
|
|
43
43
|
* import { auth } from '@/lib/auth'
|
|
44
|
-
* import { createMcpServer } from '@/.opensaas/mcp/server'
|
|
45
44
|
*
|
|
46
45
|
* const handler = withMcpAuth(auth, async (req, session) => {
|
|
47
|
-
*
|
|
48
|
-
* return
|
|
46
|
+
* // session.userId is authenticated — handle the MCP request
|
|
47
|
+
* return new Response(JSON.stringify({ ok: true }))
|
|
49
48
|
* })
|
|
50
49
|
*
|
|
51
50
|
* export { handler as GET, handler as POST, handler as DELETE }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"better-auth.d.ts","sourceRoot":"","sources":["../../src/mcp/better-auth.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAA;AAE9E;;;GAGG;AACH,MAAM,MAAM,kBAAkB,GAAG;IAE/B,GAAG,EAAE,GAAG,CAAA;IAER,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;CACnB,CAAA;AAED;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,wBAAgB,0BAA0B,CAAC,IAAI,EAAE,kBAAkB,GAAG,kBAAkB,CAIvF;AAED
|
|
1
|
+
{"version":3,"file":"better-auth.d.ts","sourceRoot":"","sources":["../../src/mcp/better-auth.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAA;AAE9E;;;GAGG;AACH,MAAM,MAAM,kBAAkB,GAAG;IAE/B,GAAG,EAAE,GAAG,CAAA;IAER,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;CACnB,CAAA;AAED;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,wBAAgB,0BAA0B,CAAC,IAAI,EAAE,kBAAkB,GAAG,kBAAkB,CAIvF;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,WAAW,CACzB,IAAI,EAAE,kBAAkB,EACxB,OAAO,EAAE,CAAC,GAAG,EAAE,OAAO,EAAE,OAAO,EAAE,UAAU,KAAK,OAAO,CAAC,QAAQ,CAAC,GAAG,QAAQ,GAC3E,CAAC,GAAG,EAAE,OAAO,KAAK,OAAO,CAAC,QAAQ,CAAC,CAoBrC;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,0BAA0B,CAAC,UAAU,EAAE,UAAU,GAAG;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE,CAIrF;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,SAAS,CAAC,OAAO,EAAE,UAAU,EAAE,cAAc,EAAE,MAAM,EAAE,GAAG,OAAO,CAGhF;AAED;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,OAAO,EAAE,UAAU,GAAG,OAAO,CAG7D;AAED;;;;;;;GAOG;AACH,wBAAgB,2BAA2B,CAAC,KAAK,EAAE,kBAAkB,SAChD,OAAO,uBAS3B;AAED;;;;;GAKG;AACH,wBAAgB,mCAAmC,CAAC,KAAK,EAAE,kBAAkB,SACxD,OAAO,uBAS3B"}
|
package/dist/mcp/better-auth.js
CHANGED
|
@@ -36,11 +36,10 @@ export function createBetterAuthMcpAdapter(auth) {
|
|
|
36
36
|
* ```typescript
|
|
37
37
|
* import { withMcpAuth } from '@opensaas/stack-auth/mcp'
|
|
38
38
|
* import { auth } from '@/lib/auth'
|
|
39
|
-
* import { createMcpServer } from '@/.opensaas/mcp/server'
|
|
40
39
|
*
|
|
41
40
|
* const handler = withMcpAuth(auth, async (req, session) => {
|
|
42
|
-
*
|
|
43
|
-
* return
|
|
41
|
+
* // session.userId is authenticated — handle the MCP request
|
|
42
|
+
* return new Response(JSON.stringify({ ok: true }))
|
|
44
43
|
* })
|
|
45
44
|
*
|
|
46
45
|
* export { handler as GET, handler as POST, handler as DELETE }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"better-auth.js","sourceRoot":"","sources":["../../src/mcp/better-auth.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAeH;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,MAAM,UAAU,0BAA0B,CAAC,IAAwB;IACjE,OAAO,KAAK,EAAE,OAAgB,EAA8B,EAAE;QAC5D,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,aAAa,CAAC,EAAE,OAAO,EAAE,CAAC,CAAA;IAClD,CAAC,CAAA;AACH,CAAC;AAED
|
|
1
|
+
{"version":3,"file":"better-auth.js","sourceRoot":"","sources":["../../src/mcp/better-auth.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAeH;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,MAAM,UAAU,0BAA0B,CAAC,IAAwB;IACjE,OAAO,KAAK,EAAE,OAAgB,EAA8B,EAAE;QAC5D,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,aAAa,CAAC,EAAE,OAAO,EAAE,CAAC,CAAA;IAClD,CAAC,CAAA;AACH,CAAC;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,UAAU,WAAW,CACzB,IAAwB,EACxB,OAA4E;IAE5E,OAAO,KAAK,EAAE,GAAY,EAAE,EAAE;QAC5B,uCAAuC;QACvC,MAAM,OAAO,GAAG,MAAM,IAAI,CAAC,GAAG,CAAC,aAAa,CAAC;YAC3C,OAAO,EAAE,GAAG,CAAC,OAAO;SACrB,CAAC,CAAA;QAEF,IAAI,CAAC,OAAO,EAAE,CAAC;YACb,4DAA4D;YAC5D,OAAO,IAAI,QAAQ,CAAC,IAAI,EA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IAC3E,OAAO,KAAK,EAAE,GAAY,EAAE,EAAE;QAC5B,6CAA6C;QAC7C,MAAM,QAAQ,GAAG,gDAAgD,CAAA;QACjE,MAAM,OAAO,GAAG,IAAI,GAAG,CAAC,QAAQ,EAAE,GAAG,CAAC,GAAG,CAAC,CAAA;QAE1C,OAAO,KAAK,CAAC,OAAO,CAAC,QAAQ,EAAE,EAAE;YAC/B,OAAO,EAAE,GAAG,CAAC,OAAO;SACrB,CAAC,CAAA;IACJ,CAAC,CAAA;AACH,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@opensaas/stack-auth",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.30.0",
|
|
4
4
|
"description": "Better-auth integration for OpenSaas Stack",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -65,7 +65,7 @@
|
|
|
65
65
|
"react": "^19.2.4",
|
|
66
66
|
"typescript": "npm:@typescript/typescript6@^6.0.2",
|
|
67
67
|
"vitest": "^4.1.10",
|
|
68
|
-
"@opensaas/stack-core": "0.
|
|
68
|
+
"@opensaas/stack-core": "0.30.0"
|
|
69
69
|
},
|
|
70
70
|
"scripts": {
|
|
71
71
|
"build": "tsc",
|
package/src/mcp/better-auth.ts
CHANGED
|
@@ -51,11 +51,10 @@ export function createBetterAuthMcpAdapter(auth: BetterAuthInstance): McpSession
|
|
|
51
51
|
* ```typescript
|
|
52
52
|
* import { withMcpAuth } from '@opensaas/stack-auth/mcp'
|
|
53
53
|
* import { auth } from '@/lib/auth'
|
|
54
|
-
* import { createMcpServer } from '@/.opensaas/mcp/server'
|
|
55
54
|
*
|
|
56
55
|
* const handler = withMcpAuth(auth, async (req, session) => {
|
|
57
|
-
*
|
|
58
|
-
* return
|
|
56
|
+
* // session.userId is authenticated — handle the MCP request
|
|
57
|
+
* return new Response(JSON.stringify({ ok: true }))
|
|
59
58
|
* })
|
|
60
59
|
*
|
|
61
60
|
* export { handler as GET, handler as POST, handler as DELETE }
|