Getnet DocsGetnet Docs

Result Codes and Errors

The Get Mini framework reports transaction status and errors through standard NSError objects in delegate callbacks and specific status properties within the RespuestaTransaccionDTO result.

SDK Error Codes

Errors are returned via the NSError parameter in methods like onPaymentFinished or onInitFinished. The code property corresponds to the library’s internal error table.

Common Library Errors (NSError.code)

CodeStatus ConstantDescription
0STATUS_OKOperation completed successfully.
1STATUS_KO_ACCESO_DATOSError accessing the local database (SQLite).
11STATUS_KO_DATOS_MAL_FIRMADOSMessage signature is incorrect.
28STATUS_KO_USER_BLOQUEADOThe user account is blocked.
78STATUS_KO_OPERACION_FALLIDAWeb Service operation failed.
117—Denegada por pin online incorrecto (Incorrect online PIN).
999—Indeterminate error.
1040—PIN pad not operational.

TPV-PC Specific Errors

These codes often appear when processing refunds or specific terminal operations.

CodeTPV-PC CodeDescription
200TPV-PC0009Refund amount exceeds the original transaction amount.
232TPV-PC0058Specified currency does not match terminal currency.
241TPV-PC0071Merchant does not have Pre-authorizations enabled.
250TPV-PC0084Card reading error (Check reader or card status).
252TPV-PC0087System busy. Retry after a few moments.
258TPV-PC0094No more confirmations allowed for this pre-authorization.

Transaction Result Values

For finalized payments, the result is delivered in a RespuestaTransaccionDTO. You must evaluate the estado and resultado fields to determine the outcome.

Estado (Transaction State)

ValueDescription
“F”Finalizada (The process reached the server and finished).
“P”En proceso (Still being processed).
“G”Denegada (The transaction was declined).
“A”Anulada (The transaction was cancelled/annulled).
“T”Fallo técnico (A technical error occurred during processing).

Estado == "F" does NOT mean the payment was approved. It only means the gateway responded. Always check the resultado field.

Resultado (Decision)

ValueDescription
“Autorizada”The transaction was approved by the issuer.
“Denegada”The transaction was declined by the issuer or gateway.

Authorization Response Codes

The codigoRespuesta property in RespuestaTransaccionDTO (or RespuestaBoletaDTO) contains the host’s authorization code (for approved sales) or the specific denial code.

Branch on resultado, which returns "Autorizada" or "Denegada", rather than on the code value. Log codigoRespuesta with the transaction so that the support team can trace a decline.

Progress Monitoring

The SDK provides real-time updates through two primary callbacks. Use these to update your UI during hardware interaction.

onInitProcess (Initialization)

Reports progress during connectAndConfigureDevice. Messages are typically strings like:

  • “Cargando claves…” (Loading keys)
  • “Configurando terminal…” (Configuring terminal)

onPaymentProcess (Payment)

Reports progress during payWithPinpadBluetooth. It notifies the UI of state changes such as:

  • Waiting for card insertion.
  • PIN entry requested.
  • Connecting to host for authorization.

Best Practices for Error Handling

  1. Evaluate NSError first: If the NSError parameter is not nil, the transaction failed before reaching the gateway (e.g., Bluetooth loss or library timeout).
  2. Handle Code 117: Always provide a specific message for code 117 (“Incorrect PIN”) as this is the most common user-correctable error.
  3. Check Merchant Profile: If you receive errors 241 or 273 consistently, use PerfilComercioManager to verify your terminal’s enabled features (Pre-authorizations, Manual Entry).
  4. Log IdentificadorRTS: For any error that occurs after the “Authorizing” phase, log the identificadorRTS to facilitate support troubleshooting with Get Mini.