You are here

public function RequestBuilder::__construct in Auth0 Single Sign On 8.2

RequestBuilder constructor.

Parameters

array $config Configuration array passed to \Auth0\SDK\API\Management constructor.:

Throws

CoreException If a returnType is set that is invalid.

File

vendor/auth0/auth0-php/src/API/Helpers/RequestBuilder.php, line 110

Class

RequestBuilder
Class RequestBuilder

Namespace

Auth0\SDK\API\Helpers

Code

public function __construct(array $config) {
  $this->method = $config['method'];
  $this->domain = $config['domain'];
  $this->basePath = isset($config['basePath']) ? $config['basePath'] : '';
  $this->guzzleOptions = isset($config['guzzleOptions']) ? $config['guzzleOptions'] : [];
  $this->headers = isset($config['headers']) ? $config['headers'] : [];
  if (array_key_exists('path', $config)) {
    $this->path = $config['path'];
  }
  $this
    ->setReturnType(isset($config['returnType']) ? $config['returnType'] : null);
}