Skip to content

Latest commit

History

46 Commits

Folders and files

NameName
Last commit message
Last commit date

Repository files navigation

alt text

Scrutinizer Code QualityBuild StatusLatest Stable VersionTotal Downloads

O2System Curl

O2System Curl is a PHP Lightweight HTTP Request Client Library which is build for working more powerful with O2System Framework, but also can be used for integrated with others as standalone version with limited features.

Features

  • Utility methods to call GET, HEAD, POST, PUT, DELETE, CONNECT, OPTIONS, TRACE, PATCH requests.
  • Supports form parameters, file uploads and custom body entities.
  • Supports gzip compression.
  • Supports Basic, Digest, Negotiate, NTLM Authentication natively.
  • Customizable timeout.
  • Customizable default headers for every request (DRY).
  • Automatic response parsing for JSON, XML, HTML and PHP Serialize Parsing into a native object.
  • Multiple request support.

Composer Instalation

The best way to install O2System Curl is to use Composer

composer require o2system/curl

Packagist: https://packagist.org/packages/o2system/curl

Usage

useO2System\Curl;
useO2System\Kernel\Http\Message\Uri;
// Single Request$request = newCurl\Request();
$request->setUri( newUri() )->withHost( 'api.o2system.id' )->withPath( 'testing');
// Multi Request$multirequest = newCurl\MultiRequest();
$multirequest->register( $request );
// Get single response$response = $request->get();
// Get multiple responses$responses = $multirequest->get();

Documentation is available on this repository wiki or visit this repository github page.

Ideas and Suggestions

Please kindly mail us at hello@o2system.id

Bugs and Issues

Please kindly submit your issues at Github so we can track all the issues along development and send a pull request to this repository.

System Requirements

About

PHP Lightweight HTTP Request Client Library

Resources

Stars

6 stars

Watchers

4 watching

Forks

Releases

Packages

Used by

Contributors

Languages