'List all versions.'

def list(self):

    endpoint = self.api.client.get_endpoint()
    url = urllib.parse.urlparse(endpoint)
    if (url.path.endswith('v2') or ('/v2/' in url.path) or url.path.endswith('v2.1') or ('/v2.1/' in url.path)):
        path = url.path[:url.path.rfind('/v2')]
        version_url = ('%s://%s%s' % (url.scheme, url.netloc, path))
    else:
        version_url = endpoint
    return self._list(version_url, 'versions')
