@mastra/deployer 0.3.1-alpha.3 → 0.3.1-alpha.5
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/server/index.cjs +19 -6
- package/dist/server/index.js +19 -6
- package/package.json +4 -4
package/dist/server/index.cjs
CHANGED
|
@@ -865,33 +865,42 @@ function errorHandler(err, c2) {
|
|
|
865
865
|
|
|
866
866
|
// src/server/handlers/agents.ts
|
|
867
867
|
async function getAgentsHandler(c2) {
|
|
868
|
-
const serializedAgents = await agents.getAgentsHandler({
|
|
868
|
+
const serializedAgents = await agents.getAgentsHandler({
|
|
869
|
+
mastra: c2.get("mastra"),
|
|
870
|
+
runtimeContext: c2.get("runtimeContext")
|
|
871
|
+
});
|
|
869
872
|
return c2.json(serializedAgents);
|
|
870
873
|
}
|
|
871
874
|
async function getAgentByIdHandler(c2) {
|
|
872
875
|
const mastra = c2.get("mastra");
|
|
873
876
|
const agentId = c2.req.param("agentId");
|
|
877
|
+
const runtimeContext = c2.get("runtimeContext");
|
|
874
878
|
const result = await agents.getAgentByIdHandler({
|
|
875
879
|
mastra,
|
|
876
|
-
agentId
|
|
880
|
+
agentId,
|
|
881
|
+
runtimeContext
|
|
877
882
|
});
|
|
878
883
|
return c2.json(result);
|
|
879
884
|
}
|
|
880
885
|
async function getEvalsByAgentIdHandler(c2) {
|
|
881
886
|
const mastra = c2.get("mastra");
|
|
882
887
|
const agentId = c2.req.param("agentId");
|
|
888
|
+
const runtimeContext = c2.get("runtimeContext");
|
|
883
889
|
const result = await agents.getEvalsByAgentIdHandler({
|
|
884
890
|
mastra,
|
|
885
|
-
agentId
|
|
891
|
+
agentId,
|
|
892
|
+
runtimeContext
|
|
886
893
|
});
|
|
887
894
|
return c2.json(result);
|
|
888
895
|
}
|
|
889
896
|
async function getLiveEvalsByAgentIdHandler(c2) {
|
|
890
897
|
const mastra = c2.get("mastra");
|
|
891
898
|
const agentId = c2.req.param("agentId");
|
|
899
|
+
const runtimeContext = c2.get("runtimeContext");
|
|
892
900
|
const result = await agents.getLiveEvalsByAgentIdHandler({
|
|
893
901
|
mastra,
|
|
894
|
-
agentId
|
|
902
|
+
agentId,
|
|
903
|
+
runtimeContext
|
|
895
904
|
});
|
|
896
905
|
return c2.json(result);
|
|
897
906
|
}
|
|
@@ -1150,8 +1159,10 @@ async function getMessagesHandler(c2) {
|
|
|
1150
1159
|
async function getNetworksHandler(c2) {
|
|
1151
1160
|
try {
|
|
1152
1161
|
const mastra = c2.get("mastra");
|
|
1162
|
+
const runtimeContext = c2.get("runtimeContext");
|
|
1153
1163
|
const networks = await network.getNetworksHandler({
|
|
1154
|
-
mastra
|
|
1164
|
+
mastra,
|
|
1165
|
+
runtimeContext
|
|
1155
1166
|
});
|
|
1156
1167
|
return c2.json(networks);
|
|
1157
1168
|
} catch (error) {
|
|
@@ -1162,9 +1173,11 @@ async function getNetworkByIdHandler(c2) {
|
|
|
1162
1173
|
try {
|
|
1163
1174
|
const mastra = c2.get("mastra");
|
|
1164
1175
|
const networkId = c2.req.param("networkId");
|
|
1176
|
+
const runtimeContext = c2.get("runtimeContext");
|
|
1165
1177
|
const network$1 = await network.getNetworkByIdHandler({
|
|
1166
1178
|
mastra,
|
|
1167
|
-
networkId
|
|
1179
|
+
networkId,
|
|
1180
|
+
runtimeContext
|
|
1168
1181
|
});
|
|
1169
1182
|
return c2.json(network$1);
|
|
1170
1183
|
} catch (error) {
|
package/dist/server/index.js
CHANGED
|
@@ -859,33 +859,42 @@ function errorHandler(err, c2) {
|
|
|
859
859
|
|
|
860
860
|
// src/server/handlers/agents.ts
|
|
861
861
|
async function getAgentsHandler(c2) {
|
|
862
|
-
const serializedAgents = await getAgentsHandler$1({
|
|
862
|
+
const serializedAgents = await getAgentsHandler$1({
|
|
863
|
+
mastra: c2.get("mastra"),
|
|
864
|
+
runtimeContext: c2.get("runtimeContext")
|
|
865
|
+
});
|
|
863
866
|
return c2.json(serializedAgents);
|
|
864
867
|
}
|
|
865
868
|
async function getAgentByIdHandler(c2) {
|
|
866
869
|
const mastra = c2.get("mastra");
|
|
867
870
|
const agentId = c2.req.param("agentId");
|
|
871
|
+
const runtimeContext = c2.get("runtimeContext");
|
|
868
872
|
const result = await getAgentByIdHandler$1({
|
|
869
873
|
mastra,
|
|
870
|
-
agentId
|
|
874
|
+
agentId,
|
|
875
|
+
runtimeContext
|
|
871
876
|
});
|
|
872
877
|
return c2.json(result);
|
|
873
878
|
}
|
|
874
879
|
async function getEvalsByAgentIdHandler(c2) {
|
|
875
880
|
const mastra = c2.get("mastra");
|
|
876
881
|
const agentId = c2.req.param("agentId");
|
|
882
|
+
const runtimeContext = c2.get("runtimeContext");
|
|
877
883
|
const result = await getEvalsByAgentIdHandler$1({
|
|
878
884
|
mastra,
|
|
879
|
-
agentId
|
|
885
|
+
agentId,
|
|
886
|
+
runtimeContext
|
|
880
887
|
});
|
|
881
888
|
return c2.json(result);
|
|
882
889
|
}
|
|
883
890
|
async function getLiveEvalsByAgentIdHandler(c2) {
|
|
884
891
|
const mastra = c2.get("mastra");
|
|
885
892
|
const agentId = c2.req.param("agentId");
|
|
893
|
+
const runtimeContext = c2.get("runtimeContext");
|
|
886
894
|
const result = await getLiveEvalsByAgentIdHandler$1({
|
|
887
895
|
mastra,
|
|
888
|
-
agentId
|
|
896
|
+
agentId,
|
|
897
|
+
runtimeContext
|
|
889
898
|
});
|
|
890
899
|
return c2.json(result);
|
|
891
900
|
}
|
|
@@ -1144,8 +1153,10 @@ async function getMessagesHandler(c2) {
|
|
|
1144
1153
|
async function getNetworksHandler(c2) {
|
|
1145
1154
|
try {
|
|
1146
1155
|
const mastra = c2.get("mastra");
|
|
1156
|
+
const runtimeContext = c2.get("runtimeContext");
|
|
1147
1157
|
const networks = await getNetworksHandler$1({
|
|
1148
|
-
mastra
|
|
1158
|
+
mastra,
|
|
1159
|
+
runtimeContext
|
|
1149
1160
|
});
|
|
1150
1161
|
return c2.json(networks);
|
|
1151
1162
|
} catch (error) {
|
|
@@ -1156,9 +1167,11 @@ async function getNetworkByIdHandler(c2) {
|
|
|
1156
1167
|
try {
|
|
1157
1168
|
const mastra = c2.get("mastra");
|
|
1158
1169
|
const networkId = c2.req.param("networkId");
|
|
1170
|
+
const runtimeContext = c2.get("runtimeContext");
|
|
1159
1171
|
const network = await getNetworkByIdHandler$1({
|
|
1160
1172
|
mastra,
|
|
1161
|
-
networkId
|
|
1173
|
+
networkId,
|
|
1174
|
+
runtimeContext
|
|
1162
1175
|
});
|
|
1163
1176
|
return c2.json(network);
|
|
1164
1177
|
} catch (error) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mastra/deployer",
|
|
3
|
-
"version": "0.3.1-alpha.
|
|
3
|
+
"version": "0.3.1-alpha.5",
|
|
4
4
|
"description": "",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"files": [
|
|
@@ -107,13 +107,13 @@
|
|
|
107
107
|
"rollup-plugin-node-externals": "^8.0.0",
|
|
108
108
|
"typescript-paths": "^1.5.1",
|
|
109
109
|
"zod": "^3.24.2",
|
|
110
|
-
"@mastra/
|
|
111
|
-
"@mastra/
|
|
110
|
+
"@mastra/server": "^2.0.1-alpha.5",
|
|
111
|
+
"@mastra/core": "^0.9.1-alpha.5"
|
|
112
112
|
},
|
|
113
113
|
"devDependencies": {
|
|
114
114
|
"@hono/node-server": "^1.13.8",
|
|
115
115
|
"@hono/swagger-ui": "^0.5.1",
|
|
116
|
-
"@microsoft/api-extractor": "^7.52.
|
|
116
|
+
"@microsoft/api-extractor": "^7.52.5",
|
|
117
117
|
"@types/babel__core": "^7.20.5",
|
|
118
118
|
"@types/babel__helper-module-imports": "^7.18.3",
|
|
119
119
|
"@types/fs-extra": "^11.0.4",
|