-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding human-readable messages to bank reports (#29)
* Adding human-readable messages to bank reports Resolves ENG-65 * linting
- Loading branch information
1 parent
b547141
commit 65bc625
Showing
5 changed files
with
254 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
# frozen_string_literal: true | ||
|
||
module Bambora | ||
module Bank | ||
module BatchReportMessages | ||
## | ||
# Adds message text to the response as per the Bambora Docs: | ||
# https://help.na.bambora.com/hc/en-us/articles/115010510248-Batch-reporting | ||
MESSAGES = { | ||
'1' => 'Invalid bank number', | ||
'2' => 'Invalid branch number', | ||
'3' => 'Invalid account number', | ||
'4' => 'Invalid transaction amount', | ||
'5' => 'Reference number too long', | ||
'6' => 'Invalid due date', | ||
'7' => 'Due date out of valid date range', | ||
'8' => 'Customer name truncated to 32 characters', | ||
'9' => 'Customer name missing', | ||
'10' => 'Duplicate transaction matching bank account', | ||
'11' => 'Zero, negative or non-numeric amount', | ||
'12' => 'Invalid bank and/or branch number', | ||
'13' => 'Payee/drawee name cannot be spaces', | ||
'14' => 'Invalid payment code', | ||
'15' => 'Invalid transaction type', | ||
'16' => 'Account Closed', | ||
'17' => 'NSF – Debit declined due to insufficient funds.', | ||
'18' => 'Transaction rejected by Bank', | ||
'19' => 'Invalid bank, branch, or account number', | ||
'20' => 'Refused by payor', | ||
'21' => 'Funds not cleared', | ||
'22' => 'Account Frozen', | ||
'23' => 'Payment Stopped', | ||
'24' => 'Transaction Cancelled', | ||
'25' => 'Cannot Trace', | ||
'26' => 'Incorrect Payor/Payee Name', | ||
'27' => 'Payor/Payee Deceased', | ||
'28' => 'Invalid transit routing number', | ||
'29' => 'Invalid Account Type', | ||
'30' => 'Transaction type not permitted', | ||
'31' => 'No Checking Privileges', | ||
'33' => 'Edit Reject', | ||
'35' => 'Reserved Return Code', | ||
'36' => 'Payment Recalled', | ||
'38' => 'Not in accordance with agreement – Personal', | ||
'39' => 'Agreement revoked – Personal', | ||
'40' => 'No pre-notification – Personal', | ||
'41' => 'Not in accordance with agreement – Business', | ||
'42' => 'Agreement revoked – Business', | ||
'43' => 'No pre-notification – Business', | ||
'44' => 'Customer Initiated Return Credit Only', | ||
'45' => 'Currency/Account Mismatch', | ||
'46' => 'No Debit Allowed', | ||
'47' => 'Interbank – Returned Item', | ||
'48' => 'Routing as entered, account modified', | ||
'49' => 'Routing as entered, repair of account unknown', | ||
'50' => 'Routing as entered, account unknown', | ||
'51' => 'Routing number modified, account as entered', | ||
'52' => 'Routing number modified, account modified', | ||
'53' => 'Routing number modified, repair of account unknown', | ||
'54' => 'Routing number modified, account unknown', | ||
'55' => 'ACH Unavailable for account', | ||
'56' => 'Customer code invalid/missing payment info', | ||
'58' => 'Profile status is closed or disabled', | ||
'59' => 'Invalid SEC code', | ||
'60' => 'Invalid Account Identifier', | ||
'61' => 'Invalid Account Identifier', | ||
'62' => 'Reference Number is Missing', | ||
'63' => 'Invalid Customer Country Code', | ||
'64' => 'Invalid Bank Country Code', | ||
'65' => 'Invalid Bank Name', | ||
'66' => 'Bank Name is Missing', | ||
'67' => 'Addendum not allowed, too long, or has invalid characters', | ||
'68' => 'Invalid Bank Descriptor', | ||
'69' => 'Invalid Customer Name', | ||
'70' => 'Transaction rejected - contact support', | ||
'71' => 'Refund Request by End Customer', | ||
'72' => 'Blocked due to a Notice of Change', | ||
}.freeze | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters