Note: There is a newer version (2.3.0) of this package available. Click here to view docs for the latest version.
Ballerina library
soap.soap12
Modules
Module soap.soap12
ballerina/soap.soap12 Ballerina library
2.2.0
Clients
soap.soap12: Client
Isolated
Object for the basic SOAP 1.2 client endpoint.
Constructor
Gets invoked during object initialization.
init (string url, *ClientConfig config)- url string - URL endpoint
- config *ClientConfig - Configurations for SOAP client
sendReceive
Isolated FunctionRemote Function
function sendReceive(xml|Entity[] body, string? action, map<string|string[]> headers, string path, typedesc<xml|Entity[]> T) returns T|ErrorSends SOAP request and expects a response.
xml response = check soapClient->sendReceive(body); -- OR -- mime:Entity[] response = check soapClient->sendReceive(body);
Parameters
- body xml|Entity[] - SOAP request body as an
XMLormime:Entity[]to work with SOAP attachments
- action string? (default ()) - SOAP action as a
string
- path string (default "") - The resource path
Return Type
- T|Error - If successful, returns the response. Else, returns an error
sendOnly
Isolated FunctionRemote Function
function sendOnly(xml|Entity[] body, string? action, map<string|string[]> headers, string path) returns Error?Fires and forgets requests. Sends the request without the possibility of any response from the service (even an error).
check soapClient->sendOnly(body);
Parameters
- body xml|Entity[] - SOAP request body as an
XMLormime:Entity[]to work with SOAP attachments
- action string? (default ()) - SOAP action as a
string
- path string (default "") - The resource path
Return Type
- Error? - If successful, returns
nil. Else, returns an error
Errors
soap.soap12: Error
Distinct
Defines the common error type for the SOAP 1.2 module.
Import
import ballerina/soap.soap12;Metadata
Released date: 11 months ago
Version: 2.2.0
License: Apache-2.0
Compatibility
Platform: java21
Ballerina version: 2201.11.0-20241209-162400-0c015833
GraalVM compatible: Yes
Pull count
Total: 0
Current verison: 0
Weekly downloads
Keywords
soap
Contributors