{"id":21072915,"url":"https://github.com/h4kuna/fio","last_synced_at":"2025-10-09T18:03:49.698Z","repository":{"id":4525610,"uuid":"5665684","full_name":"h4kuna/fio","owner":"h4kuna","description":"Read and send payment order for FIO bank, PSR-17 ready","archived":false,"fork":false,"pushed_at":"2025-07-30T11:43:30.000Z","size":366,"stargazers_count":55,"open_issues_count":4,"forks_count":25,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-10-05T13:37:39.645Z","etag":null,"topics":["api-client","fio","php"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/h4kuna.png","metadata":{"files":{"readme":"README.md","changelog":"changelog.md","contributing":null,"funding":".github/FUNDING.yml","license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null},"funding":{"github":["h4kuna"],"custom":["https://revolut.me/milan2m/czk1000/fio"]}},"created_at":"2012-09-04T00:47:18.000Z","updated_at":"2025-07-30T11:43:11.000Z","dependencies_parsed_at":"2024-03-20T12:27:48.310Z","dependency_job_id":"c954ac78-f4a1-47ec-af82-7134e4545d7d","html_url":"https://github.com/h4kuna/fio","commit_stats":{"total_commits":149,"total_committers":11,"mean_commits":"13.545454545454545","dds":0.4093959731543624,"last_synced_commit":"00a938dd22df61c733ed1ab6e75c55dc966b3aa6"},"previous_names":[],"tags_count":42,"template":false,"template_full_name":null,"purl":"pkg:github/h4kuna/fio","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/h4kuna%2Ffio","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/h4kuna%2Ffio/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/h4kuna%2Ffio/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/h4kuna%2Ffio/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/h4kuna","download_url":"https://codeload.github.com/h4kuna/fio/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/h4kuna%2Ffio/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279000741,"owners_count":26082932,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-09T02:00:07.460Z","response_time":59,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["api-client","fio","php"],"created_at":"2024-11-19T18:59:22.752Z","updated_at":"2025-10-09T18:03:49.674Z","avatar_url":"https://github.com/h4kuna.png","language":"PHP","funding_links":["https://github.com/sponsors/h4kuna","https://revolut.me/milan2m/czk1000/fio"],"categories":[],"sub_categories":[],"readme":"# Fio\n\n[![Downloads this Month](https://img.shields.io/packagist/dm/h4kuna/fio.svg)](https://packagist.org/packages/h4kuna/fio)\n[![Latest Stable Version](https://poser.pugx.org/h4kuna/fio/v/stable?format=flat)](https://packagist.org/packages/h4kuna/fio)\n[![Coverage Status](https://coveralls.io/repos/github/h4kuna/fio/badge.svg?branch=master)](https://coveralls.io/github/h4kuna/fio?branch=master)\n[![Total Downloads](https://poser.pugx.org/h4kuna/fio/downloads?format=flat)](https://packagist.org/packages/h4kuna/fio)\n[![License](https://poser.pugx.org/h4kuna/fio/license?format=flat)](https://packagist.org/packages/h4kuna/fio)\n\nSupport [Fio API](http://www.fio.sk/docs/cz/API_Bankovnictvi.pdf). Read is provided via json file.\n\n### Versions\n\nHere is [changlog](changelog.md)\n\n### Nette framework\nFollow this [extension](//github.com/h4kuna/fio-nette).\n\n\n### Installation to project by composer\n\n```sh\n$ composer require h4kuna/fio\n```\n\n## Not implemented\n- 5.3.1.7: STA (MT940)\n- 5.3.2: Transakce z POS terminálů nebo platební brány obchodníka\n- 6.4.2: pain.008 (příkazy k inkasu)\n- only json for read movements\n- only xml for import\n\n### How to use\nHere is [example](tests/origin/FioTest.php) and run via cli. This script require account.ini in same directory, whose looks like.\n\n```ini\n[my-account]\naccount = 123456789\ntoken = abcdefghijklmn\n\n[wife-account]\naccount = 987654321\ntoken = zyxuvtsrfd\n```\n\nFioFactory class help you create instances of classes FioPay and FioRead.\n\n```php\nuse h4kuna\\Fio;\n\n$fioFactory = new Fio\\FioFactory(parse_ini_file($ini, true));\n\n$fioRead = $fioFactory-\u003ecreateFioRead('my-account');\n$fioPay = $fioFactory-\u003ecreateFioPay('wife-account');\n\n$fioRead2 = $fioFactory-\u003ecreateFioRead(); // first in list is default, [my-account]\n```\n\nYou can use different config bud keep structure of php array\n```php\n[\n\t'my-alias' =\u003e [\n\t\t'account' =\u003e '123456789',\n\t\t'token' =\u003e 'abcdefg'\n\t],\n\t'next-alias' =\u003e [\n\t\t'account' =\u003e '987654321',\n\t\t'token' =\u003e 'tuvwxyz'\n\t]\n]\n```\n\n## Reading\n\n\u003e Keep on mind, all items like variable symbol, constant symbol and specific symbol can to have zeros from left side.\n\n#### Read range between date.\n\n```php\nuse h4kuna\\Fio;\n/* @var $fioRead Fio\\FioRead */\n/* @var $list Fio\\Read\\TransactionList */\n$list = $fioRead-\u003emovements(/* $from, $to */); // default is last week\n\nforeach ($list as $transaction) {\n    /* @var $transaction Fio\\Read\\Transaction */\n    var_dump($transaction-\u003emoveId);\n    foreach ($transaction as $property =\u003e $value) {\n        var_dump($property, $value);\n    }\n}\n\nvar_dump($list-\u003egetInfo());\n```\n\n#### You can download transaction by id of year.\n\n```php\nuse h4kuna\\Fio;\n/* @var $fioRead Fio\\FioRead */\n/* @var $list Fio\\Read\\TransactionList */\n$list = $fioRead-\u003emovementId(2, 2015); // second transaction of year 2015\n```\n\n#### Very useful method where download last transactions.\nAfter download it automatic set new break point.\n\n```php\nuse h4kuna\\Fio;\n/* @var $fioRead Fio\\FioRead */\n/* @var $list Fio\\Read\\TransactionList */\n$list = $fioRead-\u003elastDownload();\n// same use like above\nvar_dump($list-\u003egetInfo()-\u003eidLastDownload);\n```\n\n#### Change your break point.\nBy date.\n```php\n$fioRead-\u003esetLastDate('1986-12-30');\n$list = $fioRead-\u003elastDownload();\nvar_dump($list-\u003egetInfo()-\u003eidLastDownload);\n```\n\nBy movement ID.\n```php\n$fioRead-\u003esetLastId(123456789);\n$list = $fioRead-\u003elastDownload();\nvar_dump($list-\u003egetInfo()-\u003eidLastDownload); // 123456789\n```\n\n\u003e Tip: You can define own TransactionFactory and create instance and add to Read\\Json::__construct()\n\n## Payment (writing)\n\nApi has three response languages, default is set **cs**. For change:\n```php\n/* @var $fioPay h4kuna\\Fio\\FioPay */\n$fioPay-\u003esetLanguage('en');\n```\n\nFor send request is method send whose accept, file path to your xml or abo file or instance of class Property.\n```php\n$myFile = '/path/to/my/xml/or/abo/file.xml'; // file extension is important\n$fioPay-\u003esend($myFile);\n```\n\nObject pay only to czech or slovak:\n\n```php\n/* @var $national Fio\\Pay\\Payment\\National */\n$national = $fioPay-\u003ecreateNational($amount, $accountTo);\n$national-\u003esetVariableSymbol($vs);\n/* set next payment property $national-\u003eset* */\n$fioPay-\u003esend();\n```\n\nEuro zone payment:\n\n```php\n/* @var $euro Fio\\Pay\\Payment\\Euro */\n$euro = $fioPay-\u003ecreateEuro($amount, $accountTo, $name);\n$euro-\u003esetVariableSymbol($vs);\n/* set next payment property $euro-\u003eset* */\n$fioPay-\u003esend();\n```\n\nInternational payment:\n\n```php\n/* @var $international Fio\\Pay\\Payment\\International */\n$international = $fioPay-\u003ecreateInternational($amount, $accountTo, $bic, $name, $street, $city, $country, $info);\n$international-\u003esetRemittanceInfo2('foo');\n/* set next payment property $international-\u003eset* */\n$fioPay-\u003esend();\n```\n\nSend more payments in one request:\n\n```php\nforeach($pamentsRows as $row) {\n\t/* @var $national Fio\\Pay\\Payment\\National */\n\t$national = $fioPay-\u003ecreateNational($row-\u003eamount, $row-\u003eaccountTo);\n\t$national-\u003esetVariableSymbol($row-\u003evs);\n}\n$fioPay-\u003esend();\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fh4kuna%2Ffio","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fh4kuna%2Ffio","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fh4kuna%2Ffio/lists"}