Метод | Описание | |
---|---|---|
__construct ( $apiKey = null, $apiBase = null ) | ||
handleApiError ( string $rbody, integer $rcode, array $rheaders, array $resp ) | ||
request ( string $method, string $url, array | null $params = null, array | null $headers = null ) : array | ||
setHttpClient ( $client ) |
Метод | Описание | |
---|---|---|
_defaultHeaders ( $apiKey ) | ||
_encodeObjects ( $d ) | ||
_formatAppInfo ( $appInfo ) | ||
_interpretResponse ( $rbody, $rcode, $rheaders ) | ||
_processResourceParam ( $resource, $hasCurlFile ) | ||
_requestRaw ( $method, $url, $params, $headers ) | ||
httpClient ( ) |
public request ( string $method, string $url, array | null $params = null, array | null $headers = null ) : array | ||
$method | string | |
$url | string | |
$params | array | null | |
$headers | array | null | |
Результат | array | An array whose first element is an API response and second element is the API key used to make the request. |