@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,45 @@
|
|
|
1
|
+
export declare const BucketConfigResponseError: {
|
|
2
|
+
new (args?: {
|
|
3
|
+
message?: string;
|
|
4
|
+
cause?: unknown;
|
|
5
|
+
} | undefined): import("../../error.ts").RichError & {
|
|
6
|
+
readonly _tag: "BucketConfigResponseError";
|
|
7
|
+
} & Readonly<Record<string, never>>;
|
|
8
|
+
readonly defaultMessage?: string;
|
|
9
|
+
} & (<Shape extends {
|
|
10
|
+
[x: string]: any;
|
|
11
|
+
} = Record<string, never>>() => {
|
|
12
|
+
new (args?: (Shape extends Record<string, never> ? {
|
|
13
|
+
message?: string;
|
|
14
|
+
cause?: unknown;
|
|
15
|
+
} : Shape & {
|
|
16
|
+
message?: string;
|
|
17
|
+
cause?: unknown;
|
|
18
|
+
}) | undefined): import("../../error.ts").RichError & {
|
|
19
|
+
readonly _tag: "BucketConfigResponseError";
|
|
20
|
+
} & Readonly<Shape>;
|
|
21
|
+
readonly defaultMessage?: string;
|
|
22
|
+
});
|
|
23
|
+
export declare const StorageObjectsResponseError: {
|
|
24
|
+
new (args?: {
|
|
25
|
+
message?: string;
|
|
26
|
+
cause?: unknown;
|
|
27
|
+
} | undefined): import("../../error.ts").RichError & {
|
|
28
|
+
readonly _tag: "StorageObjectsResponseError";
|
|
29
|
+
} & Readonly<Record<string, never>>;
|
|
30
|
+
readonly defaultMessage?: string;
|
|
31
|
+
} & (<Shape extends {
|
|
32
|
+
[x: string]: any;
|
|
33
|
+
} = Record<string, never>>() => {
|
|
34
|
+
new (args?: (Shape extends Record<string, never> ? {
|
|
35
|
+
message?: string;
|
|
36
|
+
cause?: unknown;
|
|
37
|
+
} : Shape & {
|
|
38
|
+
message?: string;
|
|
39
|
+
cause?: unknown;
|
|
40
|
+
}) | undefined): import("../../error.ts").RichError & {
|
|
41
|
+
readonly _tag: "StorageObjectsResponseError";
|
|
42
|
+
} & Readonly<Shape>;
|
|
43
|
+
readonly defaultMessage?: string;
|
|
44
|
+
});
|
|
45
|
+
//# sourceMappingURL=util.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"util.d.ts","sourceRoot":"","sources":["../../../src/api/storage/util.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,yBAAyB;;;;;;;;;;;;;;;;;;;;;EAA+C,CAAC;AACtF,eAAO,MAAM,2BAA2B;;;;;;;;;;;;;;;;;;;;;EAAiD,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"util.js","sourceRoot":"","sources":["../../../src/api/storage/util.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAEjD,MAAM,CAAC,MAAM,yBAAyB,GAAG,eAAe,CAAC,2BAA2B,CAAC,CAAC;AACtF,MAAM,CAAC,MAAM,2BAA2B,GAAG,eAAe,CAAC,6BAA6B,CAAC,CAAC"}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { type APIClient } from '../api.ts';
|
|
3
|
+
export declare const StreamDetailSchema: z.ZodObject<{
|
|
4
|
+
id: z.ZodString;
|
|
5
|
+
namespace: z.ZodString;
|
|
6
|
+
metadata: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
7
|
+
url: z.ZodString;
|
|
8
|
+
sizeBytes: z.ZodNumber;
|
|
9
|
+
createdAt: z.ZodNullable<z.ZodString>;
|
|
10
|
+
updatedAt: z.ZodNullable<z.ZodString>;
|
|
11
|
+
startedAt: z.ZodNullable<z.ZodString>;
|
|
12
|
+
endedAt: z.ZodNullable<z.ZodString>;
|
|
13
|
+
expiresAt: z.ZodNullable<z.ZodString>;
|
|
14
|
+
orgId: z.ZodString;
|
|
15
|
+
projectId: z.ZodNullable<z.ZodString>;
|
|
16
|
+
completed: z.ZodBoolean;
|
|
17
|
+
headers: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
18
|
+
chunks: z.ZodNumber;
|
|
19
|
+
}, z.core.$strip>;
|
|
20
|
+
export declare const StreamDetailResponseSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
21
|
+
success: z.ZodLiteral<false>;
|
|
22
|
+
message: z.ZodString;
|
|
23
|
+
code: z.ZodOptional<z.ZodString>;
|
|
24
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
25
|
+
success: z.ZodLiteral<true>;
|
|
26
|
+
data: z.ZodObject<{
|
|
27
|
+
id: z.ZodString;
|
|
28
|
+
namespace: z.ZodString;
|
|
29
|
+
metadata: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
30
|
+
url: z.ZodString;
|
|
31
|
+
sizeBytes: z.ZodNumber;
|
|
32
|
+
createdAt: z.ZodNullable<z.ZodString>;
|
|
33
|
+
updatedAt: z.ZodNullable<z.ZodString>;
|
|
34
|
+
startedAt: z.ZodNullable<z.ZodString>;
|
|
35
|
+
endedAt: z.ZodNullable<z.ZodString>;
|
|
36
|
+
expiresAt: z.ZodNullable<z.ZodString>;
|
|
37
|
+
orgId: z.ZodString;
|
|
38
|
+
projectId: z.ZodNullable<z.ZodString>;
|
|
39
|
+
completed: z.ZodBoolean;
|
|
40
|
+
headers: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
41
|
+
chunks: z.ZodNumber;
|
|
42
|
+
}, z.core.$strip>;
|
|
43
|
+
}, z.core.$strip>], "success">;
|
|
44
|
+
export type StreamDetailResponse = z.infer<typeof StreamDetailResponseSchema>;
|
|
45
|
+
export type StreamDetail = z.infer<typeof StreamDetailSchema>;
|
|
46
|
+
/**
|
|
47
|
+
* Get a specific stream by ID.
|
|
48
|
+
*
|
|
49
|
+
* @param client - The API client
|
|
50
|
+
* @param id - The stream ID
|
|
51
|
+
* @returns A promise that resolves to the stream details
|
|
52
|
+
*
|
|
53
|
+
* @example
|
|
54
|
+
* const stream = await streamGet(client, 'stream_abc123');
|
|
55
|
+
* console.log(`Namespace: ${stream.namespace}, Size: ${stream.sizeBytes} bytes`);
|
|
56
|
+
*/
|
|
57
|
+
export declare function streamGet(client: APIClient, id: string): Promise<StreamDetail>;
|
|
58
|
+
//# sourceMappingURL=get.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get.d.ts","sourceRoot":"","sources":["../../../src/api/stream/get.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,KAAK,SAAS,EAAqB,MAAM,WAAW,CAAC;AAG9D,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;iBAgB7B,CAAC;AAEH,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;;;;;8BAAwC,CAAC;AAEhF,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,0BAA0B,CAAC,CAAC;AAC9E,MAAM,MAAM,YAAY,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC;AAE9D;;;;;;;;;;GAUG;AACH,wBAAsB,SAAS,CAAC,MAAM,EAAE,SAAS,EAAE,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,YAAY,CAAC,CAYpF"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { APIResponseSchema } from "../api.js";
|
|
3
|
+
import { StreamResponseError } from "./util.js";
|
|
4
|
+
export const StreamDetailSchema = z.object({
|
|
5
|
+
id: z.string().describe('the stream id'),
|
|
6
|
+
namespace: z.string().describe('the stream namespace'),
|
|
7
|
+
metadata: z.record(z.string(), z.string()).describe('stream metadata'),
|
|
8
|
+
url: z.string().describe('public URL to access the stream'),
|
|
9
|
+
sizeBytes: z.number().describe('size in bytes'),
|
|
10
|
+
createdAt: z.string().nullable().describe('ISO 8601 creation timestamp'),
|
|
11
|
+
updatedAt: z.string().nullable().describe('ISO 8601 last update timestamp'),
|
|
12
|
+
startedAt: z.string().nullable().describe('ISO 8601 stream start timestamp'),
|
|
13
|
+
endedAt: z.string().nullable().describe('ISO 8601 stream end timestamp'),
|
|
14
|
+
expiresAt: z.string().nullable().describe('ISO 8601 expiration timestamp or null'),
|
|
15
|
+
orgId: z.string().describe('the organization id'),
|
|
16
|
+
projectId: z.string().nullable().describe('the project id'),
|
|
17
|
+
completed: z.boolean().describe('whether the stream upload is completed'),
|
|
18
|
+
headers: z.record(z.string(), z.string()).describe('stream headers'),
|
|
19
|
+
chunks: z.number().describe('number of chunks'),
|
|
20
|
+
});
|
|
21
|
+
export const StreamDetailResponseSchema = APIResponseSchema(StreamDetailSchema);
|
|
22
|
+
/**
|
|
23
|
+
* Get a specific stream by ID.
|
|
24
|
+
*
|
|
25
|
+
* @param client - The API client
|
|
26
|
+
* @param id - The stream ID
|
|
27
|
+
* @returns A promise that resolves to the stream details
|
|
28
|
+
*
|
|
29
|
+
* @example
|
|
30
|
+
* const stream = await streamGet(client, 'stream_abc123');
|
|
31
|
+
* console.log(`Namespace: ${stream.namespace}, Size: ${stream.sizeBytes} bytes`);
|
|
32
|
+
*/
|
|
33
|
+
export async function streamGet(client, id) {
|
|
34
|
+
const resp = await client.request('GET', `/cli/stream/${encodeURIComponent(id)}`, StreamDetailResponseSchema);
|
|
35
|
+
if (resp.success) {
|
|
36
|
+
return resp.data;
|
|
37
|
+
}
|
|
38
|
+
throw new StreamResponseError({ message: resp.message });
|
|
39
|
+
}
|
|
40
|
+
//# sourceMappingURL=get.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get.js","sourceRoot":"","sources":["../../../src/api/stream/get.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAkB,iBAAiB,EAAE,MAAM,WAAW,CAAC;AAC9D,OAAO,EAAE,mBAAmB,EAAE,MAAM,WAAW,CAAC;AAEhD,MAAM,CAAC,MAAM,kBAAkB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC1C,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,eAAe,CAAC;IACxC,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,sBAAsB,CAAC;IACtD,QAAQ,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,CAAC,iBAAiB,CAAC;IACtE,GAAG,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,iCAAiC,CAAC;IAC3D,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,eAAe,CAAC;IAC/C,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,6BAA6B,CAAC;IACxE,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,gCAAgC,CAAC;IAC3E,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,iCAAiC,CAAC;IAC5E,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,+BAA+B,CAAC;IACxE,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,uCAAuC,CAAC;IAClF,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,qBAAqB,CAAC;IACjD,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,gBAAgB,CAAC;IAC3D,SAAS,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,CAAC,wCAAwC,CAAC;IACzE,OAAO,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,CAAC,gBAAgB,CAAC;IACpE,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,kBAAkB,CAAC;CAC/C,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,0BAA0B,GAAG,iBAAiB,CAAC,kBAAkB,CAAC,CAAC;AAKhF;;;;;;;;;;GAUG;AACH,MAAM,CAAC,KAAK,UAAU,SAAS,CAAC,MAAiB,EAAE,EAAU;IAC5D,MAAM,IAAI,GAAG,MAAM,MAAM,CAAC,OAAO,CAChC,KAAK,EACL,eAAe,kBAAkB,CAAC,EAAE,CAAC,EAAE,EACvC,0BAA0B,CAC1B,CAAC;IAEF,IAAI,IAAI,CAAC,OAAO,EAAE,CAAC;QAClB,OAAO,IAAI,CAAC,IAAI,CAAC;IAClB,CAAC;IAED,MAAM,IAAI,mBAAmB,CAAC,EAAE,OAAO,EAAE,IAAI,CAAC,OAAO,EAAE,CAAC,CAAC;AAC1D,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/api/stream/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,WAAW,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/api/stream/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,WAAW,CAAC"}
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
import type { SortDirection } from '../../services/pagination.ts';
|
|
2
|
+
import { z } from 'zod';
|
|
3
|
+
import { type APIClient } from '../api.ts';
|
|
4
|
+
export declare const StreamInfoSchema: z.ZodObject<{
|
|
5
|
+
id: z.ZodString;
|
|
6
|
+
namespace: z.ZodString;
|
|
7
|
+
metadata: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
8
|
+
url: z.ZodString;
|
|
9
|
+
sizeBytes: z.ZodNumber;
|
|
10
|
+
expiresAt: z.ZodNullable<z.ZodString>;
|
|
11
|
+
orgId: z.ZodString;
|
|
12
|
+
projectId: z.ZodNullable<z.ZodString>;
|
|
13
|
+
projectName: z.ZodNullable<z.ZodString>;
|
|
14
|
+
}, z.core.$strip>;
|
|
15
|
+
export declare const StreamListDataSchema: z.ZodObject<{
|
|
16
|
+
streams: z.ZodArray<z.ZodObject<{
|
|
17
|
+
id: z.ZodString;
|
|
18
|
+
namespace: z.ZodString;
|
|
19
|
+
metadata: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
20
|
+
url: z.ZodString;
|
|
21
|
+
sizeBytes: z.ZodNumber;
|
|
22
|
+
expiresAt: z.ZodNullable<z.ZodString>;
|
|
23
|
+
orgId: z.ZodString;
|
|
24
|
+
projectId: z.ZodNullable<z.ZodString>;
|
|
25
|
+
projectName: z.ZodNullable<z.ZodString>;
|
|
26
|
+
}, z.core.$strip>>;
|
|
27
|
+
total: z.ZodNumber;
|
|
28
|
+
}, z.core.$strip>;
|
|
29
|
+
export declare const StreamListResponseSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
30
|
+
success: z.ZodLiteral<false>;
|
|
31
|
+
message: z.ZodString;
|
|
32
|
+
code: z.ZodOptional<z.ZodString>;
|
|
33
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
34
|
+
success: z.ZodLiteral<true>;
|
|
35
|
+
data: z.ZodObject<{
|
|
36
|
+
streams: z.ZodArray<z.ZodObject<{
|
|
37
|
+
id: z.ZodString;
|
|
38
|
+
namespace: z.ZodString;
|
|
39
|
+
metadata: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
40
|
+
url: z.ZodString;
|
|
41
|
+
sizeBytes: z.ZodNumber;
|
|
42
|
+
expiresAt: z.ZodNullable<z.ZodString>;
|
|
43
|
+
orgId: z.ZodString;
|
|
44
|
+
projectId: z.ZodNullable<z.ZodString>;
|
|
45
|
+
projectName: z.ZodNullable<z.ZodString>;
|
|
46
|
+
}, z.core.$strip>>;
|
|
47
|
+
total: z.ZodNumber;
|
|
48
|
+
}, z.core.$strip>;
|
|
49
|
+
}, z.core.$strip>], "success">;
|
|
50
|
+
export type StreamListResponse = z.infer<typeof StreamListResponseSchema>;
|
|
51
|
+
export type StreamListData = z.infer<typeof StreamListDataSchema>;
|
|
52
|
+
export type StreamInfo = z.infer<typeof StreamInfoSchema>;
|
|
53
|
+
export interface StreamListOptions {
|
|
54
|
+
/**
|
|
55
|
+
* Filter by specific project ID
|
|
56
|
+
*/
|
|
57
|
+
projectId?: string;
|
|
58
|
+
/**
|
|
59
|
+
* Filter by specific organization ID
|
|
60
|
+
*/
|
|
61
|
+
orgId?: string;
|
|
62
|
+
/**
|
|
63
|
+
* Filter by stream namespace
|
|
64
|
+
*/
|
|
65
|
+
namespace?: string;
|
|
66
|
+
/**
|
|
67
|
+
* Filter by stream name
|
|
68
|
+
*/
|
|
69
|
+
name?: string;
|
|
70
|
+
/**
|
|
71
|
+
* Maximum number of streams to return (default: 100, max: 1000)
|
|
72
|
+
*/
|
|
73
|
+
limit?: number;
|
|
74
|
+
/**
|
|
75
|
+
* Number of streams to skip for pagination
|
|
76
|
+
*/
|
|
77
|
+
offset?: number;
|
|
78
|
+
/**
|
|
79
|
+
* Filter by metadata key-value pairs
|
|
80
|
+
*/
|
|
81
|
+
metadata?: Record<string, string>;
|
|
82
|
+
/**
|
|
83
|
+
* Field to sort by
|
|
84
|
+
*/
|
|
85
|
+
sort?: string;
|
|
86
|
+
/**
|
|
87
|
+
* Sort direction (default: 'desc')
|
|
88
|
+
*/
|
|
89
|
+
direction?: SortDirection;
|
|
90
|
+
}
|
|
91
|
+
/**
|
|
92
|
+
* List streams with optional filtering.
|
|
93
|
+
*
|
|
94
|
+
* If no projectId or orgId is provided, returns streams from all orgs the user is a member of.
|
|
95
|
+
*
|
|
96
|
+
* @param client - The API client
|
|
97
|
+
* @param options - Filtering and pagination options
|
|
98
|
+
* @returns A promise that resolves to the list of streams with metadata
|
|
99
|
+
*
|
|
100
|
+
* @example
|
|
101
|
+
* // List all streams across all orgs
|
|
102
|
+
* const result = await streamList(client);
|
|
103
|
+
* console.log(`Found ${result.total} streams`);
|
|
104
|
+
*
|
|
105
|
+
* @example
|
|
106
|
+
* // List streams for a specific project
|
|
107
|
+
* const result = await streamList(client, { projectId: 'proj_123' });
|
|
108
|
+
*
|
|
109
|
+
* @example
|
|
110
|
+
* // List streams with namespace filter
|
|
111
|
+
* const result = await streamList(client, { namespace: 'agent-logs' });
|
|
112
|
+
*
|
|
113
|
+
* @example
|
|
114
|
+
* // List streams with metadata filter
|
|
115
|
+
* const result = await streamList(client, {
|
|
116
|
+
* metadata: { type: 'export', env: 'production' }
|
|
117
|
+
* });
|
|
118
|
+
*/
|
|
119
|
+
export declare function streamList(client: APIClient, options?: StreamListOptions): Promise<StreamListData>;
|
|
120
|
+
//# sourceMappingURL=list.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"list.d.ts","sourceRoot":"","sources":["../../../src/api/stream/list.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,8BAA8B,CAAC;AAClE,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,KAAK,SAAS,EAAqB,MAAM,WAAW,CAAC;AAG9D,eAAO,MAAM,gBAAgB;;;;;;;;;;iBAU3B,CAAC;AAEH,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;iBAG/B,CAAC;AAEH,eAAO,MAAM,wBAAwB;;;;;;;;;;;;;;;;;;;;8BAA0C,CAAC;AAEhF,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAC1E,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAClE,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAE1D,MAAM,WAAW,iBAAiB;IACjC;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IACd;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAClC;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IACd;;OAEG;IACH,SAAS,CAAC,EAAE,aAAa,CAAC;CAC1B;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,wBAAsB,UAAU,CAC/B,MAAM,EAAE,SAAS,EACjB,OAAO,GAAE,iBAAsB,GAC7B,OAAO,CAAC,cAAc,CAAC,CA4BzB"}
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { APIResponseSchema } from "../api.js";
|
|
3
|
+
import { StreamResponseError } from "./util.js";
|
|
4
|
+
export const StreamInfoSchema = z.object({
|
|
5
|
+
id: z.string().describe('the stream id'),
|
|
6
|
+
namespace: z.string().describe('the stream namespace'),
|
|
7
|
+
metadata: z.record(z.string(), z.string()).describe('stream metadata'),
|
|
8
|
+
url: z.string().describe('public URL to access the stream'),
|
|
9
|
+
sizeBytes: z.number().describe('size in bytes'),
|
|
10
|
+
expiresAt: z.string().nullable().describe('ISO 8601 expiration timestamp or null'),
|
|
11
|
+
orgId: z.string().describe('the organization id'),
|
|
12
|
+
projectId: z.string().nullable().describe('the project id'),
|
|
13
|
+
projectName: z.string().nullable().describe('the project name'),
|
|
14
|
+
});
|
|
15
|
+
export const StreamListDataSchema = z.object({
|
|
16
|
+
streams: z.array(StreamInfoSchema).describe('list of streams'),
|
|
17
|
+
total: z.number().describe('total count of matching streams'),
|
|
18
|
+
});
|
|
19
|
+
export const StreamListResponseSchema = APIResponseSchema(StreamListDataSchema);
|
|
20
|
+
/**
|
|
21
|
+
* List streams with optional filtering.
|
|
22
|
+
*
|
|
23
|
+
* If no projectId or orgId is provided, returns streams from all orgs the user is a member of.
|
|
24
|
+
*
|
|
25
|
+
* @param client - The API client
|
|
26
|
+
* @param options - Filtering and pagination options
|
|
27
|
+
* @returns A promise that resolves to the list of streams with metadata
|
|
28
|
+
*
|
|
29
|
+
* @example
|
|
30
|
+
* // List all streams across all orgs
|
|
31
|
+
* const result = await streamList(client);
|
|
32
|
+
* console.log(`Found ${result.total} streams`);
|
|
33
|
+
*
|
|
34
|
+
* @example
|
|
35
|
+
* // List streams for a specific project
|
|
36
|
+
* const result = await streamList(client, { projectId: 'proj_123' });
|
|
37
|
+
*
|
|
38
|
+
* @example
|
|
39
|
+
* // List streams with namespace filter
|
|
40
|
+
* const result = await streamList(client, { namespace: 'agent-logs' });
|
|
41
|
+
*
|
|
42
|
+
* @example
|
|
43
|
+
* // List streams with metadata filter
|
|
44
|
+
* const result = await streamList(client, {
|
|
45
|
+
* metadata: { type: 'export', env: 'production' }
|
|
46
|
+
* });
|
|
47
|
+
*/
|
|
48
|
+
export async function streamList(client, options = {}) {
|
|
49
|
+
const { projectId, orgId, namespace, name, limit, offset, metadata } = options;
|
|
50
|
+
const params = new URLSearchParams();
|
|
51
|
+
if (projectId)
|
|
52
|
+
params.set('projectId', projectId);
|
|
53
|
+
if (orgId)
|
|
54
|
+
params.set('orgId', orgId);
|
|
55
|
+
if (namespace)
|
|
56
|
+
params.set('namespace', namespace);
|
|
57
|
+
if (name)
|
|
58
|
+
params.set('name', name);
|
|
59
|
+
if (limit !== undefined)
|
|
60
|
+
params.set('limit', limit.toString());
|
|
61
|
+
if (offset !== undefined)
|
|
62
|
+
params.set('offset', offset.toString());
|
|
63
|
+
if (metadata && Object.keys(metadata).length > 0) {
|
|
64
|
+
params.set('metadata', JSON.stringify(metadata));
|
|
65
|
+
}
|
|
66
|
+
if (options.sort)
|
|
67
|
+
params.set('sort', options.sort);
|
|
68
|
+
if (options.direction)
|
|
69
|
+
params.set('direction', options.direction);
|
|
70
|
+
const queryString = params.toString();
|
|
71
|
+
const resp = await client.request('GET', `/cli/stream${queryString ? `?${queryString}` : ''}`, StreamListResponseSchema);
|
|
72
|
+
if (resp.success) {
|
|
73
|
+
return resp.data;
|
|
74
|
+
}
|
|
75
|
+
throw new StreamResponseError({ message: resp.message });
|
|
76
|
+
}
|
|
77
|
+
//# sourceMappingURL=list.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"list.js","sourceRoot":"","sources":["../../../src/api/stream/list.ts"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export declare const StreamResponseError: {
|
|
2
|
+
new (args?: {
|
|
3
|
+
message?: string;
|
|
4
|
+
cause?: unknown;
|
|
5
|
+
} | undefined): import("../../error.ts").RichError & {
|
|
6
|
+
readonly _tag: "StreamResponseError";
|
|
7
|
+
} & Readonly<Record<string, never>>;
|
|
8
|
+
readonly defaultMessage?: string;
|
|
9
|
+
} & (<Shape extends {
|
|
10
|
+
[x: string]: any;
|
|
11
|
+
} = Record<string, never>>() => {
|
|
12
|
+
new (args?: (Shape extends Record<string, never> ? {
|
|
13
|
+
message?: string;
|
|
14
|
+
cause?: unknown;
|
|
15
|
+
} : Shape & {
|
|
16
|
+
message?: string;
|
|
17
|
+
cause?: unknown;
|
|
18
|
+
}) | undefined): import("../../error.ts").RichError & {
|
|
19
|
+
readonly _tag: "StreamResponseError";
|
|
20
|
+
} & Readonly<Shape>;
|
|
21
|
+
readonly defaultMessage?: string;
|
|
22
|
+
});
|
|
23
|
+
//# sourceMappingURL=util.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"util.d.ts","sourceRoot":"","sources":["../../../src/api/stream/util.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;EAAyC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"util.js","sourceRoot":"","sources":["../../../src/api/stream/util.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAEjD,MAAM,CAAC,MAAM,mBAAmB,GAAG,eAAe,CAAC,qBAAqB,CAAC,CAAC"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { APIClient } from '../api.ts';
|
|
3
|
+
export declare const _ThreadDeleteRequestSchema: z.ZodObject<{
|
|
4
|
+
id: z.ZodString;
|
|
5
|
+
}, z.core.$strip>;
|
|
6
|
+
export declare const ThreadDeleteResponseSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
7
|
+
success: z.ZodLiteral<false>;
|
|
8
|
+
message: z.ZodString;
|
|
9
|
+
code: z.ZodOptional<z.ZodString>;
|
|
10
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
11
|
+
success: z.ZodLiteral<true>;
|
|
12
|
+
}, z.core.$strip>], "success">;
|
|
13
|
+
export type ThreadDeleteRequest = z.infer<typeof _ThreadDeleteRequestSchema>;
|
|
14
|
+
export type ThreadDeleteResponse = z.infer<typeof ThreadDeleteResponseSchema>;
|
|
15
|
+
/**
|
|
16
|
+
* Delete a thread by id
|
|
17
|
+
*
|
|
18
|
+
* @param client
|
|
19
|
+
* @param request
|
|
20
|
+
* @returns
|
|
21
|
+
*/
|
|
22
|
+
export declare function threadDelete(client: APIClient, request: ThreadDeleteRequest): Promise<void>;
|
|
23
|
+
//# sourceMappingURL=delete.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"delete.d.ts","sourceRoot":"","sources":["../../../src/api/thread/delete.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,SAAS,EAA2B,MAAM,WAAW,CAAC;AAG/D,eAAO,MAAM,0BAA0B;;iBAErC,CAAC;AAEH,eAAO,MAAM,0BAA0B;;;;;;8BAA4B,CAAC;AAEpE,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,0BAA0B,CAAC,CAAC;AAC7E,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,0BAA0B,CAAC,CAAC;AAE9E;;;;;;GAMG;AACH,wBAAsB,YAAY,CAAC,MAAM,EAAE,SAAS,EAAE,OAAO,EAAE,mBAAmB,GAAG,OAAO,CAAC,IAAI,CAAC,CAUjG"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { APIResponseSchemaNoData } from "../api.js";
|
|
3
|
+
import { ThreadResponseError } from "./util.js";
|
|
4
|
+
export const _ThreadDeleteRequestSchema = z.object({
|
|
5
|
+
id: z.string().describe('the thread id'),
|
|
6
|
+
});
|
|
7
|
+
export const ThreadDeleteResponseSchema = APIResponseSchemaNoData();
|
|
8
|
+
/**
|
|
9
|
+
* Delete a thread by id
|
|
10
|
+
*
|
|
11
|
+
* @param client
|
|
12
|
+
* @param request
|
|
13
|
+
* @returns
|
|
14
|
+
*/
|
|
15
|
+
export async function threadDelete(client, request) {
|
|
16
|
+
const resp = await client.request('DELETE', `/thread/${request.id}`, ThreadDeleteResponseSchema);
|
|
17
|
+
if (!resp.success) {
|
|
18
|
+
throw new ThreadResponseError({ message: resp.message });
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
//# sourceMappingURL=delete.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"delete.js","sourceRoot":"","sources":["../../../src/api/thread/delete.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAa,uBAAuB,EAAE,MAAM,WAAW,CAAC;AAC/D,OAAO,EAAE,mBAAmB,EAAE,MAAM,WAAW,CAAC;AAEhD,MAAM,CAAC,MAAM,0BAA0B,GAAG,CAAC,CAAC,MAAM,CAAC;IAClD,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,eAAe,CAAC;CACxC,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,0BAA0B,GAAG,uBAAuB,EAAE,CAAC;AAKpE;;;;;;GAMG;AACH,MAAM,CAAC,KAAK,UAAU,YAAY,CAAC,MAAiB,EAAE,OAA4B;IACjF,MAAM,IAAI,GAAG,MAAM,MAAM,CAAC,OAAO,CAChC,QAAQ,EACR,WAAW,OAAO,CAAC,EAAE,EAAE,EACvB,0BAA0B,CAC1B,CAAC;IAEF,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE,CAAC;QACnB,MAAM,IAAI,mBAAmB,CAAC,EAAE,OAAO,EAAE,IAAI,CAAC,OAAO,EAAE,CAAC,CAAC;IAC1D,CAAC;AACF,CAAC"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { APIClient } from '../api.ts';
|
|
3
|
+
import { type Thread } from './list.ts';
|
|
4
|
+
export declare const _ThreadGetRequestSchema: z.ZodObject<{
|
|
5
|
+
id: z.ZodString;
|
|
6
|
+
}, z.core.$strip>;
|
|
7
|
+
export declare const ThreadGetResponseSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
8
|
+
success: z.ZodLiteral<false>;
|
|
9
|
+
message: z.ZodString;
|
|
10
|
+
code: z.ZodOptional<z.ZodString>;
|
|
11
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
12
|
+
success: z.ZodLiteral<true>;
|
|
13
|
+
data: z.ZodObject<{
|
|
14
|
+
id: z.ZodString;
|
|
15
|
+
created_at: z.ZodString;
|
|
16
|
+
updated_at: z.ZodString;
|
|
17
|
+
deleted: z.ZodBoolean;
|
|
18
|
+
deleted_at: z.ZodNullable<z.ZodString>;
|
|
19
|
+
deleted_by: z.ZodNullable<z.ZodString>;
|
|
20
|
+
org_id: z.ZodString;
|
|
21
|
+
project_id: z.ZodString;
|
|
22
|
+
user_data: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
23
|
+
metadata: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
24
|
+
}, z.core.$strip>;
|
|
25
|
+
}, z.core.$strip>], "success">;
|
|
26
|
+
export type ThreadGetRequest = z.infer<typeof _ThreadGetRequestSchema>;
|
|
27
|
+
export type ThreadGetResponse = z.infer<typeof ThreadGetResponseSchema>;
|
|
28
|
+
/**
|
|
29
|
+
* Get a single thread by id
|
|
30
|
+
*
|
|
31
|
+
* @param client
|
|
32
|
+
* @param request
|
|
33
|
+
* @returns
|
|
34
|
+
*/
|
|
35
|
+
export declare function threadGet(client: APIClient, request: ThreadGetRequest): Promise<Thread>;
|
|
36
|
+
//# sourceMappingURL=get.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get.d.ts","sourceRoot":"","sources":["../../../src/api/thread/get.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,SAAS,EAAqB,MAAM,WAAW,CAAC;AACzD,OAAO,EAAgB,KAAK,MAAM,EAAE,MAAM,WAAW,CAAC;AAGtD,eAAO,MAAM,uBAAuB;;iBAElC,CAAC;AAEH,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;8BAAkC,CAAC;AAEvE,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AACvE,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAExE;;;;;;GAMG;AACH,wBAAsB,SAAS,CAAC,MAAM,EAAE,SAAS,EAAE,OAAO,EAAE,gBAAgB,GAAG,OAAO,CAAC,MAAM,CAAC,CAY7F"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { APIResponseSchema } from "../api.js";
|
|
3
|
+
import { ThreadSchema } from "./list.js";
|
|
4
|
+
import { ThreadResponseError } from "./util.js";
|
|
5
|
+
export const _ThreadGetRequestSchema = z.object({
|
|
6
|
+
id: z.string().describe('the thread id'),
|
|
7
|
+
});
|
|
8
|
+
export const ThreadGetResponseSchema = APIResponseSchema(ThreadSchema);
|
|
9
|
+
/**
|
|
10
|
+
* Get a single thread by id
|
|
11
|
+
*
|
|
12
|
+
* @param client
|
|
13
|
+
* @param request
|
|
14
|
+
* @returns
|
|
15
|
+
*/
|
|
16
|
+
export async function threadGet(client, request) {
|
|
17
|
+
const resp = await client.request('GET', `/thread/${encodeURIComponent(request.id)}`, ThreadGetResponseSchema);
|
|
18
|
+
if (resp.success) {
|
|
19
|
+
return resp.data;
|
|
20
|
+
}
|
|
21
|
+
throw new ThreadResponseError({ message: resp.message });
|
|
22
|
+
}
|
|
23
|
+
//# sourceMappingURL=get.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get.js","sourceRoot":"","sources":["../../../src/api/thread/get.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAa,iBAAiB,EAAE,MAAM,WAAW,CAAC;AACzD,OAAO,EAAE,YAAY,EAAe,MAAM,WAAW,CAAC;AACtD,OAAO,EAAE,mBAAmB,EAAE,MAAM,WAAW,CAAC;AAEhD,MAAM,CAAC,MAAM,uBAAuB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC/C,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,eAAe,CAAC;CACxC,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,uBAAuB,GAAG,iBAAiB,CAAC,YAAY,CAAC,CAAC;AAKvE;;;;;;GAMG;AACH,MAAM,CAAC,KAAK,UAAU,SAAS,CAAC,MAAiB,EAAE,OAAyB;IAC3E,MAAM,IAAI,GAAG,MAAM,MAAM,CAAC,OAAO,CAChC,KAAK,EACL,WAAW,kBAAkB,CAAC,OAAO,CAAC,EAAE,CAAC,EAAE,EAC3C,uBAAuB,CACvB,CAAC;IAEF,IAAI,IAAI,CAAC,OAAO,EAAE,CAAC;QAClB,OAAO,IAAI,CAAC,IAAI,CAAC;IAClB,CAAC;IAED,MAAM,IAAI,mBAAmB,CAAC,EAAE,OAAO,EAAE,IAAI,CAAC,OAAO,EAAE,CAAC,CAAC;AAC1D,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/api/thread/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,WAAW,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/api/thread/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,WAAW,CAAC"}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import type { SortDirection } from '../../services/pagination.ts';
|
|
2
|
+
import { z } from 'zod';
|
|
3
|
+
import { APIClient } from '../api.ts';
|
|
4
|
+
export declare const ThreadSchema: z.ZodObject<{
|
|
5
|
+
id: z.ZodString;
|
|
6
|
+
created_at: z.ZodString;
|
|
7
|
+
updated_at: z.ZodString;
|
|
8
|
+
deleted: z.ZodBoolean;
|
|
9
|
+
deleted_at: z.ZodNullable<z.ZodString>;
|
|
10
|
+
deleted_by: z.ZodNullable<z.ZodString>;
|
|
11
|
+
org_id: z.ZodString;
|
|
12
|
+
project_id: z.ZodString;
|
|
13
|
+
user_data: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
14
|
+
metadata: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
15
|
+
}, z.core.$strip>;
|
|
16
|
+
export declare const ThreadListResponseData: z.ZodArray<z.ZodObject<{
|
|
17
|
+
id: z.ZodString;
|
|
18
|
+
created_at: z.ZodString;
|
|
19
|
+
updated_at: z.ZodString;
|
|
20
|
+
deleted: z.ZodBoolean;
|
|
21
|
+
deleted_at: z.ZodNullable<z.ZodString>;
|
|
22
|
+
deleted_by: z.ZodNullable<z.ZodString>;
|
|
23
|
+
org_id: z.ZodString;
|
|
24
|
+
project_id: z.ZodString;
|
|
25
|
+
user_data: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
26
|
+
metadata: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
27
|
+
}, z.core.$strip>>;
|
|
28
|
+
export declare const ThreadListResponseSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
29
|
+
success: z.ZodLiteral<false>;
|
|
30
|
+
message: z.ZodString;
|
|
31
|
+
code: z.ZodOptional<z.ZodString>;
|
|
32
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
33
|
+
success: z.ZodLiteral<true>;
|
|
34
|
+
data: z.ZodArray<z.ZodObject<{
|
|
35
|
+
id: z.ZodString;
|
|
36
|
+
created_at: z.ZodString;
|
|
37
|
+
updated_at: z.ZodString;
|
|
38
|
+
deleted: z.ZodBoolean;
|
|
39
|
+
deleted_at: z.ZodNullable<z.ZodString>;
|
|
40
|
+
deleted_by: z.ZodNullable<z.ZodString>;
|
|
41
|
+
org_id: z.ZodString;
|
|
42
|
+
project_id: z.ZodString;
|
|
43
|
+
user_data: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
44
|
+
metadata: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
45
|
+
}, z.core.$strip>>;
|
|
46
|
+
}, z.core.$strip>], "success">;
|
|
47
|
+
export type ThreadListResponse = z.infer<typeof ThreadListResponseSchema>;
|
|
48
|
+
export type ThreadList = z.infer<typeof ThreadListResponseData>;
|
|
49
|
+
export type Thread = z.infer<typeof ThreadSchema>;
|
|
50
|
+
export type ThreadSortField = 'created' | 'updated';
|
|
51
|
+
export interface ThreadListOptions {
|
|
52
|
+
count?: number;
|
|
53
|
+
limit?: number;
|
|
54
|
+
offset?: number;
|
|
55
|
+
sort?: ThreadSortField;
|
|
56
|
+
direction?: SortDirection;
|
|
57
|
+
orgId?: string;
|
|
58
|
+
projectId?: string;
|
|
59
|
+
metadata?: Record<string, unknown>;
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* List threads
|
|
63
|
+
*
|
|
64
|
+
* @param client
|
|
65
|
+
* @param options filtering and pagination options
|
|
66
|
+
* @returns
|
|
67
|
+
*/
|
|
68
|
+
export declare function threadList(client: APIClient, options?: ThreadListOptions): Promise<ThreadList>;
|
|
69
|
+
//# sourceMappingURL=list.d.ts.map
|