Quick Start: Your First Transaction
This quick start guide walks you through performing your first test payment using Get Central. By the end of this tutorial, you will have:
- initialized the middleware,
- executed a payment operation using
PAGO, and - validated the transaction result using the XML response.
This guide focuses strictly on the minimal happy path, without covering advanced scenarios such as refunds, pre-authorizations, or recurring payments.
This flow applies to TPVPC Implantado.
Requirements
Before you begin, ensure the following prerequisites are met:
- Get Central middleware installed on a supported workstation
- PIN Pad hardware connected and recognized by the operating system
- Test credentials (
cComercio,cTerminal,cClaveFirma) provided by your acquiring entity
Note: Some installations support simulation or test environments. Availability depends on the credentials and configuration supplied by the acquiring entity.
First Transaction Process
The first transaction consists of three mandatory steps:
- Initialize the middleware
- Execute a payment operation (
PAGO) - Validate the transaction result
Step 1: Initialize the Middleware
Initialization must be performed once per application lifecycle before executing any operation. A successful initialization prepares communication with the PIN Pad and enables payment execution.
| Parameter | Type | Required | Description |
|---|---|---|---|
cComercio | String | Yes | Merchant identifier assigned by the acquiring entity. |
cTerminal | String | Yes | Terminal identifier associated with the PIN Pad. |
cClaveFirma | String | Yes | Signature key assigned to the merchant and terminal. |
cConfPuerto | String | No | Optional communication port. |
cVersion | String | No | Optional protocol version. |
Here's an example of how to initialize the middleware:
csharp
int result = fnDllIniTpvpcLatente(
"99999999", // cComercio
"00000001", // cTerminal
"CLAVE123456", // cClaveFirma
"", // cConfPuerto
"" // cVersion
);
if (result != 0)
{
// Initialization failed. Do not proceed.
}csharp
int result = fnDllIniTpvpcLatente(
"99999999", // cComercio
"00000001", // cTerminal
"CLAVE123456", // cClaveFirma
"", // cConfPuerto
"" // cVersion
);
if (result != 0)
{
// Initialization failed. Do not proceed.
}A return value of
0 indicates that the middleware is ready for operations. Any other value indicates a technical error.TPVPC Implantado:cConfPuertoandcVersionmay be provided when required by the deployment. If one is specified, the other must also be specified.
Step 2: Execute a Test Payment (PAGO)
Once initialization succeeds, you can execute a payment operation using
cTipoOper = "PAGO". This operation performs a standard card-present payment and captures the funds immediately.| Parameter | Type | Required | Description |
|---|---|---|---|
cImporte | String | Yes | Transaction amount in decimal format XXXXXXXXX.XX (for example, 1.00). |
cFactura | String | Yes | Unique merchant reference for the transaction. |
cTipoOper | String | Yes | Must be set to PAGO. |
Important: The currency is determined by the terminal configuration and is not passed as a parameter in card-present payment operations.
Here's an example of how to execute a payment operation:
csharp
StringBuilder xmlResponse = new StringBuilder(8192);
int result = fnDllOperPinPad(
"1.00", // cImporte
"TEST0001", // cFactura
"PAGO", // cTipoOper
xmlResponse,
xmlResponse.Capacity
);
if (result != 0)
{
// Execution failed. Handle technical error.
}csharp
StringBuilder xmlResponse = new StringBuilder(8192);
int result = fnDllOperPinPad(
"1.00", // cImporte
"TEST0001", // cFactura
"PAGO", // cTipoOper
xmlResponse,
xmlResponse.Capacity
);
if (result != 0)
{
// Execution failed. Handle technical error.
}When the operation starts, the PIN Pad prompts the cardholder to insert, swipe, or tap the card. Once the operation completes, the XML response buffer is populated.
TPVPC Implantado: in transparent deployments, merchant-facing messages can be handled by the POS application.
Step 3: Validate the Transaction Result
After execution, the XML response must be parsed to determine whether the payment was authorized.
| XML Tag | Type | Description |
|---|---|---|
<estado> | String | Execution state. Finalized operations use value F. |
<resultado> | String | Financial result (Autorizada or Denegada). |
<codigoRespuesta> | String | Authorization or response code returned by the host. |
<pedido> | String | Merchant reference (cFactura). |
The transaction must be considered AUTHORIZED only if the XML contains:
xml
<estado>F</estado>
<resultado>Autorizada</resultado>xml
<estado>F</estado>
<resultado>Autorizada</resultado>Any other combination must be treated as DENIED or FAILED, even if the execution return code was
0.Persist the merchant reference and authorization data, as they are required for refunds, queries, and reconciliation.
Next Steps
Now that you have processed your first transaction, you can deepen your integration by exploring:
- Process a Refund - Learn how to reverse authorized payments.
- Request Parameters Reference - Complete list of technical arguments for all operations.
On this page
Quick Start: Your First Transaction