@mastra/server 1.47.0-alpha.5 → 1.47.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/CHANGELOG.md +31 -0
- package/dist/_types/@mastra_schema-compat/dist/schema.types.d.ts +4 -1
- package/dist/{api-schema-manifest-OQOZ53HZ.js → api-schema-manifest-LT57YVGI.js} +3 -3
- package/dist/{api-schema-manifest-OQOZ53HZ.js.map → api-schema-manifest-LT57YVGI.js.map} +1 -1
- package/dist/{api-schema-manifest-SYCCXMOC.cjs → api-schema-manifest-SJMFHZHR.cjs} +4 -4
- package/dist/{api-schema-manifest-SYCCXMOC.cjs.map → api-schema-manifest-SJMFHZHR.cjs.map} +1 -1
- package/dist/{chunk-XOQEKMY2.cjs → chunk-2NGSYVI3.cjs} +34 -34
- package/dist/{chunk-XOQEKMY2.cjs.map → chunk-2NGSYVI3.cjs.map} +1 -1
- package/dist/{chunk-S2HKHYJ3.cjs → chunk-2R52ZPSI.cjs} +9 -9
- package/dist/{chunk-S2HKHYJ3.cjs.map → chunk-2R52ZPSI.cjs.map} +1 -1
- package/dist/{chunk-ZZOHO2FT.js → chunk-34WNPIGV.js} +5 -5
- package/dist/{chunk-ZZOHO2FT.js.map → chunk-34WNPIGV.js.map} +1 -1
- package/dist/{chunk-UZ43QCIA.cjs → chunk-3KBURDTO.cjs} +12 -12
- package/dist/{chunk-UZ43QCIA.cjs.map → chunk-3KBURDTO.cjs.map} +1 -1
- package/dist/{chunk-RVD3DGBZ.cjs → chunk-42M6Y2OD.cjs} +3 -3
- package/dist/{chunk-RVD3DGBZ.cjs.map → chunk-42M6Y2OD.cjs.map} +1 -1
- package/dist/{chunk-Q7EQLQS5.js → chunk-43T7OG7P.js} +16 -9
- package/dist/chunk-43T7OG7P.js.map +1 -0
- package/dist/{chunk-5V2QWK2S.js → chunk-4E7VGBSM.js} +5 -5
- package/dist/{chunk-5V2QWK2S.js.map → chunk-4E7VGBSM.js.map} +1 -1
- package/dist/{chunk-PLWZVSGT.js → chunk-4UZTUQYZ.js} +5 -5
- package/dist/{chunk-PLWZVSGT.js.map → chunk-4UZTUQYZ.js.map} +1 -1
- package/dist/{chunk-V23ANIEC.cjs → chunk-4WRZ6BK4.cjs} +4 -4
- package/dist/{chunk-V23ANIEC.cjs.map → chunk-4WRZ6BK4.cjs.map} +1 -1
- package/dist/{chunk-VRERZRJQ.js → chunk-4ZD4KLXD.js} +4 -4
- package/dist/{chunk-VRERZRJQ.js.map → chunk-4ZD4KLXD.js.map} +1 -1
- package/dist/{chunk-K3FM6RLZ.cjs → chunk-5JVILML3.cjs} +9 -9
- package/dist/{chunk-K3FM6RLZ.cjs.map → chunk-5JVILML3.cjs.map} +1 -1
- package/dist/{chunk-7FIDKZUG.cjs → chunk-6CUVVNHE.cjs} +6 -6
- package/dist/{chunk-7FIDKZUG.cjs.map → chunk-6CUVVNHE.cjs.map} +1 -1
- package/dist/{chunk-QQCQV7ZF.cjs → chunk-7GNT5KQE.cjs} +3 -2
- package/dist/chunk-7GNT5KQE.cjs.map +1 -0
- package/dist/{chunk-4ZHHKMDQ.cjs → chunk-AC4YST2M.cjs} +3 -3
- package/dist/{chunk-4ZHHKMDQ.cjs.map → chunk-AC4YST2M.cjs.map} +1 -1
- package/dist/{chunk-R4O5HVDI.js → chunk-AGWL3ZLU.js} +3 -3
- package/dist/{chunk-R4O5HVDI.js.map → chunk-AGWL3ZLU.js.map} +1 -1
- package/dist/{chunk-C2A2BZFY.js → chunk-AMWGBQZU.js} +4 -4
- package/dist/{chunk-C2A2BZFY.js.map → chunk-AMWGBQZU.js.map} +1 -1
- package/dist/{chunk-TPZFGGU4.cjs → chunk-CCUQDEQW.cjs} +283 -283
- package/dist/chunk-CCUQDEQW.cjs.map +1 -0
- package/dist/{chunk-E2JNW3QM.js → chunk-D6RO4IFO.js} +3 -3
- package/dist/{chunk-E2JNW3QM.js.map → chunk-D6RO4IFO.js.map} +1 -1
- package/dist/{chunk-DULEYONH.cjs → chunk-D7YMTEPI.cjs} +13 -13
- package/dist/{chunk-DULEYONH.cjs.map → chunk-D7YMTEPI.cjs.map} +1 -1
- package/dist/{chunk-2Z3TLC4L.js → chunk-DSHITLJ4.js} +4 -4
- package/dist/{chunk-2Z3TLC4L.js.map → chunk-DSHITLJ4.js.map} +1 -1
- package/dist/{chunk-SJPWXUKZ.js → chunk-DVCCSRFP.js} +3 -3
- package/dist/{chunk-SJPWXUKZ.js.map → chunk-DVCCSRFP.js.map} +1 -1
- package/dist/{chunk-Y3MYKCTO.cjs → chunk-EBUK5R3S.cjs} +13 -13
- package/dist/{chunk-Y3MYKCTO.cjs.map → chunk-EBUK5R3S.cjs.map} +1 -1
- package/dist/{chunk-JY2LHUT4.cjs → chunk-EKRIVYU4.cjs} +22 -22
- package/dist/{chunk-JY2LHUT4.cjs.map → chunk-EKRIVYU4.cjs.map} +1 -1
- package/dist/{chunk-IBUJJIRW.js → chunk-EOGTJIPF.js} +3 -3
- package/dist/{chunk-IBUJJIRW.js.map → chunk-EOGTJIPF.js.map} +1 -1
- package/dist/{chunk-ONBABU5V.cjs → chunk-EYCW4Z4H.cjs} +10 -10
- package/dist/{chunk-ONBABU5V.cjs.map → chunk-EYCW4Z4H.cjs.map} +1 -1
- package/dist/{chunk-GU4AEOGA.cjs → chunk-F6VL25IA.cjs} +7 -7
- package/dist/{chunk-GU4AEOGA.cjs.map → chunk-F6VL25IA.cjs.map} +1 -1
- package/dist/{chunk-JZJ3PP2H.cjs → chunk-GOD4LLZT.cjs} +10 -10
- package/dist/{chunk-JZJ3PP2H.cjs.map → chunk-GOD4LLZT.cjs.map} +1 -1
- package/dist/{chunk-NEPOKWAA.js → chunk-GQI4NKKD.js} +5 -5
- package/dist/{chunk-NEPOKWAA.js.map → chunk-GQI4NKKD.js.map} +1 -1
- package/dist/{chunk-KGUHJRHZ.cjs → chunk-HDIYJI2Z.cjs} +3 -3
- package/dist/{chunk-KGUHJRHZ.cjs.map → chunk-HDIYJI2Z.cjs.map} +1 -1
- package/dist/{chunk-TPGA2ZTS.js → chunk-IEONDWGQ.js} +4 -4
- package/dist/{chunk-TPGA2ZTS.js.map → chunk-IEONDWGQ.js.map} +1 -1
- package/dist/{chunk-6HRGFBAF.cjs → chunk-IY4MNGI3.cjs} +63 -63
- package/dist/{chunk-6HRGFBAF.cjs.map → chunk-IY4MNGI3.cjs.map} +1 -1
- package/dist/{chunk-3ENQND57.js → chunk-JBSUT5XF.js} +3 -3
- package/dist/{chunk-3ENQND57.js.map → chunk-JBSUT5XF.js.map} +1 -1
- package/dist/{chunk-VNWPOCOT.cjs → chunk-JJDLXVWR.cjs} +19 -19
- package/dist/{chunk-VNWPOCOT.cjs.map → chunk-JJDLXVWR.cjs.map} +1 -1
- package/dist/{chunk-F5EEKLC4.js → chunk-KA6FUBC5.js} +6 -6
- package/dist/{chunk-F5EEKLC4.js.map → chunk-KA6FUBC5.js.map} +1 -1
- package/dist/{chunk-E345K7K7.js → chunk-KGJGR6GO.js} +5 -5
- package/dist/{chunk-E345K7K7.js.map → chunk-KGJGR6GO.js.map} +1 -1
- package/dist/{chunk-YLWKZ3VK.cjs → chunk-KIDHIRVO.cjs} +7 -7
- package/dist/{chunk-YLWKZ3VK.cjs.map → chunk-KIDHIRVO.cjs.map} +1 -1
- package/dist/{chunk-T32FQPWH.cjs → chunk-KR7FUFVK.cjs} +10 -10
- package/dist/{chunk-T32FQPWH.cjs.map → chunk-KR7FUFVK.cjs.map} +1 -1
- package/dist/{chunk-RY5RETAD.js → chunk-L4DD3HSB.js} +3 -3
- package/dist/{chunk-RY5RETAD.js.map → chunk-L4DD3HSB.js.map} +1 -1
- package/dist/{chunk-BB6RVOJY.js → chunk-LA4AQGZA.js} +3 -3
- package/dist/{chunk-BB6RVOJY.js.map → chunk-LA4AQGZA.js.map} +1 -1
- package/dist/{chunk-MMY24AC4.js → chunk-LUPNAVPL.js} +3 -3
- package/dist/{chunk-MMY24AC4.js.map → chunk-LUPNAVPL.js.map} +1 -1
- package/dist/{chunk-PSC3HAPW.cjs → chunk-MM7ONP57.cjs} +59 -59
- package/dist/{chunk-PSC3HAPW.cjs.map → chunk-MM7ONP57.cjs.map} +1 -1
- package/dist/{chunk-CIWN2JM4.js → chunk-MX3JQ3ZU.js} +3 -3
- package/dist/{chunk-CIWN2JM4.js.map → chunk-MX3JQ3ZU.js.map} +1 -1
- package/dist/{chunk-M5DAKMVZ.cjs → chunk-OE3KATAT.cjs} +4 -4
- package/dist/{chunk-M5DAKMVZ.cjs.map → chunk-OE3KATAT.cjs.map} +1 -1
- package/dist/{chunk-OT2JWWCT.cjs → chunk-OU4L45LL.cjs} +8 -8
- package/dist/{chunk-OT2JWWCT.cjs.map → chunk-OU4L45LL.cjs.map} +1 -1
- package/dist/{chunk-IRJJ2JJG.cjs → chunk-OZ64QWKA.cjs} +12 -12
- package/dist/{chunk-IRJJ2JJG.cjs.map → chunk-OZ64QWKA.cjs.map} +1 -1
- package/dist/{chunk-PUW3RA3B.js → chunk-P6TSZJ4I.js} +4 -4
- package/dist/{chunk-PUW3RA3B.js.map → chunk-P6TSZJ4I.js.map} +1 -1
- package/dist/{chunk-M25LVAUH.js → chunk-P7HCBIOK.js} +4 -4
- package/dist/{chunk-M25LVAUH.js.map → chunk-P7HCBIOK.js.map} +1 -1
- package/dist/{chunk-3ZV6GYQI.cjs → chunk-PVZX6FFO.cjs} +16 -9
- package/dist/chunk-PVZX6FFO.cjs.map +1 -0
- package/dist/{chunk-UXO4GWPT.js → chunk-Q6TDIK2A.js} +6 -6
- package/dist/{chunk-UXO4GWPT.js.map → chunk-Q6TDIK2A.js.map} +1 -1
- package/dist/{chunk-4BJSE3LM.js → chunk-QECRXNAM.js} +3 -3
- package/dist/{chunk-4BJSE3LM.js.map → chunk-QECRXNAM.js.map} +1 -1
- package/dist/{chunk-RM4ITWAQ.cjs → chunk-QRTZCP42.cjs} +10 -10
- package/dist/{chunk-RM4ITWAQ.cjs.map → chunk-QRTZCP42.cjs.map} +1 -1
- package/dist/{chunk-KBOC52HT.js → chunk-RETWAY24.js} +3 -3
- package/dist/{chunk-KBOC52HT.js.map → chunk-RETWAY24.js.map} +1 -1
- package/dist/{chunk-3WE5YAL5.js → chunk-RLAOC73C.js} +330 -327
- package/dist/chunk-RLAOC73C.js.map +1 -0
- package/dist/{chunk-MLLGO6XZ.js → chunk-S57DVRYK.js} +3 -3
- package/dist/{chunk-MLLGO6XZ.js.map → chunk-S57DVRYK.js.map} +1 -1
- package/dist/{chunk-XQ5INMFW.js → chunk-SK2BQPVT.js} +5 -5
- package/dist/{chunk-XQ5INMFW.js.map → chunk-SK2BQPVT.js.map} +1 -1
- package/dist/{chunk-7DKSWNOM.cjs → chunk-SOQPH6H2.cjs} +182 -182
- package/dist/{chunk-7DKSWNOM.cjs.map → chunk-SOQPH6H2.cjs.map} +1 -1
- package/dist/{chunk-56AYHXOU.js → chunk-SXZS6VZ3.js} +3 -3
- package/dist/{chunk-56AYHXOU.js.map → chunk-SXZS6VZ3.js.map} +1 -1
- package/dist/{chunk-OHWAEEZJ.js → chunk-UACKERCG.js} +3 -3
- package/dist/{chunk-OHWAEEZJ.js.map → chunk-UACKERCG.js.map} +1 -1
- package/dist/{chunk-4LQSGGSH.cjs → chunk-UGI45E76.cjs} +363 -360
- package/dist/chunk-UGI45E76.cjs.map +1 -0
- package/dist/{chunk-DEK4ZGUR.cjs → chunk-UQWJQWSK.cjs} +15 -15
- package/dist/{chunk-DEK4ZGUR.cjs.map → chunk-UQWJQWSK.cjs.map} +1 -1
- package/dist/{chunk-46Y4Y2RB.js → chunk-VEKFI5QZ.js} +3 -3
- package/dist/{chunk-46Y4Y2RB.js.map → chunk-VEKFI5QZ.js.map} +1 -1
- package/dist/{chunk-4JILES3G.js → chunk-VJYMPHQQ.js} +3 -2
- package/dist/chunk-VJYMPHQQ.js.map +1 -0
- package/dist/{chunk-C4U5EL4H.js → chunk-VQQSMW6M.js} +7 -7
- package/dist/{chunk-C4U5EL4H.js.map → chunk-VQQSMW6M.js.map} +1 -1
- package/dist/{chunk-BTMYAVRX.cjs → chunk-WUT3UHD6.cjs} +12 -12
- package/dist/{chunk-BTMYAVRX.cjs.map → chunk-WUT3UHD6.cjs.map} +1 -1
- package/dist/{chunk-HZWJL5Y4.js → chunk-XILM7MA7.js} +4 -4
- package/dist/{chunk-HZWJL5Y4.js.map → chunk-XILM7MA7.js.map} +1 -1
- package/dist/{chunk-73MURMD2.cjs → chunk-XLSJQAEP.cjs} +6 -6
- package/dist/{chunk-73MURMD2.cjs.map → chunk-XLSJQAEP.cjs.map} +1 -1
- package/dist/{chunk-WKSF3TVK.js → chunk-XRE4KFIZ.js} +7 -7
- package/dist/{chunk-WKSF3TVK.js.map → chunk-XRE4KFIZ.js.map} +1 -1
- package/dist/{chunk-TCWIDHH6.cjs → chunk-XTRPN52A.cjs} +3 -3
- package/dist/{chunk-TCWIDHH6.cjs.map → chunk-XTRPN52A.cjs.map} +1 -1
- package/dist/{chunk-UD7JBYUI.cjs → chunk-YIBM2OYI.cjs} +38 -38
- package/dist/{chunk-UD7JBYUI.cjs.map → chunk-YIBM2OYI.cjs.map} +1 -1
- package/dist/{chunk-UITLSJUW.cjs → chunk-YOHMEY6Q.cjs} +24 -24
- package/dist/{chunk-UITLSJUW.cjs.map → chunk-YOHMEY6Q.cjs.map} +1 -1
- package/dist/{chunk-56TEDJND.js → chunk-YUQSGB5C.js} +3 -3
- package/dist/{chunk-56TEDJND.js.map → chunk-YUQSGB5C.js.map} +1 -1
- package/dist/{chunk-GZ4HWZWE.cjs → chunk-YWUVDFQZ.cjs} +3 -3
- package/dist/{chunk-GZ4HWZWE.cjs.map → chunk-YWUVDFQZ.cjs.map} +1 -1
- package/dist/{chunk-EQ7LRJEB.cjs → chunk-Z6YXO2T6.cjs} +48 -48
- package/dist/{chunk-EQ7LRJEB.cjs.map → chunk-Z6YXO2T6.cjs.map} +1 -1
- package/dist/{chunk-TS5QYSEZ.js → chunk-Z7C226TD.js} +6 -6
- package/dist/{chunk-TS5QYSEZ.js.map → chunk-Z7C226TD.js.map} +1 -1
- package/dist/{chunk-M43CP74T.js → chunk-ZQSX425Q.js} +70 -70
- package/dist/chunk-ZQSX425Q.js.map +1 -0
- package/dist/{chunk-BTIK5TXF.cjs → chunk-ZVZBZOBY.cjs} +8 -8
- package/dist/{chunk-BTIK5TXF.cjs.map → chunk-ZVZBZOBY.cjs.map} +1 -1
- package/dist/{dist-OWZWIJZY.js → dist-EWY5C2JK.js} +5 -5
- package/dist/{dist-OWZWIJZY.js.map → dist-EWY5C2JK.js.map} +1 -1
- package/dist/{dist-TXDLPF66.cjs → dist-VNWFQ5X6.cjs} +20 -20
- package/dist/{dist-TXDLPF66.cjs.map → dist-VNWFQ5X6.cjs.map} +1 -1
- package/dist/docs/SKILL.md +1 -1
- package/dist/docs/assets/SOURCE_MAP.json +1 -1
- package/dist/{observational-memory-Y5T2OR2Y-XDEBXWNA.cjs → observational-memory-NC6DQQWD-JNRVNM7E.cjs} +26 -26
- package/dist/{observational-memory-Y5T2OR2Y-XDEBXWNA.cjs.map → observational-memory-NC6DQQWD-JNRVNM7E.cjs.map} +1 -1
- package/dist/{observational-memory-Y5T2OR2Y-QDHR4QEU.js → observational-memory-NC6DQQWD-WWE3XZFF.js} +3 -3
- package/dist/{observational-memory-Y5T2OR2Y-QDHR4QEU.js.map → observational-memory-NC6DQQWD-WWE3XZFF.js.map} +1 -1
- package/dist/server/handlers/a2a.cjs +14 -14
- package/dist/server/handlers/a2a.js +1 -1
- package/dist/server/handlers/agent-builder.cjs +17 -17
- package/dist/server/handlers/agent-builder.js +1 -1
- package/dist/server/handlers/agent-controller.cjs +144 -0
- package/dist/server/handlers/agent-controller.cjs.map +1 -0
- package/dist/server/handlers/{harness.d.ts → agent-controller.d.ts} +141 -141
- package/dist/server/handlers/agent-controller.d.ts.map +1 -0
- package/dist/server/handlers/agent-controller.js +3 -0
- package/dist/server/handlers/agent-controller.js.map +1 -0
- package/dist/server/handlers/agent-versions.cjs +8 -8
- package/dist/server/handlers/agent-versions.js +1 -1
- package/dist/server/handlers/agents.cjs +46 -46
- package/dist/server/handlers/agents.d.ts +2 -0
- package/dist/server/handlers/agents.d.ts.map +1 -1
- package/dist/server/handlers/agents.js +1 -1
- package/dist/server/handlers/auth.cjs +13 -13
- package/dist/server/handlers/auth.js +1 -1
- package/dist/server/handlers/authorship.cjs +12 -12
- package/dist/server/handlers/authorship.js +1 -1
- package/dist/server/handlers/builder-registry.cjs +6 -6
- package/dist/server/handlers/builder-registry.js +1 -1
- package/dist/server/handlers/channels.cjs +5 -5
- package/dist/server/handlers/channels.js +1 -1
- package/dist/server/handlers/conversations.cjs +5 -5
- package/dist/server/handlers/conversations.js +1 -1
- package/dist/server/handlers/editor-builder.cjs +6 -6
- package/dist/server/handlers/editor-builder.js +1 -1
- package/dist/server/handlers/favorites-enrichment.cjs +4 -4
- package/dist/server/handlers/favorites-enrichment.js +1 -1
- package/dist/server/handlers/logs.cjs +4 -4
- package/dist/server/handlers/logs.js +1 -1
- package/dist/server/handlers/mcp-client-versions.cjs +8 -8
- package/dist/server/handlers/mcp-client-versions.js +1 -1
- package/dist/server/handlers/memory.cjs +27 -27
- package/dist/server/handlers/memory.js +1 -1
- package/dist/server/handlers/prompt-block-versions.cjs +8 -8
- package/dist/server/handlers/prompt-block-versions.js +1 -1
- package/dist/server/handlers/responses.cjs +4 -4
- package/dist/server/handlers/responses.js +1 -1
- package/dist/server/handlers/responses.storage.cjs +8 -8
- package/dist/server/handlers/responses.storage.js +1 -1
- package/dist/server/handlers/scorer-versions.cjs +8 -8
- package/dist/server/handlers/scorer-versions.js +1 -1
- package/dist/server/handlers/scores.cjs +7 -7
- package/dist/server/handlers/scores.js +1 -1
- package/dist/server/handlers/stored-agent-favorites.cjs +3 -3
- package/dist/server/handlers/stored-agent-favorites.js +1 -1
- package/dist/server/handlers/stored-agents.cjs +10 -10
- package/dist/server/handlers/stored-agents.js +1 -1
- package/dist/server/handlers/stored-mcp-clients.cjs +6 -6
- package/dist/server/handlers/stored-mcp-clients.js +1 -1
- package/dist/server/handlers/stored-prompt-blocks.cjs +6 -6
- package/dist/server/handlers/stored-prompt-blocks.js +1 -1
- package/dist/server/handlers/stored-scorers.cjs +6 -6
- package/dist/server/handlers/stored-scorers.js +1 -1
- package/dist/server/handlers/stored-skill-favorites.cjs +3 -3
- package/dist/server/handlers/stored-skill-favorites.js +1 -1
- package/dist/server/handlers/stored-skills.cjs +7 -7
- package/dist/server/handlers/stored-skills.js +1 -1
- package/dist/server/handlers/stored-workspaces.cjs +6 -6
- package/dist/server/handlers/stored-workspaces.js +1 -1
- package/dist/server/handlers/system.cjs +3 -3
- package/dist/server/handlers/system.js +1 -1
- package/dist/server/handlers/tool-providers.cjs +14 -14
- package/dist/server/handlers/tool-providers.js +1 -1
- package/dist/server/handlers/tools.cjs +6 -6
- package/dist/server/handlers/tools.js +1 -1
- package/dist/server/handlers/utils.cjs +10 -10
- package/dist/server/handlers/utils.js +1 -1
- package/dist/server/handlers/workflows.cjs +27 -27
- package/dist/server/handlers/workflows.js +1 -1
- package/dist/server/handlers.cjs +22 -22
- package/dist/server/handlers.js +10 -10
- package/dist/server/schemas/agents.d.ts +1 -0
- package/dist/server/schemas/agents.d.ts.map +1 -1
- package/dist/server/schemas/index.cjs +536 -536
- package/dist/server/schemas/index.js +9 -9
- package/dist/server/server-adapter/index.cjs +42 -42
- package/dist/server/server-adapter/index.js +6 -6
- package/dist/server/server-adapter/routes/agent-controller.d.ts +6 -0
- package/dist/server/server-adapter/routes/agent-controller.d.ts.map +1 -0
- package/dist/server/server-adapter/routes/index.d.ts.map +1 -1
- package/package.json +7 -7
- package/dist/chunk-3WE5YAL5.js.map +0 -1
- package/dist/chunk-3ZV6GYQI.cjs.map +0 -1
- package/dist/chunk-4JILES3G.js.map +0 -1
- package/dist/chunk-4LQSGGSH.cjs.map +0 -1
- package/dist/chunk-M43CP74T.js.map +0 -1
- package/dist/chunk-Q7EQLQS5.js.map +0 -1
- package/dist/chunk-QQCQV7ZF.cjs.map +0 -1
- package/dist/chunk-TPZFGGU4.cjs.map +0 -1
- package/dist/server/handlers/harness.cjs +0 -144
- package/dist/server/handlers/harness.cjs.map +0 -1
- package/dist/server/handlers/harness.d.ts.map +0 -1
- package/dist/server/handlers/harness.js +0 -3
- package/dist/server/handlers/harness.js.map +0 -1
- package/dist/server/server-adapter/routes/harness.d.ts +0 -3
- package/dist/server/server-adapter/routes/harness.d.ts.map +0 -1
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var chunkPTPMBE6M_cjs = require('./chunk-PTPMBE6M.cjs');
|
|
4
|
-
var
|
|
5
|
-
var
|
|
4
|
+
var chunk7GNT5KQE_cjs = require('./chunk-7GNT5KQE.cjs');
|
|
5
|
+
var chunk42M6Y2OD_cjs = require('./chunk-42M6Y2OD.cjs');
|
|
6
6
|
var chunkDIG2K5CV_cjs = require('./chunk-DIG2K5CV.cjs');
|
|
7
|
-
var
|
|
7
|
+
var chunkYWUVDFQZ_cjs = require('./chunk-YWUVDFQZ.cjs');
|
|
8
8
|
var chunkZ7LCIYK7_cjs = require('./chunk-Z7LCIYK7.cjs');
|
|
9
9
|
var chunkG54X6VE6_cjs = require('./chunk-G54X6VE6.cjs');
|
|
10
10
|
var chunk64ITUOXI_cjs = require('./chunk-64ITUOXI.cjs');
|
|
@@ -48,7 +48,7 @@ async function listWorkflowsFromSystem({ mastra, workflowId }) {
|
|
|
48
48
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
49
49
|
}
|
|
50
50
|
let workflow;
|
|
51
|
-
workflow =
|
|
51
|
+
workflow = chunkYWUVDFQZ_cjs.WorkflowRegistry.getWorkflow(workflowId);
|
|
52
52
|
if (!workflow) {
|
|
53
53
|
try {
|
|
54
54
|
workflow = mastra.getWorkflowById(workflowId);
|
|
@@ -95,7 +95,7 @@ var LIST_WORKFLOWS_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
95
95
|
const workflows = mastra.listWorkflows({ serialized: false });
|
|
96
96
|
const isPartial = partial === "true";
|
|
97
97
|
const _workflows = Object.entries(workflows).reduce((acc, [key, workflow]) => {
|
|
98
|
-
acc[key] =
|
|
98
|
+
acc[key] = chunkYWUVDFQZ_cjs.getWorkflowInfo(workflow, isPartial);
|
|
99
99
|
return acc;
|
|
100
100
|
}, {});
|
|
101
101
|
const fgaProvider = mastra.getServer?.()?.fga;
|
|
@@ -109,7 +109,7 @@ var LIST_WORKFLOWS_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
109
109
|
user,
|
|
110
110
|
workflowList,
|
|
111
111
|
"workflow",
|
|
112
|
-
|
|
112
|
+
chunk42M6Y2OD_cjs.MastraFGAPermissions.WORKFLOWS_READ
|
|
113
113
|
);
|
|
114
114
|
const accessibleSet = new Set(accessible.map((w) => w.id));
|
|
115
115
|
for (const id of Object.keys(_workflows)) {
|
|
@@ -140,7 +140,7 @@ var GET_WORKFLOW_BY_ID_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
140
140
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
141
141
|
}
|
|
142
142
|
const { workflow } = await listWorkflowsFromSystem({ mastra, workflowId });
|
|
143
|
-
return
|
|
143
|
+
return chunkYWUVDFQZ_cjs.getWorkflowInfo(workflow);
|
|
144
144
|
} catch (error) {
|
|
145
145
|
return chunkZ7LCIYK7_cjs.handleError(error, "Error getting workflow");
|
|
146
146
|
}
|
|
@@ -171,7 +171,7 @@ var LIST_WORKFLOW_RUNS_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
171
171
|
requestContext
|
|
172
172
|
}) => {
|
|
173
173
|
try {
|
|
174
|
-
const effectiveResourceId =
|
|
174
|
+
const effectiveResourceId = chunk42M6Y2OD_cjs.getEffectiveResourceId(requestContext, resourceId);
|
|
175
175
|
if (!workflowId) {
|
|
176
176
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
177
177
|
}
|
|
@@ -223,7 +223,7 @@ var GET_WORKFLOW_RUN_BY_ID_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
223
223
|
requiresAuth: true,
|
|
224
224
|
handler: async ({ mastra, workflowId, runId, fields, withNestedWorkflows, requestContext }) => {
|
|
225
225
|
try {
|
|
226
|
-
const effectiveResourceId =
|
|
226
|
+
const effectiveResourceId = chunk42M6Y2OD_cjs.getEffectiveResourceId(requestContext, void 0);
|
|
227
227
|
if (!workflowId) {
|
|
228
228
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
229
229
|
}
|
|
@@ -243,7 +243,7 @@ var GET_WORKFLOW_RUN_BY_ID_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
243
243
|
if (!run) {
|
|
244
244
|
throw new chunk64ITUOXI_cjs.HTTPException(404, { message: "Workflow run not found" });
|
|
245
245
|
}
|
|
246
|
-
await
|
|
246
|
+
await chunk42M6Y2OD_cjs.validateRunOwnership(run, effectiveResourceId);
|
|
247
247
|
return run;
|
|
248
248
|
} catch (error) {
|
|
249
249
|
return chunkZ7LCIYK7_cjs.handleError(error, "Error getting workflow run");
|
|
@@ -262,7 +262,7 @@ var DELETE_WORKFLOW_RUN_BY_ID_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
262
262
|
requiresAuth: true,
|
|
263
263
|
handler: async ({ mastra, workflowId, runId, requestContext }) => {
|
|
264
264
|
try {
|
|
265
|
-
const effectiveResourceId =
|
|
265
|
+
const effectiveResourceId = chunk42M6Y2OD_cjs.getEffectiveResourceId(requestContext, void 0);
|
|
266
266
|
if (!workflowId) {
|
|
267
267
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
268
268
|
}
|
|
@@ -277,7 +277,7 @@ var DELETE_WORKFLOW_RUN_BY_ID_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
277
277
|
if (!run) {
|
|
278
278
|
throw new chunk64ITUOXI_cjs.HTTPException(404, { message: "Workflow run not found" });
|
|
279
279
|
}
|
|
280
|
-
await
|
|
280
|
+
await chunk42M6Y2OD_cjs.validateRunOwnership(run, effectiveResourceId);
|
|
281
281
|
await workflow.deleteWorkflowRunById(runId);
|
|
282
282
|
return { message: "Workflow run deleted" };
|
|
283
283
|
} catch (error) {
|
|
@@ -303,7 +303,7 @@ var CREATE_WORKFLOW_RUN_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
303
303
|
requiresPermission: ["workflows:write", "workflows:execute"],
|
|
304
304
|
handler: async ({ mastra, workflowId, runId, resourceId, disableScorers, requestContext }) => {
|
|
305
305
|
try {
|
|
306
|
-
const effectiveResourceId =
|
|
306
|
+
const effectiveResourceId = chunk42M6Y2OD_cjs.getEffectiveResourceId(requestContext, resourceId);
|
|
307
307
|
if (!workflowId) {
|
|
308
308
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
309
309
|
}
|
|
@@ -331,7 +331,7 @@ var STREAM_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
331
331
|
requiresAuth: true,
|
|
332
332
|
handler: async ({ mastra, workflowId, runId, resourceId, requestContext, ...params }) => {
|
|
333
333
|
try {
|
|
334
|
-
const effectiveResourceId =
|
|
334
|
+
const effectiveResourceId = chunk42M6Y2OD_cjs.getEffectiveResourceId(requestContext, resourceId);
|
|
335
335
|
if (!workflowId) {
|
|
336
336
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
337
337
|
}
|
|
@@ -365,14 +365,14 @@ var RESUME_STREAM_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
365
365
|
pathParamSchema: chunkPTPMBE6M_cjs.workflowIdPathParams,
|
|
366
366
|
queryParamSchema: chunkDIG2K5CV_cjs.runIdSchema,
|
|
367
367
|
bodySchema: chunkPTPMBE6M_cjs.resumeBodySchema,
|
|
368
|
-
responseSchema:
|
|
368
|
+
responseSchema: chunk7GNT5KQE_cjs.streamResponseSchema,
|
|
369
369
|
summary: "Resume workflow stream",
|
|
370
370
|
description: "Resumes a suspended workflow execution and continues streaming results",
|
|
371
371
|
tags: ["Workflows"],
|
|
372
372
|
requiresAuth: true,
|
|
373
373
|
handler: async ({ mastra, workflowId, runId, requestContext, ...params }) => {
|
|
374
374
|
try {
|
|
375
|
-
const effectiveResourceId =
|
|
375
|
+
const effectiveResourceId = chunk42M6Y2OD_cjs.getEffectiveResourceId(requestContext, void 0);
|
|
376
376
|
if (!workflowId) {
|
|
377
377
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
378
378
|
}
|
|
@@ -387,7 +387,7 @@ var RESUME_STREAM_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
387
387
|
if (!run) {
|
|
388
388
|
throw new chunk64ITUOXI_cjs.HTTPException(404, { message: "Workflow run not found" });
|
|
389
389
|
}
|
|
390
|
-
await
|
|
390
|
+
await chunk42M6Y2OD_cjs.validateRunOwnership(run, effectiveResourceId);
|
|
391
391
|
const _run = await workflow.createRun({ runId, resourceId: run.resourceId });
|
|
392
392
|
const serverCache = mastra.getServerCache();
|
|
393
393
|
const resumeResult = _run.resumeStream({ ...params, requestContext });
|
|
@@ -418,7 +418,7 @@ var START_ASYNC_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
418
418
|
requiresAuth: true,
|
|
419
419
|
handler: async ({ mastra, workflowId, runId, resourceId, requestContext, ...params }) => {
|
|
420
420
|
try {
|
|
421
|
-
const effectiveResourceId =
|
|
421
|
+
const effectiveResourceId = chunk42M6Y2OD_cjs.getEffectiveResourceId(requestContext, resourceId);
|
|
422
422
|
if (!workflowId) {
|
|
423
423
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
424
424
|
}
|
|
@@ -448,7 +448,7 @@ var START_WORKFLOW_RUN_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
448
448
|
requiresAuth: true,
|
|
449
449
|
handler: async ({ mastra, workflowId, runId, requestContext, ...params }) => {
|
|
450
450
|
try {
|
|
451
|
-
const effectiveResourceId =
|
|
451
|
+
const effectiveResourceId = chunk42M6Y2OD_cjs.getEffectiveResourceId(requestContext, void 0);
|
|
452
452
|
if (!workflowId) {
|
|
453
453
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
454
454
|
}
|
|
@@ -463,7 +463,7 @@ var START_WORKFLOW_RUN_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
463
463
|
if (!run) {
|
|
464
464
|
throw new chunk64ITUOXI_cjs.HTTPException(404, { message: "Workflow run not found" });
|
|
465
465
|
}
|
|
466
|
-
await
|
|
466
|
+
await chunk42M6Y2OD_cjs.validateRunOwnership(run, effectiveResourceId);
|
|
467
467
|
const _run = await workflow.createRun({ runId, resourceId: run.resourceId });
|
|
468
468
|
void _run.start({
|
|
469
469
|
...params,
|
|
@@ -481,14 +481,14 @@ var OBSERVE_STREAM_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
481
481
|
responseType: "stream",
|
|
482
482
|
pathParamSchema: chunkPTPMBE6M_cjs.workflowIdPathParams,
|
|
483
483
|
queryParamSchema: chunkPTPMBE6M_cjs.observeWorkflowQuerySchema,
|
|
484
|
-
responseSchema:
|
|
484
|
+
responseSchema: chunk7GNT5KQE_cjs.streamResponseSchema,
|
|
485
485
|
summary: "Observe workflow stream",
|
|
486
486
|
description: "Observes and streams updates from an already running workflow execution. Supports position-based resume with offset for efficient reconnection.",
|
|
487
487
|
tags: ["Workflows"],
|
|
488
488
|
requiresAuth: true,
|
|
489
489
|
handler: async ({ mastra, workflowId, runId, offset, requestContext }) => {
|
|
490
490
|
try {
|
|
491
|
-
const effectiveResourceId =
|
|
491
|
+
const effectiveResourceId = chunk42M6Y2OD_cjs.getEffectiveResourceId(requestContext, void 0);
|
|
492
492
|
if (!workflowId) {
|
|
493
493
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
494
494
|
}
|
|
@@ -503,7 +503,7 @@ var OBSERVE_STREAM_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
503
503
|
if (!run) {
|
|
504
504
|
throw new chunk64ITUOXI_cjs.HTTPException(404, { message: "Workflow run not found" });
|
|
505
505
|
}
|
|
506
|
-
await
|
|
506
|
+
await chunk42M6Y2OD_cjs.validateRunOwnership(run, effectiveResourceId);
|
|
507
507
|
const _run = await workflow.createRun({ runId, resourceId: run.resourceId });
|
|
508
508
|
const serverCache = mastra.getServerCache();
|
|
509
509
|
if (!serverCache) {
|
|
@@ -535,7 +535,7 @@ var RESUME_ASYNC_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
535
535
|
requiresAuth: true,
|
|
536
536
|
handler: async ({ mastra, workflowId, runId, requestContext, ...params }) => {
|
|
537
537
|
try {
|
|
538
|
-
const effectiveResourceId =
|
|
538
|
+
const effectiveResourceId = chunk42M6Y2OD_cjs.getEffectiveResourceId(requestContext, void 0);
|
|
539
539
|
if (!workflowId) {
|
|
540
540
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
541
541
|
}
|
|
@@ -550,7 +550,7 @@ var RESUME_ASYNC_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
550
550
|
if (!run) {
|
|
551
551
|
throw new chunk64ITUOXI_cjs.HTTPException(404, { message: "Workflow run not found" });
|
|
552
552
|
}
|
|
553
|
-
await
|
|
553
|
+
await chunk42M6Y2OD_cjs.validateRunOwnership(run, effectiveResourceId);
|
|
554
554
|
const _run = await workflow.createRun({ runId, resourceId: run.resourceId });
|
|
555
555
|
const result = await _run.resume({ ...params, requestContext });
|
|
556
556
|
return result;
|
|
@@ -573,7 +573,7 @@ var RESUME_NO_WAIT_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
573
573
|
requiresAuth: true,
|
|
574
574
|
handler: async ({ mastra, workflowId, runId, requestContext, ...params }) => {
|
|
575
575
|
try {
|
|
576
|
-
const effectiveResourceId =
|
|
576
|
+
const effectiveResourceId = chunk42M6Y2OD_cjs.getEffectiveResourceId(requestContext, void 0);
|
|
577
577
|
if (!workflowId) {
|
|
578
578
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
579
579
|
}
|
|
@@ -588,7 +588,7 @@ var RESUME_NO_WAIT_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
588
588
|
if (!run) {
|
|
589
589
|
throw new chunk64ITUOXI_cjs.HTTPException(404, { message: "Workflow run not found" });
|
|
590
590
|
}
|
|
591
|
-
await
|
|
591
|
+
await chunk42M6Y2OD_cjs.validateRunOwnership(run, effectiveResourceId);
|
|
592
592
|
const _run = await workflow.createRun({ runId, resourceId: run.resourceId });
|
|
593
593
|
const result = await _run.resumeAsync({ ...params, requestContext });
|
|
594
594
|
return result;
|
|
@@ -611,7 +611,7 @@ var RESUME_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
611
611
|
requiresAuth: true,
|
|
612
612
|
handler: async ({ mastra, workflowId, runId, requestContext, ...params }) => {
|
|
613
613
|
try {
|
|
614
|
-
const effectiveResourceId =
|
|
614
|
+
const effectiveResourceId = chunk42M6Y2OD_cjs.getEffectiveResourceId(requestContext, void 0);
|
|
615
615
|
if (!workflowId) {
|
|
616
616
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
617
617
|
}
|
|
@@ -626,7 +626,7 @@ var RESUME_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
626
626
|
if (!run) {
|
|
627
627
|
throw new chunk64ITUOXI_cjs.HTTPException(404, { message: "Workflow run not found" });
|
|
628
628
|
}
|
|
629
|
-
await
|
|
629
|
+
await chunk42M6Y2OD_cjs.validateRunOwnership(run, effectiveResourceId);
|
|
630
630
|
const _run = await workflow.createRun({ runId, resourceId: run.resourceId });
|
|
631
631
|
void _run.resume({ ...params, requestContext });
|
|
632
632
|
return { message: "Workflow run resumed" };
|
|
@@ -649,7 +649,7 @@ var RESTART_ASYNC_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
649
649
|
requiresAuth: true,
|
|
650
650
|
handler: async ({ mastra, workflowId, runId, requestContext, ...params }) => {
|
|
651
651
|
try {
|
|
652
|
-
const effectiveResourceId =
|
|
652
|
+
const effectiveResourceId = chunk42M6Y2OD_cjs.getEffectiveResourceId(requestContext, void 0);
|
|
653
653
|
if (!workflowId) {
|
|
654
654
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
655
655
|
}
|
|
@@ -664,7 +664,7 @@ var RESTART_ASYNC_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
664
664
|
if (!run) {
|
|
665
665
|
throw new chunk64ITUOXI_cjs.HTTPException(404, { message: "Workflow run not found" });
|
|
666
666
|
}
|
|
667
|
-
await
|
|
667
|
+
await chunk42M6Y2OD_cjs.validateRunOwnership(run, effectiveResourceId);
|
|
668
668
|
const _run = await workflow.createRun({ runId, resourceId: run.resourceId });
|
|
669
669
|
const result = await _run.restart({ ...params, requestContext });
|
|
670
670
|
return result;
|
|
@@ -687,7 +687,7 @@ var RESTART_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
687
687
|
requiresAuth: true,
|
|
688
688
|
handler: async ({ mastra, workflowId, runId, requestContext, ...params }) => {
|
|
689
689
|
try {
|
|
690
|
-
const effectiveResourceId =
|
|
690
|
+
const effectiveResourceId = chunk42M6Y2OD_cjs.getEffectiveResourceId(requestContext, void 0);
|
|
691
691
|
if (!workflowId) {
|
|
692
692
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
693
693
|
}
|
|
@@ -702,7 +702,7 @@ var RESTART_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
702
702
|
if (!run) {
|
|
703
703
|
throw new chunk64ITUOXI_cjs.HTTPException(404, { message: "Workflow run not found" });
|
|
704
704
|
}
|
|
705
|
-
await
|
|
705
|
+
await chunk42M6Y2OD_cjs.validateRunOwnership(run, effectiveResourceId);
|
|
706
706
|
const _run = await workflow.createRun({ runId, resourceId: run.resourceId });
|
|
707
707
|
void _run.restart({ ...params, requestContext });
|
|
708
708
|
return { message: "Workflow run restarted" };
|
|
@@ -777,7 +777,7 @@ var TIME_TRAVEL_ASYNC_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
777
777
|
requiresAuth: true,
|
|
778
778
|
handler: async ({ mastra, workflowId, runId, requestContext, ...params }) => {
|
|
779
779
|
try {
|
|
780
|
-
const effectiveResourceId =
|
|
780
|
+
const effectiveResourceId = chunk42M6Y2OD_cjs.getEffectiveResourceId(requestContext, void 0);
|
|
781
781
|
if (!workflowId) {
|
|
782
782
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
783
783
|
}
|
|
@@ -792,7 +792,7 @@ var TIME_TRAVEL_ASYNC_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
792
792
|
if (!run) {
|
|
793
793
|
throw new chunk64ITUOXI_cjs.HTTPException(404, { message: "Workflow run not found" });
|
|
794
794
|
}
|
|
795
|
-
await
|
|
795
|
+
await chunk42M6Y2OD_cjs.validateRunOwnership(run, effectiveResourceId);
|
|
796
796
|
const _run = await workflow.createRun({ runId, resourceId: run.resourceId });
|
|
797
797
|
const result = await _run.timeTravel({ ...params, requestContext });
|
|
798
798
|
return result;
|
|
@@ -815,7 +815,7 @@ var TIME_TRAVEL_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
815
815
|
requiresAuth: true,
|
|
816
816
|
handler: async ({ mastra, workflowId, runId, requestContext, ...params }) => {
|
|
817
817
|
try {
|
|
818
|
-
const effectiveResourceId =
|
|
818
|
+
const effectiveResourceId = chunk42M6Y2OD_cjs.getEffectiveResourceId(requestContext, void 0);
|
|
819
819
|
if (!workflowId) {
|
|
820
820
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
821
821
|
}
|
|
@@ -830,7 +830,7 @@ var TIME_TRAVEL_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
830
830
|
if (!run) {
|
|
831
831
|
throw new chunk64ITUOXI_cjs.HTTPException(404, { message: "Workflow run not found" });
|
|
832
832
|
}
|
|
833
|
-
await
|
|
833
|
+
await chunk42M6Y2OD_cjs.validateRunOwnership(run, effectiveResourceId);
|
|
834
834
|
const _run = await workflow.createRun({ runId, resourceId: run.resourceId });
|
|
835
835
|
void _run.timeTravel({ ...params, requestContext });
|
|
836
836
|
return { message: "Workflow run time travel started" };
|
|
@@ -852,7 +852,7 @@ var TIME_TRAVEL_STREAM_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
852
852
|
requiresAuth: true,
|
|
853
853
|
handler: async ({ mastra, workflowId, runId, requestContext, ...params }) => {
|
|
854
854
|
try {
|
|
855
|
-
const effectiveResourceId =
|
|
855
|
+
const effectiveResourceId = chunk42M6Y2OD_cjs.getEffectiveResourceId(requestContext, void 0);
|
|
856
856
|
if (!workflowId) {
|
|
857
857
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
858
858
|
}
|
|
@@ -867,7 +867,7 @@ var TIME_TRAVEL_STREAM_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
867
867
|
if (!existingRun) {
|
|
868
868
|
throw new chunk64ITUOXI_cjs.HTTPException(404, { message: "Workflow run not found" });
|
|
869
869
|
}
|
|
870
|
-
await
|
|
870
|
+
await chunk42M6Y2OD_cjs.validateRunOwnership(existingRun, effectiveResourceId);
|
|
871
871
|
const serverCache = mastra.getServerCache();
|
|
872
872
|
const run = await workflow.createRun({ runId, resourceId: existingRun.resourceId });
|
|
873
873
|
const result = run.timeTravelStream({ ...params, requestContext });
|
|
@@ -896,7 +896,7 @@ var CANCEL_WORKFLOW_RUN_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
896
896
|
requiresAuth: true,
|
|
897
897
|
handler: async ({ mastra, workflowId, runId, requestContext }) => {
|
|
898
898
|
try {
|
|
899
|
-
const effectiveResourceId =
|
|
899
|
+
const effectiveResourceId = chunk42M6Y2OD_cjs.getEffectiveResourceId(requestContext, void 0);
|
|
900
900
|
if (!workflowId) {
|
|
901
901
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
902
902
|
}
|
|
@@ -911,7 +911,7 @@ var CANCEL_WORKFLOW_RUN_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
911
911
|
if (!run) {
|
|
912
912
|
throw new chunk64ITUOXI_cjs.HTTPException(404, { message: "Workflow run not found" });
|
|
913
913
|
}
|
|
914
|
-
await
|
|
914
|
+
await chunk42M6Y2OD_cjs.validateRunOwnership(run, effectiveResourceId);
|
|
915
915
|
const _run = await workflow.createRun({ runId, resourceId: run.resourceId });
|
|
916
916
|
await _run.cancel();
|
|
917
917
|
return { message: "Workflow run cancelled" };
|
|
@@ -927,14 +927,14 @@ var STREAM_LEGACY_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
927
927
|
pathParamSchema: chunkPTPMBE6M_cjs.workflowIdPathParams,
|
|
928
928
|
queryParamSchema: chunkDIG2K5CV_cjs.runIdSchema,
|
|
929
929
|
bodySchema: chunkPTPMBE6M_cjs.streamWorkflowBodySchema,
|
|
930
|
-
responseSchema:
|
|
930
|
+
responseSchema: chunk7GNT5KQE_cjs.streamResponseSchema,
|
|
931
931
|
summary: "[DEPRECATED] Stream workflow with legacy format",
|
|
932
932
|
description: "Legacy endpoint for streaming workflow execution. Use /workflows/:workflowId/stream instead.",
|
|
933
933
|
tags: ["Workflows", "Legacy"],
|
|
934
934
|
requiresAuth: true,
|
|
935
935
|
handler: async ({ mastra, workflowId, runId, resourceId, requestContext, ...params }) => {
|
|
936
936
|
try {
|
|
937
|
-
const effectiveResourceId =
|
|
937
|
+
const effectiveResourceId = chunk42M6Y2OD_cjs.getEffectiveResourceId(requestContext, resourceId);
|
|
938
938
|
if (!workflowId) {
|
|
939
939
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
940
940
|
}
|
|
@@ -969,14 +969,14 @@ var OBSERVE_STREAM_LEGACY_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
969
969
|
responseType: "stream",
|
|
970
970
|
pathParamSchema: chunkPTPMBE6M_cjs.workflowIdPathParams,
|
|
971
971
|
queryParamSchema: chunkDIG2K5CV_cjs.runIdSchema,
|
|
972
|
-
responseSchema:
|
|
972
|
+
responseSchema: chunk7GNT5KQE_cjs.streamResponseSchema,
|
|
973
973
|
summary: "[DEPRECATED] Observe workflow stream with legacy format",
|
|
974
974
|
description: "Legacy endpoint for observing workflow stream. Use /workflows/:workflowId/observe instead.",
|
|
975
975
|
tags: ["Workflows", "Legacy"],
|
|
976
976
|
requiresAuth: true,
|
|
977
977
|
handler: async ({ mastra, workflowId, runId, requestContext }) => {
|
|
978
978
|
try {
|
|
979
|
-
const effectiveResourceId =
|
|
979
|
+
const effectiveResourceId = chunk42M6Y2OD_cjs.getEffectiveResourceId(requestContext, void 0);
|
|
980
980
|
if (!workflowId) {
|
|
981
981
|
throw new chunk64ITUOXI_cjs.HTTPException(400, { message: "Workflow ID is required" });
|
|
982
982
|
}
|
|
@@ -991,7 +991,7 @@ var OBSERVE_STREAM_LEGACY_WORKFLOW_ROUTE = chunkG54X6VE6_cjs.createRoute({
|
|
|
991
991
|
if (!run) {
|
|
992
992
|
throw new chunk64ITUOXI_cjs.HTTPException(404, { message: "Workflow run not found" });
|
|
993
993
|
}
|
|
994
|
-
await
|
|
994
|
+
await chunk42M6Y2OD_cjs.validateRunOwnership(run, effectiveResourceId);
|
|
995
995
|
const _run = await workflow.createRun({ runId, resourceId: run.resourceId });
|
|
996
996
|
const serverCache = mastra.getServerCache();
|
|
997
997
|
if (!serverCache) {
|
|
@@ -1143,5 +1143,5 @@ exports.TIME_TRAVEL_ASYNC_WORKFLOW_ROUTE = TIME_TRAVEL_ASYNC_WORKFLOW_ROUTE;
|
|
|
1143
1143
|
exports.TIME_TRAVEL_STREAM_WORKFLOW_ROUTE = TIME_TRAVEL_STREAM_WORKFLOW_ROUTE;
|
|
1144
1144
|
exports.TIME_TRAVEL_WORKFLOW_ROUTE = TIME_TRAVEL_WORKFLOW_ROUTE;
|
|
1145
1145
|
exports.workflows_exports = workflows_exports;
|
|
1146
|
-
//# sourceMappingURL=chunk-
|
|
1147
|
-
//# sourceMappingURL=chunk-
|
|
1146
|
+
//# sourceMappingURL=chunk-Z6YXO2T6.cjs.map
|
|
1147
|
+
//# sourceMappingURL=chunk-Z6YXO2T6.cjs.map
|