[PostFinance] What is the difference between the post-sale URL and the acceptURL?

The postsale URL is used to update your database after a successful transaction; it does so by using an http request with parameters containing information about the transaction (such as status, order ID, etc… ). This request is initiated by our server, thereby allowing you to automate back office tasks at your end. Please note that this URL is only ever known to you and us, not to your client: your client will NEVER be redirected to the postsale URL.

The acceptURL (or the decline/cancel/exceptionURL) is used to redirect your customer after a transaction. There are 4 different types of URL which you can redirect your customer to after a transaction:

  • acceptURL
  • cancelURL
  • declineURL
  • exceptionURL

The acceptURL is used when the payment is authorized or pending, (STATUS : ‘5’, ‘51’, ‘9’ or ‘91’).
The exceptionURL is used whenever the payment is uncertain (STATUS: ‘52’ or ‘92’). If the exceptionURL field is empty, the buyer is redirected to the acceptURL page.
The declineURL is used if a payment (authorization) has been refused (STATUS : 2).
The cancelURL is used if the buyer cancels the payment (STATUS : 1). If the cancelURL field is empty, the declineURL will be used instead.

Because the acceptURL (or the decline/cancel/exceptionURL) is sent in the hidden fields form - which makes it visible to clients - it is not recommended that this URL be used to update the status of an order in your database.
Should you also have a postsale URL and you answer the post-sale request with either a redirection or HTML, the acceptURL will NOT be used. Your customer will be redirected or shown the HTML you return.

The postsale URL is entered into your account under “technical information”. Only one URL can be entered.
The acceptURL and the decline/cancel/exceptionURL are sent with each order (and may therefore vary in each order, if so required).
Please refer to the technical documentation for detailed information on the use of both URL’s.