Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,9 @@ To do this, place the following code somewhere close to your application initial
use Covery\Client\Facade;
use Covery\Client\Transport\Curl;

Facade::setTransport(new Curl(5.0 /* Timeout */));
$connectTimeoutSeconds = 5.0;
$requestTimeoutSeconds = 2.0;
Facade::setTransport(new Curl($connectTimeoutSeconds, $requestTimeoutSeconds));
Facade::setCredentials('<token>', '<secret>');
```

Expand All @@ -51,7 +53,7 @@ use Covery\Client\Envelopes\Builder;
use Covery\Client\Facade;
use Covery\Client\Identities\Stub;

$event = Builder::loginEvent(md5($userId), string($userId), time(), 'foo@bar.com', false) // Using builder
$event = Builder::loginEvent(md5($userId), (string)$userId, time(), 'foo@bar.com', false) // Using builder
->addIdentity(new Stub()) // stub identity
->build(); // building envelope

Expand All @@ -66,7 +68,7 @@ Postback event example:
use Covery\Client\Envelopes\Builder;
use Covery\Client\Facade;

$event = Builder::postbackEvent($requestId, null, 'code', 'reason')->build(); //postbcak for event with id $requestId
$event = Builder::postbackEvent($requestId, null, 'code', 'reason')->build(); // postback for event with id $requestId
$postbackRequestId = Facade::sendPostback($event);
```

Expand Down Expand Up @@ -152,6 +154,8 @@ You may provide the following as envelopes:

<a name="changelog"></a>
## Changelog
* `1.2.0`
* Added support for request timeouts
* `1.1.9`
* Added optional `bic` field for transfer event
* `1.1.8`
Expand Down
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
},
"minimum-stability": "stable",
"require": {
"php": ">=5.4",
"php": ">=5.6",
"psr/http-message": "~1.0",
"psr/log": "~1.0",
"guzzlehttp/psr7": ">=1.0.0"
Expand All @@ -27,7 +27,7 @@
"guzzlehttp/guzzle": ">=6.0.0"
},
"require-dev": {
"phpunit/phpunit": "4.8.36",
"phpunit/phpunit": "5.7.27",
"symfony/yaml": "2.1.13",
"phpdocumentor/reflection-docblock": "2.0.4"
}
Expand Down
Loading