Some type declarations are missing
I generate a SOAP client from WSDL files. Archive with wsdl files here
Run it as:
npx wsdl-tsclient ./resources/elhub_wsdl/v2/wsdl/PollMeteringValues.wsdl -o ./generated/ --verbose
A SOAP client is generated successfully but not all the type definitions are generated.
For example, there is a PollForData interface where all properties are strings, but I expect to have real types instead (they are declared in comments above the property).
/**
* PollForData
* @targetNSAlias `rsm`
* @targetNamespace `urn:no:elhub:emif:PollForData:v2`
*/
export interface PollForData {
/** Elhub_HeaderType */
Header?: string;
/** Elhub_EnergyContextType */
ProcessEnergyContext?: string;
/** Elhub_PollForData */
Payload?: string;
}
There is a chain of includes/imports in WSDL to bring these types in.
-
PollMeteringValues.wsdlincludexsd/PollMeteringValues.xsd -
xsd/PollMeteringValues.xsdimport../../bim/PollForData.xsd -
../../bim/PollForData.xsdimportcommon/Elhub_AggregatedBusinessInformationEntities.xsd
The last file has a declarations for Elhub_HeaderType, Elhub_EnergyContextType, Elhub_PollForData.
My colleague was able to generate .NET client based on these WSDL files, so they should be fine. Most likely something wrong with wsdl-tsclient or my configuration for it.
Does anyone have an idea how to solve it?
I am having similar issues
I am generating a client from an Amadeus WSDL(it's a travel soap API). In my generated files I am missing many types. I have tried many permutations of the options to no avail. When I look into the WSDL everything is typed out properly however in my client it seems to be missing a lot of them.