@rocketmakers/orbit-capsule-utils 0.18.0 → 2.0.0-beta.10
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/README.md +3 -49
- package/lib/bootstrap/boot.d.ts +7 -10
- package/lib/bootstrap/boot.d.ts.map +1 -0
- package/lib/bootstrap/boot.js +26 -24
- package/lib/bootstrap/boot.js.map +1 -1
- package/lib/bootstrap/common.d.ts +2 -13
- package/lib/bootstrap/common.d.ts.map +1 -0
- package/lib/bootstrap/common.js +2 -48
- package/lib/bootstrap/common.js.map +1 -1
- package/lib/bootstrap/createExpressApp.d.ts +9 -3
- package/lib/bootstrap/createExpressApp.d.ts.map +1 -0
- package/lib/bootstrap/createExpressApp.js +18 -42
- package/lib/bootstrap/createExpressApp.js.map +1 -1
- package/lib/bootstrap/index.d.ts +2 -2
- package/lib/bootstrap/index.d.ts.map +1 -0
- package/lib/bootstrap/index.js +1 -2
- package/lib/bootstrap/index.js.map +1 -1
- package/lib/bootstrap/ioc/index.d.ts +3 -0
- package/lib/bootstrap/ioc/index.d.ts.map +1 -0
- package/lib/bootstrap/ioc/index.js +6 -0
- package/lib/bootstrap/ioc/index.js.map +1 -0
- package/lib/bootstrap/ioc/register.d.ts +5 -0
- package/lib/bootstrap/ioc/register.d.ts.map +1 -0
- package/lib/bootstrap/ioc/register.js +16 -0
- package/lib/bootstrap/ioc/register.js.map +1 -0
- package/lib/bootstrap/ioc/tsoaIoc.d.ts +9 -0
- package/lib/bootstrap/ioc/tsoaIoc.d.ts.map +1 -0
- package/lib/bootstrap/ioc/tsoaIoc.helper.d.ts +4 -0
- package/lib/bootstrap/ioc/tsoaIoc.helper.d.ts.map +1 -0
- package/lib/bootstrap/ioc/tsoaIoc.helper.js +15 -0
- package/lib/bootstrap/ioc/tsoaIoc.helper.js.map +1 -0
- package/lib/bootstrap/ioc/tsoaIoc.js +12 -0
- package/lib/bootstrap/ioc/tsoaIoc.js.map +1 -0
- package/lib/bootstrap/ioc/types.d.ts +10 -0
- package/lib/bootstrap/ioc/types.d.ts.map +1 -0
- package/lib/{core/dto.js → bootstrap/ioc/types.js} +1 -1
- package/lib/bootstrap/ioc/types.js.map +1 -0
- package/lib/config/app.d.ts +9 -58
- package/lib/config/app.d.ts.map +1 -0
- package/lib/config/app.js +9 -133
- package/lib/config/app.js.map +1 -1
- package/lib/config/environment.generated.d.ts +7 -0
- package/lib/config/environment.generated.d.ts.map +1 -0
- package/lib/config/environment.generated.js +25 -0
- package/lib/config/environment.generated.js.map +1 -0
- package/lib/config/index.d.ts +2 -0
- package/lib/config/index.d.ts.map +1 -0
- package/lib/config/index.js +1 -0
- package/lib/config/index.js.map +1 -1
- package/lib/database/connectionFactory.d.ts +5 -1
- package/lib/database/connectionFactory.d.ts.map +1 -0
- package/lib/database/connectionFactory.js +6 -7
- package/lib/database/connectionFactory.js.map +1 -1
- package/lib/database/index.d.ts +1 -7
- package/lib/database/index.d.ts.map +1 -0
- package/lib/database/index.js +0 -7
- package/lib/database/index.js.map +1 -1
- package/lib/index.d.ts +2 -10
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +1 -10
- package/lib/index.js.map +1 -1
- package/lib/middleware/errors.d.ts +2 -1
- package/lib/middleware/errors.d.ts.map +1 -0
- package/lib/middleware/errors.js +16 -12
- package/lib/middleware/errors.js.map +1 -1
- package/lib/middleware/index.d.ts +1 -1
- package/lib/middleware/index.d.ts.map +1 -0
- package/lib/middleware/index.js +0 -1
- package/lib/middleware/index.js.map +1 -1
- package/lib/rest/health.d.ts +7 -0
- package/lib/rest/health.d.ts.map +1 -0
- package/lib/{controllers → rest}/health.js +16 -16
- package/lib/rest/health.js.map +1 -0
- package/lib/rest/index.d.ts +2 -0
- package/lib/rest/index.d.ts.map +1 -0
- package/lib/{controllers → rest}/index.js +0 -0
- package/lib/rest/index.js.map +1 -0
- package/lib/tsconfig.tsbuildinfo +1 -22111
- package/lib/utils/capsules.d.ts +11 -0
- package/lib/utils/capsules.d.ts.map +1 -0
- package/lib/utils/capsules.js +31 -0
- package/lib/utils/capsules.js.map +1 -0
- package/lib/utils/index.d.ts +2 -10
- package/lib/utils/index.d.ts.map +1 -0
- package/lib/utils/index.js +1 -10
- package/lib/utils/index.js.map +1 -1
- package/package.json +51 -72
- package/.npm-version +0 -1
- package/check-npm.js +0 -37
- package/lib/_tests/assertHelpers/array.d.ts +0 -1
- package/lib/_tests/assertHelpers/array.js +0 -22
- package/lib/_tests/assertHelpers/array.js.map +0 -1
- package/lib/_tests/assertHelpers/authorisation.d.ts +0 -9
- package/lib/_tests/assertHelpers/authorisation.js +0 -94
- package/lib/_tests/assertHelpers/authorisation.js.map +0 -1
- package/lib/_tests/assertHelpers/context.d.ts +0 -3
- package/lib/_tests/assertHelpers/context.js +0 -13
- package/lib/_tests/assertHelpers/context.js.map +0 -1
- package/lib/_tests/assertHelpers/core.d.ts +0 -2
- package/lib/_tests/assertHelpers/core.js +0 -39
- package/lib/_tests/assertHelpers/core.js.map +0 -1
- package/lib/_tests/assertHelpers/string.d.ts +0 -4
- package/lib/_tests/assertHelpers/string.js +0 -81
- package/lib/_tests/assertHelpers/string.js.map +0 -1
- package/lib/_tests/assertHelpers/validation.d.ts +0 -14
- package/lib/_tests/assertHelpers/validation.js +0 -60
- package/lib/_tests/assertHelpers/validation.js.map +0 -1
- package/lib/_tests/common.d.ts +0 -5
- package/lib/_tests/common.js +0 -32
- package/lib/_tests/common.js.map +0 -1
- package/lib/_tests/factories/context.d.ts +0 -43
- package/lib/_tests/factories/context.js +0 -142
- package/lib/_tests/factories/context.js.map +0 -1
- package/lib/_tests/factories/transaction.d.ts +0 -2
- package/lib/_tests/factories/transaction.js +0 -8
- package/lib/_tests/factories/transaction.js.map +0 -1
- package/lib/_tests/services/claims/claims.test.d.ts +0 -1
- package/lib/_tests/services/claims/claims.test.js +0 -51
- package/lib/_tests/services/claims/claims.test.js.map +0 -1
- package/lib/_tests/services/encryption/encryptDecrypt.test.d.ts +0 -1
- package/lib/_tests/services/encryption/encryptDecrypt.test.js +0 -104
- package/lib/_tests/services/encryption/encryptDecrypt.test.js.map +0 -1
- package/lib/_tests/services/encryption/mockedService.d.ts +0 -6
- package/lib/_tests/services/encryption/mockedService.js +0 -12
- package/lib/_tests/services/encryption/mockedService.js.map +0 -1
- package/lib/_tests/tasks/factories/scheduledTask.d.ts +0 -2
- package/lib/_tests/tasks/factories/scheduledTask.js +0 -23
- package/lib/_tests/tasks/factories/scheduledTask.js.map +0 -1
- package/lib/_tests/tasks/factories/task.d.ts +0 -3
- package/lib/_tests/tasks/factories/task.js +0 -23
- package/lib/_tests/tasks/factories/task.js.map +0 -1
- package/lib/_tests/tasks/services/taskService/index.test.d.ts +0 -1
- package/lib/_tests/tasks/services/taskService/index.test.js +0 -9
- package/lib/_tests/tasks/services/taskService/index.test.js.map +0 -1
- package/lib/_tests/tasks/services/taskService/mockedService.d.ts +0 -25
- package/lib/_tests/tasks/services/taskService/mockedService.js +0 -60
- package/lib/_tests/tasks/services/taskService/mockedService.js.map +0 -1
- package/lib/_tests/tasks/services/taskService/process.d.ts +0 -1
- package/lib/_tests/tasks/services/taskService/process.js +0 -127
- package/lib/_tests/tasks/services/taskService/process.js.map +0 -1
- package/lib/_tests/tasks/services/taskService/schedule.d.ts +0 -1
- package/lib/_tests/tasks/services/taskService/schedule.js +0 -100
- package/lib/_tests/tasks/services/taskService/schedule.js.map +0 -1
- package/lib/_tests/tracing/decorators/tracing.test.d.ts +0 -1
- package/lib/_tests/tracing/decorators/tracing.test.js +0 -44
- package/lib/_tests/tracing/decorators/tracing.test.js.map +0 -1
- package/lib/_tests/utils/array.test.d.ts +0 -1
- package/lib/_tests/utils/array.test.js +0 -105
- package/lib/_tests/utils/array.test.js.map +0 -1
- package/lib/_tests/utils/dates.test.d.ts +0 -1
- package/lib/_tests/utils/dates.test.js +0 -63
- package/lib/_tests/utils/dates.test.js.map +0 -1
- package/lib/_tests/utils/errors.d.ts +0 -6
- package/lib/_tests/utils/errors.js +0 -30
- package/lib/_tests/utils/errors.js.map +0 -1
- package/lib/auth/authorisation.d.ts +0 -22
- package/lib/auth/authorisation.js +0 -198
- package/lib/auth/authorisation.js.map +0 -1
- package/lib/auth/claims.d.ts +0 -4
- package/lib/auth/claims.js +0 -11
- package/lib/auth/claims.js.map +0 -1
- package/lib/auth/context.d.ts +0 -23
- package/lib/auth/context.js +0 -58
- package/lib/auth/context.js.map +0 -1
- package/lib/auth/index.d.ts +0 -7
- package/lib/auth/index.js +0 -11
- package/lib/auth/index.js.map +0 -1
- package/lib/auth/interfaces.d.ts +0 -5
- package/lib/auth/interfaces.js +0 -3
- package/lib/auth/interfaces.js.map +0 -1
- package/lib/auth/session.d.ts +0 -15
- package/lib/auth/session.js +0 -3
- package/lib/auth/session.js.map +0 -1
- package/lib/auth/tokenParser.d.ts +0 -21
- package/lib/auth/tokenParser.js +0 -120
- package/lib/auth/tokenParser.js.map +0 -1
- package/lib/auth/user.d.ts +0 -63
- package/lib/auth/user.js +0 -27
- package/lib/auth/user.js.map +0 -1
- package/lib/bootstrap/kernel.d.ts +0 -24
- package/lib/bootstrap/kernel.js +0 -76
- package/lib/bootstrap/kernel.js.map +0 -1
- package/lib/bootstrap/request.d.ts +0 -41
- package/lib/bootstrap/request.js +0 -50
- package/lib/bootstrap/request.js.map +0 -1
- package/lib/build/config.d.ts +0 -20
- package/lib/build/config.js +0 -3
- package/lib/build/config.js.map +0 -1
- package/lib/build/index.d.ts +0 -1
- package/lib/build/index.js +0 -5
- package/lib/build/index.js.map +0 -1
- package/lib/controllers/health.d.ts +0 -7
- package/lib/controllers/health.js.map +0 -1
- package/lib/controllers/index.d.ts +0 -1
- package/lib/controllers/index.js.map +0 -1
- package/lib/core/arrays.d.ts +0 -1
- package/lib/core/arrays.js +0 -3
- package/lib/core/arrays.js.map +0 -1
- package/lib/core/dto.d.ts +0 -26
- package/lib/core/dto.js.map +0 -1
- package/lib/core/errors.d.ts +0 -51
- package/lib/core/errors.js +0 -155
- package/lib/core/errors.js.map +0 -1
- package/lib/core/index.d.ts +0 -7
- package/lib/core/index.js +0 -11
- package/lib/core/index.js.map +0 -1
- package/lib/core/opaqueTypes.d.ts +0 -12
- package/lib/core/opaqueTypes.js +0 -8
- package/lib/core/opaqueTypes.js.map +0 -1
- package/lib/core/pagination.d.ts +0 -32
- package/lib/core/pagination.js +0 -66
- package/lib/core/pagination.js.map +0 -1
- package/lib/core/query.d.ts +0 -21
- package/lib/core/query.js +0 -17
- package/lib/core/query.js.map +0 -1
- package/lib/core/serverError.d.ts +0 -42
- package/lib/core/serverError.js +0 -86
- package/lib/core/serverError.js.map +0 -1
- package/lib/core/types.d.ts +0 -37
- package/lib/core/types.js +0 -46
- package/lib/core/types.js.map +0 -1
- package/lib/database/columns.d.ts +0 -5
- package/lib/database/columns.js +0 -14
- package/lib/database/columns.js.map +0 -1
- package/lib/database/dataContext.d.ts +0 -14
- package/lib/database/dataContext.js +0 -26
- package/lib/database/dataContext.js.map +0 -1
- package/lib/database/entities.d.ts +0 -10
- package/lib/database/entities.js +0 -29
- package/lib/database/entities.js.map +0 -1
- package/lib/database/query.d.ts +0 -3
- package/lib/database/query.js +0 -51
- package/lib/database/query.js.map +0 -1
- package/lib/database/relationsBuilder.d.ts +0 -6
- package/lib/database/relationsBuilder.js +0 -33
- package/lib/database/relationsBuilder.js.map +0 -1
- package/lib/database/repository.d.ts +0 -32
- package/lib/database/repository.js +0 -157
- package/lib/database/repository.js.map +0 -1
- package/lib/database/select.d.ts +0 -4
- package/lib/database/select.js +0 -27
- package/lib/database/select.js.map +0 -1
- package/lib/database/transformers.d.ts +0 -12
- package/lib/database/transformers.js +0 -38
- package/lib/database/transformers.js.map +0 -1
- package/lib/graphql/GraphqlController.d.ts +0 -12
- package/lib/graphql/GraphqlController.js +0 -81
- package/lib/graphql/GraphqlController.js.map +0 -1
- package/lib/graphql/index.d.ts +0 -4
- package/lib/graphql/index.js +0 -8
- package/lib/graphql/index.js.map +0 -1
- package/lib/graphql/init.d.ts +0 -9
- package/lib/graphql/init.js +0 -51
- package/lib/graphql/init.js.map +0 -1
- package/lib/graphql/registrations.d.ts +0 -7
- package/lib/graphql/registrations.js +0 -16
- package/lib/graphql/registrations.js.map +0 -1
- package/lib/graphql/types/InputTypes/index.d.ts +0 -2
- package/lib/graphql/types/InputTypes/index.js +0 -6
- package/lib/graphql/types/InputTypes/index.js.map +0 -1
- package/lib/graphql/types/InputTypes/paging.d.ts +0 -5
- package/lib/graphql/types/InputTypes/paging.js +0 -20
- package/lib/graphql/types/InputTypes/paging.js.map +0 -1
- package/lib/graphql/types/InputTypes/query.d.ts +0 -7
- package/lib/graphql/types/InputTypes/query.js +0 -36
- package/lib/graphql/types/InputTypes/query.js.map +0 -1
- package/lib/graphql/types/ObjectTypes/index.d.ts +0 -2
- package/lib/graphql/types/ObjectTypes/index.js +0 -6
- package/lib/graphql/types/ObjectTypes/index.js.map +0 -1
- package/lib/graphql/types/ObjectTypes/paging.d.ts +0 -6
- package/lib/graphql/types/ObjectTypes/paging.js +0 -24
- package/lib/graphql/types/ObjectTypes/paging.js.map +0 -1
- package/lib/graphql/types/ObjectTypes/user.d.ts +0 -26
- package/lib/graphql/types/ObjectTypes/user.js +0 -114
- package/lib/graphql/types/ObjectTypes/user.js.map +0 -1
- package/lib/graphql/types/index.d.ts +0 -2
- package/lib/graphql/types/index.js +0 -6
- package/lib/graphql/types/index.js.map +0 -1
- package/lib/middleware/health.d.ts +0 -4
- package/lib/middleware/health.js +0 -15
- package/lib/middleware/health.js.map +0 -1
- package/lib/notify/decorator.d.ts +0 -6
- package/lib/notify/decorator.js +0 -8
- package/lib/notify/decorator.js.map +0 -1
- package/lib/notify/index.d.ts +0 -1
- package/lib/notify/index.js +0 -5
- package/lib/notify/index.js.map +0 -1
- package/lib/public/api-clients/auditClientApi.d.ts +0 -165
- package/lib/public/api-clients/auditClientApi.js +0 -255
- package/lib/public/api-clients/auditClientApi.js.map +0 -1
- package/lib/public/api-clients/authClientApi.d.ts +0 -585
- package/lib/public/api-clients/authClientApi.js +0 -555
- package/lib/public/api-clients/authClientApi.js.map +0 -1
- package/lib/public/api-clients/notifyClientApi.d.ts +0 -435
- package/lib/public/api-clients/notifyClientApi.js +0 -386
- package/lib/public/api-clients/notifyClientApi.js.map +0 -1
- package/lib/public/api-clients/storageClientApi.d.ts +0 -345
- package/lib/public/api-clients/storageClientApi.js +0 -340
- package/lib/public/api-clients/storageClientApi.js.map +0 -1
- package/lib/services/client.d.ts +0 -2
- package/lib/services/client.js +0 -38
- package/lib/services/client.js.map +0 -1
- package/lib/services/encryption.d.ts +0 -20
- package/lib/services/encryption.js +0 -74
- package/lib/services/encryption.js.map +0 -1
- package/lib/services/identity.d.ts +0 -7
- package/lib/services/identity.js +0 -41
- package/lib/services/identity.js.map +0 -1
- package/lib/services/index.d.ts +0 -8
- package/lib/services/index.js +0 -12
- package/lib/services/index.js.map +0 -1
- package/lib/services/jsonSchema.d.ts +0 -7
- package/lib/services/jsonSchema.js +0 -22
- package/lib/services/jsonSchema.js.map +0 -1
- package/lib/services/time.d.ts +0 -21
- package/lib/services/time.js +0 -20
- package/lib/services/time.js.map +0 -1
- package/lib/services/token.d.ts +0 -5
- package/lib/services/token.js +0 -17
- package/lib/services/token.js.map +0 -1
- package/lib/services/transaction.d.ts +0 -7
- package/lib/services/transaction.js +0 -11
- package/lib/services/transaction.js.map +0 -1
- package/lib/services/uuidGenerator.d.ts +0 -7
- package/lib/services/uuidGenerator.js +0 -11
- package/lib/services/uuidGenerator.js.map +0 -1
- package/lib/tasks/configTypes.d.ts +0 -3
- package/lib/tasks/configTypes.js +0 -3
- package/lib/tasks/configTypes.js.map +0 -1
- package/lib/tasks/data/ScheduledTaskRepository.d.ts +0 -14
- package/lib/tasks/data/ScheduledTaskRepository.js +0 -64
- package/lib/tasks/data/ScheduledTaskRepository.js.map +0 -1
- package/lib/tasks/data/TaskRepository.d.ts +0 -17
- package/lib/tasks/data/TaskRepository.js +0 -69
- package/lib/tasks/data/TaskRepository.js.map +0 -1
- package/lib/tasks/data/entities/ScheduledTask.d.ts +0 -10
- package/lib/tasks/data/entities/ScheduledTask.js +0 -33
- package/lib/tasks/data/entities/ScheduledTask.js.map +0 -1
- package/lib/tasks/data/entities/Task.d.ts +0 -13
- package/lib/tasks/data/entities/Task.js +0 -46
- package/lib/tasks/data/entities/Task.js.map +0 -1
- package/lib/tasks/data/repositories.d.ts +0 -18
- package/lib/tasks/data/repositories.js +0 -3
- package/lib/tasks/data/repositories.js.map +0 -1
- package/lib/tasks/data/types/opaqueTypes.d.ts +0 -3
- package/lib/tasks/data/types/opaqueTypes.js +0 -3
- package/lib/tasks/data/types/opaqueTypes.js.map +0 -1
- package/lib/tasks/data/types/scheduledTaskTypes.d.ts +0 -11
- package/lib/tasks/data/types/scheduledTaskTypes.js +0 -3
- package/lib/tasks/data/types/scheduledTaskTypes.js.map +0 -1
- package/lib/tasks/data/types/taskTypes.d.ts +0 -18
- package/lib/tasks/data/types/taskTypes.js +0 -10
- package/lib/tasks/data/types/taskTypes.js.map +0 -1
- package/lib/tasks/index.d.ts +0 -3
- package/lib/tasks/index.js +0 -7
- package/lib/tasks/index.js.map +0 -1
- package/lib/tasks/services/TaskService.d.ts +0 -19
- package/lib/tasks/services/TaskService.js +0 -107
- package/lib/tasks/services/TaskService.js.map +0 -1
- package/lib/tasks/services/index.d.ts +0 -16
- package/lib/tasks/services/index.js +0 -3
- package/lib/tasks/services/index.js.map +0 -1
- package/lib/tasks/validators/index.d.ts +0 -2
- package/lib/tasks/validators/index.js +0 -6
- package/lib/tasks/validators/index.js.map +0 -1
- package/lib/tasks/validators/scheduledTaskValidators.d.ts +0 -5
- package/lib/tasks/validators/scheduledTaskValidators.js +0 -12
- package/lib/tasks/validators/scheduledTaskValidators.js.map +0 -1
- package/lib/tasks/validators/taskValidators.d.ts +0 -5
- package/lib/tasks/validators/taskValidators.js +0 -15
- package/lib/tasks/validators/taskValidators.js.map +0 -1
- package/lib/tracing/decorator.d.ts +0 -19
- package/lib/tracing/decorator.js +0 -101
- package/lib/tracing/decorator.js.map +0 -1
- package/lib/tracing/index.d.ts +0 -3
- package/lib/tracing/index.js +0 -7
- package/lib/tracing/index.js.map +0 -1
- package/lib/tracing/init.d.ts +0 -4
- package/lib/tracing/init.js +0 -24
- package/lib/tracing/init.js.map +0 -1
- package/lib/tracing/middleware.d.ts +0 -3
- package/lib/tracing/middleware.js +0 -15
- package/lib/tracing/middleware.js.map +0 -1
- package/lib/utils/array.d.ts +0 -1
- package/lib/utils/array.js +0 -19
- package/lib/utils/array.js.map +0 -1
- package/lib/utils/base64.d.ts +0 -1
- package/lib/utils/base64.js +0 -12
- package/lib/utils/base64.js.map +0 -1
- package/lib/utils/context.d.ts +0 -16
- package/lib/utils/context.js +0 -21
- package/lib/utils/context.js.map +0 -1
- package/lib/utils/dates.d.ts +0 -12
- package/lib/utils/dates.js +0 -46
- package/lib/utils/dates.js.map +0 -1
- package/lib/utils/errors.d.ts +0 -4
- package/lib/utils/errors.js +0 -24
- package/lib/utils/errors.js.map +0 -1
- package/lib/utils/httpErrors.d.ts +0 -7
- package/lib/utils/httpErrors.js +0 -9
- package/lib/utils/httpErrors.js.map +0 -1
- package/lib/utils/number.d.ts +0 -4
- package/lib/utils/number.js +0 -21
- package/lib/utils/number.js.map +0 -1
- package/lib/utils/object.d.ts +0 -6
- package/lib/utils/object.js +0 -40
- package/lib/utils/object.js.map +0 -1
- package/lib/utils/random.d.ts +0 -13
- package/lib/utils/random.js +0 -41
- package/lib/utils/random.js.map +0 -1
- package/lib/utils/string.d.ts +0 -3
- package/lib/utils/string.js +0 -32
- package/lib/utils/string.js.map +0 -1
- package/lib/validation/index.d.ts +0 -1
- package/lib/validation/index.js +0 -5
- package/lib/validation/index.js.map +0 -1
- package/lib/validation/validators.d.ts +0 -32
- package/lib/validation/validators.js +0 -158
- package/lib/validation/validators.js.map +0 -1
- package/tsconfig.json +0 -35
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../capsules/shared/graphql/types/ObjectTypes/index.ts"],"names":[],"mappings":";;;AAAA,mDAAyB;AACzB,iDAAuB"}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.Paging = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const type_graphql_1 = require("type-graphql");
|
|
6
|
-
let Paging = class Paging {
|
|
7
|
-
};
|
|
8
|
-
tslib_1.__decorate([
|
|
9
|
-
type_graphql_1.Field({ description: 'Current page' }),
|
|
10
|
-
tslib_1.__metadata("design:type", String)
|
|
11
|
-
], Paging.prototype, "current", void 0);
|
|
12
|
-
tslib_1.__decorate([
|
|
13
|
-
type_graphql_1.Field({ description: 'Next page if present', nullable: true }),
|
|
14
|
-
tslib_1.__metadata("design:type", String)
|
|
15
|
-
], Paging.prototype, "next", void 0);
|
|
16
|
-
tslib_1.__decorate([
|
|
17
|
-
type_graphql_1.Field({ description: 'Previous page if not first page', nullable: true }),
|
|
18
|
-
tslib_1.__metadata("design:type", String)
|
|
19
|
-
], Paging.prototype, "previous", void 0);
|
|
20
|
-
Paging = tslib_1.__decorate([
|
|
21
|
-
type_graphql_1.ObjectType()
|
|
22
|
-
], Paging);
|
|
23
|
-
exports.Paging = Paging;
|
|
24
|
-
//# sourceMappingURL=paging.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"paging.js","sourceRoot":"","sources":["../../../../../../capsules/shared/graphql/types/ObjectTypes/paging.ts"],"names":[],"mappings":";;;;AAAA,+CAAiD;AAIjD,IAAa,MAAM,GAAnB,MAAa,MAAM;CASlB,CAAA;AAPC;IADC,oBAAK,CAAC,EAAE,WAAW,EAAE,cAAc,EAAE,CAAC;;uCACtB;AAGjB;IADC,oBAAK,CAAC,EAAE,WAAW,EAAE,sBAAsB,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;oCACjD;AAGd;IADC,oBAAK,CAAC,EAAE,WAAW,EAAE,iCAAiC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;wCACxD;AARP,MAAM;IADlB,yBAAU,EAAE;GACA,MAAM,CASlB;AATY,wBAAM"}
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { IByUnknown, IByAnon, UserType, IByUser, UserId, IBySystem } from '../../../auth';
|
|
2
|
-
import { ICreatable, DateTimeString, IUpdatable } from '../../../core';
|
|
3
|
-
export declare class ByUnknown implements IByUnknown {
|
|
4
|
-
type: 'unknown';
|
|
5
|
-
}
|
|
6
|
-
export declare class ByAnon implements IByAnon {
|
|
7
|
-
type: UserType.anonymous;
|
|
8
|
-
}
|
|
9
|
-
export declare class ByUser implements IByUser {
|
|
10
|
-
type: UserType.user;
|
|
11
|
-
userId: UserId;
|
|
12
|
-
impersonator?: UserId;
|
|
13
|
-
}
|
|
14
|
-
export declare class BySystem implements IBySystem {
|
|
15
|
-
type: UserType.system;
|
|
16
|
-
userId?: UserId;
|
|
17
|
-
}
|
|
18
|
-
export declare const ByWho: ByUnknown | ByAnon | ByUser | BySystem;
|
|
19
|
-
export declare abstract class Creatable implements ICreatable {
|
|
20
|
-
createdOn: DateTimeString;
|
|
21
|
-
createdBy: typeof ByWho;
|
|
22
|
-
}
|
|
23
|
-
export declare abstract class UpdatableCreatable extends Creatable implements IUpdatable {
|
|
24
|
-
updatedOn: DateTimeString;
|
|
25
|
-
updatedBy: typeof ByWho;
|
|
26
|
-
}
|
|
@@ -1,114 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.UpdatableCreatable = exports.Creatable = exports.ByWho = exports.BySystem = exports.ByUser = exports.ByAnon = exports.ByUnknown = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const type_graphql_1 = require("type-graphql");
|
|
6
|
-
const auth_1 = require("../../../auth");
|
|
7
|
-
const utils_1 = require("../../../utils");
|
|
8
|
-
let ByUnknown = class ByUnknown {
|
|
9
|
-
};
|
|
10
|
-
tslib_1.__decorate([
|
|
11
|
-
type_graphql_1.Field({ description: 'Unknown user-type [SHOULD NEVER SEE THIS TYPE]' }),
|
|
12
|
-
tslib_1.__metadata("design:type", String)
|
|
13
|
-
], ByUnknown.prototype, "type", void 0);
|
|
14
|
-
ByUnknown = tslib_1.__decorate([
|
|
15
|
-
type_graphql_1.ObjectType()
|
|
16
|
-
], ByUnknown);
|
|
17
|
-
exports.ByUnknown = ByUnknown;
|
|
18
|
-
let ByAnon = class ByAnon {
|
|
19
|
-
};
|
|
20
|
-
tslib_1.__decorate([
|
|
21
|
-
type_graphql_1.Field(() => auth_1.UserType, { description: 'Anonymous user-type' }),
|
|
22
|
-
tslib_1.__metadata("design:type", String)
|
|
23
|
-
], ByAnon.prototype, "type", void 0);
|
|
24
|
-
ByAnon = tslib_1.__decorate([
|
|
25
|
-
type_graphql_1.ObjectType()
|
|
26
|
-
], ByAnon);
|
|
27
|
-
exports.ByAnon = ByAnon;
|
|
28
|
-
let ByUser = class ByUser {
|
|
29
|
-
};
|
|
30
|
-
tslib_1.__decorate([
|
|
31
|
-
type_graphql_1.Field(() => auth_1.UserType, { description: 'User user-type' }),
|
|
32
|
-
tslib_1.__metadata("design:type", String)
|
|
33
|
-
], ByUser.prototype, "type", void 0);
|
|
34
|
-
tslib_1.__decorate([
|
|
35
|
-
type_graphql_1.Field(() => type_graphql_1.ID, { description: 'User ID', nullable: true }),
|
|
36
|
-
tslib_1.__metadata("design:type", String)
|
|
37
|
-
], ByUser.prototype, "userId", void 0);
|
|
38
|
-
tslib_1.__decorate([
|
|
39
|
-
type_graphql_1.Field(() => type_graphql_1.ID, { description: 'Impersonator User ID', nullable: true }),
|
|
40
|
-
tslib_1.__metadata("design:type", String)
|
|
41
|
-
], ByUser.prototype, "impersonator", void 0);
|
|
42
|
-
ByUser = tslib_1.__decorate([
|
|
43
|
-
type_graphql_1.ObjectType()
|
|
44
|
-
], ByUser);
|
|
45
|
-
exports.ByUser = ByUser;
|
|
46
|
-
let BySystem = class BySystem {
|
|
47
|
-
};
|
|
48
|
-
tslib_1.__decorate([
|
|
49
|
-
type_graphql_1.Field(() => auth_1.UserType, { description: 'System user-type' }),
|
|
50
|
-
tslib_1.__metadata("design:type", String)
|
|
51
|
-
], BySystem.prototype, "type", void 0);
|
|
52
|
-
tslib_1.__decorate([
|
|
53
|
-
type_graphql_1.Field(() => type_graphql_1.ID, { description: 'Impersonated User ID', defaultValue: '[NOT_SPECIFIED]' }),
|
|
54
|
-
tslib_1.__metadata("design:type", String)
|
|
55
|
-
], BySystem.prototype, "userId", void 0);
|
|
56
|
-
BySystem = tslib_1.__decorate([
|
|
57
|
-
type_graphql_1.ObjectType()
|
|
58
|
-
], BySystem);
|
|
59
|
-
exports.BySystem = BySystem;
|
|
60
|
-
exports.ByWho = type_graphql_1.createUnionType({
|
|
61
|
-
name: 'ByWho',
|
|
62
|
-
description: 'Object indicated with user type created the entity',
|
|
63
|
-
types: [ByUnknown, ByAnon, ByUser, BySystem],
|
|
64
|
-
resolveType: (value) => {
|
|
65
|
-
const { type } = value;
|
|
66
|
-
switch (type) {
|
|
67
|
-
case auth_1.UserType.anonymous: {
|
|
68
|
-
return ByAnon;
|
|
69
|
-
}
|
|
70
|
-
case auth_1.UserType.user: {
|
|
71
|
-
return ByUser;
|
|
72
|
-
}
|
|
73
|
-
case auth_1.UserType.system: {
|
|
74
|
-
return BySystem;
|
|
75
|
-
}
|
|
76
|
-
case 'unknown':
|
|
77
|
-
return ByUnknown;
|
|
78
|
-
default: {
|
|
79
|
-
utils_1.assertNever(type, `Unsupported user type: ${type}`);
|
|
80
|
-
break;
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
|
-
return undefined;
|
|
84
|
-
},
|
|
85
|
-
});
|
|
86
|
-
let Creatable = class Creatable {
|
|
87
|
-
};
|
|
88
|
-
tslib_1.__decorate([
|
|
89
|
-
type_graphql_1.Field({ description: 'Date time string representing creation time' }),
|
|
90
|
-
tslib_1.__metadata("design:type", String)
|
|
91
|
-
], Creatable.prototype, "createdOn", void 0);
|
|
92
|
-
tslib_1.__decorate([
|
|
93
|
-
type_graphql_1.Field(() => exports.ByWho, { description: 'Description of identity that created this entity' }),
|
|
94
|
-
tslib_1.__metadata("design:type", Object)
|
|
95
|
-
], Creatable.prototype, "createdBy", void 0);
|
|
96
|
-
Creatable = tslib_1.__decorate([
|
|
97
|
-
type_graphql_1.ObjectType()
|
|
98
|
-
], Creatable);
|
|
99
|
-
exports.Creatable = Creatable;
|
|
100
|
-
let UpdatableCreatable = class UpdatableCreatable extends Creatable {
|
|
101
|
-
};
|
|
102
|
-
tslib_1.__decorate([
|
|
103
|
-
type_graphql_1.Field({ description: 'Date time string representing last updated time' }),
|
|
104
|
-
tslib_1.__metadata("design:type", String)
|
|
105
|
-
], UpdatableCreatable.prototype, "updatedOn", void 0);
|
|
106
|
-
tslib_1.__decorate([
|
|
107
|
-
type_graphql_1.Field(() => exports.ByWho, { description: 'Description of identity that last updated this entity' }),
|
|
108
|
-
tslib_1.__metadata("design:type", Object)
|
|
109
|
-
], UpdatableCreatable.prototype, "updatedBy", void 0);
|
|
110
|
-
UpdatableCreatable = tslib_1.__decorate([
|
|
111
|
-
type_graphql_1.ObjectType()
|
|
112
|
-
], UpdatableCreatable);
|
|
113
|
-
exports.UpdatableCreatable = UpdatableCreatable;
|
|
114
|
-
//# sourceMappingURL=user.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"user.js","sourceRoot":"","sources":["../../../../../../capsules/shared/graphql/types/ObjectTypes/user.ts"],"names":[],"mappings":";;;;AAAA,+CAAsE;AACtE,wCAA0F;AAE1F,0CAA6C;AAG7C,IAAa,SAAS,GAAtB,MAAa,SAAS;CAGrB,CAAA;AADC;IADC,oBAAK,CAAC,EAAE,WAAW,EAAE,gDAAgD,EAAE,CAAC;;uCACxD;AAFN,SAAS;IADrB,yBAAU,EAAE;GACA,SAAS,CAGrB;AAHY,8BAAS;AAMtB,IAAa,MAAM,GAAnB,MAAa,MAAM;CAGlB,CAAA;AADC;IADC,oBAAK,CAAC,GAAG,EAAE,CAAC,eAAQ,EAAE,EAAE,WAAW,EAAE,qBAAqB,EAAE,CAAC;;oCACpC;AAFf,MAAM;IADlB,yBAAU,EAAE;GACA,MAAM,CAGlB;AAHY,wBAAM;AAMnB,IAAa,MAAM,GAAnB,MAAa,MAAM;CASlB,CAAA;AAPC;IADC,oBAAK,CAAC,GAAG,EAAE,CAAC,eAAQ,EAAE,EAAE,WAAW,EAAE,gBAAgB,EAAE,CAAC;;oCACpC;AAGrB;IADC,oBAAK,CAAC,GAAG,EAAE,CAAC,iBAAE,EAAE,EAAE,WAAW,EAAE,SAAS,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;sCAC5C;AAGhB;IADC,oBAAK,CAAC,GAAG,EAAE,CAAC,iBAAE,EAAE,EAAE,WAAW,EAAE,sBAAsB,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;4CACnD;AARX,MAAM;IADlB,yBAAU,EAAE;GACA,MAAM,CASlB;AATY,wBAAM;AAYnB,IAAa,QAAQ,GAArB,MAAa,QAAQ;CAMpB,CAAA;AAJC;IADC,oBAAK,CAAC,GAAG,EAAE,CAAC,eAAQ,EAAE,EAAE,WAAW,EAAE,kBAAkB,EAAE,CAAC;;sCACpC;AAGvB;IADC,oBAAK,CAAC,GAAG,EAAE,CAAC,iBAAE,EAAE,EAAE,WAAW,EAAE,sBAAsB,EAAE,YAAY,EAAE,iBAAiB,EAAE,CAAC;;wCAC1E;AALL,QAAQ;IADpB,yBAAU,EAAE;GACA,QAAQ,CAMpB;AANY,4BAAQ;AAQR,QAAA,KAAK,GAAG,8BAAe,CAAC;IACnC,IAAI,EAAE,OAAO;IACb,WAAW,EAAE,oDAAoD;IACjE,KAAK,EAAE,CAAC,SAAS,EAAE,MAAM,EAAE,MAAM,EAAE,QAAQ,CAAC;IAC5C,WAAW,EAAE,CAAC,KAAK,EAAE,EAAE;QACrB,MAAM,EAAE,IAAI,EAAE,GAAG,KAAK,CAAC;QACvB,QAAQ,IAAI,EAAE;YACZ,KAAK,eAAQ,CAAC,SAAS,CAAC,CAAC;gBACvB,OAAO,MAAM,CAAC;aACf;YACD,KAAK,eAAQ,CAAC,IAAI,CAAC,CAAC;gBAClB,OAAO,MAAM,CAAC;aACf;YACD,KAAK,eAAQ,CAAC,MAAM,CAAC,CAAC;gBACpB,OAAO,QAAQ,CAAC;aACjB;YACD,KAAK,SAAS;gBACZ,OAAO,SAAS,CAAC;YACnB,OAAO,CAAC,CAAC;gBACP,mBAAW,CAAC,IAAI,EAAE,0BAA0B,IAAI,EAAE,CAAC,CAAC;gBACpD,MAAM;aACP;SACF;QACD,OAAO,SAAS,CAAC;IACnB,CAAC;CACF,CAAC,CAAC;AAGH,IAAsB,SAAS,GAA/B,MAAsB,SAAS;CAM9B,CAAA;AAJC;IADC,oBAAK,CAAC,EAAE,WAAW,EAAE,6CAA6C,EAAE,CAAC;;4CAC3C;AAG3B;IADC,oBAAK,CAAC,GAAG,EAAE,CAAC,aAAK,EAAE,EAAE,WAAW,EAAE,kDAAkD,EAAE,CAAC;;4CAC/D;AALL,SAAS;IAD9B,yBAAU,EAAE;GACS,SAAS,CAM9B;AANqB,8BAAS;AAS/B,IAAsB,kBAAkB,GAAxC,MAAsB,kBAAmB,SAAQ,SAAS;CAMzD,CAAA;AAJC;IADC,oBAAK,CAAC,EAAE,WAAW,EAAE,iDAAiD,EAAE,CAAC;;qDAC/C;AAG3B;IADC,oBAAK,CAAC,GAAG,EAAE,CAAC,aAAK,EAAE,EAAE,WAAW,EAAE,uDAAuD,EAAE,CAAC;;qDACpE;AALL,kBAAkB;IADvC,yBAAU,EAAE;GACS,kBAAkB,CAMvC;AANqB,gDAAkB"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../capsules/shared/graphql/types/index.ts"],"names":[],"mappings":";;;AAAA,uDAA6B;AAC7B,wDAA8B"}
|
package/lib/middleware/health.js
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.healthCheck = void 0;
|
|
4
|
-
function healthCheck(logger, path) {
|
|
5
|
-
logger.trace(`Adding health check at ${path}`);
|
|
6
|
-
return (req, res, next) => {
|
|
7
|
-
if (req.path === path) {
|
|
8
|
-
res.status(204).send();
|
|
9
|
-
return;
|
|
10
|
-
}
|
|
11
|
-
next();
|
|
12
|
-
};
|
|
13
|
-
}
|
|
14
|
-
exports.healthCheck = healthCheck;
|
|
15
|
-
//# sourceMappingURL=health.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"health.js","sourceRoot":"","sources":["../../../../capsules/shared/middleware/health.ts"],"names":[],"mappings":";;;AAGA,SAAgB,WAAW,CAAC,MAAc,EAAE,IAAY;IACtD,MAAM,CAAC,KAAK,CAAC,0BAA0B,IAAI,EAAE,CAAC,CAAC;IAC/C,OAAO,CAAC,GAAY,EAAE,GAAa,EAAE,IAAkB,EAAE,EAAE;QACzD,IAAI,GAAG,CAAC,IAAI,KAAK,IAAI,EAAE;YACrB,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,CAAC;YACvB,OAAO;SACR;QACD,IAAI,EAAE,CAAC;IACT,CAAC,CAAC;AACJ,CAAC;AATD,kCASC"}
|
package/lib/notify/decorator.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"decorator.js","sourceRoot":"","sources":["../../../../capsules/shared/notify/decorator.ts"],"names":[],"mappings":";;;AAaA,SAAgB,cAAc,CAAC,KAAa,EAAE,OAAwC;IACpF,OAAO,GAAG,EAAE,GAAE,CAAC,CAAC;AAClB,CAAC;AAFD,wCAEC"}
|
package/lib/notify/index.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './decorator';
|
package/lib/notify/index.js
DELETED
package/lib/notify/index.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../capsules/shared/notify/index.ts"],"names":[],"mappings":";;;AAAA,sDAA4B"}
|
|
@@ -1,165 +0,0 @@
|
|
|
1
|
-
export declare const UnknownServerErrorAppCode = "UnknownServerError";
|
|
2
|
-
export declare abstract class ApiErrorBase<TAppCode extends string = string> extends Error {
|
|
3
|
-
appCode: TAppCode;
|
|
4
|
-
developerMessage?: string | undefined;
|
|
5
|
-
constructor(appCode: TAppCode, message: string, developerMessage?: string | undefined);
|
|
6
|
-
}
|
|
7
|
-
export interface IErrorRegistration<TError extends {
|
|
8
|
-
appCode: string;
|
|
9
|
-
}, TData> {
|
|
10
|
-
appCode: string;
|
|
11
|
-
status: number;
|
|
12
|
-
toJson: (e: TError) => TData;
|
|
13
|
-
fromJson: (d: TData) => TError;
|
|
14
|
-
}
|
|
15
|
-
export declare class ApiError {
|
|
16
|
-
static errors: IErrorRegistration<any, any>[];
|
|
17
|
-
static registerCore(): void;
|
|
18
|
-
static isApiError(testError: any): testError is ApiErrorBase<any>;
|
|
19
|
-
static register<TErrorConstructor extends new (...args: any[]) => {
|
|
20
|
-
appCode: string;
|
|
21
|
-
developerMessage?: string;
|
|
22
|
-
}>(_error: TErrorConstructor, status: number): {
|
|
23
|
-
transit<TKeys extends Exclude<keyof InstanceType<TErrorConstructor>, "developerMessage" | "appCode">>(...keys: TKeys[]): {
|
|
24
|
-
recreate(fromJson: (d: Pick<InstanceType<TErrorConstructor>, TKeys>) => InstanceType<TErrorConstructor>): ClassDecorator;
|
|
25
|
-
};
|
|
26
|
-
};
|
|
27
|
-
static createApiError(data: any): any;
|
|
28
|
-
}
|
|
29
|
-
export declare class UnknownServerError extends ApiErrorBase<typeof UnknownServerErrorAppCode> {
|
|
30
|
-
data: any;
|
|
31
|
-
constructor(data: any, developerMessage?: string);
|
|
32
|
-
}
|
|
33
|
-
export declare class UnauthorisedError extends ApiErrorBase<'UnauthorisedError'> {
|
|
34
|
-
constructor(message: string, developerMessage?: string);
|
|
35
|
-
}
|
|
36
|
-
export declare class RequestEntityTooLargeError extends ApiErrorBase<'RequestEntityTooLargeError'> {
|
|
37
|
-
expected: number;
|
|
38
|
-
length: number;
|
|
39
|
-
limit: number;
|
|
40
|
-
constructor(message: string, expected: number, length: number, limit: number);
|
|
41
|
-
}
|
|
42
|
-
export declare class NotFoundError extends ApiErrorBase<'NotFoundError'> {
|
|
43
|
-
constructor(message: string, developerMessage?: string);
|
|
44
|
-
}
|
|
45
|
-
export declare class BadRequestError extends ApiErrorBase<'BadRequestError'> {
|
|
46
|
-
constructor(message: string, developerMessage?: string);
|
|
47
|
-
}
|
|
48
|
-
export declare class ForbiddenError extends ApiErrorBase<'ForbiddenError'> {
|
|
49
|
-
constructor(message: string, developerMessage?: string);
|
|
50
|
-
}
|
|
51
|
-
export interface IValidationErrorMessages {
|
|
52
|
-
developer: string;
|
|
53
|
-
friendly?: string;
|
|
54
|
-
}
|
|
55
|
-
export interface IValidationErrorDetail {
|
|
56
|
-
attribute?: string;
|
|
57
|
-
path: string;
|
|
58
|
-
value: any;
|
|
59
|
-
messages: IValidationErrorMessages;
|
|
60
|
-
}
|
|
61
|
-
export declare class ValidationError extends ApiErrorBase<'ValidationError'> {
|
|
62
|
-
errors: IValidationErrorDetail[];
|
|
63
|
-
constructor(errors: IValidationErrorDetail[], developerMessage?: string);
|
|
64
|
-
}
|
|
65
|
-
export declare class ConfigurationError extends ApiErrorBase<'ConfigurationError'> {
|
|
66
|
-
constructor(message: string, developerMessage?: string);
|
|
67
|
-
}
|
|
68
|
-
export declare class ConflictError extends ApiErrorBase<'ConflictError'> {
|
|
69
|
-
constructor(message: string, developerMessage?: string);
|
|
70
|
-
}
|
|
71
|
-
export declare class ArgumentError extends ApiErrorBase<'ArgumentError'> {
|
|
72
|
-
parameter: string;
|
|
73
|
-
constructor(parameter: string, developerMessage?: string);
|
|
74
|
-
}
|
|
75
|
-
export declare type OrbitError = UnknownServerError | UnauthorisedError | RequestEntityTooLargeError | NotFoundError | BadRequestError | ForbiddenError | ValidationError | ConfigurationError | ConflictError | ArgumentError;
|
|
76
|
-
export declare type AuditEndpointName = OpaqueString<'AuditEndpointName'>;
|
|
77
|
-
export declare type OpaqueString<Key extends string> = string & {
|
|
78
|
-
__opaque: Key;
|
|
79
|
-
};
|
|
80
|
-
export interface IPostgresEndpointConfig {
|
|
81
|
-
kind: 'postgres';
|
|
82
|
-
}
|
|
83
|
-
export interface ISqlServerEndpointConfig {
|
|
84
|
-
kind: 'mssql';
|
|
85
|
-
}
|
|
86
|
-
export declare type EndpointConfig = IPostgresEndpointConfig | ISqlServerEndpointConfig;
|
|
87
|
-
export interface IEndpointRegistration {
|
|
88
|
-
endpointName: AuditEndpointName;
|
|
89
|
-
config: EndpointConfig;
|
|
90
|
-
}
|
|
91
|
-
export declare type AuditEventName = OpaqueString<'AuditEventName'>;
|
|
92
|
-
export declare type AuditEntryPayloadVersion = OpaqueString<'AuditEntryPayloadVersion'>;
|
|
93
|
-
export interface IJsonSchema {
|
|
94
|
-
}
|
|
95
|
-
export interface IEventRegistration {
|
|
96
|
-
eventName: AuditEventName;
|
|
97
|
-
payloadVersion: AuditEntryPayloadVersion;
|
|
98
|
-
payloadSchema: IJsonSchema;
|
|
99
|
-
}
|
|
100
|
-
export declare type ServiceName = OpaqueString<'ServiceName'>;
|
|
101
|
-
export declare type UserId = OpaqueString<'UserId'>;
|
|
102
|
-
export declare type Complexity = any;
|
|
103
|
-
export declare type CursorResult = any | void | boolean;
|
|
104
|
-
export declare type AggregationCursorResult = any | void;
|
|
105
|
-
export declare type AuditEntryPayload = any;
|
|
106
|
-
export declare type ValueType = any;
|
|
107
|
-
export interface IAuditEntry {
|
|
108
|
-
serviceName: ServiceName;
|
|
109
|
-
authUserId: UserId;
|
|
110
|
-
payloadVersion: AuditEntryPayloadVersion;
|
|
111
|
-
payload: AuditEntryPayload;
|
|
112
|
-
}
|
|
113
|
-
export declare type AuditEntryId = OpaqueString<'AuditEntryId'>;
|
|
114
|
-
export declare type DateTimeString = OpaqueString<'DateTime'>;
|
|
115
|
-
export interface IAuditEntryCreated extends IAuditEntry {
|
|
116
|
-
id: AuditEntryId;
|
|
117
|
-
timestamp: DateTimeString;
|
|
118
|
-
}
|
|
119
|
-
export interface HeaderMap {
|
|
120
|
-
[k: string]: string;
|
|
121
|
-
}
|
|
122
|
-
export interface IFetcher {
|
|
123
|
-
request<T>(url: string, verb: string, contentType: string, body?: any, headers?: HeaderMap): Promise<T>;
|
|
124
|
-
buildQueryString(query?: any): string;
|
|
125
|
-
requestValidate?(routeUniqueName: string, paramValues: {
|
|
126
|
-
body?: any;
|
|
127
|
-
params?: any;
|
|
128
|
-
query?: any;
|
|
129
|
-
}): Promise<void>;
|
|
130
|
-
}
|
|
131
|
-
export declare class Qs {
|
|
132
|
-
private static buildQueryStringKeyValueItem;
|
|
133
|
-
static buildQueryStringKeyValue(key: string, value: any): string;
|
|
134
|
-
static buildQueryString(query?: any, buildQueryStringValue?: (key: string, value: any) => string): string;
|
|
135
|
-
}
|
|
136
|
-
export declare function optionalParam(parameter: any, key: string): string;
|
|
137
|
-
export declare class AuditController {
|
|
138
|
-
private fetcher;
|
|
139
|
-
constructor(fetcher: IFetcher);
|
|
140
|
-
registerEndpoint: (body: IEndpointRegistration, headers?: HeaderMap | undefined) => Promise<void>;
|
|
141
|
-
registerEvent: (body: IEventRegistration, params: {
|
|
142
|
-
endpointName: AuditEndpointName;
|
|
143
|
-
}, headers?: HeaderMap | undefined) => Promise<void>;
|
|
144
|
-
createEntry: (body: IAuditEntry, params: {
|
|
145
|
-
endpointName: AuditEndpointName;
|
|
146
|
-
eventName: AuditEventName;
|
|
147
|
-
}, headers?: HeaderMap | undefined) => Promise<IAuditEntryCreated>;
|
|
148
|
-
}
|
|
149
|
-
export declare class TransactionalHealthController {
|
|
150
|
-
private fetcher;
|
|
151
|
-
constructor(fetcher: IFetcher);
|
|
152
|
-
health: (headers?: HeaderMap | undefined) => Promise<void>;
|
|
153
|
-
}
|
|
154
|
-
export declare class HealthController {
|
|
155
|
-
private fetcher;
|
|
156
|
-
constructor(fetcher: IFetcher);
|
|
157
|
-
health: (headers?: HeaderMap | undefined) => Promise<void>;
|
|
158
|
-
}
|
|
159
|
-
export declare class ApiClient {
|
|
160
|
-
private fetcher;
|
|
161
|
-
constructor(fetcher: IFetcher);
|
|
162
|
-
audit: AuditController;
|
|
163
|
-
transactionalHealth: TransactionalHealthController;
|
|
164
|
-
health: HealthController;
|
|
165
|
-
}
|