{ "openapi": "3.0.0", "info": { "contact": {}, "description": "Gets BidPrice's information by Flight.", "title": "API - Revenue Management BidPrice - v1.0", "version": "1.0", "x-jentic-source-url": "https://api.swaggerhub.com/apis/Copa-Airlines/api-revenue_management_bid_price_v_1_0/1.0/swagger.json" }, "servers": [ { "url": "https://api.copa.com/rms/bidprice/v1.0/bidprice" } ], "paths": { "/{flightnum}/{departdate}/{opcarrier}/{origin}/{destination}": { "get": { "parameters": [ { "description": "Flight number", "in": "path", "name": "flightnum", "required": true, "schema": { "type": "string" } }, { "description": "Date of departure in date (YYYYMMDD) format.", "in": "path", "name": "departdate", "required": true, "schema": { "type": "string" } }, { "description": "Airline operation carrier", "in": "path", "name": "opcarrier", "required": true, "schema": { "type": "string" } }, { "description": "Origin Airport.", "in": "path", "name": "origin", "required": true, "schema": { "type": "string" } }, { "description": "Destination Airport", "in": "path", "name": "destination", "required": true, "schema": { "type": "string" } }, { "description": "Cabin class (C or Y)", "in": "query", "name": "cabin", "required": false, "schema": { "type": "string" } } ], "responses": { "200": { "content": { "application/json": { "examples": { "response": { "value": { "FlightLeg": { "ArcfCfgId": "1", "ArcfType": "73E", "BPControlFlag": "1", "CarrierCode": "CM", "Compartments": [ { "AU": "11", "AdjCap": "10", "AllotmentFlag": "?", "AuIncludingNegoBlocks": "1", "BidPriceVector": [ { "BidPrice": "69", "SeatIndex": "1" }, { "BidPrice": "8", "SeatIndex": "2" }, { "BidPrice": "0", "SeatIndex": "11" } ], "CapacityReduction": "?", "Classes": [ { "AU": "11", "AuIncludingNegoBlocks": "11", "BkgPtrs": "0", "BookingMax": "?", "BookingMin": "?", "ClsCode": "C", "DcSts": "0", "GatedFlag": "?", "GrpBkd": "0", "GrpOut": "0", "MaxSts": "?", "NegoBlocks": "0", "OBDCMult": "110", "ObSts": "0", "PrntClsCode": "C", "PrtSts": "0", "ReconstrainedOut": "0.011812", "SuRate": "100", "TotAchDmd": "0.011849", "TotBkd": "0", "TotOut": "0" }, { "AU": "11", "AuIncludingNegoBlocks": "11", "BkgPtrs": "0", "BookingMax": "?", "BookingMin": "?", "ClsCode": "P", "DcSts": "0", "GatedFlag": "?", "GrpBkd": "0", "GrpOut": "0", "MaxSts": "?", "NegoBlocks": "0", "OBDCMult": "110", "ObSts": "0", "PrntClsCode": "C", "PrtSts": "0", "ReconstrainedOut": "0.0", "SuRate": "100", "TotAchDmd": "0.0", "TotBkd": "0", "TotOut": "0" } ], "CmpCode": "C", "CrFnlGrpOut": "0", "DcSts": "0", "MaxUpSts": "999", "ObSts": "1", "PhyCap": "10", "TotAchDmd": "6.342696", "UpSts": "0", "VarStsFlag": "0", "VirtCap": "10" }, { "AU": "93", "AdjCap": "84", "AllotmentFlag": "?", "AuIncludingNegoBlocks": "93", "BidPriceVector": [ { "BidPrice": "965", "SeatIndex": "1" }, { "BidPrice": "686", "SeatIndex": "2" }, { "BidPrice": "0", "SeatIndex": "93" } ], "CapacityReduction": "?", "Classes": [ { "AU": "93", "AuIncludingNegoBlocks": "93", "BkgPtrs": "1", "BookingMax": "?", "BookingMin": "?", "ClsCode": "Y", "DcSts": "0", "GatedFlag": "?", "GrpBkd": "0", "GrpOut": "0", "MaxSts": "?", "NegoBlocks": "0", "OBDCMult": "111", "ObSts": "0", "PrntClsCode": "Y", "PrtSts": "1", "ReconstrainedOut": "1.200382", "SuRate": "92", "TotAchDmd": "1.335993", "TotBkd": "1", "TotOut": "1" }, { "AU": "5", "AuIncludingNegoBlocks": "5", "BkgPtrs": "5", "BookingMax": "?", "BookingMin": "?", "ClsCode": "I", "DcSts": "0", "GatedFlag": "?", "GrpBkd": "0", "GrpOut": "0", "MaxSts": "?", "NegoBlocks": "0", "OBDCMult": "110", "ObSts": "1", "PrntClsCode": "Z", "PrtSts": "4", "ReconstrainedOut": "0.011801", "SuRate": "100", "TotAchDmd": "0.024649", "TotBkd": "0", "TotOut": "0" } ], "CmpCode": "Y", "CrFnlGrpOut": "0", "DcSts": "0", "MaxUpSts": "999", "ObSts": "9", "PhyCap": "84", "TotAchDmd": "67.867853", "UpSts": "0", "VarStsFlag": "0", "VirtCap": "84" } ], "DepartureDate": "20201012", "DestinationAirport": "JFK", "FlightNumber": "357", "InvDate": "20200203", "InvTime": "184502", "OptType": "N", "OriginAirport": "PTY", "SkipPersistFlag": "0" }, "Status": "Success" } } }, "schema": { "$ref": "#/components/schemas/BidPriceListResponse" } } }, "description": "Ok" }, "400": { "content": { "application/json": { "examples": { "response": { "value": { "ErrorMessages": [ { "Code": "1001", "Description": "Field is missing.", "Key": "CarrierCode", "TypeCode": "Missing" } ], "Status": "Failed" } } }, "schema": { "$ref": "#/components/schemas/BidPriceListResponse" } } }, "description": "400 - Error response." }, "500": { "content": { "application/json": { "examples": { "response": { "value": { "ErrorMessages": [ { "Code": "1000", "Description": "Internal system error.", "Key": "SYSERROR", "TypeCode": "SysInternal" } ], "Status": "Failed" } } }, "schema": { "$ref": "#/components/schemas/BidPriceListResponse" } } }, "description": "500 - System Internal Error response." } }, "tags": [ "default" ], "description": "Gets the list of Bidprices by flight and cabin.\n", "operationId": "get-bidprice-by-flight-and-cabin", "summary": "Gets the list of Bidprices by flight and cabin" } } }, "components": { "schemas": { "BidPriceListResponse": { "description": "The BidPrices returned.", "properties": { "ErrorMessages": { "description": "Represents an ErrorMessage Array.", "items": { "$ref": "#/components/schemas/ErrorMessage" }, "type": "array" }, "FlightLeg": { "$ref": "#/components/schemas/FlightLeg" }, "Status": { "description": "A status describing if request was successful responsed.\n - Success: The BidPrices list for flight and cabin specified was getted without problems.\n - Failed: The BidPrices list for flight and cabin specified was not getted due by flight and cabin invalid parameters or an internal error.", "enum": [ "Success", "Failed" ], "example": "Success", "type": "string" } }, "required": [ "Status" ], "type": "object" }, "ErrorMessage": { "description": "Represents an Error element with Error Code and Description", "properties": { "Code": { "description": "Error code", "example": "1002", "type": "string" }, "Description": { "description": "Error descriptions", "example": "Error descriptions", "type": "string" }, "Key": { "description": "Key", "example": "Key", "type": "string" }, "TypeCode": { "description": "TypeCode", "example": "TypeCode", "type": "string" } }, "required": [ "Code", "Description" ], "type": "object" }, "FlightLeg": { "description": "Represents a Flight Leg information.", "properties": { "ArcfCfgId": { "description": "The aircraft configuration id.", "example": "1", "type": "string" }, "ArcfType": { "description": "The aircraft type.", "example": "73E", "type": "string" }, "BPControlFlag": { "description": "The BidPrice control.", "example": "1", "type": "string" }, "CarrierCode": { "description": "IATA two letter airline code for representang the Airlines who is operating the flight.", "example": "CM", "type": "string" }, "Compartments": { "description": "Represents a Flight Leg compartment information (executive and economic classes) array.", "items": { "$ref": "#/components/schemas/FlightLegCompartment" }, "type": "array" }, "DepartureDate": { "description": "Date of departure in date (YYYYMMDD) format.", "example": "20201012", "type": "string" }, "DestinationAirport": { "description": "The destination airport.", "example": "JFK", "type": "string" }, "FlightNumber": { "description": "The airlines flight number.", "example": "357", "type": "string" }, "InvDate": { "description": "Last date inventory was recieved.", "example": "20200203", "type": "string" }, "InvTime": { "description": "Last time inventory was recieved.", "example": "184502", "type": "string" }, "OptType": { "description": "Optimization type. Describes which optimization type has triggerd the upload.", "example": "N", "type": "string" }, "OriginAirport": { "description": "The origin airport.", "example": "PTY", "type": "string" }, "SkipPersistFlag": { "description": "Indicates if the optimization results were saved to the RM Editions backend database.", "example": "0", "type": "string" } }, "required": [ "CarrierCode", "FlightNumber", "DepartureDate", "OriginAirport", "DestinationAirport" ], "type": "object" }, "FlightLegClass": { "description": "Represents a Flight Leg class information (booking classes).", "properties": { "AU": { "description": "AU.", "example": "5", "type": "string" }, "AuIncludingNegoBlocks": { "description": "The class Au including the NegoBlock(s) that exist in the class.", "example": "5", "type": "string" }, "BkgPtrs": { "description": "Booking protects.", "example": "5", "type": "string" }, "BookingMax": { "description": "Booking maximum.", "example": "?", "type": "string" }, "BookingMin": { "description": "Booking minimum.", "example": "?", "type": "string" }, "ClsCode": { "description": "The booking class code.", "example": "I", "type": "string" }, "DcSts": { "description": "Number of decrement seats.", "example": "0", "type": "string" }, "GatedFlag": { "description": "Class gated flag.", "example": "?", "type": "string" }, "GrpBkd": { "description": "Group bookings.", "example": "0", "type": "string" }, "GrpOut": { "description": "Group achievable passenger out.", "example": "0", "type": "string" }, "MaxSts": { "description": "Class max seats.", "example": "?", "type": "string" }, "NegoBlocks": { "description": "The total size of NegoBlock(s) in this class.", "example": "0", "type": "string" }, "OBDCMult": { "description": "Overbooking/Decrement multiplier.", "example": "110", "type": "string" }, "ObSts": { "description": "Number of overbooking seats.", "example": "1", "type": "string" }, "PrntClsCode": { "description": "Parent booking class code in nesting hierarchy.", "example": "Z", "type": "string" }, "PrtSts": { "description": "Protected seats.", "example": "4", "type": "string" }, "ReconstrainedOut": { "description": "The constrained demand for the day of departure multiplied by the class level show-up rate.", "example": "0.011801", "type": "string" }, "SuRate": { "description": "Show up Rate.", "example": "100", "type": "string" }, "TotAchDmd": { "description": "Total achievable demand.", "example": "0.024649", "type": "string" }, "TotBkd": { "description": "Total bookings.", "example": "0", "type": "string" }, "TotOut": { "description": "Total achievable passenger out.", "example": "0", "type": "string" } }, "required": [ "ClsCode" ], "type": "object" }, "FlightLegCompartment": { "description": "Represents a Flight Leg compartment information (executive and economic classes).", "properties": { "AU": { "description": "Compartment AU.", "example": "93", "type": "string" }, "AdjCap": { "description": "Adjusted capacity.", "example": "84", "type": "string" }, "AllotmentFlag": { "description": "A flag to indicate that an allotment(s) exist on this leg compartment.", "example": "?", "type": "string" }, "AuIncludingNegoBlocks": { "description": "The compartment Au including all NegoBlocks that exist on the Leg Compartment.", "example": "93", "type": "string" }, "BidPriceVector": { "description": "Contains all bidprices by flight/leg/compartment in JSON format.", "example": [ { "BidPrice": "965", "SeatIndex": "1" }, { "BidPrice": "686", "SeatIndex": "2" }, { "BidPrice": "525", "SeatIndex": "3" }, { "BidPrice": "392", "SeatIndex": "4" }, { "BidPrice": "276", "SeatIndex": "5" }, { "BidPrice": "183", "SeatIndex": "6" }, { "BidPrice": "115", "SeatIndex": "7" }, { "BidPrice": "68", "SeatIndex": "8" }, { "BidPrice": "38", "SeatIndex": "9" }, { "BidPrice": "20", "SeatIndex": "10" }, { "BidPrice": "10", "SeatIndex": "11" }, { "BidPrice": "5", "SeatIndex": "12" }, { "BidPrice": "2", "SeatIndex": "13" }, { "BidPrice": "1", "SeatIndex": "14" }, { "BidPrice": "0", "SeatIndex": "15" }, { "BidPrice": "0", "SeatIndex": "16" }, { "BidPrice": "0", "SeatIndex": "93" } ], "items": { "$ref": "#/components/schemas/SeatBidPriceRecord" }, "type": "array" }, "CapacityReduction": { "description": "Capacity reduction in number of seats as determined by a linked Capacity Reduction Optimizer Parameter.", "example": "?", "type": "string" }, "Classes": { "description": "Represents a classes array.", "items": { "$ref": "#/components/schemas/FlightLegClass" }, "type": "array" }, "CmpCode": { "description": "The compartment code ('C' or 'Y').", "example": "Y", "type": "string" }, "CrFnlGrpOut": { "description": "The allotment system parameter.", "example": "0", "type": "string" }, "DcSts": { "description": "Number of decrement seats.", "example": "0", "type": "string" }, "MaxUpSts": { "description": "The maximum number of upgrades allowed from a lower comparment to a higher, adjacent compartment.", "example": "999", "type": "string" }, "ObSts": { "description": "Number of overbooking seats.", "example": "9", "type": "string" }, "PhyCap": { "description": "Physical capacity.", "example": "84", "type": "string" }, "TotAchDmd": { "description": "The total achievable demand.", "example": "67.867853", "type": "string" }, "UpSts": { "description": "Upgrade seats.", "example": "0", "type": "string" }, "VarStsFlag": { "description": "Variable capacity is operated for this flight.", "example": "0", "type": "string" }, "VirtCap": { "description": "Virtual capacity.", "example": "84", "type": "string" } }, "required": [ "CmpCode" ], "type": "object" }, "SeatBidPriceRecord": { "description": "Represents the information of BidPrice Vector's row.", "properties": { "BidPrice": { "description": "Bid price.", "example": "315", "type": "string" }, "SeatIndex": { "description": "Seat index.", "example": "2", "type": "string" } }, "required": [ "SeatIndex", "BidPrice" ], "type": "object" } }, "securitySchemes": { "apiKeyHeader": { "in": "header", "name": "Ocp-Apim-Subscription-Key", "type": "apiKey" }, "apiKeyQuery": { "in": "query", "name": "subscription-key", "type": "apiKey" } } }, "security": [ { "apiKeyHeader": [] }, { "apiKeyQuery": [] } ], "tags": [ { "name": "default" } ] }