Payee Payment Type Capture Widget

The Payee Payment Type Capture Widget allows you to redirect payees to a simple page to capture their card in order to perform a Push to Card Disbursement. This page communicates directly with KyckGlobal so there are no PCI security concerns. Follow the steps below to use it.

Step 1: Unique ID Generation#

For security reasons, we generate a unique ID per client for use in the widget. Please contact support@kyckglobal.com and let them know you need a widget ID with the following information:

  • Environment (sandbox or production)
  • desired callbackURL

Step 2: Payer Auth Token#

Before loading the widget, you need to request a auth token. See below for documentation of the call.

Sandbox URL#

https://sandboxapi.kyckglobal.com/apis/userAuth

Production URL#

https://api.kyckglobal.com/apis/userAuth

Request Body#

{
"email": "string",
"password": "string"
}

Response Body#

{
"success": true,
"token": "JWT eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9",
"user": {
"role": "Payer-Super-Admin",
"userType": "Payer"
}
}

Step 3:Widget URL Retrieval#

Upon receiving a successful auth token, place this auth token in the request header and configure the request body as follows below.

Auth header: Payer Token

Sandbox Environment#

https://sandboxapi.kyckglobal.com/apis/payeePaymentTypeCapture

Request Body#

{
"paymentType" : "PushToCard",
"uniqueId": "KG-HHWQ-RJLS-4RQ2",
"payeeId": "Payee1245787956-asd4587-58s5s",
"redirectURL": "https://client-app.com/dashboard"
}

Response Body#

{
"success": true,
"URL": "https://sandbox.kyckglobal.com/pushToCardWidget/kyck?token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJwYXllZUlkIjoiUGF5ZWU5ZGM2Y2U0Yi01MmJmLTQwNzctOTAzMS1lMGIwMThmOTU1ZWMiL.j_PqvyE32YEyBIbdg_hZjIzRSerXhA0AWZ5ypfz3wl4&return_url=https%3A%2F%2Fclient-app.com%2Fdashboard"
}

Production Environment#

https://api.kyckglobal.com/apis/payeePaymentTypeCapture

Request Body#

{
"paymentType" : "PushToCard",
"uniqueId": "KG-HHWQ-RJLS-4RQ2",
"payeeId": "Payee1245787956-asd4587-58s5s",
"redirectURL": "https://client-app.com/dashboard"
}

Response Body#

{
"success": true,
"URL": "https://app.kyckglobal.com/pushToCardWidget/kyck?token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJwYXllZUlkIjoiUGF5ZWU5ZGM2Y2U0Yi01MmJmLTQwNzctOTAzMS1lMGIwMThmOTU1ZWMiL.j_PqvyE32YEyBIbdg_hZjIzRSerXhA0AWZ5ypfz3wl4&return_url=https%3A%2F%2Fclient-app.com%2Fdashboard"
}

Step 4: Render URL to Payee#

Upon receipt of the URL render the URL onto your page for the Payee to click into or forward the user directly to the URL (where appropriate) for capturing their payment details.

Payee Payment Type Capture Widget Example

Step 5: Callback#

Once the payee inputs the required fields and their card is successfully added, page will redirect to the given redirect URL and callback will be sent to the callbackURL configured by the KyckGlobal Team from Step 1.

Callback URL#

https://{callbackURL}/kyck/payeePaymentTypeCapture

Callback Body#

Callback Response:
{
"success": true,
"message": "Account Updated Successfully.",
"payeeId": "Payee1245787956-asd4587-58s5s"
}