Service endpoints
There are two endpoints (base URLs) to which you can make your API calls:
- Stage, if you are testing your integration,
- and Production, when you have finished testing and want your application to go live.
Environment |
Endpoint |
Stage |
|
Production |
Request parameters
To create a Boleto Bancário transaction on the HiPay Enterprise Payment Gateway, you must send these mandatory/complementary parameters in your transaction creation call.
(For further details, please refer to the technical documentation.)
Format abbreviation |
Description |
AN |
Alphanumeric characters (a-z, A-Z, 0-9) |
A |
Alphabetic characters only (a-z, A-Z) |
N |
Numeric characters only |
Field name |
Format |
Req. |
Description |
payment_product |
AN |
M |
Payment product In the case of Boleto Bancário: “boleto-bancario” |
language |
AN |
M |
Locale code of your customer Boleto Bancário is only available in Brazil through HiPay. Therefore, the value must be “pt_BR”. |
country |
A |
M |
Country code of the customer This two-letter country code complies with ISO 3166-1 (alpha 2). Boleto Bancário is only available in Brazil through HiPay. Therefore, the value must be “BR”. |
gender |
A |
M |
Gender of the customer (M = male, F = female) |
firstname |
AN |
M |
Customer’s first name |
lastname |
AN |
M |
Customer’s last name |
streetaddress |
AN |
M |
Street name of the customer’s address Example: Rua General Osorio |
zipcode |
N |
M |
Zip or postal code of the customer Example: 13010 |
city |
AN |
M |
Customer’s city |
|
AN |
M |
Customer’s email address |
ipaddr |
AN |
M |
IPv4 address of the purchasing customer |
national_identification_number |
AN |
M |
In Brazil, the national identification number of the customer is called "Cadastro de Pessoas Físicas (CPF)". This field is only mandatory if you call the "order" API; in the "hpayment" API, HiPay will ask the customer to fill it out. |
Example
{
"email": "john.doe@hipay.com",
"eci": "7",
"gender": "M",
"firstname": "john",
"lastname": "doe",
"streetaddress": "Rua General Osorio",
"zipcode": "13010",
"city": "Campinas",
"description": "This is the description of my order",
"ipaddr": "77.156.225.124",
"currency": "BRL",
"payment_product": "boleto-bancario",
"orderid": "578cdb0fda266",
"language": "pt_BR",
"country": "BR",
"amount": "52.99",
"accept_url":"https://www.mysite.com/accept",
'decline_url":"https://www.mysite.com/decline",
'exception_url":"https://www.mysite.com/exception",
'cancel_url":"https://www.mysite.com/cancel",
}
API response
This service creates an order and returns a forward URL. This forward URL is dedicated to display a Boleto Bancário payment page. After payment validation, HiPay will send a server-to-server notification to inform the merchant about the result of the transaction.
(For further details, please refer to the technical documentation.)
Response example (hpayment)
{
"forwardUrl":"https:\/\/secure-gateway.hipay-tpp.com\/payment\/web\/pay\/2x624359465x03f51x0533x9",
"test":"false",
"mid":"00001234567",
"cdata1":"My data 1",
"cdata2":"My data 2",
"cdata3":"My data 3",
"cdata4":"My data 4",
"cdata5":"",
"cdata6":"",
"cdata7":"",
"cdata8":"",
"cdata9":"",
"cdata10":"",
"order":{"id":"578cdb0fda266","dateCreated":"2017-03-20T10:22:04+0000","attempts":"0","amount":"52.99","shipping":"0.00","tax":"0.00","decimals":"2","currency":"BRL","customerId":"1234567","language":"pt_BR","email":"john.doe@hipay.com"}}
Commenti
0 commenti
Questo articolo è chiuso ai commenti.