PHPackages                             gplacesphp/api-client - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. gplacesphp/api-client

ActiveLibrary[API Development](/categories/api)

gplacesphp/api-client
=====================

Modern Google Places API client for PHP

v0.3.0(7y ago)12.3k2MITPHPPHP ^7.1CI failing

Since Oct 20Pushed 4y ago2 watchersCompare

[ Source](https://github.com/gplacesphp/api-client)[ Packagist](https://packagist.org/packages/gplacesphp/api-client)[ Docs](https://github.com/gplacesphp/api-client)[ RSS](/packages/gplacesphp-api-client/feed)WikiDiscussions master Synced 3d ago

READMEChangelog (3)Dependencies (7)Versions (4)Used By (0)

Google Places PHP Api Client
============================

[](#google-places-php-api-client)

[![Packagist](https://camo.githubusercontent.com/5e5837b6a166cafb1b16bf0f469fddb61570750fb34aec4c15628d4d02bc4cae/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f67706c616365737068702f6170692d636c69656e742e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/gplacesphp/api-client)[![PHP from Packagist](https://camo.githubusercontent.com/742095bbaa4b3962ac089a87cd0d83aa0939f0e0d8a78e2d7bdfc7c63313cbbc/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f67706c616365737068702f6170692d636c69656e742e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/gplacesphp/api-client)[![Packagist](https://camo.githubusercontent.com/23ff1a76e07eee7b4c55ba579c181858b02f795b94f25734e655e31b6ae54d8e/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f67706c616365737068702f6170692d636c69656e742e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/gplacesphp/api-client)

Build status
------------

[](#build-status)

VersionLinux buildWindows buildv1 (master)[![Travis (.org) branch](https://camo.githubusercontent.com/fcf5d0107cc2c10226dfa9b4f1e04e30cdc30e2a6097779c75a1c97457522373/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f67706c616365737068702f6170692d636c69656e742f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/gplacesphp/api-client)[![AppVeyor branch](https://camo.githubusercontent.com/35b82e316d137c19c38b00f7d4746d4b9e6b63ff149fbfdf8ee9f5ef35eba725/68747470733a2f2f696d672e736869656c64732e696f2f6170707665796f722f63692f5061626c6f4b6f77616c637a796b2f6170692d636c69656e742f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://ci.appveyor.com/project/PabloKowalczyk/api-client)Introduction
------------

[](#introduction)

Modern, Object-Oriented, client for using Google's Places API, requires PHP v7.1+. Any PSR-7 (HTTP Message Interface) and PSR-17 (HTTP Factories) implementations is supported (and required). Supports caching by any PSR-16 (simple cache) implementation, also works with any HTTPlug client/adapter.

Installation
------------

[](#installation)

```
composer require gplacesphp/api-client
```

Usage
-----

[](#usage)

This examples uses `php-http/guzzle6-adapter` as a PSR-18 implementation and `zendframework/zend-diactoros` as a PSR-7/PSR-17 implementation. Any other PSR-7/PSR-17/PSR-18 implementations are supported. If you don't have them installed you will need to run:

```
composer require \
    guzzlehttp/guzzle \
    php-http/guzzle6-adapter \
    zendframework/zend-diactoros
```

Remember to replace `` with you key.

More usage examples are in `examples` directory.

### Place details

[](#place-details)

#### Basic example

[](#basic-example)

```
