The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Business::Payment::SwissESR::V11Parser - Class for parsing v11 records

SYNOPSYS

 use Business::Payment::SwissESR::V11Parser;
 my $parser = Business::Payment::SwissESR::V11Parser->new();
 my $records = $parser->parse($data);
 for my $rec (@$records){
    warn Dumper $rec;
 }

DESCRIPTION

When issuing ESR payment slips to your customers, you can get payment data from swisspost in the form of so called v11 files. They contain information about the paiments received. This class transforms this information into easily accessible data.

See records https://www.postfinance.ch/content/dam/pf/de/doc/consult/manual/dldata/efin_recdescr_man_de.pdf for details (2.1 Gutschriftrecord Typ 3).

METHODS

$p->parse($string)

parses v11 encoded data and returns an array of hashes where each hash represents a payment.

      [ ...
          {
            'status' => 'reject',
            'microfilmReference' => '000010086',
            'transferDate' => '2012-09-26',
            'payDate' => '2012-09-25',
            'paymentLocation' => 'postoffice counter',
            'creditDate' => '2012-09-27',
            'submissionReference' => '5100  0100',
            'paymentType' => 'payment',
            'transactionCost' => '0.9',
            'paymentSlip' => 'ESR+',
            'amount' => '20',
            'referenceNumber' => '326015262012',
            'reseved' => '000000000',
            'accontNumber' => '01-17546-3'
          },
          {
            'status' => 'ok',
            'microfilmReference' => '004570001',
            'transferDate' => '2012-09-26',
            'payDate' => '2012-09-26',
            'paymentLocation' => 'online',
            'creditDate' => '2012-09-27',
            'submissionReference' => '0040  0400',
            'paymentType' => 'payment',
            'transactionCost' => '0',
            'paymentSlip' => 'ESR',
            'amount' => '40',
            'referenceNumber' => '326015852012',
            'reseved' => '000000000',
            'accontNumber' => '01-17546-3'
          },
       ... ]

COPYRIGHT

Copyright (c) 2014 by OETIKER+PARTNER AG. All rights reserved.

LICENSE

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.

AUTHOR

Tobias Oetiker <tobi@oetiker.ch>

HISTORY

 2014-06-23 to 0.6 initial version

1 POD Error

The following errors were encountered while parsing the POD:

Around line 205:

=back without =over