@agentuity/core 1.0.31 → 1.0.33
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/api/api.d.ts +226 -0
- package/dist/api/api.d.ts.map +1 -0
- package/dist/api/api.js +635 -0
- package/dist/api/api.js.map +1 -0
- package/dist/api/apikey/create.d.ts +33 -0
- package/dist/api/apikey/create.d.ts.map +1 -0
- package/dist/api/apikey/create.js +23 -0
- package/dist/api/apikey/create.js.map +1 -0
- package/dist/api/apikey/delete.d.ts +19 -0
- package/dist/api/apikey/delete.d.ts.map +1 -0
- package/dist/api/apikey/delete.js +19 -0
- package/dist/api/apikey/delete.js.map +1 -0
- package/dist/api/apikey/get.d.ts +45 -0
- package/dist/api/apikey/get.d.ts.map +1 -0
- package/dist/api/apikey/get.js +36 -0
- package/dist/api/apikey/get.js.map +1 -0
- package/dist/api/apikey/index.d.ts +6 -0
- package/dist/api/apikey/index.d.ts.map +1 -0
- package/dist/api/apikey/index.js +6 -0
- package/dist/api/apikey/index.js.map +1 -0
- package/dist/api/apikey/list.d.ts +64 -0
- package/dist/api/apikey/list.d.ts.map +1 -0
- package/dist/api/apikey/list.js +46 -0
- package/dist/api/apikey/list.js.map +1 -0
- package/dist/api/apikey/util.d.ts +23 -0
- package/dist/api/apikey/util.d.ts.map +1 -0
- package/dist/api/apikey/util.js +3 -0
- package/dist/api/apikey/util.js.map +1 -0
- package/dist/api/config.d.ts +20 -0
- package/dist/api/config.d.ts.map +1 -0
- package/dist/api/config.js +43 -0
- package/dist/api/config.js.map +1 -0
- package/dist/api/db/index.d.ts +5 -0
- package/dist/api/db/index.d.ts.map +1 -0
- package/dist/api/db/index.js +5 -0
- package/dist/api/db/index.js.map +1 -0
- package/dist/api/db/logs.d.ts +70 -0
- package/dist/api/db/logs.d.ts.map +1 -0
- package/dist/api/db/logs.js +59 -0
- package/dist/api/db/logs.js.map +1 -0
- package/dist/api/db/query.d.ts +39 -0
- package/dist/api/db/query.d.ts.map +1 -0
- package/dist/api/db/query.js +49 -0
- package/dist/api/db/query.js.map +1 -0
- package/dist/api/db/tables.d.ts +49 -0
- package/dist/api/db/tables.d.ts.map +1 -0
- package/dist/api/db/tables.js +59 -0
- package/dist/api/db/tables.js.map +1 -0
- package/dist/api/db/util.d.ts +31 -0
- package/dist/api/db/util.d.ts.map +1 -0
- package/dist/api/db/util.js +4 -0
- package/dist/api/db/util.js.map +1 -0
- package/dist/api/env.d.ts +5 -0
- package/dist/api/env.d.ts.map +1 -0
- package/dist/api/env.js +10 -0
- package/dist/api/env.js.map +1 -0
- package/dist/api/eval/get.d.ts +36 -0
- package/dist/api/eval/get.d.ts.map +1 -0
- package/dist/api/eval/get.js +23 -0
- package/dist/api/eval/get.js.map +1 -0
- package/dist/api/eval/index.d.ts +5 -0
- package/dist/api/eval/index.d.ts.map +1 -0
- package/dist/api/eval/index.js +5 -0
- package/dist/api/eval/index.js.map +1 -0
- package/dist/api/eval/list.d.ts +50 -0
- package/dist/api/eval/list.d.ts.map +1 -0
- package/dist/api/eval/list.js +32 -0
- package/dist/api/eval/list.js.map +1 -0
- package/dist/api/eval/run-get.d.ts +48 -0
- package/dist/api/eval/run-get.d.ts.map +1 -0
- package/dist/api/eval/run-get.js +29 -0
- package/dist/api/eval/run-get.js.map +1 -0
- package/dist/api/eval/run-list.d.ts +70 -0
- package/dist/api/eval/run-list.d.ts.map +1 -0
- package/dist/api/eval/run-list.js +42 -0
- package/dist/api/eval/run-list.js.map +1 -0
- package/dist/api/index.d.ts +21 -0
- package/dist/api/index.d.ts.map +1 -0
- package/dist/api/index.js +21 -0
- package/dist/api/index.js.map +1 -0
- package/dist/api/logger.d.ts +7 -0
- package/dist/api/logger.d.ts.map +1 -0
- package/dist/api/logger.js +23 -0
- package/dist/api/logger.js.map +1 -0
- package/dist/api/machine/index.d.ts +3 -0
- package/dist/api/machine/index.d.ts.map +1 -0
- package/dist/api/machine/index.js +3 -0
- package/dist/api/machine/index.js.map +1 -0
- package/dist/api/machine/machine.d.ts +192 -0
- package/dist/api/machine/machine.d.ts.map +1 -0
- package/dist/api/machine/machine.js +109 -0
- package/dist/api/machine/machine.js.map +1 -0
- package/dist/api/machine/util.d.ts +14 -0
- package/dist/api/machine/util.d.ts.map +1 -0
- package/dist/api/machine/util.js +3 -0
- package/dist/api/machine/util.js.map +1 -0
- package/dist/api/org/env-delete.d.ts +23 -0
- package/dist/api/org/env-delete.d.ts.map +1 -0
- package/dist/api/org/env-delete.js +25 -0
- package/dist/api/org/env-delete.js.map +1 -0
- package/dist/api/org/env-get.d.ts +33 -0
- package/dist/api/org/env-get.d.ts.map +1 -0
- package/dist/api/org/env-get.js +26 -0
- package/dist/api/org/env-get.js.map +1 -0
- package/dist/api/org/env-update.d.ts +24 -0
- package/dist/api/org/env-update.d.ts.map +1 -0
- package/dist/api/org/env-update.js +26 -0
- package/dist/api/org/env-update.js.map +1 -0
- package/dist/api/org/index.d.ts +7 -0
- package/dist/api/org/index.d.ts.map +1 -0
- package/dist/api/org/index.js +7 -0
- package/dist/api/org/index.js.map +1 -0
- package/dist/api/org/list.d.ts +27 -0
- package/dist/api/org/list.d.ts.map +1 -0
- package/dist/api/org/list.js +22 -0
- package/dist/api/org/list.js.map +1 -0
- package/dist/api/org/resources.d.ts +141 -0
- package/dist/api/org/resources.d.ts.map +1 -0
- package/dist/api/org/resources.js +97 -0
- package/dist/api/org/resources.js.map +1 -0
- package/dist/api/org/util.d.ts +45 -0
- package/dist/api/org/util.d.ts.map +1 -0
- package/dist/api/org/util.js +4 -0
- package/dist/api/org/util.js.map +1 -0
- package/dist/api/project/agent.d.ts +89 -0
- package/dist/api/project/agent.d.ts.map +1 -0
- package/dist/api/project/agent.js +60 -0
- package/dist/api/project/agent.js.map +1 -0
- package/dist/api/project/create.d.ts +37 -0
- package/dist/api/project/create.d.ts.map +1 -0
- package/dist/api/project/create.js +31 -0
- package/dist/api/project/create.js.map +1 -0
- package/dist/api/project/delete.d.ts +15 -0
- package/dist/api/project/delete.d.ts.map +1 -0
- package/dist/api/project/delete.js +13 -0
- package/dist/api/project/delete.js.map +1 -0
- package/dist/api/project/deploy.d.ts +490 -0
- package/dist/api/project/deploy.d.ts.map +1 -0
- package/dist/api/project/deploy.js +313 -0
- package/dist/api/project/deploy.js.map +1 -0
- package/dist/api/project/deployment.d.ts +237 -0
- package/dist/api/project/deployment.d.ts.map +1 -0
- package/dist/api/project/deployment.js +127 -0
- package/dist/api/project/deployment.js.map +1 -0
- package/dist/api/project/env-delete.d.ts +22 -0
- package/dist/api/project/env-delete.d.ts.map +1 -0
- package/dist/api/project/env-delete.js +29 -0
- package/dist/api/project/env-delete.js.map +1 -0
- package/dist/api/project/env-update.d.ts +31 -0
- package/dist/api/project/env-update.d.ts.map +1 -0
- package/dist/api/project/env-update.js +36 -0
- package/dist/api/project/env-update.js.map +1 -0
- package/dist/api/project/exists.d.ts +25 -0
- package/dist/api/project/exists.d.ts.map +1 -0
- package/dist/api/project/exists.js +45 -0
- package/dist/api/project/exists.js.map +1 -0
- package/dist/api/project/get.d.ts +43 -0
- package/dist/api/project/get.d.ts.map +1 -0
- package/dist/api/project/get.js +36 -0
- package/dist/api/project/get.js.map +1 -0
- package/dist/api/project/hostname.d.ts +25 -0
- package/dist/api/project/hostname.d.ts.map +1 -0
- package/dist/api/project/hostname.js +37 -0
- package/dist/api/project/hostname.js.map +1 -0
- package/dist/api/project/index.d.ts +14 -0
- package/dist/api/project/index.d.ts.map +1 -0
- package/dist/api/project/index.js +14 -0
- package/dist/api/project/index.js.map +1 -0
- package/dist/api/project/list.d.ts +48 -0
- package/dist/api/project/list.d.ts.map +1 -0
- package/dist/api/project/list.js +38 -0
- package/dist/api/project/list.js.map +1 -0
- package/dist/api/project/malware.d.ts +71 -0
- package/dist/api/project/malware.d.ts.map +1 -0
- package/dist/api/project/malware.js +42 -0
- package/dist/api/project/malware.js.map +1 -0
- package/dist/api/project/update-region.d.ts +27 -0
- package/dist/api/project/update-region.d.ts.map +1 -0
- package/dist/api/project/update-region.js +25 -0
- package/dist/api/project/update-region.js.map +1 -0
- package/dist/api/project/util.d.ts +62 -0
- package/dist/api/project/util.d.ts.map +1 -0
- package/dist/api/project/util.js +6 -0
- package/dist/api/project/util.js.map +1 -0
- package/dist/api/queue/analytics.d.ts +250 -0
- package/dist/api/queue/analytics.d.ts.map +1 -0
- package/dist/api/queue/analytics.js +233 -0
- package/dist/api/queue/analytics.js.map +1 -0
- package/dist/api/queue/destinations.d.ts +202 -0
- package/dist/api/queue/destinations.d.ts.map +1 -0
- package/dist/api/queue/destinations.js +168 -0
- package/dist/api/queue/destinations.js.map +1 -0
- package/dist/api/queue/dlq.d.ts +168 -0
- package/dist/api/queue/dlq.d.ts.map +1 -0
- package/dist/api/queue/dlq.js +166 -0
- package/dist/api/queue/dlq.js.map +1 -0
- package/dist/api/queue/index.d.ts +56 -0
- package/dist/api/queue/index.d.ts.map +1 -0
- package/dist/api/queue/index.js +90 -0
- package/dist/api/queue/index.js.map +1 -0
- package/dist/api/queue/messages.d.ts +503 -0
- package/dist/api/queue/messages.d.ts.map +1 -0
- package/dist/api/queue/messages.js +549 -0
- package/dist/api/queue/messages.js.map +1 -0
- package/dist/api/queue/queues.d.ts +226 -0
- package/dist/api/queue/queues.d.ts.map +1 -0
- package/dist/api/queue/queues.js +321 -0
- package/dist/api/queue/queues.js.map +1 -0
- package/dist/api/queue/sources.d.ts +202 -0
- package/dist/api/queue/sources.d.ts.map +1 -0
- package/dist/api/queue/sources.js +202 -0
- package/dist/api/queue/sources.js.map +1 -0
- package/dist/api/queue/types.d.ts +1218 -0
- package/dist/api/queue/types.d.ts.map +1 -0
- package/dist/api/queue/types.js +1002 -0
- package/dist/api/queue/types.js.map +1 -0
- package/dist/api/queue/util.d.ts +278 -0
- package/dist/api/queue/util.d.ts.map +1 -0
- package/dist/api/queue/util.js +233 -0
- package/dist/api/queue/util.js.map +1 -0
- package/dist/api/queue/validation.d.ts +247 -0
- package/dist/api/queue/validation.d.ts.map +1 -0
- package/dist/api/queue/validation.js +513 -0
- package/dist/api/queue/validation.js.map +1 -0
- package/dist/api/queue/websocket.d.ts +172 -0
- package/dist/api/queue/websocket.d.ts.map +1 -0
- package/dist/api/queue/websocket.js +396 -0
- package/dist/api/queue/websocket.js.map +1 -0
- package/dist/api/region/create.d.ts +81 -0
- package/dist/api/region/create.d.ts.map +1 -0
- package/dist/api/region/create.js +177 -0
- package/dist/api/region/create.js.map +1 -0
- package/dist/api/region/delete.d.ts +62 -0
- package/dist/api/region/delete.d.ts.map +1 -0
- package/dist/api/region/delete.js +37 -0
- package/dist/api/region/delete.js.map +1 -0
- package/dist/api/region/index.d.ts +5 -0
- package/dist/api/region/index.d.ts.map +1 -0
- package/dist/api/region/index.js +5 -0
- package/dist/api/region/index.js.map +1 -0
- package/dist/api/region/list.d.ts +27 -0
- package/dist/api/region/list.d.ts.map +1 -0
- package/dist/api/region/list.js +22 -0
- package/dist/api/region/list.js.map +1 -0
- package/dist/api/region/resources.d.ts +71 -0
- package/dist/api/region/resources.d.ts.map +1 -0
- package/dist/api/region/resources.js +53 -0
- package/dist/api/region/resources.js.map +1 -0
- package/dist/api/region/util.d.ts +23 -0
- package/dist/api/region/util.d.ts.map +1 -0
- package/dist/api/region/util.js +3 -0
- package/dist/api/region/util.js.map +1 -0
- package/dist/api/sandbox/cli-list.d.ts +114 -0
- package/dist/api/sandbox/cli-list.d.ts.map +1 -0
- package/dist/api/sandbox/cli-list.js +71 -0
- package/dist/api/sandbox/cli-list.js.map +1 -0
- package/dist/api/sandbox/client.d.ts +192 -0
- package/dist/api/sandbox/client.d.ts.map +1 -0
- package/dist/api/sandbox/client.js +262 -0
- package/dist/api/sandbox/client.js.map +1 -0
- package/dist/api/sandbox/create.d.ts +118 -0
- package/dist/api/sandbox/create.d.ts.map +1 -0
- package/dist/api/sandbox/create.js +211 -0
- package/dist/api/sandbox/create.js.map +1 -0
- package/dist/api/sandbox/destroy.d.ts +22 -0
- package/dist/api/sandbox/destroy.d.ts.map +1 -0
- package/dist/api/sandbox/destroy.js +25 -0
- package/dist/api/sandbox/destroy.js.map +1 -0
- package/dist/api/sandbox/disk-checkpoint.d.ts +104 -0
- package/dist/api/sandbox/disk-checkpoint.d.ts.map +1 -0
- package/dist/api/sandbox/disk-checkpoint.js +104 -0
- package/dist/api/sandbox/disk-checkpoint.js.map +1 -0
- package/dist/api/sandbox/execute.d.ts +69 -0
- package/dist/api/sandbox/execute.d.ts.map +1 -0
- package/dist/api/sandbox/execute.js +103 -0
- package/dist/api/sandbox/execute.js.map +1 -0
- package/dist/api/sandbox/execution.d.ts +169 -0
- package/dist/api/sandbox/execution.d.ts.map +1 -0
- package/dist/api/sandbox/execution.js +118 -0
- package/dist/api/sandbox/execution.js.map +1 -0
- package/dist/api/sandbox/files.d.ts +261 -0
- package/dist/api/sandbox/files.d.ts.map +1 -0
- package/dist/api/sandbox/files.js +386 -0
- package/dist/api/sandbox/files.js.map +1 -0
- package/dist/api/sandbox/get.d.ts +283 -0
- package/dist/api/sandbox/get.d.ts.map +1 -0
- package/dist/api/sandbox/get.js +215 -0
- package/dist/api/sandbox/get.js.map +1 -0
- package/dist/api/sandbox/getStatus.d.ts +16 -0
- package/dist/api/sandbox/getStatus.d.ts.map +1 -0
- package/dist/api/sandbox/getStatus.js +32 -0
- package/dist/api/sandbox/getStatus.js.map +1 -0
- package/dist/api/sandbox/index.d.ts +39 -0
- package/dist/api/sandbox/index.d.ts.map +1 -0
- package/dist/api/sandbox/index.js +20 -0
- package/dist/api/sandbox/index.js.map +1 -0
- package/dist/api/sandbox/list.d.ts +293 -0
- package/dist/api/sandbox/list.d.ts.map +1 -0
- package/dist/api/sandbox/list.js +191 -0
- package/dist/api/sandbox/list.js.map +1 -0
- package/dist/api/sandbox/pause.d.ts +22 -0
- package/dist/api/sandbox/pause.d.ts.map +1 -0
- package/dist/api/sandbox/pause.js +25 -0
- package/dist/api/sandbox/pause.js.map +1 -0
- package/dist/api/sandbox/resolve.d.ts +82 -0
- package/dist/api/sandbox/resolve.d.ts.map +1 -0
- package/dist/api/sandbox/resolve.js +71 -0
- package/dist/api/sandbox/resolve.js.map +1 -0
- package/dist/api/sandbox/resume.d.ts +22 -0
- package/dist/api/sandbox/resume.d.ts.map +1 -0
- package/dist/api/sandbox/resume.js +25 -0
- package/dist/api/sandbox/resume.js.map +1 -0
- package/dist/api/sandbox/run.d.ts +28 -0
- package/dist/api/sandbox/run.d.ts.map +1 -0
- package/dist/api/sandbox/run.js +342 -0
- package/dist/api/sandbox/run.js.map +1 -0
- package/dist/api/sandbox/runtime.d.ts +83 -0
- package/dist/api/sandbox/runtime.d.ts.map +1 -0
- package/dist/api/sandbox/runtime.js +78 -0
- package/dist/api/sandbox/runtime.js.map +1 -0
- package/dist/api/sandbox/snapshot-build.d.ts +48 -0
- package/dist/api/sandbox/snapshot-build.d.ts.map +1 -0
- package/dist/api/sandbox/snapshot-build.js +72 -0
- package/dist/api/sandbox/snapshot-build.js.map +1 -0
- package/dist/api/sandbox/snapshot.d.ts +595 -0
- package/dist/api/sandbox/snapshot.d.ts.map +1 -0
- package/dist/api/sandbox/snapshot.js +598 -0
- package/dist/api/sandbox/snapshot.js.map +1 -0
- package/dist/api/sandbox/util.d.ts +284 -0
- package/dist/api/sandbox/util.d.ts.map +1 -0
- package/dist/api/sandbox/util.js +210 -0
- package/dist/api/sandbox/util.js.map +1 -0
- package/dist/api/services/index.d.ts +2 -0
- package/dist/api/services/index.d.ts.map +1 -0
- package/dist/api/services/index.js +2 -0
- package/dist/api/services/index.js.map +1 -0
- package/dist/api/services/stats.d.ts +263 -0
- package/dist/api/services/stats.d.ts.map +1 -0
- package/dist/api/services/stats.js +144 -0
- package/dist/api/services/stats.js.map +1 -0
- package/dist/api/session/get.d.ts +169 -0
- package/dist/api/session/get.d.ts.map +1 -0
- package/dist/api/session/get.js +56 -0
- package/dist/api/session/get.js.map +1 -0
- package/dist/api/session/index.d.ts +4 -0
- package/dist/api/session/index.d.ts.map +1 -0
- package/dist/api/session/index.js +4 -0
- package/dist/api/session/index.js.map +1 -0
- package/dist/api/session/list.d.ts +143 -0
- package/dist/api/session/list.d.ts.map +1 -0
- package/dist/api/session/list.js +91 -0
- package/dist/api/session/list.js.map +1 -0
- package/dist/api/session/logs.d.ts +40 -0
- package/dist/api/session/logs.d.ts.map +1 -0
- package/dist/api/session/logs.js +28 -0
- package/dist/api/session/logs.js.map +1 -0
- package/dist/api/session/util.d.ts +23 -0
- package/dist/api/session/util.d.ts.map +1 -0
- package/dist/api/session/util.js +3 -0
- package/dist/api/session/util.js.map +1 -0
- package/dist/api/storage/config.d.ts +99 -0
- package/dist/api/storage/config.d.ts.map +1 -0
- package/dist/api/storage/config.js +61 -0
- package/dist/api/storage/config.js.map +1 -0
- package/dist/api/storage/index.d.ts +5 -0
- package/dist/api/storage/index.d.ts.map +1 -0
- package/dist/api/storage/index.js +5 -0
- package/dist/api/storage/index.js.map +1 -0
- package/dist/api/storage/objects.d.ts +155 -0
- package/dist/api/storage/objects.d.ts.map +1 -0
- package/dist/api/storage/objects.js +148 -0
- package/dist/api/storage/objects.js.map +1 -0
- package/dist/api/storage/types.d.ts +161 -0
- package/dist/api/storage/types.d.ts.map +1 -0
- package/dist/api/storage/types.js +141 -0
- package/dist/api/storage/types.js.map +1 -0
- package/dist/api/storage/util.d.ts +45 -0
- package/dist/api/storage/util.d.ts.map +1 -0
- package/dist/api/storage/util.js +4 -0
- package/dist/api/storage/util.js.map +1 -0
- package/dist/api/stream/get.d.ts +58 -0
- package/dist/api/stream/get.d.ts.map +1 -0
- package/dist/api/stream/get.js +40 -0
- package/dist/api/stream/get.js.map +1 -0
- package/dist/api/stream/index.d.ts +4 -0
- package/dist/api/stream/index.d.ts.map +1 -0
- package/dist/api/stream/index.js +4 -0
- package/dist/api/stream/index.js.map +1 -0
- package/dist/api/stream/list.d.ts +120 -0
- package/dist/api/stream/list.d.ts.map +1 -0
- package/dist/api/stream/list.js +77 -0
- package/dist/api/stream/list.js.map +1 -0
- package/dist/api/stream/util.d.ts +23 -0
- package/dist/api/stream/util.d.ts.map +1 -0
- package/dist/api/stream/util.js +3 -0
- package/dist/api/stream/util.js.map +1 -0
- package/dist/api/thread/delete.d.ts +23 -0
- package/dist/api/thread/delete.d.ts.map +1 -0
- package/dist/api/thread/delete.js +21 -0
- package/dist/api/thread/delete.js.map +1 -0
- package/dist/api/thread/get.d.ts +36 -0
- package/dist/api/thread/get.d.ts.map +1 -0
- package/dist/api/thread/get.js +23 -0
- package/dist/api/thread/get.js.map +1 -0
- package/dist/api/thread/index.d.ts +5 -0
- package/dist/api/thread/index.d.ts.map +1 -0
- package/dist/api/thread/index.js +5 -0
- package/dist/api/thread/index.js.map +1 -0
- package/dist/api/thread/list.d.ts +69 -0
- package/dist/api/thread/list.d.ts.map +1 -0
- package/dist/api/thread/list.js +51 -0
- package/dist/api/thread/list.js.map +1 -0
- package/dist/api/thread/util.d.ts +23 -0
- package/dist/api/thread/util.d.ts.map +1 -0
- package/dist/api/thread/util.js +3 -0
- package/dist/api/thread/util.js.map +1 -0
- package/dist/api/user/index.d.ts +2 -0
- package/dist/api/user/index.d.ts.map +1 -0
- package/dist/api/user/index.js +2 -0
- package/dist/api/user/index.js.map +1 -0
- package/dist/api/user/util.d.ts +23 -0
- package/dist/api/user/util.d.ts.map +1 -0
- package/dist/api/user/util.js +3 -0
- package/dist/api/user/util.js.map +1 -0
- package/dist/api/user/whoami.d.ts +39 -0
- package/dist/api/user/whoami.d.ts.map +1 -0
- package/dist/api/user/whoami.js +27 -0
- package/dist/api/user/whoami.js.map +1 -0
- package/dist/api/webhook/deliveries.d.ts +94 -0
- package/dist/api/webhook/deliveries.d.ts.map +1 -0
- package/dist/api/webhook/deliveries.js +79 -0
- package/dist/api/webhook/deliveries.js.map +1 -0
- package/dist/api/webhook/destinations.d.ts +136 -0
- package/dist/api/webhook/destinations.d.ts.map +1 -0
- package/dist/api/webhook/destinations.js +137 -0
- package/dist/api/webhook/destinations.js.map +1 -0
- package/dist/api/webhook/index.d.ts +41 -0
- package/dist/api/webhook/index.d.ts.map +1 -0
- package/dist/api/webhook/index.js +59 -0
- package/dist/api/webhook/index.js.map +1 -0
- package/dist/api/webhook/receipts.d.ts +77 -0
- package/dist/api/webhook/receipts.d.ts.map +1 -0
- package/dist/api/webhook/receipts.js +78 -0
- package/dist/api/webhook/receipts.js.map +1 -0
- package/dist/api/webhook/types.d.ts +249 -0
- package/dist/api/webhook/types.d.ts.map +1 -0
- package/dist/api/webhook/types.js +221 -0
- package/dist/api/webhook/types.js.map +1 -0
- package/dist/api/webhook/util.d.ts +202 -0
- package/dist/api/webhook/util.d.ts.map +1 -0
- package/dist/api/webhook/util.js +199 -0
- package/dist/api/webhook/util.js.map +1 -0
- package/dist/api/webhook/webhooks.d.ts +146 -0
- package/dist/api/webhook/webhooks.d.ts.map +1 -0
- package/dist/api/webhook/webhooks.js +165 -0
- package/dist/api/webhook/webhooks.js.map +1 -0
- package/dist/env-example.d.ts +11 -0
- package/dist/env-example.d.ts.map +1 -0
- package/dist/env-example.js +70 -0
- package/dist/env-example.js.map +1 -0
- package/dist/error.d.ts.map +1 -1
- package/dist/error.js +16 -9
- package/dist/error.js.map +1 -1
- package/dist/index.d.ts +20 -17
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +15 -12
- package/dist/index.js.map +1 -1
- package/dist/services/email.d.ts.map +1 -1
- package/dist/services/email.js +15 -15
- package/dist/services/email.js.map +1 -1
- package/dist/services/keyvalue.d.ts.map +1 -1
- package/dist/services/keyvalue.js +10 -10
- package/dist/services/keyvalue.js.map +1 -1
- package/dist/services/queue.d.ts.map +1 -1
- package/dist/services/queue.js +3 -3
- package/dist/services/queue.js.map +1 -1
- package/dist/services/schedule.d.ts.map +1 -1
- package/dist/services/schedule.js +8 -10
- package/dist/services/schedule.js.map +1 -1
- package/dist/services/stream.d.ts +3 -3
- package/dist/services/stream.d.ts.map +1 -1
- package/dist/services/stream.js +8 -13
- package/dist/services/stream.js.map +1 -1
- package/dist/services/vector.d.ts.map +1 -1
- package/dist/services/vector.js +9 -9
- package/dist/services/vector.js.map +1 -1
- package/dist/services/webhook.d.ts +2 -1
- package/dist/services/webhook.d.ts.map +1 -1
- package/dist/services/webhook.js +12 -14
- package/dist/services/webhook.js.map +1 -1
- package/package.json +2 -2
- package/src/api/api-example.md +164 -0
- package/src/api/api.ts +931 -0
- package/src/api/apikey/create.ts +41 -0
- package/src/api/apikey/delete.ts +30 -0
- package/src/api/apikey/get.ts +48 -0
- package/src/api/apikey/index.ts +5 -0
- package/src/api/apikey/list.ts +64 -0
- package/src/api/apikey/util.ts +3 -0
- package/src/api/config.ts +60 -0
- package/src/api/db/index.ts +27 -0
- package/src/api/db/logs.ts +75 -0
- package/src/api/db/query.ts +67 -0
- package/src/api/db/tables.ts +92 -0
- package/src/api/db/util.ts +9 -0
- package/src/api/env.ts +9 -0
- package/src/api/eval/get.ts +33 -0
- package/src/api/eval/index.ts +28 -0
- package/src/api/eval/list.ts +49 -0
- package/src/api/eval/run-get.ts +39 -0
- package/src/api/eval/run-list.ts +59 -0
- package/src/api/index.ts +20 -0
- package/src/api/logger.ts +24 -0
- package/src/api/machine/index.ts +2 -0
- package/src/api/machine/machine.ts +160 -0
- package/src/api/machine/util.ts +5 -0
- package/src/api/org/env-delete.ts +37 -0
- package/src/api/org/env-get.ts +43 -0
- package/src/api/org/env-update.ts +38 -0
- package/src/api/org/index.ts +6 -0
- package/src/api/org/list.ts +28 -0
- package/src/api/org/resources.ts +140 -0
- package/src/api/org/util.ts +4 -0
- package/src/api/project/agent.ts +86 -0
- package/src/api/project/create.ts +47 -0
- package/src/api/project/delete.ts +25 -0
- package/src/api/project/deploy.ts +458 -0
- package/src/api/project/deployment.ts +195 -0
- package/src/api/project/env-delete.ts +45 -0
- package/src/api/project/env-update.ts +55 -0
- package/src/api/project/exists.ts +58 -0
- package/src/api/project/get.ts +49 -0
- package/src/api/project/hostname.ts +73 -0
- package/src/api/project/index.ts +13 -0
- package/src/api/project/list.ts +54 -0
- package/src/api/project/malware.ts +68 -0
- package/src/api/project/update-region.ts +44 -0
- package/src/api/project/util.ts +8 -0
- package/src/api/queue/analytics.ts +311 -0
- package/src/api/queue/destinations.ts +259 -0
- package/src/api/queue/dlq.ts +243 -0
- package/src/api/queue/index.ts +308 -0
- package/src/api/queue/messages.ts +784 -0
- package/src/api/queue/queues.ts +460 -0
- package/src/api/queue/sources.ts +294 -0
- package/src/api/queue/types.ts +1325 -0
- package/src/api/queue/util.ts +275 -0
- package/src/api/queue/validation.ts +560 -0
- package/src/api/queue/websocket.ts +521 -0
- package/src/api/region/create.ts +207 -0
- package/src/api/region/delete.ts +57 -0
- package/src/api/region/index.ts +4 -0
- package/src/api/region/list.ts +32 -0
- package/src/api/region/resources.ts +69 -0
- package/src/api/region/util.ts +3 -0
- package/src/api/sandbox/cli-list.ts +127 -0
- package/src/api/sandbox/client.ts +460 -0
- package/src/api/sandbox/create.ts +256 -0
- package/src/api/sandbox/destroy.ts +41 -0
- package/src/api/sandbox/disk-checkpoint.ts +179 -0
- package/src/api/sandbox/execute.ts +132 -0
- package/src/api/sandbox/execution.ts +183 -0
- package/src/api/sandbox/files.ts +596 -0
- package/src/api/sandbox/get.ts +249 -0
- package/src/api/sandbox/getStatus.ts +54 -0
- package/src/api/sandbox/index.ts +211 -0
- package/src/api/sandbox/list.ts +224 -0
- package/src/api/sandbox/pause.ts +39 -0
- package/src/api/sandbox/resolve.ts +98 -0
- package/src/api/sandbox/resume.ts +39 -0
- package/src/api/sandbox/run.ts +439 -0
- package/src/api/sandbox/runtime.ts +104 -0
- package/src/api/sandbox/snapshot-build.ts +94 -0
- package/src/api/sandbox/snapshot.ts +781 -0
- package/src/api/sandbox/util.ts +275 -0
- package/src/api/services/index.ts +1 -0
- package/src/api/services/stats.ts +213 -0
- package/src/api/session/get.ts +106 -0
- package/src/api/session/index.ts +3 -0
- package/src/api/session/list.ts +136 -0
- package/src/api/session/logs.ts +47 -0
- package/src/api/session/util.ts +3 -0
- package/src/api/storage/config.ts +111 -0
- package/src/api/storage/index.ts +4 -0
- package/src/api/storage/objects.ts +250 -0
- package/src/api/storage/types.ts +174 -0
- package/src/api/storage/util.ts +4 -0
- package/src/api/stream/get.ts +51 -0
- package/src/api/stream/index.ts +3 -0
- package/src/api/stream/list.ts +127 -0
- package/src/api/stream/util.ts +3 -0
- package/src/api/thread/delete.ts +31 -0
- package/src/api/thread/get.ts +34 -0
- package/src/api/thread/index.ts +4 -0
- package/src/api/thread/list.ts +76 -0
- package/src/api/thread/util.ts +3 -0
- package/src/api/user/index.ts +1 -0
- package/src/api/user/util.ts +3 -0
- package/src/api/user/whoami.ts +32 -0
- package/src/api/webhook/deliveries.ts +129 -0
- package/src/api/webhook/destinations.ts +224 -0
- package/src/api/webhook/index.ts +133 -0
- package/src/api/webhook/receipts.ts +124 -0
- package/src/api/webhook/types.ts +309 -0
- package/src/api/webhook/util.ts +234 -0
- package/src/api/webhook/webhooks.ts +260 -0
- package/src/env-example.ts +90 -0
- package/src/error.ts +16 -9
- package/src/index.ts +209 -206
- package/src/services/email.ts +15 -24
- package/src/services/keyvalue.ts +10 -13
- package/src/services/queue.ts +3 -6
- package/src/services/schedule.ts +8 -19
- package/src/services/stream.ts +11 -17
- package/src/services/vector.ts +9 -12
- package/src/services/webhook.ts +14 -24
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import type { ExecuteOptions, Execution } from '../../services/sandbox.ts';
|
|
2
|
+
import { z } from 'zod';
|
|
3
|
+
import { type APIClient } from '../api.ts';
|
|
4
|
+
export declare const ExecuteRequestSchema: z.ZodObject<{
|
|
5
|
+
command: z.ZodArray<z.ZodString>;
|
|
6
|
+
files: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
7
|
+
path: z.ZodString;
|
|
8
|
+
content: z.ZodString;
|
|
9
|
+
}, z.core.$strip>>>;
|
|
10
|
+
timeout: z.ZodOptional<z.ZodString>;
|
|
11
|
+
stream: z.ZodOptional<z.ZodObject<{
|
|
12
|
+
stdout: z.ZodOptional<z.ZodString>;
|
|
13
|
+
stderr: z.ZodOptional<z.ZodString>;
|
|
14
|
+
timestamps: z.ZodOptional<z.ZodBoolean>;
|
|
15
|
+
}, z.core.$strip>>;
|
|
16
|
+
}, z.core.$strip>;
|
|
17
|
+
export declare const ExecuteDataSchema: z.ZodObject<{
|
|
18
|
+
executionId: z.ZodString;
|
|
19
|
+
status: z.ZodEnum<{
|
|
20
|
+
running: "running";
|
|
21
|
+
failed: "failed";
|
|
22
|
+
queued: "queued";
|
|
23
|
+
completed: "completed";
|
|
24
|
+
timeout: "timeout";
|
|
25
|
+
cancelled: "cancelled";
|
|
26
|
+
}>;
|
|
27
|
+
exitCode: z.ZodOptional<z.ZodNumber>;
|
|
28
|
+
durationMs: z.ZodOptional<z.ZodNumber>;
|
|
29
|
+
stdoutStreamUrl: z.ZodOptional<z.ZodString>;
|
|
30
|
+
stderrStreamUrl: z.ZodOptional<z.ZodString>;
|
|
31
|
+
}, z.core.$strip>;
|
|
32
|
+
export declare const ExecuteResponseSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
33
|
+
success: z.ZodLiteral<false>;
|
|
34
|
+
message: z.ZodString;
|
|
35
|
+
code: z.ZodOptional<z.ZodString>;
|
|
36
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
37
|
+
success: z.ZodLiteral<true>;
|
|
38
|
+
data: z.ZodObject<{
|
|
39
|
+
executionId: z.ZodString;
|
|
40
|
+
status: z.ZodEnum<{
|
|
41
|
+
running: "running";
|
|
42
|
+
failed: "failed";
|
|
43
|
+
queued: "queued";
|
|
44
|
+
completed: "completed";
|
|
45
|
+
timeout: "timeout";
|
|
46
|
+
cancelled: "cancelled";
|
|
47
|
+
}>;
|
|
48
|
+
exitCode: z.ZodOptional<z.ZodNumber>;
|
|
49
|
+
durationMs: z.ZodOptional<z.ZodNumber>;
|
|
50
|
+
stdoutStreamUrl: z.ZodOptional<z.ZodString>;
|
|
51
|
+
stderrStreamUrl: z.ZodOptional<z.ZodString>;
|
|
52
|
+
}, z.core.$strip>;
|
|
53
|
+
}, z.core.$strip>], "success">;
|
|
54
|
+
export interface SandboxExecuteParams {
|
|
55
|
+
sandboxId: string;
|
|
56
|
+
options: ExecuteOptions;
|
|
57
|
+
orgId?: string;
|
|
58
|
+
signal?: AbortSignal;
|
|
59
|
+
}
|
|
60
|
+
/**
|
|
61
|
+
* Executes a command in an existing sandbox.
|
|
62
|
+
*
|
|
63
|
+
* @param client - The API client to use for the request
|
|
64
|
+
* @param params - Parameters including sandbox ID and execution options
|
|
65
|
+
* @returns The execution result including status and stream URLs
|
|
66
|
+
* @throws {SandboxResponseError} If the execution request fails
|
|
67
|
+
*/
|
|
68
|
+
export declare function sandboxExecute(client: APIClient, params: SandboxExecuteParams): Promise<Execution>;
|
|
69
|
+
//# sourceMappingURL=execute.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"execute.d.ts","sourceRoot":"","sources":["../../../src/api/sandbox/execute.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAmB,MAAM,2BAA2B,CAAC;AAC5F,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,KAAK,SAAS,EAAqB,MAAM,WAAW,CAAC;AAG9D,eAAO,MAAM,oBAAoB;;;;;;;;;;;;iBAsB8B,CAAC;AAEhE,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;iBAWoB,CAAC;AAEnD,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;8BAAuC,CAAC;AAE1E,MAAM,WAAW,oBAAoB;IACpC,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,cAAc,CAAC;IACxB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,WAAW,CAAC;CACrB;AAED;;;;;;;GAOG;AACH,wBAAsB,cAAc,CACnC,MAAM,EAAE,SAAS,EACjB,MAAM,EAAE,oBAAoB,GAC1B,OAAO,CAAC,SAAS,CAAC,CAqEpB"}
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { APIResponseSchema } from "../api.js";
|
|
3
|
+
import { SandboxBusyError, throwSandboxError } from "./util.js";
|
|
4
|
+
export const ExecuteRequestSchema = z
|
|
5
|
+
.object({
|
|
6
|
+
command: z.array(z.string()).describe('Command and arguments to execute'),
|
|
7
|
+
files: z
|
|
8
|
+
.array(z.object({
|
|
9
|
+
path: z.string().describe('File path relative to workspace'),
|
|
10
|
+
content: z.string().describe('Base64-encoded file content'),
|
|
11
|
+
}))
|
|
12
|
+
.optional()
|
|
13
|
+
.describe('Files to write before execution'),
|
|
14
|
+
timeout: z.string().optional().describe('Execution timeout (e.g., "30s", "5m")'),
|
|
15
|
+
stream: z
|
|
16
|
+
.object({
|
|
17
|
+
stdout: z.string().optional().describe('Stream ID for stdout output'),
|
|
18
|
+
stderr: z.string().optional().describe('Stream ID for stderr output'),
|
|
19
|
+
timestamps: z.boolean().optional().describe('Whether to include timestamps in output'),
|
|
20
|
+
})
|
|
21
|
+
.optional()
|
|
22
|
+
.describe('Stream configuration for output redirection'),
|
|
23
|
+
})
|
|
24
|
+
.describe('Request body for executing a command in a sandbox');
|
|
25
|
+
export const ExecuteDataSchema = z
|
|
26
|
+
.object({
|
|
27
|
+
executionId: z.string().describe('Unique identifier for the execution'),
|
|
28
|
+
status: z
|
|
29
|
+
.enum(['queued', 'running', 'completed', 'failed', 'timeout', 'cancelled'])
|
|
30
|
+
.describe('Current status of the execution'),
|
|
31
|
+
exitCode: z.number().optional().describe('Exit code of the executed command'),
|
|
32
|
+
durationMs: z.number().optional().describe('Execution duration in milliseconds'),
|
|
33
|
+
stdoutStreamUrl: z.string().optional().describe('URL for streaming stdout output'),
|
|
34
|
+
stderrStreamUrl: z.string().optional().describe('URL for streaming stderr output'),
|
|
35
|
+
})
|
|
36
|
+
.describe('Response data from command execution');
|
|
37
|
+
export const ExecuteResponseSchema = APIResponseSchema(ExecuteDataSchema);
|
|
38
|
+
/**
|
|
39
|
+
* Executes a command in an existing sandbox.
|
|
40
|
+
*
|
|
41
|
+
* @param client - The API client to use for the request
|
|
42
|
+
* @param params - Parameters including sandbox ID and execution options
|
|
43
|
+
* @returns The execution result including status and stream URLs
|
|
44
|
+
* @throws {SandboxResponseError} If the execution request fails
|
|
45
|
+
*/
|
|
46
|
+
export async function sandboxExecute(client, params) {
|
|
47
|
+
const { sandboxId, options, orgId, signal } = params;
|
|
48
|
+
const body = {
|
|
49
|
+
command: options.command,
|
|
50
|
+
};
|
|
51
|
+
if (options.files && options.files.length > 0) {
|
|
52
|
+
body.files = options.files.map((f) => ({
|
|
53
|
+
path: f.path,
|
|
54
|
+
content: f.content.toString('base64'),
|
|
55
|
+
}));
|
|
56
|
+
}
|
|
57
|
+
if (options.timeout) {
|
|
58
|
+
body.timeout = options.timeout;
|
|
59
|
+
}
|
|
60
|
+
if (options.stream) {
|
|
61
|
+
body.stream = options.stream;
|
|
62
|
+
}
|
|
63
|
+
const queryParams = new URLSearchParams();
|
|
64
|
+
if (orgId) {
|
|
65
|
+
queryParams.set('orgId', orgId);
|
|
66
|
+
}
|
|
67
|
+
const queryString = queryParams.toString();
|
|
68
|
+
const url = `/sandbox/${sandboxId}/execute${queryString ? `?${queryString}` : ''}`;
|
|
69
|
+
let resp;
|
|
70
|
+
try {
|
|
71
|
+
resp = await client.post(url, body, ExecuteResponseSchema, ExecuteRequestSchema, signal ?? options.signal);
|
|
72
|
+
}
|
|
73
|
+
catch (error) {
|
|
74
|
+
// Detect 409 Conflict (sandbox busy) and throw a specific error.
|
|
75
|
+
// The sandbox API client is configured with maxRetries: 0 to fail fast
|
|
76
|
+
// when sandbox is busy (retrying wouldn't help - sandbox is still busy).
|
|
77
|
+
// Convert APIErrorResponse with status 409 to SandboxBusyError for clarity.
|
|
78
|
+
if (error &&
|
|
79
|
+
typeof error === 'object' &&
|
|
80
|
+
'_tag' in error &&
|
|
81
|
+
error._tag === 'APIErrorResponse' &&
|
|
82
|
+
'status' in error &&
|
|
83
|
+
error.status === 409) {
|
|
84
|
+
throw new SandboxBusyError({
|
|
85
|
+
message: 'Sandbox is currently busy executing another command. Please wait for the current execution to complete before submitting a new one.',
|
|
86
|
+
sandboxId,
|
|
87
|
+
});
|
|
88
|
+
}
|
|
89
|
+
throw error;
|
|
90
|
+
}
|
|
91
|
+
if (resp.success) {
|
|
92
|
+
return {
|
|
93
|
+
executionId: resp.data.executionId,
|
|
94
|
+
status: resp.data.status,
|
|
95
|
+
exitCode: resp.data.exitCode,
|
|
96
|
+
durationMs: resp.data.durationMs,
|
|
97
|
+
stdoutStreamUrl: resp.data.stdoutStreamUrl,
|
|
98
|
+
stderrStreamUrl: resp.data.stderrStreamUrl,
|
|
99
|
+
};
|
|
100
|
+
}
|
|
101
|
+
throwSandboxError(resp, { sandboxId });
|
|
102
|
+
}
|
|
103
|
+
//# sourceMappingURL=execute.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"execute.js","sourceRoot":"","sources":["../../../src/api/sandbox/execute.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAkB,iBAAiB,EAAE,MAAM,WAAW,CAAC;AAC9D,OAAO,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,MAAM,WAAW,CAAC;AAEhE,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAAC;KACnC,MAAM,CAAC;IACP,OAAO,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,CAAC,kCAAkC,CAAC;IACzE,KAAK,EAAE,CAAC;SACN,KAAK,CACL,CAAC,CAAC,MAAM,CAAC;QACR,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,iCAAiC,CAAC;QAC5D,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ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od';
|
|
3
|
+
import { type APIClient } from '../api.ts';
|
|
4
|
+
export declare const ExecutionInfoSchema: z.ZodObject<{
|
|
5
|
+
executionId: z.ZodString;
|
|
6
|
+
sandboxId: z.ZodString;
|
|
7
|
+
type: z.ZodOptional<z.ZodString>;
|
|
8
|
+
status: z.ZodEnum<{
|
|
9
|
+
running: "running";
|
|
10
|
+
failed: "failed";
|
|
11
|
+
queued: "queued";
|
|
12
|
+
completed: "completed";
|
|
13
|
+
timeout: "timeout";
|
|
14
|
+
cancelled: "cancelled";
|
|
15
|
+
}>;
|
|
16
|
+
command: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
17
|
+
exitCode: z.ZodOptional<z.ZodNumber>;
|
|
18
|
+
durationMs: z.ZodOptional<z.ZodNumber>;
|
|
19
|
+
startedAt: z.ZodOptional<z.ZodString>;
|
|
20
|
+
completedAt: z.ZodOptional<z.ZodString>;
|
|
21
|
+
error: z.ZodOptional<z.ZodString>;
|
|
22
|
+
stdoutStreamUrl: z.ZodOptional<z.ZodString>;
|
|
23
|
+
stderrStreamUrl: z.ZodOptional<z.ZodString>;
|
|
24
|
+
}, z.core.$strip>;
|
|
25
|
+
export declare const ExecutionGetResponseSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
26
|
+
success: z.ZodLiteral<false>;
|
|
27
|
+
message: z.ZodString;
|
|
28
|
+
code: z.ZodOptional<z.ZodString>;
|
|
29
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
30
|
+
success: z.ZodLiteral<true>;
|
|
31
|
+
data: z.ZodObject<{
|
|
32
|
+
executionId: z.ZodString;
|
|
33
|
+
sandboxId: z.ZodString;
|
|
34
|
+
type: z.ZodOptional<z.ZodString>;
|
|
35
|
+
status: z.ZodEnum<{
|
|
36
|
+
running: "running";
|
|
37
|
+
failed: "failed";
|
|
38
|
+
queued: "queued";
|
|
39
|
+
completed: "completed";
|
|
40
|
+
timeout: "timeout";
|
|
41
|
+
cancelled: "cancelled";
|
|
42
|
+
}>;
|
|
43
|
+
command: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
44
|
+
exitCode: z.ZodOptional<z.ZodNumber>;
|
|
45
|
+
durationMs: z.ZodOptional<z.ZodNumber>;
|
|
46
|
+
startedAt: z.ZodOptional<z.ZodString>;
|
|
47
|
+
completedAt: z.ZodOptional<z.ZodString>;
|
|
48
|
+
error: z.ZodOptional<z.ZodString>;
|
|
49
|
+
stdoutStreamUrl: z.ZodOptional<z.ZodString>;
|
|
50
|
+
stderrStreamUrl: z.ZodOptional<z.ZodString>;
|
|
51
|
+
}, z.core.$strip>;
|
|
52
|
+
}, z.core.$strip>], "success">;
|
|
53
|
+
export declare const ExecutionListDataSchema: z.ZodObject<{
|
|
54
|
+
executions: z.ZodArray<z.ZodObject<{
|
|
55
|
+
executionId: z.ZodString;
|
|
56
|
+
sandboxId: z.ZodString;
|
|
57
|
+
type: z.ZodOptional<z.ZodString>;
|
|
58
|
+
status: z.ZodEnum<{
|
|
59
|
+
running: "running";
|
|
60
|
+
failed: "failed";
|
|
61
|
+
queued: "queued";
|
|
62
|
+
completed: "completed";
|
|
63
|
+
timeout: "timeout";
|
|
64
|
+
cancelled: "cancelled";
|
|
65
|
+
}>;
|
|
66
|
+
command: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
67
|
+
exitCode: z.ZodOptional<z.ZodNumber>;
|
|
68
|
+
durationMs: z.ZodOptional<z.ZodNumber>;
|
|
69
|
+
startedAt: z.ZodOptional<z.ZodString>;
|
|
70
|
+
completedAt: z.ZodOptional<z.ZodString>;
|
|
71
|
+
error: z.ZodOptional<z.ZodString>;
|
|
72
|
+
stdoutStreamUrl: z.ZodOptional<z.ZodString>;
|
|
73
|
+
stderrStreamUrl: z.ZodOptional<z.ZodString>;
|
|
74
|
+
}, z.core.$strip>>;
|
|
75
|
+
}, z.core.$strip>;
|
|
76
|
+
export declare const ExecutionListResponseSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
77
|
+
success: z.ZodLiteral<false>;
|
|
78
|
+
message: z.ZodString;
|
|
79
|
+
code: z.ZodOptional<z.ZodString>;
|
|
80
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
81
|
+
success: z.ZodLiteral<true>;
|
|
82
|
+
data: z.ZodObject<{
|
|
83
|
+
executions: z.ZodArray<z.ZodObject<{
|
|
84
|
+
executionId: z.ZodString;
|
|
85
|
+
sandboxId: z.ZodString;
|
|
86
|
+
type: z.ZodOptional<z.ZodString>;
|
|
87
|
+
status: z.ZodEnum<{
|
|
88
|
+
running: "running";
|
|
89
|
+
failed: "failed";
|
|
90
|
+
queued: "queued";
|
|
91
|
+
completed: "completed";
|
|
92
|
+
timeout: "timeout";
|
|
93
|
+
cancelled: "cancelled";
|
|
94
|
+
}>;
|
|
95
|
+
command: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
96
|
+
exitCode: z.ZodOptional<z.ZodNumber>;
|
|
97
|
+
durationMs: z.ZodOptional<z.ZodNumber>;
|
|
98
|
+
startedAt: z.ZodOptional<z.ZodString>;
|
|
99
|
+
completedAt: z.ZodOptional<z.ZodString>;
|
|
100
|
+
error: z.ZodOptional<z.ZodString>;
|
|
101
|
+
stdoutStreamUrl: z.ZodOptional<z.ZodString>;
|
|
102
|
+
stderrStreamUrl: z.ZodOptional<z.ZodString>;
|
|
103
|
+
}, z.core.$strip>>;
|
|
104
|
+
}, z.core.$strip>;
|
|
105
|
+
}, z.core.$strip>], "success">;
|
|
106
|
+
export interface ExecutionInfo {
|
|
107
|
+
executionId: string;
|
|
108
|
+
sandboxId: string;
|
|
109
|
+
type?: string;
|
|
110
|
+
status: ExecutionStatus;
|
|
111
|
+
command?: string[];
|
|
112
|
+
exitCode?: number;
|
|
113
|
+
durationMs?: number;
|
|
114
|
+
startedAt?: string;
|
|
115
|
+
completedAt?: string;
|
|
116
|
+
error?: string;
|
|
117
|
+
stdoutStreamUrl?: string;
|
|
118
|
+
stderrStreamUrl?: string;
|
|
119
|
+
}
|
|
120
|
+
export interface ExecutionGetParams {
|
|
121
|
+
executionId: string;
|
|
122
|
+
orgId?: string;
|
|
123
|
+
/**
|
|
124
|
+
* Optional wait duration for long-polling. If specified, the server will hold
|
|
125
|
+
* the connection open until the execution reaches a terminal state (completed,
|
|
126
|
+
* failed, timeout, cancelled) or the wait duration expires.
|
|
127
|
+
*
|
|
128
|
+
* Format: duration string like "30s", "1m", "5m"
|
|
129
|
+
* Maximum: 5 minutes (server will cap at this value)
|
|
130
|
+
*
|
|
131
|
+
* If not specified, returns immediately with current status.
|
|
132
|
+
*/
|
|
133
|
+
wait?: string;
|
|
134
|
+
}
|
|
135
|
+
/**
|
|
136
|
+
* Retrieves detailed information about a specific execution.
|
|
137
|
+
*
|
|
138
|
+
* @param client - The API client to use for the request
|
|
139
|
+
* @param params - Parameters including the execution ID and optional wait duration
|
|
140
|
+
* @returns Detailed execution information including status, timing, and errors
|
|
141
|
+
* @throws {SandboxResponseError} If the execution is not found or request fails
|
|
142
|
+
*
|
|
143
|
+
* @example
|
|
144
|
+
* // Immediate return (current behavior)
|
|
145
|
+
* const info = await executionGet(client, { executionId: 'exec_123' });
|
|
146
|
+
*
|
|
147
|
+
* @example
|
|
148
|
+
* // Long-poll: wait up to 60 seconds for completion
|
|
149
|
+
* const info = await executionGet(client, { executionId: 'exec_123', wait: '60s' });
|
|
150
|
+
*/
|
|
151
|
+
export declare function executionGet(client: APIClient, params: ExecutionGetParams): Promise<ExecutionInfo>;
|
|
152
|
+
export interface ExecutionListParams {
|
|
153
|
+
sandboxId: string;
|
|
154
|
+
orgId?: string;
|
|
155
|
+
limit?: number;
|
|
156
|
+
}
|
|
157
|
+
export interface ExecutionListResponse {
|
|
158
|
+
executions: ExecutionInfo[];
|
|
159
|
+
}
|
|
160
|
+
/**
|
|
161
|
+
* Lists all executions for a specific sandbox.
|
|
162
|
+
*
|
|
163
|
+
* @param client - The API client to use for the request
|
|
164
|
+
* @param params - Parameters including the sandbox ID and optional limit
|
|
165
|
+
* @returns List of execution information for the sandbox
|
|
166
|
+
* @throws {SandboxResponseError} If the sandbox is not found or request fails
|
|
167
|
+
*/
|
|
168
|
+
export declare function executionList(client: APIClient, params: ExecutionListParams): Promise<ExecutionListResponse>;
|
|
169
|
+
//# sourceMappingURL=execution.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"execution.d.ts","sourceRoot":"","sources":["../../../src/api/sandbox/execution.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AACjE,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,KAAK,SAAS,EAAqB,MAAM,WAAW,CAAC;AAG9D,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;iBAoB4B,CAAC;AAE7D,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;;;;;;;;;8BAAyC,CAAC;AAEjF,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;;iBAIU,CAAC;AAE/C,eAAO,MAAM,2BAA2B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8BAA6C,CAAC;AAEtF,MAAM,WAAW,aAAa;IAC7B,WAAW,EAAE,MAAM,CAAC;IACpB,SAAS,EAAE,MAAM,CAAC;IAClB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,eAAe,CAAC;IACxB,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,eAAe,CAAC,EAAE,MAAM,CAAC;CACzB;AAED,MAAM,WAAW,kBAAkB;IAClC,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;;;;;;;;OASG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;CACd;AAED;;;;;;;;;;;;;;;GAeG;AACH,wBAAsB,YAAY,CACjC,MAAM,EAAE,SAAS,EACjB,MAAM,EAAE,kBAAkB,GACxB,OAAO,CAAC,aAAa,CAAC,CAmCxB;AAED,MAAM,WAAW,mBAAmB;IACnC,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;CACf;AAED,MAAM,WAAW,qBAAqB;IACrC,UAAU,EAAE,aAAa,EAAE,CAAC;CAC5B;AAED;;;;;;;GAOG;AACH,wBAAsB,aAAa,CAClC,MAAM,EAAE,SAAS,EACjB,MAAM,EAAE,mBAAmB,GACzB,OAAO,CAAC,qBAAqB,CAAC,CAqChC"}
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { APIResponseSchema } from "../api.js";
|
|
3
|
+
import { throwSandboxError } from "./util.js";
|
|
4
|
+
export const ExecutionInfoSchema = z
|
|
5
|
+
.object({
|
|
6
|
+
executionId: z.string().describe('Unique identifier for the execution'),
|
|
7
|
+
sandboxId: z.string().describe('ID of the sandbox where the execution ran'),
|
|
8
|
+
type: z
|
|
9
|
+
.string()
|
|
10
|
+
.optional()
|
|
11
|
+
.describe('Type of execution (e.g., exec, write_files, read_file)'),
|
|
12
|
+
status: z
|
|
13
|
+
.enum(['queued', 'running', 'completed', 'failed', 'timeout', 'cancelled'])
|
|
14
|
+
.describe('Current status of the execution'),
|
|
15
|
+
command: z.array(z.string()).optional().describe('Command that was executed'),
|
|
16
|
+
exitCode: z.number().optional().describe('Exit code of the executed command'),
|
|
17
|
+
durationMs: z.number().optional().describe('Execution duration in milliseconds'),
|
|
18
|
+
startedAt: z.string().optional().describe('ISO timestamp when execution started'),
|
|
19
|
+
completedAt: z.string().optional().describe('ISO timestamp when execution completed'),
|
|
20
|
+
error: z.string().optional().describe('Error message if execution failed'),
|
|
21
|
+
stdoutStreamUrl: z.string().optional().describe('URL to stream stdout output'),
|
|
22
|
+
stderrStreamUrl: z.string().optional().describe('URL to stream stderr output'),
|
|
23
|
+
})
|
|
24
|
+
.describe('Detailed information about a command execution');
|
|
25
|
+
export const ExecutionGetResponseSchema = APIResponseSchema(ExecutionInfoSchema);
|
|
26
|
+
export const ExecutionListDataSchema = z
|
|
27
|
+
.object({
|
|
28
|
+
executions: z.array(ExecutionInfoSchema).describe('List of executions'),
|
|
29
|
+
})
|
|
30
|
+
.describe('List of executions for a sandbox');
|
|
31
|
+
export const ExecutionListResponseSchema = APIResponseSchema(ExecutionListDataSchema);
|
|
32
|
+
/**
|
|
33
|
+
* Retrieves detailed information about a specific execution.
|
|
34
|
+
*
|
|
35
|
+
* @param client - The API client to use for the request
|
|
36
|
+
* @param params - Parameters including the execution ID and optional wait duration
|
|
37
|
+
* @returns Detailed execution information including status, timing, and errors
|
|
38
|
+
* @throws {SandboxResponseError} If the execution is not found or request fails
|
|
39
|
+
*
|
|
40
|
+
* @example
|
|
41
|
+
* // Immediate return (current behavior)
|
|
42
|
+
* const info = await executionGet(client, { executionId: 'exec_123' });
|
|
43
|
+
*
|
|
44
|
+
* @example
|
|
45
|
+
* // Long-poll: wait up to 60 seconds for completion
|
|
46
|
+
* const info = await executionGet(client, { executionId: 'exec_123', wait: '60s' });
|
|
47
|
+
*/
|
|
48
|
+
export async function executionGet(client, params) {
|
|
49
|
+
const { executionId, orgId, wait } = params;
|
|
50
|
+
const queryParams = new URLSearchParams();
|
|
51
|
+
if (orgId) {
|
|
52
|
+
queryParams.set('orgId', orgId);
|
|
53
|
+
}
|
|
54
|
+
if (wait) {
|
|
55
|
+
queryParams.set('wait', wait);
|
|
56
|
+
}
|
|
57
|
+
const queryString = queryParams.toString();
|
|
58
|
+
const url = `/sandbox/execution/${executionId}${queryString ? `?${queryString}` : ''}`;
|
|
59
|
+
const resp = await client.get(url, ExecutionGetResponseSchema);
|
|
60
|
+
if (resp.success) {
|
|
61
|
+
return {
|
|
62
|
+
executionId: resp.data.executionId,
|
|
63
|
+
sandboxId: resp.data.sandboxId,
|
|
64
|
+
type: resp.data.type,
|
|
65
|
+
status: resp.data.status,
|
|
66
|
+
command: resp.data.command,
|
|
67
|
+
exitCode: resp.data.exitCode,
|
|
68
|
+
durationMs: resp.data.durationMs,
|
|
69
|
+
startedAt: resp.data.startedAt,
|
|
70
|
+
completedAt: resp.data.completedAt,
|
|
71
|
+
error: resp.data.error,
|
|
72
|
+
stdoutStreamUrl: resp.data.stdoutStreamUrl,
|
|
73
|
+
stderrStreamUrl: resp.data.stderrStreamUrl,
|
|
74
|
+
};
|
|
75
|
+
}
|
|
76
|
+
throwSandboxError(resp, { executionId });
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* Lists all executions for a specific sandbox.
|
|
80
|
+
*
|
|
81
|
+
* @param client - The API client to use for the request
|
|
82
|
+
* @param params - Parameters including the sandbox ID and optional limit
|
|
83
|
+
* @returns List of execution information for the sandbox
|
|
84
|
+
* @throws {SandboxResponseError} If the sandbox is not found or request fails
|
|
85
|
+
*/
|
|
86
|
+
export async function executionList(client, params) {
|
|
87
|
+
const { sandboxId, orgId, limit } = params;
|
|
88
|
+
const queryParams = new URLSearchParams();
|
|
89
|
+
if (orgId) {
|
|
90
|
+
queryParams.set('orgId', orgId);
|
|
91
|
+
}
|
|
92
|
+
if (limit !== undefined) {
|
|
93
|
+
queryParams.set('limit', String(limit));
|
|
94
|
+
}
|
|
95
|
+
const queryString = queryParams.toString();
|
|
96
|
+
const url = `/sandbox/sandboxes/${sandboxId}/executions${queryString ? `?${queryString}` : ''}`;
|
|
97
|
+
const resp = await client.get(url, ExecutionListResponseSchema);
|
|
98
|
+
if (resp.success) {
|
|
99
|
+
return {
|
|
100
|
+
executions: resp.data.executions.map((exec) => ({
|
|
101
|
+
executionId: exec.executionId,
|
|
102
|
+
sandboxId: exec.sandboxId,
|
|
103
|
+
type: exec.type,
|
|
104
|
+
status: exec.status,
|
|
105
|
+
command: exec.command,
|
|
106
|
+
exitCode: exec.exitCode,
|
|
107
|
+
durationMs: exec.durationMs,
|
|
108
|
+
startedAt: exec.startedAt,
|
|
109
|
+
completedAt: exec.completedAt,
|
|
110
|
+
error: exec.error,
|
|
111
|
+
stdoutStreamUrl: exec.stdoutStreamUrl,
|
|
112
|
+
stderrStreamUrl: exec.stderrStreamUrl,
|
|
113
|
+
})),
|
|
114
|
+
};
|
|
115
|
+
}
|
|
116
|
+
throwSandboxError(resp, { sandboxId });
|
|
117
|
+
}
|
|
118
|
+
//# sourceMappingURL=execution.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"execution.js","sourceRoot":"","sources":["../../../src/api/sandbox/execution.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAkB,iBAAiB,EAAE,MAAM,WAAW,CAAC;AAC9D,OAAO,EAAE,iBAAiB,EAAE,MAAM,WAAW,CAAC;AAE9C,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC;KAClC,MAAM,CAAC;IACP,WAAW,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,qCAAqC,CAAC;IACvE,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,2CAA2C,CAAC;IAC3E,IAAI,EAAE,CAAC;SACL,MAAM,EAAE;SACR,QAAQ,EAAE;SACV,QAAQ,CAAC,wDAAwD,CAAC;IACpE,MAAM,EAAE,CAAC;SACP,IAAI,CAAC,CAAC,QAAQ,EAAE,SAAS,EAAE,WAAW,EAAE,QAAQ,EAAE,SAAS,EAAE,WAAW,CAAC,CAAC;SAC1E,QAAQ,CAAC,iCAAiC,CAAC;IAC7C,OAAO,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CA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