@ductape/sdk 0.1.6 → 0.1.8
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/package.json +5 -9
- package/dist/agents/agent-context.d.ts +0 -100
- package/dist/agents/agent-context.js +0 -604
- package/dist/agents/agent-context.js.map +0 -1
- package/dist/agents/agent-executor.d.ts +0 -180
- package/dist/agents/agent-executor.js +0 -715
- package/dist/agents/agent-executor.js.map +0 -1
- package/dist/agents/agents.service.d.ts +0 -310
- package/dist/agents/agents.service.js +0 -1255
- package/dist/agents/agents.service.js.map +0 -1
- package/dist/agents/index.d.ts +0 -55
- package/dist/agents/index.js +0 -110
- package/dist/agents/index.js.map +0 -1
- package/dist/agents/memory-manager.d.ts +0 -182
- package/dist/agents/memory-manager.js +0 -383
- package/dist/agents/memory-manager.js.map +0 -1
- package/dist/agents/tool-registry.d.ts +0 -141
- package/dist/agents/tool-registry.js +0 -355
- package/dist/agents/tool-registry.js.map +0 -1
- package/dist/agents/types/agents.types.d.ts +0 -1240
- package/dist/agents/types/agents.types.js +0 -12
- package/dist/agents/types/agents.types.js.map +0 -1
- package/dist/agents/types/index.d.ts +0 -6
- package/dist/agents/types/index.js +0 -23
- package/dist/agents/types/index.js.map +0 -1
- package/dist/agents/vector-store-adapter.d.ts +0 -108
- package/dist/agents/vector-store-adapter.js +0 -213
- package/dist/agents/vector-store-adapter.js.map +0 -1
- package/dist/api/services/appApi.service.d.ts +0 -78
- package/dist/api/services/appApi.service.js +0 -303
- package/dist/api/services/appApi.service.js.map +0 -1
- package/dist/api/services/logsApi.service.d.ts +0 -62
- package/dist/api/services/logsApi.service.js +0 -67
- package/dist/api/services/logsApi.service.js.map +0 -1
- package/dist/api/services/pricingApi.service.d.ts +0 -10
- package/dist/api/services/pricingApi.service.js +0 -34
- package/dist/api/services/pricingApi.service.js.map +0 -1
- package/dist/api/services/processorApi.service.d.ts +0 -927
- package/dist/api/services/processorApi.service.js +0 -787
- package/dist/api/services/processorApi.service.js.map +0 -1
- package/dist/api/services/productsApi.service.d.ts +0 -150
- package/dist/api/services/productsApi.service.js +0 -279
- package/dist/api/services/productsApi.service.js.map +0 -1
- package/dist/api/services/resilienceApi.service.d.ts +0 -106
- package/dist/api/services/resilienceApi.service.js +0 -224
- package/dist/api/services/resilienceApi.service.js.map +0 -1
- package/dist/api/services/secretsApi.service.d.ts +0 -51
- package/dist/api/services/secretsApi.service.js +0 -126
- package/dist/api/services/secretsApi.service.js.map +0 -1
- package/dist/api/services/userApi.service.d.ts +0 -10
- package/dist/api/services/userApi.service.js +0 -20
- package/dist/api/services/userApi.service.js.map +0 -1
- package/dist/api/services/webhooksApi.service.d.ts +0 -14
- package/dist/api/services/webhooksApi.service.js +0 -65
- package/dist/api/services/webhooksApi.service.js.map +0 -1
- package/dist/api/services/workflowApi.service.d.ts +0 -199
- package/dist/api/services/workflowApi.service.js +0 -201
- package/dist/api/services/workflowApi.service.js.map +0 -1
- package/dist/api/services/workspaceApi.service.d.ts +0 -20
- package/dist/api/services/workspaceApi.service.js +0 -54
- package/dist/api/services/workspaceApi.service.js.map +0 -1
- package/dist/api/urls.d.ts +0 -136
- package/dist/api/urls.js +0 -185
- package/dist/api/urls.js.map +0 -1
- package/dist/api/utils/auth.utils.d.ts +0 -10
- package/dist/api/utils/auth.utils.js +0 -24
- package/dist/api/utils/auth.utils.js.map +0 -1
- package/dist/api/utils/cache.utils.d.ts +0 -3
- package/dist/api/utils/cache.utils.js +0 -18
- package/dist/api/utils/cache.utils.js.map +0 -1
- package/dist/api/utils/strings.utils.d.ts +0 -7
- package/dist/api/utils/strings.utils.js +0 -64
- package/dist/api/utils/strings.utils.js.map +0 -1
- package/dist/apps/services/app.service.d.ts +0 -126
- package/dist/apps/services/app.service.js +0 -1436
- package/dist/apps/services/app.service.js.map +0 -1
- package/dist/apps/utils/auth-context-manager.d.ts +0 -137
- package/dist/apps/utils/auth-context-manager.js +0 -248
- package/dist/apps/utils/auth-context-manager.js.map +0 -1
- package/dist/apps/utils/credential-manager.d.ts +0 -128
- package/dist/apps/utils/credential-manager.js +0 -199
- package/dist/apps/utils/credential-manager.js.map +0 -1
- package/dist/apps/utils/index.d.ts +0 -10
- package/dist/apps/utils/index.js +0 -54
- package/dist/apps/utils/index.js.map +0 -1
- package/dist/apps/utils/input-helpers.d.ts +0 -67
- package/dist/apps/utils/input-helpers.js +0 -185
- package/dist/apps/utils/input-helpers.js.map +0 -1
- package/dist/apps/utils/input-resolver.d.ts +0 -165
- package/dist/apps/utils/input-resolver.js +0 -477
- package/dist/apps/utils/input-resolver.js.map +0 -1
- package/dist/apps/utils/oauth-manager.d.ts +0 -196
- package/dist/apps/utils/oauth-manager.js +0 -429
- package/dist/apps/utils/oauth-manager.js.map +0 -1
- package/dist/apps/utils/objects.utils.d.ts +0 -4
- package/dist/apps/utils/objects.utils.js +0 -59
- package/dist/apps/utils/objects.utils.js.map +0 -1
- package/dist/apps/utils/string.utils.d.ts +0 -9
- package/dist/apps/utils/string.utils.js +0 -89
- package/dist/apps/utils/string.utils.js.map +0 -1
- package/dist/apps/validators/index.d.ts +0 -17
- package/dist/apps/validators/index.js +0 -39
- package/dist/apps/validators/index.js.map +0 -1
- package/dist/apps/validators/joi-validators/create.app.validator.d.ts +0 -3
- package/dist/apps/validators/joi-validators/create.app.validator.js +0 -43
- package/dist/apps/validators/joi-validators/create.app.validator.js.map +0 -1
- package/dist/apps/validators/joi-validators/create.appAction.validator.d.ts +0 -3
- package/dist/apps/validators/joi-validators/create.appAction.validator.js +0 -72
- package/dist/apps/validators/joi-validators/create.appAction.validator.js.map +0 -1
- package/dist/apps/validators/joi-validators/create.appActionResponse.validator.d.ts +0 -7
- package/dist/apps/validators/joi-validators/create.appActionResponse.validator.js +0 -81
- package/dist/apps/validators/joi-validators/create.appActionResponse.validator.js.map +0 -1
- package/dist/apps/validators/joi-validators/create.appAuth.validator.d.ts +0 -3
- package/dist/apps/validators/joi-validators/create.appAuth.validator.js +0 -64
- package/dist/apps/validators/joi-validators/create.appAuth.validator.js.map +0 -1
- package/dist/apps/validators/joi-validators/create.appBody.validators.d.ts +0 -4
- package/dist/apps/validators/joi-validators/create.appBody.validators.js +0 -44
- package/dist/apps/validators/joi-validators/create.appBody.validators.js.map +0 -1
- package/dist/apps/validators/joi-validators/create.appConstants.validator.d.ts +0 -4
- package/dist/apps/validators/joi-validators/create.appConstants.validator.js +0 -45
- package/dist/apps/validators/joi-validators/create.appConstants.validator.js.map +0 -1
- package/dist/apps/validators/joi-validators/create.appEnv.validator.d.ts +0 -4
- package/dist/apps/validators/joi-validators/create.appEnv.validator.js +0 -50
- package/dist/apps/validators/joi-validators/create.appEnv.validator.js.map +0 -1
- package/dist/apps/validators/joi-validators/create.appVariable.validator.d.ts +0 -4
- package/dist/apps/validators/joi-validators/create.appVariable.validator.js +0 -47
- package/dist/apps/validators/joi-validators/create.appVariable.validator.js.map +0 -1
- package/dist/apps/validators/joi-validators/create.appWebhook.validator.d.ts +0 -4
- package/dist/apps/validators/joi-validators/create.appWebhook.validator.js +0 -60
- package/dist/apps/validators/joi-validators/create.appWebhook.validator.js.map +0 -1
- package/dist/apps/validators/joi-validators/create.appWebhookEvent.validator.d.ts +0 -3
- package/dist/apps/validators/joi-validators/create.appWebhookEvent.validator.js +0 -48
- package/dist/apps/validators/joi-validators/create.appWebhookEvent.validator.js.map +0 -1
- package/dist/apps/validators/joi-validators/sample.validator.d.ts +0 -6
- package/dist/apps/validators/joi-validators/sample.validator.js +0 -65
- package/dist/apps/validators/joi-validators/sample.validator.js.map +0 -1
- package/dist/apps/validators/joi-validators/update.app.validator.d.ts +0 -4
- package/dist/apps/validators/joi-validators/update.app.validator.js +0 -66
- package/dist/apps/validators/joi-validators/update.app.validator.js.map +0 -1
- package/dist/apps/validators/joi-validators/update.appAction.validator.d.ts +0 -4
- package/dist/apps/validators/joi-validators/update.appAction.validator.js +0 -76
- package/dist/apps/validators/joi-validators/update.appAction.validator.js.map +0 -1
- package/dist/apps/validators/joi-validators/update.appActionResponse.validator.d.ts +0 -3
- package/dist/apps/validators/joi-validators/update.appActionResponse.validator.js +0 -57
- package/dist/apps/validators/joi-validators/update.appActionResponse.validator.js.map +0 -1
- package/dist/apps/validators/joi-validators/update.appAuth.validator.d.ts +0 -4
- package/dist/apps/validators/joi-validators/update.appAuth.validator.js +0 -52
- package/dist/apps/validators/joi-validators/update.appAuth.validator.js.map +0 -1
- package/dist/apps/validators/joi-validators/update.appConstants.validator.d.ts +0 -4
- package/dist/apps/validators/joi-validators/update.appConstants.validator.js +0 -45
- package/dist/apps/validators/joi-validators/update.appConstants.validator.js.map +0 -1
- package/dist/apps/validators/joi-validators/update.appEnv.validator.d.ts +0 -4
- package/dist/apps/validators/joi-validators/update.appEnv.validator.js +0 -50
- package/dist/apps/validators/joi-validators/update.appEnv.validator.js.map +0 -1
- package/dist/apps/validators/joi-validators/update.appVariables.validator.d.ts +0 -4
- package/dist/apps/validators/joi-validators/update.appVariables.validator.js +0 -47
- package/dist/apps/validators/joi-validators/update.appVariables.validator.js.map +0 -1
- package/dist/apps/validators/joi-validators/update.appWebhook.validator.d.ts +0 -4
- package/dist/apps/validators/joi-validators/update.appWebhook.validator.js +0 -59
- package/dist/apps/validators/joi-validators/update.appWebhook.validator.js.map +0 -1
- package/dist/apps/validators/joi-validators/update.appWebhookEvent.validator.d.ts +0 -3
- package/dist/apps/validators/joi-validators/update.appWebhookEvent.validator.js +0 -48
- package/dist/apps/validators/joi-validators/update.appWebhookEvent.validator.js.map +0 -1
- package/dist/apps/validators/joi-validators/update.validation.entityData.validator.d.ts +0 -3
- package/dist/apps/validators/joi-validators/update.validation.entityData.validator.js +0 -60
- package/dist/apps/validators/joi-validators/update.validation.entityData.validator.js.map +0 -1
- package/dist/bin.d.ts +0 -26
- package/dist/bin.js +0 -28
- package/dist/bin.js.map +0 -1
- package/dist/brokers/brokers.service.d.ts +0 -438
- package/dist/brokers/brokers.service.js +0 -1294
- package/dist/brokers/brokers.service.js.map +0 -1
- package/dist/brokers/index.d.ts +0 -46
- package/dist/brokers/index.js +0 -83
- package/dist/brokers/index.js.map +0 -1
- package/dist/brokers/types/index.d.ts +0 -569
- package/dist/brokers/types/index.js +0 -8
- package/dist/brokers/types/index.js.map +0 -1
- package/dist/brokers/utils/broker.util.d.ts +0 -33
- package/dist/brokers/utils/broker.util.js +0 -125
- package/dist/brokers/utils/broker.util.js.map +0 -1
- package/dist/brokers/utils/providers/aws-sqs.service.d.ts +0 -16
- package/dist/brokers/utils/providers/aws-sqs.service.js +0 -71
- package/dist/brokers/utils/providers/aws-sqs.service.js.map +0 -1
- package/dist/brokers/utils/providers/google-pubsub.service.d.ts +0 -16
- package/dist/brokers/utils/providers/google-pubsub.service.js +0 -43
- package/dist/brokers/utils/providers/google-pubsub.service.js.map +0 -1
- package/dist/brokers/utils/providers/index.d.ts +0 -6
- package/dist/brokers/utils/providers/index.js +0 -16
- package/dist/brokers/utils/providers/index.js.map +0 -1
- package/dist/brokers/utils/providers/kafka.service.d.ts +0 -23
- package/dist/brokers/utils/providers/kafka.service.js +0 -131
- package/dist/brokers/utils/providers/kafka.service.js.map +0 -1
- package/dist/brokers/utils/providers/nats.service.d.ts +0 -18
- package/dist/brokers/utils/providers/nats.service.js +0 -63
- package/dist/brokers/utils/providers/nats.service.js.map +0 -1
- package/dist/brokers/utils/providers/rabbitmq.service.d.ts +0 -25
- package/dist/brokers/utils/providers/rabbitmq.service.js +0 -138
- package/dist/brokers/utils/providers/rabbitmq.service.js.map +0 -1
- package/dist/brokers/utils/providers/redis.service.d.ts +0 -18
- package/dist/brokers/utils/providers/redis.service.js +0 -93
- package/dist/brokers/utils/providers/redis.service.js.map +0 -1
- package/dist/cache/cache.manager.d.ts +0 -308
- package/dist/cache/cache.manager.js +0 -900
- package/dist/cache/cache.manager.js.map +0 -1
- package/dist/cache/cache.service.d.ts +0 -192
- package/dist/cache/cache.service.js +0 -596
- package/dist/cache/cache.service.js.map +0 -1
- package/dist/cache/index.d.ts +0 -52
- package/dist/cache/index.js +0 -81
- package/dist/cache/index.js.map +0 -1
- package/dist/cache/types/index.d.ts +0 -112
- package/dist/cache/types/index.js +0 -6
- package/dist/cache/types/index.js.map +0 -1
- package/dist/clients/apps.client.d.ts +0 -4
- package/dist/clients/apps.client.js +0 -31
- package/dist/clients/apps.client.js.map +0 -1
- package/dist/clients/email.client.d.ts +0 -4
- package/dist/clients/email.client.js +0 -29
- package/dist/clients/email.client.js.map +0 -1
- package/dist/clients/expo.client.d.ts +0 -3
- package/dist/clients/expo.client.js +0 -28
- package/dist/clients/expo.client.js.map +0 -1
- package/dist/clients/function.client.d.ts +0 -3
- package/dist/clients/function.client.js +0 -27
- package/dist/clients/function.client.js.map +0 -1
- package/dist/clients/http.client.d.ts +0 -3
- package/dist/clients/http.client.js +0 -27
- package/dist/clients/http.client.js.map +0 -1
- package/dist/clients/logs.client.d.ts +0 -4
- package/dist/clients/logs.client.js +0 -34
- package/dist/clients/logs.client.js.map +0 -1
- package/dist/clients/pricing.client.d.ts +0 -4
- package/dist/clients/pricing.client.js +0 -34
- package/dist/clients/pricing.client.js.map +0 -1
- package/dist/clients/products.client.d.ts +0 -3
- package/dist/clients/products.client.js +0 -32
- package/dist/clients/products.client.js.map +0 -1
- package/dist/clients/users.client.d.ts +0 -4
- package/dist/clients/users.client.js +0 -34
- package/dist/clients/users.client.js.map +0 -1
- package/dist/clients/webhooks.client.d.ts +0 -4
- package/dist/clients/webhooks.client.js +0 -34
- package/dist/clients/webhooks.client.js.map +0 -1
- package/dist/clients/workspace.client.d.ts +0 -7
- package/dist/clients/workspace.client.js +0 -39
- package/dist/clients/workspace.client.js.map +0 -1
- package/dist/database/actions/action-manager.d.ts +0 -170
- package/dist/database/actions/action-manager.js +0 -465
- package/dist/database/actions/action-manager.js.map +0 -1
- package/dist/database/actions/index.d.ts +0 -6
- package/dist/database/actions/index.js +0 -13
- package/dist/database/actions/index.js.map +0 -1
- package/dist/database/adapters/adapter.factory.d.ts +0 -62
- package/dist/database/adapters/adapter.factory.js +0 -97
- package/dist/database/adapters/adapter.factory.js.map +0 -1
- package/dist/database/adapters/base.adapter.d.ts +0 -423
- package/dist/database/adapters/base.adapter.js +0 -260
- package/dist/database/adapters/base.adapter.js.map +0 -1
- package/dist/database/adapters/cassandra.adapter.d.ts +0 -92
- package/dist/database/adapters/cassandra.adapter.js +0 -1091
- package/dist/database/adapters/cassandra.adapter.js.map +0 -1
- package/dist/database/adapters/dynamodb.adapter.d.ts +0 -110
- package/dist/database/adapters/dynamodb.adapter.js +0 -1564
- package/dist/database/adapters/dynamodb.adapter.js.map +0 -1
- package/dist/database/adapters/index.d.ts +0 -11
- package/dist/database/adapters/index.js +0 -27
- package/dist/database/adapters/index.js.map +0 -1
- package/dist/database/adapters/mariadb.adapter.d.ts +0 -100
- package/dist/database/adapters/mariadb.adapter.js +0 -247
- package/dist/database/adapters/mariadb.adapter.js.map +0 -1
- package/dist/database/adapters/mongodb.adapter.d.ts +0 -121
- package/dist/database/adapters/mongodb.adapter.js +0 -1284
- package/dist/database/adapters/mongodb.adapter.js.map +0 -1
- package/dist/database/adapters/mysql.adapter.d.ts +0 -86
- package/dist/database/adapters/mysql.adapter.js +0 -1371
- package/dist/database/adapters/mysql.adapter.js.map +0 -1
- package/dist/database/adapters/postgresql.adapter.d.ts +0 -90
- package/dist/database/adapters/postgresql.adapter.js +0 -1487
- package/dist/database/adapters/postgresql.adapter.js.map +0 -1
- package/dist/database/databases.service.d.ts +0 -1496
- package/dist/database/databases.service.js +0 -3294
- package/dist/database/databases.service.js.map +0 -1
- package/dist/database/index.d.ts +0 -46
- package/dist/database/index.js +0 -109
- package/dist/database/index.js.map +0 -1
- package/dist/database/migrations/index.d.ts +0 -6
- package/dist/database/migrations/index.js +0 -12
- package/dist/database/migrations/index.js.map +0 -1
- package/dist/database/migrations/migration-engine.d.ts +0 -136
- package/dist/database/migrations/migration-engine.js +0 -1421
- package/dist/database/migrations/migration-engine.js.map +0 -1
- package/dist/database/operators/aggregation-builder.d.ts +0 -67
- package/dist/database/operators/aggregation-builder.js +0 -841
- package/dist/database/operators/aggregation-builder.js.map +0 -1
- package/dist/database/operators/index.d.ts +0 -7
- package/dist/database/operators/index.js +0 -15
- package/dist/database/operators/index.js.map +0 -1
- package/dist/database/operators/query-builder.d.ts +0 -69
- package/dist/database/operators/query-builder.js +0 -447
- package/dist/database/operators/query-builder.js.map +0 -1
- package/dist/database/presave/decrypt.d.ts +0 -25
- package/dist/database/presave/decrypt.js +0 -146
- package/dist/database/presave/decrypt.js.map +0 -1
- package/dist/database/presave/index.d.ts +0 -9
- package/dist/database/presave/index.js +0 -18
- package/dist/database/presave/index.js.map +0 -1
- package/dist/database/presave/presave-processor.d.ts +0 -148
- package/dist/database/presave/presave-processor.js +0 -702
- package/dist/database/presave/presave-processor.js.map +0 -1
- package/dist/database/schema/index.d.ts +0 -7
- package/dist/database/schema/index.js +0 -13
- package/dist/database/schema/index.js.map +0 -1
- package/dist/database/schema/schema-manager.d.ts +0 -258
- package/dist/database/schema/schema-manager.js +0 -638
- package/dist/database/schema/schema-manager.js.map +0 -1
- package/dist/database/transactions/index.d.ts +0 -6
- package/dist/database/transactions/index.js +0 -13
- package/dist/database/transactions/index.js.map +0 -1
- package/dist/database/transactions/transaction-manager.d.ts +0 -113
- package/dist/database/transactions/transaction-manager.js +0 -344
- package/dist/database/transactions/transaction-manager.js.map +0 -1
- package/dist/database/triggers/index.d.ts +0 -7
- package/dist/database/triggers/index.js +0 -14
- package/dist/database/triggers/index.js.map +0 -1
- package/dist/database/triggers/trigger-processor.d.ts +0 -239
- package/dist/database/triggers/trigger-processor.js +0 -1034
- package/dist/database/triggers/trigger-processor.js.map +0 -1
- package/dist/database/types/action.interface.d.ts +0 -148
- package/dist/database/types/action.interface.js +0 -6
- package/dist/database/types/action.interface.js.map +0 -1
- package/dist/database/types/aggregation.interface.d.ts +0 -185
- package/dist/database/types/aggregation.interface.js +0 -6
- package/dist/database/types/aggregation.interface.js.map +0 -1
- package/dist/database/types/connection.interface.d.ts +0 -137
- package/dist/database/types/connection.interface.js +0 -6
- package/dist/database/types/connection.interface.js.map +0 -1
- package/dist/database/types/dashboard.interface.d.ts +0 -74
- package/dist/database/types/dashboard.interface.js +0 -7
- package/dist/database/types/dashboard.interface.js.map +0 -1
- package/dist/database/types/enums.d.ts +0 -195
- package/dist/database/types/enums.js +0 -244
- package/dist/database/types/enums.js.map +0 -1
- package/dist/database/types/index.d.ts +0 -15
- package/dist/database/types/index.js +0 -31
- package/dist/database/types/index.js.map +0 -1
- package/dist/database/types/migration.interface.d.ts +0 -686
- package/dist/database/types/migration.interface.js +0 -9
- package/dist/database/types/migration.interface.js.map +0 -1
- package/dist/database/types/presave.interface.d.ts +0 -292
- package/dist/database/types/presave.interface.js +0 -60
- package/dist/database/types/presave.interface.js.map +0 -1
- package/dist/database/types/query.interface.d.ts +0 -205
- package/dist/database/types/query.interface.js +0 -6
- package/dist/database/types/query.interface.js.map +0 -1
- package/dist/database/types/schema.interface.d.ts +0 -412
- package/dist/database/types/schema.interface.js +0 -6
- package/dist/database/types/schema.interface.js.map +0 -1
- package/dist/database/types/transaction.interface.d.ts +0 -84
- package/dist/database/types/transaction.interface.js +0 -6
- package/dist/database/types/transaction.interface.js.map +0 -1
- package/dist/database/types/trigger.interface.d.ts +0 -612
- package/dist/database/types/trigger.interface.js +0 -121
- package/dist/database/types/trigger.interface.js.map +0 -1
- package/dist/database/types/write.interface.d.ts +0 -216
- package/dist/database/types/write.interface.js +0 -6
- package/dist/database/types/write.interface.js.map +0 -1
- package/dist/database/utils/database-error.d.ts +0 -96
- package/dist/database/utils/database-error.js +0 -221
- package/dist/database/utils/database-error.js.map +0 -1
- package/dist/database/utils/index.d.ts +0 -6
- package/dist/database/utils/index.js +0 -11
- package/dist/database/utils/index.js.map +0 -1
- package/dist/graph/adapters/adapter.factory.d.ts +0 -47
- package/dist/graph/adapters/adapter.factory.js +0 -77
- package/dist/graph/adapters/adapter.factory.js.map +0 -1
- package/dist/graph/adapters/arangodb.adapter.d.ts +0 -86
- package/dist/graph/adapters/arangodb.adapter.js +0 -1588
- package/dist/graph/adapters/arangodb.adapter.js.map +0 -1
- package/dist/graph/adapters/base.adapter.d.ts +0 -264
- package/dist/graph/adapters/base.adapter.js +0 -156
- package/dist/graph/adapters/base.adapter.js.map +0 -1
- package/dist/graph/adapters/index.d.ts +0 -11
- package/dist/graph/adapters/index.js +0 -21
- package/dist/graph/adapters/index.js.map +0 -1
- package/dist/graph/adapters/memgraph.adapter.d.ts +0 -110
- package/dist/graph/adapters/memgraph.adapter.js +0 -1452
- package/dist/graph/adapters/memgraph.adapter.js.map +0 -1
- package/dist/graph/adapters/neo4j.adapter.d.ts +0 -81
- package/dist/graph/adapters/neo4j.adapter.js +0 -1317
- package/dist/graph/adapters/neo4j.adapter.js.map +0 -1
- package/dist/graph/adapters/neptune.adapter.d.ts +0 -82
- package/dist/graph/adapters/neptune.adapter.js +0 -1369
- package/dist/graph/adapters/neptune.adapter.js.map +0 -1
- package/dist/graph/graphs.service.d.ts +0 -617
- package/dist/graph/graphs.service.js +0 -2594
- package/dist/graph/graphs.service.js.map +0 -1
- package/dist/graph/index.d.ts +0 -57
- package/dist/graph/index.js +0 -77
- package/dist/graph/index.js.map +0 -1
- package/dist/graph/transactions/index.d.ts +0 -4
- package/dist/graph/transactions/index.js +0 -9
- package/dist/graph/transactions/index.js.map +0 -1
- package/dist/graph/transactions/transaction-manager.d.ts +0 -61
- package/dist/graph/transactions/transaction-manager.js +0 -126
- package/dist/graph/transactions/transaction-manager.js.map +0 -1
- package/dist/graph/types/connection.interface.d.ts +0 -149
- package/dist/graph/types/connection.interface.js +0 -9
- package/dist/graph/types/connection.interface.js.map +0 -1
- package/dist/graph/types/enums.d.ts +0 -101
- package/dist/graph/types/enums.js +0 -114
- package/dist/graph/types/enums.js.map +0 -1
- package/dist/graph/types/index.d.ts +0 -13
- package/dist/graph/types/index.js +0 -20
- package/dist/graph/types/index.js.map +0 -1
- package/dist/graph/types/node.interface.d.ts +0 -248
- package/dist/graph/types/node.interface.js +0 -9
- package/dist/graph/types/node.interface.js.map +0 -1
- package/dist/graph/types/query.interface.d.ts +0 -175
- package/dist/graph/types/query.interface.js +0 -9
- package/dist/graph/types/query.interface.js.map +0 -1
- package/dist/graph/types/relationship.interface.d.ts +0 -207
- package/dist/graph/types/relationship.interface.js +0 -9
- package/dist/graph/types/relationship.interface.js.map +0 -1
- package/dist/graph/types/schema.interface.d.ts +0 -295
- package/dist/graph/types/schema.interface.js +0 -9
- package/dist/graph/types/schema.interface.js.map +0 -1
- package/dist/graph/types/transaction.interface.d.ts +0 -55
- package/dist/graph/types/transaction.interface.js +0 -9
- package/dist/graph/types/transaction.interface.js.map +0 -1
- package/dist/graph/types/traversal.interface.d.ts +0 -181
- package/dist/graph/types/traversal.interface.js +0 -9
- package/dist/graph/types/traversal.interface.js.map +0 -1
- package/dist/graph/utils/graph-error.d.ts +0 -71
- package/dist/graph/utils/graph-error.js +0 -142
- package/dist/graph/utils/graph-error.js.map +0 -1
- package/dist/graph/utils/index.d.ts +0 -4
- package/dist/graph/utils/index.js +0 -9
- package/dist/graph/utils/index.js.map +0 -1
- package/dist/imports/imports.repo.d.ts +0 -0
- package/dist/imports/imports.repo.js +0 -1
- package/dist/imports/imports.repo.js.map +0 -1
- package/dist/imports/imports.service.d.ts +0 -23
- package/dist/imports/imports.service.js +0 -71
- package/dist/imports/imports.service.js.map +0 -1
- package/dist/imports/imports.types.d.ts +0 -350
- package/dist/imports/imports.types.js +0 -33
- package/dist/imports/imports.types.js.map +0 -1
- package/dist/imports/openAPI3.0.types.d.ts +0 -52
- package/dist/imports/openAPI3.0.types.js +0 -3
- package/dist/imports/openAPI3.0.types.js.map +0 -1
- package/dist/imports/repos/openApi.repo.d.ts +0 -6
- package/dist/imports/repos/openApi.repo.js +0 -422
- package/dist/imports/repos/openApi.repo.js.map +0 -1
- package/dist/imports/repos/postmanV21.repo.d.ts +0 -14
- package/dist/imports/repos/postmanV21.repo.js +0 -257
- package/dist/imports/repos/postmanV21.repo.js.map +0 -1
- package/dist/imports/utils/imports.utils.d.ts +0 -80
- package/dist/imports/utils/imports.utils.js +0 -114
- package/dist/imports/utils/imports.utils.js.map +0 -1
- package/dist/imports/validators/index.d.ts +0 -0
- package/dist/imports/validators/index.js +0 -1
- package/dist/imports/validators/index.js.map +0 -1
- package/dist/imports/validators/joi-validators/postmanV21.validator.d.ts +0 -5
- package/dist/imports/validators/joi-validators/postmanV21.validator.js +0 -96
- package/dist/imports/validators/joi-validators/postmanV21.validator.js.map +0 -1
- package/dist/index.d.ts +0 -4021
- package/dist/index.js +0 -5895
- package/dist/index.js.map +0 -1
- package/dist/init.interface.d.ts +0 -407
- package/dist/init.interface.js +0 -3
- package/dist/init.interface.js.map +0 -1
- package/dist/inputs/inputs.repo.d.ts +0 -7
- package/dist/inputs/inputs.repo.js +0 -16
- package/dist/inputs/inputs.repo.js.map +0 -1
- package/dist/inputs/inputs.service.d.ts +0 -61
- package/dist/inputs/inputs.service.js +0 -468
- package/dist/inputs/inputs.service.js.map +0 -1
- package/dist/inputs/utils/inputs.utils.create.d.ts +0 -11
- package/dist/inputs/utils/inputs.utils.create.js +0 -273
- package/dist/inputs/utils/inputs.utils.create.js.map +0 -1
- package/dist/inputs/validators/inputs.validator.parse.d.ts +0 -4
- package/dist/inputs/validators/inputs.validator.parse.js +0 -53
- package/dist/inputs/validators/inputs.validator.parse.js.map +0 -1
- package/dist/jobs/index.d.ts +0 -38
- package/dist/jobs/index.js +0 -50
- package/dist/jobs/index.js.map +0 -1
- package/dist/jobs/jobs.service.d.ts +0 -154
- package/dist/jobs/jobs.service.js +0 -491
- package/dist/jobs/jobs.service.js.map +0 -1
- package/dist/jobs/jobs.state.d.ts +0 -113
- package/dist/jobs/jobs.state.js +0 -447
- package/dist/jobs/jobs.state.js.map +0 -1
- package/dist/jobs/types.d.ts +0 -449
- package/dist/jobs/types.js +0 -74
- package/dist/jobs/types.js.map +0 -1
- package/dist/logs/logs.repo.d.ts +0 -6
- package/dist/logs/logs.repo.js +0 -12
- package/dist/logs/logs.repo.js.map +0 -1
- package/dist/logs/logs.service.d.ts +0 -30
- package/dist/logs/logs.service.js +0 -89
- package/dist/logs/logs.service.js.map +0 -1
- package/dist/logs/logs.types.d.ts +0 -85
- package/dist/logs/logs.types.js +0 -52
- package/dist/logs/logs.types.js.map +0 -1
- package/dist/logs/utils/logs.utils.create.d.ts +0 -0
- package/dist/logs/utils/logs.utils.create.js +0 -1
- package/dist/logs/utils/logs.utils.create.js.map +0 -1
- package/dist/logs/utils/logs.utils.errors.d.ts +0 -2
- package/dist/logs/utils/logs.utils.errors.js +0 -8
- package/dist/logs/utils/logs.utils.errors.js.map +0 -1
- package/dist/models/index.d.ts +0 -6
- package/dist/models/index.js +0 -11
- package/dist/models/index.js.map +0 -1
- package/dist/models/models.service.d.ts +0 -137
- package/dist/models/models.service.js +0 -195
- package/dist/models/models.service.js.map +0 -1
- package/dist/notifications/index.d.ts +0 -13
- package/dist/notifications/index.js +0 -26
- package/dist/notifications/index.js.map +0 -1
- package/dist/notifications/notifications.service.d.ts +0 -268
- package/dist/notifications/notifications.service.js +0 -907
- package/dist/notifications/notifications.service.js.map +0 -1
- package/dist/notifications/types/index.d.ts +0 -4
- package/dist/notifications/types/index.js +0 -21
- package/dist/notifications/types/index.js.map +0 -1
- package/dist/notifications/types/notifications.types.d.ts +0 -454
- package/dist/notifications/types/notifications.types.js +0 -51
- package/dist/notifications/types/notifications.types.js.map +0 -1
- package/dist/parsers/index.d.ts +0 -3
- package/dist/parsers/index.js +0 -27
- package/dist/parsers/index.js.map +0 -1
- package/dist/parsers/pipelines/postman.pipelines.d.ts +0 -15
- package/dist/parsers/pipelines/postman.pipelines.js +0 -103
- package/dist/parsers/pipelines/postman.pipelines.js.map +0 -1
- package/dist/parsers/types/postman.types.d.ts +0 -200
- package/dist/parsers/types/postman.types.js +0 -3
- package/dist/parsers/types/postman.types.js.map +0 -1
- package/dist/parsers/utils/postman.utils.d.ts +0 -12
- package/dist/parsers/utils/postman.utils.js +0 -116
- package/dist/parsers/utils/postman.utils.js.map +0 -1
- package/dist/parsers/validators/postman-auth.validators.d.ts +0 -10
- package/dist/parsers/validators/postman-auth.validators.js +0 -127
- package/dist/parsers/validators/postman-auth.validators.js.map +0 -1
- package/dist/parsers/validators/postman-request.validators.d.ts +0 -13
- package/dist/parsers/validators/postman-request.validators.js +0 -139
- package/dist/parsers/validators/postman-request.validators.js.map +0 -1
- package/dist/parsers/validators/postman-response.validators.d.ts +0 -13
- package/dist/parsers/validators/postman-response.validators.js +0 -150
- package/dist/parsers/validators/postman-response.validators.js.map +0 -1
- package/dist/parsers/validators/postman-variable.validators.d.ts +0 -14
- package/dist/parsers/validators/postman-variable.validators.js +0 -163
- package/dist/parsers/validators/postman-variable.validators.js.map +0 -1
- package/dist/pricing/pricing.repo.d.ts +0 -0
- package/dist/pricing/pricing.repo.js +0 -1
- package/dist/pricing/pricing.repo.js.map +0 -1
- package/dist/pricing/pricing.service.d.ts +0 -24
- package/dist/pricing/pricing.service.js +0 -51
- package/dist/pricing/pricing.service.js.map +0 -1
- package/dist/pricing/pricing.types.d.ts +0 -76
- package/dist/pricing/pricing.types.js +0 -21
- package/dist/pricing/pricing.types.js.map +0 -1
- package/dist/pricing/utils/string.utils.d.ts +0 -1
- package/dist/pricing/utils/string.utils.js +0 -9
- package/dist/pricing/utils/string.utils.js.map +0 -1
- package/dist/processor/repos/mongo.repo.d.ts +0 -39
- package/dist/processor/repos/mongo.repo.js +0 -260
- package/dist/processor/repos/mongo.repo.js.map +0 -1
- package/dist/processor/repos/postgres.repo.d.ts +0 -31
- package/dist/processor/repos/postgres.repo.js +0 -185
- package/dist/processor/repos/postgres.repo.js.map +0 -1
- package/dist/processor/repos/sms.repo.d.ts +0 -39
- package/dist/processor/repos/sms.repo.js +0 -124
- package/dist/processor/repos/sms.repo.js.map +0 -1
- package/dist/processor/services/processor.service.d.ts +0 -465
- package/dist/processor/services/processor.service.js +0 -5343
- package/dist/processor/services/processor.service.js.map +0 -1
- package/dist/processor/services/request.service.d.ts +0 -36
- package/dist/processor/services/request.service.js +0 -304
- package/dist/processor/services/request.service.js.map +0 -1
- package/dist/processor/types/request.types.d.ts +0 -14
- package/dist/processor/types/request.types.js +0 -3
- package/dist/processor/types/request.types.js.map +0 -1
- package/dist/processor/utils/processor.utils.d.ts +0 -104
- package/dist/processor/utils/processor.utils.js +0 -1066
- package/dist/processor/utils/processor.utils.js.map +0 -1
- package/dist/processor/utils/request.utils.d.ts +0 -20
- package/dist/processor/utils/request.utils.js +0 -113
- package/dist/processor/utils/request.utils.js.map +0 -1
- package/dist/processor/utils/storage.util.d.ts +0 -8
- package/dist/processor/utils/storage.util.js +0 -106
- package/dist/processor/utils/storage.util.js.map +0 -1
- package/dist/products/services/products.service.d.ts +0 -577
- package/dist/products/services/products.service.js +0 -5845
- package/dist/products/services/products.service.js.map +0 -1
- package/dist/products/utils/crypt.utils.d.ts +0 -1
- package/dist/products/utils/crypt.utils.js +0 -17
- package/dist/products/utils/crypt.utils.js.map +0 -1
- package/dist/products/utils/functions.utils.d.ts +0 -13
- package/dist/products/utils/functions.utils.js +0 -294
- package/dist/products/utils/functions.utils.js.map +0 -1
- package/dist/products/utils/objects.utils.d.ts +0 -13
- package/dist/products/utils/objects.utils.js +0 -89
- package/dist/products/utils/objects.utils.js.map +0 -1
- package/dist/products/utils/string.utils.d.ts +0 -12
- package/dist/products/utils/string.utils.js +0 -168
- package/dist/products/utils/string.utils.js.map +0 -1
- package/dist/products/validators/index.d.ts +0 -33
- package/dist/products/validators/index.js +0 -75
- package/dist/products/validators/index.js.map +0 -1
- package/dist/products/validators/joi-validators/create.html.validator.d.ts +0 -2
- package/dist/products/validators/joi-validators/create.html.validator.js +0 -55
- package/dist/products/validators/joi-validators/create.html.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productAgent.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/create.productAgent.validator.js +0 -266
- package/dist/products/validators/joi-validators/create.productAgent.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productApp.validator.d.ts +0 -4
- package/dist/products/validators/joi-validators/create.productApp.validator.js +0 -61
- package/dist/products/validators/joi-validators/create.productApp.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productCache.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/create.productCache.validator.js +0 -46
- package/dist/products/validators/joi-validators/create.productCache.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productDatabase.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/create.productDatabase.validator.js +0 -77
- package/dist/products/validators/joi-validators/create.productDatabase.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productDatabaseAction.validator.d.ts +0 -7
- package/dist/products/validators/joi-validators/create.productDatabaseAction.validator.js +0 -194
- package/dist/products/validators/joi-validators/create.productDatabaseAction.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productDatabaseMigration.validator.d.ts +0 -4
- package/dist/products/validators/joi-validators/create.productDatabaseMigration.validator.js +0 -63
- package/dist/products/validators/joi-validators/create.productDatabaseMigration.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productEnv.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/create.productEnv.validator.js +0 -45
- package/dist/products/validators/joi-validators/create.productEnv.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productFallback.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/create.productFallback.validator.js +0 -64
- package/dist/products/validators/joi-validators/create.productFallback.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productFeature.validator.d.ts +0 -14
- package/dist/products/validators/joi-validators/create.productFeature.validator.js +0 -140
- package/dist/products/validators/joi-validators/create.productFeature.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productFunction.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/create.productFunction.validator.js +0 -57
- package/dist/products/validators/joi-validators/create.productFunction.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productGraph.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/create.productGraph.validator.js +0 -89
- package/dist/products/validators/joi-validators/create.productGraph.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productHealthcheck.validator.d.ts +0 -4
- package/dist/products/validators/joi-validators/create.productHealthcheck.validator.js +0 -58
- package/dist/products/validators/joi-validators/create.productHealthcheck.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productJob.validator.d.ts +0 -12
- package/dist/products/validators/joi-validators/create.productJob.validator.js +0 -60
- package/dist/products/validators/joi-validators/create.productJob.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productMessageBrokerTopic.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/create.productMessageBrokerTopic.validator.js +0 -52
- package/dist/products/validators/joi-validators/create.productMessageBrokerTopic.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productMessageBrokers.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/create.productMessageBrokers.validator.js +0 -193
- package/dist/products/validators/joi-validators/create.productMessageBrokers.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productModel.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/create.productModel.validator.js +0 -132
- package/dist/products/validators/joi-validators/create.productModel.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productNotification.validator.d.ts +0 -4
- package/dist/products/validators/joi-validators/create.productNotification.validator.js +0 -241
- package/dist/products/validators/joi-validators/create.productNotification.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productNotificationMessage.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/create.productNotificationMessage.validator.js +0 -57
- package/dist/products/validators/joi-validators/create.productNotificationMessage.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productNotifications.validator.d.ts +0 -0
- package/dist/products/validators/joi-validators/create.productNotifications.validator.js +0 -1
- package/dist/products/validators/joi-validators/create.productNotifications.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productQuota.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/create.productQuota.validator.js +0 -67
- package/dist/products/validators/joi-validators/create.productQuota.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productStorage.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/create.productStorage.validator.js +0 -158
- package/dist/products/validators/joi-validators/create.productStorage.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.productVector.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/create.productVector.validator.js +0 -136
- package/dist/products/validators/joi-validators/create.productVector.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.products.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/create.products.validator.js +0 -43
- package/dist/products/validators/joi-validators/create.products.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.requestAction.validator.d.ts +0 -2
- package/dist/products/validators/joi-validators/create.requestAction.validator.js +0 -45
- package/dist/products/validators/joi-validators/create.requestAction.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/create.userAuth.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/create.userAuth.validator.js +0 -48
- package/dist/products/validators/joi-validators/create.userAuth.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/register.productWebhooks.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/register.productWebhooks.validator.js +0 -48
- package/dist/products/validators/joi-validators/register.productWebhooks.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/update.dataValue.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/update.dataValue.validator.js +0 -103
- package/dist/products/validators/joi-validators/update.dataValue.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/update.productApp.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/update.productApp.validator.js +0 -42
- package/dist/products/validators/joi-validators/update.productApp.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/update.productCache.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/update.productCache.validator.js +0 -45
- package/dist/products/validators/joi-validators/update.productCache.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/update.productDatabase.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/update.productDatabase.validator.js +0 -76
- package/dist/products/validators/joi-validators/update.productDatabase.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/update.productDatabaseAction.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/update.productDatabaseAction.validator.js +0 -79
- package/dist/products/validators/joi-validators/update.productDatabaseAction.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/update.productDatabaseMigration.validator.d.ts +0 -4
- package/dist/products/validators/joi-validators/update.productDatabaseMigration.validator.js +0 -64
- package/dist/products/validators/joi-validators/update.productDatabaseMigration.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/update.productEnv.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/update.productEnv.validator.js +0 -46
- package/dist/products/validators/joi-validators/update.productEnv.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/update.productFallback.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/update.productFallback.validator.js +0 -60
- package/dist/products/validators/joi-validators/update.productFallback.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/update.productFeature.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/update.productFeature.validator.js +0 -53
- package/dist/products/validators/joi-validators/update.productFeature.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/update.productFunction.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/update.productFunction.validator.js +0 -41
- package/dist/products/validators/joi-validators/update.productFunction.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/update.productGraph.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/update.productGraph.validator.js +0 -88
- package/dist/products/validators/joi-validators/update.productGraph.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/update.productJob.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/update.productJob.validator.js +0 -50
- package/dist/products/validators/joi-validators/update.productJob.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/update.productMessageBrokerTopic.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/update.productMessageBrokerTopic.validator.js +0 -52
- package/dist/products/validators/joi-validators/update.productMessageBrokerTopic.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/update.productNotification.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/update.productNotification.validator.js +0 -47
- package/dist/products/validators/joi-validators/update.productNotification.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/update.productNotificationMessage.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/update.productNotificationMessage.validator.js +0 -58
- package/dist/products/validators/joi-validators/update.productNotificationMessage.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/update.productQuota.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/update.productQuota.validator.js +0 -64
- package/dist/products/validators/joi-validators/update.productQuota.validator.js.map +0 -1
- package/dist/products/validators/joi-validators/update.userAuth.validator.d.ts +0 -3
- package/dist/products/validators/joi-validators/update.userAuth.validator.js +0 -48
- package/dist/products/validators/joi-validators/update.userAuth.validator.js.map +0 -1
- package/dist/resilience/fallback.service.d.ts +0 -141
- package/dist/resilience/fallback.service.js +0 -766
- package/dist/resilience/fallback.service.js.map +0 -1
- package/dist/resilience/healthcheck.service.d.ts +0 -163
- package/dist/resilience/healthcheck.service.js +0 -1012
- package/dist/resilience/healthcheck.service.js.map +0 -1
- package/dist/resilience/index.d.ts +0 -104
- package/dist/resilience/index.js +0 -140
- package/dist/resilience/index.js.map +0 -1
- package/dist/resilience/quota.service.d.ts +0 -83
- package/dist/resilience/quota.service.js +0 -518
- package/dist/resilience/quota.service.js.map +0 -1
- package/dist/resilience/resilience.service.d.ts +0 -98
- package/dist/resilience/resilience.service.js +0 -560
- package/dist/resilience/resilience.service.js.map +0 -1
- package/dist/resilience/types/index.d.ts +0 -513
- package/dist/resilience/types/index.js +0 -29
- package/dist/resilience/types/index.js.map +0 -1
- package/dist/secrets/index.d.ts +0 -10
- package/dist/secrets/index.js +0 -33
- package/dist/secrets/index.js.map +0 -1
- package/dist/secrets/secrets.resolver.d.ts +0 -52
- package/dist/secrets/secrets.resolver.js +0 -236
- package/dist/secrets/secrets.resolver.js.map +0 -1
- package/dist/secrets/secrets.service.d.ts +0 -93
- package/dist/secrets/secrets.service.js +0 -246
- package/dist/secrets/secrets.service.js.map +0 -1
- package/dist/secrets/secrets.types.d.ts +0 -188
- package/dist/secrets/secrets.types.js +0 -87
- package/dist/secrets/secrets.types.js.map +0 -1
- package/dist/sessions/index.d.ts +0 -50
- package/dist/sessions/index.js +0 -96
- package/dist/sessions/index.js.map +0 -1
- package/dist/sessions/sessions.helper.d.ts +0 -88
- package/dist/sessions/sessions.helper.js +0 -190
- package/dist/sessions/sessions.helper.js.map +0 -1
- package/dist/sessions/sessions.resolver.d.ts +0 -188
- package/dist/sessions/sessions.resolver.js +0 -603
- package/dist/sessions/sessions.resolver.js.map +0 -1
- package/dist/sessions/sessions.service.d.ts +0 -194
- package/dist/sessions/sessions.service.js +0 -988
- package/dist/sessions/sessions.service.js.map +0 -1
- package/dist/sessions/types/index.d.ts +0 -344
- package/dist/sessions/types/index.js +0 -6
- package/dist/sessions/types/index.js.map +0 -1
- package/dist/storage/index.d.ts +0 -66
- package/dist/storage/index.js +0 -99
- package/dist/storage/index.js.map +0 -1
- package/dist/storage/storage.service.d.ts +0 -177
- package/dist/storage/storage.service.js +0 -905
- package/dist/storage/storage.service.js.map +0 -1
- package/dist/storage/types/index.d.ts +0 -270
- package/dist/storage/types/index.js +0 -6
- package/dist/storage/types/index.js.map +0 -1
- package/dist/storage/utils/storage.util.d.ts +0 -62
- package/dist/storage/utils/storage.util.js +0 -593
- package/dist/storage/utils/storage.util.js.map +0 -1
- package/dist/types/actions.types.d.ts +0 -0
- package/dist/types/actions.types.js +0 -1
- package/dist/types/actions.types.js.map +0 -1
- package/dist/types/appBuilder.types.d.ts +0 -316
- package/dist/types/appBuilder.types.js +0 -3
- package/dist/types/appBuilder.types.js.map +0 -1
- package/dist/types/database.types.d.ts +0 -9
- package/dist/types/database.types.js +0 -3
- package/dist/types/database.types.js.map +0 -1
- package/dist/types/enums.d.ts +0 -231
- package/dist/types/enums.js +0 -261
- package/dist/types/enums.js.map +0 -1
- package/dist/types/index.d.ts +0 -12
- package/dist/types/index.js +0 -29
- package/dist/types/index.js.map +0 -1
- package/dist/types/index.types.d.ts +0 -30
- package/dist/types/index.types.js +0 -9
- package/dist/types/index.types.js.map +0 -1
- package/dist/types/inputs.types.d.ts +0 -114
- package/dist/types/inputs.types.js +0 -44
- package/dist/types/inputs.types.js.map +0 -1
- package/dist/types/logs.types.d.ts +0 -19
- package/dist/types/logs.types.js +0 -8
- package/dist/types/logs.types.js.map +0 -1
- package/dist/types/pricing.types.d.ts +0 -4
- package/dist/types/pricing.types.js +0 -3
- package/dist/types/pricing.types.js.map +0 -1
- package/dist/types/processor.types.d.ts +0 -602
- package/dist/types/processor.types.js +0 -19
- package/dist/types/processor.types.js.map +0 -1
- package/dist/types/productsBuilder.types.d.ts +0 -1566
- package/dist/types/productsBuilder.types.js +0 -303
- package/dist/types/productsBuilder.types.js.map +0 -1
- package/dist/types/request-tracker.interface.d.ts +0 -0
- package/dist/types/request-tracker.interface.js +0 -1
- package/dist/types/request-tracker.interface.js.map +0 -1
- package/dist/types/requests.types.d.ts +0 -8
- package/dist/types/requests.types.js +0 -3
- package/dist/types/requests.types.js.map +0 -1
- package/dist/types/workspaces.types.d.ts +0 -28
- package/dist/types/workspaces.types.js +0 -4
- package/dist/types/workspaces.types.js.map +0 -1
- package/dist/utils/constants.d.ts +0 -1
- package/dist/utils/constants.js +0 -5
- package/dist/utils/constants.js.map +0 -1
- package/dist/utils/index.d.ts +0 -2
- package/dist/utils/index.js +0 -109
- package/dist/utils/index.js.map +0 -1
- package/dist/vector/actions/action-manager.d.ts +0 -140
- package/dist/vector/actions/action-manager.js +0 -356
- package/dist/vector/actions/action-manager.js.map +0 -1
- package/dist/vector/adapters/base.adapter.d.ts +0 -169
- package/dist/vector/adapters/base.adapter.js +0 -218
- package/dist/vector/adapters/base.adapter.js.map +0 -1
- package/dist/vector/adapters/index.d.ts +0 -10
- package/dist/vector/adapters/index.js +0 -19
- package/dist/vector/adapters/index.js.map +0 -1
- package/dist/vector/adapters/memory.adapter.d.ts +0 -85
- package/dist/vector/adapters/memory.adapter.js +0 -505
- package/dist/vector/adapters/memory.adapter.js.map +0 -1
- package/dist/vector/adapters/pinecone.adapter.d.ts +0 -52
- package/dist/vector/adapters/pinecone.adapter.js +0 -433
- package/dist/vector/adapters/pinecone.adapter.js.map +0 -1
- package/dist/vector/adapters/qdrant.adapter.d.ts +0 -56
- package/dist/vector/adapters/qdrant.adapter.js +0 -442
- package/dist/vector/adapters/qdrant.adapter.js.map +0 -1
- package/dist/vector/adapters/weaviate.adapter.d.ts +0 -68
- package/dist/vector/adapters/weaviate.adapter.js +0 -661
- package/dist/vector/adapters/weaviate.adapter.js.map +0 -1
- package/dist/vector/index.d.ts +0 -36
- package/dist/vector/index.js +0 -70
- package/dist/vector/index.js.map +0 -1
- package/dist/vector/types/action.interface.d.ts +0 -195
- package/dist/vector/types/action.interface.js +0 -100
- package/dist/vector/types/action.interface.js.map +0 -1
- package/dist/vector/types/connection.interface.d.ts +0 -151
- package/dist/vector/types/connection.interface.js +0 -8
- package/dist/vector/types/connection.interface.js.map +0 -1
- package/dist/vector/types/embedding.interface.d.ts +0 -144
- package/dist/vector/types/embedding.interface.js +0 -8
- package/dist/vector/types/embedding.interface.js.map +0 -1
- package/dist/vector/types/enums.d.ts +0 -104
- package/dist/vector/types/enums.js +0 -113
- package/dist/vector/types/enums.js.map +0 -1
- package/dist/vector/types/index.d.ts +0 -11
- package/dist/vector/types/index.js +0 -23
- package/dist/vector/types/index.js.map +0 -1
- package/dist/vector/types/vector.interface.d.ts +0 -315
- package/dist/vector/types/vector.interface.js +0 -8
- package/dist/vector/types/vector.interface.js.map +0 -1
- package/dist/vector/utils/index.d.ts +0 -6
- package/dist/vector/utils/index.js +0 -11
- package/dist/vector/utils/index.js.map +0 -1
- package/dist/vector/utils/vector-error.d.ts +0 -69
- package/dist/vector/utils/vector-error.js +0 -116
- package/dist/vector/utils/vector-error.js.map +0 -1
- package/dist/vector/vector-database.service.d.ts +0 -484
- package/dist/vector/vector-database.service.js +0 -1002
- package/dist/vector/vector-database.service.js.map +0 -1
- package/dist/vector/vector.service.d.ts +0 -283
- package/dist/vector/vector.service.js +0 -544
- package/dist/vector/vector.service.js.map +0 -1
- package/dist/warehouse/executor/index.d.ts +0 -5
- package/dist/warehouse/executor/index.js +0 -12
- package/dist/warehouse/executor/index.js.map +0 -1
- package/dist/warehouse/executor/joins/index.d.ts +0 -5
- package/dist/warehouse/executor/joins/index.js +0 -11
- package/dist/warehouse/executor/joins/index.js.map +0 -1
- package/dist/warehouse/executor/joins/join-executor.d.ts +0 -101
- package/dist/warehouse/executor/joins/join-executor.js +0 -493
- package/dist/warehouse/executor/joins/join-executor.js.map +0 -1
- package/dist/warehouse/executor/joins/semantic-join.d.ts +0 -64
- package/dist/warehouse/executor/joins/semantic-join.js +0 -241
- package/dist/warehouse/executor/joins/semantic-join.js.map +0 -1
- package/dist/warehouse/executor/single-source-executor.d.ts +0 -155
- package/dist/warehouse/executor/single-source-executor.js +0 -573
- package/dist/warehouse/executor/single-source-executor.js.map +0 -1
- package/dist/warehouse/index.d.ts +0 -79
- package/dist/warehouse/index.js +0 -111
- package/dist/warehouse/index.js.map +0 -1
- package/dist/warehouse/parser/index.d.ts +0 -4
- package/dist/warehouse/parser/index.js +0 -10
- package/dist/warehouse/parser/index.js.map +0 -1
- package/dist/warehouse/parser/query-parser.d.ts +0 -181
- package/dist/warehouse/parser/query-parser.js +0 -415
- package/dist/warehouse/parser/query-parser.js.map +0 -1
- package/dist/warehouse/registry/data-source-registry.d.ts +0 -207
- package/dist/warehouse/registry/data-source-registry.js +0 -396
- package/dist/warehouse/registry/data-source-registry.js.map +0 -1
- package/dist/warehouse/registry/index.d.ts +0 -4
- package/dist/warehouse/registry/index.js +0 -9
- package/dist/warehouse/registry/index.js.map +0 -1
- package/dist/warehouse/transactions/index.d.ts +0 -4
- package/dist/warehouse/transactions/index.js +0 -9
- package/dist/warehouse/transactions/index.js.map +0 -1
- package/dist/warehouse/transactions/saga-orchestrator.d.ts +0 -92
- package/dist/warehouse/transactions/saga-orchestrator.js +0 -383
- package/dist/warehouse/transactions/saga-orchestrator.js.map +0 -1
- package/dist/warehouse/types/index.d.ts +0 -9
- package/dist/warehouse/types/index.js +0 -33
- package/dist/warehouse/types/index.js.map +0 -1
- package/dist/warehouse/types/join.interface.d.ts +0 -225
- package/dist/warehouse/types/join.interface.js +0 -87
- package/dist/warehouse/types/join.interface.js.map +0 -1
- package/dist/warehouse/types/query.interface.d.ts +0 -232
- package/dist/warehouse/types/query.interface.js +0 -9
- package/dist/warehouse/types/query.interface.js.map +0 -1
- package/dist/warehouse/types/transaction.interface.d.ts +0 -236
- package/dist/warehouse/types/transaction.interface.js +0 -74
- package/dist/warehouse/types/transaction.interface.js.map +0 -1
- package/dist/warehouse/types/where.interface.d.ts +0 -208
- package/dist/warehouse/types/where.interface.js +0 -89
- package/dist/warehouse/types/where.interface.js.map +0 -1
- package/dist/warehouse/warehouse.service.d.ts +0 -200
- package/dist/warehouse/warehouse.service.js +0 -470
- package/dist/warehouse/warehouse.service.js.map +0 -1
- package/dist/workflows/index.d.ts +0 -30
- package/dist/workflows/index.js +0 -64
- package/dist/workflows/index.js.map +0 -1
- package/dist/workflows/types/index.d.ts +0 -6
- package/dist/workflows/types/index.js +0 -23
- package/dist/workflows/types/index.js.map +0 -1
- package/dist/workflows/types/workflows.types.d.ts +0 -1095
- package/dist/workflows/types/workflows.types.js +0 -13
- package/dist/workflows/types/workflows.types.js.map +0 -1
- package/dist/workflows/workflow-builder.d.ts +0 -70
- package/dist/workflows/workflow-builder.js +0 -353
- package/dist/workflows/workflow-builder.js.map +0 -1
- package/dist/workflows/workflow-executor.d.ts +0 -289
- package/dist/workflows/workflow-executor.js +0 -2467
- package/dist/workflows/workflow-executor.js.map +0 -1
- package/dist/workflows/workflows.service.d.ts +0 -412
- package/dist/workflows/workflows.service.js +0 -2233
- package/dist/workflows/workflows.service.js.map +0 -1
|
@@ -1,1436 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const types_1 = require("../../types");
|
|
7
|
-
const validators_1 = require("../validators");
|
|
8
|
-
const appApi_service_1 = require("../../api/services/appApi.service");
|
|
9
|
-
const inputs_service_1 = __importDefault(require("../../inputs/inputs.service"));
|
|
10
|
-
const string_utils_1 = require("../utils/string.utils");
|
|
11
|
-
const strings_utils_1 = require("../../api/utils/strings.utils");
|
|
12
|
-
const workspaceApi_service_1 = require("../../api/services/workspaceApi.service");
|
|
13
|
-
const string_utils_2 = require("../../products/utils/string.utils");
|
|
14
|
-
const objects_utils_1 = require("../utils/objects.utils");
|
|
15
|
-
const create_appWebhook_validator_1 = require("../validators/joi-validators/create.appWebhook.validator");
|
|
16
|
-
const update_appWebhook_validator_1 = require("../validators/joi-validators/update.appWebhook.validator");
|
|
17
|
-
const create_appWebhookEvent_validator_1 = require("../validators/joi-validators/create.appWebhookEvent.validator");
|
|
18
|
-
const update_appWebhookEvent_validator_1 = require("../validators/joi-validators/update.appWebhookEvent.validator");
|
|
19
|
-
class AppBuilderService {
|
|
20
|
-
constructor({ workspace_id, public_key, user_id, token, env_type, access_key }) {
|
|
21
|
-
this.workspace_id = workspace_id;
|
|
22
|
-
this.user_id = user_id;
|
|
23
|
-
this.public_key = public_key;
|
|
24
|
-
this.token = token;
|
|
25
|
-
this.access_key = access_key !== null && access_key !== void 0 ? access_key : null;
|
|
26
|
-
this.appApi = new appApi_service_1.AppApiService(env_type);
|
|
27
|
-
this.workspaceApi = new workspaceApi_service_1.WorkspaceApiService(env_type);
|
|
28
|
-
this.inputsService = new inputs_service_1.default();
|
|
29
|
-
}
|
|
30
|
-
async createApp(data) {
|
|
31
|
-
try {
|
|
32
|
-
await validators_1.CreateAppBuilderSchema.validateAsync(data);
|
|
33
|
-
const exists = await this.checkIfAppExists(data.app_name);
|
|
34
|
-
if (exists && (exists === null || exists === void 0 ? void 0 : exists._id)) {
|
|
35
|
-
this.app = exists;
|
|
36
|
-
this.app_id = exists === null || exists === void 0 ? void 0 : exists._id;
|
|
37
|
-
}
|
|
38
|
-
else {
|
|
39
|
-
const app = await this.createNewApp(data);
|
|
40
|
-
//await this.initializeApp(app._id);
|
|
41
|
-
}
|
|
42
|
-
return { app_id: this.app._id };
|
|
43
|
-
}
|
|
44
|
-
catch (e) {
|
|
45
|
-
throw e;
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
initAppVersion(versionTag) {
|
|
49
|
-
if (versionTag) {
|
|
50
|
-
this.appVersion = this.app.versions.find((version) => version.tag === versionTag);
|
|
51
|
-
if (!this.appVersion) {
|
|
52
|
-
throw new Error(`Version ${versionTag} not found`);
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
else {
|
|
56
|
-
this.appVersion = this.app.versions.find((version) => version.latest === true);
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
async initializeAppByTag(app_tag) {
|
|
60
|
-
try {
|
|
61
|
-
this.app = await this.appApi.initApp(app_tag, this.getUserAccess());
|
|
62
|
-
this.app_id = this.app._id;
|
|
63
|
-
this.initAppVersion();
|
|
64
|
-
}
|
|
65
|
-
catch (e) {
|
|
66
|
-
throw e;
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
async initializeApp(app_id) {
|
|
70
|
-
try {
|
|
71
|
-
this.app = await this.appApi.initApp(app_id, this.getUserAccess());
|
|
72
|
-
this.app_id = app_id;
|
|
73
|
-
this.initAppVersion();
|
|
74
|
-
}
|
|
75
|
-
catch (e) {
|
|
76
|
-
throw e;
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
async initializeWorkspace(subCheck = true) {
|
|
80
|
-
if (!this.workspace) {
|
|
81
|
-
this.workspace = await this.workspaceApi.fetchWorkspaceById(this.getUserAccess(), subCheck);
|
|
82
|
-
}
|
|
83
|
-
}
|
|
84
|
-
async createNewApp(data) {
|
|
85
|
-
await this.initializeWorkspace();
|
|
86
|
-
return this.appApi.createApp(Object.assign(Object.assign({}, data), { tag: `${(0, string_utils_1.tagify)(this.workspace.name)}:${(0, string_utils_1.tagify)(data.app_name)}` }), this.getUserAccess());
|
|
87
|
-
}
|
|
88
|
-
async initializeAppByName(app_name) {
|
|
89
|
-
try {
|
|
90
|
-
const app = await this.checkIfAppExists(app_name);
|
|
91
|
-
if (!app)
|
|
92
|
-
throw new Error(`${app_name} not found in workspace`);
|
|
93
|
-
this.app = app;
|
|
94
|
-
this.app_id = app._id;
|
|
95
|
-
this.initAppVersion();
|
|
96
|
-
}
|
|
97
|
-
catch (e) {
|
|
98
|
-
throw e;
|
|
99
|
-
}
|
|
100
|
-
}
|
|
101
|
-
async checkIfAppExists(app_name) {
|
|
102
|
-
try {
|
|
103
|
-
return await this.appApi.checkAppNameExists(app_name, this.getUserAccess());
|
|
104
|
-
}
|
|
105
|
-
catch (e) {
|
|
106
|
-
return false;
|
|
107
|
-
}
|
|
108
|
-
}
|
|
109
|
-
fetchApp() {
|
|
110
|
-
return this.app;
|
|
111
|
-
}
|
|
112
|
-
async updateApp(data) {
|
|
113
|
-
try {
|
|
114
|
-
if (!this.app_id)
|
|
115
|
-
throw new Error('App not initialized');
|
|
116
|
-
await validators_1.UpdateAppBuilderSchema.validateAsync(data);
|
|
117
|
-
await this.appApi.updateApp(this.app_id, Object.assign(Object.assign({}, data), { component: types_1.AppComponents.APP, action: types_1.RequestAction.UPDATE }), this.getUserAccess());
|
|
118
|
-
//await this.initializeApp(this.app_id);
|
|
119
|
-
}
|
|
120
|
-
catch (e) {
|
|
121
|
-
throw e;
|
|
122
|
-
}
|
|
123
|
-
}
|
|
124
|
-
async createEnv(data, throwErrorIfExists = false) {
|
|
125
|
-
try {
|
|
126
|
-
// TODO: figure out a way to check if this has run before, halt if it has
|
|
127
|
-
const existingEnv = await this.fetchEnv(data.slug, false);
|
|
128
|
-
if (!existingEnv) {
|
|
129
|
-
const payload = Object.assign({}, data);
|
|
130
|
-
if (payload.base_url) {
|
|
131
|
-
const keys = (0, string_utils_1.extractBaseUrlVariables)(payload.base_url);
|
|
132
|
-
payload.base_url_variables = keys.length ? keys.map(key => ({ key })) : undefined;
|
|
133
|
-
}
|
|
134
|
-
await validators_1.CreateAppEnvSchema.validateAsync(payload);
|
|
135
|
-
await this.appApi.updateApp(this.app_id, Object.assign(Object.assign({}, payload), { component: types_1.AppComponents.ENV, action: types_1.RequestAction.CREATE }), this.getUserAccess());
|
|
136
|
-
//await this.initializeApp(this.app_id);
|
|
137
|
-
}
|
|
138
|
-
else {
|
|
139
|
-
if (throwErrorIfExists)
|
|
140
|
-
throw new Error(`Environment ${data.slug} already exists`);
|
|
141
|
-
}
|
|
142
|
-
}
|
|
143
|
-
catch (e) {
|
|
144
|
-
throw e;
|
|
145
|
-
}
|
|
146
|
-
}
|
|
147
|
-
async updateEnv(slug, data) {
|
|
148
|
-
try {
|
|
149
|
-
const payload = Object.assign(Object.assign({}, data), { slug });
|
|
150
|
-
if (payload.base_url !== undefined) {
|
|
151
|
-
const keys = (0, string_utils_1.extractBaseUrlVariables)(payload.base_url);
|
|
152
|
-
payload.base_url_variables = keys.length ? keys.map(key => ({ key })) : undefined;
|
|
153
|
-
}
|
|
154
|
-
await validators_1.UpdateAppEnvSchema.validateAsync(payload);
|
|
155
|
-
if (data.slug) {
|
|
156
|
-
const existingEnv = await this.fetchEnv(data.slug, false);
|
|
157
|
-
if (existingEnv) {
|
|
158
|
-
throw new Error(`slug ${slug} is in use`); // TODO: also check on the backend
|
|
159
|
-
}
|
|
160
|
-
}
|
|
161
|
-
// TODO: check
|
|
162
|
-
await this.appApi.updateApp(this.app_id, Object.assign(Object.assign({ slug }, payload), { component: types_1.AppComponents.ENV, action: types_1.RequestAction.UPDATE }), this.getUserAccess());
|
|
163
|
-
//await this.initializeApp(this.app_id);
|
|
164
|
-
}
|
|
165
|
-
catch (e) {
|
|
166
|
-
throw e;
|
|
167
|
-
}
|
|
168
|
-
}
|
|
169
|
-
async fetchEnvs() {
|
|
170
|
-
const components = await this.appApi.fetchAppComponents(this.app_id, 'env', this.getUserAccess(), this.appVersion.tag);
|
|
171
|
-
return components;
|
|
172
|
-
}
|
|
173
|
-
async fetchEnv(slug, throwErrorIfExists = true) {
|
|
174
|
-
const envs = await this.fetchEnvs();
|
|
175
|
-
const env = envs.find((data) => data.slug === slug);
|
|
176
|
-
if (!env && throwErrorIfExists)
|
|
177
|
-
throw new Error(`Env ${slug} not found`);
|
|
178
|
-
return env;
|
|
179
|
-
}
|
|
180
|
-
async extractResourceData(url) {
|
|
181
|
-
const pathParamsSample = (0, strings_utils_1.extractPathParams)(url);
|
|
182
|
-
const pathParamsData = (await this.inputsService.parseData({
|
|
183
|
-
data: pathParamsSample,
|
|
184
|
-
category: types_1.Categories.PARAMS,
|
|
185
|
-
type: types_1.InputsTypes.JSON,
|
|
186
|
-
expected: types_1.ExpectedValues.PARSESAMPLE,
|
|
187
|
-
}));
|
|
188
|
-
const queryParamsSample = (0, strings_utils_1.extractQueryParams)(url);
|
|
189
|
-
const queryParamsData = (await this.inputsService.parseData({
|
|
190
|
-
data: queryParamsSample,
|
|
191
|
-
category: types_1.Categories.QUERY,
|
|
192
|
-
type: types_1.InputsTypes.JSON,
|
|
193
|
-
expected: types_1.ExpectedValues.PARSESAMPLE,
|
|
194
|
-
}));
|
|
195
|
-
return {
|
|
196
|
-
query: {
|
|
197
|
-
sample: JSON.stringify(queryParamsSample),
|
|
198
|
-
data: queryParamsData,
|
|
199
|
-
},
|
|
200
|
-
params: {
|
|
201
|
-
sample: JSON.stringify(pathParamsSample),
|
|
202
|
-
data: pathParamsData,
|
|
203
|
-
},
|
|
204
|
-
};
|
|
205
|
-
}
|
|
206
|
-
// Helper function to merge metadata into parsed schema data
|
|
207
|
-
mergeMetadataIntoSchema(parsedData, metadataMap) {
|
|
208
|
-
if (!metadataMap || Object.keys(metadataMap).length === 0) {
|
|
209
|
-
return parsedData;
|
|
210
|
-
}
|
|
211
|
-
return parsedData.map(item => {
|
|
212
|
-
const metadata = metadataMap[item.key || ''];
|
|
213
|
-
if (metadata) {
|
|
214
|
-
return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({}, item), (metadata.minLength !== undefined ? { minLength: metadata.minLength } : {})), (metadata.maxLength !== undefined ? { maxLength: metadata.maxLength } : {})), (metadata.required !== undefined ? { required: metadata.required } : {})), (metadata.type !== undefined ? { type: metadata.type } : {}));
|
|
215
|
-
}
|
|
216
|
-
return item;
|
|
217
|
-
});
|
|
218
|
-
}
|
|
219
|
-
// Helper function to merge nested metadata for body fields
|
|
220
|
-
mergeNestedBodyMetadata(parsedData, fieldsMetadata) {
|
|
221
|
-
if (!fieldsMetadata || Object.keys(fieldsMetadata).length === 0) {
|
|
222
|
-
return parsedData;
|
|
223
|
-
}
|
|
224
|
-
const applyMetadataRecursively = (data, pathPrefix = '') => {
|
|
225
|
-
return data.map((item) => {
|
|
226
|
-
const fullPath = pathPrefix ? `${pathPrefix}.${item.key}` : item.key;
|
|
227
|
-
const metadata = fieldsMetadata[fullPath];
|
|
228
|
-
let updatedItem = Object.assign({}, item);
|
|
229
|
-
if (metadata) {
|
|
230
|
-
updatedItem = Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({}, updatedItem), (metadata.minLength !== undefined ? { minLength: metadata.minLength } : {})), (metadata.maxLength !== undefined ? { maxLength: metadata.maxLength } : {})), (metadata.required !== undefined ? { required: metadata.required } : {})), (metadata.type !== undefined ? { type: metadata.type } : {}));
|
|
231
|
-
}
|
|
232
|
-
// Recursively apply to nested data (if the parsed item has nested structure)
|
|
233
|
-
if (updatedItem.data && Array.isArray(updatedItem.data) && updatedItem.data.length > 0) {
|
|
234
|
-
updatedItem.data = applyMetadataRecursively(updatedItem.data, fullPath);
|
|
235
|
-
}
|
|
236
|
-
return updatedItem;
|
|
237
|
-
});
|
|
238
|
-
};
|
|
239
|
-
return applyMetadataRecursively(parsedData);
|
|
240
|
-
}
|
|
241
|
-
async createAction(data, throwErrorIfExists = false) {
|
|
242
|
-
// Validate schema
|
|
243
|
-
await validators_1.CreateAppActionSchema.validateAsync(data);
|
|
244
|
-
data.tag = (0, string_utils_1.tagify)(data.tag);
|
|
245
|
-
const { tag } = data;
|
|
246
|
-
// Check if action already exists
|
|
247
|
-
let exists;
|
|
248
|
-
try {
|
|
249
|
-
exists = await this.fetchAction(tag);
|
|
250
|
-
}
|
|
251
|
-
catch (e) {
|
|
252
|
-
exists = false;
|
|
253
|
-
}
|
|
254
|
-
if (exists && throwErrorIfExists) {
|
|
255
|
-
throw new Error(`App action ${tag} already exists`);
|
|
256
|
-
}
|
|
257
|
-
if (exists) {
|
|
258
|
-
return; // Silently skip if already exists and not throwing error
|
|
259
|
-
}
|
|
260
|
-
// Build the action body (similar to updateAction but without fetching existing action)
|
|
261
|
-
const body = Object.assign({ tag: data.tag, name: data.name, method: data.method, request_type: data.request_type || types_1.DataFormats.JSON, description: data.description || '', responses: [] }, (data.folder_id ? { folder_id: data.folder_id } : {}));
|
|
262
|
-
// Batch all parsing operations for parallel execution
|
|
263
|
-
const parseOperations = [];
|
|
264
|
-
const parseKeys = [];
|
|
265
|
-
// Prepare params parsing
|
|
266
|
-
if (data.params) {
|
|
267
|
-
parseKeys.push('params');
|
|
268
|
-
parseOperations.push(this.inputsService.parseJson({
|
|
269
|
-
data: data.params.sample,
|
|
270
|
-
expected: types_1.ExpectedValues.PARSESAMPLE,
|
|
271
|
-
category: types_1.Categories.PARAMS
|
|
272
|
-
}).then(parsedData => ({
|
|
273
|
-
key: 'params',
|
|
274
|
-
parsedData: parsedData,
|
|
275
|
-
metadata: this.extractMetadata(data.params)
|
|
276
|
-
})));
|
|
277
|
-
}
|
|
278
|
-
// Prepare query parsing
|
|
279
|
-
if (data.query) {
|
|
280
|
-
parseKeys.push('query');
|
|
281
|
-
parseOperations.push(this.inputsService.parseJson({
|
|
282
|
-
data: data.query.sample,
|
|
283
|
-
expected: types_1.ExpectedValues.PARSESAMPLE,
|
|
284
|
-
category: types_1.Categories.QUERY
|
|
285
|
-
}).then(parsedData => ({
|
|
286
|
-
key: 'query',
|
|
287
|
-
parsedData: parsedData,
|
|
288
|
-
metadata: this.extractMetadata(data.query)
|
|
289
|
-
})));
|
|
290
|
-
}
|
|
291
|
-
// Prepare body parsing
|
|
292
|
-
if (data.body) {
|
|
293
|
-
const fieldsMetadata = data.body.fieldsMetadata;
|
|
294
|
-
const bodySample = data.body.sample || data.body;
|
|
295
|
-
parseKeys.push('body');
|
|
296
|
-
parseOperations.push(this.inputsService.parseJson({
|
|
297
|
-
data: bodySample,
|
|
298
|
-
expected: types_1.ExpectedValues.PARSESAMPLE,
|
|
299
|
-
category: types_1.Categories.BODY
|
|
300
|
-
}).then(parsedData => ({
|
|
301
|
-
key: 'body',
|
|
302
|
-
parsedData: parsedData,
|
|
303
|
-
fieldsMetadata,
|
|
304
|
-
bodySample,
|
|
305
|
-
metadata: fieldsMetadata ? null : this.extractMetadata(data.body)
|
|
306
|
-
})));
|
|
307
|
-
}
|
|
308
|
-
// Prepare headers parsing
|
|
309
|
-
if (data.headers) {
|
|
310
|
-
parseKeys.push('headers');
|
|
311
|
-
parseOperations.push(this.inputsService.parseJson({
|
|
312
|
-
data: data.headers.sample,
|
|
313
|
-
expected: types_1.ExpectedValues.PARSESAMPLE,
|
|
314
|
-
category: types_1.Categories.HEADER
|
|
315
|
-
}).then(parsedData => ({
|
|
316
|
-
key: 'headers',
|
|
317
|
-
parsedData: parsedData,
|
|
318
|
-
metadata: this.extractMetadata(data.headers)
|
|
319
|
-
})));
|
|
320
|
-
}
|
|
321
|
-
// Prepare response parsing
|
|
322
|
-
if (data.response) {
|
|
323
|
-
parseKeys.push('response');
|
|
324
|
-
parseOperations.push(this.inputsService.parseJson({
|
|
325
|
-
data: data.response.body,
|
|
326
|
-
expected: types_1.ExpectedValues.PARSESAMPLE
|
|
327
|
-
}).then(parsedData => ({
|
|
328
|
-
key: 'response',
|
|
329
|
-
parsedData: parsedData
|
|
330
|
-
})));
|
|
331
|
-
}
|
|
332
|
-
// Execute all parsing operations in parallel
|
|
333
|
-
const parseResults = await Promise.all(parseOperations);
|
|
334
|
-
// Process parsed results
|
|
335
|
-
for (const result of parseResults) {
|
|
336
|
-
switch (result.key) {
|
|
337
|
-
case 'params':
|
|
338
|
-
body.params = {
|
|
339
|
-
type: types_1.InputsTypes.JSON,
|
|
340
|
-
sample: JSON.stringify(data.params.sample),
|
|
341
|
-
data: this.mergeMetadataIntoSchema(result.parsedData, result.metadata)
|
|
342
|
-
};
|
|
343
|
-
break;
|
|
344
|
-
case 'query':
|
|
345
|
-
body.query = {
|
|
346
|
-
type: types_1.InputsTypes.JSON,
|
|
347
|
-
sample: JSON.stringify(data.query.sample),
|
|
348
|
-
data: this.mergeMetadataIntoSchema(result.parsedData, result.metadata)
|
|
349
|
-
};
|
|
350
|
-
break;
|
|
351
|
-
case 'body':
|
|
352
|
-
let finalData = result.parsedData;
|
|
353
|
-
if (result.fieldsMetadata) {
|
|
354
|
-
finalData = this.mergeNestedBodyMetadata(result.parsedData, result.fieldsMetadata);
|
|
355
|
-
}
|
|
356
|
-
else if (result.metadata && Object.keys(result.metadata).length > 0) {
|
|
357
|
-
finalData = this.mergeMetadataIntoSchema(result.parsedData, result.metadata);
|
|
358
|
-
}
|
|
359
|
-
body.body = {
|
|
360
|
-
type: types_1.InputsTypes.JSON,
|
|
361
|
-
sample: JSON.stringify(result.bodySample),
|
|
362
|
-
data: finalData
|
|
363
|
-
};
|
|
364
|
-
break;
|
|
365
|
-
case 'headers':
|
|
366
|
-
body.headers = {
|
|
367
|
-
type: types_1.InputsTypes.JSON,
|
|
368
|
-
sample: JSON.stringify(data.headers.sample),
|
|
369
|
-
data: this.mergeMetadataIntoSchema(result.parsedData, result.metadata)
|
|
370
|
-
};
|
|
371
|
-
break;
|
|
372
|
-
case 'response':
|
|
373
|
-
const response = {
|
|
374
|
-
name: data.response.name || `Response - ${data.response.status_code}`,
|
|
375
|
-
tag: data.tag,
|
|
376
|
-
response_format: data.response.response_format,
|
|
377
|
-
status_code: data.response.status_code,
|
|
378
|
-
success: data.response.success,
|
|
379
|
-
body: {
|
|
380
|
-
sample: JSON.stringify(data.response.body),
|
|
381
|
-
type: types_1.InputsTypes.JSON,
|
|
382
|
-
data: result.parsedData,
|
|
383
|
-
status_code: data.response.status_code,
|
|
384
|
-
}
|
|
385
|
-
};
|
|
386
|
-
body.responses = [response];
|
|
387
|
-
break;
|
|
388
|
-
}
|
|
389
|
-
}
|
|
390
|
-
// Handle resource URL parsing
|
|
391
|
-
if (data.resource) {
|
|
392
|
-
body.resource = (0, strings_utils_1.extractURLPath)(data.resource);
|
|
393
|
-
// Only extract params/query from resource if they weren't already provided
|
|
394
|
-
if (!data.params && !data.query) {
|
|
395
|
-
const { params, query: queryData } = await this.extractResourceData(data.resource);
|
|
396
|
-
// Only set if not already defined and sample exists
|
|
397
|
-
if (!body.params && params.sample) {
|
|
398
|
-
body.params = {
|
|
399
|
-
type: types_1.InputsTypes.JSON,
|
|
400
|
-
sample: params.sample,
|
|
401
|
-
data: params.data
|
|
402
|
-
};
|
|
403
|
-
}
|
|
404
|
-
if (!body.query && queryData.sample) {
|
|
405
|
-
body.query = {
|
|
406
|
-
type: types_1.InputsTypes.JSON,
|
|
407
|
-
sample: queryData.sample,
|
|
408
|
-
data: queryData.data
|
|
409
|
-
};
|
|
410
|
-
}
|
|
411
|
-
}
|
|
412
|
-
}
|
|
413
|
-
// Create action via API
|
|
414
|
-
await this.updateActionProcess(tag, body, types_1.RequestAction.CREATE);
|
|
415
|
-
// Update local cache instead of full app refetch
|
|
416
|
-
//this.appVersion.actions.push(body as IAppAction);
|
|
417
|
-
}
|
|
418
|
-
// Helper method to extract metadata from data object
|
|
419
|
-
extractMetadata(data) {
|
|
420
|
-
const metadataMap = {};
|
|
421
|
-
if (data && data.data && Array.isArray(data.data)) {
|
|
422
|
-
data.data.forEach((item) => {
|
|
423
|
-
if (item.metadata) {
|
|
424
|
-
metadataMap[item.key] = item.metadata;
|
|
425
|
-
}
|
|
426
|
-
});
|
|
427
|
-
}
|
|
428
|
-
return metadataMap;
|
|
429
|
-
}
|
|
430
|
-
async fetchActions() {
|
|
431
|
-
const components = await this.appApi.fetchAppComponents(this.app_id, 'action', this.getUserAccess(), this.appVersion.tag);
|
|
432
|
-
return components;
|
|
433
|
-
}
|
|
434
|
-
async fetchAction(identifier) {
|
|
435
|
-
const actions = await this.fetchActions();
|
|
436
|
-
const action = actions.find((data) => data.tag === identifier || data._id === identifier);
|
|
437
|
-
if (!action)
|
|
438
|
-
throw new Error(`Action ${identifier} not found`);
|
|
439
|
-
return action;
|
|
440
|
-
}
|
|
441
|
-
async updateAction(tag, data) {
|
|
442
|
-
// Validate schema
|
|
443
|
-
await validators_1.UpdateAppActionSchema.validateAsync(data);
|
|
444
|
-
const action = await this.fetchAction(tag);
|
|
445
|
-
const body = action;
|
|
446
|
-
if (!action) {
|
|
447
|
-
throw new Error(`Action ${tag} not found`);
|
|
448
|
-
}
|
|
449
|
-
// Batch all parsing operations for parallel execution
|
|
450
|
-
const parseOperations = [];
|
|
451
|
-
// Prepare params parsing
|
|
452
|
-
if (data.params) {
|
|
453
|
-
parseOperations.push(this.inputsService.parseJson({
|
|
454
|
-
data: data.params.sample,
|
|
455
|
-
expected: types_1.ExpectedValues.PARSESAMPLE,
|
|
456
|
-
category: types_1.Categories.PARAMS
|
|
457
|
-
}).then(parsedData => ({
|
|
458
|
-
key: 'params',
|
|
459
|
-
parsedData: parsedData
|
|
460
|
-
})));
|
|
461
|
-
}
|
|
462
|
-
// Prepare query parsing
|
|
463
|
-
if (data.query) {
|
|
464
|
-
parseOperations.push(this.inputsService.parseJson({
|
|
465
|
-
data: data.query.sample,
|
|
466
|
-
expected: types_1.ExpectedValues.PARSESAMPLE,
|
|
467
|
-
category: types_1.Categories.QUERY
|
|
468
|
-
}).then(parsedData => ({
|
|
469
|
-
key: 'query',
|
|
470
|
-
parsedData: parsedData
|
|
471
|
-
})));
|
|
472
|
-
}
|
|
473
|
-
// Prepare body parsing
|
|
474
|
-
if (data.body) {
|
|
475
|
-
parseOperations.push(this.inputsService.parseJson({
|
|
476
|
-
data: data.body.sample,
|
|
477
|
-
expected: types_1.ExpectedValues.PARSESAMPLE,
|
|
478
|
-
category: types_1.Categories.BODY
|
|
479
|
-
}).then(parsedData => ({
|
|
480
|
-
key: 'body',
|
|
481
|
-
parsedData: parsedData
|
|
482
|
-
})));
|
|
483
|
-
}
|
|
484
|
-
// Prepare headers parsing
|
|
485
|
-
if (data.headers) {
|
|
486
|
-
parseOperations.push(this.inputsService.parseJson({
|
|
487
|
-
data: data.headers.sample,
|
|
488
|
-
expected: types_1.ExpectedValues.PARSESAMPLE,
|
|
489
|
-
category: types_1.Categories.HEADER
|
|
490
|
-
}).then(parsedData => ({
|
|
491
|
-
key: 'headers',
|
|
492
|
-
parsedData: parsedData
|
|
493
|
-
})));
|
|
494
|
-
}
|
|
495
|
-
// Prepare response parsing
|
|
496
|
-
if (data.response) {
|
|
497
|
-
parseOperations.push(this.inputsService.parseJson({
|
|
498
|
-
data: data.response.body,
|
|
499
|
-
expected: types_1.ExpectedValues.PARSESAMPLE
|
|
500
|
-
}).then(parsedData => ({
|
|
501
|
-
key: 'response',
|
|
502
|
-
parsedData: parsedData
|
|
503
|
-
})));
|
|
504
|
-
}
|
|
505
|
-
// Execute all parsing operations in parallel
|
|
506
|
-
const parseResults = await Promise.all(parseOperations);
|
|
507
|
-
// Process parsed results
|
|
508
|
-
for (const result of parseResults) {
|
|
509
|
-
switch (result.key) {
|
|
510
|
-
case 'params':
|
|
511
|
-
body.params = {
|
|
512
|
-
type: types_1.InputsTypes.JSON,
|
|
513
|
-
sample: JSON.stringify(data.params),
|
|
514
|
-
data: result.parsedData
|
|
515
|
-
};
|
|
516
|
-
break;
|
|
517
|
-
case 'query':
|
|
518
|
-
body.query = {
|
|
519
|
-
type: types_1.InputsTypes.JSON,
|
|
520
|
-
sample: JSON.stringify(data.query),
|
|
521
|
-
data: result.parsedData
|
|
522
|
-
};
|
|
523
|
-
break;
|
|
524
|
-
case 'body':
|
|
525
|
-
body.body = {
|
|
526
|
-
type: types_1.InputsTypes.JSON,
|
|
527
|
-
sample: JSON.stringify(data.body),
|
|
528
|
-
data: result.parsedData
|
|
529
|
-
};
|
|
530
|
-
break;
|
|
531
|
-
case 'headers':
|
|
532
|
-
body.headers = {
|
|
533
|
-
type: types_1.InputsTypes.JSON,
|
|
534
|
-
sample: JSON.stringify(data.headers),
|
|
535
|
-
data: result.parsedData
|
|
536
|
-
};
|
|
537
|
-
break;
|
|
538
|
-
case 'response':
|
|
539
|
-
body.responses = action.responses;
|
|
540
|
-
const response = {
|
|
541
|
-
name: `Response - ${data.response.status_code}`,
|
|
542
|
-
response_format: data.response.response_format,
|
|
543
|
-
status_code: data.response.status_code,
|
|
544
|
-
success: data.response.success,
|
|
545
|
-
body: {
|
|
546
|
-
sample: JSON.stringify(data.response.body),
|
|
547
|
-
type: types_1.InputsTypes.JSON,
|
|
548
|
-
data: result.parsedData,
|
|
549
|
-
status_code: data.response.status_code,
|
|
550
|
-
}
|
|
551
|
-
};
|
|
552
|
-
const statusIndex = body.responses.findIndex((resp) => resp.status_code === data.response.status_code);
|
|
553
|
-
if (data.response.success === true) {
|
|
554
|
-
const index = action.responses.findIndex((resp) => resp.success === true);
|
|
555
|
-
if (index > -1) {
|
|
556
|
-
body.responses[index] = response;
|
|
557
|
-
}
|
|
558
|
-
else {
|
|
559
|
-
if (statusIndex > -1) {
|
|
560
|
-
body.responses.splice(statusIndex, 1);
|
|
561
|
-
}
|
|
562
|
-
body.responses.push(response);
|
|
563
|
-
}
|
|
564
|
-
}
|
|
565
|
-
else {
|
|
566
|
-
if (statusIndex > -1) {
|
|
567
|
-
body.responses.splice(statusIndex, 1);
|
|
568
|
-
}
|
|
569
|
-
body.responses.push(response);
|
|
570
|
-
}
|
|
571
|
-
break;
|
|
572
|
-
}
|
|
573
|
-
}
|
|
574
|
-
// Handle resource URL parsing
|
|
575
|
-
if (data.resource) {
|
|
576
|
-
body.resource = (0, strings_utils_1.extractURLPath)(data.resource);
|
|
577
|
-
// Only extract params/query from resource if they weren't already provided in update data
|
|
578
|
-
if (!data.params && !data.query) {
|
|
579
|
-
const { params, query: queryData } = await this.extractResourceData(data.resource);
|
|
580
|
-
// Only set if not already defined in body (from existing action)
|
|
581
|
-
if (!body.params && params.sample) {
|
|
582
|
-
body.params = {
|
|
583
|
-
type: types_1.InputsTypes.JSON,
|
|
584
|
-
sample: params.sample,
|
|
585
|
-
data: params.data
|
|
586
|
-
};
|
|
587
|
-
}
|
|
588
|
-
if (!body.query && queryData.sample) {
|
|
589
|
-
body.query = {
|
|
590
|
-
type: types_1.InputsTypes.JSON,
|
|
591
|
-
sample: queryData.sample,
|
|
592
|
-
data: queryData.data
|
|
593
|
-
};
|
|
594
|
-
}
|
|
595
|
-
}
|
|
596
|
-
}
|
|
597
|
-
// Update simple fields
|
|
598
|
-
if (data.description) {
|
|
599
|
-
body.description = data.description;
|
|
600
|
-
}
|
|
601
|
-
if (data.method) {
|
|
602
|
-
body.method = data.method;
|
|
603
|
-
}
|
|
604
|
-
if (data.request_type) {
|
|
605
|
-
body.request_type = data.request_type;
|
|
606
|
-
}
|
|
607
|
-
// Update action via API
|
|
608
|
-
await this.updateActionProcess(tag, body, types_1.RequestAction.UPDATE);
|
|
609
|
-
// Update local cache instead of full app refetch
|
|
610
|
-
//const actionIndex = this.appVersion.actions.findIndex(a => a.tag === tag || a._id === action._id);
|
|
611
|
-
//if (actionIndex > -1) {
|
|
612
|
-
//this.appVersion.actions[actionIndex] = body as IAppAction;
|
|
613
|
-
//}
|
|
614
|
-
}
|
|
615
|
-
async updateActionProcess(tag, data, action) {
|
|
616
|
-
const query = Object.assign({ component: types_1.AppComponents.ACTION, action,
|
|
617
|
-
tag }, data);
|
|
618
|
-
await this.appApi.updateApp(this.app_id, query, this.getUserAccess());
|
|
619
|
-
}
|
|
620
|
-
async createActionRequestData(category, tag, payload, throwErrorIfExists = false) {
|
|
621
|
-
try {
|
|
622
|
-
const bodyData = await this.fetchActionRequestData(category, tag);
|
|
623
|
-
const exists = bodyData && bodyData.length > 0;
|
|
624
|
-
if (!exists && payload) {
|
|
625
|
-
let data = await this.parseRequestData(category, payload);
|
|
626
|
-
await this.appApi.updateApp(this.app_id, Object.assign(Object.assign({}, data), { app_id: this.app_id, category: types_1.Categories.BODY }), this.getUserAccess());
|
|
627
|
-
}
|
|
628
|
-
else if (throwErrorIfExists) {
|
|
629
|
-
throw new Error(`Body exists for action ${tag}`);
|
|
630
|
-
}
|
|
631
|
-
}
|
|
632
|
-
catch (e) {
|
|
633
|
-
throw e;
|
|
634
|
-
}
|
|
635
|
-
}
|
|
636
|
-
async parseRequestData(category, payload, key_description = []) {
|
|
637
|
-
await validators_1.CreateAppActionBodySchema.validateAsync(payload);
|
|
638
|
-
const data = (await this.inputsService.parseData({
|
|
639
|
-
data: payload.sample,
|
|
640
|
-
category,
|
|
641
|
-
type: payload.type,
|
|
642
|
-
expected: types_1.ExpectedValues.PARSESAMPLE,
|
|
643
|
-
key_description,
|
|
644
|
-
}));
|
|
645
|
-
let sample = JSON.stringify(payload.sample);
|
|
646
|
-
return Object.assign(Object.assign({}, payload), { sample, data });
|
|
647
|
-
}
|
|
648
|
-
// private fetc
|
|
649
|
-
async fetchActionRequestData(category, tag) {
|
|
650
|
-
try {
|
|
651
|
-
let data;
|
|
652
|
-
const action = await this.fetchAction(tag);
|
|
653
|
-
if (category === types_1.Categories.BODY) {
|
|
654
|
-
const { body } = action;
|
|
655
|
-
data = body.data;
|
|
656
|
-
}
|
|
657
|
-
else if (category === types_1.Categories.QUERY) {
|
|
658
|
-
const { query } = action;
|
|
659
|
-
data = query.data;
|
|
660
|
-
}
|
|
661
|
-
else if (category === types_1.Categories.PARAMS) {
|
|
662
|
-
const { params } = action;
|
|
663
|
-
data = params.data;
|
|
664
|
-
}
|
|
665
|
-
else if (category === types_1.Categories.HEADER) {
|
|
666
|
-
const { headers } = action;
|
|
667
|
-
data = headers.data;
|
|
668
|
-
}
|
|
669
|
-
else {
|
|
670
|
-
throw new Error(`Category ${category} doesn't exist`);
|
|
671
|
-
}
|
|
672
|
-
return data;
|
|
673
|
-
}
|
|
674
|
-
catch (e) {
|
|
675
|
-
throw e;
|
|
676
|
-
}
|
|
677
|
-
}
|
|
678
|
-
async fetchActionRequestSample(category, tag) {
|
|
679
|
-
try {
|
|
680
|
-
let sample;
|
|
681
|
-
const action = await this.fetchAction(tag);
|
|
682
|
-
if (category === types_1.Categories.BODY) {
|
|
683
|
-
const { body } = action;
|
|
684
|
-
sample = body.sample;
|
|
685
|
-
}
|
|
686
|
-
else if (category === types_1.Categories.QUERY) {
|
|
687
|
-
const { query } = action;
|
|
688
|
-
sample = query.sample;
|
|
689
|
-
}
|
|
690
|
-
else if (category === types_1.Categories.PARAMS) {
|
|
691
|
-
const { params } = action;
|
|
692
|
-
sample = params.sample;
|
|
693
|
-
}
|
|
694
|
-
else if (category === types_1.Categories.HEADER) {
|
|
695
|
-
const { headers } = action;
|
|
696
|
-
sample = headers.sample;
|
|
697
|
-
}
|
|
698
|
-
else {
|
|
699
|
-
throw new Error(`Category ${category} doesn't exist`);
|
|
700
|
-
}
|
|
701
|
-
return sample;
|
|
702
|
-
}
|
|
703
|
-
catch (e) {
|
|
704
|
-
throw e;
|
|
705
|
-
}
|
|
706
|
-
}
|
|
707
|
-
async createAppActionResponse(action_tag, payload) {
|
|
708
|
-
try {
|
|
709
|
-
await this.fetchAction(action_tag);
|
|
710
|
-
await validators_1.CreateAppActionResponseSchema.validateAsync(Object.assign({}, payload));
|
|
711
|
-
payload.tag = (0, string_utils_1.tagify)(payload.tag);
|
|
712
|
-
const exists = await this.fetchAppActionResponse(action_tag, payload.tag);
|
|
713
|
-
if (!exists) {
|
|
714
|
-
payload = await this.parseResponsePayload(payload);
|
|
715
|
-
await this.appApi.updateApp(this.app_id, Object.assign(Object.assign({}, payload), { action_tag, action: types_1.RequestAction.CREATE, component: types_1.AppComponents.ACTION_RESPONSE }), this.getUserAccess());
|
|
716
|
-
}
|
|
717
|
-
else {
|
|
718
|
-
await validators_1.UpdateAppActionResponseSchema.validateAsync(Object.assign({}, payload));
|
|
719
|
-
}
|
|
720
|
-
}
|
|
721
|
-
catch (e) {
|
|
722
|
-
throw e;
|
|
723
|
-
}
|
|
724
|
-
}
|
|
725
|
-
async parseResponsePayload(payload) {
|
|
726
|
-
await validators_1.CreateAppActionResponseSchema.validateAsync(Object.assign({}, payload));
|
|
727
|
-
const data = (await this.inputsService.parseData({
|
|
728
|
-
data: payload.body.sample,
|
|
729
|
-
category: types_1.Categories.RESPONSE,
|
|
730
|
-
type: payload.body.type,
|
|
731
|
-
expected: types_1.ExpectedValues.PARSESAMPLE,
|
|
732
|
-
}));
|
|
733
|
-
if (payload.success &&
|
|
734
|
-
!((payload.success_values && Object.keys(payload.success_values).length) || payload.is_status_code_success)) {
|
|
735
|
-
throw new Error('success_values or is_status_code_success required for success responses');
|
|
736
|
-
}
|
|
737
|
-
if (payload.success &&
|
|
738
|
-
payload.success_values &&
|
|
739
|
-
payload.success_values.body &&
|
|
740
|
-
payload.success_values.body.sample &&
|
|
741
|
-
Object.keys(payload.success_values.body.sample).length) {
|
|
742
|
-
const success_markers = (await this.inputsService.parseData({
|
|
743
|
-
data: payload.success_values.body.sample,
|
|
744
|
-
category: types_1.Categories.RESPONSE,
|
|
745
|
-
type: types_1.InputsTypes.JSON,
|
|
746
|
-
expected: types_1.ExpectedValues.PARSEINPUT,
|
|
747
|
-
}));
|
|
748
|
-
const invalidMarkers = await this.inputsService.compareIndexes(data, success_markers);
|
|
749
|
-
if (invalidMarkers.length)
|
|
750
|
-
throw new Error(`SUCCESS MARKERS KEYS: parent_key_level_key_index ${JSON.stringify(invalidMarkers)} do not exist in original sample`);
|
|
751
|
-
else {
|
|
752
|
-
payload.success_markers = success_markers;
|
|
753
|
-
payload.marker_type = payload.success_values.type;
|
|
754
|
-
}
|
|
755
|
-
}
|
|
756
|
-
payload.body.data = data;
|
|
757
|
-
payload.body.sample = JSON.stringify(payload.body.sample);
|
|
758
|
-
if (payload.envs && payload.envs.length) {
|
|
759
|
-
const envIds = await Promise.all(payload.envs.map(async (slug) => {
|
|
760
|
-
const env = await this.fetchEnv(slug);
|
|
761
|
-
return env._id;
|
|
762
|
-
}));
|
|
763
|
-
payload.envs = envIds;
|
|
764
|
-
}
|
|
765
|
-
return payload;
|
|
766
|
-
}
|
|
767
|
-
async fetchAppActionResponse(action_tag, response_tag, throwErrorIfExists = false) {
|
|
768
|
-
const action = await this.fetchAction(action_tag);
|
|
769
|
-
const { responses } = action;
|
|
770
|
-
const response = responses.find((data) => data.tag === response_tag);
|
|
771
|
-
if (!response && throwErrorIfExists)
|
|
772
|
-
throw new Error(`Response ${response_tag} not found`);
|
|
773
|
-
return response;
|
|
774
|
-
}
|
|
775
|
-
/*async extractEventData(data: Partial<IAppEvent>): Promise<Partial<IAppEvent>> {
|
|
776
|
-
if (data.response) {
|
|
777
|
-
data.response.data = (await this.inputsService.parseData({
|
|
778
|
-
data: data.response.sample,
|
|
779
|
-
category: Categories.WEBHOOK,
|
|
780
|
-
type: data.response.type,
|
|
781
|
-
expected: ExpectedValues.PARSESAMPLE,
|
|
782
|
-
})) as unknown as Array<IParsedSample>;
|
|
783
|
-
data.response.sample = JSON.stringify(data.response.sample);
|
|
784
|
-
}
|
|
785
|
-
|
|
786
|
-
if (data.request) {
|
|
787
|
-
data.request.data = (await this.inputsService.parseData({
|
|
788
|
-
data: data.request.sample,
|
|
789
|
-
category: Categories.WEBHOOK,
|
|
790
|
-
type: data.response.type,
|
|
791
|
-
expected: ExpectedValues.PARSESAMPLE,
|
|
792
|
-
})) as unknown as Array<IParsedSample>;
|
|
793
|
-
data.request.sample = JSON.stringify(data.request.sample);
|
|
794
|
-
}
|
|
795
|
-
|
|
796
|
-
if (data.body) {
|
|
797
|
-
data.body.data = (await this.inputsService.parseData({
|
|
798
|
-
data: data.body.sample,
|
|
799
|
-
category: Categories.WEBHOOK,
|
|
800
|
-
type: data.body.type,
|
|
801
|
-
expected: ExpectedValues.PARSESAMPLE,
|
|
802
|
-
})) as unknown as Array<IParsedSample>;
|
|
803
|
-
data.body.sample = JSON.stringify(data.body.sample);
|
|
804
|
-
}
|
|
805
|
-
|
|
806
|
-
if (data.resource) {
|
|
807
|
-
const { query, params } = await this.extractResourceData(data.resource);
|
|
808
|
-
|
|
809
|
-
data.query = { type: InputsTypes.JSON, ...query } as unknown as ISample;
|
|
810
|
-
data.params = { type: InputsTypes.JSON, ...params } as unknown as ISample;
|
|
811
|
-
data.resource = extractURLPath(data.resource);
|
|
812
|
-
}
|
|
813
|
-
|
|
814
|
-
return data;
|
|
815
|
-
}*/
|
|
816
|
-
/*async createEvent(data: Partial<IAppEvent>): Promise<void> {
|
|
817
|
-
try {
|
|
818
|
-
if (data.envs) {
|
|
819
|
-
for (const env of data.envs) {
|
|
820
|
-
const found = this.app.envs.findIndex((appEnv) => appEnv.slug === env.slug);
|
|
821
|
-
if (found === -1) {
|
|
822
|
-
throw new Error(`invalid env slug ${env.slug} is not defined`);
|
|
823
|
-
}
|
|
824
|
-
}
|
|
825
|
-
}
|
|
826
|
-
|
|
827
|
-
if (data.action_tag) {
|
|
828
|
-
const found = this.app.actions.findIndex((action) => action.tag === data.action_tag);
|
|
829
|
-
if (found === -1) {
|
|
830
|
-
throw new Error(`invalid action tag ${data.action_tag} is not defined`);
|
|
831
|
-
}
|
|
832
|
-
}
|
|
833
|
-
|
|
834
|
-
const { resource } = data;
|
|
835
|
-
|
|
836
|
-
if (data.resource) data.resource = extractURLPath(data.resource);
|
|
837
|
-
|
|
838
|
-
await CreateAppEventSchema.validateAsync(data);
|
|
839
|
-
data = await this.extractEventData({ ...data, resource });
|
|
840
|
-
|
|
841
|
-
await this.appApi.updateApp(
|
|
842
|
-
this.app_id,
|
|
843
|
-
{
|
|
844
|
-
...data,
|
|
845
|
-
action: RequestAction.CREATE,
|
|
846
|
-
component: AppComponents.EVENT,
|
|
847
|
-
},
|
|
848
|
-
this.getUserAccess(),
|
|
849
|
-
);
|
|
850
|
-
|
|
851
|
-
//await this.initializeApp(this.app_id);
|
|
852
|
-
} catch (e) {
|
|
853
|
-
throw e;
|
|
854
|
-
}
|
|
855
|
-
}
|
|
856
|
-
|
|
857
|
-
async updateEvent(tag: string, data: Partial<IAppEvent>): Promise<void> {
|
|
858
|
-
try {
|
|
859
|
-
const { resource } = data;
|
|
860
|
-
|
|
861
|
-
if (data.resource) data.resource = extractURLPath(data.resource);
|
|
862
|
-
|
|
863
|
-
await UpdateAppEventSchema.validateAsync(data);
|
|
864
|
-
|
|
865
|
-
data = await this.extractEventData({ ...data, resource });
|
|
866
|
-
|
|
867
|
-
const { _id } = this.fetchEvent(tag);
|
|
868
|
-
|
|
869
|
-
data = await this.extractEventData(data);
|
|
870
|
-
await this.appApi.updateApp(
|
|
871
|
-
this.app_id,
|
|
872
|
-
{
|
|
873
|
-
_id,
|
|
874
|
-
tag,
|
|
875
|
-
...data,
|
|
876
|
-
action: RequestAction.UPDATE,
|
|
877
|
-
component: AppComponents.EVENT,
|
|
878
|
-
},
|
|
879
|
-
this.getUserAccess(),
|
|
880
|
-
);
|
|
881
|
-
|
|
882
|
-
//await this.initializeApp(this.app_id);
|
|
883
|
-
} catch (e) {
|
|
884
|
-
throw e;
|
|
885
|
-
}
|
|
886
|
-
}
|
|
887
|
-
|
|
888
|
-
fetchEvents(): Array<IAppEvent> {
|
|
889
|
-
return this.app.events;
|
|
890
|
-
}
|
|
891
|
-
|
|
892
|
-
fetchEvent(tag: string): IAppEvent {
|
|
893
|
-
const auth = this.app.events.find((data: IAppEvent) => data.tag === tag);
|
|
894
|
-
|
|
895
|
-
if (!auth) throw new Error(`Auth ${tag} not found`);
|
|
896
|
-
|
|
897
|
-
return auth;
|
|
898
|
-
}*/
|
|
899
|
-
async extractAuthData(data) {
|
|
900
|
-
if (data.tokens.body) {
|
|
901
|
-
const sample = JSON.stringify(data.tokens.body);
|
|
902
|
-
const d = await this.inputsService.parseData({
|
|
903
|
-
data: data.tokens.body,
|
|
904
|
-
category: types_1.Categories.BODY,
|
|
905
|
-
type: types_1.InputsTypes.JSON,
|
|
906
|
-
expected: types_1.ExpectedValues.PARSESAMPLE,
|
|
907
|
-
});
|
|
908
|
-
data.tokens.body = { sample, data: d };
|
|
909
|
-
}
|
|
910
|
-
if (data.tokens.headers) {
|
|
911
|
-
const sample = JSON.stringify(data.tokens.headers);
|
|
912
|
-
const d = await this.inputsService.parseData({
|
|
913
|
-
data: data.tokens.headers,
|
|
914
|
-
category: types_1.Categories.HEADER,
|
|
915
|
-
type: types_1.InputsTypes.JSON,
|
|
916
|
-
expected: types_1.ExpectedValues.PARSESAMPLE,
|
|
917
|
-
});
|
|
918
|
-
data.tokens.headers = { sample, data: d };
|
|
919
|
-
}
|
|
920
|
-
if (data.tokens.query) {
|
|
921
|
-
const sample = JSON.stringify(data.tokens.query);
|
|
922
|
-
const d = await this.inputsService.parseData({
|
|
923
|
-
data: data.tokens.query,
|
|
924
|
-
category: types_1.Categories.QUERY,
|
|
925
|
-
type: types_1.InputsTypes.JSON,
|
|
926
|
-
expected: types_1.ExpectedValues.PARSESAMPLE,
|
|
927
|
-
});
|
|
928
|
-
data.tokens.query = { sample, data: d };
|
|
929
|
-
}
|
|
930
|
-
if (data.tokens.params) {
|
|
931
|
-
const sample = JSON.stringify(data.tokens.params);
|
|
932
|
-
const d = await this.inputsService.parseData({
|
|
933
|
-
data: data.tokens.params,
|
|
934
|
-
category: types_1.Categories.PARAMS,
|
|
935
|
-
type: types_1.InputsTypes.JSON,
|
|
936
|
-
expected: types_1.ExpectedValues.PARSESAMPLE,
|
|
937
|
-
});
|
|
938
|
-
data.tokens.params = { sample, data: d };
|
|
939
|
-
}
|
|
940
|
-
return data;
|
|
941
|
-
}
|
|
942
|
-
// TODO: make this better
|
|
943
|
-
async createAuth(data) {
|
|
944
|
-
try {
|
|
945
|
-
const { setup_type, action_tag, tokens } = data;
|
|
946
|
-
if (setup_type === types_1.AuthTypes.CREDENTIALS && !action_tag) {
|
|
947
|
-
throw new Error(`Action tag required for setup type ${setup_type}`);
|
|
948
|
-
}
|
|
949
|
-
if (setup_type === types_1.AuthTypes.TOKEN && !tokens) {
|
|
950
|
-
throw new Error(`tokens sample required for setup type ${setup_type}`);
|
|
951
|
-
}
|
|
952
|
-
await validators_1.CreateAppAuthSchema.validateAsync(data);
|
|
953
|
-
if (setup_type === types_1.AuthTypes.TOKEN && !tokens.body && !tokens.headers && !tokens.params && !tokens.query) {
|
|
954
|
-
throw new Error(`token has to have one of body, headers, params or query set`);
|
|
955
|
-
}
|
|
956
|
-
if (setup_type === types_1.AuthTypes.CREDENTIALS) {
|
|
957
|
-
await this.fetchAction(action_tag);
|
|
958
|
-
}
|
|
959
|
-
data = await this.extractAuthData(Object.assign({}, data));
|
|
960
|
-
await this.appApi.updateApp(this.app_id, Object.assign(Object.assign({}, data), { action: types_1.RequestAction.CREATE, component: types_1.AppComponents.AUTH }), this.getUserAccess());
|
|
961
|
-
//await this.initializeApp(this.app_id);
|
|
962
|
-
}
|
|
963
|
-
catch (e) {
|
|
964
|
-
throw e;
|
|
965
|
-
}
|
|
966
|
-
}
|
|
967
|
-
async updateAuth(tag, data) {
|
|
968
|
-
try {
|
|
969
|
-
await validators_1.UpdateAppAuthSchema.validateAsync(data);
|
|
970
|
-
const auth = await this.fetchAuth(tag);
|
|
971
|
-
data = await this.extractAuthData(Object.assign(Object.assign({}, auth), data));
|
|
972
|
-
await this.appApi.updateApp(this.app_id, Object.assign(Object.assign({ tag }, data), { action: types_1.RequestAction.UPDATE, component: types_1.AppComponents.AUTH }), this.getUserAccess());
|
|
973
|
-
//await this.initializeApp(this.app_id);
|
|
974
|
-
//await this.initializeApp(this.app_id);
|
|
975
|
-
}
|
|
976
|
-
catch (e) {
|
|
977
|
-
throw e;
|
|
978
|
-
}
|
|
979
|
-
}
|
|
980
|
-
async fetchAuths() {
|
|
981
|
-
const components = await this.appApi.fetchAppComponents(this.app_id, 'auth', this.getUserAccess(), this.appVersion.tag);
|
|
982
|
-
return components;
|
|
983
|
-
}
|
|
984
|
-
async fetchAuth(tag) {
|
|
985
|
-
const auths = await this.fetchAuths();
|
|
986
|
-
const auth = auths.find((data) => data.tag === tag);
|
|
987
|
-
if (!auth)
|
|
988
|
-
throw new Error(`Auth ${tag} not found`);
|
|
989
|
-
return auth;
|
|
990
|
-
}
|
|
991
|
-
async createVariable(data, throwErrorIfExists = false) {
|
|
992
|
-
try {
|
|
993
|
-
await validators_1.CreateAppVariableSchema.validateAsync(data);
|
|
994
|
-
const exists = await this.fetchVariable(data.key, false);
|
|
995
|
-
if (exists && throwErrorIfExists)
|
|
996
|
-
throw new Error(`Variable ${data.key} exists`);
|
|
997
|
-
if (!exists) {
|
|
998
|
-
await this.appApi.updateApp(this.app_id, Object.assign(Object.assign({}, data), { action: types_1.RequestAction.CREATE, component: types_1.AppComponents.VARIABLE }), this.getUserAccess());
|
|
999
|
-
}
|
|
1000
|
-
//await this.initializeApp(this.app_id);
|
|
1001
|
-
}
|
|
1002
|
-
catch (e) {
|
|
1003
|
-
throw e;
|
|
1004
|
-
}
|
|
1005
|
-
}
|
|
1006
|
-
async updateVariable(key, data) {
|
|
1007
|
-
try {
|
|
1008
|
-
await validators_1.UpdateAppVariableSchema.validateAsync(data);
|
|
1009
|
-
await this.fetchVariable(key);
|
|
1010
|
-
await this.appApi.updateApp(this.app_id, Object.assign(Object.assign({}, data), { key, action: types_1.RequestAction.UPDATE, component: types_1.AppComponents.VARIABLE }), this.getUserAccess());
|
|
1011
|
-
//await this.initializeApp(this.app_id);
|
|
1012
|
-
}
|
|
1013
|
-
catch (e) {
|
|
1014
|
-
throw e;
|
|
1015
|
-
}
|
|
1016
|
-
}
|
|
1017
|
-
async fetchVariables() {
|
|
1018
|
-
const components = await this.appApi.fetchAppComponents(this.app_id, 'variable', this.getUserAccess(), this.appVersion.tag);
|
|
1019
|
-
return components;
|
|
1020
|
-
}
|
|
1021
|
-
async fetchVariable(key, throwErrorIfExists = true) {
|
|
1022
|
-
const variables = await this.fetchVariables();
|
|
1023
|
-
const variable = variables.find((data) => data.key === key);
|
|
1024
|
-
if (!variable && throwErrorIfExists)
|
|
1025
|
-
throw new Error(`Variable ${key} not found`);
|
|
1026
|
-
return variable;
|
|
1027
|
-
}
|
|
1028
|
-
async createConstant(data, throwErrorIfExists = false) {
|
|
1029
|
-
try {
|
|
1030
|
-
await validators_1.CreateAppConstantSchema.validateAsync(data);
|
|
1031
|
-
const exists = await this.fetchConstant(data.key, false);
|
|
1032
|
-
if (exists && throwErrorIfExists)
|
|
1033
|
-
throw new Error(`Constant ${data.key} exists`);
|
|
1034
|
-
await this.appApi.updateApp(this.app_id, Object.assign(Object.assign({}, data), { action: types_1.RequestAction.CREATE, component: types_1.AppComponents.CONSTANT }), this.getUserAccess());
|
|
1035
|
-
//await this.initializeApp(this.app_id);
|
|
1036
|
-
}
|
|
1037
|
-
catch (e) {
|
|
1038
|
-
throw e;
|
|
1039
|
-
}
|
|
1040
|
-
}
|
|
1041
|
-
async updateConstant(key, data) {
|
|
1042
|
-
await validators_1.UpdateAppConstantSchema.validateAsync(data);
|
|
1043
|
-
await this.fetchConstant(key);
|
|
1044
|
-
await this.appApi.updateApp(this.app_id, Object.assign(Object.assign({}, data), { action: types_1.RequestAction.UPDATE, component: types_1.AppComponents.CONSTANT }), this.getUserAccess());
|
|
1045
|
-
//await this.initializeApp(this.app_id);
|
|
1046
|
-
}
|
|
1047
|
-
async fetchConstants() {
|
|
1048
|
-
const components = await this.appApi.fetchAppComponents(this.app_id, 'constant', this.getUserAccess(), this.appVersion.tag);
|
|
1049
|
-
return components;
|
|
1050
|
-
}
|
|
1051
|
-
async fetchConstant(key, throwErrorIfExists = true) {
|
|
1052
|
-
const constants = await this.fetchConstants();
|
|
1053
|
-
const variable = constants.find((data) => data.key === key);
|
|
1054
|
-
if (!variable && throwErrorIfExists)
|
|
1055
|
-
throw new Error(`Constant ${key} not found`);
|
|
1056
|
-
return variable;
|
|
1057
|
-
}
|
|
1058
|
-
async updateDataValidation(locator, update) {
|
|
1059
|
-
const stages = (0, string_utils_2.extractStages)(locator);
|
|
1060
|
-
if (stages.length === 0) {
|
|
1061
|
-
throw new Error(`Missing locators in ${locator}`);
|
|
1062
|
-
}
|
|
1063
|
-
// Convert stages to string[] for functions expecting string[]
|
|
1064
|
-
const stringStages = stages.map(stage => String(stage));
|
|
1065
|
-
if (locator.startsWith('$Body{')) {
|
|
1066
|
-
await this.updateValidation(types_1.AppCategories.BODY, stringStages, update);
|
|
1067
|
-
}
|
|
1068
|
-
else if (locator.startsWith('$Query{')) {
|
|
1069
|
-
await this.updateValidation(types_1.AppCategories.QUERY, stringStages, update);
|
|
1070
|
-
}
|
|
1071
|
-
else if (locator.startsWith('$Params{')) {
|
|
1072
|
-
await this.updateValidation(types_1.AppCategories.PARAMS, stringStages, update);
|
|
1073
|
-
}
|
|
1074
|
-
else if (locator.startsWith('$Header{')) {
|
|
1075
|
-
await this.updateValidation(types_1.AppCategories.HEADER, stringStages, update);
|
|
1076
|
-
}
|
|
1077
|
-
else {
|
|
1078
|
-
throw new Error(`Invalid input ${locator}`);
|
|
1079
|
-
}
|
|
1080
|
-
}
|
|
1081
|
-
async updateValidation(category, stages, update) {
|
|
1082
|
-
try {
|
|
1083
|
-
const action_tag = stages[0];
|
|
1084
|
-
const action = await this.fetchAction(action_tag);
|
|
1085
|
-
const data = action[category];
|
|
1086
|
-
let level = -1;
|
|
1087
|
-
let key = '';
|
|
1088
|
-
let datapoint;
|
|
1089
|
-
let datapointIndex;
|
|
1090
|
-
const exclude = category === types_1.AppCategories.BODY
|
|
1091
|
-
? [types_1.AppCategories.HEADER, types_1.AppCategories.PARAMS, types_1.AppCategories.QUERY]
|
|
1092
|
-
: category === types_1.AppCategories.HEADER
|
|
1093
|
-
? [types_1.AppCategories.BODY, types_1.AppCategories.PARAMS, types_1.AppCategories.QUERY]
|
|
1094
|
-
: category === types_1.AppCategories.PARAMS
|
|
1095
|
-
? [types_1.AppCategories.BODY, types_1.AppCategories.HEADER, types_1.AppCategories.QUERY]
|
|
1096
|
-
: [types_1.AppCategories.BODY, types_1.AppCategories.PARAMS, types_1.AppCategories.HEADER];
|
|
1097
|
-
for (let i = 1; i < stages.length; i++) {
|
|
1098
|
-
const parent_key = key;
|
|
1099
|
-
key = stages[i];
|
|
1100
|
-
level++;
|
|
1101
|
-
const index = data.data.findIndex((item) => item.level === level && item.key === key && item.parent_key === parent_key);
|
|
1102
|
-
if (index === -1) {
|
|
1103
|
-
throw new Error(`Datapoint ${key} not found in Action ${action_tag}'s ${category} data`);
|
|
1104
|
-
}
|
|
1105
|
-
if (index > -1 && i === stages.length - 1) {
|
|
1106
|
-
datapoint = data.data[index];
|
|
1107
|
-
datapointIndex = index;
|
|
1108
|
-
}
|
|
1109
|
-
}
|
|
1110
|
-
data.data[datapointIndex] = Object.assign(Object.assign({}, data.data[datapointIndex]), update);
|
|
1111
|
-
action[category] = data;
|
|
1112
|
-
const cleaned_action = (0, objects_utils_1.CleanObj)(action, [
|
|
1113
|
-
'tag',
|
|
1114
|
-
'_id',
|
|
1115
|
-
'created',
|
|
1116
|
-
'envs',
|
|
1117
|
-
'resource',
|
|
1118
|
-
'name',
|
|
1119
|
-
'method',
|
|
1120
|
-
'responses',
|
|
1121
|
-
...exclude,
|
|
1122
|
-
]);
|
|
1123
|
-
await this.appApi.updateApp(this.app_id, Object.assign(Object.assign({ tag: action_tag }, action), { component: types_1.AppComponents.VALIDATION, action: types_1.RequestAction.UPDATE }), this.getUserAccess());
|
|
1124
|
-
//await this.initializeApp(this.app_id);
|
|
1125
|
-
}
|
|
1126
|
-
catch (e) {
|
|
1127
|
-
throw e;
|
|
1128
|
-
}
|
|
1129
|
-
}
|
|
1130
|
-
async createWebhook(data, throwErrorIfExists = false) {
|
|
1131
|
-
try {
|
|
1132
|
-
// TODO: figure out a way to check if this has run before, halt if it has
|
|
1133
|
-
const existingWebhook = await this.fetchWebhook(data.tag);
|
|
1134
|
-
if (!existingWebhook) {
|
|
1135
|
-
await create_appWebhook_validator_1.IAppWebhookSchema.validateAsync(data);
|
|
1136
|
-
data.envs = await Promise.all(data.envs.map(async (env) => {
|
|
1137
|
-
const exists = await this.fetchEnv(env.slug);
|
|
1138
|
-
if (!exists) {
|
|
1139
|
-
throw new Error(`Env ${env.slug} does not exist`);
|
|
1140
|
-
}
|
|
1141
|
-
if (env.sample) {
|
|
1142
|
-
const bodyTemplate = env.sample.body ? (0, string_utils_2.extractPlaceholders)(JSON.stringify(env.sample.body), 'body') : [];
|
|
1143
|
-
const queryTemplate = env.sample.query
|
|
1144
|
-
? (0, string_utils_2.extractPlaceholders)(JSON.stringify(env.sample.query), 'query')
|
|
1145
|
-
: [];
|
|
1146
|
-
const paramsTemplate = env.sample.params
|
|
1147
|
-
? (0, string_utils_2.extractPlaceholders)(JSON.stringify(env.sample.params), 'params')
|
|
1148
|
-
: [];
|
|
1149
|
-
const headerTemplate = env.sample.headers
|
|
1150
|
-
? (0, string_utils_2.extractPlaceholders)(JSON.stringify(env.sample.headers), 'headers')
|
|
1151
|
-
: [];
|
|
1152
|
-
env.sample_data = [...bodyTemplate, ...queryTemplate, ...paramsTemplate, ...headerTemplate];
|
|
1153
|
-
}
|
|
1154
|
-
return env;
|
|
1155
|
-
}));
|
|
1156
|
-
const envs = await this.fetchEnvs();
|
|
1157
|
-
envs.map((env) => {
|
|
1158
|
-
const exists = data.envs.findIndex((dbEnv) => dbEnv.slug === env.slug);
|
|
1159
|
-
if (exists === -1) {
|
|
1160
|
-
throw new Error(`Product env ${env.slug} is not defined, please provide webhook registration details`);
|
|
1161
|
-
}
|
|
1162
|
-
});
|
|
1163
|
-
await this.appApi.updateApp(this.app_id, Object.assign(Object.assign({}, data), { component: types_1.AppComponents.WEBHOOK, action: types_1.RequestAction.CREATE }), this.getUserAccess());
|
|
1164
|
-
//await this.initializeApp(this.app_id);
|
|
1165
|
-
}
|
|
1166
|
-
else {
|
|
1167
|
-
if (throwErrorIfExists)
|
|
1168
|
-
throw new Error(`Database ${data.tag} already exists`);
|
|
1169
|
-
}
|
|
1170
|
-
}
|
|
1171
|
-
catch (e) {
|
|
1172
|
-
throw e;
|
|
1173
|
-
}
|
|
1174
|
-
}
|
|
1175
|
-
async updateWebhook(tag, data) {
|
|
1176
|
-
try {
|
|
1177
|
-
const webhook = await this.fetchWebhook(tag);
|
|
1178
|
-
const { _id, envs } = webhook;
|
|
1179
|
-
await update_appWebhook_validator_1.IAppWebhookUpdateSchema.validateAsync(data); // Change to update;
|
|
1180
|
-
if (data.tag) {
|
|
1181
|
-
const existingWebhook = await this.fetchWebhook(data.tag);
|
|
1182
|
-
if (existingWebhook) {
|
|
1183
|
-
throw new Error(`tag ${tag} is in use`); // TODO: also check on the backend
|
|
1184
|
-
}
|
|
1185
|
-
}
|
|
1186
|
-
data.envs = await Promise.all(data.envs.map(async (env) => {
|
|
1187
|
-
const exists = await this.fetchEnv(env.slug);
|
|
1188
|
-
if (!exists) {
|
|
1189
|
-
throw new Error(`Env ${env.slug} does not exist`);
|
|
1190
|
-
}
|
|
1191
|
-
if (env.sample) {
|
|
1192
|
-
const bodyTemplate = env.sample.body ? (0, string_utils_2.extractPlaceholders)(JSON.stringify(env.sample.body), 'body') : [];
|
|
1193
|
-
const queryTemplate = env.sample.query ? (0, string_utils_2.extractPlaceholders)(JSON.stringify(env.sample.query), 'query') : [];
|
|
1194
|
-
const paramsTemplate = env.sample.params
|
|
1195
|
-
? (0, string_utils_2.extractPlaceholders)(JSON.stringify(env.sample.params), 'params')
|
|
1196
|
-
: [];
|
|
1197
|
-
const headerTemplate = env.sample.headers
|
|
1198
|
-
? (0, string_utils_2.extractPlaceholders)(JSON.stringify(env.sample.headers), 'headers')
|
|
1199
|
-
: [];
|
|
1200
|
-
env.sample_data = [...bodyTemplate, ...queryTemplate, ...paramsTemplate, ...headerTemplate];
|
|
1201
|
-
}
|
|
1202
|
-
return env;
|
|
1203
|
-
}));
|
|
1204
|
-
const overwrite = [];
|
|
1205
|
-
const newEnvs = [];
|
|
1206
|
-
for (const env of envs) {
|
|
1207
|
-
const exists = data.envs.findIndex((dataEnv) => env.slug === dataEnv.slug);
|
|
1208
|
-
const envExists = await this.fetchEnv(env.slug, false);
|
|
1209
|
-
if (!envExists) {
|
|
1210
|
-
throw new Error(`Product Environment ${env.slug} doesn't exist`);
|
|
1211
|
-
}
|
|
1212
|
-
if (exists === -1) {
|
|
1213
|
-
newEnvs.push(data.envs[exists]);
|
|
1214
|
-
}
|
|
1215
|
-
else {
|
|
1216
|
-
overwrite.push(Object.assign(Object.assign({}, env), data.envs[exists]));
|
|
1217
|
-
}
|
|
1218
|
-
}
|
|
1219
|
-
const unchanged = [];
|
|
1220
|
-
envs.map((env) => {
|
|
1221
|
-
const newEnv = newEnvs.findIndex((dataEnv) => env.slug === dataEnv.slug) > -1;
|
|
1222
|
-
const overwriteEnv = overwrite.findIndex((dataEnv) => env.slug === dataEnv.slug) > -1;
|
|
1223
|
-
if (!newEnv && !overwriteEnv) {
|
|
1224
|
-
unchanged.push(env);
|
|
1225
|
-
}
|
|
1226
|
-
});
|
|
1227
|
-
data.envs = [...unchanged, ...overwrite, ...newEnvs];
|
|
1228
|
-
data.envs = [...overwrite, ...newEnvs];
|
|
1229
|
-
await this.appApi.updateApp(this.app_id, Object.assign(Object.assign({ _id }, data), { component: types_1.AppComponents.WEBHOOK, action: types_1.RequestAction.UPDATE }), this.getUserAccess());
|
|
1230
|
-
//await this.initializeApp(this.app_id);
|
|
1231
|
-
}
|
|
1232
|
-
catch (e) {
|
|
1233
|
-
throw e;
|
|
1234
|
-
}
|
|
1235
|
-
}
|
|
1236
|
-
async fetchWebhook(tag) {
|
|
1237
|
-
const webhooks = await this.fetchWebhooks();
|
|
1238
|
-
const exists = webhooks === null || webhooks === void 0 ? void 0 : webhooks.find((data) => data.tag === tag);
|
|
1239
|
-
return exists;
|
|
1240
|
-
}
|
|
1241
|
-
async fetchWebhooks() {
|
|
1242
|
-
const components = await this.appApi.fetchAppComponents(this.app_id, 'webhook', this.getUserAccess(), this.appVersion.tag);
|
|
1243
|
-
return components;
|
|
1244
|
-
}
|
|
1245
|
-
async createWebhookEvent(data, throwErrorIfExists = false) {
|
|
1246
|
-
try {
|
|
1247
|
-
await create_appWebhookEvent_validator_1.IAppWebhookEventSchema.validateAsync(data);
|
|
1248
|
-
if (!data.tag) {
|
|
1249
|
-
throw new Error('tag field is required');
|
|
1250
|
-
}
|
|
1251
|
-
const [webhookTag, tag] = data.tag.split(':');
|
|
1252
|
-
if (!webhookTag || !tag) {
|
|
1253
|
-
throw new Error(`tag is expected to be defined as "webhook_tag:event_tag"`);
|
|
1254
|
-
}
|
|
1255
|
-
const exists = await this.fetchWebhookEvent(data.tag);
|
|
1256
|
-
data.tag = tag;
|
|
1257
|
-
if (!exists) {
|
|
1258
|
-
// Handle comma-separated selectors (e.g., "$Event{Status},$Event{Type}")
|
|
1259
|
-
const selectors = data.selector.split(',').map(s => s.trim());
|
|
1260
|
-
const selectorValues = {};
|
|
1261
|
-
for (const selector of selectors) {
|
|
1262
|
-
if (!selector.startsWith('$Event{')) {
|
|
1263
|
-
throw new Error('Selector should be in the format $Event{...}{key}');
|
|
1264
|
-
}
|
|
1265
|
-
const stages = (0, string_utils_2.extractStages)(selector);
|
|
1266
|
-
let current = data.sample;
|
|
1267
|
-
for (const stage of stages) {
|
|
1268
|
-
if (current && typeof current === 'object' && stage in current) {
|
|
1269
|
-
current = current[stage];
|
|
1270
|
-
}
|
|
1271
|
-
else {
|
|
1272
|
-
throw new Error(`${selector} not found in event sample`);
|
|
1273
|
-
}
|
|
1274
|
-
}
|
|
1275
|
-
if (current === null ||
|
|
1276
|
-
typeof current === "undefined" ||
|
|
1277
|
-
typeof current === "object") {
|
|
1278
|
-
throw new Error("Selector value is not allowed to be an object|array|null|undefined");
|
|
1279
|
-
}
|
|
1280
|
-
// Store the selector and its value
|
|
1281
|
-
selectorValues[selector] = current;
|
|
1282
|
-
}
|
|
1283
|
-
// For single selector, use the value directly; for multiple, use the object
|
|
1284
|
-
const combinedSelectorValue = selectors.length === 1
|
|
1285
|
-
? selectorValues[selectors[0]]
|
|
1286
|
-
: selectorValues;
|
|
1287
|
-
//check other webhooksevents to see if there are other places where selector and selectorValue match up
|
|
1288
|
-
const existing = await this.fetchWebhookEvents(webhookTag);
|
|
1289
|
-
existing === null || existing === void 0 ? void 0 : existing.map((event) => {
|
|
1290
|
-
if (selectors.length === 1) {
|
|
1291
|
-
// Single selector comparison (backward compatible)
|
|
1292
|
-
if (event.selector === data.selector && event.selectorValue === combinedSelectorValue) {
|
|
1293
|
-
throw new Error(`Selector ${data.selector} with value ${combinedSelectorValue} already exists on event ${event.tag}`);
|
|
1294
|
-
}
|
|
1295
|
-
}
|
|
1296
|
-
else {
|
|
1297
|
-
// Multiple selectors - compare the full selector string and combined values
|
|
1298
|
-
if (event.selector === data.selector && JSON.stringify(event.selectorValue) === JSON.stringify(combinedSelectorValue)) {
|
|
1299
|
-
throw new Error(`Selectors ${data.selector} with values ${JSON.stringify(combinedSelectorValue)} already exists on event ${event.tag}`);
|
|
1300
|
-
}
|
|
1301
|
-
}
|
|
1302
|
-
});
|
|
1303
|
-
data.sample_data = await this.inputsService.parseJson({
|
|
1304
|
-
data: data.sample,
|
|
1305
|
-
expected: types_1.ExpectedValues.PARSESAMPLE
|
|
1306
|
-
});
|
|
1307
|
-
data.selectorValue = combinedSelectorValue;
|
|
1308
|
-
delete data.tag;
|
|
1309
|
-
const payload = Object.assign(Object.assign({}, data), { webhookTag,
|
|
1310
|
-
tag, component: types_1.AppComponents.WEBHOOK_EVENT, action: types_1.RequestAction.CREATE });
|
|
1311
|
-
await this.appApi.updateApp(this.app_id, payload, this.getUserAccess());
|
|
1312
|
-
//await this.initializeApp(this.app_id);
|
|
1313
|
-
}
|
|
1314
|
-
else {
|
|
1315
|
-
if (throwErrorIfExists)
|
|
1316
|
-
throw new Error(`Webhook Event ${data.tag} already exists`);
|
|
1317
|
-
}
|
|
1318
|
-
}
|
|
1319
|
-
catch (e) {
|
|
1320
|
-
throw e;
|
|
1321
|
-
}
|
|
1322
|
-
}
|
|
1323
|
-
async updateWebhookEvent(data) {
|
|
1324
|
-
try {
|
|
1325
|
-
await update_appWebhookEvent_validator_1.IAppWebhookEventUpdateSchema.validateAsync(data);
|
|
1326
|
-
if (!data.tag) {
|
|
1327
|
-
throw new Error('tag field is required');
|
|
1328
|
-
}
|
|
1329
|
-
const [webhookTag, tag] = data.tag.split(':');
|
|
1330
|
-
if (!webhookTag || !tag) {
|
|
1331
|
-
throw new Error(`tag is expected to be defined as "webhook_tag:event_tag"`);
|
|
1332
|
-
}
|
|
1333
|
-
// Fetch required data
|
|
1334
|
-
//const notification = await this.fetchNotification(notificationTag);
|
|
1335
|
-
const event = await this.fetchWebhookEvent(data.tag);
|
|
1336
|
-
// Validate and process the template
|
|
1337
|
-
data.tag = tag;
|
|
1338
|
-
if (data.sample && !data.selector) {
|
|
1339
|
-
throw new Error(`selector is required when new event sample is supplied`);
|
|
1340
|
-
}
|
|
1341
|
-
if (data.sample) {
|
|
1342
|
-
// Handle comma-separated selectors (e.g., "$Event{Status},$Event{Type}")
|
|
1343
|
-
const selectors = data.selector.split(',').map(s => s.trim());
|
|
1344
|
-
const selectorValues = {};
|
|
1345
|
-
for (const selector of selectors) {
|
|
1346
|
-
if (!selector.startsWith('$Event{')) {
|
|
1347
|
-
throw new Error('Selector should be in the format $Event{...}{key}');
|
|
1348
|
-
}
|
|
1349
|
-
const stages = (0, string_utils_2.extractStages)(selector);
|
|
1350
|
-
let current = data.sample;
|
|
1351
|
-
for (const stage of stages) {
|
|
1352
|
-
if (current && typeof current === 'object' && stage in current) {
|
|
1353
|
-
current = current[stage];
|
|
1354
|
-
}
|
|
1355
|
-
else {
|
|
1356
|
-
throw new Error(`${selector} not found in event sample`);
|
|
1357
|
-
}
|
|
1358
|
-
}
|
|
1359
|
-
if (current === null ||
|
|
1360
|
-
typeof current === "undefined" ||
|
|
1361
|
-
typeof current === "object") {
|
|
1362
|
-
throw new Error("Selector value is not allowed to be an object|array|null|undefined");
|
|
1363
|
-
}
|
|
1364
|
-
// Store the selector and its value
|
|
1365
|
-
selectorValues[selector] = current;
|
|
1366
|
-
}
|
|
1367
|
-
// For single selector, use the value directly; for multiple, use the object
|
|
1368
|
-
const combinedSelectorValue = selectors.length === 1
|
|
1369
|
-
? selectorValues[selectors[0]]
|
|
1370
|
-
: selectorValues;
|
|
1371
|
-
//check other webhooksevents to see if there are other places where selector and selectorValue match up
|
|
1372
|
-
const existing = await this.fetchWebhookEvents(webhookTag);
|
|
1373
|
-
existing === null || existing === void 0 ? void 0 : existing.map((existingEvent) => {
|
|
1374
|
-
if (selectors.length === 1) {
|
|
1375
|
-
// Single selector comparison (backward compatible)
|
|
1376
|
-
if (existingEvent.selector === data.selector && existingEvent.selectorValue === combinedSelectorValue && existingEvent.tag !== tag) {
|
|
1377
|
-
throw new Error(`Selector ${data.selector} with value ${combinedSelectorValue} already exists on event ${existingEvent.tag}`);
|
|
1378
|
-
}
|
|
1379
|
-
}
|
|
1380
|
-
else {
|
|
1381
|
-
// Multiple selectors - compare the full selector string and combined values
|
|
1382
|
-
if (existingEvent.selector === data.selector && JSON.stringify(existingEvent.selectorValue) === JSON.stringify(combinedSelectorValue) && existingEvent.tag !== tag) {
|
|
1383
|
-
throw new Error(`Selectors ${data.selector} with values ${JSON.stringify(combinedSelectorValue)} already exists on event ${existingEvent.tag}`);
|
|
1384
|
-
}
|
|
1385
|
-
}
|
|
1386
|
-
});
|
|
1387
|
-
data.sample_data = await this.inputsService.parseJson({
|
|
1388
|
-
data: data.sample,
|
|
1389
|
-
expected: types_1.ExpectedValues.PARSESAMPLE
|
|
1390
|
-
});
|
|
1391
|
-
data.selectorValue = combinedSelectorValue;
|
|
1392
|
-
}
|
|
1393
|
-
// Construct payload
|
|
1394
|
-
delete data.tag;
|
|
1395
|
-
const payload = Object.assign(Object.assign(Object.assign({}, event), data), { tag,
|
|
1396
|
-
webhookTag, component: types_1.AppComponents.WEBHOOK_EVENT, action: types_1.RequestAction.UPDATE });
|
|
1397
|
-
// Update product and reinitialize
|
|
1398
|
-
await this.appApi.updateApp(this.app_id, payload, this.getUserAccess());
|
|
1399
|
-
//await this.initializeApp(this.app_id);
|
|
1400
|
-
}
|
|
1401
|
-
catch (error) {
|
|
1402
|
-
throw error;
|
|
1403
|
-
}
|
|
1404
|
-
}
|
|
1405
|
-
async fetchWebhookEvent(tag) {
|
|
1406
|
-
const [webhookTag, eventTag] = tag.split(':');
|
|
1407
|
-
;
|
|
1408
|
-
if (!webhookTag || !eventTag) {
|
|
1409
|
-
throw new Error(`webhook events should be in the format webhook_tag:event_tag`);
|
|
1410
|
-
}
|
|
1411
|
-
const events = await this.fetchWebhookEvents(webhookTag);
|
|
1412
|
-
const event = events.find((event) => {
|
|
1413
|
-
return event.tag === eventTag;
|
|
1414
|
-
});
|
|
1415
|
-
return event;
|
|
1416
|
-
}
|
|
1417
|
-
async fetchWebhookEvents(tag) {
|
|
1418
|
-
const webhook = await this.fetchWebhook(tag);
|
|
1419
|
-
if (!webhook) {
|
|
1420
|
-
throw new Error(`Webhook ${tag} does not exist`);
|
|
1421
|
-
}
|
|
1422
|
-
return webhook.events;
|
|
1423
|
-
}
|
|
1424
|
-
getUserAccess() {
|
|
1425
|
-
var _a;
|
|
1426
|
-
return {
|
|
1427
|
-
user_id: this.user_id,
|
|
1428
|
-
workspace_id: this.workspace_id,
|
|
1429
|
-
token: this.token,
|
|
1430
|
-
public_key: this.public_key,
|
|
1431
|
-
access_key: (_a = this.access_key) !== null && _a !== void 0 ? _a : undefined,
|
|
1432
|
-
};
|
|
1433
|
-
}
|
|
1434
|
-
}
|
|
1435
|
-
exports.default = AppBuilderService;
|
|
1436
|
-
//# sourceMappingURL=app.service.js.map
|