@mastra/deployer 1.83.0-alpha.4 → 1.83.0-alpha.6
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/dist/docs/SKILL.md +1 -1
- package/dist/docs/assets/SOURCE_MAP.json +1 -1
- package/dist/server/index.cjs +4 -11
- package/dist/server/index.cjs.map +1 -1
- package/dist/server/index.d.ts +1 -1
- package/dist/server/index.js +4 -11
- package/dist/server/index.js.map +1 -1
- package/package.json +5 -5
- /package/dist/_types/{@mastra_hono@1.7.25-alpha.4 → @mastra_hono@1.7.25-alpha.6}/dist/auth-middleware.d.ts +0 -0
- /package/dist/_types/{@mastra_hono@1.7.25-alpha.4 → @mastra_hono@1.7.25-alpha.6}/dist/browser-stream/index.d.ts +0 -0
- /package/dist/_types/{@mastra_hono@1.7.25-alpha.4 → @mastra_hono@1.7.25-alpha.6}/dist/index.d.ts +0 -0
- /package/dist/_types/{@mastra_hono@1.7.25-alpha.4 → @mastra_hono@1.7.25-alpha.6}/package.json +0 -0
package/dist/server/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { Mastra } from '@mastra/core/mastra';
|
|
2
|
-
import type { HonoBindings, HonoVariables } from '../_types/@mastra_hono@1.7.25-alpha.
|
|
2
|
+
import type { HonoBindings, HonoVariables } from '../_types/@mastra_hono@1.7.25-alpha.6/dist/index.js';
|
|
3
3
|
import { Hono } from 'hono';
|
|
4
4
|
import type { ServerBundleOptions } from './types.js';
|
|
5
5
|
type Bindings = HonoBindings;
|
package/dist/server/index.js
CHANGED
|
@@ -4029,16 +4029,8 @@ var MastraServer$2 = class extends MastraServer {
|
|
|
4029
4029
|
const routes = await this.registerSchemaApiRoutes();
|
|
4030
4030
|
if (!await this.buildCustomRouteHandler(routes)) return;
|
|
4031
4031
|
for (const route of routes) {
|
|
4032
|
-
const serverRoute = {
|
|
4033
|
-
method: route.method,
|
|
4034
|
-
path: route.path,
|
|
4035
|
-
responseType: "json",
|
|
4036
|
-
handler: async () => {},
|
|
4037
|
-
requiresAuth: route.requiresAuth,
|
|
4038
|
-
requiresPermission: route.requiresPermission,
|
|
4039
|
-
fga: route.fga
|
|
4040
|
-
};
|
|
4041
4032
|
const routeHandler = async (c) => {
|
|
4033
|
+
const { match, serverRoute, customRouteAuthConfig } = this.resolveCustomRouteAuth(c.req.url, c.req.method, c.req.path, route);
|
|
4042
4034
|
const authError = await this.checkRouteAuth(serverRoute, {
|
|
4043
4035
|
path: c.req.path,
|
|
4044
4036
|
method: c.req.method,
|
|
@@ -4046,7 +4038,8 @@ var MastraServer$2 = class extends MastraServer {
|
|
|
4046
4038
|
getQuery: (name) => c.req.query(name),
|
|
4047
4039
|
requestContext: c.get("requestContext"),
|
|
4048
4040
|
request: c.req.raw,
|
|
4049
|
-
buildAuthorizeContext: () => c
|
|
4041
|
+
buildAuthorizeContext: () => c,
|
|
4042
|
+
customRouteAuthConfig
|
|
4050
4043
|
});
|
|
4051
4044
|
if (authError) {
|
|
4052
4045
|
if (authError.headers) for (const [key, value] of Object.entries(authError.headers)) c.header(key, value);
|
|
@@ -4083,7 +4076,7 @@ var MastraServer$2 = class extends MastraServer {
|
|
|
4083
4076
|
const fgaError = await checkRouteFGA(this.mastra, serverRoute, c.get("requestContext"), {
|
|
4084
4077
|
...Object.fromEntries(new URL(c.req.url).searchParams.entries()),
|
|
4085
4078
|
...bodyParams,
|
|
4086
|
-
...c.req.param()
|
|
4079
|
+
...match ? match.params : c.req.param()
|
|
4087
4080
|
});
|
|
4088
4081
|
if (fgaError) return c.json({
|
|
4089
4082
|
error: fgaError.error,
|