Bulk Paycode

This section guides you on generating bulk paycodes.

Step 1 - Generate Bulk Token Request (Sent from Third-party)
This describes the important element required to be sent for a Bulk Generate Token request. For more information on this endpoint please see the Generate bulk token endpoint on the API reference

Request

curl https://sandbox.interswitchng.com/api/v1/pwm/bulk/tokens \
-H "Authorization: <token>" \
-H "Content-Type: application/json" \
-d '{
"additionalInfo": {"type": "bulk"},
"amount": "5000000",
"batchSize": 10,
"channel": "ATM",
"defaultOneTimePin": "1234",
"entries":   [
{
"amount": "500000",
"beneficiaryNumber": "08021111111",
"oneTimePin": "1234"
},
{
"amount": "500000",
"beneficiaryNumber": "08021111112",
"oneTimePin": "1234"
},
{
"amount": "500000",
"beneficiaryNumber": "08021111113",
"oneTimePin": "1234"
},
{
"amount": "500000",
"beneficiaryNumber": "08021111114",
"oneTimePin": "1234"
},
{
"amount": "500000",
"beneficiaryNumber": "08021111115",
"oneTimePin": "1234"
},
{
"amount": "500000",
"beneficiaryNumber": "08021111116",
"oneTimePin": "1234"
},
{
"amount": "500000",
"beneficiaryNumber": "08021111117",
"oneTimePin": "1234"
},
{
"amount": "500000",
"beneficiaryNumber": "08021111118",
"oneTimePin": "1234"
},
{
"amount": "500000",
"beneficiaryNumber": "08021111119",
"oneTimePin": "1234"
},
{
"amount": "500000",
"beneficiaryNumber": "08021111110",
"oneTimePin": "1234"
}
],
"macData": "95e8f80c61bfec738894d0589b4909f9bf94070325e5c89f0f4d885f9fa49d77",
"paymentMethodIdentifier": "E192F3F3B3BA4596BC9704C44EA801BC",
"pinBlock": "2f04079406b19df1",
"referenceId": "ga323923o4702",
"secure": "79758137bcde04327126b604391649caa5bbe5016aba5bff5553842c646bfc7040c5a310f6d89ceb4d4a0c9545dc3523035a19357c99d28c7ba3cab37939295d5e010c4246534594900f8c1a03fa41215bc554aa1ea09f06d5896200d44d09d347e7042298312088a9a8ed54ed29eecddb2ad750c74713e7591006827f7860faa4419ce9b12693e820d98ffb4394229fa7fbbf7556160cd1508ce3ada3c35aded6a0a0d625a7b86f79adbb1770492c86cf098654eb9ecfb7859130191ae5aaebe210cea3e2b8f41b5023c0da0e18212c84542c4e1e411759fce29f91c8c5f9806a6df3e23e2a86b08b088d3aa1c0f07e92258bc2be1662fda0d8f3704c655ec0",
"subscriberId": "2348124888436",
"tokenLifeTimeInMinutes": "144,
"ttid": "274"
}' 
-X POST

Response

curl https://sandbox.interswitchng.com/api/v1/pwm/bulk/tokens \
-H "Authorization: <token>" \
-H "Content-Type: application/json" \
-d '{
"additionalInfo": {"type": "bulk"},
"amount": "5000000",
"batchSize": 10,
"channel": "ATM",
"defaultOneTimePin": "1234",
"entries":   [
{
"amount": "500000",
"beneficiaryNumber": "08021111111",
"oneTimePin": "1234"
},
{
"amount": "500000",
"beneficiaryNumber": "08021111112",
"oneTimePin": "1234"
},
{
"amount": "500000",
"beneficiaryNumber": "08021111113",
"oneTimePin": "1234"
},
{
"amount": "500000",
"beneficiaryNumber": "08021111114",
"oneTimePin": "1234"
},
{
"amount": "500000",
"beneficiaryNumber": "08021111115",
"oneTimePin": "1234"
},
{
"amount": "500000",
"beneficiaryNumber": "08021111116",
"oneTimePin": "1234"
},
{
"amount": "500000",
"beneficiaryNumber": "08021111117",
"oneTimePin": "1234"
},
{
"amount": "500000",
"beneficiaryNumber": "08021111118",
"oneTimePin": "1234"
},
{
"amount": "500000",
"beneficiaryNumber": "08021111119",
"oneTimePin": "1234"
},
{
"amount": "500000",
"beneficiaryNumber": "08021111110",
"oneTimePin": "1234"
}
],
"macData": "95e8f80c61bfec738894d0589b4909f9bf94070325e5c89f0f4d885f9fa49d77",
"paymentMethodIdentifier": "E192F3F3B3BA4596BC9704C44EA801BC",
"pinBlock": "2f04079406b19df1",
"referenceId": "ga323923o4702",
"secure": "79758137bcde04327126b604391649caa5bbe5016aba5bff5553842c646bfc7040c5a310f6d89ceb4d4a0c9545dc3523035a19357c99d28c7ba3cab37939295d5e010c4246534594900f8c1a03fa41215bc554aa1ea09f06d5896200d44d09d347e7042298312088a9a8ed54ed29eecddb2ad750c74713e7591006827f7860faa4419ce9b12693e820d98ffb4394229fa7fbbf7556160cd1508ce3ada3c35aded6a0a0d625a7b86f79adbb1770492c86cf098654eb9ecfb7859130191ae5aaebe210cea3e2b8f41b5023c0da0e18212c84542c4e1e411759fce29f91c8c5f9806a6df3e23e2a86b08b088d3aa1c0f07e92258bc2be1662fda0d8f3704c655ec0",
"subscriberId": "2348124888436",
"tokenLifeTimeInMinutes": "144,
"ttid": "274"
}' 
-X POST

Generate Bulk Token Response (Sent from Interswitch)
This describes the important data elements required for a Generate Token response.

Step 2 - Get Bulk Paycode Batch Status
A bulk Token batch status message is a request to inquire about the status of the bulk token already generated. For more information on this endpoint please see the get bulk paycode batch status on the API reference

Request

curl https://sandbox.interswitchng.com/api/v1/pwm/bulk/tokens/comprehensive/status?referenceId=1234566&frontEndPartner=455 \
-H "Authorization: <token>" \
-H "Content-Type: application/json" 
-X GET

Responses

{
“summary”: {
“batchReference”: “123456”,
“numberOfSuccessful”: “10”,
“numberOfFailed”: “0”,
“amountOfFailed”: “0”,
“amountOfSuccessful”: “4300000”
},
“successful”: [{
  “surcharge”: “”,
  “amount”: “400000”,
  “beneficiaryNumber”: “08021111111”,
  “oneTimePin”: “4321”
  },
  {
  “surcharge”: “”,
  “amount”: “300000”,
  “beneficiaryNumber”: “08021111112”,
  “oneTimePin”: “1234”
  },
  {
  “surcharge”: “”,
  “amount”: “500000”,
  “beneficiaryNumber”: “08021111113”,
  “oneTimePin”: “1234”
  },
  {
  “surcharge”: “”,
  “amount”: “400000”,
  “beneficiaryNumber”: “08021111114”,
  “oneTimePin”: “1234”
  },
  {
  “surcharge”: “”,
  “amount”: “300000”,
  “beneficiaryNumber”: “08021111115”,
  “oneTimePin”: “1234”
  },
  {
  “surcharge”: “”,
  “amount”: “500000”,
  “beneficiaryNumber”: “08021111116”,
  “oneTimePin”: “1234”
  },
  {
  “surcharge”: “”,
  “amount”: “500000”,
  “beneficiaryNumber”: “08021111117”,
  “oneTimePin”: “1234”
  },
  {
  “surcharge”: “”,
  “amount”: “400000”,
  “beneficiaryNumber”: “08021111118”,
  “oneTimePin”: “1234”
  }]
}

Step 3 - Bulk Token Batch Cancel
A Cancel Token message is a request to cancel/deactivate an already generated Token. For more information on this endpoint please see the Bulk paycode batch cancel endpoint on the API reference.

Sample Requests

curl https://sandbox.interswitchng.com/api/v1/pwm/bulk/tokens \
-H "Authorization: <token>" \
-H "Content-Type: application/json" \
-d '{
"transactionRef": 1234343",
"frontEndPartner": "IFIS"
}' 
-X DELETE

Sample Responses

{
“code”: “00”,
“description”: “Successfully queued to be cancelled”
}