Skip to main content

clients/soap/utils

@prismatic-io/spectral"clients/soap/utils"

Index

Functions

Functions

Const debugRequest

debugRequest(client: Client): void

Defined in packages/spectral/src/clients/soap/utils.ts:28

Optionally log out SOAP requests and responses for debugging purposes

Parameters:

NameTypeDescription
clientClientA SOAP client that generates requests and responses

Returns: void


Const describeWSDL

describeWSDL(wsdlParam: unknown): Promise‹string›

Defined in packages/spectral/src/clients/soap/utils.ts:39

This function takes either the URL of a WSDL or the XML defining a WSDL, and returns an object describing the methods and attributes defined in the WSDL.

Parameters:

NameTypeDescription
wsdlParamunknownEither the URL where a WSDL is stored, or the XML defining a WSDL.

Returns: Promise‹string›

An object containing the methods and attributes defined in a WSDL


Const generateHeader

generateHeader(wsdlParam: string | SOAPConnection, headerPayload: HeaderPayload, headerOptions: undefined | object): Promise‹string›

Defined in packages/spectral/src/clients/soap/utils.ts:175

Create a SOAP header

Parameters:

NameTypeDescription
wsdlParamstring | SOAPConnectionA SOAPConnection or XML definition of a WSDL
headerPayloadHeaderPayloadThe contents of a header XML node
headerOptionsundefined | objectAttributes for a header XML node, like namespace or xmlns

Returns: Promise‹string›


Const getSOAPAuth

getSOAPAuth(connection: Connection, wsdlDefinition?: undefined | string): Promise‹[any, any, any, any, undefined | IMTOMAttachments]

Defined in packages/spectral/src/clients/soap/utils.ts:198

Fetch authentication information for a SOAPConnection

Parameters:

NameTypeDescription
connectionConnectionThe SOAPConnection
wsdlDefinition?undefined | stringThe XML WSDL definition

Returns: Promise‹[any, any, any, any, undefined | IMTOMAttachments]


Const getSOAPClient

getSOAPClientT›(wsdlParam: T): Promise‹Client›

Defined in packages/spectral/src/clients/soap/utils.ts:73

Create a SOAP client given a WSDL or SOAPConnection

Type parameters:

T: string | SOAPConnection

Parameters:

NameTypeDescription
wsdlParamTa SOAPConnection or XML defining a WSDL

Returns: Promise‹Client›

An HTTP client configured to query a SOAP-based API


Const getWSDL

getWSDL(wsdlDefinitionURL: string): Promise‹string›

Defined in packages/spectral/src/clients/soap/utils.ts:59

Fetch a WSDL from a URL

Parameters:

NameTypeDescription
wsdlDefinitionURLstringThe URL where the WSDL is stored

Returns: Promise‹string›

The WSDL's raw XML


Const overrideClientDefaults

overrideClientDefaults(client: Client, overrides: ClientOverrides): void

Defined in packages/spectral/src/clients/soap/utils.ts:113

Override some HTTP client defaults

Parameters:

NameTypeDescription
clientClientThe client to override
overridesClientOverridesAn endpoint URL or SOAP headers to override

Returns: void


Const soapRequest

soapRequest(__namedParameters: object, methodParams?: unknown): Promise‹[any, any, any, any, undefined | IMTOMAttachments]

Defined in packages/spectral/src/clients/soap/utils.ts:134

Make a request to a SOAP-based API

Parameters:

__namedParameters: object

NameType
debugundefined | false | true
methodstring
overridesundefined | ClientOverrides
wsdlParamstring | SOAPConnection

Optional methodParams: unknown

Parameters to pass to the specified SOAP method

Returns: Promise‹[any, any, any, any, undefined | IMTOMAttachments]

The results from the SOAP request, including the full XML of the request and response