Simple RESTful mini WS with only one endpoint.
PHP 5.5+.
$ git clone https://github.com/eacheble/locations-test.git
$ composer install
$ php -S localhost:8080 -t . index.php
$ vendor/bin/phpunit
With the WS running locally you can:
$ curl -i -X GET -H "Content-type: application/json" -H "Accept: application/json" "http://localhost:8080/locations/{id}"
where {id}
is the instagram media id from which you want to extract the location information.
e.g:
$ curl -i -X GET -H "Content-type: application/json" -H "Accept: application/json" "http://localhost:8080/locations/8"