horat1us/inn-parser

Ukranian INN Parser

1.2.1 2021-12-21 15:30 UTC

This package is auto-updated.

Last update: 2024-04-21 20:47:11 UTC


README

Latest Stable Version Total Downloads Build Status codecov

Simple parser that allows to decode ukranian tax reference number information

Парсер позволяет расшировывать ИНН (Украина) для получения даты рождения, пола и контрольной суммы.

Installation

Using composer:

composer require horat1us/inn-parser

Usage

<?php

use Horat1us\Inn;

$inn = 3184710691;

$parser = new Inn\Parser($inn);
$info = $parser->parse();

$info->isValid(); // is control sum match
$info->getGender(); // male
$info->getBirthDate(); // \DateTime
$info->getBirthDate()->format('Y-m-d'); // 1987-03-12

Contributors

License

MIT