vsoft/intl-payment-xml

This is a library for PHP to generate XML file for International Transaction(Virement International ou NON SEPA).

dev-master 2020-12-01 10:01 UTC

This package is auto-updated.

Last update: 2025-06-29 01:28:53 UTC


README

This is a library for PHP to generate XML file for International Transaction(Virement International ou NON SEPA).

Installation

Composer

This library uses Composer to make things easy.

Learn to use composer and add this to require section (in your composer.json) :

"vsoft/intl-payment-xml":"1.*@dev"

Example

<?php
use TransferFile\TransferFileCredit;

$test = TransferFileCredit::createCustomerTransfer(
	"uniqueID",
	"My society",
	"pain.001.001.03",
	"Europe/Paris"
);

$test->addPaymentInfo("ref-paiement-x",[
    "debtorName" => "My society",
    "debtorIBAN" => "FI1350001540000056",
    "debtorBIC" => "PSSTFRPPMON"
]
);

$test->createTransaction('payement-x',[
    "amount" => 500,
    "creditorIBAN" => "FI1350001540000056",
    "creditorAccountNumber" => "12345789012",
    "creditorBIC" => "OKOYFIHH",
    "creditorName" => "creditorName",
    "reason" => "reason phrase"
]);

echo $test->build(true);

Explication

This code will initiate the basic information for transaction

$test = TransferFileCredit::createCustomerTransfer(
    "uniqueID",
    "My society",
    "pain.001.001.03",
    "Europe/Paris"
);

This code will create the debitor account

$test->addPaymentInfo("ref-paiement-x",[
    "debtorName" => "My society",
    "debtorIBAN" => "FI1350001540000056",
    "debtorBIC" => "PSSTFRPPMON"
]
);

This code will create de credit bank transfert to the beneficiary

$test->createTransaction('payement-x',[
    "amount" => 500,
    "creditorIBAN" => "FI1350001540000056",
    "creditorAccountNumber" => "12345789012",
    "creditorBIC" => "OKOYFIHH",
    "creditorName" => "creditorName",
    "reason" => "reason phrase"
]);