'Return the base url for endpoints.'

@property
def _base_url(self):

    if self.use_ssl:
        uri_scheme = 'https://'
    else:
        uri_scheme = 'http://'
    if self.port:
        return '{}{}:{}'.format(uri_scheme, self.host, self.port)
    return '{}{}'.format(uri_scheme, self.host)
