PayValid

  • Purpose: Used to verify whether the current Order can be paid to ensure the success rate of ticket issuance.
  • Request: POST
  • Encryption: No

Request

Parameter Name Type Required Description
requestId string ✅ Request ID. Each interface in the booking process is unique. A complete booking process can be connected through this field. The length is 32 bits.
orderNo string ✅ The order number of AeroHub is 20 characters in length. The supplier needs to save it and the invoicing process needs to use this field for association.
tripType int ✅ Itinerary type: 1 one-way, 2 round-trip. If 1 or 2 is passed, it means that this search only requires this type of itinerary.
sessionId string ✅ Session ID, the supplier’s unique ID for each interface connected in series during the reservation process, consisting of numbers or letters, with a maximum length of 40 characters
routing object/routing Element ✅ For itinerary and quotation information, refer to the object/routing Element in the Order interface.
pnrCode string PNR code used for quotation (occupancy)

object/routing Element

Parameter Name Type Required Description
data string ✅ The original data returned by Order interface Routing is used for suppliers to do internal business. The serial length does not exceed 64 bits.
fromSegments array/Segment Element ✅ Outbound itinerary information
retSegments array/Segment Element ⬜️ Return trip information

array/Segment Element

Parameter Name Type Required Description
marketingCarrier string ✅ Airline code, using IATA two-character code as the standard, corresponds to the first two digits in flightNumber
depAirport string ✅ Departure airport code, using IATA three-letter code as the standard
depTime string ✅ Departure date and departure time (local time), format: YYYYMMDDHHMM, for example, 202303100300 means 3:00 on March 10, 2023
arrAirport string ✅ Arrival airport code, using IATA three-letter code as the standard
arrTime string ✅ Arrival date and arrival time (local time), format: YYYYMMDDHHMM, for example, 202303101305 means 13:05 on March 10, 2023
stopCities string ⬜️ Stop cities, use/separate multiple times, adopt ISO 3166 three-character code as the standard
codeShare bool ✅ Whether this flight is a shared flight, true is a shared flight, false is not a shared flight, if true is returned, operatingCarrier and operatingFlightNo must be returned
seatClass string ✅ cabin
aircraftCode string ✅ Model, using IATA three-letter code as standard
flightNumber string ✅ Flight number, such as: CA123

Sample Request

{
    "requestId": "bc3461520668454e",
    "orderNo": "F1726885264686714880",
    "tripType": 2,
    "sessionId": "aNBOGd3p7Kf72ALZOQY",
    "routing": {
        "data": "DST_djlfOUNCMkNCSl9QVkd",
        "fromSegments": [{
            "marketingCarrier": "9C",
            "depAirport": "PVG",
            "depTime": "202302100915",
            "arrAirport": "HKG",
            "arrTime": "202302101220",
            "stopCities": "",
            "codeShare": false,
            "seatClass": "V",
            "aircraftCode": "",
            "flightNumber": "9C8921"
        }],
        "retSegments": [{
            "marketingCarrier": "9C",
            "depAirport": "HKG",
            "depTime": "202302151320",
            "arrAirport": "PVG",
            "arrTime": "202302151545",
            "stopCities": "",
            "codeShare": false,
            "seatClass": "V",
            "aircraftCode": "",
            "flightNumber": "9C8922"
        }]
    },
    "pnrCode":"R17ZCV"
}

Response

Parameter Name Type Required Description
marketErrorCode int ✅ Supplier system error code is used to assist AeroHub and suppliers in troubleshooting problems. Please return the true error truthfully.
marketErrorMsg string ✅ Supplier system error description, please truthfully return the real error reason, the length is less than 300 characters
sessionId string ✅ Session ID, the supplier’s unique ID for each interface connected in series during the reservation process, consisting of numbers or letters, with a maximum length of 40 characters
orderNo string ✅ The order number of the supplier’s own system, up to 30 characters, AeroHub will record this field for later traceability
routing object ✅ For itinerary and quotation information, refer to the object/routing Element in the Order interface.

Response Example

Success Response:

{
    "marketErrorCode": 200,
    "marketErrorMsg": "Successful",
    "sessionId": "aNBOGd3p7Kf72ALZOQY",
    "orderNo": "231121164918540071",
    "routing": {
        "data": "DST_djlfOUNCMkNCSl9QVkdfSEtHXzIwMj",
        "fromSegments": [{
            "marketingCarrier": "9C",
            "depAirport": "PVG",
            "depTime": "202302100915",
            "arrAirport": "HKG",
            "arrTime": "202302101220",
            "seatGrade": "",
            "seatClass": "V",
            "flightNumber": "9C8921",
            "codeShare": false,
            "aircraftCode": "",
            "segmentNo": 1,
            "operatingCarrier": "",
            "operatingFlightNo": "",
            "stopCities": "",
            "stopAirports": ""
        }],
        "retSegments": [{
            "marketingCarrier": "9C",
            "depAirport": "HKG",
            "depTime": "202302151320",
            "arrAirport": "PVG",
            "arrTime": "202302151545",
            "seatClass": "V",
            "seatGrade": "",
            "flightNumber": "9C8922",
            "codeShare": false,
            "aircraftCode": "",
            "segmentNo": 2,
            "operatingCarrier": "",
            "operatingFlightNo": "",
            "stopCities": "",
            "stopAirports": ""
        }],
        "priceList": [{
            "passengerType": 0,
            "publishPrice": 0,
            "price": 608,
            "taxFeeAmount": 369,
            "taxFeeDisclosureList": []
        }, {
            "passengerType": 1,
            "publishPrice": 0,
            "price": 608,
            "taxFeeAmount": 369,
            "taxFeeDisclosureList": []
        }],
        "eligibility": "NOR",
        "validatingCarrier": "9C",
        "productType": "",
        "fareBasis": "",
        "bookingOfficeNo": "",
        "ticketingOfficeNo": "",
        "reservationType": "",
        "posCode": "",
        "complexTerm": 0,
        "minAge": 0,
        "maxAge": 0,
        "planCategory": 0,
        "invoiceType": "E",
        "minPassengerCount": 1,
        "maxPassengerCount": 9,
        "note": "xxx",
        "airlineAncillaries": {
            "baggageService": true,
            "unFreeBaggage": true
        },
        "formatBaggageDetailList": [],
        "refundInfoList": [{
            "passengerType": 0,
            "refundType": 0,
            "refundStatus": "T",
            "refundFee": 0,
            "refNoshow": "T",
            "refNoShowCondition": 0,
            "refNoshowFee": 0,
            "conditionList": []
        },
        {
            "passengerType": 1,
            "refundType": 0,
            "refundStatus": "T",
            "refundFee": 0,
            "refNoshow": "T",
            "refNoShowCondition": 0,
            "refNoshowFee": 0,
            "conditionList": []
        }],
        "changesInfoList": [{
            "passengerType": 0,
            "changesType": 0,
            "changesStatus": "T",
            "changesFee": 0,
            "revNoshow": "T",
            "revNoShowCondition": 0,
            "revNoshowFee": 0,
            "conditionList": ""
        },
        {
            "passengerType": 1,
            "changesType": 0,
            "changesStatus": "T",
            "changesFee": 0,
            "revNoshow": "T",
            "revNoShowCondition": 0,
            "revNoshowFee": 0,
            "conditionList": ""
        }],
        "packageInfo": null,
        "currency": "USD",
        "ticketTimeUnit": 1000,
        "combineIndexs": [],
        "endorsement": 0
    }
}

Error Response

{
    "marketErrorCode": 5112,
    "marketErrorMsg": "Price changed to no seat"
}
Author:AeroHub  Create time:2023-07-10 16:14
Last editor:AeroHub  Update time:2026-10-20 11:28