Payment Confirmation
v1/transaction/charge
Last updated
v1/transaction/charge
Last updated
The service that the credit card payment process is finalized and the relevant amount is withdrawn from the credit card.This service is initializes by Paynet.js or Paynet-custom.js in custom form and embedded form integrations. To use this service, session_id and token_id information that Paynet.js posted to your server are required.
You should perform basic authentication with secret_key to use payment service. See more
https://api.paynet.com.tr/v1/transaction/charge
In the example below, the session_id and token_id are taken and sent to the payment confirmation service.
Parameter Name
Type
Required
Description
session_id
string
Yes
Parameter that Paynet.js attacht to your form.
token_id
string
Yes
Parameter that Paynet.js attacht to your form.
amount
string
Yes
The amount parameter sent to this service is compared with the amount that set with the data-amount parameter when starting the payment process in embedded form or custom forms integration. If the amounts do not match, the payment process cannot be completed and the payment service returns an error. The amount sent to this service should be the same as the amount that set with data-amount in embedded form integration, and the amount set with dataamount in custom forms integration should be multiplied by 100.
transaction_type
char
Yes
Sale or pre-authorization. 1 for sale, 3 for pre-authorisations. The default value is sale.
add_comission_amount
bool
Yes
It is compared with the value that set with the dataadd_commission_amount parameter when starting the payment process in embedded form or custom forms integration. If the values do not match, the payment process cannot be completed, the payment service returns an error.
ratio_code
string
Yes
When starting the payment process in embedded form or custom forms integrations, it is compared with the value that set with the dataratio_code parameter. If the values do not match, the payment process cannot be completed, the payment service returns an error. If the ratio code will not be used, this parameter can be sent as an empty string.
installments
string
Yes
When starting the payment process embedded or custom form integrations, it is compared with the value set with the data-installments parameter. If the values do not match, the payment process cannot be completed, the payment service returns an error. If installment limitation will not be used with this parameter, the value of the parameter can be sent as an empty string.
no_instalment
bool
Yes
When starting the payment process in embedded form or custom form integrations, it is compared with the value set with the data-no_instalment parameter. If the values do not match, the payment process cannot be completed, the payment service returns an error.This value can be set as true or false.
tds_required
bool
Yes
When starting the payment process in embedded form or custom form integrations, it is compared with the value set with the data-tds_required parameter. If the values do not match, the payment process cannot be completed, the payment service returns an error.This value can be set as true or false.
reference_no
string
No
A reference number to be sent by you to associate with the transaction, such as order number, invoice number. If you send the reference number with a unique value, you can check the status of the transaction through the check transaction service, in cases where you cannot get a response from the charge transaction service. In this way, we will be protected from duplicate transaction. In the example below, the session_id and token_id are taken and sent to the payment confirmation service.
is_escrow
bool
No
If you want the transaction to be approved by the company, you should send "true". If the parameter has not been sent, "false" is accepted.
agent_customer_name
string
No
The parameter which you write in this area will be seen as the "Customer's Name". You may write your firm name which you want to be seen by your customer
iban
string
No
It should be entered with a country code (ex "TR") with 26 characters in total.
Parameter Name
Type
Description
id
string
Transaction Id.
xact_id
string
Encrypted Transaction Id.
xact_date
datetime
Transaction Date.
transaction_type
char
1: sale
pos_type
char
5: Paynet POS
is_tds
bool
If the transaction performed with 3D,this value return as true.
agent_id
string
Paynet agent code of the dealer that performed the transaction.
user_id
string
Returns default as PaynetJ.
string
Mail address.
phone
string
Phone number.
bank_id
char
The bank's code in the Paynet system.
bank_name
string
The bank's name in the Paynet system.
campaign_url
string
The url showing the banks' plus installment and installment postpone selection screen. Call us for more detail information.
instalment
int
Installment count.See More
ratio
float
Rate that used during transaction.
ratio_code
string
Ratio code that used during transaction.
card_no_masked
string
Masked card number.
card_holder
string
Card owner.
amount
decimal
Amount that withdrawn from credit card.
net_amount
decimal
Amount without commission.
comission
decimal
Comission.
comission_tax
decimal
Comission tax.
end_user_commission
decimal
End user comission.
end_user_ratio
float
User ratio code that used during checkout.
currency
char
Currency.
authorization_code
string
Bank confirmation code.
reference_code
string
Bank reference code.
order_id
string
Bank order no.
user_unique_id
string
Unique id that given to user by member workplace.It’s necessary If card saving will perform at first time.Unique value(card_owner_id) assigns to user by Paynet after completion first card saving operation. You must store this value on your system by associating it with your user. Afterwards you should use the card_owner_id variable given by Paynet instead of user_unique_id for the saved card operations.
card_owner_id
string
Unique card holder information that has been generated by Paynet residing on user_unique_id after the first card saving process. This value is also used in subsequent card saving and recieving payment processes.
card_hash
string
Hash value of card number.
card_bank_id
string
The code of the stored card in the Paynet system.
card_logo_url
string
Logo image of the card.
is_succeed
bool
It returns true if the transaction successful. If the transaction is successful, it returns as http 200 and and is_succeed return as true. If the bank does not approve transaciton, it returns http 200 and is_succed return as false is_save_card_succeed: Returns true if the card save operation is successful. Its default value is false.
is_save_card_succeed
bool
Returns true if the card save operation is successful. Its default value is false.
save_card_result_message
string
Result message of card save operation.
paynet_error_id
string
Paynet system error code.
paynet_error_message
string
Paynet system error code.
bank_error_id
string
Bank error code.
bank_error_message
string
Bank error message.
bank_error_short_desc
string
Bank error message.
bank_error_long_desc
string
Bank error message
agent_reference_no
string
Reference number that used in the payment process. It is same as with reference_no.
object_name
string
Transaction.
code
string
System result code . See more
message
string
System message.
ratio_code_method
string
Please contact our support team for more detailed information.
md_status
int
3D payment confirmation transaction result.
company_cost_ratio
float
Value of Parent company service fee.
company_commission
decimal
The amount of service fee to be charged to the parent company as a result of this transaction.
company_commission_with_tax
decimal
As a result of this transaction, the amount of service fee with VAT, to be deducted to the parent company.
company_net_amount
decimal
Net amount to pay parent company.
plus_installment
string
Plus installment count.
card_type
char
Card Type. See More
card_brand_name
string
Brand of Card Bank (VISA, MASTERCARD, AMEX).
System
URL
Live System
https://api.paynet.com.tr/v1/transaction/charge
Test System
https://pts-api.paynet.com.tr/v1/transaction/charge