<!--
{
  "documentType" : "article",
  "framework" : "ExternalPurchaseServerAPI",
  "identifier" : "/documentation/ExternalPurchaseServerAPI/errorcodes",
  "metadataVersion" : "0.1.0",
  "role" : "collectionGroup",
  "title" : "Error messages and codes"
}
-->

# Error messages and codes

Error messages and codes for reports and endpoints.

## Topics

### Error objects for reports

[`object DateTooFarInPastError`](/documentation/ExternalPurchaseServerAPI/DateTooFarInPastError)

An error indicating that a provided date is too far in the past.

[`object DuplicateTokenStatusNotAllowedError`](/documentation/ExternalPurchaseServerAPI/DuplicateTokenStatusNotAllowedError)

An error indicating the duplicate token status is not allowed for the associated token type.

[`object DuplicateValueError`](/documentation/ExternalPurchaseServerAPI/DuplicateValueError)

An error indicating the field’s value is already submitted and a duplicate value is not expected.

[`object ErroneousLineItemReferencedByValidLineItemError`](/documentation/ExternalPurchaseServerAPI/ErroneousLineItemReferencedByValidLineItemError)

An error indicating the line item has status erroneously submitted but is referenced by a non-erroneously submitted line item.

[`object ErroneouslySubmittedNotRestatementError`](/documentation/ExternalPurchaseServerAPI/ErroneouslySubmittedNotRestatementError)

An error indicating the erroneously submitted line item was not marked as restatement.

[`object ExchangeRateMismatchError`](/documentation/ExternalPurchaseServerAPI/ExchangeRateMismatchError)

An error indicating the refund’s referenced buy line item has a different exchange rate.

[`object FieldNotAllowedError`](/documentation/ExternalPurchaseServerAPI/FieldNotAllowedError)

An error indicating the provided field is not allowed.

[`object FutureDateError`](/documentation/ExternalPurchaseServerAPI/FutureDateError)

An error indicating the provided date field is in the future and future values are not allowed.

[`object IncorrectAmountTaxInclusiveError`](/documentation/ExternalPurchaseServerAPI/IncorrectAmountTaxInclusiveError)

An error indicating the tax exclusive amount plus the tax amount does not equal the tax inclusive amount.

[`object IncorrectNetAmountError`](/documentation/ExternalPurchaseServerAPI/IncorrectNetAmountError)

An error indicating the net amount value does not match the expected value.

[`object InvalidTaxInclusiveAmountForSubscriptionPaymentError`](/documentation/ExternalPurchaseServerAPI/InvalidTaxInclusiveAmountForSubscriptionPaymentError)

An error indicating the tax inclusive amount must be positive for line items with a subscription payment subscription event.

[`object LineItemCreationDateOutOfRangeError`](/documentation/ExternalPurchaseServerAPI/LineItemCreationDateOutOfRangeError)

An error indicating the line item’s creation date is outside the active range of the token.

[`object LineItemStatusRegressionError`](/documentation/ExternalPurchaseServerAPI/LineItemStatusRegressionError)

An error indicating the status can’t be marked as no line item or unrecognized token after it was previously reported as a line item.

[`object LineItemsNotAllowedForStatusError`](/documentation/ExternalPurchaseServerAPI/LineItemsNotAllowedForStatusError)

An error indicating a line item was provided for an external purchase ID that has the status no line item or unrecognized token.

[`object MaximumLengthExceededError`](/documentation/ExternalPurchaseServerAPI/MaximumLengthExceededError)

An error indicating the field’s maximum length is exceeded.

[`object MissingLineItemsForStatusError`](/documentation/ExternalPurchaseServerAPI/MissingLineItemsForStatusError)

An error indicating the external purchase ID has the status line item but is missing line items.

[`object NegativeValueNotAllowedError`](/documentation/ExternalPurchaseServerAPI/NegativeValueNotAllowedError)

An error indicating the field does not allow a negative value.

[`object NetAmountMismatchError`](/documentation/ExternalPurchaseServerAPI/NetAmountMismatchError)

An error indicating two line items involved in the same net amount calculation have different net amount values.

[`object NonInitialBuyReferencedByBuyError`](/documentation/ExternalPurchaseServerAPI/NonInitialBuyReferencedByBuyError)

An error indicating the line item does not have subscription event initial buy but is referenced by a subscription line item with event type buy.

[`object NotFoundError`](/documentation/ExternalPurchaseServerAPI/NotFoundError)

An error indicating the referenced value was not found.

[`object OmittedFieldError`](/documentation/ExternalPurchaseServerAPI/OmittedFieldError)

An error indicating a required field is missing.

[`object PositiveValueRequiredError`](/documentation/ExternalPurchaseServerAPI/PositiveValueRequiredError)

An error indicating the field requires a positive value.

[`object PricingCurrencyMismatchError`](/documentation/ExternalPurchaseServerAPI/PricingCurrencyMismatchError)

An error indicating the refund’s referenced buy line item has a different pricing currency.

[`object ReferenceInvalidSubscriptionEventError`](/documentation/ExternalPurchaseServerAPI/ReferenceInvalidSubscriptionEventError)

An error indicating the referenced line item has no subscription event or its subscription event is not subscription start.

[`object ReferenceLineItemNotABuyError`](/documentation/ExternalPurchaseServerAPI/ReferenceLineItemNotABuyError)

An error indicating the referenced line item is not a buy.

[`object ReferencedCreationDateIncompatibleError`](/documentation/ExternalPurchaseServerAPI/ReferencedCreationDateIncompatibleError)

An error indicating the referenced line item has a creation date after the line item’s creation date.

[`object RefundNotAllowedCreationDateError`](/documentation/ExternalPurchaseServerAPI/RefundNotAllowedCreationDateError)

An error indicating the refund isn’t allowed for the line item because its creation date is too far in the past.

[`object RefundReferencedByRefundError`](/documentation/ExternalPurchaseServerAPI/RefundReferencedByRefundError)

An error indicating the line item has the refund event type but is referenced by a different line item that also has that type.

[`object RestatementCreationDateMismatchError`](/documentation/ExternalPurchaseServerAPI/RestatementCreationDateMismatchError)

An error indicating the creation date of the restatement line item doesn’t match the creation date of the original line item.

[`object RestatementNotAllowedCreationDateError`](/documentation/ExternalPurchaseServerAPI/RestatementNotAllowedCreationDateError)

An error indicating that restatement failed because the creation date is too far in the past.

[`object RepeatErroneousSubmissionError`](/documentation/ExternalPurchaseServerAPI/RepeatErroneousSubmissionError)

An error indicating the line item has status erroneously submitted but its previous version was already marked erroneously submitted.

[`object ReportingCurrencyExchangeNotAllowedError`](/documentation/ExternalPurchaseServerAPI/ReportingCurrencyExchangeNotAllowedError)

An error indicating that the reporting currency, which reports a currency exchange, isn’t allowed.

[`object ReportingCurrencyMismatchError`](/documentation/ExternalPurchaseServerAPI/ReportingCurrencyMismatchError)

An error indicating the refund’s referenced buy line item has a different reporting currency.

[`object SelfReferenceError`](/documentation/ExternalPurchaseServerAPI/SelfReferenceError)

An error indicating the line item references itself.

[`object SimultaneousSubmissionError`](/documentation/ExternalPurchaseServerAPI/SimultaneousSubmissionError)

An error indicating one or more simultaneous submissions of reports reference the same data.

[`object StartDateAfterEndDateError`](/documentation/ExternalPurchaseServerAPI/StartDateAfterEndDateError)

An error indicating the subscription data submitted is invalid because the start date is after the end date.

[`object SubscriptionStartNonZeroDaysPaidServiceError`](/documentation/ExternalPurchaseServerAPI/SubscriptionStartNonZeroDaysPaidServiceError)

An error indicating that the subscription days of paid service value is invalid because it’s non-zero for a subscription start line item.

[`object TaxCountryMismatchError`](/documentation/ExternalPurchaseServerAPI/TaxCountryMismatchError)

An error indicating the refund’s referenced buy line item has a different tax country.

[`object UnknownEnumError`](/documentation/ExternalPurchaseServerAPI/UnknownEnumError)

An error indicating the submission contained an invalid enum value.

[`object ValidLineItemReferencesErroneousLineItemError`](/documentation/ExternalPurchaseServerAPI/ValidLineItemReferencesErroneousLineItemError)

An error indicating the line item references an erroneously submitted line item, but the line item itself isn’t erroneously submitted.

### Error types

[`int64 errorCode`](/documentation/ExternalPurchaseServerAPI/errorCode)

An integer value that represents an error in the External Purchase Server API.

[`string errorMessage`](/documentation/ExternalPurchaseServerAPI/errorMessage)

A string that describes an error.

[`string fieldName`](/documentation/ExternalPurchaseServerAPI/fieldName)

A string that names a field of a line item.



---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)