Compatibility for clients generated from WSDL

Review these guidelines for service namespaces.

Specifying a Unique Namespace for each Table

The property glide.wsdl.definition.use_unique_namespace ensures that each table's Direct Web Service WSDL has a unique targetNamespace attribute. This property is true by default, which requires a table's Direct Web Service WSDL to use a targetNamespace value of<table name>. When false (or when the property is not present), all tables use the same targetNamespace value of Since all tables also share the same operation names, a Web Service client attempting to consume more than one ServiceNow Web Service would be unable to differentiate between requests between multiple tables. Using a unique targetNamespace value allows Web Services clients to distinguish requests between multiple tables.

For example, the DIrect Web Service WSDL for the incident table uses this targetNamepsace value.

<wsdl:definitions xmlns:soapenc= ""xmlns:wsdl = ""xmlns:http = ""xmlns:tns = ""xmlns:xsd = ""xmlns:mime = ""xmlns:soap = ""targetNamespace = "" ><wsdl:types><xsd:schema elementFormDefault = "unqualified"targetNamespace = "" >

Setting Namespace Requirements

ServiceNow's WSDL schema by default declares an attribute of elementFormDefault="unqualified". This attribute indicates whether or not locally declared elements must be qualified by the target namespace in an instance document. If the value of this attribute is 'unqualified', then locally declared elements should not be qualified by the target namespace. If the value of this attribute is 'qualified', then locally declared elements must be qualified by the target namespace.

However, this is incompatible with the way clients generated from WSDL (.NET, Axis2, webMethods, ect.) process the embedded schema, it removes the schema namespace as a result, making the web service response unparseable.

To overcome this compatibility issue, a boolean property called glide.wsdl.schema.UnqualifiedElementFormDefault is introduced. This property has the value of true by default, setting it to false will make clients generated from WSDL able to parse the return value of the web service invocation. You can modify this property using the Web Services properties page at System Properties > Web Services.

By default, service names from dynamically generated WSDL are unique and have the following format:

ServiceNow_<table name>

To allow duplicate service names, administrators can set the glide.wsdl.unique_service_name property to false. Create the property if it does not exist.