Finance::AMEX::Transaction::EPPRC::Detail::ChargeSummaryPricing - Parse AMEX Transaction/Invoice Level Reconciliation (EPPRC) Summary of Charge (SOC) Level Pricing Rows
version 0.005
use Finance::AMEX::Transaction; my $epraw = Finance::AMEX::Transaction->new(file_type => 'EPPRC'); open my $fh, '<', '/path to EPPRC file' or die "cannot open EPPRC file: $!"; while (my $record = $epraw->getline($fh)) { if ($record->type eq 'SOC_PRICING') { print $record->AMEX_PROCESS_DATE . "\n"; } } # to parse a single line my $record = $epraw->parse_line('line from an EPPRC file'); if ($record->type eq 'SOC_PRICING') { ... }
You would not normally be calling this module directly, it is one of the possible return objects from a call to Finance::AMEX::Transaction's getline method.
Returns a new Finance::AMEX::Transaction::EPPRC::Detail::ChargeSummaryPricing object.
my $record = Finance::AMEX::Transaction::EPPRC::Detail::ChargeSummaryPricing->new(line => $line);
This will always return the string SOC_PRICING.
print $record->type; # SOC_PRICING
Returns the full line that is represented by this object.
print $record->line;
Returns an arrayref of hashrefs where the name is the record name and the value is an arrayref of the start position and length of that field.
# print the start position of the PAYMENT_YEAR field print $record->field_map->[3]->{PAYMENT_YEAR}->[0]; # 31
This field contains the Service Establishment (SE) Number of the merchant that received the payment from American Express.
Note: SE Numbers are assigned by American Express.
This field contains the Service Establishment (SE) Number of the merchant being reconciled, which may not necessarily be the same SE receiving payment (see AMEX_PAYEE_NUMBER).
This is the SE Number under which the transactions were submitted, which usually corresponds to the physical location.
This field contains the merchant-assigned SE Unit Number (usually an internal, store identifier code) that corresponds to a specific store or location.
If no value is assigned, this field is character space filled.
This field contains the Payment Year that corresponds to the entry in the Julian Date subfield of PAYMENT_NUMBER.
This field contains the Payment Number, a reference number used by the American Express Payee to reconcile the daily settlement to the daily payment.
The Julian date of the payment.
An alpha character assigned by the American Express settlement system.
The Number of the payment.
This field contains the constant literal “2”, a Record Type code that indicates that this is a Summary of Charge (SOC) Detail Record.
This field contains the Detail Record Type code that indicates the type of record used in this transaction. For Summary of Charge (SOC) Level Pricing Records, this entry is always “12”
This field contains a Fee Code that corresponds to preceding SOC Detail Record. For valid SOC Level Pricing Record Fee Codes, see below:
Sr. No. Fee Code Fee Description 61 EP Expresspay Service Fee 62 EF ACH Service Fee 63 PG PIG Service Fee
This field contains the Fee Description that corresponds to the amount in FEE_CODE.
This field contains the Discount Rate (decimal place value) used to calculate the amount American Express charged a merchant for the services that correspond to the preceding SOC Detail Record.
Note: This field is not used when this record transports data for Automated Clearing House (ACH), Expresspay or Pay in Gross (PIG) fees.
This value may be a debit or credit rate. The format is a 1-digit “sign”, followed by an 8-digit “rate”.
For a debit (a negative rate), the first position is a minus sign; and a “negative .003 (.3%)” would appear as:
0 123456789 -00000300
For a credit (a positive rate), the first position is a plus sign; and a “positive .003 (.3%)” would appear as:
0 123456789 +00000300
If unused, position 1 in this field contains a character space; and the remaining positions are zero filled.
This field contains the Discount Amount that American Express charged a merchant for the services that correspond to the preceding SOC Detail Record.
This value may be a debit or credit amount; and the format is a 1-digit “sign”, followed by a 14-digit “dollar amount”.
For a debit (a negative amount), the first position is a minus sign; and a “negative $1005.05” would appear as:
0 1 123456789012345 -00000000100505
For a credit (a positive amount), the first position is a plus sign; and a “positive $1005.05” would appear as:
0 1 123456789012345 +00000000100505
This field contains the Fee Rate (decimal place value) used to calculate the amount American Express charged a merchant for a fee (described in the FEE_CODE and FEE_ DESCRIPTION fields in this record) that corresponds to the preceding SOC Detail Record. For more information, see FEE_CODE and FEE_ DESCRIPTION.
See examples of negative and positive entries under DISCOUNT_RATE.
This field contains the Fee Amount American Express charged a merchant for a fee (described in the FEE_CODE and FEE_DESCRIPTION fields in this record) that corresponds to the preceding SOC Detail Record. For more information, see FEE_CODE and FEE_DESCRIPTION.
This value may be a debit or credit amount. The format is a 1-digit “sign”, followed by a 14-digit “amount”.
See examples of negative and positive entries under DISCOUNT_AMOUNT.
This field contains the external, third party Service Agent Merchant ID number when applicable. Otherwise this field will be space filled.
Finance::AMEX::Transaction::EPPRC::Detail::ChargeSummaryPricing - Object methods for AMEX Reconciliation file summary of charge level pricing records.
Tom Heady <cpan@punch.net>
This software is copyright (c) 2022 by ZipRecruiter/Tom Heady.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Finance::AMEX::Transaction, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Finance::AMEX::Transaction
CPAN shell
perl -MCPAN -e shell install Finance::AMEX::Transaction
For more information on module installation, please visit the detailed CPAN module installation guide.