UNPKG

@dgac/nmb2b-client

Version:

EUROCONTROL Network Manager B2B SOAP client

28 lines (26 loc) 982 B
import { prepareSecurity } from "../security.js"; import { getWSDLPath } from "../constants.js"; import { deserializer } from "../utils/transformers/index.js"; import { prepareQueryNMB2BWSDLs } from "./queryNMB2BWSDLs.js"; import { prepareRetrieveUserInformation } from "./retrieveUserinformation.js"; import { createClientAsync } from "soap"; //#region src/GeneralInformation/index.ts async function getGeneralInformationClient(config) { const WSDL = getWSDLPath({ service: "GeneralinformationServices", flavour: config.flavour, XSD_PATH: config.XSD_PATH }); const security = prepareSecurity(config); const client = await createClientAsync(WSDL, { customDeserializer: deserializer }); client.setSecurity(security); return { __soapClient: client, config, queryNMB2BWSDLs: prepareQueryNMB2BWSDLs(client), retrieveUserInformation: prepareRetrieveUserInformation(client) }; } //#endregion export { getGeneralInformationClient }; //# sourceMappingURL=index.js.map