Page 1 of 1

Web Service Element Attributes

Posted: Thu Jul 14, 2016 8:44 am
by devinst
I have created a web service provider on our Power 8 using RPG. Does anyone know of a way to receive and send element attributes when providing the service? Thanks.!!
An additional note, this is a SOAP web service.

Re: Web Service Element Attributes

Posted: Fri Jul 15, 2016 9:44 am
by Scott Klement
Are you referring to the attributes of XML elements, here?

How did you create this web service? There are hundreds of ways of providing web services, and each one is different. I can't promise to be familiar with all of them, but if you are using a method I'm familiar with, I may be able to help.

Also, if you are referring to attributes of XML elements, please clarify if you are passing an XML document as the payload of your SOAP message, or whether you are looking to use an attribute in the SOAP message itself?

Re: Web Service Element Attributes

Posted: Fri Jul 15, 2016 1:46 pm
by devinst
Scott, I am referring to the attributed within the XML element. The bellow example may better explain it than I can. I would be looking to pull in the orderType and orderNumber attributes of the OrderHeader element.
<Orders>
<Order>
<OrderHeader orderType="FREIGHT" orderNumber="123457"/>
</Order>
</Orders>

I created the RPG program then used the wizard in the application server to deploy a new service. I am not clear on your comment about the payload of the SOAP message.

Hope that help explain.

Thanks.!!

Re: Web Service Element Attributes

Posted: Fri Jul 15, 2016 6:11 pm
by Scott Klement
How did you create this web service? (Which web service tool...?)