Retrieve Upload Errors Service
Use the Retrieve Upload Errors Service to interface with ATPCO systems to get a list of errors and/or warnings. This service uses GET HTTP Request method. This service is available to retrieve errors and/or warnings for Fares Upload, Rules Upload, and/or Footnote Upload for a new Work Unit or an existing Work Unit associated with Uploads file.
Request
Your request to the Retrieve Upload Errors Service must provide a valid OAuth access token and a userId in the header. For instructions on how to obtain and use an OAuth Access Token programmatically, see OAuth Access Tokens and Authentication. You can specify the following parameters in the request:
-
workUnitId
(Required) -
afterTimestamp
-
errorsOnly
You can also choose to display errors associated to upload attempts on or after the selected timestamp by using the parameter afterTimestamp
. API requests with no timestamp default to display of all errors related to all upload attempts since 12:01 AM the current day. The API response will list up to 400 error messages for each product (i.e., Fares, Rules and Footnotes). If there are more than 400 errors per product, please manually log in Uploads File Management application in FareManager to view all errors an/or warnings. The display of 400 messages per product are prioritized with errors followed by warnings.
Request Header Parameters
See OAuth Access Tokens and Authentication for instructions on header parameters needed for authentication.
Request URL Parameters
Request should contain Work Unit ID and any one of the following URL parameters
Parameter | Description | Type | Example |
---|---|---|---|
workUnitId |
Unique identifier assigned to the created work unit | String | "XXX-17MAR18-1234567" |
afterTimestamp |
Timestamp to retrieve upload error messages created on or after the specified time in Eastern Standard time | String | "2019-07-24T00:01:00.000" |
errorsOnly |
Flag indicating retrieve only errors or errors and warnings. True is the default setting and returns only errors. Change the value to false to retrieve errors and warnings. | String | "true" |
Response
Upon successful processing of a request, the Retrieve Upload Errors API will return a list of errors and/or warnings for the requested Work Unit ID and product type. The response to a successful Retrieve Upload Errors Service call will contain a JSON object including the parameters specified in the request.
Example Response Object with No Error Messages
{
"msg": "No upload errors found for the request provided",
"details": "resource - [rules,fares,footnotes]; workunitId - [AA-19MAR21-7]; afterTimestamp - [2021-03-19T00:00:00.000]; errorsOnly - [false]"
}
Example Response Object with Errors and Warnings for Fares, Rules, and Footnotes Upload
{
"workUnit": "91-10MAR21-1",
"rules": {
"errors": [
{
"carrierCode": "91",
"tarriffCode": "IPRA",
"rule": "ESTL",
"lineNum": "6",
"message": "EFFECTIVE DATE VALUE 200620 FOR EFF DATE OF TODAY TARIFFS MUST BE GREATER THAN OR EQUAL TO THE CURRENT DATE",
"timestamp": "2021-03-10 14:15:23.919"
},
{
"carrierCode": "91",
"tarriffCode": "IPRA",
"rule": "ESTL",
"lineNum": "5",
"message": "EFFECTIVE DATE VALUE 200620 FOR EFF DATE OF TODAY TARIFFS MUST BE GREATER THAN OR EQUAL TO THE CURRENT DATE",
"timestamp": "2021-03-10 14:15:23.887"
},
{
"lineNum": "7",
"message": "INVALID RECORD ID OF 1",
"timestamp": "2021-03-10 14:15:21.666"
}
],
"warnings": [
{
"carrierCode": "91",
"lineNum": "1",
"message": "INVALID NUMBER OF RECORDS IN THE WORK UNIT OF 00006",
"timestamp": "2021-03-10 14:15:21.677"
}
]
},
"fares": {
"errors": [
{
"carrierCode": "91",
"tarriffCode": "TAFP",
"fareKey": "F-81 17095-NYC-LON-ARNAB3-N--0-USD-2021-09-01",
"message": "Fare Class is invalid",
"timestamp": "2021-03-10 14:18:24.000"
},
{
"carrierCode": "91",
"tarriffCode": "PF17",
"fareKey": "V-81 17096-PFN-SFO-TEST235-N-S2-1-USD-2021-02-26",
"message": "An Effective Date Change cannot be applied to a Fare that is already in effect",
"timestamp": "2021-03-10 14:18:24.000"
},
{
"carrierCode": "91",
"tarriffCode": "AUSA",
"fareKey": "A-81 17097-IST-FRU-F*****-N--2510-USD-157-",
"message": "Market is invalid for Tariff",
"timestamp": "2021-03-10 14:18:24.000"
},
{
"carrierCode": "91",
"tarriffCode": "TAFP",
"fareKey": "B-81 17098",
"message": "Failed release. Fare sequence in the batch with a past Effective Date",
"timestamp": "2021-03-10 14:18:24.000"
}
],
"warnings": [
{
"carrierCode": "91",
"tarriffCode": "TAFP",
"fareKey": "F-81 17095-NYC-LON-TESTHM03-Y--0-INR-2021-09-01",
"message": "Currency does not match default Currency for Origin",
"timestamp": "2021-03-10 14:18:24.000"
}
]
}
"footnotes": {
"errors": [
{
"carrierCode": "91",
"tarriffCode": "TAFP",
"footnote": "V",
"lineNum": "4",
"message": "Effective date must be greater than today for non-EDOT tariff TAFP at row 000000004",
"timestamp": "2019-08-01 23:30:59.371"
}
],
"warnings": [
{
"carrierCode": "91",
"footnote": "",
"lineNum": "1",
"message": "Invalid Number Of Records In The Work Unit Of 00005",
"timestamp": "2019-08-01 23:30:57.141"
}
]
}
}
Response Parameters
Rules Upload Errors and Warnings
Parameter | Description | Type | Example |
---|---|---|---|
carrierCode |
As defined by ATPCO; generally an airline | String | "XXX" |
lineNum |
Line number in the rules upload file where the error/warning occured | String | "4" |
message |
Describes the rules upload error or warning | String | "Invalid number of records in the work unit of 00005" |
rule |
Rule code associated with the tariff | String | "1680" |
tariffCode |
Entity that is defined by system, geographic scope, and distribution process | String | "IPRA" |
timestamp |
Timestamp of the rules upload | String | "2019-12-18 14:51:07.104" |
Footnotes Upload Errors and Warnings
Parameter | Description | Type | Example |
---|---|---|---|
carrierCode |
As defined by ATPCO; generally an airline | String | "XXX" |
lineNum |
Line number in the footnotes upload file where the error/warning occured | String | "4" |
message |
Describes the footnotes upload error or warning | String | "Invalid number of records in the work unit of 00005" |
tariffCode |
Entity that is defined by system, geographic scope, and distribution process | String | "TAFP" |
timestamp |
Timestamp of the footnotes upload | String | "2019-12-18 14:51:07.104" |
Fares Upload Errors and Warnings
Parameter | Description | Type | Example |
---|---|---|---|
carrierCode |
As defined by ATPCO; generally an airline | String | "XXX" |
fareKey |
Batch and Transaction details FareKey format for Transaction errors: INTERNATIONAL - "F-BatchPrefixCd BatchNumber-LOC1-LOC2-FC-OW-FTN-RTG-CURR-EFFDT" DOMESTIC - "V-BatchPrefixCd BatchNumber-LOC1-LOC2-FC-OW-FTN-RTG-CURR-EFFDT" ADDON - "A-BatchPrefixCd BatchNumber-LOC1-LOC2-FC-OW-FTN-RTG-CURR-EFFDT-ZONE" FareKey format for Batch level errors: "B-BatchPrefixCd BatchNumber" |
||
message |
Describes the fares batch data error or warning during fares upload | String | "Invalid number of records in the work unit of 00005" |
tariffCode |
Entity that is defined by system, geographic scope, and distribution process | String | "TAFP" |
timestamp |
Timestamp of the fares upload | String | "2019-12-18 14:51:07.104" |
The Retrieve Upload Errors Service can give the following errors:
Error | Affected Parameter | Description |
---|---|---|
Invalid format. Expected format is yyyy-MM-dd'T'HH:mm:ss.SSS |
afterTimeStamp |
Invalid format |
Work Unit ID has invalid length or format |
workUnitId |
Invalid Work Unit ID |
400 Bad Request |
errorsOnly |
Invalid Flag |