protected function addEndpoint($name, $url)
    {
        // Add or modify the endpoint URL
        $this->endpoints[$name] = $this->ensureSslEndpoint($url);
        $this->active_endpoint = $name;

        // Return boolean if endpoint has been added successfully
        return array_key_exists($name, $this->endpoints);
    }