This is the Official PHP client / library for BNI API. Please visit Digital Services for more information about our product and visit our documentation page at API Documentation for more technical details.
download Composer and run command line
composer require bni-api/bni-php-client
If you are not using Composer, you can clone or download this repository.
We have 5 API products you can use:
- One Gate Payment - A solution for a company to integrate its application / system with banking transaction services. documentation
- Snap BI - Integrate with SNAP BI documentation
- RDN - is BNI's innovation in providing solutions for securities companies in opening digital accounts for investors and can facilitate book-entry transactions by integrating them with API. documentation
- RDL - is the provision of financial services to bring together lenders and loan recipients in order to enter into lending and borrowing agreements in rupiah currency directly through an electronic system using the internet network. documentation
- RDF - is a solution for fintech companies registered with OJK in opening digital accounts to facilitate fund transfer transactions by utilizing API technology. documentation
- BNI Move check out our API here. documentation
Get your client key and server key from Menu - Applications Create API client object
use BniApi\BniPhp\Bni;
$bni = new Bni(
$env = 'sandbox', // dev, sandbox, prod
$clientId = '{your-client-id}',
$clientSecret = '{your-client-secret}',
$apiKey = '{your-api-key}',
$apiSecret = '{your-api-secret}',
$appName = '{your-app-name}'
);
Create One Gate Payment
class object
use BniApi\BniPhp\Bni;
use BniApi\BniPhp\api\OneGatePayment;
$bni = new Bni(
$env = 'sandbox', // dev, sandbox, prod
$clientId = '{your-client-id}',
$clientSecret = '{your-client-secret}',
$apiKey = '{your-api-key}',
$apiSecret = '{your-api-secret}',
$appName = '{your-app-name}'
);
$ogp = new OneGatePayment($bni);
Available methods for One Gate Payment
class
$getbalance = $ogp->getBalance(
$accountNo = '115471119'
);
$getInHouseInquiry = $ogp->getInHouseInquiry(
$accountNo = '115471119'
);
$doPayment = $ogp->doPayment(
$customerReferenceNumber = '20170227000000000020', // max 20 char client defined reference number
$paymentMethod = '0', // 0: In-house (intra BNI), 1: RTGS transfer, 2: Kliring transfer
$debitAccountNo = '113183203',
$creditAccountNo = '115471119',
$valueDate = '20170227000000000',
$valueCurrency = 'IDR',
$valueAmount = '100500',
$remark = '', // optional
$beneficiaryEmailAddress = 'mail@example.com', // optional
$beneficiaryName = 'Mr.X', // optional max 50 char (mandatory if paymentMethod 1 / 2)
$beneficiaryAddress1 = 'Jakarta', // optional max 50 char (mandatory if paymentMethod 1 / 2)
$beneficiaryAddress2 = '', // optional max 50 char
$destinationBankCode = '', // optional (mandatory if paymentMethod 1 / 2)
$chargingModelId = 'OUR' // OUR: fee will be paid by sender (default), BEN: fee will be paid by beneficary, SHA: fee divided
);
$getPaymentStatus $ogp->getPaymentStatus(
$customerReferenceNumber = '20170227000000000020' // max 20 char client defined reference number
);
$getInterBankInquiry = $ogp->getInterBankInquiry(
$customerReferenceNumber = '20170227000000000021', // max 20 char client defined reference number
$accountNum = '113183203',
$destinationBankCode = '014',
$destinationAccountNum = '3333333333'
);
$getInterBankPayment = $ogp->getInterBankPayment(
$customerReferenceNumber = '20170227000000000021', // max 20 char client defined reference number
$amount = '100500',
$destinationAccountNum = '3333333333',
$destinationAccountName = 'BENEFICIARY NAME 1 UNTIL HERE1BENEFICIARY NAME 2(OPT) UNTIL HERE2',
$destinationBankCode = '014',
$destinationBankName = 'BCA',
$accountNum = '115471119',
$retrievalReffNum = '100000000024' // refference number for Interbank Transaction
);
$holdAmount = $ogp->holdAmount(
$customerReferenceNumber = '20170504153218296', // max 20 char client defined reference number
$amount = '12007',
$accountNo = '0115476151',
$detail = '' // optional
);
$holdAmountRelease = $ogp->holdAmountRelease(
$customerReferenceNumber = '20170504153218296', // max 20 char client defined reference number
$amount = 12007,
$accountNo = '0115476151',
$bankReference = '513668', // journal number. you can get this value from hold amount response
$holdTransactionDate = '31052010' // the date when you do the hold transaction
);
Create Snap BI
class object
use BniApi\BniPhp\Bni;
use BniApi\BniPhp\api\SnapBI;
$bni = new Bni(
$env = 'sandbox', // dev, sandbox, prod
$clientId = '{your-client-id}',
$clientSecret = '{your-client-secret}',
$apiKey = '{your-api-key}',
$apiSecret = '{your-api-secret}',
$appName = '{your-app-name}'
);
$snap = new SnapBI(
$bni = '{instance-of-bni-class}',
$privateKeyPath = '{your-path-private-key}',
$channelId = '{your-channel}'
);
Available methods for Snap BI
class
$balanceInquiry = $snap->balanceInquiry(
$partnerReferenceNo = '202010290000000000002', // optional
$accountNo = '0115476117'
);
$bankStatement = $snap->bankStatement(
$partnerReferenceNo = '202010290000000000002', // optional
$accountNo = '0115476117',
$fromDateTime = '2010-01-01T12:08:56+07:00', // optional
$toDateTime = '2011-01-01T12:08:56+07:00' // optional
);
$transactionStatusInquiry = $snap->transactionStatusInquiry(
$originalPartnerReferenceNo = '20211213100434', // optional
$originalReferenceNo = '20211220141520', // transaction reference number
$originalExternalId = '20211220141520', // optional
$serviceCode = '36', // SNAP BI service code
$transactionDate = '2021-12-20',
$amountValue = '12500.00',
$amountCurrency = 'IDR',
$addtionalInfoDeviceId = '123456', // optinal
$additionalInfoChannel = 'mobilephone', // optinal
);
$transferIntraBank = $snap->transferIntraBank(
$partnerReferenceNo = '202201911020300006', // transaction reference number
$amountValue = '12500',
$amountCurrency = 'IDR',
$beneficiaryAccountNo = '0115476117',
$beneficiaryEmail = 'mail@example.com', // optional
$currency = 'IDR', // optional
$customerReference = '14045', // optional
$feeType = 'OUR', // OUR: fee will be paid by sender (default), BEN: fee will be paid by beneficary, SHA: fee divided
$remark = '', // optional
$sourceAccountNo = '0115476151',
$transactionDate = '2021-12-13',
$additionalInfoDeviceId = '123456',
$additionalInfoChannel = 'mobilephone'
);
$transferRTGS = $snap->transferRTGS(
$partnerReferenceNo = '202201911020300011', // transaction reference number
$amountValue = '150005001',
$amountCurrency = 'IDR',
$beneficiaryAccountName = 'SAN',
$beneficiaryAccountNo = '3333333333',
$beneficiaryBankCode = 'CENAIDJA',
$beneficiaryBankName = 'Jakarta Barat', // optional
$beneficiaryCustomerResidence = '1',
$beneficiaryCustomerType = '1',
$beneficiaryEmail = 'mail@example.com', // optional
$customerReference = '202201911020300006',
$feeType = 'OUR', // OUR: fee will be paid by sender (default), BEN: fee will be paid by beneficary, SHA: fee divided
$kodepos = '12550', // optional
$recieverPhone = '08123456789', // optional
$remark = '', // optional
$senderCustomerResidence = '1', // optional
$senderCustomerType = '1', // optional
$senderPhone = '08123456789', // optional
$sourceAccountNo = '0115476151',
$transactionDate = '2022-01-25',
$additionalInfoDeviceId = '123456', // optional
$additionalInfoChannel = 'mobilephone' // optional
);
$transferSKNBI = $snap->transferSKNBI(
$partnerReferenceNo = '202201911020300012', // transaction reference number
$amountValue = '150005001',
$amountCurrency = 'IDR',
$beneficiaryAccountName = 'SAN',
$beneficiaryAccountNo = '3333333333',
$beneficiaryAccountAddress = 'Jakarta Barat', // optional
$beneficiaryBankCode = '0140397',
$beneficiaryBankName = 'PT. BANK CENTRAL ASIA Tbk.', // optional
$beneficiaryCustomerResidence = '1',
$beneficiaryCustomerType = '1',
$beneficiaryEmail = 'mail@example.com' // optional
$currency = 'IDR', // optional
$customerReference = '202201911020300006',
$feeType = 'OUR', // OUR: fee will be paid by sender (default), BEN: fee will be paid by beneficary, SHA: fee divided
$kodepos = '12550', // optional
$recieverPhone = '08123456789', // optional
$remark = '', // optional
$senderCustomerResidence = '1', // optional
$senderCustomerType = '1', // optional
$senderPhone = '08123456789', // optional
$sourceAccountNo = '0115476151',
$transactionDate = '2022-01-25',
$additionalInfoDeviceId = '123456', // optional
$additionalInfoChannel = 'mobilephone' // optional
);
$externalAccountInquiry = $snap->externalAccountInquiry(
$beneficiaryBankCode = '002',
$beneficiaryAccountNo = '888801000157508',
$partnerReferenceNo = '2020102900000000000001', // optional
$additionalInfoDeviceId = '123456', // optional
$additionalInfoChannel = 'mobilephone' // optional
);
$transferInterBank = $snap->transferInterBank(
$partnerReferenceNo = '2020102900000000000001', // transaction reference number
$amountValue = '12345678.00',
$amountCurrency = 'IDR',
$beneficiaryAccountName = 'Yories Yolanda',
$beneficiaryAccountNo = '888801000003301',
$beneficiaryAccountAddress = 'Palembang', // optional
$beneficiaryBankCode = '002',
$beneficiaryBankName = 'Bank BRI', // optional
$beneficiaryEmail = 'mail@example.com', // optional
$currency = 'IDR', // optional
$customerReference = '10052019', // optional
$sourceAccountNo = '888801000157508',
$transactionDate = '2019-07-03T12:08:56-07:00',
$feeType = 'OUR', // OUR: fee will be paid by sender (default), BEN: fee will be paid by beneficary, SHA: fee divided
$additionalInfoDeviceId = '123456', // optional
$additionalInfoChannel = 'mobilephone' // optional
);
Create Autopay
class object
use BniApi\BniPhp\api\Autopay;
$autopay = new Autopay(
$merchantID,
$clientID,
$clientSecret,
$privateKey,
'alpha'
);
Available methods for Autopay
class
$response = $autopay->accountBinding(
$partnerReferenceNo = '123456789009876544002',
$bankAccountNo = '92345678902787',
$bankCardNo = '92345678902788',
$limit = 250000.00,
$email = 'burhanaji2@gmail.com',
$custIdMerchant = '92345678902788'
);
$response = $autopay->accountUnbinding(
$partnerReferenceNo = '12345678900987654484',
$bankCardToken =
'vvSWxFEu5p6ONXT3qEoZ2L5o7YJ4UjH7Mee3SDuxigMixnfVuOnQpbJxuboXijOAlna' .
'ow6XVqP7VCyQqSSzdv24OQjGl7IRuUAVcAgzKzJQoybSLPk0kKKCdqJqwrOXZ',
$chargeToken = 'Xob2d8BlMxVyQRloodpujCIvuFortJ',
$otp = '',
$custIdMerchant = '12313213131'
);
$response = $autopay->balanceInquiry(
$partnerReferenceNo = '2023102899999999999902',
$accountNo = '9234567846',
$amount = 1000.00,
$bankCardToken =
'q3jcQJJTrBvYzUt2VyzY68Klw8mG400K5NWaAL5JdTbjAqjXBG9LZr' .
'0F4khuVdrezjXFLEJRzvmF5xLZhT2fJj73FbQlf9FeqGCNW8HKSEOpzz83HYkUaQWBX2TPkaJM'
);
$response = $autopay->debit(
$partnerReferenceNo = '123456789009876477',
$bankCardToken =
'YKYpg4xqTK1IuhlGQnrpiXHnxTcFx8ntjVfggWddVtTqsD8aUvi74oSijcVF0eV9' .
'1zVbCganXNROsFUURUzPLWbSZp5yHKmMnijS4D2yrMeJ7yJHHTYtRHpCP2GcoXJ3',
$chargeToken = 'ZDkLEQDZspP9FbahGkJoo3NmiSC6p0',
$otp = '',
$amount = [
'value' => '1000.00',
'currency' => 'IDR'
],
$remark = 'remark'
);
$response = $autopay->debitRefund(
$originalPartnerReferenceNo = '123456789009876408',
$partnerRefundNo = '223456789009876487',
$refundAmount = [
'value' => 1000.00,
'currency' => 'IDR'
],
$reason = 'Complaint from customer',
$refundType = 'full'
);
$response = $autopay->debitStatus(
$originalPartnerReferenceNo = '123456789009876408',
$transactionDate = '20220419',
$serviceCode = '54',
$amount = [
'value' => 1000.00,
'currency' => 'IDR'
]
);
$response = $autopay->limitInquiry(
$partnerReferenceNo = '2020102900000000000001',
$bankCardToken = '6d7963617264746f6b656e',
$accountNo = '7382382957893840',
$amount = 200000.00
);
$response = $autopay->otp(
$partnerReferenceNo = '12345678900987654484',
$journeyID = '12345678900987654484',
$bankCardToken =
'vvSWxFEu5p6ONXT3qEoZ2L5o7YJ4UjH7Mee3SDuxigMixnfVuOnQpbJxuboXijOAlna' .
'ow6XVqP7VCyQqSSzdv24OQjGl7IRuUAVcAgzKzJQoybSLPk0kKKCdqJqwrOXZ',
$otpReasonCode = '54',
$additionalInfo = [
'expiredOtp' => "2023-07-26T18:56:11+07:00",
],
$externalStoreId = '134928924949479'
);
$response = $autopay->verifyOtp(
$originalPartnerReferenceNo = '123456789009876533',
$originalReferenceNo = '7979309099377000825262452054700150269920536175232508970766089901',
$chargeToken = 'dI7aK7aEbdgeMDnG2ygcEHQpyJQINm',
$otp = '359677'
);
$response = $autopay->setLimit(
$partnerReferenceNo = '12345678900987654484',
$bankCardToken =
'vvSWxFEu5p6ONXT3qEoZ2L5o7YJ4UjH7Mee3SDuxigMixnfVuOnQpbJxuboXijOAlna' .
'ow6XVqP7VCyQqSSzdv24OQjGl7IRuUAVcAgzKzJQoybSLPk0kKKCdqJqwrOXZ',
$limit = 250000.00,
$chargeToken = '931C5fuQgmB3FICZOag30G9p0X4Gtb',
$otp = '898201'
);
Create Ecollection
class object
use BniApi\BniPhp\Bni;
use BniApi\BniPhp\api\SnapBI;
$bni = new Bni(
$env = 'sandbox', // dev, sandbox, prod
$clientId = '{your-client-id}', // clientId consists prefix and client id separated with dash (-) character. Example: 8-000. 8 as prefix, 000 as client id
$clientSecret = '{your-client-secret}', // client secret key
$apiKey = '{your-api-key}', // can be emptied
$apiSecret = '{your-api-secret}', // can be emptied
$appName = '{your-app-name}' // can be emptied
);
$ecoll = new Ecollection($bni);
Available methods for Ecollection
class
$createBilling = $ecoll->createBilling(
$trxId = "trx-id899", // mandatory
$trxAmount = "100000", // mandatory except billing type is "o" (open payment)
$billingType = "c", // mandatory. Credit: o,c,i,m,n,x. Debit: p,j,d,z
$customerName = "test name", // mandatory
$customerEmail = "mail@example.com", // optional
$customerPhone = "08123123", // optional
$virtualAccount = "", // optional, if empty then autogenerated
$datetimeExpired = "2023-09-31T17:00:00+07:00", // optional
$description = "test description update", // optional
);
$updateBilling = $ecoll->updateBilling(
$trxId = "trx-id6", // mandatory
$trxAmount = "100000", // mandatory except billing type is "o" (open payment)
$customerName = "test name updated", // mandatory
$customerEmail = "", // optional
$customerPhone = "", // optional
$virtualAccount = "8325201106194912", // optional
$datetimeExpired = "2023-09-31T17:00:00+07:00", // optional
$description = "test description update", // optional
);
$inquiryBilling = $ecoll->inquiryBilling(
$trxId = "trx-id6",
);
$inactiveBilling = $ecoll->inactiveBilling(
$trxId = "trx-id6", // mandatory
$virtualAccount = "8325201106194911" // mandatory
);
### 2.2.C Fintech Account Service (RDF)
Create `RDF` Class Object
```php
use BniApi\BniPhp\Bni;
use BniApi\BniPhp\api\RDF;
$bni = new Bni(
$env = 'sandbox', // dev, sandbox, prod
$clientId = '{your-client-id}',
$clientSecret = '{your-client-secret}',
$apiKey = '{your-api-key}',
$apiSecret = '{your-api-secret}',
$appName = '{your-app-name}'
);
$rdf = new RDF(
$bni = '{instance-of-bni-class}',
$privateKeyPath = '{your-path-private-key}',
$channelId = '{your-channel}'
);
$faceRecognition = $rdf->faceRecognition(
$companyId = 'SANDBOX',
$parentCompanyId = 'STI_CHS',
$firstName = 'MOHAMMAD',
$middleName = 'BAQER',
$lastName = 'ZALQAD',
$idNumber = '0141111121260118', // Identity Number (KTP only)
$birthDate = '29-09-2021', // format : DD-MM-YYYY
$birthPlace = 'BANDUNG',
$gender = 'M', // “M” or “F”
$cityAddress = 'Bandung',
$stateProvAddress = 'Jawa Barat',
$addressCountry = 'ID', // e.g.: “ID”
$streetAddress1 = 'bandung',
$streetAddress2 = 'bandung',
$postCodeAddress = '40914',
$country = 'ID', // e.g.: “ID”
$selfiePhoto = '29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuP', // Base64 encoded selfie photo
);
$registerInvestor = $rdf->registerInvestor(
$companyId = 'SANDBOX',
$parentCompanyId = 'STI_CHS',
$uuidFaceRecog = '492F33851D634CFB', // RequestUuid successed value from Face Recognition API (KYC valid)
$title = '01',
$firstName = 'Agus',
$middleName = '',
$lastName = 'Saputra',
$optNPWP = '1', // “1” or “0” (Default “1”)
$NPWPNum = '001058893408123',
$nationality = 'ID', // e.g.: “ID”
$domicileCountry = 'ID', // e.g.: “ID”
$religion = '2',
$birthPlace = 'Semarang',
$birthDate = '14081982', // DDMMYYYY
$gender = 'M', // “M” or “F”
$isMarried = 'S',
$motherMaidenName = 'Dina Maryati',
$jobCode = '01',
$education = '07',
$idType = '01',
$idNumber = '4147016201959998', // Identity Number (KTP only)
$idIssuingCity = 'Jakarta Barat',
$idExpiryDate = '26102099', // ddMMyyyy
$addressStreet = 'Jalan Mawar Melati',
$addressRtRwPerum = '003009Sentosa',
$addressKel = 'Cengkareng Barat',
$addressKec = 'Cengkareng/Jakarta Barat',
$zipCode = '11730',
$homePhone1 = '0214', // Area code, e.g. 021 (3 - 4 digit) If not exist, fill with “9999”
$homePhone2 = '7459', // Number after area code (min 4 digit) If not exist, fill with “99999999”
$officePhone1 = '', // Area code, e.g. 021
$officePhone2 = '', // Number after area code
$mobilePhone1 = '0812', // Operator code, e.g. 0812 (4 digit) If not exist, fill with “0899”
$mobilePhone2 = '12348331', // Number after operator code (min 6 digit) If not exist, fill with “999999”
$faxNum1 = '', // Area code, e.g. 021
$faxNum2 = '', // Number after area code
$email = 'agus.saputra@gmail.com',
$monthlyIncome = '8000000',
$branchOpening = '0259',
$institutionName = 'PT. BNI SECURITIES',
$sid = 'IDD280436215354',
$employerName = 'Salman', // Employer Name / Company Name
$employerAddDet = 'St Baker', // Employer street address / home street address
$employerAddCity = 'Arrandelle', // Employer city address / home city address
$jobDesc = 'Pedagang' // Current investor job,
$ownedBankAccNo = '0337109074', // Investor’s owned bank account
$idIssuingDate = '10122008' // Issue date, e.g.: “10122016”
);
$registerInvestorAccount = $rdf->registerInvestorAccount(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$cifNumber = '9100749959',
$currency = 'IDR',
$openAccountReason = '2',
$sourceOfFund = '1',
$branchId = '0259',
$bnisId = '19050813401',
$sre = 'NI001CX5U00109',
)
$inquiryAccountInfo = $rdf->inquiryAccountInfo(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117'
)
$inquiryAccountBalance = $rdf->inquiryAccountBalance(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117'
)
$inquiryAccountHistory = $rdf->inquiryAccountHistory(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117'
)
$paymentUsingTransfer = $rdf->paymentUsingTransfer(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117',
$beneficiaryAccountNumber = '0115471119',
$currency = 'IDR', // e.g., “IDR”
$amount = '11500',
$remark = 'Test RDN' // Recommended for the reconciliation purpose
)
$inquiryPaymentStatus = $rdf->inquiryPaymentStatus(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$requestedUuid = 'E8C6E0027F6E429F' // UUID that has been processed before
)
$paymentUsingClearing = $rdf->paymentUsingClearing(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117',
$beneficiaryAccountNumber = '3333333333',
$beneficiaryAddress1 = 'Jakarta',
$beneficiaryAddress2 = '',
$beneficiaryBankCode = '140397',
$beneficiaryName = 'Panji Samudra',
$currency = 'IDR', // e.g., “IDR”
$amount = 15000,
$remark = 'Test kliring', // Recommended for the reconciliation purpose
$chargingType = 'OUR'
)
$paymentUsingRTGS = $rdf->paymentUsingRTGS(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117',
$beneficiaryAccountNumber = '3333333333',
$beneficiaryAddress1 = 'Jakarta',
$beneficiaryAddress2 = '',
$beneficiaryBankCode = 'CENAIDJA',
$beneficiaryName = 'Panji Samudra',
$currency = 'IDR', // e.g., “IDR”
$amount = 120000000,
$remark = 'Test rtgs', // Recommended for the reconciliation purpose
$chargingType = 'OUR'
)
$inquiryInterbankAccount = $rdf->inquiryInterbankAccount(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117',
$beneficiaryBankCode = '013',
$beneficiaryAccountNumber = '01300000',
)
$paymentUsingInterbank = $rdf->paymentUsingInterbank(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117',
$beneficiaryAccountNumber = '3333333333',
$beneficiaryAccountName = 'KEN AROK', // Get from Inquiry Interbank Account
$beneficiaryBankCode = '014',
$beneficiaryBankName = 'BANK BCA', // Get from Inquiry Interbank Account
$amount = 15000,
)
Create RDN
Class Object
use BniApi\BniPhp\Bni;
use BniApi\BniPhp\api\RDN;
$bni = new Bni(
$env = 'sandbox', // dev, sandbox, prod
$clientId = '{your-client-id}',
$clientSecret = '{your-client-secret}',
$apiKey = '{your-api-key}',
$apiSecret = '{your-api-secret}',
$appName = '{your-app-name}'
);
$rdn = new RDN(
$bni = '{instance-of-bni-class}',
$privateKeyPath = '{your-path-private-key}',
$channelId = '{your-channel}'
);
$faceRecognition = $rdn->faceRecognition(
$companyId = 'SANDBOX',
$parentCompanyId = 'STI_CHS',
$firstName = 'MOHAMMAD',
$middleName = 'BAQER',
$lastName = 'ZALQAD',
$idNumber = '0141111121260118', // Identity Number (KTP only)
$birthDate = '29-09-2021', // format : DD-MM-YYYY
$birthPlace = 'BANDUNG',
$gender = 'M', // “M” or “F”
$cityAddress = 'Bandung',
$stateProvAddress = 'Jawa Barat',
$addressCountry = 'ID', // e.g.: “ID”
$streetAddress1 = 'bandung',
$streetAddress2 = 'bandung',
$postCodeAddress = '40914',
$country = 'ID', // e.g.: “ID”
$selfiePhoto = '29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuP', // Base64 encoded selfie photo
);
$checkSID = $rdn->checkSID(
$companyId = 'SANDBOX',
$parentCompanyId = 'KSEI',
$requestUuid = '52D3E26AA18D4FCA',
$participantId = 'NI001',
$sidNumber = 'IDD1206M9527805',
$accountNumberOnKsei = 'NI001CRKG00146',
$branchCode = '0259',
$ack = 'N'
);
$registerInvestor = $rdn->registerInvestor(
$companyId = 'SANDBOX',
$parentCompanyId = 'STI_CHS',
$uuidFaceRecog = '492F33851D634CFB', // RequestUuid successed value from Face Recognition API (KYC valid)
$title = '01',
$firstName = 'Agus',
$middleName = '',
$lastName = 'Saputra',
$optNPWP = '1', // “1” or “0” (Default “1”)
$NPWPNum = '001058893408123',
$nationality = 'ID', // e.g.: “ID”
$domicileCountry = 'ID', // e.g.: “ID”
$religion = '2',
$birthPlace = 'Semarang',
$birthDate = '14081982', // DDMMYYYY
$gender = 'M', // “M” or “F”
$isMarried = 'S',
$motherMaidenName = 'Dina Maryati',
$jobCode = '01',
$education = '07',
$idType = '01',
$idNumber = '4147016201959998', // Identity Number (KTP only)
$idIssuingCity = 'Jakarta Barat',
$idExpiryDate = '26102099', // ddMMyyyy
$addressStreet = 'Jalan Mawar Melati',
$addressRtRwPerum = '003009Sentosa',
$addressKel = 'Cengkareng Barat',
$addressKec = 'Cengkareng/Jakarta Barat',
$zipCode = '11730',
$homePhone1 = '0214', // Area code, e.g. 021 (3 - 4 digit) If not exist, fill with “9999”
$homePhone2 = '7459', // Number after area code (min 4 digit) If not exist, fill with “99999999”
$officePhone1 = '', // Area code, e.g. 021
$officePhone2 = '', // Number after area code
$mobilePhone1 = '0812', // Operator code, e.g. 0812 (4 digit) If not exist, fill with “0899”
$mobilePhone2 = '12348331', // Number after operator code (min 6 digit) If not exist, fill with “999999”
$faxNum1 = '', // Area code, e.g. 021
$faxNum2 = '', // Number after area code
$email = 'agus.saputra@gmail.com',
$monthlyIncome = '8000000',
$branchOpening = '0259',
$institutionName = 'PT. BNI SECURITIES',
$sid = 'IDD280436215354',
$employerName = 'Salman', // Employer Name / Company Name
$employerAddDet = 'St Baker', // Employer street address / home street address
$employerAddCity = 'Arrandelle', // Employer city address / home city address
$jobDesc = 'Pedagang' // Current investor job,
$ownedBankAccNo = '0337109074', // Investor’s owned bank account
$idIssuingDate = '10122008' // Issue date, e.g.: “10122016”
);
$registerInvestorAccount = $rdn->registerInvestorAccount(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$cifNumber = '9100749959',
$currency = 'IDR',
$openAccountReason = '2',
$sourceOfFund = '1',
$branchId = '0259',
$bnisId = '19050813401',
$sre = 'NI001CX5U00109',
)
$sendDataStatic = $rdn->sendDataStatic(
$companyId = 'SPS App',
$parentCompanyId = 'KSEI',
$participantCode = 'NI001', // Institution code, e.g: “NI001”
$participantName = 'PT. BNI SECURITIES', // Institution name, e.g.: “PT. BNI SECURITIES”
$investorName = 'SUMARNO',
$investorCode = 'IDD250436742277', // Investor code, e.g.: “IDD250436742277”
$investorAccountNumber = 'NI001042300155', // e.g.: “NI001042300155”
$bankAccountNumber = '242345393', // e.g.: “242345393”
$activityDate = '20180511', // yyyyMMdd, e.g: “20180511”
$activity = 'O' // (O)pening / (C)lose / (B)lock Account / (U)nblock Account
)
$inquiryAccountInfo = $rdn->inquiryAccountInfo(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117'
)
$inquiryAccountBalance = $rdn->inquiryAccountBalance(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117'
)
$inquiryAccountHistory = $rdn->inquiryAccountHistory(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117'
)
$paymentUsingTransfer = $rdn->paymentUsingTransfer(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117',
$beneficiaryAccountNumber = '0115471119',
$currency = 'IDR', // e.g., “IDR”
$amount = 11500,
$remark = 'Test RDN' // Recommended for the reconciliation purpose
)
$inquiryPaymentStatus = $rdn->inquiryPaymentStatus(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$requestedUuid = 'E8C6E0027F6E429F' // UUID that has been processed before
)
$paymentUsingClearing = $rdn->paymentUsingClearing(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117',
$beneficiaryAccountNumber = '3333333333',
$beneficiaryAddress1 = 'Jakarta',
$beneficiaryAddress2 = '',
$beneficiaryBankCode = '140397',
$beneficiaryName = 'Panji Samudra',
$currency = 'IDR', // e.g., “IDR”
$amount = 15000,
$remark = 'Test kliring', // Recommended for the reconciliation purpose
$chargingType = 'OUR'
)
$paymentUsingRTGS = $rdn->paymentUsingRTGS(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117',
$beneficiaryAccountNumber = '3333333333',
$beneficiaryAddress1 = 'Jakarta',
$beneficiaryAddress2 = '',
$beneficiaryBankCode = 'CENAIDJA',
$beneficiaryName = 'Panji Samudra',
$currency = 'IDR', // e.g., “IDR”
$amount = 120000000,
$remark = 'Test rtgs', // Recommended for the reconciliation purpose
$chargingType = 'OUR'
)
$inquiryInterbankAccount = $rdn->inquiryInterbankAccount(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117',
$beneficiaryBankCode = '013',
$beneficiaryAccountNumber = '01300000',
)
$paymentUsingInterbank = $rdn->paymentUsingInterbank(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117',
$beneficiaryAccountNumber = '3333333333',
$beneficiaryAccountName = 'KEN AROK', // Get from Inquiry Interbank Account
$beneficiaryBankCode = '014',
$beneficiaryBankName = 'BANK BCA', // Get from Inquiry Interbank Account
$amount = 15000,
)
Create RDL
Class Object
use BniApi\BniPhp\Bni;
use BniApi\BniPhp\api\RDL;
$bni = new Bni(
$env = 'sandbox', // dev, sandbox, prod
$clientId = '{your-client-id}',
$clientSecret = '{your-client-secret}',
$apiKey = '{your-api-key}',
$apiSecret = '{your-api-secret}',
$appName = '{your-app-name}'
);
$rdl = new RDL(
$bni = '{instance-of-bni-class}',
$privateKeyPath = '{your-path-private-key}',
$channelId = '{your-channel}'
);
$faceRecognition = $rdl->faceRecognition(
$companyId = 'SANDBOX',
$parentCompanyId = 'STI_CHS',
$firstName = 'MOHAMMAD',
$middleName = 'BAQER',
$lastName = 'ZALQAD',
$idNumber = '0141111121260118', // Identity Number (KTP only)
$birthDate = '29-09-2021', // format : DD-MM-YYYY
$birthPlace = 'BANDUNG',
$gender = 'M', // “M” or “F”
$cityAddress = 'Bandung',
$stateProvAddress = 'Jawa Barat',
$addressCountry = 'ID', // e.g.: “ID”
$streetAddress1 = 'bandung',
$streetAddress2 = 'bandung',
$postCodeAddress = '40914',
$country = 'ID', // e.g.: “ID”
$selfiePhoto = '29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuP', // Base64 encoded selfie photo
);
$registerInvestor = $rdl->registerInvestor(
$companyId = 'SANDBOX',
$parentCompanyId = 'STI_CHS',
$uuidFaceRecog = '492F33851D634CFB', // RequestUuid successed value from Face Recognition API (KYC valid)
$title = '01',
$firstName = 'Agus',
$middleName = '',
$lastName = 'Saputra',
$optNPWP = '1', // “1” or “0” (Default “1”)
$NPWPNum = '001058893408123',
$nationality = 'ID', // e.g.: “ID”
$domicileCountry = 'ID', // e.g.: “ID”
$religion = '2',
$birthPlace = 'Semarang',
$birthDate = '14081982', // DDMMYYYY
$gender = 'M', // “M” or “F”
$isMarried = 'S',
$motherMaidenName = 'Dina Maryati',
$jobCode = '01',
$education = '07',
$idType = '01',
$idNumber = '4147016201959998', // Identity Number (KTP only)
$idIssuingCity = 'Jakarta Barat',
$idExpiryDate = '26102099', // ddMMyyyy
$addressStreet = 'Jalan Mawar Melati',
$addressRtRwPerum = '003009Sentosa',
$addressKel = 'Cengkareng Barat',
$addressKec = 'Cengkareng/Jakarta Barat',
$zipCode = '11730',
$homePhone1 = '0214', // Area code, e.g. 021 (3 - 4 digit) If not exist, fill with “9999”
$homePhone2 = '7459', // Number after area code (min 4 digit) If not exist, fill with “99999999”
$officePhone1 = '', // Area code, e.g. 021
$officePhone2 = '', // Number after area code
$mobilePhone1 = '0812', // Operator code, e.g. 0812 (4 digit) If not exist, fill with “0899”
$mobilePhone2 = '12348331', // Number after operator code (min 6 digit) If not exist, fill with “999999”
$faxNum1 = '', // Area code, e.g. 021
$faxNum2 = '', // Number after area code
$email = 'agus.saputra@gmail.com',
$monthlyIncome = '8000000',
$branchOpening = '0259',
$institutionName = 'PT. BNI SECURITIES',
$sid = 'IDD280436215354',
$employerName = 'Salman', // Employer Name / Company Name
$employerAddDet = 'St Baker', // Employer street address / home street address
$employerAddCity = 'Arrandelle', // Employer city address / home city address
$jobDesc = 'Pedagang' // Current investor job,
$ownedBankAccNo = '0337109074', // Investor’s owned bank account
$idIssuingDate = '10122008' // Issue date, e.g.: “10122016”
);
$registerInvestorAccount = $rdl->registerInvestorAccount(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$cifNumber = '9100749959',
$currency = 'IDR',
$openAccountReason = '2',
$sourceOfFund = '1',
$branchId = '0259',
$bnisId = '19050813401',
$sre = 'NI001CX5U00109',
)
$inquiryAccountInfo = $rdl->inquiryAccountInfo(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117'
)
$inquiryAccountBalance = $rdl->inquiryAccountBalance(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117'
)
$inquiryAccountHistory = $rdl->inquiryAccountHistory(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117'
)
$paymentUsingTransfer = $rdl->paymentUsingTransfer(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117',
$beneficiaryAccountNumber = '0115471119',
$currency = 'IDR', // e.g., “IDR”
$amount = 11500,
$remark = 'Test RDN' // Recommended for the reconciliation purpose
)
$inquiryPaymentStatus = $rdl->inquiryPaymentStatus(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$requestedUuid = 'E8C6E0027F6E429F' // UUID that has been processed before
)
$paymentUsingClearing = $rdl->paymentUsingClearing(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117',
$beneficiaryAccountNumber = '3333333333',
$beneficiaryAddress1 = 'Jakarta',
$beneficiaryAddress2 = '',
$beneficiaryBankCode = '140397',
$beneficiaryName = 'Panji Samudra',
$currency = 'IDR', // e.g., “IDR”
$amount = 15000,
$remark = 'Test kliring', // Recommended for the reconciliation purpose
$chargingType = 'OUR'
)
$paymentUsingRTGS = $rdl->paymentUsingRTGS(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117',
$beneficiaryAccountNumber = '3333333333',
$beneficiaryAddress1 = 'Jakarta',
$beneficiaryAddress2 = '',
$beneficiaryBankCode = 'CENAIDJA',
$beneficiaryName = 'Panji Samudra',
$currency = 'IDR', // e.g., “IDR”
$amount = 120000000,
$remark = 'Test rtgs', // Recommended for the reconciliation purpose
$chargingType = 'OUR'
)
$inquiryInterbankAccount = $rdl->inquiryInterbankAccount(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117',
$beneficiaryBankCode = '013',
$beneficiaryAccountNumber = '01300000',
)
$paymentUsingInterbank = $rdl->paymentUsingInterbank(
$companyId = 'NI001',
$parentCompanyId = 'KSEI',
$accountNumber = '0115476117',
$beneficiaryAccountNumber = '3333333333',
$beneficiaryAccountName = 'KEN AROK', // Get from Inquiry Interbank Account
$beneficiaryBankCode = '014',
$beneficiaryBankName = 'BANK BCA', // Get from Inquiry Interbank Account
$amount = 15000,
)
Create Bni Move
Class Object
use BniApi\BniPhp\Bni;
use BniApi\BniPhp\api\RDL;
$bni = new Bni(
$env = 'sandbox', // dev, sandbox, prod
$clientId = '{your-client-id}',
$clientSecret = '{your-client-secret}',
$apiKey = '{your-api-key}',
$apiSecret = '{your-api-secret}',
$appName = '{your-app-name}'
);
$bniMove = new BniMove($bni)
$prescreening = $bniMove->prescreening(
$kodeMitra = 'BNI',
$npp = '',
$namaLengkapKtp = 'Muhammad Haikal Madani',
$noKtp = '3174052209980002',
$noHandphone = '085921658045',
$alamatUsaha = 'jakarta',
$provinsiUsaha = '06',
$kotaUsaha = '143',
$kecamatanUsaha = '1074',
$kelurahanUsaha = '4254',
$kodePosUsaha = '11450',
$sektorEkonomi = '2',
$totalPenjualan = 50000000,
$jangkaWaktu = '12',
$jenisPinjaman = '1',
$maximumKredit = 50000000,
$jenisKelamin = '1',
$tanggalLahir = '1998-10-07',
$subSektorEkonomi = '050111',
$deskripsi = 'Usaha Ternak Perikanan',
$Email = 'muhammadhaikalmadani@mail.com'
);
$bniMove = new BniMove($bni)
$prescreening = $bniMove->saveImage(
$Id = 'MJO2024022000004',
$deskripsi = 'Foto Identitas KTP',
$jenisDokumen = 'A03',
$namaFile = 'Foto KTP',
$extensionFile = 'png',
$dataBase64 = '{image}' #convert your image to base64
);
- Digital Services
- API documentation
- Stackoverflow
- Can't find answer you looking for? email to apisupport@bni.co.id