[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Web service help



Something like 16 looks like a good place to start. 

To my eye, it is borderline between doing it yourself and using some helpers (WSDL2RPG). The makers of the service did a terrible job of naming elements. Calling everything record and value and then having attributes describe the field makes it messier than it has to be.

If it were me...I think I would give it a shot doing it manually. If you look at in an indented view (IE), you will see that there are sections of code for request. You can definitely and easily build those in RPGLE. Tack them together and send the request.

For processing the reply...I think I'd stick with retrieving into the IFS and processing it from there. It looks like you will be doing attribute parsing and tracking and also some image manipulation so I personally would want to be able to play with that until I got it right. The data is not overly complicated or convoluted. There is an example of attribute parsing in one of the examples that will help you with that. 

-----Original Message-----
From: ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx [mailto:ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx] On Behalf Of Max Buda
Sent: Monday, December 8, 2014 4:45 PM
To: HTTPAPI and FTPAPI Projects
Subject: Re: Web service help

Mike, thanks for your response.
I have created and run some of the examples.  I do have a high level conceptual understanding.
I have reviewed the various examples and found that Example 16 is probably the closest.
I do not have a UPS account, so I was not able to get the required user ID and password.

My only concern, again, is the amount of data being exchanged and not wanting to hard-code all of the tags in the program.

I have attached 2 xml documents containing examples I was provided for a request and a response.
Let me know if that's not what you are looking for.


Thanks

Max Buda


On Mon, Dec 8, 2014 at 3:33 PM, Mike Krebs <mkrebs@xxxxxxxxxxxxxxxxxx>
wrote:

> Which example most closely resembles what you want to do?
>
> If you haven't yet, try to setup  and run the examples working your 
> way up from 1. Each program is a mini tutorial and will give you the 
> basics of that particular approach and will teach you how HTTPAPI 
> works so you will understand how to debug, how to check for errors, 
> and what some of the APIs do and how they work.
>
> If you share the information you have been given, we can advise you on 
> if the web service is "easy" or complex. Otherwise, I would just be 
> shooting the dark in giving you advise on where to start.
>
> -----Original Message-----
> From: ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx [mailto:
> ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx] On Behalf Of Max Buda
> Sent: Monday, December 8, 2014 2:45 PM
> To: ftpapi@xxxxxxxxxxxxxxxxxxxxxx
> Subject: Re: Web service help
>
> >
> > Let me start by saying I am new to web services and this list.
> > Any help and assistance is greatly appreciated.
> >
> > I need to create a program to make a web service request and capture 
> > the returned data.
> > I have been provided with a sample XML for the request, a sample XML 
> > for the response and finally the WSDL.
> >
> > Which of the provided examples (HTTP API) should I use as a starting 
> > point for my program ?
> > Since there is lots of data being exchanged, what's the best 
> > approach when formulating the request, to limit hard-coding in the program ?
> > And similarly, what's the best approach for managing the response 
> > while limiting hard-coding ?
> >
> >
> >
> > Thanks
> >
> > Max Buda
> >
> >
> ----------------------------------------------------------------------
> - This is the FTPAPI mailing list.  To unsubscribe, please go to:
> http://www.scottklement.com/mailman/listinfo/ftpapi
> ----------------------------------------------------------------------
> -
>
-----------------------------------------------------------------------
This is the FTPAPI mailing list.  To unsubscribe, please go to:
http://www.scottklement.com/mailman/listinfo/ftpapi
-----------------------------------------------------------------------