Open MiseCZ opened 7 years ago
@MiseCZ
First, we are not creating api-json as just a proxy from JSON format to SOAP. Also we are trying to simplify life for developers. As booking was created through AirService it's logical to get the reservation via AirService rather than using another one. That's why we would like to see booking retrieve function as part of AirService
Next, in my opinion it's better to have separate templates for separate functions. I'd like to hear @shmuga on this.
Also I would like you to ask you to create a separate issue for each of the requests you have described. In each ticket it would be nice to see interface description: input params and output data.
@dchertousov
I understand that uapi-json takes two responsibilities:
I would highly recommend to separate this two responsibilities on architectonic level too.
Right now I'm trying to understand how to implement AirMerchandising in this integrated concept. I will create separate issues for implementation.
So 2nd take on the AirMerchandising:
AirService.services(params)
method. AirParser.AIR_PRICE_REQUEST()
and AirParser.AIR_PRICE_REQUEST_PRICING_SOLUTION_XML()
but with new and possibly very complicated structures for OptionalServices.AIR_PRICE_REQ_OPTIONAL_SERVICES.xml
.AirService.bookService(params)
method.AIR_MERCHANDISING_FULLFILMENT.xml
.AirService.issueEMD(params)
method.EMD_ISSUANCE.xml
AirService.seatMap(params)
method.SEAT_MAP.xml
.AirService.importPNR()
should be used?Again: I'm just trying to verify overall concept. I will create issues for every request after you'll confirm it's a right way to go.
Hello, @MiseCZ! Hope, you do still have plans to include this functionality into library.
For booking OptionalServices through UAPI we need these requests:.
For AirPriceReq
We need to specify AirSegments, SearchPasseners, AirPricingCommand and FormOfPayment like this:
I believe we could either extend one of the two current templates (AIR_PRICE_REQ.xml and AIR_PRICE_REQ_MANUAL.xml) or introduce third one (AIR_PRICE_REQ_OPTIONAL_SERVICES.xml ).
We will also need to parse more data from response. All OptionalServices information which is pretty complex. That's similar situation as with templates. But I believe we need something like AirPrice.AIR_PRICE_REQUEST_OPTIONAL_SERVICES_XML.
I'm also little hesitant about public API.
AirService.services(params) => Promise
Seems like first choice possibility, but It seems to me that this function will be little more complex than other
AirService
functions.AirMerchandisingFullfilmentReq, EMDIssuanceReq, SeatMapReq requests
I believe they are all new ones and their adding into AirService seems natural. Again maybe they are somewhat more advanced than basic shop(), book() and ticket() functionality.
UniversalRecordRetrieveReq request
Here I'm little bit puzzled because I would expect this request to be part of currently non-existing UniversalRecordService (according to: https://support.travelport.com/webhelp/uapi/uAPI.htm#Getting_Started/Easy_Overview/Complete_Services_List.htm%3FTocPath%3DGetting%2520Started%7CGetting%2520Connected%7C_____4).
But I discovered that there currently is UNIVERSAL_RECORD_CANCEL_UR.xml which is part of AirService and that is not according to afforementioned document.
What would you think?