1
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
Standard Integration
Manual V 1.0
2
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
Change Control
Date Responsible Version Description
November/10/2012 Diego Zarate R1 1. New Edition
April/12/2013 Angela Acosta R2 2. Updates chapters 2 and 4
3. Several Modifications
chapters 2,3,4,5,7 and 8
Mayo 23 Dana Duarte 4. Graphical adjustments;
pages index and hyperlinks.
3
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
Content
1. Transaction Flow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
2. Prerequisites of Standard Integration with PAYU . . . . . . . . . . . 11
3. Connecting with PAYU . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
3.1 Considerations about Variables. . . . . . . . . . . . . . . . . . . . 15
4. Payments Test . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .18
5. Response and Confirmation Pages . . . . . . . . . . . . . . . . . . . . 25
5.1 Configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
5.2 Response Page. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
5.3 Confirmation Page . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
6. Transactions in Live Mode . . . . . . . . . . . . . . . . . . . . . . . . . . 30
7. Annexes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
7.1 Conventions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
7.2 Variables that are sent to the Gateway . . . . . . . . . . . . . . 32
7.3 Code of Supported Currencies . . . . . . . . . . . . . . . . . . . . 36
7.4 Supported Languages . . . . . . . . . . . . . . . . . . . . . . . . . .37
7.5 States of the Transaction . . . . . . . . . . . . . . . . . . . . . . . .37
7.6 Response Code pol. . . . . . . . . . . . . . . . . . . . . . . . . . . . .38
7.7 Response Code lap . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40
7.8 Variables that are sent to the Response Page. . . . . . . . . . . 42
7.9 Variables that are sent to the Confirmation Page . . . . . . . . 46
8. Glossary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .50
4
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
1 Transaction
Flow
5
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
1. Transaction Flow
PAYU provides a complete platform for making transactions over the Internet in a fast,
safe, reliable and fully functional way. Through our platform, users and clients will find
a friendly and intuitive interface that offers a complete e-commerce experience.
Below we will show an approximation to the transaction flow: It begins on your
website, continues on our platform and once finished, returns again to your system,
where the payer must receive information about the transaction.
6
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
In this chapter we will review the general process that must exist between the
Merchant (Your Site) and our payment platform (gateway).
7
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
>> ¿How does it Work?
1. The process starts when the buyer enters to your Website and selects
products or services that he wishes to purchase. Your system must totalize the value of the purchase and connect to our system through the "Sending Page" sending a set of data through the POST method.
8
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
2. Our system validates this set, and then allows the customer to choose the payment
means with which he desires to make the transaction depending on the available
options for the country and merchant.
9
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
3. The bank processes the transaction and returns a response to the PAYU system.
10
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
4. Our system returns to the buyer a "Response page" within PAYU, which displays the
result of the transaction.
4.1. If the transaction is rejected or fails, the system will allow to retry the payment,
which will return the payer to select the desired payment means.
4.2. When you complete a transaction, that is, when it is approved or rejected,
information about the transaction is sent by POST method to the "Confirmation
Page" in which the merchant will be able to update the databases of your system.
11
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
5. In case that a credit card is used as payment mean; PAYU has a Fraud Control
Module that uses the latest artificial intelligence techniques to evaluate transactions.
Therefore, depending on the risk factor associated with a transaction, it can send a
transaction to a manual validation process, delaying the submission of the information
to the bank while corroborating the authenticity of the transaction. When this
happens, the state of the transaction sent to the "Response Page" will be in validation
and data will not immediately sent to the "Confirmation Page", until it is resolved as
approved or rejected.
12
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
Prerequisites of Standard Integration with PAYU LATAM
2
13
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
2. Prerequisites of a Standard Integration with PAYU LATAM
We recommend that you implement some kind of database, so that your system has
records of your transactions, but this is neither necessary nor required, as in the
secure administrative module https://secure.payulatam.com you will be able to find
the detail of all transactions.
For any type of integration you want to make, the first thing you must do is to get
an account with PAYU, in this way you will get a unique user (merchantId) that will
identify you in the system, and an APIKey that will allow you to make transactions.
This ApiKey is a crucial element for processing, as discussed below. To obtain it,
enter your administrative module and select the settings tab there, technical
information, as shown in the following image:
We obtain a set of data, some editable, relating to your setup in our system, the
first one is called ApiKey, which is the key to encrypt communication with PAYU.
For further information on the use, management and functions of the secure
administrative module, please consult the entire documentation that specifically
was created for you by PAYU.
14
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
Connecting
with PAYU LATAM
3
15
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
3. Connecting with PAYU LATAM
In this chapter, you will learn how to make connections with the PAYU platform. After
having the user data, you can begin to make connections with the payment platform;
this should generate an HTML form that points to the following URL, which is our
production server:
https://gateway.payulatam.com/ppp-web-gateway
Every time you connect, some data must be sent by POST method to the PAYU system.
The minimum delivery data are:
FIELD TYPE SIZE DESCRIPTION
merchantId N 12 It is the merchant identifier in the PAYU
system, you can find this number in the account creation email.
referenceCode A 50 It is the sale or order reference. It must be unique for each transaction which is send to the system.
description A 255 It is the sale description.
amount N 14,2 It is the transaction total amount. It can contain two decimal digits. Ex 10000.00 or 10000.
tax N 14,2
It is the value of the VAT (value added tax only valid for Colombia) of the transaction, if you send a void VAT, the system automatically will apply 16%. It may contain two decimal digits. For example: 16000.00. If you have no VAT, you must send a 0.
taxReturnBase N 14,2 It is the basic value on which we calculate the VAT (only valid for Colombia). If you have no VAT, you must send a 0.
16
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
However, the gateway handles other additional variables, which are useful for your
business model. To know these additional fields and the management of them please
refer to Annex I.
>> Considerations about the Variables
The referenceCode variable is unique for each transaction. Usually you identify the
requests that are sent to the payment gateway in this form.
The tax is a value added tax that may be used by some countries and the
taxReturnBase is the base value on which VAT is calculated.
If your product does not apply for this tax, both variables must have the value 0
(tax=0, taxReturnBase =0). On the contrary, if some elements are taxed and it does
not apply to others, you must make the following calculation to find out how to send
the values to the payment platform.
signature N 32 It is the digital signature created for each transaction
accountId N 12 Identifier of the user account for each country that a merchant has associated, this field is optional. To send it only deploy payment means belonging to that
country. Required Field only for Brazil and Mexico.
currency A 3 It is the relevant currency in which the payment is made. The reconciliation process is made in pesos at the representative rate of the day. See supported currencies in Annex 7.3
buyerEmail A 255
Field that contains the email of the buyer to notify him
the result of the transaction by email. Validation is
recommended if you add this data into a form.
17
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
Other data to you must sent is signature. It is a unique way to validate payments made
through the platform, ensuring its authenticity. It consists of a string of characters to
which a MD5 (SHA) algorithm is applied to encrypt it. The chain is composed as follows:
“ApiKey~merchantId~referenceCode~amount~currency".
ApiKey is a unique field for each PAYU affiliated merchant. To know your value, please
follow this link.
Product taxReturnBase tax Amount
A 100,000 16,000 (16%) 116,000
B 200,000 20,000 (10%) 220,000
C 0 0 (0%) 150,000
Total 300,000 36,000 486,000
Note: The amount of tax + taxReturnBase can not be more than the Total Value
18
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
We will illustrate this concept with an example. In order to do so, we will use the
following test data:
merchantId: 500238
ApiKey: 6u39nqhq8ftd0hlvnjfs66eh8c
referenceCode: TestPayU
amount: 3
currency: USD
accountId: 500537
buyerEmail: [email protected]
The signature is formed by the following elements
"6u39nqhq8ftd0hlvnjfs66eh8c ~500238~TestPayU~3~USD”
Which after applying the md5 algorithm would look like this:
“4025327fc18e2703dda1f89fbcab2b02”
In the example above we use U.S. Dollars. Please refer to Annex 7.3 to learn more
about the supported currencies.
19
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
Payments Test
4
20
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
4. Payments Test
When you are clear about what data should be sent to the payment platform for
processing operations, run some test payment with different payment methods, so you
can get clear of each part of the process.
As part of the test use the same parameters of the previous test, like this:
merchantId: 500238
ApiKey: 6u39nqhq8ftd0hlvnjfs66eh8c
referenceCode: TestPayU
accountId: 500537
description = Test PAYU
amount: 3
tax: 0
taxReturnBase: 0
currency: USD
signature: 4025327fc18e2703dda1f89fbcab2b02
test: 1
buyerEmail: [email protected]
You can include additional fields, however, to process a transaction previous fields are
sufficient. The field test = 1 is used to tell the system which is a test transaction.
Note: The use of the test field enables test transactions but to process them in test mode
it is also necessary to point to the test server.
21
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
Send these variables in a HTML form to the address:
https://stg.gatewaylap.pagosonline.net/ppp-web-gateway
And you will get access to the payment gateway, which should look like this:
22
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
>> The items listed on the payment gateway are:
1. First section you can view the payment details, there you will find the reference,
the value and description, also the user can select the language in which the
gateway will be displayed, including English, Spanish and Portuguese.
2. Next you will see the section that displays the Payments means; this will depend
specifically on the chosen country. In the picture you can see the Payment means
available for Colombia.
You can select the countries for which the payment means are enabled in the drop-
down list.
For this example, select the country of Panama and the credit Cards payment means
by clicking on the Pay button, the final payer will be oriented immediately to complete
the payment with the chosen means. In this case it is credit card payment.
23
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
3. Please keep in mind that you must choose a Credit Card Entity. For testing you can choose
VISA
In this case you must complete and fill out all the necessary data like credit card
number, quotas, among others as shown below:
4. Enter the data as shown in the image, which should not be a real credit card. When
the information is sent to the network, you get the answer, in this case successful
Transaction.
24
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
5. The platform will communicate the result to the user and give the opportunity to try
it again with another payment means.
25
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
6. Finally, an email will be sent to the buyer informing him the status of his
transaction.
26
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
Response and Confirmation
Pages.
5
27
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
5. Response and Confirmation Pages
5.1 Configuration
This section will explain the concepts and Response and Confirmation page, basic in the
process of feedback on transactions. The first thing to do is to configure these websites
in PAYU. You can do this is in the settings tab, click on the module configuration
administrative accounts.
These URL must include http:// or if you prefer you can set it up sending an additional
variable in the code by which you connect to our platform.
28
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
The names of the variables are:
confirmationUrl
responseUrl
This is the code you should enter in the submission form, (remember to customize your
data in red letters).
<input name="confirmationUrl" type="hidden"
value="http://www.shop.com/confirmation.php">
<input name="responseUrl" type="hidden" value="
http://www. shop.com/response.php">
Therefore, once the transaction is completed, the gateway will make calls to the
configured url.
The transaction values estimated by the signature both for the confirmation and
response page are decimal, to change these values you can use the following code:
New_value=number_format($Oldvalue, 1, '.', '');
The signature sent to the response page is sent in the "signature" field and the system
generates it in the following way:
“ApiKey~merchantId~referenceCode~TX_VALUE~currency~transactionState”
The signature sent to the confirmation page is sent in the "sign" field and the system
generates it in the following way:
“ApiKey~merchant_id~reference_sale~value~currency~state_pol”
29
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
5.2 Response page
At the end of a transaction our system sends the payer to the response page. Our system
sends information to this page through the GET method, in this manner the payer obtains
information about the state of a transaction.
5.3 Confirmation Page
The confirmation page allows you to update the databases on your system, this is the
reason why it should not include HTML code, since it will never be visible to the buyer.
When a transaction ends, that is, when it is approved, rejected or when it is canceled,
our platform sends the variables via the POST method.
You must make the capture of data you want to save in the database on the
confirmation page. This capture will depend on the programming language used.
30
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
Transactions in Live Mode
en Producción
6
31
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
6. Transactions in Live Mode
After performing all tests in the system and verifying that everything is working properly,
you can change to the production server. To do this, you need to be sure that all your
account details are in the code, that is, that your API KEY and user Id are correct.
You must first delete or change the test variable on the submission page as follows.
<input name="test" type="hidden" value="1">
or
<input name="test" type="hidden" value="0">
To review the transactions on your Web site, you must enter the administrative module
https://secure.payulatam.com y and go to the Reports tab. There you will see all the
transactions and generate reports as needed.
32
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
Annexes
7
33
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
7. Annexes
7.1 Conventions
7.2 Variables that are sent to the Gateway
FIELD TYPE SIZE DESCRIPTION
amount D 14 It is the total amount of the transaction. It may have two decimal digits. For example.. 10000.00 or 10000.
merchantId N 12
It is the identification number of your merchant in the PAYU system, you can find this number in the account creation email. Required Field.
referenceCode A 50 It is the reference of the sale or order. It must be unique for each transaction that is sent to the system. Required Field.
accountId N 12
It is the ID of the user account for each
partner country associated with the
merchant, when sending it only payment
methods belonging to that country are
shown. Required Field only for Brazil
and Mexico.
DATA TYPE DESCRIPTION
N Numerical
D Decimal (#.00)
AN Alpha numeric
L Logic (true, false)
F Date (YYYY-MM-DD HH:mm:ss)
34
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
description A 255 It is the description of the sale.
Required Field
tax N 14,2
It is the value of the VAT of the transaction, if you send a void VAT, the system automatically will apply 16%. It may contain two decimal digits. For example: 16000.00. If you have no VAT, you must send a 0. Required Field
taxReturnBase N 14,2 It is the basic value on which we calculate the VAT. If you have no VAT, you must send a 0. Required Field
signature N 32 It is the digital signature created for each transaction. Required Field
currency N 3
It is the relevant currency in which payment
is made. The reconciliation process is made
in pesos at the representative rate of the
day. See supported currencies in Annex 7.3
Required Field
adicionalValueFirstPay
N 14,2 Additional Value First Payment
test N 2 Variable to be able to test credit cards.
buyerEmail A 255
Field that contains the email of the buyer to
notify the result of the transaction by email.
Validation is recommended if you add this
data into a form.
additionalValue N 14,2 Non Commissionable Additional Value
lng A 3
Language in which you wish to show the
payment gateway. See supported languages
in Annex 7.4
35
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
extra1 A 255
Additional field to send information about
the purchase. For example, description in
case you want to show the purchase in the
response page.
extra2 A 255
Additional field to send information about
the purchase. For example, internal codes of
the products.
responseUrl A 255 The url of the response page.
confirmationUrl A 255 The url of the confirmation page.
payerFullName A 50 The name of the buyer. This value will be
taken to fill the credit card format.
payerDocument A 25
The identification number of the purchaser.
This value will be taken to fill the form of
credit cards.
mobilePhone A 50
The phone number of the buyer. This value
will be taken to fill to fill the credit cards
form and will be the contact telephone
number.
billingAddress A 255 The mailing address
shippingAddress A 255 The address for the delivery of the goods.
telephone A 50 The buyer's home phone.
officeTelephone A 50 The buyer’s daytime phone.
36
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
discount D - Discount value on the sale
algorithmSignature A 255 The digital signature’s encryption algorithm
(signature)
extra3 A 255
Additional field to send information about
the purchase. For example, internal codes of
the products.
template AN 255 Template for the payment page.
airline A 4 Code of the airline.
billingCity AN 50 City associated with the billing address.
shippingCity A 50 The City where the goods are delivered.
zipCode AN 20 Zip Code.
billingCountry AN 50 Country associated with the billing address.
shippingCountry A 50 The country where the goods are delivered.
buyerFullName AN 150 Full name of the buyer
paymentMethods A - Payment means types
administrativeFee D - Value of the administrative fee
37
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
taxAdministrativeFee D - Tax value of the administrative fee
taxAdministrativeFeeReturnBase
D - Base value of the administrative fee for tax
refund..
payerEmail AN 255 Payer’s email
payerPhone AN 20 Payer’s phone number
payerOfficePhone AN 20 Payer’s workplace phone number
payerMobilePhone AN 20 Payer's mobile phone number
7.3 Code Supported Currencies (Currency)
ISO 4217 CODE CURRENCY
COP Colombian Pesos
MXN Mexicans Pesos
USD U.S. Dollars
PEN Peruvian Soles
38
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
6.4 Supported Languages (lng)
7.5 Transaction states (state_pol or transactionState)
7.4 Estados de la Transacción (estado_lap) CÓDIGO
NAME DESCRIPTION
2 NEW Initial state of the transaction.
101 FX_CONVERTED Returned by the currency converter, indicating the
modification carried out.
102 VERIFIED Indicates that the transaction was assessed by our anti-
fraud module.
103 SUBMITTED Transaction was sent for processing to payment provider.
4 APPROVED The transaction was approved by the financial institution.
6 DECLINED Transaction was Declined or Abandoned.
104 ERROR There was an error with external payment means
7 PENDING Operation pending finalization.
5 EXPIRED Transaction expired for exceeding response time limit.
CÓDE ISO 639 Languages
EN English
ES Spanish
PT Portuguese
39
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
7.6 Response Code (polResponseCode)
CÓDE DESCRIPTION
1 Transaction Approved
4 Transaction rejected by the entity
5 Transaction declined by the financial institution
6 Insufficient Funds
7 Invalid card
8 It is necessary to contact the entity
9 Expired card
10 Restricted card
12 Expiration date or security field Invalid
13 Repeat transaction
14 Invalid transaction
15 Transaction sent to Manual Validation
17 Amount exceeds maximum allowed by entity
22 Card not authorized to make purchases online
23 Transaction Rejected by the Fraud Control Module
40
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
50 Transaction Expired, before being sent to the network of the payment means
51 A processing error occurred in the Payment Means Network
52 The payment means is not active No request is sent to the Payment Means
Network
53 Bank not available
54 The provider of the payment means notified that the transaction was not
accepted
55 Error converting the transaction amount
56 Error converting amounts of deposit
9994 Transaction pending confirmation
9995 Digital Certificate not found
9997 Messaging error with the financial entity
10000 Adjusted Automatically
10001 Automatic Adjustment and Successful Reversion
10002 Automatic Adjustment and Failed Reversion
10003 Automatic Adjustment not supported
10004 Error in the Adjustment
10005 Error in the adjustment and reversion
41
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
7.7 Response Code (lapResponseCode)
STATE DESCRIPTION
APPROVED The transaction was approved
DECLINED The transaction was rejected
ERROR An error occurred processing the transaction
PENDING The transaction is pending
ENTITY_DECLINED The transaction was declined by the bank
ANTIFRAUD_REJECTEDTED The transaction was rejected by the fraud control system
PENDING_TRANSACTION_REVIEW The transaction was stopped and must be revised, this can occur due to security filters
INTERNAL_PAYMENT_PROVIDER_ERROR
An system error occurred trying to process the payment
INACTIVE_PAYMENT_PROVIDER The payment provider is not active
DIGITAL_CERTIFICATE_NOT_FOUND
The financial network reported an error in the authentication
PAYMENT_NETWORK_REJECTEDTED
The financial network rejected the transaction
INVALID_EXPIRATION_DATE_OR_SECURITY_CODE
The security code or expiration date is invalid
INSUFFICIENT_FUNDS The account does not have sufficient funds
42
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
CREDIT_CARD_NOT_AUTHORIZED_FOR_INTERNET_TRANSACTIONS
The credit card is not authorized for Internet transactions
INVALID_TRANSACTION The financial network reported that the transaction is invalid
INVALID_CARD The card is invalid
EXPIRED_CARD The card has expired
RESTRICTED_CARD The card has a restriction
CONTACT_THE_ENTITY You should contact the bank
REPEAT_TRANSACTION You must repeat the transaction
ENTITY_MESSAGING_ERROR The financial network reported a communication error with the bank
PENDING_TRANSACTION_CONFIRMATION
The transaction is subject to confirmation
BANK_UNREACHABLE The bank is not available
EXCEEDED_AMOUNT The transaction exceeds the amount set by the bank
NOT_ACCEPTED_TRANSACTION The transaction was not accepted by the bank for any reason
ERROR_CONVERTING_TRANSACTION_AMOUNTS
An error occurred converting the amounts to the payment currency
43
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
7. 8 Variables that are sent to the Response Page
FIELD TYPE SIZE DESCRIPTION
merchantId N 12 It is the number of the identifier of
merchant in the PAYU system, this number
can be found in the account creation email.
transactionState N 2
Indicates the status of the transaction in the system.
risk D - The risk associated with the transaction It takes a value between 0 and 1. At higher risk there is greater value. It is in ###.00 format
polResponseCode AN 64 The PAYU answer code
referenceCode A 50 It is the reference to the sale or order. Must be unique for each transaction that is sent to the system.
reference_pol AN 255 The reference or transaction number
generated in PAYU
signature AN 255 The digital signature created for each transaction.
polPaymentMethod A 255 The internal identifier of the used payment means
polPaymentMethodType N 2 The payment means type used to pay.
installmentsNumber N 2 Number of installments with which credit card payment was deferred.
TX_VALUE N 14,2 It is the total amount of the transaction May have two decimal digits For example 10000.00 OR 10000
44
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
TX_TAX N 14,2 It is the value of the VAT (value added tax only valid for Colombia) of the transaction, if you send a void VAT, the system automatically will apply 16%. It may contain two decimal digits. For example: 16000.00. If you have no VAT, you must send a 0.
buyerEmail AN 255 Field that contains the email of the buyer to notify the result of the transaction by email. Validation is recommended if you add this data into a form.
processingDate F - The date on which the transaction occurred.
currency A 3 The relevant currency in which payment is made The reconciliation process is done in pesos to the representative rate of the day See supported currencies in Annex
cus AN 255 The cus, unique tracking code is the reference of payment within the Bank applies only to payments with PSE
pseBank AN 255 The name of the bank, applies only to
payments with PSE.
lng A 2 Desired language to show on the payment gateway. See supported languages in the Annex.
description A 255 It is the description of the sale
lapResponseCode AN 64 See Annex 7.7
lapPaymentMethod A 255 Means of payment with which payment was made, for example VISA
lapPaymentMethodType A 255 Means of payment type, for example CREDIT_CARD
45
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
lapTransactionState A 32 See Annex 7.5
message A 255 Description of the state of the transaction
extra1 A 255 Additional field to send information about the purchase For example, description of the purchase, in case you want to show it on the response page
extra2 A 255 Additional field to send information about the purchase, for example, Internal codes of the products.
extra3 A 255 Additional field to send information about the purchase, for example, Internal codes of the products.
authorizationCode AN 12 Authorization Code of the sale.
merchant_address AN 255 Merchant address
merchant_name AN 255 Merchant name.
merchant_url AN 255 Website URL of the merchant.
orderLanguage A 2 Language of the order (ISO-639-1)
pseCycle N - PSE generated identifier
pseReference1 AN 255 Reference no. 1 for PSE payments.
pseReference2 AN 255 Reference no. 2 for PSE payments.
pseReference3 AN 255 Reference no. 3 for PSE payments.
telephone AN 20 Telephone number of the merchant.
46
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
transactionId AN 36 Transaction identifier
trazabilityCode AN 64 Sales tracking code of the merchant site
TX_ADMINISTRATIVE_FEE D - Value of the administrative fee
TX_TAX_ADMINISTRATIVE_FEE D - Tax value of the administrative fee
TX_TAX_ADMINISTRATIVE_FEE
_RETURN_BASE
D - Base value of the administrative fee for tax refund
action_code_description * AN 255 Description of the VISANET response code
cc_holder * AN 150 Name of cardholder
cc_number * AN Number of credit card. PAN
processing_date_time * F - Date and time of sale processing
request_number * AN 9 Order number + transaction identifier.
Note: * These variables only apply for VISANET Peru
47
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
9 Variables that are Sent to the Confirmation Page
FIELD TYPE SIZE DESCRIPTION
merchant_id N 12
It is the number identifier of the merchant
in PAYU system, this number can be found
in the account creation email.
state_pol A 32 Indicates the status of the transaction in the system
risk D - The risk associated with the transaction It takes a value between 0 and 1. At higher risk there is greater value. It is in ###.00 format
response_code_pol AN 255 PAYU’s response code
reference_sale AN 255 It is the reference to the sale or order. Must be unique for each transaction that is sent to the system.
reference_pol AN 255 The reference or transaction number
generated in PAYU
sign AN 255 It is the digital signature is created for each transaction.
extra1 A 255
Additional field to send information about the purchase For example, description of the purchase, in case you want to show it on the response page
extra2 A 255 Additional field to send information about the purchase, for example, Internal codes of the products.
payment_method N - The internal identifier of the payment means used.
payment_method_type N - Type of payment means used for payment
48
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
installments_number N - Number of installments with which credit card payment was deferred.
value N 14,2 It is the total amount of the transaction Holds two decimal digits For example 10000.00 or 10000.
tax N 14,2
It is the value of the VAT (value added tax only valid for Colombia) of the transaction, if you send a void VAT, the system automatically will apply 16%. It may contain two decimal digits. For example: 16000.00. If you have no VAT, you must send a 0.
additional_value N 14,2 Non Commissionable Additional Value.
transaction_date F - The date on which the transaction occurred.
currency A 3
The relevant currency in which payment is made. The reconciliation process is done in pesos atthe representative rate of the day. See supported currencies in Annex
email_buyer A 255
Field that contains the email of the buyer to notify the result of the transaction by email. Validation is recommended if you add this data into a form.
cus AN 64 The cus, unique tracking code is the reference of payment within the Bank applies only to payments with PSE
pse_bank AN 255 The name of the bank, applies only to payments with PSE.
test L - Variable to identify whether the operation was a test.
description A 255 It is the description of the sale
billing_address A 255 The billing address
49
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
shipping_address AN 50 The address for delivery of the goods.
phone AN 20 The buyer's home phone.
office_phone AN 20 The buyer's daytime phone.
account_number_ach AN 36 Transaction identifier.
account_type_ach AN 36 Transaction identifier.
administrative_fee D - Value of the fee administrative
administrative_fee_base D - Base value of the administrative fee
administrative_fee_tax D - Tax value of the administrative fee
airline_code A 4 Code of the airline.
attempts N - Number of attempts to send confirmation.
authorization_code AN 12 Authorization Code of sale
bank_id A 255 Bank Identifier
billing_city A 255 The billing city
billing_country A 255 The billing country
commision_pol D - Value of the commission
commision_pol_currency A 3 Currency of commission
customer_number N - Number of customer
date F - Date of operation.
50
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
error_code_bank AN 255 Bank’s error code
error_message_bank AN 255 Bank’s error message
exchange_rate D - Value of the exchange rate.
ip AN 39
IP address from which the transaction occurred.
nickname_buyer AN 150 Short name of the buyer.
nickname_seller AN 150 Short name of the seller.
payment_method_id N - Identifier of the payment mean.
payment_request_stateñ A 32 State of the payment request.
pseReference1 AN 255 Reference no. 1 with PSE payments.
pseReference2 AN 255 Reference no. 2 with PSE payments.
pseReference3 AN 255 Reference no. 3 with PSE payments.
response_message_pol AN 255 PAYU’s response message
shipping_city AN 50 City of delivery of the goods.
shipping_country A 2 Country of delivery of the goods
transaction_bank_id AN 255 ID of the transaction in the bank's system
transaction_id AN 36 Transaction identifier
51
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
8 Glossary
52
PAYU LATAM / www.payulatam.com / [email protected]
TRADITIONAL INTEGRATION
MANUAL V 1.0
POST Method: it is a method in which a form sends information, the main feature
of this method is that it sends the data encoded in the HTTP data stream and the
data will not be visible to the user.
GET method: it is a method in which a form sends information, the main feature
of this method is that it sends the data using the url, which is why the data will
be visible to the user.
Secure: it is the administrative module provided by PAYU. In it you can consult
transactions and obtain the necessary information to perform the integration. In
order to access it you must go to https://secure.payulatam.com.
merchantId: is the unique identifier of each PAYU merchant. In order to get a
User ID it is necessary to purchase a PAYU account.
API KEY: it is an alphanumeric value that is used to encrypt the communication
between PAYU and your website, you can get the secure administrativeg module
(https://secure.payulatam.com).
Production Server: it is the server where all real transactions are processed in
PAYU. In order to have an application pointing to the production server, it should
be pointed to:
https://gateway.payulatam.com/ppp-web-gateway
Tests server: it is the server you should use during the integration development
process, in order to simulate the different states of transactions. In order to have
an application pointing to the test server, it should be pointed to:
https://stg.gatewaylap.pagosonline.net/ppp-web-gateway/
Response Page: it is the page that the purchaser will be sent to once he
completes the transaction in PAYU, on this page you must show the status of the
transaction, this site can be configured in the secure administrative module or
you must send it in the responseUrl variable.
Confirmation page: it is the page to which PAYU will send the payment
confirmation once the transaction reaches a final state. This page should not
contain html code, as it is for the use of your system and not for the buyer, this
page may be configured in the secure administrative module or you must send it
in the responseUrl variable.