Documentation

GuzzleFactory
in package

This is the guzzle factory class.

Tags
author

Graham Campbell graham@alt-three.com

Table of Contents

BACKOFF  = 1000
The default backoff multiplier.
CODES  = [429]
The default 4xx retry codes.
CONNECT_TIMEOUT  = 10
The default connect timeout.
TIMEOUT  = 15
The default transport timeout.
handler()  : HandlerStack
Create a new guzzle handler stack.
make()  : Client
Create a new guzzle client.

Constants

BACKOFF

The default backoff multiplier.

public int BACKOFF = 1000

CODES

The default 4xx retry codes.

public array<string|int, int> CODES = [429]

CONNECT_TIMEOUT

The default connect timeout.

public int CONNECT_TIMEOUT = 10

TIMEOUT

The default transport timeout.

public int TIMEOUT = 15

Methods

handler()

Create a new guzzle handler stack.

public static handler([int|null $backoff = null ][, array<string|int, int>|null $codes = null ][, HandlerStack|null $stack = null ]) : HandlerStack
Parameters
$backoff : int|null = null
$codes : array<string|int, int>|null = null
$stack : HandlerStack|null = null
Return values
HandlerStack

make()

Create a new guzzle client.

public static make([array<string|int, mixed> $options = [] ][, int|null $backoff = null ][, array<string|int, int>|null $codes = null ]) : Client
Parameters
$options : array<string|int, mixed> = []
$backoff : int|null = null
$codes : array<string|int, int>|null = null
Return values
Client

Search results