项目作者: kratoon3

项目描述 :
Force.com Metadata WSDL parser and types generator
高级语言: TypeScript
项目地址: git://github.com/kratoon3/salesforce-wsdl-consumer.git
创建时间: 2019-12-05T17:50:20Z
项目社区:https://github.com/kratoon3/salesforce-wsdl-consumer

开源协议:Apache License 2.0

下载


salesforce-wsdl-consumer

npm version

Simple Force.com Metadata WSDL parser and types generator.

WARNING: this project is not stable yet and any API can change.

The result of the parser is an object containing ComplexTypes and SimpleTypes.
On top of this parser is built a types generator.
You can see the resulting
types
in another project.

If you need already generated types
or read/write metadata files,
you can use the
salesforce-metadata
project published to npm instead.

Usage

  1. generateTypesFromMetadataWSDL({
  2. outputFile: "types.ts",
  3. metadataVersion: "47"
  4. });

You can also import the LATEST_METADATA_VERSION constant.

To read MetadataWSDL, you have two options,
readMetadataWSDLByVersion and readMetadataWSDLFromPath.
Then parse types using parseMetadataWSDL function.

  1. readMetadataWSDLByVersion("47")
  2. .then(parseMetadataWSDL)
  3. .then(({complexTypes, simpleTypes}: ParsedMetadataWSDL) => {});