Skip to content
This repository was archived by the owner on Aug 29, 2024. It is now read-only.

Commit 7841a65

Browse files
committed
improve readme
1 parent 70634a5 commit 7841a65

File tree

3 files changed

+8
-5
lines changed

3 files changed

+8
-5
lines changed

README.MD

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
1-
PHP Genkgo v1 API Connector
1+
PHP Genkgo v2 API Connector
22
============================================
33

44
[![Build Status](https://travis-ci.org/genkgo/api.png?branch=master)](https://travis-ci.org/genkgo/api)
55

66
## Usage
77

8-
Add genkgo/api to your dependencies and install them. You can have a look at [one of the
9-
examples](examples) or see the [docs](docs/index.md).
8+
Add `genkgo/api` and implementation of `psr/http-client` and `psr/http-factory` to your dependencies and install them.
9+
You can have a look at [one of the examples](examples) or see the [docs](docs/index.md). The examples rely on
10+
[Guzzle](https://github.com/guzzle/guzzle) and [Guzzle PSR-7](https://github.com/guzzle/psr7) for the http implementations.
1011

1112
```php
1213
<?php

examples/example.create.and.delete.person.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,10 @@
33

44
use Genkgo\Api\Connection;
55
use GuzzleHttp\Client;
6+
use GuzzleHttp\Psr7\HttpFactory;
67

78
$config = require_once 'config.php';
8-
$connection = new Connection(new Client(), $config['url'], $config['token']);
9+
$connection = new Connection(new Client(), new HttpFactory(), $config['url'], $config['token']);
910

1011
$folder = $connection->command('organization', 'find', [
1112
'name' => 'Aanmeldingen'

examples/example.login.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,10 @@
33

44
use Genkgo\Api\Connection;
55
use GuzzleHttp\Client;
6+
use GuzzleHttp\Psr7\HttpFactory;
67

78
$config = require_once 'config.php';
8-
$connection = new Connection(new Client(), $config['url'], $config['token']);
9+
$connection = new Connection(new Client(), new HttpFactory(), $config['url'], $config['token']);
910

1011
$result = $connection->command('organization', 'login', [
1112
'uid' => 'test',

0 commit comments

Comments
 (0)