Discussions
Stay up-to-date with the latest news from NetSuite. You’ll be in the know about how to connect with peers and take your business to new heights at our virtual, in-person, on demand events, and much more.
New AI Community Guidelines. Please review and follow them to ensure AI use stays safe, accurate, and compliant.
Keep an eye out for upcoming NetSuite events, including meetups, workshops, and webinars. These sessions are a great way to connect with peers, learn from experts, and stay current on the latest NetSuite updates and best practices. Registration links are provided in each event.
Sample Script: How to make an external web service (SOAP) call
Background
This example uses the StrikeIron Address Verification web service to validate an address.
The SOAP request is constructed in JavaScript based on the WSDL for this web service. nlapiRequestURL is used
to make the external callout and the return values are extracted from the SOAP-formatted XML response using some
of the built-in XPath SuiteScript functions.
SOAP Protocol
Sample Request (SOAP Interface)
Address: 2955 Campus Dr, Suite 175, San Mateo, CA, 94403
<?xml version="1.0" encoding="utf-8"?> <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:s="http://www.w3.org/2001/XMLSchema
0