mongo.do 0.1.0 → 0.1.1
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/cli/index.d.ts +1 -15
- package/dist/cli/index.js +4083 -196
- package/dist/cli/index.js.map +1 -1
- package/dist/index.d.ts +2740 -20
- package/dist/index.js +9375 -27
- package/dist/index.js.map +1 -1
- package/dist/worker-entrypoint-BEW23Gmp.d.ts +1331 -0
- package/dist/worker.d.ts +6 -5
- package/dist/worker.js +5477 -18
- package/dist/worker.js.map +1 -1
- package/package.json +3 -2
- package/dist/agentfs/adapters/anthropic.d.ts +0 -176
- package/dist/agentfs/adapters/anthropic.d.ts.map +0 -1
- package/dist/agentfs/adapters/anthropic.js +0 -629
- package/dist/agentfs/adapters/anthropic.js.map +0 -1
- package/dist/agentfs/adapters/index.d.ts +0 -21
- package/dist/agentfs/adapters/index.d.ts.map +0 -1
- package/dist/agentfs/adapters/index.js +0 -23
- package/dist/agentfs/adapters/index.js.map +0 -1
- package/dist/agentfs/adapters/vercel.d.ts +0 -260
- package/dist/agentfs/adapters/vercel.d.ts.map +0 -1
- package/dist/agentfs/adapters/vercel.js +0 -288
- package/dist/agentfs/adapters/vercel.js.map +0 -1
- package/dist/agentfs/glob.d.ts +0 -116
- package/dist/agentfs/glob.d.ts.map +0 -1
- package/dist/agentfs/glob.js +0 -270
- package/dist/agentfs/glob.js.map +0 -1
- package/dist/agentfs/grep.d.ts +0 -83
- package/dist/agentfs/grep.d.ts.map +0 -1
- package/dist/agentfs/grep.js +0 -193
- package/dist/agentfs/grep.js.map +0 -1
- package/dist/agentfs/index.d.ts +0 -22
- package/dist/agentfs/index.d.ts.map +0 -1
- package/dist/agentfs/index.js +0 -18
- package/dist/agentfs/index.js.map +0 -1
- package/dist/agentfs/kv-store.d.ts +0 -128
- package/dist/agentfs/kv-store.d.ts.map +0 -1
- package/dist/agentfs/kv-store.js +0 -227
- package/dist/agentfs/kv-store.js.map +0 -1
- package/dist/agentfs/mondo-agent.d.ts +0 -255
- package/dist/agentfs/mondo-agent.d.ts.map +0 -1
- package/dist/agentfs/mondo-agent.js +0 -879
- package/dist/agentfs/mondo-agent.js.map +0 -1
- package/dist/agentfs/toolcalls.d.ts +0 -130
- package/dist/agentfs/toolcalls.d.ts.map +0 -1
- package/dist/agentfs/toolcalls.js +0 -178
- package/dist/agentfs/toolcalls.js.map +0 -1
- package/dist/agentfs/types.d.ts +0 -171
- package/dist/agentfs/types.d.ts.map +0 -1
- package/dist/agentfs/types.js +0 -7
- package/dist/agentfs/types.js.map +0 -1
- package/dist/agentfs/vfs.d.ts +0 -249
- package/dist/agentfs/vfs.d.ts.map +0 -1
- package/dist/agentfs/vfs.js +0 -469
- package/dist/agentfs/vfs.js.map +0 -1
- package/dist/cli/index.d.ts.map +0 -1
- package/dist/cli/mcp.d.ts +0 -119
- package/dist/cli/mcp.d.ts.map +0 -1
- package/dist/cli/mcp.js +0 -418
- package/dist/cli/mcp.js.map +0 -1
- package/dist/cli/server.d.ts +0 -179
- package/dist/cli/server.d.ts.map +0 -1
- package/dist/cli/server.js +0 -441
- package/dist/cli/server.js.map +0 -1
- package/dist/client/Collection.d.ts +0 -199
- package/dist/client/Collection.d.ts.map +0 -1
- package/dist/client/Collection.js +0 -256
- package/dist/client/Collection.js.map +0 -1
- package/dist/client/Database.d.ts +0 -68
- package/dist/client/Database.d.ts.map +0 -1
- package/dist/client/Database.js +0 -105
- package/dist/client/Database.js.map +0 -1
- package/dist/client/MongoClient.d.ts +0 -165
- package/dist/client/MongoClient.d.ts.map +0 -1
- package/dist/client/MongoClient.js +0 -307
- package/dist/client/MongoClient.js.map +0 -1
- package/dist/client/aggregation-cursor.d.ts +0 -210
- package/dist/client/aggregation-cursor.d.ts.map +0 -1
- package/dist/client/aggregation-cursor.js +0 -509
- package/dist/client/aggregation-cursor.js.map +0 -1
- package/dist/client/bulk-write.d.ts +0 -216
- package/dist/client/bulk-write.d.ts.map +0 -1
- package/dist/client/bulk-write.js +0 -63
- package/dist/client/bulk-write.js.map +0 -1
- package/dist/client/change-stream.d.ts +0 -245
- package/dist/client/change-stream.d.ts.map +0 -1
- package/dist/client/change-stream.js +0 -429
- package/dist/client/change-stream.js.map +0 -1
- package/dist/client/cursor.d.ts +0 -85
- package/dist/client/cursor.d.ts.map +0 -1
- package/dist/client/cursor.js +0 -156
- package/dist/client/cursor.js.map +0 -1
- package/dist/client/http-cursor.d.ts +0 -233
- package/dist/client/http-cursor.d.ts.map +0 -1
- package/dist/client/http-cursor.js +0 -496
- package/dist/client/http-cursor.js.map +0 -1
- package/dist/client/index.d.ts +0 -18
- package/dist/client/index.d.ts.map +0 -1
- package/dist/client/index.js +0 -24
- package/dist/client/index.js.map +0 -1
- package/dist/client/mongo-client.d.ts +0 -60
- package/dist/client/mongo-client.d.ts.map +0 -1
- package/dist/client/mongo-client.js +0 -190
- package/dist/client/mongo-client.js.map +0 -1
- package/dist/client/mongo-collection.d.ts +0 -359
- package/dist/client/mongo-collection.d.ts.map +0 -1
- package/dist/client/mongo-collection.js +0 -1641
- package/dist/client/mongo-collection.js.map +0 -1
- package/dist/client/mongo-cursor.d.ts +0 -257
- package/dist/client/mongo-cursor.d.ts.map +0 -1
- package/dist/client/mongo-cursor.js +0 -621
- package/dist/client/mongo-cursor.js.map +0 -1
- package/dist/client/mongo-database.d.ts +0 -88
- package/dist/client/mongo-database.d.ts.map +0 -1
- package/dist/client/mongo-database.js +0 -139
- package/dist/client/mongo-database.js.map +0 -1
- package/dist/client/session.d.ts +0 -210
- package/dist/client/session.d.ts.map +0 -1
- package/dist/client/session.js +0 -326
- package/dist/client/session.js.map +0 -1
- package/dist/durable-object/index-manager.d.ts +0 -173
- package/dist/durable-object/index-manager.d.ts.map +0 -1
- package/dist/durable-object/index-manager.js +0 -764
- package/dist/durable-object/index-manager.js.map +0 -1
- package/dist/durable-object/index.d.ts +0 -12
- package/dist/durable-object/index.d.ts.map +0 -1
- package/dist/durable-object/index.js +0 -8
- package/dist/durable-object/index.js.map +0 -1
- package/dist/durable-object/mcp-handler.d.ts +0 -52
- package/dist/durable-object/mcp-handler.d.ts.map +0 -1
- package/dist/durable-object/mcp-handler.js +0 -186
- package/dist/durable-object/mcp-handler.js.map +0 -1
- package/dist/durable-object/migrations.d.ts +0 -40
- package/dist/durable-object/migrations.d.ts.map +0 -1
- package/dist/durable-object/migrations.js +0 -121
- package/dist/durable-object/migrations.js.map +0 -1
- package/dist/durable-object/mondo-database.d.ts +0 -148
- package/dist/durable-object/mondo-database.d.ts.map +0 -1
- package/dist/durable-object/mondo-database.js +0 -621
- package/dist/durable-object/mondo-database.js.map +0 -1
- package/dist/durable-object/schema.d.ts +0 -192
- package/dist/durable-object/schema.d.ts.map +0 -1
- package/dist/durable-object/schema.js +0 -186
- package/dist/durable-object/schema.js.map +0 -1
- package/dist/embedding/document-serializer.d.ts +0 -118
- package/dist/embedding/document-serializer.d.ts.map +0 -1
- package/dist/embedding/document-serializer.js +0 -339
- package/dist/embedding/document-serializer.js.map +0 -1
- package/dist/embedding/embedding-manager.d.ts +0 -136
- package/dist/embedding/embedding-manager.d.ts.map +0 -1
- package/dist/embedding/embedding-manager.js +0 -176
- package/dist/embedding/embedding-manager.js.map +0 -1
- package/dist/embedding/index.d.ts +0 -9
- package/dist/embedding/index.d.ts.map +0 -1
- package/dist/embedding/index.js +0 -9
- package/dist/embedding/index.js.map +0 -1
- package/dist/executor/aggregation-executor.d.ts +0 -93
- package/dist/executor/aggregation-executor.d.ts.map +0 -1
- package/dist/executor/aggregation-executor.js +0 -275
- package/dist/executor/aggregation-executor.js.map +0 -1
- package/dist/executor/function-executor.d.ts +0 -39
- package/dist/executor/function-executor.d.ts.map +0 -1
- package/dist/executor/function-executor.js +0 -168
- package/dist/executor/function-executor.js.map +0 -1
- package/dist/executor/index.d.ts +0 -4
- package/dist/executor/index.d.ts.map +0 -1
- package/dist/executor/index.js +0 -4
- package/dist/executor/index.js.map +0 -1
- package/dist/executor/vector-search-executor.d.ts +0 -71
- package/dist/executor/vector-search-executor.d.ts.map +0 -1
- package/dist/executor/vector-search-executor.js +0 -113
- package/dist/executor/vector-search-executor.js.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/mcp/adapters/anthropic-adapter.d.ts +0 -256
- package/dist/mcp/adapters/anthropic-adapter.d.ts.map +0 -1
- package/dist/mcp/adapters/anthropic-adapter.js +0 -409
- package/dist/mcp/adapters/anthropic-adapter.js.map +0 -1
- package/dist/mcp/adapters/base-adapter.d.ts +0 -164
- package/dist/mcp/adapters/base-adapter.d.ts.map +0 -1
- package/dist/mcp/adapters/base-adapter.js +0 -277
- package/dist/mcp/adapters/base-adapter.js.map +0 -1
- package/dist/mcp/adapters/errors.d.ts +0 -173
- package/dist/mcp/adapters/errors.d.ts.map +0 -1
- package/dist/mcp/adapters/errors.js +0 -305
- package/dist/mcp/adapters/errors.js.map +0 -1
- package/dist/mcp/adapters/index.d.ts +0 -65
- package/dist/mcp/adapters/index.d.ts.map +0 -1
- package/dist/mcp/adapters/index.js +0 -92
- package/dist/mcp/adapters/index.js.map +0 -1
- package/dist/mcp/adapters/streaming.d.ts +0 -200
- package/dist/mcp/adapters/streaming.d.ts.map +0 -1
- package/dist/mcp/adapters/streaming.js +0 -381
- package/dist/mcp/adapters/streaming.js.map +0 -1
- package/dist/mcp/adapters/vercel-adapter.d.ts +0 -321
- package/dist/mcp/adapters/vercel-adapter.d.ts.map +0 -1
- package/dist/mcp/adapters/vercel-adapter.js +0 -487
- package/dist/mcp/adapters/vercel-adapter.js.map +0 -1
- package/dist/mcp/agent.d.ts +0 -192
- package/dist/mcp/agent.d.ts.map +0 -1
- package/dist/mcp/agent.js +0 -338
- package/dist/mcp/agent.js.map +0 -1
- package/dist/mcp/cli.d.ts +0 -71
- package/dist/mcp/cli.d.ts.map +0 -1
- package/dist/mcp/cli.js +0 -218
- package/dist/mcp/cli.js.map +0 -1
- package/dist/mcp/index.d.ts +0 -15
- package/dist/mcp/index.d.ts.map +0 -1
- package/dist/mcp/index.js +0 -20
- package/dist/mcp/index.js.map +0 -1
- package/dist/mcp/sandbox/database-proxy.d.ts +0 -118
- package/dist/mcp/sandbox/database-proxy.d.ts.map +0 -1
- package/dist/mcp/sandbox/database-proxy.js +0 -154
- package/dist/mcp/sandbox/database-proxy.js.map +0 -1
- package/dist/mcp/sandbox/index.d.ts +0 -8
- package/dist/mcp/sandbox/index.d.ts.map +0 -1
- package/dist/mcp/sandbox/index.js +0 -7
- package/dist/mcp/sandbox/index.js.map +0 -1
- package/dist/mcp/sandbox/miniflare-evaluator.d.ts +0 -72
- package/dist/mcp/sandbox/miniflare-evaluator.d.ts.map +0 -1
- package/dist/mcp/sandbox/miniflare-evaluator.js +0 -379
- package/dist/mcp/sandbox/miniflare-evaluator.js.map +0 -1
- package/dist/mcp/sandbox/template.d.ts +0 -48
- package/dist/mcp/sandbox/template.d.ts.map +0 -1
- package/dist/mcp/sandbox/template.js +0 -147
- package/dist/mcp/sandbox/template.js.map +0 -1
- package/dist/mcp/sandbox/worker-evaluator.d.ts +0 -160
- package/dist/mcp/sandbox/worker-evaluator.d.ts.map +0 -1
- package/dist/mcp/sandbox/worker-evaluator.js +0 -217
- package/dist/mcp/sandbox/worker-evaluator.js.map +0 -1
- package/dist/mcp/server.d.ts +0 -75
- package/dist/mcp/server.d.ts.map +0 -1
- package/dist/mcp/server.js +0 -278
- package/dist/mcp/server.js.map +0 -1
- package/dist/mcp/tool-call-auditor.d.ts +0 -188
- package/dist/mcp/tool-call-auditor.d.ts.map +0 -1
- package/dist/mcp/tool-call-auditor.js +0 -198
- package/dist/mcp/tool-call-auditor.js.map +0 -1
- package/dist/mcp/tools/do.d.ts +0 -51
- package/dist/mcp/tools/do.d.ts.map +0 -1
- package/dist/mcp/tools/do.js +0 -113
- package/dist/mcp/tools/do.js.map +0 -1
- package/dist/mcp/tools/fetch.d.ts +0 -43
- package/dist/mcp/tools/fetch.d.ts.map +0 -1
- package/dist/mcp/tools/fetch.js +0 -127
- package/dist/mcp/tools/fetch.js.map +0 -1
- package/dist/mcp/tools/index.d.ts +0 -9
- package/dist/mcp/tools/index.d.ts.map +0 -1
- package/dist/mcp/tools/index.js +0 -9
- package/dist/mcp/tools/index.js.map +0 -1
- package/dist/mcp/tools/search.d.ts +0 -60
- package/dist/mcp/tools/search.d.ts.map +0 -1
- package/dist/mcp/tools/search.js +0 -278
- package/dist/mcp/tools/search.js.map +0 -1
- package/dist/mcp/transport/http.d.ts +0 -144
- package/dist/mcp/transport/http.d.ts.map +0 -1
- package/dist/mcp/transport/http.js +0 -545
- package/dist/mcp/transport/http.js.map +0 -1
- package/dist/mcp/transport/index.d.ts +0 -10
- package/dist/mcp/transport/index.d.ts.map +0 -1
- package/dist/mcp/transport/index.js +0 -12
- package/dist/mcp/transport/index.js.map +0 -1
- package/dist/mcp/transport/stdio.d.ts +0 -132
- package/dist/mcp/transport/stdio.d.ts.map +0 -1
- package/dist/mcp/transport/stdio.js +0 -466
- package/dist/mcp/transport/stdio.js.map +0 -1
- package/dist/mcp/types.d.ts +0 -476
- package/dist/mcp/types.d.ts.map +0 -1
- package/dist/mcp/types.js +0 -178
- package/dist/mcp/types.js.map +0 -1
- package/dist/olap/cdc/cdc-buffer.d.ts +0 -92
- package/dist/olap/cdc/cdc-buffer.d.ts.map +0 -1
- package/dist/olap/cdc/cdc-buffer.js +0 -146
- package/dist/olap/cdc/cdc-buffer.js.map +0 -1
- package/dist/olap/cdc/cdc-emitter.d.ts +0 -118
- package/dist/olap/cdc/cdc-emitter.d.ts.map +0 -1
- package/dist/olap/cdc/cdc-emitter.js +0 -217
- package/dist/olap/cdc/cdc-emitter.js.map +0 -1
- package/dist/olap/cdc/cdc-schema.d.ts +0 -119
- package/dist/olap/cdc/cdc-schema.d.ts.map +0 -1
- package/dist/olap/cdc/cdc-schema.js +0 -253
- package/dist/olap/cdc/cdc-schema.js.map +0 -1
- package/dist/olap/cdc/index.d.ts +0 -10
- package/dist/olap/cdc/index.d.ts.map +0 -1
- package/dist/olap/cdc/index.js +0 -10
- package/dist/olap/cdc/index.js.map +0 -1
- package/dist/olap/clickhouse/iceberg.d.ts +0 -164
- package/dist/olap/clickhouse/iceberg.d.ts.map +0 -1
- package/dist/olap/clickhouse/iceberg.js +0 -138
- package/dist/olap/clickhouse/iceberg.js.map +0 -1
- package/dist/olap/clickhouse/index.d.ts +0 -14
- package/dist/olap/clickhouse/index.d.ts.map +0 -1
- package/dist/olap/clickhouse/index.js +0 -14
- package/dist/olap/clickhouse/index.js.map +0 -1
- package/dist/olap/clickhouse/mapper.d.ts +0 -170
- package/dist/olap/clickhouse/mapper.d.ts.map +0 -1
- package/dist/olap/clickhouse/mapper.js +0 -654
- package/dist/olap/clickhouse/mapper.js.map +0 -1
- package/dist/olap/clickhouse/olap-backend.d.ts +0 -181
- package/dist/olap/clickhouse/olap-backend.d.ts.map +0 -1
- package/dist/olap/clickhouse/olap-backend.js +0 -1083
- package/dist/olap/clickhouse/olap-backend.js.map +0 -1
- package/dist/olap/clickhouse/query-executor.d.ts +0 -163
- package/dist/olap/clickhouse/query-executor.d.ts.map +0 -1
- package/dist/olap/clickhouse/query-executor.js +0 -560
- package/dist/olap/clickhouse/query-executor.js.map +0 -1
- package/dist/olap/clickhouse/query.d.ts +0 -134
- package/dist/olap/clickhouse/query.d.ts.map +0 -1
- package/dist/olap/clickhouse/query.js +0 -512
- package/dist/olap/clickhouse/query.js.map +0 -1
- package/dist/olap/stage/index.d.ts +0 -6
- package/dist/olap/stage/index.d.ts.map +0 -1
- package/dist/olap/stage/index.js +0 -6
- package/dist/olap/stage/index.js.map +0 -1
- package/dist/olap/stage/parser.d.ts +0 -68
- package/dist/olap/stage/parser.d.ts.map +0 -1
- package/dist/olap/stage/parser.js +0 -293
- package/dist/olap/stage/parser.js.map +0 -1
- package/dist/olap/stage/router.d.ts +0 -94
- package/dist/olap/stage/router.d.ts.map +0 -1
- package/dist/olap/stage/router.js +0 -390
- package/dist/olap/stage/router.js.map +0 -1
- package/dist/rpc/endpoint.d.ts +0 -52
- package/dist/rpc/endpoint.d.ts.map +0 -1
- package/dist/rpc/endpoint.js +0 -734
- package/dist/rpc/endpoint.js.map +0 -1
- package/dist/rpc/index.d.ts +0 -34
- package/dist/rpc/index.d.ts.map +0 -1
- package/dist/rpc/index.js +0 -45
- package/dist/rpc/index.js.map +0 -1
- package/dist/rpc/rpc-client.d.ts +0 -275
- package/dist/rpc/rpc-client.d.ts.map +0 -1
- package/dist/rpc/rpc-client.js +0 -735
- package/dist/rpc/rpc-client.js.map +0 -1
- package/dist/rpc/rpc-target.d.ts +0 -220
- package/dist/rpc/rpc-target.d.ts.map +0 -1
- package/dist/rpc/rpc-target.js +0 -500
- package/dist/rpc/rpc-target.js.map +0 -1
- package/dist/rpc/worker-entrypoint.d.ts +0 -159
- package/dist/rpc/worker-entrypoint.d.ts.map +0 -1
- package/dist/rpc/worker-entrypoint.js +0 -212
- package/dist/rpc/worker-entrypoint.js.map +0 -1
- package/dist/server.d.ts +0 -18
- package/dist/server.d.ts.map +0 -1
- package/dist/server.js +0 -129
- package/dist/server.js.map +0 -1
- package/dist/studio/components/browser/CollectionItem.d.ts +0 -26
- package/dist/studio/components/browser/CollectionItem.d.ts.map +0 -1
- package/dist/studio/components/browser/CollectionItem.js +0 -143
- package/dist/studio/components/browser/CollectionItem.js.map +0 -1
- package/dist/studio/components/browser/CollectionTree.d.ts +0 -45
- package/dist/studio/components/browser/CollectionTree.d.ts.map +0 -1
- package/dist/studio/components/browser/CollectionTree.js +0 -207
- package/dist/studio/components/browser/CollectionTree.js.map +0 -1
- package/dist/studio/components/browser/ConnectedDatabaseBrowser.d.ts +0 -51
- package/dist/studio/components/browser/ConnectedDatabaseBrowser.d.ts.map +0 -1
- package/dist/studio/components/browser/ConnectedDatabaseBrowser.js +0 -185
- package/dist/studio/components/browser/ConnectedDatabaseBrowser.js.map +0 -1
- package/dist/studio/components/browser/DatabaseBrowser.d.ts +0 -46
- package/dist/studio/components/browser/DatabaseBrowser.d.ts.map +0 -1
- package/dist/studio/components/browser/DatabaseBrowser.js +0 -304
- package/dist/studio/components/browser/DatabaseBrowser.js.map +0 -1
- package/dist/studio/components/browser/__tests__/CollectionItem.test.d.ts +0 -5
- package/dist/studio/components/browser/__tests__/CollectionItem.test.d.ts.map +0 -1
- package/dist/studio/components/browser/__tests__/CollectionItem.test.js +0 -169
- package/dist/studio/components/browser/__tests__/CollectionItem.test.js.map +0 -1
- package/dist/studio/components/browser/__tests__/CollectionTree.test.d.ts +0 -5
- package/dist/studio/components/browser/__tests__/CollectionTree.test.d.ts.map +0 -1
- package/dist/studio/components/browser/__tests__/CollectionTree.test.js +0 -203
- package/dist/studio/components/browser/__tests__/CollectionTree.test.js.map +0 -1
- package/dist/studio/components/browser/__tests__/DatabaseBrowser.e2e.test.d.ts +0 -8
- package/dist/studio/components/browser/__tests__/DatabaseBrowser.e2e.test.d.ts.map +0 -1
- package/dist/studio/components/browser/__tests__/DatabaseBrowser.e2e.test.js +0 -522
- package/dist/studio/components/browser/__tests__/DatabaseBrowser.e2e.test.js.map +0 -1
- package/dist/studio/components/browser/__tests__/DatabaseBrowser.test.d.ts +0 -5
- package/dist/studio/components/browser/__tests__/DatabaseBrowser.test.d.ts.map +0 -1
- package/dist/studio/components/browser/__tests__/DatabaseBrowser.test.js +0 -518
- package/dist/studio/components/browser/__tests__/DatabaseBrowser.test.js.map +0 -1
- package/dist/studio/components/browser/__tests__/setup.d.ts +0 -5
- package/dist/studio/components/browser/__tests__/setup.d.ts.map +0 -1
- package/dist/studio/components/browser/__tests__/setup.js +0 -22
- package/dist/studio/components/browser/__tests__/setup.js.map +0 -1
- package/dist/studio/components/browser/index.d.ts +0 -15
- package/dist/studio/components/browser/index.d.ts.map +0 -1
- package/dist/studio/components/browser/index.js +0 -10
- package/dist/studio/components/browser/index.js.map +0 -1
- package/dist/studio/components/browser/types.d.ts +0 -33
- package/dist/studio/components/browser/types.d.ts.map +0 -1
- package/dist/studio/components/browser/types.js +0 -5
- package/dist/studio/components/browser/types.js.map +0 -1
- package/dist/studio/components/connection/ConnectionForm.d.ts +0 -59
- package/dist/studio/components/connection/ConnectionForm.d.ts.map +0 -1
- package/dist/studio/components/connection/ConnectionForm.js +0 -274
- package/dist/studio/components/connection/ConnectionForm.js.map +0 -1
- package/dist/studio/components/connection/ConnectionList.d.ts +0 -59
- package/dist/studio/components/connection/ConnectionList.d.ts.map +0 -1
- package/dist/studio/components/connection/ConnectionList.js +0 -286
- package/dist/studio/components/connection/ConnectionList.js.map +0 -1
- package/dist/studio/components/connection/ConnectionPanel.d.ts +0 -132
- package/dist/studio/components/connection/ConnectionPanel.d.ts.map +0 -1
- package/dist/studio/components/connection/ConnectionPanel.js +0 -293
- package/dist/studio/components/connection/ConnectionPanel.js.map +0 -1
- package/dist/studio/components/connection/__tests__/ConnectionPanel.test.d.ts +0 -8
- package/dist/studio/components/connection/__tests__/ConnectionPanel.test.d.ts.map +0 -1
- package/dist/studio/components/connection/__tests__/ConnectionPanel.test.js +0 -632
- package/dist/studio/components/connection/__tests__/ConnectionPanel.test.js.map +0 -1
- package/dist/studio/components/connection/__tests__/setup.d.ts +0 -5
- package/dist/studio/components/connection/__tests__/setup.d.ts.map +0 -1
- package/dist/studio/components/connection/__tests__/setup.js +0 -11
- package/dist/studio/components/connection/__tests__/setup.js.map +0 -1
- package/dist/studio/components/connection/index.d.ts +0 -10
- package/dist/studio/components/connection/index.d.ts.map +0 -1
- package/dist/studio/components/connection/index.js +0 -7
- package/dist/studio/components/connection/index.js.map +0 -1
- package/dist/studio/components/crud/DeleteDocumentDialog.d.ts +0 -91
- package/dist/studio/components/crud/DeleteDocumentDialog.d.ts.map +0 -1
- package/dist/studio/components/crud/DeleteDocumentDialog.js +0 -273
- package/dist/studio/components/crud/DeleteDocumentDialog.js.map +0 -1
- package/dist/studio/components/crud/DocumentEditor.d.ts +0 -32
- package/dist/studio/components/crud/DocumentEditor.d.ts.map +0 -1
- package/dist/studio/components/crud/DocumentEditor.js +0 -546
- package/dist/studio/components/crud/DocumentEditor.js.map +0 -1
- package/dist/studio/components/crud/InsertDocumentDialog.d.ts +0 -78
- package/dist/studio/components/crud/InsertDocumentDialog.d.ts.map +0 -1
- package/dist/studio/components/crud/InsertDocumentDialog.js +0 -323
- package/dist/studio/components/crud/InsertDocumentDialog.js.map +0 -1
- package/dist/studio/components/crud/__tests__/DeleteDocumentDialog.test.d.ts +0 -5
- package/dist/studio/components/crud/__tests__/DeleteDocumentDialog.test.d.ts.map +0 -1
- package/dist/studio/components/crud/__tests__/DeleteDocumentDialog.test.js +0 -298
- package/dist/studio/components/crud/__tests__/DeleteDocumentDialog.test.js.map +0 -1
- package/dist/studio/components/crud/__tests__/DocumentEditor.test.d.ts +0 -8
- package/dist/studio/components/crud/__tests__/DocumentEditor.test.d.ts.map +0 -1
- package/dist/studio/components/crud/__tests__/DocumentEditor.test.js +0 -368
- package/dist/studio/components/crud/__tests__/DocumentEditor.test.js.map +0 -1
- package/dist/studio/components/crud/__tests__/InsertDocumentDialog.test.d.ts +0 -2
- package/dist/studio/components/crud/__tests__/InsertDocumentDialog.test.d.ts.map +0 -1
- package/dist/studio/components/crud/__tests__/InsertDocumentDialog.test.js +0 -352
- package/dist/studio/components/crud/__tests__/InsertDocumentDialog.test.js.map +0 -1
- package/dist/studio/components/crud/__tests__/setup.d.ts +0 -5
- package/dist/studio/components/crud/__tests__/setup.d.ts.map +0 -1
- package/dist/studio/components/crud/__tests__/setup.js +0 -22
- package/dist/studio/components/crud/__tests__/setup.js.map +0 -1
- package/dist/studio/components/crud/index.d.ts +0 -12
- package/dist/studio/components/crud/index.d.ts.map +0 -1
- package/dist/studio/components/crud/index.js +0 -11
- package/dist/studio/components/crud/index.js.map +0 -1
- package/dist/studio/hooks/useConnection.d.ts +0 -127
- package/dist/studio/hooks/useConnection.d.ts.map +0 -1
- package/dist/studio/hooks/useConnection.js +0 -414
- package/dist/studio/hooks/useConnection.js.map +0 -1
- package/dist/studio/hooks/useDatabaseBrowser.d.ts +0 -107
- package/dist/studio/hooks/useDatabaseBrowser.d.ts.map +0 -1
- package/dist/studio/hooks/useDatabaseBrowser.js +0 -294
- package/dist/studio/hooks/useDatabaseBrowser.js.map +0 -1
- package/dist/studio/index.d.ts +0 -16
- package/dist/studio/index.d.ts.map +0 -1
- package/dist/studio/index.js +0 -14
- package/dist/studio/index.js.map +0 -1
- package/dist/studio/types/connection.d.ts +0 -266
- package/dist/studio/types/connection.d.ts.map +0 -1
- package/dist/studio/types/connection.js +0 -159
- package/dist/studio/types/connection.js.map +0 -1
- package/dist/studio/vitest.config.d.ts +0 -3
- package/dist/studio/vitest.config.d.ts.map +0 -1
- package/dist/studio/vitest.config.js +0 -33
- package/dist/studio/vitest.config.js.map +0 -1
- package/dist/translator/aggregation-translator.d.ts +0 -51
- package/dist/translator/aggregation-translator.d.ts.map +0 -1
- package/dist/translator/aggregation-translator.js +0 -324
- package/dist/translator/aggregation-translator.js.map +0 -1
- package/dist/translator/dialect.d.ts +0 -131
- package/dist/translator/dialect.d.ts.map +0 -1
- package/dist/translator/dialect.js +0 -276
- package/dist/translator/dialect.js.map +0 -1
- package/dist/translator/geo-translator.d.ts +0 -91
- package/dist/translator/geo-translator.d.ts.map +0 -1
- package/dist/translator/geo-translator.js +0 -587
- package/dist/translator/geo-translator.js.map +0 -1
- package/dist/translator/hybrid-translator.d.ts +0 -70
- package/dist/translator/hybrid-translator.d.ts.map +0 -1
- package/dist/translator/hybrid-translator.js +0 -193
- package/dist/translator/hybrid-translator.js.map +0 -1
- package/dist/translator/index.d.ts +0 -13
- package/dist/translator/index.d.ts.map +0 -1
- package/dist/translator/index.js +0 -11
- package/dist/translator/index.js.map +0 -1
- package/dist/translator/query-translator.d.ts +0 -211
- package/dist/translator/query-translator.d.ts.map +0 -1
- package/dist/translator/query-translator.js +0 -1276
- package/dist/translator/query-translator.js.map +0 -1
- package/dist/translator/search-highlight.d.ts +0 -83
- package/dist/translator/search-highlight.d.ts.map +0 -1
- package/dist/translator/search-highlight.js +0 -83
- package/dist/translator/search-highlight.js.map +0 -1
- package/dist/translator/search-translator.d.ts +0 -155
- package/dist/translator/search-translator.d.ts.map +0 -1
- package/dist/translator/search-translator.js +0 -241
- package/dist/translator/search-translator.js.map +0 -1
- package/dist/translator/stages/add-fields-stage.d.ts +0 -7
- package/dist/translator/stages/add-fields-stage.d.ts.map +0 -1
- package/dist/translator/stages/add-fields-stage.js +0 -72
- package/dist/translator/stages/add-fields-stage.js.map +0 -1
- package/dist/translator/stages/bucket-stage.d.ts +0 -7
- package/dist/translator/stages/bucket-stage.d.ts.map +0 -1
- package/dist/translator/stages/bucket-stage.js +0 -87
- package/dist/translator/stages/bucket-stage.js.map +0 -1
- package/dist/translator/stages/count-stage.d.ts +0 -7
- package/dist/translator/stages/count-stage.d.ts.map +0 -1
- package/dist/translator/stages/count-stage.js +0 -12
- package/dist/translator/stages/count-stage.js.map +0 -1
- package/dist/translator/stages/expression-translator.d.ts +0 -68
- package/dist/translator/stages/expression-translator.d.ts.map +0 -1
- package/dist/translator/stages/expression-translator.js +0 -467
- package/dist/translator/stages/expression-translator.js.map +0 -1
- package/dist/translator/stages/facet-stage.d.ts +0 -13
- package/dist/translator/stages/facet-stage.d.ts.map +0 -1
- package/dist/translator/stages/facet-stage.js +0 -26
- package/dist/translator/stages/facet-stage.js.map +0 -1
- package/dist/translator/stages/fusion-stages.d.ts +0 -118
- package/dist/translator/stages/fusion-stages.d.ts.map +0 -1
- package/dist/translator/stages/fusion-stages.js +0 -201
- package/dist/translator/stages/fusion-stages.js.map +0 -1
- package/dist/translator/stages/group-stage.d.ts +0 -8
- package/dist/translator/stages/group-stage.d.ts.map +0 -1
- package/dist/translator/stages/group-stage.js +0 -123
- package/dist/translator/stages/group-stage.js.map +0 -1
- package/dist/translator/stages/index.d.ts +0 -24
- package/dist/translator/stages/index.d.ts.map +0 -1
- package/dist/translator/stages/index.js +0 -24
- package/dist/translator/stages/index.js.map +0 -1
- package/dist/translator/stages/join-optimizer.d.ts +0 -37
- package/dist/translator/stages/join-optimizer.d.ts.map +0 -1
- package/dist/translator/stages/join-optimizer.js +0 -93
- package/dist/translator/stages/join-optimizer.js.map +0 -1
- package/dist/translator/stages/limit-stage.d.ts +0 -7
- package/dist/translator/stages/limit-stage.d.ts.map +0 -1
- package/dist/translator/stages/limit-stage.js +0 -11
- package/dist/translator/stages/limit-stage.js.map +0 -1
- package/dist/translator/stages/lookup-stage.d.ts +0 -7
- package/dist/translator/stages/lookup-stage.d.ts.map +0 -1
- package/dist/translator/stages/lookup-stage.js +0 -73
- package/dist/translator/stages/lookup-stage.js.map +0 -1
- package/dist/translator/stages/match-stage.d.ts +0 -7
- package/dist/translator/stages/match-stage.d.ts.map +0 -1
- package/dist/translator/stages/match-stage.js +0 -14
- package/dist/translator/stages/match-stage.js.map +0 -1
- package/dist/translator/stages/optimizer.d.ts +0 -15
- package/dist/translator/stages/optimizer.d.ts.map +0 -1
- package/dist/translator/stages/optimizer.js +0 -249
- package/dist/translator/stages/optimizer.js.map +0 -1
- package/dist/translator/stages/parallel-facet.d.ts +0 -47
- package/dist/translator/stages/parallel-facet.d.ts.map +0 -1
- package/dist/translator/stages/parallel-facet.js +0 -57
- package/dist/translator/stages/parallel-facet.js.map +0 -1
- package/dist/translator/stages/project-stage.d.ts +0 -8
- package/dist/translator/stages/project-stage.d.ts.map +0 -1
- package/dist/translator/stages/project-stage.js +0 -145
- package/dist/translator/stages/project-stage.js.map +0 -1
- package/dist/translator/stages/search-stage.d.ts +0 -60
- package/dist/translator/stages/search-stage.d.ts.map +0 -1
- package/dist/translator/stages/search-stage.js +0 -89
- package/dist/translator/stages/search-stage.js.map +0 -1
- package/dist/translator/stages/skip-stage.d.ts +0 -7
- package/dist/translator/stages/skip-stage.d.ts.map +0 -1
- package/dist/translator/stages/skip-stage.js +0 -11
- package/dist/translator/stages/skip-stage.js.map +0 -1
- package/dist/translator/stages/sort-stage.d.ts +0 -7
- package/dist/translator/stages/sort-stage.d.ts.map +0 -1
- package/dist/translator/stages/sort-stage.js +0 -21
- package/dist/translator/stages/sort-stage.js.map +0 -1
- package/dist/translator/stages/types.d.ts +0 -136
- package/dist/translator/stages/types.d.ts.map +0 -1
- package/dist/translator/stages/types.js +0 -5
- package/dist/translator/stages/types.js.map +0 -1
- package/dist/translator/stages/unwind-stage.d.ts +0 -7
- package/dist/translator/stages/unwind-stage.d.ts.map +0 -1
- package/dist/translator/stages/unwind-stage.js +0 -61
- package/dist/translator/stages/unwind-stage.js.map +0 -1
- package/dist/translator/stages/vector-search-stage.d.ts +0 -53
- package/dist/translator/stages/vector-search-stage.d.ts.map +0 -1
- package/dist/translator/stages/vector-search-stage.js +0 -62
- package/dist/translator/stages/vector-search-stage.js.map +0 -1
- package/dist/translator/update-translator.d.ts +0 -148
- package/dist/translator/update-translator.d.ts.map +0 -1
- package/dist/translator/update-translator.js +0 -819
- package/dist/translator/update-translator.js.map +0 -1
- package/dist/translator/vector-translator.d.ts +0 -89
- package/dist/translator/vector-translator.d.ts.map +0 -1
- package/dist/translator/vector-translator.js +0 -106
- package/dist/translator/vector-translator.js.map +0 -1
- package/dist/types/env.d.ts +0 -31
- package/dist/types/env.d.ts.map +0 -1
- package/dist/types/env.js +0 -5
- package/dist/types/env.js.map +0 -1
- package/dist/types/function.d.ts +0 -65
- package/dist/types/function.d.ts.map +0 -1
- package/dist/types/function.js +0 -5
- package/dist/types/function.js.map +0 -1
- package/dist/types/index.d.ts +0 -137
- package/dist/types/index.d.ts.map +0 -1
- package/dist/types/index.js +0 -13
- package/dist/types/index.js.map +0 -1
- package/dist/types/mongodb.d.ts +0 -258
- package/dist/types/mongodb.d.ts.map +0 -1
- package/dist/types/mongodb.js +0 -5
- package/dist/types/mongodb.js.map +0 -1
- package/dist/types/objectid.d.ts +0 -130
- package/dist/types/objectid.d.ts.map +0 -1
- package/dist/types/objectid.js +0 -314
- package/dist/types/objectid.js.map +0 -1
- package/dist/types/rpc.d.ts +0 -313
- package/dist/types/rpc.d.ts.map +0 -1
- package/dist/types/rpc.js +0 -136
- package/dist/types/rpc.js.map +0 -1
- package/dist/types/vectorize.d.ts +0 -136
- package/dist/types/vectorize.d.ts.map +0 -1
- package/dist/types/vectorize.js +0 -8
- package/dist/types/vectorize.js.map +0 -1
- package/dist/utils/sql-safety.d.ts +0 -64
- package/dist/utils/sql-safety.d.ts.map +0 -1
- package/dist/utils/sql-safety.js +0 -112
- package/dist/utils/sql-safety.js.map +0 -1
- package/dist/validation/document-validator.d.ts +0 -195
- package/dist/validation/document-validator.d.ts.map +0 -1
- package/dist/validation/document-validator.js +0 -529
- package/dist/validation/document-validator.js.map +0 -1
- package/dist/vectorize/document-serializer.d.ts +0 -119
- package/dist/vectorize/document-serializer.d.ts.map +0 -1
- package/dist/vectorize/document-serializer.js +0 -320
- package/dist/vectorize/document-serializer.js.map +0 -1
- package/dist/wire/auth/index.d.ts +0 -5
- package/dist/wire/auth/index.d.ts.map +0 -1
- package/dist/wire/auth/index.js +0 -5
- package/dist/wire/auth/index.js.map +0 -1
- package/dist/wire/auth/scram.d.ts +0 -160
- package/dist/wire/auth/scram.d.ts.map +0 -1
- package/dist/wire/auth/scram.js +0 -425
- package/dist/wire/auth/scram.js.map +0 -1
- package/dist/wire/backend/interface.d.ts +0 -168
- package/dist/wire/backend/interface.d.ts.map +0 -1
- package/dist/wire/backend/interface.js +0 -10
- package/dist/wire/backend/interface.js.map +0 -1
- package/dist/wire/backend/local-sqlite.d.ts +0 -89
- package/dist/wire/backend/local-sqlite.d.ts.map +0 -1
- package/dist/wire/backend/local-sqlite.js +0 -1002
- package/dist/wire/backend/local-sqlite.js.map +0 -1
- package/dist/wire/backend/query-router.d.ts +0 -197
- package/dist/wire/backend/query-router.d.ts.map +0 -1
- package/dist/wire/backend/query-router.js +0 -590
- package/dist/wire/backend/query-router.js.map +0 -1
- package/dist/wire/backend/validation.d.ts +0 -26
- package/dist/wire/backend/validation.d.ts.map +0 -1
- package/dist/wire/backend/validation.js +0 -79
- package/dist/wire/backend/validation.js.map +0 -1
- package/dist/wire/backend/workers-proxy.d.ts +0 -95
- package/dist/wire/backend/workers-proxy.d.ts.map +0 -1
- package/dist/wire/backend/workers-proxy.js +0 -429
- package/dist/wire/backend/workers-proxy.js.map +0 -1
- package/dist/wire/commands/admin.d.ts +0 -49
- package/dist/wire/commands/admin.d.ts.map +0 -1
- package/dist/wire/commands/admin.js +0 -272
- package/dist/wire/commands/admin.js.map +0 -1
- package/dist/wire/commands/aggregate.d.ts +0 -15
- package/dist/wire/commands/aggregate.d.ts.map +0 -1
- package/dist/wire/commands/aggregate.js +0 -98
- package/dist/wire/commands/aggregate.js.map +0 -1
- package/dist/wire/commands/auth.d.ts +0 -58
- package/dist/wire/commands/auth.d.ts.map +0 -1
- package/dist/wire/commands/auth.js +0 -158
- package/dist/wire/commands/auth.js.map +0 -1
- package/dist/wire/commands/crud.d.ts +0 -49
- package/dist/wire/commands/crud.d.ts.map +0 -1
- package/dist/wire/commands/crud.js +0 -336
- package/dist/wire/commands/crud.js.map +0 -1
- package/dist/wire/commands/hello.d.ts +0 -35
- package/dist/wire/commands/hello.d.ts.map +0 -1
- package/dist/wire/commands/hello.js +0 -204
- package/dist/wire/commands/hello.js.map +0 -1
- package/dist/wire/commands/index.d.ts +0 -24
- package/dist/wire/commands/index.d.ts.map +0 -1
- package/dist/wire/commands/index.js +0 -145
- package/dist/wire/commands/index.js.map +0 -1
- package/dist/wire/commands/router.d.ts +0 -46
- package/dist/wire/commands/router.d.ts.map +0 -1
- package/dist/wire/commands/router.js +0 -151
- package/dist/wire/commands/router.js.map +0 -1
- package/dist/wire/commands/types.d.ts +0 -51
- package/dist/wire/commands/types.d.ts.map +0 -1
- package/dist/wire/commands/types.js +0 -15
- package/dist/wire/commands/types.js.map +0 -1
- package/dist/wire/index.d.ts +0 -15
- package/dist/wire/index.d.ts.map +0 -1
- package/dist/wire/index.js +0 -19
- package/dist/wire/index.js.map +0 -1
- package/dist/wire/message.d.ts +0 -49
- package/dist/wire/message.d.ts.map +0 -1
- package/dist/wire/message.js +0 -299
- package/dist/wire/message.js.map +0 -1
- package/dist/wire/server.d.ts +0 -145
- package/dist/wire/server.d.ts.map +0 -1
- package/dist/wire/server.js +0 -284
- package/dist/wire/server.js.map +0 -1
- package/dist/wire/types.d.ts +0 -140
- package/dist/wire/types.d.ts.map +0 -1
- package/dist/wire/types.js +0 -64
- package/dist/wire/types.js.map +0 -1
- package/dist/worker.d.ts.map +0 -1
package/dist/agentfs/vfs.js
DELETED
|
@@ -1,469 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* AgentFS Virtual Filesystem Implementation
|
|
3
|
-
*
|
|
4
|
-
* Virtual filesystem stored in mongo.do collections.
|
|
5
|
-
* Provides a file-system-like interface backed by MongoDB/mongo.do.
|
|
6
|
-
*
|
|
7
|
-
* @module agentfs/vfs
|
|
8
|
-
*
|
|
9
|
-
* @example
|
|
10
|
-
* ```typescript
|
|
11
|
-
* import { AgentFilesystem } from './vfs'
|
|
12
|
-
*
|
|
13
|
-
* const fs = new AgentFilesystem(database)
|
|
14
|
-
*
|
|
15
|
-
* // Write and read files
|
|
16
|
-
* await fs.writeFile('/config.json', '{"key": "value"}')
|
|
17
|
-
* const content = await fs.readFile('/config.json')
|
|
18
|
-
*
|
|
19
|
-
* // Directory operations
|
|
20
|
-
* await fs.mkdir('/src')
|
|
21
|
-
* const files = await fs.readdir('/src')
|
|
22
|
-
*
|
|
23
|
-
* // Glob pattern matching
|
|
24
|
-
* const tsFiles = await fs.glob('**\/*.ts')
|
|
25
|
-
* ```
|
|
26
|
-
*/
|
|
27
|
-
/**
|
|
28
|
-
* AgentFilesystem - Virtual filesystem backed by mongo.do
|
|
29
|
-
*
|
|
30
|
-
* Implements the FileSystem interface using a MongoDB-compatible database.
|
|
31
|
-
* Uses the file path as the document _id for O(1) lookups.
|
|
32
|
-
*
|
|
33
|
-
* Features:
|
|
34
|
-
* - Files and directories with proper POSIX-like semantics
|
|
35
|
-
* - Implicit parent directory creation
|
|
36
|
-
* - Path normalization (removes duplicate slashes, resolves . and ..)
|
|
37
|
-
* - Glob pattern matching for file discovery
|
|
38
|
-
*
|
|
39
|
-
* Error codes follow POSIX conventions:
|
|
40
|
-
* - ENOENT: File or directory does not exist
|
|
41
|
-
* - EISDIR: Illegal operation on a directory
|
|
42
|
-
* - ENOTDIR: Not a directory
|
|
43
|
-
* - EEXIST: File already exists
|
|
44
|
-
* - ENOTEMPTY: Directory not empty
|
|
45
|
-
* - EPERM: Operation not permitted
|
|
46
|
-
*
|
|
47
|
-
* @example
|
|
48
|
-
* ```typescript
|
|
49
|
-
* const fs = new AgentFilesystem(database)
|
|
50
|
-
*
|
|
51
|
-
* // Create and read files
|
|
52
|
-
* await fs.writeFile('/data/config.json', '{}')
|
|
53
|
-
* const content = await fs.readFile('/data/config.json')
|
|
54
|
-
*
|
|
55
|
-
* // Directories are created implicitly
|
|
56
|
-
* const stat = await fs.stat('/data')
|
|
57
|
-
* // stat.type === 'directory'
|
|
58
|
-
* ```
|
|
59
|
-
*/
|
|
60
|
-
export class AgentFilesystem {
|
|
61
|
-
db;
|
|
62
|
-
collection = '__agentfs.files';
|
|
63
|
-
/**
|
|
64
|
-
* Create a new AgentFilesystem instance.
|
|
65
|
-
*
|
|
66
|
-
* @param db - Database backend implementing AgentFSDatabase interface
|
|
67
|
-
*/
|
|
68
|
-
constructor(db) {
|
|
69
|
-
this.db = db;
|
|
70
|
-
}
|
|
71
|
-
/**
|
|
72
|
-
* Normalize a path to ensure consistency.
|
|
73
|
-
*
|
|
74
|
-
* Normalization rules:
|
|
75
|
-
* - Always starts with /
|
|
76
|
-
* - No duplicate slashes (// becomes /)
|
|
77
|
-
* - No trailing slash (except for root)
|
|
78
|
-
* - Resolves . (current directory) components
|
|
79
|
-
* - Resolves .. (parent directory) components
|
|
80
|
-
*
|
|
81
|
-
* @param path - Path to normalize
|
|
82
|
-
* @returns Normalized absolute path
|
|
83
|
-
* @internal
|
|
84
|
-
*/
|
|
85
|
-
normalizePath(path) {
|
|
86
|
-
// Handle empty path
|
|
87
|
-
if (!path) {
|
|
88
|
-
return '/';
|
|
89
|
-
}
|
|
90
|
-
// Add leading slash if missing (normalize relative paths)
|
|
91
|
-
if (!path.startsWith('/')) {
|
|
92
|
-
path = '/' + path;
|
|
93
|
-
}
|
|
94
|
-
// Replace multiple slashes with single slash
|
|
95
|
-
path = path.replace(/\/+/g, '/');
|
|
96
|
-
// Remove trailing slash (unless it's the root)
|
|
97
|
-
if (path.length > 1 && path.endsWith('/')) {
|
|
98
|
-
path = path.slice(0, -1);
|
|
99
|
-
}
|
|
100
|
-
// Resolve . and .. components
|
|
101
|
-
const parts = path.split('/');
|
|
102
|
-
const resolved = [];
|
|
103
|
-
for (const part of parts) {
|
|
104
|
-
if (part === '' || part === '.') {
|
|
105
|
-
continue;
|
|
106
|
-
}
|
|
107
|
-
else if (part === '..') {
|
|
108
|
-
if (resolved.length > 0) {
|
|
109
|
-
resolved.pop();
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
else {
|
|
113
|
-
resolved.push(part);
|
|
114
|
-
}
|
|
115
|
-
}
|
|
116
|
-
return '/' + resolved.join('/') || '/';
|
|
117
|
-
}
|
|
118
|
-
/**
|
|
119
|
-
* Escape special regex characters in a string.
|
|
120
|
-
*
|
|
121
|
-
* @param str - String to escape
|
|
122
|
-
* @returns String with regex special characters escaped
|
|
123
|
-
* @internal
|
|
124
|
-
*/
|
|
125
|
-
escapeRegex(str) {
|
|
126
|
-
return str.replace(/[.*+?^${}()|[\]\\]/g, '\\$&');
|
|
127
|
-
}
|
|
128
|
-
/**
|
|
129
|
-
* Read file content at the specified path.
|
|
130
|
-
*
|
|
131
|
-
* @param path - Absolute path to the file
|
|
132
|
-
* @returns Promise resolving to the file content as a string
|
|
133
|
-
* @throws {Error} ENOENT if file does not exist
|
|
134
|
-
* @throws {Error} EISDIR if path is a directory
|
|
135
|
-
*/
|
|
136
|
-
async readFile(path) {
|
|
137
|
-
const normalizedPath = this.normalizePath(path);
|
|
138
|
-
const doc = await this.db.findOne(this.collection, { _id: normalizedPath });
|
|
139
|
-
if (!doc) {
|
|
140
|
-
throw new Error(`ENOENT: no such file or directory, '${normalizedPath}'`);
|
|
141
|
-
}
|
|
142
|
-
if (doc.type === 'directory') {
|
|
143
|
-
throw new Error(`EISDIR: illegal operation on a directory, '${normalizedPath}'`);
|
|
144
|
-
}
|
|
145
|
-
return doc.content;
|
|
146
|
-
}
|
|
147
|
-
/**
|
|
148
|
-
* Write content to a file at the specified path.
|
|
149
|
-
*
|
|
150
|
-
* Creates parent directories implicitly if they don't exist.
|
|
151
|
-
* If the file exists, it updates the content and updatedAt timestamp.
|
|
152
|
-
* If the file doesn't exist, it creates a new file with createdAt set.
|
|
153
|
-
*
|
|
154
|
-
* @param path - Absolute path to the file
|
|
155
|
-
* @param content - Content to write to the file
|
|
156
|
-
* @throws {Error} EISDIR if path is a directory
|
|
157
|
-
*/
|
|
158
|
-
async writeFile(path, content) {
|
|
159
|
-
const normalizedPath = this.normalizePath(path);
|
|
160
|
-
const now = new Date();
|
|
161
|
-
// Check if file exists to determine createdAt behavior
|
|
162
|
-
const existing = await this.db.findOne(this.collection, { _id: normalizedPath });
|
|
163
|
-
if (existing) {
|
|
164
|
-
if (existing.type === 'directory') {
|
|
165
|
-
throw new Error(`EISDIR: illegal operation on a directory, '${normalizedPath}'`);
|
|
166
|
-
}
|
|
167
|
-
// Update existing file - preserve createdAt
|
|
168
|
-
await this.db.updateOne(this.collection, { _id: normalizedPath }, {
|
|
169
|
-
$set: {
|
|
170
|
-
content,
|
|
171
|
-
updatedAt: now,
|
|
172
|
-
},
|
|
173
|
-
});
|
|
174
|
-
}
|
|
175
|
-
else {
|
|
176
|
-
// Create implicit parent directories
|
|
177
|
-
await this.createImplicitDirs(normalizedPath);
|
|
178
|
-
// Insert new file
|
|
179
|
-
await this.db.insertOne(this.collection, {
|
|
180
|
-
_id: normalizedPath,
|
|
181
|
-
path: normalizedPath,
|
|
182
|
-
content,
|
|
183
|
-
type: 'file',
|
|
184
|
-
createdAt: now,
|
|
185
|
-
updatedAt: now,
|
|
186
|
-
});
|
|
187
|
-
}
|
|
188
|
-
}
|
|
189
|
-
/**
|
|
190
|
-
* Create implicit parent directories for a file path.
|
|
191
|
-
*
|
|
192
|
-
* Traverses up the path and creates any missing directory entries.
|
|
193
|
-
*
|
|
194
|
-
* @param filePath - Absolute path to the file (not the directory)
|
|
195
|
-
* @internal
|
|
196
|
-
*/
|
|
197
|
-
async createImplicitDirs(filePath) {
|
|
198
|
-
const parts = filePath.split('/').filter(Boolean);
|
|
199
|
-
// Remove the last part (the file itself)
|
|
200
|
-
parts.pop();
|
|
201
|
-
let currentPath = '';
|
|
202
|
-
for (const part of parts) {
|
|
203
|
-
currentPath += '/' + part;
|
|
204
|
-
const exists = await this.db.findOne(this.collection, { _id: currentPath });
|
|
205
|
-
if (!exists) {
|
|
206
|
-
const now = new Date();
|
|
207
|
-
await this.db.insertOne(this.collection, {
|
|
208
|
-
_id: currentPath,
|
|
209
|
-
path: currentPath,
|
|
210
|
-
content: '',
|
|
211
|
-
type: 'directory',
|
|
212
|
-
createdAt: now,
|
|
213
|
-
updatedAt: now,
|
|
214
|
-
});
|
|
215
|
-
}
|
|
216
|
-
}
|
|
217
|
-
}
|
|
218
|
-
/**
|
|
219
|
-
* Delete a file at the specified path.
|
|
220
|
-
*
|
|
221
|
-
* @param path - Absolute path to the file to delete
|
|
222
|
-
* @throws {Error} ENOENT if file does not exist
|
|
223
|
-
* @throws {Error} EISDIR if path is a directory (use rmdir instead)
|
|
224
|
-
*/
|
|
225
|
-
async deleteFile(path) {
|
|
226
|
-
const normalizedPath = this.normalizePath(path);
|
|
227
|
-
// Check if it's a directory
|
|
228
|
-
const doc = await this.db.findOne(this.collection, { _id: normalizedPath });
|
|
229
|
-
if (doc && doc.type === 'directory') {
|
|
230
|
-
throw new Error(`EISDIR: illegal operation on a directory, '${normalizedPath}'`);
|
|
231
|
-
}
|
|
232
|
-
const result = await this.db.deleteOne(this.collection, { _id: normalizedPath });
|
|
233
|
-
if (result.deletedCount === 0) {
|
|
234
|
-
throw new Error(`ENOENT: no such file or directory, '${normalizedPath}'`);
|
|
235
|
-
}
|
|
236
|
-
}
|
|
237
|
-
/**
|
|
238
|
-
* List entries in a directory.
|
|
239
|
-
*
|
|
240
|
-
* Returns only direct children (not recursively nested).
|
|
241
|
-
* Results are sorted alphabetically.
|
|
242
|
-
*
|
|
243
|
-
* @param path - Absolute path to the directory
|
|
244
|
-
* @returns Promise resolving to array of entry names (not full paths)
|
|
245
|
-
* @throws {Error} ENOENT if directory does not exist
|
|
246
|
-
* @throws {Error} ENOTDIR if path is a file, not a directory
|
|
247
|
-
*/
|
|
248
|
-
async readdir(path) {
|
|
249
|
-
const normalizedPath = this.normalizePath(path);
|
|
250
|
-
// Check if the directory exists (explicit or implicit)
|
|
251
|
-
const dirDoc = await this.db.findOne(this.collection, { _id: normalizedPath });
|
|
252
|
-
// Pattern to match entries under this directory
|
|
253
|
-
const prefix = normalizedPath === '/' ? '' : normalizedPath;
|
|
254
|
-
// Find all files and directories under this path
|
|
255
|
-
const allDocs = await this.db.find(this.collection, {
|
|
256
|
-
path: { $regex: `^${this.escapeRegex(prefix)}/` },
|
|
257
|
-
});
|
|
258
|
-
// If directory doesn't exist and no children found
|
|
259
|
-
if (!dirDoc && allDocs.length === 0) {
|
|
260
|
-
throw new Error(`ENOENT: no such file or directory, '${normalizedPath}'`);
|
|
261
|
-
}
|
|
262
|
-
// If it's a file
|
|
263
|
-
if (dirDoc && dirDoc.type === 'file') {
|
|
264
|
-
throw new Error(`ENOTDIR: not a directory, '${normalizedPath}'`);
|
|
265
|
-
}
|
|
266
|
-
// Extract direct children only
|
|
267
|
-
const entries = new Set();
|
|
268
|
-
for (const doc of allDocs) {
|
|
269
|
-
const docPath = doc.path;
|
|
270
|
-
// Remove the prefix and leading slash
|
|
271
|
-
const relativePath = docPath.substring(prefix.length + 1);
|
|
272
|
-
// Get the first path segment (direct child)
|
|
273
|
-
const firstSegment = relativePath.split('/')[0];
|
|
274
|
-
if (firstSegment) {
|
|
275
|
-
entries.add(firstSegment);
|
|
276
|
-
}
|
|
277
|
-
}
|
|
278
|
-
return Array.from(entries).sort();
|
|
279
|
-
}
|
|
280
|
-
/**
|
|
281
|
-
* Create a directory at the specified path.
|
|
282
|
-
*
|
|
283
|
-
* Creates parent directories implicitly (behaves like mkdir -p).
|
|
284
|
-
* Idempotent - does not throw if directory already exists.
|
|
285
|
-
*
|
|
286
|
-
* @param path - Absolute path to the directory to create
|
|
287
|
-
* @throws {Error} EEXIST if a file (not directory) already exists at path
|
|
288
|
-
*/
|
|
289
|
-
async mkdir(path) {
|
|
290
|
-
const normalizedPath = this.normalizePath(path);
|
|
291
|
-
const now = new Date();
|
|
292
|
-
// Check if already exists as a file
|
|
293
|
-
const existing = await this.db.findOne(this.collection, { _id: normalizedPath });
|
|
294
|
-
if (existing) {
|
|
295
|
-
if (existing.type === 'file') {
|
|
296
|
-
throw new Error(`EEXIST: file already exists, '${normalizedPath}'`);
|
|
297
|
-
}
|
|
298
|
-
// Directory already exists - idempotent, just return
|
|
299
|
-
return;
|
|
300
|
-
}
|
|
301
|
-
// Create parent directories first
|
|
302
|
-
const parts = normalizedPath.split('/').filter(Boolean);
|
|
303
|
-
let currentPath = '';
|
|
304
|
-
for (let i = 0; i < parts.length; i++) {
|
|
305
|
-
currentPath += '/' + parts[i];
|
|
306
|
-
const exists = await this.db.findOne(this.collection, { _id: currentPath });
|
|
307
|
-
if (!exists) {
|
|
308
|
-
await this.db.insertOne(this.collection, {
|
|
309
|
-
_id: currentPath,
|
|
310
|
-
path: currentPath,
|
|
311
|
-
content: '',
|
|
312
|
-
type: 'directory',
|
|
313
|
-
createdAt: now,
|
|
314
|
-
updatedAt: now,
|
|
315
|
-
});
|
|
316
|
-
}
|
|
317
|
-
else if (exists.type === 'file' && i < parts.length - 1) {
|
|
318
|
-
throw new Error(`EEXIST: file already exists, '${currentPath}'`);
|
|
319
|
-
}
|
|
320
|
-
}
|
|
321
|
-
}
|
|
322
|
-
/**
|
|
323
|
-
* Remove an empty directory at the specified path.
|
|
324
|
-
*
|
|
325
|
-
* The directory must be empty (no files or subdirectories).
|
|
326
|
-
* Cannot remove the root directory.
|
|
327
|
-
*
|
|
328
|
-
* @param path - Absolute path to the directory to remove
|
|
329
|
-
* @throws {Error} ENOENT if directory does not exist
|
|
330
|
-
* @throws {Error} ENOTDIR if path is a file, not a directory
|
|
331
|
-
* @throws {Error} ENOTEMPTY if directory contains entries
|
|
332
|
-
* @throws {Error} EPERM if attempting to remove root directory
|
|
333
|
-
*/
|
|
334
|
-
async rmdir(path) {
|
|
335
|
-
const normalizedPath = this.normalizePath(path);
|
|
336
|
-
// Cannot remove root
|
|
337
|
-
if (normalizedPath === '/') {
|
|
338
|
-
throw new Error(`EPERM: operation not permitted, '/'`);
|
|
339
|
-
}
|
|
340
|
-
// Check if it exists
|
|
341
|
-
const doc = await this.db.findOne(this.collection, { _id: normalizedPath });
|
|
342
|
-
if (!doc) {
|
|
343
|
-
throw new Error(`ENOENT: no such file or directory, '${normalizedPath}'`);
|
|
344
|
-
}
|
|
345
|
-
if (doc.type === 'file') {
|
|
346
|
-
throw new Error(`ENOTDIR: not a directory, '${normalizedPath}'`);
|
|
347
|
-
}
|
|
348
|
-
// Check if empty
|
|
349
|
-
const prefix = normalizedPath;
|
|
350
|
-
const children = await this.db.find(this.collection, {
|
|
351
|
-
path: { $regex: `^${this.escapeRegex(prefix)}/` },
|
|
352
|
-
});
|
|
353
|
-
if (children.length > 0) {
|
|
354
|
-
throw new Error(`ENOTEMPTY: directory not empty, '${normalizedPath}'`);
|
|
355
|
-
}
|
|
356
|
-
await this.db.deleteOne(this.collection, { _id: normalizedPath });
|
|
357
|
-
}
|
|
358
|
-
/**
|
|
359
|
-
* Get file or directory statistics.
|
|
360
|
-
*
|
|
361
|
-
* Returns type, size, and timestamps for the entry.
|
|
362
|
-
* For directories, size is always 0.
|
|
363
|
-
* Supports implicit directories (directories inferred from file paths).
|
|
364
|
-
*
|
|
365
|
-
* @param path - Absolute path to the file or directory
|
|
366
|
-
* @returns Promise resolving to FileStat with type, size, createdAt, updatedAt
|
|
367
|
-
* @throws {Error} ENOENT if path does not exist
|
|
368
|
-
*/
|
|
369
|
-
async stat(path) {
|
|
370
|
-
const normalizedPath = this.normalizePath(path);
|
|
371
|
-
const doc = await this.db.findOne(this.collection, { _id: normalizedPath });
|
|
372
|
-
if (doc) {
|
|
373
|
-
return {
|
|
374
|
-
type: doc.type,
|
|
375
|
-
size: doc.type === 'file' ? doc.content.length : 0,
|
|
376
|
-
createdAt: new Date(doc.createdAt),
|
|
377
|
-
updatedAt: new Date(doc.updatedAt),
|
|
378
|
-
};
|
|
379
|
-
}
|
|
380
|
-
// Check if it's an implicit directory (has files inside)
|
|
381
|
-
const prefix = normalizedPath === '/' ? '' : normalizedPath;
|
|
382
|
-
const filesInside = await this.db.find(this.collection, {
|
|
383
|
-
path: { $regex: `^${this.escapeRegex(prefix)}/` },
|
|
384
|
-
});
|
|
385
|
-
if (filesInside.length > 0) {
|
|
386
|
-
// It's an implicit directory
|
|
387
|
-
const now = new Date();
|
|
388
|
-
return {
|
|
389
|
-
type: 'directory',
|
|
390
|
-
size: 0,
|
|
391
|
-
createdAt: now,
|
|
392
|
-
updatedAt: now,
|
|
393
|
-
};
|
|
394
|
-
}
|
|
395
|
-
throw new Error(`ENOENT: no such file or directory, '${normalizedPath}'`);
|
|
396
|
-
}
|
|
397
|
-
/**
|
|
398
|
-
* Check if a file or directory exists at the specified path.
|
|
399
|
-
*
|
|
400
|
-
* Does not throw errors for non-existent paths.
|
|
401
|
-
*
|
|
402
|
-
* @param path - Absolute path to check
|
|
403
|
-
* @returns Promise resolving to true if path exists, false otherwise
|
|
404
|
-
*/
|
|
405
|
-
async exists(path) {
|
|
406
|
-
try {
|
|
407
|
-
await this.stat(path);
|
|
408
|
-
return true;
|
|
409
|
-
}
|
|
410
|
-
catch {
|
|
411
|
-
return false;
|
|
412
|
-
}
|
|
413
|
-
}
|
|
414
|
-
/**
|
|
415
|
-
* Find files matching a glob pattern.
|
|
416
|
-
*
|
|
417
|
-
* Supports basic glob patterns:
|
|
418
|
-
* - `*` matches any characters except /
|
|
419
|
-
* - `**` matches any characters including /
|
|
420
|
-
* - `?` matches any single character except /
|
|
421
|
-
*
|
|
422
|
-
* Returns only files, not directories.
|
|
423
|
-
* Results are sorted alphabetically.
|
|
424
|
-
*
|
|
425
|
-
* @param pattern - Glob pattern to match against file paths
|
|
426
|
-
* @returns Promise resolving to array of matching file paths
|
|
427
|
-
*
|
|
428
|
-
* @example
|
|
429
|
-
* ```typescript
|
|
430
|
-
* const tsFiles = await fs.glob('**\/*.ts')
|
|
431
|
-
* const srcFiles = await fs.glob('/src/*.js')
|
|
432
|
-
* ```
|
|
433
|
-
*/
|
|
434
|
-
async glob(pattern) {
|
|
435
|
-
// Convert glob pattern to regex
|
|
436
|
-
const regexPattern = this.globToRegex(pattern);
|
|
437
|
-
const files = await this.db.find(this.collection, {
|
|
438
|
-
path: { $regex: regexPattern },
|
|
439
|
-
});
|
|
440
|
-
// Filter to only include files, not directories
|
|
441
|
-
return files
|
|
442
|
-
.filter((f) => f.type === 'file')
|
|
443
|
-
.map((f) => f.path)
|
|
444
|
-
.sort();
|
|
445
|
-
}
|
|
446
|
-
/**
|
|
447
|
-
* Convert a glob pattern to a regex string
|
|
448
|
-
*/
|
|
449
|
-
globToRegex(pattern) {
|
|
450
|
-
// Normalize the pattern
|
|
451
|
-
let normalized = pattern;
|
|
452
|
-
if (!normalized.startsWith('/')) {
|
|
453
|
-
normalized = '/' + normalized;
|
|
454
|
-
}
|
|
455
|
-
// Escape regex special characters except glob wildcards
|
|
456
|
-
let regex = normalized
|
|
457
|
-
.replace(/[.+^${}()|[\]\\]/g, '\\$&')
|
|
458
|
-
// ** matches any path segments
|
|
459
|
-
.replace(/\*\*/g, '<<DOUBLE_STAR>>')
|
|
460
|
-
// * matches any characters except /
|
|
461
|
-
.replace(/\*/g, '[^/]*')
|
|
462
|
-
// Restore ** as .*
|
|
463
|
-
.replace(/<<DOUBLE_STAR>>/g, '.*')
|
|
464
|
-
// ? matches single character except /
|
|
465
|
-
.replace(/\?/g, '[^/]');
|
|
466
|
-
return '^' + regex + '$';
|
|
467
|
-
}
|
|
468
|
-
}
|
|
469
|
-
//# sourceMappingURL=vfs.js.map
|
package/dist/agentfs/vfs.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"vfs.js","sourceRoot":"","sources":["../../src/agentfs/vfs.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AA4CH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgCG;AACH,MAAM,OAAO,eAAe;IAClB,EAAE,CAAiB;IACnB,UAAU,GAAG,iBAAiB,CAAA;IAEtC;;;;OAIG;IACH,YAAY,EAAmB;QAC7B,IAAI,CAAC,EAAE,GAAG,EAAE,CAAA;IACd,CAAC;IAED;;;;;;;;;;;;;OAaG;IACK,aAAa,CAAC,IAAY;QAChC,oBAAoB;QACpB,IAAI,CAAC,IAAI,EAAE,CAAC;YACV,OAAO,GAAG,CAAA;QACZ,CAAC;QAED,0DAA0D;QAC1D,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,EAAE,CAAC;YAC1B,IAAI,GAAG,GAAG,GAAG,IAAI,CAAA;QACnB,CAAC;QAED,6CAA6C;QAC7C,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;QAEhC,+CAA+C;QAC/C,IAAI,IAAI,CAAC,MAAM,GAAG,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;YAC1C,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAA;QAC1B,CAAC;QAED,8BAA8B;QAC9B,MAAM,KAAK,GAAG,IAAI,CAA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AAe;QACjC,wBAAwB;QACxB,IAAI,UAAU,GAAG,OAAO,CAAA;QACxB,IAAI,CAAC,UAAU,CAAC,UAAU,CAAC,GAAG,CAAC,EAAE,CAAC;YAChC,UAAU,GAAG,GAAG,GAAG,UAAU,CAAA;QAC/B,CAAC;QAED,wDAAwD;QACxD,IAAI,KAAK,GAAG,UAAU;aACnB,OAAO,CAAC,mBAAmB,EAAE,MAAM,CAAC;YACrC,+BAA+B;aAC9B,OAAO,CAAC,OAAO,EAAE,iBAAiB,CAAC;YACpC,oCAAoC;aACnC,OAAO,CAAC,KAAK,EAAE,OAAO,CAAC;YACxB,mBAAmB;aAClB,OAAO,CAAC,kBAAkB,EAAE,IAAI,CAAC;YAClC,sCAAsC;aACrC,OAAO,CAAC,KAAK,EAAE,MAAM,CAAC,CAAA;QAEzB,OAAO,GAAG,GAAG,KAAK,GAAG,GAAG,CAAA;IAC1B,CAAC;CACF"}
|
package/dist/cli/index.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/cli/index.ts"],"names":[],"mappings":";AACA;;;;;;;;;;;GAWG"}
|
package/dist/cli/mcp.d.ts
DELETED
|
@@ -1,119 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CLI MCP Command
|
|
3
|
-
*
|
|
4
|
-
* Implements the `mcp` command for the MondoDB CLI.
|
|
5
|
-
* Starts an MCP (Model Context Protocol) server that communicates via stdio.
|
|
6
|
-
*
|
|
7
|
-
* Features:
|
|
8
|
-
* - --connection <url>: Connect to a remote MondoDB Worker
|
|
9
|
-
* - --local <path>: Use a local SQLite database
|
|
10
|
-
*
|
|
11
|
-
* Usage:
|
|
12
|
-
* mongo.do mcp --connection https://my-worker.workers.dev
|
|
13
|
-
* mongo.do mcp --local ./data/local.db
|
|
14
|
-
*
|
|
15
|
-
* The MCP server exposes tools for AI agents to interact with the database:
|
|
16
|
-
* - search: Query documents
|
|
17
|
-
* - fetch: Retrieve full documents by ID
|
|
18
|
-
* - do: Execute operations (when enabled)
|
|
19
|
-
*
|
|
20
|
-
* @module cli/mcp
|
|
21
|
-
*/
|
|
22
|
-
import type { DatabaseAccess } from '../mcp/types.js';
|
|
23
|
-
/**
|
|
24
|
-
* Options for the MCP command
|
|
25
|
-
*/
|
|
26
|
-
export interface McpCommandOptions {
|
|
27
|
-
/** Remote connection URL (e.g., https://my-worker.workers.dev) */
|
|
28
|
-
connection?: string;
|
|
29
|
-
/** Local database file path */
|
|
30
|
-
local?: string;
|
|
31
|
-
/** Custom stdin stream (for testing) */
|
|
32
|
-
stdin?: NodeJS.ReadableStream;
|
|
33
|
-
/** Custom stdout stream (for testing) */
|
|
34
|
-
stdout?: NodeJS.WritableStream;
|
|
35
|
-
}
|
|
36
|
-
/**
|
|
37
|
-
* Controller for managing the MCP server lifecycle
|
|
38
|
-
*/
|
|
39
|
-
export interface McpServerController {
|
|
40
|
-
/** Whether the server is currently running */
|
|
41
|
-
readonly isRunning: boolean;
|
|
42
|
-
/** Stop the MCP server */
|
|
43
|
-
stop(): Promise<void>;
|
|
44
|
-
}
|
|
45
|
-
/**
|
|
46
|
-
* Program interface for command registration
|
|
47
|
-
* Compatible with Commander.js Command interface
|
|
48
|
-
*/
|
|
49
|
-
export interface McpProgram {
|
|
50
|
-
command(name: string): McpProgram;
|
|
51
|
-
description(desc: string): McpProgram;
|
|
52
|
-
option(flags: string, description?: string, defaultValue?: unknown): McpProgram;
|
|
53
|
-
action(fn: (...args: unknown[]) => void | Promise<void>): McpProgram;
|
|
54
|
-
}
|
|
55
|
-
/**
|
|
56
|
-
* Register the MCP command with the CLI program
|
|
57
|
-
*
|
|
58
|
-
* @param program - The CLI program to register the command with
|
|
59
|
-
*/
|
|
60
|
-
export declare function registerMcpCommand(program: McpProgram): void;
|
|
61
|
-
/**
|
|
62
|
-
* Start the MCP server with the given configuration.
|
|
63
|
-
*
|
|
64
|
-
* The server communicates via stdio using the Model Context Protocol (MCP).
|
|
65
|
-
* It exposes database operations as tools that AI agents can invoke.
|
|
66
|
-
*
|
|
67
|
-
* @param options - Server configuration options
|
|
68
|
-
* @returns Promise resolving to a controller for managing the server lifecycle
|
|
69
|
-
* @throws {Error} If neither --connection nor --local is provided
|
|
70
|
-
* @throws {Error} If both --connection and --local are provided
|
|
71
|
-
* @throws {Error} If the connection URL is invalid
|
|
72
|
-
*
|
|
73
|
-
* @example
|
|
74
|
-
* ```typescript
|
|
75
|
-
* // Remote connection
|
|
76
|
-
* const controller = await startMcpServer({
|
|
77
|
-
* connection: 'https://my-worker.workers.dev'
|
|
78
|
-
* })
|
|
79
|
-
*
|
|
80
|
-
* // Local SQLite database
|
|
81
|
-
* const controller = await startMcpServer({
|
|
82
|
-
* local: './data/local.db'
|
|
83
|
-
* })
|
|
84
|
-
*
|
|
85
|
-
* // Graceful shutdown
|
|
86
|
-
* await controller.stop()
|
|
87
|
-
* ```
|
|
88
|
-
*/
|
|
89
|
-
export declare function startMcpServer(options: McpCommandOptions): Promise<McpServerController>;
|
|
90
|
-
/**
|
|
91
|
-
* Create a DatabaseAccess instance for the MCP server.
|
|
92
|
-
*
|
|
93
|
-
* This factory function creates the appropriate database access implementation
|
|
94
|
-
* based on the provided options:
|
|
95
|
-
* - Remote: Uses RPC client to communicate with a MondoDB Worker
|
|
96
|
-
* - Local: Uses LocalSQLiteBackend for file-based storage (requires Bun)
|
|
97
|
-
*
|
|
98
|
-
* @param options - Connection options (either connection URL or local path)
|
|
99
|
-
* @returns Promise resolving to a DatabaseAccess instance
|
|
100
|
-
* @throws {Error} If neither connection nor local option is provided
|
|
101
|
-
*
|
|
102
|
-
* @example
|
|
103
|
-
* ```typescript
|
|
104
|
-
* // Remote database access
|
|
105
|
-
* const dbAccess = await createMcpDatabaseAccess({
|
|
106
|
-
* connection: 'https://my-worker.workers.dev'
|
|
107
|
-
* })
|
|
108
|
-
*
|
|
109
|
-
* // Local database access
|
|
110
|
-
* const dbAccess = await createMcpDatabaseAccess({
|
|
111
|
-
* local: './data/local.db'
|
|
112
|
-
* })
|
|
113
|
-
* ```
|
|
114
|
-
*/
|
|
115
|
-
export declare function createMcpDatabaseAccess(options: {
|
|
116
|
-
connection?: string | undefined;
|
|
117
|
-
local?: string | undefined;
|
|
118
|
-
}): Promise<DatabaseAccess>;
|
|
119
|
-
//# sourceMappingURL=mcp.d.ts.map
|
package/dist/cli/mcp.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"mcp.d.ts","sourceRoot":"","sources":["../../src/cli/mcp.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAe,MAAM,iBAAiB,CAAA;AAoBlE;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,kEAAkE;IAClE,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,+BAA+B;IAC/B,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,wCAAwC;IACxC,KAAK,CAAC,EAAE,MAAM,CAAC,cAAc,CAAA;IAC7B,yCAAyC;IACzC,MAAM,CAAC,EAAE,MAAM,CAAC,cAAc,CAAA;CAC/B;AAED;;GAEG;AACH,MAAM,WAAW,mBAAmB;IAClC,8CAA8C;IAC9C,QAAQ,CAAC,SAAS,EAAE,OAAO,CAAA;IAC3B,0BAA0B;IAC1B,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC,CAAA;CACtB;AAED;;;GAGG;AACH,MAAM,WAAW,UAAU;IACzB,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,UAAU,CAAA;IACjC,WAAW,CAAC,IAAI,EAAE,MAAM,GAAG,UAAU,CAAA;IACrC,MAAM,CAAC,KAAK,EAAE,MAAM,EAAE,WAAW,CAAC,EAAE,MAAM,EAAE,YAAY,CAAC,EAAE,OAAO,GAAG,UAAU,CAAA;IAC/E,MAAM,CAAC,EAAE,EAAE,CAAC,GAAG,IAAI,EAAE,OAAO,EAAE,KAAK,IA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