Configure Custom SOAP Headers for the SOAP Adapter

Oracle Integration supports adding custom SOAP headers that are not defined in the WSDL definition provided on the Connection page. You add custom headers by uploading a schema on the Custom SOAP Headers tab on the Request Headers page and/or Response Headers page, respectively, of the Adapter Endpoint Configuration Wizard.

Add Custom SOAP Headers

Configure custom SOAP headers and specify a valid schema from which an element can be selected as a custom SOAP header in the Adapter Endpoint Configuration Wizard:

  1. On the Header page, select Yes for Do you want to configure headers for this Endpoint?.

  2. For What types of Headers do you want to configure, select Custom SOAP Headers in the Request Headers and Response Headers columns, as applicable.
    Description of custom_header.png follows
    Description of the illustration custom_header.png

  3. On the Request page and/or Response page, upload a valid schema from which an element can be selected as a custom SOAP header. Note the following restrictions on schemas to upload.

    • The schema to upload must have a targetNamespace.

    • Endpoints that expect custom SOAP headers without a namespace are not supported.

    • Ensure the schema is defined with elementFormDefault as qualified (for child elements with a namespace prefix) or unqualified (for child elements without a namespace prefix), as required.

    • A schema with dependencies (imports/includes/cross references) is not supported. See Example Schemas.

    • Only one element can be selected as a header from the uploaded schema. To select multiple elements:
      • For the same targetNamespace, a schema must be uploaded again for each element.

      • For a different targetNamespace, a different schema with required targetNamespace can be used.

  4. Select the required element from the list of elements displayed from the uploaded schema.

  5. Click Add Header to add the element to the configured headers table.

Delete Custom SOAP Headers

  1. On the Request and/or Response page, select the check box next to the required header element in the configured headers table.

  2. Click Delete Header to remove the element from the configured headers table.

Example Schemas

The following schema includes a targetNamespace. A prefix for a child is required.

Schema XML
<xsd:schema elementFormDefault="qualified"
targetNamespace="http://xmlns.oracle.com/ 
sample" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <xsd:element name="headerRoot">
    <xsd:complexType>
      <xsd:sequence>
        <xsd:element name="headerChild" type="xsd:string"/>
      </xsd:sequence>
    </xsd:complexType>
  </xsd:element>
</xsd:schema>
<hdr:headerRoot xmlns:hdr=http://xmlns.oracle.com/sample>
<hdr:headerChild>headerValue</hdr:headerChild>
</hdr:headerRoot >

The following schema includes a targetNamespace. A prefix for a child is not required.

Schema XML
<xsd:schema elementFormDefault="unqualifi
ed" targetNamespace="http://xmlns.oracle.
com/sample" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <xsd:element name="headerRoot">
    <xsd:complexType>
      <xsd:sequence>
        <xsd:element name="headerChild" type="xsd:string"/>
      </xsd:sequence>
    </xsd:complexType>
  </xsd:element>
</xsd:schema>
<hdr:headerRoot xmlns:hdr=http://xmlns.oracle.com/sample>
<headerChild>headerValue</headerChild>
</hdr:headerRoot >