.. meta:: :description: generic payment gateway :keywords: wubook, channel manager, gateway .. toctree:: Generic Payment Gateway *********************** The Generic Payment Gateway allows you to use your preferred Payment Gateway to receive a deposit for direct online reservations. The unique parameter you should specify inside WuBook is the ACK URL. How it works ============ When a customer tries to finalize the reservation, WuBook will contact the *ACK URL*, communicating the necessary information. This information includes in particular two URLs: the *Ok Url*, which is the address where the customer should be redirected after a succesfull payment will be done, and the *Ko Url*, which is the address where the customer should be redirected if the payment of the deposit is cancelled. In case your payment gateway is **not** synchronous (for example, some payment gateways allow to pay via SMS or bank transfer), you can use two additional urls: *OkAsyncUrl* and *TempUrl*. The first one is the URL you can hit to confirm the reservation. It returns an empty page if the operation has been correctly executed, otherwise, it's a human error. While waiting for the confirmation of the payment, the customer can check his temporarirly voucher at the url TempUrl. The ACK URL replies telling WuBook what is the link where the user should be redirected to in order to execute the payment of the deposit. WuBook will then redirect the user to this url, that should lead him either to the Ok Url or the Ko Url. Check the Technical specifications chapter to know implementation details. Technical Specifications ======================== Once the ACK URL has been specified on WuBook, the Generic Payment Gateway is **ready** to be used. At this point, it should be selected as default payment gateway and the WuBook Online Reception will begin to use its Technical specifications. WuBook will issue a POST to the ACK URL sending the following information: - first_name - last_name - deposit - currency - currency_iso - email - country - city - address - zip - ok_url - async_ok_url - temp_url - ko_url - transaction - lcode - rcode If you want to **test** if your ACK URL is working, just do that as follows: .. code-block:: python import requests params= { 'first_name': 'bruce', 'last_name': 'wayne', 'deposit': 10, 'currency': 'EUR', 'email': 'bat@man.com', 'country': 'AQ', 'city': 'gotham', 'address': 'bat cave', 'zip': '123', 'lcode': 1234567, 'rcode': 7654321, 'transaction': 'id_transaction', 'ok_url': 'http://batman.ok.org', 'async_ok_url': 'http://batman.async.org', 'temp_url': 'http://batman.temp.org', 'ko_url': 'http://batman.ko.org', } page = requests.get(YOUR_ACK_URL, params=params) That's what it's all about!