Each response has a GeneralResponse section that informs about a successful result or error, with an error code and description.

It contains the following data:

ParameterComment
HostResponseCodeThis response code comes from the payment processor as is. It is usually referring to ISO 8583-1987.
HostResponseMessageMeanings for host response code that comes from the payment processor as is. It is usually referring to ISO 8583-1987.
ResultCode0 - success
1 - terminal's error
2 - SPIn proxy error
StatusCodeShows specific 4-digit response code for specific situation or terminal statement.

There are 3 basic sets of 4-digit codes depending on the side of the SPIn transaction, the place where this message comes from, and the result of the transaction. The number of sets may be extended in the future. The logic is close to HTTP Status Codes.

0xxx - successful responses from terminal application. The response comes from a terminal application.
1xxx - error responses from terminal app. The response was sent from a terminal.
2xxx - error response from SPIn Proxy server. The response did not reach the terminal, or the terminal did not provide a response in an appropriate time.

See the list of possible status codes below.
MessageShort message about response status.
DetailedMessageText message in English that describes the Status Code.

Register application may show this message or use StatusCode only and show their own messages for every StatusCode. For example, if a register needs to show messages not in English, they may add a translation for every code on their side.
DelayBeforeNextRequestTime in seconds that is recommended to wait before sending the next request. This returns when the SPIn Proxy service is busy with a previous request.

StatusCode list of values

0xxx - Successful responses from terminal application

Status CodeDetailed MessageDescription
0000ApprovedThe transaction or a service request was approved.
0001Partial ApprovalThe transaction was partially approved by the host.
One or more (but not all) applications approved the settlement request.

NOTE: On the test host, for partial approval you need to make a sale with 50baseamountand50 base amount and 2 tips - TSYS (depends on the host).

1xxx - Error responses from terminal app

Status CodeDetailed MessageDescription
1000Terminal BusyThe terminal is busy processing another SPIn request.
The terminal is in SPIn bypass mode.
1001Not FoundGet Parameter or Set Parameter service could not find requested parameters.
Status request could not find a matching transaction record.
Void request could not find a matching transaction record.
Tip Adjustment request could not find a matching transaction record.
Get request could not find matching transaction records.
TSYS level 3 request could not find a matching transaction record.
1002Not ImplementedUnsupported service requested (Invoice, GetCard, etc.).
1003Not SupportedGet PIN service request could not find a proper payment application.
Tip Adjustment request could not find a proper payment application.
Upload SnF request could not find a proper payment application.
Batch Report request could not find a proper payment application.
Disclaimer service requested on a terminal with no touch capability.
1004Not AllowedA Void Auth requested for a processor that does not allow Void Auth.
A non-EBT voucher transaction requested.
A manual Debit card entry attempted and the processor is not BridgePay.
A tip amount is sent in an Auth request.
A custom fee is sent in an Auth or EBT request.
1005Low BatteryBattery charge is low.

NOTE: not implemented on Android devices.
1006Internal ErrorPrinter service requested when the terminal is out of paper.
Unexpected internal terminal error happened.
1007Format ErrorThe SPIn request uses an unsupported markup language or the request is malformed.
1008Wrong Payment Or Transaction TypeThe transaction request uses an incorrect or inapplicable payment or transaction type.
1009Authentication FailedAuthentication failed (auth key mismatch). Usually this means you need to pull parameters on a terminal or check that the register sends the correct AuthKey.
1010Missing Reference IDThe reference ID is missing in a request that requires it.
1011Duplicate Reference IDA transaction with a requested reference ID already exists in the batch.
1012CancelledUser cancelled the transaction, or it was interrupted for an unknown reason.
1013Bad RequestIncorrect printer service request.
User Choice service request has no nested items to choose from.
User Input service request does not specify the input type.
Software Download service request is missing one or more mandatory parameters.
Load Key or Delete Key service request is missing one or more mandatory parameters.
A transaction request has no payment or transaction type.
0 amount requested for an inapplicable transaction.
Amount length is invalid.
Invalid ATM amount for PointOfBanking or BridgePay.
A tip amount is sent when tip is disabled or in "on percent" mode.
Cashback amount of 0 entered by the user when the terminal is configured for a non-zero cashback.
Fee, tip, and cashback amounts are greater than the total amount of the transaction.
Invalid clerk ID requested.
Tip Adjustment request has no amount, tip, or reference ID.
Get request is missing range parameters.
Get request has an invalid range.
TSYS level 3 request has no auth code.
1014Communication ErrorCommunication error with a third-party host occurred.
1015DeclinedLoad Key or Delete Key request failed.
Settlement requested with no payment applications installed.
A transaction is declined offline or by the host.
A settlement request is declined by the host.
1016Payment Type MismatchPayment type of the transaction is not applicable for the card.
1017Incorrect Merchant IDInvalid merchant ID specified in request.
1018PINpad Communication ErrorA communication error with the PINpad device occurred.
1019No Debit Keys LoadedAn encrypted PIN was requested by the transaction, but the terminal has no keys loaded.
1020No Open BatchNo application has an open batch during a settlement request.
1021Pending SnF TransactionSettlement has been requested, but the terminal is in SnF mode and has pending transactions to upload.
1022Untipped Transactions RemainSettlement has been requested, but the terminal is in restaurant mode and has untipped transactions.
1023Open TabSettlement has been requested, but the terminal has an open tab.

20xx - Error response from SPIn Proxy Server

Status CodeDetailed MessageDescription
2001Terminal not connected to SPIn Proxy serverNeed to check that the terminal has a connection to the Internet and to SPIn proxy, and shows that it is ready for transaction.
2002Active AuthKey not foundAuthKey in request is wrong or does not exist. Usually this means a misprint in AuthKey.
2003Register not foundTPN wrong or does not exist.
Possible that the request goes to the wrong server (test instead of prod, or vice-versa).
2004Route not foundTPN does not have configuration for SPIn proxy.
2005Active route not foundConnection was blocked on the server side.
Terminal is not active.
Two or more devices used the same TPN.
2006Not pars requestInvalid request; it may happen if there's extra space in some values.
2007The operation has timed outTerminal did not provide a response during the timeout time. Default timeout is 120 seconds. Settlement default timeout is 420 seconds.
2008Terminal in useTerminal is operating on a previous request; in this case the API returns DelayBeforeNextRequest in GeneralResponse as a recommendation of the time until the timeout will happen.
2009Transaction not found
2010Communication error
2011Terminal is not available

21xx - Error response from SPIn Proxy Server Async Requests with Call-back

Status CodeDetailed MessageDescription
2101Callback Url was not specified
2102Invalid XML document
2110Internal exception

Response

200

Response Attributes

GeneralResponse — object

AttributeType
HostResponseCodestring
HostResponseMessagestring
ResultCodestring
StatusCodestring
Messagestring
DetailedMessagestring
DelayBeforeNextRequeststring

400

Response Attributes

GeneralResponse — object

AttributeType
ResultCodestring
StatusCodestring
Messagestring
DetailedMessagestring
DelayBeforeNextRequeststring

Response

{
  "GeneralResponse": {
    "HostResponseCode": "00",
    "HostResponseMessage": "APPROVAL-Approved and completed",
    "ResultCode": "0",
    "StatusCode": "0000",
    "Message": "Approved",
    "DetailedMessage": "APPROVAL VTLMC1",
    "DelayBeforeNextRequest": null
  }
}
{
  "GeneralResponse": {
    "ResultCode": "1",
    "StatusCode": "1013",
    "Message": "Bad Request",
    "DetailedMessage": "Bad Request",
    "DelayBeforeNextRequest": null
  }
}

Last updated on