public function setGlobalVar($variable, $value = null)
    {
        $uri = 'asterisk/variable';

        try {
            $this->client->getEndpoint()->post($uri, [
                'form_params' => [
                    'variable' => $variable,
                    'value' => $value
                ]
            ]);
        } catch (RequestException $e) {
            $this->processRequestException($e);
        }
    }
public function setGlobalVar($variable, $value = null)
    {
        $uri = 'asterisk/variable';

        try {
            $this->client->getEndpoint()->post($uri, [
                'form_params' => [
                    'variable' => $variable,
                    'value' => $value
                ]
            ]);
        } catch (RequestException $e) {
            $this->processRequestException($e);
        }
    }
public function setGlobalVar ( $ variable , $ value = null ) { $ uri = 'asterisk/variable' ; try { $ this -> client -> getEndpoint ( ) -> post ( $ uri , [ 'form_params' => [ 'variable' => $ variable , 'value' => $ value ] ] ) ; } catch ( RequestException $ e ) { $ this -> processRequestException ( $ e ) ; } }
Set the value of a global variable.

@param string $variable (required) The variable to set
@param string $value The value to set the variable to
@throws InvalidParameterException
Set the value of a global variable .