burakaktna/tkgmservice

PHP TKGM API Service

1.1 2023-04-08 19:08 UTC

This package is auto-updated.

Last update: 2024-10-08 22:18:17 UTC


README

Latest Version on Packagist Build Status Quality Score Total Downloads

With this package, you can easily perform operations such as parcel inquiry, provincial list, district list, and neighborhood list from TKGM API.

Installation

You can install the package via composer:

composer require burakaktna/tkgmservice

Usage

Print the list of provinces

require_once 'vendor/autoload.php';

use Burakaktna\TKGMService\TKGMService;

$tkgmService = new TKGMService();
$provinces = $tkgmService->getProvinces();

print_r($provinces);

Print the list of districts

require_once 'vendor/autoload.php';

use Burakaktna\TKGMService\TKGMService;

$tkgmService = new TKGMService();
$districts = $tkgmService->getDistricts(int $provinceId);

print_r($districts);

Print the list of neighborhoods

require_once 'vendor/autoload.php';

use Burakaktna\TKGMService\TKGMService;

$tkgmService = new TKGMService();
$neighborhoods = $tkgmService->getNeighborhoods(int $districtId);

print_r($neighborhoods);

Parcel inquiry

require_once 'vendor/autoload.php';

use Burakaktna\TKGMService\TKGMService;

$tkgmService = new TKGMService();
$parcel = $tkgmService->parcelInquiry(int $neighborhoodId, int $bobId, int $parcelId);

print_r($parcel);

Also, you can see more examples in the examples folder.

Testing

composer test

Changelog

Please see CHANGELOG for more information on what has changed recently.

Contributing

Please see CONTRIBUTING for details.

Security

If you discover any security-related issues, please email burak.aktna@gmail.com instead of using the issue tracker.

Credits

License

The MIT License (MIT). Please see License File for more information.