Real-Time Transaction Synchronization
Alitrip has established specifications for real-time transaction order synchronization interfaces; merchants are required to obey these specifications to realize and provide corresponding services. During a user’s ordering process, the Alitrip transaction system duly triggers to invoke interfaces related to transaction reservation provided by an external merchant so as to synchronize Alitrip platform orders to the merchant system in real time, and also provides a series of callback interfaces related to transaction orders to promote order procedures.
Real-Time Transaction Order Synchronization Sequence Diagram is shown as follows:

Definition of Real-Time Transaction Order Synchronization Interfaces
Only abstract interfaces are defined herein, and physical interfaces are not involved. See real-time order synchronization schemes corresponding to different services for detailed definitions of direct-connection interfaces and callback interfaces. Currently supported service: Car Reservation. Other services are to be extended and supported!
Order verification interface
The order validation interface is used to verify whether the price and availability of an item currently bidden by a user is consistent with the latest price and availability in merchant system, and the interface needs to return a verification result in real time. Statute of the interface is as follows:
- The timeout period of the interface is 5 seconds, i.e., the merchant interface must return the verification result within 5 seconds.
Reservation interface
The Alitrip system transfers necessary customer reservation information to a merchant system via the interface, to trigger a customer reservation procedure of the merchant system. Statutes of the interface are as follows:
-
- The timeout period of the interface is 5 seconds, i.e., the merchant interface must return a reservation result or inform a reservation process within 5 seconds (if the merchant system cannot complete reservation within 5 seconds, the reservation process should be informed first. The Alitrip system will poll reservation results according to a certain strategy; see statute 3 for details). Polling reservation results is invoking “order query interface” provided by merchants.
-
- Guarantee idempotence: the reservation interface provided by a merchant must guarantee that the merchant system order numbers returned via the interface and corresponding to the same Alitrip order id must be identical, i.e., the Alitrip id has one-to-one mapping with the merchant order id.
-
- Reservation result polling strategy: reservation results are queried every 3 minutes within 30 minutes after submitting a reservation. If the merchant system still has not returned a reservation result 30 minutes later, it is regarded as a failed reservation.
Reservation cancellation interface
If a user cancels a reservation on the Alitrip system, the Alitrip system will trigger a reservation cancellation procedure of the merchant system via the interface. Statutes of the interface are as follows:
-
- The timeout period of the interface is 5 seconds, i.e., the merchant interface must return a cancellation result or inform a cancellation process within 5 seconds (if the merchant system cannot complete reservation cancellation within 5 seconds, the cancellation process should be informed first. The Alitrip system will poll cancellation results according to a certain strategy; see statute 3 for details).
-
- Guarantee idempotence: the reservation cancellation interface provided by a merchant must guarantee that for the same Alitrip order id, the merchant system cancels the same merchant order.
-
- Reservation cancellation result polling strategy: reservation cancellation results are queried every 3 minutes within 30 minutes after submitting a reservation cancellation. If the merchant system still has not returned a reservation cancellation result 30 minutes later, it is regarded as a failed reservation cancellation.
Order query interface
The Alitrip system queries a reservation result or a reservation cancellation result of a merchant system in real time by invoking the order query interface provided by a merchant. Statutes of the interface are as follows:
-
- The order query interface provided by a merchant must support queries that set Alitrip order numbers as primary keys.
-
- The timeout period of the interface is 5 seconds, i.e., the merchant interface must return a query result within 5 seconds.
-
- Guarantee idempotence: for the same Alitrip order id, the returned merchant orders must be the same.
FAQ
关于此文档暂时还没有FAQ