Payment API Error Codes
This page documents all error codes for the Payment API (v2). These errors occur when processing payments that involve one or more payment methods. Each error includes the code name, HTTP status, description, recommended developer action, and notes where applicable.
Error Summary
Authorization error
| Error Title | HTTP Status | Error Message |
|---|---|---|
| FORBIDDEN | 403 | 403 FORBIDDEN. RequestId: ${x-request-id} |
Resource Not Found error
| Error Title | HTTP Status | Error Message |
|---|---|---|
| NOT_FOUND | 404 | paymentId not found |
Schema validation error
| Error Title | HTTP Status | Error Message |
|---|---|---|
| INVALID_REQUEST | 400 | Invalid request format. Please check JSON structure and field types |
| INVALID_REQUEST | 400 | X-Merchant-Id is required |
| INVALID_REQUEST | 400 | X-Merchant-Id must be valid UUID |
| INVALID_REQUEST | 400 | source header cannot exceed 50 characters |
| INVALID_REQUEST | 400 | agent.firstName cannot exceed 50 characters |
| INVALID_REQUEST | 400 | agent.lastName cannot exceed 50 characters |
| INVALID_REQUEST | 400 | agent.userId cannot exceed 50 characters |
Payment Object
Customer Object
Business Rule Violation Error
Payment Details Object
| Error Title | HTTP Status | Error Message |
|---|---|---|
| UNPROCESSABLE_ENTITY | 422 UNPROCESSABLE ENTITY | paymentDetails.qualifiedAmount is required when paymentDetails is provided |
| UNPROCESSABLE_ENTITY | 422 UNPROCESSABLE ENTITY | sum of paymentDetails.qualifiedAmount and paymentDetails.visionAmount cannot exceed amount |
| UNPROCESSABLE_ENTITY | 422 UNPROCESSABLE ENTITY | paymentDetails.prescriptionAmount cannot exceed paymentDetails.qualifiedAmount |
Payment processor error
PaymentAllocation processor error
HTTP Status Codes
- Allocation-specific errors are returned at the allocation level under
paymentAllocations[n]within the parent processor response. - For allocation-level entries, the HTTP status is shown as NA, as it is inherited from the parent
422 UNPROCESSABLE_ENTITYresponse.
Error Code Coverage
- Error Code Coverage: Only the known and documented error-code combinations are listed here; additional combinations may occur.
- Vendor Error Details:
error.errorDetailsreflects data returned by the vendor. The structure is not guaranteed; all fields are optional and subject to change.
Error Details
Authorization error
403 FORBIDDEN. RequestId: ${x-request-id}403
Resource Not Found error
paymentId not found404
Schema validation error
Invalid request format. Please check JSON structure and field types400
X-Merchant-Id is required400
X-Merchant-Id must be valid UUID400
source header cannot exceed 50 characters400
agent.firstName cannot exceed 50 characters400
agent.lastName cannot exceed 50 characters400
agent.userId cannot exceed 50 characters400
Payment Object
paymentId must be valid UUID400
amount is required400
amount must be an integer between 1 and 99999999400
amount must equal the sum of paymentAllocations[:].amount400
merchantTransactionId is required400
merchantTransactionId cannot exceed 50 characters400
description cannot exceed 100 characters400
statementDescriptorSuffix only allows alphanumeric, space, hyphen and dot, and must contain at least one letter400
statementDescriptorSuffix cannot exceed 10 characters400
metadata cannot exceed 20 entries400
metadata key cannot exceed 40 characters400
metadata value cannot exceed 100 characters400
paymentAllocations is required and must contain at least 2 items400
paymentAllocations cannot contain more than 2 items400
paymentAllocations[n].amount is required400
paymentAllocations[n].amount must be an integer between 1 and 99999999400
paymentAllocations[n].paymentMethodId is required400
paymentAllocations[n].paymentMethodId must be valid UUID400
Customer Object
customer object is required400
customer object must include at least one of customer.hsid, customer.enterpriseId, or customer.metadata400
customer.firstName cannot exceed 50 characters400
customer.lastName cannot exceed 50 characters400
customer.email must be a valid email address400
customer.email cannot exceed 120 characters400
customer.ssn must contain only digits and cannot exceed 4 characters400
customer.dateOfBirth must be a valid date in format YYYY-MM-DD400
customer.zip5 must be exactly 5 digits400
customer.phoneNumber.countryCode must contain only digits and must be 1 to 3 characters long400
customer.phoneNumber.number must contain only digits and must be 4-11 characters long400
customer.enterpriseIdentifier must contain only digits400
customer.hsid must be a valid UUID400
Business Rule Violation Error
merchantTransactionId not found422
Customer identifier missing422
Customer not found for given enterpriseIdentifier422
Payment method ending with {last4} is not configured. Please provide a valid payment method422
Manufacturer card ending with {last4} not enabled for this merchant. Please use a different payment method422
The sum of paymentAllocations[:].amount cannot exceed 100000000422
paymentAllocations[n].paymentMethodId not found. Please provide a valid payment method422
paymentAllocations[:].paymentMethodId must be unique422
Payment method ending with {last4} is invalid. Please provide a valid payment method422
This card requires an additional security step to be performed by the customer. Please have the customer enter the card via text or email; otherwise, have the customer provide a different payment method.422
Split payments cannot be processed using a bank account. Please select a different payment method422
The payment cannot be processed because the maximum retry limit for this merchantTransactionId has been reached422
agent.userId is required422
Payment Details Object
paymentDetails.qualifiedAmount is required when paymentDetails is provided422 UNPROCESSABLE ENTITY
sum of paymentDetails.qualifiedAmount and paymentDetails.visionAmount cannot exceed amount422 UNPROCESSABLE ENTITY
paymentDetails.prescriptionAmount cannot exceed paymentDetails.qualifiedAmount422 UNPROCESSABLE ENTITY
Payment processor error
Payment allocation processing failed for all records. Check individual records for error details422
Payment Allocation processor error
HTTP Status Codes
- Allocation-specific errors are returned at the allocation level under
paymentAllocations[n]within the parent processor response. - For allocation-level entries, the HTTP status is shown as NA, as it is inherited from the parent
422 UNPROCESSABLE_ENTITYresponse.
Error Code Coverage
- Error Code Coverage: Only the known and documented error-code combinations are listed here; additional combinations may occur.
- Vendor Error Details:
error.errorDetailsreflects data returned by the vendor. The structure is not guaranteed; all fields are optional and subject to change.
Payment method could not be authorized. Please try a different payment method.NA
The card was declined because the transaction requires authentication such as 3D Secure.NA
Payment method could not be authorized. This payment method requires authentication from a customer.NA
The card was declined for an unknown reason. Contact issuer for more information.NA
The card does not support this type of purchase. Contact issuer for more information.NA
The customer has exceeded the balance, credit limit, or transaction amount limit available on their card. Contact issuer for more information.NA
The card does not support the specified currency.NA
The card has expired.NA
The CVC number is incorrect.NA
The card number is incorrect.NA
The postal code is incorrect. Contact issuer for more information.NA
The customer's account has insufficient funds to complete the purchase. Please use an alternative payment method.NA
The card, or account the card is connected to, is invalid. Contact issuer for more information.NA
The payment amount is invalid, or exceeds the amount that's allowed. Contact issuer for more informationNA
The expiration month is invalid.NA
The expiration year is invalid.NA
The PIN entered is incorrect.NA
The card issuer couldn't be reached, please try again.NA
The card was declined because it requires a PIN.NA
An error occurred while processing the card, please try again.NA
Something went wrong and we are unable to complete your request. Please try again later.NA
Test card was used. Use valid card to make payment.NA
The card was declined for an unknown reason. Try again or contact issuer for more information.NA
The customer has exceeded the balance or credit limit available on their card. Please try another payment method.NA
IIAS information is required to authorize this HSA/FSA card.NA