Invoke

<< Fare clic per visualizzazione il sommario >>

Percorso:  API di piattaforma > Altri servizi > Soap >

Invoke

Service

Soap

 

Method

Invoke

 

Description

Invokes a WSDL operation returning a Dataset.

 

Input

Name

Description

Type

Optional

wsdlUrl

Url of the service WSDL (ex.: “http://www.webservicex.net/CurrencyConvertor.asmx?WSDL”); see remarks.

String

 

serviceAddress

Service address, if different from the address contained in the wsdlUrl or in the WSDL (ex.: “http://www.webservicex.net/CurrencyConvertor.asmx”); see remarks.

String

 

wsdlStream

A reference of an attachment containing WSDL: it is needed only if the wsdlUrl is null or empty; see remarks.

Reference

 

operationName

Operation name (ex.: “ConversionRate”).

String

 

soapHeaderName

Custom header name (ex.: “AuthHeader”).

String

 

soapHeaderValues

Dataset containing Key/Value pairs of the custom header properties (ex. [“UserName”/”test”], [“PassWord”/”test”]) (Defaults to the “SoapHeaderValues” configuration field, if specified).

Dataset

 

parameters

Dataset containing Key/Value pairs of the operation parameters (ex. [“FromCurrency”, “EUR”], [“ToCurrency”, “USD”]); for parameters of type “base64Binary” (byte array) a Stream value can be used, and it will be automatically converted as needed.

Dataset

 

fieldToReturn

Name of the root field to return (optional) (ex.: “ConversionRateResult”): if the type of the field to return is a Dictionary(string, object), its Key/Value pairs will be put in the returned Dictionary; if the type of the field to return is NOT a Dictionary(string, object), the returned Dictionary will contain a Key/Value pair with the name and value of the specified field.

String

 

fieldsToDiscard

A list containing the names of fields to discard from the resulting Dictionary (at any level); a null or empty list implies that all fields (from the root field) are returned.

List of string

 

valuesIfNull

A Key/Value pair collection containing values to assign to the specified fields if their returned value is null.

Ex.: if valuesIfNull contains

“first_name”, “”

“trim_user”, false

the returned dataset will have any field named “first_name” (at any level) valued with “” instead of null, and any field named “trim_user” (at any level) valued with false instead of null.

Dataset

 

userAgent

The user-agent header value (ex.: “.NET Framework Test Client”). (Defaults to the “UserAgent” configuration field, if specified).

String

 

timeout

The number of milliseconds to wait before the request times out. (Defaults to the “Timeout” configuration field, if specified, otherwise to 100000 [100 seconds]).

Int

 

credentialsType

Type of the authentication credentials associated with the request:

1 = None (network credentials not required)

2 = NetworkCredentials (“userName” and “password” must be specified)

3 = DefaultNetworkCredentials (the network credentials of the current security context)

4 = DefaultCredentials (the system credentials of the application)

5 = WSSE Security ("UserName" and "Password" must be specified).

(Defaults to the “CredentialsType” configuration field, if specified, otherwise to 1 [None])

Int

 

userName

User name (required if “CredentialsType” = 2 or “CredentialsType” = 5).

(Defaults to the “UserName” configuration field, if specified).

String

 

password

Password (required if “CredentialsType” = 2 or “CredentialsType” = 5).

(Defaults to the “Password” configuration field, if specified).

String

 

Output

Name

Description

Type

Optional

returnValue

A dataset containing the fields contained in the soap:Header and soap:Body nodes of the Xml structure returned by the SOAP invocation. Fields defined of type “base64Binary” in the WSDL will be returned as Stream values.

Dataset

 

 

Remarks

Service address: it is taken (in order of priority) from the serviceAddress parameter, from the address specified in the WSDL or from the wsdlUrl. WSDL: it is taken (in order of priority) from the wsdlUrl or from the wsdlStream parameter; the wsdlUrl parameter can contain the url to download the wsdl from the service (ex.: “http://www.webservicex.net/CurrencyConvertor.asmx?WSDL”) or a file url to download it from the file system (ex.: “C:\CurrencyConvertor\CurrencyConvertorWsdl.xml” or “file:///C:/CurrencyConvertor/CurrencyConvertorWsdl.xml” or “file://loaclhost/C:/CurrencyConvertor/CurrencyConvertorWsdl.xml”).