options['responseType'] = $responseType; $this->options['clientId'] = $clientId; $this->options['redirectUri'] = $redirectUri; $this->options['scope'] = $scope; $this->options['state'] = $state; } /** * Response Type * * @param string $responseType Response Type * @return $this Fluent Builder */ public function setResponseType(string $responseType): self { $this->options['responseType'] = $responseType; return $this; } /** * The Client Identifier * * @param string $clientId The Client Identifier * @return $this Fluent Builder */ public function setClientId(string $clientId): self { $this->options['clientId'] = $clientId; return $this; } /** * The url to which response will be redirected to * * @param string $redirectUri The url to which response will be redirected to * @return $this Fluent Builder */ public function setRedirectUri(string $redirectUri): self { $this->options['redirectUri'] = $redirectUri; return $this; } /** * The scope of the access request * * @param string $scope The scope of the access request * @return $this Fluent Builder */ public function setScope(string $scope): self { $this->options['scope'] = $scope; return $this; } /** * An opaque value which can be used to maintain state between the request and callback * * @param string $state An opaque value which can be used to maintain state between the request and callback * @return $this Fluent Builder */ public function setState(string $state): self { $this->options['state'] = $state; return $this; } /** * Provide a friendly representation * * @return string Machine friendly representation */ public function __toString(): string { $options = \http_build_query(Values::of($this->options), '', ' '); return '[Twilio.Oauth.V1.FetchAuthorizeOptions ' . $options . ']'; } }