1. Home
  2. Quickteller SVA
  3. EPINS
  4. Create Voucher

Create Voucher

Request Endpoint: https://sandbox.interswitchng.com/api/v2/quickteller/vouchers/create

Request Body Description

Field#Field nameData typeMax lengthRequiredDescription
1paymentCodestring5False This is the payment  code
2CustomerIdstringMAXTrueThis is the id of the customer who is trying to create the voucher
3AmountLong
TrueThis is the amount of voucher that needs to be created
4Typestring10TrueThis is the type of voucher been created; gift | recharge
5ExpiryDatedatetime
TrueThis is the expiry date of the voucher
6StartDatedateTime
TrueThis is the start date of the voucher
7Redemption.Quantity int
FalseThis specifies the total number of time a user can redeem the voucher
8CodeConfig.allowedCharstring50FalseThis specifies the length and pattern of the voucher

Request Header

{
"terminalId" :" 3DMO0001 ",
"Content-Type":"application/json",
"authorization":"InterswitchAuth SUtJQUYzRDNGMkQyMEY1MTM2REVGNUExMjUwMzZDN0U0QjgzMzgwQjBGMjA=",
"nonce":"a42a92fa5718bf480684cb75c3d25fb1",
"timeStamp":"1588858522",
"signature":"5+NUy30sMxQM3VzNIS/CPTkjixo=",
"signatureMethod":"SHA1"
}

Request Body

{
    "customerId": "081242267646",
    "amount": "5000",
    "type": "recharge",
    "startDate": "2021-01-22",
    "expiryDate": "2023-11-29"
}

Sample Response (Success)

{

"TransactionRef": "PBL|Web|3PBL0001|VOS|261119122709|3BYAHU7EB3",
"RechargePIN": "u865tO9ycr",
"ApprovedAmount": "5000",
"MiscData": "u865tO9ycr",
"ResponseCode": "90000",
"ResponseDescription": "Success",
"ResponseCodeGrouping": "SUCCESSFUL"

}

Sample Response (Failed)

{
    "errors": [
        {
            "code": "90009",
            "message": "Transaction in Progress",
            "responseCodeGrouping": "PENDING"
        }
    ],
    "error": {
        "code": "90009",
        "message": "Transaction in Progress",
        "responseCodeGrouping": "PENDING"
    }
}

Response Codes
Response CodeResponse Message
VS005TYPE_CANNOT_BE_EMPTY
VS007UNRECOGNISED_TYPE
VS008VOUCHER_TYPE_NOT ALLOWED
VS009INVALID_START_DATE
VS010BAD_START_DATE_FORMAT
VS011BAD_EXPIRY_DATE_FORMAT
VS012GIFT_OBJECT_NOT_SPECIFIED
VS013DISCOUNT_OBJECT_NOT_SPECIFIED
VS014INVALID_GIFT_BALANCE
VS015INVALID_LENGTH
VS016INVALID_EXPIRY_DATE
VS017INVALID_REDEEM_QUANTITY
VS019INVALID_CODE_CONFIG_LENGTH
VS021NOT_AUTHORISED_TO_REDEEM_VOUCHER
Was this article helpful to you? Yes No

How can we help?