Pre-Auth / Post-Auth Payment

On this page, you can find the details of pre-authorization (pre auth) and capture (post auth).

Pre-authorization & Non-3D Secure

URL

The endpoint and http method information to create pre-authorized payment are stated below.

HTTP Method URL
POST /payment/v1/card-payments

Request Parameters

All parameters in a regular payment request also apply to pre-authorisation. To create a pre-authorization, a request must be sent with the paymentPhase parameter as PRE_AUTH. You can create pre-authorization by examining the payment receiving service and sending the expected parameter in the pre-authorization. The response received in the pre-authorization process is the same as in the regular payment request. For payment service see: Create Payment

Pre-authorization & 3D Secure

Pre-authorization with 3D Secure also applies to regular 3D Secure streams. PRE_AUTH will have been completed as 3D Secure when the end user validates it with the OTP code received. A 3D Secure PRE_AUTH transaction must first be completed by visiting the 3D Complete service and then the post authorization service must be used.

URL

The endpoint and http method information to create pre-authorized payment with 3D Secure are stated below.

HTTP Method URL
POST /payment/v1/card-payments/3ds-init

Request Parameters

All parameters in a normal 3D Secure payment request also apply to pre-authorisation. To create a pre-authorization, a request must be sent with the paymentPhase parameter as PRE_AUTH. You can create a pre-authorization by examining the payment receiving service and sending the expected parameter in the pre-authorization. The response received in the pre-authorization process is the same as in the regular payment request. For payment service see: Create 3D Secure Payment

Please pay attention

  • Pre-authorization does not support the marketplace model. You can initiate pre-authorization for Listing/Subscription payments.
  • Pre-authorization can only be done with stored card information or open card information. Wallet is not supported.
  • Pre-authorization cannot be refunded from an initiated payment item, you must use the refund service.
  • The price information sent during the post-authorization must be less than or equal to the amount sent during the pre-authorization process.
  • Pre-authorization process can be used for virtual POS of banks, but it cannot be used in payment and e-money institutions.

Pre-authorization Sample Codes

You can review the sample codes in the open source Craftgate API clients.

Post-Authorization

For a successfully pre-authorized payment, you can complete the payment with post-authorization.

URL

The endpoint and http method information to change an existing payment phase as post-authorization are stated below.

HTTP Method URL
POST /payment/v1/card-payments/:id/post-auth

Request Parameters

Parameter Name Type Required Description
id number Yes ID of the pre-authorized payment
paidPrice number Yes The amount that is requested to be captured

Response Parameters

Parameters returned as a result of the payment receive are also subject to the rules specified in the Response Formats section of the API documentation home page. The response received in the post-authorization is the same as the response in the regular payment request. For payment service see: Create Payment

Post-authorization Sample Codes

You can review the sample codes in the open source Craftgate API clients.