PHP code example of pecherskiy-v / dadata
1. Go to this page and download the library: Download pecherskiy-v/dadata library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
pecherskiy-v / dadata example snippets
php
$client = new Dadata\Client(new \GuzzleHttp\Client(), [
'token' => '...',
'secret' => '...',
]);
php
$response = $client->cleanAddress('мск сухонска 11/-89');
$response = $client->cleanPhone('тел 7165219 доб139');
$response = $client->cleanPassport('4509 235857');
$response = $client->cleanName('Срегей владимерович иванов');
$response = $client->cleanEmail('serega@yandex/ru');
$response = $client->cleanDate('24/3/12');
$response = $client->cleanVehicle('форд фокус')