As the name says, it is made to be basic and direct.
Client class
Psr\Http\Client\ClientInterface
| Name | Description |
|---|---|
| connect | Function connect |
| Instance a Request Interface object with the specified options. | |
| delete | Function delete |
| Instance a Request Interface object with the specified options. | |
| get | Function get |
| Instance a Request Interface object with the specified options. | |
| head | Function head |
| Instance a Request Interface object with the specified options. | |
| options | Function options |
| Instance a Request Interface object with the specified options. | |
| path | Function path |
| Instance a Request Interface object with the specified options. | |
| post | Function post |
| Instance a Request Interface object with the specified options. | |
| purge | Function purge |
| Instance a Request Interface object with the specified options. | |
| put | Function put |
| sendRequest | Funtion sendRequest |
| Sends a PSR-7 request and returns a PSR-7 response. | |
| trace | Function trace |
| Instance a Request Interface object with the specified options. |
Description
public connect (string $uri, array $data)
Function connect Instance a Request Interface object with the specified options.
Options: $method, $uri, $data, and $options, and returns a ResponseInterface instance.
Parameters
(string) $uri(array) $dataReturn Values
\ResponseInterface
Description
public delete (string $uri, array $data)
Function delete Instance a Request Interface object with the specified options.
Options: $method, $uri, $data, and $options, and returns a ResponseInterface instance.
Parameters
(string) $uri(array) $dataReturn Values
\ResponseInterface
Description
public get (string $uri, array $data, array $data)
Function get Instance a Request Interface object with the specified options.
Options: $method, $uri, $data, and $options, and returns a ResponseInterface instance.
Parameters
(string) $uri(array) $data(array) $dataReturn Values
\ResponseInterface
Description
public head (string $uri, array $data)
Function head Instance a Request Interface object with the specified options.
Options: $method, $uri, $data, and $options, and returns a ResponseInterface instance.
Parameters
(string) $uri(array) $dataReturn Values
\ResponseInterface
Description
public options (string $uri, array $data)
Function options Instance a Request Interface object with the specified options.
Options: $method, $uri, $data, and $options, and returns a ResponseInterface instance.
Parameters
(string) $uri(array) $dataReturn Values
\ResponseInterface
Description
public path (string $uri, array $data)
Function path Instance a Request Interface object with the specified options.
Options: $method, $uri, $data, and $options, and returns a ResponseInterface instance.
Parameters
(string) $uri(array) $dataReturn Values
\ResponseInterface
Description
public post (string $uri, array $data)
Function post Instance a Request Interface object with the specified options.
Options: $method, $uri, $data, and $options, and returns a ResponseInterface instance.
Parameters
(string) $uri(array) $dataReturn Values
\ResponseInterface
Description
public purge (string $uri, array $data)
Function purge Instance a Request Interface object with the specified options.
Options: $method, $uri, $data, and $options, and returns a ResponseInterface instance.
Parameters
(string) $uri(array) $dataReturn Values
\ResponseInterface
Description
public put (string $uri, array $data)
Function put
Instance a Request Interface object with the specified options.
Options: $method, $uri, $data, and $options, and returns a ResponseInterface instance.
Parameters
(string) $uri(array) $dataReturn Values
\ResponseInterface
Description
public sendRequest (\RequestInterface $request)
Funtion sendRequest Sends a PSR-7 request and returns a PSR-7 response.
Parameters
(\RequestInterface) $requestReturn Values
\ResponseInterface
Throws Exceptions
\ClientException
If an error happens while processing the request.
Description
public trace (string $uri, array $data)
Function trace Instance a Request Interface object with the specified options.
Options: $method, $uri, $data, and $options, and returns a ResponseInterface instance.
Parameters
(string) $uri(array) $dataReturn Values
\ResponseInterface