6) Terminal Payment Create
Merchants should send mobile payment request to api.paym.es service as follows.
order_create
POST
https://api.paym.es/v4.6/order_create
The first step to getting mobile payments via Paymes is creating a Payment request.
You can send the data shown below as an HTTP Post Request to Paymes to create a payment request. If the information is OK, your request to create a mobile payment transaction is approved and the necessary information is sent to the mobile phone number to complete the payment. Card information can be sent to Paymes servers in 2 different ways; via a Hosted Payment Page that developed and maintaned by Pamyes, or using Paymes API via HTTP Post Request method. It is sufficient to use only one of these two different methods. If there is no error in the card information, the URL to which the buyer will be directed for 3D verification is sent as a reply.
Request Body
publicKey*
string
Your public key
orderId*
string
Unique variable in your system so that you can follow the payment process
price*
string
Payment price amount Example: 10.00
currency*
string
"TRY", "USD", EUR"
productName*
string
The name or stock code of the product
buyerName*
string
The name and surname of the buyer.
buyerPhone*
string
Phone number of the buyer.
buyerEmail*
string
Email of the buyer.
buyerAddress*
string
Address of the buyer.
hash*
string
Base64 encoded string of SHA512 hash of data sent. It is detailed below.
create_order_by_kiosk*
boolean
true
Generating Hash Information
To generate hash; concatenate strings in this order: "orderId + price + currency + productName + buyerName + buyerPhone + buyerEmail + buyerAddress + secretKey" Get the hash of the string with SHA512 (SHA1 512). Encoding this output should be base64
For example, a hash value that created using the following values:
Combine these variables via the string concatenate method:
If this string is hashed with the SHA512 method and then the output is encoded with base64, the output will be in the following string:
If the hash is sent incorrectly, the request will fail.
If the payment request with the terminal is successful, you can make a payment from the terminal with the invoiceCode
parameter included in the response.
When the payment process with the terminal is completed, the result of the transaction is sent to your webhook URL address.
Last updated