Download the PHP package kfosoft/php-restful-client without Composer
On this page you can find all versions of the php package kfosoft/php-restful-client. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download kfosoft/php-restful-client
More information about kfosoft/php-restful-client
Files in kfosoft/php-restful-client
Download kfosoft/php-restful-client
More information about kfosoft/php-restful-client
Files in kfosoft/php-restful-client
Please rate this library. Is it a good library?
Informations about the package php-restful-client
PHP RESTful Client
Installation
Installation with Composer
Either run
php composer.phar require --prefer-dist kfosoft/rest-client:"*"
or add in composer.json
"require": {
...
"kfosoft/php-restful-client":"*"
}
Well done!
Example call GET
$result = (new RestClient())->requestParams(RestClient::GET, $url, $data)->call();
Example call CUSTOM with GET data
$result = (new RestClient())->requestParams(RestClient::CUSTOM, $url, $data)->call();
Example call CUSTOM with POST data
$result = (new RestClient())->requestParams(RestClient::CUSTOM, $url, $data)->usePost()->call();
Example call to url with http auth
$result = (new RestClient())->requestParams(RestClient::POST, $url, $data)->useHttpAuth($username, $password)->call();
Use response content type
$result = (new RestClient())->requestParams(RestClient::PATCH, $url, $data)->useResponseContentType()->call();
Get result in stdClass
$result = (new RestClient())->requestParams(RestClient::PUT, $url, $data)->usePost()->call(true);
Enjoy, guys!
All versions of php-restful-client with dependencies
PHP Build Version
Package Version
The package kfosoft/php-restful-client contains the following files
Loading the files please wait ....