@arcasdk/core 0.3.1 → 0.3.3
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/lib/application/config/env.d.ts +6 -0
- package/lib/application/config/env.js +14 -0
- package/lib/application/config/env.js.map +1 -0
- package/lib/application/config/index.d.ts +6 -0
- package/lib/application/config/index.js +15 -0
- package/lib/application/config/index.js.map +1 -0
- package/lib/application/dto/electronic-billing.dto.d.ts +192 -0
- package/lib/application/dto/electronic-billing.dto.js +3 -0
- package/lib/application/dto/electronic-billing.dto.js.map +1 -0
- package/lib/application/dto/index.d.ts +6 -0
- package/lib/application/dto/index.js +23 -0
- package/lib/application/dto/index.js.map +1 -0
- package/lib/application/dto/register.dto.d.ts +116 -0
- package/lib/application/dto/register.dto.js +8 -0
- package/lib/application/dto/register.dto.js.map +1 -0
- package/lib/application/index.d.ts +10 -0
- package/lib/application/index.js +27 -0
- package/lib/application/index.js.map +1 -0
- package/lib/application/ports/authentication/authentication-repository.port.d.ts +29 -0
- package/lib/application/ports/authentication/authentication-repository.port.js +3 -0
- package/lib/application/ports/authentication/authentication-repository.port.js.map +1 -0
- package/lib/application/ports/authentication/index.d.ts +5 -0
- package/lib/application/ports/authentication/index.js +22 -0
- package/lib/application/ports/authentication/index.js.map +1 -0
- package/lib/application/ports/electronic-billing/electronic-billing-repository.port.d.ts +139 -0
- package/lib/application/ports/electronic-billing/electronic-billing-repository.port.js +3 -0
- package/lib/application/ports/electronic-billing/electronic-billing-repository.port.js.map +1 -0
- package/lib/application/ports/electronic-billing/index.d.ts +5 -0
- package/lib/application/ports/electronic-billing/index.js +22 -0
- package/lib/application/ports/electronic-billing/index.js.map +1 -0
- package/lib/application/ports/generic/generic-repository.port.d.ts +16 -0
- package/lib/application/ports/generic/generic-repository.port.js +3 -0
- package/lib/application/ports/generic/generic-repository.port.js.map +1 -0
- package/lib/application/ports/index.d.ts +7 -0
- package/lib/application/ports/index.js +24 -0
- package/lib/application/ports/index.js.map +1 -0
- package/lib/application/ports/register/index.d.ts +5 -0
- package/lib/application/ports/register/index.js +22 -0
- package/lib/application/ports/register/index.js.map +1 -0
- package/lib/application/ports/register/register-repository.ports.d.ts +23 -0
- package/lib/application/ports/register/register-repository.ports.js +3 -0
- package/lib/application/ports/register/register-repository.ports.js.map +1 -0
- package/lib/application/services/electronic-billing.service.d.ts +202 -0
- package/lib/application/services/electronic-billing.service.js +340 -0
- package/lib/application/services/electronic-billing.service.js.map +1 -0
- package/lib/application/services/generic.service.d.ts +19 -0
- package/lib/application/services/generic.service.js +31 -0
- package/lib/application/services/generic.service.js.map +1 -0
- package/lib/application/services/index.d.ts +10 -0
- package/lib/application/services/index.js +27 -0
- package/lib/application/services/index.js.map +1 -0
- package/lib/application/services/register-inscription-proof.service.d.ts +26 -0
- package/lib/application/services/register-inscription-proof.service.js +49 -0
- package/lib/application/services/register-inscription-proof.service.js.map +1 -0
- package/lib/application/services/register-scope-five.service.d.ts +26 -0
- package/lib/application/services/register-scope-five.service.js +49 -0
- package/lib/application/services/register-scope-five.service.js.map +1 -0
- package/lib/application/services/register-scope-four.service.d.ts +28 -0
- package/lib/application/services/register-scope-four.service.js +51 -0
- package/lib/application/services/register-scope-four.service.js.map +1 -0
- package/lib/application/services/register-scope-ten.service.d.ts +21 -0
- package/lib/application/services/register-scope-ten.service.js +39 -0
- package/lib/application/services/register-scope-ten.service.js.map +1 -0
- package/lib/application/services/register-scope-thirteen.service.d.ts +26 -0
- package/lib/application/services/register-scope-thirteen.service.js +49 -0
- package/lib/application/services/register-scope-thirteen.service.js.map +1 -0
- package/lib/application/types/auth.types.d.ts +19 -0
- package/lib/application/types/auth.types.js +7 -0
- package/lib/application/types/auth.types.js.map +1 -0
- package/lib/application/types/context.types.d.ts +46 -0
- package/lib/application/types/context.types.js +3 -0
- package/lib/application/types/context.types.js.map +1 -0
- package/lib/application/types/index.d.ts +8 -0
- package/lib/application/types/index.js +25 -0
- package/lib/application/types/index.js.map +1 -0
- package/lib/application/types/result.types.d.ts +10 -0
- package/lib/application/types/result.types.js +3 -0
- package/lib/application/types/result.types.js.map +1 -0
- package/lib/application/types/use-case-inputs.types.d.ts +23 -0
- package/lib/application/types/use-case-inputs.types.js +7 -0
- package/lib/application/types/use-case-inputs.types.js.map +1 -0
- package/lib/application/use-cases/authentication/get-auth-params.use-case.d.ts +16 -0
- package/lib/application/use-cases/authentication/get-auth-params.use-case.js +29 -0
- package/lib/application/use-cases/authentication/get-auth-params.use-case.js.map +1 -0
- package/lib/application/use-cases/authentication/index.d.ts +7 -0
- package/lib/application/use-cases/authentication/index.js +24 -0
- package/lib/application/use-cases/authentication/index.js.map +1 -0
- package/lib/application/use-cases/authentication/login.use-case.d.ts +17 -0
- package/lib/application/use-cases/authentication/login.use-case.js +29 -0
- package/lib/application/use-cases/authentication/login.use-case.js.map +1 -0
- package/lib/application/use-cases/authentication/request-login.use-case.d.ts +16 -0
- package/lib/application/use-cases/authentication/request-login.use-case.js +29 -0
- package/lib/application/use-cases/authentication/request-login.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/consult-caea-no-movement.use-case.d.ts +17 -0
- package/lib/application/use-cases/electronic-billing/consult-caea-no-movement.use-case.js +30 -0
- package/lib/application/use-cases/electronic-billing/consult-caea-no-movement.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/consult-caea.use-case.d.ts +17 -0
- package/lib/application/use-cases/electronic-billing/consult-caea.use-case.js +30 -0
- package/lib/application/use-cases/electronic-billing/consult-caea.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/create-next-voucher.use-case.d.ts +17 -0
- package/lib/application/use-cases/electronic-billing/create-next-voucher.use-case.js +39 -0
- package/lib/application/use-cases/electronic-billing/create-next-voucher.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/create-voucher.use-case.d.ts +17 -0
- package/lib/application/use-cases/electronic-billing/create-voucher.use-case.js +33 -0
- package/lib/application/use-cases/electronic-billing/create-voucher.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/get-activities.use-case.d.ts +15 -0
- package/lib/application/use-cases/electronic-billing/get-activities.use-case.js +28 -0
- package/lib/application/use-cases/electronic-billing/get-activities.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/get-aliquot-types.use-case.d.ts +15 -0
- package/lib/application/use-cases/electronic-billing/get-aliquot-types.use-case.js +28 -0
- package/lib/application/use-cases/electronic-billing/get-aliquot-types.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/get-caea.use-case.d.ts +17 -0
- package/lib/application/use-cases/electronic-billing/get-caea.use-case.js +30 -0
- package/lib/application/use-cases/electronic-billing/get-caea.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/get-concept-types.use-case.d.ts +15 -0
- package/lib/application/use-cases/electronic-billing/get-concept-types.use-case.js +28 -0
- package/lib/application/use-cases/electronic-billing/get-concept-types.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/get-countries.use-case.d.ts +15 -0
- package/lib/application/use-cases/electronic-billing/get-countries.use-case.js +28 -0
- package/lib/application/use-cases/electronic-billing/get-countries.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/get-currency-types.use-case.d.ts +15 -0
- package/lib/application/use-cases/electronic-billing/get-currency-types.use-case.js +28 -0
- package/lib/application/use-cases/electronic-billing/get-currency-types.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/get-document-types.use-case.d.ts +15 -0
- package/lib/application/use-cases/electronic-billing/get-document-types.use-case.js +28 -0
- package/lib/application/use-cases/electronic-billing/get-document-types.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/get-iva-receptor-types.use-case.d.ts +16 -0
- package/lib/application/use-cases/electronic-billing/get-iva-receptor-types.use-case.js +29 -0
- package/lib/application/use-cases/electronic-billing/get-iva-receptor-types.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/get-last-voucher.use-case.d.ts +17 -0
- package/lib/application/use-cases/electronic-billing/get-last-voucher.use-case.js +29 -0
- package/lib/application/use-cases/electronic-billing/get-last-voucher.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/get-max-records.use-case.d.ts +15 -0
- package/lib/application/use-cases/electronic-billing/get-max-records.use-case.js +28 -0
- package/lib/application/use-cases/electronic-billing/get-max-records.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/get-optional-types.use-case.d.ts +15 -0
- package/lib/application/use-cases/electronic-billing/get-optional-types.use-case.js +28 -0
- package/lib/application/use-cases/electronic-billing/get-optional-types.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/get-parameter-types.use-case.d.ts +40 -0
- package/lib/application/use-cases/electronic-billing/get-parameter-types.use-case.js +73 -0
- package/lib/application/use-cases/electronic-billing/get-parameter-types.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/get-quotation.use-case.d.ts +16 -0
- package/lib/application/use-cases/electronic-billing/get-quotation.use-case.js +29 -0
- package/lib/application/use-cases/electronic-billing/get-quotation.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/get-sales-points.use-case.d.ts +15 -0
- package/lib/application/use-cases/electronic-billing/get-sales-points.use-case.js +28 -0
- package/lib/application/use-cases/electronic-billing/get-sales-points.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/get-server-status.use-case.d.ts +15 -0
- package/lib/application/use-cases/electronic-billing/get-server-status.use-case.js +28 -0
- package/lib/application/use-cases/electronic-billing/get-server-status.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/get-tax-types.use-case.d.ts +15 -0
- package/lib/application/use-cases/electronic-billing/get-tax-types.use-case.js +28 -0
- package/lib/application/use-cases/electronic-billing/get-tax-types.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/get-voucher-info.use-case.d.ts +17 -0
- package/lib/application/use-cases/electronic-billing/get-voucher-info.use-case.js +29 -0
- package/lib/application/use-cases/electronic-billing/get-voucher-info.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/get-voucher-types.use-case.d.ts +15 -0
- package/lib/application/use-cases/electronic-billing/get-voucher-types.use-case.js +28 -0
- package/lib/application/use-cases/electronic-billing/get-voucher-types.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/index.d.ts +18 -0
- package/lib/application/use-cases/electronic-billing/index.js +36 -0
- package/lib/application/use-cases/electronic-billing/index.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/inform-caea-no-movement.use-case.d.ts +17 -0
- package/lib/application/use-cases/electronic-billing/inform-caea-no-movement.use-case.js +30 -0
- package/lib/application/use-cases/electronic-billing/inform-caea-no-movement.use-case.js.map +1 -0
- package/lib/application/use-cases/electronic-billing/inform-caea-usage.use-case.d.ts +14 -0
- package/lib/application/use-cases/electronic-billing/inform-caea-usage.use-case.js +32 -0
- package/lib/application/use-cases/electronic-billing/inform-caea-usage.use-case.js.map +1 -0
- package/lib/application/use-cases/index.d.ts +7 -0
- package/lib/application/use-cases/index.js +24 -0
- package/lib/application/use-cases/index.js.map +1 -0
- package/lib/application/use-cases/register/get-register-server-status.use-case.d.ts +15 -0
- package/lib/application/use-cases/register/get-register-server-status.use-case.js +28 -0
- package/lib/application/use-cases/register/get-register-server-status.use-case.js.map +1 -0
- package/lib/application/use-cases/register/get-tax-id-by-document.use-case.d.ts +16 -0
- package/lib/application/use-cases/register/get-tax-id-by-document.use-case.js +29 -0
- package/lib/application/use-cases/register/get-tax-id-by-document.use-case.js.map +1 -0
- package/lib/application/use-cases/register/get-taxpayer-details.use-case.d.ts +16 -0
- package/lib/application/use-cases/register/get-taxpayer-details.use-case.js +29 -0
- package/lib/application/use-cases/register/get-taxpayer-details.use-case.js.map +1 -0
- package/lib/application/use-cases/register/get-taxpayers-details.use-case.d.ts +16 -0
- package/lib/application/use-cases/register/get-taxpayers-details.use-case.js +29 -0
- package/lib/application/use-cases/register/get-taxpayers-details.use-case.js.map +1 -0
- package/lib/application/use-cases/register/index.d.ts +4 -0
- package/lib/application/use-cases/register/index.js +21 -0
- package/lib/application/use-cases/register/index.js.map +1 -0
- package/lib/arca.d.ts +26 -0
- package/lib/arca.js +124 -0
- package/lib/arca.js.map +1 -0
- package/lib/domain/entities/access-ticket.entity.d.ts +73 -0
- package/lib/domain/entities/access-ticket.entity.js +144 -0
- package/lib/domain/entities/access-ticket.entity.js.map +1 -0
- package/lib/domain/entities/index.d.ts +6 -0
- package/lib/domain/entities/index.js +23 -0
- package/lib/domain/entities/index.js.map +1 -0
- package/lib/domain/entities/voucher.entity.d.ts +113 -0
- package/lib/domain/entities/voucher.entity.js +216 -0
- package/lib/domain/entities/voucher.entity.js.map +1 -0
- package/lib/domain/index.d.ts +6 -0
- package/lib/domain/index.js +23 -0
- package/lib/domain/index.js.map +1 -0
- package/lib/domain/types/electronic-billing.types.d.ts +193 -0
- package/lib/domain/types/electronic-billing.types.js +8 -0
- package/lib/domain/types/electronic-billing.types.js.map +1 -0
- package/lib/domain/types/index.d.ts +6 -0
- package/lib/domain/types/index.js +23 -0
- package/lib/domain/types/index.js.map +1 -0
- package/lib/domain/types/voucher.types.d.ts +65 -0
- package/lib/domain/types/voucher.types.js +3 -0
- package/lib/domain/types/voucher.types.js.map +1 -0
- package/lib/domain/value-objects/cae.vo.d.ts +47 -0
- package/lib/domain/value-objects/cae.vo.js +80 -0
- package/lib/domain/value-objects/cae.vo.js.map +1 -0
- package/lib/domain/value-objects/cuit.vo.d.ts +49 -0
- package/lib/domain/value-objects/cuit.vo.js +98 -0
- package/lib/domain/value-objects/cuit.vo.js.map +1 -0
- package/lib/domain/value-objects/index.d.ts +7 -0
- package/lib/domain/value-objects/index.js +24 -0
- package/lib/domain/value-objects/index.js.map +1 -0
- package/lib/domain/value-objects/voucher-number.vo.d.ts +66 -0
- package/lib/domain/value-objects/voucher-number.vo.js +106 -0
- package/lib/domain/value-objects/voucher-number.vo.js.map +1 -0
- package/lib/index.d.ts +8 -0
- package/lib/index.js +27 -0
- package/lib/index.js.map +1 -0
- package/lib/infrastructure/constants/index.d.ts +5 -0
- package/lib/infrastructure/constants/index.js +22 -0
- package/lib/infrastructure/constants/index.js.map +1 -0
- package/lib/infrastructure/constants/ssl.constants.d.ts +16 -0
- package/lib/infrastructure/constants/ssl.constants.js +20 -0
- package/lib/infrastructure/constants/ssl.constants.js.map +1 -0
- package/lib/infrastructure/index.d.ts +5 -0
- package/lib/infrastructure/index.js +22 -0
- package/lib/infrastructure/index.js.map +1 -0
- package/lib/infrastructure/outbound/adapters/auth/afip-auth.repository.d.ts +68 -0
- package/lib/infrastructure/outbound/adapters/auth/afip-auth.repository.js +128 -0
- package/lib/infrastructure/outbound/adapters/auth/afip-auth.repository.js.map +1 -0
- package/lib/infrastructure/outbound/adapters/auth/auth.repository.d.ts +59 -0
- package/lib/infrastructure/outbound/adapters/auth/auth.repository.js +134 -0
- package/lib/infrastructure/outbound/adapters/auth/auth.repository.js.map +1 -0
- package/lib/infrastructure/outbound/adapters/electronic-billing/electronic-billing-repository.d.ts +41 -0
- package/lib/infrastructure/outbound/adapters/electronic-billing/electronic-billing-repository.js +513 -0
- package/lib/infrastructure/outbound/adapters/electronic-billing/electronic-billing-repository.js.map +1 -0
- package/lib/infrastructure/outbound/adapters/electronic-billing/index.d.ts +5 -0
- package/lib/infrastructure/outbound/adapters/electronic-billing/index.js +22 -0
- package/lib/infrastructure/outbound/adapters/electronic-billing/index.js.map +1 -0
- package/lib/infrastructure/outbound/adapters/enums.d.ts +43 -0
- package/lib/infrastructure/outbound/adapters/enums.js +49 -0
- package/lib/infrastructure/outbound/adapters/enums.js.map +1 -0
- package/lib/infrastructure/outbound/adapters/generic/generic-repository.d.ts +13 -0
- package/lib/infrastructure/outbound/adapters/generic/generic-repository.js +53 -0
- package/lib/infrastructure/outbound/adapters/generic/generic-repository.js.map +1 -0
- package/lib/infrastructure/outbound/adapters/index.d.ts +10 -0
- package/lib/infrastructure/outbound/adapters/index.js +27 -0
- package/lib/infrastructure/outbound/adapters/index.js.map +1 -0
- package/lib/infrastructure/outbound/adapters/logger/winston-logger.d.ts +14 -0
- package/lib/infrastructure/outbound/adapters/logger/winston-logger.js +24 -0
- package/lib/infrastructure/outbound/adapters/logger/winston-logger.js.map +1 -0
- package/lib/infrastructure/outbound/adapters/register/index.d.ts +9 -0
- package/lib/infrastructure/outbound/adapters/register/index.js +26 -0
- package/lib/infrastructure/outbound/adapters/register/index.js.map +1 -0
- package/lib/infrastructure/outbound/adapters/register/register-inscription-proof.repository.d.ts +18 -0
- package/lib/infrastructure/outbound/adapters/register/register-inscription-proof.repository.js +143 -0
- package/lib/infrastructure/outbound/adapters/register/register-inscription-proof.repository.js.map +1 -0
- package/lib/infrastructure/outbound/adapters/register/register-scope-five.repository.d.ts +14 -0
- package/lib/infrastructure/outbound/adapters/register/register-scope-five.repository.js +136 -0
- package/lib/infrastructure/outbound/adapters/register/register-scope-five.repository.js.map +1 -0
- package/lib/infrastructure/outbound/adapters/register/register-scope-four.repository.d.ts +12 -0
- package/lib/infrastructure/outbound/adapters/register/register-scope-four.repository.js +103 -0
- package/lib/infrastructure/outbound/adapters/register/register-scope-four.repository.js.map +1 -0
- package/lib/infrastructure/outbound/adapters/register/register-scope-ten.repository.d.ts +12 -0
- package/lib/infrastructure/outbound/adapters/register/register-scope-ten.repository.js +112 -0
- package/lib/infrastructure/outbound/adapters/register/register-scope-ten.repository.js.map +1 -0
- package/lib/infrastructure/outbound/adapters/register/register-scope-thirteen.repository.d.ts +13 -0
- package/lib/infrastructure/outbound/adapters/register/register-scope-thirteen.repository.js +133 -0
- package/lib/infrastructure/outbound/adapters/register/register-scope-thirteen.repository.js.map +1 -0
- package/lib/infrastructure/outbound/adapters/soap/base-soap-repository.d.ts +30 -0
- package/lib/infrastructure/outbound/adapters/soap/base-soap-repository.js +68 -0
- package/lib/infrastructure/outbound/adapters/soap/base-soap-repository.js.map +1 -0
- package/lib/infrastructure/outbound/adapters/soap/soap-client-facade.d.ts +20 -0
- package/lib/infrastructure/outbound/adapters/soap/soap-client-facade.js +54 -0
- package/lib/infrastructure/outbound/adapters/soap/soap-client-facade.js.map +1 -0
- package/lib/infrastructure/outbound/adapters/soap/soap-client.d.ts +11 -0
- package/lib/infrastructure/outbound/adapters/soap/soap-client.js +95 -0
- package/lib/infrastructure/outbound/adapters/soap/soap-client.js.map +1 -0
- package/lib/infrastructure/outbound/adapters/soap/wsdl-strings.d.ts +10 -0
- package/lib/infrastructure/outbound/adapters/soap/wsdl-strings.js +6144 -0
- package/lib/infrastructure/outbound/adapters/soap/wsdl-strings.js.map +1 -0
- package/lib/infrastructure/outbound/adapters/storage/file-system-ticket-storage.d.ts +24 -0
- package/lib/infrastructure/outbound/adapters/storage/file-system-ticket-storage.js +98 -0
- package/lib/infrastructure/outbound/adapters/storage/file-system-ticket-storage.js.map +1 -0
- package/lib/infrastructure/outbound/index.d.ts +9 -0
- package/lib/infrastructure/outbound/index.js +26 -0
- package/lib/infrastructure/outbound/index.js.map +1 -0
- package/lib/infrastructure/outbound/ports/auth/auth-repository.types.d.ts +17 -0
- package/lib/infrastructure/outbound/ports/auth/auth-repository.types.js +3 -0
- package/lib/infrastructure/outbound/ports/auth/auth-repository.types.js.map +1 -0
- package/lib/infrastructure/outbound/ports/index.d.ts +11 -0
- package/lib/infrastructure/outbound/ports/index.js +28 -0
- package/lib/infrastructure/outbound/ports/index.js.map +1 -0
- package/lib/infrastructure/outbound/ports/logger/logger.port.d.ts +31 -0
- package/lib/infrastructure/outbound/ports/logger/logger.port.js +3 -0
- package/lib/infrastructure/outbound/ports/logger/logger.port.js.map +1 -0
- package/lib/infrastructure/outbound/ports/logger/logger.types.d.ts +7 -0
- package/lib/infrastructure/outbound/ports/logger/logger.types.js +3 -0
- package/lib/infrastructure/outbound/ports/logger/logger.types.js.map +1 -0
- package/lib/infrastructure/outbound/ports/soap/enums/endpoints.enum.d.ts +51 -0
- package/lib/infrastructure/outbound/ports/soap/enums/endpoints.enum.js +57 -0
- package/lib/infrastructure/outbound/ports/soap/enums/endpoints.enum.js.map +1 -0
- package/lib/infrastructure/outbound/ports/soap/enums/index.d.ts +7 -0
- package/lib/infrastructure/outbound/ports/soap/enums/index.js +24 -0
- package/lib/infrastructure/outbound/ports/soap/enums/index.js.map +1 -0
- package/lib/infrastructure/outbound/ports/soap/enums/service-names.enum.d.ts +9 -0
- package/lib/infrastructure/outbound/ports/soap/enums/service-names.enum.js +14 -0
- package/lib/infrastructure/outbound/ports/soap/enums/service-names.enum.js.map +1 -0
- package/lib/infrastructure/outbound/ports/soap/enums/wsdl-path.enum.d.ts +15 -0
- package/lib/infrastructure/outbound/ports/soap/enums/wsdl-path.enum.js +20 -0
- package/lib/infrastructure/outbound/ports/soap/enums/wsdl-path.enum.js.map +1 -0
- package/lib/infrastructure/outbound/ports/soap/index.d.ts +7 -0
- package/lib/infrastructure/outbound/ports/soap/index.js +24 -0
- package/lib/infrastructure/outbound/ports/soap/index.js.map +1 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/LoginCMSService/LoginCms.d.ts +42 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/LoginCMSService/LoginCms.js +3 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/LoginCMSService/LoginCms.js.map +1 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/PersonaServiceA10/PersonaServiceA10Port.d.ts +102 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/PersonaServiceA10/PersonaServiceA10Port.js +3 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/PersonaServiceA10/PersonaServiceA10Port.js.map +1 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/PersonaServiceA13/PersonaServiceA13Port.d.ts +145 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/PersonaServiceA13/PersonaServiceA13Port.js +3 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/PersonaServiceA13/PersonaServiceA13Port.js.map +1 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/PersonaServiceA4/PersonaServiceA4Port.d.ts +227 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/PersonaServiceA4/PersonaServiceA4Port.js +3 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/PersonaServiceA4/PersonaServiceA4Port.js.map +1 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/PersonaServiceA5/PersonaServiceA5Port.d.ts +300 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/PersonaServiceA5/PersonaServiceA5Port.js +3 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/PersonaServiceA5/PersonaServiceA5Port.js.map +1 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/PersonaServiceInscriptionProof/PersonaServiceInscriptionProofPort.d.ts +301 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/PersonaServiceInscriptionProof/PersonaServiceInscriptionProofPort.js +3 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/PersonaServiceInscriptionProof/PersonaServiceInscriptionProofPort.js.map +1 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/Service/ServiceSoap.d.ts +835 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/Service/ServiceSoap.js +3 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/Service/ServiceSoap.js.map +1 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/Service/ServiceSoap12.d.ts +876 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/Service/ServiceSoap12.js +3 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/Service/ServiceSoap12.js.map +1 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/index.d.ts +15 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/index.js +53 -0
- package/lib/infrastructure/outbound/ports/soap/interfaces/index.js.map +1 -0
- package/lib/infrastructure/outbound/ports/soap/soap-client.port.d.ts +30 -0
- package/lib/infrastructure/outbound/ports/soap/soap-client.port.js +3 -0
- package/lib/infrastructure/outbound/ports/soap/soap-client.port.js.map +1 -0
- package/lib/infrastructure/outbound/ports/soap/soap-repository.types.d.ts +45 -0
- package/lib/infrastructure/outbound/ports/soap/soap-repository.types.js +3 -0
- package/lib/infrastructure/outbound/ports/soap/soap-repository.types.js.map +1 -0
- package/lib/infrastructure/outbound/ports/storage/ticket-storage.port.d.ts +24 -0
- package/lib/infrastructure/outbound/ports/storage/ticket-storage.port.js +3 -0
- package/lib/infrastructure/outbound/ports/storage/ticket-storage.port.js.map +1 -0
- package/lib/infrastructure/outbound/ports/storage/ticket-storage.types.d.ts +9 -0
- package/lib/infrastructure/outbound/ports/storage/ticket-storage.types.js +3 -0
- package/lib/infrastructure/outbound/ports/storage/ticket-storage.types.js.map +1 -0
- package/lib/infrastructure/types/index.d.ts +5 -0
- package/lib/infrastructure/types/index.js +22 -0
- package/lib/infrastructure/types/index.js.map +1 -0
- package/lib/infrastructure/types/soap.types.d.ts +29 -0
- package/lib/infrastructure/types/soap.types.js +3 -0
- package/lib/infrastructure/types/soap.types.js.map +1 -0
- package/lib/infrastructure/utils/crypt-data.d.ts +6 -0
- package/lib/infrastructure/utils/crypt-data.js +46 -0
- package/lib/infrastructure/utils/crypt-data.js.map +1 -0
- package/lib/infrastructure/utils/env.d.ts +10 -0
- package/lib/infrastructure/utils/env.js +32 -0
- package/lib/infrastructure/utils/env.js.map +1 -0
- package/lib/infrastructure/utils/index.d.ts +8 -0
- package/lib/infrastructure/utils/index.js +25 -0
- package/lib/infrastructure/utils/index.js.map +1 -0
- package/lib/infrastructure/utils/logger.d.ts +4 -0
- package/lib/infrastructure/utils/logger.js +21 -0
- package/lib/infrastructure/utils/logger.js.map +1 -0
- package/lib/infrastructure/utils/parser.d.ts +14 -0
- package/lib/infrastructure/utils/parser.js +36 -0
- package/lib/infrastructure/utils/parser.js.map +1 -0
- package/lib/infrastructure/utils/soap-to-dto.mapper.d.ts +200 -0
- package/lib/infrastructure/utils/soap-to-dto.mapper.js +213 -0
- package/lib/infrastructure/utils/soap-to-dto.mapper.js.map +1 -0
- package/package.json +3 -2
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ServiceSoap12.js","sourceRoot":"","sources":["../../../../../../../src/infrastructure/outbound/ports/soap/interfaces/Service/ServiceSoap12.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* SOAP Interfaces
|
|
3
|
+
* Re-export interfaces with namespaces to avoid naming conflicts
|
|
4
|
+
*
|
|
5
|
+
* Note: Direct imports from specific files are recommended to avoid conflicts
|
|
6
|
+
* Example: import { ILoginCmsSoap } from "@infrastructure/outbound/ports/soap/interfaces/LoginCMSService/LoginCms"
|
|
7
|
+
*/
|
|
8
|
+
export * as LoginCMSService from "./LoginCMSService/LoginCms";
|
|
9
|
+
export * as PersonaServiceA10 from "./PersonaServiceA10/PersonaServiceA10Port";
|
|
10
|
+
export * as PersonaServiceA13 from "./PersonaServiceA13/PersonaServiceA13Port";
|
|
11
|
+
export * as PersonaServiceA4 from "./PersonaServiceA4/PersonaServiceA4Port";
|
|
12
|
+
export * as PersonaServiceA5 from "./PersonaServiceA5/PersonaServiceA5Port";
|
|
13
|
+
export * as PersonaServiceInscriptionProof from "./PersonaServiceInscriptionProof/PersonaServiceInscriptionProofPort";
|
|
14
|
+
export * as ServiceSoapTypes from "./Service/ServiceSoap";
|
|
15
|
+
export * as ServiceSoap12Types from "./Service/ServiceSoap12";
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* SOAP Interfaces
|
|
4
|
+
* Re-export interfaces with namespaces to avoid naming conflicts
|
|
5
|
+
*
|
|
6
|
+
* Note: Direct imports from specific files are recommended to avoid conflicts
|
|
7
|
+
* Example: import { ILoginCmsSoap } from "@infrastructure/outbound/ports/soap/interfaces/LoginCMSService/LoginCms"
|
|
8
|
+
*/
|
|
9
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
12
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
13
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
14
|
+
}
|
|
15
|
+
Object.defineProperty(o, k2, desc);
|
|
16
|
+
}) : (function(o, m, k, k2) {
|
|
17
|
+
if (k2 === undefined) k2 = k;
|
|
18
|
+
o[k2] = m[k];
|
|
19
|
+
}));
|
|
20
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
21
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
22
|
+
}) : function(o, v) {
|
|
23
|
+
o["default"] = v;
|
|
24
|
+
});
|
|
25
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
26
|
+
var ownKeys = function(o) {
|
|
27
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
28
|
+
var ar = [];
|
|
29
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
30
|
+
return ar;
|
|
31
|
+
};
|
|
32
|
+
return ownKeys(o);
|
|
33
|
+
};
|
|
34
|
+
return function (mod) {
|
|
35
|
+
if (mod && mod.__esModule) return mod;
|
|
36
|
+
var result = {};
|
|
37
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
38
|
+
__setModuleDefault(result, mod);
|
|
39
|
+
return result;
|
|
40
|
+
};
|
|
41
|
+
})();
|
|
42
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
43
|
+
exports.ServiceSoap12Types = exports.ServiceSoapTypes = exports.PersonaServiceInscriptionProof = exports.PersonaServiceA5 = exports.PersonaServiceA4 = exports.PersonaServiceA13 = exports.PersonaServiceA10 = exports.LoginCMSService = void 0;
|
|
44
|
+
// Export as namespaces to avoid conflicts
|
|
45
|
+
exports.LoginCMSService = __importStar(require("./LoginCMSService/LoginCms"));
|
|
46
|
+
exports.PersonaServiceA10 = __importStar(require("./PersonaServiceA10/PersonaServiceA10Port"));
|
|
47
|
+
exports.PersonaServiceA13 = __importStar(require("./PersonaServiceA13/PersonaServiceA13Port"));
|
|
48
|
+
exports.PersonaServiceA4 = __importStar(require("./PersonaServiceA4/PersonaServiceA4Port"));
|
|
49
|
+
exports.PersonaServiceA5 = __importStar(require("./PersonaServiceA5/PersonaServiceA5Port"));
|
|
50
|
+
exports.PersonaServiceInscriptionProof = __importStar(require("./PersonaServiceInscriptionProof/PersonaServiceInscriptionProofPort"));
|
|
51
|
+
exports.ServiceSoapTypes = __importStar(require("./Service/ServiceSoap"));
|
|
52
|
+
exports.ServiceSoap12Types = __importStar(require("./Service/ServiceSoap12"));
|
|
53
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/infrastructure/outbound/ports/soap/interfaces/index.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,0CAA0C;AAC1C,8EAA8D;AAC9D,+FAA+E;AAC/E,+FAA+E;AAC/E,4FAA4E;AAC5E,4FAA4E;AAC5E,sIAAsH;AACtH,0EAA0D;AAC1D,8EAA8D"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* SOAP Client Port
|
|
3
|
+
* Outbound port for SOAP client operations
|
|
4
|
+
*/
|
|
5
|
+
import { Client } from "soap";
|
|
6
|
+
export interface ISoapClientPort {
|
|
7
|
+
/**
|
|
8
|
+
* Create a SOAP client from a WSDL
|
|
9
|
+
* @param wsdlPath Path to the WSDL file
|
|
10
|
+
* @param options SOAP client options
|
|
11
|
+
* @returns The SOAP client
|
|
12
|
+
*/
|
|
13
|
+
createClient<T extends Client>(wsdlName: string, options?: any & {
|
|
14
|
+
wsdlContent?: string;
|
|
15
|
+
}): Promise<T>;
|
|
16
|
+
/**
|
|
17
|
+
* Set the endpoint URL for the client
|
|
18
|
+
* @param client The SOAP client
|
|
19
|
+
* @param endpoint The endpoint URL
|
|
20
|
+
*/
|
|
21
|
+
setEndpoint(client: any, endpoint: string): void;
|
|
22
|
+
/**
|
|
23
|
+
* Execute a SOAP method
|
|
24
|
+
* @param client The SOAP client
|
|
25
|
+
* @param methodName The name of the method to call
|
|
26
|
+
* @param params The parameters for the method
|
|
27
|
+
* @returns The response from the SOAP call (tuple: [result, rawResponse, soapHeader, rawRequest])
|
|
28
|
+
*/
|
|
29
|
+
call<T extends [any, string, any, string]>(client: any, methodName: string, params: any): Promise<T>;
|
|
30
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"soap-client.port.js","sourceRoot":"","sources":["../../../../../src/infrastructure/outbound/ports/soap/soap-client.port.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* SOAP Repository Types
|
|
3
|
+
* Configuration types for SOAP repositories
|
|
4
|
+
*/
|
|
5
|
+
import { ISoapClientPort } from "./soap-client.port";
|
|
6
|
+
import { IAuthenticationRepositoryPort } from "@application/ports/authentication/authentication-repository.port";
|
|
7
|
+
import { ILoggerPort } from "../logger/logger.port";
|
|
8
|
+
import { ServiceNamesEnum } from "./enums/service-names.enum";
|
|
9
|
+
import { SoapServiceVersion } from "./enums/endpoints.enum";
|
|
10
|
+
export interface BaseSoapRepositoryConstructorConfig {
|
|
11
|
+
soapClient?: ISoapClientPort;
|
|
12
|
+
authRepository: IAuthenticationRepositoryPort;
|
|
13
|
+
logger: ILoggerPort;
|
|
14
|
+
cuit: number;
|
|
15
|
+
production?: boolean;
|
|
16
|
+
/**
|
|
17
|
+
* Use SOAP 1.2 instead of SOAP 1.1 for Electronic Billing service
|
|
18
|
+
* @default true (uses SOAP 1.2 by default)
|
|
19
|
+
*/
|
|
20
|
+
useSoap12?: boolean;
|
|
21
|
+
}
|
|
22
|
+
export interface AuthenticatedProxyOptions {
|
|
23
|
+
/**
|
|
24
|
+
* Service name to use for authentication
|
|
25
|
+
*/
|
|
26
|
+
serviceName: ServiceNamesEnum;
|
|
27
|
+
/**
|
|
28
|
+
* Whether to inject auth.Auth instead of auth directly
|
|
29
|
+
* @default false
|
|
30
|
+
*/
|
|
31
|
+
injectAuthProperty?: boolean;
|
|
32
|
+
/**
|
|
33
|
+
* SOAP service version to use when checking if method requires Auth
|
|
34
|
+
* @default ServiceSoap12
|
|
35
|
+
*/
|
|
36
|
+
soapVersion?: SoapServiceVersion;
|
|
37
|
+
/**
|
|
38
|
+
* Optional function to map auth parameters before injection
|
|
39
|
+
*/
|
|
40
|
+
authMapper?: (auth: any) => any;
|
|
41
|
+
/**
|
|
42
|
+
* List of methods to exclude from authentication injection
|
|
43
|
+
*/
|
|
44
|
+
excludeMethods?: string[];
|
|
45
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"soap-repository.types.js","sourceRoot":"","sources":["../../../../../src/infrastructure/outbound/ports/soap/soap-repository.types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Ticket Storage Port
|
|
3
|
+
* Outbound port for ticket storage operations
|
|
4
|
+
*/
|
|
5
|
+
import { AccessTicket } from "@domain/entities/access-ticket.entity";
|
|
6
|
+
export interface ITicketStoragePort {
|
|
7
|
+
/**
|
|
8
|
+
* Save an access ticket
|
|
9
|
+
* @param ticket Access ticket to save
|
|
10
|
+
* @param serviceName Service name identifier
|
|
11
|
+
*/
|
|
12
|
+
save(ticket: AccessTicket, serviceName: string): Promise<void>;
|
|
13
|
+
/**
|
|
14
|
+
* Get an access ticket
|
|
15
|
+
* @param serviceName Service name identifier
|
|
16
|
+
* @returns AccessTicket or null if not found
|
|
17
|
+
*/
|
|
18
|
+
get(serviceName: string): Promise<AccessTicket | null>;
|
|
19
|
+
/**
|
|
20
|
+
* Delete an access ticket
|
|
21
|
+
* @param serviceName Service name identifier
|
|
22
|
+
*/
|
|
23
|
+
delete(serviceName: string): Promise<void>;
|
|
24
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ticket-storage.port.js","sourceRoot":"","sources":["../../../../../src/infrastructure/outbound/ports/storage/ticket-storage.port.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ticket-storage.types.js","sourceRoot":"","sources":["../../../../../src/infrastructure/outbound/ports/storage/ticket-storage.types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
/**
|
|
18
|
+
* Infrastructure Types
|
|
19
|
+
* Exports all infrastructure-related types
|
|
20
|
+
*/
|
|
21
|
+
__exportStar(require("./soap.types"), exports);
|
|
22
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/infrastructure/types/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA;;;GAGG;AACH,+CAA6B"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Infrastructure Types - SOAP
|
|
3
|
+
* Types related to SOAP infrastructure
|
|
4
|
+
*/
|
|
5
|
+
import { IOptions } from "soap";
|
|
6
|
+
import { WsdlPathEnum } from "@infrastructure/outbound/ports/soap/enums/wsdl-path.enum";
|
|
7
|
+
import { EndpointsEnum, SoapServiceVersion } from "@infrastructure/outbound/ports/soap/enums/endpoints.enum";
|
|
8
|
+
import { ServiceNamesEnum } from "@infrastructure/outbound/ports/soap/enums/service-names.enum";
|
|
9
|
+
export type SoapAsyncFunc<I, O> = (input: I, options?: any, extraHeaders?: any) => Promise<[O, string, {
|
|
10
|
+
[k: string]: any;
|
|
11
|
+
}, string]>;
|
|
12
|
+
export type WSAuthTokens = {
|
|
13
|
+
token: string;
|
|
14
|
+
sign: string;
|
|
15
|
+
expirationDate: string;
|
|
16
|
+
};
|
|
17
|
+
export type SoapClientParams = {
|
|
18
|
+
wsdl: WsdlPathEnum;
|
|
19
|
+
options?: IOptions;
|
|
20
|
+
};
|
|
21
|
+
export type ArcaServiceSoapParam = SoapClientParams & {
|
|
22
|
+
v12?: boolean;
|
|
23
|
+
url: EndpointsEnum;
|
|
24
|
+
url_test?: EndpointsEnum;
|
|
25
|
+
wsdl_test?: WsdlPathEnum;
|
|
26
|
+
} & {
|
|
27
|
+
serviceName: ServiceNamesEnum;
|
|
28
|
+
};
|
|
29
|
+
export type SoapServices<T> = Record<"Service", Record<SoapServiceVersion, Record<keyof T, Record<"input" | "output", Record<string, any>>>>>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"soap.types.js","sourceRoot":"","sources":["../../../src/infrastructure/types/soap.types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,46 @@
|
|
|
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
|
+
exports.Cryptography = void 0;
|
|
7
|
+
const node_forge_1 = __importDefault(require("node-forge"));
|
|
8
|
+
class Cryptography {
|
|
9
|
+
constructor(cert, key) {
|
|
10
|
+
this.cert = cert;
|
|
11
|
+
this.key = key;
|
|
12
|
+
}
|
|
13
|
+
sign(data) {
|
|
14
|
+
const p7 = node_forge_1.default.pkcs7.createSignedData();
|
|
15
|
+
p7.content = node_forge_1.default.util.createBuffer(data, "utf8");
|
|
16
|
+
try {
|
|
17
|
+
p7.addCertificate(this.cert);
|
|
18
|
+
}
|
|
19
|
+
catch (error) {
|
|
20
|
+
throw new Error("Invalid PEM formatted message. Check your cert.");
|
|
21
|
+
}
|
|
22
|
+
p7.addSigner({
|
|
23
|
+
authenticatedAttributes: [
|
|
24
|
+
{
|
|
25
|
+
type: node_forge_1.default.pki.oids.contentType,
|
|
26
|
+
value: node_forge_1.default.pki.oids.data,
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
type: node_forge_1.default.pki.oids.messageDigest,
|
|
30
|
+
},
|
|
31
|
+
{
|
|
32
|
+
type: node_forge_1.default.pki.oids.signingTime,
|
|
33
|
+
value: new Date(),
|
|
34
|
+
},
|
|
35
|
+
],
|
|
36
|
+
certificate: this.cert,
|
|
37
|
+
digestAlgorithm: node_forge_1.default.pki.oids.sha256,
|
|
38
|
+
key: this.key,
|
|
39
|
+
});
|
|
40
|
+
p7.sign();
|
|
41
|
+
const bytes = node_forge_1.default.asn1.toDer(p7.toAsn1()).getBytes();
|
|
42
|
+
return Buffer.from(bytes, "binary").toString("base64");
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
exports.Cryptography = Cryptography;
|
|
46
|
+
//# sourceMappingURL=crypt-data.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"crypt-data.js","sourceRoot":"","sources":["../../../src/infrastructure/utils/crypt-data.ts"],"names":[],"mappings":";;;;;;AAAA,4DAA+B;AAE/B,MAAa,YAAY;IACvB,YAA6B,IAAY,EAAmB,GAAW;QAA1C,SAAI,GAAJ,IAAI,CAAQ;QAAmB,QAAG,GAAH,GAAG,CAAQ;IAAG,CAAC;IAC3E,IAAI,CAAC,IAAY;QACf,MAAM,EAAE,GAAG,oBAAK,CAAC,KAAK,CAAC,gBAAgB,EAAE,CAAC;QAC1C,EAAE,CAAC,OAAO,GAAG,oBAAK,CAAC,IAAI,CAAC,YAAY,CAAC,IAAI,EAAE,MAAM,CAAC,CAAC;QACnD,IAAI,CAAC;YACH,EAAE,CAAC,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAC/B,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,IAAI,KAAK,CAAC,iDAAiD,CAAC,CAAC;QACrE,CAAC;QACD,EAAE,CAAC,SAAS,CAAC;YACX,uBAAuB,EAAE;gBACvB;oBACE,IAAI,EAAE,oBAAK,CAAC,GAAG,CAAC,IAAI,CAAC,WAAW;oBAChC,KAAK,EAAE,oBAAK,CAAC,GAAG,CAAC,IAAI,CAAC,IAAI;iBAC3B;gBACD;oBACE,IAAI,EAAE,oBAAK,CAAC,GAAG,CAAC,IAAI,CAAC,aAAa;iBACnC;gBACD;oBACE,IAAI,EAAE,oBAAK,CAAC,GAAG,CAAC,IAAI,CAAC,WAAW;oBAChC,KAAK,EAAE,IAAI,IAAI,EAAS;iBACzB;aACF;YACD,WAAW,EAAE,IAAI,CAAC,IAAI;YACtB,eAAe,EAAE,oBAAK,CAAC,GAAG,CAAC,IAAI,CAAC,MAAM;YACtC,GAAG,EAAE,IAAI,CAAC,GAAG;SACd,CAAC,CAAC;QACH,EAAE,CAAC,IAAI,EAAE,CAAC;QACV,MAAM,KAAK,GAAG,oBAAK,CAAC,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC;QACvD,OAAO,MAAM,CAAC,IAAI,CAAC,KAAK,EAAE,QAAQ,CAAC,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;IACzD,CAAC;CACF;AAhCD,oCAgCC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export declare class Environment {
|
|
2
|
+
readonly testCredentialsFolder: string;
|
|
3
|
+
readonly testPrivateKeyFileName: string;
|
|
4
|
+
readonly testCertFileName: string;
|
|
5
|
+
readonly nodeEnv: string;
|
|
6
|
+
constructor();
|
|
7
|
+
checkEnv(): void;
|
|
8
|
+
}
|
|
9
|
+
declare const Env: Environment;
|
|
10
|
+
export default Env;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Environment = void 0;
|
|
4
|
+
const dotenv_1 = require("dotenv");
|
|
5
|
+
class Environment {
|
|
6
|
+
constructor() {
|
|
7
|
+
(0, dotenv_1.config)();
|
|
8
|
+
this.testCredentialsFolder = process.env.TEST_CREDENTIALS_FOLDER;
|
|
9
|
+
this.testPrivateKeyFileName = process.env
|
|
10
|
+
.TEST_PRIVATE_KEY_FILE_NAME;
|
|
11
|
+
this.testCertFileName = process.env.TEST_CERT_FILE_NAME;
|
|
12
|
+
this.nodeEnv = (process.env.NODE_ENV || "local");
|
|
13
|
+
}
|
|
14
|
+
checkEnv() {
|
|
15
|
+
try {
|
|
16
|
+
if (!this.testCredentialsFolder)
|
|
17
|
+
throw new Error("TEST_CREDENTIALS_FOLDER");
|
|
18
|
+
if (!this.testPrivateKeyFileName)
|
|
19
|
+
throw new Error("TEST_PRIVATE_KEY_FILE_NAME");
|
|
20
|
+
if (!this.testCertFileName)
|
|
21
|
+
throw new Error("TEST_CERT_FILE_NAME");
|
|
22
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
23
|
+
}
|
|
24
|
+
catch (error) {
|
|
25
|
+
throw new Error(`Env parameter not defined on .env file: ${error.message}`);
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
exports.Environment = Environment;
|
|
30
|
+
const Env = new Environment();
|
|
31
|
+
exports.default = Env;
|
|
32
|
+
//# sourceMappingURL=env.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"env.js","sourceRoot":"","sources":["../../../src/infrastructure/utils/env.ts"],"names":[],"mappings":";;;AAAA,mCAAgC;AAEhC,MAAa,WAAW;IAMtB;QACE,IAAA,eAAM,GAAE,CAAC;QACT,IAAI,CAAC,qBAAqB,GAAG,OAAO,CAAC,GAAG,CAAC,uBAAiC,CAAC;QAC3E,IAAI,CAAC,sBAAsB,GAAG,OAAO,CAAC,GAAG;aACtC,0BAAoC,CAAC;QACxC,IAAI,CAAC,gBAAgB,GAAG,OAAO,CAAC,GAAG,CAAC,mBAA6B,CAAC;QAClE,IAAI,CAAC,OAAO,GAAG,CAAC,OAAO,CAAC,GAAG,CAAC,QAAQ,IAAI,OAAO,CAAW,CAAC;IAC7D,CAAC;IAED,QAAQ;QACN,IAAI,CAAC;YACH,IAAI,CAAC,IAAI,CAAC,qBAAqB;gBAC7B,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;YAC7C,IAAI,CAAC,IAAI,CAAC,sBAAsB;gBAC9B,MAAM,IAAI,KAAK,CAAC,4BAA4B,CAAC,CAAC;YAChD,IAAI,CAAC,IAAI,CAAC,gBAAgB;gBAAE,MAAM,IAAI,KAAK,CAAC,qBAAqB,CAAC,CAAC;YACnE,8DAA8D;QAChE,CAAC;QAAC,OAAO,KAAU,EAAE,CAAC;YACpB,MAAM,IAAI,KAAK,CACb,2CAA2C,KAAK,CAAC,OAAO,EAAE,CAC3D,CAAC;QACJ,CAAC;IACH,CAAC;CACF;AA7BD,kCA6BC;AAED,MAAM,GAAG,GAAG,IAAI,WAAW,EAAE,CAAC;AAE9B,kBAAe,GAAG,CAAC"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
/**
|
|
18
|
+
* Infrastructure Utils
|
|
19
|
+
* Exports all infrastructure utilities
|
|
20
|
+
*/
|
|
21
|
+
__exportStar(require("./parser"), exports);
|
|
22
|
+
__exportStar(require("./crypt-data"), exports);
|
|
23
|
+
__exportStar(require("./logger"), exports);
|
|
24
|
+
__exportStar(require("./soap-to-dto.mapper"), exports);
|
|
25
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/infrastructure/utils/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA;;;GAGG;AACH,2CAAyB;AACzB,+CAA6B;AAC7B,2CAAyB;AACzB,uDAAqC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.logger = void 0;
|
|
4
|
+
exports.createArcaLogger = createArcaLogger;
|
|
5
|
+
const winston_1 = require("winston");
|
|
6
|
+
function createArcaLogger(enableLogging = false) {
|
|
7
|
+
const logger = (0, winston_1.createLogger)({
|
|
8
|
+
format: winston_1.format.json(),
|
|
9
|
+
exitOnError: true,
|
|
10
|
+
silent: !enableLogging,
|
|
11
|
+
});
|
|
12
|
+
if (enableLogging) {
|
|
13
|
+
logger.add(new winston_1.transports.Console({
|
|
14
|
+
format: winston_1.format.combine(winston_1.format.colorize(), winston_1.format.simple()),
|
|
15
|
+
}));
|
|
16
|
+
}
|
|
17
|
+
return logger;
|
|
18
|
+
}
|
|
19
|
+
const defaultLogger = createArcaLogger(false);
|
|
20
|
+
exports.logger = defaultLogger;
|
|
21
|
+
//# sourceMappingURL=logger.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"logger.js","sourceRoot":"","sources":["../../../src/infrastructure/utils/logger.ts"],"names":[],"mappings":";;;AAEA,4CAgBC;AAlBD,qCAAmE;AAEnE,SAAgB,gBAAgB,CAAC,gBAAyB,KAAK;IAC7D,MAAM,MAAM,GAAG,IAAA,sBAAY,EAAC;QAC1B,MAAM,EAAE,gBAAM,CAAC,IAAI,EAAE;QACrB,WAAW,EAAE,IAAI;QACjB,MAAM,EAAE,CAAC,aAAa;KACvB,CAAC,CAAC;IAEH,IAAI,aAAa,EAAE,CAAC;QAClB,MAAM,CAAC,GAAG,CACR,IAAI,oBAAU,CAAC,OAAO,CAAC;YACrB,MAAM,EAAE,gBAAM,CAAC,OAAO,CAAC,gBAAM,CAAC,QAAQ,EAAE,EAAE,gBAAM,CAAC,MAAM,EAAE,CAAC;SAC3D,CAAC,CACH,CAAC;IACJ,CAAC;IAED,OAAO,MAAM,CAAC;AAChB,CAAC;AACD,MAAM,aAAa,GAAG,gBAAgB,CAAC,KAAK,CAAC,CAAC;AAEpB,+BAAM"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Parser based on node-xml2js package (https://github.com/Leonidas-from-XIV/node-xml2js).
|
|
3
|
+
*/
|
|
4
|
+
export declare class Parser {
|
|
5
|
+
static options: {
|
|
6
|
+
normalizeTags: boolean;
|
|
7
|
+
normalize: boolean;
|
|
8
|
+
explicitArray: boolean;
|
|
9
|
+
attrkey: string;
|
|
10
|
+
tagNameProcessors: ((key: string) => string)[];
|
|
11
|
+
};
|
|
12
|
+
static xmlToJson<T = Record<string, any>>(xml: string): Promise<T>;
|
|
13
|
+
static jsonToXml(obj: Record<string, any>): string;
|
|
14
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.Parser = void 0;
|
|
13
|
+
const xml2js_1 = require("xml2js");
|
|
14
|
+
/**
|
|
15
|
+
* Parser based on node-xml2js package (https://github.com/Leonidas-from-XIV/node-xml2js).
|
|
16
|
+
*/
|
|
17
|
+
class Parser {
|
|
18
|
+
static xmlToJson(xml) {
|
|
19
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
20
|
+
const parser = new xml2js_1.Parser(Parser.options);
|
|
21
|
+
return parser.parseStringPromise(xml);
|
|
22
|
+
});
|
|
23
|
+
}
|
|
24
|
+
static jsonToXml(obj) {
|
|
25
|
+
return new xml2js_1.Builder().buildObject(obj);
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
exports.Parser = Parser;
|
|
29
|
+
Parser.options = {
|
|
30
|
+
normalizeTags: true,
|
|
31
|
+
normalize: true,
|
|
32
|
+
explicitArray: false,
|
|
33
|
+
attrkey: "header",
|
|
34
|
+
tagNameProcessors: [(key) => key.replace("soapenv:", "")],
|
|
35
|
+
};
|
|
36
|
+
//# sourceMappingURL=parser.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"parser.js","sourceRoot":"","sources":["../../../src/infrastructure/utils/parser.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,mCAAsD;AAEtD;;GAEG;AACH,MAAa,MAAM;IASV,MAAM,CAAO,SAAS,CAC3B,GAAW;;YAEX,MAAM,MAAM,GAAG,IAAI,eAAS,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;YAC7C,OAAO,MAAM,CAAC,kBAAkB,CAAC,GAAG,CAAC,CAAC;QACxC,CAAC;KAAA;IAEM,MAAM,CAAC,SAAS,CAAC,GAAwB;QAC9C,OAAO,IAAI,gBAAO,EAAE,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC;IACxC,CAAC;;AAlBH,wBAmBC;AAlBQ,cAAO,GAAG;IACf,aAAa,EAAE,IAAI;IACnB,SAAS,EAAE,IAAI;IACf,aAAa,EAAE,KAAK;IACpB,OAAO,EAAE,QAAQ;IACjB,iBAAiB,EAAE,CAAC,CAAC,GAAW,EAAE,EAAE,CAAC,GAAG,CAAC,OAAO,CAAC,UAAU,EAAE,EAAE,CAAC,CAAC;CAClE,CAAC"}
|