Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/api-postcode/php-client
PHP Api Client using Curl
https://github.com/api-postcode/php-client
api client curl json php postcode
Last synced: about 5 hours ago
JSON representation
PHP Api Client using Curl
- Host: GitHub
- URL: https://github.com/api-postcode/php-client
- Owner: api-postcode
- License: mit
- Created: 2017-06-03T18:17:01.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2022-03-16T15:42:23.000Z (over 2 years ago)
- Last Synced: 2024-11-10T06:11:34.532Z (7 days ago)
- Topics: api, client, curl, json, php, postcode
- Language: PHP
- Homepage: https://api-postcode.nl
- Size: 12.7 KB
- Stars: 9
- Watchers: 3
- Forks: 3
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
Api Postcode PHP Client
=======================A PHP client for fetching address detials from https://api-postcode.nl
Installation
------------
Installation is a quick step process:1. Download the client with composer
### Step 1: Download php-client using composer
``` bash
$ composer require api-postcode/php-client
```Usage
-----
``` php
$token = 'secret-token';
$client = new ApiPostcode\Client\PostcodeClient($token);$address = $client->fetchAddress('1082MD', 34);
$address->getStreet(); // Claude Debussylaan
$address->getCity(); // Amsterdam
$address->getHouseNumber(); // 34
$address->getZipCode(); // 1082MD
$address->getLatitude(); // 52.3377074
$address->getLongitude(); // 4.8719565
```