Searching the Help
To search for information in the Help, type a word or phrase in the Search box. When you enter a group of words, OR is inferred. You can use Boolean operators to refine your search.
Results returned are case insensitive. However, results ranking takes case into account and assigns higher scores to case matches. Therefore, a search for "cats" followed by a search for "Cats" would return the same number of Help topics, but the order in which the topics are listed would be different.
Search for | Example | Results |
---|---|---|
A single word | cat
|
Topics that contain the word "cat". You will also find its grammatical variations, such as "cats". |
A phrase. You can specify that the search results contain a specific phrase. |
"cat food" (quotation marks) |
Topics that contain the literal phrase "cat food" and all its grammatical variations. Without the quotation marks, the query is equivalent to specifying an OR operator, which finds topics with one of the individual words instead of the phrase. |
Search for | Operator | Example |
---|---|---|
Two or more words in the same topic |
|
|
Either word in a topic |
|
|
Topics that do not contain a specific word or phrase |
|
|
Topics that contain one string and do not contain another | ^ (caret) |
cat ^ mouse
|
A combination of search types | ( ) parentheses |
|
- Consume an external Web Service
- Use the WSDL2JS utility
- Best practices for writing a JavaScript to consume a Web Service
- Date/Time handling
- Example: Interface to another system
- Web Services with a proxy server
- Connecting to a secure Web Service
- Use SSL connections to connect to an external Web Service
- Web Services connections through a firewall
Connecting to a secure Web service
If you are consuming a secure Web service that requires mutual authentication from Service Manager application using Javascript and WSDL2JS, follow these steps:.
If you are consuming an SSL-protected Web service using Javascript in SM 7x, which uses java.xml.soap.SOAPConnection to send the request, the SSL configuration is done using Java key stores. Refer to the documentation for the list of sm.ini parameters required for SSL configuration.
When you consume a secure Web service or Web site from JavaScript all you need to do is use an https:// URL. There are no facilities for configuring SSL in WSDL2JS or in your script. The SSL communication that is initiated by the WSDL2JS-generated code relies on the SSL configuration that is in place for the server itself. The Service Manager server’s server certificate in effect becomes the client certificate for the outbound request.
To supply a Basic Authorization header when consuming a Web service using JavaScript generated by WSDL2JS, basic authentication is supplied automatically if you supply userid and password values on the service object generated by WSDL2JS as shown in the below example:
var service = new system.library.IncidentManagement. IncidentManagement(); service.user = "falcon"; service.password = ""; ...
If on the other hand, you are coding a REST-style GET directly in your script, you need to code it manually, because you have to code the HTTP request yourself. Add the following style code in the JavaScript to perform this:
// HTTP GET example with Basic Auth header var headers = new Array(); try { if ( result.userid != undefined ) { var authHeader = new Header(); authHeader.name = "Authorization"; authHeader.value = "Basic " + base64Encode ( result.userid + ":" + result.password ); headers.push( authHeader ); } strWSDLsrc = doHTTPRequest( "GET", wsdlURL, headers, null, 10, 10, 10 ); } catch( e ) { print( "WSDL request failed with exception " + e ); ... }
We welcome your comments!
To open the configured email client on this computer, open an email window.
Otherwise, copy the information below to a web mail client, and send this email to docs.feedback@hpe.com.
Help Topic ID:
Product:
Topic Title:
Feedback: