Debit Card Issuance

Documentations

Documentations for API

End Points

https://z-sandbox.jsbl.com/zconnect/api/v1/debitCardIssuance

Http Method

POST

Header

Name Type Values Description
Accept JSON application/json
Content-Type JSON application/json
clientId String *************
clientSecret String Access-Token Auth2.0 verification
organizationId String 223 Authenticate organization

Request Parameters

Name Description Required Parameter Type Length Sample Value
processingCode processingCode Mandatory STRING DebitCardI
merchantType merchantType Mandatory STRING 0088
traceNo traceNo Mandatory STRING 782291
companyName companyName Mandatory STRING KUICKPAY
dateTime dateTime Mandatory STRING 2021010520
mobileNo mobileNo Mandatory STRING 0315024240
terminalId terminalId Mandatory STRING KUICKPAY
otpPin otpPin Optional STRING
pinType pinType Mandatory STRING 01
transactionType transactionType Mandatory STRING 01
cardProductTypeId cardProductTypeId Mandatory STRING 01
cnic cnic Mandatory STRING 4220112822
cardDescription cardDescription Mandatory STRING AHSAN
mailingAddress mailingAddress Mandatory STRING Test1
reserved1 reserved1 Optional STRING
reserved2 reserved2 Optional STRING

Sample Request

{
    "DebitCardIssuanceRequest": {
        "processingCode": "DebitCardIssue",
        "merchantType": "0088",
        "traceNo": "782291",
        "companyName": "KUICKPAY",
        "dateTime": "20210105201527",
        "mobileNo": "03150242404",
        "terminalId": "KUICKPAY",
        "otpPin": "",
        "pinType": "01",
        "transactionType": "01",
        "cardProductTypeId": "01",
        "cnic": "4220112822287",
        "cardDescription": "AHSAN",
        "mailingAddress": "Test1",
        "reserved1": "",
        "reserved2": ""
    }
}

Response Parameters

Name Description Parameter Type Length Sample Value
processingCode processingCode String DebitCardIssue
merchantType merchantType String 0088
traceNo traceNo String 782291
companyName companyName String KUICKPAY
dateTime dateTime String 20210105201527
responseCode responseCode String 00
responseDetails responseDetails object ["Successful"]

Response Sample

{
    "DebitCardIssuResponse": {
        "processingCode": "DebitCardIssue",
        "merchantType": "0088",
        "traceNo": "782291",
        "companyName": "KUICKPAY",
        "dateTime": "20210105201527",
        "responseCode": "00",
        "responseDetails": [
            "Successful"
        ],
    }
}
curl --location --request POST 'https://z-sandbox.jsbl.com/zconnect/api/v1/debitCardIssuance' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'clientId: 364E9806o51K9' \
--header 'clientSecret: eyJhbGciOiJIUzUxMiJ9.eyJleHAiOjE2OTI2MzcxOTl9.0s3evOaGFm6uyRxSioiXlOffHbZTDIB1zB1xl3ck_IIfxSrsARI9tPiooIOVjVv9rQqUInqtk1odcWtk8V3rFA' \
--header 'organizationId: 223' \
--data-raw '{
   "DebitCardIssuanceRequest": {
       "processingCode": "DebitCardIssue",
       "merchantType": "0088",
       "traceNo": "782291",
       "companyName": "KUICKPAY",
       "dateTime": "20210105201527",
       "mobileNo": "03150242404",
       "terminalId": "KUICKPAY",
       "otpPin": "",
       "pinType": "01",
       "transactionType": "01",
       "cardProductTypeId": "01",
       "cnic": "4220112822287",
       "cardDescription": "AHSAN",
       "mailingAddress": "Test1",
       "reserved1": "",
       "reserved2": ""
   }
}'
var https = require('follow-redirects').https;
var fs = require('fs');

var options = {
 'method': 'POST',
 'hostname': 'z-sandbox.jsbl.com',
 'path': '/zconnect/api/v1/debitCardIssuance',
 'headers': {
   'Content-Type': 'application/json',
   'Accept': 'application/json',
   'clientId': '364E9806o51K9',
   'clientSecret': 'eyJhbGciOiJIUzUxMiJ9.eyJleHAiOjE2OTI2MzcxOTl9.0s3evOaGFm6uyRxSioiXlOffHbZTDIB1zB1xl3ck_IIfxSrsARI9tPiooIOVjVv9rQqUInqtk1odcWtk8V3rFA',
   'organizationId': '223'
 },
 'maxRedirects': 20
};

var req = https.request(options, function (res) {
 var chunks = [];

 res.on("data", function (chunk) {
   chunks.push(chunk);
 });

 res.on("end", function (chunk) {
   var body = Buffer.concat(chunks);
   console.log(body.toString());
 });

 res.on("error", function (error) {
   console.error(error);
 });
});

var postData = JSON.stringify({
 "DebitCardIssuanceRequest": {
   "processingCode": "DebitCardIssue",
   "merchantType": "0088",
   "traceNo": "782291",
   "companyName": "KUICKPAY",
   "dateTime": "20210105201527",
   "mobileNo": "03150242404",
   "terminalId": "KUICKPAY",
   "otpPin": "",
   "pinType": "01",
   "transactionType": "01",
   "cardProductTypeId": "01",
   "cnic": "4220112822287",
   "cardDescription": "AHSAN",
   "mailingAddress": "Test1",
   "reserved1": "",
   "reserved2": ""
 }
});

req.write(postData);

req.end();

require_once 'HTTP/Request2.php';
$request = new HTTP_Request2();
$request->setUrl('https://z-sandbox.jsbl.com/zconnect/api/v1/debitCardIssuance');
$request->setMethod(HTTP_Request2::METHOD_POST);
$request->setConfig(array(
'follow_redirects' => TRUE
));
$request->setHeader(array(
'Content-Type' => 'application/json',
'Accept' => 'application/json',
'clientId' => '364E9806o51K9',
'clientSecret' => 'eyJhbGciOiJIUzUxMiJ9.eyJleHAiOjE2OTI2MzcxOTl9.0s3evOaGFm6uyRxSioiXlOffHbZTDIB1zB1xl3ck_IIfxSrsARI9tPiooIOVjVv9rQqUInqtk1odcWtk8V3rFA',
'organizationId' => '223'
));
$request->setBody('{
\n    "DebitCardIssuanceRequest": {
\n        "processingCode": "DebitCardIssue",
\n        "merchantType": "0088",
\n        "traceNo": "782291",
\n        "companyName": "KUICKPAY",
\n        "dateTime": "20210105201527",
\n        "mobileNo": "03150242404",
\n        "terminalId": "KUICKPAY",
\n        "otpPin": "",
\n        "pinType": "01",
\n        "transactionType": "01",
\n        "cardProductTypeId": "01",
\n        "cnic": "4220112822287",
\n        "cardDescription": "AHSAN",
\n        "mailingAddress": "Test1",
\n        "reserved1": "",
\n        "reserved2": ""
\n    }
\n}');
try {
$response = $request->send();
if ($response->getStatus() == 200) {
   echo $response->getBody();
}
else {
   echo 'Unexpected HTTP status: ' . $response->getStatus() . ' ' .
   $response->getReasonPhrase();
}
}
catch(HTTP_Request2_Exception $e) {
echo 'Error: ' . $e->getMessage();
}
require "uri"
require "json"
require "net/http"

url = URI("https://z-sandbox.jsbl.com/zconnect/api/v1/debitCardIssuance")

https = Net::HTTP.new(url.host, url.port)
https.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Content-Type"] = "application/json"
request["Accept"] = "application/json"
request["clientId"] = "364E9806o51K9"
request["clientSecret"] = "eyJhbGciOiJIUzUxMiJ9.eyJleHAiOjE2OTI2MzcxOTl9.0s3evOaGFm6uyRxSioiXlOffHbZTDIB1zB1xl3ck_IIfxSrsARI9tPiooIOVjVv9rQqUInqtk1odcWtk8V3rFA"
request["organizationId"] = "223"
request.body = JSON.dump({
 "DebitCardIssuanceRequest": {
   "processingCode": "DebitCardIssue",
   "merchantType": "0088",
   "traceNo": "782291",
   "companyName": "KUICKPAY",
   "dateTime": "20210105201527",
   "mobileNo": "03150242404",
   "terminalId": "KUICKPAY",
   "otpPin": "",
   "pinType": "01",
   "transactionType": "01",
   "cardProductTypeId": "01",
   "cnic": "4220112822287",
   "cardDescription": "AHSAN",
   "mailingAddress": "Test1",
   "reserved1": "",
   "reserved2": ""
 }
})

response = https.request(request)
puts response.read_body
OkHttpClient client = new OkHttpClient().newBuilder()
 .build();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\r\n    \"DebitCardIssuanceRequest\": {\r\n        \"processingCode\": \"DebitCardIssue\",\r\n        \"merchantType\": \"0088\",\r\n        \"traceNo\": \"782291\",\r\n        \"companyName\": \"KUICKPAY\",\r\n        \"dateTime\": \"20210105201527\",\r\n        \"mobileNo\": \"03150242404\",\r\n        \"terminalId\": \"KUICKPAY\",\r\n        \"otpPin\": \"\",\r\n        \"pinType\": \"01\",\r\n        \"transactionType\": \"01\",\r\n        \"cardProductTypeId\": \"01\",\r\n        \"cnic\": \"4220112822287\",\r\n        \"cardDescription\": \"AHSAN\",\r\n        \"mailingAddress\": \"Test1\",\r\n        \"reserved1\": \"\",\r\n        \"reserved2\": \"\"\r\n    }\r\n}");
Request request = new Request.Builder()
 .url("https://z-sandbox.jsbl.com/zconnect/api/v1/debitCardIssuance")
 .method("POST", body)
 .addHeader("Content-Type", "application/json")
 .addHeader("Accept", "application/json")
 .addHeader("clientId", "364E9806o51K9")
 .addHeader("clientSecret", "eyJhbGciOiJIUzUxMiJ9.eyJleHAiOjE2OTI2MzcxOTl9.0s3evOaGFm6uyRxSioiXlOffHbZTDIB1zB1xl3ck_IIfxSrsARI9tPiooIOVjVv9rQqUInqtk1odcWtk8V3rFA")
 .addHeader("organizationId", "223")
 .build();
Response response = client.newCall(request).execute();
var client = new RestClient("https://z-sandbox.jsbl.com/zconnect/api/v1/debitCardIssuance");
client.Timeout = -1;
var request = new RestRequest(Method.POST);
request.AddHeader("Content-Type", "application/json");
request.AddHeader("Accept", "application/json");
request.AddHeader("clientId", "364E9806o51K9");
request.AddHeader("clientSecret", "eyJhbGciOiJIUzUxMiJ9.eyJleHAiOjE2OTI2MzcxOTl9.0s3evOaGFm6uyRxSioiXlOffHbZTDIB1zB1xl3ck_IIfxSrsARI9tPiooIOVjVv9rQqUInqtk1odcWtk8V3rFA");
request.AddHeader("organizationId", "223");
var body = @"{
" + "\n" +
@"    ""DebitCardIssuanceRequest"": {
" + "\n" +
@"        ""processingCode"": ""DebitCardIssue"",
" + "\n" +
@"        ""merchantType"": ""0088"",
" + "\n" +
@"        ""traceNo"": ""782291"",
" + "\n" +
@"        ""companyName"": ""KUICKPAY"",
" + "\n" +
@"        ""dateTime"": ""20210105201527"",
" + "\n" +
@"        ""mobileNo"": ""03150242404"",
" + "\n" +
@"        ""terminalId"": ""KUICKPAY"",
" + "\n" +
@"        ""otpPin"": """",
" + "\n" +
@"        ""pinType"": ""01"",
" + "\n" +
@"        ""transactionType"": ""01"",
" + "\n" +
@"        ""cardProductTypeId"": ""01"",
" + "\n" +
@"        ""cnic"": ""4220112822287"",
" + "\n" +
@"        ""cardDescription"": ""AHSAN"",
" + "\n" +
@"        ""mailingAddress"": ""Test1"",
" + "\n" +
@"        ""reserved1"": """",
" + "\n" +
@"        ""reserved2"": """"
" + "\n" +
@"    }
" + "\n" +
@"}";
request.AddParameter("application/json", body,  ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);

Response Code Details

{
    "DebitCardIssuResponse": {
        "processingCode": "DebitCardIssue",
        "merchantType": "0088",
        "traceNo": "782291",
        "companyName": "KUICKPAY",
        "dateTime": "20210105201527",
        "responseCode": "00",
        "responseDetails": [
            "Successful"
        ],
    }
}
{
    "messages": "Bad Request - Invalid Access Token",
    "errorcode": "4001"
}

{
    "messages": "Bad Request - Invalid Request Payload",
    "errorcode": "4002"
}

{
    "messages": "Bad Request - Invalid Authorization Header",
    "errorcode": "4003"
}

{
    "messages": "Something Went Wrong",
    "errorcode": "4004"
}

{
    "messages": "Record Not Found",
    "errorcode": "4005"
}

{
    "messages": "Invalid Client Id\/Secret",
    "errorcode": "4006"
}

{
    "messages": "Bad Request - Invalid Access Token",
    "errorcode": "4007"
}

Try out yourself

Security

X-IBM-Client-Id(apiKey located in header)
X-IBM-Client-Secret(apiKey located in header)
1c48aa28-2614-486f-aa2c-cbc86cc7ab51

Header Parameter

Name Values Description
Content-Type application/json Content Type application/json is supported
Accept application/json Content Type application/json is supported
organizationId xyz You will make a call to the auth-blb api and give it your client ID. You should add the client secret and organisation ID it returns here.
clientId Enter your verified Client Id
clientSecret Enter Your Verified Client Secret

Request Body

Response Body