madkoding / webpay-kcc

Docker Image for Transbank Webpay KCC 6.0.2 linux 64

Home Page:https://hub.docker.com/r/lgatica/webpay-kcc/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

webPay-kcc

Transbank Webpay KCC 6.0.2 linux 64

Esta imagen de docker espera que se disponga de un endpoint de API para obtener y actualizar la orden de compra en el sitio web. Deben ser asi:

curl -i -H "Content-Type: application/json" -X GET http://hostname/resource/order_id
{
  "transaction_code": null,
  "gateway_response": null,
  "transaction_id": 111,
  "last_4_digits": null,
  "authorization_code": "",
  "payment_type": null,
  "number_quotas": null,
  "status": 0,
  "amount": 10000
}
curl -i -H "Content-Type: application/json" -X POST '{"transaction_code": "XX", "gateway_response": "XX", "transaction_id": "XX", "last_4_digits": "XX", "authorization_code": "XX", "payment_type": "XX", "number_quotas": "XX", "status": "XX"' http://hostname/resource/order_id

Ambas urls deben tener la misma base y se espera que con el metodo GET retorne un json con los datos de la orden como se muestra en el ejemplo. Con el metodo POST se espera actualizar la orden con la respuesta de Transbank, como se muestra en el ejemplo.

Example

# Development
docker run -d --restart=always -p 80:80 -v /path/local/log:/var/www/webpay/log -e IP=XXX.XXX.XXX.XXX -e ORDER_URL=http://hostname/resource --name webpay lgaticaq/webpay-kcc:dev

# Production
docker run -d --restart=always -p 80:80 -v /path/local/log:/var/www/webpay/log -e PRIVADA=`cat privada.pem` -e PUBLICA=`cat tbk_public_key.pem` -e IDCOMERCIO=XXXXXXXXXXXX -e IP=XXX.XXX.XXX.XXX -e ORDER_URL=http://hostname/resource lgaticaq/webpay-kcc

About

Docker Image for Transbank Webpay KCC 6.0.2 linux 64

https://hub.docker.com/r/lgatica/webpay-kcc/


Languages

Language:HTML 63.2%Language:PHP 35.5%Language:Shell 1.3%