def get_all_branches(self, get_data_version=False):
    'Get all the branches available in the database.'
    self._check_connection()
    api_url = self._documents_url().split('/')
    api_url = api_url[:(- 2)]
    api_url = ('/'.join(api_url) + '/_commits')
    result = requests.get(api_url, headers={'user-agent': f'terminusdb-client-python/{__version__}'}, params={'type': 'Branch'}, auth=self._auth())
    if get_data_version:
        (result, version) = _finish_response(result, get_data_version)
        return (list(_result2stream(result)), version)
    return list(_result2stream(_finish_response(result)))
Get all the branches available in the database.
def get_all_branches(self, get_data_version=False):
    
    self._check_connection()
    api_url = self._documents_url().split('/')
    api_url = api_url[:(- 2)]
    api_url = ('/'.join(api_url) + '/_commits')
    result = requests.get(api_url, headers={'user-agent': f'terminusdb-client-python/{__version__}'}, params={'type': 'Branch'}, auth=self._auth())
    if get_data_version:
        (result, version) = _finish_response(result, get_data_version)
        return (list(_result2stream(result)), version)
    return list(_result2stream(_finish_response(result)))