IBM webMethods Hybrid Integration

IBM webMethods Hybrid Integration

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
  • 1.  Define XML Prefix

    Posted Fri March 12, 2021 06:31 AM

    Hi,
    I want to generate xml like below:

    <fin:getData>
    <ExternalReference>?</ExternalReference>
    </fin:getData>
    

    for SOAP request but when i generate the xml it returns Error: namespace prefix fin not defined for element getData.

    How can i defince the namespace prefix?

    Thank you


    #webMethods


  • 2.  RE: Define XML Prefix

    Posted Fri March 12, 2021 01:54 PM

    Hi Adrian,

    can you explain your request in detail please?
    Prefixes are not needed as long as using anonymus namespaces is possible.

    When you have to define such a namespace you need to specify it on the highest level node which uses it:

    <fin:top xmlns:fin="namespace declaration here">
    <fin:getData>
    ?
    </fin:getData>
    </fin:top>
    

    Regards,
    Holger


    #webMethods


  • 3.  RE: Define XML Prefix

    Posted Sat March 13, 2021 02:28 AM

    Hi Holger,

    i need a soap request with a xml like below

    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:fin="http://financial.sekuritas.pt.com/">
    <soapenv:Header/>
    <soapenv:Body>
    <fin:getData>
    
    <ExternalReference>?</ExternalReference>
    
    </fin:getData>
    </soapenv:Body>
    </soapenv:Envelope>
    

    which is the fin:getData tag is required.
    Thank you


    #webMethods


  • 4.  RE: Define XML Prefix

    Posted Mon March 15, 2021 12:45 PM

    Hi Adrain,

    please have a look at the IS Built-In-Services Reference and/or the WebService Development Guide for further informations.

    When you have an XSD or WSDL for your Service Definition you can import this via Designer to create a DocumentType for this which has the namespace definition included.

    Some services in IS public package have an input field where you can place namespace declarations as key/value pairs.
    The prefix will be the key and the namespace itself will be the value then.

    Regards,
    Holger


    #webMethods