veasin / nx-http-curl
http for nx
Installs: 0
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 0
Forks: 0
Open Issues: 0
Type:framework
Requires
- php: >=8.4
- ext-curl: *
- veasin/nx-http: >=0.0.1
Requires (Dev)
- veasin/nx: *
- veasin/nx-tools: >=0.0.12
README
http-curl for nx
composer require urn2/nx-http-curl
class app extends \nx\app{ use \nx\parts\http\curl; } $app =new app; $response =$app->http->patch($uri) ->query(['CODE'=>404]) ->setLog(function($str){ echo is_string($str) ?$str : json_encode($str, JSON_UNESCAPED_UNICODE | JSON_UNESCAPED_SLASHES), "\n"; }) ->send(); var_dump($response); var_dump($response->headers()); var_dump($response->body());