Documentation

HttpClient
in package

Table of Contents

Properties

$debug  : bool
$guzzleHttpClient  : Client
$last_response  : mixed

Methods

__construct()  : mixed
get()  : mixed
getError()  : mixed
getGuzzleHttpClient()  : mixed
getResponseBody()  : mixed
mockLastResponse()  : mixed
post()  : mixed
getDefaultOptions()  : mixed

Properties

$guzzleHttpClient

protected Client $guzzleHttpClient

$last_response

private mixed $last_response = null

Methods

__construct()

public __construct(Client $client[, bool $debug = false ]) : mixed
Parameters
$client : Client
$debug : bool = false

get()

public get(string $endpoint, array<string|int, mixed> $options) : mixed
Parameters
$endpoint : string
$options : array<string|int, mixed>

getError()

public getError(mixed $e) : mixed
Parameters
$e : mixed

getGuzzleHttpClient()

public getGuzzleHttpClient() : mixed

getResponseBody()

public getResponseBody([mixed $key = null ]) : mixed
Parameters
$key : mixed = null

mockLastResponse()

public mockLastResponse(int $statusCode, string $json) : mixed
Parameters
$statusCode : int
$json : string

post()

public post(string $endpoint, array<string|int, mixed> $options) : mixed
Parameters
$endpoint : string
$options : array<string|int, mixed>

getDefaultOptions()

private getDefaultOptions() : mixed

        
On this page

Search results