You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 7 Current »

Overview

An example of end-to-end scenario based on on operation flow and user story


Operation flow

book (Flight) → read (booking)

User story

S7 agent wants to book one way flight from Moscow (DME) to Samara (KUF) for one adult traveler. Then S7 agent wants to read reservation to get reservation details.

Scenario

The general process for book a trip and read reservation details such as this is:

  1. Book a reservation: S7 Agent executes a book operation with passenger details and itinerary info of chosen solution from search results;

  2. Read reservation details: S7 Agent executes a read operation itinerary info of reservation PNR.

Table of contents:


Before you can send a request to S7 Agent API, you must get an SSL certificate and configure your software.


Step 1: Book a reservation

S7 Agent executes a book operation with passenger details and itinerary info of chosen solution from search results.

<DetailedFlightItem> block consists of journey information, where each slice is described by the <OriginDestination> element.

<OriginDestination>  block takes from appropriate AirShoppingRS

(lightbulb) Segments (Flight) must be devided into slices (OriginDestination):

  • one OriginDestination for One Way trip;

  • two for Round Trip and more for MultiCity;

  • for Transfer Trip all segments included in one slice have to be pass in one OriginDestination;

  • for Transfer Trip segments with stopover between have to be divided into two OriginDestination.

Envelope/Body/AirShoppingRS/DataLists/FlightSegmentList

and <ClassOfService> (RBD) from

Envelope/Body/AirShoppingRS/OffersGroup/AirlineOffers/AirlineOffer/PricedOffer/OfferPrice/RequestedDate/Associations/ApplicableFlight/FlightSegmentReference/ClassOfService/Code

<Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/">
    <Header />
    <Body>
        <OrderCreateRQ Version="" xmlns="http://www.iata.org/IATA/EDIST">
            <Document />
            <Party>
                <Sender>
                    <AgentUserSender>
                        <Name>S7-AIDL</Name>
                        <OtherIDs>
                            <OtherID Description="POS_Type">1</OtherID>
                            <OtherID Description="requestorType">U</OtherID>
                        </OtherIDs>
                        <PseudoCity>OVBS728AB</PseudoCity>
                        <AgentUserID>S7AgentAPI</AgentUserID>
                        <UserRole>AS</UserRole>
                    </AgentUserSender>
                </Sender>
            </Party>
            <Query>
                <Passengers>
                    <Passenger ObjectKey="SH1">
                        <PTC>ADT</PTC>
                        <Age>
                            <BirthDate>1992-02-27</BirthDate>
                        </Age>
                        <Name>
                            <Surname>Pilatus</Surname>
                            <Given>Pontius</Given>
                            <Title>MR</Title>
                        </Name>
                        <Contacts>
                            <Contact>
                                <EmailContact>
                                    <Address>r.tkachuk@s7.ru</Address>
                                </EmailContact>
                                <PhoneContact>
                                    <Number CountryCode="7" AreaCode="999">9999999</Number>
                                </PhoneContact>
                            </Contact>
                        </Contacts>
                        <Gender>Male</Gender>
                        <PassengerIDInfo>
                            <PassengerDocument>
                                <Type>PP</Type>
                                <ID>111111111</ID>
                                <BirthCountry>RU</BirthCountry>
                                <DateOfIssue>2012-02-27</DateOfIssue>
                                <DateOfExpiration>2030-02-27</DateOfExpiration>
                                <CountryOfResidence>RU</CountryOfResidence>
                            </PassengerDocument>
                        </PassengerIDInfo>
                    </Passenger>
                </Passengers>
                <OrderItems>
                    <ShoppingResponse>
                        <Owner>S7</Owner>
                        <ResponseID>UNKNOWN</ResponseID>
                        <Offers>
                            <Offer>
                                <OfferID Owner="S7">UNKNOWN</OfferID>
                                <OfferItems>
                                    <OfferItem>
                                        <OfferItemID Owner="S7">UNKNOWN</OfferItemID>
                                        <Passengers>
                                            <PassengerReference>SH1</PassengerReference>
                                        </Passengers>
                                        <ApplicableFlight>
                                            <FlightReferences>FL1</FlightReferences>
                                        </ApplicableFlight>
                                    </OfferItem>
                                </OfferItems>
                            </Offer>
                        </Offers>
                    </ShoppingResponse>
                    <OfferItem>
                        <OfferItemID Owner="S7">UNKNOWN</OfferItemID>
                        <OfferItemType>
                            <DetailedFlightItem>
                                <OriginDestination>
                                    <Flight>
                                        <SegmentKey>FL1</SegmentKey>
                                        <Departure>
                                            <AirportCode>DME</AirportCode>
                                            <Date>2019-09-20</Date>
                                            <Time>12:25</Time>
                                        </Departure>
                                        <Arrival>
                                            <AirportCode>KUF</AirportCode>
                                            <Date>2019-09-20</Date>
                                            <Time>15:10</Time>
                                        </Arrival>
                                        <MarketingCarrier>
                                            <AirlineID>S7</AirlineID>
                                            <FlightNumber>33</FlightNumber>
                                        </MarketingCarrier>
                                        <OperatingCarrier>
                                            <AirlineID>S7</AirlineID>
                                            <FlightNumber>33</FlightNumber>
                                        </OperatingCarrier>
                                        <ClassOfService>
                                            <Code>Y</Code>
                                        </ClassOfService>
                                    </Flight>
                                </OriginDestination>
                            </DetailedFlightItem>
                        </OfferItemType>
                    </OfferItem>
                </OrderItems>
            </Query>
        </OrderCreateRQ>
    </Body>
</Envelope>

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ns2:Envelope xmlns:ns2="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns3="http://www.iata.org/IATA/EDIST">
    <ns2:Body>
        <ns3:OrderViewRS Version="">
            <ns3:Document>
                <ns3:Name>1.0</ns3:Name>
            </ns3:Document>
            <ns3:Success/>
            <ns3:Response>
                <ns3:OrderViewProcessing/>
                <ns3:Passengers>
                    <ns3:Passenger ObjectKey="SH2">
                        <ns3:PTC Quantity="1">ADT</ns3:PTC>
                        <ns3:Age>
                            <ns3:BirthDate>1992-02-27</ns3:BirthDate>
                        </ns3:Age>
                        <ns3:Name>
                            <ns3:Surname>pilatus</ns3:Surname>
                            <ns3:Given>pontius</ns3:Given>
                            <ns3:Title>MR</ns3:Title>
                            <ns3:Middle/>
                        </ns3:Name>
                        <ns3:Contacts>
                            <ns3:Contact>
                                <ns3:EmailContact>
                                    <ns3:Address>r.tkachuk@s7.ru</ns3:Address>
                                </ns3:EmailContact>
                                <ns3:PhoneContact>
                                    <ns3:Number CountryCode="7">9999999999</ns3:Number>
                                </ns3:PhoneContact>
                            </ns3:Contact>
                        </ns3:Contacts>
                        <ns3:Gender>Male</ns3:Gender>
                        <ns3:PassengerIDInfo>
                            <ns3:PassengerDocument>
                                <ns3:Type>PP</ns3:Type>
                                <ns3:ID>111111111</ns3:ID>
                                <ns3:BirthCountry>RU</ns3:BirthCountry>
                                <ns3:DateOfExpiration>2030-02-27</ns3:DateOfExpiration>
                                <ns3:CountryOfResidence>RU</ns3:CountryOfResidence>
                            </ns3:PassengerDocument>
                        </ns3:PassengerIDInfo>
                    </ns3:Passenger>
                </ns3:Passengers>
                <ns3:Order>
                    <ns3:OrderID Owner="S7">1</ns3:OrderID>
                    <ns3:BookingReferences>
                        <ns3:BookingReference>
                            <ns3:ID>UXX22O</ns3:ID>
                            <ns3:AirlineID>S7</ns3:AirlineID>
                        </ns3:BookingReference>
                    </ns3:BookingReferences>
                    <ns3:TimeLimits>
                        <ns3:PaymentTimeLimit DateTime="2019-03-05T19:14:58"/>
                    </ns3:TimeLimits>
                    <ns3:OrderItems>
                        <ns3:OrderItem>
                            <ns3:FlightItem>
                                <ns3:OriginDestination>
                                    <ns3:Flight>
                                        <ns3:SegmentKey>FL1</ns3:SegmentKey>
                                        <ns3:Status>
                                            <ns3:StatusCode>
                                                <ns3:Code>HK</ns3:Code>
                                            </ns3:StatusCode>
                                        </ns3:Status>
                                        <ns3:Departure>
                                            <ns3:AirportCode>DME</ns3:AirportCode>
                                            <ns3:Date>2019-09-20</ns3:Date>
                                            <ns3:Time>12:25</ns3:Time>
                                        </ns3:Departure>
                                        <ns3:Arrival>
                                            <ns3:AirportCode>KUF</ns3:AirportCode>
                                            <ns3:Date>2019-09-20</ns3:Date>
                                            <ns3:Time>15:10</ns3:Time>
                                        </ns3:Arrival>
                                        <ns3:MarketingCarrier>
                                            <ns3:AirlineID>S7</ns3:AirlineID>
                                            <ns3:FlightNumber>33</ns3:FlightNumber>
                                        </ns3:MarketingCarrier>
                                        <ns3:OperatingCarrier>
                                            <ns3:AirlineID>S7</ns3:AirlineID>
                                            <ns3:FlightNumber>33</ns3:FlightNumber>
                                        </ns3:OperatingCarrier>
                                        <ns3:CabinType>
                                            <ns3:Code>Y</ns3:Code>
                                        </ns3:CabinType>
                                        <ns3:ClassOfService>
                                            <ns3:Code>Y</ns3:Code>
                                        </ns3:ClassOfService>
                                    </ns3:Flight>
                                </ns3:OriginDestination>
                            </ns3:FlightItem>
                            <ns3:Associations>
                                <ns3:Passengers>
                                    <ns3:PassengerReferences>SH2</ns3:PassengerReferences>
                                </ns3:Passengers>
                            </ns3:Associations>
                        </ns3:OrderItem>
                    </ns3:OrderItems>
                </ns3:Order>
            </ns3:Response>
        </ns3:OrderViewRS>
    </ns2:Body>
</ns2:Envelope>

Step 2: Read reservation details

S7 Agent executes a read operation itinerary info of reservation PNR.

<Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/">
    <Header />
    <Body>
        <OrderRetrieveRQ Version="1.0" xmlns="http://www.iata.org/IATA/EDIST">
            <Document />
            <Party>
                <Sender>
                    <AgentUserSender>
                        <Name>S7-AIDL</Name>
                        <OtherIDs>
                            <OtherID Description="POS_Type">1</OtherID>
                            <OtherID Description="requestorType">U</OtherID>
                        </OtherIDs>
                        <PseudoCity>OVBS728AB</PseudoCity>
                        <AgentUserID>S7AgentAPI</AgentUserID>
                        <UserRole>AS</UserRole>
                    </AgentUserSender>
                </Sender>
            </Party>
            <Query>
                <Filters>
                    <BookingReferences>
                        <BookingReference>
                            <ID>UXX22O</ID>
                            <AirlineID>S7</AirlineID>
                        </BookingReference>
                    </BookingReferences>
                </Filters>
            </Query>
        </OrderRetrieveRQ>
    </Body>
</Envelope>


<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ns2:Envelope xmlns:ns2="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns3="http://www.iata.org/IATA/EDIST">
    <ns2:Body>
        <ns3:OrderViewRS Version="">
            <ns3:Document>
                <ns3:Name>1.0</ns3:Name>
            </ns3:Document>
            <ns3:Success/>
            <ns3:Response>
                <ns3:OrderViewProcessing/>
                <ns3:Passengers>
                    <ns3:Passenger ObjectKey="SH2">
                        <ns3:PTC Quantity="1">ADT</ns3:PTC>
                        <ns3:Age>
                            <ns3:BirthDate>1992-02-27</ns3:BirthDate>
                        </ns3:Age>
                        <ns3:Name>
                            <ns3:Surname>pilatus</ns3:Surname>
                            <ns3:Given>pontius</ns3:Given>
                            <ns3:Title>MR</ns3:Title>
                            <ns3:Middle/>
                        </ns3:Name>
                        <ns3:Contacts>
                            <ns3:Contact>
                                <ns3:EmailContact>
                                    <ns3:Address>r.tkachuk@s7.ru</ns3:Address>
                                </ns3:EmailContact>
                                <ns3:PhoneContact>
                                    <ns3:Number>79999999999</ns3:Number>
                                </ns3:PhoneContact>
                            </ns3:Contact>
                        </ns3:Contacts>
                        <ns3:Gender>Male</ns3:Gender>
                        <ns3:PassengerIDInfo>
                            <ns3:PassengerDocument>
                                <ns3:Type>PP</ns3:Type>
                                <ns3:ID>111111111</ns3:ID>
                                <ns3:BirthCountry>RU</ns3:BirthCountry>
                                <ns3:DateOfExpiration>2030-02-27</ns3:DateOfExpiration>
                                <ns3:CountryOfResidence>RU</ns3:CountryOfResidence>
                            </ns3:PassengerDocument>
                        </ns3:PassengerIDInfo>
                    </ns3:Passenger>
                </ns3:Passengers>
                <ns3:Order>
                    <ns3:OrderID Owner="S7">1</ns3:OrderID>
                    <ns3:BookingReferences>
                        <ns3:BookingReference>
                            <ns3:ID>UXX22O</ns3:ID>
                            <ns3:AirlineID>S7</ns3:AirlineID>
                        </ns3:BookingReference>
                    </ns3:BookingReferences>
                    <ns3:TimeLimits>
                        <ns3:PaymentTimeLimit DateTime="2019-03-05T15:14:58"/>
                    </ns3:TimeLimits>
                    <ns3:OrderItems>
                        <ns3:OrderItem>
                            <ns3:FlightItem>
                                <ns3:OriginDestination>
                                    <ns3:Flight>
                                        <ns3:SegmentKey>FL1</ns3:SegmentKey>
                                        <ns3:Status>
                                            <ns3:StatusCode>
                                                <ns3:Code>HK</ns3:Code>
                                            </ns3:StatusCode>
                                        </ns3:Status>
                                        <ns3:Departure>
                                            <ns3:AirportCode>DME</ns3:AirportCode>
                                            <ns3:Date>2019-09-20</ns3:Date>
                                            <ns3:Time>12:25</ns3:Time>
                                        </ns3:Departure>
                                        <ns3:Arrival>
                                            <ns3:AirportCode>KUF</ns3:AirportCode>
                                            <ns3:Date>2019-09-20</ns3:Date>
                                            <ns3:Time>15:10</ns3:Time>
                                        </ns3:Arrival>
                                        <ns3:MarketingCarrier>
                                            <ns3:AirlineID>S7</ns3:AirlineID>
                                            <ns3:FlightNumber>33</ns3:FlightNumber>
                                        </ns3:MarketingCarrier>
                                        <ns3:OperatingCarrier>
                                            <ns3:AirlineID>S7</ns3:AirlineID>
                                            <ns3:FlightNumber>33</ns3:FlightNumber>
                                        </ns3:OperatingCarrier>
                                        <ns3:CabinType>
                                            <ns3:Code>Y</ns3:Code>
                                        </ns3:CabinType>
                                        <ns3:ClassOfService>
                                            <ns3:Code>Y</ns3:Code>
                                        </ns3:ClassOfService>
                                    </ns3:Flight>
                                </ns3:OriginDestination>
                            </ns3:FlightItem>
                            <ns3:Associations>
                                <ns3:Passengers>
                                    <ns3:PassengerReferences>SH2</ns3:PassengerReferences>
                                </ns3:Passengers>
                            </ns3:Associations>
                        </ns3:OrderItem>
                    </ns3:OrderItems>
                </ns3:Order>
            </ns3:Response>
        </ns3:OrderViewRS>
    </ns2:Body>
</ns2:Envelope>
  • No labels