Batchgate

Table of Contents

  1. Overview
  2. SFTP
  3. File Formats
    1. /IN Folder
    2. /OUT Folder
    3. /ERROR Folder
  4. SFTP File Format - Field Definitions
  5. Additional Notes

Overview

The Batchgate service enables corporates to integrate their ERP solutions with the platform. Through this integration, corporates can prepare payment schedules such as salary, vendor, and other bulk payments directly from their ERP systems.

The generated payment schedule will be transmitted to the Batchgate service via a dedicated SFTP location. During the integration and go-live process, the corporate will be provided with access to an SFTP directory, where payment files should be uploaded to the /IN folder for processing.


SFTP

SFTP (Secure File Transfer Protocol) is a secure network protocol used to transfer files between systems over an encrypted connection. It operates over SSH (Secure Shell), ensuring that files, credentials, and data exchanged between parties are protected from unauthorized access.

In the context of Batchgate, SFTP serves as the secure channel through which corporates exchange payment files and processing results with the platform:

  • /IN Folder – Used by the corporate to upload payment schedules for processing
  • /OUT Folder – Used by Batchgate to return transaction processing results, including switch response codes.
  • /ERROR Folder – Used by Batchgate to return files that failed validation, along with the corresponding response codes

This secure file exchange mechanism ensures the reliable and protected transmission of payment-related data between the corporate's ERP system and the Batchgate service.



File Formats

/IN Folder

This is the SFTP directory location where the corporate is required to upload its generated payment schedule for processing. All payment files should be dropped into this designated folder to enable the Batchgate service to pick up and process the transactions.

RowRecord TypeFormatDescription
1Batch Record{Batch_Reference, Batch_Description, ,Is_Single_Debit,Terminal_ID}Batch header information
2Source Account Record{SECURE_DATA,SOURCE_ACCOUNT NUMBER,SOURCE_ACCOUNT_TYPE , BANK_CBN_CODE,ENCRYPTED_PIN ,MAC_DATA}Secure card data
3 to n-1Beneficiary Transaction Record{PAYMENT_REF,AMOUNT,Narration ,BENEFICIARY_CODE, BENEFICIARY_EMAIL,BANK_CBN_CODE ,BENEFICIARY_ACCOUNT, BENEFICIARY_ACCOUNT_TYPE, IS_PREPAID_CARD_LOAD,CURRENCY_CODE ,BENEFICIARY_NAME, BENEFICIARY_PHONE_NUMBER}Consists of payment information up until the second to the last row.

Important

Please note that files are dropped in .csv format inside the /IN folder.

Click here to access .CSV file generator


/OUT Folder

This is the SFTP directory location where Batchgate returns the processing outcome for submitted payment schedules. All switch response codes for processed payments will be generated and made available in this designated folder, enabling the corporate to retrieve and reconcile the results of their transactions.

RowFormatDescription
1{Batch_Reference,Batch_Description, Is_Single_Debit,Terminal_ID,RESPONSE_CODE}Batch header information
3 to n-1{PAYMENT_REF,AMOUNT,BENEFICIARY_NAME, BANK_CBN_CODE,BENEFICIARY_ACCOUNT,BENEFICIARY_ACCOUNT_TYPE, IS_PREPAIDCARDLOAD,SWITCH_RESPONSE}Consists of payment information up until the second to the last row.
📘

Switch Response

Click here to get the list of switch response codes.


/ERROR Folder

This is the SFTP directory location where Batchgate returns validation feedback for submitted payment files that fail header validation checks during processing. All applicable response codes and error details for files that do not meet the required header format or validation criteria will be generated and made available in this designated folder, enabling the corporate to review, correct, and resubmit the affected files.

RowFormatDescription
1{Batch_Reference,Batch_Description, Terminal_ID,Is_Single_Debit,RESPONSE_CODE}Batch header information
2{SECURE_DATA,SOURCE_ACCOUNT_NUMBER, SOURCE_ACCOUNT_TYPE,BANK_CBN_CODE, ENCRYPTED_PIN,MAC_DATA}Secure card data
3 to n-1{PAYMENT_REF,AMOUNT,BENEFICIARY_CODE, BENEFICIARY_EMAIL,BENEFICIARY_ACCOUNT, BENEFICIARY_ACCOUNT_TYPE,IS_PREPAIDLOAD,CURRENCY_CODE, BENEFICIARY_NAME,BENEFICIARY_PHONE_NUMBER}Consists of payment information up until the second to the last row.
📘

Response Code

Click here to get the list of file validation response codes.


SFTP File Format - Field Definitions

FieldMandatory (M) / Optional (O)LengthFormatDescription
Batch_ReferenceM-AlphanumericCode to uniquely identify a batch of payments. Must be unique per batch.
Batch_DescriptionM-AlphanumericDescribes the batch (e.g., Salary Payments).
Is_Single_DebitM-BooleanTrue = Single debit (line-by-line debit) on the corporate account.
False = Bulk debit on the corporate account. This requires a Float Card.
Terminal_IdM8AlphanumericUniquely identifies the third-party system. Provided by Interswitch.
Secure_DataM-AlphanumericSecure value generated using Source Card PAN, Expiry Date, and PIN. Sample code is provided in JavaScript and C# on how to generate secure data. KIndly find link below after this table.
Source_Account_NumberM≤ 25NumericEnsure NUBAN for commercial banks. For prepaid load, specify the card number (PAN).
Source_Account_TypeM2NumericSpecifies whether the account is Savings or Current. Refer to the appendix for available options.
Encrypted_PinM-AlphanumericCryptographically secured PIN data.
Mac_DataM-AlphanumericConcatenate Terminal ID, Beneficiary Code(s), Amount, and Beneficiary Account Number(s). Hash using the SHA512 algorithm.
PaymentRefM-AlphanumericA unique reference tied to each payment item. Must be unique per beneficiary.
AmountM-NumericAmount for each beneficiary, sent in the lowest denomination.
BeneficiaryCodeM-AlphanumericUsually Employee ID, Contractor ID, or any unique identifier.
Beneficiary_NameM-AlphabeticName of beneficiary.
Bank_Cbn_CodeM≤ 3NumericBank code. Refer to the appendix for valid bank codes.
Beneficiary_AccountM≤ 25NumericEnsure NUBAN for commercial banks. For prepaid load, specify the card number (PAN).
Beneficiary_Account_TypeM2NumericSpecifies the beneficiary account type.
ISPrepaidCard_LoadM1BooleanUsed to specify whether a card or account is being credited (True / False).
BeneficiaryPhone_NumberO> 11NumericBeneficiary mobile number.

Sample SFTP file formats

Click here to download sample file for /IN folder

Click here to download sample file for /OUT folder

Click here to download sample file for /ERROR folder


📘

Libraries:

Please find below links to download any of the supported libraries

Additional Notes

FieldNotes
Source_Account_NumberPass any valid NUBAN account number.
Source_Account_TypePass the account type associated with the specified Source_Account_Number.
Secure_DataPAN, CVV, PIN, and Expiry Date values are used to compute the Secure_Data.
Mac_DataGenerated using SHA512 hashing of the required concatenated values.




Did this page help you?