The Bermuda Commercial Bank (BCB) RESTful Open Banking API provides secure, programmatic access to BCB's banking services, enabling developers to integrate financial services into their applications.
https://developers.bcb.bm/_mock/apis/open-banking-api/open-banking-api/
https://api-uat.bcb.bm/
https://api.bcb.bm/
Initiates an internal funds transfer between two accounts within the institution. The request must include source and destination account details, along with the amount and currency to be transferred. Optionally, clients may provide a transaction reference and remittance information describing the purpose of the payment.
The API supports idempotency through the optional Idempotency-Key
header:
Clients must use the HTTP Accept header to indicate the desired response format:
Accept: application/json
for JSON responses (default).Accept: text/csv
for CSV responses. If the Accept header is omitted, application/json
is assumed.All API requests use the versioned base URL:
https://api.bcb.bm/v1/internal-transfers
async function executeInternalTransfer() {
try {
const response = await fetch('https://api.bcb.bm/v1/internal-transfers', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_ACCESS_TOKEN',
'Content-Type': 'application/json',
'Accept': 'application/json',
'Idempotency-Key': '123e4567-e89b-12d3-a456-426614174000' // Optional: UUID format required if provided
},
body: JSON.stringify({
debitAccountNumber: "12345678901234567890123456",
debitAmountCurrency: "USD",
creditAccountNumber: "98765432109876543210987654",
creditAmountCurrency: "USD", // Must match debitAmountCurrency
debitAmount: "100.00",
endToEndIdentification: "REF-INV-20250417-001", // Optional external transaction reference
remittanceInformationUnstructured: "Payment for invoice #12345" // Optional payment description
})
});
if (!response.ok) {
const errorData = await response.json();
throw new Error(`Transfer failed: ${JSON.stringify(errorData)}`);
}
const data = await response.json();
console.log('Transfer result:', data);
// Example processing of the returned object
const { id, status, uniqueIdentifier, internalTransferDetails, linkedActivities } = data;
const { amountCredited, creditAmountCurrency, debitAmount, amountDebited, chargeAmount, valueDate, chargeAnalysisReceiver, chargeAnalysisSender, debitAccountNumber, creditAccountNumber, chargeAccountNumber } = internalTransferDetails;
// Log the main transfer details.
console.log('Transaction ID:', id);
console.log('Status:', status);
console.log('Unique Identifier:', uniqueIdentifier);
console.log('Amount Credited:', amountCredited.amount, amountCredited.currency);
console.log('Credit Amount Currency:', creditAmountCurrency);
console.log('Debit Amount:', debitAmount.amount, debitAmount.currency);
console.log('Amount Debited:', amountDebited.amount, amountDebited.currency);
console.log('Charge Amount:', chargeAmount.amount, chargeAmount.currency);
console.log('Value Date:', valueDate);
console.log('Charge Analysis Receiver:', chargeAnalysisReceiver);
console.log('Charge Analysis Sender:', chargeAnalysisSender);
// Process debit account information.
console.log('Debit Account Number:', debitAccountNumber.number);
if (debitAccountNumber.accountRoutings) {
debitAccountNumber.accountRoutings.forEach(routing => {
console.log('Debit Account Routing Scheme:', routing.scheme);
console.log('Debit Account Routing Address:', routing.address);
});
}
// Process credit account information.
console.log('Credit Account Number:', creditAccountNumber.number);
if (creditAccountNumber.accountRoutings) {
creditAccountNumber.accountRoutings.forEach(routing => {
console.log('Credit Account Routing Scheme:', routing.scheme);
console.log('Credit Account Routing Address:', routing.address);
});
}
// Process charge account information.
console.log('Charge Account Number:', chargeAccountNumber.number);
if (chargeAccountNumber.accountRoutings) {
chargeAccountNumber.accountRoutings.forEach(routing => {
console.log('Charge Account Routing Scheme:', routing.scheme);
console.log('Charge Account Routing Address:', routing.address);
});
}
// Process linked activities.
linkedActivities.forEach(activity => {
console.log('Linked Activity ID:', activity.id);
console.log('Linked Activity Transaction Status:', activity.transactionStatus);
console.log('Linked Activity Status:', activity.status);
console.log('Linked Activity Unique Identifier:', activity.uniqueIdentifier);
const { arrangementId, activityId, productId, currencyId, effectiveDate } = activity.activityDetails;
console.log('Linked Activity Arrangement ID:', arrangementId);
console.log('Linked Activity Activity ID:', activityId);
console.log('Linked Activity Product ID:', productId);
console.log('Linked Activity Currency ID:', currencyId);
console.log('Linked Activity Effective Date:', effectiveDate);
});
// Final status logging.
if (status === 'SUCCESS') {
console.log('The transfer was successful.');
} else {
console.log('The transfer failed:', status);
}
} catch (error) {
console.error('Error executing internal transfer:', error);
}
}
executeInternalTransfer();
Required Permission: internal-transfer
This endpoint requires the permission claim internal-transfer
to be present in the JWT token. These permissions are embedded in the token during the authentication process and cannot be modified afterward. The token must be obtained with the appropriate permissions to access this endpoint.
The internal transfer request details.
The account number from which the money will be taken. Please ensure this account has enough funds before initiating the transfer.
The currency code for the credit amount, such as "USD", "EUR", etc.
The amount of money to be debited from the sender's account and credited to the recipient's account. Ensure the amount does not exceed the available balance in the debit account.
Reference provided by the client to identify the transaction end-to-end.
https://developers.bcb.bm/_mock/apis/open-banking-api/open-banking-api/v1/internal-transfers
https://api-uat.bcb.bm/v1/internal-transfers
https://api.bcb.bm/v1/internal-transfers
curl -i -X POST \
https://developers.bcb.bm/_mock/apis/open-banking-api/open-banking-api/v1/internal-transfers \
-H 'Authorization: Bearer <YOUR_jwt_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"debitAccountNumber": 9.876543210987655e+25,
"debitAmountCurrency": "USD",
"creditAccountNumber": 1.2345678901234568e+25,
"creditAmountCurrency": "USD",
"debitAmount": 100,
"endToEndIdentification": "REF-INV-20250417-001",
"remittanceInformation": "Payment for invoice #12345"
}'
{ "id": "internal-transfer-123", "status": "COMPLETED", "uniqueIdentifier": "unique-identifier-123", "internalTransferDetails": { "amountCredited": { … }, "creditAmountCurrency": "USD", "debitAmount": { … }, "amountDebited": { … }, "chargeAmount": { … }, "valueDate": "2023-05-31", "chargeAnalysisReceiver": "Receiver Charge Analysis", "chargeAnalysisSender": "Sender Charge Analysis", "debitAccountNumber": { … }, "creditAccountNumber": { … }, "chargeAccountNumber": { … } }, "linkedActivities": [ { … } ] }